query
stringlengths 9
43.3k
| document
stringlengths 17
1.17M
| metadata
dict | negatives
sequencelengths 0
30
| negative_scores
sequencelengths 0
30
| document_score
stringlengths 5
10
| document_rank
stringclasses 2
values |
---|---|---|---|---|---|---|
[Layout][google.cloud.documentai.v1.Document.Page.Layout] for the [FormField][google.cloud.documentai.v1.Document.Page.FormField] value. Generated from protobuf field .google.cloud.documentai.v1.Document.Page.Layout field_value = 2; | public function setFieldValue($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\DocumentAI\V1\Document\Page\Layout::class);
$this->field_value = $var;
return $this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function html($formValue = '');",
"public function value_form(&$form, &$form_state) {\n parent::value_form($form, $form_state);\n //TODO make there on option for a checkbox. At the moment i can not get it working because if the expose filter is defaulted to True, that it will always show as check even if you uncheck it.\n #$form['value']['#type'] = 'checkbox';\n\n\n $form['value']['#options'] = array(\n SEARCH_API_SITE_THIS_SITE_ONLY => t('This site only'),\n SEARCH_API_SITE_ALL_SITES => t('All sites')\n );\n }",
"function _behat_editor_check_for_render_field($value) {\n $field_name = key($value);\n\n $id_input = (isset($value[$field_name]['#id'])) ? \"id=\\\"{$value[$field_name]['#id']}\\\"\" : '';\n $name = (isset($value[$field_name]['#name'])) ? \"name=\\\"{$value[$field_name]['#name']}\\\"\" : '';\n $class = (isset($value[$field_name]['#class'])) ? \"class=\\\"{$value[$field_name]['#class']}\\\"\" : '';\n $value = $value[$field_name]['#value'];\n $data = \"<input type='hidden' value=\\\"{$value}\\\" $id_input $name $class>\";\n return $data;\n}",
"function _fourD_analysis_goal_form_parts( $values=array() ) {\n // fourD_analysis_debug('_fourD_analysis_goal_form_parts; $form_id: ' .$form_id .', #id: '.$form['#id']. '; #type: ' . $form['type']['#value'] .'; FORM: '. print_r($form, TRUE) );\n \n $form = array();\n \n // fieldset\n $form['analysis'] = array(\n '#title' => t('Goal Analysis'),\n '#type' => 'fieldset',\n '#description' => t('Enter values for the various parameters. Explore the impact of ' .\n 'different values. Play around a get a feel for it.'),\n '#collapsible' => TRUE,\n '#collapsed' => FALSE,\n );\n \n $form['analysis']['goal_weight'] = array( // piggy back off the goal_weight from Ratings schema\n '#title' => t('Weight'),\n '#type' => 'textfield',\n '#field_suffix' => t('[0.0,1.0]'),\n '#size' => 4,\n // '#default_value'=> isset($values['goal_weight']) ? number_format($values['goal_weight'], 10) : '0.0',\n '#default_value' => _fourD_analysis_trim_decimal( $values['goal_weight'] ),\n '#weight' => 1,\n );\n \n return $form;\n}",
"public function testValue(): void\n {\n $this->setInaccessibleProperty(new Html(), 'generateIdCounter', ['i' => 6]);\n $this->formModel->setAttribute('string', '1');\n $expected = <<<'HTML'\n <div>\n <label for=\"typeform-string\">String</label>\n <input type=\"range\" id=\"typeform-string\" name=\"TypeForm[string]\" value=\"1\" placeholder=\"Typed your text string.\" oninput=\"i7.value=this.value\">\n <output id=\"i7\" name=\"i7\" for=\"TypeForm[string]\">1</output>\n <div>Write your text string.</div>\n </div>\n HTML;\n $this->assertEqualsWithoutLE(\n $expected,\n Field::widget()->config($this->formModel, 'string')->range()->render(),\n );\n\n // int value 1\n $this->setInaccessibleProperty(new Html(), 'generateIdCounter', ['i' => 7]);\n $this->formModel->setAttribute('int', '1');\n $expected = <<<'HTML'\n <div>\n <label for=\"typeform-int\">Int</label>\n <input type=\"range\" id=\"typeform-int\" name=\"TypeForm[int]\" value=\"1\" oninput=\"i8.value=this.value\">\n <output id=\"i8\" name=\"i8\" for=\"TypeForm[int]\">1</output>\n </div>\n HTML;\n $this->assertEqualsWithoutLE(\n $expected,\n Field::widget()->config($this->formModel, 'int')->range()->render(),\n );\n }",
"public function getFormFieldData() {\n return @$this->attributes['form_field_data'];\n }",
"public function getFieldValue(): string;",
"private function setFieldValue() {\n $fieldValue = null;\n $field = $this->field;\n $isArray = is_array($field) || Connect::isArray($field);\n $defaults = $this->getDefaultValues($this->data['attrs']['name']);\n\n // Custom attributes and custom fields can have default values specified for them.\n // So if there's a default value for the field but there's also a dynamic default value\n // coming in, that dynamic value should take precedence.\n if (!$isArray && $defaults['meta'] !== '' && $defaults['dynamic'] && !is_null($field) && (string) $field === (string) $defaults['meta']) {\n $this->field = $field = null;\n }\n\n if ($this->dataType === 'Menu') {\n // fieldValue is preserved as the actual Connect menu option object\n $fieldValue = $this->getMenuFieldValue($field, $defaults);\n }\n // If the field has a value (including '') sent in through POST, we should use that.\n // Generally only the case in the basic pageset.\n else if ($defaults['post'] !== false) {\n $fieldValue = $defaults['post'];\n }\n // Check if the field has an existing value.\n else if($field !== null && !$isArray) {\n if (is_bool($field) || is_int($field)) {\n $fieldValue = $field;\n }\n else if (is_string($field)) {\n $fieldValue = htmlspecialchars($field, ENT_QUOTES, 'UTF-8', false);\n }\n }\n // If the field has a value from the URL or widget attributes\n else if($defaults['dynamic']) {\n $fieldValue = $defaults[$defaults['dynamic']];\n }\n else if ($isArray) {\n //Keep an existing array value as an array. It isn't up to this base class to determine what to do\n //with the data so it shouldn't be destroying data. The child widget is responsible for displaying the data to how it sees fit.\n $fieldValue = $field;\n }\n else {\n // Entity-ize any characters in the existing value in non-array types.\n $fieldValue = htmlspecialchars($field, ENT_QUOTES, 'UTF-8', false);\n }\n return $this->modifyDateValue($fieldValue);\n }",
"function print_aweber_input($value) {\r\n\t\tif(isset($value['std'])) {\r\n\t\t\t$default = $value['std'];\r\n\t\t} else {\r\n\t\t\t$default = false;\r\n\t\t}\r\n\t\tif(isset($value['protected'][0][\"id\"])) {\r\n\t\t\t$protectedValue = $value['protected'][0][\"id\"];\r\n\t\t} else {\r\n\t\t\t$protectedValue = false;\r\n\t\t}\r\n\t\t\r\n\t\t$protected_value = $this->get_field_value($protectedValue, $default);\r\n\t\t\r\n\t\t\r\n\t\tif(((isset($value['protected'][0][\"id\"]) && $value['protected'][0][\"id\"]!=\"\") && $protected_value==$value['protected'][0][\"value\"]) || (!isset($value['protected'][0][\"id\"]))) {\r\n\t\t\t$input_value = $this->get_field_value($value['id'], $default);\r\n\t\t?>\r\n\t\t<?php if(isset($value['home']) && $value['home'] == \"yes\" ) { ?><div class=\"input-item-full-width-inside clearfix\"><?php } else { ?>\r\n\t\t\t<div class=\"input-item-full-width clearfix\">\r\n\t\t<?php } ?>\r\n\t\t\t<label><?php echo $value['title'];?></label>\r\n\t\t\t<span class=\"input-text\"><input type=\"text\" name=\"<?php echo $value['id'];?>\" value=\"<?php echo $input_value;?>\" <?php if(isset($value['number']) && $value['number'] == \"yes\") { ?>style=\"width: 46px;\"<?php } ?>/></span>\r\n\t\t</div>\r\n\t\t<?php\r\n\t\t}\r\n\t}",
"public function getFieldValue() : string;",
"public function setField($field, $input, $value): static;",
"public function get_optin_form_structure();",
"function field($type,$name,$value=\"\",$size=\"\",$format=\"\",$prefix=\"\",$postfix=\"\",$help=\"\",$helpfree=\"\")\r\n {\r\n if (right::field_view($help) or !$help or $type == \"hidden\")\r\n {\r\n if ($prefix) echo \"<span class='normal'>$prefix</span> \";\r\n\r\n $retString = \"\";\r\n\r\n// parse type\r\n switch ($type)\r\n {\r\n case image:\r\n $sizeString = \"$size\";\r\n break;\r\n \r\n default:\r\n $sizeString = \"size='$size'\";\r\n }\r\n \r\n \t\t$retString .= \"<input $format $sizeString type='$type' name='$name' value='$value' \";\r\n \r\n \tif ($help or $helpfree) $retString .= help::show($help,$helpfree);\r\n \t\t\r\n if (right::field_edit($help) or !$help or $type == \"hidden\") // editable: enable edit\r\n {\r\n $retString .= \">\";\r\n }\r\n else // display only\r\n {\r\n $retString .= \" disabled>\";\r\n }\r\n \r\n if ($postfix) $retString .= \" <span class='normal'>$postfix</span>\";\r\n }\r\n return ($retString);\r\n }",
"public function getForm()\n {\n return $this->page_control_default_data;\n }",
"function print_input($value) {\r\n\t\tif(isset($value['std'])) {\r\n\t\t\t$default = $value['std'];\r\n\t\t} else {\r\n\t\t\t$default = false;\r\n\t\t}\r\n\t\tif(isset($value['protected'][0][\"id\"])) {\r\n\t\t\t$protectedValue = $value['protected'][0][\"id\"];\r\n\t\t} else {\r\n\t\t\t$protectedValue = false;\r\n\t\t}\r\n\t\t\r\n\t\t$protected_value = $this->get_field_value($protectedValue, $default);\r\n\t\t\r\n\t\t\r\n\t\tif(((isset($value['protected'][0][\"id\"]) && $value['protected'][0][\"id\"]!=\"\") && $protected_value==$value['protected'][0][\"value\"]) || (!isset($value['protected'][0][\"id\"]))) {\r\n\t\t\t$input_value = $this->get_field_value($value['id'], $default);\r\n\r\n\t\t?>\r\n\t\t<?php if( isset($value['home']) && $value['home'] == \"yes\" ) { ?><div class=\"input-item-full-width-inside clearfix\"><?php } else { ?>\r\n\t\t\t<div class=\"input-item-full-width clearfix\">\r\n\t\t<?php } ?>\r\n\t\t\t<label>\r\n\t\t\t\t<?php \r\n\t\t\t\t\techo $value['title'];\r\n\t\t\t\t?>\r\n\t\t\t</label>\r\n\t\t\t\t<?php\r\n\t\t\t\t\tif (isset($value['info'])) {\r\n\t\t\t\t\t\techo different_themes_info_message($value['info']);\r\n\t\t\t\t\t}\t\r\n\t\t\t\t?>\r\n\t\t\t\r\n\t\t\t<span class=\"input-text\"><input type=\"text\" name=\"<?php echo $value['id'];?>\" value=\"<?php echo $input_value;?>\" <?php if(isset($value['number']) && $value['number'] == \"yes\") { ?>style=\"width: 46px;\"<?php } ?>/></span>\r\n\t\t</div>\r\n\t\t<?php\r\n\t\t}\r\n\t}",
"public function plain($formValue = '');",
"function wpcf_fields_google_map_meta_box_form( $data ) {\n $form['name'] = array(\n '#name' => 'wpcf[' . $data['slug'] . ']', // Set this to override default output\n '#type' => 'textfield',\n '#title' => __( 'Add Google Map coordinates', 'wpcf' ),\n '#description' => __( 'Your input should look something like \"41.934146,12.455821\"', 'wpcf' )\n );\n return $form;\n}",
"function formName() {\n\t\t\n\t\treturn $this->formInputField(\"\",\"DocType\",\"\",24,520,255, 'readonly=\"readonly\"');\n\t}",
"function fill_field( $field, $value, $overwrite = false )\r\n {\r\n \r\n if( ( ! isset( $_SESSION[\"oe_form\"][$this->api_call][\"data\"] ) ) or $overwrite == true )\r\n {$this->data[$field] = $value ; }\r\n }",
"function acfe_extract_sub_field(&$layout, $name, $value){\n \n $sub_field = false;\n \n // loop\n foreach($layout['sub_fields'] as $k => $row){\n \n if($row['name'] !== $name)\n continue;\n \n $sub_field = acf_extract_var($layout['sub_fields'], $k);\n break;\n \n }\n \n if(!$sub_field)\n return false;\n \n // Reset keys\n $layout['sub_fields'] = array_values($layout['sub_fields']);\n \n // Add value\n if(isset($value[$sub_field['key']])){\n \n $sub_field['value'] = $value[$sub_field['key']];\n \n }elseif(isset($sub_field['default_value'])){\n \n $sub_field['value'] = $sub_field['default_value'];\n \n }\n \n return $sub_field;\n \n}",
"public function getFieldValue()\n {\n return $this->field_value;\n }",
"public function value($field);",
"function value_form(&$form, &$form_state) {\n parent::value_form($form, $form_state);\n if (empty($form_state['exposed'])) {\n $form['value']['type'] = array(\n '#type' => 'radios',\n '#title' => t('Value type'),\n '#options' => array(\n 'date' => t('A date in any machine readable format. CCYY-MM-DD HH:MM:SS is preferred.'),\n 'offset' => t('An offset from the current time such as \"!example1\" or \"!example2\"', array('!example1' => '+1 day', '!example2' => '-2 hours -30 minutes')),\n ),\n '#default_value' => !empty($this->value['type']) ? $this->value['type'] : 'date',\n );\n if (module_exists('date_popup')) {\n $form['value']['type']['#options']['date_popup'] = t('Use a date popup field for date entry.');\n }\n/* $form['value']['accepted_relative'] = array(\n '#title' => t('Accepted Relative Values'),\n '#type' => 'fieldset',\n '#collapsible' => TRUE,\n '#collapsed' => TRUE,\n '#weight' => 20,\n '#attributes' => array('class' => array('accepted-relative-values-fieldset')),\n );\n $form['value']['accepted_relative']['info'] = array(\n '#type' => 'markup',\n '#markup' => \"All expressions are case insensitive. <br/>\" .\n \"'<strong>First Of This Month</strong>' = First Day of this Month<br/>\" .\n \"'<strong>Last Of This Month</strong>' = Last Day of this Month<br/>\" .\n \"'<strong>(<i>n</i>)th/(<i>n</i>)st Of This Month</strong>' = <i>n</i> being a numbered day, this expression will represent that numbered day of this month. e.g. 21st Of This Month or 14th Of This Month<br/>\" .\n \"'<strong>Bimonthly</strong>' = Put in both Min and Max to dynamically generate a date range based on the current date. e.g. if it is the 3rd of the month, it will return a range of the 1st to the 15th. If it is after the 15th, it will return the 16th to the end of the month.\",\n '#attributes' => array('class' => array('accepted-relative-values')),\n );*/\n }\n\n }",
"protected function form()\n {\n $form = new Form(new VisitPage);\n\n $form->text('gh_id', 'Gh id');\n $form->text('ref_date', 'Ref date');\n $form->text('page_path', 'Page path');\n $form->number('page_visit_pv', 'Page visit pv');\n $form->number('page_visit_uv', 'Page visit uv');\n $form->decimal('page_staytime_pv', 'Page staytime pv');\n $form->number('entrypage_pv', 'Entrypage pv');\n $form->number('exitpage_pv', 'Exitpage pv');\n $form->number('page_share_pv', 'Page share pv');\n $form->number('page_share_uv', 'Page share uv');\n\n return $form;\n }",
"function field_value($name, $key = null)\n{\n global $loaded_information;\n\n $field_value = isset($loaded_information[$name]) ? $loaded_information[$name] : ['value' => null, 'privacy' => 'public'];\n if ($field_value != null && !isset($field_value['privacy']) && !is_null($key) && isset($loaded_information[$key]) && isset($loaded_information[$key]['privacy'])) {\n $field_value['privacy'] = $loaded_information[$key]['privacy'];\n }\n\n if (isset($field_value['privacy']) && $field_value['privacy'] == 'private') {\n return 'This information is private';\n }\n\n return is_null($field_value['value']) || $field_value['value'] == '' ? '<span style=\"color:#AAA\">Not entered</span>' : $field_value['value'];\n}",
"public function populate(){\n \n // canary...\n $rdocblock = $this->getDocBlock();\n if(empty($rdocblock)){ return; }//if\n \n $ret_field = null;\n \n $this->reflection->setAccessible(true);\n \n $val = $this->reflection->getValue($this);\n \n if(($val === null)){\n \n if($class_name = $this->getClassName()){\n \n // if we don't have an absolute class name, then we need to check if it is a supported\n // class name...\n if($class_name[0] !== '\\\\'){\n \n foreach($this->form_field_map as $form_field => $form_field_class_name){\n \n if(preg_match(sprintf('#%s$#i',$form_field),$class_name)){\n \n $class_name = $form_field_class_name;\n break;\n \n }//if\n \n }//foreach\n \n }//if\n \n }//if\n \n if(!empty($class_name)){\n \n // make sure the class name is a Field descendant, ignore everything else... \n if(class_exists($class_name) && is_subclass_of($class_name,$this->field_class_name)){\n \n $instance = $this->createField($class_name);\n \n $this->reflection->setValue(\n $this->reflection->isStatic() ? null : $this->form,\n $instance\n );\n \n $ret_field = $instance;\n \n }//if\n \n }//if\n \n }//if\n \n $this->field = $ret_field;\n return $ret_field;\n \n }",
"function setGraphData($value) {\n return $this->setFieldValue('text_field_2', serialize($value));\n }",
"public function field()\r\n\t{\r\n\t\t$name\t= $this->name;\r\n\t\t$value\t= $this->value;\r\n\t\t$args\t=\tarray_to_string( $this->attributes );\r\n\t\t\r\n\t\t$class\t=\tstr_replace('[', '', str_replace(']', '', $name ) );\r\n\t\t\r\n\t\t$field\t=\t'<input type=\"hidden\" name=\"' . $name . '\" value=\"0\" />'\r\n\t\t\t\t.\t'<div class=\"switch\" data-on=\"primary\" data-off=\"danger\" data-on-label=\"' . t( $this->labelon ) . '\" data-off-label=\"' . t( $this->labeloff ). '\">'\r\n\t\t\t\t.\t'\t<input value=\"1\" name=\"' . $name . '\" type=\"checkbox\" ' . ( $value == 1 ? ' checked=\"checked\"' : '' ) . ' />'\r\n\t\t\t\t.\t'</div>';\r\n\t\t\r\n\t\treturn $field;\r\n\t}",
"public function text_input_field($args) {\n\t $page = '';\n\t $var_name = $args['option_name'];\n\t \n\t $label = $args['label'];\n\t $type = 'div';\n\t if ( ! empty( $args['type'] ) ) {\n\t $type = $args['type'];\n\t }\n\t $required = false;\n\t if( ! empty( $args['required'] ) ) {\n\t $required = boolval($args['required']);\n\t }\n\t if ( array_key_exists( 'value', $args ) ) {\n\t $var_value = strval($args['value']);\n\t } else {\n\t $var_value = '';\n\t /*\n\t * retain selection values in case of repost due to error\n\t */\n\t if ( array_key_exists( $var_name, $_POST ) ) {\n\t $var_value = strval($_POST[$var_name]);\n\t }\n\t }\n\t if ( $type == 'div' ) {\n\t $page .= '<label for=\"' . esc_attr($var_name) . '\">' .\n\t \t __($label, 'vmattd');\n\t \t if ( $required )\n\t \t {\n\t \t $page .= '<span class=\"description\"> (required)</span>';\n\t \t }\n\t \t $page .= '</label>';\n\t } else {\n\t $page .= '<th>' .\n\t \t __($label, 'vmattd');\n\t \t if ( $required )\n\t \t {\n\t \t $page .= '<span class=\"description\"> (required)</span>';\n\t \t }\n\t \t $page .= '</th>';\n\t \t $page .= '<td>';\n\t }\n\t \n\t $page .= '<input class=\"input vmat-form-field\" type=\"' . $args['input_type'] . '\"\n\t\t id=\"' . esc_attr($var_name) . '\"\n\t\t name=\"' . esc_attr($var_name) . '\"\n\t\t value=\"' . $var_value . '\" ';\n\t if ( $required ) {\n\t $page .= 'required';\n\t }\n\t $page .= '/>';\n\t if ( $type != 'div' ) {\n\t $page .= '</td>';\n\t }\n\t return $page;\n\t}",
"public static function parseForm($value)\n {\n $value = trim((string) $value);\n if (\n in_array(\n $value,\n [\n '0',\n (string) NormalizerInterface::NONE,\n (string) NormalizerInterface::NFC,\n (string) NormalizerInterface::NFD,\n (string) NormalizerInterface::NFD_MAC,\n (string) NormalizerInterface::NFKC,\n (string) NormalizerInterface::NFKD,\n ],\n true\n )\n ) {\n return (int) $value;\n }\n\n $form = str_replace(['-', 'NF', 'FORM_'], ['_', '', ''], strtoupper($value));\n\n switch ($form) {\n case '':\n case 'NULL':\n case 'FALSE':\n return 0;\n case 'NONE':\n case 'TRUE':\n case 'BINARY':\n case 'DEFAULT':\n case 'VALIDATE':\n return NormalizerInterface::NONE;\n case 'D':\n case 'DECOMPOSE':\n case 'COLLATION':\n return NormalizerInterface::NFD;\n case 'KD':\n return NormalizerInterface::NFKD;\n case 'C':\n case 'COMPOSE':\n case 'RECOMPOSE':\n case 'LEGACY':\n case 'HTML5':\n return NormalizerInterface::NFC;\n case 'KC':\n case 'MATCHING':\n return NormalizerInterface::NFKC;\n case 'D_MAC':\n case 'MAC':\n return NormalizerInterface::NFD_MAC;\n }\n\n throw new InvalidFormFailure(\n sprintf('Invalid unicode normalization form value: %s', $value), 1398603947\n );\n }"
] | [
"0.5099673",
"0.50939196",
"0.50746274",
"0.5064948",
"0.50491923",
"0.5039675",
"0.5026157",
"0.5017568",
"0.49589756",
"0.4958144",
"0.4956047",
"0.49444017",
"0.49223053",
"0.49122256",
"0.4903179",
"0.48824203",
"0.48593408",
"0.48537904",
"0.48517948",
"0.48337367",
"0.4821854",
"0.47980398",
"0.47826362",
"0.47814888",
"0.47594061",
"0.47392818",
"0.47232544",
"0.4716571",
"0.4704826",
"0.46953124"
] | 0.62662673 | 0 |
A list of detected languages for name together with confidence. Generated from protobuf field repeated .google.cloud.documentai.v1.Document.Page.DetectedLanguage name_detected_languages = 3; | public function getNameDetectedLanguages()
{
return $this->name_detected_languages;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function setNameDetectedLanguages($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::MESSAGE, \\Google\\Cloud\\DocumentAI\\V1\\Document\\Page\\DetectedLanguage::class);\n $this->name_detected_languages = $arr;\n\n return $this;\n }",
"public function setValueDetectedLanguages($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::MESSAGE, \\Google\\Cloud\\DocumentAI\\V1\\Document\\Page\\DetectedLanguage::class);\n $this->value_detected_languages = $arr;\n\n return $this;\n }",
"public function collectLanguages()\n {\n $langs = [];\n foreach ($this->name as $translation) {\n array_push($langs, $translation->language);\n }\n $this->languages = array_values(array_unique($langs));\n }",
"public function getValueDetectedLanguages()\n {\n return $this->value_detected_languages;\n }",
"public function languages()\n\t{\n\t\t$languages = ORM::factory('langify_language')\n\t\t\t->find_all();\n\t\t\n\t\t$return = array();\n\t\tforeach ($languages as $k => $v)\n\t\t{\n\t\t\t$return[] = array(\n\t\t\t\t'id' => $v->id,\n\t\t\t\t'name' => $v->name,\n\t\t\t);\n\t\t}\n\t\treturn $return;\n\t}",
"function languages()\n {\n // trust configuration\n $configured = $this->rc->config->get('spellcheck_languages');\n if (!empty($configured) && is_array($configured) && !$configured[0]) {\n return $configured;\n }\n else if (!empty($configured)) {\n $langs = (array)$configured;\n }\n else if ($this->backend) {\n $langs = $this->backend->languages();\n }\n\n // load index\n @include(RCUBE_LOCALIZATION_DIR . 'index.inc');\n\n // add correct labels\n $languages = array();\n foreach ($langs as $lang) {\n $langc = strtolower(substr($lang, 0, 2));\n $alias = $rcube_language_aliases[$langc];\n if (!$alias) {\n $alias = $langc.'_'.strtoupper($langc);\n }\n if ($rcube_languages[$lang]) {\n $languages[$lang] = $rcube_languages[$lang];\n }\n else if ($rcube_languages[$alias]) {\n $languages[$lang] = $rcube_languages[$alias];\n }\n else {\n $languages[$lang] = ucfirst($lang);\n }\n }\n\n // remove possible duplicates (#1489395)\n $languages = array_unique($languages);\n\n asort($languages);\n\n return $languages;\n }",
"private function gatherLanguages()\n {\n $folder = dirname(__FILE__).DIRECTORY_SEPARATOR.\"Language\";\n if (file_exists($folder)) {\n $finder = new Finder();\n $finder->directories()->in($folder)->depth(\"== 0\");\n if (count($finder) > 0) {\n foreach ($finder as $directory) {\n $languageName = $directory->getFileName();\n $this->languagesNames[] = $languageName;\n }\n }\n }\n }",
"public function getAvailableLanguages ();",
"public static function available_languages() {\n\n\t\t$languages = array(\n\t\t\t'czech' => 'APP_StopWords_Czech',\n\t\t\t'danish' => 'APP_StopWords_Danish',\n\t\t\t'dutch' => 'APP_StopWords_Dutch',\n\t\t\t'english' => 'APP_StopWords_English',\n\t\t\t'finnish' => 'APP_StopWords_Finnish',\n\t\t\t'french' => 'APP_StopWords_French',\n\t\t\t'german' => 'APP_StopWords_German',\n\t\t\t'hungarian' => 'APP_StopWords_Hungarian',\n\t\t\t'italian' => 'APP_StopWords_Italian',\n\t\t\t'norwegian' => 'APP_StopWords_Norwegian',\n\t\t\t'polish' => 'APP_StopWords_Polish',\n\t\t\t'portuguese' => 'APP_StopWords_Portuguese',\n\t\t\t'romanian' => 'APP_StopWords_Romanian',\n\t\t\t'russian' => 'APP_StopWords_Russian',\n\t\t\t'slovak' => 'APP_StopWords_Slovak',\n\t\t\t'spanish' => 'APP_StopWords_Spanish',\n\t\t\t'swedish' => 'APP_StopWords_Swedish',\n\t\t\t'turkish' => 'APP_StopWords_Turkish',\n\t\t);\n\n\t\treturn $languages;\n\t}",
"public function get_languages()\n {\n return $this->found_languages;\n }",
"public function getLanguages(): array\n {\n return $this->languages;\n }",
"public static function getListOfLanguages() {\n\t\t//--\n\t\t$all_languages = (array) self::getSafeLanguagesArr();\n\t\t//--\n\t\t$list_languages = array();\n\t\tforeach($all_languages as $key => $val) {\n\t\t\tif(is_array($val)) {\n\t\t\t\t$list_languages[(string)$key] = (string) $val['name'];\n\t\t\t} else {\n\t\t\t\t$list_languages[(string)$key] = (string) $val;\n\t\t\t} //end if\n\t\t} //end for\n\t\t//--\n\t\treturn (array) $list_languages;\n\t\t//--\n\t}",
"public function getLanguages()\n {\n return $this->languages;\n }",
"public function getLanguages()\n {\n return $this->languages;\n }",
"public function getLanguages() {\n return $this->langSource->getAllLanguages(); \n }",
"public function getSurveyLanguages()\n {\n $return = [];\n $sql = \"SELECT DISTINCT gsu_survey_languages\n FROM gems__surveys\n ORDER BY gsu_survey_languages\";\n\n $result = $this->db->fetchCol($sql);\n\n foreach ($result as $value) {\n if (strpos($value, ', ') !== false) {\n $results = explode(', ', $value);\n foreach ($results as $values) {\n $return[$values] = $values;\n }\n } else {\n $return[$value] = $value;\n }\n }\n\n return $return;\n }",
"public function getAvailableLanguages()\n {\n $languages = [];\n\n $paths = $this->fileSystem->getDirectories($this->getLanguagesPath());\n\n foreach ($paths as $path) {\n $languages[] = substr($path, strlen($this->getLanguagesPath()) + 1);\n }\n\n return $languages;\n }",
"public function getLanguages()\n\t{\n\t\treturn $this->simplify($this->findInfo('Languages', 'Languages'));\n\t}",
"function languages()\r\n\t{\r\n\t\tif (count($this->languages) == 0)\r\n\t\t{\r\n\t\t\t$this->_set_languages();\r\n\t\t}\r\n\t\r\n\t\treturn $this->languages;\r\n\t}",
"public function getLanguages()\n {\n if (null !== $this->languages) {\n return $this->languages;\n }\n $languages = AcceptHeader::fromString($this->headers->get('Accept-Language'))->all();\n $this->languages = array();\n foreach (array_keys($languages) as $lang) {\n if (strstr($lang, '-')) {\n $codes = explode('-', $lang);\n if ($codes[0] == 'i') {\n // Language not listed in ISO 639 that are not variants\n // of any listed language, which can be registered with the\n // i-prefix, such as i-cherokee\n if (count($codes) > 1) {\n $lang = $codes[1];\n }\n } else {\n for ($i = 0, $max = count($codes); $i < $max; $i++) {\n if ($i == 0) {\n $lang = strtolower($codes[0]);\n } else {\n $lang .= '_' . strtoupper($codes[$i]);\n }\n }\n }\n }\n $this->languages[] = $lang;\n }\n return $this->languages;\n }",
"public function getProjectLanguages()\n\t{\n\t\treturn json_decode($this->doRequest(['action' => 'list_languages'])->getContent());\n\t}",
"public function getLanguages()\n {\n return $this->request->send(\"translations/v1/languages\");\n }",
"public function getNativeLanguages();",
"public function getLanguages() {\n\t\t$url = self::API_URL . $this->getMethodName(self::METHOD_GET_LANGUAGES);\n\t\t\n\t\t$header = $this->getHeader();\n\t\t\n\t\t$response = $this->doRequest($url, null, $header);\n\t\t\n\t\t$xmlObj = simplexml_load_string($response);\n\t\t\n\t\t$languageCodes = array();\n\t\tforeach($xmlObj->string as $code){\n\t\t $languageCodes[] = (string) $code;\n\t\t}\n\t\t\n\t\t$url = self::API_URL . $this->getMethodName(self::METHOD_GET_LANGUAGES_NAME);\n\t\t\n\t\t$requestXml = '<ArrayOfstring xmlns=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\">';\n\t\tif(sizeof($languageCodes) > 0){\n\t\t foreach($languageCodes as $codes)\n\t\t $requestXml .= \"<string>$codes</string>\";\n\t\t} else {\n\t\t throw new Exception('$languageCodes array is empty.');\n\t\t}\n\t\t$requestXml .= '</ArrayOfstring>';\n\t\t\n\t\t$response = $this->doRequest($url . '?locale=en', $requestXml, $header, true);\n\t\t\n\t\t$xmlObj = simplexml_load_string($response);\n\t\t\n\t\t$languages = array();\n\t\t$i = 0;\n\t\tforeach($xmlObj->string as $language){\n\t\t $languages[] = new \\Webcook\\Translator\\Results\\LanguageResult($languageCodes[$i], (string) $language);\n\t\t $i++;\n\t\t}\n\t\t\n\t\treturn $languages;\n\t}",
"public static function getAvailableLanguages() {\n\t\t//--\n\t\t$all_languages = (array) self::getSafeLanguagesArr();\n\t\t//--\n\t\treturn (array) array_keys((array)$all_languages);\n\t\t//--\n\t}",
"public function getProjectLanguages()\n {\n return json_decode(\n $this->client->projects(\n 'languages',\n [\n 'project_id' => $this->config['project_id'],\n ]\n )\n );\n }",
"public function getLanguages() {\r\n return glob($this->language_folder.'*.'.$this->language_ext);\r\n }",
"public function ldv_get_available_languages(){ \r\n \r\n return array(\r\n __('Use WordPress default', 'ldv-reviews') => '',\r\n __('English (US)', 'ldv-reviews') => 'en_US', \r\n __('English (GB)', 'ldv-reviews') => 'en_GB',\r\n __('French (FR)', 'ldv-reviews') => 'fr_FR',\r\n __('French (CA)', 'ldv-reviews') => 'fr_CA',\r\n __('Spanish (ES)', 'ldv-reviews') => 'es_ES', \r\n __('Spanish (MX)', 'ldv-reviews') => 'es_MX', \r\n __('Italian', 'ldv-reviews') => 'it_IT',\r\n __('German (DE)', 'ldv-reviews') => 'de_DE',\r\n __('Russian', 'ldv-reviews') => 'ru_RU',\r\n __('Portuguese', 'ldv-reviews') => 'pt_PT', \r\n );\r\n }",
"public static function allLanguages()\n\t{\n\t\t$_countries = array(\n\t\t\t\t'Arabic'=>'Arabic',\n\t\t\t\t'Chinese - Cantonese'=>'Chinese - Cantonese',\n\t\t\t\t'Chinese - Mandarin'=>'Chinese - Mandarin',\n\t\t\t\t'English'=>'English',\n\t\t\t\t'Danish'=>'Danish',\n\t\t\t\t'Dutch'=>'Dutch',\n\t\t\t\t'Filipino'=>'Filipino',\n\t\t\t\t'Finish'=>'Finish',\n\t\t\t\t'French'=>'French',\n\t\t\t\t'German'=>'German',\n\t\t\t\t'Greek'=>'Greek',\n\t\t\t\t'Indonesian'=>'Indonesian',\n\t\t\t\t'Italian'=>'Italian',\n\t\t\t\t'Japanese'=>'Japanese',\n\t\t\t\t'Korean'=>'Korean',\n\t\t\t\t'Malay'=>'Malay',\n\t\t\t\t'Norwegian'=>'Norwegian',\n\t\t\t\t'Polish'=>'Polish',\n\t\t\t\t'Portuguese'=>'Portuguese',\n\t\t\t\t'Russian'=>'Russian',\n\t\t\t\t'Spanish'=>'Spanish',\n\t\t\t\t'Swedish'=>'Swedish',\n\t\t\t\t'Thai'=>'Thai',\n\t\t\t\t'Turkish'=>'Turkish',\n\t\t\t\t'Vietnamese'=>'Vietnamese',\n\t\t\t\t);\n\t\treturn $_countries;\n\t}",
"public static function avilablableLangs() {\n\t\treturn array_keys(self::$availableLangData);\n\t}"
] | [
"0.87073624",
"0.75357807",
"0.6600426",
"0.6413044",
"0.6260118",
"0.6139175",
"0.6133793",
"0.6102951",
"0.6085413",
"0.60844654",
"0.6073584",
"0.60438615",
"0.59747607",
"0.59747607",
"0.59011203",
"0.5900686",
"0.58993787",
"0.58855486",
"0.5833406",
"0.5799797",
"0.57957554",
"0.57918894",
"0.57871056",
"0.5771566",
"0.5711753",
"0.5699992",
"0.56857747",
"0.5681313",
"0.5634548",
"0.5629806"
] | 0.7694271 | 1 |
A list of detected languages for name together with confidence. Generated from protobuf field repeated .google.cloud.documentai.v1.Document.Page.DetectedLanguage name_detected_languages = 3; | public function setNameDetectedLanguages($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DocumentAI\V1\Document\Page\DetectedLanguage::class);
$this->name_detected_languages = $arr;
return $this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getNameDetectedLanguages()\n {\n return $this->name_detected_languages;\n }",
"public function setValueDetectedLanguages($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::MESSAGE, \\Google\\Cloud\\DocumentAI\\V1\\Document\\Page\\DetectedLanguage::class);\n $this->value_detected_languages = $arr;\n\n return $this;\n }",
"public function collectLanguages()\n {\n $langs = [];\n foreach ($this->name as $translation) {\n array_push($langs, $translation->language);\n }\n $this->languages = array_values(array_unique($langs));\n }",
"public function getValueDetectedLanguages()\n {\n return $this->value_detected_languages;\n }",
"public function languages()\n\t{\n\t\t$languages = ORM::factory('langify_language')\n\t\t\t->find_all();\n\t\t\n\t\t$return = array();\n\t\tforeach ($languages as $k => $v)\n\t\t{\n\t\t\t$return[] = array(\n\t\t\t\t'id' => $v->id,\n\t\t\t\t'name' => $v->name,\n\t\t\t);\n\t\t}\n\t\treturn $return;\n\t}",
"function languages()\n {\n // trust configuration\n $configured = $this->rc->config->get('spellcheck_languages');\n if (!empty($configured) && is_array($configured) && !$configured[0]) {\n return $configured;\n }\n else if (!empty($configured)) {\n $langs = (array)$configured;\n }\n else if ($this->backend) {\n $langs = $this->backend->languages();\n }\n\n // load index\n @include(RCUBE_LOCALIZATION_DIR . 'index.inc');\n\n // add correct labels\n $languages = array();\n foreach ($langs as $lang) {\n $langc = strtolower(substr($lang, 0, 2));\n $alias = $rcube_language_aliases[$langc];\n if (!$alias) {\n $alias = $langc.'_'.strtoupper($langc);\n }\n if ($rcube_languages[$lang]) {\n $languages[$lang] = $rcube_languages[$lang];\n }\n else if ($rcube_languages[$alias]) {\n $languages[$lang] = $rcube_languages[$alias];\n }\n else {\n $languages[$lang] = ucfirst($lang);\n }\n }\n\n // remove possible duplicates (#1489395)\n $languages = array_unique($languages);\n\n asort($languages);\n\n return $languages;\n }",
"private function gatherLanguages()\n {\n $folder = dirname(__FILE__).DIRECTORY_SEPARATOR.\"Language\";\n if (file_exists($folder)) {\n $finder = new Finder();\n $finder->directories()->in($folder)->depth(\"== 0\");\n if (count($finder) > 0) {\n foreach ($finder as $directory) {\n $languageName = $directory->getFileName();\n $this->languagesNames[] = $languageName;\n }\n }\n }\n }",
"public function getAvailableLanguages ();",
"public static function available_languages() {\n\n\t\t$languages = array(\n\t\t\t'czech' => 'APP_StopWords_Czech',\n\t\t\t'danish' => 'APP_StopWords_Danish',\n\t\t\t'dutch' => 'APP_StopWords_Dutch',\n\t\t\t'english' => 'APP_StopWords_English',\n\t\t\t'finnish' => 'APP_StopWords_Finnish',\n\t\t\t'french' => 'APP_StopWords_French',\n\t\t\t'german' => 'APP_StopWords_German',\n\t\t\t'hungarian' => 'APP_StopWords_Hungarian',\n\t\t\t'italian' => 'APP_StopWords_Italian',\n\t\t\t'norwegian' => 'APP_StopWords_Norwegian',\n\t\t\t'polish' => 'APP_StopWords_Polish',\n\t\t\t'portuguese' => 'APP_StopWords_Portuguese',\n\t\t\t'romanian' => 'APP_StopWords_Romanian',\n\t\t\t'russian' => 'APP_StopWords_Russian',\n\t\t\t'slovak' => 'APP_StopWords_Slovak',\n\t\t\t'spanish' => 'APP_StopWords_Spanish',\n\t\t\t'swedish' => 'APP_StopWords_Swedish',\n\t\t\t'turkish' => 'APP_StopWords_Turkish',\n\t\t);\n\n\t\treturn $languages;\n\t}",
"public function get_languages()\n {\n return $this->found_languages;\n }",
"public function getLanguages(): array\n {\n return $this->languages;\n }",
"public static function getListOfLanguages() {\n\t\t//--\n\t\t$all_languages = (array) self::getSafeLanguagesArr();\n\t\t//--\n\t\t$list_languages = array();\n\t\tforeach($all_languages as $key => $val) {\n\t\t\tif(is_array($val)) {\n\t\t\t\t$list_languages[(string)$key] = (string) $val['name'];\n\t\t\t} else {\n\t\t\t\t$list_languages[(string)$key] = (string) $val;\n\t\t\t} //end if\n\t\t} //end for\n\t\t//--\n\t\treturn (array) $list_languages;\n\t\t//--\n\t}",
"public function getLanguages()\n {\n return $this->languages;\n }",
"public function getLanguages()\n {\n return $this->languages;\n }",
"public function getLanguages() {\n return $this->langSource->getAllLanguages(); \n }",
"public function getSurveyLanguages()\n {\n $return = [];\n $sql = \"SELECT DISTINCT gsu_survey_languages\n FROM gems__surveys\n ORDER BY gsu_survey_languages\";\n\n $result = $this->db->fetchCol($sql);\n\n foreach ($result as $value) {\n if (strpos($value, ', ') !== false) {\n $results = explode(', ', $value);\n foreach ($results as $values) {\n $return[$values] = $values;\n }\n } else {\n $return[$value] = $value;\n }\n }\n\n return $return;\n }",
"public function getAvailableLanguages()\n {\n $languages = [];\n\n $paths = $this->fileSystem->getDirectories($this->getLanguagesPath());\n\n foreach ($paths as $path) {\n $languages[] = substr($path, strlen($this->getLanguagesPath()) + 1);\n }\n\n return $languages;\n }",
"public function getLanguages()\n\t{\n\t\treturn $this->simplify($this->findInfo('Languages', 'Languages'));\n\t}",
"function languages()\r\n\t{\r\n\t\tif (count($this->languages) == 0)\r\n\t\t{\r\n\t\t\t$this->_set_languages();\r\n\t\t}\r\n\t\r\n\t\treturn $this->languages;\r\n\t}",
"public function getLanguages()\n {\n if (null !== $this->languages) {\n return $this->languages;\n }\n $languages = AcceptHeader::fromString($this->headers->get('Accept-Language'))->all();\n $this->languages = array();\n foreach (array_keys($languages) as $lang) {\n if (strstr($lang, '-')) {\n $codes = explode('-', $lang);\n if ($codes[0] == 'i') {\n // Language not listed in ISO 639 that are not variants\n // of any listed language, which can be registered with the\n // i-prefix, such as i-cherokee\n if (count($codes) > 1) {\n $lang = $codes[1];\n }\n } else {\n for ($i = 0, $max = count($codes); $i < $max; $i++) {\n if ($i == 0) {\n $lang = strtolower($codes[0]);\n } else {\n $lang .= '_' . strtoupper($codes[$i]);\n }\n }\n }\n }\n $this->languages[] = $lang;\n }\n return $this->languages;\n }",
"public function getProjectLanguages()\n\t{\n\t\treturn json_decode($this->doRequest(['action' => 'list_languages'])->getContent());\n\t}",
"public function getLanguages()\n {\n return $this->request->send(\"translations/v1/languages\");\n }",
"public function getNativeLanguages();",
"public function getLanguages() {\n\t\t$url = self::API_URL . $this->getMethodName(self::METHOD_GET_LANGUAGES);\n\t\t\n\t\t$header = $this->getHeader();\n\t\t\n\t\t$response = $this->doRequest($url, null, $header);\n\t\t\n\t\t$xmlObj = simplexml_load_string($response);\n\t\t\n\t\t$languageCodes = array();\n\t\tforeach($xmlObj->string as $code){\n\t\t $languageCodes[] = (string) $code;\n\t\t}\n\t\t\n\t\t$url = self::API_URL . $this->getMethodName(self::METHOD_GET_LANGUAGES_NAME);\n\t\t\n\t\t$requestXml = '<ArrayOfstring xmlns=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\">';\n\t\tif(sizeof($languageCodes) > 0){\n\t\t foreach($languageCodes as $codes)\n\t\t $requestXml .= \"<string>$codes</string>\";\n\t\t} else {\n\t\t throw new Exception('$languageCodes array is empty.');\n\t\t}\n\t\t$requestXml .= '</ArrayOfstring>';\n\t\t\n\t\t$response = $this->doRequest($url . '?locale=en', $requestXml, $header, true);\n\t\t\n\t\t$xmlObj = simplexml_load_string($response);\n\t\t\n\t\t$languages = array();\n\t\t$i = 0;\n\t\tforeach($xmlObj->string as $language){\n\t\t $languages[] = new \\Webcook\\Translator\\Results\\LanguageResult($languageCodes[$i], (string) $language);\n\t\t $i++;\n\t\t}\n\t\t\n\t\treturn $languages;\n\t}",
"public static function getAvailableLanguages() {\n\t\t//--\n\t\t$all_languages = (array) self::getSafeLanguagesArr();\n\t\t//--\n\t\treturn (array) array_keys((array)$all_languages);\n\t\t//--\n\t}",
"public function getProjectLanguages()\n {\n return json_decode(\n $this->client->projects(\n 'languages',\n [\n 'project_id' => $this->config['project_id'],\n ]\n )\n );\n }",
"public function getLanguages() {\r\n return glob($this->language_folder.'*.'.$this->language_ext);\r\n }",
"public function ldv_get_available_languages(){ \r\n \r\n return array(\r\n __('Use WordPress default', 'ldv-reviews') => '',\r\n __('English (US)', 'ldv-reviews') => 'en_US', \r\n __('English (GB)', 'ldv-reviews') => 'en_GB',\r\n __('French (FR)', 'ldv-reviews') => 'fr_FR',\r\n __('French (CA)', 'ldv-reviews') => 'fr_CA',\r\n __('Spanish (ES)', 'ldv-reviews') => 'es_ES', \r\n __('Spanish (MX)', 'ldv-reviews') => 'es_MX', \r\n __('Italian', 'ldv-reviews') => 'it_IT',\r\n __('German (DE)', 'ldv-reviews') => 'de_DE',\r\n __('Russian', 'ldv-reviews') => 'ru_RU',\r\n __('Portuguese', 'ldv-reviews') => 'pt_PT', \r\n );\r\n }",
"public static function allLanguages()\n\t{\n\t\t$_countries = array(\n\t\t\t\t'Arabic'=>'Arabic',\n\t\t\t\t'Chinese - Cantonese'=>'Chinese - Cantonese',\n\t\t\t\t'Chinese - Mandarin'=>'Chinese - Mandarin',\n\t\t\t\t'English'=>'English',\n\t\t\t\t'Danish'=>'Danish',\n\t\t\t\t'Dutch'=>'Dutch',\n\t\t\t\t'Filipino'=>'Filipino',\n\t\t\t\t'Finish'=>'Finish',\n\t\t\t\t'French'=>'French',\n\t\t\t\t'German'=>'German',\n\t\t\t\t'Greek'=>'Greek',\n\t\t\t\t'Indonesian'=>'Indonesian',\n\t\t\t\t'Italian'=>'Italian',\n\t\t\t\t'Japanese'=>'Japanese',\n\t\t\t\t'Korean'=>'Korean',\n\t\t\t\t'Malay'=>'Malay',\n\t\t\t\t'Norwegian'=>'Norwegian',\n\t\t\t\t'Polish'=>'Polish',\n\t\t\t\t'Portuguese'=>'Portuguese',\n\t\t\t\t'Russian'=>'Russian',\n\t\t\t\t'Spanish'=>'Spanish',\n\t\t\t\t'Swedish'=>'Swedish',\n\t\t\t\t'Thai'=>'Thai',\n\t\t\t\t'Turkish'=>'Turkish',\n\t\t\t\t'Vietnamese'=>'Vietnamese',\n\t\t\t\t);\n\t\treturn $_countries;\n\t}",
"public static function avilablableLangs() {\n\t\treturn array_keys(self::$availableLangData);\n\t}"
] | [
"0.76933026",
"0.75351405",
"0.65995985",
"0.64118266",
"0.62599933",
"0.61389965",
"0.61335003",
"0.6103563",
"0.6085043",
"0.6084607",
"0.6073637",
"0.60438263",
"0.59744936",
"0.59744936",
"0.59011847",
"0.5899995",
"0.5899362",
"0.58853734",
"0.5833668",
"0.5800181",
"0.5796204",
"0.5791728",
"0.57882726",
"0.5772303",
"0.5711781",
"0.570092",
"0.5685722",
"0.56812644",
"0.56340635",
"0.56290525"
] | 0.8707364 | 0 |
A list of detected languages for value together with confidence. Generated from protobuf field repeated .google.cloud.documentai.v1.Document.Page.DetectedLanguage value_detected_languages = 4; | public function getValueDetectedLanguages()
{
return $this->value_detected_languages;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function setValueDetectedLanguages($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::MESSAGE, \\Google\\Cloud\\DocumentAI\\V1\\Document\\Page\\DetectedLanguage::class);\n $this->value_detected_languages = $arr;\n\n return $this;\n }",
"public function setNameDetectedLanguages($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::MESSAGE, \\Google\\Cloud\\DocumentAI\\V1\\Document\\Page\\DetectedLanguage::class);\n $this->name_detected_languages = $arr;\n\n return $this;\n }",
"public function getNameDetectedLanguages()\n {\n return $this->name_detected_languages;\n }",
"public function get_languages()\n {\n return $this->found_languages;\n }",
"public function getLanguages(): array\n {\n return $this->languages;\n }",
"public function getLanguages()\n {\n return $this->languages;\n }",
"public function getLanguages()\n {\n return $this->languages;\n }",
"public function getSurveyLanguages()\n {\n $return = [];\n $sql = \"SELECT DISTINCT gsu_survey_languages\n FROM gems__surveys\n ORDER BY gsu_survey_languages\";\n\n $result = $this->db->fetchCol($sql);\n\n foreach ($result as $value) {\n if (strpos($value, ', ') !== false) {\n $results = explode(', ', $value);\n foreach ($results as $values) {\n $return[$values] = $values;\n }\n } else {\n $return[$value] = $value;\n }\n }\n\n return $return;\n }",
"function languages()\r\n\t{\r\n\t\tif (count($this->languages) == 0)\r\n\t\t{\r\n\t\t\t$this->_set_languages();\r\n\t\t}\r\n\t\r\n\t\treturn $this->languages;\r\n\t}",
"function languages()\n {\n // trust configuration\n $configured = $this->rc->config->get('spellcheck_languages');\n if (!empty($configured) && is_array($configured) && !$configured[0]) {\n return $configured;\n }\n else if (!empty($configured)) {\n $langs = (array)$configured;\n }\n else if ($this->backend) {\n $langs = $this->backend->languages();\n }\n\n // load index\n @include(RCUBE_LOCALIZATION_DIR . 'index.inc');\n\n // add correct labels\n $languages = array();\n foreach ($langs as $lang) {\n $langc = strtolower(substr($lang, 0, 2));\n $alias = $rcube_language_aliases[$langc];\n if (!$alias) {\n $alias = $langc.'_'.strtoupper($langc);\n }\n if ($rcube_languages[$lang]) {\n $languages[$lang] = $rcube_languages[$lang];\n }\n else if ($rcube_languages[$alias]) {\n $languages[$lang] = $rcube_languages[$alias];\n }\n else {\n $languages[$lang] = ucfirst($lang);\n }\n }\n\n // remove possible duplicates (#1489395)\n $languages = array_unique($languages);\n\n asort($languages);\n\n return $languages;\n }",
"public static function available_languages() {\n\n\t\t$languages = array(\n\t\t\t'czech' => 'APP_StopWords_Czech',\n\t\t\t'danish' => 'APP_StopWords_Danish',\n\t\t\t'dutch' => 'APP_StopWords_Dutch',\n\t\t\t'english' => 'APP_StopWords_English',\n\t\t\t'finnish' => 'APP_StopWords_Finnish',\n\t\t\t'french' => 'APP_StopWords_French',\n\t\t\t'german' => 'APP_StopWords_German',\n\t\t\t'hungarian' => 'APP_StopWords_Hungarian',\n\t\t\t'italian' => 'APP_StopWords_Italian',\n\t\t\t'norwegian' => 'APP_StopWords_Norwegian',\n\t\t\t'polish' => 'APP_StopWords_Polish',\n\t\t\t'portuguese' => 'APP_StopWords_Portuguese',\n\t\t\t'romanian' => 'APP_StopWords_Romanian',\n\t\t\t'russian' => 'APP_StopWords_Russian',\n\t\t\t'slovak' => 'APP_StopWords_Slovak',\n\t\t\t'spanish' => 'APP_StopWords_Spanish',\n\t\t\t'swedish' => 'APP_StopWords_Swedish',\n\t\t\t'turkish' => 'APP_StopWords_Turkish',\n\t\t);\n\n\t\treturn $languages;\n\t}",
"public function getLanguages()\n\t{\n\t\treturn $this->simplify($this->findInfo('Languages', 'Languages'));\n\t}",
"public function getAvailableLanguages ();",
"public function getAcceptLanguages()\n\t{\n\t\tif ($this->_languages === null) {\n\t\t\tif (! isset($_SERVER['HTTP_ACCEPT_LANGUAGE']))\n\t\t\t\t$this->_languages[0] = 'en';\n\t\t\telse {\n\t\t\t\t$this->_languages = array();\n\t\t\t\tforeach (explode(',', $_SERVER['HTTP_ACCEPT_LANGUAGE']) as $language) {\n\t\t\t\t\t$array = split(';q=', trim($language));\n\t\t\t\t\t$this->_languages[trim($array[0])] = isset($array[1]) ? (float) $array[1] : 1.0;\n\t\t\t\t}\n\n\t\t\t\tarsort($this->_languages);\n\t\t\t\t$this->_languages = array_keys($this->_languages);\n\n\t\t\t\tif (empty($this->_languages))\n\t\t\t\t\t$this->_languages[0] = 'en';\n\t\t\t}\n\t\t}\n\n\t\treturn $this->_languages;\n\t}",
"public function getResponseLanguagesUsed()\n {\n if (null !== $this->data_returned and isset($this->data_returned['schema']['languages'])) {\n return $this->data_returned['schema']['languages'];\n }\n\n return null;\n }",
"public function getProjectLanguages()\n\t{\n\t\treturn json_decode($this->doRequest(['action' => 'list_languages'])->getContent());\n\t}",
"public function languages()\n\t{\n\t\t$languages = ORM::factory('langify_language')\n\t\t\t->find_all();\n\t\t\n\t\t$return = array();\n\t\tforeach ($languages as $k => $v)\n\t\t{\n\t\t\t$return[] = array(\n\t\t\t\t'id' => $v->id,\n\t\t\t\t'name' => $v->name,\n\t\t\t);\n\t\t}\n\t\treturn $return;\n\t}",
"public function getLanguages() {\n return $this->langSource->getAllLanguages(); \n }",
"public function getLanguages()\n {\n return $this->request->send(\"translations/v1/languages\");\n }",
"public function getLanguages()\n {\n if (null !== $this->languages) {\n return $this->languages;\n }\n $languages = AcceptHeader::fromString($this->headers->get('Accept-Language'))->all();\n $this->languages = array();\n foreach (array_keys($languages) as $lang) {\n if (strstr($lang, '-')) {\n $codes = explode('-', $lang);\n if ($codes[0] == 'i') {\n // Language not listed in ISO 639 that are not variants\n // of any listed language, which can be registered with the\n // i-prefix, such as i-cherokee\n if (count($codes) > 1) {\n $lang = $codes[1];\n }\n } else {\n for ($i = 0, $max = count($codes); $i < $max; $i++) {\n if ($i == 0) {\n $lang = strtolower($codes[0]);\n } else {\n $lang .= '_' . strtoupper($codes[$i]);\n }\n }\n }\n }\n $this->languages[] = $lang;\n }\n return $this->languages;\n }",
"public function getLanguages() : ?array\n {\n return $this->languages;\n }",
"public function collectLanguages()\n {\n $langs = [];\n foreach ($this->name as $translation) {\n array_push($langs, $translation->language);\n }\n $this->languages = array_values(array_unique($langs));\n }",
"public function getEnabledLanguages();",
"public function getLanguages() {\n\t\t$url = self::API_URL . $this->getMethodName(self::METHOD_GET_LANGUAGES);\n\t\t\n\t\t$header = $this->getHeader();\n\t\t\n\t\t$response = $this->doRequest($url, null, $header);\n\t\t\n\t\t$xmlObj = simplexml_load_string($response);\n\t\t\n\t\t$languageCodes = array();\n\t\tforeach($xmlObj->string as $code){\n\t\t $languageCodes[] = (string) $code;\n\t\t}\n\t\t\n\t\t$url = self::API_URL . $this->getMethodName(self::METHOD_GET_LANGUAGES_NAME);\n\t\t\n\t\t$requestXml = '<ArrayOfstring xmlns=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\">';\n\t\tif(sizeof($languageCodes) > 0){\n\t\t foreach($languageCodes as $codes)\n\t\t $requestXml .= \"<string>$codes</string>\";\n\t\t} else {\n\t\t throw new Exception('$languageCodes array is empty.');\n\t\t}\n\t\t$requestXml .= '</ArrayOfstring>';\n\t\t\n\t\t$response = $this->doRequest($url . '?locale=en', $requestXml, $header, true);\n\t\t\n\t\t$xmlObj = simplexml_load_string($response);\n\t\t\n\t\t$languages = array();\n\t\t$i = 0;\n\t\tforeach($xmlObj->string as $language){\n\t\t $languages[] = new \\Webcook\\Translator\\Results\\LanguageResult($languageCodes[$i], (string) $language);\n\t\t $i++;\n\t\t}\n\t\t\n\t\treturn $languages;\n\t}",
"public static function languages()\n\t{\n\t\tif (count(self::$languages) == 0)\n\t\t{\n\t\t\tself::_set_languages();\n\t\t}\n\n\t\treturn self::$languages;\n\t}",
"public function getLanguages() {\n\t\t$this->load->model('localisation/language');\n\t\t\n\t\t$languages = $this->model_localisation_language->getLanguages();\n\t\t\n\t\tforeach ($languages as $key => $language) {\n if (VERSION >= '2.2.0.0') {\n $languages[$key]['flag'] = 'language/' . $language['code'] . '/' . $language['code'] . '.png';\n } else {\n $languages[$key]['flag'] = 'view/image/flags/' . $language['image'];\n }\n }\n\t\t\t\t\n\t\treturn $languages;\n\t}",
"private function getLanguages()\n {\n return Language::find()->select(['id', 'code'])->orderBy(['default' => SORT_DESC, 'id' => SORT_DESC])->asArray()->all();\n }",
"public function getAvailableLanguages()\n {\n $languages = [];\n\n $paths = $this->fileSystem->getDirectories($this->getLanguagesPath());\n\n foreach ($paths as $path) {\n $languages[] = substr($path, strlen($this->getLanguagesPath()) + 1);\n }\n\n return $languages;\n }",
"public function getProjectLanguages()\n {\n return json_decode(\n $this->client->projects(\n 'languages',\n [\n 'project_id' => $this->config['project_id'],\n ]\n )\n );\n }",
"public static function getAvailableLanguages() {\n\t\t//--\n\t\t$all_languages = (array) self::getSafeLanguagesArr();\n\t\t//--\n\t\treturn (array) array_keys((array)$all_languages);\n\t\t//--\n\t}"
] | [
"0.8729115",
"0.73095",
"0.67182696",
"0.6246554",
"0.6191615",
"0.61500376",
"0.61500376",
"0.60988754",
"0.59870136",
"0.5981247",
"0.5939569",
"0.5936501",
"0.5931341",
"0.5910636",
"0.59089506",
"0.58678746",
"0.586293",
"0.58614826",
"0.57984376",
"0.5792636",
"0.5775444",
"0.576202",
"0.57592285",
"0.5755864",
"0.57393706",
"0.5721631",
"0.57190365",
"0.57187986",
"0.57158506",
"0.5698956"
] | 0.77228063 | 1 |
A list of detected languages for value together with confidence. Generated from protobuf field repeated .google.cloud.documentai.v1.Document.Page.DetectedLanguage value_detected_languages = 4; | public function setValueDetectedLanguages($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\DocumentAI\V1\Document\Page\DetectedLanguage::class);
$this->value_detected_languages = $arr;
return $this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getValueDetectedLanguages()\n {\n return $this->value_detected_languages;\n }",
"public function setNameDetectedLanguages($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::MESSAGE, \\Google\\Cloud\\DocumentAI\\V1\\Document\\Page\\DetectedLanguage::class);\n $this->name_detected_languages = $arr;\n\n return $this;\n }",
"public function getNameDetectedLanguages()\n {\n return $this->name_detected_languages;\n }",
"public function get_languages()\n {\n return $this->found_languages;\n }",
"public function getLanguages(): array\n {\n return $this->languages;\n }",
"public function getLanguages()\n {\n return $this->languages;\n }",
"public function getLanguages()\n {\n return $this->languages;\n }",
"public function getSurveyLanguages()\n {\n $return = [];\n $sql = \"SELECT DISTINCT gsu_survey_languages\n FROM gems__surveys\n ORDER BY gsu_survey_languages\";\n\n $result = $this->db->fetchCol($sql);\n\n foreach ($result as $value) {\n if (strpos($value, ', ') !== false) {\n $results = explode(', ', $value);\n foreach ($results as $values) {\n $return[$values] = $values;\n }\n } else {\n $return[$value] = $value;\n }\n }\n\n return $return;\n }",
"function languages()\r\n\t{\r\n\t\tif (count($this->languages) == 0)\r\n\t\t{\r\n\t\t\t$this->_set_languages();\r\n\t\t}\r\n\t\r\n\t\treturn $this->languages;\r\n\t}",
"function languages()\n {\n // trust configuration\n $configured = $this->rc->config->get('spellcheck_languages');\n if (!empty($configured) && is_array($configured) && !$configured[0]) {\n return $configured;\n }\n else if (!empty($configured)) {\n $langs = (array)$configured;\n }\n else if ($this->backend) {\n $langs = $this->backend->languages();\n }\n\n // load index\n @include(RCUBE_LOCALIZATION_DIR . 'index.inc');\n\n // add correct labels\n $languages = array();\n foreach ($langs as $lang) {\n $langc = strtolower(substr($lang, 0, 2));\n $alias = $rcube_language_aliases[$langc];\n if (!$alias) {\n $alias = $langc.'_'.strtoupper($langc);\n }\n if ($rcube_languages[$lang]) {\n $languages[$lang] = $rcube_languages[$lang];\n }\n else if ($rcube_languages[$alias]) {\n $languages[$lang] = $rcube_languages[$alias];\n }\n else {\n $languages[$lang] = ucfirst($lang);\n }\n }\n\n // remove possible duplicates (#1489395)\n $languages = array_unique($languages);\n\n asort($languages);\n\n return $languages;\n }",
"public static function available_languages() {\n\n\t\t$languages = array(\n\t\t\t'czech' => 'APP_StopWords_Czech',\n\t\t\t'danish' => 'APP_StopWords_Danish',\n\t\t\t'dutch' => 'APP_StopWords_Dutch',\n\t\t\t'english' => 'APP_StopWords_English',\n\t\t\t'finnish' => 'APP_StopWords_Finnish',\n\t\t\t'french' => 'APP_StopWords_French',\n\t\t\t'german' => 'APP_StopWords_German',\n\t\t\t'hungarian' => 'APP_StopWords_Hungarian',\n\t\t\t'italian' => 'APP_StopWords_Italian',\n\t\t\t'norwegian' => 'APP_StopWords_Norwegian',\n\t\t\t'polish' => 'APP_StopWords_Polish',\n\t\t\t'portuguese' => 'APP_StopWords_Portuguese',\n\t\t\t'romanian' => 'APP_StopWords_Romanian',\n\t\t\t'russian' => 'APP_StopWords_Russian',\n\t\t\t'slovak' => 'APP_StopWords_Slovak',\n\t\t\t'spanish' => 'APP_StopWords_Spanish',\n\t\t\t'swedish' => 'APP_StopWords_Swedish',\n\t\t\t'turkish' => 'APP_StopWords_Turkish',\n\t\t);\n\n\t\treturn $languages;\n\t}",
"public function getLanguages()\n\t{\n\t\treturn $this->simplify($this->findInfo('Languages', 'Languages'));\n\t}",
"public function getAvailableLanguages ();",
"public function getAcceptLanguages()\n\t{\n\t\tif ($this->_languages === null) {\n\t\t\tif (! isset($_SERVER['HTTP_ACCEPT_LANGUAGE']))\n\t\t\t\t$this->_languages[0] = 'en';\n\t\t\telse {\n\t\t\t\t$this->_languages = array();\n\t\t\t\tforeach (explode(',', $_SERVER['HTTP_ACCEPT_LANGUAGE']) as $language) {\n\t\t\t\t\t$array = split(';q=', trim($language));\n\t\t\t\t\t$this->_languages[trim($array[0])] = isset($array[1]) ? (float) $array[1] : 1.0;\n\t\t\t\t}\n\n\t\t\t\tarsort($this->_languages);\n\t\t\t\t$this->_languages = array_keys($this->_languages);\n\n\t\t\t\tif (empty($this->_languages))\n\t\t\t\t\t$this->_languages[0] = 'en';\n\t\t\t}\n\t\t}\n\n\t\treturn $this->_languages;\n\t}",
"public function getResponseLanguagesUsed()\n {\n if (null !== $this->data_returned and isset($this->data_returned['schema']['languages'])) {\n return $this->data_returned['schema']['languages'];\n }\n\n return null;\n }",
"public function getProjectLanguages()\n\t{\n\t\treturn json_decode($this->doRequest(['action' => 'list_languages'])->getContent());\n\t}",
"public function languages()\n\t{\n\t\t$languages = ORM::factory('langify_language')\n\t\t\t->find_all();\n\t\t\n\t\t$return = array();\n\t\tforeach ($languages as $k => $v)\n\t\t{\n\t\t\t$return[] = array(\n\t\t\t\t'id' => $v->id,\n\t\t\t\t'name' => $v->name,\n\t\t\t);\n\t\t}\n\t\treturn $return;\n\t}",
"public function getLanguages() {\n return $this->langSource->getAllLanguages(); \n }",
"public function getLanguages()\n {\n return $this->request->send(\"translations/v1/languages\");\n }",
"public function getLanguages()\n {\n if (null !== $this->languages) {\n return $this->languages;\n }\n $languages = AcceptHeader::fromString($this->headers->get('Accept-Language'))->all();\n $this->languages = array();\n foreach (array_keys($languages) as $lang) {\n if (strstr($lang, '-')) {\n $codes = explode('-', $lang);\n if ($codes[0] == 'i') {\n // Language not listed in ISO 639 that are not variants\n // of any listed language, which can be registered with the\n // i-prefix, such as i-cherokee\n if (count($codes) > 1) {\n $lang = $codes[1];\n }\n } else {\n for ($i = 0, $max = count($codes); $i < $max; $i++) {\n if ($i == 0) {\n $lang = strtolower($codes[0]);\n } else {\n $lang .= '_' . strtoupper($codes[$i]);\n }\n }\n }\n }\n $this->languages[] = $lang;\n }\n return $this->languages;\n }",
"public function getLanguages() : ?array\n {\n return $this->languages;\n }",
"public function collectLanguages()\n {\n $langs = [];\n foreach ($this->name as $translation) {\n array_push($langs, $translation->language);\n }\n $this->languages = array_values(array_unique($langs));\n }",
"public function getEnabledLanguages();",
"public function getLanguages() {\n\t\t$url = self::API_URL . $this->getMethodName(self::METHOD_GET_LANGUAGES);\n\t\t\n\t\t$header = $this->getHeader();\n\t\t\n\t\t$response = $this->doRequest($url, null, $header);\n\t\t\n\t\t$xmlObj = simplexml_load_string($response);\n\t\t\n\t\t$languageCodes = array();\n\t\tforeach($xmlObj->string as $code){\n\t\t $languageCodes[] = (string) $code;\n\t\t}\n\t\t\n\t\t$url = self::API_URL . $this->getMethodName(self::METHOD_GET_LANGUAGES_NAME);\n\t\t\n\t\t$requestXml = '<ArrayOfstring xmlns=\"http://schemas.microsoft.com/2003/10/Serialization/Arrays\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\">';\n\t\tif(sizeof($languageCodes) > 0){\n\t\t foreach($languageCodes as $codes)\n\t\t $requestXml .= \"<string>$codes</string>\";\n\t\t} else {\n\t\t throw new Exception('$languageCodes array is empty.');\n\t\t}\n\t\t$requestXml .= '</ArrayOfstring>';\n\t\t\n\t\t$response = $this->doRequest($url . '?locale=en', $requestXml, $header, true);\n\t\t\n\t\t$xmlObj = simplexml_load_string($response);\n\t\t\n\t\t$languages = array();\n\t\t$i = 0;\n\t\tforeach($xmlObj->string as $language){\n\t\t $languages[] = new \\Webcook\\Translator\\Results\\LanguageResult($languageCodes[$i], (string) $language);\n\t\t $i++;\n\t\t}\n\t\t\n\t\treturn $languages;\n\t}",
"public static function languages()\n\t{\n\t\tif (count(self::$languages) == 0)\n\t\t{\n\t\t\tself::_set_languages();\n\t\t}\n\n\t\treturn self::$languages;\n\t}",
"public function getLanguages() {\n\t\t$this->load->model('localisation/language');\n\t\t\n\t\t$languages = $this->model_localisation_language->getLanguages();\n\t\t\n\t\tforeach ($languages as $key => $language) {\n if (VERSION >= '2.2.0.0') {\n $languages[$key]['flag'] = 'language/' . $language['code'] . '/' . $language['code'] . '.png';\n } else {\n $languages[$key]['flag'] = 'view/image/flags/' . $language['image'];\n }\n }\n\t\t\t\t\n\t\treturn $languages;\n\t}",
"private function getLanguages()\n {\n return Language::find()->select(['id', 'code'])->orderBy(['default' => SORT_DESC, 'id' => SORT_DESC])->asArray()->all();\n }",
"public function getAvailableLanguages()\n {\n $languages = [];\n\n $paths = $this->fileSystem->getDirectories($this->getLanguagesPath());\n\n foreach ($paths as $path) {\n $languages[] = substr($path, strlen($this->getLanguagesPath()) + 1);\n }\n\n return $languages;\n }",
"public function getProjectLanguages()\n {\n return json_decode(\n $this->client->projects(\n 'languages',\n [\n 'project_id' => $this->config['project_id'],\n ]\n )\n );\n }",
"public static function getAvailableLanguages() {\n\t\t//--\n\t\t$all_languages = (array) self::getSafeLanguagesArr();\n\t\t//--\n\t\treturn (array) array_keys((array)$all_languages);\n\t\t//--\n\t}"
] | [
"0.7722988",
"0.73093706",
"0.67177135",
"0.62461585",
"0.619137",
"0.6149783",
"0.6149783",
"0.6098025",
"0.59866273",
"0.598097",
"0.59395546",
"0.593649",
"0.5932",
"0.59107405",
"0.5908945",
"0.58674216",
"0.58629054",
"0.5861567",
"0.57981163",
"0.5792447",
"0.5775074",
"0.57619846",
"0.57596534",
"0.57573044",
"0.57389355",
"0.5722686",
"0.57194066",
"0.5718785",
"0.5715749",
"0.5698849"
] | 0.87290925 | 0 |
If the value is nontextual, this field represents the type. Current valid values are: blank (this indicates the `field_value` is normal text) `unfilled_checkbox` `filled_checkbox` Generated from protobuf field string value_type = 5; | public function setValueType($var)
{
GPBUtil::checkString($var, True);
$this->value_type = $var;
return $this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static function types($value = null) {\n\t\t$options = array(\n\t\t\tself::FIELD_TYPE_TOGGLE => __('Toggle'),\n\t\t\tself::FIELD_TYPE_TAGS => __('Tags'),\n\t\t\tself::FIELD_TYPE_SELECT => __('Select'),\n\t\t\tself::FIELD_TYPE_MULTIPLE => __('Multi-select'),\n\t\t\tself::FIELD_TYPE_DATE => __('Date'),\n\t\t\tself::FIELD_TYPE_TEXT => __('Text'),\n\t\t\tself::FIELD_TYPE_TEXTAREA => __('Textarea'),\n\t\t\tself::FIELD_TYPE_NUMBER => __('Number'),\n\t\t\tself::FIELD_TYPE_EDITOR => __('Editor'),\n\t\t\tself::FIELD_TYPE_FILE => __('File')\n\t\t);\n\t\treturn AppModel::enum($value, $options);\n\t}",
"public function setTypeAttribute($value)\n {\n // be set to 'text' or 'code'\n if ( ($value !== 'text')\n\t &&\n\t ($value !== 'code') )\n {\n\t$this->_reportAttributeError('type',\"Invalid value: $value\");\n\treturn null;\n }\n\n $this->setAttribute('type',$value);\n return $value;\n }",
"public function setTypeAttribute($value)\n {\n // be set to 'text' or 'code'\n if ( ($value !== 'text')\n\t &&\n\t ($value !== 'code') )\n {\n\t$this->_reportAttributeError('type',\"Invalid value: $value\");\n\treturn null;\n }\n\n $this->setAttribute('type',$value);\n return $value;\n }",
"public function setType($value) \n {\n $this->_fields['Type']['FieldValue'] = $value;\n return $this;\n }",
"public function getTypeFromValue($value): string {\n if (\\is_array($value)) {\n if (empty($value) || \\array_keys($value) === \\range(0, \\count($value) - 1)) {\n return self::TYPE_ARRAY;\n }\n return self::TYPE_OBJECT;\n }\n if (\\is_object($value)) {\n return self::TYPE_OBJECT;\n }\n if (NULL === $value) {\n return self::TYPE_NULL;\n }\n if (\\is_bool($value)) {\n return self::TYPE_BOOLEAN;\n }\n if (\\is_int($value) || \\is_float($value)) {\n return self::TYPE_NUMBER;\n }\n return self::TYPE_STRING;\n }",
"private function setTypeByValue(){\n\t\t$value = $this->value;\n\t\t\n\t\tif(is_null($value)){\n\t\t\t$type = 'static';\n\t\t}else if(is_numeric($value)){\n\t\t\t$type = 'number';\n\t\t}else{\n\t\t\t$type = gettype($value);\n\t\t}\n\t\t\n\t\t$this->setType($type);\n\t}",
"public function getValueType()\n {\n return $this->value_type;\n }",
"public function getType_value()\n {\n return $this->type_value;\n }",
"function get_value_type()\n {\n return $this->get_default_property(self :: PROPERTY_VALUE_TYPE);\n }",
"public function value($type, $field, $value = '', $default = '') {\n\t\t$input = isset($this->_data[$field]) ? $this->_data[$field] : null;\n\t\t$output = '';\n\n\t\tswitch ($type) {\n\t\t\tdefault:\n\t\t\tcase 'text':\n\t\t\tcase 'textarea':\n\t\t\tcase 'password':\n\t\t\tcase 'hidden':\n\t\t\tcase 'file':\n\t\t\t\tif ($input !== null) {\n\t\t\t\t\t$output = self::cleanse($input);\n\t\t\t\t} else {\n\t\t\t\t\t$output = ($default !== null) ? $default : '';\n\t\t\t\t}\n\t\t\tbreak;\n\t\t\tcase 'radio':\n\t\t\t\tif ($input !== null) {\n\t\t\t\t\t$output = ($input == $value);\n\t\t\t\t} else {\n\t\t\t\t\t$output = ($value == $default || $default === true);\n\t\t\t\t}\n\t\t\tbreak;\n\t\t\tcase 'select':\n\t\t\t\t$output = ($input !== null) ? $input : $default;\n\t\t\tbreak;\n\t\t\tcase 'checkbox':\n\t\t\t\t$output = false;\n\n\t\t\t\tif (is_array($input)) {\n\t\t\t\t\t$flipped = array_flip($input);\n\t\t\t\t\t$output = isset($flipped[$value]);\n\t\t\t\t} else {\n\t\t\t\t\tif ($input !== null) {\n\t\t\t\t\t\t$output = ($input == $value);\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$output = ($value == $default || $default === true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\tbreak;\n\t\t}\n\n\t\treturn $output;\n\t}",
"public function getValueType() : string\n {\n\n if (count($this->valueParts) === 0 || count($this->valueParts) > 1) {\n return 'string';\n }\n\n return gettype($this->valueParts[0]->getContents());\n }",
"function getType() {\r\n\t\t\tif (is_bool($this->Value) ||\r\n\t\t\t is_int($this->Value)) {\r\n\t\t\t\treturn 'i';\r\n\t\t\t}\r\n\r\n\t\t\tif (is_float($this->Value) || \r\n\t\t\t is_numeric($this->Value)) {\r\n\t\t\t\treturn 'd';\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// for anything else use string\r\n\t\t\treturn 's';\r\n\t\t}",
"public function type($value) {\n return $this->setProperty('type', $value);\n }",
"public function type($value)\n {\n return $this->setProperty('type', $value);\n }",
"public function getValueElementType()\n {\n switch ($this->getAttribute()) {\n case 'shipping_method':\n case 'country_id':\n case 'region_id':\n return 'select';\n }\n return 'text';\n }",
"function set_value_type($value_type)\n {\n $this->set_default_property(self :: PROPERTY_VALUE_TYPE, $value_type);\n }",
"private function getType($value){\n\t\tswitch($value) {\n\t\t\tcase is_string($value):\n\t\t\t\treturn \"s\";\n\t\t\tbreak;\n\t\t\tcase is_int($value):\n\t\t\t\treturn \"i\";\n\t\t\tbreak;\n\t\t\tcase is_double($value):\n\t\t\t\treturn \"d\";\n\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\treturn \"s\";\n\t\t\tbreak;\n\t\t}\n\t}",
"public static function getTypeValueLabel($value){\n $labels = self::optsType();\n if(isset($labels[$value])){\n return $labels[$value];\n }\n return $value;\n }",
"public function type(string $value = null)\n {\n if (null !== $value) {\n $this->type = (string) $value;\n }\n\n return $this->type;\n }",
"public function getValueElementType()\n {\n return 'text';\n }",
"public function getType() \n {\n return $this->_fields['Type']['FieldValue'];\n }",
"public static function getTypeByValue($value)\n {\n return self::getType(gettype($value));\n }",
"public static function getTypeValueLabel($value): string\n {\n if (!$value) {\n return '';\n }\n $labels = self::optsType();\n return $labels[$value] ?? $value;\n }",
"protected function getType(): string\n\t{\n\t\tif(is_int($this->value) || is_float($this->value))\n\t\t{\n\t\t\treturn 'number';\n\t\t}\n\t\t\n\t\tif(is_array($this->value))\n\t\t{\n\t\t\treturn 'array';\n\t\t}\n\t\t\n\t\treturn 'string';\n\t}",
"public function get_sanitized_field_value_by_type( $field, $value ) {\n\n\t\t\t$field_type = ( isset( $field['type'] ) ) ? $field['type'] : '';\n\n\t\t\tswitch ( $field_type ) {\n\n\t\t\t\tcase 'time':\n\t\t\t\t\t$value = sanitize_text_field( $value );\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'date':\n\t\t\t\t\t$value = date( \"Y-m-d\", strtotime( $value ) );\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'number':\n\t\t\t\t\t$value = ( is_numeric( $value ) ) ? $value : 0;\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'password':\n\t\t\t\t\t$value = sanitize_text_field( $value );\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'textarea':\n\t\t\t\t\t// HTML and array are allowed\n\t\t\t\t\t$value = sanitize_textarea_field( $value );\n//\t\t\t\t\t $value = wp_kses_post( $value );\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'select':\n\t\t\t\t\t// no break\n\t\t\t\tcase 'radio':\n\t\t\t\t\t// no break\n\t\t\t\t\t$allowed_choices = isset( $field['choices'] ) && is_array( $field['choices'] )\n\t\t\t\t\t\t? array_keys( $field['choices'] )\n\t\t\t\t\t\t: array();\n\t\t\t\t\t$default_values = isset( $field['default'] ) && is_array( $field['default'] )\n\t\t\t\t\t\t? $field['default']\n\t\t\t\t\t\t: array();\n\n\t\t\t\t\t$value = in_array( $value, $allowed_choices ) ? $value : $default_values;\n\t\t\t\t\tunset( $allowed_choices, $default_values ); // free memory\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'checkboxes':\n\t\t\t\t\t$allowed_choices = isset( $field['choices'] ) && is_array( $field['choices'] )\n\t\t\t\t\t\t? array_keys( $field['choices'] )\n\t\t\t\t\t\t: array();\n\t\t\t\t\t$default_values = isset( $field['default'] ) && is_array( $field['default'] )\n\t\t\t\t\t\t? $field['default']\n\t\t\t\t\t\t: array();\n\n\t\t\t\t\tif ( is_array( $value ) && ! empty( $allowed_choices ) ) {\n\t\t\t\t\t\t// if the difference is empty, $value is a subset of $allowed_choices\n\t\t\t\t\t\t$value = ( empty( array_diff( $value, $allowed_choices ) ) ) ? $value : $default_values;\n\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$value = $field['default'];\n\t\t\t\t\t}\n\n\t\t\t\t\tunset( $allowed_choices, $default_values ); // free memory\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'checkbox':\n\t\t\t\t\t$value = ( (int) $value === 1 ) ? 1 : '';\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'color':\n\t\t\t\t\t$value = sanitize_hex_color( $value );\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'editor':\n\t\t\t\t\t// no break\n\t\t\t\t\t$value = wp_kses_post( $value );\n\t\t\t\t\tbreak;\n\n\n\t\t\t\tcase 'uploader':\n\t\t\t\t\t// We are getting image id posted\n\t\t\t\t\t$value = absint( $value );\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'file':\n\t\t\t\t\t// no break\n\n\t\t\t\tdefault:\n\t\t\t\t\t$value = ( ! empty( $value ) ) ? sanitize_text_field( $value ) : '';\n\n\n\t\t\t}\n\n\t\t\treturn $value;\n\n\t\t}",
"public function setType($value)\n {\n return $this->set(self::TYPE, $value);\n }",
"public function setType($value)\n {\n return $this->set(self::TYPE, $value);\n }",
"public function setType($value)\n {\n return $this->set(self::TYPE, $value);\n }",
"public function setType($value)\n {\n return $this->set(self::TYPE, $value);\n }",
"public function setType($value)\n {\n return $this->set(self::TYPE, $value);\n }"
] | [
"0.6587809",
"0.64760226",
"0.64760226",
"0.63923115",
"0.6380591",
"0.63564163",
"0.63309646",
"0.63178915",
"0.63094145",
"0.6269021",
"0.6263408",
"0.6256158",
"0.61449254",
"0.60921586",
"0.6077961",
"0.60602343",
"0.6052861",
"0.6047369",
"0.6022019",
"0.6007067",
"0.5994499",
"0.5986873",
"0.5980181",
"0.5967072",
"0.5957738",
"0.5916616",
"0.5916616",
"0.5916616",
"0.5916616",
"0.5916616"
] | 0.6528448 | 1 |
Created for Labeling UI to export key text. If corrections were made to the text identified by the `field_name.text_anchor`, this field will contain the correction. Generated from protobuf field string corrected_key_text = 6; | public function getCorrectedKeyText()
{
return $this->corrected_key_text;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function setCorrectedKeyText($var)\n {\n GPBUtil::checkString($var, True);\n $this->corrected_key_text = $var;\n\n return $this;\n }",
"function get_text($key) {\n if (isset($this->text[$key])) {\n return $this->text[$key];\n }\n }",
"function __text($key) {\n\t\techo Lang::getMessage($key);\n\t}",
"public function iText($key) {\n\t\t$str = '<input type=\"text\" id=\"i_'.$key.'\" name=\"'.$key.'\" value=\"'\n\t\t\t.$this->_value($key)\n\t\t\t.'\" />';\n\t\tif ($err = $this->_htmlError($key)) {\n\t\t\t$str .= $err;\n\t\t}\n\t\treturn $str;\n\t}",
"public function encode($key, $text)\n {\n $text = (string) trim(htmlentities($text));\n return $this->translator(\n trim(htmlentities(strip_tags($this->keyValidator($key)))), \n str_split(str_replace(' ', $this->breakText, $text))\n );\n }",
"public function setCorrectedValueText($var)\n {\n GPBUtil::checkString($var, True);\n $this->corrected_value_text = $var;\n\n return $this;\n }",
"public function getCorrectedValueText()\n {\n return $this->corrected_value_text;\n }",
"function getKeyStr() {\n return \"Curse:DuckInADungeon. You should know better than to pick up a duck in a dungeon.\";\n }",
"public function getOriginalText() {\n return $this->ptClient->getOriginalText($this->data);\n }",
"public function getMessageTextByKey($k)\n\t{\n\t $sql = \"SELECT text FROM message WHERE msg_key = '\".$k.\"'\";\n\t $result = $this->db->query($sql);\n\t\n\t return $result->row['text'];\n\t}",
"public function _settings_field_api_key()\n\t{\n\t\tif (!empty($this->settings) && array_key_exists('kayako_key', $this->settings)) {\n\t\t\t$kayako_key = htmlspecialchars($this->settings['kayako_key']);\n\t\t}\n\t\t?>\n\t\t<input type=\"text\" name=\"kayako-settings[kayako_key]\" id=\"kayako-settings[kayako_key]\" size=\"60\" value=\"<?php echo $kayako_key; ?>\"/> <?php\n\t}",
"public function updateKeyboard($key)\n {\n if(!in_array($key, $this->phrase->getSelected())){\n return '<button class=\"key\" type=\"submit\" name=\"key\" value=\"' . $key . '\">' . $key . '</button>';\n }\n\n if($this->phrase->checkLetter($key)) {\n return '<button class=\"key correct\" type=\"submit\" name=\"key\" style=\"background-color: #48db73; color: white\" value=\"' . $key . '\" disabled>' . $key . '</button>';\n } else {\n return '<button class=\"key incorrect\" type=\"submit\" name=\"key\" style=\"background-color: #ff005c; color: white\" value=\"' . $key . '\" disabled>' . $key . '</button>';\n }\n }",
"public function text($y_textkey, $y_fallback_language='@default', $y_ignore_empty=false) {\n\t\t//--\n\t\tif((string)$y_textkey == '') {\n\t\t\tSmart::log_warning('Empty Key for Text Context Translator - Area: '.$this->area.' ; SubArea: '.$this->subarea);\n\t\t\treturn '{Empty Translation Key}';\n\t\t} //end if\n\t\t//--\n\t\tif((string)$y_fallback_language == '@default') {\n\t\t\t$y_fallback_language = (string) SmartTextTranslations::getDefaultLanguage();\n\t\t} //end if else\n\t\t//--\n\t\t$text = (string) SmartTextTranslations::getTranslationByKey($this->area, $this->subarea, (string)$y_textkey, $this->language);\n\t\tif(((string)trim((string)$text) == '') AND ((string)$y_fallback_language != '') AND ((string)$y_fallback_language != (string)$this->language)) {\n\t\t\t$text = (string) SmartTextTranslations::getTranslationByKey($this->area, $this->subarea, (string)$y_textkey, (string)$y_fallback_language);\n\t\t} //end if\n\t\tif((string)trim((string)$text) == '') {\n\t\t\tif($y_ignore_empty !== true) {\n\t\t\t\tSmart::log_warning('Undefined Key: ['.$y_textkey.'] for Text Context Translator ['.$this->language.'] - Area: '.$this->area.' ; SubArea: '.$this->subarea);\n\t\t\t\t$text = '{Undefined Translation Key ['.$this->language.']: '.$y_textkey.'}';\n\t\t\t} else {\n\t\t\t\t$text = '';\n\t\t\t} //end if else\n\t\t} //end if\n\t\t//--\n\t\treturn (string) $text;\n\t\t//--\n\t}",
"public function getAltText();",
"public function getField()\n {\n $extracted = explode('key ', $this->message);\n return str_replace('\\'', '', $extracted[1]);\n }",
"public function getSingleKeyField($text,$key) {\n //echo \"start get Single Key Field: key=$key<br>\"; //testing\n $keyFields = $this->getKeyFieldArr(); //get key field and anchors from site settings.\n\n //$fieldsArr = $keyFields[$key];\n $fieldsArr = $this->getKeyArr($keyFields,$key);\n if( !$fieldsArr ) {\n return NULL;\n }\n\n //$fieldsArr[] = array('field'=>\"Applicant ID:\",'startAnchor'=>\"Applicant ID:\",'endAnchor'=>$endArr,'length'=>11);\n $thisKey = NULL; //field to find\n if( isset($fieldsArr['field']) ) {\n $thisKey = $fieldsArr['field'];\n }\n if( $thisKey && $thisKey == $key ) {\n //OK\n } else {\n return NULL;\n }\n\n $startAnchor = NULL;\n $endAnchorArr = NULL;\n $length = NULL;\n $minLength = 2;\n $maxLength = 200;\n $checkIfStartAnchorPresent = NULL;\n\n if( isset($fieldsArr['startAnchor']) ) {\n $startAnchor = $fieldsArr['startAnchor'];\n }\n if( isset($fieldsArr['endAnchor']) ) {\n $endAnchorArr = $fieldsArr['endAnchor'];\n }\n if( isset($fieldsArr['length']) ) {\n $length = $fieldsArr['length'];\n }\n if( isset($fieldsArr['minLength']) ) {\n $minLength = (int)$fieldsArr['minLength'];\n }\n if( isset($fieldsArr['maxLength']) ) {\n $maxLength = (int)$fieldsArr['maxLength'];\n }\n if( isset($fieldsArr['checkIfStartAnchorPresent']) ) {\n $checkIfStartAnchorPresent = $fieldsArr['checkIfStartAnchorPresent'];\n }\n\n //echo \"before get Shortest Field: startAnchor=$startAnchor<br>\"; //testing\n\n $field = $this->getShortestField($text, $startAnchor, $endAnchorArr, $minLength, $length, $maxLength, $checkIfStartAnchorPresent);\n return $field;\n }",
"public function extractText(string $sKey, $mValue, bool $bPlainText = false): ?string;",
"public function decode($key, $text)\n {\n $text = (string) trim(htmlentities($text));\n return $this->reverse(\n trim(htmlentities(strip_tags($this->keyValidator($key)))), \n explode(' ', $text)\n );\n }",
"public function __toString()\n {\n return $this->getKeyword() . ' \"' . str_replace('\"', '\\\\\"', $this->text) . '\"';\n }",
"public function getFormatted($key) {\n\t\t$value = $this->get($key); \n\t\t\n\t\tif($key == 'text') {\n\t\t\tif($this->textFormatted !== null) return $this->textFormatted;\n\t\t\t\n\t\t\t$textformatters = null;\n\t\t\t// $textformatters = $this->field ? $this->field->textformatters : null; // @todo\n\t\t\tif(is_array($textformatters) && count($textformatters)) {\n\t\t\t\t// output formatting with specified textformatters\n\t\t\t\tforeach($textformatters as $name) {\n\t\t\t\t\tif(!$textformatter = $this->wire('modules')->get($name)) continue;\n\t\t\t\t\t$textformatter->formatValue($this->page, $this->field, $value);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// default output formatting\n\t\t\t\t$value = $this->wire('sanitizer')->entities(trim($value));\n\t\t\t\t$value = str_replace(\"\\n\\n\", \"</p><p>\", $value);\n\t\t\t\t$value = str_replace(\"\\n\", \"<br />\", $value);\n\t\t\t}\n\t\t\t\n\t\t} else if(in_array($key, array('cite', 'email', 'user_agent', 'website'))) {\n\t\t\t$value = $this->wire('sanitizer')->entities(trim($value));\n\t\t}\n\t\t\n\t\treturn $value; \n\t}",
"public function generate_text_for_display()\n\t{\n\t\t$message = $message_uid = $message_bitfield = $message_options = false;\n\t\t$this->get_message_fields($message, $message_uid, $message_bitfield, $message_options);\n\n\t\treturn generate_text_for_display($message, $message_uid, $message_bitfield, $message_options);\n\t}",
"public function getTextAlignment () {}",
"private function getFormText() {\n return trim(substr($this->input['message']['text'], ($this->input['message']['entities'][0]['length'] + 1), (strlen($this->input['message']['text']) - 1)));\n }",
"public function getTextEncoding () {}",
"function presscore_meta_box_text_assistive_text( $field_html, $field, $meta ) {\n\tif ( !empty($field['assistive_text']) ) {\n\t\t$field_html .= ' <small>' . $field['assistive_text'] . '</small>';\n\t}\n\treturn $field_html;\n}",
"function GetKey()\r\n\t{\r\n\t\treturn \"Èä#93[äçß}¥\";\r\n\t}",
"public static function getAlias ( string $key ) : string \n\t{\n\t\tswitch ( $key )\n\t\t{\n\t\t\tcase self::KEY_TYPE_RANDOM:\n\t\t\t\treturn 'Chave Aleatória';\n\t\t\tcase self::KEY_TYPE_DOCUMENT:\n\t\t\t\treturn 'CPF/CNPJ';\n\t\t\tcase self::KEY_TYPE_EMAIL:\n\t\t\t\treturn 'E-mail';\n\t\t\tcase self::KEY_TYPE_PHONE:\n\t\t\t\treturn 'Telefone';\n\t\t}\n\n\t\treturn 'Chave Desconhecida';\n\t}",
"public function prepareKeyFormat(String $key): ?String\n {\n $separator = \"\\r\\n\";\n $line = strtok($key, $separator);\n $validBegin = false;\n $validEnd = false;\n $formattedKey = '';\n while ($line !== false) {\n if (strpos($line, \"-----BEGIN\") !== false) {\n $line = strtok($separator);\n $validBegin = true;\n continue;\n } elseif (strpos($line, \"-----END\") !== false) {\n $line = strtok($separator);\n $validEnd = true;\n continue;\n } elseif ($line == \"\") {\n $line = strtok($separator);\n continue;\n }\n\n if ($validBegin) {\n $formattedKey .= $line;\n }\n\n $line = strtok($separator);\n }\n\n if ($validBegin && $validEnd) {\n return substr($formattedKey, 0, strripos($formattedKey, '='));\n } else {\n return null;\n }\n }",
"public function get_autotext($key){\n if (!isset($this->ci->autotext_m)){\n $this->ci->load->model('mail/autotext_m');\n }\n if (is_int($key)){\n $autotext = $this->ci->autotext_m->get($key);\n }else{\n $autotext = $this->ci->autotext_m->get_by(array('name'=>$key), TRUE);\n }\n \n return $autotext;\n }",
"private function getText()\n {\n\t\tif(\\Cart2Quote\\License\\Model\\License::getInstance()->isValid()) {\n\t\t\t$message = __('Cart2Quote notice:');\n $url = $this->backendUrl->getUrl('quotation/quote');\n $newRequestCount = $this->getNewRequestCount();\n if ($newRequestCount == 1) {\n $message .= '<br/>';\n $message .= __('You have <a href=\"%1\">1 unanswered quote</a> request.', $url);\n } else {\n if ($newRequestCount > 1) {\n $message .= '<br/>';\n $message .= __('You have <a href=\"%1\">%2 unanswered quote</a> requests.', $url, $newRequestCount);\n }\n }\n $newRequestSinceLogin = $this->getNewRequestSinceLoginCount();\n if ($newRequestSinceLogin == 1) {\n $message .= '<br/>';\n $message .= __('There is <a href=\"%1\">1 new quote request</a> since your last login.', $url);\n } else {\n if ($newRequestSinceLogin > 1) {\n $message .= '<br/>';\n $message .= __(\n 'There are <a href=\"%1\">%2 new quote requests</a> since your last login.',\n $url,\n $newRequestSinceLogin\n );\n }\n }\n return $message;\n\t\t}\n\t}"
] | [
"0.7281785",
"0.5209766",
"0.520172",
"0.5088541",
"0.5063301",
"0.48811036",
"0.48503754",
"0.48082379",
"0.48071846",
"0.47091046",
"0.47086123",
"0.47008625",
"0.46892503",
"0.4670889",
"0.46638986",
"0.4634315",
"0.4621006",
"0.46191493",
"0.459982",
"0.45947254",
"0.45680746",
"0.45467755",
"0.45332816",
"0.4514754",
"0.44895828",
"0.4481977",
"0.44536972",
"0.44536376",
"0.4451993",
"0.44499266"
] | 0.7306596 | 0 |
Created for Labeling UI to export key text. If corrections were made to the text identified by the `field_name.text_anchor`, this field will contain the correction. Generated from protobuf field string corrected_key_text = 6; | public function setCorrectedKeyText($var)
{
GPBUtil::checkString($var, True);
$this->corrected_key_text = $var;
return $this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getCorrectedKeyText()\n {\n return $this->corrected_key_text;\n }",
"function get_text($key) {\n if (isset($this->text[$key])) {\n return $this->text[$key];\n }\n }",
"function __text($key) {\n\t\techo Lang::getMessage($key);\n\t}",
"public function iText($key) {\n\t\t$str = '<input type=\"text\" id=\"i_'.$key.'\" name=\"'.$key.'\" value=\"'\n\t\t\t.$this->_value($key)\n\t\t\t.'\" />';\n\t\tif ($err = $this->_htmlError($key)) {\n\t\t\t$str .= $err;\n\t\t}\n\t\treturn $str;\n\t}",
"public function encode($key, $text)\n {\n $text = (string) trim(htmlentities($text));\n return $this->translator(\n trim(htmlentities(strip_tags($this->keyValidator($key)))), \n str_split(str_replace(' ', $this->breakText, $text))\n );\n }",
"public function setCorrectedValueText($var)\n {\n GPBUtil::checkString($var, True);\n $this->corrected_value_text = $var;\n\n return $this;\n }",
"public function getCorrectedValueText()\n {\n return $this->corrected_value_text;\n }",
"public function getOriginalText() {\n return $this->ptClient->getOriginalText($this->data);\n }",
"function getKeyStr() {\n return \"Curse:DuckInADungeon. You should know better than to pick up a duck in a dungeon.\";\n }",
"public function getMessageTextByKey($k)\n\t{\n\t $sql = \"SELECT text FROM message WHERE msg_key = '\".$k.\"'\";\n\t $result = $this->db->query($sql);\n\t\n\t return $result->row['text'];\n\t}",
"public function _settings_field_api_key()\n\t{\n\t\tif (!empty($this->settings) && array_key_exists('kayako_key', $this->settings)) {\n\t\t\t$kayako_key = htmlspecialchars($this->settings['kayako_key']);\n\t\t}\n\t\t?>\n\t\t<input type=\"text\" name=\"kayako-settings[kayako_key]\" id=\"kayako-settings[kayako_key]\" size=\"60\" value=\"<?php echo $kayako_key; ?>\"/> <?php\n\t}",
"public function updateKeyboard($key)\n {\n if(!in_array($key, $this->phrase->getSelected())){\n return '<button class=\"key\" type=\"submit\" name=\"key\" value=\"' . $key . '\">' . $key . '</button>';\n }\n\n if($this->phrase->checkLetter($key)) {\n return '<button class=\"key correct\" type=\"submit\" name=\"key\" style=\"background-color: #48db73; color: white\" value=\"' . $key . '\" disabled>' . $key . '</button>';\n } else {\n return '<button class=\"key incorrect\" type=\"submit\" name=\"key\" style=\"background-color: #ff005c; color: white\" value=\"' . $key . '\" disabled>' . $key . '</button>';\n }\n }",
"public function text($y_textkey, $y_fallback_language='@default', $y_ignore_empty=false) {\n\t\t//--\n\t\tif((string)$y_textkey == '') {\n\t\t\tSmart::log_warning('Empty Key for Text Context Translator - Area: '.$this->area.' ; SubArea: '.$this->subarea);\n\t\t\treturn '{Empty Translation Key}';\n\t\t} //end if\n\t\t//--\n\t\tif((string)$y_fallback_language == '@default') {\n\t\t\t$y_fallback_language = (string) SmartTextTranslations::getDefaultLanguage();\n\t\t} //end if else\n\t\t//--\n\t\t$text = (string) SmartTextTranslations::getTranslationByKey($this->area, $this->subarea, (string)$y_textkey, $this->language);\n\t\tif(((string)trim((string)$text) == '') AND ((string)$y_fallback_language != '') AND ((string)$y_fallback_language != (string)$this->language)) {\n\t\t\t$text = (string) SmartTextTranslations::getTranslationByKey($this->area, $this->subarea, (string)$y_textkey, (string)$y_fallback_language);\n\t\t} //end if\n\t\tif((string)trim((string)$text) == '') {\n\t\t\tif($y_ignore_empty !== true) {\n\t\t\t\tSmart::log_warning('Undefined Key: ['.$y_textkey.'] for Text Context Translator ['.$this->language.'] - Area: '.$this->area.' ; SubArea: '.$this->subarea);\n\t\t\t\t$text = '{Undefined Translation Key ['.$this->language.']: '.$y_textkey.'}';\n\t\t\t} else {\n\t\t\t\t$text = '';\n\t\t\t} //end if else\n\t\t} //end if\n\t\t//--\n\t\treturn (string) $text;\n\t\t//--\n\t}",
"public function getAltText();",
"public function getField()\n {\n $extracted = explode('key ', $this->message);\n return str_replace('\\'', '', $extracted[1]);\n }",
"public function getSingleKeyField($text,$key) {\n //echo \"start get Single Key Field: key=$key<br>\"; //testing\n $keyFields = $this->getKeyFieldArr(); //get key field and anchors from site settings.\n\n //$fieldsArr = $keyFields[$key];\n $fieldsArr = $this->getKeyArr($keyFields,$key);\n if( !$fieldsArr ) {\n return NULL;\n }\n\n //$fieldsArr[] = array('field'=>\"Applicant ID:\",'startAnchor'=>\"Applicant ID:\",'endAnchor'=>$endArr,'length'=>11);\n $thisKey = NULL; //field to find\n if( isset($fieldsArr['field']) ) {\n $thisKey = $fieldsArr['field'];\n }\n if( $thisKey && $thisKey == $key ) {\n //OK\n } else {\n return NULL;\n }\n\n $startAnchor = NULL;\n $endAnchorArr = NULL;\n $length = NULL;\n $minLength = 2;\n $maxLength = 200;\n $checkIfStartAnchorPresent = NULL;\n\n if( isset($fieldsArr['startAnchor']) ) {\n $startAnchor = $fieldsArr['startAnchor'];\n }\n if( isset($fieldsArr['endAnchor']) ) {\n $endAnchorArr = $fieldsArr['endAnchor'];\n }\n if( isset($fieldsArr['length']) ) {\n $length = $fieldsArr['length'];\n }\n if( isset($fieldsArr['minLength']) ) {\n $minLength = (int)$fieldsArr['minLength'];\n }\n if( isset($fieldsArr['maxLength']) ) {\n $maxLength = (int)$fieldsArr['maxLength'];\n }\n if( isset($fieldsArr['checkIfStartAnchorPresent']) ) {\n $checkIfStartAnchorPresent = $fieldsArr['checkIfStartAnchorPresent'];\n }\n\n //echo \"before get Shortest Field: startAnchor=$startAnchor<br>\"; //testing\n\n $field = $this->getShortestField($text, $startAnchor, $endAnchorArr, $minLength, $length, $maxLength, $checkIfStartAnchorPresent);\n return $field;\n }",
"public function extractText(string $sKey, $mValue, bool $bPlainText = false): ?string;",
"public function decode($key, $text)\n {\n $text = (string) trim(htmlentities($text));\n return $this->reverse(\n trim(htmlentities(strip_tags($this->keyValidator($key)))), \n explode(' ', $text)\n );\n }",
"public function __toString()\n {\n return $this->getKeyword() . ' \"' . str_replace('\"', '\\\\\"', $this->text) . '\"';\n }",
"public function getFormatted($key) {\n\t\t$value = $this->get($key); \n\t\t\n\t\tif($key == 'text') {\n\t\t\tif($this->textFormatted !== null) return $this->textFormatted;\n\t\t\t\n\t\t\t$textformatters = null;\n\t\t\t// $textformatters = $this->field ? $this->field->textformatters : null; // @todo\n\t\t\tif(is_array($textformatters) && count($textformatters)) {\n\t\t\t\t// output formatting with specified textformatters\n\t\t\t\tforeach($textformatters as $name) {\n\t\t\t\t\tif(!$textformatter = $this->wire('modules')->get($name)) continue;\n\t\t\t\t\t$textformatter->formatValue($this->page, $this->field, $value);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// default output formatting\n\t\t\t\t$value = $this->wire('sanitizer')->entities(trim($value));\n\t\t\t\t$value = str_replace(\"\\n\\n\", \"</p><p>\", $value);\n\t\t\t\t$value = str_replace(\"\\n\", \"<br />\", $value);\n\t\t\t}\n\t\t\t\n\t\t} else if(in_array($key, array('cite', 'email', 'user_agent', 'website'))) {\n\t\t\t$value = $this->wire('sanitizer')->entities(trim($value));\n\t\t}\n\t\t\n\t\treturn $value; \n\t}",
"public function generate_text_for_display()\n\t{\n\t\t$message = $message_uid = $message_bitfield = $message_options = false;\n\t\t$this->get_message_fields($message, $message_uid, $message_bitfield, $message_options);\n\n\t\treturn generate_text_for_display($message, $message_uid, $message_bitfield, $message_options);\n\t}",
"public function getTextAlignment () {}",
"private function getFormText() {\n return trim(substr($this->input['message']['text'], ($this->input['message']['entities'][0]['length'] + 1), (strlen($this->input['message']['text']) - 1)));\n }",
"public function getTextEncoding () {}",
"function presscore_meta_box_text_assistive_text( $field_html, $field, $meta ) {\n\tif ( !empty($field['assistive_text']) ) {\n\t\t$field_html .= ' <small>' . $field['assistive_text'] . '</small>';\n\t}\n\treturn $field_html;\n}",
"function GetKey()\r\n\t{\r\n\t\treturn \"Èä#93[äçß}¥\";\r\n\t}",
"public static function getAlias ( string $key ) : string \n\t{\n\t\tswitch ( $key )\n\t\t{\n\t\t\tcase self::KEY_TYPE_RANDOM:\n\t\t\t\treturn 'Chave Aleatória';\n\t\t\tcase self::KEY_TYPE_DOCUMENT:\n\t\t\t\treturn 'CPF/CNPJ';\n\t\t\tcase self::KEY_TYPE_EMAIL:\n\t\t\t\treturn 'E-mail';\n\t\t\tcase self::KEY_TYPE_PHONE:\n\t\t\t\treturn 'Telefone';\n\t\t}\n\n\t\treturn 'Chave Desconhecida';\n\t}",
"public function prepareKeyFormat(String $key): ?String\n {\n $separator = \"\\r\\n\";\n $line = strtok($key, $separator);\n $validBegin = false;\n $validEnd = false;\n $formattedKey = '';\n while ($line !== false) {\n if (strpos($line, \"-----BEGIN\") !== false) {\n $line = strtok($separator);\n $validBegin = true;\n continue;\n } elseif (strpos($line, \"-----END\") !== false) {\n $line = strtok($separator);\n $validEnd = true;\n continue;\n } elseif ($line == \"\") {\n $line = strtok($separator);\n continue;\n }\n\n if ($validBegin) {\n $formattedKey .= $line;\n }\n\n $line = strtok($separator);\n }\n\n if ($validBegin && $validEnd) {\n return substr($formattedKey, 0, strripos($formattedKey, '='));\n } else {\n return null;\n }\n }",
"public function get_autotext($key){\n if (!isset($this->ci->autotext_m)){\n $this->ci->load->model('mail/autotext_m');\n }\n if (is_int($key)){\n $autotext = $this->ci->autotext_m->get($key);\n }else{\n $autotext = $this->ci->autotext_m->get_by(array('name'=>$key), TRUE);\n }\n \n return $autotext;\n }",
"private function getText()\n {\n\t\tif(\\Cart2Quote\\License\\Model\\License::getInstance()->isValid()) {\n\t\t\t$message = __('Cart2Quote notice:');\n $url = $this->backendUrl->getUrl('quotation/quote');\n $newRequestCount = $this->getNewRequestCount();\n if ($newRequestCount == 1) {\n $message .= '<br/>';\n $message .= __('You have <a href=\"%1\">1 unanswered quote</a> request.', $url);\n } else {\n if ($newRequestCount > 1) {\n $message .= '<br/>';\n $message .= __('You have <a href=\"%1\">%2 unanswered quote</a> requests.', $url, $newRequestCount);\n }\n }\n $newRequestSinceLogin = $this->getNewRequestSinceLoginCount();\n if ($newRequestSinceLogin == 1) {\n $message .= '<br/>';\n $message .= __('There is <a href=\"%1\">1 new quote request</a> since your last login.', $url);\n } else {\n if ($newRequestSinceLogin > 1) {\n $message .= '<br/>';\n $message .= __(\n 'There are <a href=\"%1\">%2 new quote requests</a> since your last login.',\n $url,\n $newRequestSinceLogin\n );\n }\n }\n return $message;\n\t\t}\n\t}"
] | [
"0.7304813",
"0.52087873",
"0.5198854",
"0.5086391",
"0.5063215",
"0.48817453",
"0.48489907",
"0.48070803",
"0.48048857",
"0.47071728",
"0.4705787",
"0.4698499",
"0.4688704",
"0.4669575",
"0.46606895",
"0.4630943",
"0.46202508",
"0.46180567",
"0.45985913",
"0.4592444",
"0.4566519",
"0.45453894",
"0.45327544",
"0.45142862",
"0.4488562",
"0.4478914",
"0.44508526",
"0.445027",
"0.4449622",
"0.4449064"
] | 0.72822005 | 1 |
Created for Labeling UI to export value text. If corrections were made to the text identified by the `field_value.text_anchor`, this field will contain the correction. Generated from protobuf field string corrected_value_text = 7; | public function getCorrectedValueText()
{
return $this->corrected_value_text;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function setCorrectedValueText($var)\n {\n GPBUtil::checkString($var, True);\n $this->corrected_value_text = $var;\n\n return $this;\n }",
"public function setText($value)\n {\n return $this->set(self::text, $value);\n }",
"public function TextValue()\n {\n return $this->Html();\n }",
"private function valuationString($value)\n {\n if ($value != \"no data\")\n {\n return \"The value of this space was £\" . number_format($value) . \". \";\n }\n return \"No information was available about the value of the space. \";\n }",
"function print_text($value){\r\n\t\tif ( isset ( $value['protected'][0][\"id\"] ) || isset ( $value['std'] ) ) {\r\n\t\t\t$protected_value = $this->get_field_value( $value['protected'][0][\"id\"], $value['std'] );\r\n\t\t}\r\n\t\t\r\n\t\tif ( isset ( $value['protected'][1][\"id\"] ) || isset ( $value['std'] ) ) {\r\n\t\t\t$protected_value_1 = $this->get_field_value( $value['protected'][1][\"id\"], $value['std'] );\r\n\t\t}\r\n\t\t\r\n\t\tif ( isset ( $value['id'] ) || isset ( $value['std'] ) ) {\r\n\t\t\t$input_value = $this->get_field_value( $value['id'], $value['std'] );\r\n\t\t}\r\n\t\t\r\n\t\tif(((isset($value['protected'][0][\"id\"]) && $value['protected'][0][\"id\"]!=\"\") && $protected_value==$value['protected'][0][\"value\"]) && $protected_value_1==$value['protected'][1][\"value\"] || (!isset($value['protected'][0][\"id\"]))) {\r\n\r\n\t\t\t\r\n\t\t\techo '<div id=\"theme_documentation\" style=\"min-height:300px;\">\r\n\t\t\t<div style=\"margin-left:33px; margin-right:25px;\">\r\n\t\t\t'.$value['text'].'\t\r\n\t\t\t</div>\t\t\t\t\t\t\t\t\r\n\t\t\t</div>';\r\n\t\t}\r\n\t}",
"function getTextValue( $view, $field_name, $value ) {\n $this->_zen->addDebug(\"getTextValue\", \"rendering $view, $field_name, $value\", 3);\n $field = $this->getFieldFromMap($view,$field_name);\n $userBins = $this->_zen->getUsersBins($_SESSION['login_id']);\n if( $field['is_visible'] && $field['field_type'] != 'hidden' ) {\n if( !strlen($value) ) { return ' '; }\n switch($this->fieldName($field_name)) {\n case \"priority\":\n case \"status\":\n case \"bin_id\":\n case \"type_id\":\n case \"system_id\":\n $vals = $this->_zen->getValsForTicketField($field_name,$userBins);\n if( isset($vals[\"$value\"]) ) { return $this->_zen->ffv(tr($vals[\"$value\"])); }\n else {\n $this->_zen->addDebug(\"getTextValue\", \"Unable to find choices for {$view}->{$field_name}\", 1);\n return $this->_zen->ffv($value, $field['num_cols']); \n }\n case \"user_id\":\n case \"creator_id\":\n $name = $this->_zen->formatName($value,1);\n return $this->_zen->ffv($name,$field['num_cols']);\n case \"tested\":\n case \"approved\":\n $val = $value == 1? tr('Required') : ($value == 2? tr('Complete') : tr('n/a'));\n return $this->_zen->ffv($val,$field['num_cols']);\n case \"otime\":\n case \"ctime\":\n case \"deadline\":\n case \"start_date\":\n case \"custom_date\":\n if( preg_match('/[^0-9]/', $value) ) {\n return $this->_zen->ffv($value,$field['num_cols']);\n }\n if( $value == 'NULL' ) { $value = ''; }\n if( $value == 0 ) { $value = \"\"; }\n return $this->_zen->showDateTime($value);\n case \"custom_boolean\":\n $val = $value == 1? tr('Yes') : tr('No');\n return $this->_zen->ffv($val,$field['num_cols']);\n case \"details\":\n case \"title\":\n case \"custom_text\":\n return $this->_zen->ffvText($value);\n case \"custom_multi\":\n// return str_replace(\"\\t\", \"; \", $value);\n return implode($this->_zen->multisep, $value);\n default:\n $val = $this->_zen->ffvText(str_replace(\"\\t\",\";\",$value), $field['num_cols']);\n $this->_zen->addDebug(\"getTextValue\", \"rendering default: $val\", 3);\n return $val;\n }\n }\n // it's hidden, return nothing\n return '';\n }",
"public function getValue(): string\n {\n return $this->getText();\n }",
"public function getRichtextValue()\n {\n return $this->readOneof(8);\n }",
"public function render() {\n $result = $this->text;\n foreach($this->values as $name => $value) {\n// TTracer::Trace(\"adding value: $name = $value\");\n $token = sprintf('[value:%s]',$name);\n $result = str_replace($token,$value,$result);\n }\n return $result;\n }",
"public function getTextValue()\n\t{\n\t\treturn NULL;\n\t}",
"function print_text_2($value){\r\n\t\tif(isset($value['std'])) {\r\n\t\t\t$default = $value['std'];\r\n\t\t} else {\r\n\t\t\t$default = false;\r\n\t\t}\r\n\t\tif(isset($value['protected'][0][\"id\"])) {\r\n\t\t\t$protectedValue = $value['protected'][0][\"id\"];\r\n\t\t} else {\r\n\t\t\t$protectedValue = false;\r\n\t\t}\r\n\t\t\r\n\t\t$protected_value = $this->get_field_value($protectedValue, $default);\r\n\t\t\r\n\t\t\r\n\t\tif(((isset($value['protected'][0][\"id\"]) && $value['protected'][0][\"id\"]!=\"\") && $protected_value==$value['protected'][0][\"value\"]) || (!isset($value['protected'][0][\"id\"]))) {\r\n\r\n\t\t\t\r\n\t\t\techo '<div id=\"theme_documentation\" style=\"margin-bottom:10px;\">\r\n\t\t\t<div style=\"margin-left:0px; margin-right:25px;\">\r\n\t\t\t'.$value['text'].'\t\r\n\t\t\t</div>\t\t\t\t\t\t\t\t\r\n\t\t\t</div>';\r\n\t\t}\r\n\t}",
"public function fillAfterText($varValue, \\DataContainer $dc)\n\t{\n\t\tif(strip_tags($dc->activeRecord->after_text) == '')\n\t\t{\n\t\t if(strlen($varValue)<=0) return $varValue;\n\n //hole das ausgewähte Template\n $objTemplate = IaoTemplatesModel::findById($varValue);\n\n //hole den aktuellen Datensatz als DB-Object\n $objDbOffer = IaoInvoiceModel::findById($dc->id);\n\n\t\t\t$text = $this->changeIAOTags($objTemplate->text,'invoice',$objDbOffer);\n\n\t\t\t// schreibe das Textfeld\n $set =['after_text' => $text];\n\t\t\tDB::getInstance()->prepare('UPDATE `tl_iao_invoice` %s WHERE `id`=?')\n\t\t\t\t->set($set)\n ->limit(1)\n\t\t\t\t->execute($dc->id);\n\t\t}\n\t\treturn $varValue;\n\t}",
"function _parser_prepare_field_text(&$result, $field_info, $field_instance, $entity, $job, $base_url) {\n if ($field_instance['settings']['text_processing']) {\n if (is_string($result)) {\n $result = array('value' => $result);\n }\n if (empty($result['format'])) {\n $result['format'] = 'filtered_html';\n }\n $result_value = &$result['value'];\n }\n else {\n $result_value = &$result;\n }\n\n $result_value = trim($result_value);\n if (!empty($field_info['settings']['max_length']) && drupal_strlen($result_value) > $field_info['settings']['max_length']) {\n $original_result = $result_value;\n $result_value = drupal_substr($result_value, 0, $field_info['settings']['max_length']);\n _parser_watchdog('\n Обрезан текст в поле \"' . $field_info['field_name'] . '\":\n \"<i>' . check_plain($original_result) . '</i>\" =>\n \"<i>' . check_plain($result_value) . '</i>\".\n ');\n }\n}",
"public function text_field( $fpdf, $field_name, $value, $show_border, $align = 'L' ) {\n\n\t\tif ( $this->get_field_position( $field_name ) && $value ) {\n\n\t\t\t$font = $this->get_field_font( $field_name );\n\n\t\t\t// get the field position\n\t\t\tlist( $x, $y, $w, $h ) = array_map( array( $this, 'convert_pixels_to_points' ), array_values( $this->get_field_position( $field_name ) ) );\n\n\t\t\t// font color\n\t\t\t$font['color'] = $this->hex2rgb( $font['color'] );\n\t\t\t$fpdf->SetTextColor( $font['color'][0], $font['color'][1], $font['color'][2] );\n\n\t\t\t// set the field text styling\n\t\t\t$fpdf->SetFont( $font['family'], $font['style'], $font['size'] );\n\n\t\t\t// show a border for debugging purposes\n\t\t\tif ( $show_border ) {\n\t\t\t\t$fpdf->setXY( $x, $y );\n\t\t\t\t$fpdf->Cell( $w, $h, '', 1 );\n\t\t\t}\n\n\t\t\t// align the text to the bottom edge of the cell by translating as needed\n\t\t\t$y = $font['size'] > $h ? $y - ( $font['size'] - $h ) / 2 : $y + ( $h - $font['size'] ) / 2;\n\n\t\t\t// handle right/center justification, it's left-justified by default so nothing to do in that case\n\t\t\tif ( 'R' == $align ) {\n\t\t\t\t$x = max( 0, $x + ( $w - $fpdf->GetStringWidth( $value ) ) );\n\t\t\t} elseif ( 'C' == $align ) {\n\t\t\t\t$x = max( 0, $x + ( $w - $fpdf->GetStringWidth( $value ) ) / 2 );\n\t\t\t}\n\n\t\t\t$fpdf->setXY( $x, $y );\n\n\t\t\t// and write out the value\n\t\t\t$fpdf->Cell( $w, $h, utf8_decode( $value ) ); // can try iconv('UTF-8', 'windows-1252', $value); if this doesn't work correctly for accents\n\t\t}\n\t}",
"protected function loadMotivationText($value) {\n\t\t$text=[];\n\t\tif ($value >= 0) {\n\t\t\t$text[0]='';\n\t\t\t$text[1]='Gratulacje.';\n\t\t\t$text[2]='Świetnie zarządzasz finansami!';\n\t\t} else {\n\t\t\t$text[0]='color:red';\n\t\t\t$text[1]='Uważaj,';\n\t\t\t$text[2]='wpadasz w długi!';\n\t\t}\n\t\treturn $text;\n\t}",
"public function text($value) {\n return $this->setProperty('text', $value);\n }",
"public function text($value) {\n return $this->setProperty('text', $value);\n }",
"public function text($value) {\n return $this->setProperty('text', $value);\n }",
"public function text($value) {\n return $this->setProperty('text', $value);\n }",
"public function addText($value)\n {\n $this->setValue($value);\n }",
"public function text($value)\n {\n return $this->setProperty('text', $value);\n }",
"public function getText()\n {\n return $this->readOneof(2);\n }",
"function external_text( $field_value, $field ) {\n\t\t\n\t\tif ( empty($field_value) )\n\t\t\treturn 'Empty';\n\t\t\n\t\treturn $field_value['display_name'];\n\t}",
"public function asText()\n {\n return $this->getValue();\n }",
"function TextLine($value) {\n return $value . $this->LE;\n }",
"public function getText()\n {\n return $this->readOneof(1);\n }",
"public function asNtext($value)\n {\n if ($value === null || $value == '') {\n return null;\n }\n return nl2br(Html::encode($value));\n }",
"function print_add_text($value) {\r\n\t\tif(isset($value['std'])) {\r\n\t\t\t$default = $value['std'];\r\n\t\t} else {\r\n\t\t\t$default = false;\r\n\t\t}\r\n\t\tif(isset($value['protected'][0][\"id\"])) {\r\n\t\t\t$protectedValue = $value['protected'][0][\"id\"];\r\n\t\t} else {\r\n\t\t\t$protectedValue = false;\r\n\t\t}\r\n\t\t\r\n\t\t$protected_value = $this->get_field_value($protectedValue, $default);\r\n\t\t\r\n\t\tif(((isset($protectedValue) && $protectedValue!=\"\") && $protected_value==$value['protected'][0][\"value\"]) && $protected_value_1==$value['protected'][1][\"value\"] || ($protectedValue==false)) {\r\n\r\n\t\t\t$input_value = $this->get_field_value($value['id'], $default);\r\n\r\n\t\t?>\r\n\t\t<?php if( isset($value['home']) && $value['home'] == \"yes\" ) { ?><div class=\"input-item-full-width-inside clearfix\"><?php } else { ?>\r\n\t\t\t<div class=\"input-item-full-width clearfix\">\r\n\t\t<?php } ?>\r\n\t\t\t<label><?php echo $value['title'];?></label>\r\n\t\t\t<span class=\"input-text\"><input type=\"text\" name=\"<?php echo $value['id']; ?>\" /></span>\r\n\t\t<?php\r\n\t\t}\r\n\t\t$saved_value = get_option( $value['id'].'s' );\r\n\t\t$saved_value = stripslashes($saved_value);\r\n\r\n\t\techo '<input type=\"hidden\" name=\"'.$value['id'].'s\" id=\"'.$value['id'].'s\" value=\"'.$saved_value.'\" />';\r\n\t\t?>\r\n\t\t</div>\r\n\t\t<input type=\"hidden\" name=\"action\" value=\"save\" />\r\n\t\t<a href=\"javascript:{}\" onclick=\"document.getElementById('different-themes-options').submit(); return false;\" class=\"button-1\">Add</a>\r\n\t\t\t\r\n\t\t<?php\r\n\t}",
"public function getText($value)\n\t{\n\t\tif (!$item = $this->getItem($value))\n\t\t\treturn '';\n\n\t\treturn $item['text'];\n\t}",
"public function asText($value)\n {\n if ($value === null || $value == '') {\n return null;\n }\n return Html::encode($value);\n }"
] | [
"0.66521704",
"0.5781177",
"0.57454425",
"0.56932724",
"0.5686227",
"0.5660038",
"0.5602757",
"0.5587832",
"0.5585191",
"0.5573439",
"0.5560005",
"0.55566806",
"0.5542152",
"0.54959786",
"0.54712677",
"0.5461617",
"0.5461617",
"0.5461617",
"0.5461617",
"0.5460979",
"0.54547143",
"0.5398243",
"0.5392876",
"0.53737193",
"0.5365898",
"0.53645366",
"0.5353795",
"0.5353615",
"0.5351559",
"0.53514427"
] | 0.69133455 | 0 |
Created for Labeling UI to export value text. If corrections were made to the text identified by the `field_value.text_anchor`, this field will contain the correction. Generated from protobuf field string corrected_value_text = 7; | public function setCorrectedValueText($var)
{
GPBUtil::checkString($var, True);
$this->corrected_value_text = $var;
return $this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getCorrectedValueText()\n {\n return $this->corrected_value_text;\n }",
"public function setText($value)\n {\n return $this->set(self::text, $value);\n }",
"public function TextValue()\n {\n return $this->Html();\n }",
"private function valuationString($value)\n {\n if ($value != \"no data\")\n {\n return \"The value of this space was £\" . number_format($value) . \". \";\n }\n return \"No information was available about the value of the space. \";\n }",
"function print_text($value){\r\n\t\tif ( isset ( $value['protected'][0][\"id\"] ) || isset ( $value['std'] ) ) {\r\n\t\t\t$protected_value = $this->get_field_value( $value['protected'][0][\"id\"], $value['std'] );\r\n\t\t}\r\n\t\t\r\n\t\tif ( isset ( $value['protected'][1][\"id\"] ) || isset ( $value['std'] ) ) {\r\n\t\t\t$protected_value_1 = $this->get_field_value( $value['protected'][1][\"id\"], $value['std'] );\r\n\t\t}\r\n\t\t\r\n\t\tif ( isset ( $value['id'] ) || isset ( $value['std'] ) ) {\r\n\t\t\t$input_value = $this->get_field_value( $value['id'], $value['std'] );\r\n\t\t}\r\n\t\t\r\n\t\tif(((isset($value['protected'][0][\"id\"]) && $value['protected'][0][\"id\"]!=\"\") && $protected_value==$value['protected'][0][\"value\"]) && $protected_value_1==$value['protected'][1][\"value\"] || (!isset($value['protected'][0][\"id\"]))) {\r\n\r\n\t\t\t\r\n\t\t\techo '<div id=\"theme_documentation\" style=\"min-height:300px;\">\r\n\t\t\t<div style=\"margin-left:33px; margin-right:25px;\">\r\n\t\t\t'.$value['text'].'\t\r\n\t\t\t</div>\t\t\t\t\t\t\t\t\r\n\t\t\t</div>';\r\n\t\t}\r\n\t}",
"function getTextValue( $view, $field_name, $value ) {\n $this->_zen->addDebug(\"getTextValue\", \"rendering $view, $field_name, $value\", 3);\n $field = $this->getFieldFromMap($view,$field_name);\n $userBins = $this->_zen->getUsersBins($_SESSION['login_id']);\n if( $field['is_visible'] && $field['field_type'] != 'hidden' ) {\n if( !strlen($value) ) { return ' '; }\n switch($this->fieldName($field_name)) {\n case \"priority\":\n case \"status\":\n case \"bin_id\":\n case \"type_id\":\n case \"system_id\":\n $vals = $this->_zen->getValsForTicketField($field_name,$userBins);\n if( isset($vals[\"$value\"]) ) { return $this->_zen->ffv(tr($vals[\"$value\"])); }\n else {\n $this->_zen->addDebug(\"getTextValue\", \"Unable to find choices for {$view}->{$field_name}\", 1);\n return $this->_zen->ffv($value, $field['num_cols']); \n }\n case \"user_id\":\n case \"creator_id\":\n $name = $this->_zen->formatName($value,1);\n return $this->_zen->ffv($name,$field['num_cols']);\n case \"tested\":\n case \"approved\":\n $val = $value == 1? tr('Required') : ($value == 2? tr('Complete') : tr('n/a'));\n return $this->_zen->ffv($val,$field['num_cols']);\n case \"otime\":\n case \"ctime\":\n case \"deadline\":\n case \"start_date\":\n case \"custom_date\":\n if( preg_match('/[^0-9]/', $value) ) {\n return $this->_zen->ffv($value,$field['num_cols']);\n }\n if( $value == 'NULL' ) { $value = ''; }\n if( $value == 0 ) { $value = \"\"; }\n return $this->_zen->showDateTime($value);\n case \"custom_boolean\":\n $val = $value == 1? tr('Yes') : tr('No');\n return $this->_zen->ffv($val,$field['num_cols']);\n case \"details\":\n case \"title\":\n case \"custom_text\":\n return $this->_zen->ffvText($value);\n case \"custom_multi\":\n// return str_replace(\"\\t\", \"; \", $value);\n return implode($this->_zen->multisep, $value);\n default:\n $val = $this->_zen->ffvText(str_replace(\"\\t\",\";\",$value), $field['num_cols']);\n $this->_zen->addDebug(\"getTextValue\", \"rendering default: $val\", 3);\n return $val;\n }\n }\n // it's hidden, return nothing\n return '';\n }",
"public function getValue(): string\n {\n return $this->getText();\n }",
"public function getRichtextValue()\n {\n return $this->readOneof(8);\n }",
"public function render() {\n $result = $this->text;\n foreach($this->values as $name => $value) {\n// TTracer::Trace(\"adding value: $name = $value\");\n $token = sprintf('[value:%s]',$name);\n $result = str_replace($token,$value,$result);\n }\n return $result;\n }",
"public function getTextValue()\n\t{\n\t\treturn NULL;\n\t}",
"function print_text_2($value){\r\n\t\tif(isset($value['std'])) {\r\n\t\t\t$default = $value['std'];\r\n\t\t} else {\r\n\t\t\t$default = false;\r\n\t\t}\r\n\t\tif(isset($value['protected'][0][\"id\"])) {\r\n\t\t\t$protectedValue = $value['protected'][0][\"id\"];\r\n\t\t} else {\r\n\t\t\t$protectedValue = false;\r\n\t\t}\r\n\t\t\r\n\t\t$protected_value = $this->get_field_value($protectedValue, $default);\r\n\t\t\r\n\t\t\r\n\t\tif(((isset($value['protected'][0][\"id\"]) && $value['protected'][0][\"id\"]!=\"\") && $protected_value==$value['protected'][0][\"value\"]) || (!isset($value['protected'][0][\"id\"]))) {\r\n\r\n\t\t\t\r\n\t\t\techo '<div id=\"theme_documentation\" style=\"margin-bottom:10px;\">\r\n\t\t\t<div style=\"margin-left:0px; margin-right:25px;\">\r\n\t\t\t'.$value['text'].'\t\r\n\t\t\t</div>\t\t\t\t\t\t\t\t\r\n\t\t\t</div>';\r\n\t\t}\r\n\t}",
"public function fillAfterText($varValue, \\DataContainer $dc)\n\t{\n\t\tif(strip_tags($dc->activeRecord->after_text) == '')\n\t\t{\n\t\t if(strlen($varValue)<=0) return $varValue;\n\n //hole das ausgewähte Template\n $objTemplate = IaoTemplatesModel::findById($varValue);\n\n //hole den aktuellen Datensatz als DB-Object\n $objDbOffer = IaoInvoiceModel::findById($dc->id);\n\n\t\t\t$text = $this->changeIAOTags($objTemplate->text,'invoice',$objDbOffer);\n\n\t\t\t// schreibe das Textfeld\n $set =['after_text' => $text];\n\t\t\tDB::getInstance()->prepare('UPDATE `tl_iao_invoice` %s WHERE `id`=?')\n\t\t\t\t->set($set)\n ->limit(1)\n\t\t\t\t->execute($dc->id);\n\t\t}\n\t\treturn $varValue;\n\t}",
"function _parser_prepare_field_text(&$result, $field_info, $field_instance, $entity, $job, $base_url) {\n if ($field_instance['settings']['text_processing']) {\n if (is_string($result)) {\n $result = array('value' => $result);\n }\n if (empty($result['format'])) {\n $result['format'] = 'filtered_html';\n }\n $result_value = &$result['value'];\n }\n else {\n $result_value = &$result;\n }\n\n $result_value = trim($result_value);\n if (!empty($field_info['settings']['max_length']) && drupal_strlen($result_value) > $field_info['settings']['max_length']) {\n $original_result = $result_value;\n $result_value = drupal_substr($result_value, 0, $field_info['settings']['max_length']);\n _parser_watchdog('\n Обрезан текст в поле \"' . $field_info['field_name'] . '\":\n \"<i>' . check_plain($original_result) . '</i>\" =>\n \"<i>' . check_plain($result_value) . '</i>\".\n ');\n }\n}",
"public function text_field( $fpdf, $field_name, $value, $show_border, $align = 'L' ) {\n\n\t\tif ( $this->get_field_position( $field_name ) && $value ) {\n\n\t\t\t$font = $this->get_field_font( $field_name );\n\n\t\t\t// get the field position\n\t\t\tlist( $x, $y, $w, $h ) = array_map( array( $this, 'convert_pixels_to_points' ), array_values( $this->get_field_position( $field_name ) ) );\n\n\t\t\t// font color\n\t\t\t$font['color'] = $this->hex2rgb( $font['color'] );\n\t\t\t$fpdf->SetTextColor( $font['color'][0], $font['color'][1], $font['color'][2] );\n\n\t\t\t// set the field text styling\n\t\t\t$fpdf->SetFont( $font['family'], $font['style'], $font['size'] );\n\n\t\t\t// show a border for debugging purposes\n\t\t\tif ( $show_border ) {\n\t\t\t\t$fpdf->setXY( $x, $y );\n\t\t\t\t$fpdf->Cell( $w, $h, '', 1 );\n\t\t\t}\n\n\t\t\t// align the text to the bottom edge of the cell by translating as needed\n\t\t\t$y = $font['size'] > $h ? $y - ( $font['size'] - $h ) / 2 : $y + ( $h - $font['size'] ) / 2;\n\n\t\t\t// handle right/center justification, it's left-justified by default so nothing to do in that case\n\t\t\tif ( 'R' == $align ) {\n\t\t\t\t$x = max( 0, $x + ( $w - $fpdf->GetStringWidth( $value ) ) );\n\t\t\t} elseif ( 'C' == $align ) {\n\t\t\t\t$x = max( 0, $x + ( $w - $fpdf->GetStringWidth( $value ) ) / 2 );\n\t\t\t}\n\n\t\t\t$fpdf->setXY( $x, $y );\n\n\t\t\t// and write out the value\n\t\t\t$fpdf->Cell( $w, $h, utf8_decode( $value ) ); // can try iconv('UTF-8', 'windows-1252', $value); if this doesn't work correctly for accents\n\t\t}\n\t}",
"protected function loadMotivationText($value) {\n\t\t$text=[];\n\t\tif ($value >= 0) {\n\t\t\t$text[0]='';\n\t\t\t$text[1]='Gratulacje.';\n\t\t\t$text[2]='Świetnie zarządzasz finansami!';\n\t\t} else {\n\t\t\t$text[0]='color:red';\n\t\t\t$text[1]='Uważaj,';\n\t\t\t$text[2]='wpadasz w długi!';\n\t\t}\n\t\treturn $text;\n\t}",
"public function text($value) {\n return $this->setProperty('text', $value);\n }",
"public function text($value) {\n return $this->setProperty('text', $value);\n }",
"public function text($value) {\n return $this->setProperty('text', $value);\n }",
"public function text($value) {\n return $this->setProperty('text', $value);\n }",
"public function addText($value)\n {\n $this->setValue($value);\n }",
"public function text($value)\n {\n return $this->setProperty('text', $value);\n }",
"public function getText()\n {\n return $this->readOneof(2);\n }",
"function external_text( $field_value, $field ) {\n\t\t\n\t\tif ( empty($field_value) )\n\t\t\treturn 'Empty';\n\t\t\n\t\treturn $field_value['display_name'];\n\t}",
"public function asText()\n {\n return $this->getValue();\n }",
"function TextLine($value) {\n return $value . $this->LE;\n }",
"public function getText()\n {\n return $this->readOneof(1);\n }",
"public function asNtext($value)\n {\n if ($value === null || $value == '') {\n return null;\n }\n return nl2br(Html::encode($value));\n }",
"function print_add_text($value) {\r\n\t\tif(isset($value['std'])) {\r\n\t\t\t$default = $value['std'];\r\n\t\t} else {\r\n\t\t\t$default = false;\r\n\t\t}\r\n\t\tif(isset($value['protected'][0][\"id\"])) {\r\n\t\t\t$protectedValue = $value['protected'][0][\"id\"];\r\n\t\t} else {\r\n\t\t\t$protectedValue = false;\r\n\t\t}\r\n\t\t\r\n\t\t$protected_value = $this->get_field_value($protectedValue, $default);\r\n\t\t\r\n\t\tif(((isset($protectedValue) && $protectedValue!=\"\") && $protected_value==$value['protected'][0][\"value\"]) && $protected_value_1==$value['protected'][1][\"value\"] || ($protectedValue==false)) {\r\n\r\n\t\t\t$input_value = $this->get_field_value($value['id'], $default);\r\n\r\n\t\t?>\r\n\t\t<?php if( isset($value['home']) && $value['home'] == \"yes\" ) { ?><div class=\"input-item-full-width-inside clearfix\"><?php } else { ?>\r\n\t\t\t<div class=\"input-item-full-width clearfix\">\r\n\t\t<?php } ?>\r\n\t\t\t<label><?php echo $value['title'];?></label>\r\n\t\t\t<span class=\"input-text\"><input type=\"text\" name=\"<?php echo $value['id']; ?>\" /></span>\r\n\t\t<?php\r\n\t\t}\r\n\t\t$saved_value = get_option( $value['id'].'s' );\r\n\t\t$saved_value = stripslashes($saved_value);\r\n\r\n\t\techo '<input type=\"hidden\" name=\"'.$value['id'].'s\" id=\"'.$value['id'].'s\" value=\"'.$saved_value.'\" />';\r\n\t\t?>\r\n\t\t</div>\r\n\t\t<input type=\"hidden\" name=\"action\" value=\"save\" />\r\n\t\t<a href=\"javascript:{}\" onclick=\"document.getElementById('different-themes-options').submit(); return false;\" class=\"button-1\">Add</a>\r\n\t\t\t\r\n\t\t<?php\r\n\t}",
"public function asText($value)\n {\n if ($value === null || $value == '') {\n return null;\n }\n return Html::encode($value);\n }",
"public function getText($value)\n\t{\n\t\tif (!$item = $this->getItem($value))\n\t\t\treturn '';\n\n\t\treturn $item['text'];\n\t}"
] | [
"0.6912413",
"0.57821214",
"0.57462645",
"0.5695875",
"0.56863254",
"0.56611514",
"0.5603777",
"0.55880463",
"0.5585352",
"0.5574",
"0.55602336",
"0.5557107",
"0.5541209",
"0.54949373",
"0.54729027",
"0.54623264",
"0.54623264",
"0.54623264",
"0.54623264",
"0.54613096",
"0.545559",
"0.5397485",
"0.5392752",
"0.5374077",
"0.53679335",
"0.53636914",
"0.5356959",
"0.53540426",
"0.5354029",
"0.5353363"
] | 0.6649925 | 1 |
The history of this annotation. Generated from protobuf field .google.cloud.documentai.v1.Document.Provenance provenance = 8; | public function getProvenance()
{
return $this->provenance;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function setProvenance($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\DocumentAI\\V1\\Document\\Provenance::class);\n $this->provenance = $var;\n\n return $this;\n }",
"public function getEvidence() {\n return $this->evidence;\n }",
"public function getOccurrenceNote()\n {\n return $this->occurrence_note;\n }",
"public function getDocumentChange()\n {\n return $this->readOneof(3);\n }",
"public function setProof($var)\n {\n GPBUtil::checkMessage($var, \\Types\\EventProof::class);\n $this->proof = $var;\n\n return $this;\n }",
"public function generateProvenance(){\n \n\t$sparql_query = $this->_sparql_prefixes.'prefix globiclogservice: <http://localhost/globicLog/service/>\n\t \nINSERT DATA {\n GRAPH globiclogservice:'.$this->_component_named_graph.' {\n gic:'.$this->_component_name.' a gic:ContentProcessingComponent .\n ';\n \n if ( isset($this->_request_array['user']) ){\n\t $sparql_query = $sparql_query.'gic:'.$this->_request_array['user'].' a prov:Person .\n ';\n\t}\n \n for ($i=1; $i<=10; $i++){\n if ( isset($this->_request_array['contentConsumed'.$i]) ){\n\t $sparql_query = $sparql_query.$this->_request_array['contentConsumed'.$i].' a '.$this->_request_array['contentConsumed'.$i.'Type'].' .\n ';\n\t }\n }\n \n $sparql_query = $sparql_query.'gic:'.$this->_request_array['activity'].' a gic:'.$this->_actual_activity.' ;\n prov:wasAssociatedWith gic:'.$this->_component_name.' ;\n ';\n \n if ( isset($this->_request_array['user']) ){\n\t $sparql_query = $sparql_query.' prov:wasAssociatedWith gic:'.$this->_request_array['user'].' ;\n\t ';\n\t}\n \n for ($i=1; $i<=10; $i++){\n if ( isset($this->_request_array['contentConsumed'.$i]) ){\n\t $sparql_query = $sparql_query.' gic:contentConsumed '.$this->_request_array['contentConsumed'.$i].' ;\n ';\n\t }\n }\n\t\n\t$sparql_query = $sparql_query.' prov:startedAtTime \"'.date('c', time()).'\"^^xsd:dateTime .\n';\n\t \n\tfor ($i=1; $i<=10; $i++){\n if ( isset($this->_request_array['contentGenerated'.$i]) ){\n\t $sparql_query = $sparql_query.' '.$this->_request_array['contentGenerated'.$i].' a '.$this->_request_array['contentGenerated'.$i.'Type'].' ;\n\t gic:contentGeneratedBy gic:'.$this->_request_array['activity'].' ; \n\t ';\n\t \n\t for ($ii=1; $ii<=10; $ii++){\n\t\t if ( isset($this->_request_array['contentConsumed'.$ii]) ){\n\t\t $sparql_query = $sparql_query.'prov:wasDerivedFrom '.$this->_request_array['contentConsumed'.$ii].' ;\n\t ';\n\t\t }\n\t\t }\n\t \n\t $sparql_query = $sparql_query.'prov:generatedAtTime \"'.date('c', time()).'\"^^xsd:dateTime .\n ';\n\t }\n }\n\t\n\t$sparql_query = $sparql_query.'}\n}';\n \n \n\t// Create fuseki update file\n\t$filepath1 = $_SERVER['DOCUMENT_ROOT'].\"/globicLog/service/temp/update\".$this->_request_array['component_id'].\".ru\";\n\t$file1 = fopen($filepath1,\"w\") or exit(\"Unable to open file!\");\n\tfwrite($file1, $sparql_query);\n\tfclose($file1);\n\t\n\t// Execute update query\n\tshell_exec('@ECHO OFF & cd C:\\DB_Server\\jena-fuseki-0.2.7 && ruby s-update --service http://localhost:3030/Test/update --update='.$filepath1);\n\n\t// Delete temp files\n\tunlink($filepath1);\n\t\n\t// Write to activity log\n\t$this->activityLog(false);\n }",
"public function getProof()\n {\n return $this->proof;\n }",
"public function getPrenote() {\n\t\treturn $this->prenote;\n\t}",
"public function noteCurrent()\n {\n return $this->historyCurrent()->note ?? null;\n }",
"public function getNewRemarks()\n\t{\n\t\treturn $this->new_remarks;\n\t}",
"public function getVehicleActivityNote()\n {\n return $this->vehicleActivityNote;\n }",
"private function linkDocumentsToProvenance($provenanceUri, $documents) {\n $documentModel = new YiiDocumentModel(null, null);\n\n // associated documents update\n foreach ($documents as $documentURI) {\n $documentModel = new YiiDocumentModel(null, null);\n $documentModel->findByURI(Yii::$app->session['access_token'], $documentURI);\n $documentModel->status = \"linked\";\n $concernedItem = new YiiConcernedItemModel();\n $concernedItem->uri = $provenanceUri;\n $concernedItem->rdfType = Yii::$app->params[\"Provenance\"];\n $documentModel->concernedItems = [$concernedItem];\n $dataToSend[] = $documentModel->attributesToArray();\n }\n\n if (isset($dataToSend)) {\n $requestRes = $documentModel->update(Yii::$app->session['access_token'], $dataToSend);\n\n if (is_string($requestRes) && $requestRes === \"token\") {\n return false;\n } else {\n return true;\n }\n } else {\n return true;\n }\n }",
"public function getPreviousDocumentState()\n {\n return $this->get(self::PREVIOUSDOCUMENTSTATE);\n }",
"public function getAuditMessage()\n {\n return $this->readOneof(12);\n }",
"function getSourceRevision() {\n\t\treturn $this->getData('sourceRevision');\n\t}",
"public function getNewMetadata() {\n return $this->_new_metadata;\n }",
"public function getNewMetadata() {\n return $this->_new_metadata;\n }",
"public function __toString()\n {\n if (null === $this->metadata) {\n $this->metadata = new \\Pop\\Pdf\\Document\\Metadata();\n }\n\n // Set the CreationDate and the ModDate if they are null.\n if (null === $this->metadata->getCreationDate()) {\n $this->metadata->setCreationDate(date('D, M j, Y h:i A'));\n }\n if (null === $this->metadata->getModDate()) {\n $this->metadata->setModDate(date('D, M j, Y h:i A'));\n }\n\n return str_replace(\n [\n '[{info_index}]', '[{title}]', '[{subject}]', '[{author}]',\n '[{creator}]', '[{producer}]', '[{mod_date}]', '[{creation_date}]'\n ],\n [\n $this->index, $this->metadata->getTitle(), $this->metadata->getSubject(), $this->metadata->getAuthor(),\n $this->metadata->getCreator(), $this->metadata->getProducer(), $this->metadata->getModDate(), $this->metadata->getCreationDate()\n ],\n $this->data\n );\n }",
"public function getLastRevisionSummary() {\n $revision = $this->getLastRevision();\n return $revision->getEditInfo()->getSummary();\n }",
"public function getProofs()\n {\n return $this->proofs;\n }",
"public function note()\n {\n return $this->hasOne(ProfessionalNote::class, 'ProfessionalID', 'Id')->withDefault([\n 'id' => '00000000-0000-0000-0000-000000000000',\n ]);\n }",
"public function getTranscript()\n {\n return $this->readOneof(3);\n }",
"function getNote() {\n return $this->getFieldValue('note');\n }",
"public function getRevision()\n {\n return $this->_content['_rev'];\n }",
"public function getNote() {\n return $this->note;\n }",
"public function getAffectations()\n {\n return $this->affectations;\n }",
"public function getNote()\n {\n return $this->note;\n }",
"public function getNote()\n {\n return $this->note;\n }",
"public function getNote()\n {\n return $this->note;\n }",
"public function getNote()\n {\n return $this->note;\n }"
] | [
"0.7434463",
"0.54677725",
"0.4714935",
"0.46878436",
"0.45440283",
"0.45029497",
"0.44484034",
"0.4408057",
"0.43396524",
"0.42402542",
"0.42346796",
"0.41571218",
"0.4144633",
"0.4135232",
"0.40922365",
"0.40829277",
"0.40829277",
"0.407966",
"0.4070717",
"0.40659073",
"0.40587404",
"0.40410516",
"0.40264475",
"0.4023911",
"0.4002989",
"0.4002403",
"0.3998507",
"0.3998507",
"0.3998507",
"0.3998507"
] | 0.7295494 | 1 |
The history of this annotation. Generated from protobuf field .google.cloud.documentai.v1.Document.Provenance provenance = 8; | public function setProvenance($var)
{
GPBUtil::checkMessage($var, \Google\Cloud\DocumentAI\V1\Document\Provenance::class);
$this->provenance = $var;
return $this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getProvenance()\n {\n return $this->provenance;\n }",
"public function getEvidence() {\n return $this->evidence;\n }",
"public function getOccurrenceNote()\n {\n return $this->occurrence_note;\n }",
"public function getDocumentChange()\n {\n return $this->readOneof(3);\n }",
"public function setProof($var)\n {\n GPBUtil::checkMessage($var, \\Types\\EventProof::class);\n $this->proof = $var;\n\n return $this;\n }",
"public function generateProvenance(){\n \n\t$sparql_query = $this->_sparql_prefixes.'prefix globiclogservice: <http://localhost/globicLog/service/>\n\t \nINSERT DATA {\n GRAPH globiclogservice:'.$this->_component_named_graph.' {\n gic:'.$this->_component_name.' a gic:ContentProcessingComponent .\n ';\n \n if ( isset($this->_request_array['user']) ){\n\t $sparql_query = $sparql_query.'gic:'.$this->_request_array['user'].' a prov:Person .\n ';\n\t}\n \n for ($i=1; $i<=10; $i++){\n if ( isset($this->_request_array['contentConsumed'.$i]) ){\n\t $sparql_query = $sparql_query.$this->_request_array['contentConsumed'.$i].' a '.$this->_request_array['contentConsumed'.$i.'Type'].' .\n ';\n\t }\n }\n \n $sparql_query = $sparql_query.'gic:'.$this->_request_array['activity'].' a gic:'.$this->_actual_activity.' ;\n prov:wasAssociatedWith gic:'.$this->_component_name.' ;\n ';\n \n if ( isset($this->_request_array['user']) ){\n\t $sparql_query = $sparql_query.' prov:wasAssociatedWith gic:'.$this->_request_array['user'].' ;\n\t ';\n\t}\n \n for ($i=1; $i<=10; $i++){\n if ( isset($this->_request_array['contentConsumed'.$i]) ){\n\t $sparql_query = $sparql_query.' gic:contentConsumed '.$this->_request_array['contentConsumed'.$i].' ;\n ';\n\t }\n }\n\t\n\t$sparql_query = $sparql_query.' prov:startedAtTime \"'.date('c', time()).'\"^^xsd:dateTime .\n';\n\t \n\tfor ($i=1; $i<=10; $i++){\n if ( isset($this->_request_array['contentGenerated'.$i]) ){\n\t $sparql_query = $sparql_query.' '.$this->_request_array['contentGenerated'.$i].' a '.$this->_request_array['contentGenerated'.$i.'Type'].' ;\n\t gic:contentGeneratedBy gic:'.$this->_request_array['activity'].' ; \n\t ';\n\t \n\t for ($ii=1; $ii<=10; $ii++){\n\t\t if ( isset($this->_request_array['contentConsumed'.$ii]) ){\n\t\t $sparql_query = $sparql_query.'prov:wasDerivedFrom '.$this->_request_array['contentConsumed'.$ii].' ;\n\t ';\n\t\t }\n\t\t }\n\t \n\t $sparql_query = $sparql_query.'prov:generatedAtTime \"'.date('c', time()).'\"^^xsd:dateTime .\n ';\n\t }\n }\n\t\n\t$sparql_query = $sparql_query.'}\n}';\n \n \n\t// Create fuseki update file\n\t$filepath1 = $_SERVER['DOCUMENT_ROOT'].\"/globicLog/service/temp/update\".$this->_request_array['component_id'].\".ru\";\n\t$file1 = fopen($filepath1,\"w\") or exit(\"Unable to open file!\");\n\tfwrite($file1, $sparql_query);\n\tfclose($file1);\n\t\n\t// Execute update query\n\tshell_exec('@ECHO OFF & cd C:\\DB_Server\\jena-fuseki-0.2.7 && ruby s-update --service http://localhost:3030/Test/update --update='.$filepath1);\n\n\t// Delete temp files\n\tunlink($filepath1);\n\t\n\t// Write to activity log\n\t$this->activityLog(false);\n }",
"public function getProof()\n {\n return $this->proof;\n }",
"public function getPrenote() {\n\t\treturn $this->prenote;\n\t}",
"public function noteCurrent()\n {\n return $this->historyCurrent()->note ?? null;\n }",
"public function getNewRemarks()\n\t{\n\t\treturn $this->new_remarks;\n\t}",
"public function getVehicleActivityNote()\n {\n return $this->vehicleActivityNote;\n }",
"private function linkDocumentsToProvenance($provenanceUri, $documents) {\n $documentModel = new YiiDocumentModel(null, null);\n\n // associated documents update\n foreach ($documents as $documentURI) {\n $documentModel = new YiiDocumentModel(null, null);\n $documentModel->findByURI(Yii::$app->session['access_token'], $documentURI);\n $documentModel->status = \"linked\";\n $concernedItem = new YiiConcernedItemModel();\n $concernedItem->uri = $provenanceUri;\n $concernedItem->rdfType = Yii::$app->params[\"Provenance\"];\n $documentModel->concernedItems = [$concernedItem];\n $dataToSend[] = $documentModel->attributesToArray();\n }\n\n if (isset($dataToSend)) {\n $requestRes = $documentModel->update(Yii::$app->session['access_token'], $dataToSend);\n\n if (is_string($requestRes) && $requestRes === \"token\") {\n return false;\n } else {\n return true;\n }\n } else {\n return true;\n }\n }",
"public function getPreviousDocumentState()\n {\n return $this->get(self::PREVIOUSDOCUMENTSTATE);\n }",
"public function getAuditMessage()\n {\n return $this->readOneof(12);\n }",
"function getSourceRevision() {\n\t\treturn $this->getData('sourceRevision');\n\t}",
"public function getNewMetadata() {\n return $this->_new_metadata;\n }",
"public function getNewMetadata() {\n return $this->_new_metadata;\n }",
"public function __toString()\n {\n if (null === $this->metadata) {\n $this->metadata = new \\Pop\\Pdf\\Document\\Metadata();\n }\n\n // Set the CreationDate and the ModDate if they are null.\n if (null === $this->metadata->getCreationDate()) {\n $this->metadata->setCreationDate(date('D, M j, Y h:i A'));\n }\n if (null === $this->metadata->getModDate()) {\n $this->metadata->setModDate(date('D, M j, Y h:i A'));\n }\n\n return str_replace(\n [\n '[{info_index}]', '[{title}]', '[{subject}]', '[{author}]',\n '[{creator}]', '[{producer}]', '[{mod_date}]', '[{creation_date}]'\n ],\n [\n $this->index, $this->metadata->getTitle(), $this->metadata->getSubject(), $this->metadata->getAuthor(),\n $this->metadata->getCreator(), $this->metadata->getProducer(), $this->metadata->getModDate(), $this->metadata->getCreationDate()\n ],\n $this->data\n );\n }",
"public function getLastRevisionSummary() {\n $revision = $this->getLastRevision();\n return $revision->getEditInfo()->getSummary();\n }",
"public function getProofs()\n {\n return $this->proofs;\n }",
"public function note()\n {\n return $this->hasOne(ProfessionalNote::class, 'ProfessionalID', 'Id')->withDefault([\n 'id' => '00000000-0000-0000-0000-000000000000',\n ]);\n }",
"public function getTranscript()\n {\n return $this->readOneof(3);\n }",
"function getNote() {\n return $this->getFieldValue('note');\n }",
"public function getRevision()\n {\n return $this->_content['_rev'];\n }",
"public function getNote() {\n return $this->note;\n }",
"public function getAffectations()\n {\n return $this->affectations;\n }",
"public function getNote()\n {\n return $this->note;\n }",
"public function getNote()\n {\n return $this->note;\n }",
"public function getNote()\n {\n return $this->note;\n }",
"public function getNote()\n {\n return $this->note;\n }"
] | [
"0.72941965",
"0.54650533",
"0.47159848",
"0.46882534",
"0.45435205",
"0.4501921",
"0.4448067",
"0.44110715",
"0.43417758",
"0.42423666",
"0.42351314",
"0.41558555",
"0.4146415",
"0.41351214",
"0.4091983",
"0.40852442",
"0.40852442",
"0.40816885",
"0.4070584",
"0.40675774",
"0.40608418",
"0.40408608",
"0.40276676",
"0.40234372",
"0.40044007",
"0.40013677",
"0.3999899",
"0.3999899",
"0.3999899",
"0.3999899"
] | 0.7431672 | 0 |
Gets the Type of Instant Message Service. | public function getInstantMessagingType()
{
return $this->instantMessagingType;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getInstantMessagingTypeEnum() {\n\t\t\treturn $this->instantMessagingTypeEnum;\n\t\t}",
"public function getServiceType()\n\t{\n\t\treturn $this->_service_type;\n\t}",
"public function getInstanceType()\n {\n return $this->_type;\n }",
"public function getServiceTypeId() {\n\t\treturn $this->_serviceTypeId;\n\t}",
"public function getMessageType() {\n return $this->messageType;\n }",
"public function getMessageType()\n {\n return $this->messageType;\n }",
"public function type() {\n return eventsign_type_load($this->type);\n }",
"public function getType(): string\n {\n $data = $this->getComposerData();\n return $data['type'] ?? '';\n }",
"public function getType()\n {\n return $this->get(self::TYPE);\n }",
"public function getType()\n {\n return $this->get(self::TYPE);\n }",
"public function getType()\n {\n return $this->get(self::TYPE);\n }",
"public function getType()\n {\n return $this->get(self::TYPE);\n }",
"public function getType()\n {\n return $this->get(self::TYPE);\n }",
"public function getType() \n\t{\n\t\treturn self::TYPE;\n\t}",
"public function getType() {\n\t\treturn $this->get('type');\n\t}",
"public function getType()\n {\n return $this->get('type');\n }",
"public function getType()\n {\n return static::TYPE;\n }",
"public function getMessageType() {}",
"public static function getType() {\n\t\t$type = get_called_class();\n\t\t$parts = explode('\\\\', $type);\n\t\tif(count($parts) > 1) {\n\t\t\treturn $parts[count($parts)-1];\n\t\t} else {\n\t\t\treturn $parts[0];\n\t\t}\n\t}",
"public function getType()\n {\n\n return $this->type;\n\n }",
"public function getMessageType()\n {\n return $this->header->getMessageType();\n }",
"protected function getType() {\n return $this->_type;\n }",
"public function getType()\n {\n return $this->type;\n }",
"public function getType()\n {\n return $this->type;\n }",
"public function getType()\n {\n return $this->type;\n }",
"public function getType()\n {\n return $this->type;\n }",
"public function getType()\n {\n return $this->type;\n }",
"public function getType()\n {\n return $this->type;\n }",
"public function getType()\n {\n return $this->type;\n }",
"public function getType()\n {\n return $this->type;\n }"
] | [
"0.6859605",
"0.67308664",
"0.6116617",
"0.6068186",
"0.58597636",
"0.5851467",
"0.57478184",
"0.57075834",
"0.56912446",
"0.56912446",
"0.56912446",
"0.56912446",
"0.56912446",
"0.5665423",
"0.55952644",
"0.5592338",
"0.5589224",
"0.55808115",
"0.55170214",
"0.55164695",
"0.5514977",
"0.5498839",
"0.54764885",
"0.54764885",
"0.54764885",
"0.54764885",
"0.54764885",
"0.54764885",
"0.54764885",
"0.54764885"
] | 0.7411617 | 0 |
Sets the Type of Instant Message Service. | public function setInstantMessagingType($instantMessagingType)
{
if(array_search($instantMessagingType, $this->instantMessagingTypeEnum, $strict = TRUE)) {
$this->instantMessagingType = $instantMessagingType;
} else {
$this->instantMessagingType = $this->instantMessagingTypeEnum[0];
}
return $this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getInstantMessagingType()\n\t\t{\n\t\t return $this->instantMessagingType;\n\t\t}",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"function setType($type) {\n $this->type = $type;\n }",
"public function setType($type) {\n \t$this->_type = $type;\n }",
"public function setType($type) {\n $this->type = $type;\n }",
"public function setType($type)\n {\n \n $this->type = $type;\n }",
"function setType($type) {\n\t\t$this->type = $type;\n\t}",
"function setType($type) {\n\t\t$this->type = $type;\n\t}",
"protected function setType($type) {\n $this->type = $type;\n }",
"private function _setServerType($type){\n\t\t\n\t\t$allowedTypes = array('mail', 'smtp');\n\t\t\n\t\tif (!in_array($type, $allowedTypes)){\n\t\t\tthrow new OwlException('OwlMailer: ' . $type . ' no es un tipo de servidor válido', 500);\n\t\t} else {\n\t\t\t$this->_serverType = $type;\n\t\t}\n\t\t\n\t}",
"function setType($type) {\r\r\n\t\t$this->type = $type;\r\r\n\t}",
"public function setType($type) {\n\t\t$this->type = $type;\n\t}",
"public function setType($type) {\n\t\t$this->type = $type;\n\t}",
"public function getInstantMessagingTypeEnum() {\n\t\t\treturn $this->instantMessagingTypeEnum;\n\t\t}"
] | [
"0.6133386",
"0.5953569",
"0.5953569",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.5914915",
"0.59069765",
"0.5862713",
"0.58539194",
"0.5851179",
"0.58404833",
"0.58404833",
"0.58359146",
"0.58292145",
"0.5826825",
"0.58149344",
"0.58149344",
"0.58111286"
] | 0.6813735 | 0 |
Convert Doctrine\ODM Document to Array | public function toArray()
{
$document = $this->toStdClass();
return get_object_vars($document);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function toArray()\n {\n return $this->document;\n }",
"public function toArray($document)\n {\n if ($this->isBSONModel($document)) {\n $document = $document->getArrayCopy();\n } elseif (!is_array($document)) {\n return $document;\n }\n\n $result = [];\n\n foreach ($document as $key => $value) {\n if ($this->isBSONModel($value)) {\n $value = $this->toArray($value->getArrayCopy());\n }\n\n $result[$key] = $value;\n }\n\n return $result;\n }",
"private function getDocArray($document)\n {\n if(!is_a($document, $this->className))\n throw new \\LogicException('Document should be of type ' . $this->className . ', got ' . get_class($document));\n return $document->toDocument();\n }",
"public function toArray(): array\n {\n return $this->getPersister()->getSerializer()->serialize($this->collectionObject);\n }",
"function bsonSerialize(): array\n {\n return [];\n }",
"public function toArray()\r\n\t{\r\n\t\t$tags = [];\r\n\t\tforeach($this->tags as $tag)\r\n\t\t\t$tags[] = $tag->toArray();\r\n\t\treturn ['_id' \t\t=> $this->id,\r\n\t\t\t\t'children' \t=> $this->children,\r\n\t\t\t\t'parents' \t=> $this->parents,\r\n\t\t\t\t'tags' \t\t=> $tags,\r\n\t\t\t\t'type'\t\t=> $this->type,\r\n\t\t\t\t];\r\n\t}",
"public function __toArray();",
"public function toArray(): array\n {\n $edges = [];\n foreach ($this->getEdgeDefinitions()->toArray() as $edge) {\n $edges[] = $edge->toArray();\n }\n\n return [\n '_id' => $this->getId(),\n '_key' => $this->getKey(),\n '_rev' => $this->getRevision(),\n 'name' => $this->getName(),\n 'isSmart' => $this->isSmart(),\n 'edgeDefinitions' => $edges,\n 'orphanCollections' => $this->getOrphanCollections(),\n 'options' => [\n 'numberOfShards' => $this->getNumberOfShards(),\n 'replicationFactor' => $this->getReplicationFactor(),\n 'minReplicationFactor' => $this->getMinReplicationFactor(),\n ]\n ];\n }",
"public function __toArray(): array;",
"public function toArray(): array\n {\n return $this->toCollection()->toArray();\n }",
"public function toArray() {\n $a = parent::toArray();\n if( $this->text ) {\n $a[\"text\"] = $this->text;\n }\n if( $this->created ) {\n $a[\"created\"] = $this->created;\n }\n if( $this->contributor ) {\n $a[\"contributor\"] = $this->contributor->toArray();\n }\n return $a;\n }",
"public function toArray()\n {\n return $this->collection->toArray();\n }",
"public function toArray()\n {\n return $this->content()->toArray();\n }",
"public function convertDocumentToAttributes(stdClass $document, array $options) {\r\n return (array)$document;\r\n }",
"public function result($as_object = TRUE)\n {\n $result = array();\n try {\n foreach ($this->_cursor as $doc) {\n $result[] = $as_object ? $this->_array_to_object($doc) : $doc;\n }\n } catch (Exception $exception) {\n return $this->_handle_exception($exception->getMessage(), $as_object);\n }\n return $result;\n\n }",
"public function _cast()\n {\n return $this->toArray();\n }",
"public function toArray(): array\n {\n /** @var Collection $collection */\n $collection = $this->collection->map->toArray();\n return $collection->all();\n }",
"public function toArray($object): array;",
"public function toArray()\n {\n return array_map(function($value){\n if ($value instanceof Entity || $value instanceof Collection) {\n return $value->toArray();\n }\n\n return $value;\n }, $this->properties);\n }",
"public function toArray(): array\n {\n return array_map(static function ($value) {\n return ($value instanceof AbstractEntity || $value instanceof EntityCollectionInterface) ? $value->toArray() : $value;\n }, $this->data);\n }",
"public function toArray()\n {\n $result = [];\n foreach ($this->_properties as $property => $value) {\n if (is_array($value) or $value instanceof Collection) {\n foreach ($value as $k => $v) {\n if ($v instanceof Entity) {\n $result[$property][$k] = $v->toArray();\n }\n }\n continue;\n }\n if ($value instanceof Entity) {\n $value = $value->toArray();\n }\n $result[$property] = $value;\n }\n\n return $result;\n }",
"abstract function __toArray();",
"abstract protected function convertDocument(array $raw);",
"public function convert(object $object): array;",
"public function toArray();",
"public function toArray();",
"public function toArray();",
"public function toArray();",
"public function toArray();",
"public function toArray();"
] | [
"0.7536569",
"0.7341951",
"0.68863225",
"0.64977634",
"0.64934635",
"0.6488712",
"0.6482302",
"0.6475615",
"0.64036334",
"0.639875",
"0.6384963",
"0.63415766",
"0.63151693",
"0.62708014",
"0.6270346",
"0.62524045",
"0.62394387",
"0.62314016",
"0.62309587",
"0.6230451",
"0.62234336",
"0.6215637",
"0.61949736",
"0.61587846",
"0.61554086",
"0.61554086",
"0.61554086",
"0.61554086",
"0.61554086",
"0.61554086"
] | 0.73659706 | 1 |
Lists all Langage entities. | public function indexAction()
{
$em = $this->getDoctrine()->getManager();
$langages = $em->getRepository('FormationBundle:Langage')->findAll();
return $this->render('FormationBundle:langage:index.html.twig', array(
'langages' => $langages,
));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function listAction()\n {\n \t$languages = new Languages();\n \t$this->view->languages = $languages->getAll();\n }",
"public function listlang()\r\n {\r\n $getLang = new Model_DbTable_Language();\r\n \r\n $lang = $getLang->getAllLang();\r\n \r\n \r\n return $lang;\r\n \r\n }",
"public function actionLangList()\n {\n $searchModel = new CttStaticdataAffiliationsSearch();\n $dataProvider = $searchModel->searchLangList(Yii::$app->request->queryParams);\n\n // GlobalVariable::fetchData();\n\n return $this->render('lang_list', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }",
"public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n $langues = $em->getRepository('MovibeBackendBundle:Langue')->findAll();\n $pagination = $this->pagination($langues,1000);\n\n $pages = array();\n $pages['Langues'] = \"movibe_backend_langue\";\n $this->breadcrumb($pages);\n\n return $this->render('MovibeBackendBundle:Langue:index.html.twig', array(\n 'langues' => $pagination,\n ));\n }",
"public static function listLanguages()\r\n {\r\n static $data=array();\r\n \r\n if(empty($data))\r\n {\r\n $data = self::model()->findAll(array('order'=>'title_native', 'condition'=>'published=1'));\r\n }\r\n \r\n return $data;\r\n }",
"public function getAllLocale(): Collection\n {\n return $this->repository->all();\n }",
"public static function getAll() {\n\tself::create();\n\treturn self::$instance->languages;\n }",
"function listaAll() {\n require ROOT . \"config/bootstrap.php\";\n return $em->getRepository('models\\Cabos')->findby(array(), array(\"id\" => \"DESC\"));\n $em->flush();\n }",
"private function getLanguages()\n {\n return Language::find()->select(['id', 'code'])->orderBy(['default' => SORT_DESC, 'id' => SORT_DESC])->asArray()->all();\n }",
"public function getAllLanguages($id);",
"public function index()\n {\n return Locale::all();\n }",
"function availableLangs() {\n $objLang = new Language();\n //$conditions = $this->Access->isAdmin() ? array() : array('visible' => 1);\n $conditions = array();\n return $objLang->find('list', array('conditions' => $conditions));\n }",
"protected function get_all_languages(){\n $this->languages = array();\n $i = 1;\n $this->languages['en'] = (object)array('id'=>$i++, 'name'=>'english', url=>'/en/');\n $this->languages['fr'] = (object)array('id'=>$i++, 'name'=>'francais', url=>'/fr/');\n $this->languages['nl'] = \n (object)array('id'=>$i++, 'name'=>'nederlands', url=>'/nl/');\n $this->languages['de'] = (object)array('id'=>$i++, 'name'=>'deutsch', url=>'/de/');\n }",
"public function getAllAgencesAction( ){\r\n\t\t\r\n\t\t $em = $this->getDoctrine()->getManager();\r\n\r\n $entities = $em->getRepository('ComDaufinBundle:Agence')->findAll();\r\n\r\n $response = array(\"agences\" => $entities,);\r\n \r\n \r\n return $response;\r\n\t}",
"function listaAll() {\n require ROOT . \"config/bootstrap.php\";\n return $em->getRepository('models\\Usuarios')->findby(array(), array(\"id\" => \"DESC\"));\n $em->flush();\n }",
"public function indexAction() {\n $em = $this->getDoctrine()->getManager();\n $request = $this->getRequest();\n $session = $request->getSession();\n $session->set('buttonretour', 'absences');\n $entities = $em->getRepository('ApplicationRelationsBundle:ChronoAbsences')->myFindAll();\n $paginator = $this->get('knp_paginator');\n $pagination = $paginator->paginate(\n $entities, $this->get('request')->query->get('page', 1)/* page number */, 15/* limit per page */\n );\n $pagination->setSortableTemplate('ApplicationRelationsBundle:pagination:sortable_link.html.twig');\n $pagination->setTemplate('ApplicationRelationsBundle:pagination:sliding.html.twig');\n return $this->render('ApplicationRelationsBundle:ChronoAbsences:index.html.twig', array(\n 'pagination' => $pagination,\n ));\n }",
"public function indexAction() {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $em->getRepository('ThesisBulletinBundle:College')->findAll();\n\n return array(\n 'entities' => $entities,\n );\n }",
"protected function getAllLanguages()\r\n {\r\n if (!isset($this->_languages))\r\n {\r\n $sql = 'SELECT * FROM emb_language';\r\n $rows = Yii::app()->db->createCommand($sql)->queryAll();\r\n\r\n $menuLanguages = array();\r\n $menuitemLanguages = array();\r\n foreach ($rows as $row)\r\n {\r\n if (!empty($row['itemid']))\r\n {\r\n if (!isset($menuitemLanguages[$row['itemid']]))\r\n $menuitemLanguages[$row['itemid']] = array(EMBConst::DB_LANGUAGETYPE_MENUITEMLABEL => array(), EMBConst::DB_LANGUAGETYPE_MENUITEMDESCRIPTION => array());\r\n\r\n $menuitemLanguages[$row['itemid']][$row['type']][$row['language']] = $row['text'];\r\n } else\r\n if (!empty($row['menuid']))\r\n {\r\n if (!isset($menuLanguages[$row['menuid']]))\r\n $menuLanguages[$row['menuid']] = array(EMBConst::DB_LANGUAGETYPE_MENUTITLE => array(), EMBConst::DB_LANGUAGETYPE_MENUDESCRIPTION => array());\r\n\r\n $menuLanguages[$row['menuid']][$row['type']][$row['language']] = $row['text'];\r\n }\r\n }\r\n\r\n $this->_languages = array('menu' => $menuLanguages, 'menuitem' => $menuitemLanguages);\r\n\r\n }\r\n\r\n return $this->_languages;\r\n }",
"private function _getLanguagesList() {\n $languages = CHtml::listData(Language::model()->findAll(), 'id', 'name');\n \n return $languages;\n }",
"public function all() {\n\n return $this->languages;\n\n }",
"public function languagesAction()\n {\n // action body\n $this->view->languages = Extended\\user_languages::getAllLanguages( Auth_UserAdapter::getIdentity()->getId() );\n\n }",
"public function allTranslations() {\n return $this->source\n ->select('languages.slug as locale', 'translations.*')\n ->join('languages', 'languages.id', '=','translations.language_id')\n ->get();\n }",
"public function getEntityList();",
"public function allAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $em->getRepository('TireBundle:Record')->findAll();\n\n return array(\n 'entities' => $entities,\n 'all' => 1\n );\n }",
"public function getAll()\n {\n return $this->entity->all();\n }",
"private function _getLanguagesList() {\n $languages = CHtml::listData(Language::model()->findAll(), 'id', 'name');\n\n return $languages;\n }",
"public static function all()\n {\n return GetEntity::all( self::getTableName() );\n }",
"public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $em->getRepository('AdminMenuBundle:Menu')->findAll();\n\n return ['entities' => $entities];\n }",
"public function fetch_langs () {\n try { $langs = $this->Database->getObjects(\"lang\", \"l_id\"); }\n catch (Exception $e) {\n $this->Result->show(\"danger\", _(\"Error: \").$e->getMessage());\n return false;\n }\n # return\n return $langs;\n }",
"public function getAll() {\n }"
] | [
"0.69950277",
"0.6730076",
"0.66084576",
"0.6522335",
"0.6508259",
"0.64342827",
"0.64208615",
"0.63898695",
"0.6311993",
"0.6303426",
"0.62906617",
"0.62306285",
"0.6222299",
"0.6220744",
"0.61731404",
"0.61057407",
"0.610177",
"0.60846156",
"0.6060306",
"0.6059727",
"0.60514444",
"0.60430384",
"0.6037072",
"0.6035936",
"0.6030164",
"0.60267955",
"0.5997002",
"0.59959424",
"0.5989095",
"0.5985302"
] | 0.7189643 | 0 |
Creates a new Langage entity. | public function newAction(Request $request)
{
$langage = new Langage();
$form = $this->createForm('FormationBundle\Form\LangageType', $langage);
$form->handleRequest($request);
if ($form->isSubmitted() && $form->isValid()) {
$em = $this->getDoctrine()->getManager();
$em->persist($langage);
$em->flush();
return $this->redirectToRoute('langage_index', array('id' => $langage->getId()));
}
return $this->render('FormationBundle:langage:new.html.twig', array(
'langage' => $langage,
'form' => $form->createView(),
));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function createAction(Request $request)\n {\n $langue = new Langue();\n\n $form = $this->createCreateForm($langue);\n $form->handleRequest($request);\n\n if ($form->isValid()) {\n $em = $this->getDoctrine()->getManager();\n $em->persist($langue);\n $em->flush();\n\n $request->getSession()->getFlashbag()->add('message','Une nouvelle langue a été créée');\n\n return $this->redirect($this->generateUrl('movibe_backend_langue_show', array('id' => $langue->getId())));\n }\n\n return $this->render('MovibeBackendBundle:Langue:new.html.twig', array(\n 'langue' => $langue,\n 'form' => $form->createView(),\n ));\n }",
"public function create($data)\n {\n return Language::create($data);\n }",
"private function getNewLanguage()\n {\n $language = new \\Application\\Entity\\Language();\n return $language;\n }",
"public function newAction()\n {\n $langue = new Langue();\n\n $form = $this->createCreateForm($langue);\n\n $pages = array();\n $pages['Langues'] = \"movibe_backend_langue\";\n $pages['Ajout'] = \"\";\n $this->breadcrumb($pages);\n\n return $this->render('MovibeBackendBundle:Langue:new.html.twig', array(\n 'langue' => $langue,\n 'form' => $form->createView(),\n ));\n }",
"public function store(CreateLangRequest $request)\n {\n $input = $request->all();\n\n $lang = $this->langRepository->create($input);\n\n return $this->success(__('crud.add_success'));\n }",
"public function actionCreate()\n\t{\n $model = new CoreLanguages();\n\n if (Yii::$app->request->isPost) {\n $model->load(Yii::$app->request->post());\n // $postData = Yii::$app->request->post();\n // $model->load($postData);\n // $model->order = $postData['order'] ? $postData['order'] : 0;\n\n if ($model->save()) {\n Yii::$app->session->setFlash('success', Yii::t('app', 'Language success created.'));\n return $this->redirect(['manage']);\n //return $this->redirect(['view', 'id' => $model->language_id]);\n\n } else {\n if (Yii::$app->request->isAjax) {\n return \\yii\\helpers\\Json::encode(\\app\\components\\widgets\\ActiveForm::validate($model));\n }\n }\n }\n\n\t\t$this->view->title = Yii::t('app', 'Create Language');\n\t\t$this->view->description = '';\n\t\t$this->view->keywords = '';\n\t\treturn $this->render('admin_create', [\n\t\t\t'model' => $model,\n\t\t]);\n\t}",
"public function create()\n {\n return view('translation.create_language');\n }",
"public function actionCreate()\n {\n $model = new Letter();\n\n $languages = HdbkLanguage::getLanguagesSymbols();\n $items = ArrayHelper::map($languages,'id','name');\n $curr_lang = Letter::formatLangCode(Yii::$app->language, $languages);\n $items = $curr_lang + $items;\n\n $request = Yii::$app->request->get();\n $oldModel = isset($request['translated_id']) ? Letter::findOne($request['translated_id']) : null;\n $translateLang = isset($request['translate_to']) ? Letter::formatLangCode($request['translate_to'], $languages) : null;\n $translateRow = $oldModel && $translateLang ? BlogMapEntityLang::getTranslationLetterRow($oldModel->id, $oldModel->lang->code) : null;\n $translate = isset($request['translate_to']) && !$translateRow[$request['translate_to']] && $oldModel && $translateLang;\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n return $this->render('create', [\n 'model' => $model,\n 'items' => $items,\n 'currLang' => $translateLang,\n 'translate' => $translate,\n 'translateRow' => $translateRow,\n 'oldModel' => $oldModel,\n ]);\n }\n }",
"public function create()\n {\n return view('backend.translation-language.create');\n }",
"public function store(Request $request) {\n\n $this->validate($request,[\n 'name' => 'required|alpha|max:25|unique:translations',\n 'code' => 'required|alpha|max:5|unique:translations',\n 'locale' => 'required|alpha|max:5|unique:translations',\n 'image' => 'max:20|unique:translations',\n 'order' => 'required|digits_between:1,4|unique:translations',\n ]);\n\n Language::create([\n 'name' => $request->get('name'),\n 'code' => $request->get('code'),\n 'locale' => $request->get('locale'),\n 'image' => $request->get('image'),\n 'order' => $request->get('order'),\n 'status' => $request->get('status'),\n ]);\n\n return redirect('/admin/language')->with('success', Lang::get('messages.page_added', ['page' => 'Language']));\n }",
"public function create()\n {\n return view('language_create');\n }",
"public function create()\n {\n return view('languages.create');\n }",
"public function create()\n {\n $language = Language::all();\n return view('admin.language.create', compact('language'));\n }",
"public function create()\n {\n $languages = Language::all();\n return view('new')->with(['languages' => $languages]);\n }",
"public function store(Request $request)\n {\n Language::create($request->all());\n\n return redirect('languages')->with('flash_message', 'Language has been created!');\n }",
"public function create(Request $request)\n {\n $language = Language::newDefaultLanguage();\n \n // authorize\n if (\\Gate::denies('create', $language)) {\n return $this->notAuthorized();\n }\n\n return view('admin.languages.create', [\n 'language' => $language,\n ]);\n }",
"public function create()\n {\n return view('pages.language.addlanguage');\n }",
"public function create()\n {\n return view('admin.language.create');\n }",
"public function create()\n\t{\n\t\t$langs = Lang::activelangs()->get();\n\t\treturn view('backend.langs.edit',[\n\t\t\t'langs'=>$langs,\n\t\t\t'action_method' => 'post',\n\t\t]);\n\t}",
"public function createAction(Request $request)\n {\n\n\n $em = $this->getDoctrine()->getManager();\n $languages = $em->getRepository('TigreboiteFunkylabBundle:Language')->findAll();\n\n $entity = new Pays();\n $form = $this->createCreateForm($entity);\n\n $form->handleRequest($request);\n\n if ($form->isValid()) {\n $em = $this->getDoctrine()->getManager();\n $em->persist($entity);\n $em->flush();\n\n $this->updateLanguageEntity($entity);\n\n return $this->redirect($this->generateUrl('admin_pays'));\n }\n\n return array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'ajax' => $request->isXmlHttpRequest(),\n 'languages' => $languages,\n );\n }",
"public function store(Request $request)\n {\n // authorize\n if (\\Gate::denies('create', Language::class)) {\n return $this->notAuthorized();\n }\n\n list($language, $validator) = Language::createFromRequest($request);\n\n if ($validator !== true) {\n return response()->view('admin.languages.create', [\n 'language' => $language,\n 'errors' => $validator->errors(),\n ], 400);\n }\n\n $request->session()->flash('alert-success', trans('messages.language.created'));\n return redirect()->action('Admin\\LanguageController@index');\n }",
"public function store(Request $request){\n $language = new Languages();\n $language->languageName = $request->addlanguage;\n $language->save();\n\n return redirect('languages');\n }",
"public static function create() {\n\tif (self::$instance == null) {\n\t self::$instance = new Language();\n\t}\n }",
"public function create()\r\n {\r\n echo $this->load->view('admin/languages/create', array(), TRUE);\r\n }",
"public function created(Language $language)\n {\n //\n }",
"public function postCreate( LanguageRequest $request )\n\t{\n\t\t$language = new Language();\n\t\t$language->user_id = Auth::id();\n\t\t$language->lang_code = $request->lang_code;\n\t\t$language->name = $request->name;\n\n\t\t$icon = \"\";\n\t\tif( Input::hasFile( 'icon' ) ) {\n\t\t\t$file = Input::file( 'icon' );\n\t\t\t$filename = $file->getClientOriginalName();\n\t\t\t$extension = $file->getClientOriginalExtension();\n\t\t\t$icon = sha1( $filename . time() ) . '.' . $extension;\n\t\t}\n\t\t$language->icon = $icon;\n\t\t$language->save();\n\n\t\tif( Input::hasFile( 'icon' ) ) {\n\t\t\t$destinationPath = public_path() . '/images/language/' . $language->id . '/';\n\t\t\tInput::file( 'icon' )->move( $destinationPath, $icon );\n\t\t}\n\t}",
"public function createAction()\n {\n $entity = new League();\n $entity->setOwner($this->getUser());\n $request = $this->getRequest();\n $form = $this->createForm(new LeagueType(), $entity);\n $form->bindRequest($request);\n\n if ($form->isValid()) {\n $em = $this->getDoctrine()->getManager();\n $em->persist($entity);\n //aggiungi squadra per l'owner\n $team = new Team();\n $team->setName($entity->getOwner()->getName().'\\'s team');\n $team->setLeague($entity);\n $team->setUser($entity->getOwner());\n $team->setEnabled(true);\n $team->setMessage('League Owner');\n $em->persist($team);\n $em->flush();\n\n return $this->redirect($this->generateUrl('fc_site_league_panel', array('id' => $entity->getId())));\n }\n\n return array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n );\n }",
"public function create()\n {\n $breadcrumbs = new \\Creitive\\Breadcrumbs\\Breadcrumbs;\n $this->setBreadcrumbs([\n [\n 'name' => \\Lang::get('lang.menu.home'),\n 'url' =>url('/')\n ],\n [\n 'name' => \\Lang::get('lang.menu.languages'),\n 'url' =>url('languages')\n ],\n [\n 'name' => \\Lang::get('lang.menu.languages.create'),\n 'url' =>url('languages/create')\n ],\n ]);\n return view('languages.create');\n }",
"public static function createFromArray($array) {\n\n if (isset($array['id'])) {\n $id = $array['id'];\n } else {\n throw new \\InvalidArgumentException('Missing field \"id\"');\n }\n\n if (isset($array['name'])) {\n $name = $array['name'];\n } else {\n throw new \\InvalidArgumentException('Missing field \"name\"');\n }\n\n if (isset($array['code'])) {\n $code = $array['code'];\n } else {\n throw new \\InvalidArgumentException('Missing field \"code\"');\n }\n\n\n return new Language($id, $name, $code);\n }",
"public function actionCreate() {\n $model = new TravellersProfile();\n $traveller_id = isset($_GET['traveller_id']) ? $_GET['traveller_id'] : 0;\n $travellerhelp = TravellerHelp::find()->where(['traveller_id' => $traveller_id])->one();\n $travellerlanguages = TravellersLanguages::find()->where(['traveller_id' => $traveller_id])->one();\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n if (count($travellerlanguages) > 0) {\n return $this->redirect(['travellerslanguages/update', 'id' => $model->traveller_id]);\n } else {\n return $this->redirect(['travellerslanguages/create', 'traveller_id' => $model->traveller_id]);\n }\n } else {\n return $this->render('create', [\n 'model' => $model,\n 'traveller_id' => $traveller_id,\n 'travellerhelp' => $travellerhelp,\n 'travellerlanguages' => $travellerlanguages,\n ]);\n }\n }"
] | [
"0.6641856",
"0.663575",
"0.6356467",
"0.6235658",
"0.6163784",
"0.60862076",
"0.60485506",
"0.59701324",
"0.59424585",
"0.58956593",
"0.5887103",
"0.5823867",
"0.5779251",
"0.5775261",
"0.5763902",
"0.57561487",
"0.5754528",
"0.5742181",
"0.5740061",
"0.57261264",
"0.5712964",
"0.57063216",
"0.5695129",
"0.5691493",
"0.56817293",
"0.56539506",
"0.5614408",
"0.5582353",
"0.55526876",
"0.55526775"
] | 0.6891011 | 0 |
Finds and displays a Langage entity. | public function showAction(Langage $langage)
{
$deleteForm = $this->createDeleteForm($langage);
return $this->render('FormationBundle:langage:show.html.twig', array(
'langage' => $langage,
'delete_form' => $deleteForm->createView(),
));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $langages = $em->getRepository('FormationBundle:Langage')->findAll();\n\n return $this->render('FormationBundle:langage:index.html.twig', array(\n 'langages' => $langages,\n ));\n }",
"public function showAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $langue = $em->getRepository('MovibeBackendBundle:Langue')->find($id);\n\n if (!$langue) {\n throw $this->createNotFoundException(\"La langue indiquée n'a pas été trouvée.\");\n }\n\n $pages = array();\n $pages['Langues'] = \"movibe_backend_langue\";\n $pages[$langue->getNom()] = \"\";\n $this->breadcrumb($pages);\n\n return $this->render('MovibeBackendBundle:Langue:show.html.twig', array(\n 'langue' => $langue\n ));\n }",
"public function getLocalizedEntity();",
"public function showLelang($id){\n\n\t}",
"public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n $langues = $em->getRepository('MovibeBackendBundle:Langue')->findAll();\n $pagination = $this->pagination($langues,1000);\n\n $pages = array();\n $pages['Langues'] = \"movibe_backend_langue\";\n $this->breadcrumb($pages);\n\n return $this->render('MovibeBackendBundle:Langue:index.html.twig', array(\n 'langues' => $pagination,\n ));\n }",
"public function show($id)\n {\n return \\Control::show('langs',$id);\n }",
"public function find($id)\n {\n return Language::find($id);\n }",
"public function listAction()\n {\n \t$languages = new Languages();\n \t$this->view->languages = $languages->getAll();\n }",
"public function show($name)\n {\n //dd($name);\n $language = Language::where('name', $name)->first();\n return view('language_show', compact('language'));\n }",
"public function editAction(Request $request, Langage $langage)\n {\n $deleteForm = $this->createDeleteForm($langage);\n $editForm = $this->createForm('FormationBundle\\Form\\LangageType', $langage);\n $editForm->handleRequest($request);\n\n if ($editForm->isSubmitted() && $editForm->isValid()) {\n $em = $this->getDoctrine()->getManager();\n $em->persist($langage);\n $em->flush();\n\n return $this->redirectToRoute('langage_edit', array('id' => $langage->getId()));\n }\n\n return $this->render('FormationBundle:langage:edit.html.twig', array(\n 'langage' => $langage,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }",
"public function showAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('BenLogementBundle:University')->find($id);\n if (!$entity) throw $this->createNotFoundException('Unable to find University entity.');\n\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('BenLogementBundle:University:show.html.twig', array(\n 'entity' => $entity,\n 'delete_form' => $deleteForm->createView(), ));\n }",
"public function newAction()\n {\n $langue = new Langue();\n\n $form = $this->createCreateForm($langue);\n\n $pages = array();\n $pages['Langues'] = \"movibe_backend_langue\";\n $pages['Ajout'] = \"\";\n $this->breadcrumb($pages);\n\n return $this->render('MovibeBackendBundle:Langue:new.html.twig', array(\n 'langue' => $langue,\n 'form' => $form->createView(),\n ));\n }",
"public function showAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $this->getTypeLogement($id, $em);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find TypeLogement entity.');\n }\n\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('chevPensionBundle:TypeLogement:show.html.twig', array(\n 'entity' => $entity,\n 'delete_form' => $deleteForm->createView(), ));\n }",
"private function language(){\r\n\t\t$em = $this->container->get('doctrine')->getManager();\t\r\n\t\t$query = $em->createQuery(\"SELECT p FROM MytripAdminBundle:Language p\");\t\t\t\r\n\t\treturn $query->getArrayResult();\r\n\t}",
"public function newAction(Request $request)\n {\n $langage = new Langage();\n $form = $this->createForm('FormationBundle\\Form\\LangageType', $langage);\n $form->handleRequest($request);\n\n if ($form->isSubmitted() && $form->isValid()) {\n $em = $this->getDoctrine()->getManager();\n $em->persist($langage);\n $em->flush();\n\n return $this->redirectToRoute('langage_index', array('id' => $langage->getId()));\n }\n\n return $this->render('FormationBundle:langage:new.html.twig', array(\n 'langage' => $langage,\n 'form' => $form->createView(),\n ));\n }",
"public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $lignearticles = $em->getRepository('AppBundle:Lignearticle')->findAll();\n\n return $this->render('lignearticle/index.html.twig', array(\n 'lignearticles' => $lignearticles,\n ));\n }",
"public function menuAction()\n\t{\n\t\t$repository = $this->getDoctrine()\n\t\t\t\t\t\t ->getManager()\n\t\t\t\t\t\t ->getRepository('AbbayeIndexBundle:Agences');\n\t\t \n\t\t$listeArticles = $repository->findAll();\n\t\t\n\t\treturn $this->render(\"AbbayeIndexBundle:Rouge:menu.html.twig\",array('listeArticles'=>$listeArticles));\n\t}",
"public function show($id)\n {\n return view('pages.lelang.show', ['lelang' => Lelang::findOrFail($id)]);\n }",
"public function showAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('AdmiScoBundle:Annee')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Annee entity.');\n }\n\n return $this->render('AdmiScoBundle:Annee:show.html.twig', array(\n 'entity' => $entity,\n ));\n }",
"public function show($id)\n {\n return Locale::find($id);\n }",
"public function show($id)\n {\n $lang = $this->langRepository->find($id);\n\n if (empty($lang)) {\n return redirect(route('langs.index'));\n }\n\n return view('vl-admin-tool::langs.show')->with('lang', $lang);\n }",
"public function getLang();",
"public function actionLangList()\n {\n $searchModel = new CttStaticdataAffiliationsSearch();\n $dataProvider = $searchModel->searchLangList(Yii::$app->request->queryParams);\n\n // GlobalVariable::fetchData();\n\n return $this->render('lang_list', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }",
"function GetLanguageViewAction()\n {\n return \"LanguageView\";\n }",
"public function show(tag_lang $tag_lang)\n {\n //\n }",
"public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $this->getTypeLogements($em);\n\n return $this->render('chevPensionBundle:TypeLogement:index.html.twig', array(\n 'entities' => $entities,\n ));\n }",
"public function show($id)\n {\n $language = Language::findOrFail($id);\n\n return view('languages.show', compact('language'));\n }",
"public function UserExperienceAction()\n{\n $repo = $this->getDoctrine()->getRepository(Experience::class);\n $experience = $repo->findAll();\n \n \n $params = array(\n 'experience' => $experience\n );\n \n return $this->render('@PORTFOLIO/Admin/list-experiences.html.twig', $params);\n \n}",
"public function fb_userLanguagesAction() {\n //check for logrdin company\n if (FALSE === $this->get('security.context')->isGranted('ROLE_NOTACTIVE')) {\n //redirect to login page if user not loggedin\n return $this->redirect($this->generateUrl('site_fb_homepage'));\n }\n\n $em = $this->getDoctrine()->getEntityManager();\n //get request object\n $request = $this->getRequest();\n\n //get loggedin user objects\n $user = $this->get('security.context')->getToken()->getUser();\n //create new user language\n $newUserLanguage = new UserLanguage();\n $newUserLanguage->setUser($user);\n $form = $this->createForm(new UserLanguageType(), $newUserLanguage);\n\n if ($request->getMethod() == 'POST') {\n $form->bindRequest($request);\n if ($form->isValid()) {\n //save the new language\n $em->persist($newUserLanguage);\n $em->flush();\n\n $request->getSession()->setFlash('success', 'New Language Added successfully');\n return $this->redirect($this->generateUrl('fb_user_languages'));\n }\n }\n\n //get user langauges\n $userLangauges = $user->getLanguages();\n\n return $this->render('ObjectsInternJumpBundle:InternjumpUser:fb_newLanguage.html.twig', array(\n 'newUserLanguage' => $newUserLanguage,\n 'form' => $form->createView(),\n 'formName' => $this->container->getParameter('studentAddLanguage_FormName'),\n 'formDesc' => $this->container->getParameter('studentAddLanguage_FormDesc'),\n 'userLangauges' => $userLangauges\n ));\n }",
"public function showAction($id) {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('ApplicationRelationsBundle:Applis')->find($id);\n\n $projets = $entity->getIdprojets();\n\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Applis entity.');\n }\n\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('ApplicationRelationsBundle:Applis:show.html.twig', array(\n 'entity' => $entity,\n 'delete_form' => $deleteForm->createView(),\n 'projets' => $projets,\n ));\n }"
] | [
"0.6382666",
"0.609401",
"0.5933169",
"0.5662548",
"0.5654884",
"0.56383044",
"0.55762947",
"0.5570919",
"0.55609685",
"0.5560548",
"0.55479497",
"0.5544415",
"0.5506946",
"0.54600847",
"0.54600114",
"0.534992",
"0.53426963",
"0.53272223",
"0.53209287",
"0.5316621",
"0.53143334",
"0.5307463",
"0.52983356",
"0.5291411",
"0.5290403",
"0.5274047",
"0.5240353",
"0.52308923",
"0.52286345",
"0.5221307"
] | 0.65353274 | 0 |
Displays a form to edit an existing Langage entity. | public function editAction(Request $request, Langage $langage)
{
$deleteForm = $this->createDeleteForm($langage);
$editForm = $this->createForm('FormationBundle\Form\LangageType', $langage);
$editForm->handleRequest($request);
if ($editForm->isSubmitted() && $editForm->isValid()) {
$em = $this->getDoctrine()->getManager();
$em->persist($langage);
$em->flush();
return $this->redirectToRoute('langage_edit', array('id' => $langage->getId()));
}
return $this->render('FormationBundle:langage:edit.html.twig', array(
'langage' => $langage,
'edit_form' => $editForm->createView(),
'delete_form' => $deleteForm->createView(),
));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $langue = $em->getRepository('MovibeBackendBundle:Langue')->find($id);\n\n if (!$langue) {\n throw $this->createNotFoundException(\"La langue indiquée n'a pas été trouvée.\");\n }\n\n $editForm = $this->createEditForm($langue);\n\n $pages = array();\n $pages['Langues'] = \"movibe_backend_langue\";\n $pages['Edition'] = \"\";\n $this->breadcrumb($pages);\n\n return $this->render('MovibeBackendBundle:Langue:edit.html.twig', array(\n 'langue' => $langue,\n 'edit_form' => $editForm->createView(),\n ));\n }",
"public function action_edit() {\n $article_id = $this->request->param('id');\n $article = new Model_Article($article_id);\n\n $this->template->title = \"Editar Artículo\";\n $this->template->content = View::factory('article/dashboard/form')\n ->bind('article', $article);\n }",
"public function edit($id)\n\t{\n\t\t$lang = Lang::where('id',$id)->first();\n\t\treturn view('backend.langs.edit',[\n\t\t\t'lang' => $lang,\n\t\t\t'action_method' => 'put'\n\t\t]);\n\t}",
"public function edit($id) {\n\n if( !Auth::guard('admin')->check()) {\n return redirect()->intended(route('admin.login'));\n }\n \n $verifyLangID = Language::where('id', $id)->first();\n if(isset($verifyLangID) ){\n \n $lang = Language::find($id);\n\n return view('backend.form_language', ['id' => $id, 'lang' => $lang]);\n \n }else{\n return redirect('/admin/language')->with('warning', Lang::get('messages.page_id_not_exists', ['page' => 'Language']));\n }\n }",
"public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('BenLogementBundle:University')->find($id);\n if (!$entity) throw $this->createNotFoundException('Unable to find University entity.');\n\n $editForm = $this->createForm(new UniversityType($entity->getType()), $entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('BenLogementBundle:University:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }",
"public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $this->getTypeLogement($id, $em);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find TypeLogement entity.');\n }\n\t\t\n\t\t$typeLogementType = new TypeLogementType();\n\t\t$typeLogementType->setUser($this->get('security.context')->getToken()->getUser());\n\t\t\n $editForm = $this->createForm($typeLogementType, $entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('chevPensionBundle:TypeLogement:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }",
"public function editAction($id) {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('ApplicationRelationsBundle:Applis')->find($id);\n $projets = $entity->getIdprojets();\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Applis entity.');\n }\n\n $editForm = $this->createForm(new ApplisType(), $entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('ApplicationRelationsBundle:Applis:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n 'projets' => $projets,\n ));\n }",
"public function edit($id)\n {\n $data = LanguageNation::find($id);\n return view('admin.language.create_edit',compact('data'));\n }",
"public function edit($id)\n {\n $language = Language::findOrFail($id);\n\n return view('languages.edit', compact('language'));\n }",
"public function edit($id)\n {\n // Retrieving models\n $language = Language::findOrFail($id);\n\n return view('admin.language.edit', compact('language'));\n }",
"public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('SheikhuLibraryBundle:MaisonEdition')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find MaisonEdition entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('SheikhuLibraryBundle:MaisonEdition:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }",
"public function edit(Language $language)\n {\n //\n }",
"public function newAction()\n {\n $langue = new Langue();\n\n $form = $this->createCreateForm($langue);\n\n $pages = array();\n $pages['Langues'] = \"movibe_backend_langue\";\n $pages['Ajout'] = \"\";\n $this->breadcrumb($pages);\n\n return $this->render('MovibeBackendBundle:Langue:new.html.twig', array(\n 'langue' => $langue,\n 'form' => $form->createView(),\n ));\n }",
"public function editAction($id) {\r\n $em = $this->getDoctrine()->getManager();\r\n\r\n $entity = $em->getRepository('PersonaBundle:Localidad')->find($id);\r\n\r\n if (!$entity) {\r\n throw $this->createNotFoundException('Unable to find Localidad entity.');\r\n }\r\n\r\n $editForm = $this->createForm(new LocalidadType(), $entity);\r\n $deleteForm = $this->createDeleteForm($id);\r\n\r\n return $this->render('PersonaBundle:Localidad:edit.html.twig', array(\r\n 'entity' => $entity,\r\n 'edit_form' => $editForm->createView(),\r\n 'delete_form' => $deleteForm->createView(),\r\n ));\r\n }",
"public function editAction($id) {\n $entity = $this->get('chronoabsences.common.manager')->loadAbsence($id);\n $editForm = $this->createForm(new ChronoAbsencesType(), $entity);\n $deleteForm = $this->createDeleteForm($id);\n return $this->render('ApplicationRelationsBundle:ChronoAbsences: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 //$lang = Lang::find($id);\n //return view('admin_rule.langs.edit',compact('lang'));\n return \\Control::edit('langs',$id);\n }",
"public function edit($id)\n {\n $id = substr($id, 4);\n $id = Crypt::decrypt($id);\n $language = Language::where('id', $id)->first();\n return view('pages.language.addlanguage', compact('language'));\n }",
"public function getEdit( $id )\n\t{\n\t\t$language = Language::find( $id );\n\n\t\treturn view( 'admin/language/create_edit', compact( 'language' ) );\n\t}",
"public function edit($id)\n {\n $language = Language::find($id);\n\n return view('languages.edit', [\n 'language' => $language\n ]);\n }",
"public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('AppBundle:Hoja')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Hoja entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('AppBundle:Hoja:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }",
"public function editAction($id) {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('Nfe102RestoBundle:CodesPostaux')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find CodesPostaux entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('Nfe102RestoBundle:CodesPostaux:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }",
"public function edit($id) {\n return \\View::make('master.gelombang.edit')->with('tapel', \\App\\Models\\Tapel::find($id));\n }",
"public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('HelpDeskBundle:ChamadaNivel')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find ChamadaNivel entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('HelpDeskBundle:ChamadaNivel:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }",
"public function showAction(Langage $langage)\n {\n $deleteForm = $this->createDeleteForm($langage);\n\n return $this->render('FormationBundle:langage:show.html.twig', array(\n 'langage' => $langage,\n 'delete_form' => $deleteForm->createView(),\n ));\n }",
"public function editAction() {\n\t\t$this->loadLayout(); \n\t\t$this->renderLayout();\n\t}",
"public function edit($id)\n {\n $model = Pelanggan::findOrFail($id);\n return view('admin.pelanggan.form', compact('model'));\n }",
"public function edit($language_id = NULL)\r\n {\r\n if ($language_id == 1) {\r\n redirect('admin/languages');\r\n }\r\n $language = objToArr($this->AdminLanguageModel->getLanguage('language_id', $language_id));\r\n\r\n //Getting the default lang array\r\n include(APPLICATION_ROOT . '/language/english/message_lang.php');\r\n $default = $lang;\r\n\r\n //Getting the selected lang array\r\n $entries = include(APPLICATION_ROOT . '/language/'.$language['slug'].'/message_lang.php');\r\n $entries = $lang;\r\n \r\n $data['page'] = lang('languages');\r\n $data['menu'] = 'languages';\r\n $this->load->view('admin/layout/header', $data);\r\n $this->load->view('admin/languages/edit', compact('language', 'entries', 'default'));\r\n }",
"public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('EmisionesBundle:Agente')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Agente entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('EmisionesBundle:Agente:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }",
"public function editAction()\n {\n $this->_forward('new');\n }",
"function edit()\n {\n $this->_view_edit('edit');\n }"
] | [
"0.7393921",
"0.70229065",
"0.69713265",
"0.6839926",
"0.68346304",
"0.6798271",
"0.67386246",
"0.6664154",
"0.664367",
"0.6628936",
"0.6598254",
"0.65609026",
"0.65458155",
"0.6515924",
"0.6502286",
"0.64948976",
"0.649145",
"0.64796966",
"0.6463669",
"0.64425534",
"0.6428974",
"0.64283216",
"0.6427561",
"0.6425627",
"0.64184994",
"0.64176226",
"0.6414632",
"0.64135945",
"0.6406619",
"0.64016294"
] | 0.7209271 | 1 |
Deletes a Langage entity. | public function deleteAction(Request $request, Langage $langage)
{
$form = $this->createDeleteForm($langage);
$form->handleRequest($request);
if ($form->isSubmitted() && $form->isValid()) {
$em = $this->getDoctrine()->getManager();
$em->remove($langage);
$em->flush();
}
return $this->redirectToRoute('langage_index');
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function delete(Request $request){\n //dd($request);\n $language = Languages::find($request->delid);\n $language->delete();\n\n return redirect('languages');\n }",
"public function deleteLanguage(Request $request)\n {\n \tif(!empty($request->get('key')))\n \t{\n \t\t$key = str_replace('language-ref', '', $request->get('key'));\n \t\t$user = Auth::guard('web')->user();\n \t\t$language = $user->languages()->findOrFail((int)$key);\n \t\t$language->delete();\n \t\treturn response()->json(true);\n \t}\n \treturn response()->json(['error'=>'Sorry we couldnot locate the language.']);\n \n }",
"function delete_language()\n\t{\n\t\t$languageId = $this->uri->segment('4');\n\t\t$delete_language = $this->multilanguage_model->delete_language($languageId);\n\t\t$this->setErrorMessage('success', \" Language deleted changed successfully\");\n\t\tredirect('admin/multilanguage/display_language_list');\n\t}",
"public function deleting(Language $language)\n {\n //\n }",
"function deleteLanguage()\n {\n global $_ARRAYLANG, $objDatabase;\n if (!empty($_REQUEST['id'])) {\n \n $pageRepo = \\Env::get('em')->getRepository('Cx\\Core\\ContentManager\\Model\\Entity\\Page');\n $pages = $pageRepo->findBy(array(\n 'lang' => intval($_REQUEST['id']),\n ));\n if (count($pages)) {\n if ($objDatabase->Execute(\"DELETE FROM \".DBPREFIX.\"languages WHERE id=\".intval($_REQUEST['id'])) !== false) {\n $objDatabase->Execute(\"DELETE FROM \".DBPREFIX.\"language_variable_content WHERE lang_id=\".intval($_REQUEST['id']));\n $objDatabase->Execute(\"DELETE FROM \".DBPREFIX.\"module_gallery_language WHERE lang_id=\".intval($_REQUEST['id']));\n $objDatabase->Execute(\"DELETE FROM \".DBPREFIX.\"module_gallery_language_pics WHERE lang_id=\".intval($_REQUEST['id']));\n $this->strOkMessage = $_ARRAYLANG['TXT_STATUS_SUCCESSFULLY_DELETE'];\n return true;\n }\n }\n $this->strErrMessage = $_ARRAYLANG['TXT_DATABASE_QUERY_ERROR'];\n }\n return false;\n }",
"public function postDelete( DeleteRequest $request, $id )\n\t{\n\t\t$language = Language::find( $id );\n\t\t$language->delete();\n\t}",
"public function destroy($id) {\n \n $verifyLangID = Language::where('id', $id)->first();\n if(isset($verifyLangID) ){\n \n Language::destroy($id);\n\n return redirect('/admin/language')->with('success', Lang::get('messages.page_delete', ['page' => 'Language']));\n \n }else{\n return redirect('/admin/language')->with('warning', Lang::get('messages.page_id_not_exists', ['page' => 'Language']));\n }\n }",
"public function destroy($name)\n {\n //dd($name);\n $language = Language::where('name', $name)->first();\n //dd($language);\n $language->delete();\n return redirect('/language');\n }",
"private function createDeleteForm(Langage $langage)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('langage_delete', array('id' => $langage->getId())))\n ->setMethod('DELETE')\n ->getForm()\n ;\n }",
"public function deleteAction(Request $request, $id)\n {\n $em = $this->getDoctrine()->getManager();\n $langue = $em->getRepository('MovibeBackendBundle:Langue')->find($id);\n\n if (!$langue) {\n throw $this->createNotFoundException(\"La langue indiquée n'a pas été trouvée.\");\n }\n\n $em->remove($langue);\n $em->flush();\n\n\n if ($request->isXmlHttpRequest())\n {\n return new JsonResponse(true);\n }\n else\n {\n $request->getSession()->getFlashbag()->add('message','La langue sélectionnée a été supprimée');\n return $this->redirect($this->generateUrl('movibe_backend_langue'));\n }\n }",
"public function destroy(tag_lang $tag_lang)\n {\n //\n }",
"public function delete(Request $request)\n {\n $languages = Language::whereIn('uid', explode(',', $request->uids));\n\n foreach ($languages->get() as $language) {\n // authorize\n if (\\Gate::allows('delete', $language)) {\n $language->deleteAndCleanup();\n }\n }\n\n echo trans('messages.languages.deleted');\n }",
"public function fb_deleteLanguageAction($id) {\n if (FALSE === $this->get('security.context')->isGranted('ROLE_NOTACTIVE')) {\n //redirect to login page if user not loggedin\n return $this->redirect($this->generateUrl('site_fb_homepage'));\n }\n $em = $this->getDoctrine()->getEntityManager();\n //get loggedin user objects\n $user = $this->get('security.context')->getToken()->getUser();\n //check if this language exist\n $language = $em->getRepository('ObjectsInternJumpBundle:UserLanguage')->find($id);\n if (!$language) {\n throw $this->createNotFoundException('Language Not Found');\n }\n if ($user->getId() !== $language->getUser()->getId()) {\n throw new AccessDeniedHttpException('This Language is not yours');\n }\n $em->remove($language);\n $em->flush();\n $this->getRequest()->getSession()->setFlash('success', 'Language Deleted successfully');\n return $this->redirect($this->generateUrl('fb_student_task', array('loginName' => $user->getLoginName())));\n }",
"public function destroy($id)\n {\n $language = Language::findOrFail($id);\n\n $language->delete();\n\n return redirect('languages')->with('flash_message', 'Language has been deleted!');\n }",
"public function deleteLanguageAction($id) {\n if (FALSE === $this->get('security.context')->isGranted('ROLE_NOTACTIVE')) {\n //redirect to login page if user not loggedin\n return $this->redirect($this->generateUrl('login'));\n }\n $em = $this->getDoctrine()->getEntityManager();\n //get loggedin user objects\n $user = $this->get('security.context')->getToken()->getUser();\n //check if this language exist\n $language = $em->getRepository('ObjectsInternJumpBundle:UserLanguage')->find($id);\n if (!$language) {\n throw $this->createNotFoundException('Language Not Found');\n }\n if ($user->getId() !== $language->getUser()->getId()) {\n throw new AccessDeniedHttpException('This Language is not yours');\n }\n $em->remove($language);\n $em->flush();\n $this->getRequest()->getSession()->setFlash('success', 'Language Deleted successfully');\n return $this->redirect($this->generateUrl('student_task', array('loginName' => $user->getLoginName())));\n }",
"public function delete($entity);",
"public function destroy($id)\n {\n $language = Language::find($id);\n $language->delete();\n\n return redirect('/languages');\n }",
"public function destroy($id)\n {\n $id = $id;\n $data = Language::where('id',$id)->delete();\n Session::flash('delete', \"Language Deleted Successfully\");\n return redirect()->to('/language');\n }",
"function delete($entity);",
"function delete_user_language()\n\t{\n\t\t$languageId = $this->uri->segment('4');\n\t\t$condition = array('id' => $languageId);\n\t\t$this->multilanguage_model->commonDelete(LANGUAGES_KNOWN, $condition);\n\t\t$this->setErrorMessage('success', \" Language deleted successfully\");\n\t\tredirect('admin/multilanguage/display_user_language');\n\t}",
"public function destroy($lang, Message $message)\n {\n $message->delete();\n\n return redirect()->route('message.index', app()->getlocale())->with('success-delete', 'The resource was deleted!');\n }",
"public function deleting(Language $language)\n {\n\t\t// Check Demo Website\n\t\t$this->isDemo();\n\t\t\n // Don't delete the default language\n if ($language->abbr == config('applang.abbr')) {\n Alert::error(__t('You cannot delete the default language.'))->flash();\n return back();\n }\n \n // Delete all translated entries\n $this->destroyTranslatedEntries($language->abbr);\n \n // Remove all language files\n File::deleteDirectory(resource_path('lang/' . $language->abbr));\n File::deleteDirectory(resource_path('lang/vendor/admin/' . $language->abbr));\n }",
"public function destroy($id)\n\t{\n $languages=Language::find($id);\n $languages->delete();\n Session::flash('danger','Successfully destroyed the language!');\n return Redirect::to('admin/language-recycle');\n }",
"public function deleteAction()\n {\n // @todo It's not necessary to specify a language, since the texts in all languages are removed.\n\n if (!preg_match('/\\/page\\/(\\w+[\\-\\w]*)\\/text\\/..\\/(\\w+)$/', $this->name, $matches)) {\n throw new InvalidParameterException(\"Invalid parameters\");\n }\n list($dummy, $pageName, $containerName) = $matches;\n $pageTexts = $this->getTextModel($pageName);\n $pageTexts->deleteTextContainer($containerName);\n\n $this->environment->sendJSONResult('ok');\n }",
"abstract public function delete($entity);",
"public function delete($league){\n if($league->getId() == -1){\n //if league isn't persistent, return\n return;\n }\n\n //Prepare mySQL query\n $q = 'DELETE FROM league WHERE league_id = ?;';\n //create Prepared statement\n $stmt = $this->dbConnection->prepare($q);\n //bind parameter to query\n $leagueId = $league->getId();\n $stmt->bindParam(1, $leagueId, \\PDO::PARAM_INT);\n //execute query\n if ($stmt->execute()) {\n echo 'league deleted successfully';\n }\n else{\n throw new RDException('Deletion of venue unsuccessful');\n }\n }",
"public function deleteMyLanguageAction()\n {\n\t\t$result=\\Extended\\user_languages::deleteLanguage($this->getRequest()->getParam(\"id\"), Auth_UserAdapter::getIdentity()->getId() );\n\t\tif($result)\n\t\t\techo Zend_Json::encode($result);\n\t\tdie;\n }",
"public function Delete($entity) {\r\n }",
"public function deleteByEntity($entity, $attribute)\n\t{\n\t\t// delete all values for provided entity, attribute and language\n\t\t$this\t->db->table( $this->table )\n\t\t\t\t->where( 'attribute_id', '=', $attribute->id )\n\t\t\t\t->where( 'entity_id', '=', $entity->id )\n\t\t\t\t->delete();\n\t\tif($attribute->searchable)\n\t\t{\n\t\t\t$this->db->table('attribute_values_fulltext')\n\t\t\t\t->where( 'attribute_id', '=', $attribute->id )\n\t\t\t\t->where( 'entity_id', '=', $entity->id )\n\t\t\t\t->delete();\n\t\t}\n\t}",
"public function destroy(Language $language)\n\t{\n\t\tif(LaravelLocalization::getCurrentLocale() == $language->locale)\n\t\t{\n\t\t\treturn redirect()->back();\n\t\t}\n\t\t\n\t\t$language->delete();\n\t\treturn redirect()->route('admin.languages.index')->with('success', trans('runsite::languages.The language is deleted'));\n\t}"
] | [
"0.67280275",
"0.6443047",
"0.64341915",
"0.6413722",
"0.6406841",
"0.63604355",
"0.60843974",
"0.60411334",
"0.60357076",
"0.6011012",
"0.594761",
"0.5938423",
"0.59089464",
"0.5857309",
"0.5855407",
"0.584393",
"0.58406246",
"0.58269495",
"0.5826494",
"0.581488",
"0.5811396",
"0.5786909",
"0.577425",
"0.5735452",
"0.57235414",
"0.5718029",
"0.5687519",
"0.5687226",
"0.5676361",
"0.56755656"
] | 0.7527913 | 0 |
Creates a form to delete a Langage entity. | private function createDeleteForm(Langage $langage)
{
return $this->createFormBuilder()
->setAction($this->generateUrl('langage_delete', array('id' => $langage->getId())))
->setMethod('DELETE')
->getForm()
;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function btrVocabulary_delete_form($form, &$form_state) {\n // Get an associative array of language codes and names.\n $arr_languages = bcl::get_languages();\n $languages = [];\n foreach ($arr_languages as $lng => $lang) {\n $languages[$lng] = $lang['name'];\n }\n\n // Build the form.\n $form = [\n 'delete' => [\n '#type' => 'fieldset',\n '#title' => t('Delete a vocabulary'),\n '#collapsible' => TRUE,\n '#collapsed' => TRUE,\n\n 'lng' => [\n '#type' => 'select',\n '#title' => t('Language'),\n '#options' => $languages,\n '#required' => TRUE,\n ],\n\n 'name' => [\n '#type' => 'textfield',\n '#title' => t('Name'),\n '#required' => TRUE,\n ],\n\n 'submit' => [\n '#value' => t('Delete'),\n '#type' => 'submit',\n ],\n ],\n ];\n return $form;\n}",
"public function deleteAction(Request $request, Langage $langage)\n {\n $form = $this->createDeleteForm($langage);\n $form->handleRequest($request);\n\n if ($form->isSubmitted() && $form->isValid()) {\n $em = $this->getDoctrine()->getManager();\n $em->remove($langage);\n $em->flush();\n }\n\n return $this->redirectToRoute('langage_index');\n }",
"private function createDeleteForm()\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('turnossede_delete', array('id' => '__obj_id__')))\n ->setMethod('DELETE')\n ->getForm()\n ;\n }",
"private function createDeleteForm()\n {\n return $this->factory->createBuilder()\n ->setMethod('DELETE')\n ->getForm();\n }",
"private function createDeleteForm($id) {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('absences_delete', array('id' => $id)))\n ->setMethod('DELETE')\n ->add('submit', 'submit', array('label' => 'Delete'))\n ->getForm()\n ;\n }",
"private function createDeleteForm(Atala $atala)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('admin_atala_delete', array('id' => $atala->getId())))\n ->setMethod('DELETE')\n ->getForm()\n ;\n }",
"public function deleteAction() : object\n {\n $page = $this->di->get(\"page\");\n $form = new DeleteForm($this->di);\n $form->check();\n\n $page->add(\"questions/crud/delete\", [\n \"form\" => $form->getHTML(),\n ]);\n\n return $page->render([\n \"title\" => \"Delete an item\",\n ]);\n }",
"protected function createComponentDeleteForm() {\r\n $form = new Form;\r\n $form->addSubmit('cancel', 'Zrušit');\r\n $form->addSubmit('delete', 'Smazat')->setAttribute('class', 'default');\r\n $form->onSubmit[] = callback($this, 'deleteFormSubmitted');\r\n $form->addProtection('Odešlete prosím formulář znovu (bezpečnostní token vypršel).');\r\n return $form;\r\n }",
"private function createDeleteForm($id)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('secteur_delete', array('id' => $id)))\n ->setMethod('DELETE')\n ->add('submit', 'submit', array('label' => 'Supprimer', 'attr' => array('class'=>'btn btn-danger btn-block margin-bottom')))\n ->getForm()\n ;\n }",
"public function delete(Request $request){\n //dd($request);\n $language = Languages::find($request->delid);\n $language->delete();\n\n return redirect('languages');\n }",
"private function createDeleteForm($id) {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('college_delete', array('id' => $id)))\n ->setMethod('DELETE')\n ->add('submit', 'submit', array('label' => 'Delete'))\n ->getForm()\n ;\n }",
"private function createDeleteForm($id) {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('megaloman_delete', array('id' => $id)))\n ->setMethod('DELETE')\n ->add('submit', 'submit', array('label' => 'Usuń'))\n ->getForm()\n ;\n }",
"private function createDeleteForm($id) {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('personne_delete', array('id' => $id)))\n ->setMethod('DELETE')\n ->add('submit', 'submit', array('label' => 'Delete'))\n ->getForm()\n ;\n }",
"private function createDeleteForm(Lecture $lecture)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('lecture_delete', array('id' => $lecture->getId())))\n ->setMethod('DELETE')\n ->getForm()\n ;\n }",
"private function createDeleteForm(Etiquetas $etiqueta)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('admin_crud_etiquetas_delete', array('id' => $etiqueta->getId())))\n ->setMethod('DELETE')\n ->getForm()\n ;\n }",
"private function createDeleteForm(FrigaEdital $frigaedital)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('edital_remover', array('uuid' => $frigaedital->getUuid())))\n ->setMethod('DELETE')\n ->getForm();\n }",
"private function createDeleteForm(Lignearticle $lignearticle)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('lignearticle_delete', array('id' => $lignearticle->getId())))\n ->setMethod('DELETE')\n ->getForm()\n ;\n }",
"private function createDeleteForm($id)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('certificado_delete', array('id' => $id)))\n ->setMethod('DELETE')\n ->add('submit', 'submit', array('label' => 'Borrar'))\n ->getForm()\n ;\n }",
"private function createDeleteForm($id) {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('codespostaux_delete', array('id' => $id)))\n ->setMethod('DELETE')\n ->add('submit', 'submit', array('label' => 'Delete'))\n ->getForm()\n ;\n }",
"private function createDeleteForm(AttributeType $attributeType)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('attributetype_delete', array('id' => $attributeType->getId())))\n ->setMethod('DELETE')\n ->getForm()\n ;\n }",
"private function createDeleteForm(Agence $agence)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('agence_delete', array('id' => $agence->getIdagence())))\n ->setMethod('DELETE')\n ->getForm();\n }",
"private function createDeleteForm($id)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('avenant_delete', array('id' => $id)))\n ->setMethod('DELETE')\n ->add('submit', 'submit', array('label' => 'Supprimer','attr'=>array( 'class'=> 'pc_sidebar_element')))\n ->getForm()\n ;\n }",
"private function createDeleteForm($id) {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('articles_delete', array('id' => $id)))\n ->setMethod('DELETE')\n ->add('submit', 'submit', array('label' => 'Delete'))\n ->getForm()\n ;\n }",
"private function createDeleteForm( Persona $persona ) {\n\t\treturn $this->createFormBuilder()\n\t\t ->setAction( $this->generateUrl( 'persona_delete', array( 'id' => $persona->getId() ) ) )\n\t\t ->setMethod( 'DELETE' )\n\t\t ->getForm();\n\t}",
"protected function createComponentDeleteForm()\r\n\t{\r\n\t\t$form = new Form;\r\n\t\t$form->addSubmit('delete', 'Smazat')->setAttribute('class', 'default');\r\n\t\t$form->addSubmit('cancel', 'Storno');\r\n\t\t$form->onSuccess[] = callback($this, 'deleteFormSubmitted');\r\n\t\t$form->addProtection(self::MESS_PROTECT);\r\n\t\treturn $form;\r\n\t}",
"public function delete( Entity $form ) {\n\t}",
"private function createDeleteForm(BlComtrad $blComtrad)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('blcomtrad_delete', array('id' => $blComtrad->getId())))\n ->setMethod('DELETE')\n ->getForm()\n ;\n }",
"private function createDeleteForm(VhloCfgPlaca $vhloCfgPlaca)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('vhlocfgplaca_delete', array('id' => $vhloCfgPlaca->getId())))\n ->setMethod('DELETE')\n ->getForm()\n ;\n }",
"private function createDeleteForm($id)\n {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('licenciaequipo_delete', array('id' => $id)))\n ->setMethod('DELETE')\n ->add('submit', 'submit', array('label' => 'Eliminar','attr' => array('class' => 'btn btn-danger')))\n ->getForm()\n ;\n }",
"private function createDeleteForm($id) {\n return $this->createFormBuilder()\n ->setAction($this->generateUrl('ge_estudiante_delete', array('id' => $id)))\n ->setMethod('POST')\n ->add('submit', 'submit', array('label' => 'Eliminar'))\n ->getForm();\n }"
] | [
"0.6987686",
"0.69147426",
"0.69036657",
"0.6586348",
"0.65430486",
"0.647965",
"0.6447931",
"0.6441497",
"0.64278686",
"0.6424131",
"0.6424098",
"0.64056087",
"0.64030457",
"0.6390213",
"0.6388492",
"0.63776386",
"0.63599074",
"0.6356317",
"0.635144",
"0.6347194",
"0.6326008",
"0.6324344",
"0.6323579",
"0.6314754",
"0.63060504",
"0.6301497",
"0.6277319",
"0.62672806",
"0.62644714",
"0.62588215"
] | 0.80848783 | 0 |
Redirects the user to the specified URL if the condition is not true | function allowIf($condition, $failUrl = 'index.php') {
if(!$condition) {
echo "<script>window.location.replace('$failUrl');</script>";
die();
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private function checkUrl()\n {\n if ($this->route !== strtolower($this->route)) {\n http_response_code(301);\n header('location: ' . strtolower($this->route));\n }\n }",
"public function redirect($url = '') {}",
"abstract protected function redirectTo();",
"public function redirect($url) {}",
"function ol_check_url() {\r\n $feedsmart_settings = $this->get_options();\r\n switch (basename($_SERVER['PHP_SELF'])) {\r\n case 'wp-rss.php':\r\n case 'wp-rss2.php':\r\n case 'wp-atom.php':\r\n case 'wp-rdf.php':\r\n if (trim($feedsmart_settings['feedsmart_url']) != '') {\r\n if (function_exists('status_header')) status_header( 302 );\r\n header(\"Location:\" . trim($feedsmart_settings['feedsmart_url']));\r\n header(\"HTTP/1.1 302 Temporary Redirect\");\r\n exit();\r\n }\r\n break;\r\n case 'wp-commentsrss2.php':\r\n if (trim($feedsmart_settings['feedsmart_comments_url']) != '') {\r\n if (function_exists('status_header')) status_header( 302 );\r\n header(\"Location:\" . trim($feedsmart_settings['feedsmart_comments_url']));\r\n header(\"HTTP/1.1 302 Temporary Redirect\");\r\n exit();\r\n }\r\n break;\r\n }\r\n }",
"function redirect($url=NULL) {\n\t\tif($url != \"\" && filter_var($url, FILTER_VALIDATE_URL)) {\n\t\t\tif(headers_sent()) {\n\t\t\t die(\"<script>window.location.href = '\".$url.\"';</script>\");\n\t\t\t}\n\t\t\telse{\n\t\t\t die(header(\"location: \".$url));\n\t\t\t}\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}",
"public function redirectNotLogged();",
"protected function _redirect($url)\n {\n \t$condition = $this->_condition;\n\n \t// zerowanie warunku\n \t$this->_condition = null;\n\n \tif (true === $condition)\n \t{\n \t\t// nie może być exit\n \t\tif (true === $this->_exit)\n \t\t{\n \t\t\t$this->setExit(false);\n \t\t}\n\n \t\t// warunek spełniony wtedy przekierowanie\n \t\t// nie jest potrzebne..\n \t\treturn;\n \t}\n \t\n \tparent::_redirect($url);\n }",
"public function maybe_redirect_to_default() {\n // Abort if we don't have a URL to redirect to\n if ( ! isset( $this->plugin_options['wpe_redirect_url'] ) || empty( $this->plugin_options['wpe_redirect_url'] ) ) {\n return false;\n }\n\n if ( preg_match( $this->url_pattern, $this->plugin_options['wpe_redirect_url'] ) ) {\n wp_redirect( $this->plugin_options['wpe_redirect_url'] );\n exit;\n }\n }",
"public function checkForRedirect() {\n $url = $this->formit->postHooks->getRedirectUrl();\n if (!empty($url) && !$this->formit->inTestMode) {\n $this->modx->sendRedirect($url);\n }\n }",
"public function redirect();",
"public function redirect();",
"function landpg_redirect_requirements() {\n\t\n\tif( !is_user_logged_in() ) {\n\n\t\tif( '/coming-soon/' != $_SERVER['REQUEST_URI'] && '/xmlrpc.php' != $_SERVER['REQUEST_URI'] && '/wp-login.php' != $_SERVER['REQUEST_URI'] ) {\n\t\t\twp_safe_redirect( trailingslashit( '/coming-soon' ) );\n\t\t\texit;\n\t\t}\n\t} \n}",
"private function _redirect_if_required(){\n\n if($this->subj->current_phase === 'phase_two'){\n return true;\n }\n\n if($this->subj->current_phase !== 'phase_two'){\n $this->_redirect($this->subj);\n }\n }",
"public function redirectInvalidRequest();",
"public function redirect($url, $status = 302, $allowOnlyInternalUrls = false);",
"public function check(){\n\t\tif (Yii::app()->getUrlManager()->parseUrl($_GET)=='admin/login/login'){\n\t\t\treturn;\n\t\t} \n\t\tif (Yii::app()->user->id!='admin'){\n\t\t\theader('HTTP/1.1 301 Moved Permanently');\n\t\t\theader('Location: '.Yii::app()->createUrl('admin/login/login'));\n\t\t\texit();\n\t\t}\n\t}",
"public function redirect( string $url );",
"public function redirect($url);",
"public static function redirect_if_not_allowed() {\n\t\t// Don't redirect WP-CLI.\n\t\tif ( defined( 'WP_CLI' ) && WP_CLI ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Don't redirect cron.\n\t\tif ( wp_doing_cron() ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Don't redirect the admin.\n\t\tif ( is_admin() ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Don't redirect the login page.\n\t\tif ( false !== stripos( wp_login_url(), $_SERVER['SCRIPT_NAME'] ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\t$do_redirect = false;\n\n\t\t// Redirect if user is not allowed to access the site.\n\t\tif ( ! $do_redirect ) {\n\t\t\t$do_redirect = ! self::is_user_allowed_to_access_site();\n\t\t}\n\n\t\t// Perform redirect if appropriate.\n\t\tif ( $do_redirect ) {\n\t\t\twp_redirect( 'https://wordpress.org' );\n\t\t}\n\t}",
"function redirectUrl($url) {\n\t\tif (HookRegistry::call('Request::redirect', array(&$url))) {\n\t\t\treturn;\n\t\t}\n\n\t\theader(\"Refresh: 0; url=$url\");\n\t\texit();\n\t}",
"protected function forward($url) {/*{{{*/\n if ( !$url ) {\n return;\n }\n\n header('Location:'.$url);\n return;\n }",
"public function isRedirect()\n {\n return false;\n }",
"function is_redirected_page()\n{\n\n return false;\n\n}",
"function redirect($url, $type = 303);",
"public function willRedirect() {\n return $this->statusCode >= 300 && $this->statusCode < 400;\n }",
"public function hasRedirect(): bool;",
"function redirect ($url){\n\t header(\"Location: $url\");\n\t\texit;\n\t}",
"public function isRedirect()\n {\n return true;\n }",
"public function isRedirect()\n {\n return true;\n }"
] | [
"0.73653203",
"0.6891979",
"0.68678474",
"0.6843728",
"0.6831609",
"0.6811117",
"0.67875206",
"0.6768674",
"0.6754949",
"0.67471254",
"0.671667",
"0.671667",
"0.6698314",
"0.66831005",
"0.6672888",
"0.66654676",
"0.665959",
"0.6632213",
"0.6625551",
"0.66034657",
"0.6601465",
"0.6588254",
"0.65737456",
"0.6541957",
"0.64933103",
"0.6482925",
"0.64603746",
"0.64479744",
"0.64303905",
"0.64303905"
] | 0.73202336 | 1 |
/ integrate_bbc_buttons / aside from the function name and our modified values for $row_position, $col_position, and $newbuttons | function soulraver_smf_add_buttons(&$buttons) {
global $txt;
$row_position = 2; // Which row are we adding the buttons on (starting at 1)
$col_position = 15; // which col are we inserting the buttons
// Define the new buttons
$newbuttons = array(
array(
'image' => 'zomg_spoilers',
'code' => 'spoiler',
'before' => '[spoiler]',
'after' => '[/spoiler]',
'description' => $txt['spoiler']
),
array(
'image' => 'mythic_die',
'code' => 'roll',
'before' => '[roll]',
'after' => '[/roll]',
'description' => $txt['roll']
)
);
// Move from x,y coordinates to array values
$row_position--;
$col_position--;
// Get the individual button rows
foreach ($buttons as $sub_buttons)
$button_row[] = $sub_buttons;
// set the row bounds, not less than 0, not more than an extra row
$total_rows = count($buttons);
$row_position = min(max($row_position,0),$total_rows);
// If the user specified a new row add one
if ($row_position == $total_rows)
{
$button_row[$row_position] = array();
$total_rows++;
}
// Set the col bounds, not less than 0 not more than the number of columns in this row
$total_cols = count($button_row[$row_position]);
$col_position = min(max($col_position,0),$total_cols);
// Insert the new buttons in to the row and col specified
array_splice($button_row[$row_position], $col_position, $total_cols, array_merge($newbuttons, array_slice($button_row[$row_position], $col_position)));
// join the button array back together
$buttons = array();
for ($i = 0; $i < $total_rows; $i++)
$buttons[] = $button_row[$i];
return;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function configureButtons();",
"function bmks_integrate_display_buttons()\n{\n\tglobal $context, $scripturl;\n\n\tif (!$context['can_make_bookmarks'])\n\t{\n\t\treturn;\n\t}\n\n\tloadLanguage('Bookmarks');\n\n\t$url = $scripturl . '?action=bookmarks' . ($context['has_bookmark'] ? '' : ';sa=add;topic=' . $context['current_topic'] . ';' . $context['session_var'] . '=' . $context['session_id']);\n\n\t// Define the new button\n\t$bookmarks = array('bookmarks' => array(\n\t\t'test' => 'can_make_bookmarks',\n\t\t'text' => $context['has_bookmark'] ? 'bookmark_exists' : 'bookmark',\n\t\t'image' => 'bookmark.png',\n\t\t'lang' => true,\n\t\t'url' => $url\n\t));\n\n\t// Add bookmark to the normal button array\n\t$context['normal_buttons'] = elk_array_insert($context['normal_buttons'], 'reply', $bookmarks, 'after');\n}",
"function manipulate_insert_button($buttons) {\n $cNip= $this->user->gNIP;\n $data['upload']='upload_custom_grid';\n $js = $this->load->view('js/standard_js',$data,TRUE);\n\n $iframe = '<iframe name=\"v3_soi_mikro_bb_final_frame\" id=\"v3_soi_mikro_bb_final_frame\" height=\"0\" width=\"0\"></iframe>';\n\n $sql = \"SELECT a.* FROM plc3.m_modul m JOIN plc3.m_modul_activity a ON m.iM_modul = a.iM_modul WHERE idprivi_modules = ? AND m.lDeleted = 0 AND a.lDeleted = 0 ORDER BY a.iSort ASC LIMIT 1\";\n $act = $this->db->query($sql, array($this->modul_id))->row_array();\n\n $save_draft = '<button onclick=\"javascript:save_draft_btn_multiupload(\\'v3_soi_mikro_bb_final\\', \\' '.base_url().'processor/plc/v3_soi_mikro_bb_final?draft=true&modul_id='.$this->input->get('modul_id').'&iM_modul_activity='.$act['iM_modul_activity'].' \\',this,true )\" id=\"button_save_draft_v3_soi_mikro_bb_final\" class=\"ui-button-text icon-save\" >Save as Draft</button>';\n $save = '<button onclick=\"javascript:save_btn_multiupload(\\'v3_soi_mikro_bb_final\\', \\' '.base_url().'processor/plc/v3_soi_mikro_bb_final?company_id='.$this->input->get('company_id').'&modul_id='.$this->input->get('modul_id').'&iM_modul_activity='.$act['iM_modul_activity'].'&group_id='.$this->input->get('group_id').'modul_id='.$this->input->get('modul_id').' \\',this,false )\" id=\"button_save_submit_v3_soi_mikro_bb_final\" class=\"ui-button-text icon-save\" >Save & Submit</button>';\n\n $AuthModul = $this->lib_plc->getAuthorModul($this->modul_id);\n $arrTeam = explode(',',$this->team);\n $nipAuthor = explode(',', $AuthModul['vNip_author']);\n\n if( in_array($AuthModul['vDept_author'],$arrTeam ) || in_array($this->user->gNIP, $nipAuthor) ){\n\n $buttons['save'] = $iframe.$save_draft.$save.$js;\n }else{\n unset($buttons['save']);\n $buttons['save'] = '<span style=\"color:red;\" title=\"'.$AuthModul['vDept_author'].'\">You\\'re Dept not Authorized</span>';\n }\n \n \n return $buttons;\n }",
"public function setButtons();",
"function sal_bottom_theme_cta_buttons(){\n\n //get button option settings\n $buttons = get_field('theme_btm_call_to_action_button','options');\n $count_btns = count($buttons);\n\n if($buttons){\n $output = '<div class=\"bottom-cta-links\"><div class=\"container\"><div class=\"row\"><div class=\"cta-links-container\">';\n $col_class = '';\n\n if($count_btns == 1){\n $col_class = 'col-md-12';\n }elseif($count_btns == 2){\n $col_class = 'col-md-6';\n }else{\n $col_class = 'col-md-4';\n }\n\n\n foreach ($buttons as $btn) {\n $title = $btn['button_text'];\n $link = $btn['button_link'];\n $cta_link = (strpos($link,'tel:') !== false || strpos($link,'mailto:') !== false ? $link : addhttp($link) );\n $new_window = $btn['button_link_new_window'];\n $target = ($new_window ? '_blank' : '_self');\n \n $output.= '<div class=\"' . $col_class . '\"><div class=\"cta-link\"><a href=\"' . $cta_link . '\" target=\"' . $target . '\"><div class=\"btn-text\">' . $title . '</div></a></div></div>'; \n }\n\n $output.= '</div></div></div></div>';\n }\n\n return $output;\n}",
"protected function getButtons()\n {\n $buttonBar = $this->moduleTemplate->getDocHeaderComponent()->getButtonBar();\n if ($this->page_id) {\n if ((string)$this->table === 'pages') {\n $cshButton = $buttonBar->makeHelpButton()\n ->setModuleName('xMOD_csh_corebe')\n ->setFieldName('move_el_pages');\n $buttonBar->addButton($cshButton);\n } elseif ((string)$this->table === 'tt_content') {\n $cshButton = $buttonBar->makeHelpButton()\n ->setModuleName('xMOD_csh_corebe')\n ->setFieldName('move_el_cs');\n $buttonBar->addButton($cshButton);\n }\n\n if ($this->R_URI) {\n $backButton = $buttonBar->makeLinkButton()\n ->setHref($this->R_URI)\n ->setTitle($this->getLanguageService()->getLL('goBack'))\n ->setIcon($this->moduleTemplate->getIconFactory()->getIcon(\n 'actions-view-go-back',\n Icon::SIZE_SMALL\n ));\n $buttonBar->addButton($backButton);\n }\n }\n }",
"public static function addbuttons() {\n add_filter('mce_external_plugins', 'CrayonTagEditorWP::add_plugin');\n add_filter('mce_buttons', 'CrayonTagEditorWP::register_buttons');\n add_filter('bbp_before_get_the_content_parse_args', 'CrayonTagEditorWP::bbp_get_the_content_args');\n }",
"function cb_register_buttons_editor( $buttons ) {\n\tarray_push(\n\t\t$buttons,\n\t\t//'col_6',\n\t\t//'col_4',\n\t\t'blockquote_warning',\n\t\t'blockquote_info',\n\t\t'blockquote_danger',\n\t\t'blockquote_check',\n\t\t'blockquote_quote',\n\t\t'blockquote_important',\n\t\t//'content_btn',\n\t\t'spoiler_btn',\n\t\t'mark_btn',\n\t\t'mask_link'\n\t);\n\treturn $buttons;\n}",
"function toolbar_button($v='',$columns='input-three-column',$style='')\n {\n $s = '\n <div class=\"curvy bordered clearfix \" style=\"height:130px;\" >\n <label for=\"s1\" class=\"shadow curvy\" style=\"width:50px;background:url(http://localhost/CodeIgniter/images/download.gif) no-repeat\">.</label>\n <label for=\"s1\" class=\"shadow curvy\" style=\"width:50px;background:url(http://localhost/CodeIgniter/images/notice.png) no-repeat\"> </label>\n <label for=\"s1\" class=\"shadow curvy\" style=\"width:80px;background:url(http://localhost/CodeIgniter/images/sandbox.png) no-repeat 10px 3px;\"> </label>\n <label for=\"s1\" class=\"shadow curvy\" style=\"width:90px;height:80px;background:url(http://localhost/CodeIgniter/images/tools.png) no-repeat 10px 3px;\" > </label>\n <label for=\"s1\" class=\"shadow curvy\" style=\"width:90px;height:80px;background:url(http://localhost/CodeIgniter/images/settings.png) no-repeat 10px 3px;\" > </label>\n\n</div>\n <div class=\"shadow curvy\" style=\"width:250px;height:35px;background:url(http://localhost/CodeIgniter/images/edit.png) no-repeat;\" ><a href:\"#\"> </a> </div>\n <div class=\"shadow curvy\" style=\"width:38px;height:38px;float:left;background:#eeeeec url(http://localhost/CodeIgniter/images/icons/av_beginning.png) no-repeat;\" ><a href:\"#\"> </a> </div>\n <div class=\"shadow curvy\" style=\"width:38px;height:38px;float:left;background:url(http://localhost/CodeIgniter/images/icons/av_pause.png) no-repeat;\" ><a href:\"#\"> </a> </div>\n <div class=\"shadow curvy\" style=\"width:38px;height:38px;float:left;background:url(http://localhost/CodeIgniter/images/icons/av_play.png) no-repeat;\" ><a href:\"#\"> </a> </div>\n <div class=\"shadow curvy\" style=\"width:38px;height:38px;float:left;background:url(http://localhost/CodeIgniter/images/icons/av_end.png) no-repeat;\" ><a href:\"#\"> </a> </div>\n <div class=\"shadow curvy\" style=\"width:38px;height:38px;float:left;background:url(http://localhost/CodeIgniter/images/icons/database.png) no-repeat;\" ><a href:\"#\"> </a> </div>\n\n ';\n return $s;\n }",
"function shortcode_insert_button()\n\t\t\t\t{\n\t\t\t\t\t$this->config['self_closing']\t=\t'yes';\n\t\t\t\t\t\n\t\t\t\t\t$this->config['name']\t\t= __('Page Split', 'avia_framework' );\n\t\t\t\t\t$this->config['tab']\t\t= __('Layout Elements', 'avia_framework' );\n\t\t\t\t\t$this->config['icon']\t\t= AviaBuilder::$path['imagesURL'].\"sc-heading.png\";\n\t\t\t\t\t$this->config['order']\t\t= 5;\n\t\t\t\t\t$this->config['target']\t\t= 'avia-target-insert';\n\t\t\t\t\t$this->config['shortcode'] \t= 'av_sc_page_split';\n\t $this->config['tinyMCE'] \t= array('disable' => \"true\");\n\t\t\t\t\t$this->config['tooltip'] \t= __('Add a page split to the template. A pagination helps the user to navigate to the previous/next page.', 'avia_framework' );\n\t $this->config['drag-level'] = 1;\n\t\t\t\t}",
"function register_button( $buttons ) {\n array_push( $buttons, \"|\", \"insert_shortcodes\" );\n return $buttons;\n}",
"function add_button($record_id, $add_page_url, $record_var = 'id', $add_title='Click here to add a new record to this table', $add_url = '') {\n?>\n\n<div class=\"row\"><!-- start add button row (function) -->\n\t<!-- start add button div -->\n\t<div class=\"col-md-1\">\n\t\t<a href=\"<?php \n\t\t\n\t\t\techo $add_page_url; \n\t\t\t\n\t\t?>.php?<?php \n\t\t\n\t\t\techo $record_var; \n\t\t\t\n\t\t?>=<?php \n\t\t\n\t\t\techo $record_id;\n\t\t\tif ((substr($add_url,0,1)!='&')) {\n\t\t\t\techo '&';\n\t\t\t} \n\t\t\techo $add_url; \n\t\t\t\n\t\t?>\" class=\"mb-xs mt-xs mr-xs btn btn-success pull-left\" title=\"<?php \n\t\t\n\t\t\techo $add_title; \n\t\t\t\n\t\t?>\">\n\t\t <i class=\"fa fa-plus-square\"></i>\n\t\t</a>\n\t</div>\n\t<!-- end add button div -->\n\t<!-- empty container for remaining space -->\n\t<div id=\"feature_buttons_container_id\" class=\"col-md-11\">\n\t</div>\n\t<!-- end empty div -->\n\t\n </div><!-- end add button row (function) -->\n \n <?php \n }",
"function tz_register_rich_buttons( $buttons )\n\t{\n\t\tarray_push( $buttons, \"|\", 'tz_button' );\n\t\treturn $buttons;\n\t}",
"function displaybuttons($buttonarray) {\n\n // double quote\n $dq = '\"';\n \n for ($i = 0; $i < count($buttonarray); $i++) {\n switch ($buttonarray[$i]) {\n case \"Update\":\n $GLOBALS['buttons'] .= \"<input type=\" . $dq . \"submit\" . $dq . \" name=\" . $dq . \"btnUpdate\" . $dq . \" value=\" . $dq . \"Update\" . $dq . \"> \";\n break;\n case \"Add\":\n $GLOBALS['buttons'] .= \"<input type=\" . $dq . \"submit\" . $dq . \" name=\" . $dq . \"btnInsert\" . $dq . \" value=\" . $dq . \"Add\" . $dq . \"> \";\n break;\n case \"Delete\":\n $GLOBALS['buttons'] .= \"<input type=\" . $dq . \"submit\" . $dq . \" name=\" . $dq . \"btnDelete\" . $dq . \" value=\" . $dq . \"Delete\" . $dq . \"> \";\n break;\n case \"Cancel\":\n $GLOBALS['buttons'] .= \"<input type=\" . $dq . \"submit\" . $dq . \" name=\" . $dq . \"btnCancel\" . $dq . \" value=\" . $dq . \"Cancel\" . $dq . \"> \";\n break;\n case \"Continue\":\n $GLOBALS['buttons'] .= \"<input type=\" . $dq . \"submit\" . $dq . \" name=\" . $dq . \"btnContinue\" . $dq . \" value=\" . $dq . \"Continue\" . $dq . \"> \";\n break;\n }\n }\n}",
"function register_rich_buttons( $buttons )\n\t{\n\t\tarray_push( $buttons, \"|\", 'cdo_button' );\n\t\treturn $buttons;\n\t}",
"function shortcode_insert_button()\n {\n $this->config['name']\t\t\t= __('Image ContentCarousel', '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= 11;\n $this->config['target']\t\t\t= 'avia-target-insert';\n $this->config['shortcode'] \t\t= 'sw_image_carousel';\n $this->config['shortcode_nested'] = array('sw_image_content_slider');\n $this->config['tooltip'] \t = __('Display a image carousel element', 'swedenWp' );\n }",
"protected function putHtmlButtonsPanel(){\r\n\t\t\t\t\r\n\t\t?>\r\n\t\t<div class=\"uc-buttons-panel unite-clearfix\">\r\n\t\t\t<a href=\"<?php echo esc_attr($this->urlViewCreateObject)?>\" class=\"unite-button-primary unite-float-left\"><?php HelperUC::putText(\"new_layout\");?></a>\r\n\t\t\t\r\n\t\t\t<a id=\"uc_button_import_layout\" href=\"javascript:void(0)\" class=\"unite-button-secondary unite-float-left mleft_20\"><?php HelperUC::putText(\"import_layouts\");?></a>\r\n\t\t\t\r\n\t\t\t<a href=\"javascript:void(0)\" id=\"uc_layouts_global_settings\" class=\"unite-float-right mright_20 unite-button-secondary\"><?php HelperUC::putText(\"layouts_global_settings\");?></a>\r\n\t\t\t<a href=\"<?php echo esc_attr($this->urlManageAddons)?>\" class=\"unite-float-right mright_20 unite-button-secondary\"><?php esc_html_e(\"My Addons\", \"unlimited_elements\")?></a>\r\n\t\t\t\r\n\t\t</div>\r\n\t\t<?php \r\n\t}",
"function register_button_3($buttons) { \n array_push($buttons, \"teaser\", \"teaserbox\", \"iconbox\",\"member\", \"skill\", \"blog\", \"bloglist\", \"testimonial\",\"recipe_grid\",\"recipe_list\", \"recipe_single\", \"recipe_slider\",\"product_slider\",\"author\", \"callout\", \"gap\"); \n return $buttons; \n}",
"function frame_init_mce_buttons_2($buttons)\n{\n $add_buttons = frame_config('editor.add_buttons');\n $remove_buttons = frame_config('editor.remove_buttons');\n\n if (!empty($add_buttons))\n foreach ($add_buttons as $button)\n $buttons[] = $button;\n\n if (!empty($remove_buttons))\n $buttons = array_diff($buttons, $remove_buttons);\n\n if (!empty(frame_config('editor.style_formats')))\n array_unshift($buttons, 'styleselect');\n\n return $buttons;\n}",
"public function buttons()\n {\n?>\n <div class=\"drag_drop_save\">\n <input type=\"submit\" name=\"update\" value=\"Update ranking\" title=\"Save your rank\" class=\"tooltip save_sortable_collage\" />\n <input type=\"submit\" name=\"delete\" value=\"Delete checked\" title=\"Remove items\" class=\"tooltip save_sortable_collage\" />\n </div>\n<?php\n }",
"function tfc_big_title_buttons_callback() {\n\n $tfc_big_title_first_btn_text = get_theme_mod( 'hestia_big_title_button_text', __( 'First button text', 'tfc' ) );\n $tfc_big_title_first_btn_link = get_theme_mod( 'hestia_big_title_button_link', '#' );\n $tfc_big_title_second_btn_text = get_theme_mod( 'tfc_big_title_second_button_text', __( 'Second button text', 'tfc' ) );\n $tfc_big_title_second_btn_link = get_theme_mod( 'tfc_big_title_second_button_link', '#' );\n\n if ( ! empty( $tfc_big_title_first_btn_text ) ) {\n ?>\n <a href=\"<?php echo esc_url( $tfc_big_title_first_btn_link ); ?>\" title=\"<?php echo esc_attr( $tfc_big_title_first_btn_text ); ?>\" class=\"btn btn-primary btn-lg\" <?php echo hestia_is_external_url( $tfc_big_title_first_btn_link ); ?>><?php echo esc_html( $tfc_big_title_first_btn_text ); ?></a>\n <?php\n }\n\n if ( ! empty( $tfc_big_title_second_btn_text ) ) {\n ?>\n <a href=\"<?php echo esc_url( $tfc_big_title_second_btn_link ); ?>\" title=\"<?php echo esc_attr( $tfc_big_title_second_btn_text ); ?>\" class=\"btn btn-trans btn-right btn-lg\" <?php echo hestia_is_external_url( $tfc_big_title_second_btn_link ); ?>><?php echo esc_html( $tfc_big_title_second_btn_text ); ?></a>\n <?php\n }\n}",
"function vtsc_button( $atts, $content = null ) {\n extract(shortcode_atts(array(\t'size' \t\t=> 'btn-md',\n\t\t\t\t\t\t\t\t\t'shape'\t\t=> 'btn-rounded',\n\t\t\t\t\t\t\t\t\t'color' \t=> 'btn-theme-color',\n\t\t\t\t\t\t\t\t\t'position'\t=> 'btn-align-none',\n\t\t\t\t\t\t\t\t\t'icon'\t\t=> '',\n\t\t\t\t\t\t\t\t\t'target'\t=> '_self',\n\t\t\t\t\t\t\t\t\t'url'\t\t=> '#'\n\t\t\t\t\t\t\t\t\t), $atts));\n\t$icon = $icon!='' ? '<i style=\"font-size: 110%; margin-right:10px\" class=\"fa '.$icon.'\"></i>':false;\n\tif($position=='btn-align-none') { return '<div class=\"btn-wrap\"><a href=\"' . $url . '\" target=\"'. $target .'\" class=\"' . $size . ' ' . $shape . ' ' . $color . ' btn btn-default\">' . $icon . do_shortcode($content) . '</a></div>'; }\n\telse { return '<div class=\"btn-wrap '. $position .'\"><a href=\"' . $url . '\" target=\"'. $target .'\" class=\"' . $size . ' ' . $shape . ' ' . $color . ' btn btn-default\">' . $icon . do_shortcode($content) . '</a></div><div class=\"clearfix\"></div>'; }\n\t\n}",
"function sp_ScoutnetKalender_Button()\n{\n\t// Set up some unique button image URLs for the new buttons from the plugin directory\n\t$kalender_button = buttonsnap_dirname(__FILE__) . '/bilder/ical_einzeln.png';\n\t// Calling buttonsnsap_dirname() with a filename returns the URL of that file's directory\n\t// Calling buttonsnsap_dirname() without a filename returns the URL of the active buttonsnap class' directory\n\n\t// Create a vertical separator in the WYSI toolbar (does nothing in the Quicktags):\n\t//buttonsnap_separator();\n\n\t// Create a button that changes the selected text to something specific:\n\t//buttonsnap_textbutton($button_image_url1, 'Text Button', 'Help?<br/><!--help-->');\n\t\n\t// Register an image marker to display in the RTE instead of an invisible comment:\n\t//buttonsnap_register_marker('help', 'ebt_marker');\n\t// 'help' is the text that will be replaced with an image in the RTE.\n\t// 'ebt_marker' is the CSS class that is used to display the marker in the RTE.\n\t// The my_button_marker_css() hook sink adds CSS to display a graphic for that selector class.\n\t\n\t// Create a button that executes the provided javascript:\n\t$kalender_JS = 'window.open(\"'.buttonsnap_dirname(__FILE__).'/sp_buttonsnap-popup.php\", \"ScoutnetKalender\", \"width=470,height=230,scrollbars=yes\");';\n\tbuttonsnap_jsbutton($kalender_button, 'Termin oder Kalender einfügen', $kalender_JS);\n\t\n\t// Create a button that uses Ajax to fetch replacement text from a WordPress plugin hook sink:\n\t//buttonsnap_ajaxbutton($button_image_url3, 'Ajax Button', 'my_hook');\n\t//add_filter('my_hook', 'my_hook_sink');\n}",
"function pu_add_buttons( $plugin_array )\n{\n global $wp_version;\n if ( $wp_version >= 3.8 ) {\n $jsfile = 'picatic-shortcode/inc/js/shortcode-tinymce-button-3.9.js';\n } else {\n $jsfile = 'picatic-shortcode/inc/js/shortcode-tinymce-button.js';\n }\n $plugin_array['pushortcodes'] = plugin_dir_url( __FILE__ ) . $jsfile;\n\n return $plugin_array;\n}",
"public static function addbuttons() {\n\t\t//if ( get_user_option('rich_editing') == 'true') {\n\t\tadd_filter('mce_external_plugins', 'CrayonTagEditorWP::add_plugin');\n\t\tadd_filter('mce_buttons', 'CrayonTagEditorWP::register_buttons');\n\t}",
"function wpshop_register_buttons_editor( $buttons ) {\n array_push(\n $buttons,\n //'col_6',\n //'col_4',\n 'blockquote_warning',\n 'blockquote_info',\n 'blockquote_danger',\n 'blockquote_check',\n 'blockquote_quote'\n );\n return $buttons;\n}",
"function bmks_integrate_menu_buttons(&$buttons)\n{\n\tglobal $scripturl, $txt, $modSettings;\n\n\t$bookmarks_off = empty($modSettings['bookmarks_enabled']) || !allowedTo('make_bookmarks');\n\n\tif ($bookmarks_off)\n\t{\n\t\treturn;\n\t}\n\n\tloadLanguage('Bookmarks');\n\n\t// Where do we want to place the My Bookmarks button\n\t$insert_after = 'theme';\n\n\t// Define the new menu item(s), this will call for GoogleMap.controller\n\t$new_menu = array(\n\t\t'bookmarks' => array(\n\t\t\t'title' => $txt['bookmarks'],\n\t\t\t'href' => $scripturl . '?action=bookmarks',\n\t\t\t'show' => true,\n\t\t)\n\t);\n\n\t$buttons['profile']['sub_buttons'] = elk_array_insert($buttons['profile']['sub_buttons'], $insert_after, $new_menu, 'after');\n}",
"function shortcode_insert_button()\n\t\t\t{\n\t\t\t\t$this->config['self_closing']\t=\t'no';\n\t\t\t\t\n\t\t\t\t$this->config['name']\t\t= __('Headline Rotator', 'avia_framework' );\n\t\t\t\t$this->config['tab']\t\t= __('Content Elements', 'avia_framework' );\n\t\t\t\t$this->config['icon']\t\t= AviaBuilder::$path['imagesURL'].\"sc-heading.png\";\n\t\t\t\t$this->config['order']\t\t= 85;\n\t\t\t\t$this->config['target']\t\t= 'avia-target-insert';\n\t\t\t\t$this->config['shortcode'] \t= 'av_headline_rotator';\n\t\t\t\t$this->config['shortcode_nested'] = array('av_rotator_item');\n\t\t\t\t$this->config['tooltip'] \t= __('Creates a text rotator for dynamic headings', 'avia_framework' );\n\t\t\t\t$this->config['preview'] \t= \"large\";\n\t\t\t}",
"function register_button( $buttons ) {\n\n\t\tarray_push( $buttons, 'demobutton2' );\n\n\t\treturn $buttons;\n\t}",
"function ct_toll_free_buttons() {\n \n $returnhtml .= '<div class=\"grid-x grid-margin-x cols2-s2 info_boxes\">';\n // Check rows exists.\n if( have_rows('call_to_action_btns') ):\n\n // Loop through rows.\n while( have_rows('call_to_action_btns') ) : the_row();\n\n // Load sub field value.\n $sub_text = explode(\" \", get_sub_field('sub_text'));\t\t\t\t\t\t\t\n $main_text = get_sub_field('main_text');\n \n $returnhtml .= '<div class=\"cell small-6 medium-6 large-6 col-item\">';\n $returnhtml .= '<a class=\"info_box\" href=\"tel:'.$main_text.'\">';\n $returnhtml .= '<figure class=\"icon_wrapper\"></figure>';\n for( $i=0; $i <= count($sub_text); $i++ ){\n $returnhtml .= '<div class=\"address\">'. $sub_text[$i] . '</div>';\n }\n $returnhtml .= '<div class=\"phone\">'.$main_text.'</div>';\n $returnhtml .= '</a>';\n $returnhtml .= '</div>';\n\n // End loop.\n endwhile;\n endif;\t\t\n $returnhtml .= '</div>';\n return $returnhtml;\n}"
] | [
"0.6581035",
"0.6327568",
"0.6210414",
"0.6193537",
"0.61580706",
"0.6149551",
"0.6082829",
"0.6071539",
"0.59914076",
"0.594113",
"0.5929819",
"0.5899102",
"0.5898732",
"0.5897694",
"0.58956945",
"0.5879278",
"0.58530223",
"0.58075863",
"0.5799796",
"0.57866585",
"0.57743675",
"0.5754705",
"0.5754333",
"0.57492566",
"0.5748826",
"0.57462585",
"0.5720587",
"0.5711816",
"0.5695853",
"0.5689619"
] | 0.69646007 | 0 |
Wrapper and actualiser to add a portal. Does not return. | function add_portal_wrap($member_id,$name,$text,$end_location_realm,$end_location_x,$end_location_y)
{
if ($end_location_realm==-1) $end_location_realm=NULL;
// Get $realm,$x,$y from $member_id
list($realm,$x,$y)=get_loc_details($member_id);
if (is_null($end_location_realm)) ocw_refresh_with_message(do_lang_tempcode('W_MISSING_DESTINATION_REALM'),'warn');
if ((is_null($end_location_x)) || (is_null($end_location_y))) ocw_refresh_with_message(do_lang_tempcode('W_MISSING_DESTINATION'),'warn');
if ($name=='') ocw_refresh_with_message(do_lang_tempcode('W_MISSING_NAME'),'warn');
// Check $end_location_realm exists
$allow_portal=$GLOBALS['SITE_DB']->query_value_null_ok('w_rooms','allow_portal',array('location_x'=>$end_location_x,'location_y'=>$end_location_y,'location_realm'=>$end_location_realm));
if (is_null($allow_portal))
ocw_refresh_with_message(do_lang_tempcode('W_NO_END'),'warn');
if ($allow_portal==0) ocw_refresh_with_message(do_lang_tempcode('W_BAD_END'),'warn');
// Check we don't have a portal to this realm here already
$t=$GLOBALS['SITE_DB']->query_value_null_ok('w_portals','name',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm,'end_location_realm'=>$end_location_realm));
if (!is_null($t)) ocw_refresh_with_message(do_lang_tempcode('W_DUPE_END'),'warn');
if ($GLOBALS['SITE_DB']->query_value('w_rooms','allow_portal',array('location_x'=>$x,'location_y'=>$y,'location_realm'=>$realm))==0)
ocw_refresh_with_message(do_lang_tempcode('W_BAD_START'),'warn');
if ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$realm))!=$member_id) && ($GLOBALS['SITE_DB']->query_value('w_realms','r_private',array('id'=>$realm))==1))
ocw_refresh_with_message(do_lang_tempcode('W_NO_EDIT_ACCESS_PRIVATE_REALM'),'warn');
/* if ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$end_location_realm))!=$member_id) && ($GLOBALS['SITE_DB']->query_value('w_realms','r_private',array('id'=>$end_location_realm))==1))
ocw_refresh_with_message(do_lang_tempcode('W_NO_EDIT_ACCESS_PRIVATE_REALM'),'warn');*/
// Charge them
if (!has_specific_permission($member_id,'administer_ocworld'))
{
require_code('points2');
$price=get_price('mud_portal');
if (available_points($member_id)<$price) ocw_refresh_with_message(do_lang_tempcode('W_EXPENSIVE',integer_format($price)),'warn');
charge_member($member_id,$price,do_lang('W_MADE_PORTAL_OCWORLD',$name));
}
add_portal($name,$text,$realm,$x,$y,$end_location_realm,$member_id,$end_location_x,$end_location_y);
$destname=$GLOBALS['SITE_DB']->query_value('w_realms','name',array('id'=>$end_location_realm));
ocw_refresh_with_message(do_lang_tempcode('W_PORTAL_CREATED',escape_html($name),escape_html($destname)));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function add_portal($name,$text,$realm,$x,$y,$end_location_realm,$owner,$end_location_x,$end_location_y)\n{\n\t$GLOBALS['SITE_DB']->query_insert('w_portals',array(\n\t\t'name'=>$name,\n\t\t'p_text'=>$text,\n\t\t'start_location_realm'=>$realm,\n\t\t'start_location_x'=>$x,\n\t\t'start_location_y'=>$y,\n\t\t'end_location_realm'=>$end_location_realm,\n\t\t'end_location_x'=>$end_location_x,\n\t\t'end_location_y'=>$end_location_y,\n\t\t'owner'=>$owner,\n\t));\n}",
"public function setPortal($portal)\n {\n $this->portal = $portal;\n }",
"function Add()\n{\n\tglobal $context, $scripturl, $txt, $settings, $smcFunc, $user_info, $ultimateportalSettings;\n\n\tif(empty($_POST['save']))\n\t\tcheckSession('get');\n\t\t\n\tif (empty($ultimateportalSettings['ipage_enable']))\n\t\tfatal_lang_error('ultport_error_no_active',false);\n\n\tif (!$user_info['is_admin'] && !$user_info['up-modules-permissions']['ipage_add'])\n\t\tfatal_lang_error('ultport_error_no_perms_groups',false);\n\n\tif (!empty($_REQUEST['type']) && !in_array($_REQUEST['type'], array('html', 'bbc')))\n\t\tfatal_lang_error('ultport_error_no_action',false);\n\n\tif (!empty($_POST['save']))\n\t{\n\t\tcheckSession('post');\n\t\tif (empty($_POST['title']))\n\t\t\tfatal_lang_error('ultport_error_no_add_ipage_title',false);\n\n\t\t$title = (string)$smcFunc['htmlspecialchars']($_POST['title']);\n\t\t$column_left = !empty($_POST['column_left']) ? (int)$_POST['column_left'] : 0;\n\t\t$column_right = !empty($_POST['column_right']) ? (int)$_POST['column_right'] : 0;\n\t\t$content = ($_POST['type_ipage'] == 'html') ? $_POST['elm1'] : (string)$smcFunc['htmlspecialchars']($_POST['ipage_content'], ENT_QUOTES);\t\n\t\t$content = $smcFunc['htmltrim']($content, ENT_QUOTES);\n\t\t$id_member = (int) $user_info['id'];\n\t\t$username = (string) $user_info['username'];\n\t\t$date_created = time();\n\t\t$type_ipage = $_POST['type_ipage'];\n\t\t$permissionsArray = array();\n\t\tif (!empty($_POST['perms']))\n\t\t{\n\t\t\tforeach ($_POST['perms'] as $rgroup)\n\t\t\t\t$permissionsArray[] = (int) $rgroup;\n\t\t}\n\t\t$finalPermissions = implode(\",\",$permissionsArray);\n\t\t$active = !empty($_POST['active']) ? $_POST['active'] : 'off';\n\t\t$sticky = !empty($_POST['sticky']) ? $_POST['sticky'] : 0;\n\t\t\n\t\t//Now insert the NEWS in the smf_up_news\t\t\t\n\t\t$smcFunc['db_insert']('replace',\n\t\t\t'{db_prefix}ultimate_portal_ipage',\n\t\t\tarray(\n\t\t\t\t'title' => 'string', 'sticky' => 'int', 'active' => 'string', 'type_ipage' => 'string', 'content' => 'string', 'perms' => 'string', 'column_left' => 'int', 'column_right' => 'int', 'date_created' => 'int', 'id_member' => 'int', 'username' => 'string',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t$title,$sticky,$active,$type_ipage,$content,$finalPermissions,$column_left,$column_right,$date_created,$id_member,$username\n\t\t\t),\n\t\t\tarray('id')\n\t\t);\n\t\tredirectexit('action=internal-page');\t\t\n\t}\n\t//Load Member Groups\n\tLoadMemberGroups();\n\t\n\t//Type Internal Page\n\t$context['type_ipage'] = !empty($_REQUEST['type']) ? $smcFunc['db_escape_string']($_REQUEST['type']) : 'html';\t\n\t//Load the Editor HTML or BBC?\n\tif ($_REQUEST['type'] == 'html')\n\t{\n\t\tcontext_html_headers(\"elm1\");\n\t\t$type_ipage_linktree = $txt['up_ipage_add_html'];\n\t}\t\n\tif ($_REQUEST['type'] == 'bbc')\n\t{\n\t\t// Now create the editor.\n\t\t$editorOptions = array(\n\t\t\t'id' => 'ipage_content',\n\t\t\t'value' => '',\n\t\t\t'form' => 'ipageform',\n\t\t);\n\t\t$context['smileyBox_container'] = 'smileyBox_'.$editorOptions['id'];\n\t\t$context['bbcBox_container'] = 'bbcBox_'.$editorOptions['id'];\n\t\tup_create_control_richedit($editorOptions);\t\n\t\t$context['post_box_name'] = $editorOptions['id'];\n\t\t$type_ipage_linktree = $txt['up_ipage_add_bbc'];\t\t\t\t\n\t}\n\t$context['news-linktree'] = ' <img alt=\"\" border=\"0\" src=\"'.$settings['default_images_url'].'/ultimate-portal/open_linktree.gif\" /> <a href=\"'. $scripturl .'?action=internal-page\">'. $txt['up_module_ipage_title'] .'</a> <br /><img alt=\"\" border=\"0\" src=\"'.$settings['default_images_url'].'/ultimate-portal/linktree_side.gif\" /> '. $type_ipage_linktree;\t\n\n\t$context['linktree'][1] = array(\n\t\t'url' => $scripturl . '?action=internal-page',\n\t\t'name' => $txt['up_module_ipage_title']\n\t);\t\n\t$context['sub_template'] = 'add';\n\t$context['page_title'] = $type_ipage_linktree;\n}",
"function delete_portal_wrap($member_id,$dest_realm)\n{\n\tlist($realm,$x,$y)=get_loc_details($member_id);\n\n\t$attempt_member=$member_id;\n\tif ((!has_specific_permission($attempt_member,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_portals','owner',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm,'end_location_realm'=>$dest_realm))!=$attempt_member)) ocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');\n\n\t$name=$GLOBALS['SITE_DB']->query_value('w_portals','name',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm));\n\n\t// Refund them\n\trequire_code('points2');\n\t$price=get_price('mud_portal');\n\tcharge_member($attempt_member,intval(-0.7*$price),do_lang('W_DELETE_PORTAL_OCWORLD',$name));\n\n\tdelete_portal($x,$y,$realm,$dest_realm);\n}",
"public function getPortal()\n {\n return $this->portal;\n }",
"protected function _addSite()\n {\n $name = \"website \";\n $idsite = Piwik_SitesManager_API::getInstance()->addSite($name,array(\"http://piwik.net\",\"http://piwik.com/test/\"));\n $this->assertInternalType(PHPUnit_Framework_Constraint_IsType::TYPE_INT, $idsite);\n\n $siteInfo = Piwik_SitesManager_API::getInstance()->getSiteFromId($idsite);\n $this->assertEquals($name, $siteInfo['name']);\n $this->assertEquals(\"http://piwik.net\", $siteInfo['main_url']);\n\n $siteUrls = Piwik_SitesManager_API::getInstance()->getSiteUrlsFromId($idsite);\n $this->assertEquals(array(\"http://piwik.net\",\"http://piwik.com/test\"), $siteUrls);\n\n return $idsite;\n }",
"public function setPortalUrl($val)\n {\n $this->_propDict[\"portalUrl\"] = $val;\n return $this;\n }",
"public function add()\n\t{\n\t\tif (!parent::add()) {\n\t\t\t// Redirect to the return page.\n\t\t\t$this->setRedirect($this->getReturnPage());\n\t\t}\n\t}",
"public function add_panel(): void {\n\t\tif ( $this->panel ) {\n\t\t\tKirki::add_panel(\n\t\t\t\t$this->panel['id'],\n\t\t\t\t[\n\t\t\t\t\t'priority' => $this->panel['priority'] ?? 10,\n\t\t\t\t\t'title' => esc_html( $this->panel['title'] ),\n\t\t\t\t\t'description' => esc_html( $this->panel['description'] ),\n\t\t\t\t]\n\t\t\t);\n\t\t}\n\t}",
"public function add() {\n global $wpdb;\n\n delete_option('dotpay_'.$this->name.'_title');\n add_option('dotpay_'.$this->name.'_title', $this->title, '', 'yes');\n\n $page = get_page_by_title($this->title);\n\n if (!$page) {\n $info = array();\n $info['post_title'] = $this->title;\n $info['post_content'] = \"[dotpay_content]\";\n $info['post_status'] = 'publish';\n $info['post_type'] = 'page';\n $info['comment_status'] = 'closed';\n $info['ping_status'] = 'closed';\n $info['guid'] = $this->guid;\n $info['post_category'] = array(1);\n\n $pageId = wp_insert_post($info);\n }\n else {\n $page->post_status = 'publish';\n $pageId = wp_update_post($page);\n }\n\n delete_option('dotpay_'.$this->name.'_id');\n add_option('dotpay_'.$this->name.'_id', $pageId);\n }",
"public function store(Request $request)\n {\n $user_id = $request->user_id;\n\n $this->validate($request, [\n 'name' => 'required|max:255',\n 'description' => 'required|max:255',\n ]);\n\n $portal = Portal::create([\n 'name' => $request->name,\n 'description' => $request->description,\n 'user_id' => $user_id\n ]);\n\n return redirect()->route('portal.show', $portal->id)->with('message', \"$portal->name created successfully.\");\n }",
"public function portal()\n {\n return $this->state(function (array $attributes) {\n return [\n 'disappear_at' => null,\n 'type' => 'portal'\n ];\n });\n }",
"public function testMainsectionAddSameNameOtherPortal() {\n $por_name1 = 'a first portal';\n $por_id1 = self::$base->portal->portal_add($this->token, $por_name1);\n $por_name2 = 'a second portal';\n $por_id2 = self::$base->portal->portal_add($this->token, $por_name2);\n \n $mse_name = 'a section';\n $id1 = self::$base->portal->mainsection_add($this->token, $por_id1, $mse_name);\n $id2 = self::$base->portal->mainsection_add($this->token, $por_id2, $mse_name);\n $this->assertGreaterThan($id1, $id2);\n }",
"public function add()\n {\n $msg = JText::_('COM_PARKWAY_POST_ADDED');\n $this->setRedirect('index.php?option=com_parkway', $msg);\n }",
"public function add();",
"public function add(){}",
"function panel_add( $panels ) {\n\n\t\t$panels[ $this->option_panel_id ] = array(\n\t\t\t'id' => $this->option_panel_id,\n\t\t\t'style' => false,\n\n\t\t);\n\n\t\treturn $panels;\n\t}",
"public function setPortalType($portalType)\n {\n $this->portalType = $portalType;\n return $this;\n }",
"function advertising_add_page() {\n $controller = entity_ui_controller('advertising');\n return $controller->addPage();\n}",
"public function add() {\n\n\t}",
"function page_add($id=null)\n\t{\n\t\t\tif(empty($id) && empty($this->data['wp_server_id']))\n\t\t\t{\n\t\t\t\t$this->redirect('/dashboards/');\n\t\t\t}\n\t\t\tif(empty($id))\n\t\t\t$s_id=$this->data['wp_server_id']; //this is for detecting call by dashboard or form\n\t\t\telse\n\t\t\t$s_id=$id;\n\t\t\t\t\t\t\n\t\t\tif(!($this->_checkId($s_id)))\n\t\t\t{\n\t\t\t\t$this->redirect('/dashboards/');\n\t\t\t}\t\n\t\t\tif(!empty($this->data))\n\t\t\t{\n\t\t\t\t$title=trim($this->data['title']);\n\t\t\t\t$page_desc=trim($this->data['page_desc']);\n\t\t\t\t$id=trim($this->data['wp_server_id']);\n\t\t\t\tif($title==\"\" || $page_desc==\"\" || $id==\"\")\n\t\t\t\t{\n\t\t\t\t\t$this->set('msg',\"<font color='red'>Please fill form</font>\");\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\t\n\t\t\t\t\n\t\t\t\t\t$this->WpServer->id = $id;\n\t\t\t\t\t$wp_server=$this->WpServer->read();\n\t\t\t\t\t$wp_server['WpServer']['rpc_url']=trim($wp_server['WpServer']['rpc_url']);\n\t\t\t\t\tApp::import('Vendor', 'remotepost');\n\t\t\t\t\n\t\t\t\t\ttry\n\t\t\t\t\t{\n\t\t\t\t\t\t$page_exists=false;\n\t\t\t\t\t\t$this->client = new IXR_Client($wp_server['WpServer']['rpc_url']); //making client\n\t\t\t\t\t\t$content['title']=$title;\n\t\t\t\t\t\t$content['description']=$page_desc;\n\t\t\t\t\t\n\t\t\t\t\t\t$this->client->query('wp.getPageList','',$wp_server['WpServer']['wp_admin_id'],$wp_server['WpServer']['wp_admin_password']);\n\t\t\t\t\t\t$pages=$this->client->getResponse();\n\t\t\t\t\t\tforeach($pages as $key => $value) //checking already exist in wp server or not.if exists then no need to add page.else add page.\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($value['page_title']==$title)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$page_exists=true;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//exit;\n\t\t\t\t\t\t\n\t\t\t\t\t\t//limit setting\n\t\t\t\t\t\t$this->loadModel('UserPlan');\n\t\t\t\t\t\t$user_id=$this->Session->read('user_id');\n\t\t\t\t\t\t$plan=$this->UserPlan->query(\"select plans.name,plans.page_limit,user_plans.page_limit,user_plans.id from plans inner join user_plans on plans.id=user_plans.plan_id \". \t\t\t\t\t\t\t\t\t\t \t\t\t\" where user_plans.user_id=$user_id\");\n\t\t\n\t\t\t\t\t\t$plan_page_limit=$plan[0]['plans']['page_limit'];\n\t\t\t\t\t\t$user_page_limit=$plan[0]['user_plans']['page_limit'];\n\t\t\t\t\t\tif($plan_page_limit!='umlimited')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//$this->set('user_page',$user_page_limit);\n\t\t\t\t\t\t\t//$this->set('total',$plan_blog_limit);\n\t\t\t\t\t\t\tif($user_page_limit <=0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$message=\"Please upgrade your plan. User page limit has exceeded\";\n\t\t\t\t\t\t\t\t$this->Session->setFlash($message);\n\t\t\t\t\t\t\t\t$this->redirect('/blogs/');\n\t\t\t\t\t\t\t}\t\n\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//end limit setting\n\t\t\t\t\t\tif(!$page_exists)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->client->query('wp.newPage','',$wp_server['WpServer']['wp_admin_id'],$wp_server['WpServer']['wp_admin_password'],$content,true);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//limit setting\n\t\t\t\t\t\t\t$this->UserPlan->id=$plan[0]['user_plans']['id'];\n\t\t\t\t\t\t\t$d['UserPlan']['page_limit']=$user_page_limit-1;\n\t\t\t\t\t\t\t$this->UserPlan->save($d);\t\n\t\t\t\t\t\t\t//end limit setting\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$this->set('msg',\"<font ><b>Page added to the server</b></font>\");\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$this->set('msg',\"<font color='red'>Page already exists. Please try with different page title.</font>\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}catch(Exception $e){}\n\t\t\t\t\n\t\t\t}///end else if page submitted with title and desc\n\t\t}//end if\t\n\t\t//$wp_server_ids=$this->WpServer->find('list',array('fields' => 'WpServer.name','conditions' => array('WpServer.user_id' => $this->Session->read('user_id'))));\n\t\tif(!empty($id))\n\t\t$this->set('wp_server_id',$id);\n\t\telse\n\t\t$this->set('wp_server_id',$this->data['wp_server_id']);\n\t}",
"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}",
"public function add($fullPath, $alias = null);",
"public static function makeThis()\n {\n global $_configuration;\n\n $thisPortal = new stdClass();\n $thisPortal->root_web = $_configuration['root_web'];\n $thisPortal->db_host = $_configuration['db_host'];\n $thisPortal->db_user = $_configuration['db_user'];\n $thisPortal->db_password = $_configuration['db_password'];\n $thisPortal->main_database = $_configuration['main_database'];\n\n return $thisPortal;\n }",
"public function add()\n {\n $fleet_plane = $this->fleets->create();\n $this->session->set_userdata('fleet_plane', $fleet_plane);\n $this->showit();\n }",
"public function add_proxy_page() {\n\t\tadd_dashboard_page( '', '', 'read', self::PAGE_IDENTIFIER, '' );\n\t}",
"public function add(){ }",
"function edit_portal_wrap($member_id,$dest_realm,$name,$text,$end_location_realm,$end_location_x,$end_location_y,$new_owner,$new_x,$new_y,$new_realm)\n{\n\tif ($name=='') ocw_refresh_with_message(do_lang_tempcode('W_MISSING_NAME'),'warn');\n\n\tif (is_null($end_location_realm)) ocw_refresh_with_message(do_lang_tempcode('W_MISSING_DESTINATION_REALM'),'warn');\n\tif ((is_null($end_location_x)) || (is_null($end_location_y))) ocw_refresh_with_message(do_lang_tempcode('W_MISSING_DESTINATION'),'warn');\n\tif (is_null($new_realm)) ocw_refresh_with_message(do_lang_tempcode('W_MISSING_START_REALM'),'warn');\n\tif ((is_null($new_x)) || (is_null($new_y))) ocw_refresh_with_message(do_lang_tempcode('W_MISSING_START'),'warn');\n\n\t// Get $realm,$x,$y from $member_id\n\tlist($realm,$x,$y)=get_loc_details($member_id);\n\n\tif ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_portals','owner',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm,'end_location_realm'=>$dest_realm))!=$member_id))\n\t\tocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');\n\n\tif ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$new_realm))!=$member_id) && ($GLOBALS['SITE_DB']->query_value('w_realms','r_private',array('id'=>$new_realm))==1))\n\t\tocw_refresh_with_message(do_lang_tempcode('W_PORTAL_TO_PRIVATE'),'warn');\n\n\tif ($new_realm!=$realm)\n\t{\n\t\tif ($GLOBALS['SITE_DB']->query_value('w_rooms','allow_portal',array('location_x'=>$new_x,'location_y'=>$new_y,'location_realm'=>$new_realm))==0)\n\t\t\tocw_refresh_with_message(do_lang_tempcode('W_BAD_START'),'warn');\n\t}\n\n\t// Check $end_location_realm exists\n\t$allow_portal=$GLOBALS['SITE_DB']->query_value_null_ok('w_rooms','allow_portal',array('location_x'=>$end_location_x,'location_y'=>$end_location_y,'location_realm'=>$end_location_realm));\n\tif (is_null($allow_portal))\n\t\tocw_refresh_with_message(do_lang_tempcode('W_NO_END'),'warn');\n\tif (($allow_portal==0) && ($dest_realm==$end_location_realm)) ocw_refresh_with_message(do_lang_tempcode('W_BAD_END'),'warn');\n\n\tif (($dest_realm!=$end_location_realm) || ($x!=$new_x) || ($y!=$new_y) || ($realm!=$new_realm))\n\t{\n\t\t// Check we don't have a portal to this realm here already\n\t\t$t=$GLOBALS['SITE_DB']->query_value_null_ok('w_portals','name',array('start_location_x'=>$new_x,'start_location_y'=>$new_y,'start_location_realm'=>$new_realm,'end_location_realm'=>$end_location_realm));\n\t\tif (!is_null($t)) ocw_refresh_with_message(do_lang_tempcode('W_DUPE_END'),'warn');\n\t}\n\n\t$GLOBALS['SITE_DB']->query_update('w_portals',array('name'=>$name,'p_text'=>$text,'end_location_realm'=>$end_location_realm,'end_location_x'=>$end_location_x,'end_location_y'=>$end_location_y,'start_location_realm'=>$new_realm,'start_location_x'=>$new_x,'start_location_y'=>$new_y,'owner'=>$new_owner),array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm,'end_location_realm'=>$dest_realm),'',1);\n\n\tocw_refresh_with_message(do_lang_tempcode('SUCCESS'));\n}",
"public static function PORTAL_PORTAL(): SoundImpl\n {\n return new SoundImpl(SoundIds::PORTAL_PORTAL);\n }",
"function ack_menu_link_add($scheme, $realm) {\n module_load_include('inc', 'menu', 'menu.admin');\n $handler = $scheme->handlers['menu_link'];\n $menu_name = $handler->realmMenu($realm);\n $menu = empty($menu_name) ? menu_load('navigation') : menu_load($menu_name);\n $form_state = array(\n 'ack_menu' => array(\n 'schemes' => array($scheme),\n 'realms' => array($scheme->machine_name => array($realm)),\n 'destination' => 'ack_menu/manage/' . $scheme->machine_name . '/' . $realm,\n ),\n 'build_info' => array(\n 'args' => array(\n 'add',\n NULL,\n $menu,\n ),\n ),\n );\n return drupal_build_form('menu_edit_item', $form_state);\n}"
] | [
"0.69777817",
"0.5703814",
"0.5295225",
"0.5238378",
"0.52289623",
"0.52203023",
"0.5168996",
"0.5115591",
"0.5107866",
"0.50581896",
"0.50511634",
"0.50401163",
"0.50377613",
"0.49870592",
"0.4973842",
"0.4918768",
"0.49162015",
"0.4859881",
"0.48553738",
"0.48509693",
"0.48077863",
"0.47737396",
"0.4773123",
"0.47705317",
"0.47570357",
"0.47552598",
"0.47548866",
"0.47489825",
"0.473812",
"0.47320142"
] | 0.6031767 | 1 |
Actualiser to add a portal. | function add_portal($name,$text,$realm,$x,$y,$end_location_realm,$owner,$end_location_x,$end_location_y)
{
$GLOBALS['SITE_DB']->query_insert('w_portals',array(
'name'=>$name,
'p_text'=>$text,
'start_location_realm'=>$realm,
'start_location_x'=>$x,
'start_location_y'=>$y,
'end_location_realm'=>$end_location_realm,
'end_location_x'=>$end_location_x,
'end_location_y'=>$end_location_y,
'owner'=>$owner,
));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function setPortal($portal)\n {\n $this->portal = $portal;\n }",
"public function add()\n {\n $msg = JText::_('COM_PARKWAY_POST_ADDED');\n $this->setRedirect('index.php?option=com_parkway', $msg);\n }",
"public function add()\n {\n $fleet_plane = $this->fleets->create();\n $this->session->set_userdata('fleet_plane', $fleet_plane);\n $this->showit();\n }",
"public function store(Request $request)\n {\n $user_id = $request->user_id;\n\n $this->validate($request, [\n 'name' => 'required|max:255',\n 'description' => 'required|max:255',\n ]);\n\n $portal = Portal::create([\n 'name' => $request->name,\n 'description' => $request->description,\n 'user_id' => $user_id\n ]);\n\n return redirect()->route('portal.show', $portal->id)->with('message', \"$portal->name created successfully.\");\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 add()\n {\n if($this->isWebAdmin()){\n $this->global['pageTitle'] = \"Add New ATM Location - \".APP_NAME;\n $this->global['pageMenu'] = 'Add New ATM Location';\n $this->global['contentHeader'] = 'Add New ATM Location';\n $this->global['contentTitle'] = 'Add New ATM Location';\n $this->global ['role'] = $this->role;\n $this->global ['name'] = $this->name;\n $this->global ['repo'] = $this->repo;\n\n $data['classname'] = $this->cname;\n $this->loadViews($this->view_dir.'create', $this->global, $data);\n }else{\n redirect($this->cname.'/view');\n }\n }",
"public function add_panel(): void {\n\t\tif ( $this->panel ) {\n\t\t\tKirki::add_panel(\n\t\t\t\t$this->panel['id'],\n\t\t\t\t[\n\t\t\t\t\t'priority' => $this->panel['priority'] ?? 10,\n\t\t\t\t\t'title' => esc_html( $this->panel['title'] ),\n\t\t\t\t\t'description' => esc_html( $this->panel['description'] ),\n\t\t\t\t]\n\t\t\t);\n\t\t}\n\t}",
"function add_portal_wrap($member_id,$name,$text,$end_location_realm,$end_location_x,$end_location_y)\n{\n\tif ($end_location_realm==-1) $end_location_realm=NULL;\n\n\t// Get $realm,$x,$y from $member_id\n\tlist($realm,$x,$y)=get_loc_details($member_id);\n\tif (is_null($end_location_realm)) ocw_refresh_with_message(do_lang_tempcode('W_MISSING_DESTINATION_REALM'),'warn');\n\tif ((is_null($end_location_x)) || (is_null($end_location_y))) ocw_refresh_with_message(do_lang_tempcode('W_MISSING_DESTINATION'),'warn');\n\tif ($name=='') ocw_refresh_with_message(do_lang_tempcode('W_MISSING_NAME'),'warn');\n\n\t// Check $end_location_realm exists\n\t$allow_portal=$GLOBALS['SITE_DB']->query_value_null_ok('w_rooms','allow_portal',array('location_x'=>$end_location_x,'location_y'=>$end_location_y,'location_realm'=>$end_location_realm));\n\tif (is_null($allow_portal))\n\t\tocw_refresh_with_message(do_lang_tempcode('W_NO_END'),'warn');\n\tif ($allow_portal==0) ocw_refresh_with_message(do_lang_tempcode('W_BAD_END'),'warn');\n\n\t// Check we don't have a portal to this realm here already\n\t$t=$GLOBALS['SITE_DB']->query_value_null_ok('w_portals','name',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm,'end_location_realm'=>$end_location_realm));\n\tif (!is_null($t)) ocw_refresh_with_message(do_lang_tempcode('W_DUPE_END'),'warn');\n\n\tif ($GLOBALS['SITE_DB']->query_value('w_rooms','allow_portal',array('location_x'=>$x,'location_y'=>$y,'location_realm'=>$realm))==0)\n\t\tocw_refresh_with_message(do_lang_tempcode('W_BAD_START'),'warn');\n\n\tif ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$realm))!=$member_id) && ($GLOBALS['SITE_DB']->query_value('w_realms','r_private',array('id'=>$realm))==1))\n\t\tocw_refresh_with_message(do_lang_tempcode('W_NO_EDIT_ACCESS_PRIVATE_REALM'),'warn');\n\n/*\tif ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$end_location_realm))!=$member_id) && ($GLOBALS['SITE_DB']->query_value('w_realms','r_private',array('id'=>$end_location_realm))==1))\n\t\tocw_refresh_with_message(do_lang_tempcode('W_NO_EDIT_ACCESS_PRIVATE_REALM'),'warn');*/\n\n\t// Charge them\n\tif (!has_specific_permission($member_id,'administer_ocworld'))\n\t{\n\t\trequire_code('points2');\n\t\t$price=get_price('mud_portal');\n\t\tif (available_points($member_id)<$price) ocw_refresh_with_message(do_lang_tempcode('W_EXPENSIVE',integer_format($price)),'warn');\n\t\tcharge_member($member_id,$price,do_lang('W_MADE_PORTAL_OCWORLD',$name));\n\t}\n\n\tadd_portal($name,$text,$realm,$x,$y,$end_location_realm,$member_id,$end_location_x,$end_location_y);\n\n\t$destname=$GLOBALS['SITE_DB']->query_value('w_realms','name',array('id'=>$end_location_realm));\n\n\tocw_refresh_with_message(do_lang_tempcode('W_PORTAL_CREATED',escape_html($name),escape_html($destname)));\n}",
"public function dept_add() {\n $_POST['cr_by'] = $this->user->user_id;\n\n # Unix timestamp of when this post was created / modified\n $_POST['created'] = Time::now();\n $_POST['modified'] = Time::now();\n\t\t$_POST['dept_id'] = $_POST['dept_id'];\n\t\t$_POST['dept_name'] = $_POST['dept_name'];\n\t\t\n\t\t\n # Insert\n # Note we didn't have to sanitize any of the $_POST data because we're using the insert method which does it for us\n DB::instance(DB_NAME)->insert('dept', $_POST);\n \n # Quick and dirty feedback\n echo \"Department has been added. <a href='/dept/add'>Add another</a><BR>\";\n\t\techo \"<a href='/'>Go Home</a>\";\n }",
"function Add()\n{\n\tglobal $context, $scripturl, $txt, $settings, $smcFunc, $user_info, $ultimateportalSettings;\n\n\tif(empty($_POST['save']))\n\t\tcheckSession('get');\n\t\t\n\tif (empty($ultimateportalSettings['ipage_enable']))\n\t\tfatal_lang_error('ultport_error_no_active',false);\n\n\tif (!$user_info['is_admin'] && !$user_info['up-modules-permissions']['ipage_add'])\n\t\tfatal_lang_error('ultport_error_no_perms_groups',false);\n\n\tif (!empty($_REQUEST['type']) && !in_array($_REQUEST['type'], array('html', 'bbc')))\n\t\tfatal_lang_error('ultport_error_no_action',false);\n\n\tif (!empty($_POST['save']))\n\t{\n\t\tcheckSession('post');\n\t\tif (empty($_POST['title']))\n\t\t\tfatal_lang_error('ultport_error_no_add_ipage_title',false);\n\n\t\t$title = (string)$smcFunc['htmlspecialchars']($_POST['title']);\n\t\t$column_left = !empty($_POST['column_left']) ? (int)$_POST['column_left'] : 0;\n\t\t$column_right = !empty($_POST['column_right']) ? (int)$_POST['column_right'] : 0;\n\t\t$content = ($_POST['type_ipage'] == 'html') ? $_POST['elm1'] : (string)$smcFunc['htmlspecialchars']($_POST['ipage_content'], ENT_QUOTES);\t\n\t\t$content = $smcFunc['htmltrim']($content, ENT_QUOTES);\n\t\t$id_member = (int) $user_info['id'];\n\t\t$username = (string) $user_info['username'];\n\t\t$date_created = time();\n\t\t$type_ipage = $_POST['type_ipage'];\n\t\t$permissionsArray = array();\n\t\tif (!empty($_POST['perms']))\n\t\t{\n\t\t\tforeach ($_POST['perms'] as $rgroup)\n\t\t\t\t$permissionsArray[] = (int) $rgroup;\n\t\t}\n\t\t$finalPermissions = implode(\",\",$permissionsArray);\n\t\t$active = !empty($_POST['active']) ? $_POST['active'] : 'off';\n\t\t$sticky = !empty($_POST['sticky']) ? $_POST['sticky'] : 0;\n\t\t\n\t\t//Now insert the NEWS in the smf_up_news\t\t\t\n\t\t$smcFunc['db_insert']('replace',\n\t\t\t'{db_prefix}ultimate_portal_ipage',\n\t\t\tarray(\n\t\t\t\t'title' => 'string', 'sticky' => 'int', 'active' => 'string', 'type_ipage' => 'string', 'content' => 'string', 'perms' => 'string', 'column_left' => 'int', 'column_right' => 'int', 'date_created' => 'int', 'id_member' => 'int', 'username' => 'string',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t$title,$sticky,$active,$type_ipage,$content,$finalPermissions,$column_left,$column_right,$date_created,$id_member,$username\n\t\t\t),\n\t\t\tarray('id')\n\t\t);\n\t\tredirectexit('action=internal-page');\t\t\n\t}\n\t//Load Member Groups\n\tLoadMemberGroups();\n\t\n\t//Type Internal Page\n\t$context['type_ipage'] = !empty($_REQUEST['type']) ? $smcFunc['db_escape_string']($_REQUEST['type']) : 'html';\t\n\t//Load the Editor HTML or BBC?\n\tif ($_REQUEST['type'] == 'html')\n\t{\n\t\tcontext_html_headers(\"elm1\");\n\t\t$type_ipage_linktree = $txt['up_ipage_add_html'];\n\t}\t\n\tif ($_REQUEST['type'] == 'bbc')\n\t{\n\t\t// Now create the editor.\n\t\t$editorOptions = array(\n\t\t\t'id' => 'ipage_content',\n\t\t\t'value' => '',\n\t\t\t'form' => 'ipageform',\n\t\t);\n\t\t$context['smileyBox_container'] = 'smileyBox_'.$editorOptions['id'];\n\t\t$context['bbcBox_container'] = 'bbcBox_'.$editorOptions['id'];\n\t\tup_create_control_richedit($editorOptions);\t\n\t\t$context['post_box_name'] = $editorOptions['id'];\n\t\t$type_ipage_linktree = $txt['up_ipage_add_bbc'];\t\t\t\t\n\t}\n\t$context['news-linktree'] = ' <img alt=\"\" border=\"0\" src=\"'.$settings['default_images_url'].'/ultimate-portal/open_linktree.gif\" /> <a href=\"'. $scripturl .'?action=internal-page\">'. $txt['up_module_ipage_title'] .'</a> <br /><img alt=\"\" border=\"0\" src=\"'.$settings['default_images_url'].'/ultimate-portal/linktree_side.gif\" /> '. $type_ipage_linktree;\t\n\n\t$context['linktree'][1] = array(\n\t\t'url' => $scripturl . '?action=internal-page',\n\t\t'name' => $txt['up_module_ipage_title']\n\t);\t\n\t$context['sub_template'] = 'add';\n\t$context['page_title'] = $type_ipage_linktree;\n}",
"public function add() {\n global $wpdb;\n\n delete_option('dotpay_'.$this->name.'_title');\n add_option('dotpay_'.$this->name.'_title', $this->title, '', 'yes');\n\n $page = get_page_by_title($this->title);\n\n if (!$page) {\n $info = array();\n $info['post_title'] = $this->title;\n $info['post_content'] = \"[dotpay_content]\";\n $info['post_status'] = 'publish';\n $info['post_type'] = 'page';\n $info['comment_status'] = 'closed';\n $info['ping_status'] = 'closed';\n $info['guid'] = $this->guid;\n $info['post_category'] = array(1);\n\n $pageId = wp_insert_post($info);\n }\n else {\n $page->post_status = 'publish';\n $pageId = wp_update_post($page);\n }\n\n delete_option('dotpay_'.$this->name.'_id');\n add_option('dotpay_'.$this->name.'_id', $pageId);\n }",
"function addNew()\n {\n if($this->isAdmin() == TRUE)\n {\n $this->loadThis();\n }\n else\n {\n \n $data = array();\n $this->global['pageTitle'] = ': Add New campaigns';\n\n $this->loadViews(\"admin/campaigns/add\", $this->global, $data, NULL);\n }\n }",
"public function add()\n\t{\n\t\tif (!parent::add()) {\n\t\t\t// Redirect to the return page.\n\t\t\t$this->setRedirect($this->getReturnPage());\n\t\t}\n\t}",
"function addPlan()\n {\n return view ('admin/addPlan');\n }",
"public function add()\n {\n if ($this->access->hasWriteAccess()) {\n $this->ctrl->saveParameter($this, self::IDENTIFIER);\n $xlcdLocationFormGUI = new xlcdLocationFormGUI($this, new xlcdLocation());\n $this->tpl->setContent($xlcdLocationFormGUI->getHTML());\n }\n }",
"public function addAction()\n { if (!$this->hasPermission()) {\n $this->displayError(\"You do not have permission to view this page.\");\n return;\n }\n \n $this->view->pageTitle = \"Add Site\";\n $this->view->pageTitleLinkURL = \"/account/sites/\";\n $this->view->pageTitleLinkText = \"<< Back to \".$this->view->program->name.\"'s sites\";\n $this->view->action = \"add\";\n $this->view->filterForm = new Account_Form_FilterSiteList();\n\n $this->view->headScript()->appendFile(\"/js/tableSorter/jquery.tablesorter.min.js\");\n }",
"public function add() {\r\n $this->ograniczDostepTylkoDlaZalogowanegoUzytkownika();\r\n $idNarzedzia = $this->registry->id;\r\n if (!isset($_SESSION['RobotPelny']) || !isset($_SESSION['calkowita_ilosc']) || !isset($_SESSION['waga'])) {\r\n $_SESSION['RobotPelny'] = array();\r\n $_SESSION['calkowita_ilosc'] = 0;\r\n $_SESSION['waga'] = 0;\r\n }\r\n if (isset($_SESSION['RobotPelny'][$idNarzedzia])) {\r\n $_SESSION['RobotPelny'][$idNarzedzia] ++;\r\n } else {\r\n $_SESSION['RobotPelny'][$idNarzedzia] = 1;\r\n }\r\n $this->refreshShoppingCart();\r\n $location = '/' . APP_ROOT . '/RobotPelny';\r\n header(\"Location: $location\");\r\n }",
"function advertising_add_page() {\n $controller = entity_ui_controller('advertising');\n return $controller->addPage();\n}",
"public function addPartner() {\n\n if ($this->session->userdata('login')['user']):\n\n $dane = new Panel_model();\n $dane->addPartner();\n redirect('index.php/Baza/index');\n\n\n else:\n redirect('index.php/Welocome.index');\n\n endif;\n }",
"public function add(){}",
"public function add(){\n\n\t\t\t$this->view(\n\t\t\t\tarray(\"header\",\"navbar\",\"activity/add\",\"footer\"),\n\t\t\t\t$this->component()\n\t\t\t);\n\t\t}",
"public function create()\n {\n $this->authorize('panel_settings.add');\n //\n }",
"function page_add($id=null)\n\t{\n\t\t\tif(empty($id) && empty($this->data['wp_server_id']))\n\t\t\t{\n\t\t\t\t$this->redirect('/dashboards/');\n\t\t\t}\n\t\t\tif(empty($id))\n\t\t\t$s_id=$this->data['wp_server_id']; //this is for detecting call by dashboard or form\n\t\t\telse\n\t\t\t$s_id=$id;\n\t\t\t\t\t\t\n\t\t\tif(!($this->_checkId($s_id)))\n\t\t\t{\n\t\t\t\t$this->redirect('/dashboards/');\n\t\t\t}\t\n\t\t\tif(!empty($this->data))\n\t\t\t{\n\t\t\t\t$title=trim($this->data['title']);\n\t\t\t\t$page_desc=trim($this->data['page_desc']);\n\t\t\t\t$id=trim($this->data['wp_server_id']);\n\t\t\t\tif($title==\"\" || $page_desc==\"\" || $id==\"\")\n\t\t\t\t{\n\t\t\t\t\t$this->set('msg',\"<font color='red'>Please fill form</font>\");\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\t\n\t\t\t\t\n\t\t\t\t\t$this->WpServer->id = $id;\n\t\t\t\t\t$wp_server=$this->WpServer->read();\n\t\t\t\t\t$wp_server['WpServer']['rpc_url']=trim($wp_server['WpServer']['rpc_url']);\n\t\t\t\t\tApp::import('Vendor', 'remotepost');\n\t\t\t\t\n\t\t\t\t\ttry\n\t\t\t\t\t{\n\t\t\t\t\t\t$page_exists=false;\n\t\t\t\t\t\t$this->client = new IXR_Client($wp_server['WpServer']['rpc_url']); //making client\n\t\t\t\t\t\t$content['title']=$title;\n\t\t\t\t\t\t$content['description']=$page_desc;\n\t\t\t\t\t\n\t\t\t\t\t\t$this->client->query('wp.getPageList','',$wp_server['WpServer']['wp_admin_id'],$wp_server['WpServer']['wp_admin_password']);\n\t\t\t\t\t\t$pages=$this->client->getResponse();\n\t\t\t\t\t\tforeach($pages as $key => $value) //checking already exist in wp server or not.if exists then no need to add page.else add page.\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($value['page_title']==$title)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$page_exists=true;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//exit;\n\t\t\t\t\t\t\n\t\t\t\t\t\t//limit setting\n\t\t\t\t\t\t$this->loadModel('UserPlan');\n\t\t\t\t\t\t$user_id=$this->Session->read('user_id');\n\t\t\t\t\t\t$plan=$this->UserPlan->query(\"select plans.name,plans.page_limit,user_plans.page_limit,user_plans.id from plans inner join user_plans on plans.id=user_plans.plan_id \". \t\t\t\t\t\t\t\t\t\t \t\t\t\" where user_plans.user_id=$user_id\");\n\t\t\n\t\t\t\t\t\t$plan_page_limit=$plan[0]['plans']['page_limit'];\n\t\t\t\t\t\t$user_page_limit=$plan[0]['user_plans']['page_limit'];\n\t\t\t\t\t\tif($plan_page_limit!='umlimited')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//$this->set('user_page',$user_page_limit);\n\t\t\t\t\t\t\t//$this->set('total',$plan_blog_limit);\n\t\t\t\t\t\t\tif($user_page_limit <=0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$message=\"Please upgrade your plan. User page limit has exceeded\";\n\t\t\t\t\t\t\t\t$this->Session->setFlash($message);\n\t\t\t\t\t\t\t\t$this->redirect('/blogs/');\n\t\t\t\t\t\t\t}\t\n\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//end limit setting\n\t\t\t\t\t\tif(!$page_exists)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->client->query('wp.newPage','',$wp_server['WpServer']['wp_admin_id'],$wp_server['WpServer']['wp_admin_password'],$content,true);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//limit setting\n\t\t\t\t\t\t\t$this->UserPlan->id=$plan[0]['user_plans']['id'];\n\t\t\t\t\t\t\t$d['UserPlan']['page_limit']=$user_page_limit-1;\n\t\t\t\t\t\t\t$this->UserPlan->save($d);\t\n\t\t\t\t\t\t\t//end limit setting\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$this->set('msg',\"<font ><b>Page added to the server</b></font>\");\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$this->set('msg',\"<font color='red'>Page already exists. Please try with different page title.</font>\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}catch(Exception $e){}\n\t\t\t\t\n\t\t\t}///end else if page submitted with title and desc\n\t\t}//end if\t\n\t\t//$wp_server_ids=$this->WpServer->find('list',array('fields' => 'WpServer.name','conditions' => array('WpServer.user_id' => $this->Session->read('user_id'))));\n\t\tif(!empty($id))\n\t\t$this->set('wp_server_id',$id);\n\t\telse\n\t\t$this->set('wp_server_id',$this->data['wp_server_id']);\n\t}",
"public function add(){ }",
"public function create() {\n if (Permission::hasAccess('create', 'category')) {\n $categories = Portalbranch::get();\n \n return view(Config::get('config.template') . '.pages.admin.portals.create')->withCategories($categories);\n }\n return Redirect::to('admin/error/404');\n }",
"public function add() {\n\n\t}",
"public function add() \n\t\t{\n\t\t\trequire 'views/layout.php';\n\t\t\trequire 'views/rol/newRol.php';\n\t\t}",
"public function add()\r\n {\r\n if($this->getSessionHandler()->isLoggedIn())\r\n {\r\n $v = new AddTaskView();\r\n echo $v->render();\r\n }\r\n else\r\n {\r\n $this->displayMessage('You must login to view this area!');\r\n }\r\n }",
"public function localgov_plan_add() {\n $id = $_POST['id'];\n $arr = array(\n 'localgov_plan_type' => $this->input->post('inLocalgovPlanType')\n );\n if ($id != \"\") {\n $this->My_model->update_data(\"tb_localgov_plan_type\", array(\"id\" => $id), $arr);\n } else {\n $this->My_model->insert_data(\"tb_localgov_plan_type\", $arr);\n }\n }",
"protected function _addSite()\n {\n $name = \"website \";\n $idsite = Piwik_SitesManager_API::getInstance()->addSite($name,array(\"http://piwik.net\",\"http://piwik.com/test/\"));\n $this->assertInternalType(PHPUnit_Framework_Constraint_IsType::TYPE_INT, $idsite);\n\n $siteInfo = Piwik_SitesManager_API::getInstance()->getSiteFromId($idsite);\n $this->assertEquals($name, $siteInfo['name']);\n $this->assertEquals(\"http://piwik.net\", $siteInfo['main_url']);\n\n $siteUrls = Piwik_SitesManager_API::getInstance()->getSiteUrlsFromId($idsite);\n $this->assertEquals(array(\"http://piwik.net\",\"http://piwik.com/test\"), $siteUrls);\n\n return $idsite;\n }"
] | [
"0.5825443",
"0.5779309",
"0.57058084",
"0.5698467",
"0.5660843",
"0.5637498",
"0.5544242",
"0.54600835",
"0.54062784",
"0.5373106",
"0.53595996",
"0.5354901",
"0.5353942",
"0.5352264",
"0.5332321",
"0.5316474",
"0.523413",
"0.522997",
"0.5178394",
"0.5169346",
"0.51520646",
"0.51288265",
"0.51241016",
"0.51197594",
"0.51195514",
"0.5116795",
"0.51107013",
"0.510224",
"0.5101964",
"0.5099058"
] | 0.7019203 | 0 |
Wrapper and actualiser to delete a portal. Does not return. | function delete_portal_wrap($member_id,$dest_realm)
{
list($realm,$x,$y)=get_loc_details($member_id);
$attempt_member=$member_id;
if ((!has_specific_permission($attempt_member,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_portals','owner',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm,'end_location_realm'=>$dest_realm))!=$attempt_member)) ocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');
$name=$GLOBALS['SITE_DB']->query_value('w_portals','name',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm));
// Refund them
require_code('points2');
$price=get_price('mud_portal');
charge_member($attempt_member,intval(-0.7*$price),do_lang('W_DELETE_PORTAL_OCWORLD',$name));
delete_portal($x,$y,$realm,$dest_realm);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function delete_portal($x,$y,$realm,$dest_realm)\n{\n\t// Delete from db\n\t$GLOBALS['SITE_DB']->query_delete('w_portals',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm,'end_location_realm'=>$dest_realm),'',1);\n\n\tocw_refresh_with_message(do_lang_tempcode('SUCCESS'));\n}",
"public function destroy($id)\n {\n $portal = Portal::find($id);\n $portal_name = $portal->name;\n $portal->delete();\n\n return redirect()->route('dashboard.index')->with('message', \"$portal_name deleted successfully.\");\n }",
"public function Delete()\n\t{\n\t\ttry\n\t\t{\n\t\t\t\t\t\t\n\t\t\t// TODO: if a soft delete is prefered, change this to update the deleted flag instead of hard-deleting\n\n\t\t\t$pk = $this->GetRouter()->GetUrlParam('id');\n\t\t\t$lead = $this->Phreezer->Get('Lead',$pk);\n\n\t\t\t$lead->Delete();\n\n\t\t\t$output = new stdClass();\n\n\t\t\t$this->RenderJSON($output, $this->JSONPCallback());\n\n\t\t}\n\t\tcatch (Exception $ex)\n\t\t{\n\t\t\t$this->RenderExceptionJSON($ex);\n\t\t}\n\t}",
"function Delete()\n{\n\tglobal $user_info, $smcFunc;\n\tcheckSession('get');\n\tif (!$user_info['is_admin'] && !$user_info['up-modules-permissions']['ipage_moderate'])\n\t\tfatal_lang_error('ultport_error_no_perms_groups',false);\n\t\n\t$id = !empty($_REQUEST['id']) ? (int) $smcFunc['db_escape_string']($_REQUEST['id']) : '';\n\n\tif (empty($id))\n\t\tfatal_lang_error('ultport_error_no_delete_ippage',false);\n\t\n\t$smcFunc['db_query']('',\"\n\t\tDELETE FROM {db_prefix}ultimate_portal_ipage \n\t\tWHERE id = {int:id}\n\t\tLIMIT 1\",\n\t\tarray(\n\t\t\t'id' => $id,\n\t\t)\n\t);\n\tredirectexit('action=internal-page');\n}",
"function ah_delete_dashlet(){\n\t$opts=grab_request_var(\"opts\",\"\");\n\t//echo \"OPTS: $opts\\n\";\n\t$optsarr=json_decode($opts);\n\t//echo \"OPTS2: \\n\";\n\t//print_r($optsarr);\n\t\n\t$board_id=$optsarr->board;\n\t$dashlet_id=$optsarr->dashlet;\n\t\n\techo \"BOARD ID: $board_id\\n\";\n\techo \"DASHLET ID: $dashlet_id\\n\";\n\t\n\tremove_dashlet_from_dashboard(0,$board_id,$dashlet_id);\n\t}",
"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 delete($name, $optParams = array())\n {\n $params = array('name' => $name);\n $params = array_merge($params, $optParams);\n return $this->call('delete', array($params), \"Google_Service_Sasportal_SasPortalEmpty\");\n }",
"public function delete(): void;",
"public function delete()\n {\n //fetch endpoint information from schema file\n $endpoint = $this->getEndpoint(\"destroy\");\n\n if($this->id)\n {\n $response = $this->api->request(\"/api/\".str_ireplace('{id}',$this->id,$endpoint->href),$endpoint->method);\n\n switch($response['code']) {\n case \"200\":\n return $response;\n break;\n\n default:\n throw new SaleskingException(\"DELETE_ERROR\",\"Deleting failed, an error happend\",$response);\n break;\n }\n }\n else\n {\n throw new SaleskingException(\"DELETE_IDNOTSET\",\"could not delete object\");\n }\n }",
"public function deletePrincipal($id){\n }",
"public function delete()\n\t{}",
"public function delete() {\n\n // Does the Article object have an ID?\n if ( is_null( $this->id ) ) trigger_error ( \"Article::delete(): Attempt to delete an Article object that does not have its ID property set.\", E_USER_ERROR );\n\n // Delete the Article\n $conn = new PDO( DB_DSN, DB_USERNAME, DB_PASSWORD );\n $stmt = $conn->prepare ( \"DELETE FROM articles WHERE id = :id LIMIT 1\" );\n $stmt->bindValue( \":id\", $this->id, PDO::PARAM_INT );\n $stmt->execute();\n $conn = null;\n }"
] | [
"0.6856745",
"0.64326084",
"0.61506057",
"0.5979938",
"0.5859",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5809719",
"0.5782092",
"0.57408595",
"0.5656474",
"0.5647313",
"0.562752",
"0.56138515",
"0.5606675"
] | 0.67166245 | 1 |
Actualiser to delete a portal. Does not return. | function delete_portal($x,$y,$realm,$dest_realm)
{
// Delete from db
$GLOBALS['SITE_DB']->query_delete('w_portals',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm,'end_location_realm'=>$dest_realm),'',1);
ocw_refresh_with_message(do_lang_tempcode('SUCCESS'));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function delete_portal_wrap($member_id,$dest_realm)\n{\n\tlist($realm,$x,$y)=get_loc_details($member_id);\n\n\t$attempt_member=$member_id;\n\tif ((!has_specific_permission($attempt_member,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_portals','owner',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm,'end_location_realm'=>$dest_realm))!=$attempt_member)) ocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');\n\n\t$name=$GLOBALS['SITE_DB']->query_value('w_portals','name',array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm));\n\n\t// Refund them\n\trequire_code('points2');\n\t$price=get_price('mud_portal');\n\tcharge_member($attempt_member,intval(-0.7*$price),do_lang('W_DELETE_PORTAL_OCWORLD',$name));\n\n\tdelete_portal($x,$y,$realm,$dest_realm);\n}",
"public function destroy($id)\n {\n $portal = Portal::find($id);\n $portal_name = $portal->name;\n $portal->delete();\n\n return redirect()->route('dashboard.index')->with('message', \"$portal_name deleted successfully.\");\n }",
"public function Delete()\n\t{\n\t\ttry\n\t\t{\n\t\t\t\t\t\t\n\t\t\t// TODO: if a soft delete is prefered, change this to update the deleted flag instead of hard-deleting\n\n\t\t\t$pk = $this->GetRouter()->GetUrlParam('id');\n\t\t\t$lead = $this->Phreezer->Get('Lead',$pk);\n\n\t\t\t$lead->Delete();\n\n\t\t\t$output = new stdClass();\n\n\t\t\t$this->RenderJSON($output, $this->JSONPCallback());\n\n\t\t}\n\t\tcatch (Exception $ex)\n\t\t{\n\t\t\t$this->RenderExceptionJSON($ex);\n\t\t}\n\t}",
"function Delete()\n{\n\tglobal $user_info, $smcFunc;\n\tcheckSession('get');\n\tif (!$user_info['is_admin'] && !$user_info['up-modules-permissions']['ipage_moderate'])\n\t\tfatal_lang_error('ultport_error_no_perms_groups',false);\n\t\n\t$id = !empty($_REQUEST['id']) ? (int) $smcFunc['db_escape_string']($_REQUEST['id']) : '';\n\n\tif (empty($id))\n\t\tfatal_lang_error('ultport_error_no_delete_ippage',false);\n\t\n\t$smcFunc['db_query']('',\"\n\t\tDELETE FROM {db_prefix}ultimate_portal_ipage \n\t\tWHERE id = {int:id}\n\t\tLIMIT 1\",\n\t\tarray(\n\t\t\t'id' => $id,\n\t\t)\n\t);\n\tredirectexit('action=internal-page');\n}",
"public function delete() {}",
"function ah_delete_dashlet(){\n\t$opts=grab_request_var(\"opts\",\"\");\n\t//echo \"OPTS: $opts\\n\";\n\t$optsarr=json_decode($opts);\n\t//echo \"OPTS2: \\n\";\n\t//print_r($optsarr);\n\t\n\t$board_id=$optsarr->board;\n\t$dashlet_id=$optsarr->dashlet;\n\t\n\techo \"BOARD ID: $board_id\\n\";\n\techo \"DASHLET ID: $dashlet_id\\n\";\n\t\n\tremove_dashlet_from_dashboard(0,$board_id,$dashlet_id);\n\t}",
"public function deleted(Lead $lead)\n {\n //\n }",
"public function delete() {\n\t\t}",
"public function delete() {\n\t\tif (auth()->getRecord()->isAdmissionsCoordinator() != 1) {\n\t\t\tredirect(auth()->getRecord()->homeURL());\n\t\t}\n\t\t$hospital = new CMS_Hospital(input()->hospital);\n\t\t\n\t\t\t\t\n\t\tif ($hospital->deleteHospital($hospital->id)) {\n\t\t\tfeedback()->conf(\"{$hospital->name} was successfully deleted.\");\n\t\t\t$this->redirect(SITE_URL . \"/?page=hospital&action=manage\");\n\t\t} else {\n\t\t\tfeedback()->error(\"Could not delete the hospital.\");\n\t\t\t$this->redirect(SITE_URL . \"/?page=hospital&action=manage\");\n\t\t}\n\t}",
"public function delete_plans(){\n\t\tif ($this->checkLogin('A') == ''){\n\t\t\tredirect(ADMIN_PATH);\n\t\t}else {\n\t\t\t$plan_id = $this->uri->segment(4,0);\n\t\t\t$condition = array('id' => $plan_id);\n\t\t\t$this->plans_model->commonDelete(PLANS,$condition);\n\t\t\t$this->setErrorMessage('success','Plan deleted successfully');\n\t\t\tredirect(ADMIN_PATH.'/plans/display_plans');\n\t\t}\n\t}",
"public function delete($name, $optParams = array())\n {\n $params = array('name' => $name);\n $params = array_merge($params, $optParams);\n return $this->call('delete', array($params), \"Google_Service_Sasportal_SasPortalEmpty\");\n }",
"public function deleteAction() {\n\tif(!isset($this->params['cancel'])) {\n\t\tif($this->_model->name == \"admin\") {\n\t\t\tAPI::Message(\"You cannot delete 'admin'\");\n\t\t} else {\t\n\t\t\t// XXX: Maybe do some hook call validation here?\n\t\t\t\n\t\t\t// auto call the hooks for this module/action\n \t\t\tAPI::callHooks(self::$module, $this->action, 'controller', $this->req_id);\n\t\n\t\t \t// delete an entry\n \t\t$host = $this->_model->delete();\n\t\t}\n\t}\n API::redirect(API::printUrl($this->_redirect));\n }",
"public function deletePlanning(Application $app, $id){\n $article = $app['dao.planning']->delete($id);\n //on crée un message de réussite dans la session\n $app['session']->getFlashBag()->add('success', 'Article bien supprimé');\n //on redirige vers la page d'accueil\n return $app->redirect($app['url_generator']->generate('homeAdmin'));\n }",
"public function delete()\n\t{}",
"function delete() {\r\n $dto = $this->session->userdata('plane');\r\n $plane = $this->flights_model->get($dto->id);\r\n $this->flights_model->delete($plane->id);\r\n $this->session->unset_userdata('plane');\r\n redirect('/flights');\r\n }",
"public function delete(): void\n {\n $this->strategy->delete();\n }",
"public function delete() {\n $id = $this->uri->segment(4);\n\n //delete sale\n $this->general_model->delete(TBL_companies, 'show_id', $id);\n redirect($this->config->item('admin_path') . 'companies/', 'location');\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();"
] | [
"0.65316117",
"0.6509647",
"0.6342822",
"0.59556496",
"0.58288354",
"0.5826611",
"0.58057857",
"0.5798055",
"0.5782809",
"0.5766418",
"0.57624906",
"0.5753143",
"0.5746682",
"0.5730634",
"0.5723056",
"0.57132727",
"0.5710751",
"0.57084286",
"0.57084286",
"0.57084286",
"0.57084286",
"0.57084286",
"0.57084286",
"0.57084286",
"0.57084286",
"0.57084286",
"0.57084286",
"0.57084286",
"0.57084286",
"0.57084286"
] | 0.688937 | 0 |
Wrapper and actualiser to delete a realm. Does not return. | function delete_realm_wrap($member_id)
{
$attempt_member=$member_id;
$realm=$GLOBALS['SITE_DB']->query_value('w_members','location_realm',array('id'=>$member_id));
if ($realm==0) ocw_refresh_with_message(do_lang_tempcode('W_DEL_PRIMARY_REALM'),'warn');
if ((!has_specific_permission($attempt_member,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$realm))!=$attempt_member)) ocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');
if ($GLOBALS['SITE_DB']->query_value_null_ok_full('SELECT COUNT(*) FROM '.$GLOBALS['SITE_DB']->get_table_prefix().'w_rooms WHERE location_realm='.strval((integer)$realm).' AND owner<>'.strval((integer)$attempt_member))>0) ocw_refresh_with_message(do_lang_tempcode('W_NO_DEL_OTHERS_ROOMS_REALM'),'warn');
// Refund them
require_code('points2');
$price=get_price('mud_realm');
charge_member($attempt_member,intval(-0.7*$price),do_lang('W_DELETE_REALM_OCWORLD',strval($realm)));
delete_realm($realm);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function delete_realm($realm)\n{\n\t// Remove all items from realm\n\t$GLOBALS['SITE_DB']->query_delete('w_items',array('location_realm'=>$realm));\n\n\t// Remove all rooms from realm\n\t$GLOBALS['SITE_DB']->query_delete('w_rooms',array('location_realm'=>$realm));\n\n\t// Delete troll\n\t$GLOBALS['SITE_DB']->query_delete('w_members',array('id'=>-$realm-1));\n\n\t// Send all people in realm back to 0\n\t$GLOBALS['SITE_DB']->query_update('w_members',array('location_x'=>0,'location_y'=>0),array('location_realm'=>$realm));\n\n\t// Delete from db\n\t$GLOBALS['SITE_DB']->query_delete('w_realms',array('id'=>$realm),'',1);\n\n\tocw_refresh_with_message(do_lang_tempcode('SUCCESS'));\n}",
"public static function closeRealm() : self\n {\n return self::close('close_realm');\n }",
"public function delete()\n {\n return $this->object()->delete();\n }",
"function delete(){\n if ($this->_admin_role_rights_id):\n $admin_role_rights_id = preg_replace('#[^0-9]#i', '', $this->_admin_role_rights_id);\n $Query = sprintf(\"Delete from \" . TABLE_ADMIN_ROLE_RIGHTS . \" where admin_role_rights_id =%d\",$admin_role_rights_id);\n $objDB = new database;\n $objDB->db_connect();\n return $objDB->db_query($Query);\n endif;\n }",
"public function testDelete()\n {\n $objectManager = $this->createMock(ObjectManager::class);\n $repository = $this->createMock(UnglinRoleRepositoryInterface::class);\n\n $instance = new UnglinRoleMapper($objectManager, $repository);\n\n $role = $this->createMock(UnglinRole::class);\n\n $objectManager->expects($this->once())\n ->method('remove')\n ->with($this->identicalTo($role));\n\n $this->assertNull($instance->delete($role));\n }",
"public function delete() {}",
"public function destroy(Acordo $acordo)\n {\n $acordo->delete();\n return response(['message'=>'Deleted']);\n }",
"public function delete($id = NULL)\n {\n $id = isset($id) ? $id : $this->id;\n // delete the related EnqueteMorador objects\n $repository = new TRepository('EnqueteMorador');\n $criteria = new TCriteria;\n $criteria->add(new TFilter('enquete_id', '=', $id));\n $repository->delete($criteria);\n \n \n // delete the object itself\n parent::delete($id);\n }",
"function drush_role_delete($rid) {\n $role = drush_role_get_class($rid);\n if ($role === FALSE) {\n return FALSE;\n }\n $result = $role->delete();\n if ($result !== FALSE) {\n drush_log(dt('Deleted \"!role\"', array('!role' => $rid)), 'success');\n }\n return $result;\n}",
"public function delete() {\n\t\treturn($this->__meta__['orm']::delete($this, $this->id()));\n\t}",
"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();",
"abstract public function _delete($obj);",
"function method_delete( $id )\n\t{\n\t\t$model = $this->getEntryModel();\n\t\t$model->load( $id );\n\t\tif( $this->getActiveUser()->hasRole( QCL_ROLE_ADMIN ) ) // FIXME permission\n\t\t{\n\t\t\t$model->delete();\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$personModel = $this->getPersonModel();\n\t\t\t$personModel->loadWhere( array( \"userId\" => $this->getActiveUser()->id() ) );\n\t\t\t$propModel = $this->getEntryUserPropertyModel();\n\t\t\tif( $model->get(\"personId\") == $personModel->id() )\n\t\t\t{\n\t\t\t // todo: relation\n\t\t\t\t$propModel->deleteWhere(array(\n\t\t\t\t 'entryId' => $model->id()\n\t\t\t\t));\n\t\t\t\t$model->delete();\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tthrow new JsonRpcError( $this->tr( \"Not allowed.\") );// FIXME\n\t\t\t}\n\t\t}\n\t\t$this->broadcastClientMessage(\"entry.deleted\",$id,true);\n\t\treturn \"OK\";\n\t}"
] | [
"0.70861495",
"0.590083",
"0.5777316",
"0.5739194",
"0.570147",
"0.56971323",
"0.5616908",
"0.5606871",
"0.5600924",
"0.55771303",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55677795",
"0.55676335",
"0.5552341"
] | 0.63730544 | 1 |
Actualiser to delete a realm. Does not return. | function delete_realm($realm)
{
// Remove all items from realm
$GLOBALS['SITE_DB']->query_delete('w_items',array('location_realm'=>$realm));
// Remove all rooms from realm
$GLOBALS['SITE_DB']->query_delete('w_rooms',array('location_realm'=>$realm));
// Delete troll
$GLOBALS['SITE_DB']->query_delete('w_members',array('id'=>-$realm-1));
// Send all people in realm back to 0
$GLOBALS['SITE_DB']->query_update('w_members',array('location_x'=>0,'location_y'=>0),array('location_realm'=>$realm));
// Delete from db
$GLOBALS['SITE_DB']->query_delete('w_realms',array('id'=>$realm),'',1);
ocw_refresh_with_message(do_lang_tempcode('SUCCESS'));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function delete_realm_wrap($member_id)\n{\n\t$attempt_member=$member_id;\n\n\t$realm=$GLOBALS['SITE_DB']->query_value('w_members','location_realm',array('id'=>$member_id));\n\tif ($realm==0) ocw_refresh_with_message(do_lang_tempcode('W_DEL_PRIMARY_REALM'),'warn');\n\n\tif ((!has_specific_permission($attempt_member,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$realm))!=$attempt_member)) ocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');\n\n\tif ($GLOBALS['SITE_DB']->query_value_null_ok_full('SELECT COUNT(*) FROM '.$GLOBALS['SITE_DB']->get_table_prefix().'w_rooms WHERE location_realm='.strval((integer)$realm).' AND owner<>'.strval((integer)$attempt_member))>0) ocw_refresh_with_message(do_lang_tempcode('W_NO_DEL_OTHERS_ROOMS_REALM'),'warn');\n\n\t// Refund them\n\trequire_code('points2');\n\t$price=get_price('mud_realm');\n\tcharge_member($attempt_member,intval(-0.7*$price),do_lang('W_DELETE_REALM_OCWORLD',strval($realm)));\n\n\tdelete_realm($realm);\n}",
"public function delete() {}",
"function delete(){\n if ($this->_admin_role_rights_id):\n $admin_role_rights_id = preg_replace('#[^0-9]#i', '', $this->_admin_role_rights_id);\n $Query = sprintf(\"Delete from \" . TABLE_ADMIN_ROLE_RIGHTS . \" where admin_role_rights_id =%d\",$admin_role_rights_id);\n $objDB = new database;\n $objDB->db_connect();\n return $objDB->db_query($Query);\n endif;\n }",
"public function delete(): void\n {\n $this->strategy->delete();\n }",
"public function delete()\n {\n \t$this->setDeleted(true);\n }",
"function method_delete( $id )\n\t{\n\t\t$model = $this->getEntryModel();\n\t\t$model->load( $id );\n\t\tif( $this->getActiveUser()->hasRole( QCL_ROLE_ADMIN ) ) // FIXME permission\n\t\t{\n\t\t\t$model->delete();\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$personModel = $this->getPersonModel();\n\t\t\t$personModel->loadWhere( array( \"userId\" => $this->getActiveUser()->id() ) );\n\t\t\t$propModel = $this->getEntryUserPropertyModel();\n\t\t\tif( $model->get(\"personId\") == $personModel->id() )\n\t\t\t{\n\t\t\t // todo: relation\n\t\t\t\t$propModel->deleteWhere(array(\n\t\t\t\t 'entryId' => $model->id()\n\t\t\t\t));\n\t\t\t\t$model->delete();\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tthrow new JsonRpcError( $this->tr( \"Not allowed.\") );// FIXME\n\t\t\t}\n\t\t}\n\t\t$this->broadcastClientMessage(\"entry.deleted\",$id,true);\n\t\treturn \"OK\";\n\t}",
"public function delete() {\n\t\t}",
"public function delete(Model $acl_resource) {\n\n // Delete record\n return parent::_delete($acl_resource);\n }",
"public function deleteAction() {\n\t\n\t\t$request = $this->getRequest();\n\t\t$aclRoleId = $this->filter($request->getParam('id'));\n\t\t$deleted = $this->AclRoles->deleteById($aclRoleId);\n\t\t\n\t\tif ($deleted) {\n\t\t\t$this->addFlash('ACL Role has been deleted.', 'notice');\n\t\t\n\t\t} else {\n\t\t\t$errors = $this->AclRoles->getErrors();\n\t\t\t$this->addFlash($errors['action']['delete'][0], 'errors');\n\t\t}\n\t\t\n\t\t$this->_redirect($this->view->base_url.'/admin/acl-roles');\n\t}",
"public function delete()\n {\n if ($this->request->exists('post')) {\n $data = $this->request->get();\n if ($data['csrftoken'] && $this->token->validateToken($data['csrftoken'], $data['frm_name'])) {\n $table = str_replace(' ', '', ucwords(str_replace('_', ' ', $data['table'])));\n $model = $this->container->make($table . 'Manager'::class);\n $method = isset($data['method']) ? $data['method'] : '';\n $output = $method != '' ? $model->$method($data) : $model->delete($data);\n if ($output) {\n $this->jsonResponse(['result' => 'success', 'msg' => $output]);\n }\n }\n }\n }",
"public function delete(){ }",
"public function delete()\n {\n return $this->object()->delete();\n }",
"public function destroy(Acordo $acordo)\n {\n $acordo->delete();\n return response(['message'=>'Deleted']);\n }",
"public static function closeRealm() : self\n {\n return self::close('close_realm');\n }",
"function delete() {\r\n $dto = $this->session->userdata('plane');\r\n $plane = $this->flights_model->get($dto->id);\r\n $this->flights_model->delete($plane->id);\r\n $this->session->unset_userdata('plane');\r\n redirect('/flights');\r\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();"
] | [
"0.61519074",
"0.59021866",
"0.5832109",
"0.578613",
"0.57412356",
"0.5739637",
"0.57242143",
"0.56951404",
"0.56903577",
"0.5688905",
"0.5682067",
"0.5668159",
"0.5664162",
"0.5662887",
"0.5659253",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476",
"0.5654476"
] | 0.71432364 | 0 |
Wrapper and actualiser to edit a realm. Does not return. | function edit_realm_wrap($member_id,$name,$troll_name,$qa,$private,$new_owner)
{
if ($private!=1) $private=0;
if ($name=='') ocw_refresh_with_message(do_lang_tempcode('W_MISSING_NAME'),'warn');
if (is_null($new_owner)) $new_owner=$member_id;
if ($troll_name=='') ocw_refresh_with_message(do_lang_tempcode('W_MISSING_TROLL_NAME'),'warn');
$realm=$GLOBALS['SITE_DB']->query_value('w_members','location_realm',array('id'=>$member_id));
if ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$realm))!=$member_id))
ocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');
edit_realm($realm,$name,$troll_name,$qa,$private,$new_owner);
ocw_refresh_with_message(do_lang_tempcode('SUCCESS'));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function edit_realm($realm,$name,$troll_name,$qa,$private,$new_owner)\n{\n\t$_qa=array();\n\tfor ($i=1;$i<=30;$i++)\n\t{\n\t\tif (strlen($qa[$i]['q'])>0)\n\t\t{\n\t\t\t$_qa['q'.strval($i)]=$qa[$i]['q'];\n\t\t\t$_qa['a'.strval($i)]=$qa[$i]['a'];\n\t\t} else\n\t\t{\n\t\t\t$_qa['q'.strval($i)]='';\n\t\t\t$_qa['a'.strval($i)]='';\n\t\t}\n\t}\n\n\t$GLOBALS['SITE_DB']->query_update('w_realms',array_merge($_qa,array('name'=>$name,'troll_name'=>$troll_name,'r_private'=>$private,'owner'=>$new_owner)),array('id'=>$realm),'',1);\n}",
"function setRealm($realm);",
"abstract public function edit();",
"public function edit(){\r\n\t\t//$this->auth->set_access('edit');\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 edit_room($name,$realm,$x,$y,$text,$password_question,$password_answer,$password_fail_message,$required_item,$locked_up,$locked_down,$locked_right,$locked_left,$picture_url,$allow_portal,$new_owner,$new_x,$new_y,$new_realm)\n{\n\t$GLOBALS['SITE_DB']->query_update('w_rooms',array('r_text'=>$text,'password_question'=>$password_question,'password_answer'=>$password_answer,'password_fail_message'=>$password_fail_message,'required_item'=>$required_item,'picture_url'=>$picture_url,'locked_up'=>$locked_up,'locked_down'=>$locked_down,'locked_right'=>$locked_right,'locked_left'=>$locked_left,'name'=>$name,'allow_portal'=>$allow_portal,'location_x'=>$new_x,'location_y'=>$new_y,'location_realm'=>$new_realm,'owner'=>$new_owner),array('location_x'=>$x,'location_y'=>$y,'location_realm'=>$realm),'',1);\n\t$GLOBALS['SITE_DB']->query_update('w_members',array('location_x'=>$new_x,'location_y'=>$new_y,'location_realm'=>$new_realm),array('location_x'=>$x,'location_y'=>$y,'location_realm'=>$realm));\n\t$GLOBALS['SITE_DB']->query_update('w_portals',array('start_location_x'=>$new_x,'start_location_y'=>$new_y,'start_location_realm'=>$new_realm),array('start_location_x'=>$x,'start_location_y'=>$y,'start_location_realm'=>$realm));\n}",
"function setRealm($realm) {\n\n $this->realm = $realm;\n\n }",
"public function edit(Rol $rol)\n {\n //\n }",
"public function edit(Rol $rol)\n {\n //\n }",
"public function edit();",
"public function editRoom(){\n }",
"abstract public function edit($id);",
"abstract public function edit($id);",
"public function editAction() {\n\t\n\t\t$request = $this->getRequest();\n\t\t$aclRoleId = $this->filter($request->getParam('id'));\n\t\t$this->view->aclresources = $this->getAclResources();\n\t\t\n\t\tif ($request->isPost()) {\n\t\t\t$updated = $this->AclRoles->process($request->getParams(), 'update');\n\t\t\tif (!$updated) {\n\t\t\t\t$this->addFlash('Error updating ACL role. Correct form below.', 'errors');\n\t\t\t\t$this->view->errors = $this->AclRoles->getErrors();\n\t\t\t\t$this->view->data = $request->getParams();\n\t\t\t\n\t\t\t} else {\n\t\t\t\t$this->addFlash('ACL Role updated.', 'notice');\n\t\t\t\t$this->_redirect($this->view->base_url.'/admin/acl-roles');\n\t\t\t}\n\t\t\t\n\t\t} else {\n\t\t\t$aclRole = $this->AclRoles->fetchById($aclRoleId);\n\t\t\tif ($aclRole) {\n\t\t\t\t$roleData = $aclRole->toArray();\n\t\t\t\t$ruleData = $this->AclRules->rules2Form($aclRoleId);\n\t\t\t\t$this->view->data = array_merge($roleData, $ruleData);\n\t\t\t\n\t\t\t} else {\n\t\t\t\t$this->addFlash('Invalid ACL Role.', 'errors');\n\t\t\t\t$this->_redirect($this->view->base_url.'/admin/acl-roles');\n\t\t\t}\n\t\t}\n\t}",
"public function edit(Marca $marca)\n {\n //\n }",
"public function setRealm($realm) {\n\n $this->realm = $realm;\n\n }",
"public function editAction() {\n if ($this->getRequest()->isPost()) {\n $data = $this->getRequestData();\n \n $user = $this->tokenPayload;\n $role = $this->entityManager->getRepository(Role::class)\n ->find($data['id']);\n \n if(isset($data['id']) && $role) {\n //Create New Form Permission\n $form = new RoleForm('update', $this->entityManager, $role);\n $form->setData($data);\n if ($form->isValid()) {\n $data = $form->getData(); \n $this->roleManager->updateRole($role, $data, $user); \n $this->error_code = 1;\n $this->apiResponse['message'] = \"You have modified Role!\";\n } else {\n $this->error_code = 0;\n $this->apiResponse['data'] = $form->getMessages(); \n } \n } else {\n $this->error_code = 0;\n $this->apiResponse['message'] = 'NOT_FOUND'; \n } \n \n } \n \n return $this->createResponse();\n }",
"public function edit(Ticket $ticket) {\n\t\t//\n\t}",
"public function edit(Tdr $tdr)\n {\n //\n }",
"public function edit(TurnoAfiliado $TurnoAfiliado)\n {\n //\n }",
"public function edit(Autorisation $autorisation)\n {\n //\n }",
"public function edit(Torneo $torneo)\n {\n //\n }",
"public function edit()\n\t\t{\n\t\t\tif(isset($_REQUEST['id'])) {\n\t\t\t\t$id = $_REQUEST['id'];\n\t\t\t\t$data = $this->model->getRolById($id);\n\t\t\t\trequire 'views/layout.php';\n\t\t\t\trequire 'views/rol/editRol.php';\n\t\t\t} else {\n\t\t\t\techo \"Error\";\n\t\t\t}\n\t\t}",
"public function edit(r $r)\n {\n //\n }",
"public function edit(Credential $credential)\n {\n //\n }",
"public function realm($realm)\n {\n $this->realm = $realm;\n\n return $this;\n }",
"public function edit($id)\n {\n //Check if user is authorized to access this page\n $request->user()->authorizeRoles(['admin', 'hrmanager', 'hruser']);\n }",
"public function edit($context)\n {\n $change = FALSE;\n $error = FALSE;\n $fdt = $context->formdata();\n foreach (self::$editfields as $fld => $flags)\n { // might need more fields for different applications\n $val = $fdt->post($fld, '');\n if ($flags[0] && $val === '')\n { // this is an error as this is a required field\n $error = TRUE;\n }\n elseif ($val != $this->bean->$fld)\n {\n $this->bean->$fld = $val;\n $change = TRUE;\n }\n }\n if ($change)\n {\n \\R::store($this->bean);\n }\n $pw = $fdt->post('pw', '');\n if ($pw !== '')\n {\n if ($pw == $fdt->post('rpw', ''))\n {\n $this->setpw($pw); // setting the password will do a store\n }\n else\n {\n $error = TRUE;\n }\n }\n $this->editroles($context);\n// $uroles = $this->roles();\n//\t if ($fdt->haspost('exist'))\n//\t {\n// foreach ($_POST['exist'] as $ix => $rid)\n// {\n// $rl = $context->load('role', $rid);\n// $start = $_POST['xstart'][$ix];\n// $end = $_POST['xend'][$ix];\n// $other = $_POST['xotherinfo'][$ix];\n// if (strtolower($start) == 'now')\n// {\n// $rl->start = $context->utcnow();\n// }\n// elseif ($start != $rl->start)\n// {\n// $rl->start = $context->utcdate($start);\n// }\n// if (strtolower($end) == 'never' || $end === '')\n// {\n// if ($rl->end !== '')\n// {\n// $rl->end = NULL;\n// }\n// }\n// elseif ($end != $rl->end)\n// {\n// $rl->end = $context->utcdate($end);\n// }\n// if ($other != $rl->otherinfo)\n// {\n// $rl->otherinfo = $other;\n// }\n// \\R::store($rl);\n// }\n//\t }\n// foreach ($_POST['role'] as $ix => $rn)\n// {\n// $cn = $_POST['context'][$ix];\n// if ($rn !== '' && $cn !== '')\n// {\n// $end = $_POST['end'][$ix];\n// $start = $_POST['start'][$ix];\n// $this->addrolebybean($context->load('rolecontext', $cn), $context->load('rolename', $rn), $_POST['otherinfo'][$ix],\n// strtolower($start) == 'now' ? $context->utcnow() : $context->utcdate($start),\n// strtolower($end) == 'never' || $end === '' ? '' : $context->utcdate($end)\n// );\n// }\n// }\n return TRUE;\n }",
"public function edit($id)\n {\n //stub\n }",
"public function edit($id) // modifica\n {\n \n }",
"public function edit(account $account)\n {\n //\n }"
] | [
"0.7094318",
"0.64773977",
"0.6067128",
"0.60090536",
"0.5906971",
"0.58210164",
"0.57934976",
"0.57934976",
"0.57526845",
"0.57195693",
"0.56932306",
"0.56932306",
"0.5653561",
"0.56260335",
"0.56192225",
"0.5595491",
"0.559186",
"0.5579579",
"0.5577838",
"0.5556251",
"0.5552918",
"0.55327684",
"0.5530835",
"0.5529865",
"0.5527702",
"0.55176884",
"0.55171573",
"0.54934263",
"0.5490496",
"0.54847604"
] | 0.7277615 | 0 |
Actualiser to edit a realm. | function edit_realm($realm,$name,$troll_name,$qa,$private,$new_owner)
{
$_qa=array();
for ($i=1;$i<=30;$i++)
{
if (strlen($qa[$i]['q'])>0)
{
$_qa['q'.strval($i)]=$qa[$i]['q'];
$_qa['a'.strval($i)]=$qa[$i]['a'];
} else
{
$_qa['q'.strval($i)]='';
$_qa['a'.strval($i)]='';
}
}
$GLOBALS['SITE_DB']->query_update('w_realms',array_merge($_qa,array('name'=>$name,'troll_name'=>$troll_name,'r_private'=>$private,'owner'=>$new_owner)),array('id'=>$realm),'',1);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function edit(){\r\n\t\t//$this->auth->set_access('edit');\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 edit_realm_wrap($member_id,$name,$troll_name,$qa,$private,$new_owner)\n{\n\tif ($private!=1) $private=0;\n\tif ($name=='') ocw_refresh_with_message(do_lang_tempcode('W_MISSING_NAME'),'warn');\n\tif (is_null($new_owner)) $new_owner=$member_id;\n\tif ($troll_name=='') ocw_refresh_with_message(do_lang_tempcode('W_MISSING_TROLL_NAME'),'warn');\n\n\t$realm=$GLOBALS['SITE_DB']->query_value('w_members','location_realm',array('id'=>$member_id));\n\n\tif ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$realm))!=$member_id))\n\t\tocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');\n\n\tedit_realm($realm,$name,$troll_name,$qa,$private,$new_owner);\n\tocw_refresh_with_message(do_lang_tempcode('SUCCESS'));\n}",
"function setRealm($realm);",
"public function edit(Autorisation $autorisation)\n {\n //\n }",
"public function edit(Rol $rol)\n {\n //\n }",
"public function edit(Rol $rol)\n {\n //\n }",
"public function edit(FactorActualizacion $factorActualizacion)\n {\n //\n }",
"public function edit($id)\n {\n //Check if user is authorized to access this page\n $request->user()->authorizeRoles(['admin', 'hrmanager', 'hruser']);\n }",
"abstract public function edit();",
"public function edit()\n\t\t{\n\t\t\tif(isset($_REQUEST['id'])) {\n\t\t\t\t$id = $_REQUEST['id'];\n\t\t\t\t$data = $this->model->getRolById($id);\n\t\t\t\trequire 'views/layout.php';\n\t\t\t\trequire 'views/rol/editRol.php';\n\t\t\t} else {\n\t\t\t\techo \"Error\";\n\t\t\t}\n\t\t}",
"public function editAction() {\n\t\n\t\t$request = $this->getRequest();\n\t\t$aclRoleId = $this->filter($request->getParam('id'));\n\t\t$this->view->aclresources = $this->getAclResources();\n\t\t\n\t\tif ($request->isPost()) {\n\t\t\t$updated = $this->AclRoles->process($request->getParams(), 'update');\n\t\t\tif (!$updated) {\n\t\t\t\t$this->addFlash('Error updating ACL role. Correct form below.', 'errors');\n\t\t\t\t$this->view->errors = $this->AclRoles->getErrors();\n\t\t\t\t$this->view->data = $request->getParams();\n\t\t\t\n\t\t\t} else {\n\t\t\t\t$this->addFlash('ACL Role updated.', 'notice');\n\t\t\t\t$this->_redirect($this->view->base_url.'/admin/acl-roles');\n\t\t\t}\n\t\t\t\n\t\t} else {\n\t\t\t$aclRole = $this->AclRoles->fetchById($aclRoleId);\n\t\t\tif ($aclRole) {\n\t\t\t\t$roleData = $aclRole->toArray();\n\t\t\t\t$ruleData = $this->AclRules->rules2Form($aclRoleId);\n\t\t\t\t$this->view->data = array_merge($roleData, $ruleData);\n\t\t\t\n\t\t\t} else {\n\t\t\t\t$this->addFlash('Invalid ACL Role.', 'errors');\n\t\t\t\t$this->_redirect($this->view->base_url.'/admin/acl-roles');\n\t\t\t}\n\t\t}\n\t}",
"public function edit(TurnoAfiliado $TurnoAfiliado)\n {\n //\n }",
"public function edit(Discord_Account $discord)\n {\n //\n }",
"function setRealm($realm) {\n\n $this->realm = $realm;\n\n }",
"public function edit(Ticket $ticket) {\n\t\t//\n\t}",
"public function editAction() {\n if ($this->getRequest()->isPost()) {\n $data = $this->getRequestData();\n \n $user = $this->tokenPayload;\n $role = $this->entityManager->getRepository(Role::class)\n ->find($data['id']);\n \n if(isset($data['id']) && $role) {\n //Create New Form Permission\n $form = new RoleForm('update', $this->entityManager, $role);\n $form->setData($data);\n if ($form->isValid()) {\n $data = $form->getData(); \n $this->roleManager->updateRole($role, $data, $user); \n $this->error_code = 1;\n $this->apiResponse['message'] = \"You have modified Role!\";\n } else {\n $this->error_code = 0;\n $this->apiResponse['data'] = $form->getMessages(); \n } \n } else {\n $this->error_code = 0;\n $this->apiResponse['message'] = 'NOT_FOUND'; \n } \n \n } \n \n return $this->createResponse();\n }",
"public function edit(Tdr $tdr)\n {\n //\n }",
"public function edit();",
"abstract public function edit($id);",
"abstract public function edit($id);",
"public function edit(Account $account)\n {\n //\n }",
"public function edit(Account $account)\n {\n //\n }",
"public function edit(Account $account)\n {\n //\n }",
"public function edit(account $account)\n {\n //\n }",
"public function edit(account $account)\n {\n //\n }",
"public function edit(account $account)\n {\n //\n }",
"function edit(){\r\n\t\t$role_id=decodeId($this->uri->segment(4,null));\r\n\t\tif($role_id==null){\t\t\t\t\t\t\t\t\t// if Id is empty\r\n\t\t\tset_flash_message(ROLE_ID_EMPTY,'error');\r\n\t\t\tredirect(\"admincms/roles/\");\t\t\r\n\t\t}\r\n\t\tif(!$this->role->isRoleVerified($role_id)){ // if not Available Location\r\n\t\t\tset_flash_message(ROLE_VERIFICATION_FAILED,'error');\r\n\t\t\tredirect(\"admincms/roles/\");\r\n\t\t}\r\n\t\t$data['role']=$this->role->getRole($role_id);\r\n\t\t$this->load->view(\"admincms/role/edit\",$data);\r\n\t}",
"public function actualizar_put( $id ){\n\n // Si no viene un Autor ó no viene un Id\n if( !$this->put() || !$id ){\n $this->response( null, 400 );\n }\n\n $update = $this->autores_model->update( $id, $this->put() );\n\n // Comprobar que venga la informacion\n if( !is_null( $update ) ){\n $this->response( array( 'response' => 'Autor actualizado correctamente..' ), 200 );\n } else {\n $this->response( array('error' => \"Algo ha falldo en el servidor. No se pudo editar el autor\" ), 400 );\n }\n }",
"public function edit($id) {\n $this->authorize('lead-edit');\n }",
"public function edit(Marca $marca)\n {\n //\n }"
] | [
"0.66301817",
"0.6577248",
"0.63839215",
"0.61981875",
"0.61844456",
"0.61844456",
"0.6182028",
"0.6175658",
"0.6155843",
"0.6150406",
"0.614714",
"0.60992444",
"0.60849845",
"0.6075769",
"0.60614467",
"0.6061097",
"0.60229266",
"0.6006031",
"0.59906334",
"0.59906334",
"0.5987631",
"0.5987631",
"0.5987631",
"0.5980962",
"0.5980962",
"0.5980962",
"0.59753114",
"0.5972235",
"0.5971975",
"0.597018"
] | 0.6671035 | 0 |
Wrapper to edit an item copy. Does not return. | function edit_item_wrap_copy($member_id,$name,$cost,$not_infinite,$new_x,$new_y,$new_realm,$user)
{
if (!($cost>0)) $cost=0;
if ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_items','copy_owner',array('name'=>$name))!=$member_id))
ocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');
// Get $realm,$x,$y from $member_id
list($realm,$x,$y)=get_loc_details($member_id);
if ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$new_realm))!=$member_id) && ($GLOBALS['SITE_DB']->query_value('w_realms','r_private',array('id'=>$new_realm))==1))
ocw_refresh_with_message(do_lang_tempcode('W_NO_ACCESS_MOVE'),'warn');
if (($x!=$new_x) || ($y!=$new_y) || ($realm!=$new_realm))
{
// Check we don't have a copy of this item at new dest already
$t=$GLOBALS['SITE_DB']->query_value_null_ok('w_items','name',array('location_x'=>$new_x,'location_y'=>$new_y,'location_realm'=>$new_realm,'copy_owner'=>$user,'name'=>$name));
if (!is_null($t)) ocw_refresh_with_message(do_lang_tempcode('W_COPY_SOURCE_ALREADY'),'warn');
}
// Fix infinity source thing... we can never make a non-infinite source into an infinite source
$old_not_infinite=$GLOBALS['SITE_DB']->query_value_null_ok('w_items','not_infinite',array('location_x'=>$x,'location_y'=>$y,'location_realm'=>$realm,'copy_owner'=>$user,'name'=>$name));
if (is_null($old_not_infinite)) warn_exit(do_lang_tempcode('MISSING_RESOURCE'));
if ($old_not_infinite==1) $not_infinite=1; elseif ($not_infinite!=1) $not_infinite=0;
edit_item_copy($user,$name,$not_infinite,$cost,$new_x,$new_y,$new_realm,$x,$y,$realm);
ocw_refresh_with_message(do_lang_tempcode('SUCCESS'));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function edit_item_copy($member_id,$name,$not_infinite,$cost,$new_x,$new_y,$new_realm,$x,$y,$realm)\n{\n\t$GLOBALS['SITE_DB']->query_update('w_items',array('not_infinite'=>$not_infinite,'cost'=>$cost,'location_x'=>$new_x,'location_y'=>$new_y,'location_realm'=>$new_realm),array('location_x'=>$x,'location_y'=>$y,'location_realm'=>$realm,'copy_owner'=>$member_id,'name'=>$name));\n}",
"function editcopy()\n\t{\n\t\t$is_event_editor = JEVHelper::isEventCreator();\n\t\tif (!$is_event_editor)\n\t\t{\n\t\t\tthrow new Exception(Text::_('ALERTNOTAUTH'), 403);\n\n\t\t\treturn false;\n\t\t}\n\t\t$this->editCopy = true;\n\t\t$this->edit();\n\n\t}",
"public function edit(Item $item)\n {\n //\n }",
"public function edit(Item $item)\n {\n //\n }",
"public function edit(Item $item)\n {\n //\n }",
"public function edit(Item $item)\n {\n //\n }",
"function edit_item_wrap($member_id,$original_name,$name,$bribable,$healthy,$picture_url,$new_owner,$max_per_player,$replicateable,$description)\n{\n\tif ($name=='') ocw_refresh_with_message(do_lang_tempcode('W_MISSING_NAME'),'warn');\n\n\tif ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_itemdef','owner',array('name'=>$original_name))!=$member_id))\n\t\tocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');\n\n\tif ($healthy!=1) $healthy=0;\n\tif ($bribable!=1) $bribable=0;\n\tif ($replicateable!=1) $replicateable=0;\n\tif (!($max_per_player>0)) $max_per_player=0;\n\tedit_item($name,$original_name,$bribable,$healthy,$picture_url,$new_owner,$max_per_player,$replicateable,$description);\n\tocw_refresh_with_message(do_lang_tempcode('SUCCESS'));\n}",
"function _edititem($itemid, $username, $password, $catid, $title, $body, $more, $wasdraft, $publish, $closed) {\n\tglobal $manager;\n\n\t// 1. login\n\t$mem = new MEMBER();\n\tif (!$mem->login($username, $password))\n\t\treturn _error(1,\"Could not log in\");\n\n\t// 2. check if allowed to add to blog\n\tif (!$manager->existsItem($itemid,1,1))\n\t\treturn _error(6,\"No such item ($itemid)\");\n\tif (!$mem->canAlterItem($itemid))\n\t\treturn _error(7,\"Not allowed to alter item\");\n\n\t// 3. update item\n\tITEM::update($itemid, $catid, $title, $body, $more, $closed, $wasdraft, $publish, 0);\n\n\treturn new xmlrpcresp(new xmlrpcval(1,\"boolean\"));\n}",
"function editItem($response, $item) {\n\n // Retrieve data\n $data = openDataFile();\n\n // Retrieve item ID and update item in array\n $id = $item->id;\n $data[$id] = $item;\n\n // Write data file\n writeDataFile($data);\n\n // Set response\n $response['code'] = 1000;\n $response['text'] = \"Success! Item Edited!\";\n\n // Return response\n return $response;\n }",
"public function actionCopy()\n\t{\n\t\t$id=$_GET['id'];\n\t\t$model=$this->loadModel($id);\n\t\tif(isset($_POST['Item']))\n\t\t{\n\t\t\t$createmodel=new Item;\n\t\t\t$createmodel->attributes=$_POST['Item'];\n\t\t\tif($createmodel->save())\n\t\t\t\t$this->redirect(array('view','id'=>$createmodel->fItemNo));\n\t\t}\n\n\t\t$this->render('copy',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}",
"abstract public function edit();",
"abstract protected function copy();",
"public function edit($itemid)\n {\n return Item::findorfail($itemid);\n }",
"public function ___clone(Saveable $item, $name = '') {\n\t\treturn parent::___clone($item, $name);\n\t\t// @TODO clone the field context data\n\t\t/*\n\t\t$id = $item->id; \n\t\t$item = parent::___clone($item);\n\t\tif(!$item) return false;\n\t\treturn $item; \t\n\t\t*/\n\t}",
"function edit_item($title, $description, $link, $pubDate, $guid) {\n\t\t$item_nodes = $this->find_items_by_guid($guid);\n\t\tforeach ($item_nodes as &$node) {\n\t\t\t$node->title = $title;\n\t\t\t$node->description = $description;\n\t\t\t$node->link = $link;\n\t\t\t$node->pubDate = $pubDate;\n\t\t\t$node->guid = $guid;\n\t\t}\n\t}",
"function taskEditI() {\r\n\t\t\t$this->obj_edit->editItem();\r\n\t\t}",
"public function __clone()\n {\n foreach ($this->items as &$item) {\n $item = clone $item;\n }\n }",
"public function editAction()\r\n {\r\n $item = $this->getItem();\r\n if($item === false) {\r\n $this->getResponse()->setStatusCode(404);\r\n return;\r\n }\r\n\r\n /** @var \\Zend\\Form\\Form $form */\r\n $form = $this->getServiceLocator()->get('thingyform'); // name to be dealt with here\r\n $form->setObject($item);\r\n\r\n return array(\r\n 'item' => $item,\r\n 'form' => $form\r\n );\r\n }",
"public function __clone() {\n $this->items = Arrays::copy($this->items);\n }",
"public function copy() {\n\t\t\t$map_id = intval( $_GET['map_id'] );\n\t\t\t$modelFactory = new WPGMP_Model();\n\t\t\t$map_obj = $modelFactory->create_object( 'map' );\n\t\t\t$map = $map_obj->copy( $map_id );\n\t\t\t$this->prepare_items();\n\t\t\t$this->listing();\n\t\t}",
"public function edit(KanbanItem $kanbanItem)\n {\n\n }",
"public function __clone() {\n $this->toggler = clone $this->toggler;\n $this->items = Arrays::copy($this->items);\n }",
"function add_item_wrap_copy($member_id,$name,$cost,$not_infinite)\n{\n\tif ($not_infinite!=1) $not_infinite=0;\n\tif (!($cost>0)) $cost=0;\n\n\t// Get $realm,$x,$y from $member_id\n\tlist($realm,$x,$y)=get_loc_details($member_id);\n\n\tif ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$realm))!=$member_id) && ($GLOBALS['SITE_DB']->query_value('w_realms','r_private',array('id'=>$realm))==1))\n\t\tocw_refresh_with_message(do_lang_tempcode('W_NO_EDIT_ACCESS_PRIVATE_REALM'),'warn');\n\n\tif ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_itemdef','owner',array('name'=>$name))!=$member_id) && ($GLOBALS['SITE_DB']->query_value('w_itemdef','replicateable',array('name'=>$name))==0))\n\t\tocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');\n\n\t// Make sure that they aren't in the brig and adding a bribable!\n\t$bribable=$GLOBALS['SITE_DB']->query_value('w_itemdef','bribable',array('name'=>$name));\n\tif (($x==0) && ($y==2) && ($bribable==1)) ocw_refresh_with_message(do_lang_tempcode('W_NICE_TRY'),'warn');\n\n\t// Charge them\n\tif (!has_specific_permission($member_id,'administer_ocworld'))\n\t{\n\t\t$price=get_price('mud_item_copy');\n\t\tif (available_points($member_id)<$price) ocw_refresh_with_message(do_lang_tempcode('W_EXPENSIVE',integer_format($price)),'warn');\n\t\trequire_code('points2');\n\t\tcharge_member($member_id,$price,do_lang('W_MADE_OCWORLD',$name));\n\t}\n\n\tadd_item_to_room($realm,$x,$y,$name,$not_infinite,$cost,$member_id);\n\n\tocw_refresh_with_message(do_lang_tempcode('W_MADE_ITEM_COPY_AT',escape_html($name)));\n}",
"public function editItem( $id, array $values );",
"public function testUpdateObjectItem()\n {\n }",
"public function edit($type=null,$item_id,$id)\n {\n //\n }",
"public function edit(\n Escape $escape,\n EscapeReadingList $readingList,\n ReadingListItem $item\n ) {\n //\n }",
"public function testCopyEdit()\n {\n $this->browse(function (Browser $browser) {\n $browser->assertPathIs('/copy')\n ->press('.table-text')\n ->clickLink('Bewerken')\n ->type('datebought', '2017-05-02')\n ->select('location_id', 'Bibliotheek de Stroming')\n ->select('book_id', 'Harry Potter and the Deathly Hallows')\n ->select('status_id', 'afgeschreven')\n ->press('Opslaan')\n ->assertSee('is bijgewerkt.');\n });\n }",
"abstract public function copy();",
"public function update($item);"
] | [
"0.69504267",
"0.6359195",
"0.6131764",
"0.6131764",
"0.6131764",
"0.6131764",
"0.60866743",
"0.60776293",
"0.60433906",
"0.60212106",
"0.60108566",
"0.5772949",
"0.5767018",
"0.5749331",
"0.573833",
"0.5724188",
"0.5714218",
"0.5701863",
"0.5676889",
"0.5673955",
"0.566862",
"0.5662091",
"0.56605893",
"0.56415266",
"0.56372625",
"0.5614224",
"0.5568399",
"0.55622184",
"0.5534456",
"0.55308276"
] | 0.6543224 | 1 |
Actualiser to edit an item copy. | function edit_item_copy($member_id,$name,$not_infinite,$cost,$new_x,$new_y,$new_realm,$x,$y,$realm)
{
$GLOBALS['SITE_DB']->query_update('w_items',array('not_infinite'=>$not_infinite,'cost'=>$cost,'location_x'=>$new_x,'location_y'=>$new_y,'location_realm'=>$new_realm),array('location_x'=>$x,'location_y'=>$y,'location_realm'=>$realm,'copy_owner'=>$member_id,'name'=>$name));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function editcopy()\n\t{\n\t\t$is_event_editor = JEVHelper::isEventCreator();\n\t\tif (!$is_event_editor)\n\t\t{\n\t\t\tthrow new Exception(Text::_('ALERTNOTAUTH'), 403);\n\n\t\t\treturn false;\n\t\t}\n\t\t$this->editCopy = true;\n\t\t$this->edit();\n\n\t}",
"public function actionCopy()\n\t{\n\t\t$id=$_GET['id'];\n\t\t$model=$this->loadModel($id);\n\t\tif(isset($_POST['Item']))\n\t\t{\n\t\t\t$createmodel=new Item;\n\t\t\t$createmodel->attributes=$_POST['Item'];\n\t\t\tif($createmodel->save())\n\t\t\t\t$this->redirect(array('view','id'=>$createmodel->fItemNo));\n\t\t}\n\n\t\t$this->render('copy',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}",
"function edit_item_wrap_copy($member_id,$name,$cost,$not_infinite,$new_x,$new_y,$new_realm,$user)\n{\n\tif (!($cost>0)) $cost=0;\n\n\tif ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_items','copy_owner',array('name'=>$name))!=$member_id))\n\t\tocw_refresh_with_message(do_lang_tempcode('ACCESS_DENIED__I_ERROR',$GLOBALS['FORUM_DRIVER']->get_username(get_member())),'warn');\n\n\t// Get $realm,$x,$y from $member_id\n\tlist($realm,$x,$y)=get_loc_details($member_id);\n\n\tif ((!has_specific_permission($member_id,'administer_ocworld')) && ($GLOBALS['SITE_DB']->query_value('w_realms','owner',array('id'=>$new_realm))!=$member_id) && ($GLOBALS['SITE_DB']->query_value('w_realms','r_private',array('id'=>$new_realm))==1))\n\t\tocw_refresh_with_message(do_lang_tempcode('W_NO_ACCESS_MOVE'),'warn');\n\n\tif (($x!=$new_x) || ($y!=$new_y) || ($realm!=$new_realm))\n\t{\n\t\t// Check we don't have a copy of this item at new dest already\n\t\t$t=$GLOBALS['SITE_DB']->query_value_null_ok('w_items','name',array('location_x'=>$new_x,'location_y'=>$new_y,'location_realm'=>$new_realm,'copy_owner'=>$user,'name'=>$name));\n\t\tif (!is_null($t)) ocw_refresh_with_message(do_lang_tempcode('W_COPY_SOURCE_ALREADY'),'warn');\n\t}\n\n\t// Fix infinity source thing... we can never make a non-infinite source into an infinite source\n\t$old_not_infinite=$GLOBALS['SITE_DB']->query_value_null_ok('w_items','not_infinite',array('location_x'=>$x,'location_y'=>$y,'location_realm'=>$realm,'copy_owner'=>$user,'name'=>$name));\n\tif (is_null($old_not_infinite)) warn_exit(do_lang_tempcode('MISSING_RESOURCE'));\n\tif ($old_not_infinite==1) $not_infinite=1; elseif ($not_infinite!=1) $not_infinite=0;\n\n\tedit_item_copy($user,$name,$not_infinite,$cost,$new_x,$new_y,$new_realm,$x,$y,$realm);\n\tocw_refresh_with_message(do_lang_tempcode('SUCCESS'));\n}",
"public function edit(Item $item)\n {\n //\n }",
"public function edit(Item $item)\n {\n //\n }",
"public function edit(Item $item)\n {\n //\n }",
"public function edit(Item $item)\n {\n //\n }",
"abstract public function edit();",
"public function edit(OrderItem $orderItem)\n {\n //\n }",
"public function edit(OrderItem $orderItem)\n {\n //\n }",
"public function edit(OrderItem $orderItem)\n {\n //\n }",
"function taskEditI() {\r\n\t\t\t$this->obj_edit->editItem();\r\n\t\t}",
"public function testUpdateObjectItem()\n {\n }",
"public function edit(shareholder $shareholder)\n {\n //\n }",
"public function edit(FormItem $formItem)\n {\n //\n }",
"public function edit(KanbanItem $kanbanItem)\n {\n\n }",
"function _edititem($itemid, $username, $password, $catid, $title, $body, $more, $wasdraft, $publish, $closed) {\n\tglobal $manager;\n\n\t// 1. login\n\t$mem = new MEMBER();\n\tif (!$mem->login($username, $password))\n\t\treturn _error(1,\"Could not log in\");\n\n\t// 2. check if allowed to add to blog\n\tif (!$manager->existsItem($itemid,1,1))\n\t\treturn _error(6,\"No such item ($itemid)\");\n\tif (!$mem->canAlterItem($itemid))\n\t\treturn _error(7,\"Not allowed to alter item\");\n\n\t// 3. update item\n\tITEM::update($itemid, $catid, $title, $body, $more, $closed, $wasdraft, $publish, 0);\n\n\treturn new xmlrpcresp(new xmlrpcval(1,\"boolean\"));\n}",
"public function edit(PaymentItem $paymentItem)\n {\n //\n }",
"public function edit(ItemCategory $itemCategory)\n {\n //\n }",
"public function edit(ItemCategory $itemCategory)\n {\n //\n }",
"public function edit(ItemCarrinho $itemCarrinho)\n {\n //\n }",
"public function testeAlterarItem(){\r\n\t\t\r\n\t\tglobal $tabItens;\r\n\r\n\t\t//Novos dados\r\n\t\t$dadosForm = [\"identificador2\", \"marca2\", \"titulo2\", \"descricao2\", \"caracteristicas2\", 1, 1, \"CCCCCC\", \"FFCCEE\", \"enderFoto.jpg\"];\r\n\r\n\t\t$this->idItem = incluirItem($this->mysqli, $this->dadosForm)[1];\r\n\r\n\t\t//Assert\r\n\t\t$this->assertEquals(\"sucesso\", alterarItem($this->mysqli, $this->idItem, $dadosForm));\r\n\t}",
"public function editAction(InventoryItem $item) {\n\t\t$this->view->assign('item', $item);\n\t}",
"public function edit()\n {\n $id = $this->uri->segment(5);\n if (empty($id)) {\n Template::set_message(lang('item_invalid_id'), 'error');\n\n redirect(SITE_AREA . '/content/item');\n }\n \n if (isset($_POST['save'])) {\n $this->auth->restrict($this->permissionEdit);\n\n if ($this->save_item('update', $id)) {\n log_activity($this->auth->user_id(), lang('item_act_edit_record') . ': ' . $id . ' : ' . $this->input->ip_address(), 'item');\n Template::set_message(lang('item_edit_success'), 'success');\n redirect(SITE_AREA . '/content/item');\n }\n\n // Not validation error\n if ( ! empty($this->item_model->error)) {\n Template::set_message(lang('item_edit_failure') . $this->item_model->error, 'error');\n }\n }\n \n elseif (isset($_POST['delete'])) {\n $this->auth->restrict($this->permissionDelete);\n\n if ($this->item_model->delete($id)) {\n log_activity($this->auth->user_id(), lang('item_act_delete_record') . ': ' . $id . ' : ' . $this->input->ip_address(), 'item');\n Template::set_message(lang('item_delete_success'), 'success');\n\n redirect(SITE_AREA . '/content/item');\n }\n\n Template::set_message(lang('item_delete_failure') . $this->item_model->error, 'error');\n }\n \n Template::set('item', $this->item_model->find($id));\n\n Template::set('toolbar_title', lang('item_edit_heading'));\n Template::render();\n }",
"public function testCopyEdit()\n {\n $this->browse(function (Browser $browser) {\n $browser->assertPathIs('/copy')\n ->press('.table-text')\n ->clickLink('Bewerken')\n ->type('datebought', '2017-05-02')\n ->select('location_id', 'Bibliotheek de Stroming')\n ->select('book_id', 'Harry Potter and the Deathly Hallows')\n ->select('status_id', 'afgeschreven')\n ->press('Opslaan')\n ->assertSee('is bijgewerkt.');\n });\n }",
"public function copy() {\n\t\t\t$map_id = intval( $_GET['map_id'] );\n\t\t\t$modelFactory = new WPGMP_Model();\n\t\t\t$map_obj = $modelFactory->create_object( 'map' );\n\t\t\t$map = $map_obj->copy( $map_id );\n\t\t\t$this->prepare_items();\n\t\t\t$this->listing();\n\t\t}",
"public function editAction()\r\n {\r\n $item = $this->getItem();\r\n if($item === false) {\r\n $this->getResponse()->setStatusCode(404);\r\n return;\r\n }\r\n\r\n /** @var \\Zend\\Form\\Form $form */\r\n $form = $this->getServiceLocator()->get('thingyform'); // name to be dealt with here\r\n $form->setObject($item);\r\n\r\n return array(\r\n 'item' => $item,\r\n 'form' => $form\r\n );\r\n }",
"public function edit(ProcessedProduct $processedProduct)\n {\n //\n }",
"function editItem($response, $item) {\n\n // Retrieve data\n $data = openDataFile();\n\n // Retrieve item ID and update item in array\n $id = $item->id;\n $data[$id] = $item;\n\n // Write data file\n writeDataFile($data);\n\n // Set response\n $response['code'] = 1000;\n $response['text'] = \"Success! Item Edited!\";\n\n // Return response\n return $response;\n }",
"public function edit($type=null,$item_id,$id)\n {\n //\n }"
] | [
"0.67461413",
"0.6502433",
"0.6433578",
"0.6388094",
"0.6388094",
"0.6388094",
"0.6388094",
"0.6162548",
"0.61179376",
"0.61179376",
"0.61179376",
"0.60920537",
"0.6028421",
"0.5999529",
"0.59803474",
"0.59763044",
"0.5972791",
"0.5900364",
"0.58608735",
"0.58608735",
"0.583883",
"0.58333546",
"0.5831973",
"0.5829378",
"0.5821096",
"0.5814183",
"0.5798932",
"0.5786409",
"0.57816684",
"0.5768115"
] | 0.69263315 | 0 |
Returns true if a string is empty (including empty HTML) | function vf_html_empty($str) {
return preg_match('#\S#', strip_tags($str)) !== 1;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static function isEmptyString()\n {\n return Hamcrest_Text_IsEmptyString::isEmptyString();\n }",
"function empty_string($string) {\n\t\t\tif (is_string($string)) {\n\t\t\t\tif (strlen($string) <= 0)\n\t\t\t\t\treturn true;\n\t\t\t\telse\n\t\t\t\t\treturn false;\n\t\t\t}\n\t\t\treturn empty($string);\n\t\t}",
"public function strIsEmpty($str): bool\n {\n return preg_replace('/\\s+/', '', $str) === '';\n }",
"function empty_filter($str)\n{\n\treturn (strlen($str) > 0);\n}",
"function v_is_empty($var) {\n $var = strip_tags($var);\n $var = str_replace(' ', '', $var);\n return v_custom_match('/^\\s*$/', $var);\n}",
"public static function isEmptyOrNullString()\n {\n return Hamcrest_Text_IsEmptyString::isEmptyOrNullString();\n }",
"public function isEmpty()\n {\n return $this->contents === '';\n }",
"function string_is_null_or_empty ($string) {\n\n\t\treturn $string === NULL || $string === '';\n\n\t}",
"function isEmpty($str){\n if($str){\n $cleanStr = trim($str);\n return (strlen($cleanStr)<= 0)? true : false;\n }\n}",
"function veryempty ($text) {\n $output = ((empty($text)) || (trim($text) == '') || ($text == 'NULL') || ($text == '0')) ? true: false;\n return $output;\n}",
"function is_empty_string2($str) {\n return (!isset($str) || trim($str)==='');\n}",
"public function isEmpty(): bool\n {\n return $this->value === '';\n }",
"function veryempty ($text)\n{\n $output = ((empty($text)) || (trim($text) == '') || ($text == 'NULL') || ($text == '0')) ? true: false;\n return $output;\n}",
"function isEmpty($str){\n return strlen(trim($str)) == 0;\n}",
"function test_for_empty_html($html)\n{\n\treturn preg_match('#^( |\\s|</?br\\s*/?>|[\\x{200B}-\\x{200D}])*$#ui', $html);\n}",
"function isempty($str){\r\n return (!isset($str) || trim($str) === '');\r\n}",
"function is_element_empty( $element ) {\n\t$element = trim( $element );\n\treturn empty( $element ) ? false : true;\n}",
"function isNonEmpty($input){\n return $input != \"\";\n }",
"public static function filled( $str ){\n\t\t\t\t$str = trim( $str );\n\t\t\t\treturn !empty( $str );\n\t\t\t}",
"function is_element_empty($element)\n{\n $element = trim($element);\n return !empty($element);\n}",
"public function isEmpty() {\n\t\treturn $this->getValue() == null || $this->getValue() == '';\n\t}",
"function none($str) {\n return ($str == \"\");\n }",
"public static function isEmpty($string)\n {\n return trim($string) === '';\n }",
"public function isEmpty(): bool\n {\n return $this->buffer === '';\n }",
"function isBlank( $strInput ) {\n\t// Returns 1 if the strInput is empty or null or just space(s)\n\t// expects a string as input\n\t\n\t// First trim the string\n\t$strTemp = trim( $strInput );\n\t\n\t// Check if there are any characters\n\tif ( strlen( $strTemp ) == 0 ) {\n\t\t// There aren't, the string is blank\n\t\t$Ret = 1;\n\t} else {\n\t\t// There are some characters in there\n\t\t$Ret = 0;\n\t}\n\t\n\treturn ( $Ret );\n}",
"function _notEmpty($value){\n\t$value = trim($value);\n\treturn ($value !== '') ? true : false;\n}",
"function isEmptyString($str) {\n\tif ($str == \"\") {\n\t\treturn true; \n\t}\n\tif (trim($str) == \"\") {\n\t\treturn true;\n\t} else {\n\t\treturn false;\n\t}\n}",
"public function isBlank(string $string): bool\n {\n return trim((string)$string) === '';\n }",
"public function isBlank($string) {\n\t\treturn trim((string)$string) === '';\n\t}",
"protected function isEmpty(string $input): bool\n {\n return empty($input);\n }"
] | [
"0.7785887",
"0.7722758",
"0.7477232",
"0.7471831",
"0.74451643",
"0.74435765",
"0.7434097",
"0.73926777",
"0.73091906",
"0.7298576",
"0.72863245",
"0.7282686",
"0.72794276",
"0.72620904",
"0.72597253",
"0.72539455",
"0.7242111",
"0.72420895",
"0.7238016",
"0.71501005",
"0.71466756",
"0.7135864",
"0.71328217",
"0.7128923",
"0.71088827",
"0.7073904",
"0.70640844",
"0.70587265",
"0.7053897",
"0.7049947"
] | 0.84702533 | 0 |
Loads an HTML document from the specified filename, and returns the file's contents as HTML. | function loadHTML($filename)
{
$doc = new DOMDocument();
$doc->loadHTMLFile($filename);
return $doc->saveHTML();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function loadHTMLasDOM($filename)\n\t{\n\t\t$doc = new DOMDocument();\n\t\t$doc->loadHTMLFile($filename);\n\t\treturn $doc;\n\t}",
"public static function load_file($filename)\n\t{\n\t\t$document = new DOMDocument('1.0', 'utf-8');\n\t\t$document->formatOutput = true;\n\t\t$document->preserveWhiteSpace = false;\n\n\t\t// Attempt to load the document\n\t\tif (!$document->load($filename))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\treturn self::load_element($document->documentElement);\n\t}",
"public function GetHTML()\n\t{\n\t\treturn file_get_contents($this->m_Filename);\n\t}",
"protected function loadHtml()\n {\n $this->html = $this->fsio->get($this->page->getTarget());\n }",
"function file_get_html($url, $use_include_path = false, $context=null, $offset = -1, $maxLen=-1, $lowercase = true, $forceTagsClosed=true, $target_charset = DEFAULT_TARGET_CHARSET, $stripRN=true, $defaultBRText=DEFAULT_BR_TEXT, $defaultSpanText=DEFAULT_SPAN_TEXT)\r\n {\r\n $dom = new simple_html_dom(null, $lowercase, $forceTagsClosed, $target_charset, $stripRN, $defaultBRText, $defaultSpanText);\r\n // For sourceforge users: uncomment the next line and comment the retreive_url_contents line 2 lines down if it is not already done.\r\n $contents = file_get_contents($url, $use_include_path, $context, $offset);\r\n // Paperg - use our own mechanism for getting the contents as we want to control the timeout.\r\n //$contents = retrieve_url_contents($url);\r\n if (empty($contents) || strlen($contents) > MAX_FILE_SIZE)\r\n {\r\n return false;\r\n }\r\n // The second parameter can force the selectors to all be lowercase.\r\n $dom->load($contents, $lowercase, $stripRN);\r\n return $dom;\r\n }",
"public function loadFile($file_path) {\n \n if (!$this->isFileReady($file_path)) {\n return;\n }\n \n $html = new \\DOMDocument('1.0', 'UTF-8');\n\t $sp = mb_convert_encoding(file_get_contents($file_path), 'HTML-ENTITIES', \"UTF-8\"); \n $html->loadHTML($sp);\n\t $html->encoding = 'UTF-8'; \n $this->parseDOM($html);\n }",
"function load($filename)\n \t{\n\n\t\t$this->doc = new DOMDocument;\n\n\t\t// We don't want to bother with white spaces\n\t\t$this->doc->preserveWhiteSpace = false;\n\n\t\t$this->doc->Load($filename);\n\n\t}",
"function file_get_html ($url, $use_include_path = false, $context = null, $offset = -1, $maxLen = -1, $lowercase = true, $forceTagsClosed = true, $target_charset = DEFAULT_TARGET_CHARSET, $stripRN = true, $defaultBRText = DEFAULT_BR_TEXT, $defaultSpanText = DEFAULT_SPAN_TEXT)\r\n {\r\n // We DO force the tags to be terminated.\r\n $dom = new SimpleDom(null, $lowercase, $forceTagsClosed, $target_charset, $stripRN, $defaultBRText, $defaultSpanText);\r\n // For sourceforge users: uncomment the next line and comment the retreive_url_contents line 2 lines down if it is not already done.\r\n $contents = @file_get_contents($url, $use_include_path, $context, $offset);\r\n // Paperg - use our own mechanism for getting the contents as we want to control the timeout.\r\n // $contents = retrieve_url_contents($url);\r\n if (empty($contents) || strlen($contents) > MAX_FILE_SIZE) {\r\n return false;\r\n }\r\n // The second parameter can force the selectors to all be lowercase.\r\n $dom->load($contents, $lowercase, $stripRN);\r\n return $dom;\r\n }",
"public static function fileGetContent($file)\n {\n $content = file_get_contents($file);\n $dom = \\phpQuery::newDocumentHTML($content, $charset = 'utf-8');\n if($dom->find('body')->html() == null) $content = false;\n return $content;\n }",
"function build_and_display_html_from_file($file_name) {\n // HTML so we can display it to the user.\n\n $file_path = DATA_DIRECTORY . \"/$file_name\";\n\n $file_contents = get_file_contents($file_path);\n $html_data = get_data_for_html($file_name, $file_contents);\n\n echo \"<article>\";\n\n echo \"<h2>Module Header Data...</h2>\";\n display_data_from_array($html_data[\"module_header\"]);\n\n echo \"<h2>Student ID and Mark data read from file...
</h2>\";\n display_data_from_array($html_data[\"raw_student_marks\"]);\n\n echo \"<h2>ID's and module marks to be included...</h2>\";\n display_data_from_array($html_data[\"valid_student_marks\"]);\n\n echo \"<h2>Statistical Analysis of module marks...</h2>\";\n display_data_from_array($html_data[\"statistical_analysis\"]);\n\n echo \"<h2>Grade Distribution of module marks...
</h2>\";\n display_data_from_array($html_data[\"grade_distribution\"]);\n\n echo \"</article>\";\n\n echo \"<span>---------------------------------------------</span>\";\n}",
"public function loadHTMLFile($fname, $options = NULL) {\n if ($fname === '') {\n throw new fDOMException('empty filename is not allowed', fDOMException::ParseError);\n }\n $this->xp = NULL;\n if (version_compare(PHP_VERSION, '5.4.0', '<')) {\n if ($options !== NULL) {\n throw new fDOMException('Passing options requires PHP 5.4.0+', fDOMException::LoadError);\n }\n $tmp = parent :: loadHTMLFile($fname);\n } else {\n $tmp = parent :: loadHTMLFile($fname, $options);\n }\n if (!$tmp || libxml_get_last_error()) {\n throw new fDOMException(\"loading html file '$fname' failed\", fDOMException::LoadError);\n }\n $this->registerNodeClasses();\n return TRUE;\n }",
"function file_get_html($url, $use_include_path = false, $context = null, $offset = -1, $maxLen = -1, $lowercase = true, $forceTagsClosed = true, $target_charset = DEFAULT_TARGET_CHARSET, $stripRN = true, $defaultBRText = DEFAULT_BR_TEXT, $defaultSpanText = DEFAULT_SPAN_TEXT) {\n\t\t\t// We DO force the tags to be terminated.\n\t\t\t\n\t\t\t$dom = new Engine_Domparser_Simplehtmldom(null, $lowercase, $forceTagsClosed, $target_charset, $stripRN, $defaultBRText, $defaultSpanText);\n\t\t\t// For sourceforge users: uncomment the next line and comment the retreive_url_contents line 2 lines down if it is not already done.\n\t\t\t$contents = $dom->file_get_contents($url);\n\n\t\t\t// Paperg - use our own mechanism for getting the contents as we want to control the timeout.\n\t\t\t//$contents = retrieve_url_contents($url);\n\t\t\t//if (empty($contents) || strlen($contents) > MAX_FILE_SIZE) {\n\t\t\t\tif (empty($contents)) {\n\t\t\t\t\treturn false;\n\t\t\t\t\t \n\t\t\t}\n\t\t\t\n\t\t\t// The second parameter can force the selectors to all be lowercase.\n\t\t\t$dom->load($contents, $lowercase, $stripRN);\n\t\t \n\t\t\treturn $dom;\n\t}",
"private function loadFromFile($filename) // {{{\n {\n $file_contents = file_get_contents($filename);\n $this->m_dom = new DOMDocument();\n $this->m_dom->formatOutput = true;\n $this->m_dom->loadXML($file_contents);\n $this->m_xpath = new DOMXpath($this->m_dom);\n }",
"public function fetchHTML($file) {\n\t\t\t// Fetches the content of the page\n\t\t$this->theParts['html']['content'] = $this->getURL($file);\n\t\tif ($this->theParts['html']['content']) {\n\t\t\t$addr = $this->extParseUrl($file);\n \t\t\t$path = ($addr['scheme']) ? $addr['scheme'].'://'.$addr['host'].(($addr['port'])?':'.$addr['port']:'').(($addr['filepath'])?$addr['filepath']:'/') : $addr['filepath'];\n\t\t\t$this->theParts['html']['path'] = $path;\n\t\t\treturn true;\n\t\t} else\t{\n\t\t\treturn false;\n\t\t}\n\t}",
"public function retrieveHtml()\n {\n $ch = curl_init();\n\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_URL, $this->url);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);\n\n $data = curl_exec($ch);\n curl_close($ch);\n\n $doc = new DOMDocument();\n /** @var DOMDocument $doc */\n @$doc->loadHTML($data);\n\n return $doc;\n }",
"private static function load($html){\n $dom = new \\DomDocument();\n $dom->preserveWhiteSpace = FALSE;\n $document = <<<EOD\n!html\nEOD;\n\n $document = strtr($document, [\"\\n\" => '', '!html' => $html]);\n @$dom->loadHTML($document);\n return $dom;\n }",
"public function getDom(string $filename): DOMDocument;",
"function loadHTML($viewName);",
"public static function file_get_html() {\n return call_user_func_array('file_get_html', func_get_args());\n }",
"public function get_html($url)\n {\n return HtmlDomParser::file_get_html($url);\n }",
"public function getHtml($html){\n \t$html = $this->buildHtmlPath($html);\n \treturn (file_exists($html)) ? file_get_contents($html) : false;\n }",
"private function load (): void {\n $file = $this->templatesPath . '/' . $this->file . '.html';\n\n if (file_exists($file)) {\n $content = file_get_contents($file);\n $this->html = $content;\n } else {\n throw new Exception('Template not found.');\n }\n }",
"public function readFileContent()\n {\n if (!$this->file) {\n return null;\n }\n $pathFull = Yii::getAlias('@frontend/web' . $this->file);\n if (!file_exists($pathFull) || !is_readable($pathFull)) {\n return null;\n }\n \n $pathFullHtml = \"$pathFull.html\";\n if (file_exists($pathFullHtml)) {\n return file_get_contents($pathFullHtml);\n }\n \n $content = $this->readZippedXML($pathFull);\n return $content;\n }",
"public function load(string $filename);",
"public function remote(string $filename): Document\n {\n return $this->load($filename);\n }",
"public function loadFromFile($filename);",
"public function file($name){\n if(!file_exists($name)) die(\"Template file is not reachable.\");\n $this->content = file_get_contents($name);\n }",
"public function validateHTMLFile($dom, $file)\n\t{\n\t\tlibxml_use_internal_errors(true);\n\t\t$dom->load($file);\n\t\tif($dom->validate())\n\t\t{\n\t\t\t$this->ca1Marks += 0.3125;\n\t\t\t$this->ca1Comments .= \";HTML validates, no errors.\";\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->ca1Comments .= \";HTML doesn't validate.\";\n\t\t}\n\n\t\t// Clear errors after we're done. We don't need to store this info.\n\t\tlibxml_clear_errors();\n\t}",
"function parse_html( $raw, $filename = '' ) {\n\n\tglobal $html_parsing_errors;\n\n\tif ( ! $raw ) {\n\t\treturn false;\n\t}\n\n\t// HT to:\n\t// - http://php.net/manual/en/domdocument.loadhtml.php\n\t// - http://php.net/manual/en/function.simplexml-import-dom.php\n\t// - http://stackoverflow.com/questions/3577641/how-do-you-parse-and-process-html-xml-in-php\n\t// - http://stackoverflow.com/questions/6635849/can-simplexml-be-used-to-rifle-through-html\n\t// - http://stackoverflow.com/a/2867601/1982136\n\n\t$document = new DOMDocument();\n\tob_start();\n\t$document->loadHTML( $raw ); $html_parse_line = __LINE__;\n\t$local_html_parsing_errors = ob_get_clean();\n\t$xml = simplexml_import_dom( $document );\n\n\t// Clean up HTML parsing errors\n\n\tif ( $local_html_parsing_errors ) {\n\n\t\t$local_html_parsing_errors = explode( '<br />', $local_html_parsing_errors );\n\t\t$local_html_parsing_errors = array_map( 'trim', $local_html_parsing_errors );\n\t\t$local_html_parsing_errors = array_map( 'strip_tags', $local_html_parsing_errors );\n\t\t$local_html_parsing_errors = array_map( function( $item ) use ( $html_parse_line, $filename) {\n\n\t\t\t$cleansed_line = str_replace(\n\t\t\t\tarray (\n\t\t\t\t\t'Warning: ',\n\t\t\t\t\t'DOMDocument::loadHTML(): ',\n\t\t\t\t\t' in Entity',\n\t\t\t\t\t' in ' . __FILE__ . ' on line ' . $html_parse_line,\n\t\t\t\t),\n\t\t\t\t'',\n\t\t\t\t$item\n\t\t\t);\n\n\t\t\tif ( $cleansed_line && $filename ) {\n\t\t\t\t$cleansed_line .= ' (' . basename( $filename ) . ')';\n\t\t\t}\n\n\t\t\treturn $cleansed_line;\n\n\t\t} , $local_html_parsing_errors );\n\n\t\t$local_html_parsing_errors = array_filter( $local_html_parsing_errors ); // Remove any blank lines\n\t\t$html_parsing_errors = array_merge( $html_parsing_errors, $local_html_parsing_errors );\n\n\t}\n\n\treturn $xml;\n\n}",
"private function getHtmlContent(string $name): string\n {\n $path = $this->articleBasePath . $name . '/index.html';\n\n try {\n $content = file_get_contents($path);\n } catch (Exception $e) {\n $content = false;\n }\n if (!$content) {\n throw new Exception($path . ' doesn\\'t exist or is empty. Did you build this article ?');\n }\n\n return $content;\n }"
] | [
"0.7069916",
"0.6577947",
"0.6475355",
"0.64353675",
"0.6314694",
"0.6287927",
"0.6285371",
"0.62158453",
"0.6128951",
"0.6099723",
"0.60817975",
"0.6024133",
"0.6024107",
"0.60043645",
"0.59540737",
"0.58962387",
"0.5887687",
"0.5875899",
"0.5866592",
"0.5779289",
"0.57471114",
"0.5744617",
"0.5720252",
"0.5642859",
"0.56077945",
"0.55963784",
"0.558779",
"0.5554913",
"0.5541092",
"0.55301344"
] | 0.81065255 | 0 |
Loads an HTML document from the specified filename, and returns the file as a DOMDocument. | function loadHTMLasDOM($filename)
{
$doc = new DOMDocument();
$doc->loadHTMLFile($filename);
return $doc;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getDom(string $filename): DOMDocument;",
"function loadHTML($filename)\n\t{\n\t\t$doc = new DOMDocument();\n\t\t$doc->loadHTMLFile($filename);\n\t\treturn $doc->saveHTML();\n\t}",
"function load($filename)\n \t{\n\n\t\t$this->doc = new DOMDocument;\n\n\t\t// We don't want to bother with white spaces\n\t\t$this->doc->preserveWhiteSpace = false;\n\n\t\t$this->doc->Load($filename);\n\n\t}",
"public static function load_file($filename)\n\t{\n\t\t$document = new DOMDocument('1.0', 'utf-8');\n\t\t$document->formatOutput = true;\n\t\t$document->preserveWhiteSpace = false;\n\n\t\t// Attempt to load the document\n\t\tif (!$document->load($filename))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\treturn self::load_element($document->documentElement);\n\t}",
"public function loadDocument()\r\n {\r\n if (!is_file($this->getFile())) {\r\n throw new Exception('\"' . $this->getFile() . '\" is not a file!');\r\n }\r\n $doc = new DOMDocument();\r\n try {\r\n $doc->load($this->getFile());\r\n } catch (Exception $e) {\r\n throw new Exception('Loading ' . $this->getFile() . ' was not possible. Is it corrupt, or no XML?');\r\n }\r\n return $doc;\r\n }",
"private function loadFromFile($filename) // {{{\n {\n $file_contents = file_get_contents($filename);\n $this->m_dom = new DOMDocument();\n $this->m_dom->formatOutput = true;\n $this->m_dom->loadXML($file_contents);\n $this->m_xpath = new DOMXpath($this->m_dom);\n }",
"protected function loadDomDocument()\n {\n $this->doc = new DomDocument();\n $this->doc->formatOutput = true;\n $this->doc->loadHtml(\n mb_convert_encoding($this->html, 'HTML-ENTITIES', 'UTF-8'),\n LIBXML_HTML_NODEFDTD\n );\n }",
"private static function load($html){\n $dom = new \\DomDocument();\n $dom->preserveWhiteSpace = FALSE;\n $document = <<<EOD\n!html\nEOD;\n\n $document = strtr($document, [\"\\n\" => '', '!html' => $html]);\n @$dom->loadHTML($document);\n return $dom;\n }",
"public function load(string $filename): Document\n {\n $xml = @simplexml_load_file($filename);\n\n return $this->resolveXmlObject($xml);\n }",
"public function loadHTMLFile($fname, $options = NULL) {\n if ($fname === '') {\n throw new fDOMException('empty filename is not allowed', fDOMException::ParseError);\n }\n $this->xp = NULL;\n if (version_compare(PHP_VERSION, '5.4.0', '<')) {\n if ($options !== NULL) {\n throw new fDOMException('Passing options requires PHP 5.4.0+', fDOMException::LoadError);\n }\n $tmp = parent :: loadHTMLFile($fname);\n } else {\n $tmp = parent :: loadHTMLFile($fname, $options);\n }\n if (!$tmp || libxml_get_last_error()) {\n throw new fDOMException(\"loading html file '$fname' failed\", fDOMException::LoadError);\n }\n $this->registerNodeClasses();\n return TRUE;\n }",
"private function load_xml_dom ( $filename ) {\n\t\t\t\n\t\t\t$xml_data = file_get_contents( $filename );\n\t\t\t\n\t\t\ttry {\n\t\t\t\t$dom = new SimpleXMLElement($xml_data);\n\t\t\t\treturn $dom;\n\t\t\t}\n\t\t\tcatch ( Exception $e ) {\n\t\t\t\t// log the reason we were unable to parse the XML file\n\t\t\t\tEventLog::log( _t('Unable to parse XML file. See detail for error message.', 'err', 'import', 'BlogML', array( $e->getMessage(), $xml_data ) ) );\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\t\n\t\t}",
"public function loadFile($file_path) {\n \n if (!$this->isFileReady($file_path)) {\n return;\n }\n \n $html = new \\DOMDocument('1.0', 'UTF-8');\n\t $sp = mb_convert_encoding(file_get_contents($file_path), 'HTML-ENTITIES', \"UTF-8\"); \n $html->loadHTML($sp);\n\t $html->encoding = 'UTF-8'; \n $this->parseDOM($html);\n }",
"private function getDOMDocument($URL, $localOrExternal)\n {\n // If the file is local, it skips the cURL request\n if($localOrExternal == 'local')\n {\n $DOMDocument = new DomDocument();\n @$DOMDocument->loadHTMLFile($URL);\n return $DOMDocument;\n }\n // If not, it automatically generates one\n elseif($localOrExternal == 'external')\n {\n $html = $this->cURL($URL);\n $DOMDocument = new DomDocument();\n @$DOMDocument->loadHTML($html);\n return $DOMDocument;\n }\n }",
"function getDOM(string &$content) {\n $dom = new DOMDocument();\n\n $dom->validateOnParse = false;\n\n /**\n * mb_convert_encoding() is needed as loadHTML itself\n * does not use UTF-8 and characters like ä are\n * returned as a wrong character.\n */\n $dom->loadHTML(mb_convert_encoding($content, 'HTML-ENTITIES', 'UTF-8'), LIBXML_BIGLINES | LIBXML_COMPACT | LIBXML_NOERROR );\n\n return $dom;\n}",
"function file_get_html($url, $use_include_path = false, $context=null, $offset = -1, $maxLen=-1, $lowercase = true, $forceTagsClosed=true, $target_charset = DEFAULT_TARGET_CHARSET, $stripRN=true, $defaultBRText=DEFAULT_BR_TEXT, $defaultSpanText=DEFAULT_SPAN_TEXT)\r\n {\r\n $dom = new simple_html_dom(null, $lowercase, $forceTagsClosed, $target_charset, $stripRN, $defaultBRText, $defaultSpanText);\r\n // For sourceforge users: uncomment the next line and comment the retreive_url_contents line 2 lines down if it is not already done.\r\n $contents = file_get_contents($url, $use_include_path, $context, $offset);\r\n // Paperg - use our own mechanism for getting the contents as we want to control the timeout.\r\n //$contents = retrieve_url_contents($url);\r\n if (empty($contents) || strlen($contents) > MAX_FILE_SIZE)\r\n {\r\n return false;\r\n }\r\n // The second parameter can force the selectors to all be lowercase.\r\n $dom->load($contents, $lowercase, $stripRN);\r\n return $dom;\r\n }",
"public function loadFile($filename) {\n\t\t\t$dom = @simplexml_load_file($filename);\n\t\t\tif ($dom instanceof \\SimpleXMLElement) {\n\t\t\t\t$this->node = $dom;\n\n\t\t\t\treturn $dom;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tthrow new XmlParseException($filename, @file_get_contents($filename));\n\t\t\t}\n\t\t}",
"function getDomDocumentFromHtml(&$html, $stripJavaScript = true)\n{\n //removing all scripts (we don't want them)\n if (!!$stripJavaScript) {\n $html = preg_replace('#<script[^>]*>.*<\\/script>#siU', '', trim($html));\n }\n\n /*\n * Fixing UTF8 encoding on existing full document\n * @props ricola\n */\n if (preg_match('/<head/iU', $html)) {\n $html = preg_replace('/(<head[^>]*>)/siU', '\\\\1<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />', $html);\n } else {\n /*\n * Fixing UTF8 on HTML fragment\n */\n $html = sprintf('<!DOCTYPE html><html><head><meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" /></head><body>%s</body></html>', $html);\n }\n\n $dom = new DomDocument();\n $dom->preserveWhitespace = false;\n @$dom->loadHTML($html);\n\n return $dom;\n}",
"protected static function getDomFromXmlFile($path=null)\n {\n if(!isset($path))\n {\n throw new Atom_Exception('Invalid path');\n }\n libxml_use_internal_errors(true);\n $document = DOMDocument::load($path, LIBXML_NOBLANKS);\n if (!$document) {\n $errors = libxml_get_errors();\n $msg='';\n foreach ($errors as $error) {\n $msg.=$error->message.\" | \";\n }\n libxml_clear_errors();\n throw new Atom_Exception($msg);\n }\n return $document;\n }",
"public function getDom()\r\n {\r\n if (null == $this->dom) {\r\n $this->dom = $this->loadDocument();\r\n }\r\n\r\n return $this->dom;\r\n }",
"public function remote(string $filename): Document\n {\n return $this->load($filename);\n }",
"function file_get_html ($url, $use_include_path = false, $context = null, $offset = -1, $maxLen = -1, $lowercase = true, $forceTagsClosed = true, $target_charset = DEFAULT_TARGET_CHARSET, $stripRN = true, $defaultBRText = DEFAULT_BR_TEXT, $defaultSpanText = DEFAULT_SPAN_TEXT)\r\n {\r\n // We DO force the tags to be terminated.\r\n $dom = new SimpleDom(null, $lowercase, $forceTagsClosed, $target_charset, $stripRN, $defaultBRText, $defaultSpanText);\r\n // For sourceforge users: uncomment the next line and comment the retreive_url_contents line 2 lines down if it is not already done.\r\n $contents = @file_get_contents($url, $use_include_path, $context, $offset);\r\n // Paperg - use our own mechanism for getting the contents as we want to control the timeout.\r\n // $contents = retrieve_url_contents($url);\r\n if (empty($contents) || strlen($contents) > MAX_FILE_SIZE) {\r\n return false;\r\n }\r\n // The second parameter can force the selectors to all be lowercase.\r\n $dom->load($contents, $lowercase, $stripRN);\r\n return $dom;\r\n }",
"function file_get_html($url, $use_include_path = false, $context = null, $offset = -1, $maxLen = -1, $lowercase = true, $forceTagsClosed = true, $target_charset = DEFAULT_TARGET_CHARSET, $stripRN = true, $defaultBRText = DEFAULT_BR_TEXT, $defaultSpanText = DEFAULT_SPAN_TEXT) {\n\t\t\t// We DO force the tags to be terminated.\n\t\t\t\n\t\t\t$dom = new Engine_Domparser_Simplehtmldom(null, $lowercase, $forceTagsClosed, $target_charset, $stripRN, $defaultBRText, $defaultSpanText);\n\t\t\t// For sourceforge users: uncomment the next line and comment the retreive_url_contents line 2 lines down if it is not already done.\n\t\t\t$contents = $dom->file_get_contents($url);\n\n\t\t\t// Paperg - use our own mechanism for getting the contents as we want to control the timeout.\n\t\t\t//$contents = retrieve_url_contents($url);\n\t\t\t//if (empty($contents) || strlen($contents) > MAX_FILE_SIZE) {\n\t\t\t\tif (empty($contents)) {\n\t\t\t\t\treturn false;\n\t\t\t\t\t \n\t\t\t}\n\t\t\t\n\t\t\t// The second parameter can force the selectors to all be lowercase.\n\t\t\t$dom->load($contents, $lowercase, $stripRN);\n\t\t \n\t\t\treturn $dom;\n\t}",
"public function retrieveHtml()\n {\n $ch = curl_init();\n\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_URL, $this->url);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);\n\n $data = curl_exec($ch);\n curl_close($ch);\n\n $doc = new DOMDocument();\n /** @var DOMDocument $doc */\n @$doc->loadHTML($data);\n\n return $doc;\n }",
"public function getContentFrom($url, $returnDomDocument = false)\n {\n if (!$returnDomDocument) {\n return file_get_contents($url);\n }\n\n $content = file_get_contents($url);\n if (empty($content)) {\n return '';\n }\n\n $doc = new \\DOMDocument();\n libxml_use_internal_errors(true);\n $doc->loadHTML($content);\n libxml_use_internal_errors(false);\n\n return $doc;\n }",
"function domxml_open_file($filename, $mode = false, &$error = array())\n{\n}",
"public function load($fname, $options = LIBXML_NONET) {\n if ($fname === '') {\n throw new fDOMException('empty filename is not allowed', fDOMException::ParseError);\n }\n $this->xp = NULL;\n $tmp = parent :: load($fname, $options);\n if (!$tmp || libxml_get_last_error()) {\n throw new fDOMException(\"loading file '$fname' failed.\", fDOMException::LoadError);\n }\n $this->registerNodeClasses();\n return TRUE;\n }",
"public function load_dom_xml_file($Str_FileName, $Str_Encode='utf-8', $Str_Version='1.0')\n\t{\n\t\t//Check for the XML file extension.\n\t\t//$Bol_IsXmlFile = false;\n\n\t\t//Make sure XML file exists.\n\t\tif (!file_exists($Str_FileName))\n\t\t{\n\t\t\tglobal $CMD;\n\t\t\t$CMD->handle_exception(\"Could not find XML file: $Str_FileName! Check name and location of file.\", 'MW:101');\n\t\t\treturn false;\n\t\t}\n\n\t\t//Create and validate new dom object.\n\t\t$Obj_DOMXMLFile = new DOMDocument($Str_Version, $Str_Encode);\n\t\t$Obj_DOMXMLFile->validateOnParse = true;\n\n\t\t//If the file is an XML document load it directly from file.\n\t\tif (pathinfo($Str_FileName, PATHINFO_EXTENSION) == 'xml')\n\t\t{\n\t\t\tif ($Obj_DOMXMLFile->load($Str_FileName) === false)\n\t\t\t{\n\t\t\t\tglobal $CMD;\n\t\t\t\t$CMD->handle_exception(\"Error reading XML file: $Str_FileName! Check file uses valid XML.\", 'MW:101');\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\t//Otherwise get the file contents and load xml from a string.\n\t\telse\n\t\t{\n\t\t\tif ($Obj_DOMXMLFile->loadXML($this->get_file_as_string($Str_FileName)) === false)\n\t\t\t{\n\t\t\t\tglobal $CMD;\n\t\t\t\t$CMD->handle_exception(\"Error reading XML file: $Str_FileName! Check file uses valid XML.\", 'MW:101');\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\n\t\treturn $Obj_DOMXMLFile;\n\t}",
"protected static function loadXML($xml)\n\t{\n\t\t// Activate small nodes allocation and relax LibXML's hardcoded limits if applicable\n\t\t$flags = (LIBXML_VERSION >= 20700) ? LIBXML_COMPACT | LIBXML_PARSEHUGE : 0;\n\n\t\t$dom = new DOMDocument;\n\t\t$dom->loadXML($xml, $flags);\n\n\t\treturn $dom;\n\t}",
"public function testHtmlDoc()\n {\n $filename = DATA_PATH.'/doc.html';\n $file = new TextFile($filename);\n $file->load();\n\n $doc = new HtmlDoc();\n $doc->loadFile($file);\n $doc2 = HtmlDoc::createFromFilePath($filename);\n $this->assertInstanceOf('\\Duality\\Structure\\HtmlDoc', $doc2);\n\n $doc->setTitle('Duality dummy doc title');\n $result = (string) $doc;\n $expected = \"<!DOCTYPE html>\\n<html><head><title>Duality dummy doc title</title></head><body></body></html>\\n\";\n $this->assertEquals($expected, $result);\n \n $doc = HtmlDoc::createFromFilePath($filename);\n $doc->setAttribute('body', 'id', 'dummy');\n $result = (string) $doc;\n $expected = \"<!DOCTYPE html>\\n<html><head><title></title></head><body id=\\\"dummy\\\"></body></html>\\n\";\n $this->assertEquals($expected, $result);\n\n $doc = HtmlDoc::createFromFilePath($filename);\n $expected = \"<!DOCTYPE html>\\n<html><head><title></title></head><body><p>Dummy content</p></body></html>\\n\";\n $doc->appendTo('body', '<p>Dummy content</p>');\n $result = (string) $doc;\n $this->assertEquals($expected, $result);\n }",
"public function load($src, $options=null)\r\n\t{\r\n\t\tif(!is_string($src))\r\n\t\t\tthrow new \\Exception('Input must be a string');\r\n\t\t\r\n\t\t$result = \\DOMDocument::load($src, $options);\r\n\t\t$this->src_file = $src;\r\n\t\t\r\n\t\t$this->onEvaluateNodes();\r\n\t\t$this->onLoaded();\r\n\t\t\r\n\t\treturn $result;\r\n\t}"
] | [
"0.8061026",
"0.7916849",
"0.72899157",
"0.7003046",
"0.6830563",
"0.67799884",
"0.67466885",
"0.6685162",
"0.6642484",
"0.657613",
"0.64601004",
"0.6223914",
"0.61692613",
"0.6050638",
"0.6034647",
"0.5989435",
"0.5915745",
"0.59135175",
"0.5910998",
"0.5901092",
"0.5884469",
"0.5872191",
"0.58612543",
"0.5828668",
"0.5759688",
"0.565197",
"0.5639197",
"0.55786973",
"0.5578169",
"0.55698514"
] | 0.8459932 | 0 |
Doctrine defines its primary database abstraction information in what it calls "Platform" classes (e.g. Doctrine\DBAL\Platforms\AbstractPlatform). Each database Doctrine supports implements a Platform file (e.g. OraclePlatform or MySqlPlatform). \Doctrine\DBAL\Platforms\OraclePlatform maps "DATE" fields to Doctrine's own "datetime" type, which returns it as \DateTime. The problem is that internally, Oracle DOES store time data as part of its "DATE" field (even if it's not visible in its default representation DDMONRR == "30JUL13"). Thus the Doctrine core devs thought it best to map the database tyep "DATE" to Doctrine's "datetime" type. But if in your case you will never require time data with your DATE fields this will change Oracle's "DATE" fields to be mapped to Doctrine's "date" mapping type. This is the same behavior as almost every other DBAL driver (except SQLServer, which does its own crazy stuff). | public function postConnect(ConnectionEventArgs $args)
{
$args
->getConnection()
->getDatabasePlatform()
->registerDoctrineTypeMapping('date', 'date');
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function type()\n {\n return Database::TYPE_DATE;\n }",
"public function date()\n\t{\n\t\treturn $this->schema->createColumnSchemaBuilder(Schema::TYPE_DATE);\n\t}",
"public function testConvertToDatabaseValue()\n {\n $value = new \\DateTime('01.01.2014');\n $returnValue = $this->sqlSrvDate->convertToDatabaseValue($value, $this->platform);\n $this->assertEquals('01.01.2014', $returnValue);\n }",
"function testDateDataType() {\n $data = array(\n 'id' => 1,\n 'datefield' => date('Y-m-d'),\n );\n $this->insertValues($data);\n $this->selectAndCheck($data);\n }",
"public function testCastCassandraTimestampToDatetime()\n {\n $model = TestableType::where('id', $this->uuid)->first();\n\n $this->assertTrue($model->hasCast('datetime', 'datetime'));\n $this->assertInstanceOf(\\DateTime::class, $model->datetime);\n }",
"public function testCastCassandraDateToDatetime()\n {\n $model = TestableType::where('id', $this->uuid)->first();\n\n $this->assertTrue($model->hasCast('date', 'date'));\n $this->assertInstanceOf(\\DateTime::class, $model->date);\n $this->assertEquals('00:00:00', $model->date->format('H:i:s'));\n }",
"public function testCorrectSqlDeclaration()\n {\n $this->assertEquals('Date', $this->sqlSrvDate->getSqlDeclaration(array(), $this->platform));\n }",
"public function getDatabasePlatform() : AbstractPlatform;",
"protected function getDoctrineDbalPlatform(): AbstractPlatform\n\t{\n\t\treturn $this->db->getDbalDatabasePlatform();\n\t}",
"public function dateTime($precision = null)\n\t{\n\t\treturn $this->schema->createColumnSchemaBuilder(Schema::TYPE_DATETIME, $precision);\n\t}",
"public function getBaseType()\n {\n return 'datetime';\n }",
"function testTimestampDataType() {\n $data = array(\n 'id' => 1,\n 'timestampfield' => date('Y-m-d H:i:s'),\n );\n $this->insertValues($data);\n $this->selectAndCheck($data);\n }",
"public function getCreatedAt(): \\DateTimeInterface;",
"protected function getDateObject(): DateTimeInterface\n {\n return new DateTime();\n }",
"function toMysqlDate($date)\n{\n if ($date == null) return null;\n $val = toDateTime($date);\n return $val->format(DATE_MYSQL);\n}",
"public static function getDateFromDB($datetime) {\n\t\t$dt = \\DateTime::createFromFormat(self::FM_DB_DATE, $datetime);\n\t\treturn $dt;\n\t}",
"public function toDateTime() {}",
"public function toDateTime() {}",
"public function test_table_columns_timestamp()\n\t{\n\t\t$db = Database::factory();\n\t\t$db->execute_command(\n\t\t\t'CREATE TABLE '.$db->quote_table($this->_table).' (field timestamp)'\n\t\t);\n\n\t\t$expected = array_merge($this->_information_schema_defaults, array(\n\t\t\t'column_name' => 'field',\n\t\t\t'ordinal_position' => '1',\n\t\t\t'is_nullable' => 'YES',\n\t\t\t'column_default' => 'CURRENT_TIMESTAMP',\n\t\t\t'is_nullable' => 'NO',\n\t\t\t'data_type' => 'timestamp',\n\t\t\t'column_type' => 'timestamp',\n\t\t));\n\n\t\tif (version_compare($db->execute_query('SELECT VERSION()')->get(), '5.1', '>'))\n\t\t{\n\t\t\t$expected['extra'] = 'on update CURRENT_TIMESTAMP';\n\t\t}\n\n\t\t$result = $db->table_columns($this->_table);\n\n\t\t$this->assertSame($expected, $result['field']);\n\t}",
"public function getMysqlDtTm($p_dt=NULL){ return self::getMysqlFormatedDateTime($p_dt); }",
"public function testIfCorrectInstanceisReturned()\n {\n $this->assertInstanceOf('ZF2Doctrine2SqlsrvTypes\\SqlsrvDate', $this->sqlSrvDate);\n }",
"public function datetime(): DateTimeInterface;",
"public function getDateTime(): DateTime;",
"public function getDateCreate(): DateTime\n {\n }",
"public function testReturnsTheStringDate()\n {\n $instance = new FieldType\\Date();\n $result = $instance->toNative();\n\n static::assertEquals('date', $result);\n }",
"private function convertTypeOracleToTypePhp()\n {\n foreach($this->arra_simple_attribut as $key=>$arra_data)\n {\n switch($arra_data['type'])\n {\n case \"VARCHAR2\":\n $arra_data['type_php']=\"string\";\n break;\n case \"NUMBER\":\n $arra_data['type_php']=\"float\";\n break;\n case \"DATE\":\n $arra_data['type_php']=\"untypeddate\";\n break; \n default:\n $arra_data['type_php']=strtolower($arra_data['type']);\n break;\n }\n $this->arra_simple_attribut[$key]=$arra_data;\n }\n }",
"public function testDbDateFormat()\n {\n $client = new Client();\n $this->assertNull($client->getUpdatedAt());\n $client->{Client::FIELD_UPDATED_AT} = '2001-02-03 04:05:06';\n $this->assertNotNull($client->getUpdatedAt());\n }",
"public function getMappedDatabaseTypes(AbstractPlatform $platform)\n {\n return [];\n }",
"static function sqlDateTime() {\r\n return date(\"Y-m-d H:i:s\");\r\n }",
"protected function getPlatform()\n {\n return new OraclePlatform();\n }"
] | [
"0.6339099",
"0.5726233",
"0.5683289",
"0.56045204",
"0.5517206",
"0.54501665",
"0.5407814",
"0.53933424",
"0.53134906",
"0.52219975",
"0.5215446",
"0.5193048",
"0.5192974",
"0.5165148",
"0.5157361",
"0.5139865",
"0.51246804",
"0.51246804",
"0.5123133",
"0.51164114",
"0.5110487",
"0.5098052",
"0.50731176",
"0.50646156",
"0.50644284",
"0.5054087",
"0.5033703",
"0.5024285",
"0.50232846",
"0.50145924"
] | 0.5875529 | 1 |
/ stories related with deleted project | private function _deleteRelativeStoriesForProject($projectId) {
$q = Doctrine_Query :: create()
->from('Story')
->where('deleted = ?', Story::FLAG_ACTIVE)
->andWhere('project_id = ?', $projectId);
$stories = $q->execute();
$storyDao = new StoryDao();
foreach ($stories as $story) {
$storyDao->deleteStory($story->getId(), date("Y-m-d H:i:s"));
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function delete()\n {\n $stories = Story::orderBy('title')->get();\n return view('projects/quickreads/stories/delete', compact(['stories'])); \n }",
"function project_delete($id) {\n entity_delete('project', $id);\n}",
"function deleteProjectRelatedTableElement($project)\n{\n if(($project != null) && ($project != ''))\n {\n // - scrum_project_member\n deleteTableElement('scrum_project_member', 'project_title = \"'. $project .'\"');\n\n // - scrum_sprint\n deleteTableElement('scrum_sprint', 'project = \"'. $project .'\"');\n\n // get backlog title for passing project.\n $backlogs = getTableElements('scrum_backlog', ['title'], 'project = \"'. $project .'\"');\n // delete tasks for each selected backlog.\n foreach($backlogs as $backlog)\n {\n // - scrum_task - based on backlog title.\n deleteTableElement('scrum_task', 'backlog = \"'. $backlog[0] .'\"');\n }\n\n // - scrum_backlog\n deleteTableElement('scrum_backlog', 'project = \"'. $project .'\"');\n }\n}",
"public function delete($projectId){\n $user = Session::get('user'); \n\n $isOwner = Project::userIsOwner($user['id'], $projectId);\n\n // verify if user on session is owner of project\n if(empty($isOwner)) {\n\n return Redirect::to(URL::action('DashboardController@index')); \n\n }else{\n\n // get project iterations\n $iterations = Project::getProjectIterations($user['id'], $projectId);\n\n Project::deleteCategoriesActivity($projectId); \n\n if(!empty($iterations)){\n\n foreach($iterations as $iteration){\n\n // delete project activities\n $activities = Project::getIterationActivities($iteration['id']); \n \n if(!empty($activities)){\n\n foreach($activities as $activity){\n Activity::deleteActivityComment($activity['activity_id']);\n Activity::deleteProjectActivity($activity['activity_id'], $iteration['id']);\n Activity::deleteActivity($activity['activity_id']); \n \n }\n\n } \n\n }\n }\n\n // get project artefacts\n $projectArtefacts = (array) Project::getProjectArtefacts($projectId, 'ALL'); \n\n if(!empty($projectArtefacts)){\n\n foreach( $projectArtefacts as $index => $projectArtefact){\n\n switch($projectArtefact['friendly_url']) {\n\n case Config::get('constant.artefact.heuristic_evaluation'):\n\n $artefactList = HeuristicEvaluation::getEvaluationDataByProject($projectId); \n\n if(!empty($artefactList)){\n\n // delete artefact elements\n foreach($artefactList as $artefactValue){\n\n if(!empty($artefactValue['elements'])){\n\n foreach($artefactValue['elements'] as $element){\n\n HeuristicEvaluation::deleteElement($element['id']);\n\n } \n }\n }\n\n // delete artefact info\n foreach($artefactList as $artefact){\n\n HeuristicEvaluation::_delete($artefact['id']);\n\n } \n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n }else{\n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n } \n\n break;\n\n case Config::get('constant.artefact.storm_ideas'):\n\n $artefactList = StormIdeas::enumerate($projectId); \n \n if(!empty($artefactList)){\n\n // delete artefact \n foreach($artefactList as $artefactValue){\n\n if(!empty($artefactValue)){\n\n StormIdeas::deleteStormIdeas($artefactValue['id']);\n\n } \n \n }\n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n }else{\n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n } \n\n break; \n\n case Config::get('constant.artefact.probe'):\n\n $artefactList = Probe::getProbeElementsByProject($projectId); \n\n if(!empty($artefactList)){\n\n // delete artefact elements\n foreach($artefactList as $artefactValue){\n\n if(!empty($artefactValue['elements'])){\n\n foreach($artefactValue['elements'] as $element){\n\n Probe::deleteQuestion($element['id']);\n\n } \n }\n }\n\n // delete artefact info\n foreach($artefactList as $artefact){\n\n Probe::_delete($artefact['id']);\n\n } \n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n }else{\n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n } \n\n break;\n\n case Config::get('constant.artefact.style_guide'):\n\n $artefactList = StyleGuide::getStyleGuideByProject($projectId); \n \n if(!empty($artefactList)){\n\n // delete artefact elements\n foreach($artefactList as $artefactValue){\n\n if(!empty($artefactValue['colors'])){\n\n foreach($artefactValue['colors'] as $color){\n\n StyleGuide::deleteColor($color['id']);\n\n } \n }\n\n if(!empty($artefactValue['fonts'])){\n\n foreach($artefactValue['fonts'] as $font){\n\n StyleGuide::deleteFont($font['id']);\n\n } \n }\n } \n\n // delete artefact info\n foreach($artefactList as $artefact){\n\n StyleGuide::deleteStyleGuide($artefact['id']);\n\n } \n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n }else{\n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n } \n\n break;\n\n case Config::get('constant.artefact.existing_system'):\n\n $artefactList = ExistingSystem::getExistingSystemDataByProject($projectId); \n\n if(!empty($artefactList)){\n\n // delete artefact elements\n foreach($artefactList as $artefactValue){\n\n if(!empty($artefactValue['elements'])){\n\n foreach($artefactValue['elements'] as $element){\n\n ExistingSystem::deleteElement($element['id']);\n\n } \n }\n }\n\n // delete artefact info\n foreach($artefactList as $artefact){\n\n ExistingSystem::_delete($artefact['id']);\n\n } \n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n }else{\n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n } \n\n break;\n\n case Config::get('constant.artefact.checklist'):\n\n $artefactList = Checklist::getChecklistsByProject($projectId);\n\n if(!empty($artefactList)){\n\n // delete artefact elements\n foreach($artefactList as $artefactValue){\n\n if(!empty($artefactValue['elements'])){\n\n foreach($artefactValue['elements'] as $element){\n\n Checklist::deleteChecklitsElement($element['id']);\n\n }\n } \n }\n\n // delete artefact info\n foreach($artefactList as $artefact){\n\n Checklist::deleteChecklist($artefact['id']);\n\n } \n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n }else{\n\n //delete relation artefact - project\n Artefact::deleteProjectArtefact($projectArtefact['id'], $projectId);\n\n $deletedData = TRUE; \n\n } \n\n break;\n } \n\n\n // delete iterations info\n if(!empty($iterations)){\n foreach($iterations as $iteration){\n\n // delete user invitations\n Iteration::deleteUsers($iteration['id']); \n Iteration::deleteIterationInvitations($iteration['id']);\n Iteration::_delete($iteration['id']); \n\n }\n }\n\n\n // delete project info \n Project::_delete($projectId); \n \n \n }\n\n }\n\n }\n\n Session::flash('success_message', 'Se ha eliminado el proyecto correctamente'); \n\n return Redirect::to(URL::action('DashboardController@index'));\n }",
"public function testGetUndeletedProjects(): void\n {\n $response = static::createAuthenticatedClient([\n 'email' => TestFixtures::ADMIN['email']\n ])->request('GET', '/projects', ['query' => [\n 'exists[deletedAt]' => 0\n ]]);\n\n self::assertResponseIsSuccessful();\n self::assertJsonContains([\n '@context' => '/contexts/Project',\n '@id' => '/projects',\n '@type' => 'hydra:Collection',\n 'hydra:totalItems' => 2,\n ]);\n\n // the deleted and the locked project are NOT returned\n $collection = $response->toArray();\n $this->assertCount(2, $collection['hydra:member']);\n\n $this->assertSame(TestFixtures::IDEA['id'], $collection['hydra:member'][0]['id']);\n $this->assertSame(TestFixtures::PROJECT['id'], $collection['hydra:member'][1]['id']);\n }",
"public function getProjectDeleteWidgetViewTemplate();",
"public function deleted(Project $project)\n {\n //\n }",
"public function deleteMyProjectAction()\n {\n \t$result = Extended\\project::deleteProject( $this->getRequest()->getParam(\"id\"), Auth_UserAdapter::getIdentity()->getId() );\n \tif($result)\n \t\techo Zend_Json::encode($result);\n \tdie;\n }",
"public function testSpacesProjectsDelete()\n {\n }",
"public function unpublishedAction()\n{\n $all = $this->content->query()\n ->where('published IS NULL')\n ->andWhere('deleted is NULL')\n ->execute();\n \n $this->theme->setTitle(\"Opublicerat innehåll\");\n $this->views->add('content/list-all', [\n 'content' => $all,\n 'title' => \"Opublicerat innehåll\",\n ], 'main');\n\n}",
"public function onEntityDelete(EntityEvent $event) {\n // $this->projectRepository->delete($event->getEntity()->id());\n }",
"function delete_ALL(Web $w) {\r\n $p = $w->pathMatch('id');\r\n // check to see if the id has been found\r\n if (empty($p['id'])) {\r\n // if no id found use the 'error' function to redirect the use to a safe page and display a message.\r\n $w->error('No id found for issue','accessability');\r\n }\r\n // use the id to retrieve the issue\r\n $issue = $w->accessability->getissueForId($p['id']);\r\n // check to see if the issue was found\r\n if (empty($issue)) {\r\n // no issue found so let the user know\r\n $w->error('No issue found for id','accessability');\r\n }\r\n // delete the issue\r\n $issue->delete();\r\n // redirect the user back to the issue list with a message\r\n $w->msg('issue deleted','accessability');\r\n}",
"public function Delete(){\n $revised_array = array();\n foreach($this->projects as $project=>$data){\n if($data['path']!=$this->path){\n $revised_array[] = array(\"name\"=>$data['name'],\"path\"=>$data['path']);\n }\n }\n // Save array back to JSON\n saveJSON('projects.php',$revised_array);\n // Response\n echo formatJSEND(\"success\",null);\n }",
"public function deleteprojects(){\n \n if (func_num_args() > 0):\n $projectid = func_get_arg(0);\n try {\n \n $sql = 'DELETE projects, projectlikes,projectcomments,projectcommentlikes\n FROM projects\n LEFT JOIN projectlikes ON projects.project_id = projectlikes.project_id\n LEFT JOIN projectcomments ON projects.project_id = projectcomments.project_id\n LEFT JOIN projectcommentlikes ON projects.project_id = projectcommentlikes.project_id\nWHERE projects.project_id = '.$projectid.'';\n $responseid = $this->getAdapter()->query($sql);\n } catch (Exception $e) {\n throw new Exception($e);\n }\n return $projectid;\n else:\n throw new Exception('Argument Not Passed');\n endif; \n\n \n}",
"function deleteProjectNow($project_id)\r\n{\r\n\t// Get project title (app_title)\r\n\t$q = db_query(\"select app_title from redcap_projects where project_id = $project_id\");\r\n\t$app_title = strip_tags(label_decode(db_result($q, 0)));\r\n\t// Get list of users with access to project\r\n\t$userList = str_replace(\"'\", \"\", pre_query(\"select username from redcap_user_rights where project_id = $project_id and username != ''\"));\r\n\t\r\n\t// For uploaded edoc files, set delete_date so they'll later be auto-deleted from the server\r\n\tdb_query(\"update redcap_edocs_metadata set delete_date = '\".date('Y-m-d H:i:s').\"' where project_id = $project_id and delete_date is null\");\r\n\t// Delete all project data and related info from ALL tables (most will be done by foreign keys automatically)\r\n\tdb_query(\"delete from redcap_projects where project_id = $project_id\");\r\n\t// Do other deletions manually because some tables don't have foreign key cascade deletion set\r\n\tdb_query(\"delete from redcap_data where project_id = $project_id\");\r\n\t// Don't actually delete these because they are logs, but simply remove any data-related info\r\n\tdb_query(\"update redcap_log_view set event_id = null, record = null, form_name = null, miscellaneous = null where project_id = $project_id\");\r\n\tdb_query(\"update redcap_log_event set event_id = null, sql_log = null, data_values = null, pk = null where project_id = $project_id\r\n\t\t\t\t and description != 'Delete project'\");\r\n\t\r\n\t// Log the permanent deletion of the project\r\n\t$loggingDescription = \"Permanently delete project\";\r\n\t$loggingDataValues = \"project_id = $project_id,\\napp_title = \".prep($app_title).\",\\nusernames: $userList\";\r\n\t$loggingTable\t\t= \"redcap_projects\";\r\n\t$loggingEventType\t= \"MANAGE\";\r\n\t$loggingPage \t\t= (defined(\"CRON\")) ? \"cron.php\" : PAGE;\r\n\t$loggingUser \t\t= (defined(\"CRON\")) ? \"SYSTEM\" : USERID;\r\n\tdb_query(\"insert into redcap_log_event (project_id, ts, user, page, event, object_type, pk, data_values, description) values \r\n\t\t\t\t($project_id, '\".date(\"YmdHis\").\"', '$loggingUser', '$loggingPage', '$loggingEventType', '$loggingTable', \r\n\t\t\t\t'$project_id', '$loggingDataValues', '$loggingDescription')\");\r\n}",
"public function discardedAction()\n{\n $all = $this->content->query()\n ->where('deleted is NOT NULL')\n ->execute();\n \n $this->theme->setTitle(\"Papperskorgen\");\n $this->views->add('content/list-deleted', [\n 'users' => $all,\n 'title' => \"Papperskorgen\",\n ], 'main');\n\n}",
"function unpublishproject()\r\n\t{\r\n\t\t// Get some variables from the request\t\r\n\t\t$cid\t= JRequest::getVar( 'cid', array(), 'post', 'array' );\r\n\t\t$option = JRequest::getVar('option', '', '', 'string');\r\n\t\t$project = JRequest::getVar('project', '', '', 'string');\r\n\t\t$category = JRequest::getVar('category', '', '', 'string');\r\n\t\t$owner = JRequest::getVar('owner', '', '', 'string');\r\n\t\t$name = JRequest::getVar('name', '', '', 'string');\r\n\r\n\t\t// And perform the action thru the model method setState\r\n\t\t$model = & $this->getModel('ListProject', 'JPackageDirModel');\r\n\t\tif ($model->setState($cid, 0)) {\r\n\t\t\t$msg = sprintf( JText::_( 'Project Un-Published' ), count( $cid ) );\r\n\t\t} else {\r\n\t\t\t$msg = $model->getError();\r\n\t\t}\r\n\r\n\t\t// Jump to proper page\r\n\t\t$this->setRedirect( \"index.php?option=$option&task=projects&project=$project&name=$name&owner=$owner&category=$category\" , $msg );\r\n\t}",
"public function removeViewedStoryAction()\n {\n \t$request = $this->getRequest();\n\t\techo \"Attempting to remove story \\n \";\n\t\t\n \tif ($request->isPost()) {\n\t\t\t\n \t\t$story_id = (int)$request->getParam('story_id');\n\t\t\t\n \t\tif ($story_id > 0) {\n\t\t\t\t\t\techo \"Attempting to remove story (step 2) \\n \";\n\t\t\t\t\t\t$fb_user_id = $this->facebook->getUser();\n\t\t\t\n\t\t\t\t\t\tif ($fb_user_id) {\n\t\t\t\t\t\t\techo \"Attempting to remove story (step 3) \\n \";\n\t\t\t\t\t\t\t$user_model = $this->__getModel('User');\n\t\t\t\t\t\t\t$users = $user_model->getUsers(array('fields' => array('id'),'fb_user_id' => $fb_user_id));\n\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (isset($users[0])) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t$user = $users[0]->toArray();\n\t\t\t\t\t\t\t\techo \"Attempting to remove story (step 4)\".$user['id'].\" \\n \";\n\t\t\t\t\t\t\t\t$log_model = $this->__getModel('Log');\n\t\t\t\t\t\t\t\t$sql = $log_model->removeStoryFromMap($user['id'], $story_id);\n\t\t\t\t\t\t\t\techo $sql.\"\\n\";\n\t\t\t\t\t\t\t\techo \"removing \".$story_id.\" from user id\".$user['id'];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\t\t//else {\n\t\t\t\t\t\t\t\t//die();\n\t\t\t\t\t\t\t//}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t//die();\n\t\t\t\t\t\t}\n\t\t\t\t\t\n \t\t}\n \t}\n \t\n \tdie();\n }",
"public function deletePasses()\n {\n $project = factory(Project::class)->create();\n\n $response = $this->withHeaders([\n 'X-Header' => 'Value',\n ])->json(\n 'POST',\n '/api/project/delete',\n ['id' => $project->id]\n );\n\n $deletedProject = Project::find($project->id);\n\n $this->assertEquals(null, $deletedProject);\n $response->assertStatus(200);\n }",
"public function stories(){\n \treturn $this->hasMany('App\\Story');\n }",
"function delete()\r\n\t\t{ \r\n\t\t $projectID = $this->input->post('id');\r\n\t\t if(isset($projectID) && !empty($projectID))\r\n\t\t {\r\n\t\t \t$projectID=$this->data['projectID']=$this->ProjectModel->get(array('projectID'=>$projectID));\r\n\t\t \t$delete=$this->data['delete']=$this->ProjectModel->delete(array('projectID'=>$this->input->post('id')));\r\n\t\t $projectDelete=$projectID[0]->projectID;\r\n\t\t $this->projectGetValue($projectDelete);\r\n\t\t }\r\n\t\t}",
"function delete_project() {\n $res = false;\n if ($this->request_id > 0) {\n $ok = true;\n\n // All in a single tranny..\n $qry = new PgQuery(\"BEGIN\");\n $qry->Exec(\"qa_project::delete_project\");\n\n // Remove all the subordinate request records for each project step..\n $request_table_suffixes = array(\n \"action\", \"allocated\", \"attachment\", \"history\", \"interested\",\n \"note\", \"quote\", \"status\", \"tag\", \"timesheet\", \"request\"\n );\n foreach ($this->qa_process->qa_steps as $qa_step_id => $qastep) {\n // Delete all subordinate records..\n foreach($request_table_suffixes as $suffix) {\n $qry = new PgQuery(\"DELETE FROM request_$suffix WHERE request_id=$qastep->request_id\");\n $ok = $qry->Exec(\"qa_project::delete_project\");\n if ($ok === false) {\n break;\n }\n }\n }\n\n if ($ok) {\n $qry = new PgQuery(\"DELETE FROM qa_project_approval WHERE project_id=$this->request_id\");\n $ok = $qry->Exec(\"qa_project::delete_project\");\n }\n if ($ok) {\n $qry = new PgQuery(\"DELETE FROM qa_project_step_approval WHERE project_id=$this->request_id\");\n $ok = $qry->Exec(\"qa_project::delete_project\");\n }\n if ($ok) {\n $qry = new PgQuery(\"DELETE FROM qa_project_step WHERE project_id=$this->request_id\");\n $ok = $qry->Exec(\"qa_project::delete_project\");\n }\n if ($ok) {\n $qry = new PgQuery(\"DELETE FROM request_project WHERE request_id=$this->request_id\");\n $ok = $qry->Exec(\"qa_project::delete_project\");\n }\n\n // Delete step request recs..\n foreach ($this->qa_process->qa_steps as $qa_step_id => $qastep) {\n if ($ok) {\n $qry = new PgQuery(\"DELETE FROM request WHERE request_id=$qastep->request_id\");\n $ok = $qry->Exec(\"qa_project::delete_project\");\n }\n }\n\n // Now delete the WRMS project master records..\n foreach($request_table_suffixes as $suffix) {\n if ($ok) {\n $qry = new PgQuery(\"DELETE FROM request_$suffix WHERE request_id=$this->request_id\");\n $ok = $qry->Exec(\"qa_project::delete_project\");\n }\n }\n // Then delete the main record..\n if ($ok) {\n $qry = new PgQuery(\"DELETE FROM request WHERE request_id=$this->request_id\");\n $ok = $qry->Exec(\"qa_project::delete_project\");\n }\n\n // Commit or rollback..\n $qry = new PgQuery(($ok ? \"COMMIT;\" : \"ROLLBACK;\"));\n $res = $qry->Exec(\"qa_project::delete_project\");\n }\n return $res;\n }",
"public function delete($pid){\n $data = DB::table('projects')\n ->leftJoin('owners', 'owners.id', '=' ,'projects.owner_id')\n ->where('projects.id',$pid);\n DB::table('owners')\n ->join('projects', 'owners.id', '=' ,'projects.owner_id')\n ->where('projects.id',$pid)->delete();\n $data->delete();\n return redirect('projects');\n }",
"public function perma_del($project_id, $id)\n {\n if (! Gate::allows('project_discussion_delete')) {\n return abort(401);\n }\n if ( isDemo() ) {\n return prepareBlockUserMessage( 'info', 'crud_disabled' );\n }\n $mile_stone = ProjectDiscussion::onlyTrashed()->findOrFail($id);\n $project_id = $mile_stone->project_id;\n $mile_stone->forceDelete();\n\n flashMessage( 'success', 'delete');\n\n return back();\n }",
"public function delete(){\n $tid = $this->id;\n\n // delete view counter\n Counter::where(\"[entityId] = ? AND [entityTypeId] = ?\",[$tid,Topic::ENTITY_TYPE])->delete();\n Rating::where(\"[entityId] = ? AND [entityType] = ?\",[$tid,Topic::ENTITY_TYPE])->delete();\n RatingStatistic::where(\"[entityId] = ? AND [entityType] = ?\",[$tid,Topic::ENTITY_TYPE])->delete();\n Comment::where(\"[topicId] = ?\", $tid)->delete();\n\n parent::delete();\n }",
"function delete_publishthis_publishing_actions() {\r\n\r\n $action = arg(2);\r\n $action_id = arg(3);\r\n\r\n if (!empty($action_id) && $action == 'delete') {\r\n\r\n\t$delete = db_delete('pt_publishactions')\r\n\t ->condition('id', $action_id)\r\n\t ->execute();\r\n\r\n\tdrupal_set_message('One record has been deleted successfully.');\r\n\tdrupal_goto(\"admin/config/system/publishthis/publishing-actions\");\r\n }\r\n\r\n}",
"function project_delete_multiple(array $ids) {\n entity_delete_multiple('project', $ids);\n}",
"public function destroy($id)\n {\n //\n $story= Story::find($id);\n $story->delete();\n $stories = DB::select(\"select sections.section_name, sections.id,users.name, stories.image_name, stories.id, stories.title, stories.body, stories.block, stories.id as s_id from users,stories,sections WHERE users.id=stories.user_id and stories.section_id=sections.id and stories.block='0' order by stories.id desc\");\n return view('story.stories',['stories'=>$stories]);\n }",
"function hook_actions_delete($aid) {\n db_delete('actions_assignments')\n ->condition('aid', $aid)\n ->execute();\n}",
"public function stories(){\n \treturn $this->belongsToMany('App\\Story');\n }"
] | [
"0.63799757",
"0.61692554",
"0.6037834",
"0.60071295",
"0.58425486",
"0.56212884",
"0.5552092",
"0.5494355",
"0.546031",
"0.54520345",
"0.54077727",
"0.53888434",
"0.5388246",
"0.53512216",
"0.5331895",
"0.5323548",
"0.5322792",
"0.5321288",
"0.5307176",
"0.529798",
"0.52943957",
"0.52815944",
"0.52782387",
"0.5277993",
"0.52714443",
"0.52691853",
"0.5260859",
"0.5252087",
"0.52096385",
"0.5184953"
] | 0.66681147 | 0 |
Get all project status for show in dropdown | public function getAllProjectStatuses() {
$query = Doctrine_Core::getTable('ProjectStatus')
->createQuery('c');
return $query->execute();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function CPT_get_pending_project_list() {\n\t$t_project_ids = current_user_get_accessible_projects();\n\tproject_cache_array_rows( $t_project_ids );\n\t$s = '';\n\tforeach( $t_project_ids as $t_id ){\n\t\tif( CPT_access_has_level('manage_project', $t_id)\n\t\t\t&& ( null === @plugin_config_get( 'project', null, null, ALL_USERS, $t_id ) ) )\n\t\t{\n\t\t\t$s.= '<option value=\"' . $t_id . '\"';\n\t\t\t$s.= '>' . string_attribute( project_get_field( $t_id, 'name' ) ) . '</option>' . \"\\n\";\n\t\t}\n\t\t$s.= CPT_get_subproject_option_list( $t_id, Array() );\n\t}\n\treturn $s;\n}",
"public function getProjectList(){\n\t\treturn ProjectProject::model()->findAll();\n\t}",
"function project_status_types() {\r\r\r\r\t\t##import project type model for processing\r\r\r\r\t\tApp::import(\"Model\", \"StatusType\");\r\r\r\r\t\t$this->StatusType = & new StatusType();\r\r\r\r\t\t\r\r\r\r\t\t$cont=\"StatusType.active_status\t= '1' and StatusType.delete_status=0\"; \r\r\r\r $statusdropdown=$this->StatusType->find('list',array('conditions'=>$cont,'fields'=>array('id','status_type')));\r\r\r\r\t\t//pr($statusdropdown);\r\r\r\r\t\treturn $statusdropdown;\r\r\r\r\t}",
"public function getAllProject()\n {\n return $this->client->request('GET','/rest/api/2/project');\n }",
"public function indexAction()\n {\n $this->denyAccessUnlessGranted('manage', new ProjectStatus());\n\n $em = $this->getDoctrine()->getManager();\n\n $projectStatuses = $em->getRepository('AppBundle:ProjectStatus')->findAllProjectStatus();\n\n return $this->render('projectstatus/index.html.twig', array(\n 'projectStatuses' => $projectStatuses,\n ));\n }",
"public function index()\n {\n $project_status = ProjectStatus::paginate(15);\n\n return ProjectStatusResource::collection($project_status);\n }",
"public function dropdown_project()\n {\n $sql = \"SELECT DISTINCT P_Name_ind {$this->sql_from()} {$this->sql_where()} ORDER BY P_Name_ind ASC\";\n $rows = \\NMI::db()->query($sql)->fetchAll();\n return \\Arr::assoc_to_keyval($rows, 'P_Name_ind', 'P_Name_ind');\n }",
"public function bystatus()\n\t{\n\t\t$connect = new connection;\n\t\tif($connect->tryconnect())\n\t\t{\n\t\t\t$connector = $connect->getConnector();\n\t\t\t\n\t\t\t$sqlstatus = \"SELECT * from tab_status\";\n\t\t\t$querystatus = $connector->prepare($sqlstatus);\n\t\t\t$querystatus->execute();\n\t\t\t$rowC = $querystatus->rowCount();\n\t\t\tif($rowC>0)\n\t\t\t{\n\t\t\t\t$limit = 0;\n\t\t\t\twhile($resultstatus = $querystatus->FETCH(PDO::FETCH_OBJ))\n\t\t\t\t{\n\t\t\t\t\t$id = $resultstatus->id_status;\n\t\t\t\t\t$nome = $resultstatus->nome_status;\n\t\t\t\t\t\n\t\t\t\t\t// QUERY TO COUNT BY STATUS\n\t\t\t\t\t$sqlproject = \"SELECT COUNT(*) FROM tab_projeto AS projeto INNER JOIN tab_status AS status ON projeto.id_status = status.id_status \n\t\t\t\t\tWHERE projeto.id_cc=:cc AND projeto.id_status=:amt AND projeto.id_f != 5 AND projeto.id_f != 8\";\n\t\t\t\t\t$queryproject = $connector->prepare($sqlproject);\n\t\t\t\t\t$queryproject->bindParam(':cc', $_SESSION['cc'], PDO::PARAM_STR);\n\t\t\t\t\t$queryproject->bindParam(':amt', $id, PDO::PARAM_STR);\n\t\t\t\t\t$queryproject->execute();\n\t\t\t\t\t$rowCproject = $queryproject->FETCH(PDO::FETCH_NUM);\n\t\t\t\t\tif(reset($rowCproject)>0 && ($limit<4))\n\t\t\t\t\t{\n\t\t\t\t\t\techo '<tr align=\"left\">';\n\t\t\t\t\t\techo '\t<td>'.$nome.'</td>';\n\t\t\t\t\t\techo '\t<td>'.reset($rowCproject).'</td>';\n\t\t\t\t\t\techo '\t<td>';\n\t\t\t\t\t\techo '\t <a href=\"projects.php?filter&type=status&id='.$id.'\"><button class=\"btn btn-success btn-xs\"><i class=\"fa fa-search\"></i></button></a>';\n\t\t\t\t\t\techo '\t</td>';\n\t\t\t\t\t\techo '</tr>';\n\t\t\t\t\t\t$limit++;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"public function getAllProjectNames()\n\t{\n\t\t$sql = $this->db->select()->from($this->db->getTableName(), array('name'))\n\t\t\t\t\t\t\t\t->where('status = ?', 'active');\n\t\treturn $this->db->getProjects($sql);\n\t}",
"function get_default_projectStatus() {\r\r\r\r\t\tApp::import(\"Model\", \"StatusType\");\r\r\r\r\t\t$this->StatusType = & new StatusType();\r\r\r\r\t\t\r\r\r\r\t\t$statusdropdown=$this->StatusType->find('first',array('conditions'=>array('StatusType.active_status' => 1, 'StatusType.default' => 1 ),'fields'=>array('id')));\r\r\r\r\t\tif($statusdropdown['StatusType']['id'])\r\r\r\r\t\treturn $statusdropdown['StatusType']['id'];\r\r\r\r\t\telse\r\r\r\r\t\treturn 0;\r\r\r\r\t\t//return $statusdropdown;\r\r\r\r\t}",
"public function filter_status() {\n\n\t\t$html = '<select class=\"form-control select2\" multiple><option value=\"\" disabled>Cari Status</option>';\n\t\t$html .= '<option value=\"1\">DP</option>';\n\t\t$html .= '<option value=\"2\">Lunas</option>';\n\t\t$html .= '<option value=\"3\">Piutang</option>';\n\t\t$html .= '</select>';\n\n\t\treturn $html;\n\t\t\n\t}",
"public function getProjectsForDropdown() {\n $projects = Project::forCompany()->get();\n return $projects;\n }",
"function project_status_select( $select_name, $current_status = NULL )\n{\n global $project_status;\n\n $text = \"<select name='$select_name' size='1'>\\n\" .\n \" <option value='None'>Please select...</option>\\n\";\n foreach ( $project_status as $status => $display )\n {\n $selected = ( $current_status == $status ) ? \" selected='selected'\" : \"\";\n $text .= \" <option value='$status'$selected>$display</option>\\n\";\n }\n\n $text .= \"</select>\\n\";\n\n return $text;\n}",
"public function pilih_status(){\r\n\t\t\r\n\t\t$query=\"SELECT DISTINCT id_status, status FROM status where id_status>3\";\r\n\t\t$result= $this->mysqli->query($query) or die(mysqli_connect_errno().\"salah\");\r\n\t\t//echo \"<select>\";\r\n\t\tif($result){\r\n\t\t\twhile($rows=$result->fetch_assoc()){\r\n\t\t\t\t$this->data[]=$rows;\r\n\t\t\t\t//$this->data[]=$rows;\r\n\t\t\t\t//echo(\"<option value='$rows['id_status']'>$rows['status']</option>\");\r\n\t\t\t\t//print_r($rows);\r\n\t\t\t\t//echo \"<option>\".$rows['status'].\"</option>\";\r\n\t\t\t}\r\n\t\t\treturn $this->data;\r\n\t\t}\r\n\t\t//echo \"</select>\";\r\n\t}",
"public function vb_project_list() {\r\n $confirm_user = $this->User_model->verify_credentials($this->input->post('password'), $this->input->post('username'));\r\n if ($confirm_user['success'] == false) {\r\n print json_encode(array('success' => false, 'message' => \"Invalid username or password.\"));\r\n return;\r\n }\r\n $user_data = $confirm_user['data'];\r\n $this->User_model->initialize($user_data['user_id']);\r\n $projects = $this->User_model->get_projects(null, null, \"project_name\");\r\n $count = $projects['num_rows'];\r\n unset($projects['num_rows']);\r\n print json_encode(array('success' => true, 'data' => json_encode($projects)));\r\n return;\r\n }",
"public function getListProject(){\n\n $project = MasterProject::get();\n \n if(count($project) <= 0){\n $list_project = collect();\n $list_project = $list_project->push(['id_project' => '' , 'label' => '']);\n }else{\n for ($i=0; $i < count($project) ; $i++){\n $id_project = $project->pluck('id')->get($i);\n $project_code = $project->pluck('project_code')->get($i);\n $project_description = $project->pluck('project_description')->get($i);\n \n $label_project = $project_code . ' : ' . $project_description;\n \n if($i==0){\n $list_project = collect();\n $list_project = $list_project->push(['id_project' => $id_project ,'label' => $label_project]);\n } else{\n $list_project = $list_project->push(['id_project' => $id_project ,'label' => $label_project]);\n }\n }\n }\n\n return $list_project;\n }",
"public function getStatusToSelect()\n {\n $status = $this->config->status;\n if ($status) {\n $out = [];\n foreach ($status as $item) {\n foreach ($item as $key => $value) {\n if ($key == \"label\") {\n $out[strtolower($value)] = $value;\n }\n }\n }\n return $out;\n }\n }",
"public function projects()\n {\n return $this->json(true,__('Projects'),Project::get(['id','name']));\n }",
"function GetProjects(){\n\t\tglobal $trans;\n\t\t$sql = \"\n\t\t\t\tSELECT DISTINCT\n\t\t\t\t P.Id,\n\t\t\t\t P.Name AS Description\n\t\t\t\tFROM\n\t\t\t\t Project P INNER JOIN ProjectParticipantsGroup PPG ON P.Id = PPG.Project_Id\n\t\t\t\tWHERE \n\t\t\t\t\tPPG.User_Id = \".$_SESSION['User']['Id'].\" \n\t\t\t\tORDER BY\n\t\t\t\t Description ASC\t\n\t\t\t \";\n\t\t$result = mysql_query($sql);\n\t\t$list_html = \"<li style=\\\"cursor:pointer;\\\" id=\\\"divProject-1\\\" value=\\\"All Conversations\\\" onclick=\\\"displaySelectedItem('div_project', 'spn_project', '\".$trans[\"message_center_select_project\"].\"');filterByProject(this)\\\">All Projects</li>\\n\";\n\t\twhile($row = mysql_fetch_assoc($result)){\n\t\t\t$list_html .= \"<li style=\\\"cursor:pointer;\\\" id=\\\"divProject_\".$row[\"Id\"].\"\\\" value=\\\"\".$row[\"Description\"].\"\\\" onclick=\\\"displaySelectedItem('div_project', 'spn_project', '\".$row[\"Description\"].\"');filterByProject(this)\\\">\".$row[\"Description\"].\"</li>\\n\";\n\t\t}\n\t\tmysql_free_result( $result );\n\t\treturn $list_html;\n\t}",
"public function getStatusList()\n {\n $statuses = Shop::getStatusesLabels();\n //not show status Failed at form\n unset($statuses[Shop::STATUS_FAILED]);\n unset($statuses[Shop::STATUS_INDEXING]);\n //if products has NOT already imported for shop...\n if ($this->model && !$this->model->getShopProducts()->exists()) {\n //remove status for shop with products\n unset($statuses[Shop::STATUS_INDEXED]);\n } else {\n //remove status for shop with products\n unset($statuses[Shop::STATUS_NEW]);\n }\n //return stuses are avaialbel for form\n return $statuses;\n }",
"public function listStatuses();",
"public function index()\n {\n $statuses = ProjectStatus::all();\n return view('backends.admins.project-status-index')\n ->with('statuses', $statuses);\n }",
"public function getStatusRegis($project_id = ''){\n if (!empty($project_id)){\n $this->db->where('project_id',$project_id);\n }\n $this->db->select('project_id,reg_status');\n $this->db->where('user_id',$this->session->userdata('sesUserID'));\n $this->db->from('tcdc_prj_register');\n $query = $this->db->get();\n $data =array();\n foreach ($query->result() as $key => $value) {\n @$data[$value->project_id]->status = 1;\n @$data[$value->project_id]->reg_status = $value->reg_status;\n }\n return $data;\n }",
"public function lstProject(){\r\n\t\t$Sql = \"SELECT\r\n\t\t\t\t\tportfolio_id,\r\n\t\t\t\t\tproject_name,\r\n\t\t\t\t\tproject_description,\r\n\t\t\t\t\tclient_name,\r\n\t\t\t\t\tproject_c_date,\r\n\t\t\t\t\tproject_tags,\r\n\t\t\t\t\tproject_file_1,\r\n\t\t\t\t\tproject_file_2,\r\n\t\t\t\t\tis_active\r\n\t\t\t\tFROM\r\n\t\t\t\t\trs_tbl_project\r\n\t\t\t\tWHERE\r\n\t\t\t\t\t1=1\";\r\n\t\tif($this->isPropertySet(\"portfolio_id\", \"V\"))\r\n\t\t\t$Sql .= \" AND portfolio_id=\" . $this->getProperty(\"portfolio_id\");\r\n\t\t\r\n\t\tif($this->isPropertySet(\"is_active\", \"V\"))\r\n\t\t\t$Sql .= \" AND is_active='\" . $this->getProperty(\"is_active\") . \"'\";\r\n\t\t\r\n\t\tif($this->isPropertySet(\"ORDERBY\", \"V\"))\r\n\t\t\t$Sql .= \" ORDER BY \" . $this->getProperty(\"ORDERBY\");\r\n\t\t\r\n\t\tif($this->isPropertySet(\"limit\", \"V\"))\r\n\t\t\t$Sql .= $this->appendLimit($this->getProperty(\"limit\"));\r\n\t\t\r\n\t\treturn $this->dbQuery($Sql);\r\n\t}",
"public function status_list() {\t\n\t\t$this -> db -> select('*');\n\t\t$this -> db -> from('status_info');\n\t\t$query = $this->db->get();\n\t\tif ($query->num_rows() > 0) {\n return $query->result();\n }else{\n\t\t\treturn false;\n\t\t}\n }",
"public function allWithProjects();",
"public function get_projects_selectbox(){\n\t\t\t$project_id = 0;\n\t\t\tif(isset($_GET['project_id']))\n\t\t\t{\n\t\t\t\t$project_id = wp_strip_all_tags($_GET['project_id']);\n\t\t\t}\n\t\t\t$projects = $this->get_projects();\n\t\t\t$data = '<span class=\"\"><select class=\"select_city select_title\" onchange=\"javascript:location.href = this.value;\"><option value=\"?\">Select Project</option>';\n\t\t\tforeach($projects as $project)\n\t\t\t{\n\t\t\t\t$data .= '<option value=\"?project_id='.$project->ID.'\" '.($project->ID==$project_id?'selected':'').'>'.$project->post_title.'</option>';\n\t\t\t}\n\t\t\t$data .= '</select></span>';\n\t\t\treturn $data;\n\t\t}",
"function getCompanyTypeStatusDropdown()\r\r\r\r\t{\r\r\r\r App::import(\"Model\", \"CompanyTypeStatus\");\r\r\r\r $this->CompanyTypeStatus = &new CompanyTypeStatus();\t \r\r\r\r \t $companytypestatusdata = $this->CompanyTypeStatus->find(\"all\"); \r\r\r\r $companytypestatusdropdown = Set::combine($companytypestatusdata, '{n}.CompanyTypeStatus.id','{n}.CompanyTypeStatus.company_type_status_name');\r\r\r\r asort($companytypestatusdropdown);\r\r\r\r\t return $companytypestatusdropdown;\r\r\r\r }",
"public function getStatusList()\n {\n $statusArray = [\n self::STATUS_DRAFT => Yii::t('app', 'Draft'),\n self::STATUS_PUBLISHED => Yii::t('app', 'Published'),\n ];\n\n return $statusArray;\n }",
"public function getStatusList()\n {\n $statusArray = [\n self::STATUS_DRAFT => Yii::t('app', 'Draft'),\n self::STATUS_PUBLISHED => Yii::t('app', 'Published'),\n ];\n\n return $statusArray;\n }"
] | [
"0.7231333",
"0.7027768",
"0.7018507",
"0.69504845",
"0.687458",
"0.67854387",
"0.67316246",
"0.67214173",
"0.67072743",
"0.67020804",
"0.67014915",
"0.669815",
"0.6684233",
"0.66524786",
"0.66342646",
"0.6631151",
"0.6596496",
"0.6566376",
"0.65199846",
"0.65116924",
"0.64322734",
"0.64253193",
"0.6392275",
"0.6374728",
"0.6348221",
"0.63405937",
"0.63375556",
"0.63243985",
"0.6323136",
"0.6323136"
] | 0.74566257 | 0 |
Get project status by id | public function getProjectStatusById($id) {
return Doctrine_Core::getTable('ProjectStatus')->find($id);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getStatus($id){\n $getStatus = $this->find($id);\n return $getStatus->status;\n }",
"public function getStatusById($id)\r\n {\r\n $row = $this->get($id);\r\n return $row->status;\r\n }",
"public function index($id)\n {\n return $this->repository->findWhere(['project_id'=>$id]);\n }",
"function getProjectById($id) {\n\t\t$sql = \"SELECT p.id AS project_id, title,overview,img_l,backer_count,pledge_goal,suml_pledged,DATEDIFF(end_date,CURDATE()) \n\t\t\tAS days_to_go, u.user_name,u.id\n\t\t \tFROM project p, project_status s, user u \n\t\t \tWHERE p.status = s.id AND p.id = {$id} AND p.creator_id = u.id\";\n\t\t \n\t\t\n\t\t$stmt = $this->conn->prepare($sql);\n\n\t\t$stmt->bindParam(\":id\", $id);\n\n\t\t$stmt->execute();\n\t\treturn $stmt->fetchAll();\n\t}",
"public function status($id) {\n \n }",
"public function index($id)\n {\n return $this->repository->findWhere(['project_id' => $id]);\n }",
"public function get_project($id){\n //leave until the database is updated with new attributes for the project data\n //$this->db->select('project_id, project_name');\n $this->db->where('project_id', $id);\n $query = $this->db->get(\"project\");\n return $query->result();\n }",
"public static function findByProject($id){\n if (!self::connectDB()) return null;\n $results = [];\n $query = \"SELECT i.id_institucion,i.descripcion 'institucion_nombre',i.estatus,phi.principal from proyecto_has_institucion phi INNER JOIN institucion i ON phi.instituciones_id_institucion = i.id_institucion\";\n $query.= \" WHERE i.estatus != ?\";\n $dinParams = [];\n\n $dinParams[] = self::getBindParam(\"i\",Estatus::ESTATUS_REMOVED);\n if ($id) {\n $query .=\" AND phi.proyectos_id_proyecto=?\";\n $dinParams[] = self::getBindParam(\"i\",$id);\n }\n\n $query = self::formatQuery($query);\n\n if (!$result = self::$dbManager->query($query)) return $results;\n self::bindDinParam($result,$dinParams);\n if (!self::$dbManager->executeSql($result)) return $results;\n\n $results = self::mappingFromDBResult($result);\n return $results;\n }",
"public function index($id)\n {\n return $this->repository->with(['project'])->findWhere(['project_id'=>$id]);\n }",
"public function find($id)\n {\n $projectData = $this->db->fetchAssoc('SELECT * FROM projects WHERE id = ?', array($id));\n return $projectData ? $this->buildProject($projectData) : FALSE;\n }",
"private function getProject($id)\n {\n $project = $this->request('projects/'.$id.'?opt_fields=name,id,workspace');\n if (!$this->infos['errorBoolean']) {\n $this->project = ['project' => json_decode($project)->data];\n return $project;\n }\n }",
"public function show($id) {\n return Project::find($id);\n }",
"function get_status($id) {\n\n// check if status db is up to date\n\n\n// update old entries\n\n\n// return status information as xml\n\n\t}",
"public function show($id)\n {\n $taskStatus = TaskStatus::find($id);\n return response()->json($taskStatus);\n }",
"public function getDetailsById($id)\n {\n return Project::find($id);\n }",
"public function get( $id ) {\n\t\t$subProject = $this->repo->findOneById( $id );\n\t\treturn $subProject;\n \t}",
"function db_getProjectById ($id, $link) {\n\t\n\tglobal $CONF;\n\t\n\t$schema\t\t\t\t= db_determine_schema();\n \n\t$result\t\t\t\t= db_query( \"SELECT * \" .\n\t\t\t\t\t\t\t\t\" FROM \".$schema.\"svnprojects \" .\n\t\t\t\t\t\t\t\t\" WHERE (id = '$id') \", $link);\n\tif( $result['rows'] == 1 ) {\n\t\t\n\t\t$row\t\t\t= db_assoc( $result['result'] );\n\t\t$projectname\t= $row['svnmodule'];\n\t\t\n\t\treturn $projectname;\n\t\n\t} else {\n\t\t\n\t\treturn false;\n\t\t\n\t}\t\t\n\t\n}",
"public function get($id) {\n $sql =<<<SQL\nSELECT * from $this->tableName\nwhere id = ?\nSQL;\n $pdo = $this->pdo();\n $statement = $pdo->prepare($sql);\n $statement->execute(array($id));\n if($statement->rowCount() === 0) {\n return null;\n }\n\n return new Project($statement->fetch(PDO::FETCH_ASSOC));\n }",
"public function getGameStatus($id)\n {\n return $this->em->getRepository('MeridianCoreBundle:Game')\n ->find($id)\n ->getStatus();\n }",
"public function show($id)\n {\n $status = StatusVenda::findOrFail($id);\n return $status;\n }",
"public function show($id)\n {\n $project = DB::select(\"SELECT * FROM project WHERE id = '$id' \");\n\n return $project;\n }",
"public function get_job_status($id){\n\t\tif(!empty($id)){\n\t\t\t$this->db->select('*');\n\t\t\t$this->db->from('jobstatus');\n\t\t\t$this->db->where('Id',$id);\n\t\t\t$query = $this->db->get();\n\t\t\t$result = $query->result();\n\t\t}else{\n\t\t\t$this->db->select('*');\n\t\t\t$this->db->from('jobstatus');\n\t\t\t$query = $this->db->get();\n\t\t\t$result = $query->result();\n\t\t}\n\t\treturn $result;\n\t}",
"public function show($id)\n {\n if(DB::table('projects')->where('id','=',$id)->exists()) {\n $data['statuses'] = DB::table('statuses')->get();\n\n if (DB::table('tasks')->where('projectId', '=', $id)->exists()){\n $data['tasks'] = DB::table('projects')\n ->join('tasks', 'tasks.projectId', '=', 'projects.id', 'inner')\n ->orderBy(\"tasks.updated_at\")\n ->where('projectId', '=', $id)->get();\n if(DB::table('taskstates')->count() > 0) {\n $data['taskStates'] = DB::table('taskStates')\n ->join('statuses', 'taskStates.statusId', '=', 'statuses.id', 'inner')\n ->join('tasks', 'taskStates.taskId', '=', 'tasks.id', 'inner')\n ->select('taskStates.created_at', 'taskStates.updated_at', 'taskStates.id', 'taskStates.taskStatesDesc', 'taskStates.taskId', 'taskStates.statusId', 'taskStates.userId', 'statuses.statusName')\n ->where('tasks.projectId', '=', $id)\n ->get();\n\n foreach ($data['taskStates'] as $state) {\n $state->user = User::find($state->userId);\n }\n }\n }\n $data['project'] = DB::table('projects')->find($id);\n\n $data['id'][0] = $id;\n if (DB::table('projects')->where('id', '=', $id)->exists()) {\n $data['id'][1] = true;\n } else {\n $data['id'][1] = false;\n }\n //return $data;\n return view('tecCard.dashboard', compact('data', 'data'));\n\n }//endif\n else{\n return view('tecCard.dashboard');\n }\n }",
"private function getProjectName($id)\n {\n return Project::where('id', $id)->first()->project_name;\n }",
"public function getById($id, $status = 1)\n {\n }",
"public function getById($id, $status = 1)\n {\n }",
"public function find($id)\n {\n return OrderStatus::find($id);\n }",
"public function getprojectdetails($id){ \n\t $data=array();\n $this->db->select('*');\n $data=$this->db->get_where(\"projects\",array(\"project_id\"=> $id))->row_array();\n \n \n return $data;\n \n \n }",
"public function show($id)\n {\n return new ProjectResource(Project::findOrFail($id));\n }",
"public function get ($id) {\n $query = 'SELECT * FROM projects WHERE project_id = :id';\n $stmt = $this->database->prepare($query);\n $stmt->execute(['id' => $id]);\n\n $row = $stmt->fetch();\n\n if (empty($row)) {\n throw new NotFoundException;\n }\n $result = new Project($row['project_id'], $row['codename'], $row['number']);\n $result->description = $row['description'];\n return $result;\n }"
] | [
"0.7545023",
"0.73755455",
"0.7220538",
"0.71267337",
"0.71090794",
"0.7099148",
"0.7003708",
"0.6958356",
"0.69568145",
"0.6864073",
"0.6822847",
"0.6766233",
"0.67144907",
"0.66970843",
"0.6680414",
"0.66580695",
"0.6582481",
"0.6580679",
"0.65503085",
"0.6525428",
"0.6523271",
"0.65230584",
"0.6520263",
"0.6511855",
"0.65109295",
"0.65109295",
"0.64758056",
"0.64612406",
"0.6448198",
"0.6424781"
] | 0.8529508 | 0 |
Get url to icon | public function getIconUrl(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function urlIcon(): string;",
"function icon() {\n\t\t$url = $this->plugin_url();\n\t\t$url .= '/images/transmit_blue.png';\n\t\treturn $url;\n\t}",
"public function getIconUrl()\n {\n return $this->icon_url;\n }",
"public function getIconUrl()\n {\n return $this->iconUrl;\n }",
"public function getIconUrl(): string\n {\n $result = '';\n $tokenDetails = $this->getTokenDetails();\n $iconForType = $this->getIconForType((string)$tokenDetails['type']);\n if (is_array($iconForType) && isset($iconForType['url'])) {\n $result = (string)$iconForType['url'];\n }\n\n return $result;\n }",
"public function getImageUrlIcon() \n {\n $icon = $this->icon;\n return Yii::$app->urlManager->baseUrl . '/admin/uploads/center/' . $icon;\n }",
"public function relIconPath()\n {\n preg_match('/icons\\/.*/', $this->icon, $matches);\n\n return $matches[0];\n }",
"public function get_icon()\n {\n return 'fa fa-link';\n }",
"public function getIconURL($params = array()) {\n\t\treturn _elgg_services()->iconService->getIconURL($this, $params);\n\t}",
"public function getIconOpenUrl() {\n return $this->iconOpenUrl;\n }",
"public static function getIcon();",
"function asmi_get_icons_uri() {\n\treturn apply_filters( 'asmi_icons_uri',\n\t\t'https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css' );\n}",
"function plugin_geticon_links2()\n{\n global $_CONF;\n\n return $_CONF['site_url'] . '/links/images/links.png';\n}",
"public function getIcon() {}",
"public function getIcon(): string;",
"public function get_icon() {\n return 'astha far fa-images';\n }",
"public function getIcon();",
"public function getIcon();",
"function wp_ozh_yourls_customicon( $in ) {\r\n\treturn wp_ozh_yourls_pluginurl().'res/icon.gif';\r\n}",
"function plugin_geticon_downloads()\n{\n global $_CONF;\n\n return $_CONF['site_url'] . '/downloads/images/download_icon.png';\n}",
"function getIconUrl() {\n return get_image_url('activity_log/comment.gif', RESOURCES_MODULE);\n }",
"public function getVirtualIconPath()\n {\n return !$this->image ? '' : url('/floors/' . $this->id . '/image');\n }",
"public function getCheckoutIconUrl()\n {\n $url = $this->_getEndpoint(ApiEndpoints::ENDPOINT_GLOBAL_ASSETS).'/bambora_icon_64x64.png';\n\n return $url;\n }",
"function plugin_geticon_nexproject(){\r\n global $_CONF;\r\n\r\n return $_CONF['site_url'] . '/nexproject/images/nexproject.gif';\r\n\r\n}",
"public function getIconServer();",
"public function icon() {\n\t\t$icon_url = MACHETE_BASE_URL . 'inc/' . $this->params['slug'] . '/icon.svg';\n\t\techo '<img src=\"' . esc_attr( $icon_url ) . '\" style=\"width: 96px; height: 96px;\">';\n\t}",
"public function getIconWebPath(){\n\t\treturn \"/uploads/account/{$this->getId()}/{$this->getPhoto()}\";\n\t}",
"public function getIconAttribute()\n {\n if($this->team_id){\n return Storage::getUrl('team_icon',$this->team_id . \".png\");\n } else{\n return asset(\"img/icon.jpeg\");\n }\n }",
"public function pathImageOpening()\n {\n return asset('public/main/icons/projectPublish.png');\n }",
"public function getIcon() {\n return strval($this->icon);\n }"
] | [
"0.8694709",
"0.8157901",
"0.7978993",
"0.7808003",
"0.75656176",
"0.7544475",
"0.72724706",
"0.72235113",
"0.72148496",
"0.71956265",
"0.7188184",
"0.7136623",
"0.7113656",
"0.70850813",
"0.7077361",
"0.7074598",
"0.7074515",
"0.7074515",
"0.70670336",
"0.702847",
"0.7021857",
"0.70012397",
"0.6992464",
"0.6961557",
"0.6930024",
"0.69158334",
"0.69016874",
"0.6872868",
"0.6856387",
"0.6842568"
] | 0.8554769 | 1 |
Creates a new ConfEvent entity. | public function createAction(Request $request)
{
$entity = $this->get('fibe_security.acl_entity_helper')->getEntityACL('CREATE', 'ConfEvent');
$form = $this->createForm(new ConfEventType($this->getUser()), $entity);
$form->bind($request);
if ($form->isValid())
{
$em = $this->getDoctrine()->getManager();
$entity->setMainEvent($this->getUser()->getCurrentMainEvent());
$em->persist($entity);
// $xprop= new XProperty();
// $xprop->setXNamespace("event_uri");
// $xprop->setXKey(rand(0,999999));
// $xprop->setXValue("http://dataconf-event/" . $entity->getId());
// $xprop->setCalendarEntity($entity);
// $em->persist($xprop);
$em->flush();
//$this->get('fibe_security.acl_entity_helper')->createACL($entity,MaskBuilder::MASK_OWNER);
return $this->redirect($this->generateUrl('schedule_event_show', array('id' => $entity->getId())));
}
return $this->render(
'fibeWWWConfBundle:ConfEvent:new.html.twig',
array(
'entity' => $entity,
'form' => $form->createView(),
)
);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function newAction()\n {\n $entity = $this->get('fibe_security.acl_entity_helper')->getEntityACL('CREATE', 'ConfEvent');\n\n $form = $this->createForm(new ConfEventType($this->getUser()), $entity);\n\n return $this->render(\n 'fibeWWWConfBundle:ConfEvent:new.html.twig',\n array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n )\n );\n }",
"public function create(Event $event);",
"public function createEvent()\n {\n $entityClass = 'MU\\\\YourCityModule\\\\Entity\\\\EventEntity';\n\n $entity = new $entityClass();\n\n $this->entityInitialiser->initEvent($entity);\n\n return $entity;\n }",
"public function actionCreate() {\n $sessionToken = Yii::$app->session[WSConstants::ACCESS_TOKEN];\n $event = new EventCreation();\n $event->isNewRecord = true;\n // Display form\n if (!$event->load(Yii::$app->request->post())) {\n $event->load(Yii::$app->request->get(), '');\n if (Yii::$app->request->get()['type'] === \"scientific-objects\") {\n $event->load(array(self::PARAM_CONCERNED_ITEMS_URIS => array_keys(Yii::$app->session['scientific-object'])), '');\n }\n if (isset(Yii::$app->request->get()['dateWithoutTimezone'])) {\n $validDate = explode(' ', Yii::$app->request->get()['dateWithoutTimezone'])[0];\n $event->dateWithoutTimezone = $validDate;\n }\n $event->creator = $this->getCreatorUri($sessionToken);\n $this->loadFormParams();\n return $this->render('create', ['model' => $event]);\n\n // Submit form \n } else {\n $dataToSend[] = $event->attributesToArray();\n $requestResults = $event->insert($sessionToken, $dataToSend);\n return $this->handlePostPutResponse($requestResults, $event->returnUrl);\n }\n }",
"public function create($vEvent);",
"protected function create()\n {\n\n // Event instance\n $event = new Event(null);\n\n // Get params\n $request = Request::instance();\n\n if (!$this->validator($request->all())->fails()) {\n // DB::connection()->getPdo()->quote\n $name = preg_replace('/[^A-Za-z0-9\\-@\\.\\-]/', '', $request->request->get('name'));\n $date = preg_replace('/[^A-Za-z0-9\\-@\\.\\-]/', '', $request->request->get('date'));\n $description = preg_replace('/[^A-Za-z0-9\\-@\\.\\-]/', '', $request->request->get('description'));\n $address = preg_replace('/[^A-Za-z0-9\\-@\\.\\-]/', '', $request->request->get('address'));\n $theme = preg_replace('/[^A-Za-z0-9\\-@\\.\\-]/', '', $request->request->get('theme'));\n\n $event->eventCreate([\n 'event_user_id' => $request->user_id,\n 'event_name' => $name,\n 'event_description' => $description,\n 'event_date' => $date,\n 'event_address' => $address,\n 'event_theme' => $theme,\n 'event_secret' => 0,\n ]);\n\n return response()->json('EVENT_CREATED_SUCCESSFULLY', 200);\n }\n\n return response()->json('EVENT_CREATE_FAILED', 400);\n }",
"public function create($fields = array()) {\n\n if(!$this->db()->insert('events', $fields)) {\n throw new Exception('There was a problem creating event.');\n }\n }",
"public function store(CreateEventRequest $request)\n {\n $exploded = explode(',', $request->banner);\n $decoded = base64_decode($exploded[1]);\n if(str_contains($exploded[0],'jpeg'))\n $extension = 'jpg';\n else\n $extension = 'png';\n $fileName = str_random().'.'.$extension;\n $path = public_path().'/storage/banner/'.$fileName;\n file_put_contents($path, $decoded);\n\n $event = Event::create([\n 'event' => strtoupper($request->event),\n 'id_event_type' => $request->id_event_type,\n 'date_init' => $request->date_init,\n 'date_end' => $request->date_end,\n 'id_status' => 1,\n 'banner' => $fileName,\n ]);\n Change::create([\n 'description' => 'Creo el de evento:'.$request->event.' correctamente.',\n 'id_item' => 10,\n 'id_user' => Auth::user()->id,\n ]);\n return $event;\n\n }",
"public function create(){\n $title = $_POST['title'];\n $start = $_POST['start'];\n $back = $_POST['background'];\n\n //Insertando evento a base de datos\n $evento=new Agenda;\n $evento->agenda_fec_ini=$start;\n //$evento->fechaFin=$end;\n $evento->agenda_todo_dia=true;\n $evento->agenda_color=$back;\n $evento->agenda_descripcion=$title;\n $evento->pac_id=1;\n $evento->inst_id=1;\n $evento->rrhh_id=5;\n $evento->agenda_estado='A';\n\n\n //echo \"\\t \\t \\t\".$evento;\n $evento->save();\n }",
"public function create()\n\t{\n\t\t$this->layout = null;\n $data = array('error' => true, 'msg' => '');\n\n $event = new EventModel;\n\t\t$event->title = Input::get('eventTitle');\n\t\t$event->from = Carbon::createFromFormat(Lang::get('app.format.date'), Input::get('startTime'));\n\t\t$event->to = Carbon::createFromFormat(Lang::get('app.format.date'), Input::get('endTime'));\n\t\t$event->description = Input::get('description');\n\t\t$event->user_id = Auth::getUser()->id;\n\t\t$event->save();\n\t\t\n\t\t$data['error'] = false;\n\t\t$data['event'] = $event->toArray();\n\n\t\treturn json_encode($data);\n\t}",
"public function create($EventJSON)\n {\n //\n }",
"public function creating(Events $events)\n {\n if ($user = Auth::user()) {\n $events->company_id = $user->id;\n }\n\n if ($user = Auth::guard('backpack')->user()) {\n $events->company_id = $user->id;\n }\n }",
"public function store(CreateEventRequest $request)\n {\n $event = new Event;\n $event->fill($request->all());\n if(request('allday') == null){\n $event->allday = false;\n }\n $event->save();\n\n return redirect('/admin/core/events')->with('status', 'The event was successfully created.');\n }",
"public function create()\n {\n return view('admin.events.newEvent');\n }",
"protected abstract function createEvent();",
"public function setTypeEventsCreate()\n {\n $this->type = 'events.create';\n\n return $this;\n }",
"public function create()\n {\n return view('Evenements/create_event');\n }",
"public function test_it_can_create_an_event() {\n $response = $this->requester->postRequest($this->user, '/events/create', $this->event->toArray());\n $this->assertOkAndHas($response, $this->event);\n }",
"public function create(array $params = [])\n {\n /* Defined account is a precondition due to middleware. */\n $account = MiddleAuth::get();\n\n $storeId = self::from('store', self::getBody(), null);\n if ($storeId === null) {\n self::fail(\"A store must be specified.\");\n }\n v::intVal()->min(0)->check($storeId);\n\n /* Check WRITE permissions for store. */\n $store = EStore::queryId($storeId);\n if ($store == null || !$account->getPermissions($store)->canWrite()) {\n self::fail(\"Store is invalid or missing necessary permissions.\", \\HTTP::BAD_PARAMS);\n }\n\n $title = self::from('title', self::getBody(), null);\n if ($title === null) {\n self::fail(\"An event title is required.\");\n }\n\n $title = trim($title);\n /* 100 char limit is schema restriction. */\n v::stringType()->notEmpty()->length(1, 100)->alnum('-\"\\'?_()&%$#@!/\\\\')->check($title);\n\n $maxTime = time() + (\\Brv\\core\\data\\Data::SECONDS_YEAR * 10);\n\n $from = self::from('from_unix', self::getBody(), null);\n if ($from === null) {\n self::fail(\"A from date must be specified.\");\n }\n\n if (!v::intVal()->min(0)->max($maxTime)->validate($from)) {\n self::fail(\"You cannot plan an event that far in advance.\");\n }\n\n $to = self::from('to_unix', self::getBody(), null);\n if ($to == -1) {\n $to = null;\n }\n\n if ($to !== null && !v::intVal()->min($from)->max($maxTime)->validate($to)) {\n self::fail(\"The end date must be after the start date.\");\n }\n\n // Create and return id.\n $event = new EEvent();\n $event->setTitle($title);\n $event->setStoreId($storeId);\n $event->setFrom($from);\n if ($to !== null) {\n $event->setTo($to);\n }\n try {\n $eventId = $event->commit();\n } catch (\\Exception $ex) {\n self::fail(\"Failed to create new event.\");\n }\n\n return new View([\n 'id' => $eventId\n ]);\n }",
"function newEvent() {\n\t\t$this->event_id = '_new';\n\t\treturn $this->editEvent();\n\t}",
"public static function create( $args ) {\n\t\t$post_id = wp_insert_post( array(\n\t\t\t'post_title' => empty( $args['title'] ) ? 'Untitled' : sanitize_text_field( $args['title'] ),\n\t\t\t'post_type' => 'pys_event',\n\t\t\t'post_status' => 'publish',\n\t\t\t'ping_status' => 'closed',\n\t\t\t'comment_status' => 'closed',\n\t\t), true );\n\n\t\tif ( is_wp_error( $post_id ) ) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$event = new CustomEvent( $post_id );\n\t\t$event->update( $args );\n\n\t\treturn $event;\n\n\t}",
"public function createCustomevent(): self\n {\n $this->event_type = debug_backtrace()[1]['function'];\n $attr = $this->getAttributes();\n $dirty = $this->getDirty();\n $original = $this->getOriginal();\n\n $details = [];\n foreach ($attr as $property => $value) {\n if (array_key_exists($property, $dirty) && !$dirty) {\n $details[] = [\n $property,\n $original[$property] ?? FALSE,\n $dirty[$property] ?? FALSE,\n ];\n }\n }\n\n Customevent::create([\n 'user_id' => $this->user_id,\n 'model' => $this->getTable(),\n 'model_id' => $this->id,\n 'model_name' => $this->name,\n 'type' => $this->event_type,\n 'description' => $this->event_description ?? FALSE,\n 'details' => serialize($details) ?? '',\n ]);\n return $this;\n }",
"public function create($config);",
"public function create()\n {\n //\n return view('admin.classes.events.create');\n }",
"public function create()\n {\n $event= new Event;\n\n $this->authorize('create', $event);\n return view('admin.events.create', compact('event'));\n }",
"public function create() {\n $entity = new stdClass();\n $entity->type = 'canned_email';\n $entity->ceid = 0;\n $entity->name = '';\n $entity->email_subject = '';\n $entity->email_body = '';\n return $entity;\n }",
"public function testOrmCreateNewRecord()\n {\n $eventsModel = new IdiormDbal('events');\n\n $this->assertEquals(7, $eventsModel->count());\n\n $event = $eventsModel->create();\n\n $event->title = 'Biking';\n\n $event->country = 'New Zealand';\n\n $event->started_at = '2020-07-11 11:00:00';\n\n $event->save();\n\n $this->assertEquals(8, $eventsModel->count());\n\n $eventsModel->criteria('title', '=', 'Biking');\n\n $bikingEvent = $eventsModel->first();\n\n $this->assertEquals('Biking', $bikingEvent->title);\n\n $this->assertEquals('New Zealand', $bikingEvent->country);\n\n $this->assertEquals('2020-07-11 11:00:00', $bikingEvent->started_at);\n }",
"public function create()\n {\n $event = new Event();\n return view ('eventos.create', ['event'=>$event]);\n }",
"public function create()\n {\n return view('admin.event.create');\n }",
"public function create()\n {\n return view('admin.event.create');\n }"
] | [
"0.67422104",
"0.6643508",
"0.6188318",
"0.6064154",
"0.60352355",
"0.5996608",
"0.5727528",
"0.56982934",
"0.5634414",
"0.55962336",
"0.5588252",
"0.5534091",
"0.5531995",
"0.553003",
"0.55235815",
"0.5507742",
"0.54856443",
"0.5410772",
"0.53987527",
"0.537555",
"0.5363706",
"0.5357964",
"0.5350924",
"0.5338148",
"0.5331123",
"0.53285426",
"0.53045243",
"0.5301049",
"0.529839",
"0.529839"
] | 0.6989036 | 0 |
Displays a form to create a new ConfEvent entity. | public function newAction()
{
$entity = $this->get('fibe_security.acl_entity_helper')->getEntityACL('CREATE', 'ConfEvent');
$form = $this->createForm(new ConfEventType($this->getUser()), $entity);
return $this->render(
'fibeWWWConfBundle:ConfEvent:new.html.twig',
array(
'entity' => $entity,
'form' => $form->createView(),
)
);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function create()\n {\n return view('admin.events.newEvent');\n }",
"public function createAction(Request $request)\n {\n $entity = $this->get('fibe_security.acl_entity_helper')->getEntityACL('CREATE', 'ConfEvent');\n\n $form = $this->createForm(new ConfEventType($this->getUser()), $entity);\n $form->bind($request);\n\n if ($form->isValid())\n {\n $em = $this->getDoctrine()->getManager();\n $entity->setMainEvent($this->getUser()->getCurrentMainEvent());\n $em->persist($entity);\n\n // $xprop= new XProperty();\n // $xprop->setXNamespace(\"event_uri\");\n // $xprop->setXKey(rand(0,999999));\n // $xprop->setXValue(\"http://dataconf-event/\" . $entity->getId());\n // $xprop->setCalendarEntity($entity);\n // $em->persist($xprop);\n\n $em->flush();\n\n //$this->get('fibe_security.acl_entity_helper')->createACL($entity,MaskBuilder::MASK_OWNER);\n\n return $this->redirect($this->generateUrl('schedule_event_show', array('id' => $entity->getId())));\n }\n\n return $this->render(\n 'fibeWWWConfBundle:ConfEvent:new.html.twig',\n array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n )\n );\n }",
"public function create()\n {\n return view('admin.event.create');\n }",
"public function create()\n {\n return view('admin.event.create');\n }",
"public function create()\n {\n return view('Evenements/create_event');\n }",
"public function create()\n {\n //\n return view('admin.classes.events.create');\n }",
"public function createEventForm()\n {\n $create='create';\n return view('create_event',compact('create'));\n }",
"public function newAction()\n {\n $entity = new Configfield();\n $form = $this->createForm(new ConfigfieldType(), $entity);\n\n return $this->render('HegesAppConfigFileBundle:Configfield:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView()\n ));\n }",
"public function create()\n {\n return view('events/form');\n }",
"public function create()\n {\n $event= new Event;\n\n $this->authorize('create', $event);\n return view('admin.events.create', compact('event'));\n }",
"public function create()\n {\n return view('admin.events.create');\n }",
"public function create()\n {\n return view('admin.events.create');\n }",
"public function create()\n {\n return view('admin.events.create');\n }",
"public function create()\n {\n return view('admin.events.create');\n }",
"public function create()\n {\n //\n return view('dashboard.event.create');\n }",
"public function create()\n {\n return view('backend.event.create');\n }",
"public function actionCreate() {\n $sessionToken = Yii::$app->session[WSConstants::ACCESS_TOKEN];\n $event = new EventCreation();\n $event->isNewRecord = true;\n // Display form\n if (!$event->load(Yii::$app->request->post())) {\n $event->load(Yii::$app->request->get(), '');\n if (Yii::$app->request->get()['type'] === \"scientific-objects\") {\n $event->load(array(self::PARAM_CONCERNED_ITEMS_URIS => array_keys(Yii::$app->session['scientific-object'])), '');\n }\n if (isset(Yii::$app->request->get()['dateWithoutTimezone'])) {\n $validDate = explode(' ', Yii::$app->request->get()['dateWithoutTimezone'])[0];\n $event->dateWithoutTimezone = $validDate;\n }\n $event->creator = $this->getCreatorUri($sessionToken);\n $this->loadFormParams();\n return $this->render('create', ['model' => $event]);\n\n // Submit form \n } else {\n $dataToSend[] = $event->attributesToArray();\n $requestResults = $event->insert($sessionToken, $dataToSend);\n return $this->handlePostPutResponse($requestResults, $event->returnUrl);\n }\n }",
"public function newAction()\n {\n $entity = new Config();\n $form = $this->createCreateForm($entity);\n\n return $this->render('MediashareAppBundle:Config:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'error' => $error = null\n ));\n }",
"public function create()\n {\n //\n return view('admin.events.create');\n }",
"public function create()\n {\n return view('backend.UpcomingEvents.form');\n }",
"public function newAction()\n {\n $entity = new Event();\n $form = $this->createCreateForm($entity);\n\n return array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n );\n }",
"public function create()\n {\n return view('event.create');\n }",
"public function create()\n {\n return view('event.create');\n }",
"public function create()\n {\n\n return view('event.add');\n\n }",
"public function create()\n {\n return View::make('edit_event');\n }",
"public function create()\n {\n $parse = [\n 'title' => 'Create a new Event'\n ];\n\n return view('admin_pages/event/create', ['parse' => $parse]);\n }",
"public function create()\n {\n $model = new Event;\n $models = $this->modelname;\n $action = self::STORE;\n session()->flash('page_task', 'New Event');\n return view('event.partial', compact('model', 'action', 'models'));\n }",
"public function create()\n {\n\n return view('site.event');\n\n }",
"public function create()\n {\n return view('eventos.create');\n }",
"public function create()\n {\n return view('events.create');\n }"
] | [
"0.7281546",
"0.7250614",
"0.70034003",
"0.70034003",
"0.69957346",
"0.6945118",
"0.6926035",
"0.69124657",
"0.6892551",
"0.68766767",
"0.6841145",
"0.6841145",
"0.6841145",
"0.6841145",
"0.68387693",
"0.68202996",
"0.68184936",
"0.68063974",
"0.6777911",
"0.6774043",
"0.67722195",
"0.6766845",
"0.6766845",
"0.6753739",
"0.67490715",
"0.67124367",
"0.67005944",
"0.6698147",
"0.66732067",
"0.666729"
] | 0.8649974 | 0 |
papers Add paper to the confEvent | public function addPaperAction(Request $request)
{
$id = $request->request->get('id_entity');
$entity = $this->get('fibe_security.acl_entity_helper')->getEntityACL('EDIT', 'ConfEvent', $id);
$id_paper = $request->request->get('id_paper');
$paper = $this->get('fibe_security.acl_entity_helper')->getEntityACL('VIEW', 'Paper', $id_paper);
//Add paper to the confEvent
$entity->addPaper($paper);
//Sauvegarde des données
$em = $this->getDoctrine()->getManager();
$em->persist($entity);
$em->flush();
return $this->render(
'fibeWWWConfBundle:ConfEvent:paperRelation.html.twig',
array(
'entity' => $entity,
)
);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function papers()\n {\n return $this->hasMany(PastPaper::class);\n }",
"function setPaperHeight($paperHeight) {\t \r\n\t $this->paperHeight = $paperHeight;\r\n\t}",
"function eventclass_paper()\n\t{\n\t\t$this->events[\"AfterEdit\"]=true;\n\n\n//\tonscreen events\n\n\t}",
"public function postPaper()\n {\n }",
"protected function prpArticle() {\n\t\t$prp=['classes'=>['std'=>'article'],'attributes'=>[],\n\t\t\t'data_att'=>[]];\n\t\treturn $prp;\n\t}",
"function setPaperWidth($paperWidth) {\t \r\n\t $this->paperWidth = $paperWidth;\r\n\t}",
"function eventclass_pdf()\n\t{\n\t\t$this->events[\"AfterAdd\"]=true;\n\n\t\t$this->events[\"AfterEdit\"]=true;\n\n\n//\tonscreen events\n\n\t}",
"protected function populate( $paper ) {\n\t\tif ( $paper instanceof WP_Post ) {\n\t\t\t$post_id = $paper->ID;\n\t\t\t$post_obj = $paper;\n\t\t} elseif ( is_numeric( $paper ) ) {\n\t\t\t$post_id = $paper;\n\t\t\t$post_obj = get_post( $post_id );\n\t\t}\n\n\t\tif ( 'cacsp_paper' === $post_obj->post_type ) {\n\t\t\t$this->id = $post_id;\n\t\t\t$this->post_obj = $post_obj;\n\t\t\t$this->post_obj_pristine = clone( $post_obj );\n\t\t}\n\t}",
"public function generatePaperContent($data)\n {\n if ($data['paperBrand'] != '') {\n $this->content['tags'][] = 'Paper';\n $this->content['categories'][] = $data['paperBrand'];\n $this->content['categories'][] = $data['paperModel'];\n $this->content['text'] .= \" in \" . $data['paperBrand'] . \" \" . $data['paperModel']. \" paper\";\n }\n }",
"public function getConferencePapers() // {{{\n {\n global $CCV_CONST;\n $records = array();\n $elements = $this->m_xpath->query(\"//section[@id='4b9f909503cd4c8aa8d826c87d6d874d']\");\n for ($i = 0; !is_null($elements) && $i < $elements->length; $i++)\n {\n $record = array();\n $id = $this->get_xpath(\"@recordId\", $elements->item($i));\n $record[\"title\"] = $this->get_xpath(\"field[@id='8e6ee535c95e42ec866b777c7472bafb']/value\", $elements->item($i));\n $record[\"publisher\"] = $this->get_xpath(\"field[@id='0c357193a93f4137a87394401ac81958']/value\", $elements->item($i));\n $record[\"authors\"] = $this->get_xpath(\"field[@id='3cc54d9bb92d421da46548979048396f']/value\", $elements->item($i));\n $record[\"editors\"] = $this->get_xpath(\"field[@id='018e656a0f824b1f91a6a2cb33ac61dd']/value\", $elements->item($i));\n $record[\"pages\"] = $this->get_xpath(\"field[@id='684ccb1fcdd7421f89b304ff5c40579d']/value\", $elements->item($i));\n $record[\"url\"] = $this->get_xpath(\"field[@id='61690b466fb748d99ed29b340c0ee60b']/value\", $elements->item($i));\n $record[\"status\"] = $this->get_xpath(\"field[@id='080301b1f1c0464bba7fcfa1fa8fe182']/lov/@id\", $elements->item($i));\n $pr = $this->get_xpath(\"field[@id='560a2ce08e14497ba575af760eb12ba9']/lov/@id\", $elements->item($i));\n if ($pr === $CCV_CONST[\"Yes-No\"][\"Yes\"])\n $record[\"peer_reviewed\"] = true;\n elseif ($pr === $CCV_CONST[\"Yes-No\"][\"No\"])\n $record[\"peer_reviewed\"] = false;\n $record[\"conf_name\"] = $this->get_xpath(\"field[@id='b3c8a60c053a405597b92899d95765a3']/value\", $elements->item($i));\n $record[\"published_in\"] = $this->get_xpath(\"field[@id='1a1b39e861054ee59d270e66271a4ead']/value\", $elements->item($i));\n $record[\"city\"] = $this->get_xpath(\"field[@id='c2efd9725588489b8df73467c5597c32']/value\", $elements->item($i));\n $date = $this->get_xpath(\"field[@id='0318d139f3e0479083188ff8319a97b2']/value\", $elements->item($i));\n list($date_year, $date_month) = explode(\"/\", $date);\n $record[\"date_year\"] = $date_year;\n $record[\"date_month\"] = $date_month;\n $records[$id] = $record;\n }\n return $records;\n }",
"public function paperOptions()\n {\n return $this->hasMany('App\\Models\\PaperFinishingTypeOptions', 'paper_finishing_type_id');\n }",
"function add_paper( $insertArray , $err_message = \"\" )\n{\n\t$db = adodb_connect( &$err_message );\n\t\n $values = implode(\", \", array_map(\"db_quote\", array_fill(0,count($insertArray),&$db), $insertArray));\n\t\n\t//Insert the paper info to paper table\n\t$sql = \"INSERT INTO \" . $GLOBALS[\"DB_PREFIX\"] . \"Paper \" ;\n\t$sql .= \"( \".implode(\", \", array_keys($insertArray)).\", MemberName ) \" ;\n\t$sql .= \" VALUES ( \" . $values . \", \" . db_quote( $db, $_SESSION[\"valid_user\"] ) . \" ) \" ;\n $result = $db -> Execute($sql);\n\t\n\tif( !$result )\n\t{\t\t\n\t\t$err_message .= \" Could not Insert the Paper into the Paper Table <br>\\n \";\t// Exception has occurred\t\t\t\n\t\treturn false ;\t\t\n\t}\n\telse\n\t{\n\t\t//Get the paperID first\n\t\t$paperID = $db -> Insert_ID();\t\t\n\t\treturn $paperID ;\n\t}\n}",
"public function paper()\n {\n return $this->belongsTo(Paper::class);\n }",
"function exam_paper_cpt() {\n\n $labels = array(\n 'name' => _x( 'Notes and Exam Questions', 'Post Type General Name', 'sage' ),\n 'singular_name' => _x( 'Paper', 'Post Type Singular Name', 'sage' ),\n 'menu_name' => __( 'Papers', 'sage' ),\n 'name_admin_bar' => __( 'Papers', 'sage' ),\n 'archives' => __( 'Paper Archives', 'sage' ),\n 'attributes' => __( 'Paper Attributes', 'sage' ),\n 'parent_item_colon' => __( 'Parent Paper:', 'sage' ),\n 'all_items' => __( 'All Papers', 'sage' ),\n 'add_new_item' => __( 'Add New Paper', 'sage' ),\n 'add_new' => __( 'Add New', 'sage' ),\n 'new_item' => __( 'New Paper', 'sage' ),\n 'edit_item' => __( 'Edit Paper', 'sage' ),\n 'update_item' => __( 'Update Paper', 'sage' ),\n 'view_item' => __( 'View Paper', 'sage' ),\n 'view_items' => __( 'View Papers', 'sage' ),\n 'search_items' => __( 'Search Paper', 'sage' ),\n 'not_found' => __( 'Not found', 'sage' ),\n 'not_found_in_trash' => __( 'Not found in Bin', 'sage' ),\n 'featured_image' => __( 'Featured Image', 'sage' ),\n 'set_featured_image' => __( 'Set featured image', 'sage' ),\n 'remove_featured_image' => __( 'Remove featured image', 'sage' ),\n 'use_featured_image' => __( 'Use as featured image', 'sage' ),\n 'insert_into_item' => __( 'Insert into Paper', 'sage' ),\n 'uploaded_to_this_item' => __( 'Uploaded to this Paper', 'sage' ),\n 'items_list' => __( 'Papers list', 'sage' ),\n 'items_list_navigation' => __( 'Papers list navigation', 'sage' ),\n 'filter_items_list' => __( 'Filter Papers list', 'sage' ),\n );\n\n $rewrite = array(\n 'slug' => 'subject/%ses_subject%/notes-and-exam-questions/level/%ses_level%/board/%ses_exam_board%',\n 'with_front' => false,\n 'pages' => true,\n 'feeds' => true,\n );\n\n $args = array(\n 'label' => __( 'Paper', 'sage' ),\n 'description' => __( 'Individually made topic revision booklets including all essential learning in easy to follow chunks. \nHone your understanding and exam technique with our past exam questions booklets.', 'sage' ),\n 'labels' => $labels,\n 'supports' => array( 'title', 'editor', 'revisions' ),\n 'taxonomies' => array( 'ses_subject', 'ses_level', 'ses_exam_board' ),\n 'hierarchical' => false,\n 'public' => true,\n 'show_ui' => true,\n 'show_in_menu' => true,\n 'menu_position' => 5,\n 'menu_icon' => 'dashicons-media-spreadsheet',\n 'show_in_admin_bar' => true,\n 'show_in_nav_menus' => false,\n 'can_export' => true,\n 'has_archive' => false,\n 'exclude_from_search' => false,\n 'publicly_queryable' => true,\n 'rewrite' => $rewrite,\n 'capability_type' => 'page',\n 'show_in_rest' => false,\n );\n register_post_type( 'ses_exam_paper', $args );\n\n}",
"protected function setup_config() {\n\t\t\t$config = presscore_config();\n\n\t\t\t$config->set( 'load_style', 'default' );\n\t\t\t$config->set( 'layout', $this->get_att( 'mode' ) );\n\t\t\t$config->set( 'post.preview.load.effect', $this->get_att( 'loading_effect' ), 'none' );\n\t\t\t$config->set( 'image_layout', ( 'resize' === $this->get_att( 'image_sizing' ) ? $this->get_att( 'image_sizing' ) : 'original' ) );\n\t\t\t$config->set( 'thumb_proportions', '' );\n\t\t\t$config->set( 'post.preview.width.min', $this->get_att( 'pwb_column_min_width' ) );\n\t\t\t$config->set( 'template.columns.number', $this->get_att( 'pwb_columns' ) );\n\t\t\t$config->set( 'post.preview.hover.animation', $this->get_att( 'hover_animation' ) );\n\t\t\t$config->set( 'item_padding', $this->get_att( 'gap_between_posts' ) );\n\t\t}",
"protected function prpArticleAside() {\n\t\t$prp=['classes'=>['std'=>'asidearticlewrapper'],'attributes'=>[],\n\t\t\t'data_att'=>[], 'flexaside'=>250, 'flexarticle'=>750, ];\n\t\treturn $prp;\n\t}",
"function pdf_write($param, $paper = 'a4', $layout = 'portrait')\n{\n\tglobal $sys;\n\t$text = $sys->curl($param['image']);\n\tif (!empty($text))\n\t{\n\t\t$param['image'] = 'data:image/png;base64,'.base64_encode($text);\n\t}else{\n\t\t$param['image'] = '';\n\t}\n\t$page = array(\n\t\t'content' => array(\n\t\t\tarray(\n\t\t\t\t'text' => $param['title'],\n\t\t\t\t'style' => 'title'\n\t\t\t\t),\n\t\t\tarray(\n\t\t\t\t'columns' => array(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'text' => $param['author'],\n\t\t\t\t\t\t'style' => 'author'\n\t\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'text' => $param['created'],\n\t\t\t\t\t\t'style' => 'created'\n\t\t\t\t\t\t)\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\tarray(\n\t\t\t\t'image' => $param['image'],\n\t\t\t\t'style' => 'image',\n\t\t\t\t'width' => 520\n\t\t\t\t),\n\t\t\tarray(\n\t\t\t\t'text' => pdf_cleaner($param['content']),\n\t\t\t\t'style' => 'content'\n\t\t\t\t),\n\t\t\tarray(\n\t\t\t\t'text' => $param['modified'],\n\t\t\t\t'style' => 'modified'\n\t\t\t\t),\n\t\t\tarray(\n\t\t\t\t'text' => $param['category'],\n\t\t\t\t'style' => 'category'\n\t\t\t\t),\n\t\t\t),\n\t\t'styles' => array(\n\t\t\t'title' => array(\n\t\t\t\t'fontSize' => 18,\n\t\t\t\t'bold' => true,\n\t\t\t\t'margin' => [0,0,0,20]\n\t\t\t\t),\n\t\t\t'author' => array(\n\t\t\t\t'italic' => true\n\t\t\t\t),\n\t\t\t'created' => array(\n\t\t\t\t'italic' => true,\n\t\t\t\t'alignment' => 'right'\n\t\t\t\t),\n\t\t\t'image' => array(\n\t\t\t\t'alignment' => 'center',\n\t\t\t\t'margin' => [0,0,0,10]\n\t\t\t\t),\n\t\t\t'content' => array(\n\t\t\t\t),\n\t\t\t'modified' => array(\n\t\t\t\t'italic' => true,\n\t\t\t\t'alignment' => 'right',\n\t\t\t\t'margin' => [0,10,0,0]\n\t\t\t\t),\n\t\t\t'category' => array(\n\t\t\t\t'italic' => true,\n\t\t\t\t'margin' => [0,20,0,0]\n\t\t\t\t),\n\t\t\t),\n\t\t'pageSize' => $paper,\n\t\t'pageOrientation' => $layout\n\t\t);\n\tif (empty($param['image']))\n\t{\n\t\tunset($page['content'][1]);\n\t}\n\tpdf_export($page, $param['title']);\n\t/*\n\techo json_encode($page);\n\tpr($page, $paper, $layout, __FILE__.':'.__LINE__);die();\n\t$config = array('paper' => $paper, 'layout' => $layout);\n\t$pdf = _lib('pdf', $config);\n\t$pdf -> ezSetCmMargins( 2, 1.5, 1, 1);\n\t$pdf->selectFont( './fonts/Helvetica' ); //choose font\n\n\t$all = $pdf->openObject();\n\t$pdf->saveState();\n\t$pdf->setStrokeColor( 0, 0, 0, 1 );\n\n\t// footer\n\t$pdf->addText( 250, 822, 6, config('site','title') );\n\t$pdf->line( 10, 40, 578, 40 );\n\t$pdf->line( 10, 818, 578, 818 );\n\t$pdf->addText( 30, 34, 6, _URL);\n\t$pdf->addText( 250, 34, 6, 'Powered by esoftplay.com' );\n\t$pdf->addText( 450, 34, 6, 'Created '.$param['created'] );\n\n\t$pdf->restoreState();\n\t$pdf->closeObject();\n\t$pdf->addObject( $all, 'all' );\n\t$pdf->ezSetDy( 30, 'makeSpace' );\n\n\t$pdf->ezText( $param['title'], 16 );\n\t$pdf->ezText( pdf_date($param), 6 );\n\tif(!empty($param['image']))\n\t{\n\t\t$pdf->ezImage($param['image'],5,0,'full','left');\n\t}\n\t$pdf->ezText( pdf_cleaner($param['content']), 10 );\n\n\t$options = array(\n\t\t'Content-Disposition' => menu_save($param['title']).'.pdf'\n\t,\t'Accept-Ranges'\t\t\t\t=> 0\n\t);\n\t$pdf->ezStream($options);\n\texit;\n\t*/\n}",
"function PDF() {\n\t\tglobal $Prefs;\n\t\t$PaperSize = explode(':',$Prefs['papersize']);\n\t\tparent::__construct($Prefs['paperorientation'], 'mm', $PaperSize[0]);\n\t\tif ($Prefs['paperorientation']=='P') { // Portrait - calculate max page height\n\t\t\t$this->pageY = $PaperSize[2]-$Prefs['marginbottom'];\n\t\t} else { // Landscape\n\t\t\t$this->pageY = $PaperSize[1]-$Prefs['marginbottom'];\n\t\t}\n\t\t$this->SetMargins($Prefs['marginleft'], $Prefs['margintop'], $Prefs['marginright']);\n\t\t$this->SetAutoPageBreak(0, $Prefs['marginbottom']);\n\n\t\t$this->SetDrawColor(128,0,0);\n\t\t$this->SetLineWidth(.35); // 1 point\n\t\t$this->AddPage();\n\n\t}",
"public function configure()\n {\n return $this->afterCreating(function (Post $post) {\n $post->comments()->saveMany(\n Comment::factory()->count(random_int(0, 10))->make()\n );\n });\n }",
"public function prs()\n\t{\n\t\treturn $this->belongsToMany('App\\Pr');\n\t}",
"protected function configure()\n {\n $this\n ->addProperty('post_id')\n ->addProperty('post_title')\n ->addProperty('post_date')\n ->addProperty('post_status')\n ->addProperty('post_author')\n ->addProperty('post_password')\n ->addProperty('post_content')\n ;\n }",
"function abp_prereg_pages() {\n\t\tadd_users_page( 'ABP Preregistrations', 'ABP Pre-Registrations', 'manage_options', 'abpmenu', 'abp_preregs_page');\n\t}",
"protected function prpAside() {\n\t\t$prp=[\n\t\t\t'classes'=>['std'=>'aside'],'attributes'=>[],'data_att'=>[],\n\t\t];\n\t\treturn $prp;\n\t}",
"protected function setupConfig(): void\n {\n $source = dirname(__DIR__) . '/config/easyrec.php';\n $this->publishes([$source => config_path('easyrec.php')]);\n $this->mergeConfigFrom($source, 'easyrec');\n }",
"private function _setEventsAndSpeakers() {\n\t\t//workaround for mongodb datasource bug. internal error it the collection is empty and you call ->find('list');\n\t\t$this->loadModel('Speaker');\n\t\t\n\t\t$speakers = $this->Speaker->find('count');\t\t\t\n\t\t\n\t\tif($speakers > 0) $speakers = $this->Speaker->find('list',array('order' => array('Speaker.created' => -1)));\n\t\tif($speakers == 0) $speakers = array();\n\t\t\n\t\t$this->loadModel('Event');\n\t\t\n\t\t$events = $this->Event->find('count');\t\t\t\n\t\t\n\t\tif($events > 0) $events = $this->Event->find('list');\n\t\tif($events == 0) $events = array();\n\t\t\n\t\t$this->loadModel('Topic');\n\t\t$topics = $this->Topic->find('count');\t\t\n\t\t\n\t\tif($topics > 0) $topics = array_merge(array('-1' => 'Kein Thema'),$this->Topic->find('list'));\n\t\tif($topics == 0) $topics = array('-1' => 'Kein Thema');\n\t\t\n\t\t\n\t\t$this->set(compact('speakers','events','topics'));\n\t}",
"function kalins_pdf_configure_pages() {\n global $kPDFadminPage;\n \n $kPDFadminPage = add_submenu_page('options-general.php', 'Kalins PDF Creation Station', 'PDF Creation Station', 'manage_options', 'kalins-pdf-admin', 'kalins_pdf_admin_page');\n add_action( 'load-' . $kPDFadminPage , 'kalins_admin_page_loaded' );\n \n global $kPDFtoolPage;\n \n $kPDFtoolPage = add_submenu_page('tools.php', 'Kalins PDF Creation Station', 'PDF Creation Station', 'manage_options', 'kalins-pdf-tool', 'kalins_pdf_tool_page');\n add_action( 'load-' . $kPDFtoolPage , 'kalins_admin_page_loaded' );\n}",
"function setPaperwiseSeq() {\r\n\t\t$questionquery = \"SELECT papercode,version,qcode_list FROM da_paperDetails WHERE papercode = '\".$this->papercode.\"' ORDER BY papercode\";\r\n\t\t$dbqueqry = new dbquery($questionquery,$this->connid);\r\n\t\twhile($querow = $dbqueqry->getrowarray()){\r\n\t\t\t$this->paperwiseQueSeq[$querow['version']] = explode(\",\",$querow['qcode_list']);\t\t\t\r\n\t\t\t$qcodelist = $querow['qcode_list'];\r\n\t\t}\r\n\r\n\t\t$totalQuestions = 0;\r\n\t\tif($qcodelist !='')\r\n\t\t{\r\n\t\t\t$this->totalQuestions = count(explode(\",\",$qcodelist));\r\n\t\t\t$this->qcodelist= $qcodelist;\r\n\r\n\t\t}\r\n\r\n\t\tforeach($this->paperwiseQueSeq as $paper => $quesarray){\r\n\t\t\t$this->questionSeq[$paper] = array_flip($quesarray);\r\n\t\t}\r\n\t}",
"function PaperFileManager($paperId) {\n\t\t$this->paperId = $paperId;\n\t\t$paperDao =& DAORegistry::getDAO('PaperDAO');\n\t\t$this->paper =& $paperDao->getPaper($paperId);\n\t\t$schedConfId = $this->paper->getSchedConfId();\n\t\t$schedConfDao =& DAORegistry::getDAO('SchedConfDAO');\n\t\t$schedConf =& $schedConfDao->getSchedConf($schedConfId);\n\t\t$this->filesDir = Config::getVar('files', 'files_dir') . '/conferences/' . $schedConf->getConferenceId() . '/schedConfs/' . $schedConfId .\n\t\t'/papers/' . $paperId . '/';\n\t}",
"function autoschedule_waiting_papers()\n{\n\t$db = adodb_connect( &$err_message );\n\t\n\t// Grab ordered list of suitable sessions\n\t$sql = \"SELECT * FROM \".$GLOBALS[\"DB_PREFIX\"].\"UnscheduledPaper \";\n\t$result = $db -> Execute($sql);\n\t\n\twhile ($unPaper = $result -> FetchNextObj())\n\t{\n\t\t$paper = get_paper_info($unPaper -> PaperID);\n\t\t$nextSlot = get_first_empty_slot($paper -> TrackID, $unPaper -> PresentationTypeID);\n\t\tif ($nextSlot)\n\t\t{\n\t\t\t$nextSlot -> PaperID = $unPaper -> PaperID;\n\t\t\tremove_paper_presentation($unPaper -> PaperID);\n\t\t\tadd_session_slot($nextSlot);\n\t\t}\n\t}\n}",
"public function alterCss(PrintCssAlterEvent $event) {\n $event->getBuild()['#attached']['library'][] = 'admissions_core/pdf';\n }"
] | [
"0.52255934",
"0.5015162",
"0.49342734",
"0.49330068",
"0.4800135",
"0.47584224",
"0.4731903",
"0.47129235",
"0.46841666",
"0.46059763",
"0.45986786",
"0.45822924",
"0.4572019",
"0.45594642",
"0.45580626",
"0.45527127",
"0.45461527",
"0.45412695",
"0.4524443",
"0.4512172",
"0.45059508",
"0.44761315",
"0.44650692",
"0.44219962",
"0.44109473",
"0.44031653",
"0.43906817",
"0.43853596",
"0.43781394",
"0.43561158"
] | 0.53887254 | 0 |
Delete person to a confEvent | public function deletePersonAction(Request $request)
{
$id = $request->request->get('id_entity');
$entity = $this->get('fibe_security.acl_entity_helper')->getEntityACL('EDIT', 'ConfEvent', $id);
$em = $this->getDoctrine()->getManager();
$id_role = $request->request->get('id_role');
$role = $em->getRepository('fibeWWWConfBundle:Role')->findOneBy(
array('conference' => $this->getUser()->getCurrentMainEvent(), 'id' => $id_role)
);
$em = $this->getDoctrine()->getManager();
//Add role to the confEvent
$entity->removeRole($role);
$em->remove($role);
//Sauvegarde des données
$em->persist($entity);
$em->flush();
return $this->render(
'fibeWWWConfBundle:ConfEvent:personRelation.html.twig',
array(
'entity' => $entity,
)
);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function delete() {\r\n \r\n // Does the Event object have an ID?\r\n if ( is_null( $this->id ) ) trigger_error ( \"Event::delete(): Attempt to delete a Event object that does not have its ID property set.\", E_USER_ERROR );\r\n \r\n // Delete the Event\r\n $conn = new PDO( DB_DSN, DB_USERNAME, DB_PASSWORD ); \r\n $conn->setAttribute( PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION );\r\n $st = $conn->prepare ( \"DELETE FROM \" . DB_PREFIX . \"events WHERE id = :id LIMIT 1\" );\r\n \r\n $st->bindValue( \":id\", $this->id, PDO::PARAM_INT );\r\n $st->execute();\r\n \r\n $conn = null;\r\n \r\n }",
"function delete($event_name, $data) {\n\t\tglobal $app, $conf;\n\n\t\t$this->action = 'delete';\n\n\t\t$app->uses('getconf');\n\t\t$web_config = $app->getconf->get_server_config($conf['server_id'], 'web');\n\n\t\tif ($data['old']['type'] == 'vhost' || $data['old']['type'] == 'vhostsubdomain') {\n\t\t\t$this->vhost_helper('delete', $data);\n\t\t}\n\n\t\tif ($data['old']['type'] == 'alias') {\n\t\t\t$data['new']['type'] == 'alias';\n\t\t\t$this->update($event_name, $data);\n\t\t}\n\n\t\tif ($data['old']['type'] == 'subdomain') {\n\t\t\t$data['new']['type'] == 'subdomain';\n\t\t\t$this->update($event_name, $data);\n\t\t}\n\t}",
"public function deleted(Event $event)\n {\n $event->invite()->delete();\n }",
"public function excluir(){\n\n\t\t$pdo = new \\PDO (DSN,USER,PASSWD);\t\n\n\t\t$sql = 'DELETE FROM DiscipuloTemEvento WHERE discipuloId = ? AND eventoId = ?';\n\n\t\t$stm = $pdo->prepare($sql);\n\n\t\t$stm->bindParam(1, $this->discipuloId);\n\t\t$stm->bindParam(2, $this->eventoId);\n\n\t\t$stm->execute();\n\n\t}",
"public function delete($Person_ID);",
"public function deleted(Personne $personne)\n {\n //\n }",
"public static function delete($event) {\n unset(self::$_event_tracker[$event->eid]);\n $event->delete();\n }",
"public function delete(string $collabPersonId);",
"public function onDelete($event);",
"public function delete(Event $event)\n\t{\n\t\t$event->delete();\n\t}",
"public function destroy(Event $event)\n {\n if($event->group->admin_id != auth()->user()->id && $event->host_id != auth()->user()->id){\n Abort(401);\n }\n DB::transaction(function () use(&$event){\n $notify_joined_users = $event->users()\n ->select('email')\n ->where('joined_event_updated_notify', true)\n ->where('users.id', '!=', auth()->user()->id)\n ->get();\n \n $host_name = \"\";\n $host_url = \"\";\n \n if($event->host){\n $host_name = $event->host->name;\n $host_url = 'profile/' . $event->host->username;\n }\n\n Mail::to($notify_joined_users)\n ->send(new DeletedNotificationMail(\n $event->group->name, \n 'Your event \"' . $event->name . '\" has been deleted', \n $host_name, \n $host_url\n ))\n ;\n $event->users()->detach();\n $event->delete();\n });\n }",
"public function onBeforeDeleteUser(KEvent $event)\n {\n\n $person = KService::get('repos:people.person')->find(array(\n 'id' => $event->person->id\n ));\n\n if ($person) {\n\n KService::get('repos:components')\n ->fetchSet()\n ->registerEventDispatcher(KService::get('anahita:event.dispatcher'));\n\n KService::get('anahita:event.dispatcher')\n ->dispatchEvent('onDeleteActor', array(\n 'actor_id' => $person->id\n ));\n\n $person->delete()->save();\n }\n }",
"public function deleteThePerson($sender) {\n $this->collection->removeFirstWhere(\"id\", $sender->data_id);\n }",
"function notificar_eliminacion_evento($evt)\n\t{\n\t\t//Chequeo contra identificador y contra id_real\n\t\t$id_real = (isset($evt['evento_id'])) ? $evt['evento_id'] : null;\n\t\t$identificador = $evt['identificador'];\n\n\t\t$columnas = $this->get_entidad()->tabla('columnas')->get_filas(null, false);\n\t\tif (is_array($columnas)) {\n\t\t\tforeach ($columnas as $col) {\n\t\t\t\tif (isset($col['evento_asociado']) && ($col['evento_asociado'] == $identificador || $col['evento_asociado'] == $id_real)) {\n\t\t\t\t\tthrow new toba_error_def(\"No se puede eliminar el evento '$identificador' aún esta asociado a la columna '{$col['clave']}'\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"public function deleteEvent($eid){\n\t\t$this->qrticketsDAO->deleteEvent($eid);\n\t}",
"function ciniki_events_eventDelete(&$ciniki) {\n //\n // Find all the required and optional arguments\n //\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'prepareArgs');\n $rc = ciniki_core_prepareArgs($ciniki, 'no', array(\n 'tnid'=>array('required'=>'yes', 'blank'=>'no', 'name'=>'Tenant'), \n 'event_id'=>array('required'=>'yes', 'default'=>'', 'blank'=>'yes', 'name'=>'Event'), \n ));\n if( $rc['stat'] != 'ok' ) {\n return $rc;\n }\n $args = $rc['args'];\n \n //\n // Check access to tnid as owner\n //\n ciniki_core_loadMethod($ciniki, 'ciniki', 'events', 'private', 'checkAccess');\n $rc = ciniki_events_checkAccess($ciniki, $args['tnid'], 'ciniki.events.eventDelete');\n if( $rc['stat'] != 'ok' ) {\n return $rc;\n }\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, $args['tnid'], array());\n if( $rc['stat'] != 'ok' ) {\n return $rc;\n }\n $tenant_storage_dir = $rc['storage_dir'];\n\n //\n // Get the uuid of the event to be deleted\n //\n $strsql = \"SELECT uuid \"\n . \"FROM ciniki_events \"\n . \"WHERE tnid = '\" . ciniki_core_dbQuote($ciniki, $args['tnid']) . \"' \"\n . \"AND id = '\" . ciniki_core_dbQuote($ciniki, $args['event_id']) . \"' \"\n . \"\";\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'dbHashQuery');\n $rc = ciniki_core_dbHashQuery($ciniki, $strsql, 'ciniki.events', 'event');\n if( $rc['stat'] != 'ok' ) {\n return $rc;\n }\n if( !isset($rc['event']) ) {\n return array('stat'=>'fail', 'err'=>array('code'=>'ciniki.events.7', 'msg'=>'The event does not exist'));\n }\n $event_uuid = $rc['event']['uuid'];\n\n //\n // Start transaction\n //\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'dbTransactionStart');\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'dbTransactionRollback');\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'dbTransactionCommit');\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'dbDelete');\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'objectDelete');\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'dbAddModuleHistory');\n $rc = ciniki_core_dbTransactionStart($ciniki, 'ciniki.events');\n if( $rc['stat'] != 'ok' ) { \n return $rc;\n } \n\n //\n // Remove the images\n //\n $strsql = \"SELECT id, uuid, image_id \"\n . \"FROM ciniki_event_images \"\n . \"WHERE tnid = '\" . ciniki_core_dbQuote($ciniki, $args['tnid']) . \"' \"\n . \"AND event_id = '\" . ciniki_core_dbQuote($ciniki, $args['event_id']) . \"' \"\n . \"\";\n $rc = ciniki_core_dbHashQuery($ciniki, $strsql, 'ciniki.events', 'image');\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc;\n }\n if( isset($rc['rows']) && count($rc['rows']) > 0 ) {\n $images = $rc['rows'];\n \n foreach($images as $iid => $image) {\n $rc = ciniki_core_objectDelete($ciniki, $args['tnid'], 'ciniki.events.image', \n $image['id'], $image['uuid'], 0x04);\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc; \n }\n }\n }\n\n //\n // Remove the files for the event\n //\n $strsql = \"SELECT id, uuid \"\n . \"FROM ciniki_event_files \"\n . \"WHERE tnid = '\" . ciniki_core_dbQuote($ciniki, $args['tnid']) . \"' \"\n . \"AND event_id = '\" . ciniki_core_dbQuote($ciniki, $args['event_id']) . \"' \"\n . \"\";\n $rc = ciniki_core_dbHashQuery($ciniki, $strsql, 'ciniki.events', 'file');\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc;\n }\n if( isset($rc['rows']) && count($rc['rows']) > 0 ) {\n $files = $rc['rows'];\n foreach($files as $fid => $file) {\n //\n // Remove file from disk\n //\n $storage_filename = $tenant_storage_dir . '/ciniki.events/files/' . $file['uuid'][0] . '/' . $file['uuid'];\n if( file_exists($storage_filename) ) {\n unlink($storage_filename);\n }\n\n //\n // Remove the object \n //\n $rc = ciniki_core_objectDelete($ciniki, $args['tnid'], 'ciniki.events.file', \n $file['id'], $file['uuid'], 0x04);\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc; \n }\n }\n }\n\n //\n // Remove the prices\n //\n $strsql = \"SELECT id, uuid \"\n . \"FROM ciniki_event_prices \"\n . \"WHERE tnid = '\" . ciniki_core_dbQuote($ciniki, $args['tnid']) . \"' \"\n . \"AND event_id = '\" . ciniki_core_dbQuote($ciniki, $args['event_id']) . \"' \"\n . \"\";\n $rc = ciniki_core_dbHashQuery($ciniki, $strsql, 'ciniki.events', 'price');\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc;\n }\n if( isset($rc['rows']) && count($rc['rows']) > 0 ) {\n $prices = $rc['rows'];\n foreach($prices as $rid => $price) {\n $rc = ciniki_core_objectDelete($ciniki, $args['tnid'], 'ciniki.events.price', $price['id'], $price['uuid'], 0x04);\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc;\n }\n }\n }\n\n //\n // Remove the registrations\n //\n $strsql = \"SELECT id, uuid \"\n . \"FROM ciniki_event_registrations \"\n . \"WHERE tnid = '\" . ciniki_core_dbQuote($ciniki, $args['tnid']) . \"' \"\n . \"AND event_id = '\" . ciniki_core_dbQuote($ciniki, $args['event_id']) . \"' \"\n . \"\";\n $rc = ciniki_core_dbHashQuery($ciniki, $strsql, 'ciniki.events', 'registration');\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc;\n }\n if( isset($rc['rows']) && count($rc['rows']) > 0 ) {\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'objectDelete');\n $registrations = $rc['rows'];\n foreach($registrations as $rid => $registration) {\n $rc = ciniki_core_objectDelete($ciniki, $args['tnid'], 'ciniki.events.registration',\n $registration['id'],$registration['uuid']);\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc;\n }\n }\n }\n\n //\n // Remove any registration questions for this event\n //\n/* $strsql = \"SELECT id, uuid \"\n . \"FROM ciniki_event_registration_questions \"\n . \"WHERE tnid = '\" . ciniki_core_dbQuote($ciniki, $args['tnid']) . \"' \"\n . \"AND event_id = '\" . ciniki_core_dbQuote($ciniki, $args['event_id']) . \"' \"\n . \"\";\n $rc = ciniki_core_dbHashQuery($ciniki, $strsql, 'ciniki.events', 'question');\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc;\n }\n if( isset($rc['rows']) && count($rc['rows']) > 0 ) {\n $questions = $rc['rows'];\n foreach($questions as $qid => $question) {\n $rc = ciniki_core_objectDelete($ciniki, 'ciniki.events.question', $question['id'], $question['uuid'],\n array('tnid'=>$args['tnid']), 0x04);\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc; \n }\n }\n }\n*/\n\n //\n // Remove any tags\n //\n if( ($ciniki['tenant']['modules']['ciniki.events']['flags']&0x10) > 0 ) {\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'tagsDelete');\n $rc = ciniki_core_tagsDelete($ciniki, 'ciniki.events', 'tag', $args['tnid'],\n 'ciniki_event_tags', 'ciniki_event_history', 'event_id', $args['event_id']);\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc;\n }\n }\n\n //\n // Remove the event from any web collections\n //\n if( isset($ciniki['tenant']['modules']['ciniki.web']) \n && ($ciniki['tenant']['modules']['ciniki.web']['flags']&0x08) == 0x08\n ) {\n ciniki_core_loadMethod($ciniki, 'ciniki', 'web', 'hooks', 'webCollectionDeleteObjRef');\n $rc = ciniki_web_hooks_webCollectionDeleteObjRef($ciniki, $args['tnid'],\n array('object'=>'ciniki.events.event', 'object_id'=>$args['event_id']));\n if( $rc['stat'] != 'ok' ) { \n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc;\n }\n }\n\n //\n // Remove the event\n //\n $rc = ciniki_core_objectDelete($ciniki, $args['tnid'], 'ciniki.events.event', \n $args['event_id'], $event_uuid, 0x04);\n if( $rc['stat'] != 'ok' ) {\n ciniki_core_dbTransactionRollback($ciniki, 'ciniki.events');\n return $rc;\n }\n\n //\n // Commit the transaction\n //\n $rc = ciniki_core_dbTransactionCommit($ciniki, 'ciniki.events');\n if( $rc['stat'] != 'ok' ) {\n return $rc;\n }\n\n //\n // Update the last_change date in the tenant modules\n // Ignore the result, as we don't want to stop user updates if this fails.\n //\n ciniki_core_loadMethod($ciniki, 'ciniki', 'tenants', 'private', 'updateModuleChangeDate');\n ciniki_tenants_updateModuleChangeDate($ciniki, $args['tnid'], 'ciniki', 'events');\n\n //\n // Update the web index if enabled\n //\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'hookExec');\n ciniki_core_hookExec($ciniki, $args['tnid'], 'ciniki', 'web', 'indexObject', array('object'=>'ciniki.events.event', 'object_id'=>$args['event_id']));\n ciniki_core_hookExec($ciniki, $args['tnid'], 'ciniki', 'wng', 'indexObject', array('object'=>'ciniki.events.event', 'object_id'=>$args['event_id']));\n\n return array('stat'=>'ok');\n}",
"function client_delete($event_name, $data) {\n\t\tglobal $app, $conf;\n\n\t\t$app->uses('getconf');\n\t\t$web_config = $app->getconf->get_server_config($conf['server_id'], 'web');\n\n\t\t$client_id = intval($data['old']['client_id']);\n\t\t$client_vhosts = array();\n\t\t$client_vhosts = $app->dbmaster->queryAllRecords('SELECT domain FROM web_domain WHERE sys_userid = '. $client_id .' AND parent_domain_id = 0');\n\n\t\tif (count($client_vhosts) > 0) {\n\t\t\tforeach($client_vhosts as $vhost) {\n\t\t\t\t$data['old']['domain'] = $vhost['domain'];\n\t\t\t\t$this->vhost_helper('delete', $data);\n\n\t\t\t\t$app->log('Removing vhost file: '. $data['old']['domain'], LOGLEVEL_DEBUG);\n\t\t\t}\n\t\t}\n\t}",
"public function deleteUserFromEvent(Request $request)\n {\n /*DB::table('join_event')->where('joinEventID', $request->joinEventID)->update(\n [\n 'status' => 'suspend'\n ]\n );*/\n // Fire an event where join event is open.\n event(new EventOpen($request));\n\n DB::table('join_event')->where('joinEventID', $request->joinEventID)->delete();\n\n $notification = \"You have been removed from the event '$request->title''\";\n\n $notificationID = DB::table('event_notifications')->insertGetId(\n [\n 'poiID' => $request->poiID,\n 'message' => $notification,\n 'notificationType' => 'Removed From Event',\n 'created_at' => date('Y/m/d H:i:s')\n ]\n );\n\n echo $request->joinEventID;\n\n }",
"function eliminar_evento($id) {}",
"public function beforeDelete($event)\n {\n if($fn = $this->owner->{$this->attribute})\n @unlink($this->getFileFullPath($fn));\n }",
"public function action_personDelete(){\r\n\t\tif ( $this->validateEdit() ){\r\n\t\t\t\r\n\t\t\ttry{\r\n\t\t\t\t// 2. usunięcie rekordu\r\n\t\t\t\tgetDB()->delete(\"person\",[\r\n\t\t\t\t\t\"idperson\" => $this->form->id\r\n\t\t\t\t]);\r\n\t\t\t\tgetMessages()->addInfo('Pomyślnie usunięto rekord');\r\n\t\t\t} catch (PDOException $e){\r\n\t\t\t\tgetMessages()->addError('Wystąpił błąd podczas usuwania rekordu');\r\n\t\t\t\tif (getConf()->debug) getMessages()->addError($e->getMessage());\t\t\t\r\n\t\t\t}\t\r\n\t\t}\r\n\t\t\r\n\t\t// 3. Przekierowanie na stronę listy osób\r\n\t\tforwardTo('personList');\t\t\r\n\t}",
"static function deletePerson($dni) {\n // Abro la conexion\n GestionBDD::conectarBDD();\n\n // Preparo la sentencia SQL\n $query = 'DELETE FROM ' . Constants::$PEOPLE . ' WHERE dni = ?';\n $stmt = GestionBDD::$conexion->prepare($query);\n $stmt->bind_param(\"s\", $val1);\n\n // Valores de la sentencia\n $val1 = $dni;\n\n // Ejecuto y cierro la conexion\n $stmt->execute();\n GestionBDD::cerrarBDD();\n }",
"public function delete( $person) {\n \t\n\t\ttry \n\t\t{ \n\t\t \n\t\t\t \n\t\t\t $this->db->StartTrans();\n\t\t\t \n\t\t\t $persona = $this->getInfo($person);\n\t\t\t \t\t \n\t\t $sql=\"DELETE FROM contact_institutions WHERE pins_persona = '$person'\";\n\t\t $this->db->Execute($sql);\t\t\n\t\t $sql = \"DELETE FROM personas WHERE pers_persona='$person'\";\n\t\t\t $this->db->Execute($sql);\n\t\t\t \n\t\t\t $this->db->CompleteTrans();\n\t\t\t \n\t\t\t return array(\"success\"=> true, 'message'=>\"Se ha eliminado de la base de datos a la persona: \\n\\n\".$persona['nombre']);\n\t\t\t\n\t\t}catch(Exception $e){\n\t\t $this->db->RollbackTrans();\n\t\t\t $this->setError($e->getCode(), $e->getMessage());\n\t\t\t throw new Exception( $e->getMessage() , $e->getCode() );\t\n\t\t}\n\t\t\t\t\n }",
"public function destroy(Event $event, Courtesy $courtesy)\n {\n $courtesy->delete();\n session()->flash('message','Tiquet de Cortesía eliminado');\n return redirect(url(\"events/$event->id/courtesy\"));\n }",
"public function onDelete(UserEvent $event)\n {\n }",
"public function delete()\n {\n self::$db->query(\n 'DELETE FROM public.events WHERE eventid = $1',\n [$this->getID()]\n );\n self::$cache->purge();\n }",
"public static function delete(Event $event) {\n $defaults = [\n 'settings_path' => 'docroot/sites/default/settings.generated.php',\n ];\n\n $options = self::extractEnvironmentVariables(array_keys($defaults))\n + self::extractCliOptions($event->getArguments(), array_keys($defaults))\n + $defaults;\n\n $fs = new Filesystem();\n if (!$fs->exists($options['settings_path'])) {\n $event->getIO()->write('Skipping deletion of Drupal settings file - file does not exists');\n }\n else {\n $fs->remove($options['settings_path']);\n $event->getIO()->write(sprintf('Deleted file %s', $options['settings_path']));\n }\n }",
"public function deleteEvent($data){\n\t\t$this->db->where('id', $data['id']);\n\t\t$this->db->update('event', $data);\n\t}",
"public function events_delete(): void\n {\n $response = $this->check_request('Delete event');\n if (!$response) {\n $eventid = input_request('eventid');\n TableEvents::deleteByID($eventid);\n TableParticipants::deleteByEvent($eventid);\n TableRSVPs::deleteByEvent($eventid);\n $this->log_info(\"Delete event $eventid\");\n $response = $this->get_response(false, 'Event deleted');\n }\n exit(json_encode($response));\n }",
"public function onEntityDelete(EntityEvent $event) {\n // $this->projectRepository->delete($event->getEntity()->id());\n }"
] | [
"0.6526318",
"0.6467284",
"0.64272887",
"0.6378604",
"0.6362687",
"0.63410306",
"0.6327261",
"0.62913525",
"0.6266447",
"0.61768234",
"0.6147905",
"0.6147083",
"0.6142165",
"0.61244774",
"0.6092087",
"0.604227",
"0.5999527",
"0.5993338",
"0.5979393",
"0.5959303",
"0.59507316",
"0.59238094",
"0.5914979",
"0.5911701",
"0.5906179",
"0.5891769",
"0.58719414",
"0.5854765",
"0.5851656",
"0.5839944"
] | 0.69996405 | 0 |
retrieve all shapes list | public function getAllShapesApi()
{
$shapes = Shape::orderBy('name')->get();
return $shapes;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getList()\n {\n return $this->createQueryBuilder('Shape')\n ->select('Shape.name, Shape.id')\n ->getQuery()\n ->getArrayResult();\n }",
"public function getAllShapesByProductIdApi($product_id)\n {\n $shapes = DB::table('productshapes')\n ->leftJoin('products', 'products.id', '=', 'productshapes.product_id')\n ->leftJoin('shapes', 'shapes.id', '=', 'productshapes.shape_id')\n ->where('products.id', $product_id)\n ->select(\n 'productshapes.id', 'shapes.name', 'productshapes.multiplier'\n )\n ->get();\n\n return $shapes;\n }",
"public function getRings()\n {\n return $this->getGeometries();\n }",
"private function _random_shape() {\n $rshapes = array();\n // Bounding points that constrain the maximal shape expansion\n $min = new Point(0, 0);\n $max = new Point($this->width, $this->height);\n // Get a start point\n $previous = $startp = new Point(secure_rand($min->x, $max->x), secure_rand($min->y, $max->y));\n // Of how many random geometrical primitives should our random shape consist?\n $ngp = secure_rand(min($this->dsettings['shapeify']['r_num_gp']), max($this->dsettings['shapeify']['r_num_gp']));\n\n foreach (range(0, $ngp) as $j) {\n // Find a random endpoint for geometrical primitves\n // If there are only 4 remaining shapes to add, choose a random point that\n // is closer to the endpoint!\n $rp = new Point(secure_rand($min->x, $max->x), secure_rand($min->y, $max->y));\n if (($ngp - 4) <= $j) {\n $rp = new Point(secure_rand($min->x, $max->x), secure_rand($min->y, $max->y));\n // Make the component closer to the startpoint that is currently wider away\n // This ensures that the component switches over the iterations (most likely).\n $axis = abs($startp->x - $rp->x) > abs($startp->y - $rp->y) ? 'x' : 'y';\n if ($axis === 'x') {\n $rp->x += ($startp->x > $rp->x) ? abs($startp->x - $rp->x) / 4 : abs($startp->x - $rp->x) / -4;\n } else {\n $rp->y += ($startp->y > $rp->y) ? abs($startp->y - $rp->y) / 4 : abs($startp->y - $rp->y) / -4;\n }\n }\n\n if ($j == ($ngp - 1)) { // Close the shape. With a line\n $rshapes[] = array($previous, $startp);\n break;\n } elseif (rand(0, 1) == 1) { // Add a line\n $rshapes[] = array($previous, $rp);\n } else { // Add quadratic bezier curve\n $rshapes[] = array($previous, new Point($previous->x, $rp->y), $rp);\n }\n\n $previous = $rp;\n }\n return $rshapes;\n }",
"public function testDrawAllShapes() {\n\n\n $payload = [\"shapes\" => [[\"type\" => \"circle\", \"params\" => [\"x\" => 1, \"y\" => 2, \"radius\" => 12, \"color\" => \"blue\"]],\n [\"type\" => \"square\", \"params\" => [\"x\" => 5, \"y\" => 6, \"side\" => 5, \"borderSize\" => \"2\"]]]];\n // $payload = json_encode($payload);\n\n\n $this->json('POST', '/api/drawAllShapes', $payload)\n // ->assertStatus(200)\n ->assertJson(\n [\n [\"points\" => [\"X\" => 1, \"Y\" => 2, \"Radius\" => 12], \"attributes\" => [\"color\" => \"blue\", \"borderSize\" => null]],\n [\"points\" => [\"X\" => 5, \"Y\" => 6, \"Side\" => 5], \"attributes\" => [\"color\" => null, \"borderSize\" => 2]]]\n );\n }",
"function getLayersets();",
"public function getShapeByShapeID($shapeID){\n\n }",
"function addShapes(array $shapes){\n\t\t$this->shapes = array_merge($this->shapes, $shapes);\n\t}",
"public function getObjects()\n {\n $objects = array();\n $iterator = new CubeFacesIterator($this->getObjectsIndex());\n foreach ($iterator as $currentTile) {\n foreach ($currentTile as $current) {\n $objects[] = $current;\n }\n }\n\n return $objects;\n }",
"public function getShape()\n {\n return $this->shape;\n }",
"public function all()\n {\n return AnestheticsResource::collection(\n Anesthesia::all()\n );\n }",
"public function allDrawings(): array\n {\n return parent::allDrawings();\n }",
"private function _shapeify($shapearray) {\n $random_shapes = array();\n\n // How many random shapes? \n $ns = secure_rand(min($this->dsettings['shapeify']['r_num_shapes']), max($this->dsettings['shapeify']['r_num_shapes']));\n\n foreach (range(0, $ns) as $i) {\n $random_shapes = array_merge($random_shapes, $this->_random_shape());\n }\n\n return array_merge($shapearray, $random_shapes);\n }",
"public function getObjects()\n {\n $object_ids = $this->getObjectIds();\n\n $objects = array();\n\n foreach ($object_ids as $class => $ids)\n {\n $q = Doctrine::getTable($class)->createQuery('p')->whereIn('p.id', $ids); \n $results = $q->execute();\n foreach ($results as $object) {\n $objects[] = $object;\n }\n }\n\n return $objects;\n }",
"public function all()\n {\n return $this->objects;\n }",
"public function loadShapesInput(): void\n {\n foreach ($this->shapeFiles as $file) {\n $errors = [];\n $json = file_get_contents($file);\n $input = json_decode($json, true);\n if (!empty($json) && $input === null && json_last_error() != JSON_ERROR_NONE) {\n error_log(sprintf( '%s: Error while decoding; %s', __FUNCTION__, json_last_error_msg())); // todo: logger\n $errors[] = json_last_error_msg();\n }\n\n if (is_array($input)) {\n $this->shapeParameters = array_merge($this->shapeParameters, $input);\n\n\n //$input;\n } else {\n $this->shapeParameters[] = $input;\n\n }\n\n\n }\n }",
"abstract protected static function getAllObjects();",
"public function getPolygonList() {\r\n\r\n $resId = $this->request->getData('resid');\r\n $this->autoRender = false;\r\n $this->request->getData('resid');\r\n $coordQuery = $this->Areamaps->find('all', [\r\n 'fields' => [\r\n 'id',\r\n 'mapcoords',\r\n 'colorcode'\r\n ],\r\n 'conditions' => [\r\n 'res_id' => $resId\r\n ],\r\n 'order' => [\r\n 'id' => 'asc'\r\n ]\r\n ])->hydrate(false)->toArray();\r\n $coords = '';\r\n foreach ($coordQuery as $key => $value) {\r\n $coords[] = $value;\r\n }\r\n\r\n echo '{\"rows\":'.json_encode($coords) .'}';\r\n exit();\r\n }",
"public function layers() : Traversable;",
"public function getKernels();",
"public function all() {\n return $this->objs->copy()->all();\n }",
"abstract protected function getObjects(): array;",
"public function getList()\n\t{\n\t\t$st = $this->_getBoundStmt();\n\t\t\n\t\t$r = array();\n\t\twhile( $row = $st->fetch( PDO::FETCH_BOUND ) ) {\n\t\t\t$r[ $this->_d['id'] ] = array(\n\t\t\t\t'id'=>$this->_d['id'],\n\t\t\t\t'x'=>$this->_d['point']['x'],\n\t\t\t\t'y'=>$this->_d['point']['y'],\n\t\t\t\t't'=>$this->_d['time'],\n\t\t\t\t'unit'=>$this->_d['unit'] );\n\t\t}\n\t\t\n\t\treturn $r;\n\t}",
"public function obtenerAreas();",
"public function calculateShape(){\n $count = 0;\n $i;\n $j;\n $n = $this->getSideLength();\n for ($i = 1; $i <= $n; $i++)\n {\n for ($j = 1; $j <= $n; $j++)\n {\n if ($i == 1 || $i == $n ||\n $j == 1 || $j == $n)\n $data[$count]= \"*\";\n else\n\n $data[$count]= \"\\t\\t\";\n $count++;\n }\n $data[$count] = \"\\n\";\n $count++;\n }\n\n return $data;\n }",
"public function getPathList(){\n return $this->_get(2);\n }",
"public function getAll(){\n return Gate::all();\n }",
"public function getAll() {\r\n\r\n return $this->db->get_where('images')->result_array();\r\n }",
"public static function getAll();",
"public function obtenerAllAreas() { \t\n\t\n\t\t$q = Doctrine_Query::create()\n\t\t\t->select(\"a.*\")\n\t \t\t->from(\"Areas a\")\n\t \t->where(\"a.idarea = 17 or a.idarea = 18 or a.idarea = 32 or a.idarea = 33 or a.idarea = 34\");\n\n\t\treturn $q->execute();\n\t}"
] | [
"0.7472698",
"0.6097278",
"0.58248895",
"0.57163805",
"0.56423426",
"0.561937",
"0.5543071",
"0.5498049",
"0.5489521",
"0.5480029",
"0.547735",
"0.54251343",
"0.5304265",
"0.5229744",
"0.5216445",
"0.52030754",
"0.5201178",
"0.5199089",
"0.5184019",
"0.51730883",
"0.51537347",
"0.5090037",
"0.5063796",
"0.50251573",
"0.5021445",
"0.5013613",
"0.50036424",
"0.50025207",
"0.50023836",
"0.49894214"
] | 0.7678652 | 0 |
retrieve all shapes by product id list | public function getAllShapesByProductIdApi($product_id)
{
$shapes = DB::table('productshapes')
->leftJoin('products', 'products.id', '=', 'productshapes.product_id')
->leftJoin('shapes', 'shapes.id', '=', 'productshapes.shape_id')
->where('products.id', $product_id)
->select(
'productshapes.id', 'shapes.name', 'productshapes.multiplier'
)
->get();
return $shapes;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getShapeByShapeID($shapeID){\n\n }",
"public function getAllShapesApi()\n {\n $shapes = Shape::orderBy('name')->get();\n\n return $shapes;\n }",
"public function all($productId)\r\n {\r\n // left join mshop_product_list as mpl on mpl.parentid = mp.id \r\n // left join mshop_media as mm on mm.id = mpl.refid\r\n // left JOIN mshop_price as mpri on mpri.id = mpl.refid\r\n // where mpl.pos = 0 and mpl.domain in ('media','price')\";\r\n $qry = \"select mp.id as product_id, mp.code as product_code, mp.label as product_name, mm.preview as image_url from mshop_product as mp \r\n left join mshop_product_list as mpl on mpl.parentid = mp.id \r\n left join mshop_media as mm on mm.id = mpl.refid\r\n where mpl.pos = 0 and mpl.domain in ('media') and mp.id = \".$productId;\r\n $products = DB::select($qry);\r\n return $products;\r\n }",
"public function getList()\n {\n return $this->createQueryBuilder('Shape')\n ->select('Shape.name, Shape.id')\n ->getQuery()\n ->getArrayResult();\n }",
"public function getProducts($id);",
"public function getProducts($id);",
"function getImageProducts($pos_product_image_id)\n{\n\t\n\t//need a name: brand_name + title + 'in' + color\n\t\n\t$sql = \"SELECT pos_products_sub_id.pos_product_sub_id \n\t\t\tFROM pos_products_sub_id\n\t\t\tLEFT JOIN pos_product_image_lookup ON pos_product_image_lookup.pos_product_sub_id = pos_products_sub_id.pos_product_sub_id\n\t\t\tWHERE pos_product_image_lookup.pos_product_image_id = $pos_product_image_id\";\n\t$data = getSQL($sql);\n\tfor($i=0;$i<sizeof($data);$i++)\n\t{\n\t\t$pos_product_sub_id = $data[$i]['pos_product_sub_id'];\n\t\t$return[$i] = getPinnacleCartValues($pos_product_sub_id);\n\t\t$return[$i]['pos_product_id'] = getProductIdFromProductSubId($pos_product_sub_id);\n\t\t$return[$i]['pos_product_sub_id'] = $pos_product_sub_id;\n\t}\t\n\treturn $return;\n}",
"protected function _getSelectedProducts()\n {\n $collection = Mage::getResourceModel('storefinder/poi_product_collection')\n // which one is better ?\n //->getProductIds(Mage::registry('storefinder_poi_data')->getId());\n ->getProductIds($this->getRequest()->getParam('id'));\n \n foreach ($collection as $product) {\n $products[] = $product->getProductId();\n }\n\n return $products;\n }",
"public function allProduct() {\n $result = $this->connection->query(\n \"SELECT p.ID id, p.name name, p.price price,\n p.description description, f.name flower\n FROM product p INNER JOIN flower f ON (p.id_flower=f.ID)\"\n );\n return $result->fetchAll(PDO::FETCH_OBJ);\n }",
"public function getProduct($id){\n \n $sql = \"SELECT `product`.`id`, `product`.`name`, `product`.`price`, `product`.`discountPercentage`, `product`.`status`, `product`.`productShapeId`, `product`.`productColorId`, `product`.`productType`, `product`.`quantity`, `product`.`description`, `product`.`vendorId`, `product`.`productCategoryId`, `product`.`weight`, `product`.`size`, `product`.`createdAt`, `product`.`updatedAt`, `product`.`enabled`, `product`.`productId`,`productcategory`.`categoryName`,`productcolor`.`colorName`,`productshape`.`shapeName`,`vendor`.`name` AS `vendorName` FROM `product` LEFT JOIN `productcategory` ON `productcategory`.`id` = `product`. `productCategoryId` LEFT JOIN `productcolor` ON `productcolor`.`id` = `product`. `productColorId` LEFT JOIN `productshape` ON `productshape`.`id` = `product`. `productShapeId` LEFT JOIN `vendor` ON `vendor`.`id` = `product`.`vendorId` WHERE 1 AND `product`.`id`='\".$id.\"'\";\n //echo $sql;\n \t$query = $this->db->query($sql);\n \tif ($query->num_rows() > 0) {\n \t$rowRes = $query->row_array();\n /*Get images for products*/\n $sqlImage = \"SELECT * FROM `productimage` WHERE 1 AND `productId` = '\".$rowRes['id'].\"'\";\n $queryImage = $this->db->query($sqlImage);\n $imagesArray = $queryImage->result_array();\n $rowRes[\"imagesArray\"] = $imagesArray;\n return $rowRes; \n \t} else {\n \treturn 0;\n \t\t}\n }",
"public function selectAllProductsOrders($id)\n {\n $id_order = $id;\n $this->db->select('products.id_product , products.product_name , products.reference , products.description , products.base_price , products.img_url , products_orders.quantity_product , colors.color_name , colors.id_color , meanings.id_meaning, meanings.meaning_name, sizes.size_name , sizes.id_size , sizes.price AS size_price');\n $this->db->from($this->table);\n $this->db->join('products', 'products.id_product = products_orders.id_product');\n $this->db->join('orders', 'orders.id_order = products_orders.id_order');\n $this->db->join('colors', 'colors.id_color = products_orders.id_color');\n $this->db->join('sizes', 'sizes.id_size = products_orders.id_size');\n $this->db->join('meanings' ,'meanings.id_meaning = products_orders.id_meaning');\n $this->db->where('orders.id_order', $id_order);\n $query = $this->db->get();\n $query->result_array();\n return $query->result_array();\n\n }",
"public function products($product_ids)\n {\n return $this->select('id', 'name', 'price', 'image')\n ->whereIn('id', $product_ids)\n ->get();\n }",
"public function getProductsByorder($id){\n//\t\t\t\t. \"(SELECT product_id FROM lines_orders WHERE order_id={$id})\";\n\t\n\t\t$sql = \"SELECT pr.*, lp.units FROM products pr \"\n\t\t\t\t. \"INNER JOIN lines_orders lp ON pr.id = lp.product_id \"\n\t\t\t\t. \"WHERE lp.order_id={$id}\";\n\t\t\t\t\n\t\t$products = $this->db->query($sql);\n\t\t\t\n\t\treturn $products;\n\t}",
"public function getShapeByTripID($tripID){\n\n }",
"public function getShapeByRouteID($routeID){}",
"public function allProductImages()\n {\n $id = \\Request::get('id');\n return ['productImagesForEditMode' => Product_images::select('image_name')->where('products_id', $id)->get()];\n \n }",
"function dameproductos($id){\n $sql=\"select p.nombre, p.precio,p.imagen, lp.unidades from productos p inner join lineas_pedidos lp on p.id=lp.producto_id where pedido_id=$id\";\n \n \n $td=$this->db->query($sql);\n \n $fer= $td;\n return $fer;\n }",
"function getExistingSizes($id){\n return $this->find('list', array(\n 'fields' => array(\n 'Detail.size_id'\n ),\n 'conditions' => array(\n 'Detail.product_entity_id' => $id\n )\n ));\n }",
"public static function getAllProducts() {\n $db = Database::getDB();\n\n try {\n \n $query = 'SELECT * FROM products p \n INNER JOIN categories c ON p.productCategory = c.categoryID \n INNER JOIN brands b ON p.productBrand = b.brandID \n INNER JOIN clothing g ON p.productClothing = g.clothingID \n \n ORDER BY productID';\n $statement = $db->prepare($query);\n $statement->execute();\n $products = $statement->fetchAll();\n $statement->closeCursor();\n \n return $products;\n\n } catch (PDOException $e) {\n $error_message = $e->getMessage();\n // display_db_error($error_message);\n }\n}",
"function getByProductID($product_id) {\n return $this->find('all', array(\n 'conditions' => array(\n 'Image.product_entity_id' => $product_id,\n )\n ));\n }",
"public function action_get_product_relate()\n {\n $product_id = (int) Arr::get($_GET, 'product_id', 0);\n if($product_id)\n {\n $product_relate = DB::select('relate')\n ->from('ga_product_relate')\n ->where('product_id', '=', $product_id)\n ->where('relate_count', '>', 28)\n ->execute()->get('relate');\n echo $product_relate;\n }\n exit;\n }",
"public function getAllProduct()\n {\n return Product::with('images','type')->orderBy('id', 'desc')->paginate(Product::ITEMS_PER_PAGE);\n }",
"function getSizeByProductID($id){\n return $this->find('all', array(\n 'fields' => array(\n 'Detail.id, Detail.size_id, Detail.stock,Detail.show, Size.name' \n ),\n 'joins' => array(\n array(\n 'table' => 'sizes',\n 'alias' => 'Size',\n 'type' => 'INNER',\n 'conditions' => array(\n 'Detail.size_id = Size.id'\n )\n )\n ),\n 'conditions' => array('Detail.product_entity_id' => $id)\n ));\n }",
"public function confiSimpleProductIds(){\r\n\t\t \t\t$assoc_productIds = array();\r\n\t\t\t\t$collection = Mage::getResourceModel('catalog/product_collection')-> addFieldToFilter('type_id', array('configurable'));\r\n\t\t\t\tforeach($collection->getAllIds() as $key => $pId){\r\n\t\t\t\t\t$product = Mage::getModel('catalog/product')->load($pId);\r\n\t\t\t\t\t$associated_prods = $product->getTypeInstance()->getUsedProducts();\r\n\t\t\t\t\tforeach ($associated_prods as $assoc_product) {\r\n\t\t\t\t\t\t\t$assoc_products[] = $assoc_product;\r\n\t\t\t\t\t\t\t$assoc_productIds[] = $assoc_product->getId();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\treturn $assoc_productIds;\r\n\t\t }",
"public function getShops($product_id){\n\n // 1. show have a bridge table like shop_product get all shop ids for products\n // 2. pick all shops in an array\n\n $valid_dates = [\"12/10\", \"11/25\"];\n $fake_shops = [\n [\n \"shop_id\"=>\"1\",\n \"name\"=> \"天府川菜馆 South Yarra旗舰店\",\n \"distance\"=> \"393米\",\n \"address\"=>\"176 Toorak Road, South Yarra,VIC 3141\",\n \"phone\"=>\"03-9078 1686\",\n \"image_url\"=> \"/groupbuy/public/images/shop_1.png\",\n \"valid_date\"=> $valid_dates\n ],\n [\n \"shop_id\"=>\"2\",\n \"name\"=> \"天府川菜馆 Glen Waverley分店\",\n \"distance\"=> \"393米\",\n \"address\"=>\"25 Railway Parade North, Glen Waverley, VIC 3150\",\n \"phone\"=>\"03-9887 8686\",\n \"image_url\"=> \"/groupbuy/public/images/shop_2.png\",\n \"valid_date\"=> $valid_dates\n ],\n [\n \"shop_id\"=>\"3\",\n \"name\"=> \"天府精品火锅 Box Hill分店\",\n \"distance\"=> \"393米\",\n \"address\"=>\"Level 1, 2A Cambridge Street, Box Hill, VIC 3128\",\n \"phone\"=>\"03-9041 4318\",\n \"image_url\"=> \"/groupbuy/public/images/shop_3.png\",\n \"valid_date\"=> $valid_dates\n ],\n [\n \"shop_id\"=>\"4\",\n \"name\"=> \"天府川菜馆 South Yarra旗舰店\",\n \"distance\"=> \"393米\",\n \"address\"=>\"149 Lonsdale Street, Melbourne, VIC 3000\",\n \"phone\"=>\"03-9662 2019\",\n \"image_url\"=> \"/groupbuy/public/images/shop_4.png\",\n \"valid_date\"=> $valid_dates\n ]\n ];\n //create container\n $shops = array();\n // shop_id hasMany({product_id,product_sold})\n $fake_shop_product_table = [\n \"1\"=>[[\"1\",222],[\"2\",222],[\"3\",222]],\n \"2\"=>[[\"2\",333],[\"3\",333],[\"4\",333]],\n \"3\"=>[[\"3\",444],[\"4\",444],[\"5\",444]],\n \"4\"=>[[\"4\",555],[\"5\",555],[\"6\",555]]\n ];\n foreach ($fake_shop_product_table as $key => $value) { //[\"product_id\",\"sold in this shop\"]\n foreach ($value as $item) {\n if($item[0]==$product_id){ // if product_id match\n foreach($fake_shops as $shop){ // found shop\n if($shop[\"shop_id\"]==$key)\n {\n $shop[\"sold\"]=$item[1]; // add one property to shop obj\n array_push($shops,$shop);\n }\n }\n\n }\n }\n\n }\n\n return response()->json($shops,200);\n\n }",
"public function getProducts(){\n if($this->get_request_method() != \"GET\"){\n $this->response('',406);\n }\n\n $query=\"SELECT p.id, p.nombre, p.descripcion, p.precio, c.nombre AS categoria, c.id as catId FROM producto p JOIN categoria c on p.categoria = c.id\";\n\n $this->db->get($query);\n }",
"public function getAllProduct()\n {\n $query = $this->createQueryBuilder('p')\n ->orderBy('p.id','DESC')\n ->getQuery();\n \n return $query->getResult();\n }",
"public function getProductBoxes( $productId ){\r\n\t\t//Lógica para retorno de um dado BoxProduct\r\n\t\t\r\n\t\ttry{\r\n\t\t\t\r\n\t\t\t//Busca lista de caixas\r\n\t\t\t$boxList = BoxProductModel::select( 'idBox' ,'howMuchFit' )\r\n\t\t\t\t->where('idProduct', $productId )\r\n\t\t\t\t->get();\r\n\t\t\t\r\n\t\t\t//Verifica se existem caixas para o produto\r\n\t\t\tif( !( count( $boxList ) > 0 ) )\r\n\t\t\t\treturn response()->json( \r\n\t\t\t\t\t[ \"message\"=> \"Caixa não encontrada.\" ], \r\n\t\t\t\t\tResponse::HTTP_NOT_FOUND \r\n\t\t\t\t);\r\n\t\t\t\r\n\t\t\t//Retorna lista de caixas\r\n\t\t\treturn response()->json(\r\n\t\t\t\r\n\t\t\t\t$boxList, \r\n\t\t\t\tResponse::HTTP_OK \r\n\t\t\t\r\n\t\t\t);\r\n\t\t\t\r\n\t\t\r\n\t\t}catch( QueryException $exception ){\r\n\t\t\t\r\n\t\t\t//Trata QueryException\r\n\t\t\treturn response()->json( \r\n\t\t\t\t\r\n\t\t\t\t[ 'message' => \"Erro de conexão com banco de dados.\" ], \r\n\t\t\t\tResponse::HTTP_INTERNAL_SERVER_ERROR \r\n\t\t\t\r\n\t\t\t);\r\n\t\t\r\n\t\t}\r\n\t\t\r\n\t}",
"public static function imagesForProduct($product) {\n return self::findEntities(\\obo\\Carriers\\QueryCarrier::instance()->where(\"AND [product] = %i\", $product));\n //return self::findEntities(new \\obo\\Carriers\\QueryCarrier(), $paginator, $filter);\n }",
"public function showProduct($id)\n { \n return Product::with('images','type')->find($id);\n }"
] | [
"0.66325384",
"0.6612602",
"0.6500685",
"0.6430264",
"0.61663485",
"0.61663485",
"0.60614985",
"0.58898425",
"0.58476204",
"0.58365804",
"0.5805844",
"0.5802184",
"0.5801481",
"0.57853067",
"0.57778543",
"0.5755044",
"0.57423806",
"0.5701795",
"0.5696526",
"0.5687471",
"0.56861955",
"0.56751627",
"0.5668804",
"0.5664964",
"0.5642864",
"0.5638745",
"0.56113505",
"0.56000614",
"0.5550758",
"0.5550643"
] | 0.8180801 | 0 |
update product shape by given id | public function updateProductShapeByIdApi($id)
{
$model = Productshape::findOrFail($id);
$multiplier = request('multiplier');
$model->multiplier = $multiplier;
$model->save();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function updateProduct($id)\r\n {\r\n }",
"public function update(Request $request, $id)\n {\n $product = Product::with('Images', 'Categories', 'Colors','Sizes')->find($id);\n $product->update($request->all());\n // $array_size = explode(',', $request->size); \n // $array_color = explode(',', $request->color);\n \n \n // foreach ($product->sizes as $key) {\n // foreach ($array_size as $size){\n // $update_size = Size::UpdateOrCreate([\n // 'product_id' => $product->id,\n // 'size' => $size\n // ]);\n // \\Log::info($size);\n // $update_size->update(['size' => $size]);\n // }\n // }\n // $update_size = Size::where('product_id', $id);\n // $update_size->update([ 'size' => $size ]);\n \n // foreach ($array_color as $color) {\n // $update_color = Color::where('product_id', $id);\n // $update_color->update(['color' => $color]);\n // }\n \n // foreach ($request->photos as $photo) {\n // $photo_name = time().'-product-'.$photo->getClientOriginalName();\n // $photo->move(public_path('fashe-colorlib/images/product/'), $photo_name);\n // $store_photo = Image::create([\n // 'product_id' => $product->id,\n // 'image' => $photo_name\n // ]);\n\n // }\n \\Session::flash('success', 'Produk Berhasil diupdate!');\n return redirect()->route('admin.product');\n }",
"function updateProductPart($data, $id)\n {\n }",
"public function update(Request $request, $id)\n {\n\n $this->validate($request, [\n 'name_ar' => 'required',\n 'name_en' => 'required',\n 'description_ar' => 'required|min:30' ,\n 'description_en' => 'required' ,\n 'price' => 'required' ,\n 'parent_id' => 'required|integer' ,\n 'product_owner_id' => 'required' ,\n 'min_quantity' => 'required|integer' ,\n 'image'=>'bail|image|mimes:jpg,jpeg,png,gif' ,\n ]);\n\n if(isset($request->sub_id)){\n $this->validate($request, [\n 'sub_id' => 'required|integer',\n ]);\n }\n\n if(isset($request->sub_sub_section_id)){\n $this->validate($request, [\n 'sub_id' => 'required|integer',\n 'sub_sub_id' => 'required|integer',\n ]);\n }\n\n $product = Product::find($id) ;\n\n $product->name_ar = $request->name_ar;\n $product->name_en = $request->name_en;\n $product->description_ar = $request->description_ar ;\n $product->description_en = $request->description_en ;\n $product->keywords_ar = $request->keywords_ar ;\n $product->keywords_en = $request->keywords_en ;\n $product->brand_id = $request->brand_id ;\n $product->section_id = $request->parent_id ;\n $product->sub_section_id =(isset($request->sub_id ) ) ? $request->sub_id: 0;\n $product->sub_sub_section_id = (isset($request->sub_sub_id ) ) ? $request->sub_sub_id: 0 ;\n $product->product_owner_id = $request->product_owner_id ;\n $product->price = $request->price ;\n $product->weight = (isset($request->weight ) ) ? $request->weight: 1 ;\n $product->min_price = $request->min_price ;\n $product->quantity = $request->quantity ;\n $product->min_quantity = $request->min_quantity ;\n $product->max_quantity = $request->max_quantity ;\n $product->active = $request->active ;\n $product->featured = $request->featured ;\n $product->manfacture_country = (isset($request->manfacture_country ) ) ? $request->manfacture_country : 0;\n $product->measurements_unit_id = (isset($request->measurements_unit_id ) ) ? $request->measurements_unit_id : 0;\n\n //upload one image\n if(!empty($request->file('image'))){\n $image = Storage::putFile('public', $request->file('image'));\n $product->image = Storage::url($image);\n }\n\n //uploaded many image\n $files = $request->file('images');\n if(!empty($request->hasFile('images')))\n {\n $files_list = array();\n foreach ($files as $key=>$file) {\n if($key == 5 ) { break ; }\n\n $photo = Storage::putFile('public' , $file);\n $original = Storage::url($photo);\n array_push($files_list,$original);\n\n }\n $product->images = implode(\",\",$files_list);\n }\n\n //save colors\n if(!empty($request->colors))\n {\n $colors = array();\n foreach ($request->colors as $color) {\n\n array_push($colors , $color);\n\n }\n $product->color_id = implode(\",\",$colors );\n }\n\n //save sizes\n if(!empty($request->sizes))\n {\n $sizes = array();\n foreach ($request->sizes as $size) {\n\n array_push($sizes , $size);\n\n }\n $product->size_id = implode(\",\",$sizes );\n }\n\n //option arabic\n if(!empty($request->details_ar) || $request->details_ar != null )\n {\n $details_ar = array();\n foreach ($request->details_ar as $detail_ar) {\n if(isset($detail_ar)){\n array_push($details_ar , $detail_ar);\n }\n }\n $product->details_ar = implode(\",\",$details_ar );\n }else{\n $product->details_ar = null ;\n }\n //option english\n if(!empty($request->details_en) || isset($request->details_en))\n {\n $details_en = array();\n foreach ($request->details_en as $detail_en) {\n if(isset($detail_en) || $detail_en != \" \" ){\n array_push($details_en , $detail_en);\n }\n }\n $product->details_en = implode(\",\",$details_en );\n }else{\n $product->details_en = null ;\n }\n\n\n $product->save();\n\n $request->session()->flash('alert-success', __('admin.alerts_success_editing'));\n return back();\n }",
"public function update(Request $request, $id) \n {\n \t$product = array();\n $product[\"product\"] = array();\n $product[\"product\"] = $request->product;\n\n $sizes = $request->sizes?$request->sizes:'';\n $colors = $request->colors?$request->colors:'';\n $materials = $request->materials?$request->materials:'';\n\n if(!empty($sizes)) $product[\"product\"][\"options\"][] = array(\"name\" => $request->size);\n if(!empty($colors)) $product[\"product\"][\"options\"][] = array(\"name\" => $request->color);\n if(!empty($materials)) $product[\"product\"][\"options\"][] = array(\"name\" => $request->material);\n\n if ($request->hasFile('image')) {\n $photo = $request->file('image');\n $filename = $product[\"product\"][\"title\"].'.'.$photo->getClientOriginalExtension();\n // $filesize = $photo->getClientSize();\n $path = public_path().'/upload/img';\n\n $photo->move($path, $filename);\n $dir=$path.'/'.$filename;\n \t$url_image = env('APP_URL').'/upload/img/'.$filename;\n\n if(file_exists($dir)) {\n $imagick = new Imagick($dir);\n\t\t\t\t$imagick->setCompressionQuality(20);\n\t\t\t\t$imagick->setImageDepth(8);\n\t\t\t\t$imagick->despeckleimage();\n\t\t $imagick->writeImage($dir);\n }\n\n\t\t\t$img_src = array(\"src\" => $url_image);\n $product[\"product\"][\"image\"] = $img_src;\n if(!empty($product[\"product\"][\"images\"])) {\n\t\t array_unshift($product[\"product\"][\"images\"], $img_src);\n }else{\n $product[\"product\"][\"images\"] = array($img_src);\n }\n\n } else {\n\t\t\t\n\t\t\t$img_id = array(\"id\" => $request->image_id);\n $product[\"product\"][\"image\"] = $img_id;\n if(!empty($product[\"product\"][\"images\"])) {\n array_unshift($product[\"product\"][\"images\"], $img_id);\n }else{\n $product[\"product\"][\"images\"] = $img_id;\n }\n }\n\n if($product) {\n\n $notification = array(\n 'message' => 'Product was successfully updated', \n 'alert-type' => 'success'\n );\n\n \t$product_id = $request->product[\"id\"];\n $product_url = \"/admin/products/$product_id.json\";\n $res = $this->sendRequest($product, $product_url, \"PUT\");\n if(!$res) {\n $notification = array(\n 'message' => 'Update fail!', \n 'alert-type' => 'error'\n );\n\n return redirect('/')->with($notification);\n }\n\n }\n\n return redirect('/')->with($notification);\n }",
"public function updateProduct(Request $request, $id)\n {\n $path = \"/product_images/\";\n $product = Products::find($id);\n //main_picture\n if ($request->hasFile('image')) {\n //get filename with extension\n $filenamewithextension = $request->file('image')->getClientOriginalName();\n //get filename without extension\n $filename = pathinfo($filenamewithextension, PATHINFO_FILENAME);\n //get file extension\n $extension = $request->file('image')->getClientOriginalExtension();\n\n $smallthumbnail = $filename.'_small_'.time().'.'.$extension;\n //Upload File\n $request->file('image')->storeAs('public/product_images/', $smallthumbnail);\n //create small thumbnail\n $smallthumbnailpath = public_path('storage/product_images/'.$smallthumbnail);\n $this->imageServices->createThumbnail($smallthumbnailpath, 250, 300);\n\n if (!empty($product->image)) {\n unlink(public_path('storage' . $product->image));\n }\n $product->image = $path.$smallthumbnail;\n }\n $product->name = $request->name;\n $product->category_id = $request->category_id;\n $product->artist_id = $request->artist_id;\n $product->description = $request->description;\n $product->short_description = $request->short_description;\n $product->start_time = $request->start_time ? $request->start_time : null;\n $product->end_time = $request->end_time ? $request->end_time : null;\n $product->release_year = $request->release_year;\n $product->price = $request->price;\n $product->save();\n }",
"public function update(Request $request, $id)\n {\n // dd($request->product['name']);\n\n $editedProduct = $request->product;\n $sizes = $request->sizes;\n dd('sizes', $sizes);\n\n // $product = Product::where('id', $id)->get();\n $product = Product::find($id);\n dd($product->name);\n\n $product->name = $editedProduct['name'];\n $product->type = $editedProduct['type'];\n $product->price = $editedProduct['price'];\n $product->gender = $editedProduct['gender'];\n $product->brand = $editedProduct['brand'];\n $product->name = $editedProduct['name'];\n\n\n /*\n \"image1\" => \"/img/products/Nike-Air-Max-Plus-Yellow.png\"\n \"image2\" => null\n \"image3\" => null\n \"image4\" => null\n \"image5\" => null\n\n */\n }",
"public function update(Request $request, $id)\n {\n $data = array();\n $data['category_id'] = $request->category_id;\n $data['supplier_id'] = $request->supplier_id;\n $data['product_name'] = $request->product_name;\n $data['product_code'] = $request->product_code;\n $data['buying_date'] = $request->buying_date;\n $data['product_quantity'] = $request->product_quantity;\n $data['root'] = $request->root;\n $data['buying_price'] = $request->buying_price;\n $data['selling_price'] = $request->selling_price;\n $data['image'] = $request->image;\n $image = $request->new_image;\n if ($image) {\n $position = strpos($image, ';');\n $sub = substr($image, 0, $position);\n $ext = explode('/', $sub)[1];\n $name = time() . '.' . $ext;\n $img = Image::make($image)->resize(240, 200);\n $upload_path = 'uploads/backend/product/';\n $image_url = $upload_path . $name;\n $success = $img->save($image_url);\n if ($success) {\n $data['image'] = $image_url;\n $img = DB::table('products')->where('id', $id)->first();\n $image_path = $img->image;\n $done = unlink($image_path);\n $user = DB::table('products')->where('id', $id)->update($data);\n }\n } else {\n $data['image'] = $request->image;\n $user = DB::table('products')->where('id', $id)->update($data);\n }\n }",
"public function update(ProductUpdateRequest $request, $id)\n {\n if (!$request->ajax()) return redirect('/');\n try {\n $product = Product::findOrFail($request->product_id);\n DB::beginTransaction();\n //Insertar valores de negocio\n\n $product->category_id = $request->category_id;\n $product->name = $request->name;\n $product->slug = $request->slug;\n $product->descripcion = $request->descripcion;\n $product->stock = $request->stock;\n $product->file = $request->file;\n $product->presentacion = $request->presentacion;\n $product->precio_venta = $request->precio_venta;\n $product->condition = $request->condition;\n $product->save();\n if ($request->file('image')) {\n $path = Storage::disk('public')->put('image', $request->file('image'));\n $product->fill(['file' => asset($path)])->save();\n }\n DB::commit();\n } catch (Exception $e) {\n DB::rollBack();\n }\n }",
"public function update(Request $request, $id)\n {\n \n $product = Property::where('id',$id);\n \n $property_name = $request->property_name;\n \n //get client name \n $img = $request->file('image')->getClientOriginalName();\n \n // store image\n $request->file('image')->storeAs('public/images', $img);\n\n\n\n \n \n //update remaining properties \n $productUpdate = $product->update([\n \n 'property_name'=> $property_name,\n 'description'=> $request->description,\n 'property_slug'=> str_slug($property_name, '-'),\n 'price' => $request->price,\n 'location' => $request->location,\n 'image'=>'/public/images/'.$img\n \n ]);\n \n \n if($productUpdate){\n return response()->json('successfully updated property');\n\n }else{\n return response()->json('an error occured ,try again');\n \n }\n \n }",
"public function update(Request $request, $id)\n {\n $product = Products::find($id);\n\n $this->validate($request,[\n 'name'=>'required|max:255',\n //'slug'=>\"required|alpha_dash|min:5|max:255|unique:products,slug,$id\",//unique(table,column,except除了自己以外)!!!外圍一定要用雙引號才有辦法把變數$id放進來!!!\n 'short'=>'required',\n 'category_id'=>'required|integer',\n // 'format'=>'required|max:255',\n 'price'=>'required|integer',\n 'bonus'=>'required|integer',\n 'image'=>'sometimes|image',\n // 'content'->'required'\n ]);\n\n $product->name=$request->input('name');\n $product->discription=$request->input('discription');\n $product->short = $request->input('short');\n $product->erp_id = $request->input('erp_id');\n $product->category_id=$request->input('category_id');\n $product->format=$request->input('format');\n $product->price=$request->input('price');\n $product->bonus=$request->input('bonus');\n $product->content=$request->input('content');\n\n if($request->hasFile('image')){\n //image stuff\n $image = $request->file('image'); //先把檔案存到 $image 變數\n $filename = time() . '.' . $image->getClientOriginalExtension(); //取得檔案完整原檔名再加上 時間在前面\n $location = public_path('images/productsIMG/' . $filename);//把圖片url存到$location變數裡面\n Image::make($image)->resize(600,600)->save($location);//把圖面resize之後存進路徑\n\n $oldFilename = $product->image;//原來的圖片存進oldFilename變數\n\n $product->image = $filename;//存進資料庫語法跟其他欄位一樣只是放進來是$filename變數\n\n Storage::delete('productsIMG/' . $oldFilename);\n }\n\n $product->save();\n\n $carrier_id_array = [];\n if($request->has('carrier_id')){\n $carrier_id_array = $request->carrier_id;\n }\n $product->updateCarrierRestriction($carrier_id_array);\n \n if($request->has('previous_url')){\n return redirect($request->previous_url);\n }\n return redirect()->route('products.index');\n\n\n }",
"public function update(Request $request,$id)\n {\n $product = Product::find($id);\n if ($request->updateimage) {\n $position = strpos($request->updateimage, ';');\n $sub=substr($request->updateimage, 0 ,$position);\n $ext=explode('/', $sub)[1];\n $name=time().\".\".$ext;\n $img=Image::make($request->updateimage)->resize(240,200);\n $upload_path='product/';\n $image_url=$upload_path.$name;\n $img->save($image_url);\n $product->image = $image_url;\n }\n $product->title = $request->title;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->save();\n return response()->json($product);\n\n }",
"public function update(StoreProductRequest $request, $id)\n {\n if ($request->hasFile('images')){\n $file = $request->file('images');\n $name_img = $file->getClientOriginalName();\n $path = $file->move('products', $name_img);\n }else{\n dd('k co file');\n }\n\n $name = $request->get('name');\n $slug = \\Illuminate\\Support\\Str::slug($request->get('name'));\n $category_id = $request->get('category_id');\n $origin_price = $request->get('origin_price');\n $sale_price = $request->get('sale_price');\n $content = $request->get('content');\n $status = $request->get('status');\n $description = $request->get('description');\n $image = $path;\n \n \n\n $product = Product::find($id);\n $product->name = $name;\n $product->slug = $slug;\n $product->category_id = $category_id;\n $product->origin_price = $origin_price;\n $product->sale_price = $sale_price;\n $product->content = $content;\n $product->status = $status;\n $product->description = $description;\n \n $product->image = $image;\n\n $product->save();\n\n return redirect()->route('backend.product.index');\n }",
"public function update(Request $request, $id)\n {\n $this->product = $this->product->with('images')->find($id);\n if(!$this->product){\n request()->session()->flash('error','Product does not exists');\n return redirect()->route('product.index');\n }\n\n $rules = $this->product->getRules();\n $request->validate($rules);\n\n $data = $request->except('image');\n\n $this->product->fill($data);\n $status = $this->product->save();\n\n if($status){\n\n if($request->image){\n foreach ($request->image as $image_file){\n $image_name = uploadImage($image_file,'product','200x200');\n if($image_name){\n $temp_data = array(\n 'product_id' => $this->product->id,\n 'image_name' => $image_name\n );\n $product_image = new ProductImage();\n $product_image->fill($temp_data);\n $product_image->save();\n }\n }\n }\n\n if(isset($request->del_image) && !empty($request->del_image)){\n foreach ($request->del_image as $del_image_info){\n $prod_img = new ProductImage();\n $prod_img = $prod_img->where('image_name', $del_image_info)->first();\n $del = $prod_img->delete();\n if($del){\n deleteImage($del_image_info, 'product');\n }\n\n }\n }\n\n $request->session()->flash('success','Product added successfully.');\n }else{\n $request->session()->flash('error','Problem while adding product.');\n }\n return redirect()->route('product.index');\n }",
"public function update(ProductRequest $request, $id)\n {\n $product = Product::findOrFail($id);\n\n $data = $request->all();\n \n $data['is_featured'] = isset($request['is_featured']) ? 1 : 0;\n $data['pool'] = isset($request['pool']) ? 1 : 0;\n $data['barbecue'] = isset($request['barbecue']) ? 1 : 0;\n $data['soccer'] = isset($request['soccer']) ? 1 : 0;\n $data['air_conditioning'] = isset($request['air_conditioning']) ? 1 : 0;\n $data['wifi'] = isset($request['wifi']) ? 1 : 0;\n\n $size = $request->input('size');\n\n if ($size) {\n $data['size'] = implode(',', $size);\n } else {\n $data['size'] = '';\n }\n\n if ($request->hasFile('photo')) {\n $image = $request->file('photo');\n $filename = time() . '.' . $image->getClientOriginalExtension();\n $location = public_path('frontend/products/' . $filename);\n \\Image::make($image)->resize(2250, 1500)->save($location);\n if ($product->photo != null) {\n Storage::delete($product->photo);\n unlink(public_path('frontend/products/' . $product->photo));\n }\n $data['photo'] = $filename;\n }\n\n $status = $product->fill($data)->save();\n \n if ($status) {\n request()->session()->flash('success', 'Produto atualizado com sucesso!');\n } else {\n request()->session()->flash('error', 'Ocorreu um erro ao atualizar o produto. Por favor, tente novamente.');\n }\n return redirect()->route('products.index');\n }",
"public function update(Request $request, $id)\n {\n\n $validatedData = $request->validate([\n 'product_name' => ['required', 'string', 'max:255'],\n 'category_id' => ['required'],\n 'root' => ['required', 'string'],\n 'selling_price' => ['required'],\n 'product_quantity' => ['required'],\n \n ]);\n\n $product = Product::find($id);\n\n if ($request->image != $product->image) { //database image and edited image if didn't match new image insert and old image unlink\n\n $strpos = strpos($request->image, ';'); //get string position\n $sub = substr($request->image, 0, $strpos); // cut string 0 to ';' position\n $ex = explode('/', $sub)[1]; //explode from '/'\n $name = time().'.'.$ex; //time() gives a name and ex get a extension and then join here\n $location = ('backend/images/product/'.$name); // which location we want to save\n $img = Image::make($request->image)->resize(240,200); //make image\n $img->save($location); //save to location\n\n $image_path = public_path($product->image);\n if (file_exists($image_path)) {\n @unlink($image_path);\n }\n\n }else{\n\n $location = $product->image;\n }\n\n \n $product->product_name = $request->product_name;\n $product->category_id = $request->category_id;\n $product->supplier_id = $request->supplier_id;\n $product->product_code = $request->product_code;\n $product->root = $request->root;\n $product->buying_price = $request->buying_price;\n $product->selling_price = $request->selling_price;\n $product->buying_date = $request->buying_date;\n $product->product_quantity = $request->product_quantity;\n $product->image = $location;\n $product->save();\n\n }",
"public function update(ProductRequest $request, $id)\n {\n\n try {\n $product = Product::findOrFail($id);\n $product->update([\n 'name' => $request['name'],\n 'sku' => $request['sku'],\n 'description' => $request['description'],\n 'category_id' => $request['category_id'],\n 'stock' => $request['stock'],\n 'status' => $request['status'],\n 'sale_price' => $request['sale_price'],\n 'principal_image' => $request['principal_image']\n ]);\n\n ProductImage::where('product_id', $id)->delete();\n foreach ($request->gallery as $item) {\n ProductImage::create(\n [\n 'product_id' => $product->id,\n 'image_id' => $item['key']\n ]\n );\n }\n return response()->json(['msg' => 'El registro se ha editado correctamente.',]);\n } catch (\\Exception $ex) {\n return response('No se pudo editar, intente mas tarde', 400)\n ->header('Content-Type', 'text/plain');\n }\n\n }",
"public function update(productRequest $request, $id)\n {\n\n if($request->hasFile('img')) {\n\n $image = $request->file('img');\n $filename = $image->getClientOriginalName();\n\n $image_resize = Image::make($image->getRealPath());\n $image_resize->resize(300, 300);\n $image_resize->save(public_path('images/' . $filename));\n $uploadimage = $filename;\n }\n\n $pid = Product::findOrFail($id);\n $pid->pname = $request->pname;\n $pid->description = $request->description;\n $pid->price = $request->price;\n $pid->discount = $request->discount;\n $pid->discount_price = $request->discount_price;\n $pid->img = $uploadimage;\n $pid->save();\n $pid->categories()->sync($request->category);\n\n return redirect(route('admin.product.index'))->with('message','Data updated Sucessfully');\n }",
"public function update_product($data,$id){\n $this->db->where('id', $id);\n $this->db->update('product', $data);\n \n }",
"public function update (Request $request, $id)\n {\n// $product = Product::find($id);\n//\n// $product->name='foo';\n//\n// $product->save();\n }",
"public function update(Request $request, $id)\n {\n $product=Box::find($id);\n $product->name= $request->input('name');\n $product->details= $request->input('detail');\n $product->description= $request->input('description');\n $product->price= $request->input('price');\n $product->slug= $request->input('slug');\n $product->weight= $request->input('weight');\n\n if($request->hasFile('product_image')){\n $image=$request->file('product_image');\n $filename=time().'.'.$image->getClientOriginalExtension();\n $location=public_path('images/products/'.$filename);\n Image::make($image)->resize(800,400)->save($location);\n $product->image=$filename;\n }\n\n $product->save();\n\n return redirect('/admin/box')->with('success','Box Updated Successfully');\n }",
"public function update(UpdateProductRequest $request, $id)\n {\n $product = Product::find($id);\n \n\n $thumb = ('images/products/thumb');\n $full = ('images/products/full');\n\n $product->update($request->except('image'));\n\n $pro_id = $product->id;\n $product->save();\n if ($request->hasFile('image')) {\n $images = $request->file('image');\n db::table('product_img')\n ->where('id_product', $id)\n ->delete();\n db::table('transactions') \n ->where('product_id', $id)\n ->delete();\n foreach ($images as $image) {\n $name = str_random(5) . '.' . $image->getClientOriginalExtension();\n $img = new Gambar();\n $img->img_name = $name;\n $img->id_product = $pro_id;\n $img->path_thumb = 'images/products/thumb/' . $name;\n $img->path_full = 'images/products/full/' . $name;\n $img->save();\n Image::make($image)->save($full . '/' . $name);\n Image::make($image)->resize('100', '100')->save($thumb . '/' . $name);\n }\n \n }\n\n\n Session::flash(\"flash_notification\", [\n \"level\"=>\"success\",\n \"message\"=>\"Berhasil menyimpan $product->name\"\n ]);\n return redirect()->route('admin.products.index');\n }",
"public function update(Request $request, $id)\n {\n $Product_Attributes_Assoc = Product_Attributes_Assoc::where('product_id', $id)->delete();\n $product = Product::find($id);\n // dd($product);\n $product->name = request('name');\n $product->sku = request('sku');\n $product->short_description = request('short_description');\n $product->long_description = request('long_description');\n $product->price = request('price');\n $product->special_price = request('special_price');\n $product->special_price_from = request('special_price_from');\n $product->special_price_to = request('special_price_to');\n $product->quanity = request('quanity');\n $product->meta_title = request('meta_title');\n $product->meta_description = request('meta_description');\n $product->meta_keywords = request('meta_keywords');\n $product->created_by = auth()->user()->id;\n $product->updated_by = auth()->user()->id;\n $product->status = request('status');\n $product->save();\n // dd($request->all());\n // dd(request('product_imageoldid'));\n if (!empty(request('product_imageoldid'))) {\n Product_Images::whereNotIn('id', request('product_imageoldid'))->where('product_id', $id)->delete();\n foreach (request('product_imageoldid') as $key => $value) {\n // dd(request('product_imageoldid'));\n // dd($value);\n if (isset($request->product_image_name[$key])) {\n $product_image = Product_Images::find($value);\n // dd($product_image);\n $path = public_path() . \"/admin/product_image/\" . $product_image->image_name;\n // for deleteing the old image\n if (file_exists($path)) {\n unlink($path);\n }\n $extension = $request->product_image_name[$key]->getClientOriginalExtension();\n // dd($request->product_image_name[$key]);\n $filename = time() . '.' . $extension;\n // dd($filename);\n $request->product_image_name[$key]->move('admin/product_image/', $filename);\n $product_image->image_name = $filename;\n $product_image->save();\n // dd($request->product_image_name[$key]);\n // unset($request->product_image_name[$key]);\n\n }\n }\n }\n // if user go to any edit product and than he want to add new image .\n if (!empty($request->product_image_name)) {\n // dd($request->product_image_name);\n foreach ($request->product_image_name as $k => $product_image_names) {\n if (!array_key_exists($k, request('product_imageoldid'))) {\n $extension = $product_image_names->getClientOriginalExtension();\n $filename = time() . '.' . $extension;\n // dd($filename);\n $product_image_names->move('admin/product_image/', $filename);\n\n $images[] = [\n 'product_id' => $id,\n 'image_name' => $filename,\n 'created_by' => auth()->user()->id,\n 'updated_by' => auth()->user()->id,\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now()\n ];\n }\n }\n if (!empty($images)) {\n Product_Images::insert($images);\n }\n }\n $ProductAttribute = request('ProductAttribute');\n $productattributevalue = request('productattributevalue');\n // dd($productattributevalue);\n $productvaluearry = [];\n $i = 0;\n foreach ($ProductAttribute as $pa) {\n $j = 0;\n foreach ($productattributevalue as $pav) {\n if ($i == $j) {\n // dd($pa);\n $productvaluearry[] = [\n 'product_id' => $product->id,\n 'product_attribute_id' => $pa,\n 'product_attribute_value_id' => $pav,\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now()\n ];\n }\n $j = $j + 1;\n }\n $i = $i + 1;\n }\n if (!empty($productvaluearry)) {\n Product_Attributes_Assoc::insert($productvaluearry);\n }\n // for deleting a categorys\n // dd($id);\n Product_Categories::where('product_id', $id)->delete();\n // for adding the categorys\n $category = [];\n $category[] = [\n 'product_id' => $product->id,\n 'category_id' => request('categorys'),\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now()\n ];\n if (!empty($category)) {\n Product_Categories::insert($category);\n }\n\n return redirect('admin/product')->with('flash_message', 'Product updated!');\n }",
"public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'name' => 'required',\n 'price' => 'required|numeric',\n 'category' => 'required|integer',\n 'condition' => 'required|string',\n 'description' => 'required',\n 'province' => 'required',\n 'district' => 'required',\n 'sub_district' => 'required',\n 'address' => 'required',\n 'image.*' => 'nullable|mimes:jpeg,png,jpg|max:2048',\n ]);\n\n $product = Product::find($id);\n $product->update([\n\t \t'category_id' => $request->category,\n 'address_id' => $request->address,\n\t 'name' => $request->name,\n\t 'price' => $request->price,\n\t 'description' => $request->description\n \t]);\n\n $address = $product->address;\n $address->province = $request->province;\n $address->district = $request->district;\n $address->sub_district = $request->sub_district;\n $address->address = $request->address;\n $address->save();\n\n\t\t$fileImg = ProductImage::where('product_id',$id)->whereNotIn('id',$request->file)->get();\n \tforeach ($fileImg as $val) {\n \t\tif($val->name && !empty($val->name) && !is_null($val->name)){\n $img = public_path('product/'.$val->name);\n if(file_exists($img)){\n unlink($img);\n }\n }\n \t$val->delete();\n \t}\n\n \tif($request->hasFile('image')){\n\t \tforeach ($request->file('image') as $image) {\n \t$nameimage = uniqid().'.'.$image->getClientOriginalExtension();\n \t$image->move('product/',$nameimage);\n\t \t\tProductImage::create([\n\t \t'product_id' => $id,\n\t \t\t\t'name' => $nameimage\n\t ]);\n\t \t}\n \t}\n $request->session()->flash('success', 'Successfully, updated product');\n \treturn redirect()->back();\n }",
"public function update(ProductRequest $request, $id)\n {\n\n\n if ($product = $this->productService->editproduct($request, $id)) {\n $ware = $request['warehouse_id'];\n DB::table('warehouse_product')->where('product_id', $id)->delete();\n foreach ($ware as $w) {\n $productwarehouse = [\n 'product_id' => $id,\n 'warehouse_id' => $w\n ];\n\n $this->assignupdatewarehouse($productwarehouse);\n }\n return redirect('/product')->withSuccess('Product edited');\n }\n return back()->withErrors('something went wrong');\n }",
"public function update(Request $request, $id)\n {\n //\n //dd($request->all());\n $validation = $request->validate([\n \"name\" =>\"required|unique:products,name,$id\",\n \"price\" =>\"required|regex:/^\\d+(\\.\\d{1,2})?$/\",\n \"color\" =>\"required|in:red,blue,green,yellow,black\",\n \"category\" =>\"required|exists:categories,id\",\n \"vendor\" =>\"required|exists:vendors,id\",\n \"logo\" =>\"mimes:png,jpg|max:2048|nullable\"\n ]);\n \n \n $product = Product::findorFail($id);\n $product->name = $request->name;\n $product->price = $request->price;\n $product->color = $request->color;\n $product->category_id = $request->category;\n $product->vendor_id = $request->vendor;\n if (isset($request->logo) && $request->logo !=null){\n $fileName = time().'_'.str_replace(' ','-',$request->logo->getClientOriginalName());\n $filePath = $request->file('logo')->storeAs('uploads/products', $fileName, 'public');\n $product->logo = $filePath;\n }\n \n \n if (isset($request->active) && $request->active==1)\n $product->active = 1;\n else $product->active = 0;\n $product->save();\n Session::flash('message', 'Product Updated!'); \n return redirect(route('product.edit',$id));\n }",
"public function update(Request $request, $id)\n {\n $category_name=$request->category_name;\n $product_name=$request->product_name;\n $target_sale=$request->target_sale;\n $quantity=$request->quantity;\n $product_cost=$request->product_cost;\n $percentage=$request->percentage;\n $supplier_id=$request->supplier_id;\n $approximate_cost=$request->approximate_cost;\n if(count($request->id) > 0) {\n foreach ($request->id as $key=>$value) {\n\n $data=[\n 'category_name'=>$category_name[$key],\n 'product_name'=>$product_name[$key],\n 'target_sale'=>$target_sale[$key],\n 'quantity'=>$quantity[$key],\n 'product_cost'=>$product_cost[$key],\n 'percentage'=>$percentage[$key],\n 'supplier_id'=>$supplier_id[$key],\n 'approximate_cost'=>$approximate_cost[$key],\n\n\n\n ];\n $product=product::where('id',$request->id[$key])->first();\n $product->update($data);\n }\n }\n session()->flash('msg','Product Updated Successfully');\n return back();\n }",
"public function update(Request $request, $id) {\n $this->validate($request, [\n 'product_name'=>'required',\n 'product_description'=>'required',\n 'product_price'=>'required|numeric',\n 'cat_id'=>'required|not_in:0',\n 'product_pv_value'=>'required|numeric',\n 'product_image'=>'required',\n ]);\n \n $product = product::find($id);\n $product->product_name = $request->product_name;\n $product->product_description = $request->product_description;\n $product->product_price = $request->product_price;\n $product->cat_id = $request->cat_id;\n $product->product_pv_value = $request->product_pv_value;\n $product->product_status = 1;\n //\n\n if ($request->hasFile('product_image')) {\n\n $fileName = $request->product_image->getClientOriginalName();\n $request->product_image->storeAs('public/images', $fileName);\n\n $product->product_image = $fileName;\n } else {\n return 'no file selected';\n }\n\n $product->save();\n return redirect('/product');\n }",
"public function getShapeByShapeID($shapeID){\n\n }",
"public function update(\\App\\Http\\Requests\\admin\\ProductRequest $request, $id)\n {\n $product = Product::findOrFail($id);\n $data = $request->all();\n $checkboxes = array('hit', 'new', 'ya_market', 'merchant', 'act');\n foreach ($checkboxes as $ch) {\n if(!isset($data[$ch])) {\n $data[$ch] = 0;\n }\n }\n $data['brand_id'] = ($data['brand_id'] ?: null);\n\n $product->update($data);\n\n //связь с категориями\n $product->categories()->sync($request->input('categories'));\n\n //delete photos\n if($request->has('p_ids')) {\n foreach($data['p_ids'] as $key => $id_photo) {\n $photo = $product->photos()->find($id_photo);\n if(!empty($photo)) {\n //delete\n if (!empty($data['p_delete'][$key])) {\n $photo->uploads->delete();\n $photo->delete();\n }\n }\n }\n }\n\n //добавление основного изображения\n if($img = $request->file('img')) {\n $validator = Validator::make(['img' => $img], ProductPhoto::$rules);\n if ($validator->passes()) {\n $product->uploads->upload();\n $product->save();\n }\n }\n\n //добавление дополнительных изображений\n if($request->file('photos')) {\n foreach($request->file('photos') as $key => $photo) {\n $validator = Validator::make(['img' => $photo], ProductPhoto::$rules);\n if ($validator->passes()) {\n $photo = new ProductPhoto(['product_id' => $product->id]);\n $photo->uploads->upload(['img' => 'photos.'.$key]);\n $product->photos()->save($photo);\n }\n }\n }\n\n //связь с тегами\n if($request->has('tags')) {\n $product->tags()->sync($request->input('tags'));\n }elseif($product->tags()->count()) {\n foreach($product->tags as $tag) {\n $product->tags()->detach($tag->id);\n }\n }\n\n if($request->has('kits'))\n $product->kits()->sync($request->kits);\n elseif($product->kits()->count())\n foreach($product->kits as $kit)\n $product->kits()->detach($kit->id);\n\n //связь с \"покупают также\"\n if($request->has('related'))\n $product->related()->sync(array_diff($request->input('related'), ['']));\n\n elseif($product->related()->count())\n foreach($product->related as $product)\n $product->related()->detach($product->id);\n\n //связь с атрибутами\n if(!$product->setAttributesFromRequest(true))\n Session::flash('error', 'Не все атрибуты товара были сохранены.');\n\n return redirect()->route('admin.products.index')->withMessage('Товар изменен');\n }"
] | [
"0.687418",
"0.647888",
"0.6403875",
"0.6338126",
"0.6336837",
"0.6268605",
"0.6260781",
"0.6239885",
"0.6222728",
"0.61954486",
"0.61860657",
"0.61821604",
"0.6172219",
"0.6147472",
"0.6130681",
"0.6113007",
"0.61100626",
"0.6105262",
"0.60986674",
"0.6098056",
"0.6097403",
"0.6083106",
"0.6073779",
"0.6070943",
"0.6068037",
"0.6062329",
"0.6061848",
"0.60595614",
"0.60589164",
"0.6051125"
] | 0.8107958 | 0 |
Get a websocket client for the given gateway. | public function getSocket($gateway)
{
return new WebSocketClient($gateway);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getGateway()\n {\n $gateway = $this->gateway;\n\n try {\n $response = (new Client)->get('https://discordapp.com/api/gateway', [\n 'headers' => [\n 'Authorization' => 'Bot ' . setting('herpaderp.seatnotifications.discord.credentials.bot_token', true),\n ],\n ]);\n\n $gateway = Arr::get(json_decode($response->getBody(), true), 'url', $gateway);\n } catch (Exception $e) {\n\n return redirect()->route('seatnotifications.configuration')\n ->with('error', 'Could not get a websocket gateway address, defaulting to' . $gateway . '. An error occurred while trying to create websocket connection with Discord. ' .\n $e->getMessage());\n }\n\n return $gateway;\n }",
"public function getGateway()\n {\n if (!$this->gateway->connected() && !$this->gateway->connect($this->getUsername())) {\n throw new RuntimeException('Unable to connect to remote server.');\n }\n\n return $this->gateway;\n }",
"private function _getClient() {\n\n static $client = FALSE;\n\n if ($client instanceof Client) {\n return $client;\n }\n\n $client = Client::factory([\n 'url' => $this->getServer()->getUrl(),\n 'client_id' => 'example_id',\n 'client_secret' => 'example_secret',\n 'munchkin_id' => 'example_munchkin_id',\n ]);\n\n return $client;\n }",
"protected function getGateway()\n\t{\n\t\tif (!isset($this->gateway))\n\t\t{\n\t\t\t$db = JFactory::getDbo();\n\t\t\t$query = $db->getQuery(true);\n\t\t\t$data = $this->getEmailData();\n\t\t\t$id = (int) $data['jos_fabrik_subs_users___gateway_raw'][0];\n\t\t\t$query->select('*')->from('#__fabrik_subs_payment_gateways')\n\t\t\t->where('id = ' . $id);\n\t\t\t$db->setQuery($query);\n\t\t\t$this->gateway = $db->loadObject();\n\t\t}\n\t\treturn $this->gateway;\n\t}",
"protected function getWebClient() {\n if ($this->webClient === null) {\n $this->webClient = new WebToPay_WebClient();\n }\n return $this->webClient;\n }",
"public function getGateway()\r\n {\r\n return $this->_gateway;\r\n }",
"public static function getGateway()\n {\n $gateways = Session::get('shop.gateway');\n return $gateways && count($gateways) > 0\n ? $gateways[count($gateways) - 1]\n : null;\n }",
"public function getSoapClient()\n {\n if (!$this->getData('soap_client') instanceof SoapClient)\n { \n try { \n $soap_client= new SoapClient($this->getWsdlUrl(),\n array(\n 'connection_timeout' => 2, // If Authorize.net isn't responding within two seconds, it's down\n 'exceptions' => true, // Throw exceptions if encountered - these should be caught by code\n 'trace' => ($this->_getConfig('debug')) ? 1 : 0, // If debug is enabled, use the trace\n 'compression'=> SOAP_COMPRESSION_ACCEPT | SOAP_COMPRESSION_GZIP // request a compressed response\n )\n ); \n $soap_client->__setLocation($this->getGatewayUrl());\n $this->setData('soap_client',$soap_client);\n } catch (SoapFault $sf) {\n //Log SOAP fault from connection\n if ($this->_getConfig('debug'))\n {\n $this->debugData($sf);\n } \n return false;\n } catch (Exception $e) { \n //Log Exception from Connection\n if ($this->_getConfig('debug'))\n {\n $this->debugData($e);\n } \n return false;\n } \n }\n \n return $this->getData('soap_client'); // Return the client to the user\n }",
"public function getClient(): OssClient\n {\n return $this->client;\n }",
"public function get_gateway() {\n\t\treturn $this->gateway;\n\t}",
"public function get_client( $client_id = '' ) {\n\n return $this->make_request( 'clients/' . $client_id );\n\n }",
"public function client(): Client\n {\n return $this->client;\n }",
"public function getClient(): \\Swoole\\Coroutine\\Http2\\Client\n {\n return $this->client->getClient();\n }",
"public function getClient(): Client\n {\n return $this->getAdapter()->getClient();\n }",
"public function getClient(): object\n {\n return $this->_client;\n }",
"public function getClient(): Client\n {\n return $this->client;\n }",
"public function getClient(): Client\n {\n return $this->client;\n }",
"public function getClient(): Client\n {\n return $this->client;\n }",
"public static function get() {\n\t\tif (self::$client == null)\n\t\t\tself::$client = new Client();\n\t\treturn self::$client;\n\t}",
"public static function getThriftClient();",
"public function getSoapClient($wdsl) {\n if(empty($this->soapClients[$wdsl])) {\n $handle = curl_init();\n curl_setopt($handle, CURLOPT_URL, $wdsl);\n curl_setopt($handle, CURLOPT_RETURNTRANSFER, TRUE);\n curl_exec($handle);\n $httpCode = curl_getinfo($handle, CURLINFO_HTTP_CODE);\n if($httpCode != 200) {\n throw new Exception('SOAP Server has gone away.');\n }\n $this->soapClients[$wdsl] = new SoapClient($wdsl);\n }\n return $this->soapClients[$wdsl];\n }",
"public function getClientInstance()\n\t{\n\t\treturn Client::instance($this->db);\n\t}",
"protected function getClient(): Client\n {\n return $this->client;\n }",
"public function getClient()\n {\n Yii::setAlias('@Solarium', dirname(__DIR__) . '/vendors/solarium/library/Solarium');\n Yii::setAlias('@Symfony/Component/EventDispatcher', dirname(__DIR__) . '/vendors/solarium/vendor/symfony/event-dispatcher/');\n\n $config = array(\n 'endpoint' => array(\n 'localhost' => array(\n 'host' => $this->host,\n 'port' => $this->port,\n 'path' => $this->path,\n )\n )\n );\n $client = new \\Solarium\\Core\\Client\\Client($config);\n\n if ($this->username != \"\") {\n $endpoint = $client->getEndpoint();\n $endpoint->setAuthentication($this->username, $this->password);\n }\n\n return $client;\n }",
"private function getClient()\n {\n if (!$this->client) {\n $this->client = new Client(['base_uri' => self::BASE_URI]);\n }\n\n return $this->client;\n }",
"private function get_client() {\n\t\treturn $this->client;\n\t}",
"private function get_client() {\n\t\treturn $this->client;\n\t}",
"protected function _getInstanceOfClient()\n\t{\n\t\treturn minimee()->makeClient();\n\t}",
"public function getClient(): TelegramClient\n {\n return $this->client ??= (new TelegramClient())->setToken($this->getToken());\n }",
"public function client()\n {\n return $this->client;\n }"
] | [
"0.70304585",
"0.5728749",
"0.55672884",
"0.5541406",
"0.5488101",
"0.5439486",
"0.54309833",
"0.5426847",
"0.54265314",
"0.54236174",
"0.5347596",
"0.5296805",
"0.52934635",
"0.5258017",
"0.5251318",
"0.52410764",
"0.52410764",
"0.52410764",
"0.5238862",
"0.5223331",
"0.5221324",
"0.52207845",
"0.5219375",
"0.52158546",
"0.52094495",
"0.5198431",
"0.5198431",
"0.5181453",
"0.5178602",
"0.5172726"
] | 0.85684484 | 0 |
$_date = new DateTime($comment['Comment_Date']); | function news_comment_date($comment)
{
return "";//$_date->format("d/m/Y à H:i");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getComment_date()\n {\n return $this->comment_date;\n }",
"public function postDate() : \\DateTime\n {\n return new \\DateTime($this->info()->date);\n }",
"public function getPostDate() : \\DateTime {\n\t\treturn($this->postDate);\n\t}",
"public function __construct(){ $this->created_at =(new DateTime());\n $this->updated_at = $this->created_at;\n $this->comment = array();\n }",
"public function getArticleDatePublished() : \\DateTime{\n\treturn($this->articleDatePublished);\n}",
"public function getLikeDate() : \\DateTime {\n return ($this->likeDate);\n }",
"function getDate()\r\n {\r\n return $this->_date;\r\n }",
"public function getResultDate(array $result)\n {\n return $result['comment_date'];\n }",
"function getPostDate() {\n\t\treturn $this->data_array['post_date'];\n\t}",
"public function getDateCreate(): DateTime\n {\n }",
"public function getDateTime() {\n\t\treturn (new DateTime ( $this->date ))->format ( 'Y-m-d @ H:i:s' );\n\t}",
"public function __construct() {\n \t$oDate = new dateTime();\n \t$this->date = $oDate->format(\"Y-m-d\");\n }",
"public function __construct()\n {\n \n \n $this->createdAt = new \\DateTime();\n }",
"public function __construct()\n {\n $this->createdAt = new DateTime();\n }",
"function extractDate($datetime) {\n\t\t\t\t\t\n\t\t\t\t\t$date = date(\"Y-m-d\",strtotime($datetime));\n\t\t\t\t\t\n\t\t\t\t\treturn $date;\n\t\t\t\t\t\n\t\t\t\t}",
"private static function _getDateTime(): DateTime\n {\n return new DateTime();\n }",
"public function getDate()\n {\n return $this->date;\n }",
"function getDate() {\n return $this->date;\n }",
"function __construct($date) {\r\n $this->date = new DateTime($date); // new object of DateTime\r\n }",
"function getPostDate()\n{\n global $post;\n return $post[0]['created'];\n}",
"public function toDateTime() {\n }",
"public function getPostDateTime()\n {\n return $this->postDateTime;\n }",
"public function getDateTime(): DateTime;",
"public function setFeedbackDate(\\DateTime $feedbackDate)\n {\n $this->feedbackDate = $feedbackDate;\n\n \n }",
"public function getDate(): \\DateTime\n {\n return $this->date;\n }",
"public function getCreatedDate(): DateTime {\n return $this->created_date;\n }",
"function getLastCommentOn() {\n return $this->getDatetimeField1();\n }",
"public function getDate(): DateTime\n {\n return $this->date;\n }",
"public function getDate()\n {\n return $this->date;\n }",
"public function getDate()\n {\n return $this->date;\n }"
] | [
"0.71050674",
"0.6586288",
"0.63920987",
"0.6334561",
"0.622101",
"0.611831",
"0.6087",
"0.6083131",
"0.60194063",
"0.6017237",
"0.5997198",
"0.5978311",
"0.59678155",
"0.59484893",
"0.594158",
"0.5903276",
"0.5899143",
"0.58761597",
"0.58522755",
"0.58520836",
"0.5833269",
"0.58177304",
"0.5811355",
"0.5770883",
"0.57462025",
"0.5743331",
"0.57398367",
"0.57354325",
"0.5727562",
"0.5727562"
] | 0.68818897 | 1 |
Registers the default application parameters. | protected function registerDefaultParameters()
{
$path = isset($this['path']) ? $this['path'] : array();
if (!isset($path['base'])) {
$path['base'] = realpath(__DIR__ . '/../../../..');
}
$defaults = array(
'cache' => $path['base'] . '/app/cache',
'config' => $path['base'] . '/app/config',
'logs' => $path['base'] . '/app/logs',
'translations' => $path['base'] . '/app/translations',
'views' => $path['base'] . '/app/views',
);
foreach ($defaults as $key => $value) {
if (!isset($path[$key])) {
$path[$key] = $value;
}
}
$this['path'] = $path;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getDefaultParameters();",
"abstract public function provideDefaultValues();",
"public function setDefaults();",
"public function setDefaults();",
"protected function initialiseDefaultValues()\n {\n\n }",
"public function getDefaultSettings();",
"private function addDefaultSettings()\n {\n $settings = array(\n 'mobileview' => 320,\n 'tabletview' => 600,\n 'desktopview' => 920,\n 'imagesmall' => 30,\n 'imagemedium' => 50,\n 'imagelarge' => 100,\n 'showswitches' => true,\n 'placeholder' => $this->translator->trans(\"aes.settings.label.defaultplaceholder\"),\n );\n\n $globalSettings = array(\n 'apiendpoint' => \"/api\",\n 'default_image_size' => 'medium',\n 'css_custom_style' => $this->editorService->getDefaultCss(),\n );\n\n $this->setUpSettings($settings);\n $this->setUpSettings($globalSettings, true);\n }",
"protected function getDefaultParameters()\n {\n return array(\n 'allowed_slugs' => array(\n 0 => 'dev',\n 1 => 'preprod',\n ),\n 'allowed_versions' => array(\n 0 => '2.62',\n 1 => '2.61',\n ),\n );\n }",
"public function getDefaultParameters()\n {\n return [\n 'goId' => '',\n 'clientId' => '',\n 'clientSecret' => '',\n 'testMode' => true,\n ];\n }",
"public function getDefaultParameters()\n {\n return [\n 'apiKey' => '',\n 'testMode' => true,\n\n ];\n }",
"public function setDefaultParams()\n\t{\n\t\t$this->position = 'wrap';\n\t\t\n\t\t$this->render_time = 'normal';\n\t}",
"public function getDefaultParameters()\n {\n return array(\n 'apiType' => 0,\n 'publicKey' => '',\n 'privateKey' => '',\n );\n }",
"public function getDefaultParams()\n {\n return array();\n }",
"public function setDefaultParams(array $params)\n {\n $this->_defaultParams = $params;\n }",
"public function getDefaultParameters()\n {\n return array(\n 'enableIPN' => false,\n 'locale' => 'en',\n 'testMode' => false,\n );\n }",
"public function getDefaultParameters(): array\n {\n return [];\n }",
"public function loadDefaultConfigs() {\n $this->setMode();\n $this->setHostname();\n $this->setLocale();\n $this->setCharset();\n $this->setEncoding();\n $this->setWordwrap();\n }",
"public function getDefaultConfig();",
"public function getDefaultParameters()\n {\n return array(\n 'MerchantID' => '',\n 'APIPassword' => ''\n );\n }",
"protected function getDefaultParameters()\n {\n return array(\n 'kernel.root_dir' => '/Users/pete.robinson/Sites/wam/image/tests/SupportFiles/app',\n 'kernel.environment' => 'test',\n 'kernel.debug' => true,\n 'kernel.name' => 'app',\n 'kernel.cache_dir' => '/Users/pete.robinson/Sites/wam/image/tests/SupportFiles/app/../../../tmp/cache',\n 'kernel.logs_dir' => '/Users/pete.robinson/Sites/wam/image/tests/SupportFiles/app/../../../tmp/logs',\n 'kernel.bundles' => array(\n 'FrameworkBundle' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\FrameworkBundle',\n 'SecurityBundle' => 'Symfony\\\\Bundle\\\\SecurityBundle\\\\SecurityBundle',\n 'DoctrineBundle' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\DoctrineBundle',\n 'DoctrineFixturesBundle' => 'Doctrine\\\\Bundle\\\\FixturesBundle\\\\DoctrineFixturesBundle',\n 'AcmeTestBundle' => 'Acme\\\\TestBundle\\\\AcmeTestBundle',\n 'WamAssetBundle' => 'Wam\\\\AssetBundle\\\\WamAssetBundle',\n 'WamImageBundle' => 'Wam\\\\ImageBundle\\\\WamImageBundle',\n ),\n 'kernel.charset' => 'UTF-8',\n 'kernel.container_class' => 'appTestDebugProjectContainer',\n 'database_driver' => 'pdo_mysql',\n 'database_host' => 'localhost',\n 'database_port' => NULL,\n 'database_name' => 'wam',\n 'database_user' => 'root',\n 'database_password' => NULL,\n 'locale' => 'en',\n 'secret' => '41a217f064a7c679528a644e4b61ab7cd290d9dd',\n 'database_path' => NULL,\n 'controller_resolver.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Controller\\\\ControllerResolver',\n 'controller_name_converter.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Controller\\\\ControllerNameParser',\n 'response_listener.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\ResponseListener',\n 'streamed_response_listener.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\StreamedResponseListener',\n 'locale_listener.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\LocaleListener',\n 'event_dispatcher.class' => 'Symfony\\\\Component\\\\EventDispatcher\\\\ContainerAwareEventDispatcher',\n 'http_kernel.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\HttpKernel',\n 'filesystem.class' => 'Symfony\\\\Component\\\\Filesystem\\\\Filesystem',\n 'cache_warmer.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\CacheWarmer\\\\CacheWarmerAggregate',\n 'cache_clearer.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\CacheClearer\\\\ChainCacheClearer',\n 'file_locator.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\Config\\\\FileLocator',\n 'uri_signer.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\UriSigner',\n 'fragment.handler.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\Fragment\\\\FragmentHandler',\n 'fragment.renderer.inline.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\Fragment\\\\InlineFragmentRenderer',\n 'fragment.renderer.hinclude.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Fragment\\\\ContainerAwareHIncludeFragmentRenderer',\n 'fragment.renderer.hinclude.global_template' => '',\n 'fragment.path' => '/_fragment',\n 'translator.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Translation\\\\Translator',\n 'translator.identity.class' => 'Symfony\\\\Component\\\\Translation\\\\IdentityTranslator',\n 'translator.selector.class' => 'Symfony\\\\Component\\\\Translation\\\\MessageSelector',\n 'translation.loader.php.class' => 'Symfony\\\\Component\\\\Translation\\\\Loader\\\\PhpFileLoader',\n 'translation.loader.yml.class' => 'Symfony\\\\Component\\\\Translation\\\\Loader\\\\YamlFileLoader',\n 'translation.loader.xliff.class' => 'Symfony\\\\Component\\\\Translation\\\\Loader\\\\XliffFileLoader',\n 'translation.loader.po.class' => 'Symfony\\\\Component\\\\Translation\\\\Loader\\\\PoFileLoader',\n 'translation.loader.mo.class' => 'Symfony\\\\Component\\\\Translation\\\\Loader\\\\MoFileLoader',\n 'translation.loader.qt.class' => 'Symfony\\\\Component\\\\Translation\\\\Loader\\\\QtFileLoader',\n 'translation.loader.csv.class' => 'Symfony\\\\Component\\\\Translation\\\\Loader\\\\CsvFileLoader',\n 'translation.loader.res.class' => 'Symfony\\\\Component\\\\Translation\\\\Loader\\\\IcuResFileLoader',\n 'translation.loader.dat.class' => 'Symfony\\\\Component\\\\Translation\\\\Loader\\\\IcuDatFileLoader',\n 'translation.loader.ini.class' => 'Symfony\\\\Component\\\\Translation\\\\Loader\\\\IniFileLoader',\n 'translation.dumper.php.class' => 'Symfony\\\\Component\\\\Translation\\\\Dumper\\\\PhpFileDumper',\n 'translation.dumper.xliff.class' => 'Symfony\\\\Component\\\\Translation\\\\Dumper\\\\XliffFileDumper',\n 'translation.dumper.po.class' => 'Symfony\\\\Component\\\\Translation\\\\Dumper\\\\PoFileDumper',\n 'translation.dumper.mo.class' => 'Symfony\\\\Component\\\\Translation\\\\Dumper\\\\MoFileDumper',\n 'translation.dumper.yml.class' => 'Symfony\\\\Component\\\\Translation\\\\Dumper\\\\YamlFileDumper',\n 'translation.dumper.qt.class' => 'Symfony\\\\Component\\\\Translation\\\\Dumper\\\\QtFileDumper',\n 'translation.dumper.csv.class' => 'Symfony\\\\Component\\\\Translation\\\\Dumper\\\\CsvFileDumper',\n 'translation.dumper.ini.class' => 'Symfony\\\\Component\\\\Translation\\\\Dumper\\\\IniFileDumper',\n 'translation.dumper.res.class' => 'Symfony\\\\Component\\\\Translation\\\\Dumper\\\\IcuResFileDumper',\n 'translation.extractor.php.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Translation\\\\PhpExtractor',\n 'translation.loader.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Translation\\\\TranslationLoader',\n 'translation.extractor.class' => 'Symfony\\\\Component\\\\Translation\\\\Extractor\\\\ChainExtractor',\n 'translation.writer.class' => 'Symfony\\\\Component\\\\Translation\\\\Writer\\\\TranslationWriter',\n 'debug.event_dispatcher.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\Debug\\\\TraceableEventDispatcher',\n 'debug.stopwatch.class' => 'Symfony\\\\Component\\\\Stopwatch\\\\Stopwatch',\n 'debug.container.dump' => '/Users/pete.robinson/Sites/wam/image/tests/SupportFiles/app/../../../tmp/cache/appTestDebugProjectContainer.xml',\n 'debug.controller_resolver.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\Controller\\\\TraceableControllerResolver',\n 'debug.deprecation_logger_listener.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\DeprecationLoggerListener',\n 'kernel.secret' => 'something',\n 'kernel.trusted_proxies' => array(\n\n ),\n 'kernel.trust_proxy_headers' => false,\n 'kernel.default_locale' => 'Europe
ondon',\n 'test.client.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Client',\n 'test.client.parameters' => array(\n\n ),\n 'test.client.history.class' => 'Symfony\\\\Component\\\\BrowserKit\\\\History',\n 'test.client.cookiejar.class' => 'Symfony\\\\Component\\\\BrowserKit\\\\CookieJar',\n 'test.session.listener.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\EventListener\\\\TestSessionListener',\n 'session.class' => 'Symfony\\\\Component\\\\HttpFoundation\\\\Session\\\\Session',\n 'session.flashbag.class' => 'Symfony\\\\Component\\\\HttpFoundation\\\\Session\\\\Flash\\\\FlashBag',\n 'session.attribute_bag.class' => 'Symfony\\\\Component\\\\HttpFoundation\\\\Session\\\\Attribute\\\\AttributeBag',\n 'session.storage.native.class' => 'Symfony\\\\Component\\\\HttpFoundation\\\\Session\\\\Storage\\\\NativeSessionStorage',\n 'session.storage.mock_file.class' => 'Symfony\\\\Component\\\\HttpFoundation\\\\Session\\\\Storage\\\\MockFileSessionStorage',\n 'session.handler.native_file.class' => 'Symfony\\\\Component\\\\HttpFoundation\\\\Session\\\\Storage\\\\Handler\\\\NativeFileSessionHandler',\n 'session_listener.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\EventListener\\\\SessionListener',\n 'session.storage.options' => array(\n\n ),\n 'session.save_path' => '/Users/pete.robinson/Sites/wam/image/tests/SupportFiles/app/../../../tmp/cache/sessions',\n 'validator.class' => 'Symfony\\\\Component\\\\Validator\\\\Validator',\n 'validator.mapping.class_metadata_factory.class' => 'Symfony\\\\Component\\\\Validator\\\\Mapping\\\\ClassMetadataFactory',\n 'validator.mapping.cache.apc.class' => 'Symfony\\\\Component\\\\Validator\\\\Mapping\\\\Cache\\\\ApcCache',\n 'validator.mapping.cache.prefix' => '',\n 'validator.mapping.loader.loader_chain.class' => 'Symfony\\\\Component\\\\Validator\\\\Mapping\\\\Loader\\\\LoaderChain',\n 'validator.mapping.loader.static_method_loader.class' => 'Symfony\\\\Component\\\\Validator\\\\Mapping\\\\Loader\\\\StaticMethodLoader',\n 'validator.mapping.loader.annotation_loader.class' => 'Symfony\\\\Component\\\\Validator\\\\Mapping\\\\Loader\\\\AnnotationLoader',\n 'validator.mapping.loader.xml_files_loader.class' => 'Symfony\\\\Component\\\\Validator\\\\Mapping\\\\Loader\\\\XmlFilesLoader',\n 'validator.mapping.loader.yaml_files_loader.class' => 'Symfony\\\\Component\\\\Validator\\\\Mapping\\\\Loader\\\\YamlFilesLoader',\n 'validator.validator_factory.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Validator\\\\ConstraintValidatorFactory',\n 'validator.mapping.loader.xml_files_loader.mapping_files' => array(\n 0 => '/Users/pete.robinson/Sites/wam/image/vendor/symfony/symfony/src/Symfony/Component/Form/Resources/config/validation.xml',\n ),\n 'validator.mapping.loader.yaml_files_loader.mapping_files' => array(\n\n ),\n 'validator.translation_domain' => 'validators',\n 'profiler.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\Profiler\\\\Profiler',\n 'profiler_listener.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\ProfilerListener',\n 'data_collector.config.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\DataCollector\\\\ConfigDataCollector',\n 'data_collector.request.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\DataCollector\\\\RequestDataCollector',\n 'data_collector.exception.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\DataCollector\\\\ExceptionDataCollector',\n 'data_collector.events.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\DataCollector\\\\EventDataCollector',\n 'data_collector.logger.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\DataCollector\\\\LoggerDataCollector',\n 'data_collector.time.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\DataCollector\\\\TimeDataCollector',\n 'data_collector.memory.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\DataCollector\\\\MemoryDataCollector',\n 'data_collector.router.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\DataCollector\\\\RouterDataCollector',\n 'profiler_listener.only_exceptions' => false,\n 'profiler_listener.only_master_requests' => false,\n 'profiler.storage.dsn' => 'file:/Users/pete.robinson/Sites/wam/image/tests/SupportFiles/app/../../../tmp/cache/profiler',\n 'profiler.storage.username' => '',\n 'profiler.storage.password' => '',\n 'profiler.storage.lifetime' => 86400,\n 'router.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Routing\\\\Router',\n 'router.request_context.class' => 'Symfony\\\\Component\\\\Routing\\\\RequestContext',\n 'routing.loader.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Routing\\\\DelegatingLoader',\n 'routing.resolver.class' => 'Symfony\\\\Component\\\\Config\\\\Loader\\\\LoaderResolver',\n 'routing.loader.xml.class' => 'Symfony\\\\Component\\\\Routing\\\\Loader\\\\XmlFileLoader',\n 'routing.loader.yml.class' => 'Symfony\\\\Component\\\\Routing\\\\Loader\\\\YamlFileLoader',\n 'routing.loader.php.class' => 'Symfony\\\\Component\\\\Routing\\\\Loader\\\\PhpFileLoader',\n 'router.options.generator_class' => 'Symfony\\\\Component\\\\Routing\\\\Generator\\\\UrlGenerator',\n 'router.options.generator_base_class' => 'Symfony\\\\Component\\\\Routing\\\\Generator\\\\UrlGenerator',\n 'router.options.generator_dumper_class' => 'Symfony\\\\Component\\\\Routing\\\\Generator\\\\Dumper\\\\PhpGeneratorDumper',\n 'router.options.matcher_class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Routing\\\\RedirectableUrlMatcher',\n 'router.options.matcher_base_class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Routing\\\\RedirectableUrlMatcher',\n 'router.options.matcher_dumper_class' => 'Symfony\\\\Component\\\\Routing\\\\Matcher\\\\Dumper\\\\PhpMatcherDumper',\n 'router.cache_warmer.class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\CacheWarmer\\\\RouterCacheWarmer',\n 'router.options.matcher.cache_class' => 'appTestUrlMatcher',\n 'router.options.generator.cache_class' => 'appTestUrlGenerator',\n 'router_listener.class' => 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\RouterListener',\n 'router.request_context.host' => 'localhost',\n 'router.request_context.scheme' => 'http',\n 'router.request_context.base_url' => '',\n 'router.resource' => '/Users/pete.robinson/Sites/wam/image/tests/SupportFiles/app/config/routing.yml',\n 'router.cache_class_prefix' => 'appTest',\n 'request_listener.http_port' => 80,\n 'request_listener.https_port' => 443,\n 'annotations.reader.class' => 'Doctrine\\\\Common\\\\Annotations\\\\AnnotationReader',\n 'annotations.cached_reader.class' => 'Doctrine\\\\Common\\\\Annotations\\\\CachedReader',\n 'annotations.file_cache_reader.class' => 'Doctrine\\\\Common\\\\Annotations\\\\FileCacheReader',\n 'doctrine.dbal.logger.chain.class' => 'Doctrine\\\\DBAL\\\\Logging\\\\LoggerChain',\n 'doctrine.dbal.logger.profiling.class' => 'Doctrine\\\\DBAL\\\\Logging\\\\DebugStack',\n 'doctrine.dbal.logger.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\Logger\\\\DbalLogger',\n 'doctrine.dbal.configuration.class' => 'Doctrine\\\\DBAL\\\\Configuration',\n 'doctrine.data_collector.class' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\DataCollector\\\\DoctrineDataCollector',\n 'doctrine.dbal.connection.event_manager.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\ContainerAwareEventManager',\n 'doctrine.dbal.connection_factory.class' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\ConnectionFactory',\n 'doctrine.dbal.events.mysql_session_init.class' => 'Doctrine\\\\DBAL\\\\Event\\\\Listeners\\\\MysqlSessionInit',\n 'doctrine.dbal.events.oracle_session_init.class' => 'Doctrine\\\\DBAL\\\\Event\\\\Listeners\\\\OracleSessionInit',\n 'doctrine.class' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\Registry',\n 'doctrine.entity_managers' => array(\n 'default' => 'doctrine.orm.default_entity_manager',\n ),\n 'doctrine.default_entity_manager' => 'default',\n 'doctrine.dbal.connection_factory.types' => array(\n\n ),\n 'doctrine.connections' => array(\n 'default' => 'doctrine.dbal.default_connection',\n ),\n 'doctrine.default_connection' => 'default',\n 'doctrine.orm.configuration.class' => 'Doctrine\\\\ORM\\\\Configuration',\n 'doctrine.orm.entity_manager.class' => 'Doctrine\\\\ORM\\\\EntityManager',\n 'doctrine.orm.manager_configurator.class' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\ManagerConfigurator',\n 'doctrine.orm.cache.array.class' => 'Doctrine\\\\Common\\\\Cache\\\\ArrayCache',\n 'doctrine.orm.cache.apc.class' => 'Doctrine\\\\Common\\\\Cache\\\\ApcCache',\n 'doctrine.orm.cache.memcache.class' => 'Doctrine\\\\Common\\\\Cache\\\\MemcacheCache',\n 'doctrine.orm.cache.memcache_host' => 'localhost',\n 'doctrine.orm.cache.memcache_port' => 11211,\n 'doctrine.orm.cache.memcache_instance.class' => 'Memcache',\n 'doctrine.orm.cache.memcached.class' => 'Doctrine\\\\Common\\\\Cache\\\\MemcachedCache',\n 'doctrine.orm.cache.memcached_host' => 'localhost',\n 'doctrine.orm.cache.memcached_port' => 11211,\n 'doctrine.orm.cache.memcached_instance.class' => 'Memcached',\n 'doctrine.orm.cache.redis.class' => 'Doctrine\\\\Common\\\\Cache\\\\RedisCache',\n 'doctrine.orm.cache.redis_host' => 'localhost',\n 'doctrine.orm.cache.redis_port' => 6379,\n 'doctrine.orm.cache.redis_instance.class' => 'Redis',\n 'doctrine.orm.cache.xcache.class' => 'Doctrine\\\\Common\\\\Cache\\\\XcacheCache',\n 'doctrine.orm.cache.wincache.class' => 'Doctrine\\\\Common\\\\Cache\\\\WinCacheCache',\n 'doctrine.orm.cache.zenddata.class' => 'Doctrine\\\\Common\\\\Cache\\\\ZendDataCache',\n 'doctrine.orm.metadata.driver_chain.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\DriverChain',\n 'doctrine.orm.metadata.annotation.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\AnnotationDriver',\n 'doctrine.orm.metadata.xml.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\SimplifiedXmlDriver',\n 'doctrine.orm.metadata.yml.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\SimplifiedYamlDriver',\n 'doctrine.orm.metadata.php.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\PHPDriver',\n 'doctrine.orm.metadata.staticphp.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\StaticPHPDriver',\n 'doctrine.orm.proxy_cache_warmer.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\CacheWarmer\\\\ProxyCacheWarmer',\n 'form.type_guesser.doctrine.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\Form\\\\DoctrineOrmTypeGuesser',\n 'doctrine.orm.validator.unique.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\Validator\\\\Constraints\\\\UniqueEntityValidator',\n 'doctrine.orm.validator_initializer.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\Validator\\\\DoctrineInitializer',\n 'doctrine.orm.security.user.provider.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\Security\\\\User\\\\EntityUserProvider',\n 'doctrine.orm.listeners.resolve_target_entity.class' => 'Doctrine\\\\ORM\\\\Tools\\\\ResolveTargetEntityListener',\n 'doctrine.orm.naming_strategy.default.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\DefaultNamingStrategy',\n 'doctrine.orm.naming_strategy.underscore.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\UnderscoreNamingStrategy',\n 'doctrine.orm.auto_generate_proxy_classes' => true,\n 'doctrine.orm.proxy_dir' => '/Users/pete.robinson/Sites/wam/image/tests/SupportFiles/app/../../../tmp/cache/doctrine/orm/Proxies',\n 'doctrine.orm.proxy_namespace' => 'Proxies',\n 'wam_tmp_dir' => '/Users/pete.robinson/Sites/wam/image/tests/SupportFiles/app/../web/tmp',\n 'data_collector.templates' => array(\n 'data_collector.config' => array(\n 0 => 'config',\n 1 => '@WebProfiler/Collector/config.html.twig',\n ),\n 'data_collector.request' => array(\n 0 => 'request',\n 1 => '@WebProfiler/Collector/request.html.twig',\n ),\n 'data_collector.exception' => array(\n 0 => 'exception',\n 1 => '@WebProfiler/Collector/exception.html.twig',\n ),\n 'data_collector.events' => array(\n 0 => 'events',\n 1 => '@WebProfiler/Collector/events.html.twig',\n ),\n 'data_collector.logger' => array(\n 0 => 'logger',\n 1 => '@WebProfiler/Collector/logger.html.twig',\n ),\n 'data_collector.time' => array(\n 0 => 'time',\n 1 => '@WebProfiler/Collector/time.html.twig',\n ),\n 'data_collector.memory' => array(\n 0 => 'memory',\n 1 => '@WebProfiler/Collector/memory.html.twig',\n ),\n 'data_collector.router' => array(\n 0 => 'router',\n 1 => '@WebProfiler/Collector/router.html.twig',\n ),\n 'data_collector.doctrine' => array(\n 0 => 'db',\n 1 => 'DoctrineBundle:Collector:db',\n ),\n ),\n );\n }",
"protected function initDefaultValues()\n {\n parent::initDefaultValues();\n\n $this\n ->attributes([])\n ->permissions([])\n ;\n }",
"public function getDefaultParameters()\n {\n return array(\n 'merchantId' => '508029',\n 'accountId' => '512327',\n 'apiLogin' => '',\n 'apiKey' => '',\n 'testMode' => false,\n );\n }",
"public function getDefaultParameters()\n {\n return array(\n 'apiKey' => '',\n 'privateKey' => '',\n );\n }",
"public function getDefaultValues();",
"private function _setDefaults()\n {\n $this->setDefault('mysql_server', \t'localhost');\n $this->setDefault('mysql_username', 'root');\n $this->setDefault('mysql_dbname', \t'piwam');\n }",
"protected function enrich_optional_params_with_defaults() {\r\n $defaults = array(\r\n // Assume premium code migration.\r\n 'is_premium' => true,\r\n // Assume module is installed and active.\r\n 'is_uninstalled' => false,\r\n 'is_active' => true,\r\n );\r\n\r\n foreach ( $defaults as $k => $v ) {\r\n if ( ! isset( $this->_request_data[ $k ] ) ) {\r\n $this->_request_data[ $k ] = $v;\r\n }\r\n }\r\n\r\n /*if ( empty( $this->_request_data['url'] ) ) {\r\n // Attempt to grab the URL from the user agent if no URL is specified\r\n $domain = array_map( 'trim', explode( ';', $_SERVER['HTTP_USER_AGENT'] ) );\r\n if ( 1 < count( $domain ) ) {\r\n $url = trim( $domain[1] );\r\n } else {\r\n // If URL is missing and can't fetch from user agent, use required 'site_url' instead.\r\n $url = $this->get_param( 'site_url' );\r\n }\r\n\r\n $this->_request_data['url'] = $url;\r\n }*/\r\n }",
"protected function getDefaultParameters()\n {\n return array(\n 'kernel.environment' => 'dev',\n 'kernel.debug' => true,\n 'kernel.name' => 'app',\n 'kernel.cache_dir' => __DIR__,\n 'kernel.bundles' => array(\n 'FrameworkBundle' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\FrameworkBundle',\n 'SecurityBundle' => 'Symfony\\\\Bundle\\\\SecurityBundle\\\\SecurityBundle',\n 'TwigBundle' => 'Symfony\\\\Bundle\\\\TwigBundle\\\\TwigBundle',\n 'MonologBundle' => 'Symfony\\\\Bundle\\\\MonologBundle\\\\MonologBundle',\n 'SwiftmailerBundle' => 'Symfony\\\\Bundle\\\\SwiftmailerBundle\\\\SwiftmailerBundle',\n 'DoctrineBundle' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\DoctrineBundle',\n 'SensioFrameworkExtraBundle' => 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\SensioFrameworkExtraBundle',\n 'JMSAopBundle' => 'JMS\\\\AopBundle\\\\JMSAopBundle',\n 'JMSSecurityExtraBundle' => 'JMS\\\\SecurityExtraBundle\\\\JMSSecurityExtraBundle',\n 'DoctrineMigrationsBundle' => 'Doctrine\\\\Bundle\\\\MigrationsBundle\\\\DoctrineMigrationsBundle',\n 'DoctrineCacheBundle' => 'Doctrine\\\\Bundle\\\\DoctrineCacheBundle\\\\DoctrineCacheBundle',\n 'KnpMenuBundle' => 'Knp\\\\Bundle\\\\MenuBundle\\\\KnpMenuBundle',\n 'KnpMarkdownBundle' => 'Knp\\\\Bundle\\\\MarkdownBundle\\\\KnpMarkdownBundle',\n 'KnpPaginatorBundle' => 'Knp\\\\Bundle\\\\PaginatorBundle\\\\KnpPaginatorBundle',\n 'FOSUserBundle' => 'FOS\\\\UserBundle\\\\FOSUserBundle',\n 'SonataUserBundle' => 'Sonata\\\\UserBundle\\\\SonataUserBundle',\n 'SonataMediaBundle' => 'Sonata\\\\MediaBundle\\\\SonataMediaBundle',\n 'IvoryCKEditorBundle' => 'Ivory\\\\CKEditorBundle\\\\IvoryCKEditorBundle',\n 'SonataAdminBundle' => 'Sonata\\\\AdminBundle\\\\SonataAdminBundle',\n 'SonataDoctrineORMAdminBundle' => 'Sonata\\\\DoctrineORMAdminBundle\\\\SonataDoctrineORMAdminBundle',\n 'FOSRestBundle' => 'FOS\\\\RestBundle\\\\FOSRestBundle',\n 'BazingaHateoasBundle' => 'Bazinga\\\\Bundle\\\\HateoasBundle\\\\BazingaHateoasBundle',\n 'NelmioApiDocBundle' => 'Nelmio\\\\ApiDocBundle\\\\NelmioApiDocBundle',\n 'NelmioCorsBundle' => 'Nelmio\\\\CorsBundle\\\\NelmioCorsBundle',\n 'JMSSerializerBundle' => 'JMS\\\\SerializerBundle\\\\JMSSerializerBundle',\n 'SonataEasyExtendsBundle' => 'Sonata\\\\EasyExtendsBundle\\\\SonataEasyExtendsBundle',\n 'SonataCoreBundle' => 'Sonata\\\\CoreBundle\\\\SonataCoreBundle',\n 'SonataIntlBundle' => 'Sonata\\\\IntlBundle\\\\SonataIntlBundle',\n 'SonataFormatterBundle' => 'Sonata\\\\FormatterBundle\\\\SonataFormatterBundle',\n 'SonataBlockBundle' => 'Sonata\\\\BlockBundle\\\\SonataBlockBundle',\n 'SonataClassificationBundle' => 'Sonata\\\\ClassificationBundle\\\\SonataClassificationBundle',\n 'SonataDatagridBundle' => 'Sonata\\\\DatagridBundle\\\\SonataDatagridBundle',\n 'MopaBootstrapBundle' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\MopaBootstrapBundle',\n 'FOSJsRoutingBundle' => 'FOS\\\\JsRoutingBundle\\\\FOSJsRoutingBundle',\n 'LexikFormFilterBundle' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\LexikFormFilterBundle',\n 'LiipImagineBundle' => 'Liip\\\\ImagineBundle\\\\LiipImagineBundle',\n 'KnpGaufretteBundle' => 'Knp\\\\Bundle\\\\GaufretteBundle\\\\KnpGaufretteBundle',\n 'WhiteOctoberPagerfantaBundle' => 'WhiteOctober\\\\PagerfantaBundle\\\\WhiteOctoberPagerfantaBundle',\n 'DataDogAuditBundle' => 'DataDog\\\\AuditBundle\\\\DataDogAuditBundle',\n 'GregwarCaptchaBundle' => 'Gregwar\\\\CaptchaBundle\\\\GregwarCaptchaBundle',\n 'LexikJWTAuthenticationBundle' => 'Lexik\\\\Bundle\\\\JWTAuthenticationBundle\\\\LexikJWTAuthenticationBundle',\n 'GesdinetJWTRefreshTokenBundle' => 'Gesdinet\\\\JWTRefreshTokenBundle\\\\GesdinetJWTRefreshTokenBundle',\n 'AppBundle' => 'AppBundle\\\\AppBundle',\n 'DebugBundle' => 'Symfony\\\\Bundle\\\\DebugBundle\\\\DebugBundle',\n 'WebProfilerBundle' => 'Symfony\\\\Bundle\\\\WebProfilerBundle\\\\WebProfilerBundle',\n 'SensioDistributionBundle' => 'Sensio\\\\Bundle\\\\DistributionBundle\\\\SensioDistributionBundle',\n 'SensioGeneratorBundle' => 'Sensio\\\\Bundle\\\\GeneratorBundle\\\\SensioGeneratorBundle',\n 'WebServerBundle' => 'Symfony\\\\Bundle\\\\WebServerBundle\\\\WebServerBundle',\n ),\n 'kernel.charset' => 'UTF-8',\n 'kernel.container_class' => 'appDevDebugProjectContainer',\n 'database_driver' => 'pdo_mysql',\n 'database_host' => '127.0.0.1',\n 'database_port' => NULL,\n 'database_name' => 'siunic_etecsa',\n 'database_user' => 'root',\n 'database_password' => NULL,\n 'mailer_transport' => 'smtp',\n 'mailer_host' => '127.0.0.1',\n 'mailer_user' => '[email protected]',\n 'mailer_password' => 'service',\n 'locale' => 'es',\n 'secret' => '692cd6b4574faf02145126fe2f31c3fdbf88a5fc',\n 'webapp_host' => '127.0.0.1:8000',\n 'webapp_url' => 'http://127.0.0.1:8000',\n 'webapp.logo' => 'logo_etecsa.jpg',\n 'webapp.short_title' => 'SIUNIC',\n 'webapp.title' => 'Sistema Unificado de Cliente Único',\n 'sonata_admin.title' => 'SIUNIC ETECSA',\n 'sonata_admin.short_title' => 'SIUNIC',\n 'sonata_admin.logo_title' => 'logo_etecsa.jpg',\n 'sonata_admin.skin' => 'skin-purple',\n 'sonata_media.cdn.host' => '/uploads/media',\n 'sonata_user.google_authenticator.server' => 'app.symfony-sonata-project.com',\n 'jwt_key_pass_phrase' => '1234',\n 'jwt_token_ttl' => 86400,\n 'security.acl.permission.map.class' => 'Sonata\\\\AdminBundle\\\\Security\\\\Acl\\\\Permission\\\\AdminPermissionMap',\n 'security_user_class' => 'AppBundle\\\\Entity\\\\User\\\\User',\n 'security_group_class' => 'AppBundle\\\\Entity\\\\User\\\\Group',\n 'security_user_group_table' => 'security__user_group',\n 'security_user_admin_class' => 'AppBundle\\\\Admin\\\\User\\\\UserAdmin',\n 'security_group_admin_class' => 'AppBundle\\\\Admin\\\\User\\\\GroupAdmin',\n 'fragment.renderer.hinclude.global_template' => 'hinclude.html.twig',\n 'fragment.path' => '/_fragment',\n 'kernel.secret' => '692cd6b4574faf02145126fe2f31c3fdbf88a5fc',\n 'kernel.http_method_override' => true,\n 'kernel.trusted_hosts' => array(\n\n ),\n 'kernel.default_locale' => 'es',\n 'templating.helper.code.file_link_format' => NULL,\n 'debug.file_link_format' => NULL,\n 'session.metadata.storage_key' => '_sf2_meta',\n 'session.storage.options' => array(\n 'cookie_httponly' => true,\n 'gc_probability' => 1,\n ),\n 'session.metadata.update_threshold' => '0',\n 'form.type_extension.csrf.enabled' => true,\n 'form.type_extension.csrf.field_name' => '_token',\n 'templating.loader.cache.path' => NULL,\n 'templating.engines' => array(\n 0 => 'twig',\n ),\n 'validator.mapping.cache.prefix' => '',\n 'validator.mapping.cache.file' => (__DIR__.'/validation.php'),\n 'validator.translation_domain' => 'validators',\n 'translator.logging' => true,\n 'profiler_listener.only_exceptions' => false,\n 'profiler_listener.only_master_requests' => false,\n 'profiler.storage.dsn' => ('file:'.__DIR__.'/profiler'),\n 'debug.error_handler.throw_at' => -1,\n 'debug.container.dump' => (__DIR__.'/appDevDebugProjectContainer.xml'),\n 'router.options.generator_class' => 'Symfony\\\\Component\\\\Routing\\\\Generator\\\\UrlGenerator',\n 'router.options.generator_base_class' => 'Symfony\\\\Component\\\\Routing\\\\Generator\\\\UrlGenerator',\n 'router.options.generator_dumper_class' => 'Symfony\\\\Component\\\\Routing\\\\Generator\\\\Dumper\\\\PhpGeneratorDumper',\n 'router.options.matcher_class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Routing\\\\RedirectableUrlMatcher',\n 'router.options.matcher_base_class' => 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\Routing\\\\RedirectableUrlMatcher',\n 'router.options.matcher_dumper_class' => 'Symfony\\\\Component\\\\Routing\\\\Matcher\\\\Dumper\\\\PhpMatcherDumper',\n 'router.options.matcher.cache_class' => 'appDevDebugProjectContainerUrlMatcher',\n 'router.options.generator.cache_class' => 'appDevDebugProjectContainerUrlGenerator',\n 'router.request_context.host' => 'localhost',\n 'router.request_context.scheme' => 'http',\n 'router.request_context.base_url' => '',\n 'router.cache_class_prefix' => 'appDevDebugProjectContainer',\n 'request_listener.http_port' => 80,\n 'request_listener.https_port' => 443,\n 'security.authentication.trust_resolver.anonymous_class' => 'Symfony\\\\Component\\\\Security\\\\Core\\\\Authentication\\\\Token\\\\AnonymousToken',\n 'security.authentication.trust_resolver.rememberme_class' => 'Symfony\\\\Component\\\\Security\\\\Core\\\\Authentication\\\\Token\\\\RememberMeToken',\n 'security.role_hierarchy.roles' => array(\n 'SONATA' => array(\n\n ),\n 'ROLE_AUDIT_LOGS_ADMIN' => array(\n 0 => 'ROLE_DATA_DOG_AUDIT_ADMIN_AUDIT_LOG_LIST',\n 1 => 'ROLE_DATA_DOG_AUDIT_ADMIN_AUDIT_LOG_VIEW',\n ),\n 'ROLE_USER' => array(\n 0 => 'ROLE_API',\n 1 => 'ROLE_SONATA_ADMIN',\n ),\n 'ROLE_SONATA_ADMIN' => array(\n 0 => 'ROLE_SONATA_USER_ADMIN_USER_VIEW',\n 1 => 'ROLE_SONATA_USER_ADMIN_USER_EDIT',\n ),\n 'ROLE_ADMIN' => array(\n 0 => 'ROLE_USER',\n 1 => 'ROLE_AUDIT_LOGS_ADMIN',\n ),\n 'ROLE_SUPER_ADMIN' => array(\n 0 => 'ROLE_USER',\n 1 => 'ROLE_ADMIN',\n 2 => 'ROLE_AUDIT_LOGS_ADMIN',\n 3 => 'ROLE_ALLOWED_TO_SWITCH',\n ),\n 'ROLE_APP_USER' => array(\n 0 => 'ROLE_USER',\n 1 => 'ROLE_DASHBOARD_USER',\n ),\n 'ROLE_APP_ADMIN' => array(\n 0 => 'ROLE_USER',\n 1 => 'ROLE_ADMIN',\n ),\n ),\n 'security.access.denied_url' => NULL,\n 'security.authentication.manager.erase_credentials' => true,\n 'security.authentication.session_strategy.strategy' => 'migrate',\n 'security.access.always_authenticate_before_granting' => false,\n 'security.authentication.hide_user_not_found' => true,\n 'twig.exception_listener.controller' => 'FOS\\\\RestBundle\\\\Controller\\\\ExceptionController::showAction',\n 'twig.form.resources' => array(\n 0 => '@IvoryCKEditor/Form/ckeditor_widget.html.twig',\n 1 => 'GregwarCaptchaBundle::captcha.html.twig',\n 2 => 'form_div_layout.html.twig',\n 3 => '@MopaBootstrap/Form/fields.html.twig',\n 4 => 'SonataMediaBundle:Form:media_widgets.html.twig',\n 5 => '@SonataCore/Form/datepicker.html.twig',\n 6 => 'SonataUserBundle:Form:form_admin_fields.html.twig',\n 7 => 'LiipImagineBundle:Form:form_div_layout.html.twig',\n ),\n 'monolog.use_microseconds' => true,\n 'monolog.swift_mailer.handlers' => array(\n\n ),\n 'monolog.handlers_to_channels' => array(\n 'monolog.handler.server_log' => NULL,\n 'monolog.handler.console' => array(\n 'type' => 'exclusive',\n 'elements' => array(\n 0 => 'event',\n 1 => 'doctrine',\n 2 => 'console',\n ),\n ),\n 'monolog.handler.main' => array(\n 'type' => 'exclusive',\n 'elements' => array(\n 0 => 'event',\n ),\n ),\n ),\n 'swiftmailer.class' => 'Swift_Mailer',\n 'swiftmailer.transport.sendmail.class' => 'Swift_Transport_SendmailTransport',\n 'swiftmailer.transport.mail.class' => 'Swift_Transport_MailTransport',\n 'swiftmailer.transport.failover.class' => 'Swift_Transport_FailoverTransport',\n 'swiftmailer.plugin.redirecting.class' => 'Swift_Plugins_RedirectingPlugin',\n 'swiftmailer.plugin.impersonate.class' => 'Swift_Plugins_ImpersonatePlugin',\n 'swiftmailer.plugin.messagelogger.class' => 'Swift_Plugins_MessageLogger',\n 'swiftmailer.plugin.antiflood.class' => 'Swift_Plugins_AntiFloodPlugin',\n 'swiftmailer.transport.smtp.class' => 'Swift_Transport_EsmtpTransport',\n 'swiftmailer.plugin.blackhole.class' => 'Swift_Plugins_BlackholePlugin',\n 'swiftmailer.spool.file.class' => 'Swift_FileSpool',\n 'swiftmailer.spool.memory.class' => 'Swift_MemorySpool',\n 'swiftmailer.email_sender.listener.class' => 'Symfony\\\\Bundle\\\\SwiftmailerBundle\\\\EventListener\\\\EmailSenderListener',\n 'swiftmailer.data_collector.class' => 'Symfony\\\\Bundle\\\\SwiftmailerBundle\\\\DataCollector\\\\MessageDataCollector',\n 'swiftmailer.mailer.default.transport.name' => 'smtp',\n 'swiftmailer.mailer.default.transport.smtp.encryption' => NULL,\n 'swiftmailer.mailer.default.transport.smtp.port' => 25,\n 'swiftmailer.mailer.default.transport.smtp.host' => '127.0.0.1',\n 'swiftmailer.mailer.default.transport.smtp.username' => '[email protected]',\n 'swiftmailer.mailer.default.transport.smtp.password' => 'service',\n 'swiftmailer.mailer.default.transport.smtp.auth_mode' => NULL,\n 'swiftmailer.mailer.default.transport.smtp.timeout' => 30,\n 'swiftmailer.mailer.default.transport.smtp.source_ip' => NULL,\n 'swiftmailer.mailer.default.transport.smtp.local_domain' => NULL,\n 'swiftmailer.spool.default.memory.path' => (__DIR__.'/swiftmailer/spool/default'),\n 'swiftmailer.mailer.default.spool.enabled' => true,\n 'swiftmailer.mailer.default.plugin.impersonate' => NULL,\n 'swiftmailer.mailer.default.single_address' => NULL,\n 'swiftmailer.mailer.default.delivery.enabled' => true,\n 'swiftmailer.spool.enabled' => true,\n 'swiftmailer.delivery.enabled' => true,\n 'swiftmailer.single_address' => NULL,\n 'swiftmailer.mailers' => array(\n 'default' => 'swiftmailer.mailer.default',\n ),\n 'swiftmailer.default_mailer' => 'default',\n 'doctrine_cache.apc.class' => 'Doctrine\\\\Common\\\\Cache\\\\ApcCache',\n 'doctrine_cache.apcu.class' => 'Doctrine\\\\Common\\\\Cache\\\\ApcuCache',\n 'doctrine_cache.array.class' => 'Doctrine\\\\Common\\\\Cache\\\\ArrayCache',\n 'doctrine_cache.chain.class' => 'Doctrine\\\\Common\\\\Cache\\\\ChainCache',\n 'doctrine_cache.couchbase.class' => 'Doctrine\\\\Common\\\\Cache\\\\CouchbaseCache',\n 'doctrine_cache.couchbase.connection.class' => 'Couchbase',\n 'doctrine_cache.couchbase.hostnames' => 'localhost:8091',\n 'doctrine_cache.file_system.class' => 'Doctrine\\\\Common\\\\Cache\\\\FilesystemCache',\n 'doctrine_cache.php_file.class' => 'Doctrine\\\\Common\\\\Cache\\\\PhpFileCache',\n 'doctrine_cache.memcache.class' => 'Doctrine\\\\Common\\\\Cache\\\\MemcacheCache',\n 'doctrine_cache.memcache.connection.class' => 'Memcache',\n 'doctrine_cache.memcache.host' => 'localhost',\n 'doctrine_cache.memcache.port' => 11211,\n 'doctrine_cache.memcached.class' => 'Doctrine\\\\Common\\\\Cache\\\\MemcachedCache',\n 'doctrine_cache.memcached.connection.class' => 'Memcached',\n 'doctrine_cache.memcached.host' => 'localhost',\n 'doctrine_cache.memcached.port' => 11211,\n 'doctrine_cache.mongodb.class' => 'Doctrine\\\\Common\\\\Cache\\\\MongoDBCache',\n 'doctrine_cache.mongodb.collection.class' => 'MongoCollection',\n 'doctrine_cache.mongodb.connection.class' => 'MongoClient',\n 'doctrine_cache.mongodb.server' => 'localhost:27017',\n 'doctrine_cache.predis.client.class' => 'Predis\\\\Client',\n 'doctrine_cache.predis.scheme' => 'tcp',\n 'doctrine_cache.predis.host' => 'localhost',\n 'doctrine_cache.predis.port' => 6379,\n 'doctrine_cache.redis.class' => 'Doctrine\\\\Common\\\\Cache\\\\RedisCache',\n 'doctrine_cache.redis.connection.class' => 'Redis',\n 'doctrine_cache.redis.host' => 'localhost',\n 'doctrine_cache.redis.port' => 6379,\n 'doctrine_cache.riak.class' => 'Doctrine\\\\Common\\\\Cache\\\\RiakCache',\n 'doctrine_cache.riak.bucket.class' => 'Riak\\\\Bucket',\n 'doctrine_cache.riak.connection.class' => 'Riak\\\\Connection',\n 'doctrine_cache.riak.bucket_property_list.class' => 'Riak\\\\BucketPropertyList',\n 'doctrine_cache.riak.host' => 'localhost',\n 'doctrine_cache.riak.port' => 8087,\n 'doctrine_cache.sqlite3.class' => 'Doctrine\\\\Common\\\\Cache\\\\SQLite3Cache',\n 'doctrine_cache.sqlite3.connection.class' => 'SQLite3',\n 'doctrine_cache.void.class' => 'Doctrine\\\\Common\\\\Cache\\\\VoidCache',\n 'doctrine_cache.wincache.class' => 'Doctrine\\\\Common\\\\Cache\\\\WinCacheCache',\n 'doctrine_cache.xcache.class' => 'Doctrine\\\\Common\\\\Cache\\\\XcacheCache',\n 'doctrine_cache.zenddata.class' => 'Doctrine\\\\Common\\\\Cache\\\\ZendDataCache',\n 'doctrine_cache.security.acl.cache.class' => 'Doctrine\\\\Bundle\\\\DoctrineCacheBundle\\\\Acl\\\\Model\\\\AclCache',\n 'doctrine.dbal.logger.chain.class' => 'Doctrine\\\\DBAL\\\\Logging\\\\LoggerChain',\n 'doctrine.dbal.logger.profiling.class' => 'Doctrine\\\\DBAL\\\\Logging\\\\DebugStack',\n 'doctrine.dbal.logger.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\Logger\\\\DbalLogger',\n 'doctrine.dbal.configuration.class' => 'Doctrine\\\\DBAL\\\\Configuration',\n 'doctrine.data_collector.class' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\DataCollector\\\\DoctrineDataCollector',\n 'doctrine.dbal.connection.event_manager.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\ContainerAwareEventManager',\n 'doctrine.dbal.connection_factory.class' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\ConnectionFactory',\n 'doctrine.dbal.events.mysql_session_init.class' => 'Doctrine\\\\DBAL\\\\Event\\\\Listeners\\\\MysqlSessionInit',\n 'doctrine.dbal.events.oracle_session_init.class' => 'Doctrine\\\\DBAL\\\\Event\\\\Listeners\\\\OracleSessionInit',\n 'doctrine.class' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\Registry',\n 'doctrine.entity_managers' => array(\n 'default' => 'doctrine.orm.default_entity_manager',\n ),\n 'doctrine.default_entity_manager' => 'default',\n 'doctrine.dbal.connection_factory.types' => array(\n 'json' => array(\n 'class' => 'Sonata\\\\Doctrine\\\\Types\\\\JsonType',\n 'commented' => true,\n ),\n ),\n 'doctrine.connections' => array(\n 'default' => 'doctrine.dbal.default_connection',\n ),\n 'doctrine.default_connection' => 'default',\n 'doctrine.orm.configuration.class' => 'Doctrine\\\\ORM\\\\Configuration',\n 'doctrine.orm.entity_manager.class' => 'Doctrine\\\\ORM\\\\EntityManager',\n 'doctrine.orm.manager_configurator.class' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\ManagerConfigurator',\n 'doctrine.orm.cache.array.class' => 'Doctrine\\\\Common\\\\Cache\\\\ArrayCache',\n 'doctrine.orm.cache.apc.class' => 'Doctrine\\\\Common\\\\Cache\\\\ApcCache',\n 'doctrine.orm.cache.memcache.class' => 'Doctrine\\\\Common\\\\Cache\\\\MemcacheCache',\n 'doctrine.orm.cache.memcache_host' => 'localhost',\n 'doctrine.orm.cache.memcache_port' => 11211,\n 'doctrine.orm.cache.memcache_instance.class' => 'Memcache',\n 'doctrine.orm.cache.memcached.class' => 'Doctrine\\\\Common\\\\Cache\\\\MemcachedCache',\n 'doctrine.orm.cache.memcached_host' => 'localhost',\n 'doctrine.orm.cache.memcached_port' => 11211,\n 'doctrine.orm.cache.memcached_instance.class' => 'Memcached',\n 'doctrine.orm.cache.redis.class' => 'Doctrine\\\\Common\\\\Cache\\\\RedisCache',\n 'doctrine.orm.cache.redis_host' => 'localhost',\n 'doctrine.orm.cache.redis_port' => 6379,\n 'doctrine.orm.cache.redis_instance.class' => 'Redis',\n 'doctrine.orm.cache.xcache.class' => 'Doctrine\\\\Common\\\\Cache\\\\XcacheCache',\n 'doctrine.orm.cache.wincache.class' => 'Doctrine\\\\Common\\\\Cache\\\\WinCacheCache',\n 'doctrine.orm.cache.zenddata.class' => 'Doctrine\\\\Common\\\\Cache\\\\ZendDataCache',\n 'doctrine.orm.metadata.driver_chain.class' => 'Doctrine\\\\Common\\\\Persistence\\\\Mapping\\\\Driver\\\\MappingDriverChain',\n 'doctrine.orm.metadata.annotation.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\AnnotationDriver',\n 'doctrine.orm.metadata.xml.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\SimplifiedXmlDriver',\n 'doctrine.orm.metadata.yml.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\SimplifiedYamlDriver',\n 'doctrine.orm.metadata.php.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\PHPDriver',\n 'doctrine.orm.metadata.staticphp.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\Driver\\\\StaticPHPDriver',\n 'doctrine.orm.proxy_cache_warmer.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\CacheWarmer\\\\ProxyCacheWarmer',\n 'form.type_guesser.doctrine.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\Form\\\\DoctrineOrmTypeGuesser',\n 'doctrine.orm.validator.unique.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\Validator\\\\Constraints\\\\UniqueEntityValidator',\n 'doctrine.orm.validator_initializer.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\Validator\\\\DoctrineInitializer',\n 'doctrine.orm.security.user.provider.class' => 'Symfony\\\\Bridge\\\\Doctrine\\\\Security\\\\User\\\\EntityUserProvider',\n 'doctrine.orm.listeners.resolve_target_entity.class' => 'Doctrine\\\\ORM\\\\Tools\\\\ResolveTargetEntityListener',\n 'doctrine.orm.listeners.attach_entity_listeners.class' => 'Doctrine\\\\ORM\\\\Tools\\\\AttachEntityListenersListener',\n 'doctrine.orm.naming_strategy.default.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\DefaultNamingStrategy',\n 'doctrine.orm.naming_strategy.underscore.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\UnderscoreNamingStrategy',\n 'doctrine.orm.quote_strategy.default.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\DefaultQuoteStrategy',\n 'doctrine.orm.quote_strategy.ansi.class' => 'Doctrine\\\\ORM\\\\Mapping\\\\AnsiQuoteStrategy',\n 'doctrine.orm.entity_listener_resolver.class' => 'Doctrine\\\\Bundle\\\\DoctrineBundle\\\\Mapping\\\\ContainerAwareEntityListenerResolver',\n 'doctrine.orm.second_level_cache.default_cache_factory.class' => 'Doctrine\\\\ORM\\\\Cache\\\\DefaultCacheFactory',\n 'doctrine.orm.second_level_cache.default_region.class' => 'Doctrine\\\\ORM\\\\Cache\\\\Region\\\\DefaultRegion',\n 'doctrine.orm.second_level_cache.filelock_region.class' => 'Doctrine\\\\ORM\\\\Cache\\\\Region\\\\FileLockRegion',\n 'doctrine.orm.second_level_cache.logger_chain.class' => 'Doctrine\\\\ORM\\\\Cache\\\\Logging\\\\CacheLoggerChain',\n 'doctrine.orm.second_level_cache.logger_statistics.class' => 'Doctrine\\\\ORM\\\\Cache\\\\Logging\\\\StatisticsCacheLogger',\n 'doctrine.orm.second_level_cache.cache_configuration.class' => 'Doctrine\\\\ORM\\\\Cache\\\\CacheConfiguration',\n 'doctrine.orm.second_level_cache.regions_configuration.class' => 'Doctrine\\\\ORM\\\\Cache\\\\RegionsConfiguration',\n 'doctrine.orm.auto_generate_proxy_classes' => true,\n 'doctrine.orm.proxy_dir' => (__DIR__.'/doctrine/orm/Proxies'),\n 'doctrine.orm.proxy_namespace' => 'Proxies',\n 'sensio_framework_extra.view.guesser.class' => 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\Templating\\\\TemplateGuesser',\n 'sensio_framework_extra.controller.listener.class' => 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\EventListener\\\\ControllerListener',\n 'sensio_framework_extra.routing.loader.annot_dir.class' => 'Symfony\\\\Component\\\\Routing\\\\Loader\\\\AnnotationDirectoryLoader',\n 'sensio_framework_extra.routing.loader.annot_file.class' => 'Symfony\\\\Component\\\\Routing\\\\Loader\\\\AnnotationFileLoader',\n 'sensio_framework_extra.routing.loader.annot_class.class' => 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\Routing\\\\AnnotatedRouteControllerLoader',\n 'sensio_framework_extra.converter.listener.class' => 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\EventListener\\\\ParamConverterListener',\n 'sensio_framework_extra.converter.manager.class' => 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\Request\\\\ParamConverter\\\\ParamConverterManager',\n 'sensio_framework_extra.converter.doctrine.class' => 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\Request\\\\ParamConverter\\\\DoctrineParamConverter',\n 'sensio_framework_extra.converter.datetime.class' => 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\Request\\\\ParamConverter\\\\DateTimeParamConverter',\n 'sensio_framework_extra.view.listener.class' => 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\EventListener\\\\TemplateListener',\n 'jms_aop.cache_dir' => (__DIR__.'/jms_aop'),\n 'jms_aop.interceptor_loader.class' => 'JMS\\\\AopBundle\\\\Aop\\\\InterceptorLoader',\n 'security.secured_services' => array(\n\n ),\n 'security.access.method_interceptor.class' => 'JMS\\\\SecurityExtraBundle\\\\Security\\\\Authorization\\\\Interception\\\\MethodSecurityInterceptor',\n 'security.access.method_access_control' => array(\n\n ),\n 'security.access.remembering_access_decision_manager.class' => 'JMS\\\\SecurityExtraBundle\\\\Security\\\\Authorization\\\\RememberingAccessDecisionManager',\n 'security.access.run_as_manager.class' => 'JMS\\\\SecurityExtraBundle\\\\Security\\\\Authorization\\\\RunAsManager',\n 'security.authentication.provider.run_as.class' => 'JMS\\\\SecurityExtraBundle\\\\Security\\\\Authentication\\\\Provider\\\\RunAsAuthenticationProvider',\n 'security.run_as.key' => 'RunAsToken',\n 'security.run_as.role_prefix' => 'ROLE_',\n 'security.access.after_invocation_manager.class' => 'JMS\\\\SecurityExtraBundle\\\\Security\\\\Authorization\\\\AfterInvocation\\\\AfterInvocationManager',\n 'security.access.after_invocation.acl_provider.class' => 'JMS\\\\SecurityExtraBundle\\\\Security\\\\Authorization\\\\AfterInvocation\\\\AclAfterInvocationProvider',\n 'security.access.iddqd_voter.class' => 'JMS\\\\SecurityExtraBundle\\\\Security\\\\Authorization\\\\Voter\\\\IddqdVoter',\n 'security.extra.metadata_factory.class' => 'Metadata\\\\MetadataFactory',\n 'security.extra.lazy_loading_driver.class' => 'Metadata\\\\Driver\\\\LazyLoadingDriver',\n 'security.extra.driver_chain.class' => 'Metadata\\\\Driver\\\\DriverChain',\n 'security.extra.annotation_driver.class' => 'JMS\\\\SecurityExtraBundle\\\\Metadata\\\\Driver\\\\AnnotationDriver',\n 'security.extra.file_cache.class' => 'Metadata\\\\Cache\\\\FileCache',\n 'security.access.secure_all_services' => false,\n 'security.extra.cache_dir' => (__DIR__.'/jms_security'),\n 'security.authenticated_voter.disabled' => false,\n 'security.role_voter.disabled' => false,\n 'security.acl_voter.disabled' => false,\n 'security.extra.iddqd_ignore_roles' => array(\n 0 => 'ROLE_PREVIOUS_ADMIN',\n ),\n 'security.iddqd_aliases' => array(\n\n ),\n 'doctrine_migrations.namespace' => 'Application\\\\Migrations',\n 'doctrine_migrations.table_name' => 'migration_versions',\n 'doctrine_migrations.name' => 'Application Migrations',\n 'doctrine_migrations.custom_template' => NULL,\n 'doctrine_migrations.organize_migrations' => false,\n 'knp_menu.factory.class' => 'Knp\\\\Menu\\\\MenuFactory',\n 'knp_menu.factory_extension.routing.class' => 'Knp\\\\Menu\\\\Integration\\\\Symfony\\\\RoutingExtension',\n 'knp_menu.helper.class' => 'Knp\\\\Menu\\\\Twig\\\\Helper',\n 'knp_menu.matcher.class' => 'Knp\\\\Menu\\\\Matcher\\\\Matcher',\n 'knp_menu.menu_provider.chain.class' => 'Knp\\\\Menu\\\\Provider\\\\ChainProvider',\n 'knp_menu.menu_provider.container_aware.class' => 'Knp\\\\Bundle\\\\MenuBundle\\\\Provider\\\\ContainerAwareProvider',\n 'knp_menu.menu_provider.builder_alias.class' => 'Knp\\\\Bundle\\\\MenuBundle\\\\Provider\\\\BuilderAliasProvider',\n 'knp_menu.renderer_provider.class' => 'Knp\\\\Bundle\\\\MenuBundle\\\\Renderer\\\\ContainerAwareProvider',\n 'knp_menu.renderer.list.class' => 'Knp\\\\Menu\\\\Renderer\\\\ListRenderer',\n 'knp_menu.renderer.list.options' => array(\n\n ),\n 'knp_menu.listener.voters.class' => 'Knp\\\\Bundle\\\\MenuBundle\\\\EventListener\\\\VoterInitializerListener',\n 'knp_menu.voter.router.class' => 'Knp\\\\Menu\\\\Matcher\\\\Voter\\\\RouteVoter',\n 'knp_menu.twig.extension.class' => 'Knp\\\\Menu\\\\Twig\\\\MenuExtension',\n 'knp_menu.renderer.twig.class' => 'Knp\\\\Menu\\\\Renderer\\\\TwigRenderer',\n 'knp_menu.renderer.twig.options' => array(\n\n ),\n 'knp_menu.renderer.twig.template' => '@KnpMenu/menu.html.twig',\n 'knp_menu.default_renderer' => 'twig',\n 'templating.helper.markdown.class' => 'Knp\\\\Bundle\\\\MarkdownBundle\\\\Helper\\\\MarkdownHelper',\n 'knp_paginator.class' => 'Knp\\\\Component\\\\Pager\\\\Paginator',\n 'knp_paginator.helper.processor.class' => 'Knp\\\\Bundle\\\\PaginatorBundle\\\\Helper\\\\Processor',\n 'knp_paginator.template.pagination' => 'MopaBootstrapBundle:Pagination:sliding.html.twig',\n 'knp_paginator.template.filtration' => '@KnpPaginator/Pagination/filtration.html.twig',\n 'knp_paginator.template.sortable' => '@KnpPaginator/Pagination/sortable_link.html.twig',\n 'knp_paginator.page_range' => 5,\n 'fos_user.backend_type_orm' => true,\n 'fos_user.security.interactive_login_listener.class' => 'FOS\\\\UserBundle\\\\EventListener\\\\LastLoginListener',\n 'fos_user.security.login_manager.class' => 'FOS\\\\UserBundle\\\\Security\\\\LoginManager',\n 'fos_user.resetting.email.template' => '@FOSUser/Resetting/email.txt.twig',\n 'fos_user.registration.confirmation.template' => '@FOSUser/Registration/email.txt.twig',\n 'fos_user.storage' => 'orm',\n 'fos_user.firewall_name' => 'main',\n 'fos_user.model_manager_name' => NULL,\n 'fos_user.model.user.class' => 'AppBundle\\\\Entity\\\\User\\\\User',\n 'fos_user.profile.form.type' => 'AppBundle\\\\Form\\\\User\\\\Type\\\\ProfileFormType',\n 'fos_user.profile.form.name' => 'fos_user_profile_form',\n 'fos_user.profile.form.validation_groups' => array(\n 0 => 'Profile',\n 1 => 'Default',\n ),\n 'fos_user.registration.confirmation.from_email' => array(\n '[email protected]' => 'webmaster',\n ),\n 'fos_user.registration.confirmation.enabled' => true,\n 'fos_user.registration.form.type' => 'AppBundle\\\\Form\\\\User\\\\Type\\\\RegistrationFormType',\n 'fos_user.registration.form.name' => 'fos_user_registration_form',\n 'fos_user.registration.form.validation_groups' => array(\n 0 => 'Registration',\n 1 => 'Default',\n ),\n 'fos_user.change_password.form.type' => 'FOS\\\\UserBundle\\\\Form\\\\Type\\\\ChangePasswordFormType',\n 'fos_user.change_password.form.name' => 'fos_user_change_password_form',\n 'fos_user.change_password.form.validation_groups' => array(\n 0 => 'ChangePassword',\n 1 => 'Default',\n ),\n 'fos_user.resetting.email.from_email' => array(\n '[email protected]' => 'webmaster',\n ),\n 'fos_user.resetting.retry_ttl' => 7200,\n 'fos_user.resetting.token_ttl' => 86400,\n 'fos_user.resetting.form.type' => 'FOS\\\\UserBundle\\\\Form\\\\Type\\\\ResettingFormType',\n 'fos_user.resetting.form.name' => 'fos_user_resetting_form',\n 'fos_user.resetting.form.validation_groups' => array(\n 0 => 'ResetPassword',\n 1 => 'Default',\n ),\n 'fos_user.group_manager.class' => 'FOS\\\\UserBundle\\\\Doctrine\\\\GroupManager',\n 'fos_user.model.group.class' => 'AppBundle\\\\Entity\\\\User\\\\Group',\n 'fos_user.group.form.type' => 'FOS\\\\UserBundle\\\\Form\\\\Type\\\\GroupFormType',\n 'fos_user.group.form.name' => 'fos_user_group_form',\n 'fos_user.group.form.validation_groups' => array(\n 0 => 'Registration',\n 1 => 'Default',\n ),\n 'sonata.user.admin.groupname' => 'sonata_user',\n 'sonata.user.admin.label_catalogue' => 'SonataUserBundle',\n 'sonata.user.admin.groupicon' => '<i class=\\'fa fa-users\\'></i>',\n 'sonata.user.admin.user.class' => 'AppBundle\\\\Admin\\\\User\\\\UserAdmin',\n 'sonata.user.admin.group.class' => 'AppBundle\\\\Admin\\\\User\\\\GroupAdmin',\n 'sonata.user.admin.user.entity' => 'AppBundle\\\\Entity\\\\User\\\\User',\n 'sonata.user.admin.group.entity' => 'AppBundle\\\\Entity\\\\User\\\\Group',\n 'sonata.user.admin.user.translation_domain' => 'SonataUserBundle',\n 'sonata.user.admin.group.translation_domain' => 'SonataUserBundle',\n 'sonata.user.admin.user.controller' => 'SonataAdminBundle:CRUD',\n 'sonata.user.admin.group.controller' => 'SonataAdminBundle:CRUD',\n 'sonata.user.default_avatar' => 'bundles/sonatauser/default_avatar.png',\n 'sonata.user.impersonating' => array(\n 'route' => 'page_slug',\n 'parameters' => array(\n 'path' => '/',\n ),\n ),\n 'sonata.user.google.authenticator.enabled' => false,\n 'sonata.user.profile.form.type' => 'application_sonata_user_profile',\n 'sonata.user.profile.form.name' => 'application_sonata_user_profile_form',\n 'sonata.user.profile.form.validation_groups' => array(\n 0 => 'Profile',\n 1 => 'Default',\n ),\n 'sonata.user.register.confirm.redirect_route' => 'sonata_user_profile_show',\n 'sonata.user.register.confirm.redirect_route_params' => array(\n\n ),\n 'sonata.user.configuration.profile_blocks' => array(\n 0 => array(\n 'position' => 'left',\n 'type' => 'sonata.block.service.text',\n 'settings' => array(\n 'content' => '<h2>Welcome!</h2> <p>This is a sample user profile dashboard, feel free to override it in the configuration! Want to make this text dynamic? For instance display the user\\'s name? Create a dedicated block and edit the configuration!</p>',\n ),\n ),\n ),\n 'sonata.user.registration.form.options' => array(\n 'horizontal_input_wrapper_class' => 'col-lg-8',\n 'horizontal_label_class' => 'col-lg-4 control-label',\n ),\n 'sonata.user.registration.form.type' => 'sonata_user_registration',\n 'sonata.user.registration.form.name' => 'sonata_user_registration_form',\n 'sonata.user.registration.form.validation_groups' => array(\n 0 => 'Registration',\n 1 => 'Default',\n ),\n 'sonata.media.provider.image.class' => 'Sonata\\\\MediaBundle\\\\Provider\\\\ImageProvider',\n 'sonata.media.provider.file.class' => 'Sonata\\\\MediaBundle\\\\Provider\\\\FileProvider',\n 'sonata.media.provider.youtube.class' => 'Sonata\\\\MediaBundle\\\\Provider\\\\YouTubeProvider',\n 'sonata.media.provider.dailymotion.class' => 'Sonata\\\\MediaBundle\\\\Provider\\\\DailyMotionProvider',\n 'sonata.media.provider.vimeo.class' => 'Sonata\\\\MediaBundle\\\\Provider\\\\VimeoProvider',\n 'sonata.media.thumbnail.format' => 'Sonata\\\\MediaBundle\\\\Thumbnail\\\\FormatThumbnail',\n 'sonata.media.thumbnail.format.default' => 'jpg',\n 'sonata.media.thumbnail.liip_imagine' => 'Sonata\\\\MediaBundle\\\\Thumbnail\\\\LiipImagineThumbnail',\n 'sonata.media.pool.class' => 'Sonata\\\\MediaBundle\\\\Provider\\\\Pool',\n 'sonata.media.resizer.simple.class' => 'Sonata\\\\MediaBundle\\\\Resizer\\\\SimpleResizer',\n 'sonata.media.resizer.square.class' => 'Sonata\\\\MediaBundle\\\\Resizer\\\\SquareResizer',\n 'sonata.media.adapter.image.gd.class' => 'Imagine\\\\Gd\\\\Imagine',\n 'sonata.media.adapter.image.imagick.class' => 'Imagine\\\\Imagick\\\\Imagine',\n 'sonata.media.adapter.image.gmagick.class' => 'Imagine\\\\Gmagick\\\\Imagine',\n 'sonata.media.metadata.proxy.class' => 'Sonata\\\\MediaBundle\\\\Metadata\\\\ProxyMetadataBuilder',\n 'sonata.media.metadata.amazon.class' => 'Sonata\\\\MediaBundle\\\\Metadata\\\\AmazonMetadataBuilder',\n 'sonata.media.metadata.noop.class' => 'Sonata\\\\MediaBundle\\\\Metadata\\\\NoopMetadataBuilder',\n 'sonata.media.adapater.filesystem.opencloud.class' => '',\n 'sonata.media.block.media.class' => 'Sonata\\\\MediaBundle\\\\Block\\\\MediaBlockService',\n 'sonata.media.block.feature_media.class' => 'Sonata\\\\MediaBundle\\\\Block\\\\FeatureMediaBlockService',\n 'sonata.media.block.gallery.class' => 'Sonata\\\\MediaBundle\\\\Block\\\\GalleryBlockService',\n 'sonata.media.block.gallery_list.class' => 'Sonata\\\\MediaBundle\\\\Block\\\\GalleryListBlockService',\n 'sonata.media.manager.media.class' => 'Sonata\\\\MediaBundle\\\\Entity\\\\MediaManager',\n 'sonata.media.manager.gallery.class' => 'Sonata\\\\MediaBundle\\\\Entity\\\\GalleryManager',\n 'sonata.media.admin.groupname' => 'sonata_media',\n 'sonata.media.admin.groupicon' => '<i class=\\'fa fa-image\\'></i>',\n 'sonata.media.admin.media.class' => 'Sonata\\\\MediaBundle\\\\Admin\\\\ORM\\\\MediaAdmin',\n 'sonata.media.admin.media.controller' => 'SonataMediaBundle:MediaAdmin',\n 'sonata.media.admin.media.translation_domain' => 'SonataMediaBundle',\n 'sonata.media.admin.gallery.class' => 'Sonata\\\\MediaBundle\\\\Admin\\\\GalleryAdmin',\n 'sonata.media.admin.gallery.controller' => 'SonataMediaBundle:GalleryAdmin',\n 'sonata.media.admin.gallery.translation_domain' => 'SonataMediaBundle',\n 'sonata.media.admin.gallery_has_media.class' => 'Sonata\\\\MediaBundle\\\\Admin\\\\GalleryHasMediaAdmin',\n 'sonata.media.admin.gallery_has_media.controller' => 'SonataAdminBundle:CRUD',\n 'sonata.media.admin.gallery_has_media.translation_domain' => 'SonataMediaBundle',\n 'sonata.media.admin_format' => array(\n 'width' => 200,\n 'height' => false,\n 'quality' => 90,\n 'format' => 'jpg',\n 'constraint' => true,\n ),\n 'sonata.media.resizer.simple.adapter.mode' => 'inset',\n 'sonata.media.resizer.square.adapter.mode' => 'inset',\n 'sonata.media.admin.media.entity' => 'AppBundle\\\\Entity\\\\Media\\\\Media',\n 'sonata.media.admin.gallery.entity' => 'AppBundle\\\\Entity\\\\Media\\\\Gallery',\n 'sonata.media.admin.gallery_has_media.entity' => 'AppBundle\\\\Entity\\\\Media\\\\GalleryHasMedia',\n 'sonata.media.media.class' => 'AppBundle\\\\Entity\\\\Media\\\\Media',\n 'sonata.media.gallery.class' => 'AppBundle\\\\Entity\\\\Media\\\\Gallery',\n 'sonata.admin.twig.extension.x_editable_type_mapping' => array(\n 'choice' => 'select',\n 'boolean' => 'select',\n 'text' => 'text',\n 'textarea' => 'textarea',\n 'html' => 'textarea',\n 'email' => 'email',\n 'string' => 'text',\n 'smallint' => 'text',\n 'bigint' => 'text',\n 'integer' => 'number',\n 'decimal' => 'number',\n 'currency' => 'number',\n 'percent' => 'number',\n 'url' => 'url',\n 'date' => 'date',\n ),\n 'sonata.admin.configuration.global_search.empty_boxes' => 'show',\n 'sonata.admin.configuration.templates' => array(\n 'history_revision_timestamp' => '@SonataIntl/CRUD/history_revision_timestamp.html.twig',\n 'user_block' => '@SonataUser/Admin/Core/user_block.html.twig',\n 'layout' => 'AppBundle:Admin:standard_layout.html.twig',\n 'ajax' => 'SonataAdminBundle::ajax_layout.html.twig',\n 'list' => 'SonataAdminBundle:CRUD:list.html.twig',\n 'show' => 'SonataAdminBundle:CRUD:show.html.twig',\n 'edit' => 'SonataAdminBundle:CRUD:edit.html.twig',\n 'base_list_field' => 'AppBundle:Admin:CRUD/base_list_field.html.twig',\n 'dashboard' => 'AppBundle:Admin:dashboard.html.twig',\n 'add_block' => '@SonataAdmin/Core/add_block.html.twig',\n 'search' => '@SonataAdmin/Core/search.html.twig',\n 'filter' => '@SonataAdmin/Form/filter_admin_fields.html.twig',\n 'show_compare' => '@SonataAdmin/CRUD/show_compare.html.twig',\n 'preview' => '@SonataAdmin/CRUD/preview.html.twig',\n 'history' => '@SonataAdmin/CRUD/history.html.twig',\n 'acl' => '@SonataAdmin/CRUD/acl.html.twig',\n 'action' => '@SonataAdmin/CRUD/action.html.twig',\n 'select' => '@SonataAdmin/CRUD/list__select.html.twig',\n 'list_block' => '@SonataAdmin/Block/block_admin_list.html.twig',\n 'search_result_block' => '@SonataAdmin/Block/block_search_result.html.twig',\n 'short_object_description' => '@SonataAdmin/Helper/short-object-description.html.twig',\n 'delete' => '@SonataAdmin/CRUD/delete.html.twig',\n 'batch' => '@SonataAdmin/CRUD/list__batch.html.twig',\n 'batch_confirmation' => '@SonataAdmin/CRUD/batch_confirmation.html.twig',\n 'inner_list_row' => '@SonataAdmin/CRUD/list_inner_row.html.twig',\n 'outer_list_rows_mosaic' => '@SonataAdmin/CRUD/list_outer_rows_mosaic.html.twig',\n 'outer_list_rows_list' => '@SonataAdmin/CRUD/list_outer_rows_list.html.twig',\n 'outer_list_rows_tree' => '@SonataAdmin/CRUD/list_outer_rows_tree.html.twig',\n 'pager_links' => '@SonataAdmin/Pager/links.html.twig',\n 'pager_results' => '@SonataAdmin/Pager/results.html.twig',\n 'tab_menu_template' => '@SonataAdmin/Core/tab_menu_template.html.twig',\n 'knp_menu_template' => '@SonataAdmin/Menu/sonata_menu.html.twig',\n 'action_create' => '@SonataAdmin/CRUD/dashboard__action_create.html.twig',\n 'button_acl' => '@SonataAdmin/Button/acl_button.html.twig',\n 'button_create' => '@SonataAdmin/Button/create_button.html.twig',\n 'button_edit' => '@SonataAdmin/Button/edit_button.html.twig',\n 'button_history' => '@SonataAdmin/Button/history_button.html.twig',\n 'button_list' => '@SonataAdmin/Button/list_button.html.twig',\n 'button_show' => '@SonataAdmin/Button/show_button.html.twig',\n ),\n 'sonata.admin.configuration.admin_services' => array(\n\n ),\n 'sonata.admin.configuration.dashboard_groups' => array(\n 'sonata.admin.group.administration' => array(\n 'label' => 'sonata_administration',\n 'label_catalogue' => 'SonataAdminBundle',\n 'icon' => '<i class=\"glyphicon glyphicon-user\"></i>',\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n 'roles' => array(\n\n ),\n ),\n 'sonata.admin.group.site_builder' => array(\n 'label' => 'sonata_page',\n 'label_catalogue' => 'SonataPageBundle',\n 'icon' => '<i class=\"fa fa-puzzle-piece\"></i>',\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n 'roles' => array(\n\n ),\n ),\n 'sonata.admin.group.classification' => array(\n 'label' => 'sonata_classification',\n 'label_catalogue' => 'SonataClassificationBundle',\n 'icon' => '<i class=\"fa fa-sitemap\"></i>',\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n 'roles' => array(\n\n ),\n ),\n 'sonata.admin.group.content' => array(\n 'label' => 'sonata_media',\n 'label_catalogue' => 'SonataMediaBundle',\n 'icon' => '<i class=\"fa fa-th\"></i>',\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n 'roles' => array(\n\n ),\n ),\n 'administration' => array(\n 'label' => 'sonata_administration',\n 'label_catalogue' => 'SonataAdminBundle',\n 'icon' => '<i class=\"glyphicon glyphicon-user\"></i>',\n 'items' => array(\n 0 => array(\n 'admin' => 'sonata.user.admin.user',\n 'label' => '',\n 'route' => '',\n 'route_params' => array(\n\n ),\n 'route_absolute' => false,\n 'roles' => array(\n\n ),\n ),\n 1 => array(\n 'admin' => 'sonata.user.admin.group',\n 'label' => '',\n 'route' => '',\n 'route_params' => array(\n\n ),\n 'route_absolute' => false,\n 'roles' => array(\n\n ),\n ),\n 2 => array(\n 'admin' => 'data_dog_audit.admin.audit_log',\n 'label' => '',\n 'route' => '',\n 'route_params' => array(\n\n ),\n 'route_absolute' => false,\n 'roles' => array(\n\n ),\n ),\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n 'roles' => array(\n\n ),\n ),\n 'admin' => array(\n 'label' => 'admin.dashboard.menu.admin.label',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_ADMIN',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'general' => array(\n 'label' => 'Datos Generales',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_ADMIN',\n 1 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_agencia' => array(\n 'label' => 'Contratos Agencia Persona Jurídica',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_areas' => array(\n 'label' => 'Contratos Áreas de Internet',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_arrendamiento_pizarra' => array(\n 'label' => 'Contratos Arrendamiento de Pizarras',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_arrendamiento_redes' => array(\n 'label' => 'Contratos Arrendamiento de Redes',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_compra_venta_pizarra' => array(\n 'label' => 'Contratos Compra Venta Pizarras',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_compra_venta' => array(\n 'label' => 'Contratos Compra Venta',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_instalacion_pizarra' => array(\n 'label' => 'Contratos Instalacion de Pizarras',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_mantenimiento_pizarra' => array(\n 'label' => 'Contratos Mantenimiento de Pizarras',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_prestacion_servicios_ct' => array(\n 'label' => 'Contratos Prestacion de Servicios CT',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_prestacion_servicios' => array(\n 'label' => 'Contratos Prestacion de Servicios',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'contrato_recarga_pos' => array(\n 'label' => 'Contratos Recarga por POS',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n 'user' => array(\n 'label' => 'admin.dashboard.menu.user.label',\n 'label_catalogue' => 'AppBundle',\n 'icon' => '<i class=\"fa fa-list-alt\"></i>',\n 'roles' => array(\n 0 => 'ROLE_USER',\n ),\n 'items' => array(\n\n ),\n 'on_top' => false,\n 'keep_open' => false,\n 'item_adds' => array(\n\n ),\n ),\n ),\n 'sonata.admin.configuration.dashboard_blocks' => array(\n 0 => array(\n 'position' => 'left',\n 'type' => 'sonata.admin.block.admin_list',\n 'settings' => array(\n 'groups' => array(\n 0 => 'administration',\n 1 => 'contrato_agencia',\n 2 => 'contrato_recarga_pos',\n 3 => 'contrato_prestacion_servicios',\n 4 => 'contrato_compra_venta',\n 5 => 'contrato_arrendamiento_redes',\n 6 => 'contrato_instalacion_pizarra',\n 7 => 'contrato_compra_venta_pizarra',\n 8 => 'contrato_mantenimiento_pizarra',\n ),\n ),\n 'roles' => array(\n\n ),\n 'class' => 'col-md-4',\n ),\n 1 => array(\n 'position' => 'right',\n 'type' => 'sonata.admin.block.admin_list',\n 'settings' => array(\n 'groups' => array(\n 0 => 'admin',\n 1 => 'user',\n 2 => 'contrato_prestacion_servicios_ct',\n 3 => 'contrato_areas',\n 4 => 'contrato_arrendamiento_pizarra',\n ),\n ),\n 'roles' => array(\n\n ),\n 'class' => 'col-md-4',\n ),\n ),\n 'sonata.admin.configuration.sort_admins' => false,\n 'sonata.admin.configuration.breadcrumbs' => array(\n 'child_admin_route' => 'edit',\n ),\n 'sonata.admin.security.acl_user_manager' => 'fos_user.user_manager',\n 'sonata.admin.configuration.security.role_admin' => 'ROLE_SONATA_ADMIN',\n 'sonata.admin.configuration.security.role_super_admin' => 'ROLE_SUPER_ADMIN',\n 'sonata.admin.configuration.security.information' => array(\n 'EDIT' => array(\n 0 => 'EDIT',\n ),\n 'LIST' => array(\n 0 => 'LIST',\n ),\n 'CREATE' => array(\n 0 => 'CREATE',\n ),\n 'VIEW' => array(\n 0 => 'VIEW',\n ),\n 'DELETE' => array(\n 0 => 'DELETE',\n ),\n 'EXPORT' => array(\n 0 => 'EXPORT',\n ),\n 'ALL' => array(\n 0 => 'ALL',\n ),\n ),\n 'sonata.admin.configuration.security.admin_permissions' => array(\n 0 => 'CREATE',\n 1 => 'LIST',\n 2 => 'DELETE',\n 3 => 'UNDELETE',\n 4 => 'EXPORT',\n 5 => 'OPERATOR',\n 6 => 'MASTER',\n ),\n 'sonata.admin.configuration.security.object_permissions' => array(\n 0 => 'VIEW',\n 1 => 'EDIT',\n 2 => 'DELETE',\n 3 => 'UNDELETE',\n 4 => 'OPERATOR',\n 5 => 'MASTER',\n 6 => 'OWNER',\n ),\n 'sonata.admin.security.handler.noop.class' => 'Sonata\\\\AdminBundle\\\\Security\\\\Handler\\\\NoopSecurityHandler',\n 'sonata.admin.security.handler.role.class' => 'Sonata\\\\AdminBundle\\\\Security\\\\Handler\\\\RoleSecurityHandler',\n 'sonata.admin.security.handler.acl.class' => 'Sonata\\\\AdminBundle\\\\Security\\\\Handler\\\\AclSecurityHandler',\n 'sonata.admin.security.mask.builder.class' => 'Sonata\\\\AdminBundle\\\\Security\\\\Acl\\\\Permission\\\\MaskBuilder',\n 'sonata.admin.manipulator.acl.admin.class' => 'Sonata\\\\AdminBundle\\\\Util\\\\AdminAclManipulator',\n 'sonata.admin.object.manipulator.acl.admin.class' => 'Sonata\\\\AdminBundle\\\\Util\\\\AdminObjectAclManipulator',\n 'sonata.admin.extension.map' => array(\n 'admins' => array(\n\n ),\n 'excludes' => array(\n\n ),\n 'implements' => array(\n\n ),\n 'extends' => array(\n\n ),\n 'instanceof' => array(\n\n ),\n 'uses' => array(\n\n ),\n ),\n 'sonata.admin.configuration.filters.persist' => false,\n 'sonata.admin.configuration.filters.persister' => 'sonata.admin.filter_persister.session',\n 'sonata.admin.configuration.show.mosaic.button' => true,\n 'sonata.admin.configuration.translate_group_label' => false,\n 'sonata.admin.manipulator.acl.object.orm.class' => 'Sonata\\\\DoctrineORMAdminBundle\\\\Util\\\\ObjectAclManipulator',\n 'sonata_doctrine_orm_admin.entity_manager' => NULL,\n 'sonata_doctrine_orm_admin.templates' => array(\n 'types' => array(\n 'list' => array(\n 'array' => '@SonataAdmin/CRUD/list_array.html.twig',\n 'boolean' => '@SonataAdmin/CRUD/list_boolean.html.twig',\n 'date' => '@SonataIntl/CRUD/list_date.html.twig',\n 'time' => '@SonataAdmin/CRUD/list_time.html.twig',\n 'datetime' => '@SonataIntl/CRUD/list_datetime.html.twig',\n 'text' => '@SonataAdmin/CRUD/list_string.html.twig',\n 'textarea' => '@SonataAdmin/CRUD/list_string.html.twig',\n 'email' => '@SonataAdmin/CRUD/list_email.html.twig',\n 'trans' => '@SonataAdmin/CRUD/list_trans.html.twig',\n 'string' => '@SonataAdmin/CRUD/list_string.html.twig',\n 'smallint' => '@SonataIntl/CRUD/list_decimal.html.twig',\n 'bigint' => '@SonataIntl/CRUD/list_decimal.html.twig',\n 'integer' => '@SonataIntl/CRUD/list_decimal.html.twig',\n 'decimal' => '@SonataIntl/CRUD/list_decimal.html.twig',\n 'identifier' => '@SonataAdmin/CRUD/list_string.html.twig',\n 'currency' => '@SonataIntl/CRUD/list_currency.html.twig',\n 'percent' => '@SonataIntl/CRUD/list_percent.html.twig',\n 'choice' => '@SonataAdmin/CRUD/list_choice.html.twig',\n 'url' => '@SonataAdmin/CRUD/list_url.html.twig',\n 'html' => '@SonataAdmin/CRUD/list_html.html.twig',\n ),\n 'show' => array(\n 'array' => '@SonataAdmin/CRUD/show_array.html.twig',\n 'boolean' => '@SonataAdmin/CRUD/show_boolean.html.twig',\n 'date' => '@SonataIntl/CRUD/show_date.html.twig',\n 'time' => '@SonataAdmin/CRUD/show_time.html.twig',\n 'datetime' => '@SonataIntl/CRUD/show_datetime.html.twig',\n 'text' => '@SonataAdmin/CRUD/base_show_field.html.twig',\n 'email' => '@SonataAdmin/CRUD/show_email.html.twig',\n 'trans' => '@SonataAdmin/CRUD/show_trans.html.twig',\n 'string' => '@SonataAdmin/CRUD/base_show_field.html.twig',\n 'smallint' => '@SonataIntl/CRUD/show_decimal.html.twig',\n 'bigint' => '@SonataIntl/CRUD/show_decimal.html.twig',\n 'integer' => '@SonataIntl/CRUD/show_decimal.html.twig',\n 'decimal' => '@SonataIntl/CRUD/show_decimal.html.twig',\n 'currency' => '@SonataIntl/CRUD/show_currency.html.twig',\n 'percent' => '@SonataIntl/CRUD/show_percent.html.twig',\n 'choice' => '@SonataAdmin/CRUD/show_choice.html.twig',\n 'url' => '@SonataAdmin/CRUD/show_url.html.twig',\n 'html' => '@SonataAdmin/CRUD/show_html.html.twig',\n ),\n ),\n 'form' => array(\n 0 => '@SonataDoctrineORMAdmin/Form/form_admin_fields.html.twig',\n ),\n 'filter' => array(\n 0 => '@SonataDoctrineORMAdmin/Form/filter_admin_fields.html.twig',\n ),\n ),\n 'fos_rest.format_listener.rules' => NULL,\n 'hateoas.link_factory.class' => 'Hateoas\\\\Factory\\\\LinkFactory',\n 'hateoas.links_factory.class' => 'Hateoas\\\\Factory\\\\LinksFactory',\n 'hateoas.embeds_factory.class' => 'Hateoas\\\\Factory\\\\EmbeddedsFactory',\n 'hateoas.expression.evaluator.class' => 'Bazinga\\\\Bundle\\\\HateoasBundle\\\\Hateoas\\\\Expression\\\\LazyFunctionExpressionEvaluator',\n 'bazinga_hateoas.expression_language.class' => 'Bazinga\\\\Bundle\\\\HateoasBundle\\\\ExpressionLanguage\\\\ExpressionLanguage',\n 'hateoas.expression.link.class' => 'Hateoas\\\\Expression\\\\LinkExpressionFunction',\n 'hateoas.serializer.xml.class' => 'Hateoas\\\\Serializer\\\\XmlSerializer',\n 'hateoas.serializer.json_hal.class' => 'Hateoas\\\\Serializer\\\\JsonHalSerializer',\n 'hateoas.serializer.exclusion_manager.class' => 'Hateoas\\\\Serializer\\\\ExclusionManager',\n 'hateoas.event_subscriber.xml.class' => 'Hateoas\\\\Serializer\\\\EventSubscriber\\\\XmlEventSubscriber',\n 'hateoas.event_subscriber.json.class' => 'Hateoas\\\\Serializer\\\\EventSubscriber\\\\JsonEventSubscriber',\n 'hateoas.inline_deferrer.embeds.class' => 'Hateoas\\\\Serializer\\\\Metadata\\\\InlineDeferrer',\n 'hateoas.inline_deferrer.links.class' => 'Hateoas\\\\Serializer\\\\Metadata\\\\InlineDeferrer',\n 'hateoas.configuration.provider.resolver.chain.class' => 'Hateoas\\\\Configuration\\\\Provider\\\\Resolver\\\\ChainResolver',\n 'hateoas.configuration.provider.resolver.method.class' => 'Hateoas\\\\Configuration\\\\Provider\\\\Resolver\\\\MethodResolver',\n 'hateoas.configuration.provider.resolver.static_method.class' => 'Hateoas\\\\Configuration\\\\Provider\\\\Resolver\\\\StaticMethodResolver',\n 'hateoas.configuration.provider.resolver.symfony_container.class' => 'Hateoas\\\\Configuration\\\\Provider\\\\Resolver\\\\SymfonyContainerResolver',\n 'hateoas.configuration.relation_provider.class' => 'Hateoas\\\\Configuration\\\\Provider\\\\RelationProvider',\n 'hateoas.configuration.relations_repository.class' => 'Hateoas\\\\Configuration\\\\RelationsRepository',\n 'hateoas.configuration.metadata.yaml_driver.class' => 'Hateoas\\\\Configuration\\\\Metadata\\\\Driver\\\\YamlDriver',\n 'hateoas.configuration.metadata.xml_driver.class' => 'Hateoas\\\\Configuration\\\\Metadata\\\\Driver\\\\XmlDriver',\n 'hateoas.configuration.metadata.annotation_driver.class' => 'Hateoas\\\\Configuration\\\\Metadata\\\\Driver\\\\AnnotationDriver',\n 'hateoas.configuration.metadata.extension_driver.class' => 'Hateoas\\\\Configuration\\\\Metadata\\\\Driver\\\\ExtensionDriver',\n 'hateoas.generator.registry.class' => 'Hateoas\\\\UrlGenerator\\\\UrlGeneratorRegistry',\n 'hateoas.generator.symfony.class' => 'Hateoas\\\\UrlGenerator\\\\SymfonyUrlGenerator',\n 'hateoas.helper.link.class' => 'Hateoas\\\\Helper\\\\LinkHelper',\n 'hateoas.twig.link.class' => 'Hateoas\\\\Twig\\\\Extension\\\\LinkExtension',\n 'nelmio_api_doc.motd.template' => 'NelmioApiDocBundle::Components/motd.html.twig',\n 'nelmio_api_doc.exclude_sections' => array(\n\n ),\n 'nelmio_api_doc.default_sections_opened' => true,\n 'nelmio_api_doc.api_name' => 'System API',\n 'nelmio_api_doc.sandbox.enabled' => true,\n 'nelmio_api_doc.sandbox.endpoint' => NULL,\n 'nelmio_api_doc.sandbox.accept_type' => NULL,\n 'nelmio_api_doc.sandbox.body_format.formats' => array(\n 0 => 'form',\n 1 => 'json',\n ),\n 'nelmio_api_doc.sandbox.body_format.default_format' => 'form',\n 'nelmio_api_doc.sandbox.request_format.method' => 'accept_header',\n 'nelmio_api_doc.sandbox.request_format.default_format' => 'json',\n 'nelmio_api_doc.sandbox.request_format.formats' => array(\n 'json' => 'application/json',\n 'xml' => 'application/xml',\n ),\n 'nelmio_api_doc.sandbox.entity_to_choice' => true,\n 'nelmio_api_doc.formatter.abstract_formatter.class' => 'Nelmio\\\\ApiDocBundle\\\\Formatter\\\\AbstractFormatter',\n 'nelmio_api_doc.formatter.markdown_formatter.class' => 'Nelmio\\\\ApiDocBundle\\\\Formatter\\\\MarkdownFormatter',\n 'nelmio_api_doc.formatter.simple_formatter.class' => 'Nelmio\\\\ApiDocBundle\\\\Formatter\\\\SimpleFormatter',\n 'nelmio_api_doc.formatter.html_formatter.class' => 'Nelmio\\\\ApiDocBundle\\\\Formatter\\\\HtmlFormatter',\n 'nelmio_api_doc.formatter.swagger_formatter.class' => 'Nelmio\\\\ApiDocBundle\\\\Formatter\\\\SwaggerFormatter',\n 'nelmio_api_doc.sandbox.authentication' => array(\n 'delivery' => 'http',\n 'type' => 'bearer',\n 'name' => 'Authorization',\n 'custom_endpoint' => false,\n ),\n 'nelmio_api_doc.extractor.api_doc_extractor.class' => 'Nelmio\\\\ApiDocBundle\\\\Extractor\\\\ApiDocExtractor',\n 'nelmio_api_doc.form.extension.description_form_type_extension.class' => 'Nelmio\\\\ApiDocBundle\\\\Form\\\\Extension\\\\DescriptionFormTypeExtension',\n 'nelmio_api_doc.twig.extension.extra_markdown.class' => 'Nelmio\\\\ApiDocBundle\\\\Twig\\\\Extension\\\\MarkdownExtension',\n 'nelmio_api_doc.doc_comment_extractor.class' => 'Nelmio\\\\ApiDocBundle\\\\Util\\\\DocCommentExtractor',\n 'nelmio_api_doc.extractor.handler.fos_rest.class' => 'Nelmio\\\\ApiDocBundle\\\\Extractor\\\\Handler\\\\FosRestHandler',\n 'nelmio_api_doc.extractor.handler.jms_security.class' => 'Nelmio\\\\ApiDocBundle\\\\Extractor\\\\Handler\\\\JmsSecurityExtraHandler',\n 'nelmio_api_doc.extractor.handler.sensio_framework_extra.class' => 'Nelmio\\\\ApiDocBundle\\\\Extractor\\\\Handler\\\\SensioFrameworkExtraHandler',\n 'nelmio_api_doc.extractor.handler.phpdoc.class' => 'Nelmio\\\\ApiDocBundle\\\\Extractor\\\\Handler\\\\PhpDocHandler',\n 'nelmio_api_doc.parser.collection_parser.class' => 'Nelmio\\\\ApiDocBundle\\\\Parser\\\\CollectionParser',\n 'nelmio_api_doc.parser.form_errors_parser.class' => 'Nelmio\\\\ApiDocBundle\\\\Parser\\\\FormErrorsParser',\n 'nelmio_api_doc.parser.json_serializable_parser.class' => 'Nelmio\\\\ApiDocBundle\\\\Parser\\\\JsonSerializableParser',\n 'nelmio_api_doc.request_listener.parameter' => '_doc',\n 'nelmio_api_doc.event_listener.request.class' => 'Nelmio\\\\ApiDocBundle\\\\EventListener\\\\RequestListener',\n 'nelmio_api_doc.parser.validation_parser.class' => 'Nelmio\\\\ApiDocBundle\\\\Parser\\\\ValidationParser',\n 'nelmio_api_doc.swagger.base_path' => '/api',\n 'nelmio_api_doc.swagger.swagger_version' => '1.2',\n 'nelmio_api_doc.swagger.api_version' => '0.1',\n 'nelmio_api_doc.swagger.info' => array(\n 'title' => 'Symfony2',\n 'description' => 'My awesome Symfony2 app!',\n 'TermsOfServiceUrl' => NULL,\n 'contact' => NULL,\n 'license' => NULL,\n 'licenseUrl' => NULL,\n ),\n 'nelmio_api_doc.swagger.model_naming_strategy' => 'dot_notation',\n 'nelmio_cors.map' => array(\n '^/api/' => array(\n 'allow_origin' => true,\n 'allow_headers' => true,\n 'allow_methods' => array(\n 0 => 'GET',\n 1 => 'POST',\n 2 => 'PUT',\n 3 => 'PATCH',\n 4 => 'DELETE',\n 5 => 'OPTIONS',\n ),\n 'max_age' => 3600,\n ),\n '^/' => array(\n 'origin_regex' => true,\n 'allow_origin' => array(\n 0 => '^http://localhost:[0-9]+',\n ),\n 'allow_headers' => array(\n 0 => 'x-custom-auth',\n ),\n 'allow_methods' => array(\n 0 => 'GET',\n 1 => 'POST',\n 2 => 'PUT',\n 3 => 'PATCH',\n 4 => 'DELETE',\n 5 => 'OPTIONS',\n ),\n 'max_age' => 3600,\n 'hosts' => array(\n 0 => '^api\\\\.',\n ),\n ),\n ),\n 'nelmio_cors.defaults' => array(\n 'allow_origin' => array(\n\n ),\n 'allow_credentials' => false,\n 'allow_headers' => array(\n\n ),\n 'expose_headers' => array(\n\n ),\n 'allow_methods' => array(\n\n ),\n 'max_age' => 0,\n 'hosts' => array(\n\n ),\n 'origin_regex' => false,\n 'forced_allow_origin_value' => NULL,\n ),\n 'nelmio_cors.cors_listener.class' => 'Nelmio\\\\CorsBundle\\\\EventListener\\\\CorsListener',\n 'nelmio_cors.options_resolver.class' => 'Nelmio\\\\CorsBundle\\\\Options\\\\Resolver',\n 'nelmio_cors.options_provider.config.class' => 'Nelmio\\\\CorsBundle\\\\Options\\\\ConfigProvider',\n 'jms_serializer.metadata.file_locator.class' => 'Metadata\\\\Driver\\\\FileLocator',\n 'jms_serializer.metadata.annotation_driver.class' => 'JMS\\\\Serializer\\\\Metadata\\\\Driver\\\\AnnotationDriver',\n 'jms_serializer.metadata.chain_driver.class' => 'Metadata\\\\Driver\\\\DriverChain',\n 'jms_serializer.metadata.yaml_driver.class' => 'JMS\\\\Serializer\\\\Metadata\\\\Driver\\\\YamlDriver',\n 'jms_serializer.metadata.xml_driver.class' => 'JMS\\\\Serializer\\\\Metadata\\\\Driver\\\\XmlDriver',\n 'jms_serializer.metadata.php_driver.class' => 'JMS\\\\Serializer\\\\Metadata\\\\Driver\\\\PhpDriver',\n 'jms_serializer.metadata.doctrine_type_driver.class' => 'JMS\\\\Serializer\\\\Metadata\\\\Driver\\\\DoctrineTypeDriver',\n 'jms_serializer.metadata.doctrine_phpcr_type_driver.class' => 'JMS\\\\Serializer\\\\Metadata\\\\Driver\\\\DoctrinePHPCRTypeDriver',\n 'jms_serializer.metadata.lazy_loading_driver.class' => 'Metadata\\\\Driver\\\\LazyLoadingDriver',\n 'jms_serializer.metadata.metadata_factory.class' => 'Metadata\\\\MetadataFactory',\n 'jms_serializer.metadata.cache.file_cache.class' => 'Metadata\\\\Cache\\\\FileCache',\n 'jms_serializer.event_dispatcher.class' => 'JMS\\\\Serializer\\\\EventDispatcher\\\\LazyEventDispatcher',\n 'jms_serializer.camel_case_naming_strategy.class' => 'JMS\\\\Serializer\\\\Naming\\\\CamelCaseNamingStrategy',\n 'jms_serializer.identical_property_naming_strategy.class' => 'JMS\\\\Serializer\\\\Naming\\\\IdenticalPropertyNamingStrategy',\n 'jms_serializer.serialized_name_annotation_strategy.class' => 'JMS\\\\Serializer\\\\Naming\\\\SerializedNameAnnotationStrategy',\n 'jms_serializer.cache_naming_strategy.class' => 'JMS\\\\Serializer\\\\Naming\\\\CacheNamingStrategy',\n 'jms_serializer.doctrine_object_constructor.class' => 'JMS\\\\Serializer\\\\Construction\\\\DoctrineObjectConstructor',\n 'jms_serializer.unserialize_object_constructor.class' => 'JMS\\\\Serializer\\\\Construction\\\\UnserializeObjectConstructor',\n 'jms_serializer.version_exclusion_strategy.class' => 'JMS\\\\Serializer\\\\Exclusion\\\\VersionExclusionStrategy',\n 'jms_serializer.serializer.class' => 'JMS\\\\Serializer\\\\Serializer',\n 'jms_serializer.twig_extension.class' => 'JMS\\\\Serializer\\\\Twig\\\\SerializerExtension',\n 'jms_serializer.twig_runtime_extension.class' => 'JMS\\\\Serializer\\\\Twig\\\\SerializerRuntimeExtension',\n 'jms_serializer.twig_runtime_extension_helper.class' => 'JMS\\\\Serializer\\\\Twig\\\\SerializerRuntimeHelper',\n 'jms_serializer.templating.helper.class' => 'JMS\\\\SerializerBundle\\\\Templating\\\\SerializerHelper',\n 'jms_serializer.json_serialization_visitor.class' => 'JMS\\\\Serializer\\\\JsonSerializationVisitor',\n 'jms_serializer.json_serialization_visitor.options' => 0,\n 'jms_serializer.json_deserialization_visitor.class' => 'JMS\\\\Serializer\\\\JsonDeserializationVisitor',\n 'jms_serializer.xml_serialization_visitor.class' => 'JMS\\\\Serializer\\\\XmlSerializationVisitor',\n 'jms_serializer.xml_deserialization_visitor.class' => 'JMS\\\\Serializer\\\\XmlDeserializationVisitor',\n 'jms_serializer.xml_deserialization_visitor.doctype_whitelist' => array(\n\n ),\n 'jms_serializer.xml_serialization_visitor.format_output' => true,\n 'jms_serializer.yaml_serialization_visitor.class' => 'JMS\\\\Serializer\\\\YamlSerializationVisitor',\n 'jms_serializer.handler_registry.class' => 'JMS\\\\Serializer\\\\Handler\\\\LazyHandlerRegistry',\n 'jms_serializer.datetime_handler.class' => 'JMS\\\\Serializer\\\\Handler\\\\DateHandler',\n 'jms_serializer.array_collection_handler.class' => 'JMS\\\\Serializer\\\\Handler\\\\ArrayCollectionHandler',\n 'jms_serializer.php_collection_handler.class' => 'JMS\\\\Serializer\\\\Handler\\\\PhpCollectionHandler',\n 'jms_serializer.form_error_handler.class' => 'FOS\\\\RestBundle\\\\Serializer\\\\Normalizer\\\\FormErrorHandler',\n 'jms_serializer.constraint_violation_handler.class' => 'JMS\\\\Serializer\\\\Handler\\\\ConstraintViolationHandler',\n 'jms_serializer.doctrine_proxy_subscriber.class' => 'JMS\\\\Serializer\\\\EventDispatcher\\\\Subscriber\\\\DoctrineProxySubscriber',\n 'jms_serializer.stopwatch_subscriber.class' => 'JMS\\\\SerializerBundle\\\\Serializer\\\\StopwatchEventSubscriber',\n 'jms_serializer.configured_context_factory.class' => 'JMS\\\\SerializerBundle\\\\ContextFactory\\\\ConfiguredContextFactory',\n 'jms_serializer.expression_evaluator.class' => 'JMS\\\\Serializer\\\\Expression\\\\ExpressionEvaluator',\n 'jms_serializer.expression_language.class' => 'Symfony\\\\Component\\\\ExpressionLanguage\\\\ExpressionLanguage',\n 'jms_serializer.expression_language.function_provider.class' => 'JMS\\\\SerializerBundle\\\\ExpressionLanguage\\\\BasicSerializerFunctionsProvider',\n 'jms_serializer.accessor_strategy.default.class' => 'JMS\\\\Serializer\\\\Accessor\\\\DefaultAccessorStrategy',\n 'jms_serializer.accessor_strategy.expression.class' => 'JMS\\\\Serializer\\\\Accessor\\\\ExpressionAccessorStrategy',\n 'jms_serializer.cache.cache_warmer.class' => 'JMS\\\\SerializerBundle\\\\Cache\\\\CacheWarmer',\n 'sonata.core.flashmessage.manager.class' => 'Sonata\\\\CoreBundle\\\\FlashMessage\\\\FlashManager',\n 'sonata.core.twig.extension.flashmessage.class' => 'Sonata\\\\CoreBundle\\\\Twig\\\\Extension\\\\FlashMessageExtension',\n 'sonata.core.form_type' => 'standard',\n 'sonata.core.form.mapping.type' => array(\n\n ),\n 'sonata.core.form.mapping.extension' => array(\n\n ),\n 'sonata.intl.locale_detector.request.class' => 'Sonata\\\\IntlBundle\\\\Locale\\\\RequestDetector',\n 'sonata.intl.locale_detector.session.class' => 'Sonata\\\\IntlBundle\\\\Locale\\\\SessionDetector',\n 'sonata.intl.templating.helper.locale.class' => 'Sonata\\\\IntlBundle\\\\Templating\\\\Helper\\\\LocaleHelper',\n 'sonata.intl.templating.helper.number.class' => 'Sonata\\\\IntlBundle\\\\Templating\\\\Helper\\\\NumberHelper',\n 'sonata.intl.templating.helper.datetime.class' => 'Sonata\\\\IntlBundle\\\\Templating\\\\Helper\\\\DateTimeHelper',\n 'sonata.intl.timezone_detector.chain.class' => 'Sonata\\\\IntlBundle\\\\Timezone\\\\ChainTimezoneDetector',\n 'sonata.intl.timezone_detector.user.class' => 'Sonata\\\\IntlBundle\\\\Timezone\\\\UserBasedTimezoneDetector',\n 'sonata.intl.timezone_detector.locale.class' => 'Sonata\\\\IntlBundle\\\\Timezone\\\\LocaleBasedTimezoneDetector',\n 'sonata.intl.twig.helper.locale.class' => 'Sonata\\\\IntlBundle\\\\Twig\\\\Extension\\\\LocaleExtension',\n 'sonata.intl.twig.helper.number.class' => 'Sonata\\\\IntlBundle\\\\Twig\\\\Extension\\\\NumberExtension',\n 'sonata.intl.twig.helper.datetime.class' => 'Sonata\\\\IntlBundle\\\\Twig\\\\Extension\\\\DateTimeExtension',\n 'sonata_intl.timezone.detectors' => array(\n 0 => 'sonata.intl.timezone_detector.user',\n 1 => 'sonata.intl.timezone_detector.locale',\n ),\n 'sonata.formatter.text.markdown.class' => 'Sonata\\\\FormatterBundle\\\\Formatter\\\\MarkdownFormatter',\n 'sonata.formatter.text.text.class' => 'Sonata\\\\FormatterBundle\\\\Formatter\\\\TextFormatter',\n 'sonata.formatter.text.raw.class' => 'Sonata\\\\FormatterBundle\\\\Formatter\\\\RawFormatter',\n 'sonata.formatter.text.twigengine.class' => 'Sonata\\\\FormatterBundle\\\\Formatter\\\\TwigFormatter',\n 'sonata.formatter.block.formatter.class' => 'Sonata\\\\FormatterBundle\\\\Block\\\\FormatterBlockService',\n 'sonata.formatter.ckeditor.extension.class' => 'Sonata\\\\FormatterBundle\\\\Admin\\\\CkeditorAdminExtension',\n 'sonata.formatter.ckeditor.configuration.templates' => array(\n 'browser' => 'SonataFormatterBundle:Ckeditor:browser.html.twig',\n 'upload' => 'SonataFormatterBundle:Ckeditor:upload.html.twig',\n ),\n 'sonata.block.service.container.class' => 'Sonata\\\\BlockBundle\\\\Block\\\\Service\\\\ContainerBlockService',\n 'sonata.block.service.empty.class' => 'Sonata\\\\BlockBundle\\\\Block\\\\Service\\\\EmptyBlockService',\n 'sonata.block.service.text.class' => 'Sonata\\\\BlockBundle\\\\Block\\\\Service\\\\TextBlockService',\n 'sonata.block.service.rss.class' => 'Sonata\\\\BlockBundle\\\\Block\\\\Service\\\\RssBlockService',\n 'sonata.block.service.menu.class' => 'Sonata\\\\BlockBundle\\\\Block\\\\Service\\\\MenuBlockService',\n 'sonata.block.service.template.class' => 'Sonata\\\\BlockBundle\\\\Block\\\\Service\\\\TemplateBlockService',\n 'sonata.block.exception.strategy.manager.class' => 'Sonata\\\\BlockBundle\\\\Exception\\\\Strategy\\\\StrategyManager',\n 'sonata.block.container.types' => array(\n 0 => 'sonata.block.service.container',\n 1 => 'sonata.page.block.container',\n 2 => 'sonata.dashboard.block.container',\n 3 => 'cmf.block.container',\n 4 => 'cmf.block.slideshow',\n ),\n 'sonata_block.blocks' => array(\n 'sonata.admin.block.stats' => array(\n 'contexts' => array(\n 0 => 'admin',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.admin.block.admin_list' => array(\n 'contexts' => array(\n 0 => 'admin',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.block.service.text' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.block.service.container' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.block.service.rss' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.block.service.menu' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.block.service.template' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.page.block.container' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.page.block.children_pages' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.page.block.ajax' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.page.block.context_manager' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.page.block.breadcrumb' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.page.block.shared_block' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.page.block.pagelist' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.media.block.media' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.media.block.gallery' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.media.block.feature_media' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.media.block.gallery_list' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.user.block.account' => array(\n 'cache' => 'sonata.page.cache.js_async',\n 'contexts' => array(\n 0 => 'user',\n 1 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'settings' => array(\n\n ),\n ),\n 'sonata.user.block.menu' => array(\n 'contexts' => array(\n 0 => 'user',\n 1 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.user.block.breadcrumb_index' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.user.block.breadcrumb_profile' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.email.share_button' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.facebook.like_box' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.facebook.like_button' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.facebook.send_button' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.facebook.share_button' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.pinterest.pin_button' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.twitter.share_button' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.twitter.follow_button' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.twitter.hashtag_button' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.twitter.mention_button' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.twitter.embed' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.formatter.block.formatter' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.seo.block.breadcrumb.homepage' => array(\n 'contexts' => array(\n 0 => 'sonata_page_bundle',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n 'sonata.admin.block.search_result' => array(\n 'contexts' => array(\n 0 => 'admin',\n ),\n 'templates' => array(\n\n ),\n 'cache' => 'sonata.cache.noop',\n 'settings' => array(\n\n ),\n ),\n ),\n 'sonata_block.blocks_by_class' => array(\n\n ),\n 'sonata_block.cache_blocks' => array(\n 'by_type' => array(\n 'sonata.admin.block.stats' => 'sonata.cache.noop',\n 'sonata.admin.block.admin_list' => 'sonata.cache.noop',\n 'sonata.block.service.text' => 'sonata.cache.noop',\n 'sonata.block.service.container' => 'sonata.cache.noop',\n 'sonata.block.service.rss' => 'sonata.cache.noop',\n 'sonata.block.service.menu' => 'sonata.cache.noop',\n 'sonata.block.service.template' => 'sonata.cache.noop',\n 'sonata.page.block.container' => 'sonata.cache.noop',\n 'sonata.page.block.children_pages' => 'sonata.cache.noop',\n 'sonata.page.block.ajax' => 'sonata.cache.noop',\n 'sonata.page.block.context_manager' => 'sonata.cache.noop',\n 'sonata.page.block.breadcrumb' => 'sonata.cache.noop',\n 'sonata.page.block.shared_block' => 'sonata.cache.noop',\n 'sonata.page.block.pagelist' => 'sonata.cache.noop',\n 'sonata.media.block.media' => 'sonata.cache.noop',\n 'sonata.media.block.gallery' => 'sonata.cache.noop',\n 'sonata.media.block.feature_media' => 'sonata.cache.noop',\n 'sonata.media.block.gallery_list' => 'sonata.cache.noop',\n 'sonata.user.block.account' => 'sonata.page.cache.js_async',\n 'sonata.user.block.menu' => 'sonata.cache.noop',\n 'sonata.user.block.breadcrumb_index' => 'sonata.cache.noop',\n 'sonata.user.block.breadcrumb_profile' => 'sonata.cache.noop',\n 'sonata.seo.block.email.share_button' => 'sonata.cache.noop',\n 'sonata.seo.block.facebook.like_box' => 'sonata.cache.noop',\n 'sonata.seo.block.facebook.like_button' => 'sonata.cache.noop',\n 'sonata.seo.block.facebook.send_button' => 'sonata.cache.noop',\n 'sonata.seo.block.facebook.share_button' => 'sonata.cache.noop',\n 'sonata.seo.block.pinterest.pin_button' => 'sonata.cache.noop',\n 'sonata.seo.block.twitter.share_button' => 'sonata.cache.noop',\n 'sonata.seo.block.twitter.follow_button' => 'sonata.cache.noop',\n 'sonata.seo.block.twitter.hashtag_button' => 'sonata.cache.noop',\n 'sonata.seo.block.twitter.mention_button' => 'sonata.cache.noop',\n 'sonata.seo.block.twitter.embed' => 'sonata.cache.noop',\n 'sonata.formatter.block.formatter' => 'sonata.cache.noop',\n 'sonata.seo.block.breadcrumb.homepage' => 'sonata.cache.noop',\n 'sonata.admin.block.search_result' => 'sonata.cache.noop',\n ),\n ),\n 'sonata.classification.manager.category.class' => 'Sonata\\\\ClassificationBundle\\\\Entity\\\\CategoryManager',\n 'sonata.classification.manager.tag.class' => 'Sonata\\\\ClassificationBundle\\\\Entity\\\\TagManager',\n 'sonata.classification.manager.collection.class' => 'Sonata\\\\ClassificationBundle\\\\Entity\\\\CollectionManager',\n 'sonata.classification.manager.context.class' => 'Sonata\\\\ClassificationBundle\\\\Entity\\\\ContextManager',\n 'sonata.classification.admin.groupname' => 'sonata_classification',\n 'sonata.classification.admin.groupicon' => '<i class=\\'fa fa-tags\\'></i>',\n 'sonata.classification.admin.tag.entity' => 'AppBundle\\\\Entity\\\\Classification\\\\Tag',\n 'sonata.classification.admin.category.entity' => 'AppBundle\\\\Entity\\\\Classification\\\\Category',\n 'sonata.classification.admin.collection.entity' => 'AppBundle\\\\Entity\\\\Classification\\\\Collection',\n 'sonata.classification.admin.context.entity' => 'AppBundle\\\\Entity\\\\Classification\\\\Context',\n 'sonata.classification.manager.tag.entity' => 'AppBundle\\\\Entity\\\\Classification\\\\Tag',\n 'sonata.classification.manager.category.entity' => 'AppBundle\\\\Entity\\\\Classification\\\\Category',\n 'sonata.classification.manager.collection.entity' => 'AppBundle\\\\Entity\\\\Classification\\\\Collection',\n 'sonata.classification.manager.context.entity' => 'AppBundle\\\\Entity\\\\Classification\\\\Context',\n 'sonata.classification.admin.category.class' => 'Sonata\\\\ClassificationBundle\\\\Admin\\\\CategoryAdmin',\n 'sonata.classification.admin.category.controller' => 'SonataClassificationBundle:CategoryAdmin',\n 'sonata.classification.admin.category.translation_domain' => 'SonataClassificationBundle',\n 'sonata.classification.admin.tag.class' => 'Sonata\\\\ClassificationBundle\\\\Admin\\\\TagAdmin',\n 'sonata.classification.admin.tag.controller' => 'SonataAdminBundle:CRUD',\n 'sonata.classification.admin.tag.translation_domain' => 'SonataClassificationBundle',\n 'sonata.classification.admin.collection.class' => 'Sonata\\\\ClassificationBundle\\\\Admin\\\\CollectionAdmin',\n 'sonata.classification.admin.collection.controller' => 'SonataAdminBundle:CRUD',\n 'sonata.classification.admin.collection.translation_domain' => 'SonataClassificationBundle',\n 'sonata.classification.admin.context.class' => 'Sonata\\\\ClassificationBundle\\\\Admin\\\\ContextAdmin',\n 'sonata.classification.admin.context.controller' => 'SonataAdminBundle:CRUD',\n 'sonata.classification.admin.context.translation_domain' => 'SonataClassificationBundle',\n 'mopa_bootstrap.bootstrap.install_path' => 'Resources/public/bootstrap',\n 'mopa_bootstrap.twig.extension.form.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Twig\\\\FormExtension',\n 'mopa_bootstrap.twig.extension.icon.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Twig\\\\IconExtension',\n 'mopa_bootstrap.twig.extension.flash.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Twig\\\\FlashExtension',\n 'mopa_bootstrap.form.type_extension.embed_form.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\EmbedFormExtension',\n 'mopa_bootstrap.form.type_extension.static_text.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\StaticTextExtension',\n 'mopa_bootstrap.form.type_extension.offset_button.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\OffsetButtonExtension',\n 'mopa_bootstrap.form.type_extension.button.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\IconButtonExtension',\n 'mopa_bootstrap.form.type_extension.help.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\HelpFormTypeExtension',\n 'mopa_bootstrap.form.type_extension.legend.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\LegendFormTypeExtension',\n 'mopa_bootstrap.form.type_extension.error.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\ErrorTypeFormTypeExtension',\n 'mopa_bootstrap.form.type_extension.widget.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\WidgetFormTypeExtension',\n 'mopa_bootstrap.form.type_extension.layout.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\LayoutFormTypeExtension',\n 'mopa_bootstrap.form.type_extension.widget_collection.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\WidgetCollectionFormTypeExtension',\n 'mopa_bootstrap.form.type_extension.date.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\DateTypeExtension',\n 'mopa_bootstrap.form.type_extension.datetime.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\DatetimeTypeExtension',\n 'mopa_bootstrap.form.type_extension.time.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\TimeTypeExtension',\n 'mopa_bootstrap.form.type_extension.tabbed.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Extension\\\\TabbedFormTypeExtension',\n 'mopa_bootstrap.form.type.tab.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Type\\\\TabType',\n 'mopa_bootstrap.form.type.form_actions.class' => 'Mopa\\\\Bundle\\\\BootstrapBundle\\\\Form\\\\Type\\\\FormActionsType',\n 'mopa_bootstrap.form.show_legend' => false,\n 'mopa_bootstrap.form.render_optional_text' => false,\n 'mopa_bootstrap.form.render_required_asterisk' => true,\n 'mopa_bootstrap.form.allow_legacy' => false,\n 'mopa_bootstrap.form.templating' => '@MopaBootstrap/Form/fields.html.twig',\n 'mopa_bootstrap.form.layout' => 'horizontal',\n 'mopa_bootstrap.form.horizontal_label_class' => 'col-sm-3',\n 'mopa_bootstrap.form.horizontal_label_div_class' => NULL,\n 'mopa_bootstrap.form.horizontal_label_offset_class' => 'col-sm-offset-3',\n 'mopa_bootstrap.form.horizontal_input_wrapper_class' => 'col-sm-9',\n 'mopa_bootstrap.form.date_wrapper_class.year' => 'col-xs-4',\n 'mopa_bootstrap.form.date_wrapper_class.month' => 'col-xs-4',\n 'mopa_bootstrap.form.date_wrapper_class.day' => 'col-xs-4',\n 'mopa_bootstrap.form.render_fieldset' => true,\n 'mopa_bootstrap.form.render_collection_item' => true,\n 'mopa_bootstrap.form.show_child_legend' => false,\n 'mopa_bootstrap.form.legend_tag' => 'legend',\n 'mopa_bootstrap.form.checkbox_label' => 'both',\n 'mopa_bootstrap.form.error_type' => NULL,\n 'mopa_bootstrap.form.tabs.class' => 'nav nav-tabs',\n 'mopa_bootstrap.form.help_widget.popover' => array(\n 'title' => NULL,\n 'content' => NULL,\n 'trigger' => 'hover',\n 'toggle' => 'popover',\n 'placement' => 'right',\n 'selector' => NULL,\n ),\n 'mopa_bootstrap.form.help_label.tooltip' => array(\n 'title' => NULL,\n 'text' => NULL,\n 'icon' => 'info-sign',\n 'placement' => 'top',\n ),\n 'mopa_bootstrap.form.help_label.popover' => array(\n 'title' => NULL,\n 'content' => NULL,\n 'text' => NULL,\n 'icon' => 'info-sign',\n 'placement' => 'top',\n ),\n 'mopa_bootstrap.form.help_block.tooltip' => array(\n 'title' => NULL,\n 'text' => NULL,\n 'icon' => 'info-sign',\n 'placement' => 'top',\n ),\n 'mopa_bootstrap.form.help_block.popover' => array(\n 'title' => NULL,\n 'content' => NULL,\n 'text' => NULL,\n 'icon' => 'info-sign',\n 'placement' => 'top',\n ),\n 'mopa_bootstrap.form.collection.widget_remove_btn' => array(\n 'attr' => array(\n 'class' => 'btn btn-default',\n ),\n 'wrapper_div' => array(\n 'class' => 'form-group',\n ),\n 'horizontal_wrapper_div' => array(\n 'class' => 'col-sm-3 col-sm-offset-3',\n ),\n 'label' => 'remove_item',\n 'translation_domain' => NULL,\n 'icon' => NULL,\n 'icon_inverted' => false,\n ),\n 'mopa_bootstrap.form.collection.widget_add_btn' => array(\n 'attr' => array(\n 'class' => 'btn btn-default',\n ),\n 'label' => 'add_item',\n 'translation_domain' => NULL,\n 'icon' => NULL,\n 'icon_inverted' => false,\n ),\n 'mopa_bootstrap.icons.icon_set' => 'glyphicons',\n 'mopa_bootstrap.icons.shortcut' => 'icon',\n 'fos_js_routing.extractor.class' => 'FOS\\\\JsRoutingBundle\\\\Extractor\\\\ExposedRoutesExtractor',\n 'fos_js_routing.controller.class' => 'FOS\\\\JsRoutingBundle\\\\Controller\\\\Controller',\n 'fos_js_routing.cache_control' => array(\n 'enabled' => false,\n ),\n 'lexik_form_filter.query_builder_updater.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\FilterBuilderUpdater',\n 'lexik_form_filter.form_data_extractor.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\DataExtractor\\\\FormDataExtractor',\n 'lexik_form_filter.data_extraction_method.default.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\DataExtractor\\\\Method\\\\DefaultExtractionMethod',\n 'lexik_form_filter.data_extraction_method.text.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\DataExtractor\\\\Method\\\\TextExtractionMethod',\n 'lexik_form_filter.data_extraction_method.key_values.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\DataExtractor\\\\Method\\\\ValueKeysExtractionMethod',\n 'lexik_form_filter.filter_prepare.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Event\\\\Listener\\\\PrepareListener',\n 'lexik_form_filter.type.filter_text.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\TextFilterType',\n 'lexik_form_filter.type.filter_number.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\NumberFilterType',\n 'lexik_form_filter.type.filter_number_range.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\NumberRangeFilterType',\n 'lexik_form_filter.type.filter_checkbox.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\CheckboxFilterType',\n 'lexik_form_filter.type.filter_boolean.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\BooleanFilterType',\n 'lexik_form_filter.type.filter_choice.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\ChoiceFilterType',\n 'lexik_form_filter.type.filter_date.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\DateFilterType',\n 'lexik_form_filter.type.filter_date_range.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\DateRangeFilterType',\n 'lexik_form_filter.type.filter_datetime.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\DateTimeFilterType',\n 'lexik_form_filter.type.filter_datetime_range.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\DateTimeRangeFilterType',\n 'lexik_form_filter.type.filter_collection_adapter.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\CollectionAdapterFilterType',\n 'lexik_form_filter.type.filter_sharedable.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\SharedableFilterType',\n 'lexik_form_filter.type_extension.filter_extension.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\FilterTypeExtension',\n 'lexik_form_filter.get_filter.doctrine_orm.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Event\\\\Subscriber\\\\DoctrineORMSubscriber',\n 'lexik_form_filter.apply_filter.doctrine_orm.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Event\\\\Listener\\\\DoctrineApplyFilterListener',\n 'lexik_form_filter.type.filter_entity.class' => 'Lexik\\\\Bundle\\\\FormFilterBundle\\\\Filter\\\\Form\\\\Type\\\\EntityFilterType',\n 'lexik_form_filter.where_method' => 'and',\n 'lexik_form_filter.text.condition_pattern' => 1,\n 'liip_imagine.filter.configuration.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\FilterConfiguration',\n 'liip_imagine.filter.manager.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\FilterManager',\n 'liip_imagine.data.manager.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Data\\\\DataManager',\n 'liip_imagine.cache.manager.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Cache\\\\CacheManager',\n 'liip_imagine.cache.signer.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Cache\\\\Signer',\n 'liip_imagine.binary.mime_type_guesser.class' => 'Liip\\\\ImagineBundle\\\\Binary\\\\SimpleMimeTypeGuesser',\n 'liip_imagine.controller.class' => 'Liip\\\\ImagineBundle\\\\Controller\\\\ImagineController',\n 'liip_imagine.twig.extension.class' => 'Liip\\\\ImagineBundle\\\\Templating\\\\ImagineExtension',\n 'liip_imagine.templating.helper.class' => 'Liip\\\\ImagineBundle\\\\Templating\\\\Helper\\\\ImagineHelper',\n 'liip_imagine.gd.class' => 'Imagine\\\\Gd\\\\Imagine',\n 'liip_imagine.imagick.class' => 'Imagine\\\\Imagick\\\\Imagine',\n 'liip_imagine.gmagick.class' => 'Imagine\\\\Gmagick\\\\Imagine',\n 'liip_imagine.filter.loader.relative_resize.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\RelativeResizeFilterLoader',\n 'liip_imagine.filter.loader.resize.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\ResizeFilterLoader',\n 'liip_imagine.filter.loader.thumbnail.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\ThumbnailFilterLoader',\n 'liip_imagine.filter.loader.crop.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\CropFilterLoader',\n 'liip_imagine.filter.loader.grayscale.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\GrayscaleFilterLoader',\n 'liip_imagine.filter.loader.paste.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\PasteFilterLoader',\n 'liip_imagine.filter.loader.watermark.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\WatermarkFilterLoader',\n 'liip_imagine.filter.loader.strip.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\StripFilterLoader',\n 'liip_imagine.filter.loader.background.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\BackgroundFilterLoader',\n 'liip_imagine.filter.loader.scale.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\ScaleFilterLoader',\n 'liip_imagine.filter.loader.upscale.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\UpscaleFilterLoader',\n 'liip_imagine.filter.loader.downscale.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\DownscaleFilterLoader',\n 'liip_imagine.filter.loader.auto_rotate.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\AutoRotateFilterLoader',\n 'liip_imagine.filter.loader.rotate.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\RotateFilterLoader',\n 'liip_imagine.filter.loader.flip.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\FlipFilterLoader',\n 'liip_imagine.filter.loader.interlace.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\InterlaceFilterLoader',\n 'liip_imagine.filter.loader.resample.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\Loader\\\\ResampleFilterLoader',\n 'liip_imagine.binary.loader.filesystem.class' => 'Liip\\\\ImagineBundle\\\\Binary\\\\Loader\\\\FileSystemLoader',\n 'liip_imagine.binary.loader.stream.class' => 'Liip\\\\ImagineBundle\\\\Binary\\\\Loader\\\\StreamLoader',\n 'liip_imagine.binary.loader.flysystem.class' => 'Liip\\\\ImagineBundle\\\\Binary\\\\Loader\\\\FlysystemLoader',\n 'liip_imagine.binary.loader.chain.class' => 'Liip\\\\ImagineBundle\\\\Binary\\\\Loader\\\\ChainLoader',\n 'liip_imagine.binary.locator.filesystem.class' => 'Liip\\\\ImagineBundle\\\\Binary\\\\Locator\\\\FileSystemLocator',\n 'liip_imagine.binary.locator.filesystem_insecure.class' => 'Liip\\\\ImagineBundle\\\\Binary\\\\Locator\\\\FileSystemInsecureLocator',\n 'liip_imagine.cache.resolver.web_path.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Cache\\\\Resolver\\\\WebPathResolver',\n 'liip_imagine.cache.resolver.no_cache_web_path.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Cache\\\\Resolver\\\\NoCacheWebPathResolver',\n 'liip_imagine.cache.resolver.aws_s3.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Cache\\\\Resolver\\\\AwsS3Resolver',\n 'liip_imagine.cache.resolver.cache.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Cache\\\\Resolver\\\\CacheResolver',\n 'liip_imagine.cache.resolver.flysystem.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Cache\\\\Resolver\\\\FlysystemResolver',\n 'liip_imagine.cache.resolver.proxy.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Cache\\\\Resolver\\\\ProxyResolver',\n 'liip_imagine.form.type.image.class' => 'Liip\\\\ImagineBundle\\\\Form\\\\Type\\\\ImageType',\n 'liip_imagine.meta_data.reader.class' => 'Imagine\\\\Image\\\\Metadata\\\\ExifMetadataReader',\n 'liip_imagine.filter.post_processor.jpegoptim.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\PostProcessor\\\\JpegOptimPostProcessor',\n 'liip_imagine.jpegoptim.binary' => '/usr/bin/jpegoptim',\n 'liip_imagine.jpegoptim.stripall' => true,\n 'liip_imagine.jpegoptim.max' => NULL,\n 'liip_imagine.jpegoptim.progressive' => true,\n 'liip_imagine.jpegoptim.tempdir' => NULL,\n 'liip_imagine.filter.post_processor.optipng.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\PostProcessor\\\\OptiPngPostProcessor',\n 'liip_imagine.optipng.binary' => '/usr/bin/optipng',\n 'liip_imagine.optipng.level' => 7,\n 'liip_imagine.optipng.stripall' => true,\n 'liip_imagine.optipng.tempdir' => NULL,\n 'liip_imagine.filter.post_processor.pngquant.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\PostProcessor\\\\PngquantPostProcessor',\n 'liip_imagine.pngquant.binary' => '/usr/bin/pngquant',\n 'liip_imagine.filter.post_processor.mozjpeg.class' => 'Liip\\\\ImagineBundle\\\\Imagine\\\\Filter\\\\PostProcessor\\\\MozJpegPostProcessor',\n 'liip_imagine.mozjpeg.binary' => '/opt/mozjpeg/bin/cjpeg',\n 'liip_imagine.cache.resolver.default' => 'web_path',\n 'liip_imagine.default_image' => NULL,\n 'liip_imagine.filter_sets' => array(\n 'thumbnail_50x40' => array(\n 'filters' => array(\n 'relative_resize' => array(\n 'widen' => 50,\n ),\n ),\n 'quality' => 100,\n 'jpeg_quality' => NULL,\n 'png_compression_level' => NULL,\n 'png_compression_filter' => NULL,\n 'format' => NULL,\n 'animated' => false,\n 'cache' => NULL,\n 'data_loader' => NULL,\n 'default_image' => NULL,\n 'post_processors' => array(\n\n ),\n ),\n 'thumbnail_90x60' => array(\n 'filters' => array(\n 'thumbnail' => array(\n 'size' => array(\n 0 => 90,\n 1 => 60,\n ),\n 'mode' => 'outbound',\n ),\n ),\n 'quality' => 100,\n 'jpeg_quality' => NULL,\n 'png_compression_level' => NULL,\n 'png_compression_filter' => NULL,\n 'format' => NULL,\n 'animated' => false,\n 'cache' => NULL,\n 'data_loader' => NULL,\n 'default_image' => NULL,\n 'post_processors' => array(\n\n ),\n ),\n 'thumbnail_200x200' => array(\n 'filters' => array(\n 'relative_resize' => array(\n 'widen' => 200,\n ),\n ),\n 'quality' => 100,\n 'jpeg_quality' => NULL,\n 'png_compression_level' => NULL,\n 'png_compression_filter' => NULL,\n 'format' => NULL,\n 'animated' => false,\n 'cache' => NULL,\n 'data_loader' => NULL,\n 'default_image' => NULL,\n 'post_processors' => array(\n\n ),\n ),\n 'thumbnail_262x255' => array(\n 'filters' => array(\n 'thumbnail' => array(\n 'size' => array(\n 0 => 265,\n 1 => 255,\n ),\n 'mode' => 'inset',\n ),\n ),\n 'quality' => 100,\n 'jpeg_quality' => NULL,\n 'png_compression_level' => NULL,\n 'png_compression_filter' => NULL,\n 'format' => NULL,\n 'animated' => false,\n 'cache' => NULL,\n 'data_loader' => NULL,\n 'default_image' => NULL,\n 'post_processors' => array(\n\n ),\n ),\n 'thumbnail_310x300' => array(\n 'filters' => array(\n 'relative_resize' => array(\n 'widen' => 310,\n ),\n ),\n 'quality' => 100,\n 'jpeg_quality' => NULL,\n 'png_compression_level' => NULL,\n 'png_compression_filter' => NULL,\n 'format' => NULL,\n 'animated' => false,\n 'cache' => NULL,\n 'data_loader' => NULL,\n 'default_image' => NULL,\n 'post_processors' => array(\n\n ),\n ),\n 'thumbnail_610x600' => array(\n 'filters' => array(\n 'relative_resize' => array(\n 'widen' => 610,\n ),\n ),\n 'quality' => 100,\n 'jpeg_quality' => NULL,\n 'png_compression_level' => NULL,\n 'png_compression_filter' => NULL,\n 'format' => NULL,\n 'animated' => false,\n 'cache' => NULL,\n 'data_loader' => NULL,\n 'default_image' => NULL,\n 'post_processors' => array(\n\n ),\n ),\n ),\n 'liip_imagine.binary.loader.default' => 'filesystem',\n 'liip_imagine.controller.filter_action' => 'liip_imagine.controller:filterAction',\n 'liip_imagine.controller.filter_runtime_action' => 'liip_imagine.controller:filterRuntimeAction',\n 'liip_imagine.controller.redirect_response_code' => 301,\n 'knp_gaufrette.filesystem_map.class' => 'Knp\\\\Bundle\\\\GaufretteBundle\\\\FilesystemMap',\n 'white_october_pagerfanta.default_view' => 'default',\n 'white_october_pagerfanta.view_factory.class' => 'Pagerfanta\\\\View\\\\ViewFactory',\n 'gregwar_captcha.captcha_type.class' => 'Gregwar\\\\CaptchaBundle\\\\Type\\\\CaptchaType',\n 'gregwar_captcha.captcha_generator.class' => 'Gregwar\\\\CaptchaBundle\\\\Generator\\\\CaptchaGenerator',\n 'gregwar_captcha.image_file_handler.class' => 'Gregwar\\\\CaptchaBundle\\\\Generator\\\\ImageFileHandler',\n 'gregwar_captcha.captcha_builder.class' => 'Gregwar\\\\Captcha\\\\CaptchaBuilder',\n 'gregwar_captcha.phrase_builder.class' => 'Gregwar\\\\Captcha\\\\PhraseBuilder',\n 'gregwar_captcha.config.image_folder' => 'captcha',\n 'gregwar_captcha.config.gc_freq' => 100,\n 'gregwar_captcha.config.expiration' => 60,\n 'gregwar_captcha.config.whitelist_key' => 'captcha_whitelist_key',\n 'lexik_jwt_authentication.pass_phrase' => '1234',\n 'lexik_jwt_authentication.token_ttl' => 86400,\n 'lexik_jwt_authentication.user_identity_field' => 'username',\n 'lexik_jwt_authentication.encoder.signature_algorithm' => 'RS256',\n 'lexik_jwt_authentication.encoder.crypto_engine' => 'openssl',\n 'gesdinet.jwtrefreshtoken.refresh_token.class' => 'Gesdinet\\\\JWTRefreshTokenBundle\\\\Entity\\\\RefreshToken',\n 'gesdinet_jwt_refresh_token.ttl' => 86400,\n 'gesdinet_jwt_refresh_token.ttl_update' => true,\n 'gesdinet_jwt_refresh_token.security.firewall' => 'api',\n 'gesdinet_jwt_refresh_token.user_provider' => NULL,\n 'gesdinet.jwtrefreshtoken.entity_manager.id' => 'doctrine.orm.entity_manager',\n 'web_profiler.debug_toolbar.position' => 'bottom',\n 'web_profiler.debug_toolbar.intercept_redirects' => false,\n 'web_profiler.debug_toolbar.mode' => 2,\n 'data_collector.templates' => array(\n 'data_collector.request' => array(\n 0 => 'request',\n 1 => '@WebProfiler/Collector/request.html.twig',\n ),\n 'data_collector.time' => array(\n 0 => 'time',\n 1 => '@WebProfiler/Collector/time.html.twig',\n ),\n 'data_collector.memory' => array(\n 0 => 'memory',\n 1 => '@WebProfiler/Collector/memory.html.twig',\n ),\n 'data_collector.ajax' => array(\n 0 => 'ajax',\n 1 => '@WebProfiler/Collector/ajax.html.twig',\n ),\n 'data_collector.form' => array(\n 0 => 'form',\n 1 => '@WebProfiler/Collector/form.html.twig',\n ),\n 'data_collector.exception' => array(\n 0 => 'exception',\n 1 => '@WebProfiler/Collector/exception.html.twig',\n ),\n 'data_collector.logger' => array(\n 0 => 'logger',\n 1 => '@WebProfiler/Collector/logger.html.twig',\n ),\n 'data_collector.events' => array(\n 0 => 'events',\n 1 => '@WebProfiler/Collector/events.html.twig',\n ),\n 'data_collector.router' => array(\n 0 => 'router',\n 1 => '@WebProfiler/Collector/router.html.twig',\n ),\n 'data_collector.cache' => array(\n 0 => 'cache',\n 1 => '@WebProfiler/Collector/cache.html.twig',\n ),\n 'data_collector.translation' => array(\n 0 => 'translation',\n 1 => '@WebProfiler/Collector/translation.html.twig',\n ),\n 'data_collector.security' => array(\n 0 => 'security',\n 1 => '@Security/Collector/security.html.twig',\n ),\n 'data_collector.twig' => array(\n 0 => 'twig',\n 1 => '@WebProfiler/Collector/twig.html.twig',\n ),\n 'data_collector.doctrine' => array(\n 0 => 'db',\n 1 => '@Doctrine/Collector/db.html.twig',\n ),\n 'swiftmailer.data_collector' => array(\n 0 => 'swiftmailer',\n 1 => '@Swiftmailer/Collector/swiftmailer.html.twig',\n ),\n 'data_collector.dump' => array(\n 0 => 'dump',\n 1 => '@Debug/Profiler/dump.html.twig',\n ),\n 'sonata.block.data_collector' => array(\n 0 => 'block',\n 1 => '@SonataBlock/Profiler/block.html.twig',\n ),\n 'data_collector.config' => array(\n 0 => 'config',\n 1 => '@WebProfiler/Collector/config.html.twig',\n ),\n ),\n 'console.command.ids' => array(\n 'console.command.symfony_bundle_securitybundle_command_userpasswordencodercommand' => 'console.command.symfony_bundle_securitybundle_command_userpasswordencodercommand',\n 'console.command.doctrine_bundle_doctrinecachebundle_command_containscommand' => 'doctrine_cache.contains_command',\n 'console.command.doctrine_bundle_doctrinecachebundle_command_deletecommand' => 'doctrine_cache.delete_command',\n 'console.command.doctrine_bundle_doctrinecachebundle_command_flushcommand' => 'doctrine_cache.flush_command',\n 'console.command.doctrine_bundle_doctrinecachebundle_command_statscommand' => 'doctrine_cache.stats_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_createdatabasedoctrinecommand' => 'doctrine.database_create_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_dropdatabasedoctrinecommand' => 'doctrine.database_drop_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_generateentitiesdoctrinecommand' => 'doctrine.generate_entities_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_importmappingdoctrinecommand' => 'doctrine.mapping_import_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_clearmetadatacachedoctrinecommand' => 'doctrine.cache_clear_metadata_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_clearquerycachedoctrinecommand' => 'doctrine.cache_clear_query_cache_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_clearresultcachedoctrinecommand' => 'doctrine.cache_clear_result_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_collectionregiondoctrinecommand' => 'doctrine.cache_collection_region_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_convertmappingdoctrinecommand' => 'doctrine.mapping_convert_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_createschemadoctrinecommand' => 'doctrine.schema_create_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_dropschemadoctrinecommand' => 'doctrine.schema_drop_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_ensureproductionsettingsdoctrinecommand' => 'doctrine.ensure_production_settings_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_entityregioncachedoctrinecommand' => 'doctrine.clear_entity_region_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_importdoctrinecommand' => 'doctrine.database_import_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_infodoctrinecommand' => 'doctrine.mapping_info_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_queryregioncachedoctrinecommand' => 'doctrine.clear_query_region_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_rundqldoctrinecommand' => 'doctrine.query_dql_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_runsqldoctrinecommand' => 'doctrine.query_sql_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_updateschemadoctrinecommand' => 'doctrine.schema_update_command',\n 'console.command.doctrine_bundle_doctrinebundle_command_proxy_validateschemacommand' => 'doctrine.schema_validate_command',\n 'console.command.doctrine_bundle_migrationsbundle_command_migrationsdiffdoctrinecommand' => 'doctrine_migrations.diff_command',\n 'console.command.doctrine_bundle_migrationsbundle_command_migrationsexecutedoctrinecommand' => 'doctrine_migrations.execute_command',\n 'console.command.doctrine_bundle_migrationsbundle_command_migrationsgeneratedoctrinecommand' => 'doctrine_migrations.generate_command',\n 'console.command.doctrine_bundle_migrationsbundle_command_migrationslatestdoctrinecommand' => 'doctrine_migrations.latest_command',\n 'console.command.doctrine_bundle_migrationsbundle_command_migrationsmigratedoctrinecommand' => 'doctrine_migrations.migrate_command',\n 'console.command.doctrine_bundle_migrationsbundle_command_migrationsstatusdoctrinecommand' => 'doctrine_migrations.status_command',\n 'console.command.doctrine_bundle_migrationsbundle_command_migrationsversiondoctrinecommand' => 'doctrine_migrations.version_command',\n 'console.command.fos_userbundle_command_activateusercommand' => 'fos_user.command.activate_user',\n 'console.command.fos_userbundle_command_changepasswordcommand' => 'fos_user.command.change_password',\n 'console.command.fos_userbundle_command_createusercommand' => 'fos_user.command.create_user',\n 'console.command.fos_userbundle_command_deactivateusercommand' => 'fos_user.command.deactivate_user',\n 'console.command.fos_userbundle_command_demoteusercommand' => 'fos_user.command.demote_user',\n 'console.command.fos_userbundle_command_promoteusercommand' => 'fos_user.command.promote_user',\n 'console.command.sonata_mediabundle_command_addmassmediacommand' => 'Sonata\\\\MediaBundle\\\\Command\\\\AddMassMediaCommand',\n 'console.command.sonata_mediabundle_command_addmediacommand' => 'Sonata\\\\MediaBundle\\\\Command\\\\AddMediaCommand',\n 'console.command.sonata_mediabundle_command_cleanmediacommand' => 'Sonata\\\\MediaBundle\\\\Command\\\\CleanMediaCommand',\n 'console.command.sonata_mediabundle_command_fixmediacontextcommand' => 'Sonata\\\\MediaBundle\\\\Command\\\\FixMediaContextCommand',\n 'console.command.sonata_mediabundle_command_migratetojsontypecommand' => 'Sonata\\\\MediaBundle\\\\Command\\\\MigrateToJsonTypeCommand',\n 'console.command.sonata_mediabundle_command_refreshmetadatacommand' => 'Sonata\\\\MediaBundle\\\\Command\\\\RefreshMetadataCommand',\n 'console.command.sonata_mediabundle_command_removethumbscommand' => 'Sonata\\\\MediaBundle\\\\Command\\\\RemoveThumbsCommand',\n 'console.command.sonata_mediabundle_command_syncthumbscommand' => 'Sonata\\\\MediaBundle\\\\Command\\\\SyncThumbsCommand',\n 'console.command.sonata_mediabundle_command_updatecdnstatuscommand' => 'Sonata\\\\MediaBundle\\\\Command\\\\UpdateCdnStatusCommand',\n 'console.command.sonata_adminbundle_command_createclasscachecommand' => 'Sonata\\\\AdminBundle\\\\Command\\\\CreateClassCacheCommand',\n 'console.command.sonata_adminbundle_command_explainadmincommand' => 'Sonata\\\\AdminBundle\\\\Command\\\\ExplainAdminCommand',\n 'console.command.sonata_adminbundle_command_generateadmincommand' => 'Sonata\\\\AdminBundle\\\\Command\\\\GenerateAdminCommand',\n 'console.command.sonata_adminbundle_command_generateobjectaclcommand' => 'Sonata\\\\AdminBundle\\\\Command\\\\GenerateObjectAclCommand',\n 'console.command.sonata_adminbundle_command_listadmincommand' => 'Sonata\\\\AdminBundle\\\\Command\\\\ListAdminCommand',\n 'console.command.sonata_adminbundle_command_setupaclcommand' => 'Sonata\\\\AdminBundle\\\\Command\\\\SetupAclCommand',\n 'console.command.sonata_easyextendsbundle_command_dumpmappingcommand' => 'Sonata\\\\EasyExtendsBundle\\\\Command\\\\DumpMappingCommand',\n 'console.command.sonata_easyextendsbundle_command_generatecommand' => 'Sonata\\\\EasyExtendsBundle\\\\Command\\\\GenerateCommand',\n 'console.command.sonata_corebundle_command_sonatadumpdoctrinemetacommand' => 'Sonata\\\\CoreBundle\\\\Command\\\\SonataDumpDoctrineMetaCommand',\n 'console.command.sonata_corebundle_command_sonatalistformmappingcommand' => 'Sonata\\\\CoreBundle\\\\Command\\\\SonataListFormMappingCommand',\n 'console.command.sonata_blockbundle_command_debugblockscommand' => 'Sonata\\\\BlockBundle\\\\Command\\\\DebugBlocksCommand',\n 'console.command.lexik_bundle_jwtauthenticationbundle_command_checkconfigcommand' => 'lexik_jwt_authentication.check_config_command',\n 'console.command.sensiolabs_security_command_securitycheckercommand' => 'sensio_distribution.security_checker.command',\n 'console.command.symfony_bundle_webserverbundle_command_serverruncommand' => 'console.command.symfony_bundle_webserverbundle_command_serverruncommand',\n 'console.command.symfony_bundle_webserverbundle_command_serverstartcommand' => 'console.command.symfony_bundle_webserverbundle_command_serverstartcommand',\n 'console.command.symfony_bundle_webserverbundle_command_serverstopcommand' => 'console.command.symfony_bundle_webserverbundle_command_serverstopcommand',\n 'console.command.symfony_bundle_webserverbundle_command_serverstatuscommand' => 'console.command.symfony_bundle_webserverbundle_command_serverstatuscommand',\n ),\n 'nelmio_api_doc.parser.form_type_parser.class' => 'Nelmio\\\\ApiDocBundle\\\\Parser\\\\FormTypeParser',\n 'nelmio_api_doc.parser.jms_metadata_parser.class' => 'Nelmio\\\\ApiDocBundle\\\\Parser\\\\JmsMetadataParser',\n 'sonata.core.form.types' => array(\n 0 => 'application_user.registration.form.type',\n 1 => 'application_user.profile.form.type',\n 2 => 'application_sonata_user.profile.authentication.form.type',\n 3 => 'form.type.form',\n 4 => 'form.type.choice',\n 5 => 'form.type.entity',\n 6 => 'fos_user.username_form_type',\n 7 => 'fos_user.profile.form.type',\n 8 => 'fos_user.registration.form.type',\n 9 => 'fos_user.change_password.form.type',\n 10 => 'fos_user.resetting.form.type',\n 11 => 'fos_user.group.form.type',\n 12 => 'sonata.user.form.type.security_roles',\n 13 => 'sonata.user.profile.form.type',\n 14 => 'sonata.user.form.gender_list',\n 15 => 'sonata.user.registration.form.type',\n 16 => 'sonata.user.api.form.type.group',\n 17 => 'sonata.user.api.form.type.user',\n 18 => 'sonata.media.form.type.media',\n 19 => 'sonata.media.api.form.type.doctrine.media',\n 20 => 'sonata.media.api.form.type.media',\n 21 => 'sonata.media.api.form.type.gallery',\n 22 => 'sonata.media.api.form.type.gallery_has_media',\n 23 => 'ivory_ck_editor.form.type',\n 24 => 'sonata.admin.form.type.admin',\n 25 => 'sonata.admin.form.type.model_choice',\n 26 => 'sonata.admin.form.type.model_list',\n 27 => 'sonata.admin.form.type.model_reference',\n 28 => 'sonata.admin.form.type.model_hidden',\n 29 => 'sonata.admin.form.type.model_autocomplete',\n 30 => 'sonata.admin.form.type.collection',\n 31 => 'sonata.admin.doctrine_orm.form.type.choice_field_mask',\n 32 => 'sonata.admin.form.filter.type.number',\n 33 => 'sonata.admin.form.filter.type.choice',\n 34 => 'sonata.admin.form.filter.type.default',\n 35 => 'sonata.admin.form.filter.type.date',\n 36 => 'sonata.admin.form.filter.type.daterange',\n 37 => 'sonata.admin.form.filter.type.datetime',\n 38 => 'sonata.admin.form.filter.type.datetime_range',\n 39 => 'sonata.core.form.type.array',\n 40 => 'sonata.core.form.type.boolean',\n 41 => 'sonata.core.form.type.collection',\n 42 => 'sonata.core.form.type.translatable_choice',\n 43 => 'sonata.core.form.type.date_range',\n 44 => 'sonata.core.form.type.datetime_range',\n 45 => 'sonata.core.form.type.date_picker',\n 46 => 'sonata.core.form.type.datetime_picker',\n 47 => 'sonata.core.form.type.date_range_picker',\n 48 => 'sonata.core.form.type.datetime_range_picker',\n 49 => 'sonata.core.form.type.equal',\n 50 => 'sonata.core.form.type.color_selector',\n 51 => 'sonata.core.form.type.color',\n 52 => 'sonata.formatter.form.type.selector',\n 53 => 'sonata.formatter.form.type.simple',\n 54 => 'sonata.block.form.type.block',\n 55 => 'sonata.block.form.type.container_template',\n 56 => 'sonata.classification.form.type.category_selector',\n 57 => 'sonata.classification.api.form.type.category',\n 58 => 'sonata.classification.api.form.type.collection',\n 59 => 'sonata.classification.api.form.type.tag',\n 60 => 'sonata.classification.api.form.type.context',\n 61 => 'mopa_bootstrap.form.type.tab',\n 62 => 'mopa_bootstrap.form.type.form_actions',\n 63 => 'lexik_form_filter.type.filter_text',\n 64 => 'lexik_form_filter.type.filter_number',\n 65 => 'lexik_form_filter.type.filter_number_range',\n 66 => 'lexik_form_filter.type.filter_checkbox',\n 67 => 'lexik_form_filter.type.filter_boolean',\n 68 => 'lexik_form_filter.type.filter_choice',\n 69 => 'lexik_form_filter.type.filter_date',\n 70 => 'lexik_form_filter.type.filter_date_range',\n 71 => 'lexik_form_filter.type.filter_datetime',\n 72 => 'lexik_form_filter.type.filter_datetime_range',\n 73 => 'lexik_form_filter.type.filter_collection_adapter',\n 74 => 'lexik_form_filter.type.filter_sharedable',\n 75 => 'lexik_form_filter.type.filter_entity',\n 76 => 'liip_imagine.form.type.image',\n 77 => 'captcha.type',\n ),\n 'sonata.core.form.type_extensions' => array(\n 0 => 'form.type_extension.form.http_foundation',\n 1 => 'form.type_extension.form.validator',\n 2 => 'form.type_extension.repeated.validator',\n 3 => 'form.type_extension.submit.validator',\n 4 => 'form.type_extension.upload.validator',\n 5 => 'form.type_extension.csrf',\n 6 => 'form.type_extension.form.data_collector',\n 7 => 'sonata.admin.form.extension.field',\n 8 => 'sonata.admin.form.extension.choice',\n 9 => 'fos_rest.form.extension.csrf_disable',\n 10 => 'nelmio_api_doc.form.extension.description_form_type_extension',\n 11 => 'mopa_bootstrap.form.type_extension.embed_form',\n 12 => 'mopa_bootstrap.form.type_extension.static_text',\n 13 => 'mopa_bootstrap.form.type_extension.offset_button',\n 14 => 'mopa_bootstrap.form.type_extension.button',\n 15 => 'mopa_bootstrap.form.type_extension.help',\n 16 => 'mopa_bootstrap.form.type_extension.legend',\n 17 => 'mopa_bootstrap.form.type_extension.error',\n 18 => 'mopa_bootstrap.form.type_extension.widget',\n 19 => 'mopa_bootstrap.form.type_extension.horizontal',\n 20 => 'mopa_bootstrap.form.type_extension.widget_collection',\n 21 => 'mopa_bootstrap.form.type_extension.date',\n 22 => 'mopa_bootstrap.form.type_extension.datetime',\n 23 => 'mopa_bootstrap.form.type_extension.time',\n 24 => 'mopa_bootstrap.form.type_extension.tabbed',\n 25 => 'lexik_form_filter.type_extension.filter_extension',\n ),\n );\n }",
"protected static function getDefaultParams()\n {\n return [\n \"skipSerialisation\" => false,\n \"useFullHead\" => false,\n \"url\" => null\n ];\n }",
"private function getDefaultParams(): array\n {\n return [\n 'lamg' => $this->lang,\n 'limit' => 1,\n 'hours' => false,\n 'extra' => false,\n ];\n }",
"public function appParams()\n {\n return [];\n }"
] | [
"0.6951218",
"0.6579614",
"0.6342236",
"0.6342236",
"0.63258076",
"0.63229597",
"0.62768537",
"0.62225384",
"0.6212396",
"0.6146185",
"0.61311734",
"0.60378563",
"0.6022152",
"0.60137975",
"0.6013667",
"0.60122955",
"0.5994975",
"0.5967293",
"0.5959802",
"0.59202355",
"0.58774424",
"0.5857227",
"0.5853842",
"0.58399254",
"0.58208114",
"0.57945126",
"0.5787325",
"0.57433486",
"0.57384807",
"0.57340634"
] | 0.75034314 | 0 |
Registers the default application routes. | protected function registerDefaultRoutes()
{
WiseServiceProvider::registerRoutes($this);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected function defineRoutes()\n {\n if (!$this->app->routesAreCached()) {\n $router = app('router');\n\n $router->group(['namespace' => 'Scool\\Social\\Notifications\\Http\\Controllers'], function () {\n require __DIR__.'/../Http/routes.php';\n });\n\n }\n }",
"public function loadCustomRoutes()\n {\n if (strpos($this->app->version(), 'Lumen') !== false) {\n\n $this->app->group([\n 'namespace' => 'SumanIon\\TelegramBot\\Controllers',\n 'prefix' => 'api'\n ], function () {\n\n $router = $this->app;\n\n require __DIR__ . '/../../routes/api.php';\n });\n\n } else {\n\n $this->app['router']->group([\n 'middleware' => 'api',\n 'namespace' => 'SumanIon\\TelegramBot\\Controllers',\n 'prefix' => 'api',\n ], function () {\n\n $router = $this->app['router'];\n\n require __DIR__ . '/../../routes/api.php';\n });\n }\n }",
"protected function routes()\n {\n Nova::routes()\n ->withAuthenticationRoutes()\n ->withPasswordResetRoutes()\n ->register();\n }",
"protected function routes()\n {\n Nova::routes()\n ->withAuthenticationRoutes()\n ->withPasswordResetRoutes()\n ->register();\n }",
"protected function routes()\n {\n Nova::routes()\n ->withAuthenticationRoutes()\n ->withPasswordResetRoutes()\n ->register();\n }",
"protected function defineRoutes()\n {\n if (! $this->app->routesAreCached()) {\n $router = app('router');\n\n $router->group(['namespace' => 'CopyaTestimonial\\Http\\Controllers'], function ($router) {\n\n require __DIR__.'/../routes/console.php';\n require __DIR__.'/../routes/web.php';\n });\n\n $this->mapApiRoutes();\n }\n }",
"public function setRoutes(): void\n {\n $versions = $this->_versions;\n $default = 'api/v1/v0';\n\n Router::scope('/api', function ($routes) use ($versions, $default) {\n // Setting up fallback non-versioned API url calls.\n // It can handle `api/controller/index.json` as well\n // as `api/controller.json` calls.\n Router::prefix('api', function ($routes) use ($default) {\n $routes->setExtensions(['json']);\n $routes->connect('/:controller', ['prefix' => $default], ['routeClass' => DashedRoute::class]);\n $routes->connect('/:controller/:action/*', ['prefix' => $default], ['routeClass' => DashedRoute::class]);\n $routes->fallbacks(DashedRoute::class);\n });\n\n foreach ($versions as $version) {\n Router::prefix($version['prefix'], ['path' => $version['path']], function ($routes) {\n $routes->setExtensions(['json']);\n $routes->fallbacks(DashedRoute::class);\n });\n }\n });\n }",
"protected function bootRoutes(): void\n\t{\n\t\tif ($this->app->routesAreCached()) {\n\t\t\treturn;\n\t\t}\n\n\t\t// TODO: Config CSRF requirements/HTTP referrer checks\n\n\t\ttry {\n\t\t\t/** @var \\Illuminate\\Contracts\\Routing\\Registrar $router */\n\t\t\t$router = $this->app->make('router');\n\n\t\t\t/** @var \\Illuminate\\Contracts\\Config\\Repository $config */\n\t\t\t$config = $this->app->make('config');\n\n\t\t\t// Skip if routes have been disabled\n\t\t\tif (! $config->get('addressing.routes.enabled', true)) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t$prefix = $config->get('addressing.routes.prefix', 'galahad/addressing');\n\n\t\t\t$router->group(compact('prefix'), static function(Registrar $route) {\n\t\t\t\t$route->get('/countries', CountriesController::class)\n\t\t\t\t\t->name('galahad.addressing.countries');\n\n\t\t\t\t$route->get('/countries/{country_code}/administrative-areas', AdministrativeAreasController::class)\n\t\t\t\t\t->name('galahad.addressing.administrative-areas');\n\t\t\t});\n\t\t} catch (BindingResolutionException $exception) {\n\t\t\t// Skip routes if no router exists\n\t\t}\n\t}",
"protected function registerRoutes()\n {\n $config = $this->app['config']->get('mail-telemetry.route', []);\n $authConfig = $this->app['config']->get('mail-telemetry.auth-route', []);\n $namespace = ['namespace'=> 'Pace\\MailTelemetry\\Http\\Controllers'];\n\n Route::group(\\array_merge($config, $namespace), function () {\n $this->loadRoutesFrom(__DIR__ . '/../routes/api.php');\n });\n\n Route::group(\\array_merge($authConfig, $namespace), function () {\n $this->loadRoutesFrom(__DIR__ . '/../routes/auth.php');\n });\n }",
"private function registerRoutes()\n {\n Route::group($this->routeConfiguration(), function () {\n $this->loadRoutesFrom(__DIR__ . '/Http/routes.php');\n });\n }",
"protected function initRoutes()\n {\n if (isset($this->settings) && $this->settings->exists('routes') || !self::$init_stages[$this->name]['routes']) {\n\n $routes = $this->settings->get('routes');\n\n // Get uncamelized app name\n $string = new CamelCase($this->name);\n $app = $string->uncamelize();\n\n // Add always a missing index route!\n if (!array_key_exists('index', $routes)) {\n $routes['index'] = [];\n }\n\n foreach ($routes as $name => $definition) {\n\n if (is_numeric($name)) {\n Throw new AppException(sprintf('AbstractApp \"%s\" sent a nameless route to be mapped.', $this->name));\n }\n\n $definition = $this->parseRouteDefintion($name, $definition);\n\n $this->core->router->map($definition['method'], $definition['route'], $definition['target'], $definition['name']);\n }\n\n self::$init_stages[$this->name]['routes'] = true;\n }\n }",
"protected function registerRoutes()\n {\n $this->app['router']->group(\n [\n 'namespace' => __NAMESPACE__.'\\Http\\Controllers',\n 'middleware' => config('laravolt.auth.router.middleware'),\n 'prefix' => config('laravolt.auth.router.prefix'),\n 'as' => 'auth::',\n ],\n function (Router $router) {\n\n // Authentication Routes...\n $router->get('login', 'LoginController@showLoginForm')->name('login');\n $router->post('login', 'LoginController@login')->name('login');\n $router->any('logout', 'LoginController@logout')->name('logout');\n\n // Password Reset Routes...\n $router->get('forgot', 'ForgotPasswordController@showLinkRequestForm')->name('forgot');\n $router->post('forgot', 'ForgotPasswordController@sendResetLinkEmail')->name('forgot');\n $router->get('reset/{token}', 'ResetPasswordController@showResetForm')->name('reset');\n $router->post('reset/{token}', 'ResetPasswordController@reset')->name('reset');\n\n if (config('laravolt.auth.registration.enable')) {\n // Registration Routes...\n $router->get('register', 'RegisterController@showRegistrationForm')->name('register');\n $router->post('register', 'RegisterController@register')->name('register');\n\n // Activation Routes...\n $router->get('activate/{token}', 'ActivationController@activate')->name('activate');\n }\n }\n );\n }",
"protected function registerRoutes()\n {\n Route::group($this->routeConfiguration(), function () {\n $this->loadRoutesFrom(__DIR__.'/../routes/api.php');\n });\n }",
"public function registerRoutes()\n {\n register_rest_route(\n 'kma/v1',\n $this->restCollection,\n [\n 'methods' => 'GET',\n 'callback' => [$this, 'restCollection'],\n 'permission_callback' => '__return_true'\n ]\n );\n\n register_rest_route(\n 'kma/v1',\n $this->restSingleton,\n [\n 'methods' => 'GET',\n 'callback' => [$this, 'restSingleton'],\n 'permission_callback' => '__return_true'\n ]\n );\n\n $this->addRestRoutes();\n }",
"protected function iniRoutes() {\n \n }",
"protected function registerRoutes()\n {\n Route::group($this->routeConfiguration(), function () {\n $this->loadRoutesFrom(__DIR__ . '/../routes/web.php');\n });\n }",
"private function registerRoutes()\n {\n Route::group($this->routeConfiguration(), function () {\n $this->loadRoutesFrom(__DIR__.'/Http/routes.php');\n });\n }",
"private function registerRoutes()\n {\n Route::group($this->routeConfiguration(), function () {\n $this->loadRoutesFrom(__DIR__.'/Http/routes.php');\n });\n }",
"abstract public function register_routes();",
"public function register_routes()\n {\n // ping\n register_rest_route(static::$namespace, '/ping', array(\n 'methods' => 'GET',\n 'callback' => array($this, 'ping'),\n 'permission_callback' => '__return_true',\n ));\n\n // Right now we only have a survey disconnect endpoint.\n register_rest_route(static::$namespace, \"/survey/disconnect\", array(\n 'methods' => 'POST',\n 'callback' => array($this, 'post_disconnect_survey'),\n 'permission_callback' => array($this, 'permission_callback'),\n ));\n\n // Sync Stats\n register_rest_route(static::$namespace, '/sync/stats', array(\n 'methods' => 'GET',\n 'callback' => array($this, 'get_sync_stats'),\n 'permission_callback' => array($this, 'permission_callback'),\n ));\n\n // remove review banner\n register_rest_route(static::$namespace, \"/review-banner\", array(\n 'methods' => 'GET',\n 'callback' => array($this, 'dismiss_review_banner'),\n 'permission_callback' => array($this, 'permission_callback'),\n ));\n }",
"private function registerRoutes()\n {\n Route::group($this->routeConfiguration(), function (): void {\n $this->loadRoutesFrom(__DIR__.'/../routes/routes.php');\n });\n }",
"protected function registerRoutes()\n {\n Route::group($this->routeConfiguration(), function () {\n $this->loadRoutesFrom(__DIR__.'/../routes/web.php');\n });\n }",
"private function registerRoutes()\n {\n Route::group($this->routeConfiguration(), function () {\n Route::get('/', 'SettingController@index')->name('settings');\n Route::post('/', 'SettingController@store');\n });\n }",
"private function registerRoutes()\n {\n Route::namespace('Davidhsianturi\\Compass\\Http\\Controllers')\n ->as('compass.')\n ->prefix(config('compass.path'))\n ->group(function () {\n $this->loadRoutesFrom(__DIR__.'/Http/routes.php');\n });\n }",
"protected function defineRoutes()\n {\n if (app()->routesAreCached() || config('zpay.routes') === false) {\n return;\n }\n\n Route::group($this->routeConfiguration(), function () {\n $this->loadRoutesFrom(__DIR__.'/../routes/web.php');\n });\n }",
"protected function configureRoutes()\n {\n if (Money::$registersRoutes) {\n Route::group([\n 'namespace' => 'ScadaUnity\\Money\\Http\\Controllers',\n 'domain' => config('money.domain', null),\n 'prefix' => config('money.prefix', config('money.path')),\n ], function () {\n $this->loadRoutesFrom(__DIR__.'/../routes/'.config('money.stack').'.php');\n });\n }\n }",
"protected function mapRoutes()\n {\n $this->loadRoutesFrom(__DIR__.'/../routes/api.php');\n $this->loadRoutesFrom(__DIR__.'/../routes/web.php');\n }",
"public function loadRoutes()\n {\n require path('app') . '/Http/routes.php';\n }",
"public function registerRoutes()\n {\n foreach (self::routes() as $route) {\n register_rest_route(Constants::HYPHEN_NAME, '/' . $route['slug'], [\n [\n 'methods' => $route['method'],\n 'callback' => $route['callback'],\n ]\n ]);\n }\n }",
"public function loadRoutes()\n {\n include($this->getLibBasePath() . '/config/routes.php');\n include($this->getLibUniPath() . '/config/routes.php');\n $this->loadAppRoutes();\n }"
] | [
"0.71575594",
"0.7090626",
"0.70153767",
"0.7013848",
"0.7013848",
"0.6968404",
"0.6964437",
"0.69332004",
"0.68867993",
"0.68729305",
"0.68654865",
"0.68646765",
"0.68545973",
"0.6851512",
"0.68453664",
"0.6841957",
"0.68305707",
"0.68305707",
"0.68207073",
"0.6810306",
"0.67978066",
"0.67955536",
"0.6766587",
"0.6746117",
"0.6745188",
"0.6726197",
"0.6713218",
"0.6709169",
"0.6692277",
"0.6664336"
] | 0.79207957 | 0 |
Registers the default application services. | protected function registerDefaultServices()
{
$this->register(
new WiseServiceProvider(),
array(
'wise.cache_dir' => $this['path']['cache'] . '/config',
'wise.path' => $this['path']['config'],
'wise.options' => array(
'config' => array(
'routes' => 'routes',
'services' => 'services',
),
'mode' => $this['mode'],
'parameters' => $this,
'type' => 'yml',
)
)
);
$file = 'parameters';
if ('prod' !== $this['mode']) {
$file .= '_' . $this['mode'];
}
$file .= '.' . $this['wise.options']['type'];
$parameters = $this->load($file);
unset($parameters['imports']);
foreach ($parameters as $key => $value) {
$this[$key] = $value;
}
WiseServiceProvider::registerServices($this);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected function registerServices()\n {\n $this->app->register(GravatarServiceProvider::class);\n\n foreach ($this->bindings as $key => $value) {\n is_numeric($key) ? $this->app->singleton($value) : $this->app->singleton($key, $value);\n }\n }",
"protected function registerServices()\n {\n foreach ($this->bindings as $key => $value) {\n is_numeric($key)\n ? $this->app->singleton($value)\n : $this->app->singleton($key, $value);\n }\n }",
"private function registerServices()\n {\n $this->app->singleton('pluggables', function ($app) {\n return new Pluggables($app['config'], $app['files']);\n });\n\n $this->app->booting(function ($app) {\n $app['pluggables']->register();\n });\n }",
"public function register()\n {\n $this->defaultLoaders();\n }",
"public function register()\n {\n $this->app->singleton(DefaultManager::class, function($app) {\n $manager = new DefaultManager();\n $manager->addIndex(Page::class, PageIndex::class);\n $manager->addIndex(Entry::class, EntityIndex::class);\n return $manager;\n });\n $this->app->bindIf(IndexManagerInterface::class, DefaultManager::class);\n }",
"public function register()\n {\n $this->app->singleton(Generator::class, DefaultGenerator::class);\n $this->app->singleton(Connector::class, DefaultConnector::class);\n }",
"protected function registerServices()\n {\n\n $services = [\n 'Contracts\\InitialFrontendState' => 'InitialFrontendState',\n ];\n\n foreach ($services as $key => $value) {\n $this->app->singleton('Modules\\Evolutly\\\\'.$key, 'Modules\\Evolutly\\\\'.$value);\n }\n }",
"public function register(): void {\n $this->registerRepositories();\n $this->registerServices();\n }",
"public function register()\n {\n // TODO: Implement register() method.\n // Nothing to register, makes me think a service provider may not be the best solution.\n }",
"public function register()\n {\n $this->app->bind(\n ServicesInterface::class,\n Services::class\n );\n }",
"private function registerCoreServices()\n\t{\n\t\t$this->container->set('router', new Router());\n\t}",
"protected function registerServices()\n {\n $this->app->bind(History::class);\n $this->app->bind(CookieJar::class);\n\n $this->app->singleton('goutte', function ($app) {\n $config = $app->make('config');\n\n $goutte = new GoutteClient(\n HttpClient::create($config->get('goutte.client', [])),\n $app->make(History::class),\n $app->make(CookieJar::class)\n );\n\n return $goutte;\n });\n }",
"public function register() {\n $services = [\n HomePageInterface::class => HomePageRepository::class,\n NumbersInterface::class => NumbersRepository::class,\n AboutPageInterface::class => AboutPageRepository::class,\n TeamsInterface::class => TeamsRepository::class,\n GamesInterface::class => GamesRepository::class,\n CalendarPageInterface::class => CalendarPageRepository::class,\n DonatePageInterface::class => DonatePageRepository::class,\n NewsInterface::class => NewsRepository::class,\n ContactInterface::class => ContactRepository::class,\n ];\n\n foreach ($services as $key => $value) {\n $this->app->bindIf($key, $value);\n }\n }",
"protected function registerServices()\n\t{\n\t\t$di = new FactoryDefault();\n\n\t\t$loader = new Loader();\n\n\t\t//register namespaces here\n\n\t\t$loader->registerNamespaces(array(\n\t\t\t'Sport\\Library'\t=>\tAPP_PATH . 'app/library/',\n\t\t\t'Sport\\Common'\t=>\tAPP_PATH . 'app/common/classes/',\n\t\t\t'Sport\\Auth'\t=>\tAPP_PATH . 'app/modules/auth/classes'\n\t\t));\n\n\t\t//\tadd config to $di => dependancy injection\n\t\t$config = new \\Phalcon\\Config\\Adapter\\Php(APP_PATH . 'app/config/config.php');\n\t\t$di->set('config', $config);\n\n\t\t//\tregister the directories\n\t\t$loader->registerDirs(array(\n\t\t\tAPP_PATH . 'app/library/',\n\t\t\tAPP_PATH . 'app/config',\n\t\t\tAPP_PATH . 'app/common/controllers'\n\t\t))->register();\n\n\t\t//\tregister the MVC dispatcher\n\t\t$di->setShared('dispatcher', function(){\n\t\t\t$eventsmanager = new EventsManager;\n\n\t\t\t$dispatcher = new PhDispatcher;\n\n\t\t\t$dispatcher->setEventsManager($eventsmanager);\n\n\t\t\treturn $dispatcher;\n\t\t});\n\n\t\t$di->set('view', function(){\n\t\t\t$view = new View();\n\t\t\treturn $view;\n\t\t}, true);\n\n\t\t$di->set('commonv', function(){\n\t\t\t$view = new View();\n\t\t\treturn $view;\n\t\t}, true);\n\n\t\t//\tregister a router\n\t\t$di->set('router', function(){\n\t\t\t$router = new Router();\n\n\t\t\t$router->removeExtraSlashes(true);\n\n\t\t\t$router->setDefaultModule('main');\n\n\t\t\t$router->add('/', [\n\t\t\t\t'module'\t\t=>\t'main',\n\t\t\t\t'controller'\t=>\t'home',\n\t\t\t\t'action'\t\t=>\t'index'\n\t\t\t]);\n\n\t\t\t$router->add('/:module', [\n\t\t\t\t'module'\t\t=>\t1,\n\t\t\t\t'controller'\t=>\t'home',\n\t\t\t\t'action'\t\t=>\t'index'\n\t\t\t]);\n\n\t\t\t$router->add('/:module/:controller', [\n\t\t\t\t'module'\t\t=>\t1,\n\t\t\t\t'controller'\t=>\t2,\n\t\t\t\t'action'\t\t=>\t'index'\n\t\t\t]);\n\n\t\t\t$router->add('/:module/:controller/:action/:params', [\n\t\t\t\t'module'\t\t=>\t1,\n\t\t\t\t'controller'\t=>\t2,\n\t\t\t\t'action'\t\t=>\t3,\n\t\t\t\t'params'\t\t=>\t4\n\t\t\t]);\n\n\t\t\treturn $router;\n\t\t});\n\n\t\t//\tregister assets\n\n\t\t$di->set('assets', function(){\n\t\t\t$assets = new \\Phalcon\\Assets\\Manager();\n\t\t\t$assets\n\t\t\t\t->collection('js')\n\t\t\t\t;\n\t\t\t$assets\n\t\t\t\t->collection('css')\n\t\t\t\t->addCss('semantic/semantic.min.css')\n\t\t\t;\n\n\t\t\treturn $assets;\n\t\t});\n\n\t\t$di->set('url', function(){\n\t\t\t$url = new \\Phalcon\\Mvc\\Url();\n\t\t\t$url->setBaseUri($config->app->base_url );\n\t\t\treturn $url;\n\t\t});\n\n\t\t$di->set('flash', function(){\n\t\t\treturn new FlashDirect();\n\t\t});\n\n\t\t$di->setShared('session', function(){\n\t\t\t$session = new SessionAdapter();\n\n\t\t\t$session->start();\n\n\t\t\treturn $session;\n\t\t});\n\n\t\t$di->set('db', function() use ($config){\n\t\t\t$db = new MysqlAdapater([\n\t\t\t\t\"host\"\t\t=>\t$config->database->host,\n\t\t\t\t\"username\"\t=>\t$config->database->username,\n\t\t\t\t\"password\"\t=>\t$config->database->password,\n\t\t\t\t\"dbname\"\t=>\t$config->database->name,\n\t\t\t\t\"options\"\t=> [\n\t\t\t\t\t\\PDO::MYSQL_ATTR_INIT_COMMAND => \"SET NAMES 'UTF8'\"\n\t\t\t\t]\n\t\t\t]);\n\n\t\t\treturn $db;\n\t\t});\n\n\t\t$this->setDI($di);\n\t}",
"protected function registerDefaultRoutes()\n {\n WiseServiceProvider::registerRoutes($this);\n }",
"public function register()\n {\n $this->loadConfigDefaults();\n }",
"public function register() : void\n {\n $environment = $this->app->environment();\n\n $providers = array_unique(array_merge(\n $this->app['config']->get('app.' . 'providers', []),\n $this->app['config']->get('app.' . $environment . '_providers', [])\n ));\n\n foreach ($providers as $provider) {\n $this->app->register($provider);\n }\n }",
"public function register()\n {\n $this->app->register(BaumServiceProvider::class);\n }",
"public function register()\n {\n $services = [\n [\n UserServiceInterface::class,\n UserService::class\n ],\n [\n HomeServiceInterface::class,\n HomeService::class\n ],\n [\n CategoryServiceInterface::class,\n CategoryService::class\n ],\n ];\n foreach ($services as $service) {\n $this->app->bind(\n $service[0],\n $service[1]\n );\n }\n }",
"public function registerContainerServices()\n {\n $containerServices = new ContainerServices($this->getAppInstance());\n $containerServices->registerAllServices();\n }",
"public function register()\n {\n $this->app->bind(EmployeesInterface::class, EmployeesService::class);\n }",
"public function register()\n {\n foreach ($this->services as $interface => $service) {\n App::bind($interface, $service);\n }\n }",
"public function register(): void\n {\n $this->app->register(BindingInformationProvider::class);\n $this->app->register(ProviderInformationProvider::class);\n }",
"public function register()\n {\n $this->app->bind(\\Laravel\\Passport\\Http\\Controllers\\AccessTokenController::class, AccessTokenController::class);\n\n $this->mergeConfigurations();\n\n $this->registerSingletons();\n\n }",
"public function register()\n {\n $services = ['Login', 'Organ'];\n\n foreach ($services as $item) {\n $this->app->bind(\"App\\Http\\Service\\\\{$item}Service\",\n \"App\\Http\\Service\\Impl\\\\{$item}ServiceImpl\");\n $this->app->singleton(\"App\\Http\\Controller\\\\{$item}Controller\", function ($app) use ($item) {\n return new ${\"${$item}Controller\"}($app->make(\"{$item}Service\"));\n });\n }\n }",
"public function register()\n {\n $this->app->bind(ProviderInterface::class, AppleService::class);\n $this->app->bind(ProviderInterface::class, GoogleService::class);\n }",
"protected function registerServices()\n {\n $this->app->singleton(\n 'document',\n function () {\n return new Manager();\n }\n );\n }",
"public function register()\n {\n $this->app->register(RouteServiceProvider::class);\n $this->app->register(VoyagerServiceProvider::class);\n }",
"protected function registerCore()\n {\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ExceptionServiceProvider');\n\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ApplicationServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\TransformerServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\DecoratorServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\PresenterServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\MessagesServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ListenerServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\LoaderServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\AssetServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ImageServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ModelServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\CacheServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ViewServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\LogServiceProvider');\n\n // Deferred\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\TranslationServiceProvider');\n\n // Register addon components.\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\AddonServiceProvider');\n\n // Setup some application components.\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ActiveDistributionServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ActiveModuleServiceProvider');\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ActiveThemeServiceProvider');\n\n // Lastly let config cascade nicely back to themes.\n $this->app->register('Anomaly\\Streams\\Platform\\Provider\\ConfigServiceProvider');\n }",
"public function register()\n {\n $this->app->register(RouteServiceProvider::class);\n $this->app->register(EventServiceProvider::class);\n $this->app->register(MenuServiceProvider::class);\n $this->app->register(AuthServiceProvider::class);\n $this->app->register(ConsoleServiceProvider::class);\n }"
] | [
"0.62135863",
"0.5912074",
"0.5892821",
"0.58863544",
"0.5862195",
"0.579497",
"0.57133806",
"0.56812966",
"0.56731915",
"0.5665839",
"0.5657304",
"0.56498766",
"0.56472725",
"0.56272733",
"0.56228745",
"0.5599039",
"0.55733466",
"0.55549645",
"0.55498177",
"0.55424136",
"0.5542055",
"0.5532339",
"0.55242723",
"0.5489408",
"0.5485736",
"0.548313",
"0.5466199",
"0.54628754",
"0.54474324",
"0.54435647"
] | 0.66257936 | 0 |
Get products primary category. | public function getPrimaryCategory($productID)
{
$this->Category->unbindProducts();
$this->Category->bindName($this->Category, 0, false);
$record = $this->Category->find('first', array(
'joins' => array(
array(
'table' => 'product_categories',
'alias' => 'ProductCategory',
'type' => 'INNER',
'conditions'=> array('ProductCategory.category_id = Category.id')
)
),
'conditions' => array(
'ProductCategory.product_id' => $productID,
'ProductCategory.primary' => 1
)
));
return $record;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getPrimaryCategory()\n {\n return $this->primaryCategory;\n }",
"function mp_category_get_primary_category( $post_id ) {\n\t$primary_category_id = get_post_meta( '1', '_minimal-primary-category', true );\n\treturn get_category( $primary_category_id );\n}",
"public function getProductsCatFirst(){\n\t\t$id_max = $this->min('ordering_products_categories');\n\t\t$categories = $this\n\t\t->where('ordering_products_categories','=',$id_max)\n\t\t->first();\n\t\treturn $categories; \n\t}",
"public function getProductCategory(){\n $sql = \"SELECT p.*, c.name AS 'categoryname' FROM products p\n INNER JOIN categories c ON c.id = p.category_id\n WHERE p.category_id = {$this->getCategoryId()}\n ORDER BY id DESC\";\n\n $products = $this->db->query($sql);\n\n return $products;\n }",
"function today_get_primary_category( $post ) {\n\tif ( ! $post instanceof WP_Post ) return null;\n\n\t$primary = null;\n\t$cats = wp_get_post_categories( $post->ID, array(\n\t\t'fields' => 'all'\n\t) );\n\n\tif ( is_wp_error( $cats ) || ! $cats ) return null;\n\n\tforeach ( $cats as $cat ) {\n\t\tif ( intval( get_post_meta( $post->ID, '_yoast_wpseo_primary_category', true ) ) === intval( $cat->term_id ) ) {\n\t\t\t$primary = $cat;\n\t\t\tbreak;\n\t\t}\n\t}\n\n\tif ( ! $primary ) {\n\t\t$primary = $cats[0];\n\t}\n\n\treturn $primary;\n}",
"public function getCategory()\n\t{\n\t\t$Category = new Product_Category();\n\t\treturn $Category->findItem( array( 'Id = '.$this->CategoryId ) );\n\t}",
"public function get_current_post_primary_category() {\n\t\tglobal $post;\n\t\tif ( ! $post || ! $post->ID ) {\n\t\t\treturn 0;\n\t\t}\n\t\treturn $this->get_primary_category_for_post( $post->ID );\n\t}",
"public function products_category()\n {\n \n $value = $this->buy_product_mdl->fetch_categories();\n return $value;\n }",
"public function getByProductCategory()\n {\n return $this->db->Query('Select * from Product where product_category_id = ' . MySQL::SQLValue($this->ProductCategoryID,MySQL::SQLVALUE_NUMBER))->fetch_all(MYSQLI_ASSOC);\n }",
"public function getCategory()\n\t{\n\t\tif (empty($this->_category)) {\n\t\t\t$productCategoryTable = KIT_Db_Table_Abstract::get('KIT_Catalog_DbTable_Product_Category');\n\t\t\t$defaultCategory = $productCategoryTable->getDefaultCategory($this->getId(), true);\n\t\t\t$this->_category = self::get('KIT_Catalog_Product_Category');\n\t\t\tif (empty($defaultCategory)) {\n\t\t\t\t$this->_category->setProductId($this->getId());\n\t\t\t\t$this->_category->setCategoryId(0);\n\t\t\t\t$this->_category->setIsDefault(1);\n\t\t\t} else {\n\t\t\t\t$this->_category->setOptions(\n\t\t\t\t\tKIT_Db_Table_Abstract::dbFieldsToAlias($defaultCategory->toArray())\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t\treturn $this->_category;\n\t}",
"public function getCategory()\n {\n return Category::select($this->category_id);\n }",
"public static function getRandCategoryId()\n {\n $product = Product::select(['category_id'])\n ->free()\n ->orderByRaw('RAND()')\n ->take(1)\n ->first();\n\n return ($product) ? $product->id : 1;\n }",
"public function getproductcategory($shop_id_pri = null) {\n $this->db->select('product_category.product_category_id AS category_id');\n $this->db->select('product_category.product_category_name AS category_name');\n $this->db->where('product_category.shop_id_pri', $shop_id_pri);\n $this->db->order_by('product_category.product_category_name');\n return $this->db->get('product_category');\n }",
"public function getCategory()\n {\n return $this->hasOne(CatalogCategories::className(), ['id' => 'category_id']);\n }",
"public function getFirstCategory()\n {\n if (($collection = $this->getParentCategories())) {\n if (($collection = $collection->toArray())) {\n if (($category = array_shift($collection))) {\n return $category;\n }\n }\n }\n return null;\n }",
"public function get_product_category(){\n\t\t $this->db->select('*');\n\t\t\t$this->db->from('tbl_category');\n\t\t\t$this->db->where('status','1');\n\t\t\t$query = $this->db->get();\n\t\t\treturn $query->result();\n\t }",
"function google_base_get_category($products_id) {\n global $categories_array, $db;\n static $p2c;\n if(!$p2c) {\n $q = $db->Execute(\"SELECT *\n FROM \" . TABLE_PRODUCTS_TO_CATEGORIES);\n while (!$q->EOF) {\n if(!isset($p2c[$q->fields['products_id']]))\n $p2c[$q->fields['products_id']] = $q->fields['categories_id'];\n $q->MoveNext();\n }\n }\n if(isset($p2c[$products_id])) {\n $retval = $categories_array[$p2c[$products_id]]['name'];\n $cPath = $categories_array[$p2c[$products_id]]['cPath'];\n } else {\n $cPath = $retval = \"\";\n }\n return array($retval, $cPath);\n }",
"public function getIdCategory()\n {\n return $this->idCategory;\n }",
"public function getCategory()\n {\n return rex_category::get($this->getCategoryId(), $this->getClang());\n }",
"public function getCurrentCategory()\n {\n $categoryId =(int)$this->getRequest()->getQuery('cat');\n if(!$categoryId)\n {\n return parent::getCurrentCategory();\n }\n else\n {\n return Mage::getModel('catalog/category')\n ->setStoreId(Mage::app()->getStore()->getId())\n ->load($categoryId);\n }\n }",
"public function getIdCategory(){\n\t\treturn $this->idCategory;\t\n\t}",
"function get_category()\r\n {\r\n return $this->get_default_property(self :: PROPERTY_CATEGORY);\r\n }",
"public function getCategory()\n {\n return $this->_data[self::CATEGORY];\n }",
"public function getCategory()\n {\n return Mage::registry('current_category');\n }",
"public function getCategoryId()\n {\n return $this->category_id;\n }",
"public function getCategoryId()\n {\n return $this->category_id;\n }",
"public function getCategoryId()\n {\n return (new CategoriesModel)->find($this->category_id, Categories::class);\n }",
"public function getProductCategory()\n {\n $category = ProductsCategory::all();\n\n $data_category = $category->map(function($category){\n return [\n 'value' => $category->id,\n 'label' => $category->category,\n ];\n });\n\n return response()->json(['cat' => ['data' => $data_category]]);\n }",
"public function getCategoryId()\n {\n return $this->category_id;\n }",
"public function getCategory_id()\n {\n return $this->category_id;\n }"
] | [
"0.80106115",
"0.75858504",
"0.7454034",
"0.7098324",
"0.70497",
"0.7019208",
"0.6990123",
"0.6815009",
"0.66888905",
"0.66852826",
"0.65652245",
"0.6562841",
"0.6557472",
"0.652112",
"0.64988786",
"0.6480266",
"0.6469581",
"0.6461247",
"0.6433679",
"0.6428413",
"0.6424551",
"0.6420779",
"0.64130545",
"0.63826793",
"0.6376011",
"0.6376011",
"0.6360977",
"0.63498175",
"0.6339781",
"0.63274246"
] | 0.77723014 | 1 |
Constructs the IBM PDO DSN. | private function _constructPdoDsn(array $params)
{
$dsn = 'ibm:';
if (isset($params['host'])) {
$dsn .= 'HOSTNAME=' . $params['host'] . ';';
}
if (isset($params['port'])) {
$dsn .= 'PORT=' . $params['port'] . ';';
}
$dsn .= 'PROTOCOL=TCPIP;';
if (isset($params['dbname'])) {
$dsn .= 'DATABASE=' . $params['dbname'] . ';';
}
return $dsn;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected function _dsn()\n {\n // baseline of DSN parts\n $dsn = $this->_config;\n\n // don't pass the username, password, charset, persistent and driver_options in the DSN\n unset($dsn['username']);\n unset($dsn['password']);\n unset($dsn['options']);\n unset($dsn['charset']);\n unset($dsn['persistent']);\n unset($dsn['driver_options']);\n\n // use all remaining parts in the DSN\n foreach ($dsn as $key => $val) {\n $dsn[$key] = \"$key=$val\";\n }\n\n $dsn = implode(';', $dsn);\n\n if (isset($this->_config['charset'])) {\n $dsn .= ';charset=' . (string)$this->_config['charset'];\n }\n\n return $this->_pdoType . ':' . $dsn;\n }",
"protected function createDSN()\n {\n $dsn = 'mysql:';\n\n if (empty($this->options['unix_socket'])) {\n $dsn .= 'host=' . $this->options['host'] . ';port=' . $this->options['port'];\n } else {\n $dsn .= 'unix_socket=' . $this->options['unix_socket'];\n }\n\n $dsn .= ';dbname=' . $this->options['database'];\n\n return $dsn;\n }",
"protected function _dsn()\n {\n // baseline of DSN parts\n $dsn = $this->_config;\n\n if (isset($dsn['host'])) {\n $tns = 'dbname=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)' .\n '(HOST=' . $dsn['host'] . ')';\n\n if (isset($dsn['port'])) {\n $tns .= '(PORT=' . $dsn['port'] . ')';\n } else {\n $tns .= '(PORT=1521)';\n }\n\n $tns .= '))(CONNECT_DATA=(SID=' . $dsn['dbname'] . ')))';\n } else {\n $tns = 'dbname=' . $dsn['dbname'];\n }\n\n if (isset($dsn['charset'])) {\n $tns .= ';charset=' . $dsn['charset'];\n }\n\n return $this->_pdoType . ':' . $tns;\n }",
"private function _constructPdoDsn(array $params)\n {\n if (stristr(PHP_OS, 'WIN') && PHP_OS != 'Darwin')\n {\n // use for testing on Win\n $dsn = 'sqlsrv:server=';\n\n if (isset($params['host'])) {\n $dsn .= $params['host'];\n }\n\n if (isset($params['port']) && !empty($params['port'])) {\n // $dsn .= ',' . $params['port'];\n }\n\n if (isset($params['dbname'])) {\n $dsn .= ';Database=' . $params['dbname'];\n }\n return $dsn;\n\n } else {\n\n $dsn = 'dblib:';\n if (isset($params['host'])) {\n $dsn .= 'host=' . $params['host'] . ';';\n }\n if (isset($params['port'])) {\n //$dsn .= 'port=' . $params['port'] . ';';\n }\n if (isset($params['dbname'])) {\n $dsn .= 'dbname=' . $params['dbname'] . ';';\n }\n // Support charset config\n if(isset($params['charset'])) {\n $dsn .= 'charset=' . $params['charset'] .';';\n }\n\n return $dsn;\n }\n }",
"private function constructPdoDsn(array $params)\n {\n if ( empty($params['host']) ) {\n throw new Exception(\"Missing 'host' in configuration for informix driver\");\n }\n\n if ( empty($params['protocol']) ) {\n throw new Exception(\"Missing 'protocol' in configuration for informix driver\");\n }\n\n if ( empty($params['server']) ) {\n throw new Exception(\"Missing 'server' in configuration for informix driver\");\n }\n\n $dsn = 'informix:'\n . 'host=' . $params['host'] . ';'\n . 'server=' . $params['server'] . ';';\n\n if ( ! empty($params['dbname']) ) {\n $dsn .= 'database=' . $params['dbname'] . ';';\n } else {\n $dsn .= 'CONNECTDATABASE=NO;';\n }\n\n $dsn .= 'protocol=' . $params['protocol'] . ';';\n\n if ( ! empty($params['port']) ) {\n $dsn .= 'service=' . $params['port'] . ';';\n }\n\n return $dsn;\n }",
"private function _prepareDsnString() : string\n {\n return sprintf(\n \"%s:host=%s;dbname=%s;charset=%s\",\n $this->_config['driver'],\n $this->_config['host'],\n $this->_config['database'],\n $this->_config['charset']\n );\n }",
"protected function _getDsn() : string {\n $dsn = parent::_getDsn();\n $Database = $this->_database ?: static::$_DefaultDatabase;\n if ($Database === NULL) {\n throw new \\Exception('No Database provided!');\n }\n $dsn .= 'dbname=' . $Database;\n\n if ($this->_charSet !== NULL) {\n $dsn .= ';charset=' . $this->_charSet;\n }\n\n return $dsn;\n }",
"public function buildDsn(): void\n {\n if ($this->dsn == 'mysql') {\n $this->dsn = 'mysql:dbname=' . $this->dbname . ';host=' . $this->host;\n } elseif ($this->dsn == 'sqlite' && $this->host == 'memory') {\n $this->dsn = 'sqlite::memory:';\n }\n }",
"public function dsn()\n {\n $dsn = \"$this->sTipo_Bd:dbname=$this->sDb;user=$this->sUser;password=$this->sPasswd;host=$this->sHost\";\n return $dsn;\n }",
"private function _constructPdoDsn(array $params) {\n\t\t$dsn = 'mysql:';\n\t\tif (isset ( $params ['host'] ) && $params ['host'] != '') {\n\t\t\t$dsn .= 'host=' . $params ['host'] . ';';\n\t\t}\n\t\tif (isset ( $params ['port'] )) {\n\t\t\t$dsn .= 'port=' . $params ['port'] . ';';\n\t\t}\n\t\tif (isset ( $params ['dbname'] )) {\n\t\t\t$dsn .= 'dbname=' . $params ['dbname'] . ';';\n\t\t}\n\t\tif (isset ( $params ['unix_socket'] )) {\n\t\t\t$dsn .= 'unix_socket=' . $params ['unix_socket'] . ';';\n\t\t}\n\t\t\n\t\treturn $dsn;\n\t}",
"protected function dsn() {\n\t\t// Builds DSN :\n\t\t$dsn = 'pgsql:host=' . $this->host . ';port=' . $this->port . ';dbname=' . $this->dbname;\n\n\t\t// Unset connection parameters to make sure no forgotten debug message\n\t\t// displays them unintentionaly to a user :\n\t\t$this->host = null;\n\t\t$this->port = null;\n\t\t$this->dbname = null;\n\n\t\treturn $dsn;\n\t}",
"function dsn_connect($dsn)\n {\n // Use persistent connections if available\n $db_options = array(\n 'persistent' => $this->db_pconn,\n 'emulate_prepared' => $this->debug_mode,\n 'debug' => $this->debug_mode,\n 'debug_handler' => 'mdb2_debug_handler',\n 'portability' => MDB2_PORTABILITY_ALL ^ MDB2_PORTABILITY_EMPTY_TO_NULL);\n\n if ($this->db_provider == 'pgsql') {\n $db_options['disable_smart_seqname'] = true;\n $db_options['seqname_format'] = '%s';\n }\n\n $dbh = MDB2::connect($dsn, $db_options);\n\n if (MDB2::isError($dbh))\n {\n $this->db_error = TRUE;\n $this->db_error_msg = $dbh->getMessage();\n \n raise_error(array('code' => 500, 'type' => 'db', 'line' => __LINE__,\n 'file' => __FILE__, 'message' => $dbh->getUserInfo()), TRUE, FALSE);\n }\n else if ($this->db_provider=='sqlite')\n {\n $dsn_array = MDB2::parseDSN($dsn);\n if (!filesize($dsn_array['database']) && !empty($this->sqlite_initials))\n $this->_sqlite_create_database($dbh, $this->sqlite_initials);\n }\n else if ($this->db_provider!='mssql' && $this->db_provider!='sqlsrv')\n $dbh->setCharset('utf8');\n\n return $dbh;\n }",
"private function dsn() {\n return 'mysql:dbname=' . self::$config['db_name'] .\n ';host=' . self::$config['db_host'];\n }",
"abstract protected function dsn();",
"public static function create(array $config)\n {\n // Build DSN connection string for PDO\n $dsn = new self($config['driver']);\n\n if (isset($config['unix_socket'])) {\n $dsn['unix_socket'] = $config['unix_socket'];\n } else {\n if (isset($config['host'])) {\n $dsn['host'] = $config['host'];\n }\n if (isset($config['port'])) {\n $dsn['port'] = $config['port'];\n }\n }\n\n foreach (array('database', 'dbname') as $key) {\n if (isset($config[$key])) {\n $dsn['dbname'] = $config[$key];\n break;\n }\n }\n\n if (isset($config['charset'])) {\n $dsn['charset'] = $config['charset'];\n }\n\n\n return $dsn;\n }",
"private function createPdo()\n {\n if ($this->username && $this->password && $this->options) {\n $this->db = new PDO($this->dsn, $this->username, $this->password, $this->options);\n } elseif ($this->username && $this->password) {\n $this->db = new PDO($this->dsn, $this->username, $this->password);\n } else {\n $this->db = new PDO($this->dsn);\n }\n }",
"public function getDsn(): string\n {\n/*\n # File connection\n $connection = new PDO('sqlite:<filename>', null, null\n array(PDO::ATTR_PERSISTENT => true)\n );\n\n # Memory connection\n $connection = new PDO('sqlite::memory:', null, null\n array(PDO::ATTR_PERSISTENT => true)\n );\n*/\n # Build the DSN\n $_dsn = $this->getDriver().':'.$this->getFilename();\n\n # Set it\n $this->setDsn($_dsn);\n\n return $_dsn;\n }",
"abstract public function dsn();",
"protected function createPdoInstance () {\r\n $pdoClass = 'PDO';\r\n if (($pos = strpos( \r\n $this->connectionString , \r\n ':' )) !== false) {\r\n $driver = strtolower( \r\n substr( \r\n $this->connectionString , \r\n 0 , \r\n $pos ) );\r\n if ($driver === 'mssql' || $driver === 'dblib') $pdoClass = 'CMssqlPdoAdapter';\r\n }\r\n return new $pdoClass( \r\n $this->connectionString , \r\n $this->username , \r\n $this->password , \r\n $this->_attributes );\r\n }",
"protected function getDSN():string{\n\n\t\tif(empty($this->options->database)){\n\t\t\tthrow new DriverException('no database given');\n\t\t}\n\n\t\t$dsn = 'pgsql';\n\n\t\tif($this->options->socket){\n\t\t\t$dsn .= ':unix_socket='.$this->options->socket;\n\t\t}\n\t\telse{\n\n\t\t\tif(empty($this->options->host)){\n\t\t\t\tthrow new DriverException('no host given');\n\t\t\t}\n\n\t\t\t$dsn .= ':host='.$this->options->host;\n\n\t\t\tif(is_numeric($this->options->port)){\n\t\t\t\t$dsn .= ';port='.$this->options->port;\n\t\t\t}\n\n\t\t}\n\n\t\t$dsn .= ';dbname='.$this->options->database;\n\n\t\treturn $dsn;\n\t}",
"protected function constructPdoDsn(array $params, $username = null, $password = null)\n {\n $dsn = '';\n\n if (isset($params['host']) && $params['host'] != '') {\n $dsn .= 'host=' . $params['host'] . ';';\n }\n if (isset($params['port'])) {\n $dsn .= 'port=' . $params['port'] . ';';\n }\n if (isset($params['dbname'])) {\n $dsn .= 'dbname=' . $params['dbname'] . ';';\n }\n if (isset($params['unix_socket'])) {\n $dsn .= 'unix_socket=' . $params['unix_socket'] . ';';\n }\n if (isset($params['charset'])) {\n $dsn .= 'charset=' . $params['charset'] . ';';\n }\n\n if ($username) {\n $dsn .= 'user=' . $username . ';';\n }\n\n if ($password) {\n $dsn .= 'password=' . $password . ';';\n }\n\n return trim($dsn, ';');\n }",
"protected function constructPdoDsn(array $params)\n {\n $dsn = 'mysql:';\n if (isset($params['host']) && $params['host'] !== '') {\n $dsn .= 'host=' . $params['host'] . ';';\n }\n\n if (isset($params['port'])) {\n $dsn .= 'port=' . $params['port'] . ';';\n }\n\n if (isset($params['dbname'])) {\n $dsn .= 'dbname=' . $params['dbname'] . ';';\n }\n\n if (isset($params['unix_socket'])) {\n $dsn .= 'unix_socket=' . $params['unix_socket'] . ';';\n }\n\n if (isset($params['charset'])) {\n $dsn .= 'charset=' . $params['charset'] . ';';\n }\n\n return $dsn;\n }",
"public function dsn() {\n if ($this->_config['dsn']) {\n return $this->_config['dsn'];\n }\n if (!$this->_config['database']) {\n throw new DatabaseException('Error, no database name has been configured.');\n }\n if ($this->_config['socket']) {\n return sprintf($this->_protocol . \":unix_socket=%s;dbname=%s\", $this->_config['socket'], $this->_config['database']);\n }\n\n $host = $this->_config['host'];\n list($host, $port) = explode(':', $host) + [1 => $this->_config['port']];\n return sprintf($this->_protocol . \":host=%s;port=%s;dbname=%s\", $host, $port, $this->_config['database']);\n }",
"abstract protected function getDsn(): string;",
"protected function initializePDO($dsn) {\n $credentials = array(null,null);\n if(@file_exists(STRATA_CREDENTIALS)) {\n $credentials = include(STRATA_CREDENTIALS);\n }\n return new PDO($dsn, $credentials[0], $credentials[1]);\n }",
"protected function connect(): PDO\n {\n if (is_null($this->conn)) {\n if (!is_array($this->dsn)) {\n throw new \\RuntimeException(\"database not configured\");\n }\n\n $this->conn = new PDO($this->dsn[\"dsn\"], $this->dsn[\"user\"] ?? null, $this->dsn[\"password\"] ?? null);\n $this->conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);\n $this->conn->setAttribute(PDO::ATTR_EMULATE_PREPARES, true);\n $this->conn->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_ASSOC);\n\n if (0 === strpos($this->dsn['dsn'], 'mysql:')) {\n $this->conn->query('SET NAMES utf8');\n }\n\n // Perform initialization stuff, like SET NAMES utf8.\n if (!empty($this->dsn[\"bootstrap\"])) {\n foreach ($this->dsn[\"bootstrap\"] as $query) {\n $this->conn->query($query);\n }\n }\n }\n\n return $this->conn;\n }",
"private function buildDsn($host, $port, $server, $dsn, $dbname, $username = null, $password = null, array $driverOptions = [])\n {\n /* If DSN is set, disregard host/port and set \"host\" to DSN */\n if(! empty($dsn) ){\n $host = 'DSN=' . $dsn;\n }else{\n /* No need to use this driver if not using DSN to connect, but just in case - no BC break */\n $host = $host ?: 'localhost';\n $port = $port ?: 2638;\n $host = 'HOST=' . $host . ':' . $port;\n }\n if (! empty($server)) {\n $server = ';ServerName=' . $server;\n }\n return\n $host .\n $server .\n ';DBN=' . $dbname .\n ';UID=' . $username .\n ';PWD=' . $password .\n ';' . \\implode(\n ';',\n \\array_map(static function ($key, $value) {\n return $key . '=' . $value;\n }, \\array_keys($driverOptions), $driverOptions)\n );\n }",
"abstract protected function makePDO(array $config, array $options);",
"private function constructPdoDsn(array $params): string\n {\n $dsn = 'sqlite:';\n if (isset($params['path'])) {\n $dsn .= $params['path'];\n } elseif (isset($params['memory'])) {\n $dsn .= ':memory:';\n }\n\n return $dsn;\n }",
"protected function _dsn()\n {\n return $this->getDatabaseHelper()->dsn();\n }"
] | [
"0.68463045",
"0.68175733",
"0.6804297",
"0.6797826",
"0.6745591",
"0.6701066",
"0.66618323",
"0.6648033",
"0.66117924",
"0.6611309",
"0.65893227",
"0.65332335",
"0.63781303",
"0.62954307",
"0.6265204",
"0.62215245",
"0.61844724",
"0.61790425",
"0.61304224",
"0.6122609",
"0.60853386",
"0.6064271",
"0.6051314",
"0.5988435",
"0.5981346",
"0.59445256",
"0.59301174",
"0.59265107",
"0.5914576",
"0.58627117"
] | 0.77170396 | 0 |
Get the available types for a job. These are defined by schema.org. | public function getJobTypes(): array
{
return $this->buildSelectionList(Job::TYPES, 'job.type.');
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static function GetJobTypes() {\n\t\t\t\n\t\t\t$jobTypes = Array();\n\t\t\t\n\t\t\t$sql = \"select * from job_type order by JobTypeName;\";\n\t\t\t\t\n\t\t\t$conn = mysqli_connect(DB_HOST, DB_USERNAME, DB_PASSWORD, DB_NAME) or die(\"Connection failed: \" . $conn->connect_error);\n\t\t\t\n\t\t\t$stmt = $conn->prepare($sql);\n\t\t\t$stmt->execute();\n\t\t\t$result = mysqli_stmt_get_result($stmt);\n\t\t\t$stmt->close();\n\t\t\t$conn->close();\n\t\t\t\n\t\t\twhile($row = mysqli_fetch_array($result))\n\t\t\t{\n\t\t\t\t$jobType = new JobType();\n\t\t\t\tJobType::LoadObject($jobType, $row);\n\t\t\t\t$jobTypes[] = $jobType;\n\t\t\t}\n\t\t\t\n\t\t\treturn $jobTypes;\n\t\t\t\n\t\t}",
"public function getTypes($only_queued = false) {\n\t\t$query = $only_queued ? ['completed' => null] : [];\n\n\t\treturn $this->distinct('job_type', $query);\n\t}",
"function get_job_listing_types() {\n\treturn get_terms( \"job_listing_type\", array(\n\t\t'orderby' => 'name',\n\t 'order' => 'ASC',\n\t 'hide_empty' => false,\n\t) );\n}",
"public function CheckType(){\n\t\t$jobWithTypeChecked = array();\n\t\t//print_r($this->Type);\n\t\t//echo \"<br />\";\n\t\tforeach ($this->JobsWillSuggest as $job){\n\t\t\t//echo $job->getID(). \": \". $job->getType();\n\t\t\tif(in_array($job->getType(), $this->Type)){\n\t\t\t\t//echo \" pushed\";\n\t\t\t\tarray_push($jobWithTypeChecked, $job);\n\t\t\t}\n\t\t\t//echo \"<br />\";\n\t\t}\n\t\t\n\t\t$this->JobsWillSuggest = $jobWithTypeChecked;\n\t}",
"public function getTypes();",
"public static function getTypes();",
"function getTypes(){\n $result = $this->dma->managementApiCall('GET', \"{$this->hashid}/types\");\n return $result['response'];\n }",
"abstract public function getTypes();",
"public function types() {\n\t\treturn $this->getEntity($this->invokeGet(\"_types\"));\n\t}",
"public function getTypes()\n {\n return [\n 'normal' => 'Normal',\n 'batch' => 'Batch',\n ];\n }",
"protected function get_types() {\r\n\t\treturn $this->types;\r\n\t}",
"public function getTypes()\n {\n // Perform re-login if required.\n $this->checkLogin();\n\n $getdata = [\n 'operation' => 'listtypes',\n 'sessionName' => $this->sessionName\n ];\n\n $result = $this->sendHttpRequest($getdata, 'GET');\n $modules = $result['types'];\n\n $result = array();\n foreach ($modules as $moduleName) {\n $result[$moduleName] = ['name' => $moduleName];\n }\n return $result;\n }",
"public static function get_types() {\n\t return self::$types;\n\t}",
"public function getTypes() {\n\t\t$types = array(\n\t\t\t'' => 'None/Unknown',\n\t\t\t'Feedb' => 'Feedback',\n\t\t\t'Help' => 'Help',\n\t\t\t'Cont' => 'Contact',\n\t\t);\n\t\treturn $types;\n\t}",
"public function getTypes()\n {\n $response = $this->request(\n 'GET',\n '/webservice.php?operation=listtypes&sessionName=' . $this->getSession()\n );\n\n return $response;\n }",
"public static function getTypes()\n {\n return [\n static::ENQUIRY,\n static::COMPLAINT,\n ];\n }",
"public static function register_post_types() {\n\t\tif ( post_type_exists('job') ) {\n\t\t\treturn;\n\t\t}\n\n\t\t/*\n\t\tRegister post_type order\n\t\t */\n\t\t$labels = array(\n\t\t\t'name' => __( 'Job', 'boxtheme' ),\n\t\t\t'singular_name' => __( 'Job', 'boxtheme' ),\n\t\t\t'menu_name' => _x( 'Jobs', 'Admin menu name', 'boxtheme' ),\n\t\t\t'add_new' => __( 'Add Job', 'boxtheme' ),\n\t\t\t'add_new_item' => __( 'Add New Job', 'boxtheme' ),\n\t\t\t'edit' => __( 'Edit', 'boxtheme' ),\n\t\t\t'edit_item' => __( 'Edit Job', 'boxtheme' ),\n\t\t\t'new_item' => __( 'New Job', 'boxtheme' ),\n\t\t\t'view' => __( 'View Job', 'boxtheme' ),\n\t\t\t'view_item' => __( 'View Job', 'boxtheme' ),\n\t\t\t'search_items' => __( 'Search Jobs', 'boxtheme' ),\n\t\t\t'not_found' => __( 'No Jobs found', 'boxtheme' ),\n\t\t\t'not_found_in_trash' => __( 'No Jobs found in trash', 'boxtheme' ),\n\t\t\t'parent' => __( 'Parent Job', 'boxtheme' ),\n\t\t\t'featured_image' => __( 'Featured Image', 'boxtheme' ),\n\t\t\t'set_featured_image' => __( 'Set Job image', 'boxtheme' ),\n\t\t\t'remove_featured_image' => __( 'Remove Job image', 'boxtheme' ),\n\t\t\t'use_featured_image' => __( 'Use as Job image', 'boxtheme' ),\n\t\t\t'insert_into_item' => __( 'Insert into Job', 'boxtheme' ),\n\t\t\t'uploaded_to_this_item' => __( 'Uploaded to this Job', 'boxtheme' ),\n\t\t\t'filter_items_list' => __( 'Filter Jobs', 'boxtheme' ),\n\t\t\t'items_list_navigation' => __( 'Job navigation', 'boxtheme' ),\n\t\t\t'items_list' => __( 'Job list', 'boxtheme', 'boxtheme' ),\n\t\t);\n\t \t$args = apply_filters( 'bx_job_post_type', array(\n\t \t\t'labels' => $labels,\n\t \t\t'description' => __( 'This is where you can add new Jobs.', 'boxtheme' ),\n\t \t'public' => true,\n\t \t'label' => 'Jobs',\n\t \t'capability_type' => 'post',\n\t\t\t'show_ui' => true,\n\t\t\t'publicly_queryable' => true,\n\t\t\t'exclude_from_search' => false,\n\t\t\t'hierarchical' => false, // Hierarchical causes memory issues - WP loads all records!\n\t\t\t'rewrite' => array( 'slug' => 'job' ),\n\t\t\t'query_var' => true,\n\t\t\t'supports' => array( 'title', 'editor', 'author', 'excerpt', 'thumbnail', 'comments', 'custom-fields'),\n\t\t\t'has_archive' => 'jobs',\n\t\t\t'show_in_nav_menus' => true,\n\t ));\n\t \tregister_post_type( 'job', $args );\n\n\t\tif ( post_type_exists('order') ) {\n\t\t\treturn;\n\t\t}\n\t\t/*\n\t\tRegister post_type order\n\t\t */\n\t \t$args = array(\n\t \t'public' => true,\n\t \t'label' => 'Orders',\n\t \t'capability_type' => 'post',\n\t \t'description' => __( 'This is where you can add new order.', 'boxtheme' ),\n\t \t'public' => true,\n\t \t'capability_type' => 'post',\n\n\t\t\t'show_ui' => true,\n\t\t\t'capability_type' => 'post',\n\t\t\t'publicly_queryable' => false,\n\t\t\t'exclude_from_search' => true,\n\t\t\t'hierarchical' => false, // Hierarchical causes memory issues - WP loads all records!\n\t\t\t'query_var' => false,\n\t\t\t'supports' => array( 'title', 'editor', 'author', 'excerpt', 'custom-fields'),\n\t\t\t'show_in_nav_menus' => true\n\t );\n\t \tregister_post_type( 'order', $args );\n\n\t\t/*\n\t\tEnd post_type order\n\t\t*/\n\t\t/*\n\t\tRegister profile order\n\t\t */\n\t\t$labels = array(\n\t\t\t'name' => __( 'Profile', 'boxtheme' ),\n\t\t\t'singular_name' => __( 'Profile', 'boxtheme' ),\n\t\t\t'menu_name' => _x( 'Profiles', 'Admin menu name', 'boxtheme' ),\n\t\t\t'add_new' => __( 'Add Profile', 'boxtheme' ),\n\t\t\t'add_new_item' => __( 'Add New Profile', 'boxtheme' ),\n\t\t\t'edit' => __( 'Edit', 'boxtheme' ),\n\t\t\t'edit_item' => __( 'Edit Profile', 'boxtheme' ),\n\t\t\t'new_item' => __( 'New Profile', 'boxtheme' ),\n\t\t\t'view' => __( 'View Profile', 'boxtheme' ),\n\t\t\t'view_item' => __( 'View Profile', 'boxtheme' ),\n\t\t\t'search_items' => __( 'Search Profiles', 'boxtheme' ),\n\t\t\t'not_found' => __( 'No Profiles found', 'boxtheme' ),\n\t\t\t'not_found_in_trash' => __( 'No Profiles found in trash', 'boxtheme' ),\n\t\t\t'parent' => __( 'Parent Profile', 'boxtheme' ),\n\t\t\t'featured_image' => __( 'Featured Image', 'boxtheme' ),\n\t\t\t'set_featured_image' => __( 'Set Profile image', 'boxtheme' ),\n\t\t\t'remove_featured_image' => __( 'Remove Profile image', 'boxtheme' ),\n\t\t\t'use_featured_image' => __( 'Use as Profile image', 'boxtheme' ),\n\t\t\t'insert_into_item' => __( 'Insert into Profile', 'boxtheme' ),\n\t\t\t'uploaded_to_this_item' => __( 'Uploaded to this Job', 'boxtheme' ),\n\t\t\t'filter_items_list' => __( 'Filter Jobs', 'boxtheme' ),\n\t\t\t'items_list_navigation' => __( 'Profile navigation', 'boxtheme' ),\n\t\t\t'items_list' => __( 'Profile list', 'boxtheme', 'boxtheme' ),\n\t\t);\n\t \t$args = apply_filters( 'bx_profile_post_type',array(\n\t \t\t'labels' => $labels,\n\t \t\t'description' => __( 'This is where you can add new profiles.', 'boxtheme' ),\n\t \t'public' => true,\n\t \t'label' => 'Profiles',\n\t \t'capability_type' => 'post',\n\t\t\t'show_ui' => true,\n\t\t\t'publicly_queryable' => true,\n\t\t\t'exclude_from_search' => false,\n\t\t\t'hierarchical' => false, // Hierarchical causes memory issues - WP loads all records!\n\t\t\t'rewrite' => array( 'slug' => 'profile' ),\n\t\t\t'query_var' => true,\n\t\t\t'supports' => array( 'title', 'editor', 'author', 'excerpt', 'custom-fields'),\n\t\t\t'has_archive' => 'profiles',\n\t\t\t'show_in_nav_menus' => true\n\t ));\n\t \tregister_post_type( 'profile', $args );\n\n \t\t$args = array(\n \t'public' => true,\n \t'label' => 'Testimonial',\n \t'capability_type' => 'post',\n \t'description' => __( 'This is where you can add new testimonial.', 'boxtheme' ),\n \t'public' => true,\n \t'capability_type' => 'post',\n\n\t\t\t'show_ui' => true,\n\t\t\t'capability_type' => 'post',\n\t\t\t'publicly_queryable' => false,\n\t\t\t'exclude_from_search' => true,\n\t\t\t'hierarchical' => false, // Hierarchical causes memory issues - WP loads all records!\n\t\t\t'query_var' => false,\n\t\t\t'supports' => array( 'title', 'editor', 'author', 'excerpt', 'custom-fields','thumbnail'),\n\t\t\t'show_in_nav_menus' => true\n\t );\n\t \tregister_post_type( 'testimonial', $args );\n\n\t}",
"public function getTypes()\n {\n return $this->types;\n }",
"public function getTypes()\n {\n return $this->types;\n }",
"public function getTypes()\n {\n return array_values($this->resourceTypes);\n }",
"public function getTypes() {\n\t\treturn array_keys($this->tca['types']);\n\t}",
"public function fetch_post_types() {\n $args = array( \n 'public' => true,\n '_builtin' => true\n );\n \n $post_types = get_post_types( $args, 'objects', 'and' );\n return $post_types;\n }",
"public static function getAvailableTypes()\n {\n return array(\n \"string\",\n \"number\",\n \"integer\", \n \"file\",\n \"boolean\",\n \"date\",\n );\n }",
"function getTypeList() {\n\t\t$query = <<<'SQL'\nSELECT\n\ttype,\n\tname\nFROM\n\tmachine_type\nSQL;\n\t\tif(($result = $GLOBALS['mysqli']->query($query)) !== false) {\n\t\t\t$list = array();\n\t\t\twhile(is_null($row = $result->fetch_assoc()) === false) {\n\t\t\t\tarray_push($list, $row);\n\t\t\t}\n\t\t\t\n\t\t\treturn $list;\n\t\t}\n\t}",
"function getDocumentTypes() {\n\t\tglobal $default;\n\t\t$aDocumentTypes = array();\n\t\t$sql = $default->db;\n\t\t$sQuery = \"SELECT document_type_id FROM \" . $default->document_type_fields_table . \" WHERE field_id = ?\";/*ok*/\n $aParams = array($this->iId);\n\t\tif ($sql->query(array($sQuery, $aParams))) {\n\t\t\twhile ($sql->next_record()) {\n \t\t\t$aDocumentTypes[] = & DocumentType::get($sql->f(\"document_type_id\"));\n \t\t}\n\t\t\treturn $aDocumentTypes;\n\t\t} else{\n\t\t\treturn false;\n\t\t}\n\t}",
"public function getTypes()\n {\n return $this->getSmartPropertyItems('Type');\n }",
"static function listAvailableTypes() {\n global $_lib;\n\n $l = array();\n\n $r = $_lib['db']->db_query(\"SELECT * FROM fakturabankscheme ORDER BY SchemeType\");\n while( ($row = $_lib['db']->db_fetch_assoc($r)) ) {\n $l[(int)$row['FakturabankSchemeID']] = $row;\n }\n\n return $l;\n }",
"public function getTypes() {\n\t\treturn $this->types;\n\t}",
"private static function getTypeList()\n {\n return Bootstrap::getInstance()->getObjectManager()->get('Magento\\Framework\\App\\Cache\\TypeListInterface');\n }",
"function cfcpt_get_types() {\n\t\tglobal $cfcpt_post_types;\n\t\treturn $cfcpt_post_types;\n\t}"
] | [
"0.7624101",
"0.70016456",
"0.6994271",
"0.64249486",
"0.6228701",
"0.6203876",
"0.6176757",
"0.6138346",
"0.6107472",
"0.60875916",
"0.60410154",
"0.6037336",
"0.60362786",
"0.6013638",
"0.59909046",
"0.59790254",
"0.59789133",
"0.5975853",
"0.5975853",
"0.5971029",
"0.59498847",
"0.59392285",
"0.5935589",
"0.5931622",
"0.5929958",
"0.5919432",
"0.591905",
"0.59026957",
"0.58836526",
"0.5878238"
] | 0.7612305 | 1 |
Get the available salary intervals for a job. These are defined by schema.org. | public function getJobSalaryInterval(): array
{
return $this->buildSelectionList(Job::SALARY_INTERVAL, 'job.salary_interval.');
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function get_intervals() {\n $intervals = get_option( self::$interval_key );\n return apply_filters( 'rota_intervals', $intervals );\n }",
"public function getIntervals();",
"public function getIntervals()\n {\n return $this->intervals;\n }",
"public function load_salary(){\t\n\t\t$sal = array('10000' => '10000', '20000' => '20000', '30000' => '30000', '40000' => '40000', '50000' => '50000', '60000' => '60000', '70000' => '70000', '80000' => '80000','90000' => '90000', '100000' => '100000');\t\t\n\t\treturn $sal;\n\t}",
"private function get_employee_availability() {\n\n $date = new \\DateTime($this->date);\n\n $periodsObjArray = EmployeeModel::with(array('periods.weekdays.breaks'))->where('id', $this->employeeId)->get();\n\n if ($periodsObjArray->isNotEmpty()) {\n\n $periods = $periodsObjArray[0]->periods;\n\n foreach ($periods as $period) {\n\n $periodStart = new \\DateTime($period['start_date']);\n $periodEnd = new \\DateTime($period['end_date']);\n\n if ($date >= $periodStart && $date <= $periodEnd) {\n\n $this->periodStart = $periodStart;\n $this->periodEnd = $periodEnd;\n $this->periodInterval = $period->interval;\n $this->intervalLines = $period->interval_lines;\n $this->periodDescription = $period->description;\n $this->daySchedule = $period['weekdays']->where('day', formatS($date))->first();\n $dayBreaks = $this->daySchedule['breaks'];\n\n //Make and assign 1 dimensional array containing all breaks\n $this->breaksArray = $this->make_break_array($dayBreaks);\n }\n }\n }\n }",
"public function getAvailabilityEnds();",
"function GetWorkExperience()\r\n {\r\n $companyid = $this->companyID;\r\n $emp_seqno = $this->empSeqNO;\r\n $sql_string = <<<eof\r\n select work_company,\r\n job_title,\r\n salary,\r\n job_type,\r\n in_date,\r\n out_date,\r\n work_years,\r\n leave_reason\r\n from ehr_emp_workexp_v\r\n where company_id = '$companyid'\r\n and emp_seq_no = '$emp_seqno'\r\n\t\t\t\t order by in_date desc\r\neof;\r\n\t\t\t//print $sql_string;\r\n return $this->DBConn->GetArray($sql_string);\r\n }",
"public function getInterval();",
"public static function getTimeIntervals()\n {\n return self::$timeIntervals;\n }",
"public function getTimeIntervals($start='', $end='') {\n\t\tif (count($this->_time_intervals)) {\n\t\t\treturn $this->_time_intervals;\n\t\t}\n\t\t$intervals = array();\n\t\tforeach ($this->_events as $event) {\n\t\t\t$t = substr($event['start'], 11, 5);\n\t\t\tif (!in_array($t, $intervals)) {\n\t\t\t\t$intervals[] = $t;\n\t\t\t}\n\t\t\t$t = substr($event['end'], 11, 5);\n\t\t\tif (!in_array($t, $intervals)) {\n\t\t\t\t$intervals[] = $t;\n\t\t\t}\n\t\t}\n\t\tsort($intervals);\n\t\t$this->_time_intervals = $intervals;\n\t\treturn $intervals;\n\t}",
"public function employee_salary() {\n $data = array();\n $query = $this->db->query(\"SELECT * FROM salary\");\n foreach ($query->result_array() as $row) {\n $data[] = $row;\n }\n return $data;\n }",
"public function getJobs()\n {\n return $this->_configData->getJobs();\n }",
"public function calculateRanges()\n {\n if (count($this->workstationIds) === 0) {\n\n $ranges = $this->calculateRangesOnWorkstation();\n\n // Map to BookableTimeRange without workstation\n $ranges = Arrays::each($ranges, function($range)\n {\n return Data\\BookableTimeRange::rangeByRange($range, null);\n });\n\n } else {\n\n // Merge workstation ranges into an unique array\n $ranges = array();\n\n foreach ($this->workstationIds as $workstationId) {\n\n // Get ranges of current workstation\n $workstationRanges = $this\n ->calculateRangesOnWorkstation($workstationId);\n\n // Merge ranges into new workstation ranges\n $ranges = $this\n ->mergeIntoBookableRanges($ranges, $workstationRanges, $workstationId);\n }\n\n // Order ranges by start time\n $ranges = Arrays::sort($ranges, function($range)\n {\n return $range->getStartTime();\n });\n }\n\n return $ranges;\n }",
"public function getJobsYearly ()\n {\n\n $date = date(Zend_Date::YEAR_8601) . \"-01-01\";\n $sql = $this->job->select();\n $sql->where(\"j_customer =?\", $this->labName);\n $sql->where(\"j_datein >= ?\", $date);\n $sql->where(\"`j_qty_ordered` != 1\");\n $sql->where(\"`j_qty_ordered` != 0\");\n $sql->order(\"j_deldate DESC\");\n $rows = $this->job->fetchAll($sql);\n return $rows;\n }",
"public static function calculateWorkTimeByInterval(Carbon $startTime, Carbon $endTime, Collection $holidays): array\n {\n $currentStartTime = clone $startTime;\n\n $firstTierAmount = 0;\n $secondTierAmount = 0;\n $thirdTierAmount = 0;\n $fourthTierAmount = 0;\n\n do {\n $currentEndTime = clone $startTime;\n /** @var Carbon $endTime */\n $currentEndTime = $currentEndTime->endOfDay()->min($endTime);\n if ($holidays->first(function ($item) use ($currentStartTime) {\n return $item->date->format('Y-m-d') == $currentStartTime->format('Y-m-d');\n })) {\n $fourthTierAmount += $endTime->diffInMinutes($startTime);\n //Add payment for work with fourth tier rate\n } elseif ($currentStartTime->isWeekend()) {\n $thirdTierAmount += $endTime->diffInMinutes($startTime);\n //Add payment for work with third tier rate\n } else {\n $workingInterval = self::getIntersectionInMinutes(\n $startTime,\n $endTime,\n Carbon::create(\n $currentStartTime->year,\n $currentStartTime->month,\n $currentStartTime->day,\n self::START_DAY_HOUR\n ),\n Carbon::create(\n $currentStartTime->year,\n $currentStartTime->month,\n $currentStartTime->day,\n self::END_DAY_HOUR\n )\n );\n\n //Add payment for work with second tier rate\n $secondTierAmount += ($endTime->diffInMinutes($startTime) - $workingInterval);\n //Add payment for work with first tier rate\n $firstTierAmount += $workingInterval;\n }\n\n $currentStartTime->addDay()->startOfDay();\n } while ($currentEndTime > $endTime);\n\n return [\n 'firstTierAmount' => $firstTierAmount,\n 'secondTierAmount' => $secondTierAmount,\n 'thirdTierAmount' => $thirdTierAmount,\n 'fourthTierAmount' => $fourthTierAmount,\n ];\n }",
"function getWorkhours($period = null) {\n \treturn BendService::getInstance($this->w)->getWorkhoursForUser($this->user_id,$period);\n }",
"public function getInterval()\n {\n return $this->interval;\n }",
"public function getInterval()\n {\n return $this->interval;\n }",
"public function getInterval()\n {\n return $this->interval;\n }",
"function getWorkhoursLevyForWorkperiod(BendWorkPeriod $workperiod) {\n \t$user_months = BendService::diffInMonths(\n \t\t!empty($this->d_end) && $this->d_end < $workperiod->d_end ?\n \t\t\tnew DateTime(formatDate($this->d_end,\"Y-m-d\")) :\n \t\t\tnew DateTime(formatDate($workperiod->d_end,\"Y-m-d\")),\n \t\t$this->d_start > $workperiod->d_start ?\n \t\t\tnew DateTime(formatDate($this->d_start,\"Y-m-d\")) :\n \t\t\tnew DateTime(formatDate($workperiod->d_start,\"Y-m-d\"))\n \t\t);\n \treturn $user_months * $workperiod->monthly_person_hours;\n }",
"public function getAvailabilityStarts();",
"public function getRunningJobs() {\n $jobs = array();\n // TODO: impelement this function.\n return $jobs;\n }",
"public function expenditureRange(string $interval, int $offset, int $length): array {\n self::$db->prepared_query(\"\n SELECT bi.ID AS id,\n bi.Title AS title,\n count(bh.ItemID) AS total\n FROM bonus_item bi\n LEFT JOIN bonus_history bh ON (bh.ItemID = bi.ID)\n WHERE (\n bh.ItemID IS NULL\n OR\n bh.PurchaseDate BETWEEN (now() - INTERVAL ? {$interval}) AND (now() - INTERVAL ? {$interval})\n )\n GROUP BY bi.ID\n ORDER BY bi.sequence\n \", ($offset + $length), $offset\n );\n return self::$db->to_array('id', MYSQLI_ASSOC, false);\n }",
"public function intervalHS($start,$finish)\n {\n\t\t$start = date(\"Y-m-d H:i:s\",$start);\n\t\t$finish = date(\"Y-m-d H:i:s\",$finish);\n\n\t\t$where= new Where();\n\t\t$where->between('start_date_time',$start,$finish);\n\t\t$resultSet = $this->binTable->select($where);\n\t\t$rows = array();\n\t\t\n\t\tforeach ($resultSet as $binTableModel){\n\t\t\t\t$rows[0][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch01,\n\t\t\t\t);\n\t\t\t\t$rows[1][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch02,\n\t\t\t\t);\n\t\t\t\t$rows[2][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch03,\n\t\t\t\t);\n\t\t\t\t$rows[3][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch04,\n\t\t\t\t);\n\t\t\t\t$rows[4][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch05,\n\t\t\t\t);\n\t\t\t\t$rows[5][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch06,\n\t\t\t\t);\n\t\t\t\t$rows[6][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch07,\n\t\t\t\t);\n\t\t\t\t$rows[7][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch08,\n\t\t\t\t);\n\t\t\t\t$rows[8][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch09,\n\t\t\t\t);\n\t\t\t\t$rows[9][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch10,\n\t\t\t\t);\n\t\t\t\t$rows[10][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch11,\n\t\t\t\t);\n\t\t\t\t$rows[11][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch12,\n\t\t\t\t);\n\t\t\t\t$rows[12][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch13,\n\t\t\t\t);\n\t\t\t\t$rows[13][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch14,\n\t\t\t\t);\n\t\t\t\t$rows[14][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch15,\n\t\t\t\t);\n\t\t\t\t$rows[15][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch16,\n\t\t\t\t);\n\t\t\t\t$rows[16][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch17,\n\t\t\t\t);\n\t\t\t\t$rows[17][]=array(\n\t\t\t\t\tstrtotime($binTableModel->start_date_time)*1000,\n\t\t\t\t\t(int)$binTableModel->ch18,\n\t\t\t\t);\n\t\t\t}\n\n\t\treturn \tJson::encode($rows);\n }",
"public function getInterval(){\n\t\treturn $this->interval;\n\t}",
"public function toWordPressArray(): array\n {\n $recurrent = \\apply_filters(\n 'rumur/scheduling/intervals/recurrent',\n $this->asWordPressInterval($this->recurrent, null, '-')\n );\n\n $additional = \\apply_filters(\n 'rumur/scheduling/intervals/additional',\n $this->asWordPressInterval($this->additional)\n );\n\n return \\apply_filters('rumur/scheduling/intervals', array_merge($recurrent, $additional));\n }",
"public function reservedJobs()\n {\n return $this->get('current-jobs-reserved', 0);\n }",
"public function getAllInActive()\n {\n return\n DB::table('job_families')\n ->select(\n 'id',\n 'code',\n 'description',\n 'name',\n 'eff_begin as effBegin',\n 'eff_end as effEnd'\n )\n ->where([\n ['tenant_id', $this->requester->getTenantId()],\n ['company_id', $this->requester->getCompanyId()],\n ['eff_end', '<', Carbon::now()]\n ])\n ->get();\n }",
"public function getEmployment() // {{{\n {\n global $CCV_CONST;\n $records = array();\n $elements = $this->m_xpath->query(\"//section[@id='b857f61b33484cb093068bd2da764f99']\");\n for ($i = 0; !is_null($elements) && $i < $elements->length; $i++)\n {\n $record = array();\n $id = $this->get_xpath(\"@recordId\", $elements->item($i));\n $record['type'] = $this->get_xpath(\"field[@id='9510a03a308f43ceb8cd046aeffa9499']/lov/@id\", $elements->item($i));\n $record['title'] = $this->get_xpath(\"field[@id='886807b87b624978bc8ca9045ff56e47']/value\", $elements->item($i));\n $record['status'] = $this->get_xpath(\"field[@id='ef7bd6fa8dd040449fa181f0ca4530e4']/lov/@id\", $elements->item($i));\n $record['rank'] = $this->get_xpath(\"field[@id='500e1360abd14972bc1ef844a8b98087']/lov/@id\", $elements->item($i));\n $date = $this->get_xpath(\"field[@id='c7e85d10d10249c68b28c71fc80ec570']/value\", $elements->item($i));\n @list($record[\"start_year\"], $record[\"start_month\"]) = explode(\"/\", $date);\n $date = $this->get_xpath(\"field[@id='b4681f52d85440829faa3160ba3bb31f']/value\", $elements->item($i));\n @list($record[\"end_year\"], $record[\"end_month\"]) = explode(\"/\", $date);\n $record[\"end_year\"] = ($record[\"end_year\"] == null) ? \"\" : $record[\"end_year\"];\n $record[\"end_month\"] = ($record[\"end_month\"] == null) ? \"\" : $record[\"end_month\"];\n \n $record['organization_country'] = $this->get_xpath(\"field[@id='5dd34f14c1ea47c09e8ddcd202653814']/refTable/linkedWith[@label='Country']/@value\", $elements->item($i));\n $record['organization_subdivision'] = $this->get_xpath(\"field[@id='5dd34f14c1ea47c09e8ddcd202653814']/refTable/linkedWith[@label='Subdivision']/@value\", $elements->item($i));\n $record['organization_type'] = $this->get_xpath(\"field[@id='5dd34f14c1ea47c09e8ddcd202653814']/refTable/linkedWith[@label='Organization Type']/@value\", $elements->item($i));\n $record['organization_name'] = $this->get_xpath(\"field[@id='5dd34f14c1ea47c09e8ddcd202653814']/refTable/linkedWith[@label='Organization']/@value\", $elements->item($i));\n $record['department'] = $this->get_xpath(\"field[@id='cd6e5e97994e42f893bd5c9e7212c94b']/value\", $elements->item($i));\n $record['faculty'] = $this->get_xpath(\"field[@id='58cf7001d283421b91f5da21f0ef2188']/value\", $elements->item($i));\n $record['tenure'] = $this->get_xpath(\"field[@id='b0eca39ad77346648180dec948d13432']/lov/@id\", $elements->item($i));\n $records[$id] = $record;\n }\n return $records;\n }",
"public function getJobHistories(){\n return $this->securityDAO->getJobHistoriesDAO();\n }"
] | [
"0.6341017",
"0.6014717",
"0.59247905",
"0.5626282",
"0.54279625",
"0.54205066",
"0.53948295",
"0.5238477",
"0.5214682",
"0.520898",
"0.5180877",
"0.5048829",
"0.5038632",
"0.50284",
"0.50219715",
"0.5018175",
"0.49848828",
"0.49848828",
"0.49848828",
"0.49796382",
"0.4978706",
"0.49545178",
"0.49476346",
"0.49423578",
"0.4925031",
"0.4859665",
"0.48522592",
"0.48507684",
"0.4850246",
"0.4845971"
] | 0.8080105 | 0 |
/ Retrieve collection class | protected function _getCollectionClass()
{
return 'sm_cameraslide/slide';
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getCollectionClass ()\n {\n return Doctrine_Manager::getInstance()->getAttribute(Doctrine::ATTR_COLLECTION_CLASS);\n }",
"abstract public function getCollectionTypeHelper();",
"abstract public function getCollectionType(): string;",
"public function getCollection() {\n\t\t$colelction = $this->tsValue('collection');\n\t\tvar_dump($collection);\n\t\treturn $this->tsValue('collection');\n\t}",
"public function get_collection(){\n\t\treturn $this->collection;\n\t}",
"public function get_collection(){\n\t\treturn $this->collection;\n\t}",
"function tainacan_get_collection() {\n\t$collection_id = tainacan_get_collection_id();\n\tif ( $collection_id ) {\n\t\t$TainacanCollections = Repositories\\Collections::get_instance();\n\t\t$collection = $TainacanCollections->fetch($collection_id);\n\t\tif ( $collection instanceof Entities\\Collection ) {\n\t\t\treturn $collection;\n\t\t}\n\t\treturn false;\n\t}\n}",
"public function getCollection();",
"public function getCollection();",
"public function collection()\n {\n return $this->collection;\n }",
"public function getCollection()\r\n {\r\n return $this->_collection;\r\n }",
"public function collection(): Collection\n {\n return $this->collection;\n }",
"public function collectionClassProvider()\n {\n return [\n [Collection::class],\n [LazyCollection::class],\n ];\n }",
"public function collectionClassProvider()\n {\n return [\n [Collection::class],\n [LazyCollection::class],\n ];\n }",
"public function getCollection()\n {\n return $this->collection;\n }",
"public function getCollection()\n {\n return $this->collection;\n }",
"public function getCollection()\n {\n return $this->collection;\n }",
"public function getCollection()\n {\n return $this->collection;\n }",
"public function getCollection()\n {\n return $this->collection;\n }",
"public function ctr() {\n return static::$collectionTypeReference;\n }",
"public function getCollectionForSelf();",
"public function getCollection()\n\t{\n\t\t$name = \"{$this->db}.{$this->name}.{$this->gridFS}\";\n\n\t\tif (!isset(static::$collections[$name])) {\n\t\t\t$method = ($this->gridFS ? 'getGridFS' : 'selectCollection');\n\t\t\tstatic::$collections[$name] = $this->getClientInstance()->getDb()->$method($this->name);\n\t\t}\n\n\t\treturn static::$collections[$name];\n\t}",
"public function getCollection($type)\n\t{\n\t\tif(!isset($this->_collections[$type]))\n\t\t{\n\t\t\t$this->_collections[$type] =\n\t\t\t\tYaPhpDoc_Token_Structure_Collection_Abstract\n\t\t\t\t\t::getCollection($this, $type);\n\t\t}\n\t\treturn $this->_collections[$type];\n\t}",
"public function getCollection()\n {\n return parent::getCollection();\n }",
"public function getCollection() {\n if ($this->collection == null) {\n $this->collection = new \\Broker\\Collection ( SITE_CACHE_DATABASE_DIR, $this->configuration );\n }\n return $this->collection;\n }",
"public function getCollection()\n {\n if ($this->isEmbeddable()) {\n return null;\n }\n\n $collection = $this->property('collection');\n\n if (empty($collection)) {\n if ($this->parentSchema()) {\n //Using parent collection\n return $this->parentSchema()->getCollection();\n }\n\n $collection = Inflector::camelize($this->getShortName());\n $collection = Inflector::pluralize($collection);\n }\n\n return $collection;\n }",
"public function getCollection()\n {\n //@todo create logic for getting all records from database\n return $this->collectionFactory->create();\n }",
"public function getCollection()\n\t{\n\t\tif (!isset($this->_collection))\n {\n $this->_collection = Yii::app()->edmsMongoCollection($this->_collectionName,$this->_dbName,$this->_connectionId);\n $this->callObjectMethods($this->_collection,$this->_callAfterCollectionCreate,self::CALLAFTER_COLLECTIONCREATE);\n }\n\n\t\treturn $this->_collection;\n\t}",
"public function get(): Collection;",
"public function getCollection()\n {\n if (null !== $this->collection) {\n return $this->collection;\n }\n\n return $this->collection = $this->generateCollection();\n }"
] | [
"0.83718956",
"0.7296203",
"0.7276853",
"0.69306594",
"0.69074523",
"0.69074523",
"0.68144554",
"0.6777781",
"0.6777781",
"0.6715317",
"0.6688146",
"0.6632281",
"0.6627981",
"0.6627981",
"0.66274506",
"0.66274506",
"0.66274506",
"0.66274506",
"0.66274506",
"0.6608297",
"0.65542394",
"0.65347177",
"0.6458306",
"0.6454602",
"0.6437116",
"0.6421902",
"0.6381949",
"0.6373245",
"0.637189",
"0.6362696"
] | 0.73836213 | 1 |
/ Prepare collection for grid | protected function _prepareCollection()
{
$collection = Mage::getModel($this->_getCollectionClass())->getCollection();
$this->setCollection($collection);
return parent::_prepareCollection();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected function _prepareCollection()\n {\n // Get and set our collection for the grid\n $collection = Mage::getResourceModel($this->_getCollectionClass());\n $this->setCollection($collection);\n\n return parent::_prepareCollection();\n }",
"protected function _prepareCollection()\n {\n $collection = $this->_collectionFactory->create();\n\n $this->setCollection($collection);\n\n return parent::_prepareCollection();\n }",
"protected function _prepareCollection()\r\n {\t\r\n \tMage::dispatchEvent('extendedmassaction_adminhtml_catalog_product_grid_prepare_collection', array('collection' => $this));\r\n \t\treturn parent::_prepareCollection(); \r\n }",
"protected function _prepareCollection()\n {\n $collection = $this->_collectionFactory->getReport('sales_order_grid_data_source')->addFieldToSelect(\n 'entity_id'\n )->addFieldToSelect(\n 'increment_id'\n )->addFieldToSelect(\n 'customer_id'\n )->addFieldToSelect(\n 'created_at'\n )->addFieldToSelect(\n 'grand_total'\n )->addFieldToSelect(\n 'order_currency_code'\n )->addFieldToSelect(\n 'store_id'\n )->addFieldToSelect(\n 'billing_name'\n )->addFieldToSelect(\n 'shipping_name'\n )->addFieldToFilter(\n 'customer_id',\n $this->_coreRegistry->registry(RegistryConstants::CURRENT_CUSTOMER_ID)\n );\n\n $this->setCollection($collection);\n return parent::_prepareCollection();\n }",
"protected function _prepareCollection()\n {\n $collection = Mage::getResourceModel('emvemt/emt_collection');\n $collection->prepareQueryToGetMagentoName();\n $collection->prepareQueryToGetAccountName();\n $collection->unselectEmvSendingTemplate();\n $this->setCollection($collection);\n\n parent::_prepareCollection();\n }",
"protected function _prepareCollection()\n {\n return parent::_prepareCollection();\n }",
"protected function _prepareCollection()\n {\n $collection = Mage::getResourceModel('bluesnap/logger_db_entry_collection');\n\n\n //$collection->addFieldToFilter('return_id',Mage::app()->getRequest()->getParam('id'));\n $this->setCollection($collection);\n\n if ($this->getCollection()) {\n\n $this->_preparePage();\n\n $columnId = $this->getParam($this->getVarNameSort(), $this->_defaultSort);\n $dir = $this->getParam($this->getVarNameDir(), $this->_defaultDir);\n $filter = $this->getParam($this->getVarNameFilter(), null);\n\n if (is_null($filter)) {\n $filter = $this->_defaultFilter;\n }\n\n if (is_string($filter)) {\n $data = $this->helper('adminhtml')->prepareFilterString($filter);\n $this->_setFilterValues($data);\n } else if ($filter && is_array($filter)) {\n $this->_setFilterValues($filter);\n } else if (0 !== sizeof($this->_defaultFilter)) {\n $this->_setFilterValues($this->_defaultFilter);\n }\n\n if (isset($this->_columns[$columnId]) && $this->_columns[$columnId]->getIndex()) {\n $dir = (strtolower($dir) == 'desc') ? 'desc' : 'asc';\n $this->_columns[$columnId]->setDir($dir);\n $this->_setCollectionOrder($this->_columns[$columnId]);\n }\n\n if (!$this->_isExport) {\n $this->getCollection()->load();\n $this->_afterLoadCollection();\n }\n }\n return $this;\n }",
"protected function _prepareCollection()\n {\n $collection = Mage::getModel($this->getModelPath())->getCollection();\n $this->setCollection($collection);\n return parent::_prepareCollection();\n }",
"protected function _prepareCollection()\n {\n $collection = Mage::getModel('sagepayreporting/sagepayreporting_collection', Mage::registry('sagepay_related_transactions'));\n $this->setCollection($collection);\n return Mage_Adminhtml_Block_Widget_Grid::_prepareCollection();\n }",
"protected function prepare()\n {\n /** @var CollectionView $collection */\n $collection = $this->getComponent('collection_view');\n $collection->setData($this->getDataProvider());\n if ($collection->getDataInjector() === null) {\n $collection->setDataInjector($this->makeDataInjector());\n }\n $this->applyOperations();\n $this->hideSubmitButtonIfNotUsed();\n }",
"protected function _prepareCollection() \n {\n $collection = Mage::getModel('simipwa/agent')->getCollection();\n $this->setCollection($collection);\n return parent::_prepareCollection();\n }",
"protected function _prepareCollection()\n {\n /** @var $collection \\Magento\\Rma\\Model\\ResourceModel\\Item\\Collection */\n $collection = $this->_collectionFactory->create();\n $collection->addAttributeToSelect('*');\n $collection->addAttributeToFilter('entity_id', null);\n\n $this->setCollection($collection);\n\n return parent::_prepareCollection();\n }",
"protected function _prepareCollection()\n {\n $collection = Mage::getModel('inchoo_ticket/ticket')\n ->getResourceCollection();\n $this->setCollection($collection);\n return parent::_prepareCollection();\n }",
"protected function _prepareCollection()\r\n {\r\n $collection = Mage::getModel('manager/channel')->getCollection();\r\n $this->setCollection($collection);\r\n return parent::_prepareCollection();\r\n }",
"protected function _prepareCollection() {\r\n $collection = Mage::getModel('events/event')->getCollection();\r\n $this->setCollection($collection);\r\n return parent::_prepareCollection();\r\n }",
"protected function _prepareCollection()\n {\n $collection = Mage::getModel('core/website')\n ->getCollection()\n ->joinGroupAndStore();\n\n $collection->getSelect()->join(\n array('stock_table' => $collection->getTable('cataloginventory/stock')),\n 'main_table.stock_id=stock_table.stock_id',\n array('stock_name')\n );\n\n $this->setCollection($collection);\n Mage_Adminhtml_Block_Widget_Grid::_prepareCollection();\n\n return $this;\n }",
"protected function _prepareCollection()\n {\n $collection = Mage::getModel('d3w_album/photo')->getResourceCollection();\n $this->setCollection($collection);\n return parent::_prepareCollection();\n }",
"function pld_preprocess_islandora_basic_collection_grid(&$variables) {\n\tpld_preprocess_islandora_basic_collection($variables);\n}",
"protected function _prepareCollection()\n {\n $alias = array(\n 'qty_on_sale' => '`cataloginventory/stock_item`.qty',\n );\n\n $stockFields = array(\n 'qty_on_sale' => 'qty',\n 'item_id' => 'item_id'\n );\n\n /* @var $collection Mage_Catalog_Model_Resource_Eav_Mysql4_Product_Collection */\n $collection = Mage::getResourceModel('catalog/product_collection');\n\n $collection\n ->addAttributeToSelect('name')\n ->addAttributeToSelect('short_description')\n ->joinTable('cataloginventory/stock_item','product_id=entity_id',$stockFields,null,'left');\n\n $this->setCollection($collection);\n\n return parent::_prepareCollection();\n }",
"protected function _prepareCollection()\n {\n $collection = Mage::getSingleton('languagecsv/file_collection');\n// Mage::log($collection->load(), null, 'debug.log', true);\n $this->setCollection($collection);\n return parent::_prepareCollection();\n }",
"protected function _prepareCollection()\n {\n $this->setCollection($this->_actorCollection);\n return parent::_prepareCollection();\n }",
"public function prepareGrid() {\n return $this;\n }",
"protected function _prepareCollection()\n {\n \n $collection = Mage::getResourceModel(\n 'som_localstore/sale'\n );\n \n $this->setCollection($collection);\n \n return parent::_prepareCollection();\n }",
"public function prepare_items() {\n\t\t$this->_column_headers = array( $this->get_columns(), array(), $this->get_sortable_columns() );\n\t\t$this->items = self::get_data();\n\t}",
"protected function _prepareCollection()\n {\n $current_store = Mage::app()->getStore()->getId();\n $configTestyBlockValue = Mage::getStoreConfig('testimonialsection/testisettings/testynumbers');\n $configFeaturedTestyBlockValue = Mage::getStoreConfig('testimonialsection/testyblock/featuredtestynumbers');\n $pagerEnable = Mage::getStoreConfig('testimonialsection/testisettings/allowpagination');\n $collection = Mage::getModel(\"testimonial/testimonial\")->getCollection()\n ->addFieldToFilter('status','1');\n \n \n /* echo '<pre>';\n print_r(get_class_methods($collection));exit; */ \n if(!$this->getSidebar()) {\n if($pagerEnable != 1){ \n if($configTestyBlockValue =='')\n {\n $collection->clear()->setPageSize(10);\n }\n else\n {\n $collection->clear()->setPageSize($configTestyBlockValue);\n }\n }\n else{\n $limit = $this->getRequest()->getParam('limit');\n $pager = $this->getLayout()->createBlock('page/html_pager', 'testimonials.pager');\n //$pager->setAvailableLimit(array(6=>6,12=>12,20=>20));\n if(!empty($limit))\n {\n $collection->clear()->setPageSize($limit);\n $pager->setCollection($collection); \n }\n else\n {\n $collection->clear()->setPageSize(10);\n $pager->setCollection($collection); \n }\n $this->setChild('pager', $pager);\n } \n } \n if ($this->getSidebar()){\n $collection->addFieldToFilter('testimonial_sidebar', '1');\n if($configFeaturedTestyBlockValue ==''){\n $collection->clear()->setPageSize(5);\n }\n else{\n $collection->clear()->setPageSize($configFeaturedTestyBlockValue);\n }\n }\n $collection->setOrder('testimonial_position', 'DESC')\n ->load();\n \n $testys = array();\n foreach ($collection as $testy) {\n $stores = explode(',',$testy->getStores());\n if (in_array(0,$stores) || in_array($current_store,$stores))\n //if ($banner->getStatus())\n $testys[] = $testy;\n \n }\n $this->setTestimonials($testys);\n \n return $this;\n }",
"public function prepare_items() {\r\n\t\t$columns = $this->get_columns();\r\n\t\t$hidden = array(); // No hidden columns\r\n\t\t$sortable = $this->get_sortable_columns();\r\n\t\t$this->_column_headers = array( $columns, $hidden, $sortable );\r\n\t\t$this->items = $this->reports_data();\r\n\r\n\t}",
"function prepare_items() {\n\t\t$columns = $this->get_columns();\n\t\t$hidden = $this->get_hidden_columns();\n\t\t$sortable = $this->get_sortable_columns();\n\t\t$this->_column_headers = array($columns, $hidden, $sortable);\n\n\t\t$per_page = 50;\n\t\tif(!empty($_GET['per_page'])){\n\t\t\t$per_page = absint($_GET['per_page']);\n\t\t}\n\n\t\t$current_page = $this->get_pagenum();\n\t\t// Prepare sequence of elements to display\n\t\t$display_data = array_slice($this->aDBc_elements_to_display,(($current_page-1) * $per_page), $per_page);\n\t\t$this->set_pagination_args( array(\n\t\t\t'total_items' => count($this->aDBc_elements_to_display),\n\t\t\t'per_page' => $per_page\n\t\t));\n\t\t$this->items = $display_data;\n\t}",
"abstract protected function generateCollection();",
"public function setUpCollection()\n {\n $this->type = 'collection';\n }",
"protected function _prepareCollection()\n {\n // ---------------------------------------\n $collectionSellingFormat = $this->activeRecordFactory->getObject('Template\\SellingFormat')->getCollection();\n $collectionSellingFormat->getSelect()->reset(Select::COLUMNS);\n $collectionSellingFormat->getSelect()->columns(\n [\n 'id as template_id',\n 'title',\n new \\Zend_Db_Expr('\\'' . self::TEMPLATE_SELLING_FORMAT . '\\' as `type`'),\n new \\Zend_Db_Expr('\\'0\\' as `marketplace_id`'),\n 'create_date',\n 'update_date',\n new \\Zend_Db_Expr('NULL as `category_path`'),\n new \\Zend_Db_Expr('NULL as `browsenode_id`'),\n new \\Zend_Db_Expr('NULL as `is_new_asin_accepted`'),\n ]\n );\n $collectionSellingFormat->getSelect()->where('component_mode = (?)', \\Ess\\M2ePro\\Helper\\Component\\Amazon::NICK);\n // ---------------------------------------\n\n // Prepare synchronization collection\n // ---------------------------------------\n $collectionSynchronization = $this->activeRecordFactory->getObject('Template\\Synchronization')->getCollection();\n $collectionSynchronization->getSelect()->reset(Select::COLUMNS);\n $collectionSynchronization->getSelect()->columns(\n [\n 'id as template_id',\n 'title',\n new \\Zend_Db_Expr('\\'' . self::TEMPLATE_SYNCHRONIZATION . '\\' as `type`'),\n new \\Zend_Db_Expr('\\'0\\' as `marketplace_id`'),\n 'create_date',\n 'update_date',\n new \\Zend_Db_Expr('NULL as `category_path`'),\n new \\Zend_Db_Expr('NULL as `browsenode_id`'),\n new \\Zend_Db_Expr('NULL as `is_new_asin_accepted`'),\n ]\n );\n $collectionSynchronization->getSelect()->where(\n 'component_mode = (?)',\n \\Ess\\M2ePro\\Helper\\Component\\Amazon::NICK\n );\n // ---------------------------------------\n\n // Prepare Shipping collection\n // ---------------------------------------\n $collectionShipping = $this->activeRecordFactory->getObject('Amazon_Template_Shipping')\n ->getCollection();\n $collectionShipping->getSelect()->join(\n ['mm' => $this->marketplaceFactory->create()->getResource()->getMainTable()],\n 'mm.id=main_table.marketplace_id',\n []\n );\n $collectionShipping->addFieldToFilter('mm.status', \\Ess\\M2ePro\\Model\\Marketplace::STATUS_ENABLE);\n $collectionShipping->getSelect()->reset(Select::COLUMNS);\n $collectionShipping->getSelect()->columns(\n [\n 'id as template_id',\n 'title',\n new \\Zend_Db_Expr('\\'' . self::TEMPLATE_SHIPPING . '\\' as `type`'),\n 'marketplace_id',\n 'create_date',\n 'update_date',\n new \\Zend_Db_Expr('NULL as `category_path`'),\n new \\Zend_Db_Expr('NULL as `browsenode_id`'),\n new \\Zend_Db_Expr('NULL as `is_new_asin_accepted`'),\n ]\n );\n // ---------------------------------------\n\n // Prepare Product Tax Code collection\n // ---------------------------------------\n $collectionProductTaxCode = $this->activeRecordFactory->getObject('Amazon_Template_ProductTaxCode')\n ->getCollection();\n\n $collectionProductTaxCode->getSelect()->reset(\\Magento\\Framework\\DB\\Select::COLUMNS);\n $collectionProductTaxCode->getSelect()->columns(\n [\n 'id as template_id',\n 'title',\n new \\Zend_Db_Expr('\\'' . self::TEMPLATE_PRODUCT_TAX_CODE . '\\' as `type`'),\n new \\Zend_Db_Expr('\\'0\\' as `marketplace_id`'),\n 'create_date',\n 'update_date',\n new \\Zend_Db_Expr('NULL as `category_path`'),\n new \\Zend_Db_Expr('NULL as `browsenode_id`'),\n new \\Zend_Db_Expr('NULL as `is_new_asin_accepted`'),\n ]\n );\n // ---------------------------------------\n\n // Prepare union select\n // ---------------------------------------\n $collectionsArray = [\n $collectionSellingFormat->getSelect(),\n $collectionSynchronization->getSelect(),\n $collectionShipping->getSelect(),\n $collectionProductTaxCode->getSelect(),\n ];\n\n $unionSelect = $this->resourceConnection->getConnection()->select();\n $unionSelect->union($collectionsArray);\n // ---------------------------------------\n\n // Prepare result collection\n // ---------------------------------------\n /** @var \\Ess\\M2ePro\\Model\\ResourceModel\\Collection\\Wrapper $resultCollection */\n $resultCollection = $this->wrapperCollectionFactory->create();\n $resultCollection->setConnection($this->resourceConnection->getConnection());\n $resultCollection->getSelect()->reset()->from(\n ['main_table' => $unionSelect],\n [\n 'template_id',\n 'title',\n 'type',\n 'marketplace_id',\n 'create_date',\n 'update_date',\n 'category_path',\n 'browsenode_id',\n 'is_new_asin_accepted',\n ]\n );\n // ---------------------------------------\n\n $this->setCollection($resultCollection);\n\n return parent::_prepareCollection();\n }"
] | [
"0.811302",
"0.75176144",
"0.75007755",
"0.74723774",
"0.7437473",
"0.73704505",
"0.7358649",
"0.7326479",
"0.7225759",
"0.709619",
"0.70853025",
"0.7029483",
"0.7028532",
"0.702788",
"0.7003564",
"0.69944215",
"0.6976197",
"0.69161564",
"0.68745357",
"0.6852451",
"0.6837529",
"0.6765282",
"0.67501146",
"0.67383295",
"0.6733872",
"0.6728725",
"0.67281216",
"0.669599",
"0.6695397",
"0.66235626"
] | 0.7584213 | 1 |
Return an array of Meta tag type values | private function tagTypes()
{
return [
'name' => '<meta name="name" content="value">',
'link' => '<link rel="name" href="value">',
'property' => '<meta property="name" content="value">'
];
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getMetaTags(): array\n {\n return $this->attributes['meta']['metaTags'] ?? [];\n }",
"private function meta_tags() {\n\n /*\n Create an empty array\n */\n\n $frontend_meta = array();\n\n /*\n Get Current Route\n */\n\n $current_route = !empty( Route::getCurrentRoute()->getName() ) ? Route::getCurrentRoute()->getName() : '';\n \n if( isset( $current_route ) && !empty( $current_route) ) {\n\n /*\n Get Meta Fields using current route;\n */\n $metaTags = StaticPageSeo::where( 'route', $current_route )->first();\n\n if( isset( $metaTags ) && !empty( $metaTags) ) {\n $frontend_meta['name'] = $metaTags['name'];\n $frontend_meta['route'] = $metaTags['route'];\n $frontend_meta['meta_title'] = $metaTags['meta_title'];\n $frontend_meta['meta_description']= $metaTags['meta_description'];\n $frontend_meta['meta_keyword'] = $metaTags['meta_keyword'];\n }\n }\n\n return $frontend_meta;\n }",
"public function getMetas(): array\n {\n return $this->metas;\n }",
"public function getMetadataTypes()\n {\n $rowset = $this->database->fetchAll(\n $this->database->select()->from('metadata', 'metadatatype')->group('metadatatype')\n );\n $types = array();\n foreach ($rowset as $row) {\n $types[] = $this->mapTypeToName($row['metadatatype']);\n }\n\n return $types;\n }",
"public function metas() {\n if(!is_null($this->metas)) return $this->metas;\n return $this->filterBy('type', 'meta');\n }",
"private function get_post_metas() {\n\t\tif ( $this->post_id === null ) {\n\t\t\treturn array();\n\t\t}\n\n\t\t$metas = array();\n\t\tforeach ( $this->available_post_meta as $meta ) {\n\t\t\t$meta_value = get_post_meta( $this->post_id, $meta, true );\n\t\t\tif ( empty( $meta_value ) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t$metas[ $meta ] = $meta_value;\n\t\t}\n\n\t\treturn $metas;\n\t}",
"public static function get_all_dynamic_types()\n {\n self::createTypeCategoryTag();\n $id = Type_category::where(\"name\", \"=\", \"tag\")->first()->id;\n $data_types = TypeModel::where(\"type_category_id\", \"=\", $id)->all();\n $types = [];\n foreach ($data_types as $data_type)\n array_push($types, $data_type->name);\n return $types;\n }",
"public function getMetaTags() {\n return $this->doc->getElementsByTagName(\"meta\");\n }",
"function _metatag_owms_core_metatag_type_options() {\n\t$values = _metatag_owms_core_metatag_options('information_type');\n foreach($values as $value) { //for all lines\n\t\t$options[$value] = $value; //add the values to the options\n\t}\n return $options;\n}",
"function pxlz_edgtf_get_header_type_meta_values() {\n global $wpdb;\n global $edgtf_header_types_values;\n\n if (pxlz_edgtf_is_wpml_installed()) {\n $lang = ICL_LANGUAGE_CODE;\n\n $sql = \"SELECT pm.meta_value\n\t\t\t\t\tFROM {$wpdb->prefix}postmeta pm\n\t\t\t\t\tLEFT JOIN {$wpdb->prefix}posts p ON p.ID = pm.post_id\n\t\t\t\t\tLEFT JOIN {$wpdb->prefix}icl_translations icl_t ON icl_t.element_id = p.ID\n\t\t\t\t\tWHERE pm.meta_key = 'edgtf_header_type_meta'\n\t\t\t\t\tAND icl_t.language_code='$lang'\";\n } else {\n $sql = \"SELECT pm.meta_value\n\t\t\t\t\tFROM {$wpdb->prefix}postmeta pm\n\t\t\t\t\tWHERE pm.meta_key = 'edgtf_header_type_meta'\";\n }\n\n $results = $wpdb->get_results($sql, ARRAY_A);\n\n if (!(is_array($results) && count($results))) {\n $edgtf_header_types_values = false;\n } else {\n $results_array = array();\n foreach ($results as $result) {\n foreach ($result as $value) {\n $results_array[] = $value;\n }\n }\n\n $edgtf_header_types_values = $results_array;\n }\n }",
"public function get_page_meta_tags() {\n $tags = array();\n isset($this->params[\"page_meta_tags\"]) && $tags = $this->params[\"page_meta_tags\"];\n\n array_key_exists(\"description\", $tags) || $tags[\"description\"] = \"Simple open source issue tracker - free for personal and commercial use\"; \n array_key_exists(\"keywords\", $tags) || $tags[\"keywords\"] = \"issue, tracker, open source, project, management, free, personal, commercial\"; \n\n $result = \"\";\n foreach ( $tags as $key => $value ) {\n $result .= '<meta name=\"' . $key . '\" description =\"' . $this->escape_string($value) . '\">' . PHP_EOL;\n }\n\n return ($result);\n }",
"public function get_custom_values()\n\t{\n\t\treturn $this->_custom_types;\n\t}",
"private function get_metatags() {\n $metatags = $this->display->get_option('metatags');\n\n // Leave some possibility for future versions to support translation.\n if (empty($metatags)) {\n $metatags = array(LANGUAGE_NONE => array());\n }\n if (!isset($metatags[LANGUAGE_NONE])) {\n $metatags = array(LANGUAGE_NONE => $metatags);\n }\n\n return $metatags;\n }",
"public function getMeta();",
"public function getMeta();",
"public function getMetaTags()\n {\n return ($this->metaTags && count($this->metaTags)) ? $this->metaTags : null;\n }",
"public function getTagMetadata(): array\n {\n return [\n '@param' => [\n 'min' => 0,\n 'max' => null,\n 'lineAfter' => true\n ],\n '@return' => [\n 'min' => 1,\n 'max' => 1,\n 'if' => [$this->getTagHelper(), 'isNoWhitelistedFunction'],\n 'lineAfter' => true\n ],\n '@throws' => [\n 'min' => 0,\n 'max' => null\n ],\n '@deprecated' => [\n 'min' => 0,\n 'max' => 1\n ],\n '@link' => [\n 'min' => 0,\n 'max' => null\n ]\n ];\n }",
"public function getTypes(): array;",
"public function getTypes()\n {\n $types = [];\n $validCustomFieldTypes = $this->getCustomFieldTypes();\n if (empty($validCustomFieldTypes)) {\n return $types;\n }\n foreach ($validCustomFieldTypes as $k => $customField) {\n $types[$k] = $customField['title'];\n }\n return $types;\n }",
"public function getMetaWithAttr($name) {\n\t\t$metas = $this->document->getElementsByTagName(\"meta\");\n\t\t// FIXME: case sensitive. Should iterate over attributes and do strcasecmp.\n\t\tforeach ($metas as $meta) {\n\t\t\tif (($charset = $meta->attributes->getNamedItem($name)) != null) {\n\t\t\t\t$result[] = array ( \n\t\t\t\t\t'code' => $this->dump($meta),\n\t\t\t\t\t'values' => $charset->value\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t\treturn isset($result) ? $result : array();\n\t}",
"public function getMetaKeys(): array;",
"public function get_meta_as_array($type=NULL)\r\n\t{\r\n\t\t//TODO: This needs to be updated to take an optional type ID and if none is provided return data for every image type\r\n\t\tif(!$this->loaded()) return;\r\n\r\n\t\t$meta = $this->typelinks;\r\n\r\n\t\tif($type===NULL)\r\n\t\t{\r\n\t\t\t$res = $meta->find_all();\r\n\t\t\t$retArr = array();\r\n\t\t\tforeach($res as $type)\r\n\t\t\t{\r\n\t\t\t\t$retArr[$type->image_types_id] = $this->get_meta_as_array($type->image_types_id);\r\n\t\t\t}\r\n\t\t\treturn $retArr;\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t$typelink = $meta->where('image_types_id','=',$type)->find();\r\n\t\t\tif(!$typelink->loaded()) return;\r\n\t\t\treturn $typelink->get_meta_as_array();\r\n\t\t}\r\n\r\n\t}",
"public function getMetaClassNames()\n {\n return [\n ($this->hasMetaImage() ? 'has-image' : 'no-image')\n ];\n }",
"public static function getTypes(): array;",
"public function meta() {\n\t\t$metaArray = [];\n\t\tforeach ( $this->webmasterTools as $key => $metaName ) {\n\t\t\t$value = aioseo()->options->webmasterTools->$key;\n\t\t\tif ( $value ) {\n\t\t\t\t$metaArray[ $metaName ] = $value;\n\t\t\t}\n\t\t}\n\n\t\treturn $metaArray;\n\t}",
"public function getMetaData(): array;",
"public static function getMeta();",
"public function getTypes(){\n $types = array();\n \n\t\t// Loop through and save types key as key and title as value in a new array\n\t\tforeach($this->types AS $key => $value){\n\t\t\t$types[$key] = $value['title'];\n\t\t}\n\t\t\n\t\treturn $types;\n\t}",
"public function getMeta($book): array\n {\n return [];\n }",
"public function getTypeList()\n {\n \t$typeList = [\n \tself::CODE => Yii::t('app', 'Code'),\n \tself::BITMAP => Yii::t('app', 'Bitmap'),\n \tself::TEXT => Yii::t('app', 'Text'),\n \t];\n \n \treturn $typeList;\n }"
] | [
"0.74491596",
"0.70802027",
"0.6954457",
"0.6925225",
"0.67907435",
"0.6591696",
"0.65748256",
"0.6530277",
"0.6467009",
"0.64500237",
"0.64134777",
"0.6407369",
"0.6393003",
"0.6382397",
"0.6382397",
"0.63648045",
"0.63232183",
"0.62836564",
"0.6279484",
"0.62424743",
"0.6231113",
"0.6227995",
"0.6225926",
"0.6222968",
"0.6220832",
"0.6208975",
"0.6196394",
"0.61895955",
"0.6187096",
"0.6179707"
] | 0.80470383 | 0 |
Returns the next page token from the response. | public function getNextPageToken()
{
$responsePageTokenGetMethod = $this->pageStreamingDescriptor->getResponsePageTokenGetMethod();
return $this->getResponseObject()->$responsePageTokenGetMethod();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getNextToken()\n {\n return $this->_fields['NextToken']['FieldValue'];\n }",
"public function getNextPageToken()\n {\n return $this->next_page_token;\n }",
"public function getNextPageToken()\n {\n return $this->next_page_token;\n }",
"public function getNextPageToken()\n {\n return $this->next_page_token;\n }",
"public function getNextPageToken()\n {\n return $this->next_page_token;\n }",
"public function getNextPageToken()\n {\n return $this->next_page_token;\n }",
"public function getNextPageToken()\n {\n return $this->next_page_token;\n }",
"public function getNextPageToken()\n {\n return $this->next_page_token;\n }",
"public function getNextPageToken()\n {\n return $this->next_page_token;\n }",
"public function nextToken() {\n return empty($this->body->SelectResult->NextToken) ?\n null : (string)$this->body->SelectResult->NextToken;\n }",
"private function next()\n {\n $this->tok = $this->lex->getToken();\n return $this->tok;\n }",
"public function getNextPage() {\n if($this->_nextInformation && isset($this->_nextInformation->startIndex))\n return $this->_request->setStartIndex($this->_nextInformation->startIndex);\n\n return null;\n }",
"private static function _parse_next() {\n\t\t$page_number = self::_get_next_page( self::$properties['current_page'], self::$properties['page_count'] );\n\t\t$offset = self::page_to_offset( $page_number, self::$properties['per_page'] );\n\t\tif ( self::$properties['current_page'] < self::$properties['page_count'] ) {\n\t\t\treturn static::_parse(static::$tpls['next'], array('offset'=> $offset, 'page_number'=> $page_number));\n\t\t} \n return '';\n\t}",
"private function nextParsedToken()\n {\n if ($this->current_pos + 1 >= count($this->ptokens)) {\n return false;\n }\n\n $this->current_pos++;\n $this->setupContext();\n return $this->ptokens[$this->current_pos];\n }",
"public function next()\n {\n $this->_currentItem++;\n if ($this->_currentItem >= $this->_pageItems) {\n $this->_currentPage++;\n if ($this->_currentPage <= $this->_pages) {\n $expectedPage = $this->_currentPage;\n $this->load();\n if($this->_currentPage != $expectedPage) {\n throw new InvalidAPIResponseException(\"Got page \" . $this->_currentPage . ' but expected page' . $expectedPage);\n }\n $this->_currentItem = 0;\n }\n }\n }",
"public function nextPage()\n {\n return $this->paginate('next');\n }",
"public function nextToken(): Token;",
"private static function getNextToken(): Token\n\t{\n\t\t$token = self::$stream->consumeToken();\n\t\tif ($token === NULL) {\n\t\t\tthrow new ParserException('Unexpected end of string, expected value');\n\t\t}\n\t\treturn $token;\n\t}",
"public function next()\n {\n return $this->page + 1;\n }",
"public function nextPage(){\n if($this->hasNext())\n {\n return $this->query($this->lastQuery, $this->page+1 );\n }\n return null;\n }",
"public function getNextToken(): ?TokenInterface;",
"public function nextPage() {\n // get the current page number\n $currentPageNumber = $this->currentPageNumber();\n\n // get the next page results and return them\n return $this->query()\n ->page($currentPageNumber + 1)\n ->get();\n }",
"public function getNextPage()\n {\n return (isset($this->data['nextPage'])) ? $this->data['nextPage'] : null;\n }",
"function nextToken(array $config = []);",
"public function nextPage() {\n return $this->currentPage + 1;\n }",
"public function getNextToken()\n {\n $token = null;\n $value = null;\n $nextOffset = $this->length;\n foreach ($this->tokens as $name => $regexp) {\n if(preg_match('/' . $regexp . '/m', $this->data, $matches, PREG_OFFSET_CAPTURE, $this->offset)) {\n if ($nextOffset > $matches[0][1]) {\n $token = $name;\n $value = $matches[0][0];\n $nextOffset = $matches[0][1];\n }\n }\n }\n return array($token, $value, $nextOffset);\n }",
"public function getNext() {\n\t\treturn $this->createPage($this->getCurrent() + 1);\n\t}",
"public function getNextPage(): ?int;",
"public function getNextToken($skip = false)\n {\n $token = $this->tokens[$this->cursor + 1];\n if ($skip) {\n $this->cursor++;\n }\n return $token;\n }",
"public function getNextPageNo() {\n\t\treturn $this->next_page_no;\n\t}"
] | [
"0.71547544",
"0.6815654",
"0.6815654",
"0.6815654",
"0.6815654",
"0.6815654",
"0.6815654",
"0.6815654",
"0.6815654",
"0.63314706",
"0.6199279",
"0.61789286",
"0.61002445",
"0.6097002",
"0.60712516",
"0.6068541",
"0.6056622",
"0.6031628",
"0.6025338",
"0.59783196",
"0.59760064",
"0.59389895",
"0.58630794",
"0.5806534",
"0.57576597",
"0.57544386",
"0.57217056",
"0.57214665",
"0.5705297",
"0.5667634"
] | 0.68789494 | 1 |
Return an iterator over the elements in the response. | #[\ReturnTypeWillChange]
public function getIterator()
{
$resourcesGetMethod = $this->pageStreamingDescriptor->getResourcesGetMethod();
$items = $this->getResponseObject()->$resourcesGetMethod();
foreach ($items as $key => $element) {
if ($items instanceof MapField) {
yield $key => $element;
} else {
yield $element;
}
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function ri(): ResponseIterator\n {\n return $this->readAsIterator();\n }",
"public function getAllResponses() {\n return new ArrayIterator($this->responses);\n }",
"#[\\ReturnTypeWillChange]\n public function getIterator()\n {\n return new \\ArrayIterator($this->headers);\n }",
"public function getIterator()\r\n {\r\n return new \\ArrayIterator($this->headers);\r\n }",
"public function getIterator()\n {\n return new \\ArrayIterator($this->headers);\n }",
"public function createAppropriateIterator(Response $response);",
"public function getIterator();",
"public function getIterator();",
"public function iterator();",
"public function iterator()\n {\n return $this->services->getIterator();\n }",
"public function getIterator()\n\t{\n\t\tfor ( $theItem=$this->fetch(); $theItem !== false; $theItem=$this->fetch() ) {\n\t\t\tyield $theItem;\n\t\t}\n\t}",
"public function getIterator()\n {\n return $this->all();\n }",
"public function getIterator(): ArrayIterator\n\t{\n\t\treturn new ArrayIterator($this->headers);\n\t}",
"public function getIterator () {\n return new ArrayIterator ($this->allRequest ($this->defaultRequest));\n }",
"public function getIterator()\n {\n return new \\ArrayIterator($this->all());\n }",
"public function getIterator()\n\t{\n\t\treturn new \\ArrayIterator($this->getAll());\n\t}",
"public function getItemIterator()\n {\n $item_outs = $this->simple_xml_element->xpath('//ItemOut');\n $result = array();\n foreach ($item_outs as $item_out) {\n $result[] = CxmlItemOut::factory($item_out);\n }\n return $result;\n }",
"public function getIterator(): \\Traversable\n {\n $client = $this->awsClient;\n if (!$client instanceof S3Client) {\n throw new InvalidArgument('missing client injected in paginated result');\n }\n if (!$this->input instanceof ListMultipartUploadsRequest) {\n throw new InvalidArgument('missing last request injected in paginated result');\n }\n $input = clone $this->input;\n $page = $this;\n while (true) {\n $page->initialize();\n if ($page->isTruncated) {\n $input->setKeyMarker($page->nextKeyMarker);\n\n $input->setUploadIdMarker($page->nextUploadIdMarker);\n\n $this->registerPrefetch($nextPage = $client->listMultipartUploads($input));\n } else {\n $nextPage = null;\n }\n\n yield from $page->getUploads(true);\n yield from $page->getCommonPrefixes(true);\n\n if (null === $nextPage) {\n break;\n }\n\n $this->unregisterPrefetch($nextPage);\n $page = $nextPage;\n }\n }",
"public function getIterator()\n {\n return new \\ArrayIterator($this->getCurrentPageResults());\n }",
"public function iterator() {\n return $this->getIterator();\n }",
"public function getIterator(): \\Iterator;",
"public function getIterator() {\r\n return new ArrayIterator($this->_results);\r\n }",
"public function getIterator()\n {\n }",
"public function getIterator(): Iterator;",
"public function getIterator()\n {\n return new \\ArrayIterator($this->metadata);\n }",
"public function getIterator()\n {\n return new \\ArrayIterator($this->data);\n }",
"public function getIterator()\n {\n return new \\ArrayIterator($this->data);\n }",
"public function getIterator()\n {\n return new \\ArrayIterator($this->data);\n }",
"public function getIterator()\n {\n $items = new ArrayIterator($this->_datas);\n return $items;\n }",
"public function getIterator()\n {\n return new \\ArrayIterator($this->_contents);\n }"
] | [
"0.7445465",
"0.71225727",
"0.68847054",
"0.6866364",
"0.6846943",
"0.6697174",
"0.6653101",
"0.6653101",
"0.6560715",
"0.6546589",
"0.6475614",
"0.64715457",
"0.63942176",
"0.6390187",
"0.6351887",
"0.6349967",
"0.631003",
"0.6280775",
"0.6263979",
"0.6263133",
"0.6239512",
"0.6236343",
"0.62289",
"0.62275976",
"0.62142026",
"0.62088466",
"0.62088466",
"0.62088466",
"0.6201212",
"0.6199578"
] | 0.71365726 | 1 |
Return an iterator over Page objects, beginning with this object. Additional Page objects are retrieved lazily via API calls until all elements have been retrieved. | public function iteratePages()
{
$currentPage = $this;
yield $this;
while ($currentPage->hasNextPage()) {
$currentPage = $currentPage->getNextPage();
yield $currentPage;
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getIterator()\n {\n return new \\ArrayIterator($this->pages);\n }",
"public function getPagesIterator()\n {\n if (!$this->hasPages()) {\n // Empty pages.\n return new ArrayIterator;\n }\n\n return new ArrayIterator(range(1, $this->getTotalPages()));\n }",
"public function getIterator()\n {\n $iterator = new ArrayIterator();\n for($page = $this->getFirstPageNumberShown(); $page <= $this->getLastPageNumberShown(); $page++) {\n $iterator->append(\n FF::getInstance('item', $page, $this->getPageLink($page), ($page == $this->currentPage))\n );\n }\n return $iterator;\n }",
"private function loadAll()\n {\n if($this->currentPage === 1 && $this->lastPage === 1) {\n return $this->getPage($this->currentPage);\n }\n\n $resources = [];\n\n while($this->hasNextPage()) {\n $this->currentPage++;\n $latestRequest = $this->getPage($this->currentPage);\n\n $resources = array_merge($resources, $latestRequest->getCollection());\n }\n\n $this->paginationData['data'] = $resources;\n\n $this->prepare();\n\n return $this;\n }",
"#[\\ReturnTypeWillChange]\n public function getIterator()\n {\n $resourcesGetMethod = $this->pageStreamingDescriptor->getResourcesGetMethod();\n $items = $this->getResponseObject()->$resourcesGetMethod();\n foreach ($items as $key => $element) {\n if ($items instanceof MapField) {\n yield $key => $element;\n } else {\n yield $element;\n }\n }\n }",
"public function getIterator()\n {\n return new \\ArrayIterator($this->getCurrentPageResults());\n }",
"public function iterator()\n {\n if (!$this->paginate) {\n $this->paginate = true;\n }\n $this->pageParams = null;\n // Make sure a page limit exists, if not use defaults\n if ($this->pageLimit === null) {\n $this->pageLimit = 'default';\n }\n\n $totalCount = null;\n if ($this->_totalCount === null) {\n $totalCount = $this->calculateTotalCount();\n $this->_totalCount = $totalCount;\n } else {\n $totalCount = $this->_totalCount;\n }\n $paginator = $this->createPaginator($totalCount, $this->pageLimit);\n return new QuerySetIterator($this, $paginator);\n }",
"public function getIterator(): \\Traversable\n {\n $client = $this->awsClient;\n if (!$client instanceof S3Client) {\n throw new InvalidArgument('missing client injected in paginated result');\n }\n if (!$this->input instanceof ListMultipartUploadsRequest) {\n throw new InvalidArgument('missing last request injected in paginated result');\n }\n $input = clone $this->input;\n $page = $this;\n while (true) {\n $page->initialize();\n if ($page->isTruncated) {\n $input->setKeyMarker($page->nextKeyMarker);\n\n $input->setUploadIdMarker($page->nextUploadIdMarker);\n\n $this->registerPrefetch($nextPage = $client->listMultipartUploads($input));\n } else {\n $nextPage = null;\n }\n\n yield from $page->getUploads(true);\n yield from $page->getCommonPrefixes(true);\n\n if (null === $nextPage) {\n break;\n }\n\n $this->unregisterPrefetch($nextPage);\n $page = $nextPage;\n }\n }",
"public function getIterator()\n\t{\n\t\tfor ( $theItem=$this->fetch(); $theItem !== false; $theItem=$this->fetch() ) {\n\t\t\tyield $theItem;\n\t\t}\n\t}",
"public function getPages() {\n if(empty($this->pages)) {\n $db = \\Helper::getDB();\n $db->where('documentId', $db->escape($this->getId()));\n $db->orderBy('p.id', 'ASC');\n $db->join('comments c', 'c.itemId = p.id AND c.type = \"page\" ', 'LEFT');\n $db->groupBy('p.id');\n $results = $db->get('document_pages p', NULL, '*, count(c.id) as commentsCount, p.id as id');\n\n $i = 1;\n foreach($results as $result) {\n $hasComments = $result['commentsCount'] > 0 ? TRUE : FALSE;\n $this->pages[$i] = new \\Models\\Page($result['id'], $i, $this->getPath(). DS . $i .'.'. IMAGE_TYPE, $hasComments);\n $i++;\n }\n }\n\n return $this->pages;\n }",
"public function getPages();",
"private function getPages()\n {\n $pageRepo = new PageRepository(new Page);\n return $pageRepo->listPages('name', 'asc', 1)->whereIn('parent_id', [1]);\n }",
"public function findAllIterator() {\n\t\t/** @var QueryBuilder $queryBuilder */\n\t\t$queryBuilder = $this->entityManager->createQueryBuilder();\n\t\treturn $queryBuilder\n\t\t\t->select('Thumbnail')\n\t\t\t->from($this->getEntityClassName(), 'Thumbnail')\n\t\t\t->getQuery()->iterate();\n\t}",
"private function nextPage() {\n $limit = $this->params['limit'] ?? 25;\n $this->params['offset'] = ($this->params['offset'] ?? 0) + $limit;\n $response = Etsy::$client->get(\n $this->uri,\n $this->params\n );\n $collection = Etsy::getResource($response, $this->resource);\n if(!$collection) {\n $collection->next_page = false;\n return false;\n }\n if(count($this->_append)) {\n $collection->append($this->_append);\n }\n if(count($collection->data) < $limit) {\n $collection->next_page = false;\n }\n return $collection;\n }",
"public function pageInstances()\n {\n return $this->hasMany(PageInstance::class)\n ->orderBy('id');\n }",
"public function pages()\n\t{\n\t\treturn $this->oneToMany(__NAMESPACE__ . '\\Page', 'event_id');\n\t}",
"public function getIterator(): \\Generator\n {\n yield from ($this->itemsCache->getCollection() ?? $this->buildQuery()->getIterator());\n }",
"public function getPage();",
"public function getPage();",
"public function getPage();",
"public function getPages()\n {\n return $this->pages;\n }",
"public function getPages()\n {\n return $this->pages;\n }",
"function getPages() {\n return $this->Pagelist;\n }",
"public function getIterator() {\n\t\tif (!$this->loaded) $this->load();\n\t\t\n\t\treturn parent::getIterator();\n\t}",
"public function getPageEntries()\n {\n return $this->pageEntries;\n }",
"function get_pages() {\n\n\t\t\treturn $this->pages;\n\n\t\t}",
"private function fetchPaginatedResults()\n {\n $select = new Select($this->tableGateway->getTable());\n\n // Create a new result set based on the Cours entity:\n $resultSetPrototype = new ResultSet();\n $resultSetPrototype->setArrayObjectPrototype(new Cours());\n\n // Create a new pagination adapter object:\n $paginatorAdapter = new DbSelect(\n // our configured select object:\n $select,\n // the adapter to run it against:\n $this->tableGateway->getAdapter(),\n // the result set to hydrate:\n $resultSetPrototype\n );\n\n $paginator = new Paginator($paginatorAdapter);\n\n return $paginator;\n }",
"public function next()\n {\n if (!$this->started) {\n return $this;\n }\n\n ++$this->index;\n $this->updatePagedResult();\n\n // Log::write('debug', __METHOD__.': info='.print_r([\n // 'index'=>$this->index,\n // 'paged_index'=>$this->paged_index,\n // 'page'=>$this->page,\n // 'total_page'=>$this->total_page,\n // 'total_record'=>$this->total_record,\n // ], true));\n \n return $this;\n }",
"public function getIterator();",
"public function getIterator();"
] | [
"0.732864",
"0.6837419",
"0.67131865",
"0.65772694",
"0.6489542",
"0.63845474",
"0.6356706",
"0.62704295",
"0.62007135",
"0.61609894",
"0.611431",
"0.6086708",
"0.6084906",
"0.60374767",
"0.6012527",
"0.5985952",
"0.59504205",
"0.5923623",
"0.5923623",
"0.5923623",
"0.59032625",
"0.59032625",
"0.5851133",
"0.58380604",
"0.5813891",
"0.5808478",
"0.5802317",
"0.5797259",
"0.57853395",
"0.57853395"
] | 0.7533701 | 0 |
Gets the API response object. | public function getResponseObject()
{
return $this->response;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"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 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 getResponseObject()\n {\n return $this->responseObject;\n }",
"public function getResponse(): Response\n {\n return $this->response;\n }",
"public function getResponseObject() {\n return $this->responseObject;\n }",
"public function getResponse()\n {\n return new \\OAuth2\\Response();\n }",
"private function getResponse()\n {\n return json_decode($this->response->getBody(), true);\n }",
"private function getResponse()\n {\n return json_decode($this->response->getBody(), true);\n }",
"private function getResponse()\n {\n return json_decode($this->response->getBody(), true);\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }",
"public function getResponse()\n {\n return $this->get('Response');\n }"
] | [
"0.7875999",
"0.7875999",
"0.7875999",
"0.7875999",
"0.7875999",
"0.7875999",
"0.7875999",
"0.78187263",
"0.7811984",
"0.7719081",
"0.7705527",
"0.7705527",
"0.7705527",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388",
"0.768388"
] | 0.80708826 | 0 |
Returns a collection of elements with a fixed size set by the collectionSize parameter. The collection will only contain fewer than collectionSize elements if there are no more pages to be retrieved from the server. NOTE: it is an error to call this method if an optional parameter to set the page size is not supported or has not been set in the API call that was used to create this page. It is also an error if the collectionSize parameter is less than the page size that has been set. | public function expandToFixedSizeCollection($collectionSize)
{
if (!$this->pageStreamingDescriptor->requestHasPageSizeField()) {
throw new ValidationException(
"FixedSizeCollection is not supported for this method, because " .
"the method does not support an optional argument to set the " .
"page size."
);
}
$request = $this->getRequestObject();
$pageSizeGetMethod = $this->pageStreamingDescriptor->getRequestPageSizeGetMethod();
$pageSize = $request->$pageSizeGetMethod();
if (is_null($pageSize)) {
throw new ValidationException(
"Error while expanding Page to FixedSizeCollection: No page size " .
"parameter found. The page size parameter must be set in the API " .
"optional arguments array, and must be less than the collectionSize " .
"parameter, in order to create a FixedSizeCollection object."
);
}
if ($pageSize > $collectionSize) {
throw new ValidationException(
"Error while expanding Page to FixedSizeCollection: collectionSize " .
"parameter is less than the page size optional argument specified in " .
"the API call. collectionSize: $collectionSize, page size: $pageSize"
);
}
return new FixedSizeCollection($this, $collectionSize);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected function paginate(Collection $collection){\n // regla para permitir al usuario personalizar la cantidad de elementos por pagina que desea\n $rules = [\n 'per_page' => 'integer | min:2 | max:50'\n ];\n\n Validator::validate(request()->all(), $rules);\n\n // nos permite resolver la pagina actual en que estamos para mostar el segmento de la coleccion a mostrar\n $page = LengthAwarePaginator::resolveCurrentPage();\n // valor predefinido de elementos por pagina\n $perPage = 15;\n\n if (request()->has('per_page')){\n $perPage = (int) request()->per_page;\n }\n\n // dividir la coleccion en secciones dependiendo del tamaño de la pagina\n $result = $collection->slice( ($page-1) * $perPage, $perPage ) -> values();\n // crear la instancia del paginador. Ojo aqui se eliminan los parametros que vengan por url\n $paginated = new LengthAwarePaginator($result, $collection->count(), $perPage, $page, [\n 'path' => LengthAwarePaginator::resolveCurrentPath(), // ruta que se utilizara para la pagina en que estamos, indica cual es la siguiente y anterior pagina\n ]);\n\n // para conservar los parametros por url se vuelven a agregar\n $paginated->appends(request()->all());\n\n return $paginated;\n }",
"public function setPageSize($size = 0);",
"public static function chunk($size = nil, $collection = nil)\n {\n return \\phln\\collection\\chunk($size, $collection);\n }",
"public static function makeLengthAware($collection, $url, $query, $page)\n {\n $perPage = Material::$paginate;\n\n //Create our paginator and pass it to the view\n return $paginatedSearchResults = new LengthAwarePaginator(\n $collection->forPage($page, $perPage), $collection->count(), $perPage, $page\n ,['path' => $url,'query' => $query,\n ]);\n }",
"public function paginateHelper( $collection, $perpage = 10 ) {\n\t\t$currentPage = LengthAwarePaginator::resolveCurrentPage();\n\n\t\t//Create a new Laravel collection from the array data\n\t\t$collection = new Collection( $collection );\n\n\t\t//Define how many items we want to be visible in each page\n\t\t$perPage = $perpage;\n\n\t\t//Slice the collection to get the items to display in current page\n\t\t$currentPageSearchResults = $collection->slice( ( $currentPage - 1 ) * $perPage, $perPage )->all();\n\n\t\t//Create our paginator and pass it to the view\n\t\t$paginatedSearchResults = new LengthAwarePaginator( $currentPageSearchResults, count( $collection ), $perPage );\n\n\t\treturn $paginatedSearchResults;\n\t}",
"private function nextPage() {\n $limit = $this->params['limit'] ?? 25;\n $this->params['offset'] = ($this->params['offset'] ?? 0) + $limit;\n $response = Etsy::$client->get(\n $this->uri,\n $this->params\n );\n $collection = Etsy::getResource($response, $this->resource);\n if(!$collection) {\n $collection->next_page = false;\n return false;\n }\n if(count($this->_append)) {\n $collection->append($this->_append);\n }\n if(count($collection->data) < $limit) {\n $collection->next_page = false;\n }\n return $collection;\n }",
"public function getListing(int $offset, int $size)\n {\n $url = BASE_API_URL . \"/marketplace/\" . $offset . \"/\" . $size;\n\n try {\n return new MarketItemCollection( [ $this->get( $url, $this->global_header ) ] );\n } catch (ErrorException $e) {\n Log::LogWrite(__METHOD__, $e->getMessage(), __FILE__, __LINE__);\n return $e->getMessage();\n }\n }",
"public function findAll($page, $size);",
"public function getCollectionEntriesPerPage()\n {\n return $this->collectionEntriesPerPage;\n }",
"public function chunkBy(int $size): Collection;",
"public function paginate($perPage = 5);",
"public function limit($collection, $limit);",
"public function paginate(Collection $collection, $per_page = null, $current_page = null)\n {\n $offset = $collection->forPage($this->current_page, $this->per_page);\n $total = count($collection);\n return new LengthAwarePaginator($offset, $total, $this->per_page, Paginator::resolveCurrentPage(), ['path' => Paginator::resolveCurrentPath()]);\n }",
"public static function collectionToPaginator($collection, Request $request)\n {\n return PaginationController::arrayToPaginator($collection->all(), $request);\n }",
"public function findAllPublic($page, $size);",
"function paginate_collection($data, Request $request, $perPage = null, $page = null)\n {\n // force presence of a collection\n if (!$data instanceof Collection) {\n $data = collect($data);\n }\n $pg = $request->get('page');\n $perPage = !$perPage ? app()['config']['repository.pagination_limit'] : $perPage;\n $page = $page ? (int)$page * 1 : (isset($pg) ? (int)$request->get('page') * 1 : 1);\n $offset = ($page * $perPage) - $perPage;\n\n return new LengthAwarePaginator($data->splice($offset, $perPage), $data->count(), $perPage,\n Paginator::resolveCurrentPage(), ['path' => Paginator::resolveCurrentPath(),]);\n }",
"public function paginate($perPage);",
"public function all($limit = 5, $offset = 0);",
"public function getElementsPerPage(): int;",
"public function page($size=10, $page=1) {\n\t\tif (!$size) {\n\t\t\t$this->qry->reset('limit');\n\t\t}\n\t\tif (!$page) {\n\t\t\t$page = 1;\n\t\t}\n\t\t$this->qry->limit(($page - 1) * $size, $size);\t\n\t}",
"public function setPageSize($var)\n {\n GPBUtil::checkInt32($var);\n $this->page_size = $var;\n\n return $this;\n }",
"public function setPageSize($var)\n {\n GPBUtil::checkInt32($var);\n $this->page_size = $var;\n\n return $this;\n }",
"public function setPageSize($var)\n {\n GPBUtil::checkInt32($var);\n $this->page_size = $var;\n\n return $this;\n }",
"public function setPageSize($var)\n {\n GPBUtil::checkInt32($var);\n $this->page_size = $var;\n\n return $this;\n }",
"public function setPageSize($var)\n {\n GPBUtil::checkInt32($var);\n $this->page_size = $var;\n\n return $this;\n }",
"public function setPageSize($var)\n {\n GPBUtil::checkInt32($var);\n $this->page_size = $var;\n\n return $this;\n }",
"public function setPageSize($var)\n {\n GPBUtil::checkInt32($var);\n $this->page_size = $var;\n\n return $this;\n }",
"public function setPageSize($var)\n {\n GPBUtil::checkInt32($var);\n $this->page_size = $var;\n\n return $this;\n }",
"public function setPageSize($var)\n {\n GPBUtil::checkInt32($var);\n $this->page_size = $var;\n\n return $this;\n }",
"public function setPageSize($var)\n {\n GPBUtil::checkInt32($var);\n $this->page_size = $var;\n\n return $this;\n }"
] | [
"0.63756555",
"0.6055694",
"0.5939679",
"0.59056234",
"0.589184",
"0.5867031",
"0.5830784",
"0.5828589",
"0.5719866",
"0.5705084",
"0.568717",
"0.5639275",
"0.5600829",
"0.55868304",
"0.556798",
"0.5501875",
"0.5404836",
"0.54036605",
"0.53887093",
"0.5370335",
"0.53695285",
"0.53695285",
"0.53695285",
"0.53695285",
"0.53695285",
"0.53695285",
"0.53695285",
"0.53695285",
"0.53695285",
"0.53695285"
] | 0.6863158 | 0 |
Instantiate the controls and actually load them into the control manager. | public function load_controls() {
if ( empty( $this->control_classes ) ) {
return;
}
foreach ( $this->control_classes as $control_manager ) {
$control_instance = new $control_manager();
if ( ! $control_instance instanceof Controls_Base ) {
continue;
}
$control_instance->init();
$this->controls = array_merge( $this->controls, $control_instance->get_controls() );
}
$this->order_by_priority();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected function _register_controls() {\n\n\t\t// Content Tab\n\n\t\t$this->register_heading_controls();\n\t\t$this->register_banners_controls();\n\t\t$this->register_product_tabs_controls();\n\t\t$this->register_side_products_controls();\n\t\t$this->register_lazy_loading_controls();\n\n\t\t// Style Tab\n\n\t\t$this->register_heading_style_controls();\n\t\t$this->register_banners_style_controls();\n\t\t$this->register_product_tabs_style_controls();\n\t\t$this->register_side_products_style_controls();\n\t\t$this->register_lazy_loading_style_controls();\n\n\t}",
"protected function _register_controls()\n {\n $this->tab_content();\n $this->tab_style();\n }",
"protected function _register_controls()\n {\n\t\t//Display Text\n\t\t$this->start_controls_section(\n\t\t\t'_section_breadcrumbs_display',\n\t\t\t[\n\t\t\t\t'label' => __('Display Text', 'happyden'),\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'home',\n\t\t\t[\n\t\t\t\t'label' => __( 'Homepage', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'Home', 'happyden' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'page_title',\n\t\t\t[\n\t\t\t\t'label' => __( 'Pages', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'Pages', 'happyden' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'search',\n\t\t\t[\n\t\t\t\t'label' => __( 'Search', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'Search results for:', 'happyden' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'error_404',\n\t\t\t[\n\t\t\t\t'label' => __( 'Error 404', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( '404 Not Found', 'happyden' ),\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_breadcrumbs',\n\t\t\t[\n\t\t\t\t'label' => __('Breadcrumbs', 'happyden'),\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'home_icon',\n\t\t\t[\n\t\t\t\t'label'\t\t\t\t\t=> __( 'Home Icon', 'happyden' ),\n\t\t\t\t'label_block'\t\t\t=> false,\n\t\t\t\t'type'\t\t\t\t\t=> Controls_Manager::ICONS,\n\t\t\t\t'default'\t\t\t\t=> [\n\t\t\t\t\t'value'\t\t=> 'fas fa-home',\n\t\t\t\t\t'library'\t=> 'fa-solid',\n\t\t\t\t],\n\t\t\t\t'skin' => 'inline',\n\t\t\t\t'exclude_inline_options' => [ 'svg' ],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'separator_type',\n\t\t\t[\n\t\t\t\t'label' => __( 'Separator Type', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'icon',\n\t\t\t\t'options' => [\n\t\t\t\t\t'text' => __( 'Text', 'happyden' ),\n\t\t\t\t\t'icon' => __( 'Icon', 'happyden' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'separator_text',\n\t\t\t[\n\t\t\t\t'label' => __( 'Separator', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( '>', 'happyden' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'separator_type' => 'text'\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'separator_icon',\n\t\t\t[\n\t\t\t\t'label'\t\t\t\t\t=> __( 'Separator', 'happyden' ),\n\t\t\t\t'label_block'\t\t\t=> false,\n\t\t\t\t'type'\t\t\t\t\t=> Controls_Manager::ICONS,\n\t\t\t\t'default'\t\t\t\t=> [\n\t\t\t\t\t'value'\t\t=> 'fas fa-angle-right',\n\t\t\t\t\t'library'\t=> 'fa-solid',\n\t\t\t\t],\n\t\t\t\t'skin' => 'inline',\n\t\t\t\t'exclude_inline_options' => [ 'svg' ],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'separator_type' => 'icon'\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'show_on_front',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show on front page', 'happyden' ),\n\t\t\t\t'type' => 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'show_title',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show last item', 'happyden' ),\n\t\t\t\t'type' => 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_responsive_control(\n\t\t\t'align',\n\t\t\t[\n\t\t\t\t'label' => __( 'Alignment', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'default' => '',\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'happyden' ),\n\t\t\t\t\t\t'icon' => 'eicon-h-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'happyden' ),\n\t\t\t\t\t\t'icon' => 'eicon-h-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'happyden' ),\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'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs' => 'text-align: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t\n\t\t//Breadcrumbs Style\n\t\t$this->start_controls_section(\n\t\t\t'_section_breadcrumbs_style',\n\t\t\t[\n\t\t\t\t'label' => __('Breadcrumbs', 'happyden'),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\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' => 'breadcrumbs_background',\n\t\t\t\t'label' => __( 'Background', 'happyden' ),\n\t\t\t\t'types' => [ 'classic', 'gradient' ],\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs',\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' => 'breadcrumbs_border',\n\t\t\t\t'label' => __( 'Border', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'breadcrumbs_border_radius',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Radius', 'happyden' ),\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}} .happyden-breadcrumbs' => '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' => 'breadcrumbs_shadow',\n\t\t\t\t'label' => __( 'Box Shadow', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'breadcrumbs_margin',\n\t\t\t[\n\t\t\t\t'label' => __( 'Margin', 'happyden' ),\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}} .happyden-breadcrumbs' => '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'breadcrumbs_padding',\n\t\t\t[\n\t\t\t\t'label' => __( 'Padding', 'happyden' ),\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}} .happyden-breadcrumbs' => '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->end_controls_section();\n\n\t\t//Common Style\n\t\t$this->start_controls_section(\n\t\t\t'_section_common_style',\n\t\t\t[\n\t\t\t\t'label' => __('Common', 'happyden'),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'common_spacing',\n\t\t\t[\n\t\t\t\t'label' => __( 'Spacing', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' \t=> [\n\t\t\t\t\t\t'max' => 50,\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-breadcrumbs li' => 'margin-right: {{SIZE}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li:last-child' => 'margin-right: 0;',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->start_controls_tabs( 'tabs_common_style' );\n\n\t\t$this->start_controls_tab(\n\t\t\t'tab_common_normal',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'happyden' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'common_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text' => '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_Background::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'common_background_color',\n\t\t\t\t'label' => __( 'Background', 'happyden' ),\n\t\t\t\t'types' => [ 'classic', 'gradient' ],\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text',\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' => 'common_typography',\n\t\t\t\t'label' => __( 'Typography', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text',\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' => 'common_border',\n\t\t\t\t'label' => __( 'Border', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'common_border_radius',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Radius', 'happyden' ),\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}} .happyden-breadcrumbs li.happyden-breadcrumbs-item a' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text' => '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->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'tab_common_hover',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'happyden' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'common_color_hover',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text:hover' => '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_Background::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'common_background_color_hover',\n\t\t\t\t'label' => __( 'Background', 'happyden' ),\n\t\t\t\t'types' => [ 'classic', 'gradient' ],\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text:hover',\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' => 'common_typography_hover',\n\t\t\t\t'label' => __( 'Typography', 'happyden' ),\n\t\t\t\t'exclude' => [\n\t\t\t\t\t'font_family',\n\t\t\t\t\t'font_size',\n\t\t\t\t\t'text_transform',\n\t\t\t\t\t'font_style',\n\t\t\t\t\t'line_height',\n\t\t\t\t\t'letter_spacing',\n\t\t\t\t],\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text:hover',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'common_border_color_hover',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Color', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text:hover' => 'border-color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_tab();\n\t\t$this->end_controls_tabs();\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' => 'common_shadow',\n\t\t\t\t'label' => __( 'Box Shadow', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'common_padding',\n\t\t\t[\n\t\t\t\t'label' => __( 'Padding', 'happyden' ),\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}} .happyden-breadcrumbs li span.happyden-breadcrumbs-text' => '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->end_controls_section();\n\n\t\t//Home Style\n\t\t$this->start_controls_section(\n\t\t\t'_section_home_style',\n\t\t\t[\n\t\t\t\t'label' => __('Home', 'happyden'),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t$this->start_controls_tabs( 'tabs_home_style' );\n\n\t\t$this->start_controls_tab(\n\t\t\t'tab_home_normal',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'happyden' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'home_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text' => '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'home_icon_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Home Icon Color', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text .happyden-breadcrumbs-home-icon' => '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_Background::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'home_background_color',\n\t\t\t\t'label' => __( 'Background', 'happyden' ),\n\t\t\t\t'types' => [ 'classic', 'gradient' ],\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text',\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' => 'home_typography',\n\t\t\t\t'label' => __( 'Typography', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text',\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' => 'home_border',\n\t\t\t\t'label' => __( 'Border', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'home_border_radius',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Radius', 'happyden' ),\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}} .happyden-breadcrumbs li.happyden-breadcrumbs-start a' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text' => '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->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'tab_home_hover',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'happyden' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'home_color_hover',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'happyden' ),\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}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text:hover' => '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'home_icon_color_hover',\n\t\t\t[\n\t\t\t\t'label' => __( 'Home Icon Color', 'happyden' ),\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}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text:hover .happyden-breadcrumbs-home-icon' => 'color: {{VALUE}}',\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text .happyden-breadcrumbs-home-icon' => '-webkit-transition: all .4s;transition: all .4s;',\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_Background::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'home_background_color_hover',\n\t\t\t\t'label' => __( 'Background', 'happyden' ),\n\t\t\t\t'types' => [ 'classic', 'gradient' ],\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text:hover',\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' => 'home_typography_hover',\n\t\t\t\t'label' => __( 'Typography', 'happyden' ),\n\t\t\t\t'exclude' => [\n\t\t\t\t\t'font_family',\n\t\t\t\t\t'font_size',\n\t\t\t\t\t'text_transform',\n\t\t\t\t\t'font_style',\n\t\t\t\t\t'line_height',\n\t\t\t\t\t'letter_spacing',\n\t\t\t\t],\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text:hover',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'home_border_color_hover',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Color', 'happyden' ),\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}} .happyden-breadcrumbs li.happyden-breadcrumbs-start span.happyden-breadcrumbs-text:hover' => 'border-color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_tab();\n\t\t$this->end_controls_tabs();\n\n\t\t$this->add_control(\n\t\t\t'home_spacing',\n\t\t\t[\n\t\t\t\t'label' => __( 'Home Icon Spacing', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' \t=> [\n\t\t\t\t\t\t'max' => 50,\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-breadcrumbs li span.happyden-breadcrumbs-home-icon' => 'margin-right: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t//Separator Style\n\t\t$this->start_controls_section(\n\t\t\t'_section_separator_style',\n\t\t\t[\n\t\t\t\t'label' => __('Separator', 'happyden'),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'separator_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-icon' => 'color: {{VALUE}}',\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-text' => '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_Background::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'separator_background_color',\n\t\t\t\t'label' => __( 'Background', 'happyden' ),\n\t\t\t\t'types' => [ 'classic', 'gradient' ],\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-icon, {{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-text',\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' => 'separator_typography',\n\t\t\t\t'label' => __( 'Typography', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-icon, {{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-text',\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' => 'separator_border',\n\t\t\t\t'label' => __( 'Border', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-icon, {{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-icon',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'separator_border_radius',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Radius', 'happyden' ),\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}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-icon' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-text' => '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_responsive_control(\n\t\t\t'separator_padding',\n\t\t\t[\n\t\t\t\t'label' => __( 'Padding', 'happyden' ),\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}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-icon' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-separator span.happyden-breadcrumbs-separator-text' => '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->end_controls_section();\n\n\t\t//Current Style\n\t\t$this->start_controls_section(\n\t\t\t'_section_current_style',\n\t\t\t[\n\t\t\t\t'label' => __('Current', 'happyden'),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'current_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-item.happyden-breadcrumbs-end span.happyden-breadcrumbs-text' => '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_Background::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'current_background_color',\n\t\t\t\t'label' => __( 'Background', 'happyden' ),\n\t\t\t\t'types' => [ 'classic', 'gradient' ],\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-item.happyden-breadcrumbs-end span.happyden-breadcrumbs-text',\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' => 'current_typography',\n\t\t\t\t'label' => __( 'Typography', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-item.happyden-breadcrumbs-end span.happyden-breadcrumbs-text',\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' => 'current_border',\n\t\t\t\t'label' => __( 'Border', 'happyden' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .happyden-breadcrumbs li.happyden-breadcrumbs-item.happyden-breadcrumbs-end span.happyden-breadcrumbs-text',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'current_border_radius',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Radius', 'happyden' ),\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}} .happyden-breadcrumbs li.happyden-breadcrumbs-item.happyden-breadcrumbs-end span.happyden-breadcrumbs-text' => '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->end_controls_section();\n\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', 'atl-extension' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\n\t\t\n\n\t\t$this->add_control(\n\t\t\t'about_intro_sub_title', [\n\t\t\t\t'label' => __( 'About Intro Sub Title', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'About Us' , 'atl-extension' ),\n\t\t\t\t'label_block' => true,\n 'separator'=> 'before',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'about_intro_title', [\n\t\t\t\t'label' => __( 'About Intro Title', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'Business Agency That Helps You Succeed' , 'atl-extension' ),\n\t\t\t\t'label_block' => true,\n 'separator'=> 'before',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'about_intro_desc', [\n\t\t\t\t'label' => __( 'About Intro Description', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXTAREA,\n\t\t\t\t'default' => __( 'lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et.' , 'atl-extension' ),\n\t\t\t\t'label_block' => true,\n 'separator'=> 'before',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'about_intro_image', [\n 'label' => __( 'About Intro Image', 'atl-extension' ),\n 'type' => \\Elementor\\Controls_Manager::MEDIA,\n 'label_block' => true,\n 'separator'=> 'before',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'btn_text',\n\t\t\t[\n\t\t\t\t'label' => __( 'Button Text', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n 'label_block' => true,\n 'separator'=> 'before',\n\t\t\t\t'default' => 'Read More ',\n\t\t\t]\n );\n \n // Button Link\n\t\t$this->add_control(\n\t\t\t'btn_link',\n\t\t\t[\n\t\t\t\t'label' => __( 'Button Link', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'Write Button Linke Here', 'atl-extension' ),\n\t\t\t]\n );\n\t\n\t\t$repeater = new \\Elementor\\Repeater();\n\n // about_intro Options\n $this->add_control(\n 'about_intro_list_heading',\n [\n 'label' => __( 'Left About Intro', 'atl-extension' ),\n 'type' => \\Elementor\\Controls_Manager::HEADING,\n 'separator'=> 'before',\n ]\n );\n\n\n\t\n\n\t\t$repeater->add_control(\n\t\t\t'about_intro_list_icon',\n\t\t\t[\n\t\t\t\t'label' => __( 'Icon', 'text-domain' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::ICONS,\n\t\t\t\t'default' => [\n\t\t\t\t\t'value' => 'fas fa-circle',\n\t\t\t\t\t'library' => 'solid',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'about_intro_list_title', [\n\t\t\t\t'label' => __( 'About Intro Title', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXTAREA,\n\t\t\t\t'default' => __( 'We’re the leaders in web and App based.' , 'atl-extension' ),\n\t\t\t\t'label_block' => true,\n\t\t\t]\n\t\t);\n\n\t\n\n\t\t$this->add_control(\n\t\t\t'about_intro_lists',\n\t\t\t[\n\t\t\t\t'label' => __( 'About Intro Lists', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::REPEATER,\n\t\t\t\t'fields' => $repeater->get_controls(),\n\t\t\t\t'title_field' => '{{{ about_intro_list_title }}}',\n\t\t\t]\n\t\t);\n \n\n\t\t$this->end_controls_section();\n\n\n\t\t// About Intro Style Tab\n $this->start_controls_section(\n\t\t\t'about_intro_intro_style_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'About Intro Heading', 'atl-extension' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t]\n );\n\n\t\n \n\n\n\n\n\n\t// About Intro Icon\n\t$this->add_control(\n\t\t'about_intro_intro_sub_title_heading',\n\t\t[\n\t\t\t'label' => __( 'Sub Title', 'atl-extension' ),\n\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t'separator' => 'before'\n\t\t]\n\t);\n\n\t // About Intro Title Color\n\t $this->add_control(\n\t\t'about_intro_intro_sub_title_color',\n\t\t[\n\t\t\t'label' => __( 'Color', 'atl-extension' ),\n\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t'scheme' => [\n\t\t\t\t'type' => \\Elementor\\Core\\Schemes\\Color::get_type(),\n\t\t\t\t'value' => \\Elementor\\Core\\Schemes\\Color::COLOR_1,\n\t\t\t],\n\t\t\t'default' => '#000',\n\t\t\t'selectors' => [\n\t\t\t\t'{{WRAPPER}} .aboutIntro .display-2--start' => 'color: {{VALUE}}',\n\t\t\t],\n\t\t]\n\t);\n\t\n\t// About Intro Title Typography \n\t$this->add_group_control(\n\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t[\n\t\t\t'name' => 'about_intro_intro_sub_title_typography',\n\t\t\t'label' => __( 'Typography', 'atl-extension' ),\n\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_1,\n\t\t\t'selector' => '{{WRAPPER}} .aboutIntro .display-2--start',\n\t\t]\n\t);\n\n\n\n\n\t\t// About Intro Icon\n\t\t$this->add_control(\n\t\t\t'about_intro_intro_title_heading',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title', 'atl-extension' ),\n 'type' => \\Elementor\\Controls_Manager::HEADING,\n 'separator' => 'before'\n\t\t\t]\n\t\t);\n\n // About Intro Title Color\n $this->add_control(\n\t\t\t'about_intro_intro_title_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Core\\Schemes\\Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Core\\Schemes\\Color::COLOR_1,\n ],\n 'default' => '#1714e0',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .aboutIntro .display-2--intro ' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n );\n \n // About Intro Title Typography \n $this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'about_intro_intro_title_typography',\n\t\t\t\t'label' => __( 'Typography', 'atl-extension' ),\n\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .aboutIntro .display-2--intro ',\n\t\t\t]\n );\n\n\n\n\n\n\n\n\n\t\t// About Intro Icon\n\t\t$this->add_control(\n\t\t\t'about_intro_intro_desc_heading',\n\t\t\t[\n\t\t\t\t'label' => __( 'Description', 'atl-extension' ),\n 'type' => \\Elementor\\Controls_Manager::HEADING,\n 'separator' => 'before'\n\t\t\t]\n\t\t);\n\n // About Intro Title Color\n $this->add_control(\n\t\t\t'about_intro_intro_desc_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Core\\Schemes\\Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Core\\Schemes\\Color::COLOR_1,\n ],\n 'default' => '#000',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .aboutIntro .about-sub-title ' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n );\n \n // About Intro Title Typography \n $this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'about_intro_intro_desc_typography',\n\t\t\t\t'label' => __( 'Typography', 'atl-extension' ),\n\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .aboutIntro .about-sub-title ',\n\t\t\t]\n );\n\n\n\n\t\t\n $this->end_controls_section();\n\n\n\n\n\n\n\n\t\t// About Intro Style Tab\n $this->start_controls_section(\n\t\t\t'about_intro_style_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'About Intro', 'atl-extension' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t]\n );\n\n\t\n \n\n\t\t// icon Options\n\t\t$this->add_control(\n\t\t\t'about_intro_icon_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Icon', 'atl-extension' ),\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// icon Background Color\n\t\t$this->add_control(\n\t\t\t'about_intro_icon_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Core\\Schemes\\Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Core\\Schemes\\Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#1714e0',\n\t\t\t\t'separator' => 'after',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .aboutIntro .address i' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\n\n\n\n\n\n\n\t\t// About Intro Title\n\t\t$this->add_control(\n\t\t\t'about_intro_title_heading',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title', 'atl-extension' ),\n 'type' => \\Elementor\\Controls_Manager::HEADING,\n 'separator' => 'before'\n\t\t\t]\n\t\t);\n\n // About Intro Title Color\n $this->add_control(\n\t\t\t'about_intro_title_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Core\\Schemes\\Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Core\\Schemes\\Color::COLOR_1,\n ],\n 'default' => '#000',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .aboutIntro .address p' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n );\n \n // About Intro Title Typography \n $this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'about_intro_title_typography',\n\t\t\t\t'label' => __( 'Typography', 'atl-extension' ),\n\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .aboutIntro .address p',\n\t\t\t]\n );\n\n\n\n\n $this->end_controls_section();\n\t}",
"protected function _register_controls() {\n \n\n //For General Section\n $this->content_general_controls();\n\n \n //For Design Section Style Tab\n $this->style_design_controls();\n \n //For Typography Section Style Tab\n //$this->style_typography_controls();\n\n \n }",
"protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'section_layout',\n\t\t\t[\n\t\t\t\t'label' => __( 'Layout', 'thegem' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'thegem_elementor_preset',\n [\n 'label' => __( 'Skin', 'thegem' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => $this->get_presets_options(),\n 'default' => $this->set_default_presets_options(),\n 'frontend_available' => true,\n 'render_type' => 'none',\n ]\n );\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'thegem' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'content_choose_image',\n [\n 'label' => __( 'Choose image', 'thegem' ),\n 'type' => Controls_Manager::MEDIA,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n ]\n );\n\n $this->add_control(\n 'content_image_link_to',\n [\n 'label' => __( 'Link', 'thegem' ),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'none',\n 'options' => [\n 'none' => __( 'None', 'thegem' ),\n 'file' => __( 'Media File', 'thegem' ),\n 'custom' => __( 'Custom URL', 'thegem' ),\n ],\n ]\n );\n\n $this->add_control(\n 'link',\n [\n 'label' => __( 'Link', 'thegem' ),\n 'type' => Controls_Manager::URL,\n 'dynamic' => [\n 'active' => true,\n ],\n 'placeholder' => __( 'https://your-link.com', 'thegem' ),\n 'condition' => [\n 'content_image_link_to' => 'custom',\n ],\n 'show_label' => false,\n ]\n );\n\n $this->add_control(\n 'open_lightbox',\n [\n 'label' => __( 'Lightbox', 'thegem' ),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'default',\n 'options' => [\n 'default' => __( 'Default', 'thegem' ),\n 'yes' => __( 'Yes', 'thegem' ),\n 'no' => __( 'No', 'thegem' ),\n ],\n 'condition' => [\n 'content_image_link_to' => 'file',\n ],\n ]\n );\n\n $this->add_control(\n 'view',\n [\n 'label' => __( 'View', 'thegem' ),\n 'type' => Controls_Manager::HIDDEN,\n 'default' => 'traditional',\n ]\n );\n\n\t\t$this->end_controls_section();\n\n $this->start_controls_section(\n 'section_options',\n [\n 'label' => __( 'Options', 'thegem' ),\n ]\n );\n\n $this->add_control(\n 'options_lazy_loading',\n [\n 'label' => __( 'Lazy Loading', 'thegem' ),\n 'type' => Controls_Manager::SWITCHER,\n 'label_on' => __( 'On', 'thegem' ),\n 'label_off' => __( 'Off', 'thegem' ),\n 'return_value' => 'yes',\n 'default' => 'no',\n ]\n );\n\n $this->end_controls_section();\n\n\t\t$this->add_styles_controls( $this );\n\n\t}",
"protected function _register_controls()\n {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => __('Content', 'webt'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'taxonomy',\n [\n 'label' => __('Taxonomy', 'webt'),\n 'type' => Controls_Manager::SELECT,\n 'options' => get_taxonomies(),\n 'default' => '',\n ]\n );\n\n $this->add_control(\n 'parent_term_id',\n [\n 'label' => __('Term id', 'webt'),\n 'type' => Controls_Manager::NUMBER,\n ]\n );\n\n $this->add_control(\n 'show_term_url',\n [\n 'label' => __('Term Link', 'webt'),\n 'type' => Controls_Manager::SWITCHER,\n 'label_on' => __('Show', 'webt'),\n 'label_off' => __('Hide', 'webt'),\n 'return_value' => 'yes',\n 'default' => 'yes',\n ]\n );\n\n $this->add_control(\n 'hide_empty_term',\n [\n 'label' => __('Hide Empty', 'webt'),\n 'type' => Controls_Manager::SWITCHER,\n 'label_on' => __('Show', 'webt'),\n 'label_off' => __('Hide', 'webt'),\n 'return_value' => true,\n 'default' => true,\n ]\n );\n\n $this->end_controls_section();\n\n /**\n * Style Section\n */\n\n // Text\n $this->start_controls_section(\n 'term_style',\n array(\n 'label' => __('Term', 'webt'),\n 'tab' => Controls_Manager::TAB_STYLE,\n )\n );\n\n\n $this->start_controls_tabs('term_style_tabs');\n\n $this->start_controls_tab(\n 'term_tab_normal',\n [\n 'label' => __('Normal', 'webt'),\n ]\n );\n\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'term_typography',\n 'label' => __('Typography', 'webt'),\n 'selector' => '{{WRAPPER}} .term-item-container .term-item ',\n ]\n );\n\n $this->add_control(\n 'term_color',\n [\n 'label' => __('Color', 'webt'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .term-item-container .term-item' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n // Hover Style\n $this->start_controls_tab(\n 'term_tab_hover',\n [\n 'label' => __('Hover', 'webt'),\n ]\n );\n\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'term_typography_hover',\n 'label' => __('Typography', 'webt'),\n 'selector' => '{{WRAPPER}} .term-item-container .term-item:hover ',\n ]\n );\n\n $this->add_control(\n 'term_hover_color',\n [\n 'label' => __('Hover Color', 'webt'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .term-item-container .term-item:hover' => 'color: {{VALUE}} ',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->end_controls_tabs();\n\n $this->add_responsive_control(\n 'term_align',\n [\n 'label' => __('Alignment', 'webt'),\n 'type' => Controls_Manager::CHOOSE,\n 'options' => [\n 'left' => [\n 'title' => __('Left', 'webt'),\n 'icon' => 'fa fa-align-left',\n ],\n 'center' => [\n 'title' => __('Center', 'webt'),\n 'icon' => 'fa fa-align-center',\n ],\n 'right' => [\n 'title' => __('Right', 'webt'),\n 'icon' => 'fa fa-align-right',\n ],\n 'justify' => [\n 'title' => __('Justified', 'webt'),\n 'icon' => 'fa fa-align-justify',\n ],\n ],\n 'prefix_class' => 'elementor%s-align-',\n 'default' => 'left',\n 'selectors' => [\n '{{WRAPPER}} .term-item-container .term-item' => 'text-align: {{VALUE}}',\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'general_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'General', 'dreamit-elementor-extension' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'select_style',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Select Style', 'dreamit-elementor-extension' ),\n\t\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t\t'options' => [\n\t\t\t\t\t\t'one' => __( 'One', 'dreamit-elementor-extension' ),\n\t\t\t\t\t\t'two' => __( 'Two', 'dreamit-elementor-extension' ),\n\t\t\t\t\t\t'three' => __( 'Three', 'dreamit-elementor-extension' ),\n\t\t\t\t\t\t'four' => __( 'Four', 'dreamit-elementor-extension' ),\n\t\t\t\t\t],\n\t\t\t\t\t'default' => 'one',\n\t\t\t\t\t\n\t\t\t\t]\n\t\t\t);\n\t\t\t$this->add_control(\n\t\t\t\t'overlay_color',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Overlay Color', 'dreamit-elementor-extension' ),\n\t\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '',\n\t\t\t\t\t'selectors' => [\n\t\t\t\t\t\t'{{WRAPPER}} .style-two .case-study-thumb:before' => 'background: {{VALUE}};',\n\t\t\t\t\t],\n\t\t\t\t]\n\t\t\t);\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'title_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title', 'dreamit-elementor-extension' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t\t$this->start_controls_tabs(\n\t\t\t\t'title_style_tabs'\n\t\t\t);\n\t\t\t\t$this->start_controls_tab(\n\t\t\t\t\t'title_style_normal_tab',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Normal', 'dreamit-elementor-extension' ),\n\t\t\t\t\t]\n\t\t\t\t);\n\t\t\t\t\n\t\t\t\t\t$this->add_control(\n\t\t\t\t\t\t'title_color',\n\t\t\t\t\t\t[\n\t\t\t\t\t\t\t'label' => __( 'Color', 'dreamit-elementor-extension' ),\n\t\t\t\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t\t\t\t'default' => '',\n\t\t\t\t\t\t\t'selectors' => [\n\t\t\t\t\t\t\t\t'{{WRAPPER}} .em-cases-study-title h2 a' => 'color: {{VALUE}};',\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\t$this->end_controls_tab();\n\t\t\t\t\n\t\t\t\t$this->start_controls_tab(\n\t\t\t\t\t'title_style_hover_tab',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Hover', 'dreamit-elementor-extension' ),\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t\t$this->add_control(\n\t\t\t\t\t\t'hover_title_color',\n\t\t\t\t\t\t[\n\t\t\t\t\t\t\t'label' => __( 'Color', 'dreamit-elementor-extension' ),\n\t\t\t\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t\t\t\t'default' => '',\n\t\t\t\t\t\t\t'selectors' => [\n\t\t\t\t\t\t\t\t'{{WRAPPER}} .em-cases-study-title h2 a:hover' => 'color: {{VALUE}};',\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\t$this->end_controls_tab();\n\t\t\t\t\n\t\t\t$this->end_controls_tabs();\n\n\t\t\t$this->add_responsive_control(\n\t\t\t\t'title_margin',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Margin', 'dreamit-elementor-extension' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::DIMENSIONS,\n\t\t\t\t\t'size_units' => [ 'px', 'em', '%' ],\n\t\t\t\t\t'selectors' => [\n\t\t\t\t\t\t'{{WRAPPER}} .em-cases-study-title h2' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t\t],\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t]\n\t\t\t);\n\n\t $this->add_group_control(\n\t\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t\t[\n\t\t\t\t\t'name' => 'title_typography',\n\t\t\t\t\t'label' => esc_html__( 'Typography', 'dreamit-elementor-extension' ),\n\t\t\t\t\t'selector' => \n\t '{{WRAPPER}} .em-cases-study-title h2 a',\n\t\t\t\t]\n\t\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'category_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Category', 'dreamit-elementor-extension' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'category_color',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Color', 'dreamit-elementor-extension' ),\n\t\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '',\n\t\t\t\t\t'selectors' => [\n\t\t\t\t\t\t'{{WRAPPER}} .case_category span' => 'color: {{VALUE}};',\n\t\t\t\t\t],\n\t\t\t\t]\n\t\t\t);\n\n\t $this->add_group_control(\n\t\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t\t[\n\t\t\t\t\t'name' => 'category_typography',\n\t\t\t\t\t'label' => esc_html__( 'Typography', 'dreamit-elementor-extension' ),\n\t\t\t\t\t'selector' => \n\t '{{WRAPPER}} .case_category span',\n\t\t\t\t]\n\t\t\t);\n\n\t\t$this->end_controls_section();\n\t}",
"protected function _register_controls()\n {\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => __('Content', 'jimmyhowedotcom'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'select_superglobal',\n [\n 'label' => __('Superglobal', 'jimmyhowedotcom'),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n '$_SERVER' => __('$_SERVER', 'jimmyhowedotcom'),\n '$_REQUEST' => __('$_REQUEST', 'jimmyhowedotcom'),\n '$_POST' => __('$_POST', 'jimmyhowedotcom'),\n '$_GET' => __('$_GET', 'jimmyhowedotcom'),\n '$_FILES' => __('$_FILES', 'jimmyhowedotcom'),\n '$_ENV' => __('$_ENV', 'jimmyhowedotcom'),\n '$_COOKIE' => __('$_COOKIE', 'jimmyhowedotcom'),\n '$_SESSION' => __('$_SESSION', 'jimmyhowedotcom'),\n ],\n 'default' => 'globals',\n ]\n );\n\n $this->end_controls_section();\n }",
"public function registerControlsUI(){\n \n\t}",
"protected function _register_controls(){\n //Name of the content section\n $this->start_controls_section(\n 'client',\n array(\n 'label' => __('Client Slider', 'reveal'),\n 'tab' => Controls_Manager::TAB_CONTENT\n )\n );\n\n $this->add_control(\n 'gallery', [\n 'label' => __( 'Brand Logo Images', 'reveal' ),\n 'type' => Controls_Manager::GALLERY,\n 'label_block' => true,\n 'default' => []\n ]\n );\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 }",
"protected function _register_controls() {\n\n $allowed_html = array(\n 'a' => array(\n 'href' => array(),\n 'title' => array()\n ),\n 'br' => array(),\n 'em' => array(),\n 'strong' => array(),\n );\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Properties', 'houzez-theme-functionality' ),\n 'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'posts_limit',\n [\n 'label' => esc_html__('Number of properties', 'houzez-theme-functionality'),\n 'type' => \\Elementor\\Controls_Manager::NUMBER,\n 'min' => 1,\n 'max' => 5000,\n 'step' => 1,\n 'default' => 9,\n ]\n );\n\n $this->add_control(\n 'offset',\n [\n 'label' => 'Offset',\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'description' => '',\n ]\n );\n\n // Property taxonomies controls\n $prop_taxonomies = get_object_taxonomies( 'property', 'objects' );\n\n if ( ! empty( $prop_taxonomies ) && ! is_wp_error( $prop_taxonomies ) ) {\n foreach ( $prop_taxonomies as $single_tax ) {\n\n $options_array = array();\n $terms = get_terms( $single_tax->name );\n\n if ( ! empty( $terms ) && ! is_wp_error( $terms ) ) {\n foreach ( $terms as $term ) {\n $options_array[ $term->slug ] = $term->name;\n }\n }\n\n $this->add_control(\n $single_tax->name,\n [\n 'label' => $single_tax->label,\n 'type' => \\Elementor\\Controls_Manager::SELECT2,\n 'multiple' => true,\n 'label_block' => true,\n 'options' => $options_array,\n ]\n );\n }\n }\n\n $this->add_control(\n 'featured_prop',\n [\n 'label' => esc_html__( 'Featured Properties', 'houzez-theme-functionality' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n \"description\" => esc_html__(\"You can make a property featured by clicking featured properties checkbox while add/edit property\", \"houzez-theme-functionality\"),\n 'label_on' => esc_html__( 'Yes', 'houzez-theme-functionality' ),\n 'label_off' => esc_html__( 'No', 'houzez-theme-functionality' ),\n 'return_value' => 'yes',\n 'default' => 'no',\n ]\n );\n\n $this->add_responsive_control(\n 'map_height',\n [\n 'label' => esc_html__( 'Map Height (px)', 'houzez-theme-functionality' ),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n ],\n 'devices' => [ 'desktop', 'tablet', 'mobile' ],\n 'desktop_default' => [\n 'size' => 600,\n 'unit' => 'px',\n ],\n 'tablet_default' => [\n 'size' => '',\n 'unit' => 'px',\n ],\n 'mobile_default' => [\n 'size' => '',\n 'unit' => 'px',\n ],\n 'selectors' => [\n '{{WRAPPER}} .h-properties-map-for-elementor' => 'height: {{SIZE}}{{UNIT}};',\n\n ],\n ]\n );\n\n \n $this->end_controls_section();\n\n $this->start_controls_section(\n 'map_options_section',\n [\n 'label' => esc_html__( 'Map Options', 'houzez-theme-functionality' ),\n 'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'mapbox_api_key',\n [\n 'label' => esc_html__('MapBox API Key', 'houzez-theme-functionality'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'description' => __( 'Please enter the Mapbox API key, you can get from <a target=\"_blank\" href=\"https://account.mapbox.com/\">here</a>.', 'houzez' ),\n ]\n );\n\n\n $this->add_control(\n 'mapCluster',\n [\n 'label' => esc_html__( 'Map Cluster', 'houzez-theme-functionality' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n \"description\" => '',\n 'label_on' => esc_html__( 'Yes', 'houzez-theme-functionality' ),\n 'label_off' => esc_html__( 'No', 'houzez-theme-functionality' ),\n 'return_value' => 'yes',\n 'default' => 'yes',\n ]\n );\n\n $this->add_control(\n 'zoomControl',\n [\n 'label' => esc_html__( 'Zoom Control', 'houzez-theme-functionality' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n \"description\" => '',\n 'label_on' => esc_html__( 'Yes', 'houzez-theme-functionality' ),\n 'label_off' => esc_html__( 'No', 'houzez-theme-functionality' ),\n 'return_value' => 'yes',\n 'default' => 'yes',\n ]\n );\n \n $this->end_controls_section();\n\n\n\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', 'atl-extension' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\n // Sub Heading\n\t\t$this->add_control(\n\t\t\t'main_sub_heading',\n\t\t\t[\n\t\t\t\t'label' => __( 'Sub Heading', 'atl-extension' ),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'label_block' => true,\n\t\t\t\t'placeholder' => __( 'Write Sub Heading Here', 'atl-extension' ),\n\t\t\t\t'default' => 'Our Featured Services',\n\t\t\t]\n );\n \n // Heading\n\t\t$this->add_control(\n\t\t\t'main_heading',\n\t\t\t[\n\t\t\t\t'label' => __( 'Heading', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n 'label_block' => true,\n 'separator'=> 'before',\n\t\t\t\t'placeholder' => __( 'Write Heading Here', 'atl-extension' ),\n\t\t\t\t'default' => 'Bringing New IT Business Solutions And Ideas',\n\t\t\t\t]\n\t\t\t);\n\t\t\t\n\t\t\t// Description\n\t\t\t$this->add_control(\n\t\t\t\t'main_description',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Description', 'atl-extension' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXTAREA,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'separator'=> 'before',\n\t\t\t\t\t'placeholder' => __( 'Write Description Here', 'atl-extension' ),\n\t\t\t\t\t'default' => 'Lorem ipsum dolor sit amet, consectetuer </br> Lorem ipsum dolor sit amet.',\n\t\t\t]\n );\n\n\t\t$this->add_control(\n\t\t\t'main_heading_align',\n\t\t\t[\n\t\t\t\t'label' => __( 'Alignment', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\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', 'atl-extension' ),\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', 'atl-extension' ),\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', 'atl-extension' ),\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'default' => 'center',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title' => 'text-align: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n \n $this->end_controls_section();\n\n // Style Tab\n $this->start_controls_section(\n\t\t\t'style_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Styles', 'atl-extension' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t]\n );\n\n // Subtitle Options\n\t\t$this->add_control(\n\t\t\t'subtitle_heading',\n\t\t\t[\n\t\t\t\t'label' => __( 'Sub Title', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t]\n\t\t);\n\n // Sub Title Color\n $this->add_control(\n\t\t\t'subtitle_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Core\\Schemes\\Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Core\\Schemes\\Color::COLOR_1,\n ],\n 'default' => '#2F0E85',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title h5' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n );\n \n // Subtitle Typography \n $this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'subtitle_typography',\n\t\t\t\t'label' => __( 'Typography', 'atl-extension' ),\n\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .section-title h5',\n\t\t\t]\n );\n \n // Title Options\n\t\t$this->add_control(\n\t\t\t'title_heading',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title', 'atl-extension' ),\n 'type' => \\Elementor\\Controls_Manager::HEADING,\n 'separator' => 'before'\n\t\t\t]\n\t\t);\n\n // Title Color\n $this->add_control(\n\t\t\t'title_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Core\\Schemes\\Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Core\\Schemes\\Color::COLOR_1,\n ],\n 'default' => '#333',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title h3' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n );\n \n // Title Typography \n $this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'title_typography',\n\t\t\t\t'label' => __( 'Typography', 'atl-extension' ),\n\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .section-title h3',\n\t\t\t]\n );\n \n // Description Options\n\t\t$this->add_control(\n\t\t\t'desc_heading',\n\t\t\t[\n\t\t\t\t'label' => __( 'Description', 'atl-extension' ),\n 'type' => \\Elementor\\Controls_Manager::HEADING,\n 'separator' => 'before'\n\t\t\t]\n\t\t);\n\n // Description Color\n $this->add_control(\n\t\t\t'desc_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Core\\Schemes\\Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Core\\Schemes\\Color::COLOR_1,\n ],\n 'default' => '#333',\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 );\n \n // Description Typography \n $this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'desc_typography',\n\t\t\t\t'label' => __( 'Typography', 'atl-extension' ),\n\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .section-title p',\n\t\t\t]\n );\n\n\t\t// Border Options\n\t\t$this->add_control(\n\t\t\t'border_heading',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border', 'atl-extension' ),\n 'type' => \\Elementor\\Controls_Manager::HEADING,\n 'separator' => 'before'\n\t\t\t]\n\t\t);\n\n\t\t// Border 1 Background Color\n $this->add_control(\n\t\t\t'border1_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Core\\Schemes\\Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Core\\Schemes\\Color::COLOR_1,\n ],\n 'default' => '#777',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title h3::before' => 'background-color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n );\n\n\t\t// Border 2 Background Color\n $this->add_control(\n\t\t\t'border2_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Color', 'atl-extension' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Core\\Schemes\\Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Core\\Schemes\\Color::COLOR_1,\n ],\n 'default' => '#FF4A33',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title h3::after' => 'background-color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n );\n\n $this->end_controls_section();\n\t}",
"protected function _register_controls() {\n\t\t\t\t$this->start_controls_section(\n\t\t\t\t\t'section_sc_layouts_featured',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Layouts: Featured', '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'type',\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' => apply_filters('trx_addons_sc_type', array(\n\t\t\t\t\t\t\t\t'default' => esc_html__('Default', 'trx_addons'),\n\t\t\t\t\t\t\t), 'trx_sc_layouts_featured'),\n\t\t\t\t\t\t'default' => 'default'\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'height',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Height of the block', 'trx_addons' ),\n\t\t\t\t\t\t'description' => wp_kses_data( __(\"Specify height of this block. If empty - use default height\", 'trx_addons') ),\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SLIDER,\n\t\t\t\t\t\t'default' => [\n\t\t\t\t\t\t\t'size' => 0,\n\t\t\t\t\t\t\t'unit' => 'px'\n\t\t\t\t\t\t],\n\t\t\t\t\t\t'size_units' => ['px', 'em'],\n\t\t\t\t\t\t'range' => [\n\t\t\t\t\t\t\t'px' => [\n\t\t\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t\t\t'max' => 800\n\t\t\t\t\t\t\t],\n\t\t\t\t\t\t\t'em' => [\n\t\t\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t\t\t'max' => 50\n\t\t\t\t\t\t\t]\n\t\t\t\t\t\t],\n\t\t\t\t\t\t'selectors' => [\n\t\t\t\t\t\t\t'{{WRAPPER}} .sc_layouts_featured' => 'min-height: {{SIZE}}{{UNIT}};',\n\t\t\t\t\t\t]\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'align', \n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __(\"Content alignment\", '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_get_list_sc_aligns(true, false),\n\t\t\t\t\t\t'default' => 'inherit'\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'hide_on_frontpage',\n\t\t\t\t\t[\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'label' => __( 'Hide on Frontpage', 'trx_addons' ),\n\t\t\t\t\t\t'label_off' => __( 'Off', 'trx_addons' ),\n\t\t\t\t\t\t'label_on' => __( 'On', 'trx_addons' ),\n\t\t\t\t\t\t'return_value' => '1'\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->start_controls_section(\n\t\t\t'style_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Style', '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'category',\n\t\t\t[\n\t\t\t\t'label' => __( 'Category', 'plugin-domain' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'Default', 'plugin-domain' ),\n\t\t\t\t'placeholder' => __( 'Type your category here', 'plugin-domain' ),\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$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'phoenixdigi' ),\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', 'phoenixdigi' ),\n\t\t\t\t'type' => \\Elementor\\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' => __( 'Milestones', 'phoenixdigi' ),\n\t\t\t\t'placeholder' => __( 'Milestones', 'phoenixdigi' ),\n\t\t\t]\n\t\t);\n\n\t\t$repeater = new \\Elementor\\Repeater();\n\n\t\t$repeater->add_control(\n\t\t\t'text',\n\t\t\t[\n\t\t\t\t'label' => __( 'Text', 'phoenixdigi' ),\n\t\t\t\t'type' => \\Elementor\\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' => __( 'October 2018: Docker named a Leader in The Forrester New Wave™: Enterprise Container Platform Software Suites, Q4 2018 report', 'phoenixdigi' ),\n\t\t\t\t'placeholder' => __( 'October 2018: Docker named a Leader in The Forrester New Wave™: Enterprise Container Platform Software Suites, Q4 2018 report', 'phoenixdigi' ),\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'acquisition',\n\t\t\t[\n\t\t\t\t'label' => __( 'Acquisition', 'phoenixdigi' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_off' => __( 'No', 'phoenixdigi' ),\n\t\t\t\t'label_on' => __( 'Yes', 'phoenixdigi' ),\n\t\t\t\t'default' => 'no',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'items',\n\t\t\t[\n\t\t\t\t'label' => __( 'Items', 'phoenixdigi' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::REPEATER,\n\t\t\t\t'fields' => $repeater->get_controls(),\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t}",
"protected function _register_controls() {\n\t\t\t\t$this->start_controls_section(\n\t\t\t\t\t'section_sc_rating_posts',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Widget: Post by rating', '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'title',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Title', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t\t\t'placeholder' => __( \"Widget title\", 'trx_addons' ),\n\t\t\t\t\t\t'default' => ''\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'number',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Number posts to show', 'trx_addons' ),\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SLIDER,\n\t\t\t\t\t\t'default' => [\n\t\t\t\t\t\t\t'size' => 4,\n\t\t\t\t\t\t],\n\t\t\t\t\t\t'range' => [\n\t\t\t\t\t\t\t'px' => [\n\t\t\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t\t\t'max' => 12\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\t\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'post_type',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Post type', '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_get_list_reviews_posts_types(),\n\t\t\t\t\t\t'default' => 'post'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'details',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Details', 'elementor' ),\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t\t'separator' => 'before',\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'show_image',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( \"Show post's image\", 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'label_off' => __( 'Hide', 'trx_addons' ),\n\t\t\t\t\t\t'label_on' => __( 'Show', 'trx_addons' ),\n\t\t\t\t\t\t'default' => 1,\n\t\t\t\t\t\t'return_value' => '1'\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'show_author',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( \"Show post's author\", 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'label_off' => __( 'Hide', 'trx_addons' ),\n\t\t\t\t\t\t'label_on' => __( 'Show', 'trx_addons' ),\n\t\t\t\t\t\t'default' => 1,\n\t\t\t\t\t\t'return_value' => '1'\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'show_date',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( \"Show post's date\", 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'label_off' => __( 'Hide', 'trx_addons' ),\n\t\t\t\t\t\t'label_on' => __( 'Show', 'trx_addons' ),\n\t\t\t\t\t\t'default' => 1,\n\t\t\t\t\t\t'return_value' => '1'\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'show_counters',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( \"Show post's counters\", 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'label_off' => __( 'Hide', 'trx_addons' ),\n\t\t\t\t\t\t'label_on' => __( 'Show', 'trx_addons' ),\n\t\t\t\t\t\t'default' => 1,\n\t\t\t\t\t\t'return_value' => '1'\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'show_categories',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( \"Show post's categories\", 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'label_off' => __( 'Hide', 'trx_addons' ),\n\t\t\t\t\t\t'label_on' => __( 'Show', 'trx_addons' ),\n\t\t\t\t\t\t'default' => 1,\n\t\t\t\t\t\t'return_value' => '1'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->end_controls_section();\n\t\t\t}",
"protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'section_blog',\n\t\t\t[\n\t\t\t\t'label' => __( 'Blog', 'elementor' ),\n\t\t\t]\n\t\t);\n\n\t\tif ( \\Sydney_Toolbox::is_pro() ) {\n\t\t\t$this->add_control(\n\t\t\t\t'style',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Style', 'elementor' ),\n\t\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t\t'options' => [\n\t\t\t\t\t\t'style1' => __( 'Style 1', 'elementor' ),\n\t\t\t\t\t\t'style2' => __( 'Style 2', 'elementor' ),\n\t\t\t\t\t],\n\t\t\t\t\t'default' => 'style2',\n\t\t\t\t]\n\t\t\t);\t\n\t\t}\n\n\t\t$this->add_control(\n\t\t\t'number',\n\t\t\t[\n\t\t\t\t'label' => __( 'Number of posts', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::NUMBER,\n\t\t\t\t'default' => 4,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'category',\n\t\t\t[\n\t\t\t\t'label' \t=> __( 'Categories', 'elementor' ),\n\t\t\t\t'type' \t\t=> Controls_Manager::SELECT,\n 'options' \t=> $this->get_cats(),\n 'multiple' \t=> true,\t\t\t\t\n\t\t\t\t'default' \t=> 4,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'see_all_text',\n\t\t\t[\n\t\t\t\t'label' => __( 'See all button text', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'See all our news', 'elementor' ),\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'view',\n\t\t\t[\n\t\t\t\t'label' => __( 'View', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::HIDDEN,\n\t\t\t\t'default' => 'traditional',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\n\t\t//Post titles styles\n\t\t$this->start_controls_section(\n\t\t\t'section_post_title_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Post title', 'elementor' ),\n\t\t\t\t'tab' \t=> Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'name_color',\n\t\t\t[\n\t\t\t\t'label' \t=> __( 'Color', 'elementor' ),\n\t\t\t\t'type' \t\t=> Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .latest-news-wrapper.carousel h4 a' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .latest-news-wrapper.carousel.style2 .blog-post:hover h4 a' => 'color: #fff;',\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' \t\t=> 'post_title_typography',\n\t\t\t\t'selector' \t=> '{{WRAPPER}} .latest-news-wrapper.carousel h4',\n\t\t\t\t'scheme' \t=> Scheme_Typography::TYPOGRAPHY_3,\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t\t//End post titles styles\t\n\n\t\t//Post meta styles\n\t\t$this->start_controls_section(\n\t\t\t'section_post_meta_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Post meta', 'elementor' ),\n\t\t\t\t'tab' \t=> Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'post_meta_color',\n\t\t\t[\n\t\t\t\t'label' \t=> __( 'Meta text', 'elementor' ),\n\t\t\t\t'type' \t\t=> Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .latest-news-wrapper.carousel.style2 .meta-post' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .latest-news-wrapper.carousel.style2 .blog-post:hover .meta-post' => 'color: #fff;',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'post_meta_links_color',\n\t\t\t[\n\t\t\t\t'label' \t=> __( 'Meta links', 'elementor' ),\n\t\t\t\t'type' \t\t=> Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .latest-news-wrapper.carousel.style2 .meta-post a' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .latest-news-wrapper.carousel.style2 .blog-post:hover .meta-post a' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .latest-news-wrapper.carousel.style2 .meta-post a:hover' => 'color: #fff;',\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' \t\t=> 'post_meta_typography',\n\t\t\t\t'selector' \t=> '{{WRAPPER}} .latest-news-wrapper.carousel .meta-post',\n\t\t\t\t'scheme' \t=> Scheme_Typography::TYPOGRAPHY_3,\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t\t//End post meta styles\t\n\n\t\t//Content styles\n\t\t$this->start_controls_section(\n\t\t\t'section_content_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Post content', 'elementor' ),\n\t\t\t\t'tab' \t=> Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'content_color',\n\t\t\t[\n\t\t\t\t'label' \t=> __( 'Color', 'elementor' ),\n\t\t\t\t'type' \t\t=> Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .latest-news-wrapper.carousel .blog-post .entry-summary' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .latest-news-wrapper.carousel.style2 .blog-post:hover .entry-summary' => 'color: #fff;',\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' \t\t=> 'content_typography',\n\t\t\t\t'selector' \t=> '{{WRAPPER}} .latest-news-wrapper.carousel .blog-post .entry-summary',\n\t\t\t\t'scheme' \t=> Scheme_Typography::TYPOGRAPHY_3,\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t\t//End content styles\t\n\n\t\t//Content styles\n\t\t$this->start_controls_section(\n\t\t\t'section_carousel_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Carousel dots', 'elementor' ),\n\t\t\t\t'tab' \t=> Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'dots_color',\n\t\t\t[\n\t\t\t\t'label' \t=> __( 'Color', 'elementor' ),\n\t\t\t\t'type' \t\t=> Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .owl-theme .owl-controls .owl-page.active span,{{WRAPPER}} .owl-theme .owl-controls.clickable .owl-page:hover span' => 'background-color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .owl-theme .owl-controls .owl-page:hover span, .owl-theme .owl-controls .owl-page.active span' => 'border-color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t\t//End content styles\t\t\n\n\t\t//Button styles\n\t\t$this->start_controls_section(\n\t\t\t'section_button_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Button', 'elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\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' => 'typography',\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_4,\n\t\t\t\t'selector' => '{{WRAPPER}} a.roll-button, {{WRAPPER}} .roll-button',\n\t\t\t]\n\t\t);\n\t\n\t\t$this->start_controls_tabs( 'tabs_button_style' );\n\n\t\t$this->start_controls_tab(\n\t\t\t'tab_button_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_control(\n\t\t\t'button_text_color',\n\t\t\t[\n\t\t\t\t'label' \t=> __( 'Text Color', 'elementor' ),\n\t\t\t\t'type' \t\t=> Controls_Manager::COLOR,\n\t\t\t\t'default' \t=> '#fff',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} a.roll-button, {{WRAPPER}} .roll-button' => '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'background_color',\n\t\t\t[\n\t\t\t\t'label' \t=> __( 'Background Color', 'elementor' ),\n\t\t\t\t'type' \t\t=> Controls_Manager::COLOR,\n\t\t\t\t'default' \t=> '#e64e4e',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} a.roll-button, {{WRAPPER}} .roll-button' => 'background-color: {{VALUE}};',\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'tab_button_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_control(\n\t\t\t'hover_color',\n\t\t\t[\n\t\t\t\t'label' \t=> __( 'Text Color', 'elementor' ),\n\t\t\t\t'type' \t\t=> Controls_Manager::COLOR,\n\t\t\t\t'default' \t=> '#47425d',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} a.roll-button:hover, {{WRAPPER}} .roll-button:hover' => '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'button_background_hover_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Background Color', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'\t=> 'transparent',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} a.roll-button:hover, {{WRAPPER}} .roll-button:hover' => 'background-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'button_hover_border_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Color', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'condition' => [\n\t\t\t\t\t'border_border!' => '',\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} a.roll-button:hover, {{WRAPPER}} .roll-button:hover' => 'border-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'hover_animation',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover Animation', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::HOVER_ANIMATION,\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_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'placeholder' => '1px',\n\t\t\t\t'default' => '1px',\n\t\t\t\t'selector' => '{{WRAPPER}} .roll-button',\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'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'default' => [\t'top' => 3,\n\t\t\t\t\t\t'right' => 3,\n\t\t\t\t\t\t'bottom' => 3,\n\t\t\t\t\t\t'left' => 3,\n\t\t\t\t\t\t'unit' => 'px',\n\t\t\t\t\t\t'isLinked' => false,\n\t\t\t\t\t],\t\t\t\t\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} a.roll-button, {{WRAPPER}} .roll-button' => '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' => 'button_box_shadow',\n\t\t\t\t'selector' => '{{WRAPPER}} .roll-button',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'text_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', '%' ],\n\t\t\t\t'default' => [\t'top' => 16,\n\t\t\t\t\t\t'right' => 35,\n\t\t\t\t\t\t'bottom' => 16,\n\t\t\t\t\t\t'left' => 35,\n\t\t\t\t\t\t'unit' => 'px',\n\t\t\t\t\t\t'isLinked' => false,\n\t\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} a.roll-button, {{WRAPPER}} .roll-button' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t\t//End button styles\n\n\n\t}",
"protected function _register_controls() {\r\n\t\t$this->start_controls_section(\r\n\t\t\t'section_content',\r\n\t\t\t[\r\n\t\t\t\t'label' => __( 'Simple Modal', 'elementor-imgtec' ),\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->add_control(\r\n\t\t\t'unique_identifier',\r\n\t\t\t[\r\n\t\t\t\t'label' => __( 'Unique ID For Modal', 'elementor-imgtec' ),\r\n\t\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t\t'placeholder' => 'enter-unique-id-here'\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->add_control(\r\n\t\t\t'open_modal_type',\r\n\t\t\t[\r\n\t\t\t\t'label' \t=> 'Open Modal Type',\r\n\t\t\t\t'type' \t\t=> Controls_Manager::CHOOSE,\r\n\t\t\t\t'default' \t=> 'text',\r\n\t\t\t\t'options' \t=> [\r\n\t\t\t\t\t'text' \t\t=> [\r\n\t\t\t\t\t\t'title' \t=> __( '<a> Tag', 'elementor-imgtec' ),\r\n\t\t\t\t\t\t'icon' \t\t=> 'eicon-animation-text'\r\n\t\t\t\t\t],\r\n\t\t\t\t\t'button' \t=> [\r\n\t\t\t\t\t\t'title' \t=> __( '<button> Tag', 'elementor-imgtec' ),\r\n\t\t\t\t\t\t'icon' \t\t=> 'eicon-button'\r\n\t\t\t\t\t],\r\n\t\t\t\t\t'btn_primary' \t=> [\r\n\t\t\t\t\t\t'title' \t=> __( '<a class=\"btn-primary\">', 'elementor-imgtec' ),\r\n\t\t\t\t\t\t'icon' \t\t=> 'eicon-button'\r\n\t\t\t\t\t]\r\n\t\t\t\t],\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->add_control(\r\n\t\t\t'open_modal_text',\r\n\t\t\t[\r\n\t\t\t\t'label' \t\t=> __( 'Open Modal Text', 'elementor-imgtec' ),\r\n\t\t\t\t'type' \t\t\t=> Controls_Manager::TEXT,\r\n\t\t\t\t'default' \t\t=> 'Display Modal',\r\n\t\t\t\t'description' \t=> __( 'This text will open your modal when clicked.' ,'elementor-imgtec' )\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->add_control(\r\n\t\t\t'modal_content',\r\n\t\t\t[\r\n\t\t\t\t'label' \t\t=> __( 'Modal Content', 'elementor-imgtec' ),\r\n\t\t\t\t'type' \t\t\t=> Controls_Manager::WYSIWYG,\r\n\t\t\t\t'placeholder' \t=> __( 'Enter the content you wish to be contained on your modal. You can include images, videos, files from the media gallery, etc.' ,'elementor-imgtec' ),\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->add_control(\r\n\t\t\t'extra_modal_close',\r\n\t\t\t[\r\n\t\t\t\t'label' \t\t=> __( 'Extra Close Trigger Needed?', 'elementor-imgtec' ),\r\n\t\t\t\t'type' \t\t\t=> Controls_Manager::SWITCHER,\r\n\t\t\t\t'default' \t\t=> 'no',\r\n\t\t\t\t'label_on' \t\t=> __( 'YES', 'elementor-imgtec' ),\r\n\t\t\t\t'label_off' \t=> __( 'NO', 'elementor-imgtec' ),\r\n\t\t\t\t'return_value' \t=> 'yes',\r\n\t\t\t\t'description' \t=> __( 'This will be in addition to the \"X\" close button in the top right hand corner of the modal window', 'elementor-imgtec' )\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->add_control(\r\n\t\t\t'close_modal_type',\r\n\t\t\t[\r\n\t\t\t\t'label' \t=> 'Close Modal Type',\r\n\t\t\t\t'type' \t\t=> Controls_Manager::CHOOSE,\r\n\t\t\t\t'default' \t=> 'text',\r\n\t\t\t\t'options' \t=> [\r\n\t\t\t\t\t'text' \t\t=> [\r\n\t\t\t\t\t\t'title' \t=> __( '<a> Tag', 'elementor-imgtec' ),\r\n\t\t\t\t\t\t'icon' \t\t=> 'eicon-animation-text'\r\n\t\t\t\t\t],\r\n\t\t\t\t\t'button' \t=> [\r\n\t\t\t\t\t\t'title' \t=> __( '<button> Tag', 'elementor-imgtec' ),\r\n\t\t\t\t\t\t'icon' \t\t=> 'eicon-button'\r\n\t\t\t\t\t],\r\n\t\t\t\t\t'btn_primary' => [\r\n\t\t\t\t\t\t'title' \t=> __( '<a class=\"btn-primary\">', 'elementor-imgtec' ),\r\n\t\t\t\t\t\t'icon' \t\t=> 'eicon-button'\r\n\t\t\t\t\t]\r\n\t\t\t\t],\r\n\t\t\t\t'condition' => [\r\n\t\t\t\t\t'extra_modal_close' => 'yes'\r\n\t\t\t\t]\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->add_control(\r\n\t\t\t'close_modal_text',\r\n\t\t\t[\r\n\t\t\t\t'label' \t\t=> __( 'Close Modal Text', 'elementor-imgtec' ),\r\n\t\t\t\t'type' \t\t\t=> Controls_Manager::TEXT,\r\n\t\t\t\t'default' \t\t=> 'Close Modal',\r\n\t\t\t\t'description' \t=> __( 'This text will close your modal when clicked.' ,'elementor-imgtec' ),\r\n\t\t\t\t'condition' \t=> [\r\n\t\t\t\t\t'extra_modal_close' => 'yes'\r\n\t\t\t\t]\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->end_controls_section();\r\n\r\n\t}",
"protected function _register_controls()\n {\n $this->start_controls_section(\n 'section_style',\n [\n 'label' => __('Style', 'elementor-pro'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_responsive_control(\n 'align',\n [\n 'label' => __('Alignment', 'elementor-pro'),\n 'type' => Controls_Manager::CHOOSE,\n 'options' => [\n 'left' => [\n 'title' => __('Left', 'elementor-pro'),\n 'icon' => 'eicon-text-align-left',\n ],\n 'center' => [\n 'title' => __('Center', 'elementor-pro'),\n 'icon' => 'eicon-text-align-center',\n ],\n 'right' => [\n 'title' => __('Right', 'elementor-pro'),\n 'icon' => 'eicon-text-align-right',\n ],\n 'justify' => [\n 'title' => __('Justified', 'elementor-pro'),\n 'icon' => 'eicon-text-align-justify',\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}}' => 'text-align: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_control(\n 'text_color',\n [\n 'label' => __('Text Color', 'elementor-pro'),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}}' => 'color: {{VALUE}};',\n ],\n 'global' => [\n 'default' => Global_Colors::COLOR_TEXT,\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'typography',\n 'global' => [\n 'default' => Global_Typography::TYPOGRAPHY_TEXT,\n ],\n ]\n );\n\n $this->end_controls_section();\n }",
"static function AddControls(&$page){\n $page->Kernel->ImportClass(\"web.controls.structurecontrol\", \"StructureControl\", \"content\");\n $page->AddControl(new StructureControl(\"cms_page\", \"cms_page\"));\n\n $page->Kernel->ImportClass(\"web.controls.sitestructurecontrol\", \"SiteStructureControl\", \"content\");\n $page->AddControl(new SiteStructureControl(\"cms_structure\", \"cms_structure\"));\n\n $page->Kernel->ImportClass(\"web.controls.menucontrol\", \"MenuControl\", \"content\");\n $page->AddControl(new MenuControl(\"cms_menu\", \"cms_menu\"));\n\n $page->Kernel->ImportClass(\"web.controls.contentcontrol\", \"ContentControl\", \"content\");\n $page->AddControl(new ContentControl(\"cms_content\", \"cms_content\"));\n\n\t if (Engine::isPackageExists($page->Kernel, \"banner\")) {\n $page->Kernel->ImportClass(\"web.controls.bannerscontrol\", \"BannersControl\", \"banner\");\n $page->AddControl(new BannersControl(\"cms_banners\", \"cms_banners\"));\n }\n\n if (Engine::isPackageExists($page->Kernel, \"context\")) {\n $page->Kernel->ImportClass(\"web.controls.contextcontrol\", \"ContextControl\", \"context\");\n $page->AddControl(new ContextControl(\"cms_context\", \"cms_context\"));\n }\n\n //--include publications control\n if (Engine::isPackageExists($page->Kernel, \"publications\")) {\n $page->Kernel->ImportClass(\"web.controls.publicationcontrol\", \"PublicationControl\", \"publications\");\n $page->AddControl(new PublicationControl(\"cms_publications\", \"cms_publications\"));\n }\n //--include comments control\n if (Engine::isPackageExists($page->Kernel, \"comments\")) {\n $page->Kernel->ImportClass(\"web.controls.commentscontrol\", \"CommentsControl\", \"comments\");\n $page->AddControl(new CommentsControl(\"cms_comments\", \"cms_comments\"));\n }\n //--include statistics control\n if (Engine::isPackageExists($page->Kernel, \"stat\")) {\n $page->Kernel->ImportClass(\"web.controls.statcollectorcontrol\", \"StatCollectorControl\", \"stat\");\n $page->AddControl(new StatCollectorControl(\"statcollector\", \"statcollector\"));\n }\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( 'features_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'theme' => 'theme-01',\r\n\t\t\t\t\t'title' => esc_html__( 'Clean Design', 'aapside-master' ),\r\n\t\t\t\t\t'icon' => 'flaticon-vector',\r\n\t\t\t\t\t'description' => esc_html__( 'Consectetur adipiscing elit, sed do eiusmod tempor tempor incididunt', 'aapside-master' ),\r\n\t\t\t\t],\r\n\t\t\t\t[\r\n\t\t\t\t\t'theme' => 'theme-02',\r\n\t\t\t\t\t'title' => esc_html__( 'Fully Respnosive', 'aapside-master' ),\r\n\t\t\t\t\t'icon' => 'flaticon-responsive',\r\n\t\t\t\t\t'description' => esc_html__( 'Consectetur adipiscing elit, sed do eiusmod tempor tempor incididunt', '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' => 'theme',\r\n\t\t\t\t\t'label' => esc_html__( 'Theme', 'aapside-master' ),\r\n\t\t\t\t\t'type' => Controls_Manager::SELECT,\r\n\t\t\t\t\t'description' => esc_html__( 'select theme.', 'aapside-master' ),\r\n\t\t\t\t\t'options' => array(\r\n\t\t\t\t\t\t'theme-01' => esc_html__( 'Theme One' ),\r\n\t\t\t\t\t\t'theme-02' => esc_html__( 'Theme Two' ),\r\n\t\t\t\t\t\t'theme-03' => esc_html__( 'Theme Three' ),\r\n\t\t\t\t\t),\r\n\t\t\t\t\t'default' => 'theme-01'\r\n\t\t\t\t],\r\n\t\t\t\t[\r\n\t\t\t\t\t'name' => 'title',\r\n\t\t\t\t\t'label' => esc_html__( 'Title', 'aapside-master' ),\r\n\t\t\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t\t\t'description' => esc_html__( 'enter title.', 'aapside-master' ),\r\n\t\t\t\t\t'default' => esc_html__( 'Clean Design', 'aapside-master' )\r\n\t\t\t\t],\r\n\t\t\t\t[\r\n\t\t\t\t\t'name' => 'description',\r\n\t\t\t\t\t'label' => esc_html__( 'Description', 'aapside-master' ),\r\n\t\t\t\t\t'type' => Controls_Manager::TEXTAREA,\r\n\t\t\t\t\t'default' => esc_html__( 'Consectetur adipiscing elit, sed do eiusmod tempor tempor incididunt', 'aapside-master' ),\r\n\t\t\t\t\t'description' => esc_html__( 'enter description.', 'aapside-master' ),\r\n\t\t\t\t],\r\n\t\t\t\t[\r\n\t\t\t\t\t'name' => 'icon',\r\n\t\t\t\t\t'label' => esc_html__( 'Icon', 'aapside-master' ),\r\n\t\t\t\t\t'type' => Controls_Manager::ICON,\r\n\t\t\t\t\t'description' => esc_html__( 'select icon.', 'aapside-master' ),\r\n\t\t\t\t\t'default' => 'flaticon-vector'\r\n\t\t\t\t]\r\n\t\t\t],\r\n\t\t\t'title_field' => \"{{title}}\"\r\n\t\t] );\r\n\r\n\r\n\t\t$this->end_controls_section();\r\n\r\n\t\t$this->start_controls_section(\r\n\t\t\t'typography_section',\r\n\t\t\t[\r\n\t\t\t\t'label' => esc_html__( 'Typography Settings', 'aapside-master' ),\r\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->add_group_control( Group_Control_Typography::get_type(), [\r\n\t\t\t'label' => esc_html__( 'Title Typography' ),\r\n\t\t\t'name' => 'title_typography',\r\n\t\t\t'selector' => \"{{WRAPPER}} .feature-list-04 .single-feature-list-item-04 .content .title\"\r\n\t\t] );\r\n\t\t$this->add_control( 'styling_divider', [\r\n\t\t\t'type' => Controls_Manager::DIVIDER\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Typography::get_type(), [\r\n\t\t\t'label' => esc_html__( 'Description Typography' ),\r\n\t\t\t'name' => 'description_typography',\r\n\t\t\t'selector' => \"{{WRAPPER}} .feature-list-04 .single-feature-list-item-04 .content p\"\r\n\t\t] );\r\n\t\t$this->end_controls_section();\r\n\t\t\r\n\t\t/* theme one icon color start */\r\n\t\t$this->start_controls_section(\r\n\t\t\t'theme_one_section',\r\n\t\t\t[\r\n\t\t\t\t'label' => __( 'Theme One Styling', 'aapside-master' ),\r\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->start_controls_tabs(\r\n\t\t\t'theme_one_style_tabs'\r\n\t\t);\r\n\r\n\t\t$this->start_controls_tab(\r\n\t\t\t'theme_01_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( 'theme_01_icon_color', [\r\n\t\t\t'label' => esc_html__( 'Icon 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}} .feature-list-04 .theme-01.single-feature-list-item-04 .icon\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_01_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}} .feature-list-04 .theme-01.single-feature-list-item-04 .content .title\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_01_description_color', [\r\n\t\t\t'label' => esc_html__( 'Description 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}} .feature-list-04 .theme-01.single-feature-list-item-04 .content p\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'styling_divider_01', [\r\n\t\t\t'type' => Controls_Manager::DIVIDER\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'name' => 'feature_list_background',\r\n\t\t\t'title' => esc_html__( 'Background', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .feature-list-04 .theme-01.single-feature-list-item-04\"\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'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\r\n\t\t$this->add_control( 'theme_01_icon_hover_color', [\r\n\t\t\t'label' => esc_html__( 'Icon 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}} .feature-list-04 .theme-01.single-feature-list-item-04:hover .icon\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_01_title_hover_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}} .feature-list-04 .theme-01.single-feature-list-item-04:hover .content .title\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_01_description_hover_color', [\r\n\t\t\t'label' => esc_html__( 'Description 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}} .feature-list-04 .theme-01.single-feature-list-item-04:hover .content p\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'styling_hover_divider', [\r\n\t\t\t'type' => Controls_Manager::DIVIDER\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'name' => 'theme_01_feature_list_hover_background',\r\n\t\t\t'title' => esc_html__( 'Background', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .feature-list-04 .theme-01.single-feature-list-item-04: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\r\n\t\t$this->end_controls_section();\r\n\t\t/* theme one icon color end */\r\n\r\n\t\t/* theme two icon color start */\r\n\t\t$this->start_controls_section(\r\n\t\t\t'theme_two_section',\r\n\t\t\t[\r\n\t\t\t\t'label' => __( 'Theme Two Styling', 'aapside-master' ),\r\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->start_controls_tabs(\r\n\t\t\t'theme_two_style_tabs'\r\n\t\t);\r\n\r\n\t\t$this->start_controls_tab(\r\n\t\t\t'theme_02_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( 'theme_02_icon_color', [\r\n\t\t\t'label' => esc_html__( 'Icon 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}} .feature-list-04 .theme-02.single-feature-list-item-04 .icon\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_02_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}} .feature-list-04 .theme-02.single-feature-list-item-04 .content .title\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_02_description_color', [\r\n\t\t\t'label' => esc_html__( 'Description 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}} .feature-list-04 .theme-02.single-feature-list-item-04 .content p\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'styling_divider_02', [\r\n\t\t\t'type' => Controls_Manager::DIVIDER\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'name' => 'feature_theme_02_list_background',\r\n\t\t\t'title' => esc_html__( 'Background', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .feature-list-04 .theme-02.single-feature-list-item-04\"\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'style_theme_02_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\r\n\t\t$this->add_control( 'theme_02_icon_hover_color', [\r\n\t\t\t'label' => esc_html__( 'Icon 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}} .feature-list-04 .theme-02.single-feature-list-item-04:hover .icon\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_02_title_hover_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}} .feature-list-04 .theme-02.single-feature-list-item-04:hover .content .title\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_02_description_hover_color', [\r\n\t\t\t'label' => esc_html__( 'Description 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}} .feature-list-04 .theme-02.single-feature-list-item-04:hover .content p\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'styling_hover_divider_02', [\r\n\t\t\t'type' => Controls_Manager::DIVIDER\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'name' => 'theme_02_feature_list_hover_background',\r\n\t\t\t'title' => esc_html__( 'Background', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .feature-list-04 .theme-02.single-feature-list-item-04: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\r\n\r\n\t\t$this->end_controls_section();\r\n\t\t/* theme two icon end */\r\n\r\n\t\t/* theme two icon color start */\r\n\t\t$this->start_controls_section(\r\n\t\t\t'theme_three_section',\r\n\t\t\t[\r\n\t\t\t\t'label' => __( 'Theme Three Styling', 'aapside-master' ),\r\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\r\n\t\t\t]\r\n\t\t);\r\n\r\n\t\t$this->start_controls_tabs(\r\n\t\t\t'theme_three_style_tabs'\r\n\t\t);\r\n\r\n\t\t$this->start_controls_tab(\r\n\t\t\t'theme_03_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( 'theme_03_icon_color', [\r\n\t\t\t'label' => esc_html__( 'Icon 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}} .feature-list-04 .theme-03.single-feature-list-item-04 .icon\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_03_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}} .feature-list-04 .theme-03.single-feature-list-item-04 .content .title\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_03_description_color', [\r\n\t\t\t'label' => esc_html__( 'Description 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}} .feature-list-04 .theme-03.single-feature-list-item-04 .content p\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'styling_divider_03', [\r\n\t\t\t'type' => Controls_Manager::DIVIDER\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'name' => 'feature_theme_03_list_background',\r\n\t\t\t'title' => esc_html__( 'Background', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .feature-list-04 .theme-03.single-feature-list-item-04\"\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'theme_03_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\r\n\t\t$this->add_control( 'theme_03_icon_hover_color', [\r\n\t\t\t'label' => esc_html__( 'Icon 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}} .feature-list-04 .theme-03.single-feature-list-item-04:hover .icon\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_03_title_hover_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}} .feature-list-04 .theme-03.single-feature-list-item-04:hover .content .title\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'theme_03_description_hover_color', [\r\n\t\t\t'label' => esc_html__( 'Description 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}} .feature-list-04 .theme-03.single-feature-list-item-04:hover .content p\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'styling_hover_divider_03', [\r\n\t\t\t'type' => Controls_Manager::DIVIDER\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'name' => 'theme_03_feature_list_hover_background',\r\n\t\t\t'title' => esc_html__( 'Background', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .feature-list-04 .theme-03.single-feature-list-item-04: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\r\n\r\n\t\t$this->end_controls_section();\r\n\t\t/* theme three icon color end */\r\n\t}",
"protected function _register_controls()\n\t{\n\t\t$this->start_controls_section('brand_colors', [\n\t\t\t'label' => __('Colors', 'jhdc-branding-elementor-extension'),\n\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t]);\n\n\t\t$this->add_control('color', [\n\t\t\t'label' => __('Color', 'jhdc-branding-elementor-extension'),\n\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t'default' => '#ababab',\n\t\t\t//'scheme' => [\n\t\t\t//\t'type' => Scheme_Color::get_type(),\n\t\t\t//\t'value' => Scheme_Color::COLOR_1,\n\t\t\t//],\n\t\t\t'selectors' => [\n\t\t\t\t'{{WRAPPER}} a' => 'color: {{VALUE}}',\n\t\t\t],\n\t\t]);\n\n\t\t$this->add_group_control(Group_Control_Typography::get_type(), [\n\t\t\t'name' => 'typography',\n\t\t\t'selector' => '{{WRAPPER}} a',\n\t\t]);\n\n\t\t$this->end_controls_section();\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_timeline_style',\n [\n 'label' => __( 'Timeline Style', 'essential-addons-elementor' ),\n 'tab' => Controls_Manager::TAB_STYLE\n ]\n );\n\n $this->add_control(\n\t\t\t'eael_timeline_overlay_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Overlay Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'description' => __('Leave blank or Clear to use default gradient overlay', 'essential-addons-elementor'),\n\t\t\t\t'default' => 'linear-gradient(45deg, #3f3f46 0%, #05abe0 100%) repeat scroll 0 0 rgba(0, 0, 0, 0)',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-timeline-post-inner' => 'background: {{VALUE}}',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_timeline_bullet_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Timeline Bullet Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '#9fa9af',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-timeline-bullet' => 'background-color: {{VALUE}};',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_timeline_bullet_border_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Timeline Bullet Border 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-timeline-bullet' => 'border-color: {{VALUE}};',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_timeline_vertical_line_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Timeline Vertical Line Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> 'rgba(83, 85, 86, .2)',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-timeline-post:after' => 'background-color: {{VALUE}};',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_timeline_border_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border & Arrow Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '#e5eaed',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-timeline-post-inner' => 'border-color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .eael-timeline-post-inner::after' => 'border-left-color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .eael-timeline-post:nth-child(2n) .eael-timeline-post-inner::after' => 'border-right-color: {{VALUE}};',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_timeline_date_background_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Date Background Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> 'rgba(0, 0, 0, 0.7)',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-timeline-post time' => 'background-color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .eael-timeline-post time::before' => 'border-bottom-color: {{VALUE}};',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_timeline_date_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Date Text 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-timeline-post time' => 'color: {{VALUE}};',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n\n\t\t$this->end_controls_section();\n\n $this->start_controls_section(\n 'eael_section_typography',\n [\n 'label' => __( 'Typography', 'essential-addons-elementor' ),\n 'tab' => Controls_Manager::TAB_STYLE\n ]\n );\n\n\t\t$this->add_control(\n\t\t\t'eael_timeline_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_timeline_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'=> '#fff',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-timeline-post-title h2' => '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_timeline_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-timeline-post-title h2' => '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_timeline_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-timeline-post-title h2',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'eael_timeline_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_timeline_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'=> '#ffffff',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-timeline-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_timeline_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-timeline-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_timeline_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-timeline-post-excerpt p',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->end_controls_section();\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\t/**\n\t\t * Content tab.\n\t\t */\n\n\t\t/**\n\t\t * General settings.\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'general_content_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'General', 'woodmart' ),\n\t\t\t]\n\t\t);\n\n\t\t$repeater = new Repeater();\n\n\t\t$repeater->start_controls_tabs( 'banner_tabs' );\n\n\t\t$repeater->start_controls_tab(\n\t\t\t'link_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Link', 'woodmart' ),\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'link',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Link', 'woodmart' ),\n\t\t\t\t'description' => esc_html__( 'Enter URL if you want this banner to have a link.', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => '#',\n\t\t\t\t\t'is_external' => false,\n\t\t\t\t\t'nofollow' => false,\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$repeater->end_controls_tab();\n\n\t\t$repeater->start_controls_tab(\n\t\t\t'image_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image', 'woodmart' ),\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'image_type',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Display', 'xts-theme' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'background' => esc_html__( 'As background', 'xts-theme' ),\n\t\t\t\t\t'image' => esc_html__( 'As image', 'xts-theme' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'image',\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'image',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Choose image', 'woodmart' ),\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]\n\t\t);\n\n\t\t$repeater->add_group_control(\n\t\t\tGroup_Control_Image_Size::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'image',\n\t\t\t\t'default' => 'thumbnail',\n\t\t\t\t'separator' => 'none',\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_responsive_control(\n\t\t\t'image_height',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image height', 'xts-theme' ),\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'min' => 100,\n\t\t\t\t\t\t'max' => 2000,\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'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} {{CURRENT_ITEM}} .banner-image' => 'height: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'image_type' => [ 'background' ],\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'image_bg_position',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Background position', 'xts-theme' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'center center' => esc_html__( 'Center', 'xts-theme' ),\n\t\t\t\t\t'center top' => esc_html__( 'Top', 'xts-theme' ),\n\t\t\t\t\t'center bottom' => esc_html__( 'Bottom', 'xts-theme' ),\n\t\t\t\t\t'left center' => esc_html__( 'Left', 'xts-theme' ),\n\t\t\t\t\t'right center' => esc_html__( 'Right', 'xts-theme' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'center center',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} {{CURRENT_ITEM}} .banner-image' => 'background-position: {{VALUE}};',\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'image_type' => [ 'background' ],\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$repeater->end_controls_tab();\n\n\t\t$repeater->start_controls_tab(\n\t\t\t'text_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Text', 'woodmart' ),\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'subtitle',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Subtitle', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n\t\t\t\t'default' => 'Banner subtitle text',\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'title',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Title', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n\t\t\t\t'default' => 'Banner title, click to edit.',\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'content',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'btn_text',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Button text', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => 'Read more',\n\t\t\t]\n\t\t);\n\n\t\t$repeater->end_controls_tab();\n\n\t\t$repeater->start_controls_tab(\n\t\t\t'layout_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Layout', 'woodmart' ),\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'horizontal_alignment',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content horizontal alignment', 'woodmart' ),\n\t\t\t\t'type' => 'wd_buttons',\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => esc_html__( 'Left', 'xts-theme' ),\n\t\t\t\t\t\t'image' => WOODMART_ASSETS_IMAGES . '/settings/content-align/horizontal/left.png',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => esc_html__( 'Center', 'xts-theme' ),\n\t\t\t\t\t\t'image' => WOODMART_ASSETS_IMAGES . '/settings/content-align/horizontal/center.png',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => esc_html__( 'Right', 'xts-theme' ),\n\t\t\t\t\t\t'image' => WOODMART_ASSETS_IMAGES . '/settings/content-align/horizontal/right.png',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => 'left',\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'vertical_alignment',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content vertical alignment', 'woodmart' ),\n\t\t\t\t'type' => 'wd_buttons',\n\t\t\t\t'options' => [\n\t\t\t\t\t'top' => [\n\t\t\t\t\t\t'title' => esc_html__( 'Top', 'xts-theme' ),\n\t\t\t\t\t\t'image' => WOODMART_ASSETS_IMAGES . '/settings/content-align/vertical/top.png',\n\t\t\t\t\t],\n\t\t\t\t\t'middle' => [\n\t\t\t\t\t\t'title' => esc_html__( 'Middle', 'xts-theme' ),\n\t\t\t\t\t\t'image' => WOODMART_ASSETS_IMAGES . '/settings/content-align/vertical/middle.png',\n\t\t\t\t\t],\n\t\t\t\t\t'bottom' => [\n\t\t\t\t\t\t'title' => esc_html__( 'Bottom', 'xts-theme' ),\n\t\t\t\t\t\t'image' => WOODMART_ASSETS_IMAGES . '/settings/content-align/vertical/bottom.png',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => 'top',\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'text_alignment',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Text alignment', 'woodmart' ),\n\t\t\t\t'type' => 'wd_buttons',\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => esc_html__( 'Left', 'xts-theme' ),\n\t\t\t\t\t\t'image' => WOODMART_ASSETS_IMAGES . '/settings/align/left.jpg',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => esc_html__( 'Center', 'xts-theme' ),\n\t\t\t\t\t\t'image' => WOODMART_ASSETS_IMAGES . '/settings/align/center.jpg',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => esc_html__( 'Right', 'xts-theme' ),\n\t\t\t\t\t\t'image' => WOODMART_ASSETS_IMAGES . '/settings/align/right.jpg',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => 'left',\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_responsive_control(\n\t\t\t'width',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Width', 'woodmart' ),\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' => [ '%' ],\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],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} {{CURRENT_ITEM}} .promo-banner:not(.banner-content-background) .content-banner, {{WRAPPER}} {{CURRENT_ITEM}} .promo-banner.banner-content-background .wrapper-content-banner' => 'max-width: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'increase_spaces',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Increase spaces', 'woodmart' ),\n\t\t\t\t'description' => esc_html__( 'Suggest to use this option if you have large banners. Padding will be set in percentage to your screen width.', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'no',\n\t\t\t\t'label_on' => esc_html__( 'Yes', 'woodmart' ),\n\t\t\t\t'label_off' => esc_html__( 'No', 'woodmart' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t]\n\t\t);\n\n\t\t$repeater->end_controls_tab();\n\n\t\t$repeater->end_controls_tabs();\n\n\t\t/**\n\t\t * Repeater settings\n\t\t */\n\t\t$this->add_control(\n\t\t\t'content_repeater',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'title_field' => '{{{ title }}}',\n\t\t\t\t'fields' => array_values( $repeater->get_controls() ),\n\t\t\t\t'default' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' => 'Banner title, click to edit.',\n\t\t\t\t\t\t'subtitle' => 'Banner subtitle text',\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' => 'Banner title, click to edit.',\n\t\t\t\t\t\t'subtitle' => 'Banner subtitle text',\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' => 'Banner title, click to edit.',\n\t\t\t\t\t\t'subtitle' => 'Banner subtitle text',\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/**\n\t\t * Style tab.\n\t\t */\n\n\t\t/**\n\t\t * General settings.\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'general_style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'General', 'woodmart' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'style',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Style', 'woodmart' ),\n\t\t\t\t'description' => esc_html__( 'You can use some of our predefined styles for your banner content.', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'default' => esc_html__( 'Default', 'woodmart' ),\n\t\t\t\t\t'mask' => esc_html__( 'Color mask', 'woodmart' ),\n\t\t\t\t\t'shadow' => esc_html__( 'Mask with shadow', 'woodmart' ),\n\t\t\t\t\t'border' => esc_html__( 'Bordered', 'woodmart' ),\n\t\t\t\t\t'background' => esc_html__( 'Bordered background', 'woodmart' ),\n\t\t\t\t\t'content-background' => esc_html__( 'Content background', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'default',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'hover',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hover effect', 'woodmart' ),\n\t\t\t\t'description' => esc_html__( 'Set beautiful hover effects for your banner.', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'zoom' => esc_html__( 'Zoom image', 'woodmart' ),\n\t\t\t\t\t'parallax' => esc_html__( 'Parallax', 'woodmart' ),\n\t\t\t\t\t'background' => esc_html__( 'Background', 'woodmart' ),\n\t\t\t\t\t'border' => esc_html__( 'Bordered', 'woodmart' ),\n\t\t\t\t\t'zoom-reverse' => esc_html__( 'Zoom reverse', 'woodmart' ),\n\t\t\t\t\t'none' => esc_html__( 'Disable', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'none',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'woodmart_color_scheme',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color Scheme', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'' => esc_html__( 'Inherit', 'woodmart' ),\n\t\t\t\t\t'light' => esc_html__( 'Light', 'woodmart' ),\n\t\t\t\t\t'dark' => esc_html__( 'Dark', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => '',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'title_size',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Predefined size', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'default' => esc_html__( 'Default (22px)', 'woodmart' ),\n\t\t\t\t\t'small' => esc_html__( 'Small (18px)', 'woodmart' ),\n\t\t\t\t\t'large' => esc_html__( 'Large (28px)', 'woodmart' ),\n\t\t\t\t\t'extra-large' => esc_html__( 'Extra Large (32px)', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'default',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'custom_content_bg_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content background color', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .wrapper-content-banner' => 'background-color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'style' => 'content-background',\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 * Carousel settings.\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'carousel_style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Carousel', 'woodmart' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'slides_per_view',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Slides per view', 'woodmart' ),\n\t\t\t\t'description' => esc_html__( 'Set numbers of slides you want to display at the same time on slider\\'s container for carousel mode.', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 3,\n\t\t\t\t],\n\t\t\t\t'size_units' => '',\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' => 8,\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\n\t\t$this->add_control(\n\t\t\t'slider_spacing',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Space between', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t0 => esc_html__( '0 px', 'woodmart' ),\n\t\t\t\t\t2 => esc_html__( '2 px', 'woodmart' ),\n\t\t\t\t\t6 => esc_html__( '6 px', 'woodmart' ),\n\t\t\t\t\t10 => esc_html__( '10 px', 'woodmart' ),\n\t\t\t\t\t20 => esc_html__( '20 px', 'woodmart' ),\n\t\t\t\t\t30 => esc_html__( '30 px', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 30,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'scroll_per_page',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Scroll per page', 'woodmart' ),\n\t\t\t\t'description' => esc_html__( 'Scroll per page not per item. This affect next/prev buttons and mouse/touch dragging.', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'yes',\n\t\t\t\t'label_on' => esc_html__( 'Yes', 'woodmart' ),\n\t\t\t\t'label_off' => esc_html__( 'No', 'woodmart' ),\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'hide_pagination_control',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hide pagination control', 'woodmart' ),\n\t\t\t\t'description' => esc_html__( 'If \"YES\" pagination control will be removed.', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'no',\n\t\t\t\t'label_on' => esc_html__( 'Yes', 'woodmart' ),\n\t\t\t\t'label_off' => esc_html__( 'No', 'woodmart' ),\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'hide_prev_next_buttons',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hide prev/next buttons', 'woodmart' ),\n\t\t\t\t'description' => esc_html__( 'If \"YES\" prev/next control will be removed', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'no',\n\t\t\t\t'label_on' => esc_html__( 'Yes', 'woodmart' ),\n\t\t\t\t'label_off' => esc_html__( 'No', 'woodmart' ),\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'wrap',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Slider loop', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'no',\n\t\t\t\t'label_on' => esc_html__( 'Yes', 'woodmart' ),\n\t\t\t\t'label_off' => esc_html__( 'No', 'woodmart' ),\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'autoplay',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Slider autoplay', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'no',\n\t\t\t\t'label_on' => esc_html__( 'Yes', 'woodmart' ),\n\t\t\t\t'label_off' => esc_html__( 'No', 'woodmart' ),\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'speed',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Slider speed', 'woodmart' ),\n\t\t\t\t'description' => esc_html__( 'Duration of animation between slides (in ms)', 'woodmart' ),\n\t\t\t\t'default' => '5000',\n\t\t\t\t'type' => Controls_Manager::NUMBER,\n\t\t\t\t'condition' => [\n\t\t\t\t\t'autoplay' => 'yes',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'scroll_carousel_init',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Init carousel on scroll', 'woodmart' ),\n\t\t\t\t'description' => esc_html__( 'This option allows you to init carousel script only when visitor scroll the page to the slider. Useful for performance optimization.', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'no',\n\t\t\t\t'label_on' => esc_html__( 'Yes', 'woodmart' ),\n\t\t\t\t'label_off' => esc_html__( 'No', 'woodmart' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t/**\n\t\t * Title settings.\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'title_style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Title', 'woodmart' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'title_tag',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Tag', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'h1' => esc_html__( 'h1', 'woodmart' ),\n\t\t\t\t\t'h2' => esc_html__( 'h2', 'woodmart' ),\n\t\t\t\t\t'h3' => esc_html__( 'h3', 'woodmart' ),\n\t\t\t\t\t'h4' => esc_html__( 'h4', 'woodmart' ),\n\t\t\t\t\t'h5' => esc_html__( 'h5', 'woodmart' ),\n\t\t\t\t\t'h6' => esc_html__( 'h6', 'woodmart' ),\n\t\t\t\t\t'p' => esc_html__( 'p', 'woodmart' ),\n\t\t\t\t\t'div' => esc_html__( 'div', 'woodmart' ),\n\t\t\t\t\t'span' => esc_html__( 'span', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'h4',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'title_decoration_style',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Text decoration style', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'default' => esc_html__( 'Default', 'woodmart' ),\n\t\t\t\t\t'colored' => esc_html__( 'Colored', 'woodmart' ),\n\t\t\t\t\t'bordered' => esc_html__( 'Bordered', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'default',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'custom_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .banner-title' => '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_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'title_typography',\n\t\t\t\t'label' => esc_html__( 'Custom typography', 'woodmart' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .banner-title',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t/**\n\t\t * Subtitle settings.\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'subtitle_style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Subtitle', 'woodmart' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'subtitle_style',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Subtitle style', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'default' => esc_html__( 'Default', 'woodmart' ),\n\t\t\t\t\t'background' => esc_html__( 'Background', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'default',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'subtitle_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Predefined color', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'default' => esc_html__( 'Default', 'woodmart' ),\n\t\t\t\t\t'primary' => esc_html__( 'Primary', 'woodmart' ),\n\t\t\t\t\t'alt' => esc_html__( 'Alternative', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'default',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'custom_subtitle_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .banner-subtitle' => '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'custom_subtitle_bg_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Background color', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .banner-subtitle' => 'background-color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'subtitle_style' => [ 'background' ],\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' => 'subtitle_typography',\n\t\t\t\t'label' => esc_html__( 'Custom typography', 'woodmart' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .banner-subtitle',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t/**\n\t\t * Content settings.\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'content_style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content', 'woodmart' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'content_text_size',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Predefined size', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'default' => esc_html__( 'Default (14px)', 'woodmart' ),\n\t\t\t\t\t'medium' => esc_html__( 'Medium (16px)', 'woodmart' ),\n\t\t\t\t\t'large' => esc_html__( 'Large (18px)', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'default',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'custom_text_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .banner-inner' => '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_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'text_typography',\n\t\t\t\t'label' => esc_html__( 'Custom typography', 'woodmart' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .banner-inner',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t/**\n\t\t * Button settings.\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'button_style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Button', 'woodmart' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'btn_position',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Button position', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'hover' => esc_html__( 'Show on hover', 'woodmart' ),\n\t\t\t\t\t'static' => esc_html__( 'Static', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'hover',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'style!' => 'content-background',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'btn_size',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Predefined size', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'default' => esc_html__( 'Default', 'woodmart' ),\n\t\t\t\t\t'extra-small' => esc_html__( 'Extra Small', 'woodmart' ),\n\t\t\t\t\t'small' => esc_html__( 'Small', 'woodmart' ),\n\t\t\t\t\t'large' => esc_html__( 'Large', 'woodmart' ),\n\t\t\t\t\t'extra-large' => esc_html__( 'Extra Large', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'default',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'btn_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Predefined color', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'default' => esc_html__( 'Default', 'woodmart' ),\n\t\t\t\t\t'primary' => esc_html__( 'Primary', 'woodmart' ),\n\t\t\t\t\t'alt' => esc_html__( 'Alternative', 'woodmart' ),\n\t\t\t\t\t'black' => esc_html__( 'Black', 'woodmart' ),\n\t\t\t\t\t'white' => esc_html__( 'White', 'woodmart' ),\n\t\t\t\t\t'custom' => esc_html__( 'Custom', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'default',\n\t\t\t]\n\t\t);\n\n\t\t$this->start_controls_tabs(\n\t\t\t'button_tabs_style',\n\t\t\t[\n\t\t\t\t'condition' => [\n\t\t\t\t\t'color' => [ 'custom' ],\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->start_controls_tab(\n\t\t\t'button_tab_normal',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Normal', 'xts-theme' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'bg_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Background color', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woodmart-button-wrapper a' => 'background-color: {{VALUE}}; border-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'color_scheme',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Text color scheme', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'inherit' => esc_html__( 'Inherit', 'woodmart' ),\n\t\t\t\t\t'dark' => esc_html__( 'Dark', 'woodmart' ),\n\t\t\t\t\t'light' => esc_html__( 'Light', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'inherit',\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'button_tab_hover',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hover', 'xts-theme' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'bg_color_hover',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Background color hover', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woodmart-button-wrapper:hover a' => 'background-color: {{VALUE}}; border-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'color_scheme_hover',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Text color scheme on hover', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'inherit' => esc_html__( 'Inherit', 'woodmart' ),\n\t\t\t\t\t'dark' => esc_html__( 'Dark', 'woodmart' ),\n\t\t\t\t\t'light' => esc_html__( 'Light', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'inherit',\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'btn_style',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Style', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'default' => esc_html__( 'Default', 'woodmart' ),\n\t\t\t\t\t'bordered' => esc_html__( 'Bordered', 'woodmart' ),\n\t\t\t\t\t'link' => esc_html__( 'Link button', 'woodmart' ),\n\t\t\t\t\t'3d' => esc_html__( '3D', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'default',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'btn_shape',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Shape', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'rectangle' => esc_html__( 'Rectangle', 'woodmart' ),\n\t\t\t\t\t'round' => esc_html__( 'Circle', 'woodmart' ),\n\t\t\t\t\t'semi-round' => esc_html__( 'Round', 'woodmart' ),\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'btn_style!' => [ 'link' ],\n\t\t\t\t],\n\t\t\t\t'default' => 'rectangle',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'button_icon_heading',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Icon', 'woodmart' ),\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\t\twoodmart_get_button_style_icon_map( $this );\n\n\t\t$this->add_control(\n\t\t\t'button_layout_heading',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Layout', 'woodmart' ),\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\t\t$this->add_control(\n\t\t\t'full_width',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Full width', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'no',\n\t\t\t\t'label_on' => esc_html__( 'Yes', 'woodmart' ),\n\t\t\t\t'label_off' => esc_html__( 'No', 'woodmart' ),\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'button_hr',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::DIVIDER,\n\t\t\t\t'style' => 'thick',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'hide_btn_tablet',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hide button on tablet', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'no',\n\t\t\t\t'label_on' => esc_html__( 'Yes', 'woodmart' ),\n\t\t\t\t'label_off' => esc_html__( 'No', 'woodmart' ),\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'hide_btn_mobile',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hide button on mobile', 'woodmart' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'no',\n\t\t\t\t'label_on' => esc_html__( 'Yes', 'woodmart' ),\n\t\t\t\t'label_off' => esc_html__( 'No', 'woodmart' ),\n\t\t\t\t'return_value' => 'yes',\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$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// Hero Title\n\t\t$this->add_control(\n\t\t 'portfolio_hero_title',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Hero 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 Hero Title','portfolio-elementor'),\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Sub Title Two\n\t\t$this->add_control(\n\t\t 'portfolio_hero_sub_title_one',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Hero Sub Title Two','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 Hero Sub Title Two','portfolio-elementor'),\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Sub Title Two\n\t\t$this->add_control(\n\t\t 'portfolio_hero_sub_title_two',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Hero Sub Title Two','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 Hero Sub Title Two','portfolio-elementor'),\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Description\n\t\t$this->add_control(\n\t\t 'portfolio_hero_description',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Hero Description','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 Hero Description','portfolio-elementor'),\n\t\t\t]\n\t\t);\n\t\t\n\t\t//Hero Button One Link\n\t\t$this->add_control(\n\t\t 'portfolio_hero_button_one_link',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Hero Button One Link','portfolio-elementor'),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::URL,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => [\n\t\t\t\t 'url' => '#',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button One Text\n $this->add_control(\n \t'portfolio_hero_button_one_text',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Hero Button One Text', '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 Button One Text','portfolio-elementor'),\n\t\t\t]\n );\n\t\t\n\t\t//Hero Button Two Link\n\t\t$this->add_control(\n\t\t 'portfolio_hero_button_two_link',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Hero Button Two Link','portfolio-elementor'),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::URL,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => [\n\t\t\t\t 'url' => '#',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button Two Text\n $this->add_control(\n \t'portfolio_hero_button_two_text',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Hero Button Two Text', '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 Button Two Text','portfolio-elementor'),\n\t\t\t]\n );\n\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// Hero Title Options\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_title_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hero 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// Hero Title Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_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' => '#001418',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .hero-title' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero 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_hero_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}} .hero-title',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Sub Title One Options\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_sub_title_one_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hero Sub Title One', '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// Hero Sub Title One Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_sub_title_one_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Sub Title One 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}} .hero-content h4' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Sub Title One 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_hero_sub_title_one_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}} .hero-content h4',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Sub Title Two Options\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_sub_title_one_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hero Sub Title Two', '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// Hero Sub Title Two Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_sub_title_two_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Sub Title Two 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' => '#5e9e9f',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .typed' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Sub Title Two 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_hero_sub_title_two_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}} .typed',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Description Options\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_description_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hero Description', '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// Hero Description Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_description_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Description 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}} .hero-content p' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Description 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_hero_description_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}} .hero-content p',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button One Options\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_one_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hero Button One', '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// Hero Button One Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_one_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' => '#ffffff',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .btn span' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button One Background Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_one_background_color',\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' => '#5e9e9f',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .btn' => 'background-color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button One Border\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_one_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' => '#5e9e9f',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .btn' => 'border: 1px solid {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button Two Options\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_two_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hero Button Two', '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// Hero Button Two Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_two_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' => '#000000',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .site-btn' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button Two Background Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_two_background_color',\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' => '#ffffff',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .site-btn' => 'background-color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button Two Border\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_two_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' => '#5e9e9f',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .site-btn' => 'border: 1px solid {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button Options\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hero Button', '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// Hero Button 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_hero_btn_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}} .hero-content a',\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// Hero Button One Hover Options\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_one_hover_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hero Button', '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// Hero Button One Hover Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_one_hover_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' => '#000000',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .btn:hover span' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button Two Hover Options\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_two_hover_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hero Button', '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// Hero Button Two Hover Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_two_hover_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' => '#ffffff',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .site-btn:hover' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Hero Button Two Hover Background Color\n\t\t$this->add_control(\n\t\t\t'portfolio_hero_btn_two_hover_background_color',\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' => '#5e9e9f',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .site-btn:hover' => 'background-color: {{VALUE}}',\n\t\t\t\t],\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 * get all product for select list\n */\n $args = [\n 'orderby' => 'name',\n 'order' => 'DESC',\n 'numberposts' => -1,\n 'post_status' => 'published',\n ];\n $optionProduct = ['' => 'Empty'];\n $optionProductVariant = ['' => 'Empty'];\n $products = wc_get_products($args);\n\n foreach ($products as $product) {\n\n if(is_object($product)){\n $optionProduct[$product->get_id()] = $product->get_id() . ' - ' . $product->get_name();\n }\n }\n\n foreach ($products as $productVariant) {\n if ($productVariant->is_type('variable')) {\n $variation_ids = $productVariant->get_visible_children();\n foreach ($variation_ids as $variation_id) {\n $variation = wc_get_product($variation_id);\n\n if(is_object($variation)){\n $optionProductVariant[$variation_id] = $variation->get_id() . ' - ' . $variation->get_name();\n }\n }\n }\n }\n\n /**\n * BestSellers\n */\n\n $this->start_controls_section(\n 'section_content',\n [\n 'label' => __('First tab', 'elementor-wps-bestsellers'),\n ]\n );\n\n\n $this->add_control(\n 'title_1',\n [\n 'label' => __('Title', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'default' => __('Best Sellers', 'elementor-wps-bestsellers'),\n 'placeholder' => __('Title first tab', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'title_1_color',\n [\n 'label' => __('Title color', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'default' => '#000000',\n ]\n );\n\n $this->add_control(\n 'title_1_color_selected',\n [\n 'label' => __('Title color selected', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'default' => '#000000',\n ]\n );\n\n $this->add_control(\n 'hr0',\n [\n 'type' => \\Elementor\\Controls_Manager::DIVIDER,\n ]\n );\n\n for ($i = 1; $i <= 4; $i++) {\n\n $this->add_control(\n 'important_note_' . $i,\n [\n 'type' => \\Elementor\\Controls_Manager::RAW_HTML,\n 'raw' => __('Select ' . $i . ' product or variant', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_product_' . $i,\n [\n 'label' => __('Select product ' . $i, 'elementor-wps-bestsellers'),\n 'type' => Controls_Manager::SELECT2,\n 'options' => $optionProduct,\n 'default' => __('Empty', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'or_note_' . $i,\n [\n 'type' => \\Elementor\\Controls_Manager::RAW_HTML,\n 'raw' => __('OR', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_variant_' . $i,\n [\n 'label' => __('Select variant ' . $i, 'elementor-wps-bestsellers'),\n 'type' => Controls_Manager::SELECT2,\n 'options' => $optionProductVariant,\n 'default' => __('Empty', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_product_sale_' . $i,\n [\n 'label' => __('Sale price over ' . $i, 'elementor-wps'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'id_product_color_button_' . $i,\n [\n 'label' => __('Select color button', 'elementor-wps-bestsellers'),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n '301A46' => 'standart', 'ffffff' => 'white',\n '000000' => 'black',\n '795a78' => 'purple',\n '276699' => 'blue',\n ],\n 'default' => __('301A46', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_product_color_background_' . $i,\n [\n 'label' => __('Select color background', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'default' => '#ffffff',\n ]\n );\n\n $this->add_control(\n 'id_product_title_' . $i,\n [\n 'label' => __('Title product ' . $i, 'elementor-wps'),\n 'type' => \\Elementor\\Controls_Manager::TEXTAREA,\n ]\n );\n\n $this->add_control(\n 'id_product_image_' . $i,\n [\n 'label' => __('Choose Image for product ' . $i, 'elementor-wps'),\n 'type' => \\Elementor\\Controls_Manager::MEDIA,\n ]\n );\n\n $this->add_control(\n 'hr' . $i,\n [\n 'type' => \\Elementor\\Controls_Manager::DIVIDER,\n ]\n );\n\n }\n\n $this->end_controls_section();\n\n\n /**\n * New Arrivals\n */\n\n $this->start_controls_section(\n 'section_content_new_arrivals',\n [\n 'label' => __('Second tab', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'title_2',\n [\n 'label' => __('Title', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'default' => __('New arrivals', 'elementor-wps-bestsellers'),\n 'placeholder' => __('Title second tab', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'title_2_color',\n [\n 'label' => __('Title color', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'default' => '#000000',\n ]\n );\n\n $this->add_control(\n 'title_2_color_selected',\n [\n 'label' => __('Title color selected', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'default' => '#000000',\n ]\n );\n\n $this->add_control(\n 'hr0_new_arrivals',\n [\n 'type' => \\Elementor\\Controls_Manager::DIVIDER,\n ]\n );\n\n for ($pna = 1; $pna <= 4; $pna++) {\n $this->add_control(\n 'important_note_new_arrivals_' . $pna,\n [\n 'type' => \\Elementor\\Controls_Manager::RAW_HTML,\n 'raw' => __('Select ' . $pna . ' product or variant', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_product_new_arrivals_' . $pna,\n [\n 'label' => __('Select product ' . $pna, 'elementor-wps-bestsellers'),\n 'type' => Controls_Manager::SELECT2,\n 'options' => $optionProduct,\n 'default' => __('Empty', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'or_note_new_arrivals_' . $pna,\n [\n 'type' => \\Elementor\\Controls_Manager::RAW_HTML,\n 'raw' => __('OR', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_variant_new_arrivals_' . $pna,\n [\n 'label' => __('Select variant '. $pna, 'elementor-wps-bestsellers'),\n 'type' => Controls_Manager::SELECT2,\n 'options' => $optionProductVariant,\n 'default' => __('Empty', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_product_sale_new_arrivals_' . $pna,\n [\n 'label' => __('Sale price over ' . $pna, 'elementor-wps'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'id_product_color_button_new_arrivals_' . $pna,\n [\n 'label' => __('Select color button', 'elementor-wps-bestsellers'),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n '301A46' => 'standart', 'ffffff' => 'white',\n '000000' => 'black',\n '795a78' => 'purple',\n '276699' => 'blue',\n ],\n 'default' => __('301A46', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_product_color_background_new_arrivals_' . $pna,\n [\n 'label' => __('Select color background', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'default' => '#ffffff',\n ]\n );\n\n $this->add_control(\n 'id_product_title_new_arrivals_' . $pna,\n [\n 'label' => __('Title product ' . $pna, 'elementor-wps'),\n 'type' => \\Elementor\\Controls_Manager::TEXTAREA,\n ]\n );\n\n $this->add_control(\n 'id_product_image_new_arrivals_' . $pna,\n [\n 'label' => __('Choose Image for product ' . $pna, 'elementor-wps'),\n 'type' => \\Elementor\\Controls_Manager::MEDIA,\n ]\n );\n\n $this->add_control(\n 'hr_new_arrivals' . $pna,\n [\n 'type' => \\Elementor\\Controls_Manager::DIVIDER,\n ]\n );\n }\n\n $this->end_controls_section();\n\n\n /**\n * Clearance\n */\n\n $this->start_controls_section(\n 'section_content_clearance',\n [\n 'label' => __('Third tab ', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'title_3',\n [\n 'label' => __('Title', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'default' => __('Clearance', 'elementor-wps-bestsellers'),\n 'placeholder' => __('Title third tab', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'title_3_color',\n [\n 'label' => __('Title color', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'default' => '#000000',\n ]\n );\n\n $this->add_control(\n 'title_3_color_selected',\n [\n 'label' => __('Title color selected', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'default' => '#000000',\n ]\n );\n\n $this->add_control(\n 'hr0_clearance',\n [\n 'type' => \\Elementor\\Controls_Manager::DIVIDER,\n ]\n );\n\n for ($pc = 1; $pc <= 4; $pc++) {\n $this->add_control(\n 'important_note_clearance_' . $pc,\n [\n 'type' => \\Elementor\\Controls_Manager::RAW_HTML,\n 'raw' => __('Select ' . $pc . ' product or variant', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_product_clearance_' . $pc,\n [\n 'label' => __('Select product ' . $pc, 'elementor-wps-bestsellers'),\n 'type' => Controls_Manager::SELECT2,\n 'options' => $optionProduct,\n 'default' => __('Empty', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'or_note_clearance_' . $pc,\n [\n 'type' => \\Elementor\\Controls_Manager::RAW_HTML,\n 'raw' => __('OR', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_variant_clearance_' . $pc,\n [\n 'label' => __('Select variant ' . $pc, 'elementor-wps-bestsellers'),\n 'type' => Controls_Manager::SELECT2,\n 'options' => $optionProductVariant,\n 'default' => __('Empty', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_product_sale_clearance_' . $pc,\n [\n 'label' => __('Sale price over ' . $pc, 'elementor-wps'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'id_product_color_button_clearance_' . $pc,\n [\n 'label' => __('Select color button', 'elementor-wps-bestsellers'),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n '301A46' => 'standart', 'ffffff' => 'white',\n '000000' => 'black',\n '795a78' => 'purple',\n '276699' => 'blue',\n ],\n 'default' => __('301A46', 'elementor-wps-bestsellers'),\n ]\n );\n\n $this->add_control(\n 'id_product_color_background_clearance_' . $pc,\n [\n 'label' => __('Select color backgorund', 'elementor-wps-bestsellers'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'default' => '#ffffff',\n ]\n );\n\n $this->add_control(\n 'id_product_title_clearance_' . $pc,\n [\n 'label' => __('Title product ' . $pc, 'elementor-wps'),\n 'type' => \\Elementor\\Controls_Manager::TEXTAREA,\n ]\n );\n\n $this->add_control(\n 'id_product_image_clearance_' . $pc,\n [\n 'label' => __('Choose Image for product ' . $pc, 'elementor-wps'),\n 'type' => \\Elementor\\Controls_Manager::MEDIA,\n ]\n );\n\n $this->add_control(\n 'hr' . $pc . '_clearance',\n [\n 'type' => \\Elementor\\Controls_Manager::DIVIDER,\n ]\n );\n }\n\n $this->end_controls_section();\n\n }",
"protected function _register_controls()\n {\n\n /*-----------------------------------------------------------------------------------*/\n /*\tCONTENT TAB\n /*-----------------------------------------------------------------------------------*/\n\n /**\n * Content Tab: Logo Carousel\n */\n $this->start_controls_section(\n 'section_logo_carousel',\n [\n 'label' => __('Logo Carousel', SA_ELEMENTOR_TEXTDOMAIN),\n ]\n );\n\n $this->add_control(\n 'carousel-slides',\n [\n 'label' => '',\n 'type' => Controls_Manager::REPEATER,\n 'default' => [\n [\n 'logo_carousel_slide' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n ],\n [\n 'logo_carousel_slide' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n ],\n [\n 'logo_carousel_slide' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n ],\n [\n 'logo_carousel_slide' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n ],\n [\n 'logo_carousel_slide' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n ],\n ],\n 'fields' => [\n [\n 'name' => 'logo_carousel_slide',\n 'label' => __('Upload Logo Image', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::MEDIA,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n ],\n [\n 'name' => 'logo_title',\n 'label' => __('Title', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::TEXT,\n 'dynamic' => [\n 'active' => true,\n ],\n ],\n [\n 'name' => 'logo_alt',\n 'label' => __('Alt Text', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::TEXT,\n ],\n [\n 'name' => 'link',\n 'label' => __('Link', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::URL,\n 'dynamic' => [\n 'active' => true,\n ],\n 'placeholder' => 'https://www.link_here.com',\n 'default' => [\n 'url' => '',\n ],\n ],\n ],\n 'title_field' => __('Logo Image', SA_ELEMENTOR_TEXTDOMAIN),\n ]\n );\n\n $this->add_control(\n 'title_html_tag',\n [\n 'label' => __('Title HTML Tag', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'h4',\n 'options' => [\n 'h1' => __('H1', SA_ELEMENTOR_TEXTDOMAIN),\n 'h2' => __('H2', SA_ELEMENTOR_TEXTDOMAIN),\n 'h3' => __('H3', SA_ELEMENTOR_TEXTDOMAIN),\n 'h4' => __('H4', SA_ELEMENTOR_TEXTDOMAIN),\n 'h5' => __('H5', SA_ELEMENTOR_TEXTDOMAIN),\n 'h6' => __('H6', SA_ELEMENTOR_TEXTDOMAIN),\n 'div' => __('div', SA_ELEMENTOR_TEXTDOMAIN),\n 'span' => __('span', SA_ELEMENTOR_TEXTDOMAIN),\n 'p' => __('p', SA_ELEMENTOR_TEXTDOMAIN),\n ],\n ]\n );\n\n $this->end_controls_section();\n\n /**\n * Content Tab: Carousel Settings\n */\n $this->start_controls_section(\n 'section_additional_options',\n [\n 'label' => __('Carousel Settings', SA_ELEMENTOR_TEXTDOMAIN),\n ]\n );\n\n $this->add_control(\n 'carousel_effect',\n [\n 'label' => __('Effect', SA_ELEMENTOR_TEXTDOMAIN),\n 'description' => __('Sets transition effect', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'slide',\n 'options' => [\n 'slide' => __('Slide', SA_ELEMENTOR_TEXTDOMAIN),\n 'fade' => __('Fade', SA_ELEMENTOR_TEXTDOMAIN),\n 'cube' => __('Cube', SA_ELEMENTOR_TEXTDOMAIN),\n 'coverflow' => __('Coverflow', SA_ELEMENTOR_TEXTDOMAIN),\n 'flip' => __('Flip', SA_ELEMENTOR_TEXTDOMAIN),\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'items',\n [\n 'label' => __('Visible Items', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'default' => ['size' => 3],\n 'tablet_default' => ['size' => 2],\n 'mobile_default' => ['size' => 1],\n 'range' => [\n 'px' => [\n 'min' => 1,\n 'max' => 10,\n 'step' => 1,\n ],\n ],\n 'size_units' => '',\n 'condition' => [\n 'carousel_effect' => 'slide',\n ],\n 'separator' => 'before',\n ]\n );\n\n $this->add_responsive_control(\n 'margin',\n [\n 'label' => __('Items Gap', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'default' => ['size' => 10],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n 'step' => 1,\n ],\n ],\n 'size_units' => '',\n 'condition' => [\n 'carousel_effect' => 'slide',\n ],\n ]\n );\n\n $this->add_control(\n 'slider_speed',\n [\n 'label' => __('Slider Speed', SA_ELEMENTOR_TEXTDOMAIN),\n 'description' => __('Duration of transition between slides (in ms)', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'default' => ['size' => 400],\n 'range' => [\n 'px' => [\n 'min' => 100,\n 'max' => 3000,\n 'step' => 1,\n ],\n ],\n 'size_units' => '',\n 'separator' => 'before',\n ]\n );\n\n $this->add_control(\n 'autoplay',\n [\n 'label' => __('Autoplay', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'yes',\n 'label_on' => __('Yes', SA_ELEMENTOR_TEXTDOMAIN),\n 'label_off' => __('No', SA_ELEMENTOR_TEXTDOMAIN),\n 'return_value' => 'yes',\n 'separator' => 'before',\n ]\n );\n\n $this->add_control(\n 'autoplay_speed',\n [\n 'label' => __('Autoplay Speed', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'default' => ['size' => 2000],\n 'range' => [\n 'px' => [\n 'min' => 500,\n 'max' => 5000,\n 'step' => 1,\n ],\n ],\n 'size_units' => '',\n 'condition' => [\n 'autoplay' => 'yes',\n ],\n ]\n );\n\n $this->add_control(\n 'infinite_loop',\n [\n 'label' => __('Infinite Loop', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'yes',\n 'label_on' => __('Yes', SA_ELEMENTOR_TEXTDOMAIN),\n 'label_off' => __('No', SA_ELEMENTOR_TEXTDOMAIN),\n 'return_value' => 'yes',\n ]\n );\n\n $this->add_control(\n 'pause_on_hover',\n [\n 'label' => __('Pause On Hover', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => '',\n 'label_on' => __('Yes', SA_ELEMENTOR_TEXTDOMAIN),\n 'label_off' => __('No', SA_ELEMENTOR_TEXTDOMAIN),\n 'return_value' => 'yes',\n 'condition' => [\n 'autoplay' => 'yes',\n ],\n ]\n );\n\n $this->add_control(\n 'grab_cursor',\n [\n 'label' => __('Grab Cursor', SA_ELEMENTOR_TEXTDOMAIN),\n 'description' => __('Shows grab cursor when you hover over the slider', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => '',\n 'label_on' => __('Show', SA_ELEMENTOR_TEXTDOMAIN),\n 'label_off' => __('Hide', SA_ELEMENTOR_TEXTDOMAIN),\n 'return_value' => 'yes',\n 'separator' => 'before',\n ]\n );\n\n $this->add_control(\n 'navigation_heading',\n [\n 'label' => __('Navigation', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::HEADING,\n 'separator' => 'before',\n ]\n );\n\n $this->add_control(\n 'arrows',\n [\n 'label' => __('Arrows', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'yes',\n 'label_on' => __('Yes', SA_ELEMENTOR_TEXTDOMAIN),\n 'label_off' => __('No', SA_ELEMENTOR_TEXTDOMAIN),\n 'return_value' => 'yes',\n ]\n );\n\n $this->add_control(\n 'dots',\n [\n 'label' => __('Dots', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'yes',\n 'label_on' => __('Yes', SA_ELEMENTOR_TEXTDOMAIN),\n 'label_off' => __('No', SA_ELEMENTOR_TEXTDOMAIN),\n 'return_value' => 'yes',\n ]\n );\n\n $this->add_control(\n 'direction',\n [\n 'label' => __('Direction', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'left',\n 'options' => [\n 'left' => __('Left', SA_ELEMENTOR_TEXTDOMAIN),\n 'right' => __('Right', SA_ELEMENTOR_TEXTDOMAIN),\n ],\n 'separator' => 'before',\n ]\n );\n\n $this->end_controls_section();\n if (!apply_filters(SA_ELEMENTOR_TEXTDOMAIN . '/pro-enable', ['', '', TRUE])) {\n $this->start_controls_section(\n 'sa_el_section_pro',\n [\n 'label' => __('Go Premium for More Features', SA_ELEMENTOR_TEXTDOMAIN)\n ]\n );\n\n $this->add_control(\n 'sa_el_control_get_pro',\n [\n 'label' => __('Unlock more possibilities', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::CHOOSE,\n 'options' => [\n '1' => [\n 'title' => __('', SA_ELEMENTOR_TEXTDOMAIN),\n 'icon' => 'fa fa-unlock-alt',\n ],\n ],\n 'default' => '1',\n 'description' => '<span class=\"pro-feature\"> Get the <a href=\"https://www.oxilab.org/downloads/short-code-addons/\" target=\"_blank\">Pro version</a> for more stunning elements and customization options.</span>'\n ]\n );\n\n $this->end_controls_section();\n }\n /*-----------------------------------------------------------------------------------*/\n /*\tSTYLE TAB\n /*-----------------------------------------------------------------------------------*/\n\n /**\n * Style Tab: Logos\n */\n $this->start_controls_section(\n 'section_logos_style',\n [\n 'label' => __('Logos', SA_ELEMENTOR_TEXTDOMAIN),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_group_control(\n Group_Control_Background::get_type(),\n [\n 'name' => 'logo_bg',\n 'label' => __('Button Background', SA_ELEMENTOR_TEXTDOMAIN),\n 'types' => ['none', 'classic', 'gradient'],\n 'selector' => '{{WRAPPER}} .sa_el_lc_logo',\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'logo_border',\n 'label' => __('Border', SA_ELEMENTOR_TEXTDOMAIN),\n 'placeholder' => '1px',\n 'default' => '1px',\n 'selector' => '{{WRAPPER}} .sa_el_lc_logo',\n ]\n );\n\n $this->add_control(\n 'logo_border_radius',\n [\n 'label' => __('Border Radius', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', '%'],\n 'selectors' => [\n '{{WRAPPER}} .sa_el_lc_logo, {{WRAPPER}} .sa_el_lc_logo img' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'logo_padding',\n [\n 'label' => __('Padding', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', '%'],\n 'selectors' => [\n '{{WRAPPER}} .sa_el_lc_logo' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n ],\n ]\n );\n\n $this->start_controls_tabs('tabs_logos_style');\n\n $this->start_controls_tab(\n 'tab_logos_normal',\n [\n 'label' => __('Normal', SA_ELEMENTOR_TEXTDOMAIN),\n ]\n );\n\n $this->add_control(\n 'grayscale_normal',\n [\n 'label' => __('Grayscale', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'no',\n 'label_on' => __('Yes', SA_ELEMENTOR_TEXTDOMAIN),\n 'label_off' => __('No', SA_ELEMENTOR_TEXTDOMAIN),\n 'return_value' => 'yes',\n ]\n );\n\n $this->add_control(\n 'opacity_normal',\n [\n 'label' => __('Opacity', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1,\n 'step' => 0.1,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .sa_el_logo_carousel img' => 'opacity: {{SIZE}};',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'tab_logos_hover',\n [\n 'label' => __('Hover', SA_ELEMENTOR_TEXTDOMAIN),\n ]\n );\n\n $this->add_control(\n 'grayscale_hover',\n [\n 'label' => __('Grayscale', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'no',\n 'label_on' => __('Yes', SA_ELEMENTOR_TEXTDOMAIN),\n 'label_off' => __('No', SA_ELEMENTOR_TEXTDOMAIN),\n 'return_value' => 'yes',\n ]\n );\n\n $this->add_control(\n 'opacity_hover',\n [\n 'label' => __('Opacity', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1,\n 'step' => 0.1,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .sa_el_logo_carousel .swiper-slide:hover img' => 'opacity: {{SIZE}};',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->end_controls_tabs();\n\n $this->end_controls_section();\n\n /**\n * Style Tab: Title\n */\n $this->start_controls_section(\n 'section_logo_title_style',\n [\n 'label' => __('Title', SA_ELEMENTOR_TEXTDOMAIN),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_control(\n 'title_color',\n [\n 'label' => __('Color', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} .sa_el_logo_carousel_title' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'title_spacing',\n [\n 'label' => __('Margin Top', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => ['px'],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .sa_el_logo_carousel_title' => 'margin-top: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'title_typography',\n 'label' => __('Typography', SA_ELEMENTOR_TEXTDOMAIN),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_4,\n 'selector' => '{{WRAPPER}} .sa_el_logo_carousel_title',\n ]\n );\n\n $this->end_controls_section();\n\n /**\n * Style Tab: Arrows\n */\n $this->start_controls_section(\n 'section_arrows_style',\n [\n 'label' => __('Arrows', SA_ELEMENTOR_TEXTDOMAIN),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'arrows' => 'yes',\n ],\n ]\n );\n\n $this->add_control(\n 'arrow',\n [\n 'label' => __('Choose Arrow', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::ICON,\n 'label_block' => true,\n 'default' => 'fa fa-angle-right',\n 'include' => [\n 'fa fa-angle-right',\n 'fa fa-angle-double-right',\n 'fa fa-chevron-right',\n 'fa fa-chevron-circle-right',\n 'fa fa-arrow-right',\n 'fa fa-long-arrow-right',\n 'fa fa-caret-right',\n 'fa fa-caret-square-o-right',\n 'fa fa-arrow-circle-right',\n 'fa fa-arrow-circle-o-right',\n 'fa fa-toggle-right',\n 'fa fa-hand-o-right',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'arrows_size',\n [\n 'label' => __('Arrows Size', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'default' => ['size' => '22'],\n 'range' => [\n 'px' => [\n 'min' => 15,\n 'max' => 100,\n 'step' => 1,\n ],\n ],\n 'size_units' => ['px'],\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-button-next, {{WRAPPER}} .swiper-container-wrap .swiper-button-prev' => 'font-size: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'left_arrow_position',\n [\n 'label' => __('Align Left Arrow', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => -100,\n 'max' => 40,\n 'step' => 1,\n ],\n ],\n 'size_units' => ['px'],\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-button-prev' => 'left: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'right_arrow_position',\n [\n 'label' => __('Align Right Arrow', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => -100,\n 'max' => 40,\n 'step' => 1,\n ],\n ],\n 'size_units' => ['px'],\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-button-next' => 'right: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->start_controls_tabs('tabs_arrows_style');\n\n $this->start_controls_tab(\n 'tab_arrows_normal',\n [\n 'label' => __('Normal', SA_ELEMENTOR_TEXTDOMAIN),\n ]\n );\n\n $this->add_control(\n 'arrows_bg_color_normal',\n [\n 'label' => __('Background Color', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-button-next, {{WRAPPER}} .swiper-container-wrap .swiper-button-prev' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_control(\n 'arrows_color_normal',\n [\n 'label' => __('Color', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-button-next, {{WRAPPER}} .swiper-container-wrap .swiper-button-prev' => 'color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'arrows_border_normal',\n 'label' => __('Border', SA_ELEMENTOR_TEXTDOMAIN),\n 'placeholder' => '1px',\n 'default' => '1px',\n 'selector' => '{{WRAPPER}} .swiper-container-wrap .swiper-button-next, {{WRAPPER}} .swiper-container-wrap .swiper-button-prev'\n ]\n );\n\n $this->add_control(\n 'arrows_border_radius_normal',\n [\n 'label' => __('Border Radius', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', '%'],\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-button-next, {{WRAPPER}} .swiper-container-wrap .swiper-button-prev' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'tab_arrows_hover',\n [\n 'label' => __('Hover', SA_ELEMENTOR_TEXTDOMAIN),\n ]\n );\n\n $this->add_control(\n 'arrows_bg_color_hover',\n [\n 'label' => __('Background Color', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-button-next:hover, {{WRAPPER}} .swiper-container-wrap .swiper-button-prev:hover' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_control(\n 'arrows_color_hover',\n [\n 'label' => __('Color', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-button-next:hover, {{WRAPPER}} .swiper-container-wrap .swiper-button-prev:hover' => 'color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_control(\n 'arrows_border_color_hover',\n [\n 'label' => __('Border Color', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-button-next:hover, {{WRAPPER}} .swiper-container-wrap .swiper-button-prev:hover' => 'border-color: {{VALUE}};',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->end_controls_tabs();\n\n $this->add_responsive_control(\n 'arrows_padding',\n [\n 'label' => __('Padding', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', '%'],\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-button-next, {{WRAPPER}} .swiper-container-wrap .swiper-button-prev' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n ],\n 'separator' => 'before',\n ]\n );\n\n $this->end_controls_section();\n\n /**\n * Style Tab: Dots\n */\n $this->start_controls_section(\n 'section_dots_style',\n [\n 'label' => __('Pagination: Dots', SA_ELEMENTOR_TEXTDOMAIN),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->add_control(\n 'dots_position',\n [\n 'label' => __('Position', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n 'inside' => __('Inside', SA_ELEMENTOR_TEXTDOMAIN),\n 'outside' => __('Outside', SA_ELEMENTOR_TEXTDOMAIN),\n ],\n 'default' => 'outside',\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'dots_size',\n [\n 'label' => __('Size', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => 2,\n 'max' => 40,\n 'step' => 1,\n ],\n ],\n 'size_units' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-pagination-bullet' => 'height: {{SIZE}}{{UNIT}}; width: {{SIZE}}{{UNIT}}',\n ],\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'dots_spacing',\n [\n 'label' => __('Spacing', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => 1,\n 'max' => 30,\n 'step' => 1,\n ],\n ],\n 'size_units' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-pagination-bullet' => 'margin-left: {{SIZE}}{{UNIT}}; margin-right: {{SIZE}}{{UNIT}}',\n ],\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->start_controls_tabs('tabs_dots_style');\n\n $this->start_controls_tab(\n 'tab_dots_normal',\n [\n 'label' => __('Normal', SA_ELEMENTOR_TEXTDOMAIN),\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->add_control(\n 'dots_color_normal',\n [\n 'label' => __('Color', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-pagination-bullet' => 'background: {{VALUE}};',\n ],\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->add_control(\n 'active_dot_color_normal',\n [\n 'label' => __('Active Color', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-pagination-bullet-active' => 'background: {{VALUE}};',\n ],\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'dots_border_normal',\n 'label' => __('Border', SA_ELEMENTOR_TEXTDOMAIN),\n 'placeholder' => '1px',\n 'default' => '1px',\n 'selector' => '{{WRAPPER}} .swiper-container-wrap .swiper-pagination-bullet',\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->add_control(\n 'dots_border_radius_normal',\n [\n 'label' => __('Border Radius', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', '%'],\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-pagination-bullet' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n ],\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'dots_padding',\n [\n 'label' => __('Padding', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'allowed_dimensions' => 'vertical',\n 'placeholder' => [\n 'top' => '',\n 'right' => 'auto',\n 'bottom' => '',\n 'left' => 'auto',\n ],\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-pagination-bullets' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n ],\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'tab_dots_hover',\n [\n 'label' => __('Hover', SA_ELEMENTOR_TEXTDOMAIN),\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->add_control(\n 'dots_color_hover',\n [\n 'label' => __('Color', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-pagination-bullet:hover' => 'background: {{VALUE}};',\n ],\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->add_control(\n 'dots_border_color_hover',\n [\n 'label' => __('Border Color', SA_ELEMENTOR_TEXTDOMAIN),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} .swiper-container-wrap .swiper-pagination-bullet:hover' => 'border-color: {{VALUE}};',\n ],\n 'condition' => [\n 'dots' => 'yes'\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->end_controls_tabs();\n\n $this->end_controls_section();\n }",
"protected function _register_controls()\n {\n $categories = get_categories(array(\n 'orderby' => 'name',\n ));\n\n $cate_array = array(esc_html__(\"Select Category\", \"careerfy-frame\") => '');\n if (is_array($categories) && sizeof($categories) > 0) {\n foreach ($categories as $category) {\n $cate_array[$category->cat_name] = $category->slug;\n }\n }\n\n $this->start_controls_section(\n 'blog',\n [\n 'label' => __('Blog Settings', 'careerfy-frame'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'blog_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 'view7' => __('Style 6', 'careerfy-frame'),\n 'view8' => __('Style 7', 'careerfy-frame'),\n 'view9' => __('Style 8', 'careerfy-frame'),\n 'view10' => __('Style 9', 'careerfy-frame'),\n 'view11' => __('Style 10', 'careerfy-frame'),\n 'view12' => __('Style 11', 'careerfy-frame'),\n 'view13' => __('Style 12', 'careerfy-frame'),\n ],\n ]\n );\n\n $this->add_control(\n 'blog_cat',\n [\n 'label' => __('Category', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => '0',\n 'options' => $cate_array,\n ]\n );\n\n $this->add_control(\n 'blog_excerpt',\n [\n 'label' => __('Excerpt Length', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'default'=> '20',\n 'description' => __(\"Set the number of words you want to show for post excerpt.\", \"careerfy-frame\")\n ]\n );\n\n $this->add_control(\n 'blog_order',\n [\n 'label' => __('Orderby', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => 'DESC',\n 'description' => __(\"Choose blog list items orderby.\", \"careerfy-frame\"),\n 'options' => [\n 'DESC' => __('Descending', 'careerfy-frame'),\n 'ASC' => __('Ascending', 'careerfy-frame'),\n\n ],\n ]\n );\n\n $this->add_control(\n 'blog_orderby',\n [\n 'label' => __('Orderby', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => 'date',\n 'description' => __(\"Choose blog list items orderby.\", \"careerfy-frame\"),\n 'options' => [\n 'date' => __('Date', 'careerfy-frame'),\n 'title' => __('Title', 'careerfy-frame'),\n\n ],\n ]\n );\n\n $this->add_control(\n 'blog_pagination',\n [\n 'label' => __('Pagination', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => 'yes',\n 'description' => __(\"Choose Yes if you want to show pagination for post items.\", \"careerfy-frame\"),\n 'options' => [\n 'yes' => __('Yes', 'careerfy-frame'),\n 'no' => __('No', 'careerfy-frame'),\n ],\n 'condition' => [\n 'blog_view' => array('view1', 'view2', 'view3', 'view4', 'view5', 'view9', 'view10', 'view11', 'view12', 'view13')\n ]\n ]\n );\n\n $this->add_control(\n 'blog_per_page',\n [\n 'label' => __('Posts per Page', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'default' => '9',\n 'description' => __(\"Set number that how much posts you want to show per page. Leave it blank for all posts on a single page.\", \"careerfy-frame\")\n ]\n );\n\n $this->end_controls_section();\n }",
"protected function _register_controls()\n {\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => __('Recent Questions Settings', 'careerfy-frame'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'ques_title',\n [\n 'label' => __('Title', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n ]\n );\n\n $repeater = new \\Elementor\\Repeater();\n $repeater->add_control(\n 'q_question', [\n 'label' => __('Question', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n ]\n );\n\n $repeater->add_control(\n 'q_url', [\n 'label' => __('Link', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'careerfy_recent_questions_item',\n [\n 'label' => __('Add recent questions item', 'careerfy-frame'),\n 'type' => Controls_Manager::REPEATER,\n 'fields' => $repeater->get_controls(),\n 'title_field' => '{{{ q_question }}}',\n ]\n );\n $this->end_controls_section();\n }"
] | [
"0.6981561",
"0.6934344",
"0.6895935",
"0.684285",
"0.6788226",
"0.678671",
"0.67617786",
"0.6753755",
"0.67046857",
"0.6665382",
"0.66578966",
"0.6631825",
"0.6613909",
"0.6600231",
"0.6590594",
"0.6545432",
"0.6526226",
"0.65014035",
"0.6481853",
"0.6476151",
"0.6468848",
"0.6447964",
"0.64304113",
"0.6417278",
"0.6386615",
"0.6370399",
"0.6297587",
"0.62828153",
"0.6280017",
"0.62698066"
] | 0.8415835 | 0 |
Order the controls by given priority. | private function order_by_priority() {
$order = array();
foreach ( $this->controls as $key => $control_object ) {
$order[ $key ] = $control_object->priority;
}
array_multisort( $order, SORT_ASC, $this->controls );
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function order_by_priority() {\n\t\t\t\tuasort($this->queue,array($this,'order_by_callback'));\n\t\t\t}",
"function maybe_orderby() {\n\t\t$this->validate_orderby_order();\n\n\t\tforeach ( (array) $this->orderby as $priority => $orderby ) {\n\t\t\tswitch ( $orderby ) {\n\t\t\t\tcase 'date':\n\t\t\t\t\t$mod = new \\SearchWP\\Mod();\n\n\t\t\t\t\t$mod->raw_join_sql( function( $runtime ) {\n\t\t\t\t\t\tglobal $wpdb;\n\n\t\t\t\t\t\treturn \"LEFT JOIN {$wpdb->posts} swpqueryorder ON (swpqueryorder.ID = {$runtime->get_foreign_alias()}.id)\";\n\t\t\t\t\t} );\n\n\t\t\t\t\t$mod->order_by( 'swpqueryorder.post_date', $this->order[ $priority ], $priority + 1 );\n\n\t\t\t\t\t$this->mods[] = $mod;\n\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'rand':\n\t\t\t\tcase 'random':\n\t\t\t\t\t$mod = new \\SearchWP\\Mod();\n\t\t\t\t\t$mod->order_by( 'random', $priority );\n\n\t\t\t\t\t$this->mods[] = $mod;\n\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'relevance':\n\t\t\t\t\t// By default there is already a relevance Mod in place at priority 10.\n\t\t\t\t\t// $mod = new \\SearchWP\\Mod();\n\t\t\t\t\t// $mod->order_by( 'relevance', $this->order[ $priority ], $priority + 1 );\n\n\t\t\t\t\t// $this->mods[] = $mod;\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'title':\n\t\t\t\t\t$mod = new \\SearchWP\\Mod();\n\n\t\t\t\t\t$mod->raw_join_sql( function( $runtime ) {\n\t\t\t\t\t\tglobal $wpdb;\n\n\t\t\t\t\t\treturn \"LEFT JOIN {$wpdb->posts} swpqueryorder ON (swpqueryorder.ID = {$runtime->get_foreign_alias()}.id)\";\n\t\t\t\t\t} );\n\n\t\t\t\t\t$mod->order_by( 'swpqueryorder.post_title', $this->order[ $priority ], $priority + 1 );\n\n\t\t\t\t\t$this->mods[] = $mod;\n\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}",
"function set_priorities()\n\t{\n\t\treturn array( 'action_form_comment' => 10, );\n\t}",
"function SetupSortOrder() {\n\n\t\t// Check for Ctrl pressed\n\t\t$bCtrl = (@$_GET[\"ctrl\"] <> \"\");\n\n\t\t// Check for \"order\" parameter\n\t\tif (@$_GET[\"order\"] <> \"\") {\n\t\t\t$this->CurrentOrder = @$_GET[\"order\"];\n\t\t\t$this->CurrentOrderType = @$_GET[\"ordertype\"];\n\t\t\t$this->UpdateSort($this->id, $bCtrl); // id\n\t\t\t$this->UpdateSort($this->id_actividad, $bCtrl); // id_actividad\n\t\t\t$this->UpdateSort($this->apellidopaterno, $bCtrl); // apellidopaterno\n\t\t\t$this->UpdateSort($this->apellidomaterno, $bCtrl); // apellidomaterno\n\t\t\t$this->UpdateSort($this->nombre, $bCtrl); // nombre\n\t\t\t$this->UpdateSort($this->nrodiscapacidad, $bCtrl); // nrodiscapacidad\n\t\t\t$this->UpdateSort($this->ci, $bCtrl); // ci\n\t\t\t$this->UpdateSort($this->fecha_nacimiento, $bCtrl); // fecha_nacimiento\n\t\t\t$this->UpdateSort($this->sexo, $bCtrl); // sexo\n\t\t\t$this->UpdateSort($this->nivelestudio, $bCtrl); // nivelestudio\n\t\t\t$this->UpdateSort($this->id_discapacidad, $bCtrl); // id_discapacidad\n\t\t\t$this->UpdateSort($this->id_tipodiscapacidad, $bCtrl); // id_tipodiscapacidad\n\t\t\t$this->UpdateSort($this->resultado, $bCtrl); // resultado\n\t\t\t$this->UpdateSort($this->resultadotamizaje, $bCtrl); // resultadotamizaje\n\t\t\t$this->UpdateSort($this->tapon, $bCtrl); // tapon\n\t\t\t$this->UpdateSort($this->tipo, $bCtrl); // tipo\n\t\t\t$this->UpdateSort($this->repetirprueba, $bCtrl); // repetirprueba\n\t\t\t$this->UpdateSort($this->observaciones, $bCtrl); // observaciones\n\t\t\t$this->UpdateSort($this->id_apoderado, $bCtrl); // id_apoderado\n\t\t\t$this->UpdateSort($this->id_referencia, $bCtrl); // id_referencia\n\t\t\t$this->setStartRecordNumber(1); // Reset start position\n\t\t}\n\t}",
"public function sort_decisions() {\n\t\t$this->uasort( function( Decision $a, Decision $b ) {\n\t\t\treturn $a->priority < $b->priority ? -1 : 1;\n\t\t} );\n\t}",
"public function sort() {\n\t\tuasort($this->scenarios, function (Scenario $firstScenario, Scenario $secondScenario) {\n\t\t\treturn $firstScenario->getPriority() <=> $secondScenario->getPriority();\n\t\t});\n\t}",
"function SetUpSortOrder() {\n\n\t\t// Check for Ctrl pressed\n\t\t$bCtrl = (@$_GET[\"ctrl\"] <> \"\");\n\n\t\t// Check for \"order\" parameter\n\t\tif (@$_GET[\"order\"] <> \"\") {\n\t\t\t$this->CurrentOrder = ew_StripSlashes(@$_GET[\"order\"]);\n\t\t\t$this->CurrentOrderType = @$_GET[\"ordertype\"];\n\t\t\t$this->UpdateSort($this->NOMR, $bCtrl); // NOMR\n\t\t\t$this->UpdateSort($this->NAMA, $bCtrl); // NAMA\n\t\t\t$this->UpdateSort($this->TEMPAT, $bCtrl); // TEMPAT\n\t\t\t$this->UpdateSort($this->TGLLAHIR, $bCtrl); // TGLLAHIR\n\t\t\t$this->UpdateSort($this->JENISKELAMIN, $bCtrl); // JENISKELAMIN\n\t\t\t$this->UpdateSort($this->ALAMAT, $bCtrl); // ALAMAT\n\t\t\t$this->UpdateSort($this->NOTELP, $bCtrl); // NOTELP\n\t\t\t$this->setStartRecordNumber(1); // Reset start position\n\t\t}\n\t}",
"public function prepare_conditions_for_controls() {\n\n\t\t\t$sorted_conditions = array();\n\n\t\t\tforeach ( $this->_conditions as $cid => $instance ) {\n\n\t\t\t\tif ( in_array( $cid, $this->_processed_childs ) ) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t$group = $instance->get_group();\n\t\t\t\t$childs = $instance->get_childs();\n\n\t\t\t\tif ( ! isset( $sorted_conditions[ $group ] ) ) {\n\t\t\t\t\t$sorted_conditions[ $group ] = array();\n\t\t\t\t}\n\n\t\t\t\t$current = array(\n\t\t\t\t\t'label' => $instance->get_label(),\n\t\t\t\t);\n\n\t\t\t\tif ( ! empty( $childs ) ) {\n\t\t\t\t\t$current['childs'] = $this->add_condition_childs( $childs );\n\t\t\t\t}\n\n\t\t\t\t$sorted_conditions[ $group ][ $cid ] = $current;\n\n\t\t\t}\n\n\t\t\treturn $sorted_conditions;\n\t\t}",
"public function getSortOrder()\n\t\t{\n\t\t\treturn \"order by priority desc, date_available asc, date_queued asc\";\n\t\t}",
"function SetUpSortOrder() {\n\n\t\t// Check for Ctrl pressed\n\t\t$bCtrl = (@$_GET[\"ctrl\"] <> \"\");\n\n\t\t// Check for \"order\" parameter\n\t\tif (@$_GET[\"order\"] <> \"\") {\n\t\t\t$this->CurrentOrder = ew_StripSlashes(@$_GET[\"order\"]);\n\t\t\t$this->CurrentOrderType = @$_GET[\"ordertype\"];\n\t\t\t$this->UpdateSort($this->IDXDAFTAR, $bCtrl); // IDXDAFTAR\n\t\t\t$this->UpdateSort($this->NOMR, $bCtrl); // NOMR\n\t\t\t$this->UpdateSort($this->KDCARABAYAR, $bCtrl); // KDCARABAYAR\n\t\t\t$this->UpdateSort($this->NIP, $bCtrl); // NIP\n\t\t\t$this->UpdateSort($this->JAMREG, $bCtrl); // JAMREG\n\t\t\t$this->UpdateSort($this->NO_SJP, $bCtrl); // NO_SJP\n\t\t\t$this->UpdateSort($this->NOKARTU, $bCtrl); // NOKARTU\n\t\t\t$this->UpdateSort($this->USER, $bCtrl); // USER\n\t\t\t$this->setStartRecordNumber(1); // Reset start position\n\t\t}\n\t}",
"public function setPriority($priority);",
"public function setPriority($priority);",
"public function setPriority($priority);",
"function mysupport_update_setting_orders()\r\n{\r\n\tglobal $db;\r\n\t\r\n\t$settings = mysupport_setting_names();\r\n\t\r\n\t$i = 1;\r\n\tforeach($settings as $setting)\r\n\t{\r\n\t\t$update = array(\r\n\t\t\t\"disporder\" => $i\r\n\t\t);\r\n\t\t$db->update_query(\"settings\", $update, \"name = '\" . $db->escape_string($setting) . \"'\");\r\n\t\t$i++;\r\n\t}\r\n\t\r\n\trebuild_settings();\r\n}",
"public function setPriority($value);",
"function set_custom_post_types_admin_order($wp_query) {\n if (is_admin()) {\n $post_type = $wp_query->query['post_type'];\n if ( $post_type == 'libtech_snowboards' || $post_type == 'libtech_nas' || $post_type == 'libtech_skateboards' || $post_type == 'libtech_awards' || $post_type == 'libtech_technology' || $post_type == 'libtech_outerwear' || $post_type == 'libtech_apparel' || $post_type == 'libtech_accessories' || $post_type == 'libtech_team_snow' || $post_type == 'libtech_team_nas' || $post_type == 'libtech_team_skate' || $post_type == 'libtech_dealers' || $post_type == 'libtech_partners') {\n $wp_query->set('orderby', 'menu_order');\n $wp_query->set('order', 'ASC');\n }\n }\n}",
"function SetUpSortOrder() {\n\n\t\t// Check for Ctrl pressed\n\t\t$bCtrl = (@$_GET[\"ctrl\"] <> \"\");\n\n\t\t// Check for \"order\" parameter\n\t\tif (@$_GET[\"order\"] <> \"\") {\n\t\t\t$this->CurrentOrder = ew_StripSlashes(@$_GET[\"order\"]);\n\t\t\t$this->CurrentOrderType = @$_GET[\"ordertype\"];\n\t\t\t$this->UpdateSort($this->llave, $bCtrl); // llave\n\t\t\t$this->UpdateSort($this->F_Sincron, $bCtrl); // F_Sincron\n\t\t\t$this->UpdateSort($this->USUARIO, $bCtrl); // USUARIO\n\t\t\t$this->UpdateSort($this->Cargo_gme, $bCtrl); // Cargo_gme\n\t\t\t$this->UpdateSort($this->NOM_PE, $bCtrl); // NOM_PE\n\t\t\t$this->UpdateSort($this->Otro_PE, $bCtrl); // Otro_PE\n\t\t\t$this->UpdateSort($this->NOM_APOYO, $bCtrl); // NOM_APOYO\n\t\t\t$this->UpdateSort($this->Otro_Nom_Apoyo, $bCtrl); // Otro_Nom_Apoyo\n\t\t\t$this->UpdateSort($this->Otro_CC_Apoyo, $bCtrl); // Otro_CC_Apoyo\n\t\t\t$this->UpdateSort($this->NOM_ENLACE, $bCtrl); // NOM_ENLACE\n\t\t\t$this->UpdateSort($this->Otro_Nom_Enlace, $bCtrl); // Otro_Nom_Enlace\n\t\t\t$this->UpdateSort($this->Otro_CC_Enlace, $bCtrl); // Otro_CC_Enlace\n\t\t\t$this->UpdateSort($this->NOM_PGE, $bCtrl); // NOM_PGE\n\t\t\t$this->UpdateSort($this->Otro_Nom_PGE, $bCtrl); // Otro_Nom_PGE\n\t\t\t$this->UpdateSort($this->Otro_CC_PGE, $bCtrl); // Otro_CC_PGE\n\t\t\t$this->UpdateSort($this->Departamento, $bCtrl); // Departamento\n\t\t\t$this->UpdateSort($this->Muncipio, $bCtrl); // Muncipio\n\t\t\t$this->UpdateSort($this->NOM_VDA, $bCtrl); // NOM_VDA\n\t\t\t$this->UpdateSort($this->LATITUD, $bCtrl); // LATITUD\n\t\t\t$this->UpdateSort($this->GRA_LAT, $bCtrl); // GRA_LAT\n\t\t\t$this->UpdateSort($this->MIN_LAT, $bCtrl); // MIN_LAT\n\t\t\t$this->UpdateSort($this->SEG_LAT, $bCtrl); // SEG_LAT\n\t\t\t$this->UpdateSort($this->GRA_LONG, $bCtrl); // GRA_LONG\n\t\t\t$this->UpdateSort($this->MIN_LONG, $bCtrl); // MIN_LONG\n\t\t\t$this->UpdateSort($this->SEG_LONG, $bCtrl); // SEG_LONG\n\t\t\t$this->UpdateSort($this->FECHA_ACC, $bCtrl); // FECHA_ACC\n\t\t\t$this->UpdateSort($this->HORA_ACC, $bCtrl); // HORA_ACC\n\t\t\t$this->UpdateSort($this->Hora_ingreso, $bCtrl); // Hora_ingreso\n\t\t\t$this->UpdateSort($this->FP_Armada, $bCtrl); // FP_Armada\n\t\t\t$this->UpdateSort($this->FP_Ejercito, $bCtrl); // FP_Ejercito\n\t\t\t$this->UpdateSort($this->FP_Policia, $bCtrl); // FP_Policia\n\t\t\t$this->UpdateSort($this->NOM_COMANDANTE, $bCtrl); // NOM_COMANDANTE\n\t\t\t$this->UpdateSort($this->TESTI1, $bCtrl); // TESTI1\n\t\t\t$this->UpdateSort($this->CC_TESTI1, $bCtrl); // CC_TESTI1\n\t\t\t$this->UpdateSort($this->CARGO_TESTI1, $bCtrl); // CARGO_TESTI1\n\t\t\t$this->UpdateSort($this->TESTI2, $bCtrl); // TESTI2\n\t\t\t$this->UpdateSort($this->CC_TESTI2, $bCtrl); // CC_TESTI2\n\t\t\t$this->UpdateSort($this->CARGO_TESTI2, $bCtrl); // CARGO_TESTI2\n\t\t\t$this->UpdateSort($this->Afectados, $bCtrl); // Afectados\n\t\t\t$this->UpdateSort($this->NUM_Afectado, $bCtrl); // NUM_Afectado\n\t\t\t$this->UpdateSort($this->Nom_Afectado, $bCtrl); // Nom_Afectado\n\t\t\t$this->UpdateSort($this->CC_Afectado, $bCtrl); // CC_Afectado\n\t\t\t$this->UpdateSort($this->Cargo_Afectado, $bCtrl); // Cargo_Afectado\n\t\t\t$this->UpdateSort($this->Tipo_incidente, $bCtrl); // Tipo_incidente\n\t\t\t$this->UpdateSort($this->Riesgo, $bCtrl); // Riesgo\n\t\t\t$this->UpdateSort($this->Parte_Cuerpo, $bCtrl); // Parte_Cuerpo\n\t\t\t$this->UpdateSort($this->ESTADO_AFEC, $bCtrl); // ESTADO_AFEC\n\t\t\t$this->UpdateSort($this->EVACUADO, $bCtrl); // EVACUADO\n\t\t\t$this->UpdateSort($this->DESC_ACC, $bCtrl); // DESC_ACC\n\t\t\t$this->UpdateSort($this->Modificado, $bCtrl); // Modificado\n\t\t\t$this->UpdateSort($this->llave_2, $bCtrl); // llave_2\n\t\t\t$this->setStartRecordNumber(1); // Reset start position\n\t\t}\n\t}",
"public function change_priority()\n {\n $a_status['priority'] = $this->input->post(\"priority\");\n $this->Generic_model->updateData(\"appointments\", $a_status, array(\n 'appointment_id' => $this->input->post(\"appointment_id\")));\n }",
"function SetUpSortOrder() {\n\t\tglobal $CustomView1;\n\n\t\t// Check for an Order parameter\n\t\tif (@$_GET[\"order\"] <> \"\") {\n\t\t\t$CustomView1->CurrentOrder = ew_StripSlashes(@$_GET[\"order\"]);\n\t\t\t$CustomView1->CurrentOrderType = @$_GET[\"ordertype\"];\n\t\t\t$CustomView1->UpdateSort($CustomView1->DetailNo); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->PatientID); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->StudyDate); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->StudyTime); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->PatientName); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->PatientSex); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->Modality); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->ProtocolName); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->BodyPartExamined); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->StudyID); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->InstanceNumber); // Field \n\t\t\t$CustomView1->UpdateSort($CustomView1->Status); // Field \n\t\t\t$CustomView1->setStartRecordNumber(1); // Reset start position\n\t\t}\n\t}",
"static function get_sort_order_options() {\n return array(\"weight\" => t(\"Manual\"),\n \"captured\" => t(\"Date captured\"),\n \"created\" => t(\"Date uploaded\"),\n \"title\" => t(\"Title\"),\n \"name\" => t(\"File name\"),\n \"updated\" => t(\"Date modified\"),\n \"view_count\" => t(\"Number of views\"),\n \"rand_key\" => t(\"Random\"));\n }",
"public function getPriority()\n {\n return 10;\n }",
"public function getPriority()\n {\n return 1;\n }",
"public function getPriority()\n {\n return 1;\n }",
"public function load_controls() {\n\t\tif ( empty( $this->control_classes ) ) {\n\t\t\treturn;\n\t\t}\n\t\tforeach ( $this->control_classes as $control_manager ) {\n\t\t\t$control_instance = new $control_manager();\n\t\t\tif ( ! $control_instance instanceof Controls_Base ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$control_instance->init();\n\n\t\t\t$this->controls = array_merge( $this->controls, $control_instance->get_controls() );\n\t\t}\n\t\t$this->order_by_priority();\n\t}",
"function orderByPrioritas(){\r\n\t\t$query = \"SELECT * FROM tb_to_do ORDER BY prioritas ASC\";\r\n\r\n\t\t// Mengeksekusi query\r\n\t\treturn $this->execute($query);\r\n\t}",
"protected function getPriority(): int\n\t{\n\t\treturn 10;\n\t}",
"function SetUpSortOrder() {\r\n\t\tglobal $tbl_group;\r\n\r\n\t\t// Check for \"order\" parameter\r\n\t\tif (@$_GET[\"order\"] <> \"\") {\r\n\t\t\t$tbl_group->CurrentOrder = ew_StripSlashes(@$_GET[\"order\"]);\r\n\t\t\t$tbl_group->CurrentOrderType = @$_GET[\"ordertype\"];\r\n\t\t\t$tbl_group->UpdateSort($tbl_group->id); // id\r\n\t\t\t$tbl_group->UpdateSort($tbl_group->name); // name\r\n\t\t\t$tbl_group->UpdateSort($tbl_group->is_active); // is_active\r\n\t\t\t$tbl_group->setStartRecordNumber(1); // Reset start position\r\n\t\t}\r\n\t}",
"public function getPriority();",
"public function getPriority();",
"public function getPriority();"
] | [
"0.63136536",
"0.57631797",
"0.5755133",
"0.56629986",
"0.56162024",
"0.55845135",
"0.5522841",
"0.55021906",
"0.5414609",
"0.5413844",
"0.5404706",
"0.5404706",
"0.5404706",
"0.53871036",
"0.5385897",
"0.53834736",
"0.5349149",
"0.5328467",
"0.5327462",
"0.5326487",
"0.5305248",
"0.52945447",
"0.52945447",
"0.5253084",
"0.52493864",
"0.5243278",
"0.52368283",
"0.5208055",
"0.5208055",
"0.5208055"
] | 0.8801825 | 0 |
Activates a share. For shares that are created via configlets (e.g. web apps), this method can be called postinstall to activate the share. | function activate($name)
{
clearos_profile(__METHOD__, __LINE__);
$share = $this->get_share($name);
$folder = new Folder($share['ShareDir']);
if (!$folder->exists())
$folder->create(self::CONSTANT_WEB_APP_USERNAME, 'allusers', '0770'); // FIXME: allusers
$this->set_share_state($name, TRUE);
$this->update_share($name, TRUE);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function activate() {\r\n\t\t\t$this->addInstallInstance();\r\n\t\t\tset_transient( '_fp_activation_redirect', 1, 60 * 60 );\r\n\t\t\tdo_action('foodpress_activate');\r\n\t\t}",
"public function activate() {\n $install_controller = self::get_controller( 'Install' );\n $install_controller->install();\n }",
"public function activate() \n {\n $installed = get_option(\"WD_MY_META_installed\");\n if( ! $installed ) {\n update_option('WD_MY_META_installed', time());\n }\n update_option('WD_MY_META_version', WD_MY_META_VERSION);\n }",
"public function setShareType($shareType);",
"public function setIsExternalShareEnabled($val)\n {\n $this->_propDict[\"isExternalShareEnabled\"] = $val;\n return $this;\n }",
"function set_share_state($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $share = $this->get_share($name);\n $state_value = ($state) ? 1 : 0;\n\n $this->_set_parameter($name, 'ShareEnabled', $state_value);\n\n $this->_update_folder_links($name, $this->_get_parameter($name, 'ShareDir'));\n }",
"public function activate() {\n\n // module get activated again - what about using this method for license check of module?\n\n return true;\n }",
"public function activate_extension()\n\t{\n\t\t// Setup custom settings in this array.\n\t\t$this->settings = array();\n\t\t\n\t\t$data = array(\n\t\t\t'class'\t\t=> __CLASS__,\n\t\t\t'method'\t=> 'publish_form_channel_preferences',\n\t\t\t'hook'\t\t=> 'publish_form_channel_preferences',\n\t\t\t'settings'\t=> serialize($this->settings),\n\t\t\t'version'\t=> $this->version,\n\t\t\t'enabled'\t=> 'y'\n\t\t);\n\n\t\t$this->EE->db->insert('extensions', $data);\t\t\t\n\t\t\n\t}",
"public function activate()\n {\n flush_rewrite_rules();\n $installer = new Book\\Store\\Installer();\n $installer->run();\n }",
"public function activate()\n {\n if ($this->can_install()) {\n require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'install' . DIRECTORY_SEPARATOR . 'activate.php');\n $install = new PeepSoActivate();\n $res = $install->plugin_activation();\n if (FALSE === $res) {\n // error during installation - disable\n deactivate_plugins(plugin_basename(__FILE__));\n } else if (NULL === get_option('peepso_install_date', NULL)) {\n add_option('peepso_install_date', date('Y-m-d'));\n\n if(class_exists('PeepSoConfigSettings') && function_exists('get_option')) {\n $PeepSoConfigSettings = PeepSoConfigSettings::get_instance();\n $PeepSoConfigSettings->set_option('site_emails_admin_email', get_option('admin_email'));\n }\n }\n }\n }",
"public function share(bool $share = true)\n {\n // cannot be shared\n }",
"public function activate() {\n\t\t$settings = array(\n\t\t\t'rda_access_switch' => 'manage_options',\n\t\t\t'rda_access_cap' => 'manage_options',\n\t\t\t'rda_redirect_url' => home_url(),\n\t\t\t'rda_enable_profile' => 1,\n\t\t\t'rda_login_message' => ''\n\t\t);\n\n\t\tforeach ( $settings as $key => $value ) {\n\t\t\tadd_option( $key, $value );\n\t\t}\n\t}",
"private static function single_activate() {\n\n\t\tglobal $mspdb;\n\t\t$mspdb->create_tables();\n\n\t\t// add masterslider custom caps\n\t\tself::assign_custom_caps();\n\t\tdo_action( 'masterslider_activated', get_current_blog_id() );\n\t}",
"public function activate() {\n $installer = new WdStudentInfo\\Installer();\n $installer->run();\n }",
"private static function single_activate() {\n\t\t// @TODO: Define activation functionality here\n\t}",
"public function activate()\r\n\t{\r\n\t\t$this->active = true;\r\n\t}",
"public function activate_extension()\n\t{\n\t\t//the module will install the extension if needed\n\t\treturn true;\n\t}",
"public function activate()\n {\n $this->activated = 1;\n $this->activation_code = null;\n $this->save();\n }",
"public function enable()\n {\n $this->app['events']->fire('plugin.enabling', [$this]);\n\n $this->setActive(1);\n\n $this->app['events']->fire('plugin.enabled', [$this]);\n }",
"public function updateShareableAction() {\n // Validate request methods\n $this->validateRequestMethod('POST');\n\n $db = Engine_Api::_()->getDbtable('actions', 'advancedactivity')->getAdapter();\n $db->beginTransaction();\n try {\n $this->_action->shareable = !$this->_action->shareable;\n $this->_action->save();\n $db->commit();\n\n $this->respondWithSuccess($this->_action->shareable);\n } catch (Exception $e) {\n $db->rollBack();\n $this->respondWithValidationError('internal_server_error', $e->getMessage());\n }\n }",
"public function activate()\r\n\t{\r\n\t\t$this->default_settings();\r\n\t}",
"public function activate_extension()\n {\n // Setup custom settings in this array.\n $this->settings = array();\n\n $data = array(\n 'class' => __CLASS__,\n 'method' => 'on_channel_entries_query_result',\n 'hook' => 'channel_entries_query_result',\n 'settings' => serialize($this->settings),\n 'version' => $this->version,\n 'enabled' => 'y',\n );\n\n ee()->db->insert('extensions', $data);\n\n }",
"public function activate()\n {\n $this->config->doNotTrackEnabled = true;\n }",
"public function activate() {\n $installer = new Nbr\\Book\\Review\\Admin\\Installer();\n $installer->run();\n }",
"public function plugin_activate() {\n \n }",
"public function setShare($val)\n {\n $this->_propDict[\"share\"] = $val;\n return $this;\n }",
"public static function Install() \n\t{ \n\t\tself::setInstalled(true); \n\t}",
"private function activate() {\n\t\t// Init to use the common filters.\n\t\tnew \\RankMath\\Defaults();\n\n\t\t$current_version = get_option( 'rank_math_version', null );\n\t\t$current_db_version = get_option( 'rank_math_db_version', null );\n\n\t\t$this->create_options();\n\t\t$this->set_capabilities();\n\t\t$this->create_cron_jobs();\n\n\t\tif ( is_null( $current_version ) && is_null( $current_db_version ) ) {\n\t\t\tset_transient( '_rank_math_activation_redirect', 1, 30 );\n\t\t}\n\n\t\t// Update to latest version.\n\t\tupdate_option( 'rank_math_version', rank_math()->version );\n\t\tupdate_option( 'rank_math_db_version', rank_math()->db_version );\n\n\t\t// Clear rollback option if necessary.\n\t\tif ( rank_math()->version !== get_option( 'rank_math_rollback_version' ) ) {\n\t\t\tdelete_option( 'rank_math_rollback_version' );\n\t\t}\n\n\t\t// Save install date.\n\t\tif ( false === boolval( get_option( 'rank_math_install_date' ) ) ) {\n\t\t\tupdate_option( 'rank_math_install_date', current_time( 'timestamp' ) );\n\t\t}\n\n\t\t// Activate Watcher.\n\t\t$watcher = new Watcher();\n\t\t$watcher->check_activated_plugin();\n\n\t\t$this->clear_rewrite_rules( true );\n\t\tHelper::clear_cache();\n\n\t\t$this->do_action( 'activate' );\n\t}",
"public function activate_extension()\n\t{\n\t\t// Setup custom settings in this array.\n\t\t$this->settings = array();\n\n\t\t$hooks = array(\n\t\t\t'entry_submission_end',\n\t\t\t'update_multi_entries_loop',\n\t\t\t'cp_menu_array'\n\t\t);\n\n\t\tforeach($hooks as $hook)\n\t\t{\n\t\t\t$data = array(\n\t\t\t\t'class'\t\t=> __CLASS__,\n\t\t\t\t'method'\t=> $hook,\n\t\t\t\t'hook'\t\t=> $hook,\n\t\t\t\t'settings'\t=> serialize($this->settings),\n\t\t\t\t'version'\t=> $this->version,\n\t\t\t\t'enabled'\t=> 'y'\n\t\t\t);\n\n\t\t\tee()->db->insert('extensions', $data);\n\t\t}\t\n\t\t\n\t}",
"public function activate() {\n\n\n\n\t\t//$this->create_update_database();\n\t\t//$this->create_user_role();\n\t\t$this->create_user_roles();\n\t\techo \"Mplugin Activated\";\n\t\t\n\t\t\n\t}"
] | [
"0.5732736",
"0.57107675",
"0.545196",
"0.5451936",
"0.5439268",
"0.5366786",
"0.5348116",
"0.53234416",
"0.5315344",
"0.5305546",
"0.52819777",
"0.5257667",
"0.5228405",
"0.5218459",
"0.5172761",
"0.51575434",
"0.51217425",
"0.5077242",
"0.50668836",
"0.5032569",
"0.5010449",
"0.5003548",
"0.4996851",
"0.49925667",
"0.49791163",
"0.4972114",
"0.49600154",
"0.49484876",
"0.49386743",
"0.49249437"
] | 0.69117695 | 0 |
Auto configures Flexshare on events like a network change. | function auto_configure()
{
clearos_profile(__METHOD__, __LINE__);
try {
if (clearos_library_installed('ftp/ProFTPd')) {
$this->_generate_ftp_flexshares();
$proftpd = new ProFTPd();
$proftpd->reset(TRUE);
}
} catch (Exception $e) {
// Not fatal
}
try {
if (clearos_library_installed('web_server/Httpd')) {
$this->_generate_web_flexshares();
$httpd = new Httpd();
$httpd->reset(TRUE);
}
} catch (Exception $e) {
// Not fatal
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function slideshare()\n {\n if ($this->options->slideshare->active == true) {\n wp_oembed_remove_provider('#https?://(.+?\\.)?slideshare\\.net/.*#i');\n $this->registerHandler('slideshare');\n }\n }",
"public function setShared($shared);",
"function set_share_state($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $share = $this->get_share($name);\n $state_value = ($state) ? 1 : 0;\n\n $this->_set_parameter($name, 'ShareEnabled', $state_value);\n\n $this->_update_folder_links($name, $this->_get_parameter($name, 'ShareDir'));\n }",
"private function setupSharedEvents()\n {\n $sm = $this->_sm; // service manager\n $controllerLoader = $sm->get('ControllerLoader');\n $this->sharedManager->attach(\n 'Financial', 'appointmentJobTypeChanged', function (Event $evt) use ($controllerLoader) {\n $detailsController = $controllerLoader->get('Financial\\Controller\\Details');\n $detailsController->onStatementJobTypeChanged($evt);\n }\n );\n }",
"function activate($name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $share = $this->get_share($name);\n\n $folder = new Folder($share['ShareDir']);\n\n if (!$folder->exists())\n $folder->create(self::CONSTANT_WEB_APP_USERNAME, 'allusers', '0770'); // FIXME: allusers\n\n $this->set_share_state($name, TRUE);\n $this->update_share($name, TRUE);\n }",
"public function setConfig(): void;",
"public function setConfig()\n {\n // section 10-10--91-60-7f09995f:12e75e0bc39:-8000:0000000000000946 begin\n // section 10-10--91-60-7f09995f:12e75e0bc39:-8000:0000000000000946 end\n }",
"function setToLocalConf($a_socialMedia) {\r\n\t\t// stolen from core =)\r\n\t\t\r\n\t\t// Instance of install tool\r\n\t\t$instObj = new t3lib_install;\r\n\t\t$instObj->allowUpdateLocalConf = 1;\r\n\t\t$instObj->updateIdentity = 'TYPO3 Social Connect Extension';\r\n\t\t\r\n\t\t// Get lines from localconf file\r\n\t\t$lines = $instObj->writeToLocalconf_control();\r\n\t\t$serializedData = serialize($a_socialMedia);\r\n\t\t$instObj->setValueInLocalconfFile($lines, '$TYPO3_CONF_VARS[\\'EXT\\'][\\'extConf\\'][\\''.self :: $extKey.'\\']', $serializedData);\r\n\t\t$instObj->writeToLocalconf_control($lines);\r\n\t\tt3lib_extMgm::removeCacheFiles();\r\n\t}",
"function smartrest_activate() {\n smartrest_add_endpoint();\n // flush rewrite rules - only do this on activation as anything more frequent is bad!\n flush_rewrite_rules();\n}",
"function configure() {\n\t}",
"public static function share_cache(){\n self::$cache_shared = true;\n }",
"function brokerStartup(){\n\t\t$this->layout = 'short_app';\n\t\t$this->Session->write('activeMenu','broker');\n\t}",
"function gen_astmanproxy_conf()\n{\n\tglobal $__BRD_SUM__;\n\tglobal $__BRD_HEAD__;\n\t$cfg_path = '/etc/asterisk/gw/astmanproxy.conf';\t\n\t$usr_path = '/etc/asterisk/gw/astmanproxy.users';\n\t$default_ast_username = 'internalspecifyuser';\n\t$default_ast_password = '2rujzdndyznbg7u6xju';\n\t$default_amp_username = 'internalspecifyuser';\n\t$default_amp_password = 'xn60qvh9dqx1j6ekcj1';\n\n\tif(!file_exists($cfg_path)){\n\t\ttouch($cfg_path);\n\t}\n\n\t$cluster_info = get_cluster_info();\n\n\t$lock = lock_file($cfg_path);\n\t$contents = \"host = 127.0.0.1, 5038, $default_ast_username, $default_ast_password, off, off\\n\";\n\tif($cluster_info['mode'] == 'master') {\n\t\tfor($b=2; $b<=$__BRD_SUM__; $b++) {\n\t\t\tif(isset($cluster_info[$__BRD_HEAD__.$b.'_ip']) && $cluster_info[$__BRD_HEAD__.$b.'_ip'] != '') {\n\t\t\t\t$ip = $cluster_info[$__BRD_HEAD__.$b.'_ip'];\n\t\t\t\t$contents .= \"host = $ip, 5038, $default_ast_username, $default_ast_password, off, off\\n\";\n\t\t\t} \n\t\t} \n\t} \n\n\t$contents .= \"listenaddress = *\\n\";\n\t$contents .= \"listenport = 1234\\n\";\n\t$contents .= \"inputformat = standard\\n\";\n\t$contents .= \"outputformat = standard\\n\";\n\t$contents .= \"autofilter = off\\n\";\n\t$contents .= \"authrequired = yes\\n\";\n\t$contents .= \"retryinterval = 2\\n\";\n\t$contents .= \"maxretries = 0\\n\";\n\t$contents .= \"sslclienthellotimeout = 200\\n\";\n\t$contents .= \"acceptencryptedconnection = yes\\n\";\n\t$contents .= \"acceptunencryptedconnection = yes\\n\";\n\t$contents .= \"asteriskwritetimeout=100\\n\";\n\t$contents .= \"clientwritetimeout=200\\n\";\n\n\tfile_put_contents($cfg_path, $contents);\n\tunlock_file($lock);\n\n\t/* generate astmanproxy.users */\n\t$lock = lock_file($usr_path);\n\tfile_put_contents($usr_path, \"$default_amp_username=$default_amp_password\\n\");\n\tunlock_file($lock);\n}",
"protected function _setFeedUrl()\n\t{\n\t\t$this->_url = $this->_config['gcal_url'];\n\t}",
"public function share(bool $share = true)\n {\n // cannot be shared\n }",
"public function init() {\n\t\t\t// Before init action\n\t\t\tdo_action( 'before_wolf_share_init' );\n\n\t\t\t// Set up localisation\n\t\t\t$this->load_plugin_textdomain();\n\n\t\t\t// Init action\n\t\t\tdo_action( 'wolf_share_init' );\n\t\t}",
"public function setShareType($shareType);",
"public function share($files = null, $reset = false)\n {\n if (is_string($files)) $files = [$files];\n if (is_array($files)) {\n if ($reset) $this->share = [];\n $this->share = array_merge($files, $this->share);\n } elseif ($files === null) {\n $this->section(\"Setting up shared files...\");\n $this->echo(\"Usage:\");\n $this->echo(\"Symlink to existing shared asset: \\$deploy->share('/your/file.txt');\");\n $this->echo(\"Copy asset to shared folder and then symlink: \\$deploy->push('/your/file.txt');\");\n\n $release = $this->paths->release;\n $shared = $this->paths->shared;\n\n $this->echo(\"Config of shared items:\");\n $this->echo($this->share);\n $this->echo(\"Processing items...\");\n foreach ($this->share as $k => $v) {\n $file = $v;\n\n // push to shared folder or just create link?\n $type = 'link';\n if (is_string($k)) {\n $file = $k;\n $type = $v;\n }\n\n // prepare the src path\n $file = trim(Paths::normalizeSeparators($file), \"/\");\n $from = Paths::normalizeSeparators(\"$release/$file\");\n $toAbs = Paths::normalizeSeparators(\"$shared/$file\");\n $isfile = !!pathinfo($from, PATHINFO_EXTENSION);\n $toDir = dirname($toAbs);\n $fromDir = dirname($from);\n\n // we create relative symlinks\n $level = substr_count($file, \"/\");\n $to = \"shared/$file\";\n for ($i = 0; $i <= $level; $i++) $to = \"../$to\";\n\n if ($isfile) {\n $this->echo(\" [file] $from\");\n if (!is_file($toAbs)) {\n if (basename($toAbs) == 'config-local.php') {\n $configDir = dirname($toAbs);\n $this->exec(\"mkdir -p $configDir\");\n $rand1 = bin2hex(random_bytes(rand(15, 30)));\n $rand2 = bin2hex(random_bytes(rand(15, 30)));\n file_put_contents(\n $toAbs,\n \"<?php\\n// file created by RockMigrations\"\n . \"\\n// put your site-specific config here\\n\"\n . \"\\n// you can use these random salts:\"\n . \"\\n// \\$config->userAuthSalt = '$rand1';\"\n . \"\\n// \\$config->tableSalt = '$rand2';\"\n );\n }\n }\n $this->exec(\"ln -sf $to $from\");\n } else {\n $this->echo(\" [directory] $from\");\n\n // push means we only push files to the shared folder\n // but we do not create a symlink. This can be used to push site\n // translations where the files folder itself is already symlinked\n if ($type == 'push') {\n $this->exec(\n \" rm -rf $toAbs\\n\" .\n \" mkdir -p $toDir\\n\" .\n \" mv $from $toDir\",\n $this->isVerbose\n );\n } else {\n // regular shared directory\n // first wipe that directory in the temporary release\n // then create a symlink to the shared folder instead\n $this->exec(\n \" mkdir -p $toAbs\\n\" .\n \" mkdir -p $fromDir\\n\" .\n \" rm -rf $from\\n\" .\n \" ln -snf $to $from\",\n $this->isVerbose\n );\n }\n }\n }\n\n $this->ok();\n }\n }",
"protected function shareWithInertia()\n {\n $this->shareVersion();\n $this->shareAuthenticatedUser();\n $this->shareWinkAuthor();\n $this->shareAppData();\n $this->shareFlashMessages();\n $this->shareNews();\n $this->shareErrors();\n }",
"public function setHost()\n {\n $this->host = Config::get('smsglobal.host');\n }",
"public function share()\n\t{\n\t\tparent::setPageName('Partager');\n\t\t\n\t\tparent::loadHeader();\n\n\t\t$this->load->view('notification_zone');\n\t\t$this->load->view('flux/flux_share');\n\n\t\tparent::loadFooter();\n\t}",
"protected function syncSharedFolders()\n\t{\n\t\t$shared = (array) $this->rocketeer->getOption('remote.shared');\n\t\tforeach ($shared as $file) {\n\t\t\t$this->share($file);\n\t\t}\n\t}",
"public function setSharingManager(SharingManagerInterface $sharingManager);",
"function wpad_sync_on_changes() {\n\tglobal $config;\n\n\tif (is_array($config['installedpackages']['wpadsync']['config'])) {\n\t\t$wpad_sync = $config['installedpackages']['wpadsync']['config'][0];\n\t\t$synconchanges = $wpad_sync['synconchanges'];\n\t\t$synctimeout = $wpad_sync['synctimeout'] ?: '250';\n\t\tswitch ($synconchanges) {\n\t\t\tcase \"manual\":\n\t\t\t\tif (is_array($wpad_sync['row'])) {\n\t\t\t\t\t$rs = $wpad_sync['row'];\n\t\t\t\t} else {\n\t\t\t\t\tlog_error(\"[wpad] XMLRPC sync is enabled but there are no hosts configured as replication targets.\");\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase \"auto\":\n\t\t\t\tif (is_array($config['hasync'])) {\n\t\t\t\t\t$system_carp = $config['hasync'];\n\t\t\t\t\t$rs[0]['ipaddress'] = $system_carp['synchronizetoip'];\n\t\t\t\t\t$rs[0]['username'] = $system_carp['username'];\n\t\t\t\t\t$rs[0]['password'] = $system_carp['password'];\n\t\t\t\t\t$rs[0]['syncdestinenable'] = FALSE;\n\n\t\t\t\t\t// XMLRPC sync is currently only supported over connections using the same protocol and port as this system\n\t\t\t\t\tif ($config['system']['webgui']['protocol'] == \"http\") {\n\t\t\t\t\t\t$rs[0]['syncprotocol'] = \"http\";\n\t\t\t\t\t\t$rs[0]['syncport'] = $config['system']['webgui']['port'] ?: '80';\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$rs[0]['syncprotocol'] = \"https\";\n\t\t\t\t\t\t$rs[0]['syncport'] = $config['system']['webgui']['port'] ?: '443';\n\t\t\t\t\t}\n\t\t\t\t\tif ($system_carp['synchronizetoip'] == \"\") {\n\t\t\t\t\t\tlog_error(\"[wpad] XMLRPC CARP/HA sync is enabled but there are no system backup hosts configured as replication targets.\");\n\t\t\t\t\t\treturn;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$rs[0]['syncdestinenable'] = TRUE;\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tlog_error(\"[wpad] XMLRPC CARP/HA sync is enabled but there are no system backup hosts configured as replication targets.\");\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\treturn;\n\t\t\t\tbreak;\n\t\t}\n\t\tif (is_array($rs)) {\n\t\t\tlog_error(\"[wpad] XMLRPC sync is starting.\");\n\t\t\tforeach ($rs as $sh) {\n\t\t\t\t// Only sync enabled replication targets\n\t\t\t\tif ($sh['syncdestinenable']) {\n\t\t\t\t\t$sync_to_ip = $sh['ipaddress'];\n\t\t\t\t\t$port = $sh['syncport'];\n\t\t\t\t\t$username = $sh['username'] ?: 'admin';\n\t\t\t\t\t$password = $sh['password'];\n\t\t\t\t\t$protocol = $sh['syncprotocol'];\n\n\t\t\t\t\t$error = '';\n\t\t\t\t\t$valid = TRUE;\n\n\t\t\t\t\tif ($password == \"\") {\n\t\t\t\t\t\t$error = \"Password parameter is empty. \";\n\t\t\t\t\t\t$valid = FALSE;\n\t\t\t\t\t}\n\t\t\t\t\tif (!is_ipaddr($sync_to_ip) && !is_hostname($sync_to_ip) && !is_domain($sync_to_ip)) {\n\t\t\t\t\t\t$error .= \"Misconfigured Replication Target IP Address or Hostname. \";\n\t\t\t\t\t\t$valid = FALSE;\n\t\t\t\t\t}\n\t\t\t\t\tif (!is_port($port)) {\n\t\t\t\t\t\t$error .= \"Misconfigured Replication Target Port. \";\n\t\t\t\t\t\t$valid = FALSE;\n\t\t\t\t\t}\n\t\t\t\t\tif ($valid) {\n\t\t\t\t\t\twpad_do_xmlrpc_sync($sync_to_ip, $port, $protocol, $username, $password, $synctimeout);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tlog_error(\"[wpad] XMLRPC sync with '{$sync_to_ip}' aborted due to the following error(s): {$error}\");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tlog_error(\"[wpad] XMLRPC sync completed.\");\n\t\t}\n \t}\n}",
"protected function _generate_file_flexshares()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (!clearos_library_installed('samba_common/Samba'))\n return;\n\n $samba = new Samba();\n\n if (! $samba->is_file_server())\n return;\n\n // Create a unique file identifier\n $backup_key = time();\n\n // Backup original file\n $backup = new File(self::SMB_VIRTUAL_HOST_PATH . '/' . self::FILE_SMB_VIRTUAL);\n if ($backup->exists()) {\n $backup->move_to(self::PATH_TEMP . \"/$backup_key.bak\");\n $backup_exists = TRUE;\n } else {\n $backup_exists = FALSE;\n }\n\n // Samba is slightly different. We dump all flexshare-related 'stuff' in one file\n $file = new File(self::SMB_VIRTUAL_HOST_PATH . '/' . self::FILE_SMB_VIRTUAL);\n if ($file->exists())\n $file->delete();\n\n $file->create('root', 'root', '0644');\n\n $shares = $this->_get_shares(self::TYPE_ALL);\n\n $linestoadd = '';\n\n // Recreate samba flexshare.conf\n\n foreach ($shares as $name => $share) {\n // If not enabled, continue through loop - we're re-creating lines here\n if (! isset($share['ShareEnabled']) || ! $share['ShareEnabled'])\n continue;\n\n if (! isset($share['FileEnabled']) || ! $share['FileEnabled'])\n continue;\n\n $linestoadd .= \"[\" . $name . \"]\\n\";\n $linestoadd .= \"\\tpath = \" . $share[\"ShareDir\"] . \"\\n\";\n $linestoadd .= \"\\tcomment = \" . $share[\"FileComment\"] . \"\\n\";\n $linestoadd .= \"\\tbrowseable = Yes\\n\";\n\n if ((int)$share[\"FilePermission\"] == self::PERMISSION_READ_WRITE)\n $linestoadd .= \"\\tread only = No\\n\";\n\n if (isset($share[\"FilePublicAccess\"]) && $share[\"FilePublicAccess\"]) {\n $linestoadd .= \"\\tguest ok = Yes\\n\";\n } else {\n $linestoadd .= \"\\tguest ok = No\\n\";\n $linestoadd .= \"\\tdirectory mask = 0775\\n\";\n $linestoadd .= \"\\tcreate mask = 0664\\n\";\n $linestoadd .= \"\\tvalid users = @\\\"%D\" . '\\\\' . trim($share[\"ShareGroup\"]) . \"\\\", @\" .\n trim($share[\"ShareGroup\"]) . \"\\n\";\n }\n\n $linestoadd .= \"\\tveto files = /.flexshare*/\\n\";\n\n $vfsobject = \"\";\n\n if (isset($share[\"FileRecycleBin\"]) && $share[\"FileRecycleBin\"]) {\n $vfsobject .= \" recycle:recycle\";\n $linestoadd .= \"\\trecycle:repository = .trash/%U\\n\";\n $linestoadd .= \"\\trecycle:maxsize = 0\\n\";\n $linestoadd .= \"\\trecycle:versions = Yes\\n\";\n $linestoadd .= \"\\trecycle:keeptree = Yes\\n\";\n $linestoadd .= \"\\trecycle:touch = No\\n\";\n $linestoadd .= \"\\trecycle:directory_mode = 0775\\n\";\n }\n\n if (isset($share[\"FileAuditLog\"]) && $share[\"FileAuditLog\"]) {\n $vfsobject .= \" full_audit:audit\";\n $linestoadd .= \"\\taudit:prefix = %u\\n\";\n $linestoadd .= \"\\taudit:success = open opendir\\n\";\n $linestoadd .= \"\\taudit:failure = all\\n\";\n $linestoadd .= \"\\taudit:facility = LOCAL5\\n\";\n $linestoadd .= \"\\taudit:priority = NOTICE\\n\";\n }\n\n if ($vfsobject)\n $linestoadd .= \"\\tvfs object =$vfsobject\\n\";\n\n $linestoadd .= \"\\n\";\n }\n\n $file->add_lines($linestoadd);\n\n // Make sure Samba has flexshare include\n //--------------------------------------\n\n $samba->add_include('/etc/samba/flexshare.conf');\n\n // Validate smbd configuration\n //----------------------------\n\n $config_ok = TRUE;\n\n try {\n $shell = new Shell();\n $options['validate_exit_code'] = FALSE;\n $exitcode = $shell->execute(self::CMD_VALIDATE_SMBD, '-s', FALSE, $options);\n } catch (Exception $e) {\n $config_ok = FALSE;\n clearos_log(self::LOG_TAG, \"Invalid Samba config: \" . clearos_exception_message($e));\n }\n\n if ($config_ok) {\n // Delete backups\n if ($backup_exists)\n $backup->delete();\n } else {\n // Recover backups\n if ($backup_exists) {\n try {\n $backup->move_to(self::SMB_VIRTUAL_HOST_PATH . \"/\" . self::FILE_SMB_VIRTUAL);\n } catch (Exception $e) {\n // Supresss error here...could be same file\n }\n }\n\n throw new Engine_Exception(lang('flexshare_config_validation_failed'));\n }\n }",
"private static function _svcSetting()\n {\n define('UDPSENDERPATH', '/usr/local/sbin/udp-sender');\n define('MULTICASTINTERFACE', 'eth0');\n define('UDPSENDER_MAXWAIT', null);\n }",
"function sss_activation() {\n\t// defaults if none are present\n\tif( ! get_option( 'sss_settings') ) \n\t\tupdate_option( 'sss_settings', sss_settings_defaults( NULL, true ) );\t\n}",
"public function sync_access() {\n\t\tglobal $sync_request_dir;\n\t\t$sync_request = new SyncRequest;\n\t\t$sync_request->server_id = $this->id;\n\t\t$sync_request->account_name = null;\n\t\t$sync_request_dir->add_sync_request($sync_request);\n\t}",
"protected function _generate_ftp_flexshares()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (!clearos_library_installed('ftp/ProFTPd'))\n return;\n\n $confs = array();\n $proftpd = new ProFTPd();\n\n // Create a unique file identifier\n $backup_key = time();\n\n // Get file listing in FTP confs dir\n $folder = new Folder(self::FTP_VIRTUAL_HOST_PATH);\n\n if (!$folder->exists())\n return;\n\n $confs = $folder->get_listing();\n $index = 0;\n\n foreach ($confs as $conf) {\n if (preg_match(\"/^\" . self::PREFIX . \".*conf$/i\", $conf)) {\n $conf_file = new File(self::FTP_VIRTUAL_HOST_PATH . \"/\" . $conf);\n // Backup existing file\n $conf_file->move_to(self::PATH_TEMP . \"/$conf.$backup_key.bak\");\n } else {\n unset($confs[$index]);\n }\n\n $index++;\n }\n\n $shares = $this->_get_shares(self::TYPE_ALL);\n $ftps_filename = '';\n\n // Recreate all virtual configs\n foreach ($shares as $name => $share) {\n\n $newlines = array();\n $append = FALSE;\n\n // If not enabled, continue through loop - we're re-creating lines here\n if (!isset($share['ShareEnabled']) || !$share['ShareEnabled'])\n continue;\n\n if (!isset($share['FtpEnabled']) || !$share['FtpEnabled'])\n continue;\n\n // Add group greeting file\n try {\n // This isn't fatal. Log and continue on exception\n $file = new File(self::SHARE_PATH . \"/$name/.flexshare-group.txt\");\n if ($file->exists())\n $file->delete();\n\n if ($share['FtpGroupGreeting']) {\n $file->create(\"root\", \"root\", 644);\n $file->add_lines($share['FtpGroupGreeting'] . \"\\n\");\n }\n } catch (Exception $e) {\n //\n }\n\n // Need to know which file we'll be writing to.\n // We determine this by port\n // Ie. /etc/proftpd.d/flex-<port>.conf\n\n // Port\n if ($share['FtpOverridePort'])\n $port = $share['FtpPort'];\n else\n $port = self::DEFAULT_PORT_FTP;\n\n // Passive mode flag\n $pasv = '';\n if ($share['FtpAllowPassive'])\n $pasv = ' PASV';\n\n // Overwrite permission\n if ((int)$share['FtpGroupPermission'] == self::PERMISSION_WRITE_PLUS)\n $group_write = 'on';\n else if ((int)$share['FtpGroupPermission'] == self::PERMISSION_READ_WRITE_PLUS)\n $group_write = 'on';\n else\n $group_write = 'off';\n\n // Create new file in parallel\n $filename = self::PREFIX . $port . '.conf';\n $ftps_filename = self::PREFIX . '990' . '.conf';\n\n // Add to confs array in case of failure\n if (!in_array($filename, $confs))\n $confs[] = $filename;\n\n $file = new File(self::FTP_VIRTUAL_HOST_PATH . \"/\" . $filename);\n $tempfile = new File(self::FTP_VIRTUAL_HOST_PATH . \"/\" . $filename . '.cctmp');\n\n if ($tempfile->exists())\n $tempfile->delete();\n\n $tempfile->create('root', 'root', '0644');\n\n if ($file->exists()) {\n $oldlines = $file->get_contents_as_array();\n $found_start = FALSE;\n\n $linestoadd = \"\";\n foreach ($oldlines as $line) {\n if (preg_match(\"/^\\s*# DNR:Webconfig start - $name$/\", $line))\n $found_start = TRUE;\n\n if ($found_start && preg_match(\"/^\\s*# DNR:Webconfig end - $name$/\", $line)) {\n $found_start = FALSE;\n continue;\n }\n\n if ($found_start)\n continue;\n\n $linestoadd .= $line . \"\\n\";\n\n // We need to know if we are working on top of another define or not\n $append = TRUE;\n }\n\n $tempfile->add_lines($linestoadd);\n }\n\n try {\n $proftpd_conf = new File(ProFTPd::FILE_CONFIG);\n $proftpd_conf->lookup_line(\"/Include \\/etc\\/proftpd.d\\/\\*.conf/i\");\n } catch (File_No_Match_Exception $e) {\n // Need this line to include flexshare confs\n $proftpd_conf->add_lines(\"Include /etc/proftpd.d/*.conf\\n\");\n } catch (Exception $e) {\n throw new Engine_Exception(clearos_exception_message($e), CLEAROS_ERROR);\n }\n\n if (! $append) {\n $newlines[] = self::WRITE_WARNING;\n // Note: event system will automatically handle IP address changes.\n $iface_manager = new Iface_Manager();\n $external_ips = $iface_manager->get_external_ip_addresses();\n $trusted_ips = $iface_manager->get_most_trusted_ips();\n\n $ips = array_merge($external_ips, $trusted_ips);\n $ip_list = implode(' ', array_unique($ips));\n\n $newlines[] = \"<VirtualHost $ip_list>\";\n $newlines[] = \"\\tPort $port\";\n $newlines[] = \"\\tDefaultRoot \" . self::SHARE_PATH . \"/\";\n $newlines[] = \"\\tRequireValidShell off\";\n $newlines[] = \"\\tAuthPam on\";\n $newlines[] = \"\\tAuthPAMConfig proftpd\";\n\n if ($share[\"FtpPassivePortMin\"] && $share[\"FtpPassivePortMax\"])\n $newlines[] = \"\\tPassivePorts \" . $share[\"FtpPassivePortMin\"] . \" \" . $share[\"FtpPassivePortMax\"];\n\n $newlines[] = \"\\tCapabilitiesEngine on\";\n $newlines[] = \"\\tCapabilitiesSet +CAP_CHOWN\";\n\n $newlines[] = \"\";\n $newlines[] = \"\\t<Limit LOGIN CDUP PWD XPWD LIST PROT$pasv>\";\n $newlines[] = \"\\t\\tAllowAll\";\n $newlines[] = \"\\t</Limit>\";\n $newlines[] = \"\\t<Limit ALL>\";\n $newlines[] = \"\\t\\tDenyAll\";\n $newlines[] = \"\\t</Limit>\";\n $newlines[] = \"\";\n\n // FTPES (SSL)\n // if ($share['FtpEnableFtpes']) {\n $newlines[] = \"\\t<IfModule mod_tls.c>\";\n $newlines[] = \"\\t\\tTLSEngine on\";\n $newlines[] = \"\\t\\tTLSLog /var/log/tls.log\";\n $newlines[] = \"\\t\\tTLSOptions NoCertRequest\";\n $newlines[] = \"\\t\\tTLSRequired off\";\n $newlines[] = \"\\t\\tTLSRSACertificateFile /etc/pki/CA/bootstrap.crt\";\n $newlines[] = \"\\t\\tTLSRSACertificateKeyFile /etc/pki/CA/bootstrap.key\";\n $newlines[] = \"\\t\\tTLSVerifyClient off\";\n $newlines[] = \"\\t</IfModule>\";\n $newlines[] = \"\\n\";\n } else {\n if ($share['FtpAllowPassive']) {\n $tempfile->replace_lines(\n \"/\\sPassivePorts \\d+\\s+\\d+/\",\n \"\\tPassivePorts \" . $share['FtpPassivePortMin'] . \" \" . $share['FtpPassivePortMax'] . \"\\n\"\n );\n }\n }\n\n // Add flexshare specific directory directives\n $newlines[] = \"\\t# DNR:Webconfig start - $name\";\n $newlines[] = \"\\t<Directory \" . self::SHARE_PATH . \"/$name>\";\n $newlines[] = \"\\t\\tAllowOverwrite \" . $group_write;\n $newlines[] = \"\\t\\tAllowRetrieveRestart on\";\n $newlines[] = \"\\t\\tAllowStoreRestart on\";\n $newlines[] = \"\\t\\tDisplayChdir .flexshare-group.txt TRUE\";\n $newlines[] = \"\\t\\tHideNoAccess on\";\n $newlines[] = \"\\t\\tHideFiles (.flexshare)\";\n $newlines[] = \"\\t\\tGroupOwner \\\"\" . $share[\"ShareGroup\"] . \"\\\"\";\n $newlines[] = \"\\t\\tUmask 0113 0002\";\n $newlines[] = \"\\t\\t<Limit \" . $this->access[$share['FtpGroupPermission']] . \"$pasv>\";\n $newlines[] = \"\\t\\t AllowGroup \\\"\" . $share['ShareGroup'] . \"\\\"\";\n $newlines[] = \"\\t\\t IgnoreHidden on\";\n $newlines[] = \"\\t\\t</Limit>\";\n $newlines[] = \"\\t\\t<Limit ALL>\";\n $newlines[] = \"\\t\\t DenyAll\";\n $newlines[] = \"\\t\\t</Limit>\";\n\n $newlines[] = \"\\t</Directory>\";\n $newlines[] = \"\\t# DNR:Webconfig end - $name\";\n $newlines[] = \"\";\n\n if ($append) {\n $tempfile->delete_lines(\"/<\\/VirtualHost>/\");\n $tempfile->add_lines(implode(\"\\n\", $newlines) . \"\\n</VirtualHost>\\n\");\n } else {\n $tempfile->add_lines(implode(\"\\n\", $newlines) . \"\\n</VirtualHost>\\n\");\n }\n\n $tempfile->move_to(self::FTP_VIRTUAL_HOST_PATH . \"/\" . $filename);\n }\n\n // Validate proftpd configuration before restarting server\n $config_ok = TRUE;\n\n try {\n $options['validate_exit_code'] = FALSE;\n $shell = new Shell();\n // TODO: this fails on DNS lookup issues\n //$exitcode = $shell->execute(self::CMD_VALIDATE_PROFTPD, '-t', TRUE, $options);\n $exitcode = 0;\n } catch (Exception $e) {\n $config_ok = FALSE;\n }\n\n if ($exitcode !== 0) {\n $config_ok = FALSE;\n $output = $shell->get_output();\n clearos_log(self::LOG_TAG, \"Invalid ProFTP configuration!\");\n\n foreach ($output as $line)\n clearos_log(self::LOG_TAG, $line);\n }\n\n foreach ($confs as $conf) {\n // Not a flexshare conf file\n if (!isset($conf))\n continue;\n\n $file = new File(self::PATH_TEMP . \"/$conf.$backup_key.bak\");\n\n if (! $file->exists()) {\n // Conf was newly created\n $file = new File(self::FTP_VIRTUAL_HOST_PATH . \"/$conf\");\n\n if (! $config_ok)\n $file->delete();\n\n continue;\n }\n\n if ($config_ok) {\n // Delete backups\n $file->delete();\n } else {\n // Recover backups\n $file->move_to(self::FTP_VIRTUAL_HOST_PATH . \"/$conf\");\n }\n }\n\n if (!$config_ok)\n throw new Engine_Exception(lang('flexshare_config_validation_failed'));\n\n // Copy to FTPS configuration\n if (!empty($ftps_filename)) {\n $base_config = new File(self::FTP_VIRTUAL_HOST_PATH . '/' . $filename);\n $lines = $base_config->get_contents_as_array();\n $newlines = array();\n\n foreach ($lines as $line) {\n if (preg_match(\"/^\\s*Port\\s+[\\d]+$/\", $line))\n $newlines[] = \"\\tPort 990\";\n else if (preg_match(\"/^\\s*TLSOptions\\s+/\", $line))\n $newlines[] = \"\\t\\tTLSOptions NoCertRequest UseImplicitSSL\";\n else\n $newlines[] = $line;\n }\n\n $file = new File(self::FTP_VIRTUAL_HOST_PATH . '/' . $ftps_filename);\n if ($file->exists())\n $file->delete();\n\n $file->create('root', 'root', '0644');\n $file->dump_contents_from_array($newlines);\n }\n\n if ($config_ok) {\n try {\n $proftpd = new ProFTPd();\n $proftpd->reset(TRUE);\n } catch (Exception $e) {\n // Keep going\n }\n }\n }",
"function delete_share($name, $delete_dir)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_name($name));\n\n // Set directory back to default\n // This will remove any mount points\n\n $defaultdir = self::SHARE_PATH . '/' . $name;\n $this->set_directory($name, $defaultdir);\n\n $file = new File(self::FILE_CONFIG);\n\n if (! $file->exists())\n throw new File_Not_Found_Exception(self::FILE_CONFIG);\n\n // Backup in case we need to go back to original\n $file->move_to(self::PATH_TEMP . \"/flexshare.conf.orig\");\n\n // Create new file in parallel\n $newfile = new File(self::FILE_CONFIG . \".cctmp\", TRUE);\n\n if ($newfile->exists())\n $newfile->delete();\n\n $newfile->create('root', 'root', '0644');\n\n $lines = $file->get_contents_as_array();\n $found = FALSE;\n $match = array();\n $new_lines = '';\n\n foreach ($lines as $line) {\n if (preg_match(self::REGEX_OPEN, $line, $match) && $match[1] == $name) {\n $found = TRUE;\n } elseif (preg_match(self::REGEX_CLOSE, $line) && $found) {\n $found = FALSE;\n continue;\n }\n\n if ($found)\n continue;\n\n $new_lines .= \"$line\\n\";\n }\n\n $newfile->add_lines($new_lines);\n $newfile->move_to(self::FILE_CONFIG);\n\n $this->shares = NULL; // Force a configuration reload\n\n try {\n $this->_generate_web_flexshares();\n $this->_generate_ftp_flexshares();\n $this->_generate_file_flexshares();\n\n try {\n $file->delete();\n } catch (Exception $ignore) {\n // Just log\n }\n } catch (Exception $e) {\n // Any exception here, toggle...well, toggle.\n $file->move_to(self::FILE_CONFIG);\n throw new Engine_Exception(clearos_exception_message($e), CLEAROS_ERROR);\n }\n\n // If you get here, it's OK to delete (as required)\n if ($delete_dir) {\n try {\n $folder = new Folder(self::SHARE_PATH . \"/$name\");\n if ($folder->exists())\n $folder->delete(TRUE);\n } catch (Exception $e) {\n // Just log\n }\n }\n }"
] | [
"0.5549844",
"0.52504545",
"0.5237554",
"0.52002114",
"0.51992244",
"0.50733364",
"0.5057471",
"0.50302297",
"0.500256",
"0.4966841",
"0.4962191",
"0.49327084",
"0.4924047",
"0.49171215",
"0.49020177",
"0.49004322",
"0.48981655",
"0.4864378",
"0.48557818",
"0.48235673",
"0.4822141",
"0.48081172",
"0.4797216",
"0.47886968",
"0.4788657",
"0.478252",
"0.4781278",
"0.4761393",
"0.47562808",
"0.47537926"
] | 0.5468688 | 1 |
Returns existence of a Flexshare. | function exists($name)
{
clearos_profile(__METHOD__, __LINE__);
try {
$share_info = $this->get_share($name);
} catch (Flexshare_Not_Found_Exception $e) {
return FALSE;
}
return TRUE;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function exists($share)\n {\n if (isset($this->_cache[$share])) {\n return true;\n }\n\n return $this->_exists($share);\n }",
"public function getIsExternalShareEnabled()\n {\n if (array_key_exists(\"isExternalShareEnabled\", $this->_propDict)) {\n return $this->_propDict[\"isExternalShareEnabled\"];\n } else {\n return null;\n }\n }",
"function snax_show_item_share() {\n\t$bool = true;\n\tif ( snax_is_item( null, 'text' ) ) {\n\t\t$bool = false;\n\t}\n\n\treturn (bool) apply_filters( 'snax_show_item_share', $bool );\n}",
"function get_share($name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $shares = $this->_get_shares(self::TYPE_ALL);\n\n if (empty($shares[$name]))\n throw new Flexshare_Not_Found_Exception($name, CLEAROS_INFO);\n\n return $shares[$name];\n }",
"public function isShared()\n {\n return str_contains($this->getPath(), 'addons/shared/' . $this->getVendor());\n }",
"public function isShared();",
"public static function exists()\n {\n return self::_s_call('exists', []);\n }",
"public function isShared(): bool\n {\n return $this->shared;\n }",
"public function has($alias) {\n if (array_key_exists($alias, $this->networks)) {\n return true;\n }\n return false;\n }",
"public function hasCatalog($alias)\n {\n return isset($this->configuration[$alias]);\n }",
"public function isShared()\n {\n return $this->shared;\n }",
"public function exists();",
"public function exists();",
"public function exists();",
"public function exists();",
"public function exists();",
"public function exists();",
"public function exists();",
"function exists()\n {\n clearstatcache();\n //var_dump($this->getStoreName());\n $ret = file_exists($this->getStoreName());\n if (!$ret) {\n return $this->canFix();\n }\n return $ret;\n }",
"public function exists(): bool;",
"public function exists(): bool;",
"public function exists(): bool;",
"public function exists(): bool;",
"public function exists(): bool;",
"public function exists() {\n\t\treturn $this -> exists;\n\t}",
"public function exists()\n\t{\n\t\treturn true;\n\t}",
"public static function exists($alias)\n {\n return static::locator()->exists($alias);\n }",
"public function exists() {\n return FALSE;\n }",
"public function exists() {\n\t\treturn file_exists( $this->getCacheFileName() );\n\t}",
"public function exists()\n {\n return false;\n }"
] | [
"0.74024385",
"0.6836088",
"0.64276445",
"0.6418435",
"0.6084761",
"0.6072755",
"0.60692626",
"0.6056801",
"0.60511625",
"0.6044283",
"0.5969797",
"0.5954292",
"0.5954292",
"0.5954292",
"0.5954292",
"0.5954292",
"0.5954292",
"0.5954292",
"0.5934069",
"0.59338987",
"0.59338987",
"0.59338987",
"0.59338987",
"0.59338987",
"0.59013164",
"0.5884546",
"0.58806604",
"0.5862557",
"0.5845741",
"0.58214986"
] | 0.8195364 | 0 |
Returns configured group for given share. | function get_group($name)
{
clearos_profile(__METHOD__, __LINE__);
return $this->_get_parameter($name, 'ShareGroup');
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getGroup()\n\t{\n\t\treturn $this->groups[$this->extension];\n\t}",
"public static function get_group() {\n return 'group_course_settings';\n }",
"public function getGroup() {\n $group_id = filegroup($this->__full_path);\n $group_info = posix_getgrgid($group_id);\n return $group_info[\"name\"];\n }",
"protected function _getGroup()\n\t{ \n\t $group = $this->_mixer->getIdentifier();\n\t return $group;\n\t}",
"static public function getSourceFromShare(Horde_Share $share)\n {\n // Require a fresh config file.\n $cfgSources = self::availableSources();\n\n $params = @unserialize($share->get('params'));\n $newConfig = $cfgSources[$params['source']];\n $newConfig['params']['config'] = $cfgSources[$params['source']];\n $newConfig['params']['config']['params']['share'] = $share;\n $newConfig['params']['config']['params']['name'] = $params['name'];\n $newConfig['title'] = $share->get('name');\n $newConfig['type'] = 'share';\n $newConfig['use_shares'] = false;\n\n return $newConfig;\n }",
"public function getGroup() {\n return $this->system->groupByID(posix_getgid());\n }",
"public function getGroupId()\n {\n if (array_key_exists(\"groupId\", $this->_propDict)) {\n return $this->_propDict[\"groupId\"];\n } else {\n return null;\n }\n }",
"public function getGroup(): ?string\n {\n return $this->group;\n }",
"function mention_get_settingsgroup()\n{\n\tstatic $mention_settings_gid;\n\n\t// if we have already stored the value\n\tif(isset($mention_settings_gid))\n\t{\n\t\t// don't waste a query\n\t\t$gid = (int) $mention_settings_gid;\n\t}\n\telse\n\t{\n\t\tglobal $db;\n\n\t\t// otherwise we will have to query the db\n\t\t$query = $db->simple_select(\"settinggroups\", \"gid\", \"name='mention_settings'\");\n\t\t$gid = (int) $db->fetch_field($query, 'gid');\n\t}\n\treturn $gid;\n}",
"public function group() {\n\t\treturn ( $role = $this->getRoles()->sortBy( 'group' )->first() ) ? $role->group : 'default';\n\t}",
"public function getGroup()\n {\n return $this->group;\n }",
"public function getGroup()\n {\n return $this->group;\n }",
"public function getGroup()\r\n {\r\n return $this->group;\r\n }",
"public function getGroup ()\n {\n return $this->group;\n }",
"public function getGroup()\n {\n $this->getTopology();\n return $this->group;\n }",
"public function getGroup()\n\t{\n\t\treturn $this->group;\n\t}",
"public function getGroup()\n {\n return $this->_group;\n }",
"function getGroup() { return $this->_repo->getGroup($this->_groupid); }",
"function scrollonGetSettingsGroup()\n{\n\tstatic $gid = null;\n\n\t// if we have already stored the value\n\tif ($gid === null) {\n\t\tglobal $db;\n\n\t\t// otherwise we will have to query the db\n\t\t$query = $db->simple_select('settinggroups', 'gid', \"name='scrollon_settings'\");\n\t\t$gid = (int) $db->fetch_field($query, 'gid');\n\t}\n\treturn $gid;\n}",
"public function getGroup()\n {\n return $this->getProperty(\"Group\");\n }",
"public function getGroupIdentifier()\n {\n return $this->groupIdentifier;\n }",
"public function getGroup()\n {\n return $this->group;\n\n }",
"function _horde_listGroupsOfShare($shareRoot, $shareName, $permissions)\n{\n if (!Auth::isAdmin()) {\n return PEAR::raiseError(_(\"You are not allowed to list groups of shares.\"));\n }\n\n require_once 'Horde/Share.php';\n $shares = &Horde_Share::singleton($shareRoot);\n\n if (is_a($share = &$shares->getShare($shareName), 'PEAR_Error')) {\n return $share;\n }\n\n $perm = 0;\n foreach ($permissions as $permission) {\n $permission = String::upper($permission);\n if (defined('PERMS_' . $permission)) {\n $perm &= constant('PERMS_' . $permission);\n }\n }\n\n return $share->listGroups($perm);\n}",
"public function getGroup(): SiteGroup\n {\n if ($this->groupId === null) {\n throw new InvalidConfigException('Site is missing its group ID');\n }\n\n if (($group = Craft::$app->getSites()->getGroupById($this->groupId)) === null) {\n throw new InvalidConfigException('Invalid site group ID: ' . $this->groupId);\n }\n\n return $group;\n }",
"public function getGroup()\n {\n if (!$this->valid()) {\n return null;\n }\n\n $attributes = $this->processors[$this->action][$this->index]['attributes'];\n\n return isset($attributes['group'])\n ? $attributes['group']\n : null;\n }",
"public function getGroupById($groupId)\n {\n $groups = $this->getGroups();\n if (isset($groups[$groupId])) {\n return $groups[$groupId];\n } else {\n return null;\n }\n }",
"public function getGroup($group) {\n\t\treturn $this->options[$group];\n\t}",
"public function get_group_id(){\n\t\t// get session log info\n\t\treturn ($this->_logInfo['group_id']) ? $this->_logInfo['group_id'] : NULL ;\n\t}",
"public function getGroup()\n {\n \tglobal $_mConfig;\n\n \tif(empty($_SESSION['AMADIS']['Admin']['group'])) {\n $g = new CMGroup;\n $g->codeGroup = $_SESSION['config']['admin']['codeGroup'];\n $g->load();\n $_SESSION['AMADIS']['Admin']['group'] = $g;\n } else {\n $g = $_SESSION['AMADIS']['Admin']['group'];\n }\n return $g;\n }",
"public function get_steam_group() {\n\t\treturn $this->steam_group;\n\t}"
] | [
"0.5905817",
"0.5884109",
"0.58605635",
"0.58489776",
"0.5843984",
"0.5832226",
"0.5820025",
"0.58011365",
"0.5800607",
"0.5774665",
"0.56964964",
"0.56964964",
"0.56922346",
"0.5664549",
"0.56542116",
"0.5650143",
"0.5635289",
"0.55993795",
"0.5598627",
"0.557742",
"0.5571712",
"0.5570444",
"0.55602264",
"0.55352324",
"0.55281055",
"0.5528007",
"0.5521273",
"0.55093485",
"0.5484331",
"0.54751533"
] | 0.70671016 | 0 |
Returns security permissions option. | function get_enforce_group_permissions()
{
clearos_profile(__METHOD__, __LINE__);
try {
$option = $this->_get_global_parameter('FlexshareSecurityPermissions');
} catch (Flexshare_Parameter_Not_Found_Exception $e) {
// Ignore
} catch (Engine_Exception $e) {
// Ignore
}
if (empty($option))
$option = 'on';
return $option;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function getPermissionOptions()\n {\n return [\n 'read' => 'View listing and edit views',\n 'create' => 'Create new items',\n 'update' => 'Update existing items',\n 'grant' => 'Change role and permissions',\n 'destroy' => ['Delete', 'Delete items permanently'],\n ];\n }",
"function getPermission(){\n\t\tif (Yii::$app->getUserOpt->Modul_akses('11')){\n\t\t\treturn Yii::$app->getUserOpt->Modul_akses('11');\n\t\t}else{\n\t\t\treturn false;\n\t\t}\n\t}",
"function get_file_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"public function getPermissionsOnlyMode()\n {\n return $this->getProperty(\"PermissionsOnlyMode\");\n }",
"function get_ftp_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE_PLUS => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"public function getPermission() {\n $this->group();\n\n if ($this->_editPermission) {\n return CRM_Core_Permission::EDIT;\n }\n elseif ($this->_viewPermission) {\n return CRM_Core_Permission::VIEW;\n }\n return NULL;\n }",
"function getPermissions(){\n $auth =& Dataface_AuthenticationTool::getInstance();\n $user =& $auth->getLoggedInUser();\n if ( $user and $user->val('Role') != 'ADMIN' ){\n return Dataface_PermissionsTool::READ_ONLY();\n }\n }",
"public function & GetPermissions();",
"public function permissions()\n {\n return $this->permissions;\n }",
"private static function _get_option_permission_root(){\n if ( is_null(self::$id_option_permission_root) ){\n /** @var bbn\\appui\\options $opt */\n if ( $opt = bbn\\appui\\options::get_options() ){\n self::$id_option_permission_root = $opt->from_code('options', 'misc', 'bbn_permissions');\n }\n }\n return self::$id_option_permission_root;\n }",
"public function getPermissions() : string\n {\n return $this->permissions;\n }",
"public function getPerm()\n {\n return $this->perm;\n }",
"public function permissions();",
"public function permissions();",
"public function permissions();",
"public function getEffectivePermissions()\n {\n return $this->effective_permissions;\n }",
"function getPermissions(&$record){\n\t\tif ( isAdmin() ) return Dataface_PermissionsTool::ALL();\n\t\treturn Dataface_PermissionsTool::NO_ACCESS();\n\t}",
"function permissions()\n {\n return $this->Permissions;\n }",
"public function getPermissions()\n {\n return $this->getConfiguration();\n }",
"public function getSecuritySettings()\n {\n return $this->security_settings;\n }",
"public function getPermission(): string {\n\t\treturn \"blocksniper.type.\" . str_replace(\"hollow\", \"\", str_replace(\" \", \"_\", strtolower($this->getName())));\n\t}",
"abstract protected function getPermissions();",
"public function getPermissions();",
"public function getPermissions();",
"public function getPermissions();",
"public function getPermissions();",
"public function getPermissions();",
"function get_system_permissions()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $permissions = array(\n self::PERMISSIONS_SECURE => lang('base_disabled'),\n self::PERMISSIONS_READ_ONLY => lang('flexshare_read_only')\n );\n\n return $permissions;\n }",
"public function permissions()\n {\n return $this->roles->pluck('permissions')->collapse();\n }",
"public function getPermissions()\n {\n return $this->permissions;\n }"
] | [
"0.6761008",
"0.66882366",
"0.6506774",
"0.64854234",
"0.6463638",
"0.62561715",
"0.62514",
"0.6248536",
"0.6203074",
"0.62008125",
"0.6153841",
"0.6147152",
"0.6133436",
"0.6133436",
"0.6133436",
"0.6076698",
"0.6058072",
"0.6041171",
"0.601399",
"0.60128635",
"0.6001442",
"0.5999441",
"0.5997452",
"0.5997452",
"0.5997452",
"0.5997452",
"0.5997452",
"0.59631306",
"0.59454113",
"0.59188473"
] | 0.71894395 | 0 |
Returns system permissions options. | function get_system_permissions()
{
clearos_profile(__METHOD__, __LINE__);
$permissions = array(
self::PERMISSIONS_SECURE => lang('base_disabled'),
self::PERMISSIONS_READ_ONLY => lang('flexshare_read_only')
);
return $permissions;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function get_file_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"function get_ftp_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE_PLUS => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"public function getPermissionOptions()\n {\n return [\n 'read' => 'View listing and edit views',\n 'create' => 'Create new items',\n 'update' => 'Update existing items',\n 'grant' => 'Change role and permissions',\n 'destroy' => ['Delete', 'Delete items permanently'],\n ];\n }",
"function get_enforce_group_permissions()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n try {\n $option = $this->_get_global_parameter('FlexshareSecurityPermissions');\n } catch (Flexshare_Parameter_Not_Found_Exception $e) {\n // Ignore\n } catch (Engine_Exception $e) {\n // Ignore\n }\n\n if (empty($option))\n $option = 'on';\n\n return $option;\n }",
"public static function getOptions() {\n global $sitemap_activated;\n if(!$sitemap_activated)\n return array();\n\n $robot = new File('..', 'robots.txt');\n $sitemap = new File('..', 'sitemap.xml');\n $rights = array(\n '../robots.txt' => $robot->isWritable(true),\n '../sitemap.xml' => $sitemap->isWritable(true),\n );\n $failure = false;\n foreach($rights as $file=>$r) {\n if(!$r) {\n $failure = true;\n break;\n }\n }\n if($failure)\n Controller::notifyUser('error', 'permission', $rights);\n\n return array();\n }",
"function get_ftp_umask_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n // Umask is inverted.\n $options = array(\n 7 => \"---\",\n 6 => \"--x\",\n 5 => \"-w-\",\n 4 => \"-wx\",\n 3 => \"r--\",\n 2 => \"r-x\",\n 1 => \"rw-\",\n 0 => \"rwx\"\n );\n\n return $options;\n }",
"public function getSystemPrivileges()\n {\n $this->readData();\n return $this->m_aPrivs;\n }",
"function get_web_access_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::ACCESS_LAN => lang('flexshare_access_lan'),\n self::ACCESS_ALL => lang('base_all')\n );\n\n return $options;\n }",
"public function getPermissions()\n {\n return $this->getConfiguration();\n }",
"public function permissions()\n {\n return $this->permissions;\n }",
"public function getPermissions() {\n\t\t$sql = \"SELECT * FROM {$this->cTableName} ORDER BY systemcode ASC\";\n\t\t$statement = $this->prepare($sql);\n\t\t$statement->execute();\n\t\treturn $this->fetchObjects($statement);\n\t}",
"private function getPermissions()\n {\n return $this->manager->getManagerPermissions();\n }",
"protected function getOptions()\n {\n return [\n ['assign-to-roles', null, InputOption::VALUE_OPTIONAL, 'Comma separated list of role IDs that the permissions need to be assigned to.', null],\n ];\n }",
"public function list_permissions(){\n $auth = Yii::$app->authManager;\n\n return ['list' => $auth->getPermissions()];\n }",
"public function getPermissions() {\r\n\t\treturn array();\r\n\t}",
"public function permissionList(): array {\n return $this->info()['Permission'];\n }",
"public static function getPermissions() {\n\t\t$permissions = array(\n\t\t\t'users' => array(\n\t\t\t\t'admin.users.index' => trans('permissions/general.users_list'),\n\t\t\t\t'admin.users.edit' => trans('permissions/general.users_edit'),\n\t\t\t\t'admin.users.create' => trans('permissions/general.users_create'),\n\t\t\t\t'delete.user' => trans('permissions/general.users_delate'),\n\t\t\t),\n\t\t\t'groups' => array(\n\t\t\t\t'groups' => trans('permissions/general.group_list'),\n\t\t\t\t'edit.group' => trans('permissions/general.group_edit'),\n\t\t\t\t'create.group' => trans('permissions/general.group_create'),\n\t\t\t\t'delete.group' => trans('permissions/general.group_delate'),\n\t\t\t),\n\t\t\t'blocks' => array(\n\t\t\t\t'blocks' => trans('permissions/general.blocks_list'),\n\t\t\t\t'edit.block' => trans('permissions/general.block_edit'),\n\t\t\t\t'create.block' => trans('permissions/general.block_create'),\n\t\t\t\t'delete.block' => trans('permissions/general.block_delate'),\n\t\t\t),\n\t\t\t'pages' => array(\n\t\t\t\t'pages' => trans('permissions/general.pages_list'),\n\t\t\t\t'edit.page' => trans('permissions/general.page_edit'),\n\t\t\t\t'create.page' => trans('permissions/general.page_create'),\n\t\t\t\t'delete.page' => trans('permissions/general.page_delate'),\n\t\t\t),\n 'menu' => array(\n\t\t\t\t'menu' => trans('permissions/general.menu_list'),\n\t\t\t\t'menu.data.quickrename' => trans('permissions/general.menu_edit'),\n\t\t\t\t'menu.data.quickcreate' => trans('permissions/general.menu_create'),\n\t\t\t\t'menu.data.quickremove' => trans('permissions/general.menu_delate'),\n\t\t\t\t'menu.data.move' => trans('permissions/general.menu_move'),\n\t\t\t),\n\t\t\t'classifiedschema' => array(\n\t\t\t\t'classifiedschema' => trans('permissions/general.classifiedschema_list'),\n\t\t\t\t'classifiedschema.data.quickrename' => trans('permissions/general.classifiedschema_edit'),\n\t\t\t\t'classifiedschema.data.quickcreate' => trans('permissions/general.classifiedschema_create'),\n\t\t\t\t'classifiedschema.data.quickremove' => trans('permissions/general.classifiedschema_delate'),\n\t\t\t\t'classifiedschema.data.move' => trans('permissions/general.classifiedschema_move'),\n\t\t\t),\n\t\t\t'classifiedcategories' => array(\n\t\t\t\t'classifiedcategories' => trans('permissions/general.classifiedcategories_list'),\n\t\t\t\t'update.classifiedcategories' => trans('permissions/general.classifiedcategories_edit'),\n\t\t\t\t'create.classifiedcategories' => trans('permissions/general.classifiedcategories_create'),\n\t\t\t\t'delete.classifiedcategories' => trans('permissions/general.classifiedcategories_delate'),\n\t\t\t\t'classifiedcategories.data.move' => trans('permissions/general.classifiedcategories_move'),\n 'classifiedcategories.recreate' => trans('permissions/general.recreateclassifiedcategories'),\n\t\t\t),\n\t\t\t'classifieds' => array(\n\t\t\t\t'classifieds' => trans('permissions/general.classifieds_list'),\n\t\t\t\t'update.classified' => trans('permissions/general.classifieds_edit'),\n\t\t\t\t'create.classified' => trans('permissions/general.classifieds_create'),\n\t\t\t\t'delete.classified' => trans('permissions/general.classifieds_delate'),\n\t\t\t),\n\t\t\t'nearmecategory' => array(\n\t\t\t\t'nearmecategories' => trans('permissions/general.nearmecategory_list'),\n\t\t\t\t'update.nearmecategory' => trans('permissions/general.nearmecategory_edit'),\n\t\t\t\t'create.nearmecategory' => trans('permissions/general.nearmecategory_create'),\n\t\t\t\t'delete.nearmecategory' => trans('permissions/general.nearmecategory_delate'),\n\t\t\t),\n\t\t\t'nearmeitemscategory' => array(\n\t\t\t\t'nearmeitemscategory' => trans('permissions/general.nearmeitemscategory_list'),\n\t\t\t\t'update.nearmeitemscategory' => trans('permissions/general.nearmeitemscategory_edit'),\n\t\t\t\t'create.nearmeitemscategory' => trans('permissions/general.nearmeitemscategory_create'),\n\t\t\t\t'delete.nearmeitemscategory' => trans('permissions/general.nearmeitemscategory_delate'),\n\t\t\t),\n 'nearme' => array(\n\t\t\t\t'nearmes' => trans('permissions/general.nearme_list'),\n\t\t\t\t'update.nearme' => trans('permissions/general.nearme_edit'),\n\t\t\t\t'create.nearme' => trans('permissions/general.nearme_create'),\n\t\t\t\t'delete.nearme' => trans('permissions/general.nearme_delate'),\n\t\t\t),\n\t\t\t'ads' => array(\n\t\t\t\t'ads' => trans('permissions/general.ads_list'),\n\t\t\t\t'update.ads' => trans('permissions/general.ads_edit'),\n\t\t\t\t'create.ads' => trans('permissions/general.ads_create'),\n\t\t\t\t'delete.ads' => trans('permissions/general.ads_delate'),\n\t\t\t),\n\t\t\t'adscompanies' => array(\n\t\t\t\t'adscompanies' => trans('permissions/general.adscompanies_list'),\n\t\t\t\t'update.adscompanies' => trans('permissions/general.adscompanies_edit'),\n\t\t\t\t'create.adscompanies' => trans('permissions/general.adscompanies_create'),\n\t\t\t\t'delete.adscompanies' => trans('permissions/general.adscompanies_delate'),\n\t\t\t),\n\t\t\t'adspositions' => array(\n\t\t\t\t'adspositions' => trans('permissions/general.adspositions_list'),\n\t\t\t\t'update.adspositions' => trans('permissions/general.adspositions_edit'),\n\t\t\t\t'create.adspositions' => trans('permissions/general.adspositions_create'),\n\t\t\t\t'delete.adspositions' => trans('permissions/general.adspositions_delate'),\n\t\t\t),\n\t\t\t'blogcategory' => array(\n\t\t\t\t'blogcategories' => trans('permissions/general.blogcategories_list'),\n\t\t\t\t'update.blogcategory' => trans('permissions/general.blogcategory_edit'),\n\t\t\t\t'create.blogcategory' => trans('permissions/general.blogcategory_create'),\n\t\t\t\t'delete.blogcategory' => trans('permissions/general.blogcategory_delate'),\n\t\t\t),\n\t\t\t'blog' => array(\n\t\t\t\t'blogs' => trans('permissions/general.blogs_list'),\n\t\t\t\t'update.blog' => trans('permissions/general.blog_edit'),\n\t\t\t\t'create.blog' => trans('permissions/general.blog_create'),\n\t\t\t\t'delete.blog' => trans('permissions/general.blog_delate'),\n\t\t\t),\n 'reporteditems' => array(\n\t\t\t\t'reporteditems' => trans('permissions/general.reporteditems_list'),\n\t\t\t\t'update.reporteditems' => trans('permissions/general.reporteditems_edit'),\n\t\t\t),\n 'issues' => array(\n\t\t\t\t'issues' => trans('permissions/general.issues_list'),\n\t\t\t\t'update.issues' => trans('permissions/general.issues_edit'),\n\t\t\t),\n 'plans' => array(\n\t\t\t\t'plans' => trans('permissions/general.plans_list'),\n\t\t\t\t'update.plan' => trans('permissions/general.plan_edit'),\n\t\t\t\t'create.plan' => trans('permissions/general.plan_create'),\n\t\t\t\t'delete.plan' => trans('permissions/general.plan_delate'),\n\t\t\t),\n 'payments' => array(\n\t\t\t\t'payments' => trans('permissions/general.payments_list'),\n\t\t\t),\n 'settings' => array(\n\t\t\t\t'settings' => trans('permissions/general.settings_list'),\n 'update.settings' => trans('permissions/general.settings_edit'),\n\t\t\t),\n 'coupons' => array(\n 'coupons' => trans('permissions/general.coupons_list'),\n\t\t\t\t'update.coupons' => trans('permissions/general.coupons_edit'),\n\t\t\t\t'create.coupons' => trans('permissions/general.coupons_create'),\n\t\t\t\t'delete.coupons' => trans('permissions/general.coupons_delate'),\n ),\n 'claim' => array(\n 'claim' => trans('permissions/general.claim_claim'),\n 'unclaim' => trans('permissions/general.claim_unclaim'),\n 'claim.sales' => trans('permissions/general.claim_sales'),\n 'claim.approve' => trans('permissions/general.claim_approve'),\n 'claim.unapprove' => trans('permissions/general.claim_unapprove'),\n ),\n 'sales' => array(\n 'sales.sales' => trans('permissions/general.sales'),\n 'sales.approve' => trans('permissions/general.sales_approve'),\n ),\n\t\t);\n\t\t\n\t\treturn $permissions;\n }",
"protected function getOptions() \r\n\t{\r\n\t\t$options = array('Modus 1', 'Modus 2');\r\n\t\treturn $options;\r\n\t}",
"abstract protected function getPermissions();",
"public function getPermissions();",
"public function getPermissions();",
"public function getPermissions();",
"public function getPermissions();",
"public function getPermissions();",
"public function getPermissions()\n {\n return $this->permissions;\n }",
"public function getPermissions()\n {\n return $this->permissions;\n }",
"public function getPermissions()\n {\n return $this->permissions;\n }",
"public function getEffectivePermissions()\n {\n return $this->effective_permissions;\n }",
"public function getPermissions() : string\n {\n return $this->permissions;\n }",
"public function permissions(): array\n {\n $permissions = [];\n $operations = ['create', 'read', 'update', 'delete'];\n\n foreach ($operations as $operation) {\n $permissions[$operation] = lit_user()\n ? $this->authorize(lit_user(), $operation)\n : false;\n }\n\n return $permissions;\n }"
] | [
"0.7620145",
"0.7596545",
"0.73881465",
"0.6713674",
"0.6673849",
"0.6666611",
"0.6584979",
"0.643198",
"0.6333509",
"0.63205564",
"0.6287562",
"0.62157226",
"0.6136772",
"0.6108583",
"0.6085702",
"0.60800964",
"0.6077112",
"0.6074156",
"0.6052579",
"0.6047676",
"0.6047676",
"0.6047676",
"0.6047676",
"0.6047676",
"0.6035367",
"0.6035367",
"0.6035367",
"0.6030226",
"0.60117203",
"0.60048676"
] | 0.7619478 | 1 |
Returns a list of directory options to map to flexshare. | function get_dir_options($name)
{
clearos_profile(__METHOD__, __LINE__);
$options = array();
// Custom
try {
$custom_data = $this->_get_global_parameter('FlexshareDirCustom');
if (! empty($custom_data)) {
$list = preg_split("/\\|/", $this->_get_global_parameter('FlexshareDirCustom'));
foreach ($list as $custom) {
list ($desc, $path) = preg_split("/:/", $custom);
$options[$path] = $desc . ' (' . $path . ")\n";
}
}
} catch (Flexshare_Parameter_Not_Found_Exception $e) {
// Ignore
} catch (Engine_Exception $e) {
// Ignore
}
// If $name is NULL, fancy up the path displayed
if ($name == NULL)
$display_name = preg_replace('/ /', '_', strtoupper(lang('flexshare_share_name')));
else
$display_name = $name;
// Default
$options[self::SHARE_PATH . '/' . $name] = lang('base_default') . ' (' . self::SHARE_PATH . '/' . $display_name . ")";
return $options;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function get_web_folder_layout_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::FOLDER_LAYOUT_STANDARD => lang('flexshare_standard'),\n self::FOLDER_LAYOUT_SANDBOX => lang('flexshare_sandbox')\n );\n\n return $options;\n }",
"function get_file_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"function get_web_access_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::ACCESS_LAN => lang('flexshare_access_lan'),\n self::ACCESS_ALL => lang('base_all')\n );\n\n return $options;\n }",
"public function getDirectoryListing();",
"public static function getFolderTypes(): array\r\n {\r\n return self::getOptions('folders');\r\n }",
"public function getOptions()\n\t{\n\t\t$options = array();\n\n\t\t$directories = glob(JPATH_ROOT . '/media/editors/tinymce/skins' . '/*', GLOB_ONLYDIR);\n\n\t\tfor ($i = 0, $iMax = count($directories); $i < $iMax; ++$i)\n\t\t{\n\t\t\t$dir = basename($directories[$i]);\n\t\t\t$options[] = JHtml::_('select.option', $i, $dir);\n\t\t}\n\n\t\t$options = array_merge(parent::getOptions(), $options);\n\n\t\treturn $options;\n\t}",
"public function list_ldap_access_options() {\n\t\tif(is_null($this->id)) throw new BadMethodCallException('Server must be in directory before LDAP access options can be listed');\n\t\t$stmt = $this->database->prepare(\"\n\t\t\tSELECT *\n\t\t\tFROM server_ldap_access_option\n\t\t\tWHERE server_id = ?\n\t\t\tORDER BY `option`\n\t\t\");\n\t\t$stmt->bind_param('d', $this->id);\n\t\t$stmt->execute();\n\t\t$result = $stmt->get_result();\n\t\t$options = array();\n\t\twhile($row = $result->fetch_assoc()) {\n\t\t\t$options[$row['option']] = new ServerLDAPAccessOption($row['option'], $row);\n\t\t}\n\t\t$stmt->close();\n\t\treturn $options;\n\t}",
"public function getDirectoryList() : array\n {\n return $this->directoryList;\n }",
"function get_options() {\r\n return get_option($this->dir, array());\r\n }",
"function getAdminOptions() {\n $devloungeAdminOptions = array('brandfolder_url' => '');\n $devOptions = get_option($this->adminOptionsName);\n if (!empty($devOptions)) {\n foreach ($devOptions as $key => $option)\n $devloungeAdminOptions[$key] = $option;\n }\n update_option($this->adminOptionsName, $devloungeAdminOptions);\n return $devloungeAdminOptions;\n }",
"function get_ftp_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE_PLUS => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"public function directoryProvider() {\n\t\treturn [['folder']];\n\t}",
"public static function get_filemanager_options() {\n return [\n 'subdirs' => 1,\n 'accepted_types' => '*'\n ];\n }",
"private function get_all_dir() {\n $arraFinal = [];\n $directory = $this->dirArray;\n $indexCount = count($directory);\n\n for ($index = 1; $index < $indexCount; $index++):\n if (substr(\"$directory[$index]\", 0, 1) != \".\" && $directory[$index] != 'inc') {// don't list hidden files\n $arraFinal[] = array(\n \"file\" => \"$directory[$index]\",\n \"name\" => ucwords(str_replace('_', ' ', $directory[$index])),\n \"type\" => mime_content_type(\"$directory[$index]\"),\n \"size\" => $this->formatBytes(filesize(\"$directory[$index]\")),\n \"created\" => date('d-m-Y H:i:s', filectime(\"$directory[$index]\")),\n \"modified\" => date('d-m-Y H:i:s', filemtime(\"$directory[$index]\"))\n );\n }\n endfor;\n $this->dirArray = $arraFinal;\n }",
"static function getOptions()\n\t{\n\t\treturn array_merge(parent::getOptions(), array('files'));\n\t}",
"protected function getOptions()\n\t{\n\t\t// Initialize variables.\n\t\t$options = array();\n\n\t\t// Get the Ldap Domains\n\t\t$configs = SHLdapHelper::getConfigIDs();\n\n\t\t// Present the Ldap domains in the list\n\t\tforeach ($configs as $id => $config)\n\t\t{\n\t\t\t$options[] = JHtml::_('select.option', $config, $config, 'value', 'text');\n\t\t}\n\n\t\t// Merge any additional options in the XML definition.\n\t\t$options = array_merge(parent::getOptions(), $options);\n\n\t\treturn $options;\n\t}",
"public static function get_options() {\n\n\t\t$custom = [];\n\n\t\tif ( defined( 'KINSTA_CDN_USERDIRS' ) && ! empty( KINSTA_CDN_USERDIRS ) ) {\n\t\t\t$custom['dirs'] = 'wp-content,wp-includes,images,' . KINSTA_CDN_USERDIRS;\n\t\t}\n\t\tif ( isset( $_SERVER['KINSTA_CDN_DOMAIN'] ) && '' !== $_SERVER['KINSTA_CDN_DOMAIN'] ) {\n\t\t\t$custom['url'] = 'https://' . $_SERVER['KINSTA_CDN_DOMAIN'];\n\t\t}\n\t\tif ( isset( $_SERVER['KINSTA_CDN_DIRECTORIES'] ) && '' !== $_SERVER['KINSTA_CDN_DIRECTORIES'] ) {\n\t\t\t$custom['dirs'] = $_SERVER['KINSTA_CDN_DIRECTORIES'];\n\t\t}\n\t\tif ( isset( $_SERVER['KINSTA_CDN_EXCLUDE_TYPES'] ) && '' !== $_SERVER['KINSTA_CDN_EXCLUDE_TYPES'] ) {\n\t\t\t$exclude_types = sanitize_exclude_types( $_SERVER['KINSTA_CDN_EXCLUDE_TYPES'] );\n\t\t\t$exclude_types = array_merge( [ '.php' ], $exclude_types );\n\n\t\t\t$custom['exclude_types'] = $exclude_types;\n\t\t}\n\t\tif ( isset( $_SERVER['KINSTA_CDN_HTTPS'] ) && '' !== $_SERVER['KINSTA_CDN_HTTPS'] ) {\n\t\t\t$custom['https'] = $_SERVER['KINSTA_CDN_HTTPS'];\n\t\t}\n\n\t\treturn wp_parse_args(\n\t\t\t$custom,\n\t\t\t[\n\t\t\t\t'url' => get_option( 'home' ),\n\t\t\t\t'dirs' => 'wp-content,wp-includes,images',\n\t\t\t\t'exclude_types' => [ '.php' ],\n\t\t\t\t'relative' => 1,\n\t\t\t\t'https' => 1,\n\t\t\t]\n\t\t);\n\t}",
"protected function getOptions()\n\t{\n\t\t// Initialize variables.\n\t\t$options = array();\n\n\t\t// Initialize some field attributes.\n\t\t$filter = (string) $this->element['filter'];\n\t\t$exclude = (string) $this->element['exclude'];\n\t\t$hideNone = (string) $this->element['hide_none'];\n\t\t$hideDefault = (string) $this->element['hide_default'];\n\t\t$base \t\t= JPATH_ROOT;\n\t\t// Get the path in which to search for file options.\n\t\t$path = (string) $this->element['directory'];\n\t\tif (!is_dir($path))\n\t\t{\n\t\t\t$path = JPATH_ROOT . '/' . $path;\n\t\t}\n\n\t\t// Prepend some default options based on field attributes.\n\t\tif (!$hideNone)\n\t\t{\n\t\t\t$options[] = JHtml::_('select.option', '-1', JText::alt('JOPTION_DO_NOT_USE', preg_replace('/[^a-zA-Z0-9_\\-]/', '_', $this->fieldname)));\n\t\t}\n\t\tif (!$hideDefault)\n\t\t{\n\t\t\t$options[] = JHtml::_('select.option', '', JText::alt('JOPTION_USE_DEFAULT', preg_replace('/[^a-zA-Z0-9_\\-]/', '_', $this->fieldname)));\n\t\t}\n\n\t\t// Get a list of folders in the search path with the given filter.\n\t\t$folders = JFolder::folders($path, $filter, true, true);\n\n\t\t// Build the options list from the list of folders.\n\t\tif (is_array($folders))\n\t\t{\n\t\t\tforeach ($folders as $folder)\n\t\t\t{\n\t\t\t\t$folder = str_replace(JPATH_ROOT, '', $folder);\n\t\t\t\t// Check to see if the file is in the exclude mask.\n\t\t\t\tif ($exclude)\n\t\t\t\t{\n\t\t\t\t\tif (preg_match(chr(1) . $exclude . chr(1), $folder))\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$options[] = JHtml::_('select.option', $folder, $folder);\n\t\t\t}\n\t\t}\n\n\t\t// Merge any additional options in the XML definition.\n\t\t$options = array_merge(parent::getOptions(), $options);\n\n\t\treturn $options;\n\t}",
"function get_allowed_use_subdirectories() {\n\treturn [ 'common' ];\n}",
"private function getRemoteDirectoryList() : array\n {\n return Util\\Path::getDirectoryListFromAbsolutePath($this->remotePath->getPath());\n }",
"public static function getOptions() {\n global $sitemap_activated;\n if(!$sitemap_activated)\n return array();\n\n $robot = new File('..', 'robots.txt');\n $sitemap = new File('..', 'sitemap.xml');\n $rights = array(\n '../robots.txt' => $robot->isWritable(true),\n '../sitemap.xml' => $sitemap->isWritable(true),\n );\n $failure = false;\n foreach($rights as $file=>$r) {\n if(!$r) {\n $failure = true;\n break;\n }\n }\n if($failure)\n Controller::notifyUser('error', 'permission', $rights);\n\n return array();\n }",
"public function getOptions()\n {\n if (isset($this->options)) {\n return $this->options;\n }\n\n $options = array();\n foreach ($this->fieldMap as $ldapName => $finnovaName) {\n\n $option = $this->getConfig()->get($finnovaName);\n if (isset($option)) {\n $options[$ldapName] = $option;\n }\n }\n\n $this->options = $this->normalizeOptions($options);\n\n return $this->options;\n }",
"function getOptions()\n {\n if (count($this->options) > 0) {\n return $this->options;\n }\n \n $options = array();\n $items = xarMod::apiFunc('modules', 'admin', 'getlist',array('filter' => $this->filter));\n foreach($items as $item) {\n try {\n $options[] = array('id' => $item[$this->initialization_store_prop], 'name' => $item[$this->initialization_display_prop]);\n } catch(Exception $e) {}\n }\n return $options;\n }",
"function getAllApps(){\n\t$dir1 = scandir('.');\n foreach($dir1 as $element) {\n\t if (is_dir($element) && $element != '.' && $element != '..') {\n\t echo '<option value=\"'.$element .'\">'.$element .'</option>';\n\t }\n }\n}",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'size' => 1\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"public function toOptionArray()\r\n {\r\n $options = array(\r\n array('value' => Mage_Core_Model_Store::URL_TYPE_JS, 'label' => '/js/'),\r\n array('value' => Mage_Core_Model_Store::URL_TYPE_MEDIA, 'label' => '/media/'),\r\n array('value' => Mage_Core_Model_Store::URL_TYPE_SKIN, 'label' => '/skin/'),\r\n );\r\n\r\n return $options;\r\n }",
"public function getDirectories(){\n\t\t$sql = \"select * from st_directories\";\n\t\t$data = $this->runRequest ( $sql );\n\t\treturn $data->fetchAll();\n\t}",
"public function dir_list($dir){\n\t\n\t\n\t$d = dir($dir);\n\t$temp = array();\n\t\n\twhile (false !== ($entry = $d->read())) {\n\t\tif(is_dir($entry)){\n\t\t\tif($entry !='.' && $entry != '..' && $entry != '.settings' ){\t\n\t\t\t\t\n \t\t \t\tarray_push($temp, $entry);\n \t\t \t\t\n\t\t\t}\n\t\t}\n\t}\n\t$d->close();\n\n\treturn $temp;\n\t\n\t\n\t}",
"public function getServersList() {\n \n require_once 'BackupPcFinder.php';\n \n switch($this->type) {\n \n case 'tarhely':\n \n $finder = new BackupPcFinder($this->config['path_to_tarhely_backups']);\n \n return $finder->listDirs(); \n \n break;\n case 'mysql':\n \n $finder = new BackupPcFinder($this->config['path_to_mysql_backups']);\n \n return $finder->listDirs();\n \n break;\n }\n }",
"protected function getOptions() \r\n\t{\r\n\t\t$options = array('Modus 1', 'Modus 2');\r\n\t\treturn $options;\r\n\t}"
] | [
"0.6288097",
"0.61491024",
"0.6119608",
"0.60213774",
"0.5947053",
"0.5939162",
"0.5928367",
"0.5906145",
"0.583526",
"0.57831097",
"0.5777791",
"0.5738438",
"0.5646027",
"0.5538807",
"0.5533376",
"0.5497012",
"0.54867136",
"0.54736406",
"0.54677767",
"0.5446585",
"0.54294103",
"0.53769815",
"0.53584975",
"0.5341996",
"0.53188336",
"0.5302848",
"0.53014064",
"0.52959216",
"0.5277022",
"0.5273194"
] | 0.7534738 | 0 |
Returns a list of valid web access options for a flexshare. | function get_web_access_options()
{
clearos_profile(__METHOD__, __LINE__);
$options = array(
self::ACCESS_LAN => lang('flexshare_access_lan'),
self::ACCESS_ALL => lang('base_all')
);
return $options;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function wine_access_options($wine) {\n\t$access_array = array(\n\t\tACCESS_PRIVATE => 'private',\n\t\tACCESS_LOGGED_IN => 'logged in users',\n\t\tACCESS_PUBLIC => 'public',\n\t\t$wine->group_acl => elgg_echo('wine:acl', array($wine->name)),\n\t);\n\treturn $access_array;\n}",
"function get_file_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"function validate_web_access($accessibility)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = $this->get_web_access_options();\n\n if (!array_key_exists($accessibility, $options))\n return lang('flexshare_accessibility_invalid');\n }",
"function get_ftp_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE_PLUS => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"public function accessControls()\n {\n return [\n [\n 'allow' => true,\n 'roles' => ['?'],\n ],\n\n [\n 'allow' => true,\n 'actions' => ['options'],\n 'roles' => ['?'],\n ],\n ];\n }",
"function get_dir_options($name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array();\n\n // Custom\n try {\n $custom_data = $this->_get_global_parameter('FlexshareDirCustom');\n if (! empty($custom_data)) {\n $list = preg_split(\"/\\\\|/\", $this->_get_global_parameter('FlexshareDirCustom'));\n foreach ($list as $custom) {\n list ($desc, $path) = preg_split(\"/:/\", $custom);\n $options[$path] = $desc . ' (' . $path . \")\\n\";\n }\n }\n } catch (Flexshare_Parameter_Not_Found_Exception $e) {\n // Ignore\n } catch (Engine_Exception $e) {\n // Ignore\n }\n\n // If $name is NULL, fancy up the path displayed\n if ($name == NULL)\n $display_name = preg_replace('/ /', '_', strtoupper(lang('flexshare_share_name'))); \n else\n $display_name = $name;\n\n // Default\n $options[self::SHARE_PATH . '/' . $name] = lang('base_default') . ' (' . self::SHARE_PATH . '/' . $display_name . \")\";\n\n return $options;\n }",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'size' => 1\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'cols' => 1,\n\t\t\t\t\t\t\t'rows' => 1,\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'tabindex' => 1,\n\t\t\t\t\t\t\t'accesskey' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'readonly' => 1\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"public function list_ldap_access_options() {\n\t\tif(is_null($this->id)) throw new BadMethodCallException('Server must be in directory before LDAP access options can be listed');\n\t\t$stmt = $this->database->prepare(\"\n\t\t\tSELECT *\n\t\t\tFROM server_ldap_access_option\n\t\t\tWHERE server_id = ?\n\t\t\tORDER BY `option`\n\t\t\");\n\t\t$stmt->bind_param('d', $this->id);\n\t\t$stmt->execute();\n\t\t$result = $stmt->get_result();\n\t\t$options = array();\n\t\twhile($row = $result->fetch_assoc()) {\n\t\t\t$options[$row['option']] = new ServerLDAPAccessOption($row['option'], $row);\n\t\t}\n\t\t$stmt->close();\n\t\treturn $options;\n\t}",
"protected function getRequiredOptions()\n {\n return [\n 'urlAuthorize',\n 'urlAccessToken',\n ];\n }",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'cols' => 1,\n\t\t\t\t\t\t\t'rows' => 1,\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'tabindex' => 1,\n\t\t\t\t\t\t\t'accesskey' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'readonly' => 1,\n\t\t\t\t\t\t\t'type' => 2\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"function access_scheme_list_field_settings($scheme, $has_data) {\n // Find all available fields of the given type.\n $fields = field_read_fields(array('type' => $scheme->type));\n // Exclude other realm fields from the list.\n foreach ($fields as $field_name => $field) {\n if (!empty($field['settings']['allowed_values_function']) && $field['settings']['allowed_values_function'] == '_access_field_allowed_values') {\n unset($fields[$field_name]);\n }\n }\n\n // Build the form.\n $form = array();\n if (!empty($fields)) {\n $options = drupal_map_assoc(array_keys($fields));\n $form['field_name'] = array(\n '#type' => 'select',\n '#title' => t('List field'),\n '#description' => t('The allowed values list from this field will become the access realms for the scheme.'),\n '#default_value' => isset($scheme->settings['field_name']) ? $scheme->settings['field_name'] : NULL,\n '#options' => $options,\n '#required' => TRUE,\n '#disabled' => $has_data,\n );\n }\n return $form;\n}",
"public static function getOptions() {\n global $sitemap_activated;\n if(!$sitemap_activated)\n return array();\n\n $robot = new File('..', 'robots.txt');\n $sitemap = new File('..', 'sitemap.xml');\n $rights = array(\n '../robots.txt' => $robot->isWritable(true),\n '../sitemap.xml' => $sitemap->isWritable(true),\n );\n $failure = false;\n foreach($rights as $file=>$r) {\n if(!$r) {\n $failure = true;\n break;\n }\n }\n if($failure)\n Controller::notifyUser('error', 'permission', $rights);\n\n return array();\n }",
"function kleo_memberships($theme='')\n{\n\t$restrict_options = sq_option('membership');\n\t\n\treturn $restrict_options;\n}",
"public function get_allowlist_plugins() {\n\t\t\t// Fetch allowlist from wp-options\n\t\t\t$this->allowlist = get_option( 'woocart_allowlist_plugins', array() );\n\t\t}",
"public static function getSettings()\n {\n return [\n 'login' => 'editor',\n 'legalTemplates' => ['skyscraper'],\n 'access' => [\n 'templates' => [\n [\n 'name' => 'skyscraper',\n // 'roles' => ['editor'], // <-- has no view permission\n ]\n ]\n ]\n ];\n }",
"public static function getSettings()\n {\n return [\n 'login' => 'editor',\n 'legalTemplates' => ['skyscraper'],\n 'legalFields' => ['title'],\n 'access' => [\n 'templates' => [\n [\n 'name' => 'skyscraper',\n 'roles' => ['editor'],\n ]\n ],\n 'fields' => [\n [\n 'name' => 'title',\n 'viewRoles' => ['editor'], // <-- has view permission for title!\n ]\n ]\n ]\n ];\n }",
"public static function getSettings()\n {\n return [\n 'login' => 'admin',\n 'legalTemplates' => ['skyscraper'],\n 'legalFields' => ['title'],\n ];\n }",
"public function testAccessOptionsShouldBeLimitedToPrivateOrLoggedIn() {\n\t\t$this->markTestIncomplete('Requires manual testing for now');\n\t}",
"public function accessRules()\n\t{\n\t\t$cekFitur = Option::model()->findAll(array('condition'=>'key_config LIKE \"%fitur_materi%\"'));\n\t\t$status = 1;\n\n\t\tif(!empty($cekFitur)){\n\t\t\tif($cekFitur[0]->value == 2){\n\t\t\t\t$status = 2;\n\t\t\t}\n\t\t}\n\n\t\treturn array(\n\t\t\t/*array('allow', // allow all users to perform 'index' and 'view' actions\n\t\t\t\t'actions'=>array('index','view'),\n\t\t\t\t'users'=>array('*'),\n\t\t\t),*/\n\t\t\tarray('allow', // allow all users to perform 'index' and 'view' actions\n\t\t\t\t'actions'=>array('index','view'),\n\t\t\t\t//'users'=>array('@'),\n\t\t\t\t'expression'=>\"(!Yii::app()->user->isGuest && $status == 1)\",\n\t\t\t),\n\t\t\tarray('allow', // allow authenticated user to perform 'create' and 'update' actions\n\t\t\t\t'actions'=>array('create','update','hapus','copy'),\n\t\t\t\t'expression'=>\"(Yii::app()->user->YiiTeacher && $status == 1)\",\n\t\t\t),\n\t\t\tarray('allow', // allow admin user to perform 'admin' and 'delete' actions\n\t\t\t\t'actions'=>array('admin','delete','copy','create','update','hapus'),\n\t\t\t\t'expression'=>\"(Yii::app()->user->YiiAdmin && $status == 1)\",\n\t\t\t),\n\t\t\tarray('deny', // deny all users\n\t\t\t\t'users'=>array('*'),\n\t\t\t\t// 'actions'=>array('*'),\n\t\t\t\t// 'expression'=>\"{$status} == {2}\",\n\t\t\t),\n\t\t);\n\t}",
"function GetPossibleAccess()\n\t{\t$access = array();\n\t\tforeach ($this->user->accessAreas as $area=>$flag)\n\t\t{\t$access[$area] = $area;\n\t\t}\n\t\treturn $access;\n\t}",
"protected function _generate_web_flexshares()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (!clearos_library_installed('web_server/Httpd'))\n return;\n\n $httpd = new Httpd();\n\n // Create a unique file identifier\n $backup_key = time();\n\n // Get file listing in Apache vhost dir\n $folder = new Folder(self::WEB_VIRTUAL_HOST_PATH);\n $vhosts = $folder->get_listing();\n $index = 0;\n\n foreach ($vhosts as $vhost) {\n // Flexshares are prefixed with 'flexshare-'. Find these files\n if (preg_match(\"/flex-443.conf|^\" . self::PREFIX . \".*vhost$|^\" . self::PREFIX . \".*conf$/i\", $vhost)) {\n $vhost_file = new File(self::WEB_VIRTUAL_HOST_PATH . \"/\" . $vhost);\n // Backup existing file\n $vhost_file->move_to(self::PATH_TEMP . \"/\" . \"$vhost.$backup_key.bak\");\n } else {\n unset($vhosts[$index]);\n }\n\n $index++;\n }\n\n // Re-order shared to make sure default web site is first virtual host\n //--------------------------------------------------------------------\n\n $raw_shares = $this->_get_shares(self::TYPE_ALL);\n\n $shares = array();\n\n foreach ($raw_shares as $name => $share) {\n if (empty($share['WebDefaultSite']))\n $shares[] = $share;\n else\n array_unshift($shares, $share);\n }\n\n // Grab the list of ports from the PHP Engine app\n //-----------------------------------------------\n\n if (clearos_load_library('php_engines/PHP_Engines')) {\n $php_engine = new \\clearos\\apps\\php_engines\\PHP_Engines();\n $php_engine_ports = $php_engine->get_ports();\n\n // TODO: remove method check in ClearOS 8.0\n if (method_exists($php_engine, 'get_version_codes')) {\n $php_version_codes = $php_engine->get_version_codes();\n } else {\n $php_version_codes['rh-php56-php-fpm'] = 56;\n $php_version_codes['rh-php70-php-fpm'] = 70;\n }\n } else {\n $php_engine_ports = [];\n }\n\n // Recreate all virtual configs\n //-----------------------------\n\n $lans = NULL;\n $newlines = array();\n $flexshare_certs = array();\n $flexshare_php_engines = array();\n $website_certs = array();\n $website_php_engines = array();\n\n foreach ($shares as $share) {\n $name = $share['Name'];\n\n $newlines = array();\n $config_doc_comment = array();\n $config_aliases = array();\n $config_directory = array();\n\n // Bail if not enabled, continue through loop - we're re-creating lines here\n //--------------------------------------------------------------------------\n\n if (! isset($share['ShareEnabled']) || ! $share['ShareEnabled'])\n continue;\n\n if (! isset($share['WebEnabled']) || ! $share['WebEnabled'])\n continue;\n\n if (isset($share['WebCustomConfiguration']) && $share['WebCustomConfiguration'])\n continue;\n\n // Certs\n //------\n\n if (!empty($share['WebSslCertificate'])) {\n if (($share['ShareInternal'] == 1) || ($share['ShareInternal'] == 2))\n $website_certs[$name] = $share['WebSslCertificate'];\n else\n $flexshare_certs[$name] = $share['WebSslCertificate'];\n }\n\n // PHP Engines\n //------------\n\n // Handle upgrade - if WebPhpEngine is not set, but PHP is running, it's using mod_php\n if (!isset($share['WebPhpEngine']) && $share['WebPhp'])\n $share['WebPhpEngine'] = 'httpd';\n\n if (!empty($share['WebPhpEngine'])) {\n if (($share['ShareInternal'] == 1) || ($share['ShareInternal'] == 2))\n $website_php_engines[$name] = $share['WebPhpEngine'];\n else\n $flexshare_php_engines[$name] = $share['WebPhpEngine'];\n }\n\n // Get LAN info, but only if it is necessary (expensive call)\n //-----------------------------------------------------------\n\n if (($share['WebAccess'] == self::ACCESS_LAN) && ($lans === NULL)) {\n $iface_manager = new Iface_Manager();\n $lans = $iface_manager->get_most_trusted_networks();\n }\n\n // Configuration doc comments\n //---------------------------\n\n if ($share['ShareInternal'] == 1)\n $doc_comment = 'Web Site';\n else if ($share['ShareInternal'] == 2)\n $doc_comment = 'Web App';\n else\n $doc_comment = 'File Share';\n\n $config_doc_comment[] = \"\";\n $config_doc_comment[] = \"# -----------------------------------------------#\";\n $config_doc_comment[] = \"# $doc_comment\";\n $config_doc_comment[] = \"# -----------------------------------------------#\";\n $config_doc_comment[] = \"\";\n\n // cgi-bin handling\n //-----------------\n\n if ($share['WebCgi']) {\n // Create cgi-bin directory if it does not exist.\n $cgifolder = new Folder(self::SHARE_PATH . \"/$name/cgi-bin\", TRUE);\n\n if (!$cgifolder->exists())\n $cgifolder->create(self::CONSTANT_WEB_SITE_USERNAME, self::CONSTANT_FILES_USERNAME, \"0777\");\n\n // Build <Directory> block for for cgi-bin\n $config_directory[] = \"<Directory \" . $share['ShareDir'] . \"/cgi-bin>\";\n $config_directory[] = \"\\tOptions +ExecCGI\";\n\n if ($share[\"WebAccess\"] == self::ACCESS_LAN) {\n $config_directory[] = \"\\tRequire local\";\n if (count($lans) > 0) {\n foreach ($lans as $lan)\n $config_directory[] = \"\\tRequire ip \" . $lan;\n }\n } else {\n if (!$share['WebReqAuth'])\n $config_directory[] = \"\\tRequire all granted\";\n }\n\n $config_directory[] = \"</Directory>\\n\";\n }\n\n // Sandbox subdir handling\n //-------------------------\n\n if (isset($share['WebFolderLayout']) && ($share['WebFolderLayout'] == self::FOLDER_LAYOUT_SANDBOX)) {\n $log_folder = new Folder(self::SHARE_PATH . \"/$name/\" . self::SANDBOX_LOG_SUBDIR, TRUE);\n\n if (!$log_folder->exists())\n $log_folder->create(self::CONSTANT_WEB_SITE_USERNAME, $share['ShareGroup'], '0775');\n\n $docroot_folder = new Folder(self::SHARE_PATH . \"/$name/\" . self::SANDBOX_DOCROOT_SUBDIR, TRUE);\n\n if (!$docroot_folder->exists())\n $docroot_folder->create(self::CONSTANT_WEB_SITE_USERNAME, $share['ShareGroup'], '0775');\n\n $errors_folder = new Folder(self::SHARE_PATH . \"/$name/\" . self::SANDBOX_ERRORS_SUBDIR, TRUE);\n\n if (!$errors_folder->exists())\n $errors_folder->create(self::CONSTANT_WEB_SITE_USERNAME, $share['ShareGroup'], '0775');\n }\n\n // Build <Directory> block\n //-------------------------\n\n $config_directory[] = \"<Directory \" . $share['ShareDir'] . \">\";\n $options = '';\n\n if ($share['WebShowIndex'])\n $options .= ' +Indexes';\n else\n $options .= ' -Indexes';\n\n if ($share['WebFollowSymLinks'] || $share['WebReqSsl'])\n $options .= ' +FollowSymLinks';\n else\n $options .= ' -FollowSymLinks';\n\n if ($share['WebAllowSSI'])\n $options .= ' +' . self::DEFAULT_SSI_PARAM;\n else\n $options .= ' -' . self::DEFAULT_SSI_PARAM;\n\n if (strlen($options) > 0)\n $config_directory[] = \"\\tOptions\" . $options;\n\n if ($share['WebHtaccessOverride'])\n $config_directory[] = \"\\tAllowOverride All\";\n\n $phpenv = new File(self::SHARE_PATH . \"/$name/.phpenv\", TRUE);\n\n if ($phpenv->exists())\n $phpenv->delete();\n\n if ($share['WebPhpEngine'] && clearos_load_library('php_engines/PHP_Engines')) {\n $port = $php_engine_ports[$share['WebPhpEngine']];\n\n if (!empty($php_version_codes[$share['WebPhpEngine']])) {\n $phpenv->create('root', 'root', '0644');\n $phpenv->add_lines($php_version_codes[$share['WebPhpEngine']] . \"\\n\");\n }\n\n if ($port) {\n $config_directory[] = \"\\t<FilesMatch \\.php$>\";\n $config_directory[] = \"\\t\\tSetHandler \\\"proxy:fcgi://127.0.0.1:$port\\\"\";\n $config_directory[] = \"\\t</FilesMatch>\";\n }\n }\n\n if ($share['WebReqAuth']) {\n $config_directory[] = \"\\tAuthName \\\"\" . $share['WebRealm'] . \"\\\"\";\n $config_directory[] = \"\\tAuthType Basic\";\n $config_directory[] = \"\\tAuthBasicProvider external\";\n $config_directory[] = \"\\tAuthExternal pwauth\";\n $config_directory[] = \"\\t<RequireAll>\";\n $config_directory[] = \"\\t\\tRequire unix-group \" . $share['ShareGroup'];\n\n if ($share['WebAccess'] == self::ACCESS_LAN) {\n $config_directory[] = \"\\t\\t<RequireAny>\";\n $config_directory[] = \"\\t\\t\\tRequire local\";\n if (count($lans) > 0) {\n foreach ($lans as $lan)\n $config_directory[] = \"\\t\\t\\tRequire ip \" . $lan;\n }\n $config_directory[] = \"\\t\\t</RequireAny>\";\n }\n $config_directory[] = \"\\t</RequireAll>\";\n\n } else {\n if ($share['WebAccess'] == self::ACCESS_LAN) {\n $config_directory[] = \"\\t<RequireAny>\";\n $config_directory[] = \"\\t\\tRequire local\";\n if (count($lans) > 0) {\n foreach ($lans as $lan)\n $config_directory[] = \"\\t\\tRequire ip \" . $lan;\n }\n $config_directory[] = \"\\t</RequireAny>\";\n } else {\n $config_directory[] = \"\\tRequire all granted\";\n }\n }\n\n // PHP support\n //------------\n\n if ($share['WebPhp']) {\n // Anything required?\n } else {\n $config_directory[] = \"\\t<FilesMatch \\.php$>\";\n $config_directory[] = \"\\t\\tSetHandler None\";\n $config_directory[] = \"\\t\\tForceType text/plain\";\n $config_directory[] = \"\\t\\tSetHandler application/x-httpd-php-source\";\n $config_directory[] = \"\\t</FilesMatch>\";\n }\n\n if ($share['WebReqSsl']) {\n $config_directory[] = \"\\tRewriteEngine On\";\n $config_directory[] = \"\\tRewriteCond %{HTTPS} off\";\n $config_directory[] = \"\\tRewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}\";\n }\n\n // DAV (unsupported)\n $davcheck = self::SHARE_PATH . \"/$name/.DAV\";\n $davfile = new File($davcheck);\n if ($davfile->exists())\n $config_directory[] = \"\\tDav on\";\n\n $config_directory[] = \"</Directory>\\n\\n\\n\";\n\n // Ports\n //\n // For standard Flexshares:\n // - SSL or non-SSL can be specified, but not both\n // - End users can override the port number\n //\n // For web sites and web apps\n // - SSL or both SSL + non-SSL can be specified\n // - End usrs cannot override the prot number\n //-------------------------------------------------\n \n if (empty($share['ShareInternal'])) {\n if ($share['WebOverridePort'])\n $ports = array($share['WebPort']);\n else\n $ports = (isset($share['WebReqSsl']) && $share['WebReqSsl']) ? array(443) : array(80);\n } else {\n $ports = (isset($share['WebReqSsl']) && $share['WebReqSsl']) ? array(443) : array(80, 443);\n }\n\n // Create new configuration files in parallel\n //-------------------------------------------\n\n $config_one_time = array();\n\n foreach ($ports as $port) {\n // Need to know which file we'll be writing to.\n // We determine this by port\n // i.e. /etc/httpd/conf.d/flexshare-<port><ssl>.conf\n\n $ssl = (empty($share['ShareInternal']) && $share['WebOverridePort'] && $share['WebReqSsl']) ? '-ssl' : '';\n\n $filename = self::PREFIX . $port . $ssl . '.conf';\n $file = new File(self::WEB_VIRTUAL_HOST_PATH . '/' . $filename);\n\n // Create the configuration file\n // Write out a common header\n //-------------------------------\n\n if (! $file->exists()) {\n $vhosts[] = $filename;\n\n $header_lines = array();\n $header_lines[] = self::WRITE_WARNING;\n\n // Only specify Listen directive for custom ports\n if (($port != 80) && ($port != 443))\n $header_lines[] = \"Listen *:$port\";\n\n $header_lines[] = \"\";\n $header_lines[] = \"# Authentication mechanism\";\n $header_lines[] = \"DefineExternalAuth pwauth pipe /usr/bin/pwauth\";\n $header_lines[] = \"DefineExternalGroup pwauth pipe /usr/bin/unixgroup\";\n $header_lines[] = \"\";\n\n $file->create('root', 'root', '0644');\n $file->add_lines(implode(\"\\n\", $header_lines));\n }\n\n // Write out Aliases and Directory definitions. This is only\n // required once per FlexShare, whereas VirtualHost blocks\n // can appear multiple times.\n\n $check_name = $share['Name'];\n\n if (in_array($check_name, $config_one_time)) {\n $config_aliases = array();\n $config_directory = array();\n } else {\n $config_aliases = $this->_generate_web_aliases($share, $port);\n\n $config_one_time[] = $check_name;\n }\n\n // Create new configuration files in parallel\n $config_virtual_host = $this->_generate_web_virtual_hosts($share, $port);\n\n $config_lines = array_merge(\n $config_doc_comment,\n $config_aliases,\n $config_virtual_host,\n $config_directory\n );\n\n $file->add_lines(implode(\"\\n\", $config_lines));\n }\n }\n\n // Validate httpd configuration before restarting server\n //------------------------------------------------------\n\n $config_ok = TRUE;\n\n try {\n $shell = new Shell();\n $shell_options['validate_exit_code'] = FALSE;\n $exitcode = $shell->execute(self::CMD_VALIDATE_HTTPD, '-t', TRUE, $shell_options);\n } catch (Exception $e) {\n // Backup out of commits\n $config_ok = FALSE;\n }\n\n if (($config_ok === FALSE) || ($exitcode != 0)) {\n $config_ok = FALSE;\n $output = $shell->get_output();\n clearos_log(self::LOG_TAG, \"Invalid httpd configuration!\");\n // Oops...we generated an invalid conf file\n foreach ($output as $line)\n clearos_log(self::LOG_TAG, $line);\n }\n\n foreach ($vhosts as $vhost) {\n // Not a flexshare vhost file\n if (!isset($vhost))\n continue;\n\n $file = new File(self::PATH_TEMP . \"/$vhost.$backup_key.bak\");\n\n if (! $file->exists()) {\n // Conf was newly created\n $file = new File(self::WEB_VIRTUAL_HOST_PATH . \"/$vhost\");\n if (! $config_ok)\n $file->delete();\n\n continue;\n }\n\n if ($config_ok) {\n // Delete backups\n $file->delete();\n } else {\n // Recover backups\n $file->move_to(self::WEB_VIRTUAL_HOST_PATH . \"/$vhost\");\n }\n }\n\n if ($config_ok) {\n try {\n $httpd = new Httpd();\n $httpd->reset(TRUE);\n } catch (Exception $e) {\n // Keep going\n }\n } else {\n throw new Engine_Exception(lang('flexshare_config_validation_failed'), CLEAROS_ERROR);\n }\n\n // Report state of certs to Certificate Manager\n //---------------------------------------------\n\n $certificate_manager = new Certificate_Manager();\n $certificate_manager->register($flexshare_certs, 'flexshare', lang('flexshare_app_name'));\n $certificate_manager->register($website_certs, 'web_server', lang('web_server_app_name'));\n\n if (clearos_load_library('php_engines/PHP_Engines')) {\n $php = new \\clearos\\apps\\php_engines\\PHP_Engines();\n $php->register($website_php_engines, 'web_server', lang('web_server_app_name'));\n $php->register($flexshare_php_engines, 'flexshare', lang('flexshare_app_name'));\n }\n }",
"function smatika_get_all_options()\r\n {\r\n return array(\r\n 'smatika_activate_prod_mode',\r\n 'smatika_use_local_font',\r\n 'smatika_enable_top_bar',\r\n 'smatika_show_top_social_icons',\r\n 'smatika_enable_sticky_header',\r\n 'smatika_enable_back_to_top_btn',\r\n 'smatika_show_home_page_banner',\r\n 'smatika_banner_closable',\r\n 'smatika_banner_show_ask_box',\r\n 'smatika_show_collapsible_btns',\r\n 'smatika_show_breadcrumbs',\r\n 'smatika_show_site_stats_above_footer',\r\n 'smatika_show_social_links_at_footer',\r\n 'smatika_show_copyright_at_footer',\r\n 'smatika_copyright_text',\r\n 'smatika_banner_head_text',\r\n 'smatika_banner_div1_text',\r\n 'smatika_banner_div1_icon',\r\n 'smatika_banner_div2_text',\r\n 'smatika_banner_div2_icon',\r\n 'smatika_banner_div3_text',\r\n 'smatika_banner_div3_icon',\r\n 'smatika_top_bar_left_text',\r\n 'smatika_top_bar_right_text',\r\n );\r\n }",
"public function getIsExternalShareEnabled()\n {\n if (array_key_exists(\"isExternalShareEnabled\", $this->_propDict)) {\n return $this->_propDict[\"isExternalShareEnabled\"];\n } else {\n return null;\n }\n }",
"function get_web_folder_layout_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::FOLDER_LAYOUT_STANDARD => lang('flexshare_standard'),\n self::FOLDER_LAYOUT_SANDBOX => lang('flexshare_sandbox')\n );\n\n return $options;\n }",
"private function getAccessRules() {\n\n $rules['forbidden'] = \n array(\n );\n \n $rules['allowed'] = \n array(\n 'client'=>array(\n 'account'=>array('index','show'),\n 'client'=>array('show','edit','update'),\n 'staff'=>array('show','index'),\n 'invoice'=>array('index','show'),\n 'work'=>array('index','show'),\n )\n );\n \n return $rules;\n\n }",
"function usersets_list() {\n\t$results = sql(\"SELECT * FROM usersets\",\"getAll\",DB_FETCHMODE_ASSOC);\n\tif(is_array($results)){\n\t\tforeach($results as $result){\n\t\t\t// check to see if we have a dept match for the current AMP User.\n\t\t\tif (checkDept($result['deptname'])){\n\t\t\t\t// return this item's dialplan destination, and the description\n\t\t\t\t$allowed[] = $result;\n\t\t\t}\n\t\t}\n\t}\n\tif (isset($allowed)) {\n\t\treturn $allowed;\n\t} else {\n\t\treturn null;\n\t}\n}",
"public function displayOptions()\n {\n $data = $_POST;\n $listing = geoListing::getListing($data['listing']);\n $urlToListing = $listing->getFullUrl();\n\n $tpl = new geoTemplate('addon', 'sharing');\n $tpl->assign('listing_url', urlencode($urlToListing));\n $tpl->assign('title', $listing->title); //already urlencoded in the database, and needs to stay that way\n $tpl->assign('description', urlencode(strip_tags(geoString::fromDB($listing->description))));\n $tpl->assign('msgs', geoAddon::getText('geo_addons', 'sharing'));\n $html = $tpl->fetch('methods/linkedin_options.tpl');\n return $html;\n }",
"public static function getSettings()\n {\n return [\n 'login' => 'editor',\n 'legalTemplates' => ['city'],\n 'legalFields' => ['images'], // <-- the \"title\" field is not legal.\n 'access' => [\n 'templates' => [\n [\n 'name' => 'city',\n 'roles' => ['editor'],\n 'editRoles' => ['editor'],\n ],\n ],\n 'fields' => [\n [\n 'name' => 'title',\n 'viewRoles' => ['editor'],\n 'editRoles' => ['editor'],\n ],\n [\n 'name' => 'images',\n 'viewRoles' => ['editor'],\n 'editRoles' => ['editor'],\n ],\n ]\n ]\n ];\n }",
"function getAdminOptions() {\n $devloungeAdminOptions = array('brandfolder_url' => '');\n $devOptions = get_option($this->adminOptionsName);\n if (!empty($devOptions)) {\n foreach ($devOptions as $key => $option)\n $devloungeAdminOptions[$key] = $option;\n }\n update_option($this->adminOptionsName, $devloungeAdminOptions);\n return $devloungeAdminOptions;\n }"
] | [
"0.60345024",
"0.5727811",
"0.55479926",
"0.5542275",
"0.55014783",
"0.54887253",
"0.54704213",
"0.5433015",
"0.542813",
"0.5425433",
"0.5409796",
"0.54067695",
"0.5403597",
"0.53871",
"0.5378966",
"0.5264397",
"0.5237183",
"0.52253884",
"0.51501304",
"0.51382935",
"0.51341206",
"0.51293296",
"0.5113023",
"0.5111519",
"0.51095873",
"0.5103998",
"0.5084541",
"0.50825167",
"0.5075314",
"0.50596243"
] | 0.7823245 | 0 |
Returns a list of valid web folder layout options. | function get_web_folder_layout_options()
{
clearos_profile(__METHOD__, __LINE__);
$options = array(
self::FOLDER_LAYOUT_STANDARD => lang('flexshare_standard'),
self::FOLDER_LAYOUT_SANDBOX => lang('flexshare_sandbox')
);
return $options;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private function getLayoutOptions()\n {\n $layouts = $this->get('finder')->in($this->get('path.theme').'layout')->files();\n $options = array();\n foreach ($layouts as $layout) {\n $options[$layout->getFileName()] = $layout->getFileName();\n }\n\n return $options;\n }",
"public function getLayoutList()\n {\n // get a list of all the layouts\n $layouts = File::files(base_path(config('pilot.plugins.pages.pathToPageLayouts', 'vendor/flex360/pilot/resources/views/layouts')));\n\n // clean up paths\n foreach ($layouts as $index => $layout) {\n // manipulate the path into a blade friendly form\n $layout = str_replace(base_path(config('pilot.plugins.pages.pathToLayoutCleanup', 'vendor/flex360/pilot/resources/views/')), '', $layout);\n\n $layout = str_replace('.blade.php', '', $layout);\n\n $layout = str_replace('.php', '', $layout);\n\n $layout = str_replace('/', '.', $layout);\n\n // remove the old layout\n unset($layouts[$index]);\n\n // add the layout in a select list friendly format\n $layouts[$layout] = ucfirst(substr($layout, strrpos($layout, '.') + 1));\n\n // remove any ignored layouts\n $ignoredLayouts = config('pilot.plugins.pages.ignoredLayouts');\n\n // ignore home layout when not the root page\n if (!$this->isRoot()) {\n $ignoredLayouts[] = 'layouts.home';\n }\n\n if (in_array($layout, $ignoredLayouts)) {\n unset($layouts[$layout]);\n }\n }\n\n return $layouts;\n }",
"public static function getLayoutOptions()\n\t{\n\t\treturn array(\n\t\t\t1 => 'Default',\n\t\t);\n\t}",
"function getLayouts(): array\n {\n return array_keys($this->options['layouts']);\n }",
"function acquia_get_layouts_options() {\n $contexts = acquia_get_layout_contexts();\n foreach ($contexts as $layout => &$info) {\n $info = t(str_replace(array(\"-\", \"_\"), \" \", $info));\n }\n\n return $contexts;\n}",
"public function layoutOptions() {\n return array_map(function (array $info) {\n return $info['title'];\n }, $this->declaredLayouts());\n }",
"function validate_web_folder_layout($layout)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = $this->get_web_folder_layout_options();\n\n if (!array_key_exists($layout, $options))\n return lang('flexshare_folder_layout_invalid');\n }",
"public static function getAvailableLayoutFormOptions($layouts);",
"public function get_layout_options() {\n\t\tcheck_ajax_referer( 'fusion_tb_new_layout', 'security' );\n\n\t\t$parent = isset( $_POST['parent'] ) ? sanitize_text_field( wp_unslash( $_POST['parent'] ) ) : '';\n\t\t$search = isset( $_POST['search'] ) ? sanitize_text_field( wp_unslash( $_POST['search'] ) ) : '';\n\t\t$page = isset( $_POST['page'] ) ? (int) $_POST['page'] : 1;\n\n\t\t$conditions = Fusion_Template_Builder()->get_layout_child_conditions( $parent, $page, $search );\n\n\t\twp_send_json_success( array_values( $conditions ) );\n\t}",
"protected function getLayouts() {\n $lReadOnly = (!$this -> mUsr -> canEdit('job-cms.template')) ? ' disabled' : '';\n $lArr = CCor_Res::get('htb', array('domain' => 'phl'));\n aSort($lArr);\n \n $lLayouts = array_merge(array(\"\" => \"\"), $lArr);\n\t$lRet = '<select id=\"layout1\" name=\"layout\" class=\"cms_lay w100p\" onchange=\"Flow.cmsTemplate.addItem(this);\"'.$lReadOnly.'>';\n foreach ($lLayouts as $lKey => $lName) {\n $lRet.= '<option value=\"'.$lKey.'\">'.htm($lName).'</option>'.LF;\n }\n $lRet.= '</select>';\n \n return $lRet;\n }",
"public static function getFolderTypes(): array\r\n {\r\n return self::getOptions('folders');\r\n }",
"public function formatLayoutTemplateFiles()\n {\n if(defined('THEME_FOLDER')) {\n $name = $this->getName();\n $presenter = substr($name, strrpos(':' . $name, ':'));\n $layout = $this->layout ? $this->layout : 'layout';\n $dir = dirname($this->getReflection()->getFileName());\n $dir = is_dir(\"$dir/templates\") ? $dir : dirname($dir);\n $list = array(\n \"$dir/templates/\" . THEME_FOLDER . \"/$presenter/@$layout.latte\",\n \"$dir/templates/\" . THEME_FOLDER . \"/$presenter.@$layout.latte\",\n \"$dir/templates/\" . THEME_FOLDER . \"/$presenter/@$layout.phtml\",\n \"$dir/templates/\" . THEME_FOLDER . \"/$presenter.@$layout.phtml\",\n );\n do {\n $list[] = \"$dir/templates/\" . THEME_FOLDER . \"/@$layout.latte\";\n $list[] = \"$dir/templates/\" . THEME_FOLDER . \"/@$layout.phtml\";\n $dir = dirname($dir);\n } while ($dir && ($name = substr($name, 0, strrpos($name, ':'))));\n return $list;\n } else {\n return parent::formatLayoutTemplateFiles();\n }\n }",
"public static function getAllLayouts()\n\t{\n\t\t$all = (new \\App\\Db\\Query())->select(['name', 'label'])->from('vtiger_layout')->all();\n\t\t$folders = [\n\t\t\t'basic' => Language::translate('LBL_DEFAULT'),\n\t\t];\n\t\tforeach ($all as $row) {\n\t\t\t$folders[$row['name']] = Language::translate($row['label']);\n\t\t}\n\n\t\treturn $folders;\n\t}",
"public function get_layout_type() {\n\t\t\treturn array(\n\t\t\t\t'0' => __( '— Select —', 'astra-addon' ),\n\t\t\t\t'header' => __( 'Header', 'astra-addon' ),\n\t\t\t\t'footer' => __( 'Footer', 'astra-addon' ),\n\t\t\t\t'404-page' => __( '404 Page', 'astra-addon' ),\n\t\t\t\t'hooks' => __( 'Hooks', 'astra-addon' ),\n\t\t\t\t'content' => __( 'Inside Post/Page Content', 'astra-addon' ),\n\t\t\t);\n\t\t}",
"public static function getLayouts(): array;",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'size' => 1\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"public static function getFieldLayoutOptions() {\n $options = [];\n foreach (\\Drupal::service('plugin.manager.ds.field.layout')->getDefinitions() as $plugin_id => $plugin) {\n $options[$plugin_id] = $plugin['title'];\n }\n return $options;\n }",
"abstract protected function options_layout();",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'cols' => 1,\n\t\t\t\t\t\t\t'rows' => 1,\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'tabindex' => 1,\n\t\t\t\t\t\t\t'accesskey' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'readonly' => 1\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'cols' => 1,\n\t\t\t\t\t\t\t'rows' => 1,\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'tabindex' => 1,\n\t\t\t\t\t\t\t'accesskey' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'readonly' => 1,\n\t\t\t\t\t\t\t'type' => 2\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"public function getAllowedFolderStructure()\n {\n if (!$this->getAllowedFolders()) {\n return [];\n }\n\n return Folder::getStructure($this->getAllowedFolders());\n }",
"protected function getOptions()\n\t{\n\t\t// Initialize variables.\n\t\t$options = array();\n\n\t\t// Initialize some field attributes.\n\t\t$filter = (string) $this->element['filter'];\n\t\t$exclude = (string) $this->element['exclude'];\n\t\t$hideNone = (string) $this->element['hide_none'];\n\t\t$hideDefault = (string) $this->element['hide_default'];\n\t\t$base \t\t= JPATH_ROOT;\n\t\t// Get the path in which to search for file options.\n\t\t$path = (string) $this->element['directory'];\n\t\tif (!is_dir($path))\n\t\t{\n\t\t\t$path = JPATH_ROOT . '/' . $path;\n\t\t}\n\n\t\t// Prepend some default options based on field attributes.\n\t\tif (!$hideNone)\n\t\t{\n\t\t\t$options[] = JHtml::_('select.option', '-1', JText::alt('JOPTION_DO_NOT_USE', preg_replace('/[^a-zA-Z0-9_\\-]/', '_', $this->fieldname)));\n\t\t}\n\t\tif (!$hideDefault)\n\t\t{\n\t\t\t$options[] = JHtml::_('select.option', '', JText::alt('JOPTION_USE_DEFAULT', preg_replace('/[^a-zA-Z0-9_\\-]/', '_', $this->fieldname)));\n\t\t}\n\n\t\t// Get a list of folders in the search path with the given filter.\n\t\t$folders = JFolder::folders($path, $filter, true, true);\n\n\t\t// Build the options list from the list of folders.\n\t\tif (is_array($folders))\n\t\t{\n\t\t\tforeach ($folders as $folder)\n\t\t\t{\n\t\t\t\t$folder = str_replace(JPATH_ROOT, '', $folder);\n\t\t\t\t// Check to see if the file is in the exclude mask.\n\t\t\t\tif ($exclude)\n\t\t\t\t{\n\t\t\t\t\tif (preg_match(chr(1) . $exclude . chr(1), $folder))\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$options[] = JHtml::_('select.option', $folder, $folder);\n\t\t\t}\n\t\t}\n\n\t\t// Merge any additional options in the XML definition.\n\t\t$options = array_merge(parent::getOptions(), $options);\n\n\t\treturn $options;\n\t}",
"public function layout_preferences()\n\t{\n\t\tif ( ! $this->layout_preferences )\n\t\t{\n\t\t\t$this->layout_preferences = get_option( $this->id_base . '-layout-preferences', array() );\n\t\t}//end if\n\n\t\treturn $this->layout_preferences;\n\t}",
"public function formatLayoutTemplateFiles() { \n $layoutFiles = parent::formatLayoutTemplateFiles(); \n $layoutFiles[] = __DIR__ . \"/../templates/@layout.latte\";\n return $layoutFiles;\n }",
"public static function getLayouts() {\n static $layouts = FALSE;\n\n if (!$layouts) {\n // This can be called before ds_update_8003() has run. If that is the case\n // return an empty array and don't static cache anything.\n if (!\\Drupal::hasService('plugin.manager.core.layout')) {\n return [];\n }\n $layouts = \\Drupal::service('plugin.manager.core.layout')->getDefinitions();\n }\n\n return $layouts;\n }",
"protected function get_layouts() {\n\t\treturn [\n\t\t\t'carousel' => __( 'Box Carousel', 'web-stories' ),\n\t\t\t'circles' => __( 'Circle Carousel', 'web-stories' ),\n\t\t\t'grid' => __( 'Grid', 'web-stories' ),\n\t\t\t'list' => __( 'List', 'web-stories' ),\n\t\t];\n\t}",
"protected static function allowedOptions()\n\t{\n\t\treturn array(\n\t\t\t\t\t\t'type' => 4,\n\t\t\t\t\t\t'constraint' => 4,\n\t\t\t\t\t\t'class' => 1,\n\t\t\t\t\t\t'title' => 1,\n\t\t\t\t\t\t'style' => 1,\n\t\t\t\t\t\t'lblLast' => 2,\n\t\t\t\t\t\t'default' => 2,\n\t\t\t\t\t\t'role' => 4,\n\t\t\t\t\t\t'targetAttribute' => 4,\n\t\t\t\t\t\t'novalue' => 2,\n\t\t\t\t\t\t'noLabel' => 2,\n\t\t\t\t\t\t'from' => 2,\n\t\t\t\t\t\t'optype' => 2,\n\t\t\t\t\t\t'language' => 2\n\t\t\t\t\t);\n\t}",
"protected function getLayoutPaths()\n\t{\n\t\t$template = JFactory::getApplication()->getTemplate();\n\n\t\treturn array(\n\t\t\tJPATH_ADMINISTRATOR . '/templates/' . $template . '/html/layouts/plugins/system/stats',\n\t\t\tdirname(__DIR__) . '/layouts',\n\t\t\tJPATH_SITE . '/layouts'\n\t\t);\n\t}",
"public function formatLayoutTemplateFiles()\n\t{\n\t\treturn array($this->getContext()->coreModule->getPath() . \"/layouts/administration.latte\");\n\t}",
"public function formatLayoutTemplateFiles() {\t\t\n\t\t$list = array();\n\t\t$name = $this->getName();\n\t\t$presenter = substr($name, strrpos(':' . $name, ':'));\n\t\t$layout = $this->layout ? $this->layout : 'layout';\n\t\t\n\t\tforeach(array($presenter, \"System:Default\") as $curr) {\n\t\t\tif(($path = Nette\\Utils\\Strings::replace($curr, \"/^([^\\\\:]+)\\\\:(.+)$/\", '/${1}/${2}')) === NULL)\n\t\t\t\tthrow new \\LogicException('Something wrong with presenter name');\n\n\t\t\t$appDir = Nette\\Environment::getVariable('appDir');\n\t\t\t$pathP = substr_replace($path, '/Templates', strrpos($path, '/'), 0);\n\t\t\t$list = array_merge($list, array(\n\t\t\t\t \"$appDir$pathP/@$layout.latte\",\n\t\t\t\t \"$appDir$pathP.@$layout.latte\",\n\t\t\t\t \"$appDir$pathP/@$layout.phtml\",\n\t\t\t\t \"$appDir$pathP.@$layout.phtml\",\n\t\t\t));\n\t\t}\n\t\t\n\t\twhile(($path = substr($path, 0, strrpos($path, '/'))) !== FALSE) {\n\t\t\t$list[] = \"$appDir$path/Templates/@$layout.latte\";\n\t\t\t$list[] = \"$appDir$path/Templates/@$layout.phtml\";\n\t\t}\n\t\t\n\t\treturn $list;\n\t}"
] | [
"0.7449071",
"0.67550874",
"0.6685292",
"0.6513529",
"0.64529663",
"0.63953173",
"0.6302954",
"0.62547415",
"0.61131537",
"0.5996525",
"0.59808594",
"0.5891017",
"0.5860377",
"0.58481336",
"0.5733493",
"0.5725414",
"0.5693248",
"0.56891",
"0.5678778",
"0.56682634",
"0.5658615",
"0.56362104",
"0.5609613",
"0.5589334",
"0.55669624",
"0.5560472",
"0.5540939",
"0.55203515",
"0.54913664",
"0.54762137"
] | 0.81311655 | 0 |
Returns a list of valid web certificates for a flexshare. | function get_web_ssl_certificate_options()
{
clearos_profile(__METHOD__, __LINE__);
$certificate_manager = new Certificate_Manager();
$certs = $certificate_manager->get_list();
return $certs;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function secured()\n {\n return collect($this->files->scandir($this->certificatesPath()))\n ->map(function ($file) {\n return str_replace(['.key', '.csr', '.crt', '.conf'], '', $file);\n })->unique()->values()->all();\n }",
"public function ListCertificates() {\n\t\treturn $this->doQuery(\"passbookCerts\", \"GET\");\n\t}",
"public function checkSSLCerts()\n {\n $info = array(\n 'name' => 'SSL Certificate Info',\n 'state' => 'missing',\n 'success' => self::FAILURE,\n 'more' => 'ssl'\n );\n\n\n if (!function_exists('openssl_get_cert_locations')) {\n return $info;\n }\n\n $stores = openssl_get_cert_locations();\n\n foreach (array('ini_cafile', 'default_cert_file') as $key) {\n if (!empty($stores[$key]) && file_exists($stores[$key])) {\n $info['success'] = self::SUCCESS;\n $info['state'] = $stores[$key];\n return $info;\n }\n }\n\n foreach (array('ini_capath', 'default_cert_dir') as $key) {\n if (!empty($stores[$key]) && is_dir($stores[$key]) && glob($stores[$key] . '/*')) {\n $info['success'] = self::SUCCESS;\n $info['state'] = $stores[$key];\n return $info;\n }\n }\n\n return $info;\n }",
"public function links()\n {\n $certsPath = $this->certificatesPath();\n\n $this->files->ensureDirExists($certsPath, user());\n\n $certs = $this->getCertificates($certsPath);\n\n return $this->getSites($this->sitesPath(), $certs);\n }",
"public function all(): array\n {\n return $this->certs;\n }",
"function get_certificate_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $certificate_manager = new Certificate_Manager();\n $certs = $certificate_manager->get_list();\n\n return $certs;\n }",
"public function getStoreWebsites();",
"public function getCardSecureAssetBundleUrls(): array\n {\n return Plugin::getInstance()->getAssetBundles()->getCardSecureAssetBundleUrls();\n }",
"function parse_certificates($xpath) {\n $nodes = $xpath->query(\"//ds:Signature/ds:KeyInfo/ds:X509Data/ds:X509Certificate/text()\");\n $certs = array();\n foreach ($nodes as $node) {\n $cert = trim($node->wholeText);\n $cert = str_replace(array(\"\\r\", \"\\n\"), \"\", $cert);\n $cert = chunk_split($cert, 64, \"\\n\");\n $cert = \"-----BEGIN CERTIFICATE-----\\n\".$cert.\"-----END CERTIFICATE-----\\n\";\n $certs[] = $cert;\n }\n return $certs;\n }",
"public function getCertificates(): array\n {\n return $this->certificates;\n }",
"protected function _generate_web_flexshares()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (!clearos_library_installed('web_server/Httpd'))\n return;\n\n $httpd = new Httpd();\n\n // Create a unique file identifier\n $backup_key = time();\n\n // Get file listing in Apache vhost dir\n $folder = new Folder(self::WEB_VIRTUAL_HOST_PATH);\n $vhosts = $folder->get_listing();\n $index = 0;\n\n foreach ($vhosts as $vhost) {\n // Flexshares are prefixed with 'flexshare-'. Find these files\n if (preg_match(\"/flex-443.conf|^\" . self::PREFIX . \".*vhost$|^\" . self::PREFIX . \".*conf$/i\", $vhost)) {\n $vhost_file = new File(self::WEB_VIRTUAL_HOST_PATH . \"/\" . $vhost);\n // Backup existing file\n $vhost_file->move_to(self::PATH_TEMP . \"/\" . \"$vhost.$backup_key.bak\");\n } else {\n unset($vhosts[$index]);\n }\n\n $index++;\n }\n\n // Re-order shared to make sure default web site is first virtual host\n //--------------------------------------------------------------------\n\n $raw_shares = $this->_get_shares(self::TYPE_ALL);\n\n $shares = array();\n\n foreach ($raw_shares as $name => $share) {\n if (empty($share['WebDefaultSite']))\n $shares[] = $share;\n else\n array_unshift($shares, $share);\n }\n\n // Grab the list of ports from the PHP Engine app\n //-----------------------------------------------\n\n if (clearos_load_library('php_engines/PHP_Engines')) {\n $php_engine = new \\clearos\\apps\\php_engines\\PHP_Engines();\n $php_engine_ports = $php_engine->get_ports();\n\n // TODO: remove method check in ClearOS 8.0\n if (method_exists($php_engine, 'get_version_codes')) {\n $php_version_codes = $php_engine->get_version_codes();\n } else {\n $php_version_codes['rh-php56-php-fpm'] = 56;\n $php_version_codes['rh-php70-php-fpm'] = 70;\n }\n } else {\n $php_engine_ports = [];\n }\n\n // Recreate all virtual configs\n //-----------------------------\n\n $lans = NULL;\n $newlines = array();\n $flexshare_certs = array();\n $flexshare_php_engines = array();\n $website_certs = array();\n $website_php_engines = array();\n\n foreach ($shares as $share) {\n $name = $share['Name'];\n\n $newlines = array();\n $config_doc_comment = array();\n $config_aliases = array();\n $config_directory = array();\n\n // Bail if not enabled, continue through loop - we're re-creating lines here\n //--------------------------------------------------------------------------\n\n if (! isset($share['ShareEnabled']) || ! $share['ShareEnabled'])\n continue;\n\n if (! isset($share['WebEnabled']) || ! $share['WebEnabled'])\n continue;\n\n if (isset($share['WebCustomConfiguration']) && $share['WebCustomConfiguration'])\n continue;\n\n // Certs\n //------\n\n if (!empty($share['WebSslCertificate'])) {\n if (($share['ShareInternal'] == 1) || ($share['ShareInternal'] == 2))\n $website_certs[$name] = $share['WebSslCertificate'];\n else\n $flexshare_certs[$name] = $share['WebSslCertificate'];\n }\n\n // PHP Engines\n //------------\n\n // Handle upgrade - if WebPhpEngine is not set, but PHP is running, it's using mod_php\n if (!isset($share['WebPhpEngine']) && $share['WebPhp'])\n $share['WebPhpEngine'] = 'httpd';\n\n if (!empty($share['WebPhpEngine'])) {\n if (($share['ShareInternal'] == 1) || ($share['ShareInternal'] == 2))\n $website_php_engines[$name] = $share['WebPhpEngine'];\n else\n $flexshare_php_engines[$name] = $share['WebPhpEngine'];\n }\n\n // Get LAN info, but only if it is necessary (expensive call)\n //-----------------------------------------------------------\n\n if (($share['WebAccess'] == self::ACCESS_LAN) && ($lans === NULL)) {\n $iface_manager = new Iface_Manager();\n $lans = $iface_manager->get_most_trusted_networks();\n }\n\n // Configuration doc comments\n //---------------------------\n\n if ($share['ShareInternal'] == 1)\n $doc_comment = 'Web Site';\n else if ($share['ShareInternal'] == 2)\n $doc_comment = 'Web App';\n else\n $doc_comment = 'File Share';\n\n $config_doc_comment[] = \"\";\n $config_doc_comment[] = \"# -----------------------------------------------#\";\n $config_doc_comment[] = \"# $doc_comment\";\n $config_doc_comment[] = \"# -----------------------------------------------#\";\n $config_doc_comment[] = \"\";\n\n // cgi-bin handling\n //-----------------\n\n if ($share['WebCgi']) {\n // Create cgi-bin directory if it does not exist.\n $cgifolder = new Folder(self::SHARE_PATH . \"/$name/cgi-bin\", TRUE);\n\n if (!$cgifolder->exists())\n $cgifolder->create(self::CONSTANT_WEB_SITE_USERNAME, self::CONSTANT_FILES_USERNAME, \"0777\");\n\n // Build <Directory> block for for cgi-bin\n $config_directory[] = \"<Directory \" . $share['ShareDir'] . \"/cgi-bin>\";\n $config_directory[] = \"\\tOptions +ExecCGI\";\n\n if ($share[\"WebAccess\"] == self::ACCESS_LAN) {\n $config_directory[] = \"\\tRequire local\";\n if (count($lans) > 0) {\n foreach ($lans as $lan)\n $config_directory[] = \"\\tRequire ip \" . $lan;\n }\n } else {\n if (!$share['WebReqAuth'])\n $config_directory[] = \"\\tRequire all granted\";\n }\n\n $config_directory[] = \"</Directory>\\n\";\n }\n\n // Sandbox subdir handling\n //-------------------------\n\n if (isset($share['WebFolderLayout']) && ($share['WebFolderLayout'] == self::FOLDER_LAYOUT_SANDBOX)) {\n $log_folder = new Folder(self::SHARE_PATH . \"/$name/\" . self::SANDBOX_LOG_SUBDIR, TRUE);\n\n if (!$log_folder->exists())\n $log_folder->create(self::CONSTANT_WEB_SITE_USERNAME, $share['ShareGroup'], '0775');\n\n $docroot_folder = new Folder(self::SHARE_PATH . \"/$name/\" . self::SANDBOX_DOCROOT_SUBDIR, TRUE);\n\n if (!$docroot_folder->exists())\n $docroot_folder->create(self::CONSTANT_WEB_SITE_USERNAME, $share['ShareGroup'], '0775');\n\n $errors_folder = new Folder(self::SHARE_PATH . \"/$name/\" . self::SANDBOX_ERRORS_SUBDIR, TRUE);\n\n if (!$errors_folder->exists())\n $errors_folder->create(self::CONSTANT_WEB_SITE_USERNAME, $share['ShareGroup'], '0775');\n }\n\n // Build <Directory> block\n //-------------------------\n\n $config_directory[] = \"<Directory \" . $share['ShareDir'] . \">\";\n $options = '';\n\n if ($share['WebShowIndex'])\n $options .= ' +Indexes';\n else\n $options .= ' -Indexes';\n\n if ($share['WebFollowSymLinks'] || $share['WebReqSsl'])\n $options .= ' +FollowSymLinks';\n else\n $options .= ' -FollowSymLinks';\n\n if ($share['WebAllowSSI'])\n $options .= ' +' . self::DEFAULT_SSI_PARAM;\n else\n $options .= ' -' . self::DEFAULT_SSI_PARAM;\n\n if (strlen($options) > 0)\n $config_directory[] = \"\\tOptions\" . $options;\n\n if ($share['WebHtaccessOverride'])\n $config_directory[] = \"\\tAllowOverride All\";\n\n $phpenv = new File(self::SHARE_PATH . \"/$name/.phpenv\", TRUE);\n\n if ($phpenv->exists())\n $phpenv->delete();\n\n if ($share['WebPhpEngine'] && clearos_load_library('php_engines/PHP_Engines')) {\n $port = $php_engine_ports[$share['WebPhpEngine']];\n\n if (!empty($php_version_codes[$share['WebPhpEngine']])) {\n $phpenv->create('root', 'root', '0644');\n $phpenv->add_lines($php_version_codes[$share['WebPhpEngine']] . \"\\n\");\n }\n\n if ($port) {\n $config_directory[] = \"\\t<FilesMatch \\.php$>\";\n $config_directory[] = \"\\t\\tSetHandler \\\"proxy:fcgi://127.0.0.1:$port\\\"\";\n $config_directory[] = \"\\t</FilesMatch>\";\n }\n }\n\n if ($share['WebReqAuth']) {\n $config_directory[] = \"\\tAuthName \\\"\" . $share['WebRealm'] . \"\\\"\";\n $config_directory[] = \"\\tAuthType Basic\";\n $config_directory[] = \"\\tAuthBasicProvider external\";\n $config_directory[] = \"\\tAuthExternal pwauth\";\n $config_directory[] = \"\\t<RequireAll>\";\n $config_directory[] = \"\\t\\tRequire unix-group \" . $share['ShareGroup'];\n\n if ($share['WebAccess'] == self::ACCESS_LAN) {\n $config_directory[] = \"\\t\\t<RequireAny>\";\n $config_directory[] = \"\\t\\t\\tRequire local\";\n if (count($lans) > 0) {\n foreach ($lans as $lan)\n $config_directory[] = \"\\t\\t\\tRequire ip \" . $lan;\n }\n $config_directory[] = \"\\t\\t</RequireAny>\";\n }\n $config_directory[] = \"\\t</RequireAll>\";\n\n } else {\n if ($share['WebAccess'] == self::ACCESS_LAN) {\n $config_directory[] = \"\\t<RequireAny>\";\n $config_directory[] = \"\\t\\tRequire local\";\n if (count($lans) > 0) {\n foreach ($lans as $lan)\n $config_directory[] = \"\\t\\tRequire ip \" . $lan;\n }\n $config_directory[] = \"\\t</RequireAny>\";\n } else {\n $config_directory[] = \"\\tRequire all granted\";\n }\n }\n\n // PHP support\n //------------\n\n if ($share['WebPhp']) {\n // Anything required?\n } else {\n $config_directory[] = \"\\t<FilesMatch \\.php$>\";\n $config_directory[] = \"\\t\\tSetHandler None\";\n $config_directory[] = \"\\t\\tForceType text/plain\";\n $config_directory[] = \"\\t\\tSetHandler application/x-httpd-php-source\";\n $config_directory[] = \"\\t</FilesMatch>\";\n }\n\n if ($share['WebReqSsl']) {\n $config_directory[] = \"\\tRewriteEngine On\";\n $config_directory[] = \"\\tRewriteCond %{HTTPS} off\";\n $config_directory[] = \"\\tRewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}\";\n }\n\n // DAV (unsupported)\n $davcheck = self::SHARE_PATH . \"/$name/.DAV\";\n $davfile = new File($davcheck);\n if ($davfile->exists())\n $config_directory[] = \"\\tDav on\";\n\n $config_directory[] = \"</Directory>\\n\\n\\n\";\n\n // Ports\n //\n // For standard Flexshares:\n // - SSL or non-SSL can be specified, but not both\n // - End users can override the port number\n //\n // For web sites and web apps\n // - SSL or both SSL + non-SSL can be specified\n // - End usrs cannot override the prot number\n //-------------------------------------------------\n \n if (empty($share['ShareInternal'])) {\n if ($share['WebOverridePort'])\n $ports = array($share['WebPort']);\n else\n $ports = (isset($share['WebReqSsl']) && $share['WebReqSsl']) ? array(443) : array(80);\n } else {\n $ports = (isset($share['WebReqSsl']) && $share['WebReqSsl']) ? array(443) : array(80, 443);\n }\n\n // Create new configuration files in parallel\n //-------------------------------------------\n\n $config_one_time = array();\n\n foreach ($ports as $port) {\n // Need to know which file we'll be writing to.\n // We determine this by port\n // i.e. /etc/httpd/conf.d/flexshare-<port><ssl>.conf\n\n $ssl = (empty($share['ShareInternal']) && $share['WebOverridePort'] && $share['WebReqSsl']) ? '-ssl' : '';\n\n $filename = self::PREFIX . $port . $ssl . '.conf';\n $file = new File(self::WEB_VIRTUAL_HOST_PATH . '/' . $filename);\n\n // Create the configuration file\n // Write out a common header\n //-------------------------------\n\n if (! $file->exists()) {\n $vhosts[] = $filename;\n\n $header_lines = array();\n $header_lines[] = self::WRITE_WARNING;\n\n // Only specify Listen directive for custom ports\n if (($port != 80) && ($port != 443))\n $header_lines[] = \"Listen *:$port\";\n\n $header_lines[] = \"\";\n $header_lines[] = \"# Authentication mechanism\";\n $header_lines[] = \"DefineExternalAuth pwauth pipe /usr/bin/pwauth\";\n $header_lines[] = \"DefineExternalGroup pwauth pipe /usr/bin/unixgroup\";\n $header_lines[] = \"\";\n\n $file->create('root', 'root', '0644');\n $file->add_lines(implode(\"\\n\", $header_lines));\n }\n\n // Write out Aliases and Directory definitions. This is only\n // required once per FlexShare, whereas VirtualHost blocks\n // can appear multiple times.\n\n $check_name = $share['Name'];\n\n if (in_array($check_name, $config_one_time)) {\n $config_aliases = array();\n $config_directory = array();\n } else {\n $config_aliases = $this->_generate_web_aliases($share, $port);\n\n $config_one_time[] = $check_name;\n }\n\n // Create new configuration files in parallel\n $config_virtual_host = $this->_generate_web_virtual_hosts($share, $port);\n\n $config_lines = array_merge(\n $config_doc_comment,\n $config_aliases,\n $config_virtual_host,\n $config_directory\n );\n\n $file->add_lines(implode(\"\\n\", $config_lines));\n }\n }\n\n // Validate httpd configuration before restarting server\n //------------------------------------------------------\n\n $config_ok = TRUE;\n\n try {\n $shell = new Shell();\n $shell_options['validate_exit_code'] = FALSE;\n $exitcode = $shell->execute(self::CMD_VALIDATE_HTTPD, '-t', TRUE, $shell_options);\n } catch (Exception $e) {\n // Backup out of commits\n $config_ok = FALSE;\n }\n\n if (($config_ok === FALSE) || ($exitcode != 0)) {\n $config_ok = FALSE;\n $output = $shell->get_output();\n clearos_log(self::LOG_TAG, \"Invalid httpd configuration!\");\n // Oops...we generated an invalid conf file\n foreach ($output as $line)\n clearos_log(self::LOG_TAG, $line);\n }\n\n foreach ($vhosts as $vhost) {\n // Not a flexshare vhost file\n if (!isset($vhost))\n continue;\n\n $file = new File(self::PATH_TEMP . \"/$vhost.$backup_key.bak\");\n\n if (! $file->exists()) {\n // Conf was newly created\n $file = new File(self::WEB_VIRTUAL_HOST_PATH . \"/$vhost\");\n if (! $config_ok)\n $file->delete();\n\n continue;\n }\n\n if ($config_ok) {\n // Delete backups\n $file->delete();\n } else {\n // Recover backups\n $file->move_to(self::WEB_VIRTUAL_HOST_PATH . \"/$vhost\");\n }\n }\n\n if ($config_ok) {\n try {\n $httpd = new Httpd();\n $httpd->reset(TRUE);\n } catch (Exception $e) {\n // Keep going\n }\n } else {\n throw new Engine_Exception(lang('flexshare_config_validation_failed'), CLEAROS_ERROR);\n }\n\n // Report state of certs to Certificate Manager\n //---------------------------------------------\n\n $certificate_manager = new Certificate_Manager();\n $certificate_manager->register($flexshare_certs, 'flexshare', lang('flexshare_app_name'));\n $certificate_manager->register($website_certs, 'web_server', lang('web_server_app_name'));\n\n if (clearos_load_library('php_engines/PHP_Engines')) {\n $php = new \\clearos\\apps\\php_engines\\PHP_Engines();\n $php->register($website_php_engines, 'web_server', lang('web_server_app_name'));\n $php->register($flexshare_php_engines, 'flexshare', lang('flexshare_app_name'));\n }\n }",
"function GetSSL($user = '')\n {\n $dirname = $user === '' ? $this->_ssl_dir : $this->_ssl_dir . $user;\n $files = array();\n if ($handle = opendir($dirname)) {\n while (false !== ($file = readdir($handle))) {\n if ($file != \".\" && $file != \"..\") {\n $path_parts = pathinfo($file);\n if (isset($path_parts['extension']) && $path_parts['extension'] === 'crt') {\n $files[] = str_replace('.crt', '', $file);\n }\n }\n }\n closedir($handle);\n }\n return $files;\n }",
"function streamCert() \n\t\t{\n\t\t\t$SSLclient = NULL;\n\t\t\t$SSLclient = array();\n\t\t\t\n\t\t\twhile (list($key,$value) = each($_SERVER)) {\n\t\t\t\tif (strpos($key, 'SSL_CLIENT') !== false) {\n\t\t\t\t\t$SSLclient[$key]= $value;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn $SSLclient;\n\t\t}",
"public function checkSSL()\n {\n $ok = in_array('ssl', stream_get_transports());\n return array(\n 'name' => 'SSL Support',\n 'state' => $ok ? 'available' : 'missing',\n 'success' => $ok ? self::SUCCESS : self::FAILURE,\n 'more' => 'ssl'\n );\n }",
"function getDomainsWPEHosted($wpeClientUrlListUrl) {\n $domains = array(\"techcrunch.com\",\"news.cnet.com\");\n \n return $domains;\n}",
"public function listCertification()\n {\n $certificacion = Certificaciones::orderBy('nombre', 'asc')\n ->get();\n return response()->json($certificacion, 200);\n }",
"public function getCertificates($path = null)\n {\n $path = $path ?: $this->certificatesPath();\n\n $this->files->ensureDirExists($path, user());\n\n $config = $this->config->read();\n\n return collect($this->files->scandir($path))->filter(function ($value, $key) {\n return ends_with($value, '.crt');\n })->map(function ($cert) use ($config) {\n $certWithoutSuffix = substr($cert, 0, -4);\n $trimToString = '.';\n\n // If we have the cert ending in our tld strip that tld specifically\n // if not then just strip the last segment for backwards compatibility.\n if (ends_with($certWithoutSuffix, $config['tld'])) {\n $trimToString .= $config['tld'];\n }\n\n return substr($certWithoutSuffix, 0, strrpos($certWithoutSuffix, $trimToString));\n })->flip();\n }",
"public function get_certificates() {\n\t\treturn $this->client->GetCertificates();\n\t}",
"public function has_ssl() {\n $domain = 'https://'.$_SERVER['HTTP_HOST'];\n $stream = stream_context_create (array(\"ssl\" => array(\"capture_peer_cert\" => true)));\n if( $read = @fopen($domain, \"rb\", false, $stream)){\n $cont = stream_context_get_params($read);\n if(isset($cont[\"options\"][\"ssl\"][\"peer_certificate\"])){\n $var = ($cont[\"options\"][\"ssl\"][\"peer_certificate\"]);\n $result = (!is_null($var)) ? true : false;\n }else {\n $result = false;\n } \n } else {\n $result = false;\n }\n \n return array(\n 'status' => $result,\n );\n }",
"private function getFederatedSignOnCerts() {\n // This relies on makeRequest caching certificate responses.\n $request = Google_Client::$io->makeRequest(new Google_HttpRequest(\n self::OAUTH2_FEDERATED_SIGNON_CERTS_URL));\n if ($request->getResponseHttpCode() == 200) {\n $certs = json_decode($request->getResponseBody(), true);\n if ($certs) {\n return $certs;\n }\n }\n throw new Google_AuthException(\n \"Failed to retrieve verification certificates: '\" .\n $request->getResponseBody() . \"'.\",\n $request->getResponseHttpCode());\n }",
"public function getCertificates() {\n $sql = \"SELECT email, certificate\n FROM tbl_certificates\";\n $stmt = $this->db->query($sql);\n $results = [];\n while($row = $stmt->fetch()) {\n $results[] = new CertificateEntity($row);\n }\n return $results;\n }",
"function list_of_urls_with_and_without_https() {\n return array(\n array( 'http://omg', 'http://omg', 'https://omg' ),\n array( 'https://omg', 'https://omg', 'https://omg' ),\n array( 'http://omg?http', 'http://omg?http', 'https://omg?http' ),\n array( 'https://omg?http', 'https://omg?http', 'https://omg?http' ),\n array( 'omg?http://bleh', 'omg?http://bleh', 'omg?http://bleh' ),\n array( 'omg?https://bleh', 'omg?https://bleh', 'omg?https://bleh' ),\n array( 'http', 'http', 'http' ),\n array( 'https', 'https', 'https' ),\n array( 'http://https', 'http://https', 'https://https' ),\n array( 'https://https', 'https://https', 'https://https' ),\n );\n }",
"public function getAvailableUrls() {\n $sql = \"\n SELECT short_url, long_url, expiration\n FROM links\n WHERE NOW() <= expiration;\n \";\n\n $query = $this->db->prepare($sql);\n $query->execute();\n\n $links = $query->fetchAll();\n\n return [\n 'success' => true,\n 'info' => 'URLs successfully retrieved.',\n 'data' => $links ? $links : null\n ];\n }",
"public function describeDcdnCertificateList($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->describeDcdnCertificateListWithOptions($request, $runtime);\n }",
"public function index()\n {\n $certs = Certification::all();\n\n return view('certifications.index')->with([\n 'certs' => $certs\n ]);\n }",
"private function getRevokeList(){\n\t\t\t$strRevokeList = false;\n\t\t\tif (is_file($this->pfh->FilePath('crl.txt', 'eqdkp/certs', false))){\n\t\t\t\t$strRevokeList = file_get_contents($this->pfh->FilePath('crl.txt', 'eqdkp/certs'));\n\t\t\t} else {\n\t\t\t\t$blnResult = $this->loadRevokeList();\n\t\t\t\tif ($blnResult){\n\t\t\t\t\t$strRevokeList = file_get_contents($this->pfh->FilePath('crl.txt', 'eqdkp/certs'));\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif ($strRevokeList && strlen($strRevokeList)){\n\t\t\t\t$arrRevokeList = array();\n\t\t\t\t$convert = explode(\"\\n\", $strRevokeList);\n\t\t\t\tfor ($i=0;$i<count($convert);$i++) {\t\n\t\t\t\t\t$arrRevokeList[] = strtolower(str_replace(':', '', $convert[$i]));\n\t\t\t\t}\n\t\t\t\treturn $arrRevokeList;\n\t\t\t}\n\t\t\t\n\t\t\treturn false;\n\t\t}",
"public function getAvailableWebsites()\n {\n /** @var StoreUrlGroupDataInterface[] $urlGroup */\n $urlGroups = $this->storeUrlGroup->getGroups();\n\n $availableWebsites = [];\n\n /** @var StoreUrlGroupDataInterface $group */\n foreach ($urlGroups as $group) {\n $availableWebsites[] = $group->getUrl();\n }\n\n return $availableWebsites;\n }",
"public function ssls()\n {\n return (new SslClient($this->httpClient))->auth($this->token);\n }",
"public function ssls()\n {\n return (new SslClient($this->httpClient))->auth($this->token);\n }",
"public function describeDcdnSMCertificateList($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->describeDcdnSMCertificateListWithOptions($request, $runtime);\n }"
] | [
"0.6166135",
"0.6114516",
"0.5795448",
"0.5665231",
"0.5653761",
"0.5605805",
"0.5439549",
"0.54147923",
"0.5366197",
"0.5361321",
"0.5302163",
"0.52947766",
"0.52860683",
"0.52360237",
"0.5213825",
"0.51968855",
"0.5139755",
"0.5139231",
"0.5102055",
"0.5070948",
"0.5004756",
"0.49873424",
"0.4983914",
"0.49454376",
"0.4913119",
"0.49102885",
"0.49021307",
"0.48785716",
"0.48785716",
"0.48721755"
] | 0.63718057 | 0 |
Returns a list of valid FTP permission options for a flexshare. | function get_ftp_permission_options()
{
clearos_profile(__METHOD__, __LINE__);
$options = array(
self::PERMISSION_READ => lang('flexshare_read_only'),
self::PERMISSION_READ_WRITE_PLUS => lang('flexshare_read_write')
);
return $options;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function get_file_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"function get_web_access_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::ACCESS_LAN => lang('flexshare_access_lan'),\n self::ACCESS_ALL => lang('base_all')\n );\n\n return $options;\n }",
"public function getPermissionOptions()\n {\n return [\n 'read' => 'View listing and edit views',\n 'create' => 'Create new items',\n 'update' => 'Update existing items',\n 'grant' => 'Change role and permissions',\n 'destroy' => ['Delete', 'Delete items permanently'],\n ];\n }",
"function get_ftp_umask_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n // Umask is inverted.\n $options = array(\n 7 => \"---\",\n 6 => \"--x\",\n 5 => \"-w-\",\n 4 => \"-wx\",\n 3 => \"r--\",\n 2 => \"r-x\",\n 1 => \"rw-\",\n 0 => \"rwx\"\n );\n\n return $options;\n }",
"public function permissionList(): array {\n return $this->info()['Permission'];\n }",
"public function list_permissions(){\n $auth = Yii::$app->authManager;\n\n return ['list' => $auth->getPermissions()];\n }",
"function get_enforce_group_permissions()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n try {\n $option = $this->_get_global_parameter('FlexshareSecurityPermissions');\n } catch (Flexshare_Parameter_Not_Found_Exception $e) {\n // Ignore\n } catch (Engine_Exception $e) {\n // Ignore\n }\n\n if (empty($option))\n $option = 'on';\n\n return $option;\n }",
"public static function getPermissionsFiles() {\n\t\t$writableFilesAndFolders = self::$writableFilesAndFolders;\n\t\t$permissions = array();\n\t\trequire_once ('include/utils/VtlibUtils.php');\n\t\tforeach ($writableFilesAndFolders as $index => $value) {\n\t\t\t$permissions[$index]['permission'] = 'TruePermission';\n\t\t\t$permissions[$index]['path'] = $value;\n\t\t\tif (!vtlib_isWriteable($value)) {\n\t\t\t\t$permissions[$index]['permission'] = 'FailedPermission';\n\t\t\t}\n\t\t}\n\t\treturn $permissions;\n\t}",
"function get_system_permissions()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $permissions = array(\n self::PERMISSIONS_SECURE => lang('base_disabled'),\n self::PERMISSIONS_READ_ONLY => lang('flexshare_read_only')\n );\n\n return $permissions;\n }",
"public function getFTPOptions()\n\t{\n\t\t$config = JFactory::getConfig();\n\t\treturn array(\n\t\t\t'host' => $config->get('ftp_host'),\n\t\t\t'port' => $config->get('ftp_port'),\n\t\t\t'username' => $config->get('ftp_user'),\n\t\t\t'password' => $config->get('ftp_pass'),\n\t\t\t'directory' => $config->get('ftp_root'),\n\t\t\t'enabled' => $config->get('ftp_enable'),\n\t\t);\n\t}",
"public function list_ldap_access_options() {\n\t\tif(is_null($this->id)) throw new BadMethodCallException('Server must be in directory before LDAP access options can be listed');\n\t\t$stmt = $this->database->prepare(\"\n\t\t\tSELECT *\n\t\t\tFROM server_ldap_access_option\n\t\t\tWHERE server_id = ?\n\t\t\tORDER BY `option`\n\t\t\");\n\t\t$stmt->bind_param('d', $this->id);\n\t\t$stmt->execute();\n\t\t$result = $stmt->get_result();\n\t\t$options = array();\n\t\twhile($row = $result->fetch_assoc()) {\n\t\t\t$options[$row['option']] = new ServerLDAPAccessOption($row['option'], $row);\n\t\t}\n\t\t$stmt->close();\n\t\treturn $options;\n\t}",
"public static function getOptions() {\n global $sitemap_activated;\n if(!$sitemap_activated)\n return array();\n\n $robot = new File('..', 'robots.txt');\n $sitemap = new File('..', 'sitemap.xml');\n $rights = array(\n '../robots.txt' => $robot->isWritable(true),\n '../sitemap.xml' => $sitemap->isWritable(true),\n );\n $failure = false;\n foreach($rights as $file=>$r) {\n if(!$r) {\n $failure = true;\n break;\n }\n }\n if($failure)\n Controller::notifyUser('error', 'permission', $rights);\n\n return array();\n }",
"public function getDirectPermissions(): Collection;",
"public function allPermissions()\n {\n return [];\n }",
"public function defaultPermissionList(): array {\n return $this->info()['defaultPermission'] ?? [];\n }",
"function access_scheme_list_field_settings($scheme, $has_data) {\n // Find all available fields of the given type.\n $fields = field_read_fields(array('type' => $scheme->type));\n // Exclude other realm fields from the list.\n foreach ($fields as $field_name => $field) {\n if (!empty($field['settings']['allowed_values_function']) && $field['settings']['allowed_values_function'] == '_access_field_allowed_values') {\n unset($fields[$field_name]);\n }\n }\n\n // Build the form.\n $form = array();\n if (!empty($fields)) {\n $options = drupal_map_assoc(array_keys($fields));\n $form['field_name'] = array(\n '#type' => 'select',\n '#title' => t('List field'),\n '#description' => t('The allowed values list from this field will become the access realms for the scheme.'),\n '#default_value' => isset($scheme->settings['field_name']) ? $scheme->settings['field_name'] : NULL,\n '#options' => $options,\n '#required' => TRUE,\n '#disabled' => $has_data,\n );\n }\n return $form;\n}",
"public function getTypeAllowableValues()\n {\n return [\n self::TYPE_FILE,\nself::TYPE_FOLDER,\nself::TYPE_SHARED_FOLDER,\nself::TYPE_SEND_RECEIPT,\nself::TYPE_SHARE_RECEIPT,\nself::TYPE_FILE_DROP, ];\n }",
"function _horde_listUserPermissions($shareRoot, $shareName, $userName)\n{\n if (!Auth::isAdmin()) {\n return PEAR::raiseError(_(\"You are not allowed to list share permissions.\"));\n }\n\n $perm_map = array(PERMS_SHOW => 'show',\n PERMS_READ => 'read',\n PERMS_EDIT => 'edit',\n PERMS_DELETE => 'delete');\n\n require_once 'Horde/Share.php';\n $shares = &Horde_Share::singleton($shareRoot);\n\n if (is_a($share = &$shares->getShare($shareName), 'PEAR_Error')) {\n return $share;\n }\n\n $perm = &$share->getPermission();\n $permissions = $perm->getUserPermissions();\n if (empty($permissions[$userName])) {\n return array();\n }\n\n $user_permissions = array();\n foreach (array_keys(Perms::integerToArray($permissions[$userName])) as $permission) {\n $user_permissions[] = $perm_map[$permission];\n }\n\n return $user_permissions;\n}",
"public function getListaPermissoes()\r\n\t{\r\n\t\treturn $this->listaPermissoes;\r\n\t}",
"function get_dir_options($name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array();\n\n // Custom\n try {\n $custom_data = $this->_get_global_parameter('FlexshareDirCustom');\n if (! empty($custom_data)) {\n $list = preg_split(\"/\\\\|/\", $this->_get_global_parameter('FlexshareDirCustom'));\n foreach ($list as $custom) {\n list ($desc, $path) = preg_split(\"/:/\", $custom);\n $options[$path] = $desc . ' (' . $path . \")\\n\";\n }\n }\n } catch (Flexshare_Parameter_Not_Found_Exception $e) {\n // Ignore\n } catch (Engine_Exception $e) {\n // Ignore\n }\n\n // If $name is NULL, fancy up the path displayed\n if ($name == NULL)\n $display_name = preg_replace('/ /', '_', strtoupper(lang('flexshare_share_name'))); \n else\n $display_name = $name;\n\n // Default\n $options[self::SHARE_PATH . '/' . $name] = lang('base_default') . ' (' . self::SHARE_PATH . '/' . $display_name . \")\";\n\n return $options;\n }",
"public function accessControls()\n {\n return [\n [\n 'allow' => true,\n 'roles' => ['?'],\n ],\n\n [\n 'allow' => true,\n 'actions' => ['options'],\n 'roles' => ['?'],\n ],\n ];\n }",
"public function getPermissions() {\r\n\t\treturn array();\r\n\t}",
"public function getAllPermissions(){\n\t\treturn [$this->getReadPermissionName(),\n\t\t\t\t$this->getEditPermissionName()];\n\t}",
"public function allPermissions();",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'size' => 1\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"public static function getPermissions() {\n\t\t$permissions = array(\n\t\t\t'users' => array(\n\t\t\t\t'admin.users.index' => trans('permissions/general.users_list'),\n\t\t\t\t'admin.users.edit' => trans('permissions/general.users_edit'),\n\t\t\t\t'admin.users.create' => trans('permissions/general.users_create'),\n\t\t\t\t'delete.user' => trans('permissions/general.users_delate'),\n\t\t\t),\n\t\t\t'groups' => array(\n\t\t\t\t'groups' => trans('permissions/general.group_list'),\n\t\t\t\t'edit.group' => trans('permissions/general.group_edit'),\n\t\t\t\t'create.group' => trans('permissions/general.group_create'),\n\t\t\t\t'delete.group' => trans('permissions/general.group_delate'),\n\t\t\t),\n\t\t\t'blocks' => array(\n\t\t\t\t'blocks' => trans('permissions/general.blocks_list'),\n\t\t\t\t'edit.block' => trans('permissions/general.block_edit'),\n\t\t\t\t'create.block' => trans('permissions/general.block_create'),\n\t\t\t\t'delete.block' => trans('permissions/general.block_delate'),\n\t\t\t),\n\t\t\t'pages' => array(\n\t\t\t\t'pages' => trans('permissions/general.pages_list'),\n\t\t\t\t'edit.page' => trans('permissions/general.page_edit'),\n\t\t\t\t'create.page' => trans('permissions/general.page_create'),\n\t\t\t\t'delete.page' => trans('permissions/general.page_delate'),\n\t\t\t),\n 'menu' => array(\n\t\t\t\t'menu' => trans('permissions/general.menu_list'),\n\t\t\t\t'menu.data.quickrename' => trans('permissions/general.menu_edit'),\n\t\t\t\t'menu.data.quickcreate' => trans('permissions/general.menu_create'),\n\t\t\t\t'menu.data.quickremove' => trans('permissions/general.menu_delate'),\n\t\t\t\t'menu.data.move' => trans('permissions/general.menu_move'),\n\t\t\t),\n\t\t\t'classifiedschema' => array(\n\t\t\t\t'classifiedschema' => trans('permissions/general.classifiedschema_list'),\n\t\t\t\t'classifiedschema.data.quickrename' => trans('permissions/general.classifiedschema_edit'),\n\t\t\t\t'classifiedschema.data.quickcreate' => trans('permissions/general.classifiedschema_create'),\n\t\t\t\t'classifiedschema.data.quickremove' => trans('permissions/general.classifiedschema_delate'),\n\t\t\t\t'classifiedschema.data.move' => trans('permissions/general.classifiedschema_move'),\n\t\t\t),\n\t\t\t'classifiedcategories' => array(\n\t\t\t\t'classifiedcategories' => trans('permissions/general.classifiedcategories_list'),\n\t\t\t\t'update.classifiedcategories' => trans('permissions/general.classifiedcategories_edit'),\n\t\t\t\t'create.classifiedcategories' => trans('permissions/general.classifiedcategories_create'),\n\t\t\t\t'delete.classifiedcategories' => trans('permissions/general.classifiedcategories_delate'),\n\t\t\t\t'classifiedcategories.data.move' => trans('permissions/general.classifiedcategories_move'),\n 'classifiedcategories.recreate' => trans('permissions/general.recreateclassifiedcategories'),\n\t\t\t),\n\t\t\t'classifieds' => array(\n\t\t\t\t'classifieds' => trans('permissions/general.classifieds_list'),\n\t\t\t\t'update.classified' => trans('permissions/general.classifieds_edit'),\n\t\t\t\t'create.classified' => trans('permissions/general.classifieds_create'),\n\t\t\t\t'delete.classified' => trans('permissions/general.classifieds_delate'),\n\t\t\t),\n\t\t\t'nearmecategory' => array(\n\t\t\t\t'nearmecategories' => trans('permissions/general.nearmecategory_list'),\n\t\t\t\t'update.nearmecategory' => trans('permissions/general.nearmecategory_edit'),\n\t\t\t\t'create.nearmecategory' => trans('permissions/general.nearmecategory_create'),\n\t\t\t\t'delete.nearmecategory' => trans('permissions/general.nearmecategory_delate'),\n\t\t\t),\n\t\t\t'nearmeitemscategory' => array(\n\t\t\t\t'nearmeitemscategory' => trans('permissions/general.nearmeitemscategory_list'),\n\t\t\t\t'update.nearmeitemscategory' => trans('permissions/general.nearmeitemscategory_edit'),\n\t\t\t\t'create.nearmeitemscategory' => trans('permissions/general.nearmeitemscategory_create'),\n\t\t\t\t'delete.nearmeitemscategory' => trans('permissions/general.nearmeitemscategory_delate'),\n\t\t\t),\n 'nearme' => array(\n\t\t\t\t'nearmes' => trans('permissions/general.nearme_list'),\n\t\t\t\t'update.nearme' => trans('permissions/general.nearme_edit'),\n\t\t\t\t'create.nearme' => trans('permissions/general.nearme_create'),\n\t\t\t\t'delete.nearme' => trans('permissions/general.nearme_delate'),\n\t\t\t),\n\t\t\t'ads' => array(\n\t\t\t\t'ads' => trans('permissions/general.ads_list'),\n\t\t\t\t'update.ads' => trans('permissions/general.ads_edit'),\n\t\t\t\t'create.ads' => trans('permissions/general.ads_create'),\n\t\t\t\t'delete.ads' => trans('permissions/general.ads_delate'),\n\t\t\t),\n\t\t\t'adscompanies' => array(\n\t\t\t\t'adscompanies' => trans('permissions/general.adscompanies_list'),\n\t\t\t\t'update.adscompanies' => trans('permissions/general.adscompanies_edit'),\n\t\t\t\t'create.adscompanies' => trans('permissions/general.adscompanies_create'),\n\t\t\t\t'delete.adscompanies' => trans('permissions/general.adscompanies_delate'),\n\t\t\t),\n\t\t\t'adspositions' => array(\n\t\t\t\t'adspositions' => trans('permissions/general.adspositions_list'),\n\t\t\t\t'update.adspositions' => trans('permissions/general.adspositions_edit'),\n\t\t\t\t'create.adspositions' => trans('permissions/general.adspositions_create'),\n\t\t\t\t'delete.adspositions' => trans('permissions/general.adspositions_delate'),\n\t\t\t),\n\t\t\t'blogcategory' => array(\n\t\t\t\t'blogcategories' => trans('permissions/general.blogcategories_list'),\n\t\t\t\t'update.blogcategory' => trans('permissions/general.blogcategory_edit'),\n\t\t\t\t'create.blogcategory' => trans('permissions/general.blogcategory_create'),\n\t\t\t\t'delete.blogcategory' => trans('permissions/general.blogcategory_delate'),\n\t\t\t),\n\t\t\t'blog' => array(\n\t\t\t\t'blogs' => trans('permissions/general.blogs_list'),\n\t\t\t\t'update.blog' => trans('permissions/general.blog_edit'),\n\t\t\t\t'create.blog' => trans('permissions/general.blog_create'),\n\t\t\t\t'delete.blog' => trans('permissions/general.blog_delate'),\n\t\t\t),\n 'reporteditems' => array(\n\t\t\t\t'reporteditems' => trans('permissions/general.reporteditems_list'),\n\t\t\t\t'update.reporteditems' => trans('permissions/general.reporteditems_edit'),\n\t\t\t),\n 'issues' => array(\n\t\t\t\t'issues' => trans('permissions/general.issues_list'),\n\t\t\t\t'update.issues' => trans('permissions/general.issues_edit'),\n\t\t\t),\n 'plans' => array(\n\t\t\t\t'plans' => trans('permissions/general.plans_list'),\n\t\t\t\t'update.plan' => trans('permissions/general.plan_edit'),\n\t\t\t\t'create.plan' => trans('permissions/general.plan_create'),\n\t\t\t\t'delete.plan' => trans('permissions/general.plan_delate'),\n\t\t\t),\n 'payments' => array(\n\t\t\t\t'payments' => trans('permissions/general.payments_list'),\n\t\t\t),\n 'settings' => array(\n\t\t\t\t'settings' => trans('permissions/general.settings_list'),\n 'update.settings' => trans('permissions/general.settings_edit'),\n\t\t\t),\n 'coupons' => array(\n 'coupons' => trans('permissions/general.coupons_list'),\n\t\t\t\t'update.coupons' => trans('permissions/general.coupons_edit'),\n\t\t\t\t'create.coupons' => trans('permissions/general.coupons_create'),\n\t\t\t\t'delete.coupons' => trans('permissions/general.coupons_delate'),\n ),\n 'claim' => array(\n 'claim' => trans('permissions/general.claim_claim'),\n 'unclaim' => trans('permissions/general.claim_unclaim'),\n 'claim.sales' => trans('permissions/general.claim_sales'),\n 'claim.approve' => trans('permissions/general.claim_approve'),\n 'claim.unapprove' => trans('permissions/general.claim_unapprove'),\n ),\n 'sales' => array(\n 'sales.sales' => trans('permissions/general.sales'),\n 'sales.approve' => trans('permissions/general.sales_approve'),\n ),\n\t\t);\n\t\t\n\t\treturn $permissions;\n }",
"private function list_rights($attrib=array())\n {\n // Get ACL for the folder\n $acl = $this->rc->storage->get_acl($this->mbox);\n\n if (!is_array($acl)) {\n $acl = array();\n }\n\n // Keep special entries (anyone/anonymous) on top of the list\n if (!empty($this->specials) && !empty($acl)) {\n foreach ($this->specials as $key) {\n if (isset($acl[$key])) {\n $acl_special[$key] = $acl[$key];\n unset($acl[$key]);\n }\n }\n }\n\n // Sort the list by username\n uksort($acl, 'strnatcasecmp');\n\n if (!empty($acl_special)) {\n $acl = array_merge($acl_special, $acl);\n }\n\n // Get supported rights and build column names\n $supported = $this->rights_supported();\n\n // give plugins the opportunity to adjust this list\n $data = $this->rc->plugins->exec_hook('acl_rights_supported',\n array('rights' => $supported, 'folder' => $this->mbox, 'labels' => array()));\n $supported = $data['rights'];\n\n // depending on server capability either use 'te' or 'd' for deleting msgs\n $deleteright = implode(array_intersect(str_split('ted'), $supported));\n\n // Use advanced or simple (grouped) rights\n $advanced = $this->rc->config->get('acl_advanced_mode');\n\n if ($advanced) {\n $items = array();\n foreach ($supported as $sup) {\n $items[$sup] = $sup;\n }\n }\n else {\n $items = array(\n 'read' => 'lrs',\n 'write' => 'wi',\n 'delete' => $deleteright,\n 'other' => preg_replace('/[lrswi'.$deleteright.']/', '', implode($supported)),\n );\n\n // give plugins the opportunity to adjust this list\n $data = $this->rc->plugins->exec_hook('acl_rights_simple',\n array('rights' => $items, 'folder' => $this->mbox, 'labels' => array()));\n $items = $data['rights'];\n }\n\n // Create the table\n $attrib['noheader'] = true;\n $table = new html_table($attrib);\n\n // Create table header\n $table->add_header('user', $this->gettext('identifier'));\n foreach (array_keys($items) as $key) {\n $label = $data['labels'][$key] ?: $this->gettext('shortacl'.$key);\n $table->add_header(array('class' => 'acl'.$key, 'title' => $label), $label);\n }\n\n $js_table = array();\n foreach ($acl as $user => $rights) {\n if ($this->rc->storage->conn->user == $user) {\n continue;\n }\n\n // filter out virtual rights (c or d) the server may return\n $userrights = array_intersect($rights, $supported);\n $userid = rcube_utils::html_identifier($user);\n\n if (!empty($this->specials) && in_array($user, $this->specials)) {\n $user = $this->gettext($user);\n }\n\n $table->add_row(array('id' => 'rcmrow'.$userid));\n $table->add('user', html::a(array('id' => 'rcmlinkrow'.$userid), rcube::Q($user)));\n\n foreach ($items as $key => $right) {\n $in = $this->acl_compare($userrights, $right);\n switch ($in) {\n case 2: $class = 'enabled'; break;\n case 1: $class = 'partial'; break;\n default: $class = 'disabled'; break;\n }\n $table->add('acl' . $key . ' ' . $class, '');\n }\n\n $js_table[$userid] = implode($userrights);\n }\n\n $this->rc->output->set_env('acl', $js_table);\n $this->rc->output->set_env('acl_advanced', $advanced);\n\n $out = $table->show();\n\n return $out;\n }",
"public function getDirectPermissions(): Collection\n {\n return $this->permissions;\n }",
"public function spacePermissions();",
"public function list_ftp($include_acct_types, $skip_acct_types){\n $input=array(\n 'module' => 'Ftp',\n 'function' => 'listftp',\n 'include_acct_types' => $include_acct_types,\n 'skip_acct_types' => $skip_acct_types\n );\n $query=$this->build_query($input);\n $raw=$this->query($query);\n $ob=json_decode($raw, false);\n return $status=$ob->cpanelresult->data;\n }"
] | [
"0.7140791",
"0.6174813",
"0.60892564",
"0.59880906",
"0.5939845",
"0.5713667",
"0.5676744",
"0.5654741",
"0.5642633",
"0.5626044",
"0.5608369",
"0.547023",
"0.5419028",
"0.5391877",
"0.53684837",
"0.5330033",
"0.5329376",
"0.5320898",
"0.5305571",
"0.5289093",
"0.527181",
"0.5268938",
"0.52686054",
"0.52679545",
"0.52619743",
"0.5238846",
"0.52335864",
"0.52296335",
"0.51849765",
"0.5184879"
] | 0.7862596 | 0 |
Returns a list of valid FTP umask options for a flexshare. | function get_ftp_umask_options()
{
clearos_profile(__METHOD__, __LINE__);
// Umask is inverted.
$options = array(
7 => "---",
6 => "--x",
5 => "-w-",
4 => "-wx",
3 => "r--",
2 => "r-x",
1 => "rw-",
0 => "rwx"
);
return $options;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function get_ftp_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE_PLUS => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"function get_file_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"function get_dir_options($name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array();\n\n // Custom\n try {\n $custom_data = $this->_get_global_parameter('FlexshareDirCustom');\n if (! empty($custom_data)) {\n $list = preg_split(\"/\\\\|/\", $this->_get_global_parameter('FlexshareDirCustom'));\n foreach ($list as $custom) {\n list ($desc, $path) = preg_split(\"/:/\", $custom);\n $options[$path] = $desc . ' (' . $path . \")\\n\";\n }\n }\n } catch (Flexshare_Parameter_Not_Found_Exception $e) {\n // Ignore\n } catch (Engine_Exception $e) {\n // Ignore\n }\n\n // If $name is NULL, fancy up the path displayed\n if ($name == NULL)\n $display_name = preg_replace('/ /', '_', strtoupper(lang('flexshare_share_name'))); \n else\n $display_name = $name;\n\n // Default\n $options[self::SHARE_PATH . '/' . $name] = lang('base_default') . ' (' . self::SHARE_PATH . '/' . $display_name . \")\";\n\n return $options;\n }",
"function get_web_access_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::ACCESS_LAN => lang('flexshare_access_lan'),\n self::ACCESS_ALL => lang('base_all')\n );\n\n return $options;\n }",
"public function getFTPOptions()\n\t{\n\t\t$config = JFactory::getConfig();\n\t\treturn array(\n\t\t\t'host' => $config->get('ftp_host'),\n\t\t\t'port' => $config->get('ftp_port'),\n\t\t\t'username' => $config->get('ftp_user'),\n\t\t\t'password' => $config->get('ftp_pass'),\n\t\t\t'directory' => $config->get('ftp_root'),\n\t\t\t'enabled' => $config->get('ftp_enable'),\n\t\t);\n\t}",
"function ftpspider_options() {\n\t\n\t$params = getopt(\"\", array(\"host:\", \"username:\", \"password:\", \"help\", \"debug\", \"outputlinks\"));\n\t\n\t// Required\n\t$Options['host'] = (isset($params['host'])) ? $params['host'] : false;\n\t\n\t// Optional\n\t$Options['username'] = (isset($params['username'])) ? $params['username'] : false;\n\t$Options['password'] = (isset($params['password'])) ? $params['password'] : false;\n\t$Options['debug'] = (isset($params['debug'])) ? true : false;\n\t$Options['help'] = (isset($params['help'])) ? true : false;\n\t$Options['outputlinks'] = (isset($params['outputlinks'])) ? true : false;\n\t\n\t// Are all the required parameters in?\n\tif ($Options['host'] == false) {\n\t\treturn false;\n\t} else {\n\t\treturn $Options;\n\t}\n\t\n}",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'size' => 1\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"function get_web_folder_layout_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::FOLDER_LAYOUT_STANDARD => lang('flexshare_standard'),\n self::FOLDER_LAYOUT_SANDBOX => lang('flexshare_sandbox')\n );\n\n return $options;\n }",
"public function getPermissionOptions()\n {\n return [\n 'read' => 'View listing and edit views',\n 'create' => 'Create new items',\n 'update' => 'Update existing items',\n 'grant' => 'Change role and permissions',\n 'destroy' => ['Delete', 'Delete items permanently'],\n ];\n }",
"function usersets_list() {\n\t$results = sql(\"SELECT * FROM usersets\",\"getAll\",DB_FETCHMODE_ASSOC);\n\tif(is_array($results)){\n\t\tforeach($results as $result){\n\t\t\t// check to see if we have a dept match for the current AMP User.\n\t\t\tif (checkDept($result['deptname'])){\n\t\t\t\t// return this item's dialplan destination, and the description\n\t\t\t\t$allowed[] = $result;\n\t\t\t}\n\t\t}\n\t}\n\tif (isset($allowed)) {\n\t\treturn $allowed;\n\t} else {\n\t\treturn null;\n\t}\n}",
"function getAdminOptions() {\n $devloungeAdminOptions = array('brandfolder_url' => '');\n $devOptions = get_option($this->adminOptionsName);\n if (!empty($devOptions)) {\n foreach ($devOptions as $key => $option)\n $devloungeAdminOptions[$key] = $option;\n }\n update_option($this->adminOptionsName, $devloungeAdminOptions);\n return $devloungeAdminOptions;\n }",
"function plugin_getuseroption_downloads()\n{\n global $_CONF, $_TABLES, $LANG_DLM, $_DLM_CONF;\n\n if (SEC_hasRights('downloads.upload') || $_DLM_CONF['download_uploadselect'] == 1) {\n return array($LANG_DLM['user_menu'], $_CONF['site_url'] . '/submit.php?type=downloads');\n }\n return false;\n}",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'cols' => 1,\n\t\t\t\t\t\t\t'rows' => 1,\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'tabindex' => 1,\n\t\t\t\t\t\t\t'accesskey' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'readonly' => 1,\n\t\t\t\t\t\t\t'type' => 2\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"public static function get_filemanager_options() {\n return [\n 'subdirs' => 1,\n 'accepted_types' => '*'\n ];\n }",
"function ftplist($dir=NULL) {\n\t\t\treturn ftp_nlist(fra_ftp, fra_var[\"ftp_path\"].\"\".$dir);\n\t\t}",
"function _terminatur_file_options(&$aliases) {\n // Check if user has rsync\n $method = drush_shell_exec('rsync --version') ? 'rsync' : 'download';\n foreach ($aliases as $key => $value) {\n $aliases[$key]['terminatur']['files']['method'] = $method;\n switch ($method) {\n case 'rsync':\n $rsync = array(\n 'options' => '-rlztv --ipv4',\n 'ssh' => addcslashes(\"-e 'ssh \" . $aliases[$key]['ssh-options'] . \"'\", \"'\"),\n 'excludes' => addcslashes(\"--exclude 'js' --exclude 'css' --exclude 'ctools' --exclude 'imagecache' --exclude 'xmlsitemap' --exclude 'backup_migrate' --exclude 'styles' --exclude 'less'\", \"'\"),\n 'remote-files' => $aliases[$key]['remote-user'] . \"@\" . $aliases[$key]['remote-host'] . \":files\",\n );\n $aliases[$key]['terminatur']['files']['rsync'] = $rsync;\n break;\n case 'download':\n $bucket = terminus_latest_bucket($aliases[$key]['uuid'], $aliases[$key]['env'], 'files');\n $aliases[$key]['terminatur']['files']['download-bucket'] = $bucket ? $bucket : 'NONE';\n break;\n }\n }\n}",
"public static function getAllowedInodeTypes()\n {\n $allowed = [\n 'file', 'image', 'video', 'audio', 'archive'\n ];\n if (\\is_array(config('omen.showFileTypes'))) {\n foreach (config('omen.showFileTypes') as $inodeFileType) {\n if (!\\defined(sprintf('Kwaadpepper\\Omen\\Lib\\InodeFileType::%s', \\strtoupper($inodeFileType))) and $inodeFileType != 'file') {\n throw new OmenException(\"Wrong configuration option: omen.showFileTypes $inodeFileType is unkown\");\n }\n }\n $allowed = config('omen.showFileTypes');\n }\n\n if (session()->has('omen.showFileTypes')) {\n $allowed = session('omen.showFileTypes');\n }\n\n if (!count($allowed)) {\n throw new OmenException(\"Wrong configuration omen.showFileTypes is too restrictive, cant display anything\");\n }\n\n if (\\in_array('file', $allowed)) {\n $allowed = \\array_merge($allowed, [\n InodeFileType::PDF,\n InodeFileType::TEXT,\n InodeFileType::FILE,\n InodeFileType::WRITER,\n InodeFileType::CALC,\n InodeFileType::IMPRESS,\n InodeFileType::DISKIMAGE,\n InodeFileType::EXECUTABLE\n ]);\n }\n\n return $allowed;\n }",
"function get_system_permissions()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $permissions = array(\n self::PERMISSIONS_SECURE => lang('base_disabled'),\n self::PERMISSIONS_READ_ONLY => lang('flexshare_read_only')\n );\n\n return $permissions;\n }",
"function get_allowed_video_file_types()\n{\n $supported = str_replace(' ', '', get_option('valid_videos'));\n if (get_option('allow_audio_videos') == '1') {\n $supported .= ',' . get_allowed_audio_file_types();\n }\n $supported .= ',pdf';\n if (has_privilege(get_member(), 'use_very_dangerous_comcode')) {\n $supported .= ',swf';\n }\n return $supported;\n}",
"protected function getOptions() \r\n\t{\r\n\t\t$options = array('Modus 1', 'Modus 2');\r\n\t\treturn $options;\r\n\t}",
"public function ListSupportedLoginModes()\n\t{\n\t\treturn array('form','basic', 'external', 'url');\n\t}",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'cols' => 1,\n\t\t\t\t\t\t\t'rows' => 1,\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'tabindex' => 1,\n\t\t\t\t\t\t\t'accesskey' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'readonly' => 1\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"static public function getAllUSPSOptions()\n {\n $options = array();\n\n foreach(self::getBoxmenuGroups() as $boxmenuId=>$boxmenuGroup) {\n $boxType = $boxmenuGroup->getBoxType();\n\n if ($boxType!=4 && $boxType!=0) {\n $options[$boxmenuId] = $boxmenuGroup['title'];\n }\n }\n\n return $options;\n }",
"public function getTransferOptions()\n {\n return $this->transfer_options;\n }",
"function plugin_getuseroption_forum()\n{\n global $CONF_FORUM, $_CONF, $LANG_GF00;\n\n if ($CONF_FORUM['registration_required'] == 0 || SEC_hasRights('forum.user')) {\n return array($LANG_GF00['useradminmenu'], $_CONF['site_url'] . '/forum/userprefs.php', 0);\n }\n}",
"public function getTypeAllowableValues()\n {\n return [\n self::TYPE_FILE,\nself::TYPE_FOLDER,\nself::TYPE_SHARED_FOLDER,\nself::TYPE_SEND_RECEIPT,\nself::TYPE_SHARE_RECEIPT,\nself::TYPE_FILE_DROP, ];\n }",
"public function get_allowed_types() {\n\t\t$types = array();\n\t\t$wp_get_ext_types = wp_get_ext_types();\n\t\t$types[\"@\"] = esc_html__( 'Use allowed file types from WordPress', 'woocommerce-tm-extra-product-options' );\n\t\tforeach ( $wp_get_ext_types as $key => $value ) {\n\t\t\t$types[ \"@\" . $key ] = $key . \" \" . esc_html__( 'files', 'woocommerce-tm-extra-product-options' );\n\t\t\tforeach ( $value as $key2 => $value2 ) {\n\t\t\t\t$types[ $value2 ] = $value2;\n\t\t\t}\n\t\t}\n\n\t\treturn $types;\n\t}",
"protected static function allowedOptions()\n\t{\n\t\treturn array(\n\t\t\t\t\t\t'type' => 4,\n\t\t\t\t\t\t'constraint' => 4,\n\t\t\t\t\t\t'class' => 1,\n\t\t\t\t\t\t'title' => 1,\n\t\t\t\t\t\t'style' => 1,\n\t\t\t\t\t\t'lblLast' => 2,\n\t\t\t\t\t\t'default' => 2,\n\t\t\t\t\t\t'role' => 4,\n\t\t\t\t\t\t'targetAttribute' => 4,\n\t\t\t\t\t\t'novalue' => 2,\n\t\t\t\t\t\t'noLabel' => 2,\n\t\t\t\t\t\t'from' => 2,\n\t\t\t\t\t\t'optype' => 2,\n\t\t\t\t\t\t'language' => 2\n\t\t\t\t\t);\n\t}",
"public function getAdminOptions()\n {\n if (empty($this->adminOptions)) {\n $uamAdminOptions = array(\n \t'hide_post_title' => 'false', \n \t'post_title' => __('No rights!', 'user-access-manager'),\n \t'post_content' => __(\n \t\t'Sorry you have no rights to view this post!', \n \t\t'user-access-manager'\n ),\n 'hide_post' => 'false', \n \t'hide_post_comment' => 'false', \n \t'post_comment_content' => __(\n \t\t'Sorry no rights to view comments!', \n \t\t'user-access-manager'\n ), \n \t'post_comments_locked' => 'false',\n \t'hide_page_title' => 'false', \n \t'page_title' => __('No rights!', 'user-access-manager'), \n \t'page_content' => __(\n \t\t'Sorry you have no rights to view this page!', \n \t\t'user-access-manager'\n ), \n \t'hide_page' => 'false',\n 'hide_page_comment' => 'false', \n \t'page_comment_content' => __(\n \t\t'Sorry no rights to view comments!', \n \t\t'user-access-manager'\n ), \n \t'page_comments_locked' => 'false',\n \t'redirect' => 'false', \n \t'redirect_custom_page' => '', \n \t'redirect_custom_url' => '', \n \t'lock_recursive' => 'true',\n 'authors_has_access_to_own' => 'true',\n 'authors_can_add_posts_to_groups' => 'false',\n \t'lock_file' => 'false', \n \t'file_pass_type' => 'random', \n \t'lock_file_types' => 'all', \n \t'download_type' => 'fopen', \n \t'locked_file_types' => 'zip,rar,tar,gz,bz2', \n \t'not_locked_file_types' => 'gif,jpg,jpeg,png', \n \t'blog_admin_hint' => 'true', \n \t'blog_admin_hint_text' => '[L]',\n \t'hide_empty_categories' => 'true', \n \t'protect_feed' => 'true', \n \t'show_post_content_before_more' => 'false', \n \t'full_access_role' => 'administrator'\n );\n \n $uamOptions = get_option($this->adminOptionsName);\n \n if (!empty($uamOptions)) {\n foreach ($uamOptions as $key => $option) {\n $uamAdminOptions[$key] = $option;\n }\n }\n \n update_option($this->adminOptionsName, $uamAdminOptions);\n $this->adminOptions = $uamAdminOptions;\n }\n\n return $this->adminOptions;\n }",
"protected static function getUnisAsOptionList()\r\n\t{\r\n\t\t$options = \"\";\r\n\t\tforeach(self::$unis as $uni)\r\n\t\t{\r\n\t\t\tif($uni->isSelected())\r\n\t\t\t{\r\n\t\t\t\t$selected = \" selected=\\\"selected\\\"\";\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\t$selected = \"\";\r\n\t\t\t}\r\n\t\t\t$options .= \"<option value=\\\"\".$uni->getDomain().\"\\\"\".$selected.\">\".$uni->getName().\"</option>\";\r\n\t\t}\r\n\t\treturn $options;\r\n\t}"
] | [
"0.6938663",
"0.6240682",
"0.5592648",
"0.55735636",
"0.5561757",
"0.532915",
"0.50743955",
"0.50407916",
"0.49321887",
"0.4914908",
"0.4895234",
"0.48796886",
"0.4857754",
"0.48576498",
"0.48447502",
"0.48423606",
"0.4834309",
"0.48317933",
"0.4826499",
"0.4821484",
"0.48112795",
"0.4808581",
"0.48072556",
"0.4773777",
"0.47710818",
"0.4750752",
"0.47404534",
"0.47284585",
"0.47188336",
"0.47142997"
] | 0.70851886 | 0 |
Returns a list of valid file permission options for a flexshare. | function get_file_permission_options()
{
clearos_profile(__METHOD__, __LINE__);
$options = array(
self::PERMISSION_READ => lang('flexshare_read_only'),
self::PERMISSION_READ_WRITE => lang('flexshare_read_write')
);
return $options;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function get_ftp_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE_PLUS => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"public static function getPermissionsFiles() {\n\t\t$writableFilesAndFolders = self::$writableFilesAndFolders;\n\t\t$permissions = array();\n\t\trequire_once ('include/utils/VtlibUtils.php');\n\t\tforeach ($writableFilesAndFolders as $index => $value) {\n\t\t\t$permissions[$index]['permission'] = 'TruePermission';\n\t\t\t$permissions[$index]['path'] = $value;\n\t\t\tif (!vtlib_isWriteable($value)) {\n\t\t\t\t$permissions[$index]['permission'] = 'FailedPermission';\n\t\t\t}\n\t\t}\n\t\treturn $permissions;\n\t}",
"public function getPermissionOptions()\n {\n return [\n 'read' => 'View listing and edit views',\n 'create' => 'Create new items',\n 'update' => 'Update existing items',\n 'grant' => 'Change role and permissions',\n 'destroy' => ['Delete', 'Delete items permanently'],\n ];\n }",
"function get_web_access_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::ACCESS_LAN => lang('flexshare_access_lan'),\n self::ACCESS_ALL => lang('base_all')\n );\n\n return $options;\n }",
"public static function getOptions() {\n global $sitemap_activated;\n if(!$sitemap_activated)\n return array();\n\n $robot = new File('..', 'robots.txt');\n $sitemap = new File('..', 'sitemap.xml');\n $rights = array(\n '../robots.txt' => $robot->isWritable(true),\n '../sitemap.xml' => $sitemap->isWritable(true),\n );\n $failure = false;\n foreach($rights as $file=>$r) {\n if(!$r) {\n $failure = true;\n break;\n }\n }\n if($failure)\n Controller::notifyUser('error', 'permission', $rights);\n\n return array();\n }",
"public function permissionList(): array {\n return $this->info()['Permission'];\n }",
"function get_system_permissions()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $permissions = array(\n self::PERMISSIONS_SECURE => lang('base_disabled'),\n self::PERMISSIONS_READ_ONLY => lang('flexshare_read_only')\n );\n\n return $permissions;\n }",
"public function getTypeAllowableValues()\n {\n return [\n self::TYPE_FILE,\nself::TYPE_FOLDER,\nself::TYPE_SHARED_FOLDER,\nself::TYPE_SEND_RECEIPT,\nself::TYPE_SHARE_RECEIPT,\nself::TYPE_FILE_DROP, ];\n }",
"function get_enforce_group_permissions()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n try {\n $option = $this->_get_global_parameter('FlexshareSecurityPermissions');\n } catch (Flexshare_Parameter_Not_Found_Exception $e) {\n // Ignore\n } catch (Engine_Exception $e) {\n // Ignore\n }\n\n if (empty($option))\n $option = 'on';\n\n return $option;\n }",
"public static function getAllowedInodeTypes()\n {\n $allowed = [\n 'file', 'image', 'video', 'audio', 'archive'\n ];\n if (\\is_array(config('omen.showFileTypes'))) {\n foreach (config('omen.showFileTypes') as $inodeFileType) {\n if (!\\defined(sprintf('Kwaadpepper\\Omen\\Lib\\InodeFileType::%s', \\strtoupper($inodeFileType))) and $inodeFileType != 'file') {\n throw new OmenException(\"Wrong configuration option: omen.showFileTypes $inodeFileType is unkown\");\n }\n }\n $allowed = config('omen.showFileTypes');\n }\n\n if (session()->has('omen.showFileTypes')) {\n $allowed = session('omen.showFileTypes');\n }\n\n if (!count($allowed)) {\n throw new OmenException(\"Wrong configuration omen.showFileTypes is too restrictive, cant display anything\");\n }\n\n if (\\in_array('file', $allowed)) {\n $allowed = \\array_merge($allowed, [\n InodeFileType::PDF,\n InodeFileType::TEXT,\n InodeFileType::FILE,\n InodeFileType::WRITER,\n InodeFileType::CALC,\n InodeFileType::IMPRESS,\n InodeFileType::DISKIMAGE,\n InodeFileType::EXECUTABLE\n ]);\n }\n\n return $allowed;\n }",
"public function list_permissions(){\n $auth = Yii::$app->authManager;\n\n return ['list' => $auth->getPermissions()];\n }",
"function get_dir_options($name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array();\n\n // Custom\n try {\n $custom_data = $this->_get_global_parameter('FlexshareDirCustom');\n if (! empty($custom_data)) {\n $list = preg_split(\"/\\\\|/\", $this->_get_global_parameter('FlexshareDirCustom'));\n foreach ($list as $custom) {\n list ($desc, $path) = preg_split(\"/:/\", $custom);\n $options[$path] = $desc . ' (' . $path . \")\\n\";\n }\n }\n } catch (Flexshare_Parameter_Not_Found_Exception $e) {\n // Ignore\n } catch (Engine_Exception $e) {\n // Ignore\n }\n\n // If $name is NULL, fancy up the path displayed\n if ($name == NULL)\n $display_name = preg_replace('/ /', '_', strtoupper(lang('flexshare_share_name'))); \n else\n $display_name = $name;\n\n // Default\n $options[self::SHARE_PATH . '/' . $name] = lang('base_default') . ' (' . self::SHARE_PATH . '/' . $display_name . \")\";\n\n return $options;\n }",
"public function view_file_permissions()\n{\n\t$jinput = JFactory::getApplication()->input;\n\t$jinput->set('view', 'filesstatus');\n\t\n\tparent::display();\n}",
"function get_ftp_umask_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n // Umask is inverted.\n $options = array(\n 7 => \"---\",\n 6 => \"--x\",\n 5 => \"-w-\",\n 4 => \"-wx\",\n 3 => \"r--\",\n 2 => \"r-x\",\n 1 => \"rw-\",\n 0 => \"rwx\"\n );\n\n return $options;\n }",
"public function list_ldap_access_options() {\n\t\tif(is_null($this->id)) throw new BadMethodCallException('Server must be in directory before LDAP access options can be listed');\n\t\t$stmt = $this->database->prepare(\"\n\t\t\tSELECT *\n\t\t\tFROM server_ldap_access_option\n\t\t\tWHERE server_id = ?\n\t\t\tORDER BY `option`\n\t\t\");\n\t\t$stmt->bind_param('d', $this->id);\n\t\t$stmt->execute();\n\t\t$result = $stmt->get_result();\n\t\t$options = array();\n\t\twhile($row = $result->fetch_assoc()) {\n\t\t\t$options[$row['option']] = new ServerLDAPAccessOption($row['option'], $row);\n\t\t}\n\t\t$stmt->close();\n\t\treturn $options;\n\t}",
"public function getAllowedFiles(){\n return self::$allowed_files;\n }",
"protected static function allowedOptions()\n\t{\n\t\t$additional = array(\n\t\t\t\t\t\t\t'dir' => 1,\n\t\t\t\t\t\t\t'lang' => 1,\n\t\t\t\t\t\t\t'xml:lang' => 1,\n\t\t\t\t\t\t\t'disabled' => 1,\n\t\t\t\t\t\t\t'size' => 1\n\t\t\t\t\t\t\t);\n\t\treturn array_merge(parent::allowedOptions(), $additional);\n\t}",
"public function getPermissions() {\r\n\t\treturn array();\r\n\t}",
"public function defaultPermissionList(): array {\n return $this->info()['defaultPermission'] ?? [];\n }",
"function fileperms ($filename) {}",
"public function getDirectPermissions(): Collection;",
"public function get_chmod_array($runtime = false)\n {\n return array();\n }",
"public function get_chmod_array($runtime = false)\n {\n return array();\n }",
"public function get_chmod_array($runtime = false)\n {\n return array();\n }",
"public function get_chmod_array($runtime = false)\n {\n return array();\n }",
"private static function _isAllowed($allows){\n\t\treturn in_array(self::$files['type'], $allows);\n\t}",
"public function allPermissions()\n {\n return [];\n }",
"private function list_rights($attrib=array())\n {\n // Get ACL for the folder\n $acl = $this->rc->storage->get_acl($this->mbox);\n\n if (!is_array($acl)) {\n $acl = array();\n }\n\n // Keep special entries (anyone/anonymous) on top of the list\n if (!empty($this->specials) && !empty($acl)) {\n foreach ($this->specials as $key) {\n if (isset($acl[$key])) {\n $acl_special[$key] = $acl[$key];\n unset($acl[$key]);\n }\n }\n }\n\n // Sort the list by username\n uksort($acl, 'strnatcasecmp');\n\n if (!empty($acl_special)) {\n $acl = array_merge($acl_special, $acl);\n }\n\n // Get supported rights and build column names\n $supported = $this->rights_supported();\n\n // give plugins the opportunity to adjust this list\n $data = $this->rc->plugins->exec_hook('acl_rights_supported',\n array('rights' => $supported, 'folder' => $this->mbox, 'labels' => array()));\n $supported = $data['rights'];\n\n // depending on server capability either use 'te' or 'd' for deleting msgs\n $deleteright = implode(array_intersect(str_split('ted'), $supported));\n\n // Use advanced or simple (grouped) rights\n $advanced = $this->rc->config->get('acl_advanced_mode');\n\n if ($advanced) {\n $items = array();\n foreach ($supported as $sup) {\n $items[$sup] = $sup;\n }\n }\n else {\n $items = array(\n 'read' => 'lrs',\n 'write' => 'wi',\n 'delete' => $deleteright,\n 'other' => preg_replace('/[lrswi'.$deleteright.']/', '', implode($supported)),\n );\n\n // give plugins the opportunity to adjust this list\n $data = $this->rc->plugins->exec_hook('acl_rights_simple',\n array('rights' => $items, 'folder' => $this->mbox, 'labels' => array()));\n $items = $data['rights'];\n }\n\n // Create the table\n $attrib['noheader'] = true;\n $table = new html_table($attrib);\n\n // Create table header\n $table->add_header('user', $this->gettext('identifier'));\n foreach (array_keys($items) as $key) {\n $label = $data['labels'][$key] ?: $this->gettext('shortacl'.$key);\n $table->add_header(array('class' => 'acl'.$key, 'title' => $label), $label);\n }\n\n $js_table = array();\n foreach ($acl as $user => $rights) {\n if ($this->rc->storage->conn->user == $user) {\n continue;\n }\n\n // filter out virtual rights (c or d) the server may return\n $userrights = array_intersect($rights, $supported);\n $userid = rcube_utils::html_identifier($user);\n\n if (!empty($this->specials) && in_array($user, $this->specials)) {\n $user = $this->gettext($user);\n }\n\n $table->add_row(array('id' => 'rcmrow'.$userid));\n $table->add('user', html::a(array('id' => 'rcmlinkrow'.$userid), rcube::Q($user)));\n\n foreach ($items as $key => $right) {\n $in = $this->acl_compare($userrights, $right);\n switch ($in) {\n case 2: $class = 'enabled'; break;\n case 1: $class = 'partial'; break;\n default: $class = 'disabled'; break;\n }\n $table->add('acl' . $key . ' ' . $class, '');\n }\n\n $js_table[$userid] = implode($userrights);\n }\n\n $this->rc->output->set_env('acl', $js_table);\n $this->rc->output->set_env('acl_advanced', $advanced);\n\n $out = $table->show();\n\n return $out;\n }",
"function file_permissions($file) {\n\t// fileperms returns a numeric value\n\t$numeric_perms = fileperms($file);\n\t// but we are used to seeing the octal value\n\t$octal_perms = sprintf('%o', $numeric_perms);\n\treturn substr($octal_perms, -4);\n}",
"function check_verzeichnis_rechte()\n\t{\n\t\t$verz_array = array(\"../styles\");\n\t\t$i=0;\n\t\tforeach ($verz_array as $file) {\n\t\t\tif ($this->checkpermission($file)) {\n\t\t\t\t$perm[$i]['perm'] = \"no\";\n\t\t\t\t$perm[$i]['file'] = $file;\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$perm[$i]['perm'] = \"ja\";\n\t\t\t\t$perm[$i]['file'] = $file;\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\t\tIfNotSetNull($perm);\n\t\treturn $perm;\n\t}"
] | [
"0.73702586",
"0.629822",
"0.6200755",
"0.6157769",
"0.6025316",
"0.59840643",
"0.59187686",
"0.5816291",
"0.5804032",
"0.5756475",
"0.57302517",
"0.57188076",
"0.56730986",
"0.56722826",
"0.5647997",
"0.5588631",
"0.5576522",
"0.54978716",
"0.54690796",
"0.5462587",
"0.5461702",
"0.54497325",
"0.54497325",
"0.54497325",
"0.54497325",
"0.5441472",
"0.54389507",
"0.5435872",
"0.54281855",
"0.5421683"
] | 0.7889539 | 0 |
Sets a flex share's description. | function set_description($name, $description)
{
clearos_profile(__METHOD__, __LINE__);
Validation_Exception::is_valid($this->validate_description($description));
$this->_set_parameter($name, 'ShareDescription', $description);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function setDescription($value) {\n $this->description = $value;\n }",
"public function setDescription($value)\n {\n $this->_description = $value;\n }",
"function setDescription( $value )\r\n {\r\n $this->Description = $value;\r\n }",
"public function setDescription($value)\n {\n $this->description = $value;\n }",
"public function setDescription($description)\r\n {\r\n $this->_description = $description;\r\n }",
"public function setDescription($description){\n $this->description = $description;\n }",
"public function setDescription($description) {\r\n\t$this->description = $description;\r\n }",
"public function setDescription($desc)\n\t{\n\t\t$this->description = $desc;\n\t}",
"public function setDescription($val) {\n $this->_description = $val;\n }",
"public function setDescription( $description ) \n {\n $this->description = $description; \n }",
"function setDescription($description=\"\") {\n $this->description = $description;\n }",
"public function setDescription($description) {\n $this->description = $description;\n }",
"public function setDescription($description) {\n $this->description = $description;\n }",
"public function setDescription($description)\n {\n $this->_description = $description;\n }",
"public function setDescription($description) {\n\t\t$this->setMeta('Description', $description);\n\t}",
"public function setDescription($description) {\n\t\t$this->description = $description;\n\t}",
"function setDescription($description = \"\") \n\t{\n\t\t$this->description = $description;\n\t}",
"public static function setDescription($description )\n\t{\n\t\tself::metadata();\n\t\tstatic::$metadata->description = $description;\n\t}",
"public function setDescription($description)\n\t{\n\t\t$this->description = $description;\n\t}",
"public static function assignDescription($description)\n {\n global $xoopsTpl, $xoTheme;\n\n $description = trim($description);\n if (!empty($description)) {\n if (is_object($xoTheme)) {\n $xoTheme->addMeta('meta', 'description', $description);\n } else {\n $xoopsTpl->assign('xoops_meta_description', $description);\n }\n }\n }",
"public function setDescription($description) {\n $this->description = $description;\n }",
"public function setDescription($description) {\n $this->description = $description;\n }",
"public function setDescription($description) {\n $this->description = $description;\n }",
"public function setDescription($description) {\n $this->description = $description;\n }",
"public function setDescription($description) {\n $this->description = $description;\n }",
"public function setDesc($a_desc) {\n\n $this->a_desc = $a_desc;\n\n }",
"function setDescription($new_description)\n\t\t{\n\t\t\t$this->description = $new_description;\n\t\t}",
"protected function setDescription(string $description): void\n {\n $this->_description = $description;\n }",
"public function setDescription(string $description)\n\t{\n\t\t$this->description=$description; \n\t\t$this->keyModified['description'] = 1; \n\n\t}",
"public function setDescription( $description )\n {\n $this->description = $description;\n }"
] | [
"0.6798926",
"0.66979146",
"0.6609604",
"0.6604832",
"0.65765923",
"0.6571131",
"0.6569206",
"0.65654534",
"0.65623206",
"0.6546839",
"0.6536112",
"0.6520138",
"0.6520138",
"0.64889044",
"0.64848053",
"0.6482115",
"0.64709604",
"0.6456734",
"0.6455635",
"0.6452576",
"0.6427464",
"0.6427464",
"0.642415",
"0.642415",
"0.642415",
"0.641369",
"0.6394627",
"0.6392298",
"0.6391671",
"0.6389735"
] | 0.74660814 | 0 |
Sets a flex share's system permissions. | function set_system_permissions($name, $permissions)
{
clearos_profile(__METHOD__, __LINE__);
Validation_Exception::is_valid($this->validate_system_permissions($permissions));
$this->_set_parameter($name, 'ShareSystemPermissions', $permissions);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function update_share_permissions()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $enforce = $this->get_enforce_group_permissions();\n\n if ($enforce == self::ENFORCE_OFF)\n return;\n\n $type = ($enforce == self::ENFORCE_FULL) ? self::TYPE_ALL : self::TYPE_FILE_SHARE;\n $shares = $this->_get_shares($type);\n\n foreach ($shares as $name => $detail)\n $this->_update_folder_attributes($detail['ShareDir'], $detail['ShareOwner'], $detail['ShareGroup'], $detail['ShareSystemPermissions']);\n }",
"public function setWritePermissions()\n {\n if( is_dir(ROOT . '/app/tmp') )\n {\n $this->out('Setting permissions on ROOT/app/tmp ...');\n $this->chMod(ROOT . '/app/tmp/');\n }\n\n if( is_dir(ROOT . '/app/webroot/media') )\n {\n $this->out('Setting permissions on ROOT/app/webroot/media ...');\n $this->chMod(ROOT . '/app/webroot/media/');\n }\n }",
"protected function setApplicationPermissions()\n\t{\n\t\t$files = (array) $this->rocketeer->getOption('remote.permissions.files');\n\t\tforeach ($files as $file) {\n\t\t\t$this->setPermissions($file);\n\t\t}\n\t}",
"private function setPermissions()\n\t{\n\t\tforeach ($this->foldersToChmod as $folder => $permissions)\n\t\t{\n\t\t\tchmod(__DIR__ . '/' . $folder, $permissions);\n\t\t}\n\n\t\t$this->success('Permissions changed ...');\n\t}",
"function _horde_addUserPermissions($shareRoot, $shareName, $userName,\n $permissions)\n{\n if (!Auth::isAdmin()) {\n return PEAR::raiseError(_(\"You are not allowed to change shares.\"));\n }\n\n require_once 'Horde/Share.php';\n $shares = &Horde_Share::singleton($shareRoot);\n\n if (is_a($share = &$shares->getShare($shareName), 'PEAR_Error')) {\n return $share;\n }\n\n $perm = &$share->getPermission();\n foreach ($permissions as $permission) {\n $permission = String::upper($permission);\n if (defined('PERMS_' . $permission)) {\n $perm->addUserPermission($userName, constant('PERMS_' . $permission), false);\n }\n }\n\n if (is_a($result = $share->setPermission($perm), 'PEAR_Error')) {\n return $result;\n }\n\n return true;\n}",
"protected function setUserPermissions() {\n\t\t\t\t\n\t}",
"public function setCanCurrentUserShareExternally($value)\n {\n $this->setProperty(\"CanCurrentUserShareExternally\", $value, true);\n }",
"public function setDefaultShareLinkPermission($value)\n {\n $this->setProperty(\"DefaultShareLinkPermission\", $value, true);\n }",
"public function setPermissions( $permissions );",
"public function setAclInfo(){\n\t\t$acl = new WDS_System_Acl();\n\t\t$acl = new \\WDS\\Acl\\Acl();\n\t\t$acl->createPrivilegeArray();\n\t\t$acl->createRole();\n\t}",
"function setDefaultSharing($permission_text='Public_ReadWriteDelete') {\n\t\tVtiger_Access::setDefaultSharing($this, $permission_text);\n\t}",
"public function setPermissions($permissions);",
"public function & SetPermissions ($permissions);",
"private function updatePermissions()\n {\n $pathNames = $this->resolver->names();\n // These should be moved to PathResolver paths eventually.\n $pathNames[] = '%web%/extensions';\n $pathNames[] = '%web%/thumbs';\n\n $dirMode = $this->options->getDirMode();\n foreach ($pathNames as $name) {\n $path = $this->resolver->resolve($name);\n if (!$this->filesystem->exists($path)) {\n $this->filesystem->mkdir($path);\n }\n $this->filesystem->chmod($path, $dirMode);\n }\n }",
"public function setCanCurrentUserShareInternally($value)\n {\n $this->setProperty(\"CanCurrentUserShareInternally\", $value, true);\n }",
"public function & SetPermission ($permissionName, $allow = TRUE);",
"public function setPermissionAttribute($value)\n {\n $this->attributes[\"permission\"] = ($value[0] != \"_\") ? \"_{$value}\" : $value;\n }",
"public function changePermissions($path, $permissions);",
"public function setPermissions($mixed) {\n\t\tif(is_array($mixed)) {\n\t\t\tarray_shift($mixed);\n\t\t\t$this->manageUsers = (bool) $mixed[0];\n\t\t\t$this->manageColors = (bool) $mixed[1];\n\t\t\t$this->manageInventory = (bool) $mixed[2];\n\t\t\t$this->manageOptions = (bool) $mixed[3];\n\t\t\t$this->manageDatabase = (bool) $mixed[4];\n\t\t\t$this->browseColors = (bool) $mixed[5];\n\t\t} else if(is_object($mixed)) {\n\t\t\t$this->manageUsers = (bool) $mixed->ManageUsers;\n\t\t\t$this->manageColors = (bool) $mixed->ManageColors;\n\t\t\t$this->manageInventory = (bool) $mixed->ManageInventory;\n\t\t\t$this->manageOptions = (bool) $mixed->ManageOptions;\n\t\t\t$this->manageDatabase = (bool) $mixed->ManageDatabase;\n\t\t\t$this->browseColors = (bool) $mixed->BrowseColors;\n\t\t}\n\t}",
"public function spacePermissions();",
"public function setAclInfo() {\n\t\t$acl = new Zendvn_System_Acl();\n\t\t$acl->createPrivilegeArray();\n\t\t$acl->createRole();\n\t}",
"function setSiteLevelAccess( ) \n {\n $sitePriv = RowManager_AccountAdminAccessManager::PRIVILEDGE_SITE;\n $this->setValueByFieldName( 'accountadminaccess_privilege', $sitePriv );\n }",
"public function silo_permissions($path)\n\t{\n\t}",
"abstract public static function setup_permissions(): void;",
"function drush_permissions_set() {\n $args = func_get_args();\n print var_dump($args);\n $perm = $args[0];\n $role = $args[1];\n if ($role && $perm && is_numeric($role)){\n db_query('DELETE FROM {permission} WHERE rid = %d', $role);\n db_query(\"INSERT INTO {permission} (rid, perm) VALUES (%d, '%s')\", $role, $permissions);\n }\n\n print sprintf(\"Set rid %s permissions to '%s'\", $role, $permissions);\n}",
"function get_system_permissions()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $permissions = array(\n self::PERMISSIONS_SECURE => lang('base_disabled'),\n self::PERMISSIONS_READ_ONLY => lang('flexshare_read_only')\n );\n\n return $permissions;\n }",
"static public function permissions($aclType = null){\n\t\tif($aclType){\n\t\t\t$varPath = __DIR__ . '/../var';\n\t\t\t$cachePath = $varPath . \"/cache\";\n\t\t\t$logPath = $varPath . \"/logs\";\n\t\t\tif(is_dir($cachePath)){\n\t\t\t\techo \"Clearing cache folder\\n\";\n\t\t\t\tpassthru(\"rm -rf {$cachePath}/*\");\n\t\t\t}else{\n\t\t\t\techo \"Creating cache folder\\n\";\n\t\t\t\tpassthru(\"mkdir {$cachePath}\");\n\t\t\t}\n\t\t\tif(is_dir($logPath)){\n\t\t\t\techo \"Clearing log folder\\n\";\n\t\t\t\tpassthru(\"rm -rf {$logPath}/*\");\n\t\t\t}else{\n\t\t\t\techo \"Creating log folder\\n\";\n\t\t\t\tpassthru(\"mkdir {$logPath}\");\n\t\t\t}\n\n\t\t\t$apacheUser = exec(\"ps aux | grep -E '[a]pache|[h]ttpd' | grep -v root | head -1 | cut -d\\ -f1\");\n\n\t\t\tswitch($aclType){\n\t\t\t\tcase 'chmod':\n\t\t\t\t\t$command = \"sudo chmod +a \\\"`whoami` allow delete,write,append,file_inherit,directory_inherit\\\" {$cachePath} {$logPath}\";\n\t\t\t\t\tif($apacheUser){\n\t\t\t\t\t\t$command .= \" && sudo chmod +a \\\"{$apacheUser} allow delete,write,append,file_inherit,directory_inherit\\\" {$cachePath} {$logPath}\";\n\t\t\t\t\t}\n\t\t\t\t\techo \"Running: {$command}\";\n\t\t\t\t\tpassthru($command, $return);\n\t\t\t\tbreak;\n\t\t\t\tcase 'setfacl':\n\t\t\t\t\t$apacheCommandPart = ($apacheUser)\n\t\t\t\t\t\t? \" -m u:{$apacheUser}:rwX\"\n\t\t\t\t\t\t: ''\n\t\t\t\t\t;\n\t\t\t\t\t$command = \"sudo setfacl -R {$apacheCommandPart} -m u:`whoami`:rwX {$cachePath} {$logPath} && sudo setfacl -dR {$apacheCommandPart} -m u:`whoami`:rwX {$cachePath} {$logPath}\";\n\t\t\t\t\techo \"Running: {$command}\";\n\t\t\t\t\tpassthru($command, $return);\n\t\t\t\tbreak;\n\t\t\t\tcase 'none':\n\t\t\t\t\techo \"There is no way to set the permissions directly. Please add 'umask(0000);' to app.php and app_dev.php to bypass the need for setting permissions, though it has some security implications.\";\n\t\t\t\t\t$return = 1;\n\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\techo \"Unrecognized option. Please try another option. Try 'none' if your system doesn't support ACLs.\";\n\t\t\t\t\t$return = 1;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}else{\n\t\t\techo \"Choose what type of ACLs your system supports. Options:\\n\"\n\t\t\t\t. \" - chmod: supports `chmod +a` syntax\\n\"\n\t\t\t\t. \" - setfacl: supports `setfacl` command\\n\"\n\t\t\t\t. \" - none: doesn't have ACL support\\n\"\n\t\t\t;\n\t\t\t$return = 1;\n\t\t}\n\n\t\t//--return. if a command failed above, set exit status.\n\t\tif($return !== 0){\n\t\t\texit($return);\n\t\t}\n\t}",
"public function setCanShareFolder($value)\n {\n $this->setProperty(\"CanShareFolder\", $value, true);\n }",
"public function permissions()\n {\n $config = $this->app['config']->get('motor-backend-permissions', []);\n $this->app['config']->set('motor-backend-permissions', array_replace_recursive(require __DIR__.'/../../config/motor-backend-permissions.php', $config));\n }",
"private function setPermissions()\n {\n $this->permissions = \\PermissionModel::getUserPermissionsByRole($this->data['role_id']);\n unset($this->permissions['role_id']);\n }"
] | [
"0.70041126",
"0.6581832",
"0.6302497",
"0.62498015",
"0.6072333",
"0.60238355",
"0.5897806",
"0.5869312",
"0.5833286",
"0.5789502",
"0.57820016",
"0.5757099",
"0.5733167",
"0.5717566",
"0.5676976",
"0.5598962",
"0.5572812",
"0.55528355",
"0.55426",
"0.55242646",
"0.5520593",
"0.5503209",
"0.5498047",
"0.5476795",
"0.5476003",
"0.54695046",
"0.5446306",
"0.5439276",
"0.54303986",
"0.5367223"
] | 0.71573156 | 0 |
Sets the state of a flexshare. | function set_share_state($name, $state)
{
clearos_profile(__METHOD__, __LINE__);
$share = $this->get_share($name);
$state_value = ($state) ? 1 : 0;
$this->_set_parameter($name, 'ShareEnabled', $state_value);
$this->_update_folder_links($name, $this->_get_parameter($name, 'ShareDir'));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function setShare($val)\n {\n $this->_propDict[\"share\"] = $val;\n return $this;\n }",
"public function setShared($shared);",
"public function setIsExternalShareEnabled($val)\n {\n $this->_propDict[\"isExternalShareEnabled\"] = $val;\n return $this;\n }",
"final public function set_state($state) \n {\n $this->_state = $state;\n }",
"public function setShareCounter($shareCounter) {\r\n\t$this->shareCounter = $shareCounter;\r\n }",
"function setShareOb(&$shareOb)\n {\n if (!is_a($shareOb, 'Horde_Share')) {\n return PEAR::raiseError('This object needs a Horde_Share instance as storage handler!');\n }\n $this->_shareOb = &$shareOb;\n }",
"public function setShareType($shareType);",
"public static function __set_state($data);",
"function setState($state) {\n \n $this->state = $state;\n \n }",
"public function setState($state)\n {\n fhread_mutex_lock($this->stateMutex);\n $this->state = $state;\n fhread_mutex_unlock($this->stateMutex);\n }",
"public function share(bool $share = true)\n {\n // cannot be shared\n }",
"function activate($name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $share = $this->get_share($name);\n\n $folder = new Folder($share['ShareDir']);\n\n if (!$folder->exists())\n $folder->create(self::CONSTANT_WEB_APP_USERNAME, 'allusers', '0770'); // FIXME: allusers\n\n $this->set_share_state($name, TRUE);\n $this->update_share($name, TRUE);\n }",
"public function setShared($name, $flag)\n {\n $this->configure(['shared' => [$name => (bool) $flag]]);\n }",
"public function setState($state){\n\n $this->session->set('state', $state);\n }",
"public function setState(AState $state) : void\n {\n $this->stateCount = 0;\n $this->state = $state;\n }",
"public function setState($aState)\n\t{\n\t\t$this->state = $aState;\n\t\n\t}",
"public function setShared ( $key, $shared ) {\n\t\t\n\t\t$this->shared[ $key ] = $shared;\n\t}",
"public function setState($state) {\n\t\t$this->state = $state;\n\t}",
"function setopen($state) {\n\t\t$this->open=$state;\n\t}",
"public function set_state(array $state)\n {\n $state_query = http_build_query($state, '', '&'); \n\n //tell the UCS to load the serialized state\n $this->send_raw_command('l '.$state_query);\n\n //discard the response\n $this->read_response();\n }",
"public function set(StateInterface $state);",
"public function setActive();",
"public function setSharingType($sharingType)\n {\n $this->_sharingType = $sharingType;\n }",
"public function set_state(){\n\n foreach( $this->kernel->params as $key => $val )\n $_SESSION[\"state\"][$this->kernel->app][$this->kernel->object][$key] = $val;\n\n }",
"function update_share($name, $update_perms = TRUE)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $share = $this->get_share($name);\n\n $this->_generate_web_flexshares();\n $this->_generate_ftp_flexshares();\n $this->_generate_file_flexshares();\n\n $this->_update_folder_links($name, $this->_get_parameter($name, 'ShareDir'));\n\n if ($update_perms)\n $this->_update_folder_attributes($share['ShareDir'], $share['ShareOwner'], $share['ShareGroup'], $share['ShareSystemPermissions']);\n }",
"public function setState($state)\n {\n $this->state = $state;\n }",
"public function setSharingManager(SharingManagerInterface $sharingManager);",
"protected function _setStream($stream) {\n $this->_stream = $stream;\n $this->_streamPtr = 0;\n }",
"public function updateShare(Share $share)\n {\n $this->request->getSession()->start();\n $contents = $this->request->request->all(); \n $data = json_decode($this->request->getContent(), true); \n $content = $contents['share']['content'] ?? $data['content'];\n\n $share->setContent($content);\n $share->setUpdateAt(new \\DateTime(null, new \\DateTimeZone(\"UTC\")));\n $this->dm->flush();\n }",
"public function __set($name,$value)\n\t{\n\t\tif($this->hasState($name))\n\t\t\t$this->setState($name,$value);\n\t\telse\n\t\t\tparent::__set($name,$value);\n\t}"
] | [
"0.63268775",
"0.6165987",
"0.5985441",
"0.5739103",
"0.5714255",
"0.57039523",
"0.56861055",
"0.54803145",
"0.542567",
"0.542399",
"0.54196286",
"0.54058665",
"0.5397384",
"0.5389476",
"0.53787553",
"0.5376278",
"0.53371716",
"0.5335836",
"0.52798873",
"0.5265376",
"0.5255579",
"0.52175325",
"0.52057666",
"0.51921654",
"0.5176106",
"0.5162225",
"0.5103516",
"0.5052196",
"0.5040284",
"0.5037646"
] | 0.7995333 | 0 |
////////////////// W E B // ////////////////// Sets the directory alias of webbased access. | function set_web_directory_alias($name, $alias)
{
clearos_profile(__METHOD__, __LINE__);
Validation_Exception::is_valid($this->validate_web_directory_alias($alias));
$this->_set_parameter($name, 'WebDirectoryAlias', $alias);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_web_directory_alias_alternate($name, $alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_directory_alias($alias));\n\n $this->_set_parameter($name, 'WebDirectoryAliasAlternate', $alias);\n }",
"function set_web_server_alias($name, $server_alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));\n\n $this->_set_parameter($name, 'WebServerAlias', $server_alias);\n }",
"function set_web_server_alias_alternate($name, $server_alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));\n\n $this->_set_parameter($name, 'WebServerAliasAlternate', $server_alias);\n }",
"public function setAllowAlias($var) {}",
"function validate_web_directory_alias($alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n return;\n }",
"function base_admin()\n{\n $root='';\n $root = \"http://\".$_SERVER['HTTP_HOST'];\n $root .= \"/\".DIR_ADMIN;\n return $root;\n}",
"public function setAppDirectory($directory) {}",
"function op_directory_uri() {\n\tstatic $uri;\n\n\tif ( empty( $uri ) )\n\t\t$uri = apply_filters( 'op/directory_uri', '' );\n\n\treturn $uri;\n}",
"protected function setWebRoot() {\n $web_directory = empty($this->config['web_directory']) ? 'web' : $this->config['web_directory'];\n $this->webRoot = $this->getInstallDir() . trim($web_directory, '/') . '/';\n $this->webRoot = str_replace('//', '/', $this->webRoot);\n }",
"function getAlias($alias){\n if (strpos($alias, '.html')) {\n $alias = substr($alias, strrpos($alias, '/') + 1);\n $alias = str_replace('.html', '', $alias);\n } else {\n $alias = str_replace('/', '', $alias);\n }\n return $alias != '' ? strtolower($alias) : 'home';\n}",
"function set_directory($name, $directory)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $directory = trim($directory);\n $defaultdir = self::SHARE_PATH . '/' . $name;\n\n if (!isset($directory) || !$directory)\n $directory = $defaultdir;\n\n // Validate\n Validation_Exception::is_valid($this->validate_directory($directory));\n\n $this->_update_folder_links($name, $directory);\n\n $this->_set_parameter($name, 'ShareDir', $directory);\n }",
"public function getAlias() {\n\t\treturn $this->site_alias;\n\t}",
"public function setAlias(string $alias)\n\t{\n\t\t$this->addKeyValue('alias', $alias); \n\n\t}",
"public function getAbsoluteDirectory(){\r\n\t\treturn $_SERVER['DOCUMENT_ROOT'].\"/usr/\".$this->_name.\"/\";\r\n\t}",
"function setUseAlias($useAlias);",
"public function testBaseUrlwithModRewriteAlias(): void\n {\n Configure::write('App.base', '/control');\n\n $request = ServerRequestFactory::fromGlobals([\n 'DOCUMENT_ROOT' => '/home/aplusnur/public_html',\n 'PHP_SELF' => '/control/index.php',\n ]);\n\n $this->assertSame('/control', $request->getAttribute('base'));\n $this->assertSame('/control/', $request->getAttribute('webroot'));\n\n Configure::write('App.base', false);\n Configure::write('App.dir', 'affiliate');\n Configure::write('App.webroot', 'newaffiliate');\n\n $request = ServerRequestFactory::fromGlobals([\n 'DOCUMENT_ROOT' => '/var/www/abtravaff/html',\n 'PHP_SELF' => '/newaffiliate/index.php',\n ]);\n\n $this->assertSame('', $request->getAttribute('base'));\n $this->assertSame('/', $request->getAttribute('webroot'));\n }",
"function alias()\n {\n global $W_SES ;\n return $W_SES['alias'] ;\n }",
"public function setWebPath()\n {\n $folder_array = explode(self::DS, $this->getUploadPath());\n $this->web_path = array_pop($folder_array);\n }",
"function setDir ($arg)\n {\n $this->_dir = './themes/' . $arg ;\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"public function setPublicDirectory(string $public_directory): void\n {\n $this->public_directory = $public_directory;\n }",
"public function setFolder() {\n $fb = str_replace('index.php', '', $_SERVER['SCRIPT_FILENAME']);\n $folder = $fb . 'media/blog/';\n if (is_dir($folder . date('Y'))) {\n $folder = $folder . date('Y') . '/';\n }\n else {\n mkdir($folder . date('Y'));\n $folder = $folder . date('Y') . '/';\n }\n if (is_dir($folder . date('m'))) {\n $folder = $folder . date('m') . '/';\n }\n else {\n mkdir($folder . date('m'));\n $folder = $folder . date('m') . '/';\n }\n $this->folder = $folder;\n $this->folder_clean = substr(str_replace($fb, '', $folder), 0, -1);\n }",
"public function getPublicDir(): string;",
"public function getDirectory(){\r\n\t\treturn \"usr/\".$this->_name.\"/\";\r\n\t}",
"function setCacheDir($value) {\n $this->cache_dir = with_slash($value);\n }",
"function vpopmail_add_alias_domain($domain, $aliasdomain)\n{\n}",
"public function getDirectoryURL();",
"protected function setpanoFolderPath() {\r\n $this->panoFolderURL = site_url() . '/' . $this->panoFolder;\r\n // Absolute Path where panogeneration will be store\r\n $this->panoFolderPath = NGGPANOWINABSPATH . $this->panoFolder; \r\n }",
"function setMedPoolFolder()\n\t{\n\t\t$_SESSION[\"il_link_mep_obj\"] = $_GET[\"mep_fold\"];\n\t\t$this->showLinkHelp();\n\t}"
] | [
"0.67108446",
"0.64819276",
"0.61992836",
"0.5971443",
"0.58855623",
"0.57619345",
"0.56781167",
"0.56251955",
"0.5598594",
"0.5590664",
"0.5575043",
"0.5500396",
"0.5492459",
"0.5477983",
"0.5477851",
"0.5476117",
"0.5466719",
"0.54398096",
"0.5414405",
"0.5399681",
"0.5399681",
"0.53860295",
"0.5378022",
"0.5373188",
"0.537137",
"0.5361314",
"0.53328484",
"0.531811",
"0.53059494",
"0.5304753"
] | 0.73319453 | 0 |
Sets the directory alias of webbased access. | function set_web_directory_alias_alternate($name, $alias)
{
clearos_profile(__METHOD__, __LINE__);
Validation_Exception::is_valid($this->validate_web_directory_alias($alias));
$this->_set_parameter($name, 'WebDirectoryAliasAlternate', $alias);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_web_directory_alias($name, $alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_directory_alias($alias));\n\n $this->_set_parameter($name, 'WebDirectoryAlias', $alias);\n }",
"function set_web_server_alias($name, $server_alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));\n\n $this->_set_parameter($name, 'WebServerAlias', $server_alias);\n }",
"function set_web_server_alias_alternate($name, $server_alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));\n\n $this->_set_parameter($name, 'WebServerAliasAlternate', $server_alias);\n }",
"public function setAllowAlias($var) {}",
"function set_directory($name, $directory)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $directory = trim($directory);\n $defaultdir = self::SHARE_PATH . '/' . $name;\n\n if (!isset($directory) || !$directory)\n $directory = $defaultdir;\n\n // Validate\n Validation_Exception::is_valid($this->validate_directory($directory));\n\n $this->_update_folder_links($name, $directory);\n\n $this->_set_parameter($name, 'ShareDir', $directory);\n }",
"public function setAppDirectory($directory) {}",
"protected function setWebRoot() {\n $web_directory = empty($this->config['web_directory']) ? 'web' : $this->config['web_directory'];\n $this->webRoot = $this->getInstallDir() . trim($web_directory, '/') . '/';\n $this->webRoot = str_replace('//', '/', $this->webRoot);\n }",
"public function setPublicDirectory(string $public_directory): void\n {\n $this->public_directory = $public_directory;\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"public function setAlias(string $alias)\n\t{\n\t\t$this->addKeyValue('alias', $alias); \n\n\t}",
"public static function setPathOfAlias($alias, $path)\n {\n if (empty($path))\n unset(self::$_aliases[$alias]);\n else\n self::$_aliases[$alias] = rtrim($path, '\\\\/');\n }",
"function setUseAlias($useAlias);",
"public function setDir($dir);",
"function setDir ($arg)\n {\n $this->_dir = './themes/' . $arg ;\n }",
"public function setWebPath()\n {\n $folder_array = explode(self::DS, $this->getUploadPath());\n $this->web_path = array_pop($folder_array);\n }",
"function setCacheDir($value) {\n $this->cache_dir = with_slash($value);\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"private function _setUserAgentFolder()\n {\n if ($this->getPageSetPath())\n $this->_changeUriForAgent();\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"function validate_web_directory_alias($alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n return;\n }",
"private function setDirectory() {\n\t\t\tif(!is_null($this->folder)) {\n\t\t\t\tif(!file_exists($this->targetDir.$this->folder)) {\n\t\t\t\t\tif(!mkdir($this->targetDir.$this->folder, 0777)) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$this->targetDir .= $this->folder.'/';\n\t\t\t}\n\t\t}",
"protected function setpanoFolderPath() {\r\n $this->panoFolderURL = site_url() . '/' . $this->panoFolder;\r\n // Absolute Path where panogeneration will be store\r\n $this->panoFolderPath = NGGPANOWINABSPATH . $this->panoFolder; \r\n }",
"function setDir($d) {\n if ( is_string($d) )\n $this->dir = new PhingFile($d);\n else\n $this->dir = $d;\n }",
"public function testBaseUrlwithModRewriteAlias(): void\n {\n Configure::write('App.base', '/control');\n\n $request = ServerRequestFactory::fromGlobals([\n 'DOCUMENT_ROOT' => '/home/aplusnur/public_html',\n 'PHP_SELF' => '/control/index.php',\n ]);\n\n $this->assertSame('/control', $request->getAttribute('base'));\n $this->assertSame('/control/', $request->getAttribute('webroot'));\n\n Configure::write('App.base', false);\n Configure::write('App.dir', 'affiliate');\n Configure::write('App.webroot', 'newaffiliate');\n\n $request = ServerRequestFactory::fromGlobals([\n 'DOCUMENT_ROOT' => '/var/www/abtravaff/html',\n 'PHP_SELF' => '/newaffiliate/index.php',\n ]);\n\n $this->assertSame('', $request->getAttribute('base'));\n $this->assertSame('/', $request->getAttribute('webroot'));\n }",
"public function setFolder() {\n $fb = str_replace('index.php', '', $_SERVER['SCRIPT_FILENAME']);\n $folder = $fb . 'media/blog/';\n if (is_dir($folder . date('Y'))) {\n $folder = $folder . date('Y') . '/';\n }\n else {\n mkdir($folder . date('Y'));\n $folder = $folder . date('Y') . '/';\n }\n if (is_dir($folder . date('m'))) {\n $folder = $folder . date('m') . '/';\n }\n else {\n mkdir($folder . date('m'));\n $folder = $folder . date('m') . '/';\n }\n $this->folder = $folder;\n $this->folder_clean = substr(str_replace($fb, '', $folder), 0, -1);\n }",
"public function setDocumentRoot($dir)\n {\n $_SERVER['DOCUMENT_ROOT'] = $this->documentRoot = $dir;\n }",
"private function setDocDir() {\n\t\t$docDir = $this->context->parameters['docDir'];\n\t\tif (!$docDir) {\n\t\t\tthrow new DirectiveException(DirectiveException::DOCDIR_NOT_SET);\n\t\t}\n\t\t$path = ROOT . \"/\" . $docDir;\n\t\tif (!is_dir($path)) {\n\t\t\tthrow new DirectiveException(DirectiveException::DOCDIR_NOT_EXISTS, array($path));\n\t\t}\n\t\t$this->docDir = $docDir;\n\t}",
"protected function setURI()\n {\n $this->uri = $this->protocol . $this->host . '/' . $this->prefix . $this->path;\n }",
"public function set_alias_path($alias_path) {\n if (cf_is_empty_or_non_string('alias_path', $alias_path)) {\n $this->alias_path = '';\n return FALSE;\n }\n\n $this->alias_path = $this->p_sanitize_partial_path($alias_path);\n $this->alias_path_alternate = $this->p_sanitize_partial_path($alias_path, TRUE);\n $this->alias_path_legacy = $this->p_sanitize_partial_path_legacy($alias_path);\n return TRUE;\n }"
] | [
"0.7501402",
"0.664676",
"0.6218793",
"0.60358036",
"0.5921741",
"0.588468",
"0.5713484",
"0.56271577",
"0.562114",
"0.562114",
"0.5620273",
"0.5617568",
"0.5614199",
"0.5599558",
"0.5587067",
"0.55742174",
"0.5561568",
"0.55094206",
"0.5438195",
"0.54288673",
"0.542018",
"0.54041255",
"0.5395837",
"0.53874266",
"0.5333263",
"0.53317565",
"0.5313219",
"0.5287812",
"0.52526605",
"0.52482533"
] | 0.6720595 | 1 |
Sets the enabled of webbased access. | function set_web_enabled($name, $enabled)
{
clearos_profile(__METHOD__, __LINE__);
// TODO: kludgy, the realm name is now automatically set to the flexshare description
$share = $this->get_share($name);
$this->_set_parameter($name, 'WebRealm', $share['ShareDescription']);
$this->_set_parameter($name, 'WebEnabled', ($enabled ? 1: 0));
$this->_generate_web_flexshares();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_web_access($name, $access)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n // Validate\n // --------\n Validation_Exception::is_valid($this->validate_web_access($access));\n\n // If web access is ALL, check e-mail restricts access\n $prevent = TRUE;\n if ((int)$access == self::ACCESS_LAN) {\n $share = $this->get_share($name);\n if (isset($share['EmailRestrictAccess']) && $share['EmailRestrictAccess'])\n $prevent = FALSE;\n if (!isset($share['EmailEnabled']) || !$share['EmailEnabled'])\n $prevent = FALSE;\n if (!isset($share['WebEnabled']) || !$share['WebEnabled'])\n $prevent = FALSE;\n if (isset($share['WebReqAuth']) && $share['WebReqAuth'])\n $prevent = FALSE;\n if ((!isset($share['WebPhp']) || !$share['WebPhp']) && (!isset($share['WebCgi']) || !$share['WebCgi']))\n $prevent = FALSE;\n } else {\n $prevent = FALSE;\n }\n\n if ($prevent)\n throw new Engine_Exception(FLEXSHARE_LANG_WARNING_CONFIG, COMMON_WARNING);\n\n $this->_set_parameter($name, 'WebAccess', $access);\n }",
"public function setEnabled(bool $enable);",
"public function setEnabled($enabled);",
"public function setEnabled($enabled);",
"public function enable();",
"public function enable();",
"public function enabled();",
"public function setEnable( $value = true )\r\n\t{\r\n\t\t$this->enabled = (bool) $value;\r\n\t}",
"public function setEnabled(bool $enabled);",
"public static function enable()\n {\n self::$enabled = true;\n }",
"function set_web_php($name, $web_php)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n // If PHP enabled, check e-mail restricts access\n $prevent = TRUE;\n if ($web_php) {\n $share = $this->get_share($name);\n if (isset($share['EmailRestrictAccess']) && $share['EmailRestrictAccess'])\n $prevent = FALSE;\n if (!isset($share['EmailEnabled']) || !$share['EmailEnabled'])\n $prevent = FALSE;\n if (!isset($share['WebEnabled']) || !$share['WebEnabled'])\n $prevent = FALSE;\n if (isset($share['WebReqAuth']) && $share['WebReqAuth'])\n $prevent = FALSE;\n if (isset($share['WebAccess']) && (int)$share['WebAccess'] == self::ACCESS_LAN)\n $prevent = FALSE;\n\n } else {\n $prevent = FALSE;\n }\n\n if ($prevent)\n throw new Engine_Exception(FLEXSHARE_LANG_WARNING_CONFIG, COMMON_WARNING);\n\n $this->_set_parameter($name, 'WebPhp', $web_php);\n }",
"function set_web_require_authentication($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n // If no auth required, check e-mail restricts access\n $prevent = TRUE;\n\n if (!$state) {\n $share = $this->get_share($name);\n if (isset($share['EmailRestrictAccess']) && $share['EmailRestrictAccess'])\n $prevent = FALSE;\n if (!isset($share['EmailEnabled']) || !$share['EmailEnabled'])\n $prevent = FALSE;\n if (!isset($share['WebEnabled']) || !$share['WebEnabled'])\n $prevent = FALSE;\n if ((!isset($share['WebPhp']) || !$share['WebPhp']) && (!isset($share['WebCgi']) || !$share['WebCgi']))\n $prevent = FALSE;\n if (isset($share['WebAccess']) && (int)$share['WebAccess'] == self::ACCESS_LAN)\n $prevent = FALSE;\n } else {\n $prevent = FALSE;\n }\n\n if ($prevent)\n throw new Engine_Exception(FLEXSHARE_LANG_WARNING_CONFIG, COMMON_WARNING);\n\n $this->_set_parameter($name, 'WebReqAuth', $state);\n }",
"public function enabled() { return true; }",
"public function enable()\n {\n $payload = '';\n\n $this->sendRequest(self::FUNCTION_ENABLE, $payload);\n }",
"public static function setViewEnabled(){\n\t\t$_SESSION[\"view\"] = true;\n\t}",
"public function set_enabled($enabled){\n\t\t$this->filter->set_enabled($enabled);\n\t}",
"public final function setEnabled($enabled) {\n\t\t$this->_disabled = empty($enabled);\n\t}",
"public function setAuthMode()\n {\n $this->authMode = true;\n }",
"public function setEnableViaGetParam() {\n\t\tif (t3lib_div::_GET(self::GETPARAM_KEY)) {\n\t\t\t$this->enable = true;\n\t\t}\n\t}",
"public function setEnabled($enabled)\n {\n $this->enabled = $enabled;\n }",
"public function setEnabled($enabled)\n {\n $this->enabled = $enabled;\n }",
"public function setEnabled($enabled)\n {\n $this->enabled = $enabled;\n }",
"public function enabled($enabled)\n\t{\n\t\t$this->_userEnabled = (bool) $enabled;\n\t}",
"abstract public static function enabled();",
"public function requestWriteMode() {\r\n\t\tif (!$this->mEnableWrite)\r\n\t\t\t$this->dieUsage('Editing of this site is disabled. Make sure the $wgEnableWriteAPI=true; ' .\r\n\t\t\t'statement is included in the site\\'s LocalSettings.php file', 'readonly');\r\n\t}",
"public function enable() {\n }",
"public function set_enabled($enabled)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $file = new File(self::FILE_DAT, TRUE); \n $apache_configlet = new File(self::FILE_APACHE_CONFIGLET, TRUE); \n $httpd_reset = FALSE;\n if ($enabled) {\n if (!$file->exists()) {\n // Let's check for a backup configuration\n $backup = new File(self::FILE_DAT . '.bak', TRUE); \n if ($backup->exists())\n $backup->move_to(self::FILE_DAT);\n else\n $file->create('root', 'root', '0644');\n }\n if ($apache_configlet->exists())\n $apache_configlet->delete();\n $template = new File(clearos_app_base('wpad') . \"/deploy/wpad.conf\");\n if (!$template->exists())\n throw new Engine_Exception(lang('wpad_template_not_found'), CLEAROS_ERROR);\n $template->copy_to(self::FILE_APACHE_CONFIGLET);\n $hostname = new Hostname();\n $hosts = new Hosts();\n $apache_configlet->replace_lines(\"/ServerName SERVER_NAME/\", \" ServerName \" . $this->get_hostname() . \"\\n\");\n $httpd_reset = TRUE;\n } else {\n if ($file->exists()) {\n $backup = new File(self::FILE_DAT . '.bak', TRUE); \n if ($backup->exists())\n $backup->move_to(self::FILE_DAT .'.' . date('ymd-hi') . '.bak');\n $file->move_to(self::FILE_DAT . '.bak');\n }\n if ($apache_configlet->exists()) {\n $apache_configlet->delete();\n $httpd_reset = TRUE;\n }\n }\n if ($httpd_reset && clearos_library_installed('web_server/Httpd')) {\n $httpd = new Httpd();\n $httpd->reset(TRUE);\n }\n }",
"function setEnabled($switch)\r\n {\r\n if ($switch) {\r\n $this->_enabled = true;\r\n } else {\r\n $this->_enabled = false;\r\n }\r\n }",
"public function enabled()\n {\n return true;\n }",
"public function enableUserControl()\n\t{\n\t\t$this->setState('user_control', 1);\n\t}"
] | [
"0.67083305",
"0.63639426",
"0.6271365",
"0.6271365",
"0.62493575",
"0.62493575",
"0.62116724",
"0.61618745",
"0.61052924",
"0.6094343",
"0.6022777",
"0.599828",
"0.5939076",
"0.59096247",
"0.5897601",
"0.5856479",
"0.5855144",
"0.58296704",
"0.581657",
"0.5787912",
"0.5787912",
"0.5787912",
"0.57839185",
"0.57792103",
"0.57717484",
"0.5763524",
"0.5732668",
"0.5725775",
"0.570841",
"0.56894827"
] | 0.731576 | 0 |
Sets the server alias of webbased access. | function set_web_server_alias($name, $server_alias)
{
clearos_profile(__METHOD__, __LINE__);
Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));
$this->_set_parameter($name, 'WebServerAlias', $server_alias);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_web_server_alias_alternate($name, $server_alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));\n\n $this->_set_parameter($name, 'WebServerAliasAlternate', $server_alias);\n }",
"public function setServer($server)\n {\n $this->_url = 'http://' . $server;\n }",
"protected function setServer()\n {\n if (Arr::get($this->config, 'sandbox', false)) {\n $this->serverUrl = self::SERVER_SANDBOX_URL;\n } else {\n $this->serverUrl = self::SERVER_URL;\n }\n }",
"function set_web_directory_alias($name, $alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_directory_alias($alias));\n\n $this->_set_parameter($name, 'WebDirectoryAlias', $alias);\n }",
"public function setServer($server);",
"function set_web_server_name_alternate($name, $server_name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_name($server_name));\n\n $this->_set_parameter($name, 'WebServerNameAlternate', $server_name);\n }",
"public function setAllowAlias($var) {}",
"function setServerName($server_name = null) {\n $http = empty($_SERVER['HTTPS']) ? 'http://' : 'https://';\n if (isSet($_SERVER['SERVER_NAME'])) {\n $server_name = str_replace(array('http://', 'https://'), '', $_SERVER['SERVER_NAME']);\n }\n if (empty($server_name)) {\n $file = WWW_ROOT . 'serw_name.txt';\n $server_name = file_get_contents($file);\n\n $_SERVER['SERVER_NAME'] = $http . $server_name;\n }\n if (!defined('FULL_BASE_URL')) {\n define('FULL_BASE_URL', $http . $server_name);\n }\n\n if (!defined('SURE_BASE_URL')) {\n define('SURE_BASE_URL', $server_name);\n }\n Configure::write('App.SERVER_NAME', $server_name);\n}",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"private function setName() {\n\t\t$this->strName = $_SERVER[\"SERVER_NAME\"];\n\t}",
"function set_web_directory_alias_alternate($name, $alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_directory_alias($alias));\n\n $this->_set_parameter($name, 'WebDirectoryAliasAlternate', $alias);\n }",
"public function setAlias(string $alias)\n\t{\n\t\t$this->addKeyValue('alias', $alias); \n\n\t}",
"public function getAlias() {\n\t\treturn $this->site_alias;\n\t}",
"public function setHost()\n {\n $this->host = Config::get('smsglobal.host');\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"public function setServer($server)\n {\n $this->server = (string)$server;\n }",
"public function setServer($server) {\n $this->server = $server;\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"public static function setSERVER(string $name, $value)\n\t{\n\t\tself::setVar($name, 'server', $value);\n\t}",
"function setUseAlias($useAlias);",
"public function setServerName($val)\n {\n $this->_propDict[\"serverName\"] = $val;\n return $this;\n }",
"function setHost($value) {\n $this->host = $value;\n }",
"public function setServer(Server $server);",
"function alias()\n {\n global $W_SES ;\n return $W_SES['alias'] ;\n }",
"private function assignWebsiteURL() {\n if(isset($_SERVER['HTTPS'])){\n $protocol = ($_SERVER['HTTPS'] && $_SERVER['HTTPS'] != \"off\") ? \"https\" : \"http\";\n }else{\n $protocol = 'http';\n }\n $this->websiteURL = $protocol . \"://\" . $_SERVER['HTTP_HOST'];\n }",
"function get_servername() {return $this->a_servername;}",
"public function setActiveServer( $server ) {\n\t\t$this->active_server = $server;\n\t}",
"public function setHost($host = '')\n {\n if (!empty($host)) {\n $this->host = $host;\n }\n }",
"public function setServerUrl(string $url = 'http://localhost'): void {\n $url = filter_var($url, FILTER_SANITIZE_URL);\n if(filter_var($url, FILTER_VALIDATE_URL)) {\n $this->server_url = $url;\n } else {\n trigger_error(__CLASS__ . ' => setServerUrl(): \"' . $url . '\" is not a valid URL!', E_USER_WARNING);\n }\n }"
] | [
"0.7483295",
"0.64127016",
"0.6256395",
"0.62543845",
"0.6242781",
"0.6213462",
"0.61937773",
"0.6078303",
"0.60568196",
"0.60568196",
"0.60351",
"0.6016309",
"0.5970465",
"0.5956758",
"0.5938634",
"0.59342825",
"0.5928618",
"0.59150845",
"0.58756584",
"0.5832054",
"0.578707",
"0.57715493",
"0.57649404",
"0.57310325",
"0.57099587",
"0.55778116",
"0.55399173",
"0.552448",
"0.5500195",
"0.54765135"
] | 0.7918627 | 0 |
Sets the alternate server alias of webbased access. | function set_web_server_alias_alternate($name, $server_alias)
{
clearos_profile(__METHOD__, __LINE__);
Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));
$this->_set_parameter($name, 'WebServerAliasAlternate', $server_alias);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_web_server_alias($name, $server_alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));\n\n $this->_set_parameter($name, 'WebServerAlias', $server_alias);\n }",
"function set_web_server_name_alternate($name, $server_name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_name($server_name));\n\n $this->_set_parameter($name, 'WebServerNameAlternate', $server_name);\n }",
"function set_web_directory_alias_alternate($name, $alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_directory_alias($alias));\n\n $this->_set_parameter($name, 'WebDirectoryAliasAlternate', $alias);\n }",
"public function setServer($server)\n {\n $this->_url = 'http://' . $server;\n }",
"public function setServer($server);",
"protected function setServer()\n {\n if (Arr::get($this->config, 'sandbox', false)) {\n $this->serverUrl = self::SERVER_SANDBOX_URL;\n } else {\n $this->serverUrl = self::SERVER_URL;\n }\n }",
"function set_web_directory_alias($name, $alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_directory_alias($alias));\n\n $this->_set_parameter($name, 'WebDirectoryAlias', $alias);\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"public function getAlias() {\n\t\treturn $this->site_alias;\n\t}",
"public function setAllowAlias($var) {}",
"public function setAlias(string $alias)\n\t{\n\t\t$this->addKeyValue('alias', $alias); \n\n\t}",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"function setServerName($server_name = null) {\n $http = empty($_SERVER['HTTPS']) ? 'http://' : 'https://';\n if (isSet($_SERVER['SERVER_NAME'])) {\n $server_name = str_replace(array('http://', 'https://'), '', $_SERVER['SERVER_NAME']);\n }\n if (empty($server_name)) {\n $file = WWW_ROOT . 'serw_name.txt';\n $server_name = file_get_contents($file);\n\n $_SERVER['SERVER_NAME'] = $http . $server_name;\n }\n if (!defined('FULL_BASE_URL')) {\n define('FULL_BASE_URL', $http . $server_name);\n }\n\n if (!defined('SURE_BASE_URL')) {\n define('SURE_BASE_URL', $server_name);\n }\n Configure::write('App.SERVER_NAME', $server_name);\n}",
"public function setAlias($alias) {\n $this->alias = $alias;\n }",
"public function setServer($server)\n {\n $this->server = (string)$server;\n }",
"public function setServer($server) {\n $this->server = $server;\n }",
"public function setHost()\n {\n $this->host = Config::get('smsglobal.host');\n }",
"function drush_backend_generate_sitealias($backend_options) {\n // Ensure default values.\n $backend_options += [\n 'remote-host' => NULL,\n 'remote-user' => NULL,\n 'ssh-options' => NULL,\n 'drush-script' => NULL,\n 'env-vars' => NULL\n ];\n return [\n 'remote-host' => $backend_options['remote-host'],\n 'remote-user' => $backend_options['remote-user'],\n 'ssh-options' => $backend_options['ssh-options'],\n '#env-vars' => $backend_options['env-vars'],\n 'path-aliases' => [\n '%drush-script' => $backend_options['drush-script'],\n ],\n ];\n}",
"function setUseAlias($useAlias);",
"private function setName() {\n\t\t$this->strName = $_SERVER[\"SERVER_NAME\"];\n\t}",
"private function assignWebsiteURL() {\n if(isset($_SERVER['HTTPS'])){\n $protocol = ($_SERVER['HTTPS'] && $_SERVER['HTTPS'] != \"off\") ? \"https\" : \"http\";\n }else{\n $protocol = 'http';\n }\n $this->websiteURL = $protocol . \"://\" . $_SERVER['HTTP_HOST'];\n }",
"public static function setSERVER(string $name, $value)\n\t{\n\t\tself::setVar($name, 'server', $value);\n\t}",
"public function setActiveServer( $server ) {\n\t\t$this->active_server = $server;\n\t}",
"public function setExchangeAlias($val)\n {\n $this->_propDict[\"exchangeAlias\"] = $val;\n return $this;\n }",
"public function setAlias(array $alias);",
"function alias()\n {\n global $W_SES ;\n return $W_SES['alias'] ;\n }",
"public function setServer(Server $server);",
"function setHost($value) {\n $this->host = $value;\n }",
"public function setServer($sAddress) {\n $this->m_aSocketInfo ['RemoteIP'] = $sAddress;\n }"
] | [
"0.752813",
"0.69539523",
"0.6725019",
"0.608797",
"0.5961817",
"0.59580016",
"0.5887538",
"0.5807962",
"0.5807962",
"0.578548",
"0.57651544",
"0.57481885",
"0.5678979",
"0.56698596",
"0.564419",
"0.5616146",
"0.5579982",
"0.55680114",
"0.5503547",
"0.54597217",
"0.54278797",
"0.54235363",
"0.54055315",
"0.54023963",
"0.53945076",
"0.5380909",
"0.536839",
"0.5350595",
"0.5342618",
"0.5297402"
] | 0.8103009 | 0 |
Sets the server name of webbased access. | function set_web_server_name($name, $server_name)
{
clearos_profile(__METHOD__, __LINE__);
Validation_Exception::is_valid($this->validate_web_server_name($server_name));
$this->_set_parameter($name, 'WebServerName', $server_name);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private function setName() {\n\t\t$this->strName = $_SERVER[\"SERVER_NAME\"];\n\t}",
"function set_web_server_name_alternate($name, $server_name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_name($server_name));\n\n $this->_set_parameter($name, 'WebServerNameAlternate', $server_name);\n }",
"function setServerName($server_name = null) {\n $http = empty($_SERVER['HTTPS']) ? 'http://' : 'https://';\n if (isSet($_SERVER['SERVER_NAME'])) {\n $server_name = str_replace(array('http://', 'https://'), '', $_SERVER['SERVER_NAME']);\n }\n if (empty($server_name)) {\n $file = WWW_ROOT . 'serw_name.txt';\n $server_name = file_get_contents($file);\n\n $_SERVER['SERVER_NAME'] = $http . $server_name;\n }\n if (!defined('FULL_BASE_URL')) {\n define('FULL_BASE_URL', $http . $server_name);\n }\n\n if (!defined('SURE_BASE_URL')) {\n define('SURE_BASE_URL', $server_name);\n }\n Configure::write('App.SERVER_NAME', $server_name);\n}",
"public static function setSERVER(string $name, $value)\n\t{\n\t\tself::setVar($name, 'server', $value);\n\t}",
"public function setServerName($val)\n {\n $this->_propDict[\"serverName\"] = $val;\n return $this;\n }",
"function set_web_server_alias($name, $server_alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));\n\n $this->_set_parameter($name, 'WebServerAlias', $server_alias);\n }",
"protected function setServer()\n {\n if (Arr::get($this->config, 'sandbox', false)) {\n $this->serverUrl = self::SERVER_SANDBOX_URL;\n } else {\n $this->serverUrl = self::SERVER_URL;\n }\n }",
"public function setServerDefault($name, $value) {\n\t\t$this->_server_defaults[$name] = $value;\n\t}",
"public function setServerFilename(string $serve_filename): void\n {\n $this->serve_filename = $serve_filename;\n }",
"public function setServer($server)\n {\n $this->_url = 'http://' . $server;\n }",
"public function setServer(string $serverName){\n\t\t//IPSLog(\"Starte Funktion : \", 'setServer');\n\t\t$which_key = \"FriendlyName\";\n\t\t$which_value = $serverName;\n\t\t$array = $this->getvalue(\"Ceol_ServerArray\");\n\t\t$Server_Array = unserialize($array);\n\t\t$key = $this->search_key($which_key, $which_value, $Server_Array);\n\n\t\t$Server_Array[$key]['ServerActiveIcon'] = \"image/button_ok_blue_80x80.png\";\n\t\t$ServerIP = $Server_Array[$key]['ServerIP'];\n\t\t$ServerPort = $Server_Array[$key]['ServerPort'];\n\t\t$friendlyName = $Server_Array[$key]['FriendlyName'];\n\t\t$ServerServiceType = $Server_Array[$key]['ServerServiceType'];\n\t\t$ServerContentDirectory = $Server_Array[$key]['ServerContentDirectory'];\n\t\t$ServerActiveIcon = $Server_Array[$key]['ServerActiveIcon'];\n\t\t$ServerIconURL = $Server_Array[$key]['IconURL'];\n\t\t$this->SetValue(\"Ceol_ServerIP\", $ServerIP);\n\t\t$this->SetValue(\"Ceol_ServerPort\", $ServerPort);\n\t\t$this->SetValue(\"Ceol_ServerName\", $friendlyName);\n\t\t$this->SetValue(\"Ceol_ServerKey\", $key);\n\t\t//SetValue(UPNP_Server_ServiceType, $ServerServiceType);\n\t\t$this->SetValue(\"Ceol_ServerContentDirectory\", $ServerContentDirectory);\n\t\t$this->SetValue(\"Ceol_ServerIcon\", $ServerIconURL);\n\t\treturn $key;\n\t}",
"public function setServer($server);",
"function get_servername() {return $this->a_servername;}",
"public function setServer($server)\n {\n $this->server = (string)$server;\n }",
"public function setServer($server) {\n $this->server = $server;\n }",
"public function setServerName($serverName)\n {\n if (!($serverName instanceof ServerNameProperty)) {\n $serverName = new ServerNameProperty($serverName);\n }\n\n $this->addProperty(ServerNameProperty::NAME, $serverName, $this->properties);\n\n return $this;\n }",
"protected function setSiteName( $siteName )\n {\n $this->siteName = $siteName;\n }",
"public function setSiteName($sitename);",
"public function setServer(Server $server);",
"function set_web_server_alias_alternate($name, $server_alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));\n\n $this->_set_parameter($name, 'WebServerAliasAlternate', $server_alias);\n }",
"public function setAllowedServer($value)\n {\n $this->ionOptionsXS['allowed-server'] = $value;\n }",
"public function getServerName()\n\t{\n\t\treturn craft()->request->getServerName();\n\t}",
"public function onServerStart()\n {\n ini_set('session.name', $this->sessionName);\n }",
"public function serverName(string|null $value): void;",
"public function server($name = null) {\n\t\treturn $name ? $_SERVER[$name] : $_SERVER;\n\t}",
"function set_web_access($name, $access)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n // Validate\n // --------\n Validation_Exception::is_valid($this->validate_web_access($access));\n\n // If web access is ALL, check e-mail restricts access\n $prevent = TRUE;\n if ((int)$access == self::ACCESS_LAN) {\n $share = $this->get_share($name);\n if (isset($share['EmailRestrictAccess']) && $share['EmailRestrictAccess'])\n $prevent = FALSE;\n if (!isset($share['EmailEnabled']) || !$share['EmailEnabled'])\n $prevent = FALSE;\n if (!isset($share['WebEnabled']) || !$share['WebEnabled'])\n $prevent = FALSE;\n if (isset($share['WebReqAuth']) && $share['WebReqAuth'])\n $prevent = FALSE;\n if ((!isset($share['WebPhp']) || !$share['WebPhp']) && (!isset($share['WebCgi']) || !$share['WebCgi']))\n $prevent = FALSE;\n } else {\n $prevent = FALSE;\n }\n\n if ($prevent)\n throw new Engine_Exception(FLEXSHARE_LANG_WARNING_CONFIG, COMMON_WARNING);\n\n $this->_set_parameter($name, 'WebAccess', $access);\n }",
"public function getServerName();",
"public function serverName():string\n {\n return $_SERVER['SERVER_NAME'];\n }",
"public function getName()\r\n {\r\n return $this->_serverName;\r\n }",
"public function getServerName()\n {\n return $_SERVER['SERVER_NAME'];\n }"
] | [
"0.7662646",
"0.7504614",
"0.7131679",
"0.70602906",
"0.67936766",
"0.67184114",
"0.65521383",
"0.6390707",
"0.63707304",
"0.6327512",
"0.63195026",
"0.62679595",
"0.619021",
"0.6139476",
"0.6124813",
"0.6034462",
"0.598149",
"0.5878315",
"0.58728194",
"0.58712226",
"0.5863651",
"0.5861927",
"0.58367234",
"0.5819582",
"0.58157754",
"0.581352",
"0.5803352",
"0.57820207",
"0.5764384",
"0.57351696"
] | 0.7941652 | 0 |
Sets the alternate server name of webbased access. | function set_web_server_name_alternate($name, $server_name)
{
clearos_profile(__METHOD__, __LINE__);
Validation_Exception::is_valid($this->validate_web_server_name($server_name));
$this->_set_parameter($name, 'WebServerNameAlternate', $server_name);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_web_server_alias_alternate($name, $server_alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));\n\n $this->_set_parameter($name, 'WebServerAliasAlternate', $server_alias);\n }",
"function set_web_server_alias($name, $server_alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_alias($server_alias));\n\n $this->_set_parameter($name, 'WebServerAlias', $server_alias);\n }",
"function set_web_server_name($name, $server_name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_name($server_name));\n\n $this->_set_parameter($name, 'WebServerName', $server_name);\n }",
"private function setName() {\n\t\t$this->strName = $_SERVER[\"SERVER_NAME\"];\n\t}",
"function setServerName($server_name = null) {\n $http = empty($_SERVER['HTTPS']) ? 'http://' : 'https://';\n if (isSet($_SERVER['SERVER_NAME'])) {\n $server_name = str_replace(array('http://', 'https://'), '', $_SERVER['SERVER_NAME']);\n }\n if (empty($server_name)) {\n $file = WWW_ROOT . 'serw_name.txt';\n $server_name = file_get_contents($file);\n\n $_SERVER['SERVER_NAME'] = $http . $server_name;\n }\n if (!defined('FULL_BASE_URL')) {\n define('FULL_BASE_URL', $http . $server_name);\n }\n\n if (!defined('SURE_BASE_URL')) {\n define('SURE_BASE_URL', $server_name);\n }\n Configure::write('App.SERVER_NAME', $server_name);\n}",
"public static function setSERVER(string $name, $value)\n\t{\n\t\tself::setVar($name, 'server', $value);\n\t}",
"protected function setServer()\n {\n if (Arr::get($this->config, 'sandbox', false)) {\n $this->serverUrl = self::SERVER_SANDBOX_URL;\n } else {\n $this->serverUrl = self::SERVER_URL;\n }\n }",
"public function setServer($server)\n {\n $this->_url = 'http://' . $server;\n }",
"public function setServerName($val)\n {\n $this->_propDict[\"serverName\"] = $val;\n return $this;\n }",
"public function setServerDefault($name, $value) {\n\t\t$this->_server_defaults[$name] = $value;\n\t}",
"public function setServer(string $serverName){\n\t\t//IPSLog(\"Starte Funktion : \", 'setServer');\n\t\t$which_key = \"FriendlyName\";\n\t\t$which_value = $serverName;\n\t\t$array = $this->getvalue(\"Ceol_ServerArray\");\n\t\t$Server_Array = unserialize($array);\n\t\t$key = $this->search_key($which_key, $which_value, $Server_Array);\n\n\t\t$Server_Array[$key]['ServerActiveIcon'] = \"image/button_ok_blue_80x80.png\";\n\t\t$ServerIP = $Server_Array[$key]['ServerIP'];\n\t\t$ServerPort = $Server_Array[$key]['ServerPort'];\n\t\t$friendlyName = $Server_Array[$key]['FriendlyName'];\n\t\t$ServerServiceType = $Server_Array[$key]['ServerServiceType'];\n\t\t$ServerContentDirectory = $Server_Array[$key]['ServerContentDirectory'];\n\t\t$ServerActiveIcon = $Server_Array[$key]['ServerActiveIcon'];\n\t\t$ServerIconURL = $Server_Array[$key]['IconURL'];\n\t\t$this->SetValue(\"Ceol_ServerIP\", $ServerIP);\n\t\t$this->SetValue(\"Ceol_ServerPort\", $ServerPort);\n\t\t$this->SetValue(\"Ceol_ServerName\", $friendlyName);\n\t\t$this->SetValue(\"Ceol_ServerKey\", $key);\n\t\t//SetValue(UPNP_Server_ServiceType, $ServerServiceType);\n\t\t$this->SetValue(\"Ceol_ServerContentDirectory\", $ServerContentDirectory);\n\t\t$this->SetValue(\"Ceol_ServerIcon\", $ServerIconURL);\n\t\treturn $key;\n\t}",
"public function setServer($server);",
"function get_servername() {return $this->a_servername;}",
"function set_web_directory_alias_alternate($name, $alias)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_directory_alias($alias));\n\n $this->_set_parameter($name, 'WebDirectoryAliasAlternate', $alias);\n }",
"public function setServer($server)\n {\n $this->server = (string)$server;\n }",
"public function setServer($server) {\n $this->server = $server;\n }",
"public function alternateName($alternateName)\n {\n return $this->setProperty('alternateName', $alternateName);\n }",
"public function alternateName($alternateName)\n {\n return $this->setProperty('alternateName', $alternateName);\n }",
"public function alternateName($alternateName)\n {\n return $this->setProperty('alternateName', $alternateName);\n }",
"public function alternateName($alternateName)\n {\n return $this->setProperty('alternateName', $alternateName);\n }",
"public function alternateName($alternateName)\n {\n return $this->setProperty('alternateName', $alternateName);\n }",
"public function getServer (mixed $name, mixed $default = NULL)\n {\n }",
"public function setServerFilename(string $serve_filename): void\n {\n $this->serve_filename = $serve_filename;\n }",
"public function setSiteName($sitename);",
"public function setHostName(string $value)\n {\n $this->hostName = $value ?: $this->getHostName();\n }",
"public function setActiveServer( $server ) {\n\t\t$this->active_server = $server;\n\t}",
"function setServers()\n\t{\t\n\t\tglobal $db;\n\t\t\t\n\t\t$conn_city \t\t= ((in_array(strtolower($this->data_city), $this->dataservers)) ? strtolower($this->data_city) : 'remote');\n\t\t\n\t\t$this->conn_iro \t\t= $db[$conn_city]['iro']['master'];\n\t\t$this->conn_fin \t\t= $db[$conn_city]['fin']['master'];\n\t\t$this->conn_national\t= $db['db_national'];\t \n\t}",
"private function migrateSiteName() {\n\t\taioseo()->options->social->facebook->general->siteName = '#site_title';\n\t}",
"public function server($name = null) {\n\t\treturn $name ? $_SERVER[$name] : $_SERVER;\n\t}",
"public function setServer(Server $server);"
] | [
"0.7291454",
"0.6807305",
"0.67852366",
"0.6652062",
"0.64079815",
"0.61787313",
"0.60618114",
"0.6000399",
"0.59541035",
"0.59255594",
"0.59252894",
"0.5904558",
"0.59023887",
"0.5797001",
"0.5726826",
"0.56609213",
"0.55912405",
"0.55912405",
"0.55912405",
"0.55912405",
"0.55912405",
"0.549262",
"0.5472409",
"0.5456956",
"0.540781",
"0.5406725",
"0.53681123",
"0.536791",
"0.53475446",
"0.5344274"
] | 0.8232847 | 0 |
Sets web folder layout | function set_web_folder_layout($name, $layout)
{
clearos_profile(__METHOD__, __LINE__);
Validation_Exception::is_valid($this->validate_web_folder_layout($layout));
$this->_set_parameter($name, 'WebFolderLayout', $layout);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected function setWebRoot() {\n $web_directory = empty($this->config['web_directory']) ? 'web' : $this->config['web_directory'];\n $this->webRoot = $this->getInstallDir() . trim($web_directory, '/') . '/';\n $this->webRoot = str_replace('//', '/', $this->webRoot);\n }",
"public function setLayout()\n\t{\n \t$this->_helper->layout->setLayout('admin');\t\n\t}",
"protected function setupLayout()\n\t{\n\t\t//if (!is_null($this->layout))\n\t\t//{\n\t\t//\t$this->layout = View::make($this->layout, array('BaseUrl'=>URL::to('/')));\n\t\t//}\n\t}",
"public function init() \n\t{\n\t\tif(!Yii::app()->user->isGuest) {\n\t\t\tif(in_array(Yii::app()->user->level, array(1,2))) {\n\t\t\t\t$arrThemes = $this->currentTemplate('admin');\n\t\t\t\tYii::app()->theme = $arrThemes['folder'];\n\t\t\t\t$this->layout = $arrThemes['layout'];\n\t\t\t}\n\t\t} else\n\t\t\t$this->redirect(Yii::app()->createUrl('site/login'));\n\t}",
"public function setWebPath()\n {\n $folder_array = explode(self::DS, $this->getUploadPath());\n $this->web_path = array_pop($folder_array);\n }",
"public function setLayout($name)\n\t{\n\t\t$path = WEB_PATH . DS . 'layout' . DS . $name . '.php';\n\n\t\tif(file_exists($path))\n\t\t{\n\t\t\t$this->_path['layout'] = $path;\n\t\t}\n\t}",
"public function index(){\r\n\t\t\t$this->middle = 'adminLayout';\r\n\t\t\t//On appelle le layout\r\n\t\t \t$this->layout();\r\n\t\t}",
"public function setFolder() {\n $fb = str_replace('index.php', '', $_SERVER['SCRIPT_FILENAME']);\n $folder = $fb . 'media/blog/';\n if (is_dir($folder . date('Y'))) {\n $folder = $folder . date('Y') . '/';\n }\n else {\n mkdir($folder . date('Y'));\n $folder = $folder . date('Y') . '/';\n }\n if (is_dir($folder . date('m'))) {\n $folder = $folder . date('m') . '/';\n }\n else {\n mkdir($folder . date('m'));\n $folder = $folder . date('m') . '/';\n }\n $this->folder = $folder;\n $this->folder_clean = substr(str_replace($fb, '', $folder), 0, -1);\n }",
"public function layouts() {\n\t\trequire_once FUSION_BUILDER_PLUGIN_DIR . 'inc/admin-screens/layouts.php';\n\t}",
"function index() {\n\t\t$this -> layout = \"Hondey/login\";\n\t}",
"public function initialize() {\n $this->view->setViewsDir(__VIEW_HOME__);\n }",
"public function admin_fileBrowser() {\n\t\t$this -> layout = \"Ez.file_browser\";\n\t\tApp::uses('Folder', 'Utility');\n\t\tApp::uses('File', 'Utility');\n\t\t$folder = new Folder(WWW_ROOT . DS . \"wysiwyg\");\n\t\t$this -> set(\"folder\", $folder -> read());\n\t\t$this -> set(\"folderPath\", \"/wysiwyg\");\n\t}",
"protected function setupLayout()\n {\n if (!is_null($this->layout)) {\n $this->layout = View::make($this->layout);\n }\n\n \\Breadcrumbs::setListElement('ol');\n \\Breadcrumbs::addCssClasses('breadcrumb');\n \\Breadcrumbs::removeCssClasses('breadcrumbs');\n \\Breadcrumbs::setDivider(null);\n $this->getThemeConfig();\n\n $navtools = Event::fire('frontend.navbar.create');\n $navtools_html = $footeritems_html = $headeritems_html = '';\n \\View::share('navbar', '');\n \\View::share('header', '');\n \\View::share('footer', '');\n foreach ($navtools as $w) {\n foreach ($w as $o) {\n $navtools_html .= View::make($o);\n }\n }\n\n $footeritems = Event::fire('frontend.footer.create');\n\n foreach ($footeritems as $w) {\n foreach ($w as $o) {\n $footeritems_html .= View::make($o);\n }\n }\n\n $headeritems = Event::fire('frontend.header.create');\n\n\n foreach ($headeritems as $w) {\n foreach ($w as $o) {\n $headeritems_html .= View::make($o);\n }\n }\n\n Config::set('theme.menus', Event::fire('menu.positions.collect'));\n\n //get the layout for the current route\n //load the default if no layout specified\n\n\n// ll($footeritems_html);\n\n if (\\View::exists('anastasia::navbar')) {\n $navtools = \\View::make('navbar')->with('navtools', $navtools_html);\n\n \\View::share('navbar', (string)$navtools);\n }\n if (\\View::exists('header')) {\n $headeritems = \\View::make('header')->with('headeritems', $headeritems_html);\n \\View::share('header', (string)$headeritems);\n }\n if (\\View::exists('footer')) {\n $footeritems = \\View::make('footer')->with('footeritems', $footeritems_html);\n \\View::share('footer', (string)$footeritems);\n }\n\n\n\n }",
"function beforeRender() {\n\t\tApp::build(array(\n\t\t\t'views' => CARACOLE.'plugins'.DS.'caracole_documents'.DS.'views'.DS\n\t\t));\n\t\t$this->layoutPath = $this->params['url']['ext'];\n\t\t$this->layout = empty($this->params['admin']) ? 'default' : 'admin';\n\t\t$this->viewPath = 'documents/'.$this->params['url']['ext'];\n\t}",
"public function setLayoutDirectory($dir)\n\t{\n\t\tPathManager::setViewLayoutDirectory($dir);\n\t}",
"protected function setupLayout()\n\t{\n\t\t/** Start adding styles **/\n\t\tAsset::container('header')->add('bootstrap-css', 'plugins/bootstrap/css/bootstrap.min.css');\n\t\tAsset::container('header')->add('fontawesome-css', 'plugins/font-awesome/css/font-awesome.min.css');\n\t\tAsset::container('header')->add('sb-admin-css', 'css/base/sb-admin.css');\n\t\tAsset::container('header')->add('notify-css', 'css/base/notify.css');\n\t\n\t\tif ($this->layout != 'layout.auth' && $this->layout != 'layout.subscribe') {\n\t\t\tAsset::container('header')->add('datepicker-css', 'plugins/datepicker/css/datepicker.css');\n\t\t\tAsset::container('header')->add('bootstrap-notify-master-css', 'plugins/bootstrap-notify-master/css/bootstrap-notify.css');\n\t\t\tAsset::container('header')->add('datatables-css', 'plugins/datatable/media/css/demo_table.css');\n\t\t\tAsset::container('header')->add('custom-datatable-css', 'plugins/datatable/media/css/custom_datatable.css');\n\t\t\tAsset::container('header')->add('jquery-ui-css', 'plugins/jquery-ui/css/jquery-ui.css');\n\t\t}\n\t\telse {\n\t\t\tAsset::container('header')->add('auth-css', 'css/auth/auth.css');\n\t\t\tAsset::container('header')->add('the-big-picture-css', 'css/auth/the_big_picture.css');\n\t\t}\n\n\t\t/** End adding styles **/\n\n\n\n\t\t/** Start adding javascripts **/\n\t\tAsset::container('footer')->add('jquery', 'js/core/jquery-1.10.2.min.js');\n\t\tAsset::container('footer')->add('jquery-ui-1.9.2-js', 'plugins/jquery-ui/js/jquery-ui-1.9.2.custom.min.js');\n\t\tAsset::container('footer')->add('bootstrap-js', 'plugins/bootstrap/js/bootstrap.min.js');\n\n\t\tif ($this->layout != 'layout.auth') {\n\t\t\tAsset::container('footer')->add('angular-js', 'js/core/angular.js');\n\t\t\tAsset::container('footer')->add('datepicker-js', 'plugins/datepicker/js/bootstrap-datepicker.js');\n\t\t\tAsset::container('footer')->add('bootstrap-notify-master-js', 'plugins/bootstrap-notify-master/js/bootstrap-notify.js');\n\t\t\tAsset::container('footer')->add('jquery-dataTables-js', 'plugins/datatable/media/js/jquery.dataTables.js');\n\t\t\tAsset::container('footer')->add('numeric-input-js', 'js/core/numericInput.min.js');\n\t\t}\n\t\t/** End adding javascripts **/\n\n\t\tif (Sentry::check()) {\n\t\t\tView::share('current_clients', PracticeProClient::getAllCurrentClients());\n\t\t}\n\n\t\tView::share('user', $this->user);\n\n\t\t$this->layout = View::make($this->layout);\n\t}",
"protected function create_main_layout()\n {\n if (!file_exists($path = resource_path(\"/views/layouts\"))) {\n mkdir($path, 0777, true);\n }\n\n if (!file_exists($path = resource_path(\"/views/layouts/main.blade.php\"))) {\n file_put_contents(base_path(\"/resources/views/layouts/main.blade.php\"), $this->getBladeStub('main_blade'));\n }\n }",
"protected function setupLayout()\n {\n View::composer('layouts.master', function($view){\n $view->with('status', Session::get('status'));\n });\n\n\t\tif ( ! is_null($this->layout))\n\t\t{\n $this->layout = View::make($this->layout)\n ->with('status', Session::get('status'));\n\t\t}\n\t}",
"public function home() {\n\t$this->layout = \"shop_main\";\n\t$this->set('page_type','home');\n}",
"protected function setupLayout()\n {\n if ( ! is_null($this->layout))\n {\n $this->layout = View::make($this->layout);\n $this->layout->title = Config::get('blog.name');\n $this->layout->tagline = Config::get('blog.tagline');\n\n if(\\Auth::check()) {\n $this->layout->user = \\Auth::getUser();\n }\n }\n }",
"protected function setLayout () {\n\t\tif ($this->_getParam('catalog')) {\n\t\t\t$config = Zend_Registry::getInstance()->config;\n\t\t\tif (count($config->catalog->layouts)) {\n\t\t\t\t$catalogId = $this->_helper->osidId->fromString($this->_getParam('catalog'));\n\t\t\t\tforeach ($config->catalog->layouts as $layoutConfig) {\n\t\t\t\t\tif ($catalogId->isEqual(new phpkit_id_URNInetId($layoutConfig->catalog_id))) {\n\t\t\t\t\t\t$this->_helper->layout()->setLayout($layoutConfig->layout);\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}",
"protected function _getLayout()\n {\n return $this->rootPath . DIRECTORY_SEPARATOR . 'views' . DIRECTORY_SEPARATOR . 'layout.php';\n }",
"protected function addOverrideViewPath()\n {\n if (Yii::$app instanceof WebApplication) {\n $view = Yii::$app->getView();\n if ($view->theme === null) {\n $view->theme = Yii::createObject(['class' => 'yii\\base\\Theme', 'pathMap' => []]);\n }\n $view->theme->pathMap[\"@{$this->vendor}/\" . $this->getUniqueId()] = realpath(Yii::$app->basePath.'/modules/' . $this->getUniqueId());\n }\n }",
"protected function setupLayout(){\n\t\tif ( ! is_null($this->layout))\n\t\t{\n\t\t\t$this->layout = View::make($this->layout);\n\t\t}\n\t}",
"protected function setupLayout() {\r\n\r\n if (null !== $this->layout) {\r\n $this->changeLayout($this->layout);\r\n }\r\n }",
"function admin_login() {\n $this->layout = 'admin_login';\n }",
"private function getViewFolder()\n {\n $guard = substr($this->getGuard(), 0, strpos(getenv('guard'), '.'));\n return config(\"theme.themes.\" . $guard . \".view\", config('theme.themes.default.view', $guard));\n }",
"public function setLayout($layout, $fullpath = false)\n {\n if ( !empty($layout) && !$fullpath){\n $this->_layout = TO_ROOT . \"/subtemplates/{$layout}_layout.tpl.php\";\n } else {\n $this->_layout = $layout;\n }\n }",
"public function index()\n {\n $css = array('main.css', 'project.css');\n\n require ROOT . 'views/header.php';\n require ROOT . 'views/projects.php';\n require ROOT . 'views/footer.php';\n }",
"protected function setupLayout()\n\t{\n\t\tif ( ! is_null($this->layout))\n\t\t{\n\n\t\t\t$menus = DB::table('main_menu')\t\t\t\t\t\n\t\t\t\t\t->where('is_visible', true)\n ->orderBy('index') \n ->get();\n \n\t\t\t$this->layout = View::make($this->layout)->nest('menu', 'menus.view', array(\n\t\t\t\t'menus' => $menus\n\t\t\t));\n\t\t\t\n\t\t}\n\t}"
] | [
"0.6396316",
"0.6346562",
"0.6252494",
"0.617237",
"0.6166799",
"0.6160635",
"0.6116422",
"0.6112932",
"0.59635305",
"0.59615713",
"0.5876196",
"0.585649",
"0.58561987",
"0.5814608",
"0.57871306",
"0.5724514",
"0.5712324",
"0.5709541",
"0.57075983",
"0.5706857",
"0.56572855",
"0.5654359",
"0.56515384",
"0.56423354",
"0.5632479",
"0.56241894",
"0.5610534",
"0.55914056",
"0.5582557",
"0.5578254"
] | 0.7068048 | 0 |
Sets whether to follow sym links. | function set_web_follow_symlinks($name, $follow_symlinks)
{
clearos_profile(__METHOD__, __LINE__);
$this->_set_parameter($name, 'WebFollowSymLinks', $follow_symlinks);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function TrackLinks($tracklinks = false)\r\n {\r\n $this->tracklinks = (bool)$tracklinks;\r\n }",
"function TrackLinks($tracklinks=false)\n\t{\n\t\t$this->tracklinks = (bool)$tracklinks;\n\t}",
"public function setUnfurlLinks($value)\n {\n $this->unfurlLinks = (boolean) $value;\n }",
"public function setFollowLocation(/* boolean */ $really);",
"public function setFollowLocation(bool $follow): void\n {\n $this->followLocation = $follow;\n }",
"public function setLinkAttribute($value)\n {\n $this->attributes['link'] = strtolower($value);\n }",
"function setLink($value) {\n $this->link = $value;\n }",
"public function setFollowRedirects(bool $followRedirects): void {\r\n $this->followRedirects = $followRedirects;\r\n }",
"public function setBypassWalk()\n {\n $this->bypassWalk[count($this->bypassWalk) - 1] = true;\n }",
"function ForceLinkChecks($forcechecks=false)\n\t{\n\t\t$this->forcechecks = (bool)$forcechecks;\n\t}",
"static public function setLinks($links) {\n self::$links = $links;\n }",
"function setLinks( $links )\n {\n $this->links = $links;\n }",
"public function setLinks($links) {\n $this->links = $links;\n }",
"public function setLinks($links) {\n $this->links = $links;\n }",
"public function setLinks($links) {\n $this->links = $links;\n }",
"protected function setLink($name, $method){\n $this->links[$name] = $method;\n }",
"function setLinks($links) \n {\n $this->linkValues = $links;\n }",
"function use_link_brackets($flag)\r\n {\r\n $this->link_brackets = $flag;\r\n }",
"public function setLinkAttribute($value)\n {\n $this->attributes['link'] = SamirzValidator::sanitizeUrl($value)[0];\n }",
"function plugin_enablestatechange_links2($enable)\n{\n global $_TABLES;\n\n $is_enabled = $enable ? 1 : 0;\n\n // toggle links feeds\n DB_query (\"UPDATE {$_TABLES['syndication']} SET is_enabled = $is_enabled WHERE type = 'links'\");\n}",
"function setLinkAttribute($name, $value);",
"function toggle_link($notify) {\n\n if ($notify == TRUE) {\n return FALSE;\n } elseif ($notify == FALSE) {\n return TRUE;\n }\n}",
"protected function _createSymbolicLinks()\r\n\t{\r\n\t\t/**\r\n\t\t * Dojo\r\n\t\t */\r\n\t\tif($this->_config->dojo->path) {\r\n\t\t\t$dojoLibPath = ROOT_PATH . DIRECTORY_SEPARATOR .'public';\r\n\t\t\t$dojoLibPath .= DIRECTORY_SEPARATOR . 'scripts';\r\n\t\t\t$dojoLibPath .= DIRECTORY_SEPARATOR . 'dojo';\r\n\t\t\t$dojoLibPath .= DIRECTORY_SEPARATOR . 'library';\r\n\t\t\t\r\n\t\t\tif(!is_dir($dojoLibPath)) {\r\n\t\t\t\tif($this->_isWindows()){\r\n\t\t\t\t\t$call = 'mklink /D ' . $dojoLibPath . ' ' . $this->_config->dojo->path;\r\n \t\t\texec($call);\r\n \t\t} else {\r\n\t\t\t\t\t$call = 'ln -s ' . $this->_config->dojo->path . ' ' . $dojoLibPath;\r\n \t\t\tshell_exec($call);\r\n \t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\t/**\r\n\t\t * Tinymce\r\n\t\t */\r\n\t\tif(isset($this->_config->tinymce->path)) {\r\n\t\t\tif($this->_config->tinymce->path) {\r\n\t\t\t\t\r\n\t\t\t\t$tinymceLibPath = ROOT_PATH . DIRECTORY_SEPARATOR .'public';\r\n\t\t\t\t$tinymceLibPath .= DIRECTORY_SEPARATOR . 'scripts';\r\n\t\t\t\t$tinymceLibPath .= DIRECTORY_SEPARATOR . 'tiny_mce';\r\n\t\t\t\t\r\n\t\t\t\tif(!is_dir($tinymceLibPath)) {\r\n\t\t\t\t\tif($this->_isWindows()){\r\n\t\t\t\t\t\t$call = 'mklink /D ' . $tinymceLibPath . ' ' . $this->_config->tinymce->path;\r\n\t \t\t\texec($call);\r\n\t \t\t} else {\r\n\t\t\t\t\t\t$call = 'ln -s ' . $this->_config->tinymce->path . ' ' . $tinymceLibPath;\r\n\t \t\t\tshell_exec($call);\r\n\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}",
"public function setShowUrl($bool)\n {\n if ($bool && !Mage::getStoreConfig('carriers/dpdparcelshops/google_maps_display'))\n $this->_showurl = $bool;\n return;\n }",
"public function setUseLink($v)\n\t{\n\t\tif ($v !== null) {\n\t\t\t$v = (string) $v;\n\t\t}\n\n\t\tif ($this->use_link !== $v) {\n\t\t\t$this->use_link = $v;\n\t\t\t$this->modifiedColumns[] = UsersPeer::USE_LINK;\n\t\t}\n\n\t\treturn $this;\n\t}",
"public function setDefaultShareLinkType($value)\n {\n $this->setProperty(\"DefaultShareLinkType\", $value, true);\n }",
"public function setDefaultShareLinkPermission($value)\n {\n $this->setProperty(\"DefaultShareLinkPermission\", $value, true);\n }",
"public function setCanSendLink($value)\n {\n $this->setProperty(\"CanSendLink\", $value, true);\n }",
"protected function setFacebook($value = true)\n {\n $this->_is_facebook = $value;\n }",
"public function setFollowMode($follow_mode)\n {\n // Check mode\n if (!preg_match(\"/^[0-3]{1}$/\", $follow_mode)) return false;\n \n $this->UrlFilter->general_follow_mode = $follow_mode;\n return true;\n }"
] | [
"0.5989206",
"0.58353716",
"0.57011235",
"0.54899293",
"0.5428338",
"0.53226733",
"0.5270044",
"0.52600884",
"0.52216625",
"0.52140266",
"0.51910335",
"0.5138102",
"0.50923353",
"0.50923353",
"0.50923353",
"0.50358313",
"0.4996651",
"0.49658102",
"0.49616346",
"0.49127215",
"0.49099293",
"0.48992738",
"0.4855748",
"0.48505265",
"0.48055616",
"0.47820047",
"0.47808498",
"0.47620383",
"0.47536537",
"0.47491482"
] | 0.64702773 | 0 |
Sets an override flag to use custom port on the flexshare. | function set_web_override_port($name, $override_port, $port)
{
clearos_profile(__METHOD__, __LINE__);
if ($override_port && ($port == 80 || $port == 443))
throw new Engine_Exception(lang('flexshare_non_custom_port_warning'), CLEAROS_ERROR);
$shares = $this->_get_shares(self::TYPE_ALL);
$ssl = isset($shares[$name]['WebReqSsl']) ? $shares[$name]['WebReqSsl'] : FALSE;
$inuse_ports = array();
foreach ($shares as $share_name => $share) {
$ssl_for_share = isset($share['WebReqSsl']) ? $share['WebReqSsl'] : FALSE;
if (($name != $share_name) && ($ssl != $ssl_for_share))
$inuse_ports[] = $share['WebPort'];
}
if ($override_port && (in_array($port, $this->bad_ports) || in_array($port, $inuse_ports)))
throw new Validation_Exception(lang('flexshare_port_already_in_use'));
$this->_set_parameter($name, 'WebOverridePort', $override_port);
$this->_set_parameter($name, 'WebPort', $port);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_ftp_override_port($name, $override_port, $port)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if ($override_port && ($port == self::DEFAULT_PORT_FTP || $port == self::DEFAULT_PORT_FTPS))\n throw new Engine_Exception(lang('flexshare_non_custom_port_warning'), CLEAROS_ERROR);\n\n if ($override_port && ($port == 21 || $port == 990))\n throw new Engine_Exception(lang('flexshare_ftp_cannot_use_default_ports'), CLEAROS_ERROR);\n\n // Find all ports and see if any conflicts with n-1\n if ($override_port) {\n $shares = $this->_get_shares(self::TYPE_ALL);\n\n foreach ($shares as $share_name => $share) {\n if ($share_name != $name) {\n if ((int)$share[\"FtpPort\"] == ($port - 1)) {\n throw new Engine_Exception(lang('flexshare_ftp_port_conflict'), CLEAROS_ERROR);\n } else if (((int)$share[\"FtpPort\"] -1) == $port) {\n throw new Engine_Exception(lang('flexshare_ftp_port_conflict'), CLEAROS_ERROR);\n }\n }\n }\n }\n\n $this->_set_parameter($name, 'FtpOverridePort', $override_port);\n $this->_set_parameter($name, 'FtpPort', $port);\n }",
"public function setPort()\n {\n $this->port = Config::get('smsglobal.port');\n }",
"public function setAllowOverride($flag)\n {\n $this->allowOverride = (bool) $flag;\n }",
"public function setOverride(bool $override): self;",
"private function setPort($port)\n {\n $this->_port = $port;\n \n\treturn TRUE;\n }",
"public function setPort($port)\n {\n \t$this->port = $port;\n }",
"function validate_web_override_port($port)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (! Network_Utils::is_valid_port($port))\n return lang('flexshare_port_invalid');\n\n if ($port == self::DEFAULT_PORT_WEB)\n return lang('flexshare_non_custom_port_warning');\n }",
"public function setport($port)\n {\n $this->_port = $port;\n }",
"public function setOverride($override)\n {\n $this->override = (bool) $override;\n\n return $this;\n }",
"public function setPort($port)\n {\n // Check port\n if (!preg_match(\"#^[0-9]{1,5}$#\", $port)) return false;\n\n // Add port to the starting-URL\n $url_parts = PHPCrawlerUtils::splitURL($this->starting_url);\n $url_parts[\"port\"] = $port;\n $this->starting_url = PHPCrawlerUtils::buildURLFromParts($url_parts, true);\n \n return true;\n }",
"function validate_ftp_override_port($port)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (! Network_Utils::is_valid_port($port))\n return lang('flexshare_port_invalid');\n if (($port == self::DEFAULT_PORT_FTP) || ($port == self::DEFAULT_PORT_FTPS))\n return lang('flexshare_non_custom_port_warning');\n }",
"private function setPort($port){\n\n\t\t$this->phpMailer->Port = $port;\n\t\n\t}",
"public function setProxyPort($value) { $this->proxyPort = intval($value); }",
"public function setPort( $port = 21 )\n {\n $this->port = (int)$port;\n }",
"public function setPortInfo($var)\n {\n if ($var)\n {\n $this->db_row['port_info']=$var;\n return true;\n }\n else\n {\n return false;\n }\n }",
"public function setPort($nPort) {\n $this->m_aSocketInfo ['RemotePort'] = $nPort;\n }",
"public function bSetSocksPort($port=\"9000\",$exitnode=\"\"){\n\t\t\n\t\tif(!$this->aGetRouterDesc($exitnode))\n\t\t\treturn false;\n\t\t\n\t\t\n\t\t$aSocksPortList = $this->aGetSocksPort();\n\t\t\n\t\t\n\t\tif(count($aSocksPortList)==0){\n\t\t\tif(!$port) $port = 9000;\n\t\t\treturn $this->bSetConf(\"socksport=\\\"9000 ExitNode=$exitnode\\\"\");\n\t\t\t\n\t\t}\n\n\t\t$cmd=\"\";\n\t\t$find = false;\n\t\tfor($i=0;$i<count($aSocksPortList);$i++){\n\t\t\tif($aSocksPortList[$i]['port']==$port){\n\t\t\t\t$find = true;\n\t\t\t\t$cmd.=\" socksport=\\\"$port ExitNode=$exitnode\\\"\";\n\t\t\t}else\t\t\t\n\t\t\t\tif($aSocksPortList[$i]['port'])\n\t\t\t\t$cmd.=\" socksport=\\\"\".$aSocksPortList[$i]['port'].\" ExitNode=\".$aSocksPortList[$i]['exitnode'].\"\\\"\";\n\t\t}\n\t\t\n\t\tif(!$find){\n\t\t\tif(!$port) $port = 9000;\n\t\t\t$cmd.=\" socksport=\\\"$port ExitNode=$exitnode\\\"\";\n\t\t}\n\t\t\n\t\treturn $this->bSetConf($cmd);\n\t}",
"public function setAddress($host, $port);",
"public function setPort($port)\n {\n $this->port = $port === null ? null : (int)$port;\n }",
"public function setProtocol()\n {\n $this->protocol = strtolower(Config::get('smsglobal.protocol'));\n }",
"function default_port() {\n return 8983;\n }",
"function default_port() {\n return 8983;\n }",
"public function setShared($name, $flag)\n {\n $this->configure(['shared' => [$name => (bool) $flag]]);\n }",
"public function setMemcachePort($memcachePort) {\n\t\t$this->_memcachePort = (int)$memcachePort;\n\t}",
"public function setPort($value)\n {\n return $this->set('Port', $value);\n }",
"public function setPort($value)\n {\n return $this->set('Port', $value);\n }",
"public function setPort($value)\n {\n return $this->set('Port', $value);\n }",
"public function setPort($port) {\n $this->port = $port;\n return $this;\n }",
"public function setCustomDialerAppProtocol(?string $value): void {\n $this->getBackingStore()->set('customDialerAppProtocol', $value);\n }",
"public function setVar( $name, $value, $override = true )\n {\n if(isset($this->override[$name]))\n {\n return null;\n }\n else\n {\n if($override == false)\n {\n $this->override[$name] = true;\n }\n $this->config[$name] = $value;\n } \n }"
] | [
"0.6986275",
"0.62608707",
"0.60830843",
"0.5852413",
"0.5835859",
"0.58220714",
"0.5655161",
"0.56272995",
"0.5593717",
"0.5537694",
"0.5506833",
"0.5478862",
"0.545625",
"0.5370784",
"0.53563714",
"0.5326696",
"0.53027767",
"0.52816236",
"0.52114576",
"0.5156339",
"0.50973797",
"0.50973797",
"0.5075082",
"0.5049975",
"0.50374174",
"0.50374174",
"0.50374174",
"0.5034504",
"0.5033781",
"0.49927285"
] | 0.718305 | 0 |
Sets the realm name of webbased access. | function set_web_realm($name, $realm)
{
clearos_profile(__METHOD__, __LINE__);
// Validate
// --------
Validation_Exception::is_valid($this->validate_web_realm($realm));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function setRealm($realm);",
"function setRealm($realm) {\n\n $this->realm = $realm;\n\n }",
"public function setRealm($realm) {\n\n $this->realm = $realm;\n\n }",
"public function getRealm($realmName);",
"public function setKerberosRealm(?string $value): void {\n $this->getBackingStore()->set('kerberosRealm', $value);\n }",
"public function realm($realm)\n {\n $this->realm = $realm;\n\n return $this;\n }",
"public function setRealName($realName) {\n $this->realName = $realName;\n }",
"private function setName() {\n\t\t$this->strName = $_SERVER[\"SERVER_NAME\"];\n\t}",
"public function getRealm()\n {\n return $this->realm;\n }",
"function set_web_access($name, $access)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n // Validate\n // --------\n Validation_Exception::is_valid($this->validate_web_access($access));\n\n // If web access is ALL, check e-mail restricts access\n $prevent = TRUE;\n if ((int)$access == self::ACCESS_LAN) {\n $share = $this->get_share($name);\n if (isset($share['EmailRestrictAccess']) && $share['EmailRestrictAccess'])\n $prevent = FALSE;\n if (!isset($share['EmailEnabled']) || !$share['EmailEnabled'])\n $prevent = FALSE;\n if (!isset($share['WebEnabled']) || !$share['WebEnabled'])\n $prevent = FALSE;\n if (isset($share['WebReqAuth']) && $share['WebReqAuth'])\n $prevent = FALSE;\n if ((!isset($share['WebPhp']) || !$share['WebPhp']) && (!isset($share['WebCgi']) || !$share['WebCgi']))\n $prevent = FALSE;\n } else {\n $prevent = FALSE;\n }\n\n if ($prevent)\n throw new Engine_Exception(FLEXSHARE_LANG_WARNING_CONFIG, COMMON_WARNING);\n\n $this->_set_parameter($name, 'WebAccess', $access);\n }",
"function set_web_enabled($name, $enabled)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n // TODO: kludgy, the realm name is now automatically set to the flexshare description\n $share = $this->get_share($name);\n $this->_set_parameter($name, 'WebRealm', $share['ShareDescription']);\n\n $this->_set_parameter($name, 'WebEnabled', ($enabled ? 1: 0));\n $this->_generate_web_flexshares();\n }",
"function getRealm() {\n\n return $this->realm;\n\n }",
"function LdapRealm() {\n }",
"function set_web_server_name($name, $server_name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_name($server_name));\n\n $this->_set_parameter($name, 'WebServerName', $server_name);\n }",
"private function setName($name) {\n if (true == is_null($this->realName)) {\n $this->realName = $name;\n }\n\n $this->name = $name;\n }",
"public function setUserName($name) {\n $this -> userName = $name;\n }",
"protected function getDefaultAuthenticationRealm() {\n return \"Service\";\n }",
"function validate_web_realm($realm)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (!preg_match(\"/^([A-Za-z0-9\\-\\.\\_\\/\\' ]+)$/\", $realm))\n return lang('flexshare_web_realm_invalid');\n }",
"public function setUsernameAction($name)\n {\n $_SESSION['username'] = $name;\n\n print 'username was set';\n }",
"function set_web_server_name_alternate($name, $server_name)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_web_server_name($server_name));\n\n $this->_set_parameter($name, 'WebServerNameAlternate', $server_name);\n }",
"protected function setCredentialByName ( $cred_name , $cred_val )\r\n\t{\r\n\t\t$use_cookies = $this->getLoggedInUser() == NULL;\r\n\t\tif ( $use_cookies )\r\n\t\t{\r\n\t\t\trequestUtils::setSecureCookie( $cred_name , $cred_val , self::COOKIE_CREDENTAIL_IV , self::COOKIE_EXPIRY );\r\n//\t\t\tself::addToSecureCookieList ( $cred_name );\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t// if the user is logged in - use the credential mechaism\r\n\t\t\t$real_cred = $this->findCredential ( $cred_name );\r\n\t\t\tif ( $real_cred )\t$this->getUser()->removeCredential( $real_cred );\r\n\t\t\t$this->getUser()->addCredential ( $cred_name . \":\" . $cred_val );\r\n\t\t}\r\n\t\t\r\n\t}",
"protected function set_name( $name ) {\n\t\t$this->name = sanitize_key( $name );\n\t}",
"function edit_realm($realm,$name,$troll_name,$qa,$private,$new_owner)\n{\n\t$_qa=array();\n\tfor ($i=1;$i<=30;$i++)\n\t{\n\t\tif (strlen($qa[$i]['q'])>0)\n\t\t{\n\t\t\t$_qa['q'.strval($i)]=$qa[$i]['q'];\n\t\t\t$_qa['a'.strval($i)]=$qa[$i]['a'];\n\t\t} else\n\t\t{\n\t\t\t$_qa['q'.strval($i)]='';\n\t\t\t$_qa['a'.strval($i)]='';\n\t\t}\n\t}\n\n\t$GLOBALS['SITE_DB']->query_update('w_realms',array_merge($_qa,array('name'=>$name,'troll_name'=>$troll_name,'r_private'=>$private,'owner'=>$new_owner)),array('id'=>$realm),'',1);\n}",
"function setUserName($userName) {\n $this->userName = strtolower($userName);\n }",
"public function setUserPrincipalName($val)\n {\n $this->_propDict[\"userPrincipalName\"] = $val;\n return $this;\n }",
"public function setUserPrincipalName($val)\n {\n $this->_propDict[\"userPrincipalName\"] = $val;\n return $this;\n }",
"public function setUserPrincipalName($val)\n {\n $this->_propDict[\"userPrincipalName\"] = $val;\n return $this;\n }",
"public function setUserPrincipalName($val)\n {\n $this->_propDict[\"userPrincipalName\"] = $val;\n return $this;\n }",
"public function setUserPrincipalName($val)\n {\n $this->_propDict[\"userPrincipalName\"] = $val;\n return $this;\n }",
"public function setUserPrincipalName($val)\n {\n $this->_propDict[\"userPrincipalName\"] = $val;\n return $this;\n }"
] | [
"0.7265765",
"0.71363634",
"0.6824245",
"0.6142549",
"0.6070108",
"0.5787249",
"0.5595994",
"0.55818754",
"0.55553734",
"0.55034035",
"0.54508984",
"0.54508936",
"0.54377824",
"0.54135954",
"0.5399387",
"0.5387031",
"0.53773576",
"0.5373651",
"0.53532505",
"0.5318722",
"0.53024036",
"0.5291485",
"0.52577895",
"0.52505076",
"0.5223882",
"0.5223882",
"0.5223882",
"0.5223882",
"0.5223882",
"0.5223882"
] | 0.79986817 | 0 |
////////////////// F T P // ////////////////// Sets the enabled of ftpbased access. | function set_ftp_enabled($name, $enabled)
{
clearos_profile(__METHOD__, __LINE__);
$this->_set_parameter($name, 'FtpEnabled', $enabled);
$this->_generate_ftp_flexshares();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_ftp_protocol_ftp($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtp', $state);\n }",
"function set_ftp_protocol_ftps($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtps', $state);\n }",
"public function setPassive($passive)\n\t{\n\t\tif(!$this->connected)\n\t\t\tthrow new FTPException('Could not change passive mode: not connected to remote FTP server');\n \n\t\tif($this->passive != $passive)\n\t\t{\n\t\t\tif(!ftp_pasv($this->resource, $passive))\n\t\t\t\t\tthrow new FTPException('Could not change passive mode: unknown error');\n\t\t\t$this->passive = $passive;\n\t\t}\n\t}",
"public function setAuthMode()\n {\n $this->authMode = true;\n }",
"function set_ftp_protocol_ftpes($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtpes', $state);\n }",
"function ftpValidate()\n\t{\n\t\tJClientHelper::setCredentialsFromRequest('ftp');\n\t}",
"protected function Passive($pasv=false) {\r\n\t\tif (!function_exists('ftp_pasv')){\r\n\t\t\t$this->SendMSG(\"Fatal error: Call to undefined function ftp_pasv\");\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t$ret = ftp_pasv($this->_conn_id, $pasv);\r\n\t\t$this->SendMSG(\"Passive mode \".($pasv?\"on\":\"off\"));\r\n\t\treturn $ret;\r\n\t}",
"function set_ftp_allow_passive($name, $allow_passive, $port_min = self::FTP_PASV_MIN, $port_max = self::FTP_PASV_MAX)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if ($allow_passive)\n Validation_Exception::is_valid($this->validate_passive_port_range($port_min, $port_max));\n\n $this->_set_parameter($name, 'FtpAllowPassive', $allow_passive);\n\n if ($allow_passive) {\n $this->_set_parameter($name, 'FtpPassivePortMin', $port_min);\n $this->_set_parameter($name, 'FtpPassivePortMax', $port_max);\n }\n }",
"function setFS ($fs=true) {\n\tset('isFS', $fs);\n}",
"public function setUseFtp($host, $username, $password, $path)\n {\n $this->_useFtp = true;\n $this->_ftpHost = $host;\n $this->_ftpUser = $username;\n $this->_ftpPass = $password;\n $this->_ftpPath = $path;\n return $this;\n }",
"public function setAllowUpload(bool $value = true): self\r\n {\r\n $this->extras['allow_upload'] = $value;\r\n return $this;\r\n }",
"public function setDirectDownloadsEnabled($val)\n {\n $this->_propDict[\"directDownloadsEnabled\"] = $val;\n return $this;\n }",
"public function setPermissionsOnlyMode($value)\n {\n $this->setProperty(\"PermissionsOnlyMode\", $value, true);\n }",
"function get_ftp_permission_options()\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $options = array(\n self::PERMISSION_READ => lang('flexshare_read_only'),\n self::PERMISSION_READ_WRITE_PLUS => lang('flexshare_read_write')\n );\n\n return $options;\n }",
"public function setAccessRequestMode($value)\n {\n $this->setProperty(\"AccessRequestMode\", $value, true);\n }",
"public function setPassive($passive, $test = false)\n {\n if (false === $test) {\n @ftp_pasv($this->_getFtp(), (bool) $passive);\n }\n return $this;\n }",
"function set_ftp_group_access($name, $access)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpGroupAccess', implode(' ', $access));\n }",
"function validate_ftp_enabled($status)\n {\n clearos_profile(__METHOD__, __LINE__);\n }",
"public function isFtp()\n\t{\n\t\t$scheme = strtolower($this->getScheme());\n\n\t\treturn $this->isNormal() and ($scheme == 'ftp');\n\t}",
"public function pasv($pasv) {\n\t\t$this->connectIfNeeded();\n\t\t$this->param = $pasv;\n\n\t\tif (!ftp_pasv($this->handle, $pasv === true)) {\n\t\t\tthrow new GFtpException(\n\t\t\t\t\tYii::t('gftp', 'Could not {set} passive mode on server \"{host}\": {message}',\n\t\t\t\t\t\t\tarray('{host}' => $this->host, '{set}' => $pasv ? \"set\" : \"unset\")\n\t\t\t\t\t)\n\t\t\t);\n\t\t}\n\t}",
"public function setEnable( $value = true )\r\n\t{\r\n\t\t$this->enabled = (bool) $value;\r\n\t}",
"protected function connect() {\n\t\tif (!($this->connect = ftp_connect($this->options['host'], $this->options['port'], $this->options['timeout']))) {\n\t\t\treturn $this->setError('Unable to connect to FTP server '.$this->options['host']);\n\t\t}\n\t\tif (!ftp_login($this->connect, $this->options['user'], $this->options['pass'])) {\n\t\t\t$this->umount();\n\t\t\treturn $this->setError('Unable to login into '.$this->options['host']);\n\t\t}\n\t\t\n\t\t// switch off extended passive mode - may be usefull for some servers\n\t\t//@ftp_exec($this->connect, 'epsv4 off' );\n\t\t// enter passive mode if required\n\t\t$this->options['mode'] = 'active';\n\t\tftp_pasv($this->connect, $this->options['mode'] == 'passive');\n\n\t\t// enter root folder\n\t\tif (!ftp_chdir($this->connect, $this->root))\n\t\t{\n\t\t\t$this->umount();\n\t\t\treturn $this->setError('Unable to open root folder.');\n\t\t}\n\t\t\n\t\t$stat = array();\n\t\t$stat['name'] = $this->root;\n\t\t$stat['mime'] = 'directory';\n\t\t$this->filesCache[$this->root] = $stat;\n\t\t$this->cacheDir($this->root);\n\t\t\n\t\treturn true;\n\t}",
"static function enableSetFile($settings = array())\n {\n if ($settings === true) {\n $settings = array();\n }\n\n self::structSet('modules', 'setFile', $settings + array(\n 'path' => dSystem::getGlobal('baseDir') . '/dat/',\n 'cbAfterFileAccept' => false, // Callback(filename, Ofilename)\n ));\n }",
"public function setUserForcePasswordChangeOnLogonEnabled(?bool $value): void {\n $this->getBackingStore()->set('userForcePasswordChangeOnLogonEnabled', $value);\n }",
"public function set_enabled($enabled)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $file = new File(self::FILE_DAT, TRUE); \n $apache_configlet = new File(self::FILE_APACHE_CONFIGLET, TRUE); \n $httpd_reset = FALSE;\n if ($enabled) {\n if (!$file->exists()) {\n // Let's check for a backup configuration\n $backup = new File(self::FILE_DAT . '.bak', TRUE); \n if ($backup->exists())\n $backup->move_to(self::FILE_DAT);\n else\n $file->create('root', 'root', '0644');\n }\n if ($apache_configlet->exists())\n $apache_configlet->delete();\n $template = new File(clearos_app_base('wpad') . \"/deploy/wpad.conf\");\n if (!$template->exists())\n throw new Engine_Exception(lang('wpad_template_not_found'), CLEAROS_ERROR);\n $template->copy_to(self::FILE_APACHE_CONFIGLET);\n $hostname = new Hostname();\n $hosts = new Hosts();\n $apache_configlet->replace_lines(\"/ServerName SERVER_NAME/\", \" ServerName \" . $this->get_hostname() . \"\\n\");\n $httpd_reset = TRUE;\n } else {\n if ($file->exists()) {\n $backup = new File(self::FILE_DAT . '.bak', TRUE); \n if ($backup->exists())\n $backup->move_to(self::FILE_DAT .'.' . date('ymd-hi') . '.bak');\n $file->move_to(self::FILE_DAT . '.bak');\n }\n if ($apache_configlet->exists()) {\n $apache_configlet->delete();\n $httpd_reset = TRUE;\n }\n }\n if ($httpd_reset && clearos_library_installed('web_server/Httpd')) {\n $httpd = new Httpd();\n $httpd->reset(TRUE);\n }\n }",
"public function setPermission(File $f, $access, $enable = null, $owneronly = null)\n {\n $mode = $this->generateAccessMode($f, $enable, $owneronly);\n $this->fs->chmod($f->getAbsolutePath(), $mode);\n }",
"function access() {\r\n\t\t\r\n\t\t$access = false;\r\n\t\t\r\n\t\tif($GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['timtab']['importers'])\r\n\t\t{\r\n\t\t\t$access = true;\r\n\t\t}\r\n\t\t\r\n\t\treturn $access;\r\n\t}",
"function setDefaultAccess($value) {\n\t $this->defaultAccess = (int) $value == 0 ? 0 : 1;\n\t}",
"public function ftpFget(){\r\n\t\treturn ftp_fget();\r\n\t\treturn ftp_nb_fget();\r\n\t}",
"public function setDebugMode( $tf, $logger = NULL )\r\n {\r\n $this->connect();\r\n\r\n $this->debug = (bool) $tf;\r\n\r\n if ( $this->debug and !$logger ) {\r\n $logger = new RedBean_Logger_Default();\r\n }\r\n\r\n $this->setLogger( $logger );\r\n }"
] | [
"0.6450324",
"0.6330565",
"0.5987628",
"0.5865243",
"0.5807441",
"0.5713288",
"0.5707439",
"0.5702123",
"0.55248034",
"0.5524676",
"0.5506314",
"0.5478113",
"0.54367",
"0.5434448",
"0.54226255",
"0.5414249",
"0.538363",
"0.536287",
"0.53202933",
"0.5316499",
"0.53125453",
"0.53097105",
"0.530347",
"0.52999204",
"0.52920395",
"0.5282229",
"0.5244983",
"0.52390313",
"0.52342844",
"0.52311575"
] | 0.7123009 | 0 |
Sets an override flag to use custom port on the flexshare. | function set_ftp_override_port($name, $override_port, $port)
{
clearos_profile(__METHOD__, __LINE__);
if ($override_port && ($port == self::DEFAULT_PORT_FTP || $port == self::DEFAULT_PORT_FTPS))
throw new Engine_Exception(lang('flexshare_non_custom_port_warning'), CLEAROS_ERROR);
if ($override_port && ($port == 21 || $port == 990))
throw new Engine_Exception(lang('flexshare_ftp_cannot_use_default_ports'), CLEAROS_ERROR);
// Find all ports and see if any conflicts with n-1
if ($override_port) {
$shares = $this->_get_shares(self::TYPE_ALL);
foreach ($shares as $share_name => $share) {
if ($share_name != $name) {
if ((int)$share["FtpPort"] == ($port - 1)) {
throw new Engine_Exception(lang('flexshare_ftp_port_conflict'), CLEAROS_ERROR);
} else if (((int)$share["FtpPort"] -1) == $port) {
throw new Engine_Exception(lang('flexshare_ftp_port_conflict'), CLEAROS_ERROR);
}
}
}
}
$this->_set_parameter($name, 'FtpOverridePort', $override_port);
$this->_set_parameter($name, 'FtpPort', $port);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_web_override_port($name, $override_port, $port)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if ($override_port && ($port == 80 || $port == 443))\n throw new Engine_Exception(lang('flexshare_non_custom_port_warning'), CLEAROS_ERROR);\n\n $shares = $this->_get_shares(self::TYPE_ALL);\n\n $ssl = isset($shares[$name]['WebReqSsl']) ? $shares[$name]['WebReqSsl'] : FALSE;\n\n $inuse_ports = array();\n\n foreach ($shares as $share_name => $share) {\n $ssl_for_share = isset($share['WebReqSsl']) ? $share['WebReqSsl'] : FALSE;\n if (($name != $share_name) && ($ssl != $ssl_for_share))\n $inuse_ports[] = $share['WebPort'];\n }\n\n if ($override_port && (in_array($port, $this->bad_ports) || in_array($port, $inuse_ports)))\n throw new Validation_Exception(lang('flexshare_port_already_in_use'));\n\n $this->_set_parameter($name, 'WebOverridePort', $override_port);\n $this->_set_parameter($name, 'WebPort', $port);\n }",
"public function setPort()\n {\n $this->port = Config::get('smsglobal.port');\n }",
"public function setAllowOverride($flag)\n {\n $this->allowOverride = (bool) $flag;\n }",
"public function setOverride(bool $override): self;",
"private function setPort($port)\n {\n $this->_port = $port;\n \n\treturn TRUE;\n }",
"public function setPort($port)\n {\n \t$this->port = $port;\n }",
"function validate_web_override_port($port)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (! Network_Utils::is_valid_port($port))\n return lang('flexshare_port_invalid');\n\n if ($port == self::DEFAULT_PORT_WEB)\n return lang('flexshare_non_custom_port_warning');\n }",
"public function setport($port)\n {\n $this->_port = $port;\n }",
"public function setOverride($override)\n {\n $this->override = (bool) $override;\n\n return $this;\n }",
"public function setPort($port)\n {\n // Check port\n if (!preg_match(\"#^[0-9]{1,5}$#\", $port)) return false;\n\n // Add port to the starting-URL\n $url_parts = PHPCrawlerUtils::splitURL($this->starting_url);\n $url_parts[\"port\"] = $port;\n $this->starting_url = PHPCrawlerUtils::buildURLFromParts($url_parts, true);\n \n return true;\n }",
"function validate_ftp_override_port($port)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (! Network_Utils::is_valid_port($port))\n return lang('flexshare_port_invalid');\n if (($port == self::DEFAULT_PORT_FTP) || ($port == self::DEFAULT_PORT_FTPS))\n return lang('flexshare_non_custom_port_warning');\n }",
"private function setPort($port){\n\n\t\t$this->phpMailer->Port = $port;\n\t\n\t}",
"public function setProxyPort($value) { $this->proxyPort = intval($value); }",
"public function setPort( $port = 21 )\n {\n $this->port = (int)$port;\n }",
"public function setPortInfo($var)\n {\n if ($var)\n {\n $this->db_row['port_info']=$var;\n return true;\n }\n else\n {\n return false;\n }\n }",
"public function setPort($nPort) {\n $this->m_aSocketInfo ['RemotePort'] = $nPort;\n }",
"public function bSetSocksPort($port=\"9000\",$exitnode=\"\"){\n\t\t\n\t\tif(!$this->aGetRouterDesc($exitnode))\n\t\t\treturn false;\n\t\t\n\t\t\n\t\t$aSocksPortList = $this->aGetSocksPort();\n\t\t\n\t\t\n\t\tif(count($aSocksPortList)==0){\n\t\t\tif(!$port) $port = 9000;\n\t\t\treturn $this->bSetConf(\"socksport=\\\"9000 ExitNode=$exitnode\\\"\");\n\t\t\t\n\t\t}\n\n\t\t$cmd=\"\";\n\t\t$find = false;\n\t\tfor($i=0;$i<count($aSocksPortList);$i++){\n\t\t\tif($aSocksPortList[$i]['port']==$port){\n\t\t\t\t$find = true;\n\t\t\t\t$cmd.=\" socksport=\\\"$port ExitNode=$exitnode\\\"\";\n\t\t\t}else\t\t\t\n\t\t\t\tif($aSocksPortList[$i]['port'])\n\t\t\t\t$cmd.=\" socksport=\\\"\".$aSocksPortList[$i]['port'].\" ExitNode=\".$aSocksPortList[$i]['exitnode'].\"\\\"\";\n\t\t}\n\t\t\n\t\tif(!$find){\n\t\t\tif(!$port) $port = 9000;\n\t\t\t$cmd.=\" socksport=\\\"$port ExitNode=$exitnode\\\"\";\n\t\t}\n\t\t\n\t\treturn $this->bSetConf($cmd);\n\t}",
"public function setAddress($host, $port);",
"public function setPort($port)\n {\n $this->port = $port === null ? null : (int)$port;\n }",
"public function setProtocol()\n {\n $this->protocol = strtolower(Config::get('smsglobal.protocol'));\n }",
"function default_port() {\n return 8983;\n }",
"function default_port() {\n return 8983;\n }",
"public function setShared($name, $flag)\n {\n $this->configure(['shared' => [$name => (bool) $flag]]);\n }",
"public function setMemcachePort($memcachePort) {\n\t\t$this->_memcachePort = (int)$memcachePort;\n\t}",
"public function setPort($value)\n {\n return $this->set('Port', $value);\n }",
"public function setPort($value)\n {\n return $this->set('Port', $value);\n }",
"public function setPort($value)\n {\n return $this->set('Port', $value);\n }",
"public function setCustomDialerAppProtocol(?string $value): void {\n $this->getBackingStore()->set('customDialerAppProtocol', $value);\n }",
"public function setPort($port) {\n $this->port = $port;\n return $this;\n }",
"public function setVar( $name, $value, $override = true )\n {\n if(isset($this->override[$name]))\n {\n return null;\n }\n else\n {\n if($override == false)\n {\n $this->override[$name] = true;\n }\n $this->config[$name] = $value;\n } \n }"
] | [
"0.71846884",
"0.62600017",
"0.60815555",
"0.58528817",
"0.5835197",
"0.5821881",
"0.56564236",
"0.56273645",
"0.55940324",
"0.55375874",
"0.5507893",
"0.54793686",
"0.5455719",
"0.5370943",
"0.5355359",
"0.53273857",
"0.53014123",
"0.5281728",
"0.52120215",
"0.51559424",
"0.5096698",
"0.5096698",
"0.50729257",
"0.50502074",
"0.5036276",
"0.5036276",
"0.5036276",
"0.5034305",
"0.5034213",
"0.49931148"
] | 0.6987769 | 1 |
Sets the allow passive port (PASV) flag for the flexshare. | function set_ftp_allow_passive($name, $allow_passive, $port_min = self::FTP_PASV_MIN, $port_max = self::FTP_PASV_MAX)
{
clearos_profile(__METHOD__, __LINE__);
if ($allow_passive)
Validation_Exception::is_valid($this->validate_passive_port_range($port_min, $port_max));
$this->_set_parameter($name, 'FtpAllowPassive', $allow_passive);
if ($allow_passive) {
$this->_set_parameter($name, 'FtpPassivePortMin', $port_min);
$this->_set_parameter($name, 'FtpPassivePortMax', $port_max);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public function pasv($pasv) {\n\t\t$this->connectIfNeeded();\n\t\t$this->param = $pasv;\n\n\t\tif (!ftp_pasv($this->handle, $pasv === true)) {\n\t\t\tthrow new GFtpException(\n\t\t\t\t\tYii::t('gftp', 'Could not {set} passive mode on server \"{host}\": {message}',\n\t\t\t\t\t\t\tarray('{host}' => $this->host, '{set}' => $pasv ? \"set\" : \"unset\")\n\t\t\t\t\t)\n\t\t\t);\n\t\t}\n\t}",
"protected function Passive($pasv=false) {\r\n\t\tif (!function_exists('ftp_pasv')){\r\n\t\t\t$this->SendMSG(\"Fatal error: Call to undefined function ftp_pasv\");\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t$ret = ftp_pasv($this->_conn_id, $pasv);\r\n\t\t$this->SendMSG(\"Passive mode \".($pasv?\"on\":\"off\"));\r\n\t\treturn $ret;\r\n\t}",
"public function setPassive($passive)\n\t{\n\t\tif(!$this->connected)\n\t\t\tthrow new FTPException('Could not change passive mode: not connected to remote FTP server');\n \n\t\tif($this->passive != $passive)\n\t\t{\n\t\t\tif(!ftp_pasv($this->resource, $passive))\n\t\t\t\t\tthrow new FTPException('Could not change passive mode: unknown error');\n\t\t\t$this->passive = $passive;\n\t\t}\n\t}",
"public function passive()\n\t{\n\t\t// We can't create a passive data connection without a primary one first being there.\n\t\tif (!is_resource($this->connection))\n\t\t\treturn false;\n\n\t\t// Request a passive connection - this means, we'll talk to you, you don't talk to us.\n\t\t@fwrite($this->connection, 'PASV' . \"\\r\\n\");\n\t\t$time = time();\n\t\tdo\n\t\t\t$response = fgets($this->connection, 1024);\n\t\twhile (strpos($response, ' ', 3) !== 3 && time() - $time < 5);\n\n\t\t// If it's not 227, we weren't given an IP and port, which means it failed.\n\t\tif (strpos($response, '227 ') !== 0)\n\t\t{\n\t\t\t$this->error = 'bad_response';\n\t\t\treturn false;\n\t\t}\n\n\t\t// Snatch the IP and port information, or die horribly trying...\n\t\tif (preg_match('~\\((\\d+),\\s*(\\d+),\\s*(\\d+),\\s*(\\d+),\\s*(\\d+)(?:,\\s*(\\d+))\\)~', $response, $match) == 0)\n\t\t{\n\t\t\t$this->error = 'bad_response';\n\t\t\treturn false;\n\t\t}\n\n\t\t// This is pretty simple - store it for later use ;).\n\t\t$this->pasv = array('ip' => $match[1] . '.' . $match[2] . '.' . $match[3] . '.' . $match[4], 'port' => $match[5] * 256 + $match[6]);\n\n\t\treturn true;\n\t}",
"public function setPassive(bool $passive)\n {\n $this->passive = $passive;\n\n return $this;\n }",
"public function setPassive($passive, $test = false)\n {\n if (false === $test) {\n @ftp_pasv($this->_getFtp(), (bool) $passive);\n }\n return $this;\n }",
"function setPassthru($passthru) {\n\t\t$this->passthru = (bool) $passthru;\n\t}",
"function validate_ftp_passive_port($port)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (! Network_Utils::is_valid_port($port))\n return lang('flexshare_port_invalid');\n }",
"public function isPassive()\n {\n return $this->passive;\n }",
"function set_ftp_enabled($name, $enabled)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnabled', $enabled);\n $this->_generate_ftp_flexshares();\n }",
"public function form_passive_set($passive, $method = NULL) {\n\t\t\t\t$this->form_passive = ($passive == true);\n\t\t\t\t$this->form_button_name = ($this->form_passive ? NULL : 'button'); // As passive we don't need to know which button is pressed (just adds cruft to url)\n\t\t\t\tif ($method !== NULL) {\n\t\t\t\t\t$this->form_method_set($method);\n\t\t\t\t} else {\n\t\t\t\t\t$this->_is_submitted();\n\t\t\t\t}\n\t\t\t}",
"private function setPort($port)\n {\n $this->_port = $port;\n \n\treturn TRUE;\n }",
"public function getPassive()\n\t{\n\t\treturn $this->passive;\n\t}",
"function validate_passive_port_range($port_min, $port_max)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (! Network_Utils::is_valid_port_range($port_min, $port_max))\n return lang('flexshare_port_range_invalid');\n\n if ($port_min < 1023 || $port_max < 1023)\n return lang('flexshare_passive_port_below_min');\n }",
"public function isPassive()\n {\n return $this->getTypeObject()->isPassive();\n }",
"public function testIsPassive()\n {\n $settingsDir = TEST_ROOT .'/settings/';\n include $settingsDir.'settings1.php';\n\n $settings = new OneLogin_Saml2_Settings($settingsInfo);\n $authnRequest = new OneLogin_Saml2_AuthnRequest($settings);\n $encodedRequest = $authnRequest->getRequest();\n $decoded = base64_decode($encodedRequest);\n $request = gzinflate($decoded);\n $this->assertNotContains('IsPassive=\"true\"', $request);\n\n $authnRequest2 = new OneLogin_Saml2_AuthnRequest($settings, false, false);\n $encodedRequest2 = $authnRequest2->getRequest();\n $decoded2 = base64_decode($encodedRequest2);\n $request2 = gzinflate($decoded2);\n $this->assertNotContains('IsPassive=\"true\"', $request2);\n\n $authnRequest3 = new OneLogin_Saml2_AuthnRequest($settings, false, true);\n $encodedRequest3 = $authnRequest3->getRequest();\n $decoded3 = base64_decode($encodedRequest3);\n $request3 = gzinflate($decoded3);\n $this->assertContains('IsPassive=\"true\"', $request3);\n }",
"public function setVirtualSecureMode($val)\n {\n $this->_propDict[\"virtualSecureMode\"] = $val;\n return $this;\n }",
"function set_ftp_protocol_ftpes($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtpes', $state);\n }",
"public function setPortInfo($var)\n {\n if ($var)\n {\n $this->db_row['port_info']=$var;\n return true;\n }\n else\n {\n return false;\n }\n }",
"function validate_ftp_override_port($port)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (! Network_Utils::is_valid_port($port))\n return lang('flexshare_port_invalid');\n if (($port == self::DEFAULT_PORT_FTP) || ($port == self::DEFAULT_PORT_FTPS))\n return lang('flexshare_non_custom_port_warning');\n }",
"public function setAllow($allow) {\n $this->allow = $allow;\n }",
"public function setPassive($id)\n {\n }",
"function validate_ftp_allow_passive_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n }",
"public function setPort($port)\n {\n // Check port\n if (!preg_match(\"#^[0-9]{1,5}$#\", $port)) return false;\n\n // Add port to the starting-URL\n $url_parts = PHPCrawlerUtils::splitURL($this->starting_url);\n $url_parts[\"port\"] = $port;\n $this->starting_url = PHPCrawlerUtils::buildURLFromParts($url_parts, true);\n \n return true;\n }",
"public function fau_videoportal()\n {\n if ($this->options->fau_videoportal->active == true) {\n $this->registerHandler('fau_videoportal');\n }\n }",
"function setSecure($value) {\n $this->secure = (boolean) $value;\n }",
"public function setSecure($secure)\n {\n $this->secure = (bool) $secure;\n }",
"public function enableSandbox()\n {\n $this->sandbox = true;\n $this->ip = '127.0.0.1';\n }",
"function set_ftp_override_port($name, $override_port, $port)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if ($override_port && ($port == self::DEFAULT_PORT_FTP || $port == self::DEFAULT_PORT_FTPS))\n throw new Engine_Exception(lang('flexshare_non_custom_port_warning'), CLEAROS_ERROR);\n\n if ($override_port && ($port == 21 || $port == 990))\n throw new Engine_Exception(lang('flexshare_ftp_cannot_use_default_ports'), CLEAROS_ERROR);\n\n // Find all ports and see if any conflicts with n-1\n if ($override_port) {\n $shares = $this->_get_shares(self::TYPE_ALL);\n\n foreach ($shares as $share_name => $share) {\n if ($share_name != $name) {\n if ((int)$share[\"FtpPort\"] == ($port - 1)) {\n throw new Engine_Exception(lang('flexshare_ftp_port_conflict'), CLEAROS_ERROR);\n } else if (((int)$share[\"FtpPort\"] -1) == $port) {\n throw new Engine_Exception(lang('flexshare_ftp_port_conflict'), CLEAROS_ERROR);\n }\n }\n }\n }\n\n $this->_set_parameter($name, 'FtpOverridePort', $override_port);\n $this->_set_parameter($name, 'FtpPort', $port);\n }",
"function set_ftp_protocol_ftps($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtps', $state);\n }"
] | [
"0.6604524",
"0.6533456",
"0.6378219",
"0.62266624",
"0.60195893",
"0.59950274",
"0.58700144",
"0.58203787",
"0.5656712",
"0.5493375",
"0.54779005",
"0.5474276",
"0.531772",
"0.52581763",
"0.52375996",
"0.5115982",
"0.49565867",
"0.4954591",
"0.4944586",
"0.492979",
"0.48690587",
"0.48308438",
"0.48125044",
"0.47731727",
"0.47678867",
"0.47487754",
"0.47389907",
"0.47371507",
"0.47116068",
"0.4677818"
] | 0.7071113 | 0 |
Sets the FTP protocol state. | function set_ftp_protocol_ftp($name, $state)
{
clearos_profile(__METHOD__, __LINE__);
$this->_set_parameter($name, 'FtpEnableFtp', $state);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_ftp_protocol_ftps($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtps', $state);\n }",
"function set_ftp_protocol_ftpes($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtpes', $state);\n }",
"function validate_ftp_protocol_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (! clearos_is_valid_boolean($state))\n return lang('base_state_invalid');\n }",
"public function setProtocol()\n {\n $this->protocol = strtolower(Config::get('smsglobal.protocol'));\n }",
"public function setPassive($passive)\n\t{\n\t\tif(!$this->connected)\n\t\t\tthrow new FTPException('Could not change passive mode: not connected to remote FTP server');\n \n\t\tif($this->passive != $passive)\n\t\t{\n\t\t\tif(!ftp_pasv($this->resource, $passive))\n\t\t\t\t\tthrow new FTPException('Could not change passive mode: unknown error');\n\t\t\t$this->passive = $passive;\n\t\t}\n\t}",
"function validate_ftp_override_port_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n }",
"function validate_ftp_allow_passive_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n }",
"public function setProtocol($protocol)\n\t{\n\t\tif($protocol === 1)\n\t\t{\n\t\t\t$this->protocol = HTTP_VERSION_1_1;\n\t\t}else\n\t\t{\n\t\t\t$this->protocol = HTTP_VERSION_1_0;\n\t\t}\n\t}",
"public function setProtocol($protocol)\n {\n $this->protocol = $protocol;\n }",
"function set_ftp_enabled($name, $enabled)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnabled', $enabled);\n $this->_generate_ftp_flexshares();\n }",
"public function set_translation_mode_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_state($state));\n\n $file = new File(self::FILE_MODE);\n\n if (!$state && $file->exists())\n $file->delete();\n else if ($state && !$file->exists())\n $file->create('root', 'root', '0644');\n }",
"public function setPort($port)\n\t{\n\t\tif($this->connected)\n\t\t\tthrow new FTPException('Unable to set port: open connnection');\n \n\t\t$this->port = $port;\n\t}",
"function ftpValidate()\n\t{\n\t\tJClientHelper::setCredentialsFromRequest('ftp');\n\t}",
"public function pasv($pasv) {\n\t\t$this->connectIfNeeded();\n\t\t$this->param = $pasv;\n\n\t\tif (!ftp_pasv($this->handle, $pasv === true)) {\n\t\t\tthrow new GFtpException(\n\t\t\t\t\tYii::t('gftp', 'Could not {set} passive mode on server \"{host}\": {message}',\n\t\t\t\t\t\t\tarray('{host}' => $this->host, '{set}' => $pasv ? \"set\" : \"unset\")\n\t\t\t\t\t)\n\t\t\t);\n\t\t}\n\t}",
"public function setProtocol(AbstractProtocol $protocol);",
"public function setPassword($password)\n\t{\n\t\tif($this->connected)\n\t\t\tthrow new FTPException('Unable to set password: open connnection');\n \n\t\t$this->password = $password;\n\t}",
"protected function setMode($mode)\n {\n $mode = strtolower($mode);\n\n // These are largely ignored, as the remote\n // object storage does not distinguish between\n // text and binary files. Per the PHP recommendation\n // files are treated as binary.\n $this->isBinary = strpos($mode, 'b') !== false;\n $this->isText = strpos($mode, 't') !== false;\n\n // Rewrite mode to remove b or t:\n $mode = preg_replace('/[bt]?/', '', $mode);\n\n switch ($mode) {\n case 'r+':\n $this->isWriting = true;\n case 'r':\n $this->isReading = true;\n $this->createIfNotFound = false;\n break;\n\n\n case 'w+':\n $this->isReading = true;\n case 'w':\n $this->isTruncating = true;\n $this->isWriting = true;\n break;\n\n\n case 'a+':\n $this->isReading = true;\n case 'a':\n $this->isAppending = true;\n $this->isWriting = true;\n break;\n\n\n case 'x+':\n $this->isReading = true;\n case 'x':\n $this->isWriting = true;\n $this->noOverwrite = true;\n break;\n\n case 'c+':\n $this->isReading = true;\n case 'c':\n $this->isWriting = true;\n break;\n\n // nope mode: Mock read/write support,\n // but never write to the remote server.\n // (This is accomplished by never marking\n // the stream as dirty.)\n case 'nope':\n $this->isReading = true;\n $this->isWriting = true;\n $this->isNeverDirty = true;\n break;\n\n // Default case is read/write\n // like c+.\n default:\n $this->isReading = true;\n $this->isWriting = true;\n break;\n\n }\n\n return $this;\n }",
"function setopen($state) {\n\t\t$this->open=$state;\n\t}",
"protected function setFtp($type, Array $ftp){\n $allowed_types = ['image','backup'];\n if(!in_array($type, $allowed_types)){\n throw new \\Exception($this->trans('errors.internal'));\n }\n try{\n // prepare db connection\n $ftp = array(\n 'type' => $ftp['type'],\n 'host' => $ftp['host'],\n 'root' => isset($ftp['root']) ? $ftp['root'] : '',\n 'port' => isset($ftp['port']) ? $ftp['port'] : '22',\n 'username' => $ftp['username'],\n 'password' => $ftp['password'],\n 'ssl' => isset($ftp['ssl']) ? $ftp['ssl'] : false,\n );\n } catch(\\Exception $e) {\n throw new \\Exception($this->trans('errors.internal'));\n }\n // store connection as config\n app('config')->set('user.ftp.'.$type,$ftp);\n }",
"public function setProtocols($val)\n {\n $this->_propDict[\"protocols\"] = $val;\n return $this;\n }",
"public function set_transport_mode($value)\n {\n $this->transport_mode = self::id_or_entity_helper($value, 'ResponseMode');\n }",
"public function setUseFtp($host, $username, $password, $path)\n {\n $this->_useFtp = true;\n $this->_ftpHost = $host;\n $this->_ftpUser = $username;\n $this->_ftpPass = $password;\n $this->_ftpPath = $path;\n return $this;\n }",
"final public function set_state($state) \n {\n $this->_state = $state;\n }",
"public function provider_set_protocol()\n\t{\n\t\treturn array(\n\t\t\tarray(\n\t\t\t\t'http',\n\t\t\t\t'http',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'FTP',\n\t\t\t\t'ftp',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'hTTps',\n\t\t\t\t'https',\n\t\t\t),\n\t\t);\n\t}",
"protected function setProtocolVersion()\n {\n $this->setOption(LDAP_OPT_PROTOCOL_VERSION, $this->config['protocol_version']);\n }",
"public function setCredentials($ftpLogin, $ftpPassword)\n {\n $this->_ftpUser = $ftpLogin;\n $this->_ftpPassword = $ftpPassword;\n }",
"function setFlag($mode) {\n $this->mode |= $mode;\n }",
"public function setFiniteState($state);",
"function set_ftp_allow_passive($name, $allow_passive, $port_min = self::FTP_PASV_MIN, $port_max = self::FTP_PASV_MAX)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if ($allow_passive)\n Validation_Exception::is_valid($this->validate_passive_port_range($port_min, $port_max));\n\n $this->_set_parameter($name, 'FtpAllowPassive', $allow_passive);\n\n if ($allow_passive) {\n $this->_set_parameter($name, 'FtpPassivePortMin', $port_min);\n $this->_set_parameter($name, 'FtpPassivePortMax', $port_max);\n }\n }",
"function set_mode($mode)\r\n {\r\n $this->mode = $mode;\r\n }"
] | [
"0.7776378",
"0.75696355",
"0.620886",
"0.6064081",
"0.58522224",
"0.5733577",
"0.5626198",
"0.5591048",
"0.55056065",
"0.54122454",
"0.5411817",
"0.54045594",
"0.53019977",
"0.52683777",
"0.52402127",
"0.52375454",
"0.5137111",
"0.50953084",
"0.50177914",
"0.50168526",
"0.50105894",
"0.50015223",
"0.49172089",
"0.4914982",
"0.49112096",
"0.48806155",
"0.4873656",
"0.48674732",
"0.4860223",
"0.4820408"
] | 0.8156603 | 0 |
Sets the FTPES protocol state. | function set_ftp_protocol_ftpes($name, $state)
{
clearos_profile(__METHOD__, __LINE__);
$this->_set_parameter($name, 'FtpEnableFtpes', $state);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_ftp_protocol_ftps($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtps', $state);\n }",
"function set_ftp_protocol_ftp($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtp', $state);\n }",
"public function set_state(array $state)\n {\n $state_query = http_build_query($state, '', '&'); \n\n //tell the UCS to load the serialized state\n $this->send_raw_command('l '.$state_query);\n\n //discard the response\n $this->read_response();\n }",
"function setOnState($state) {\n if(is_bool($state)) {\n $conn = new ApiConnection();\n $URL = \"lights/\" . $this->lightID . \"/state\";\n $state = $state ? 'true' : 'false';\n $data = '{\"on\": ' . $state .'}';\n $result = $conn->sendPutCmd($URL, $data);\n return $result;\n } else {\n return null;\n }\n }",
"public function setState($state){\n\n $this->session->set('state', $state);\n }",
"public function set_translation_mode_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_state($state));\n\n $file = new File(self::FILE_MODE);\n\n if (!$state && $file->exists())\n $file->delete();\n else if ($state && !$file->exists())\n $file->create('root', 'root', '0644');\n }",
"function setStatus($bS=false){\n $this->bStatus = is_bool($bS) ? $bS : false;\n }",
"public function set($flags)\n {\n $this->flags = $flags;\n }",
"final public function set_state($state) \n {\n $this->_state = $state;\n }",
"public function set_transport_mode($value)\n {\n $this->transport_mode = self::id_or_entity_helper($value, 'ResponseMode');\n }",
"function setState($state){\r\n if(strlen($state)==2) {\r\n $this->state=$state;\r\n }\r\n else {\r\n $this->state='NA';\r\n }\r\n }",
"public function setState($state)\n {\n fhread_mutex_lock($this->stateMutex);\n $this->state = $state;\n fhread_mutex_unlock($this->stateMutex);\n }",
"function validate_ftp_protocol_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (! clearos_is_valid_boolean($state))\n return lang('base_state_invalid');\n }",
"public function setState($state) {\n\t\t$this->state = $state;\n\t}",
"public function setFiniteState($state);",
"function setopen($state) {\n\t\t$this->open=$state;\n\t}",
"Public function SetPower($state){\n\t\t$host = $this->ReadPropertyString('IPAddress');\n\t\t$url = \"http://$host:80/goform/formiPhoneAppPower.xml\";\n\t\tif ($state == true){\n $this->SendDebug('SetPower', 'Power: '.'einschalten', 0);\n\t\t\t$cmd = '1+PowerOn';\n\t\t\t$power=true;\n\t\t}\n\t\tif ($state == false){\n\t\t\t$cmd = '1+PowerStandby';\n\t\t\t$power=false;\n\t\t}\n\t\t$xml = $this->curl_get($url, $cmd);\n //$this->SendDebug('SetPower:XMLcreateArray_IN: ', $xml, 0);\n\t\t//$output = XML2Array::createArray($xml);\n $output = json_decode(json_encode((array)simplexml_load_string($xml)),true);\n //$this->SendDebug('SetPower:XMLcreateArray_IN: ', $output, 0);\n \t\t//$status = ($output['item']['Power']['value']);\n $status = ($output['Power']['value']);\n $this->SetValue(\"CeolPower\", $power);\n\t\treturn $status;\t\n\t}",
"function setState($state) {\n \n $this->state = $state;\n \n }",
"public function set_status($p_status){\n\t\t$this->v_status = (int) $p_status;\n\t}",
"function setStatus($status){\n\t\t$this->_options['status'] = (bool) $status;\n\t}",
"public function set_state($state) {\n if ($state != $this->_state + 1 || $state > self::STATE_DONE) {\n throw new coding_exception('Invalid state passed to moodle_page::set_state. We are in state ' .\n $this->_state . ' and state ' . $state . ' was requestsed.');\n }\n\n if ($state == self::STATE_PRINTING_HEADER) {\n $this->starting_output();\n }\n\n $this->_state = $state;\n }",
"public function set_status($p_status) {\n $this->status = $p_status;\n }",
"public function setState($state) {\n if ($state instanceof PaperStateApi) {\n $state = $state->getId();\n }\n\n $this->paperState = NULL;\n $this->state_id = $state;\n $this->toSave['state.id'] = $state;\n }",
"public function setEstado($estado){\n\t\t$this->estado = $estado;\n\t}",
"function validate_ftp_allow_passive_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n }",
"public function setPending()\n {\n $this->status = self::STATUS_PENDING;\n $this->save();\n }",
"public function setState($state)\n {\n $this->state = $state;\n }",
"function validate_ftp_override_port_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n }",
"function setFlagBits() {\n $this->flags = 0;\n\n // Note: NULL == \"\" so checking for 0 length string is not needed.\n if ($this->ip != NULL) {\n $this->flags = $this->flags | $this->FLAG_IP;\n }\n if ($this->path != NULL) {\n $this->flags = $this->flags | $this->FLAG_PATH;\n }\n if ($this->profile != NULL) {\n $this->flags = $this->flags | $this->FLAG_PROFILE;\n }\n if ($this->password != NULL) {\n $this->flags = $this->flags | $this->FLAG_PASSWD;\n }\n if ($this->window > 0) {\n $this->flags = $this->flags | $this->FLAG_WINDOW;\n }\n if ($this->payload != NULL) {\n $this->flags = $this->flags | $this->FLAG_PAYLOAD;\n }\n if ($this->duration > 0) {\n $this->flags = $this->flags | $this->FLAG_DURATION;\n }\n }",
"public function setParsingSucceeded(?bool $value): void {\n $this->getBackingStore()->set('parsingSucceeded', $value);\n }"
] | [
"0.5880874",
"0.56742847",
"0.534811",
"0.5224293",
"0.5169015",
"0.51577437",
"0.51387787",
"0.5136406",
"0.51105183",
"0.5066723",
"0.5017576",
"0.4996954",
"0.49922788",
"0.4942652",
"0.49122345",
"0.49060792",
"0.4889848",
"0.48764578",
"0.48562992",
"0.4837092",
"0.48288614",
"0.47808444",
"0.47780386",
"0.47763017",
"0.47683245",
"0.4765834",
"0.47490013",
"0.47380808",
"0.4730818",
"0.47115254"
] | 0.71603054 | 0 |
Sets the FTPS protocol state. | function set_ftp_protocol_ftps($name, $state)
{
clearos_profile(__METHOD__, __LINE__);
$this->_set_parameter($name, 'FtpEnableFtps', $state);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"function set_ftp_protocol_ftp($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtp', $state);\n }",
"function set_ftp_protocol_ftpes($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnableFtpes', $state);\n }",
"public function setProtocol()\n {\n $this->protocol = strtolower(Config::get('smsglobal.protocol'));\n }",
"function validate_ftp_protocol_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n if (! clearos_is_valid_boolean($state))\n return lang('base_state_invalid');\n }",
"function validate_ftp_override_port_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n }",
"function validate_ftp_allow_passive_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n }",
"public function setPassive($passive)\n\t{\n\t\tif(!$this->connected)\n\t\t\tthrow new FTPException('Could not change passive mode: not connected to remote FTP server');\n \n\t\tif($this->passive != $passive)\n\t\t{\n\t\t\tif(!ftp_pasv($this->resource, $passive))\n\t\t\t\t\tthrow new FTPException('Could not change passive mode: unknown error');\n\t\t\t$this->passive = $passive;\n\t\t}\n\t}",
"public function set_translation_mode_state($state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n Validation_Exception::is_valid($this->validate_state($state));\n\n $file = new File(self::FILE_MODE);\n\n if (!$state && $file->exists())\n $file->delete();\n else if ($state && !$file->exists())\n $file->create('root', 'root', '0644');\n }",
"public function setProtocol($protocol)\n\t{\n\t\tif($protocol === 1)\n\t\t{\n\t\t\t$this->protocol = HTTP_VERSION_1_1;\n\t\t}else\n\t\t{\n\t\t\t$this->protocol = HTTP_VERSION_1_0;\n\t\t}\n\t}",
"public function set_state(array $state)\n {\n $state_query = http_build_query($state, '', '&'); \n\n //tell the UCS to load the serialized state\n $this->send_raw_command('l '.$state_query);\n\n //discard the response\n $this->read_response();\n }",
"final public function set_state($state) \n {\n $this->_state = $state;\n }",
"function setopen($state) {\n\t\t$this->open=$state;\n\t}",
"public function setSecure($secure)\n {\n $this->secure = (bool) $secure;\n }",
"public function setProtocol($protocol)\n {\n $this->protocol = $protocol;\n }",
"function setFS ($fs=true) {\n\tset('isFS', $fs);\n}",
"public function set_https_mode($flag)\n {\n return $this->_api->setHttpsMode($flag);\n }",
"public function setState($state){\n\n $this->session->set('state', $state);\n }",
"public function setFiniteState($state);",
"function set_ftp_enabled($name, $enabled)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $this->_set_parameter($name, 'FtpEnabled', $enabled);\n $this->_generate_ftp_flexshares();\n }",
"public function pasv($pasv) {\n\t\t$this->connectIfNeeded();\n\t\t$this->param = $pasv;\n\n\t\tif (!ftp_pasv($this->handle, $pasv === true)) {\n\t\t\tthrow new GFtpException(\n\t\t\t\t\tYii::t('gftp', 'Could not {set} passive mode on server \"{host}\": {message}',\n\t\t\t\t\t\t\tarray('{host}' => $this->host, '{set}' => $pasv ? \"set\" : \"unset\")\n\t\t\t\t\t)\n\t\t\t);\n\t\t}\n\t}",
"function setSecure($value) {\n $this->secure = (boolean) $value;\n }",
"public function setState($state)\n {\n fhread_mutex_lock($this->stateMutex);\n $this->state = $state;\n fhread_mutex_unlock($this->stateMutex);\n }",
"public function setProtocols($val)\n {\n $this->_propDict[\"protocols\"] = $val;\n return $this;\n }",
"public function setSecure(bool $secure)\n {\n $this->secure = $secure;\n }",
"protected function _setStream($stream) {\n $this->_stream = $stream;\n $this->_streamPtr = 0;\n }",
"public function set_transport_mode($value)\n {\n $this->transport_mode = self::id_or_entity_helper($value, 'ResponseMode');\n }",
"function set_share_state($name, $state)\n {\n clearos_profile(__METHOD__, __LINE__);\n\n $share = $this->get_share($name);\n $state_value = ($state) ? 1 : 0;\n\n $this->_set_parameter($name, 'ShareEnabled', $state_value);\n\n $this->_update_folder_links($name, $this->_get_parameter($name, 'ShareDir'));\n }",
"function setStatus($bS=false){\n $this->bStatus = is_bool($bS) ? $bS : false;\n }",
"public function setSecure(bool $bool): void\n {\n $this->secure = $bool;\n }",
"function setOnState($state) {\n if(is_bool($state)) {\n $conn = new ApiConnection();\n $URL = \"lights/\" . $this->lightID . \"/state\";\n $state = $state ? 'true' : 'false';\n $data = '{\"on\": ' . $state .'}';\n $result = $conn->sendPutCmd($URL, $data);\n return $result;\n } else {\n return null;\n }\n }"
] | [
"0.7663082",
"0.74541605",
"0.6167513",
"0.61120754",
"0.5580634",
"0.5482395",
"0.5472112",
"0.54239154",
"0.5282617",
"0.5258808",
"0.5253242",
"0.52497965",
"0.5184425",
"0.51792663",
"0.51509315",
"0.5099392",
"0.5092189",
"0.5088867",
"0.50759804",
"0.50652903",
"0.5047981",
"0.5031025",
"0.50240797",
"0.5023024",
"0.4956426",
"0.49468467",
"0.49283418",
"0.4919025",
"0.4914604",
"0.49125367"
] | 0.79625523 | 0 |
Subsets and Splits