query_id
stringlengths
32
32
query
stringlengths
7
5.32k
positive_passages
listlengths
1
1
negative_passages
listlengths
88
101
2f63d46cf1336b1b24428e68a0e2dfec
$guzzle = new Client();
[ { "docid": "762282077e4b83914cd5d60bd929b26f", "score": "0.0", "text": "public static function getDocContent()\n {\n //$response = $guzzle->get('https://www.reg.ru/support/help/api2');\n //$html = $response->getBody()->getContents();\n //file_put_contents('test.html', $html);\n return file_get_contents('test.html');\n }", "title": "" } ]
[ { "docid": "51993e089141e7c55d88f39027c1c77a", "score": "0.82196033", "text": "public function __construct()\n {\n $this->guzzle = new Guzzle();\n }", "title": "" }, { "docid": "9e9a42f9f9bd7d5747e7e611e1f444ba", "score": "0.79109144", "text": "function GuzzleTester()\n{\n\treturn new GuzzleHttp\\Client\n\t([\n\t\t'base_url' => 'http://127.0.0.1:'.RoboFile::$serverPort,\n\t\t'defaults' => ['cookies' => true]\n\t]);\n}", "title": "" }, { "docid": "a48951c9940a27ea3023a21ce6fa0b66", "score": "0.7743631", "text": "function guzzle($options = null)\n{\n\treturn is_null($options) ? $client = new GuzzleHttp\\Client() : new GuzzleHttp\\Client($options);\n}", "title": "" }, { "docid": "145ba1ab5413bf1d7418de6066ba2984", "score": "0.7722203", "text": "public static function getGuzzle()\n {\n $guzzle = new GuzzleClient(array('redirect.disable' => true, 'base_url' => ''));\n return $guzzle;\n }", "title": "" }, { "docid": "bbf51caf7f4c6da85ba388f3bac0fc30", "score": "0.7698935", "text": "public function getClient(): \\GuzzleHttp\\ClientInterface;", "title": "" }, { "docid": "1439c8c00fe487fb1fddc2ec788b917d", "score": "0.7627085", "text": "public function getClient()\n\t{\n\t\treturn new \\Guzzle\\Http\\Client;\n\t}", "title": "" }, { "docid": "e76b473485e2644051c34b05b7e35e87", "score": "0.75641245", "text": "private function getClient()\n {\n if(!$this->client){\n $this->client = new GuzzleHttpClient();\n }\n return $this->client;\n }", "title": "" }, { "docid": "849cf24366ad613403dcb1e1c505b2dd", "score": "0.7406574", "text": "public static function getGuzzle() {\n return self::container()->get('http');\n }", "title": "" }, { "docid": "ecc96ea81bb2da654a25014a7cfdcad3", "score": "0.73973405", "text": "public function __construct(GuzzleClient $client)\n {\n $this->client = $client;\n }", "title": "" }, { "docid": "74c8ec01e731d64584120ca0476aa35b", "score": "0.73304886", "text": "private function getGuzzleClient()\n {\n if (null === $this->guzzleClient) {\n $this->guzzleClient = new \\GuzzleHttp\\Client([\n 'base_uri' => self::BASE_URL,\n 'timeout' => 5,\n ]);\n }\n\n return $this->guzzleClient;\n }", "title": "" }, { "docid": "a64d59bbd276ba2a2aa1e8e1f6590b20", "score": "0.7291502", "text": "protected function getGuzzleInstance(): Client\n {\n return new Client(['headers' => ['Authorization' => 'Bearer '.$this->token, 'Content-Type' => 'application/json']]);\n }", "title": "" }, { "docid": "f4580d81699f403ed297a649374086c5", "score": "0.7291249", "text": "private function getClient()\n {\n return new \\GuzzleHttp\\Client([\n 'base_uri' => $this->url,\n 'timeout' => 2.0,\n ]);\n }", "title": "" }, { "docid": "9d16f075e49368adbd8a075ebf70bc04", "score": "0.72584707", "text": "protected function client() : GuzzleClient {\n return $this->client;\n }", "title": "" }, { "docid": "dcec86ff0af1522e607ebb1832a73f63", "score": "0.7248182", "text": "public function __construct()\n {\n $this->client = new HttpClient();\n }", "title": "" }, { "docid": "f83e0ccaafbc9f122a48c36d7e5fe516", "score": "0.72079945", "text": "public function getGuzzle()\n {\n return $this->guzzle;\n }", "title": "" }, { "docid": "46b29794e6cfb862430ef4e6a50466fb", "score": "0.7205306", "text": "public function __construct()\n {\n parent::__construct();\n\n $this->httpClient = new GuzzleHttpClient();\n }", "title": "" }, { "docid": "33e2b09865a61212039dad2654f17807", "score": "0.7178152", "text": "public function __construct()\n {\n $this->api = '';\n $this->client = new Guzzle(self::URI);\n }", "title": "" }, { "docid": "a191f298b3cbc6d33213065f6b62a8cb", "score": "0.70921", "text": "protected function getGuzzleClient() {\n\n $headerMiddleware = function (RequestInterface $request) {\n return $request\n ->withHeader('Authorization', 'Bearer ' . $this->getApiKey())\n ->withHeader('Content-type', 'application/json');\n };\n $headerMiddleware->bindTo($this);\n\n $stack = new HandlerStack();\n $stack->setHandler(new CurlHandler());\n $stack->push(Middleware::mapRequest($headerMiddleware));\n\n $client = new GuzzleHttpClient([\n 'base_uri' => self::BASE_URL,\n 'handler' => $stack,\n ]);\n\n return $client;\n }", "title": "" }, { "docid": "432c4eb30ee895b43fbb22c31ccaba16", "score": "0.7065639", "text": "public function client(): HttpClient;", "title": "" }, { "docid": "f5ad1b4ced70c56bbdc14584bf45512e", "score": "0.70452464", "text": "public function __construct(Guzzle\\Http\\Client $client) {\n $this->setClient($client);\n }", "title": "" }, { "docid": "a2a88d0f10f16dcd69a8ecf1b24b917a", "score": "0.7031996", "text": "protected function newGuzzleClient()\n {\n $baseUrl = sprintf(self::BASE_URL, $this->hostname);\n\n return new GuzzleClient([\n 'base_uri' => $baseUrl,\n ]);\n }", "title": "" }, { "docid": "0170387ae70c73b0dfae1ce505685120", "score": "0.6983791", "text": "public function getHttp()\n\t{\n\t\t$client = new \\Guzzle\\Http\\Client;\n\n\t\t$client->setSslVerification(false, false, false);\n\n\t\treturn $client;\n\t}", "title": "" }, { "docid": "c8c0f20041ee846c2df0860b9e299d26", "score": "0.69387496", "text": "protected function guzzleClient()\n {\n // Create a new HTTP Errors middleware with a body summarizer of length\n // 240 characters (the default is 120)\n $httpErrorsMiddleware = Middleware::httpErrors(new BodySummarizer(240));\n $stack = HandlerStack::create();\n $stack->remove('http_errors');\n $stack->unshift($httpErrorsMiddleware, 'http_errors');\n return new Client(['handler' => $stack]);\n }", "title": "" }, { "docid": "d0d2b02b9d7a3a755e97d73ccb13cac5", "score": "0.6880405", "text": "public function __construct()\n {\n $this->httpClient = new HttpClient();\n }", "title": "" }, { "docid": "fc69ed3898babd88e39afd26cf422c4d", "score": "0.68570536", "text": "public function __construct()\n {\n parent::__construct();\n $this->httpClient = new Client();\n }", "title": "" }, { "docid": "b057b10d74efaac403abb15e6b39f7fb", "score": "0.68555", "text": "protected function getGuzzleClientMock()\n\t{\n\t\t$c = m::mock('GuzzleHttp\\Client');\n\t\treturn $c;\n\t}", "title": "" }, { "docid": "fc38a71d8b7ccf3b4282859683a05d8f", "score": "0.6835885", "text": "public function __construct(Guzzle $guzzle = null)\n {\n $this->guzzle = null === $guzzle ? new Guzzle() : $guzzle;\n }", "title": "" }, { "docid": "cd6ba3da2e685811440db114c41053b8", "score": "0.6832559", "text": "function __construct() {\n\t\t//$this->httpClient = $this->client->getHttpClient();\n\t\t$this->httpClient = new GuzzleClient([\n\t\t\t'base_uri' => $this->base,\n\t\t\t'proxy' => '',\n\t\t]);\n\n\t\t//$hc = $this->httpClient;\n\t\t$hc = new AdapterClient($this->httpClient);\n\n\t\t$this->client = GithubClient::createWithHttpClient(\n\t\t\tnew\tHttpMethodsClient($hc,\n\t\t\t\tMessageFactoryDiscovery::find()\n\t\t\t)\n\t\t);\n\t}", "title": "" }, { "docid": "bbc03a60f96554dd09c7ecaa903cdf8d", "score": "0.6832012", "text": "private function getClient()\r\n {\r\n return $this->container->get('guzzle.client.api_pay_union');\r\n }", "title": "" }, { "docid": "4c4f7ba0c3e2e9cb9f9c5c0bcbeadc28", "score": "0.6831171", "text": "private function getClient(): Client\n {\n // create the client object and call\n return new Client();\n }", "title": "" }, { "docid": "5dcc405c1c5de654a2085c30269e02ac", "score": "0.6824941", "text": "public function __construct()\n {\n $this->client = new CurlHttpClient();\n }", "title": "" }, { "docid": "562acbcbf0810310d450acbc2fc5fe49", "score": "0.679926", "text": "protected function getClient()\n {\n if ($this->_guzzle == null) {\n $this->_guzzle = new HttpClient();\n }\n return $this->_guzzle;\n }", "title": "" }, { "docid": "0bc306cddf07458af28bb0ff2b059a99", "score": "0.679375", "text": "public function __construct()\n {\n parent::__construct();\n $this->client = new Client();\n }", "title": "" }, { "docid": "62d1310c43bf8f14b6441d9ba230963a", "score": "0.6789976", "text": "public function setGuzzleClient(\\GuzzleHttp\\Client $guzzleClient)\n {\n $this->guzzleClient = $guzzleClient;\n }", "title": "" }, { "docid": "4e551110601ccc2fb4a6cf3305d9f57b", "score": "0.67337096", "text": "protected function http()\n {\n return new Client;\n }", "title": "" }, { "docid": "4e551110601ccc2fb4a6cf3305d9f57b", "score": "0.67337096", "text": "protected function http()\n {\n return new Client;\n }", "title": "" }, { "docid": "78b2f8f0eb033d30a7c3210fec3d2a66", "score": "0.6715318", "text": "private function initializeClient()\n {\n $this->client = new Client($this->guzzleConfig);\n\n if ($this->isInDebugMode()) {\n $this->setDebugger();\n }\n if ($this->needsAuthentication()) {\n $this->authenticate();\n }\n\n return $this->client;\n }", "title": "" }, { "docid": "361bea3ab8b6703baaae7c631f284a8b", "score": "0.6705967", "text": "public function buildClient()\n {\n return new GuzzleClient([\n 'base_uri' => $this->apiPath(),\n 'headers' => [\n 'Content-Type' => 'application/json',\n 'X-TrackerToken' => $this->getToken()\n ]\n ]);\n }", "title": "" }, { "docid": "5adcc4ecb4b7cdb85766ca3d6cfd3a89", "score": "0.6697476", "text": "public function buildClient();", "title": "" }, { "docid": "a937525451943de2f41d18554330ee56", "score": "0.66612935", "text": "public function handle()\n {\n $client = new Client([\n 'base_uri' => 'http://58.20.36.50:8860/cod_cus/',\n 'timeout' => 5.0,\n 'headers' => [\n 'userToken' => 'eyJoZWFkZXIxIjoiaGVhZGVyMSB2YWx1ZTIiLCJhbGciOiJSUzI1NiJ9.eyJzdWIiOiJzaWduYXR1cmUiLCJjbGllbnRJZCI6IkJMUyIsImNsaWVudEtleSI6InRrMjM2NUU5OHU4NzQiLCJwYXNzd29yZCI6ImI0Mzk4MjA4MDVhODY5YzU2NTE2YjBhYzE5OWQ5OWQyN2QxMjhiZDUwMDMyNjI2MjcxOTdmZWQ2MzRlOGEwZGJhNzc0NDUyZmU0MmM1NTgwMDkyYTBkZTljNTBjNjk5ZGQwOGE3MmQ4YTVlMjM1OTRhODhlZDAxODVkYzRmZmYxOWZlZDQ0ZGY3MDhjMTE1MjFkM2I0NWRjNzA1NzE3NGZkZGJiMWFiM2FhZTZmNjJjMzU1ZjdhMDRlZGIyZGU3MDAzNWM3MWViNDJmNzBmOWY2NDhkZTcwNzNlMTdmYTUwMmUzZjI1YTY4YzdiZTRlYzA0NWY1MGIxNDJlNDdiNjkiLCJ1c2VyTmFtZSI6ImhoaGFuY2hvbmciLCJ0cyI6IjE1NzE2MjE0OTU5NTMifQ.sk510eixkq_BcUfkeNFkGwkLM0vfnOoBE-EpVsZyqTn9-wKKtGdUUMtOng4L-ggl4b43CCiYuGUuwc8AD0GvpdHinlw5R8gG_LNVYvBURBtH0NhdwyWulvED4OLuJP_9dS6ncXbmvTAdGhAOSjjvbTKvYj64NYI5rsM-3AYAzl2rli-c9T6YIZ-f37O3RIXqQpIaJTxlqHla4LTc9if6myG0DI_jUhcqW-EjAvhVXthatocCstu9OUpePod9vLq2ygKTEcrSDEmXLJFz_esCD8QhYQ3052XRvhW36CGFheU6GyLYuV-dG5IOq8VDtePLm0LXIViDmKoIHvx4_EbG3g'\n ]\n ]);\n\n $this->handleOnce($client);\n\n }", "title": "" }, { "docid": "5f5cc079e6cb8fdc3b730e0b54fcb018", "score": "0.6648763", "text": "public function getClient() {}", "title": "" }, { "docid": "5f5cc079e6cb8fdc3b730e0b54fcb018", "score": "0.6648763", "text": "public function getClient() {}", "title": "" }, { "docid": "f1c8d8d6d35b974f32b3adfe6a3c6de6", "score": "0.6622161", "text": "private function get_client() {\n\t\treturn $this->client;\n\t}", "title": "" }, { "docid": "f1c8d8d6d35b974f32b3adfe6a3c6de6", "score": "0.6622161", "text": "private function get_client() {\n\t\treturn $this->client;\n\t}", "title": "" }, { "docid": "f1c8d8d6d35b974f32b3adfe6a3c6de6", "score": "0.6622161", "text": "private function get_client() {\n\t\treturn $this->client;\n\t}", "title": "" }, { "docid": "007d432483e1f761cba8694de8aba8c5", "score": "0.6608525", "text": "public function __construct()\n {\n parent::__construct();\n $this->client = new Client([\n 'timeout' => 1000,\n 'verify' => false,\n ]);\n }", "title": "" }, { "docid": "13d00f48351283da8ff382b549cd5dfb", "score": "0.6604212", "text": "public function setUp(): void\n {\n $this->http = new GuzzleHttp\\Client(['base_uri' => 'http://web/api/']);\n }", "title": "" }, { "docid": "8b193a6112568d8fd81328ffb7b9f5fc", "score": "0.6590299", "text": "public function client()\n {\n }", "title": "" }, { "docid": "d5e6471b4802e0d189e9c6c2b97c2113", "score": "0.6578738", "text": "public function getHttpClient()\n {\n // @codeCoverageIgnoreStart\n if (!$this->httpClient) {\n if (interface_exists(GuzzleClientInterface::class)\n && ((defined(GuzzleClientInterface::class.'::VERSION') && Util::compareGuzzleVersion(\n constant(GuzzleClientInterface::class.'::VERSION'),\n '6.0.0'\n ) >= 0)\n || (defined(GuzzleClientInterface::class.'::MAJOR_VERSION') && Util::compareGuzzleVersion(\n constant(GuzzleClientInterface::class.'::MAJOR_VERSION'),\n '7.0.0'\n ) >= 0))\n ) {\n $this->httpClient = new GuzzleClient();\n }\n\n if (!$this->httpClient && class_exists(HttpAsyncClientDiscovery::class)) {\n try {\n // Detect PHP HTTPlug async HTTP client support\n if (HttpAsyncClientDiscovery::find()) {\n $this->httpClient = new HTTPlugClient();\n }\n } catch (\\Http\\Discovery\\Exception\\NotFoundException $e) {\n } catch (NoCandidateFoundException $e) {\n } catch (DiscoveryFailedException $e) {\n } catch (ClassInstantiationFailedException $e) {\n }\n }\n\n if (!$this->httpClient && class_exists(Psr18ClientDiscovery::class)) {\n try {\n // Detect PHP HTTPlug PSR-18 HTTP client support\n if (Psr18ClientDiscovery::find()) {\n $this->httpClient = new HTTPlugClient();\n }\n } catch (\\Http\\Discovery\\Exception\\NotFoundException $e) {\n } catch (NoCandidateFoundException $e) {\n } catch (DiscoveryFailedException $e) {\n } catch (ClassInstantiationFailedException $e) {\n }\n }\n\n if (!$this->httpClient && class_exists(HttpClientDiscovery::class)) {\n try {\n // Detect PHP HTTPlug HTTP client support\n if (HttpClientDiscovery::find()) {\n $this->httpClient = new HTTPlugClient();\n }\n } catch (\\Http\\Discovery\\Exception\\NotFoundException $e) {\n } catch (NoCandidateFoundException $e) {\n } catch (DiscoveryFailedException $e) {\n } catch (ClassInstantiationFailedException $e) {\n }\n }\n\n if (!$this->httpClient) {\n $this->httpClient = new CurlClient();\n }\n\n $this->httpClient->setLogger($this->getLogger());\n $this->httpClient->setVerify($this->verifySslCerts);\n }\n // @codeCoverageIgnoreEnd\n\n $this->httpClient->setRequestFactory($this->getRequestFactory());\n $this->httpClient->setResponseFactory($this->getResponseFactory());\n $this->httpClient->setStreamFactory($this->getStreamFactory());\n\n return $this->httpClient;\n }", "title": "" }, { "docid": "a525bbdd421aa1f2867307ca8c2da1fa", "score": "0.65709215", "text": "public static function client()\n {\n $client = new Client(['verify' => false]);\n return $client;\n }", "title": "" }, { "docid": "3298d3534edace9e3b41a25eb2337126", "score": "0.6517268", "text": "protected function initializeClient() : self {\n $this->client = new GuzzleClient([\n 'headers' => [\n 'Accept' => 'application/json',\n 'Accept-Encoding' => 'gzip, deflate',\n 'Cache-Control' => 'max-age=0',\n 'User-Agent' => sprintf('FreedomCore Media/%s Jackett Client', env('APP_VERSION'))\n ],\n 'timeout' => $this->timeout,\n 'allow_redirects' => [\n 'max' => $this->maxRedirects,\n ],\n 'debug' => $this->debug\n ]);\n return $this;\n }", "title": "" }, { "docid": "02c92329c0f613c55a18a7dedb08aa26", "score": "0.65122426", "text": "public function setClient(Guzzle\\Http\\Client $client) {\n $this->client = $client;\n }", "title": "" }, { "docid": "15a6124f04c32e2056cf663280abadd1", "score": "0.64822257", "text": "public function __construct()\n {\n parent::__construct();\n\n $this->client = GuzzleFactory::make([\n 'base_uri' => 'https://www.arkvatar.com/arkvatar/',\n 'allow_redirects' => false,\n ]);\n }", "title": "" }, { "docid": "de908fc3e4144d7ee5af91a7007e2ecf", "score": "0.64397156", "text": "private function initiateHttpClient()\n {\n $options = [\n 'headers' => [\n 'Content-Type' => 'application/json',\n 'Accept' => 'application/json',\n 'Authorization' => $this->apiKey,\n ]\n ];\n\n $this->httpClient = new GuzzleClient(array_replace_recursive($this->clientOptions, $options));\n }", "title": "" }, { "docid": "cad027fc2d78b8be38d4ecfe7224c93c", "score": "0.6438647", "text": "public function getClient() {\n if (!$this->_client instanceof Client) {\n $this->_client = new Client();\n $options = [\n 'maxredirects' => 0,\n 'timeout' => 30\n ];\n $this->_client->setOptions($options);\n $this->_client->setHeaders([\n 'Authorization' => 'Bearer ' . $this->token,\n 'Content-Type' => 'application/json'\n ]);\n }\n\n return $this->_client;\n }", "title": "" }, { "docid": "a3dc37429809d43d28a6fc490bd9f429", "score": "0.6418302", "text": "private function getClient() {\n return $this->client;\n }", "title": "" }, { "docid": "45b5e111ecd59d2e906cac9dacf90cf2", "score": "0.6408738", "text": "static private function setHTTPClient() {\n self::$handler = new \\GuzzleHttp\\Handler\\CurlMultiHandler();\n self::$http = new \\GuzzleHttp\\Client(array(\n 'handler' => \\GuzzleHttp\\HandlerStack::create(self::$handler)\n ));\n }", "title": "" }, { "docid": "d4f7b39cbff8bb9f71b0979c2d99fe6e", "score": "0.64041775", "text": "public function setClient(\\Phalconry\\Http\\Client $client) {}", "title": "" }, { "docid": "baabc1a90230cf18955336a7f61d666d", "score": "0.6398574", "text": "public static function getClient() {\n return self::$client;\n }", "title": "" }, { "docid": "9e75bfd2e14ecdc2d0e0591cf69c57c4", "score": "0.639435", "text": "public function __construct($client)\n {\n $this->client = $client;\n }", "title": "" }, { "docid": "9e75bfd2e14ecdc2d0e0591cf69c57c4", "score": "0.639435", "text": "public function __construct($client)\n {\n $this->client = $client;\n }", "title": "" }, { "docid": "d7f69d255f7f396d5e5c855675d5c4e1", "score": "0.63920236", "text": "public function getClient() {\n return $this->client;\n }", "title": "" }, { "docid": "d7f69d255f7f396d5e5c855675d5c4e1", "score": "0.63920236", "text": "public function getClient() {\n return $this->client;\n }", "title": "" }, { "docid": "d7f69d255f7f396d5e5c855675d5c4e1", "score": "0.63920236", "text": "public function getClient() {\n return $this->client;\n }", "title": "" }, { "docid": "d7f69d255f7f396d5e5c855675d5c4e1", "score": "0.63920236", "text": "public function getClient() {\n return $this->client;\n }", "title": "" }, { "docid": "c37b905630affdef1d14d8f19ca182e0", "score": "0.63915205", "text": "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 }", "title": "" }, { "docid": "134aa0d60e5a14b4e4cf3a15dfae8c22", "score": "0.63872975", "text": "private function getClient(): HttpClientInterface\n {\n return HttpClient::create([\n 'base_uri' => self::URI_API\n ]);\n }", "title": "" }, { "docid": "8ec117a8bc4291d13d7fa7ac52956e64", "score": "0.6386489", "text": "public function setUp()\n {\n $this->client = new Client(['base_uri' => 'http://127.0.0.1:8000/']);\n }", "title": "" }, { "docid": "4a63ef91e6177ea91d04187baff53eca", "score": "0.6375123", "text": "private function prepareHttpClient() {\n $clientsetup = [];\n $headers = [];\n // Set the API key header for the request.\n $headers['Authorization'] = 'Bearer' . ' ' . $this->apiKey;\n\n // Using http proxy\n if (isset($this->options['proxy'])) {\n $clientsetup['request.options'] = [\n 'proxy' => $this->options['proxy'],\n ];\n }\n $headers['User-Agent'] = 'sendgrid/' . $this->version . ';php';\n // Create an empty stack for error processing.\n // Guzzlehttp will choose the most appropriate handler based on the system.\n if (empty($this->options['handler'])) {\n $stack = HandlerStack::create();\n }\n else {\n $stack = $this->options['handler'];\n }\n $clientsetup['base_uri'] = $this->url;\n $clientsetup['handler'] = $stack;\n $clientsetup['headers'] = $headers;\n\n return new \\GuzzleHttp\\Client($clientsetup);\n }", "title": "" }, { "docid": "5097460e166686e23c63026a5506320a", "score": "0.6367039", "text": "public function client();", "title": "" }, { "docid": "425147fe9b3d5e03b4741bee05f505ec", "score": "0.63659453", "text": "public function getHttpClient()\n {\n \treturn $this->_client;\n }", "title": "" }, { "docid": "8507a047e6a7d097d8d5c6d2ec495249", "score": "0.6363236", "text": "public function testGetClient()\n {\n $client = $this->object->getClient();\n\n $this->assertInstanceOf('GuzzleHttp\\ClientInterface', $client);\n $this->assertSame($this->client, $client);\n }", "title": "" }, { "docid": "2e1bee1e32b6bf406b0783b597d781de", "score": "0.6362861", "text": "public function getClient();", "title": "" }, { "docid": "2e1bee1e32b6bf406b0783b597d781de", "score": "0.6362861", "text": "public function getClient();", "title": "" }, { "docid": "2e1bee1e32b6bf406b0783b597d781de", "score": "0.6362861", "text": "public function getClient();", "title": "" }, { "docid": "aacd073f31497869b32b6e9e202769ba", "score": "0.63622993", "text": "protected function guzzle(array $config)\n {\n return new HttpClient(Arr::add(\n $config['guzzle'] ?? [],\n 'connect_timeout',\n 60\n ));\n }", "title": "" }, { "docid": "aacd073f31497869b32b6e9e202769ba", "score": "0.63622993", "text": "protected function guzzle(array $config)\n {\n return new HttpClient(Arr::add(\n $config['guzzle'] ?? [],\n 'connect_timeout',\n 60\n ));\n }", "title": "" }, { "docid": "50a9c44551929605cc37b9af38da554c", "score": "0.63328147", "text": "public function __construct(Client $client) \n\t{\n\t\t$this->client = $client;\n\t}", "title": "" }, { "docid": "6c7d73dc22adfcd10b5197412b23bc68", "score": "0.6328838", "text": "public function __construct(ClientInterface $http_client) {\n $this->httpClient = $http_client;\n }", "title": "" }, { "docid": "6e6e0408059143ff1bbeb0b5c8dd7b85", "score": "0.6324604", "text": "protected static function getFacadeAccessor()\n {\n return 'GuzzleHttp\\Client';\n }", "title": "" }, { "docid": "4a24a8f2640631c89e464e6ac45269c8", "score": "0.6314991", "text": "public function client()\n {\n return $this->client;\n }", "title": "" }, { "docid": "5ef37db2e9c49ddc135c03f565ec386d", "score": "0.63073504", "text": "protected function getClient()\n {\n return $this->httpClient;\n }", "title": "" }, { "docid": "1ddef56327c342d9774b55c6ea56eeee", "score": "0.6295797", "text": "protected function _getInstanceOfClient()\n\t{\n\t\treturn minimee()->makeClient();\n\t}", "title": "" }, { "docid": "13f15d479c11722b68e0cc1e45a63633", "score": "0.62889457", "text": "public function __construct(Client $client)\n {\n $this->client = $client;\n }", "title": "" }, { "docid": "13f15d479c11722b68e0cc1e45a63633", "score": "0.62889457", "text": "public function __construct(Client $client)\n {\n $this->client = $client;\n }", "title": "" }, { "docid": "13f15d479c11722b68e0cc1e45a63633", "score": "0.62889457", "text": "public function __construct(Client $client)\n {\n $this->client = $client;\n }", "title": "" }, { "docid": "13f15d479c11722b68e0cc1e45a63633", "score": "0.62889457", "text": "public function __construct(Client $client)\n {\n $this->client = $client;\n }", "title": "" }, { "docid": "13f15d479c11722b68e0cc1e45a63633", "score": "0.62889457", "text": "public function __construct(Client $client)\n {\n $this->client = $client;\n }", "title": "" }, { "docid": "13f15d479c11722b68e0cc1e45a63633", "score": "0.62889457", "text": "public function __construct(Client $client)\n {\n $this->client = $client;\n }", "title": "" }, { "docid": "13f15d479c11722b68e0cc1e45a63633", "score": "0.62889457", "text": "public function __construct(Client $client)\n {\n $this->client = $client;\n }", "title": "" }, { "docid": "8b3cf7276bd63d2b695dd3e857be53c7", "score": "0.6283825", "text": "public function getGuzzleResponse();", "title": "" }, { "docid": "0923dd890f2e4fae050623b4197a8fd1", "score": "0.6278742", "text": "public function getHttpClient(): HttpClient;", "title": "" }, { "docid": "c68c83110a80c1722c575dd429c6b02e", "score": "0.62743413", "text": "protected function getRequest(){\n $client = $this->client;\n if(!$client instanceof Client){\n $client = new Client();\n }\n return $client;\n }", "title": "" }, { "docid": "d4ab90092e508150ef9009d632996b23", "score": "0.62716323", "text": "public function getClient() {\n return $this->client;\n }", "title": "" }, { "docid": "d0d967b525ec87c8f01e9b16538fcbcc", "score": "0.62619895", "text": "public function __construct(Client $client)\n\t{\n\t\t$this->client = $client;\n\t}", "title": "" }, { "docid": "b09a4ea11702dda1731c105ba5aff9ef", "score": "0.62573385", "text": "public function getHttpClient();", "title": "" }, { "docid": "6da070c8cd02cd8505f5422df0f228e5", "score": "0.6256405", "text": "public static function client(){\n\t\tif(!self::$client){\n\t\t\tself::$client = new self();\n\t\t}\n\t\treturn self::$client;\n\t}", "title": "" }, { "docid": "e1992167fb65a54f3b030eb8baf43825", "score": "0.6249166", "text": "public function setUp(){\n $this->client = static::createClient();\n }", "title": "" }, { "docid": "4bb90cdfdc2394b3fb8164e51deabfb6", "score": "0.62445444", "text": "public function __construct()\n {\n $this->http = new HttpClient(['base_uri' => env('EXAMPLE_ENDPOINT'), 'http_errors' => false]);\n }", "title": "" }, { "docid": "ce003d9019b149dc740306c905317915", "score": "0.6241438", "text": "public function setClient($token){\n $this->_client = new Guzzle([\n 'base_url' => $this->_mediumBaseApiUrl,\n 'headers' => [\n 'Content-Type' => 'application/json',\n 'Accept' => 'application/json',\n 'Accept-Charset' => 'utf-8',\n 'Authorization' => 'Bearer ' . $token,\n ]\n ]);\n }", "title": "" }, { "docid": "a2c1dd94270a397a1b3ec7aaa5a0b4da", "score": "0.6234699", "text": "public static function get() {\n\t\tif (self::$client == null)\n\t\t\tself::$client = new Client();\n\t\treturn self::$client;\n\t}", "title": "" } ]
8de458809c26fb94acbbfbb8623c2ecd
Send transactional email to recipient
[ { "docid": "1a2667b210b5aa85faf2d2fa912eaf96", "score": "0.0", "text": "public function sendTransactional($templateId, $sender, $email, $name, $vars=array(), $storeId=null)\n {\n $this->setSentSuccess(false);\n if (($storeId === null) && $this->getDesignConfig()->getStore()) {\n $storeId = $this->getDesignConfig()->getStore();\n }\n\n if (is_numeric($templateId)) {\n $this->load($templateId);\n } else {\n $localeCode = Mage::getStoreConfig('general/locale/code', $storeId);\n $this->loadDefault($templateId, $localeCode);\n }\n\n if (!$this->getId()) {\n throw Mage::exception('Mage_Core', Mage::helper('core')->__('Invalid transactional email code: ' . $templateId));\n }\n\n if (!is_array($sender)) {\n $this->setSenderName(Mage::getStoreConfig('trans_email/ident_' . $sender . '/name', $storeId));\n $this->setSenderEmail(Mage::getStoreConfig('trans_email/ident_' . $sender . '/email', $storeId));\n } else {\n $this->setSenderName($sender['name']);\n $this->setSenderEmail($sender['email']);\n }\n\n if (!isset($vars['store'])) {\n $vars['store'] = Mage::app()->getStore($storeId);\n }\n\n if (Mage::getStoreConfig(\"gemgento_email/settings/enabled\")) {\n $this->setSentSuccess($this->gemgentoSend($email, $name, $vars));\n } else {\n $this->setSentSuccess($this->send($email, $name, $vars));\n }\n\n return $this;\n }", "title": "" } ]
[ { "docid": "940d050d1d523cbd484192f562f4d706", "score": "0.7150296", "text": "protected function _sendTransactional()\n {\n /* @var $options Varien_Object */\n $options = $this->_emailOptions;\n /* @var $mailTemplate Mage_Core_Model_Email_Template */\n $mailTemplate = $this->_emailModel;\n\n if (!$options || !$mailTemplate) {\n throw Mage::exception('Symmetrics_Buyerprotect', 'Email options/model is not set!');\n }\n\n $mailTemplate->sendTransactional(\n $options->getTemplate(),\n $options->getSender(),\n $options->getRecipient(),\n null,\n $options->getPostObject()\n );\n\n if (!$mailTemplate->getSentSuccess()) {\n throw Mage::exception('Symmetrics_Buyerprotect', 'Email couldn\\'t get sent!');\n }\n\n $this->_emailOptions = null;\n\n return;\n }", "title": "" }, { "docid": "1a9d9c617871109f2f3d99920d7055cf", "score": "0.68831396", "text": "private function sendActivationEmail(){\n\n }", "title": "" }, { "docid": "46b7e85dbe1ce60dad607f6b2c5792cf", "score": "0.6857183", "text": "public function send_email () {\n\t \t\t\n\t \t\t// TO DO\n\t \t\t\n\t \t}", "title": "" }, { "docid": "09030a58b651225fd6174ee28cbe5cbe", "score": "0.68251", "text": "public function sendMail()\n {\n $id = 2;\n $model = $this->manager->create()->load($id);\n\n $this->inlineTranslation->suspend();\n $array = [\n 'store' => $this->_storeManager->getStore(),\n 'store URL' => $this->_storeManager->getStore()->getBaseUrl(),\n 'ticket_code' => $this->getCode(),\n 'customer_name' => $this->getCustomerName(),\n ];\n\n $this->_logger->debug(print_r($model,true));\n// $transport = $this->_transportBuilder->setTemplateIdentifier('calltoorder_email_template')->setTemplateOptions(\n// [\n// 'area' => Area::AREA_FRONTEND,\n// 'store' => $this->_storeManager->getStore()->getId(),\n// ]\n// )->setTemplateVars(\n// [\n// 'store' => $this->_storeManager->getStore(),\n// 'store URL' => $this->_storeManager->getStore()->getBaseUrl(),\n// 'ticket_code' => $this->getCode(),\n// 'customer_name' => $this->getCustomerName(),\n// ]\n// )->setFrom(\n// [\n// 'email' => $this->_scopeConfig->getValue(self::XML_PATH_EMAIL_SENDER),\n// 'name' => $this->_scopeConfig->getValue(self::XML_PATH_NAME_SENDER)\n// ]\n// )->addTo(\n// $model->getEmail(),\n// $model->getName()\n// )->getTransport();\n// $transport->sendMessage();\n// $this->inlineTranslation->resume();\n }", "title": "" }, { "docid": "edca53236ebee0a366060800b8413732", "score": "0.67655337", "text": "private function sendEmail()\n {\n\n }", "title": "" }, { "docid": "1d6a73ee03bce383681c5fce7d7759b5", "score": "0.6587068", "text": "private function sendEmails()\n {\n\t\tif(\\Cart2Quote\\License\\Model\\License::getInstance()->isValid()) {\n\t\t\tif ($this->globalConfig->getValue('sales_email/general/async_sending')) {\n $this->entityCollection->addFieldToFilter($this->emailSender->getSendEmailIdentifier(), ['eq' => 1]);\n $this->entityCollection->addFieldToFilter($this->emailSender->getEmailSentIdentifier(), ['null' => true]);\n /** @var \\Magento\\Sales\\Model\\AbstractModel $item */\n foreach ($this->entityCollection->getItems() as $item) {\n $this->emailSender->send($item, true);\n }\n }\n\t\t}\n\t}", "title": "" }, { "docid": "ad8c20eb837c4b0ece771ffadc51196a", "score": "0.6550625", "text": "private function sendEmail(){\r\n \r\n $arr=array(\"drecipient\",\"dsubject\",\"dbody\");\r\n \r\n $this->checkFormBlanks($arr);\r\n \r\n $this->recoverFormData($arr);\r\n \r\n if(strlen($_POST['drecipient'])<5){\r\n \r\n $_SESSION['amberr']['drecipient2']=\"huh?\";\r\n \r\n }//if\r\n \r\n if(!isset($_SESSION['amberr'])){\r\n \r\n $this->clearNotifications();\r\n \r\n $subject=strip_tags($_POST['dsubject']);\r\n \r\n $sender=$this->model->getSender();\r\n \r\n $recipients=$this->getRecipients($_POST['drecipient']);\r\n \r\n $mailer=new \\Amba\\Core\\AmbaMailer($sender->senderName,$sender->senderAddress,$sender->rawPassword);\r\n \r\n $sent=$mailer->sendMail($recipients,$subject,$_POST['dbody']);\r\n \r\n if($sent && ALLOWOUTBOX){\r\n \r\n $this->model->saveOutGoingMail($recipients,$subject,$_POST['dbody']);\r\n \r\n }//if\r\n \r\n }//if\r\n \r\n if(isset($sent) && $sent==true){\r\n \r\n if(ALLOWOUTBOX!==true){\r\n \r\n header(\"Location: \".AMBALINK.\"demo/\");\r\n \r\n }//if\r\n else{\r\n \r\n header(\"Location: \".AMBALINK.\"outbox/#hustle\");\r\n \r\n }//else\r\n \r\n }//if\r\n \r\n }", "title": "" }, { "docid": "e2fa40de74b0144f429f06154548f432", "score": "0.6516745", "text": "private function sendEmail()\n {\n //setup email config\n $email = $this->prepareEmail();\n $mh = Loader::helper('mail');\n\n //1. send email to client\n $mh->to($email['to']);\n $mh->from($email['from']);\n $mh->replyto($email['replyto']);\n $mh->setSubject($email['subject']);\n $mh->setBodyHTML($email['body']);\n $mh->sendMail();\n\n //2. send confirmation email to person who submitted the form\n if ($this->config->sendConfirmationEmail===TRUE && $this->config->emailConfirmationSubject != \"\") {\n $mh->reset(); //resets the class scope variables.\n $mh->to($email['replyto']);\n $mh->from($email['from']);\n $mh->setSubject($this->config->emailConfirmationSubject);\n $mh->setBodyHTML($this->getEmailConfirmationBody());\n $mh->sendMail();\n }\n }", "title": "" }, { "docid": "02fe65763bf3746fb38999a18e7cc818", "score": "0.6510138", "text": "public function sendEmail()\n {\n\n (new EmailHelper() )->sendEmail($this->item->itemSeller->email, [], 'Reported Item : '. $this->item->name, 'item/report-item', [ 'report' => $this, 'seller' => $this->item->itemSeller]);\n\n $toEmail = (new AppSetting())->getByAttribute('admin_email');\n\n (new EmailHelper() )->sendEmail($toEmail, [], 'Reported Item : '. $this->item->name, 'item/report-item-admin', [ 'report' => $this, 'seller' => $this->item->itemSeller]);\n }", "title": "" }, { "docid": "8629a739410fee5c3d8836a1c69d38b5", "score": "0.64041054", "text": "static public function sendMail()\n {\n \\Mail::send('auth.mail.mail_confirm', $data, function($message) use ($data) {\n $message\n ->locale('es')\n ->to($data['email'], $data['nb_usuario'])\n ->subject('\"DesdeCasaWeb.com\", Por favor confirma tu correo')\n ->queue(new OrderShipped($order));\n });\n }", "title": "" }, { "docid": "68b6d28730d0a9484c09334f8dbfe31a", "score": "0.6399648", "text": "public function sendReceipt() {\n\t\t$this->sendEmail(\n\t\t\t'Order_ReceiptEmail',\n\t\t\tConfig::inst()->get('OrderProcessor', 'bcc_receipt_to_admin')\n\t\t);\n\t\t$this->order->ReceiptSent = SS_Datetime::now()->Rfc2822();\n\t\t$this->order->write();\n\t}", "title": "" }, { "docid": "1b9c96ef3776e02875ed55449a03b63d", "score": "0.63865036", "text": "public function sendEmailToCustomer()\n {\n Mail::to($this->model->customer_email)\n ->send(new SendOrderToCustomerMailable($this->findOrderById($this->model->id)));\n }", "title": "" }, { "docid": "750f78f3f54050454c41a899d4b55861", "score": "0.6316067", "text": "function dsf_send_voucher_mail($savedorder, $address_confirmations=''){\nglobal $cart, $customer_id, $payment, $currencies;\n\n\t\t\t\n\t\t\t\t// Send an email notification to the customer.\n\t\t\t\n\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t$email_query = dsf_db_query(\"select subject, details from \". DS_DB_SHOP . \".email_templates where id ='13'\");\n\t\n// lets start with the email confirmation\n\n\t\t\t\t\t\t \n\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t$email_details = dsf_db_fetch_array($email_query);\n\t\t\t\t\t\t\t\t\t\t$signature_query = dsf_db_query(\"select subject, details from \". DS_DB_SHOP . \".email_templates where id ='1'\");\n\t\t\t\t\t\t\t\t\t $signature_details = dsf_db_fetch_array($signature_query);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t $email_subject = $email_details['subject'];\n\t\t\t\t\t\t\t\t\t $email_footer = $signature_details['details'];\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t// overwrite subject as per Christian emails 2011-09-28\n\t\t\t\t\t\t\t\t\t $email_subject = TRANSLATION_EMAIL_YOUR_ORDER . ' ' . SAP_ORDER_PREFIX . $savedorder->info['id'];\n\n\n\t\t\t\t\t\t\t\t// plain text;\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t $email_order = TRANSLATION_WORD_DEAR . ' ' . $savedorder->customer['name'] . \"\\n\\n\" . $email_details['details'] . \"\\n\";\n\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t// get products ordered by doing email function.\n\t\t\t\t\t\t\t\t\t $products_ordered = dsf_order_email_items($savedorder, 'true');\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t $email_order .= $products_ordered['plain'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t $email_order .= \"\\n\" .EMAIL_SEPARATOR .\"\\n\" . $email_footer;\n\t\t\t\t\t\t \n\t\t\t\t\t\t \n\t\t\t\t\t\t \t\t// html\n\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t $html_order = TRANSLATION_WORD_DEAR . ' ' . $savedorder->customer['name'] . \"<br /><br />\";\n\t\t\t\t\t\t\t\t\t $html_order .= nl2br($email_details['details']) . \"<br /><br />\";\n\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t $html_order .= $products_ordered['html'] . '<br /><br />';\n\t\t\t\t\t\t\t\t\t $html_order .= nl2br($email_footer);\n\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t $email_order = str_replace(\"[ORDER_NUMBER]\" , SAP_ORDER_PREFIX . $savedorder->info['id'], $email_order);\n\t\t\t\t\t\t\t\t\t $html_order = str_replace(\"[ORDER_NUMBER]\" , SAP_ORDER_PREFIX . $savedorder->info['id'], $html_order);\n\t\t\t\t\t\t \n\t\t\t\t\t\t // end of email.\n\t\t\t\t\t\t \n\t\t\t\t\t\t \n \n \n\t\t\t\t\t dsf_send_email($savedorder->customer['name'], $savedorder->customer['email_address'], $email_subject, $email_order, STORE_OWNER, EMAIL_FROM,$html_order);\n\t\t\t\t\t\n\t\t\t\t\t// send emails to other people\n\t\t\t\t\t if (SEND_EXTRA_ORDER_EMAILS_TO != '') {\n\t\t\t\t\t\tdsf_send_email(STORE_OWNER, SEND_EXTRA_ORDER_EMAILS_TO, $email_subject, $email_order, STORE_OWNER, EMAIL_FROM,$html_order);\n\t\t\t\t\t }\n\n\t\t\t\t\t if (SEND_EXTRA_ORDER_EMAILS_DUPLICATE != '') {\n\t\t\t\t\t\tdsf_send_email(STORE_OWNER, SEND_EXTRA_ORDER_EMAILS_DUPLICATE, $email_subject, $email_order, STORE_OWNER, EMAIL_FROM,$html_order);\n\t\t\t\t\t }\n\n\n// just for consistancy.\n\nreturn true;\n\n\n\n\n}", "title": "" }, { "docid": "4e736b40c09d0e8c58d9c7da5551295e", "score": "0.6307365", "text": "public function sendEmailToCustomer()\n {\n Mail::to($this->model->customer)\n ->send(new SendOrderToCustomerMailable($this->findOrderById($this->model->id)));\n }", "title": "" }, { "docid": "7a261bbbb73c0cb541c1f6eb8ddb89ad", "score": "0.6307265", "text": "public function sendmail()\n {\n \n }", "title": "" }, { "docid": "39f222f68d24f5db85d5f837b2aeb7e8", "score": "0.62972814", "text": "public function sendActivationEmail(){\n\n $url = 'http://' . $_SERVER['HTTP_HOST'] . '/signup/account-activation/' . $this->activation_token->getValue();\n $body = View::getTemplate('SignUP/activation_email.html', [\n 'first_name' => $this->first_name,\n 'site_name' => Config::SITE_NAME,\n 'url' => $url\n ]);\n Mail::send($this->email, 'Account activation', 'Account activation', $body);\n\n }", "title": "" }, { "docid": "a60e2ec231ee3410cf222d6f915bbf4d", "score": "0.627278", "text": "public function sendScheduleEmail() {\r\n $collection = Mage::getResourceModel('giftvoucher/giftvoucher_collection');\r\n $collection->addFieldToFilter('is_sent', array('neq' => 1))\r\n ->addFieldToFilter('day_to_send', array('notnull' => true))\r\n ->addFieldToFilter('day_to_send', array('to' => now(true)));\r\n if (count($collection)) {\r\n $translate = Mage::getSingleton('core/translate');\r\n $translate->setTranslateInline(false);\r\n foreach ($collection as $giftCard) {\r\n if ($giftCard->sendEmailToRecipient()) {\r\n try {\r\n $giftCard->setData('is_sent', 1)\r\n ->save();\r\n } catch (Exception $e) {\r\n Mage::logException($e);\r\n }\r\n }\r\n }\r\n $translate->setTranslateInline(true);\r\n }\r\n }", "title": "" }, { "docid": "8f5a043ac7b848b8ab6017c19612ff00", "score": "0.62668884", "text": "public function trackingSendEmail() {\n $this->sendEmail();\n }", "title": "" }, { "docid": "e75e9b677dbbe00169eaf03112831fb4", "score": "0.6247261", "text": "public function sendEmail()\n {\n // Validation for the 'send email' form to make sure all fields are validated with the correct info\n $this->validate([\n 'message_to' => ['required', 'string', 'email', 'max:60', 'exists:users,email'],\n 'subject' => ['required', 'string', 'max:45'],\n 'message' => ['required', 'string', 'max:140'],\n\n ], [\n 'subject.max' => 'Subject is too long, 45 character is the limit',\n 'message.max' => '140 characters are the limit!!',\n 'message_to.email' => 'Invalid email address format, please try again',\n 'message_to.exists' => 'Not a varified email, please enter a varified email.'\n\n ]);\n\n // sending the email via mailgun, tested for only specific users due to restriction by mailgun\n // using the SendingEmails Job to send the requested email then storing the message in the database if succesaful\n // otherwise and exception error message will be thrown\n try {\n SendingEmails::dispatch($this->message, $this->message_to, $this->subject);\n $this->jobStatus = true;\n } catch (\\Exception $e) {\n\n // Send message to user saying it has been unsuccessful\n session()->flash('error', 'your message was not sent!');\n }\n\n // makes sure email is stored in the database after job is dispatched\n if ($this->jobStatus == true) {\n $this->storeEmail();\n }\n }", "title": "" }, { "docid": "53a785a4c95d9e2b3736d81bc4e61129", "score": "0.62457424", "text": "function sendEmailToBuyer($emailAddress) {\n}", "title": "" }, { "docid": "3c13812bf5b34ea9de9247cef052f571", "score": "0.6240853", "text": "public function send() {\n list($to, $subject, $body, $headers, $additional) = $this->toArray();\n mail($to, $subject, $body, $headers, $additional);\n }", "title": "" }, { "docid": "d65ae162ab12eb92a0de55c3c540a570", "score": "0.62302524", "text": "function sendEmailToBuyer($emailAddress) {\r\n}", "title": "" }, { "docid": "0055efe18b3ab3645407ab47a58a82f6", "score": "0.6218394", "text": "public function sendMail($reciever, $templateId) {\n $objectManager = \\Magento\\Framework\\App\\ObjectManager::getInstance();\n $transportBuilder = $objectManager->create('\\Magento\\Framework\\Mail\\Template\\TransportBuilder');\n $scopeConfig = $objectManager->create('\\Magento\\Framework\\App\\Config\\ScopeConfigInterface'); \n //Name and Email Address of Sales Representative.\n $salesName = $scopeConfig->getValue('trans_email/ident_sales/name', \\Magento\\Store\\Model\\ScopeInterface::SCOPE_STORE);\n $salesEmail = $scopeConfig->getValue('trans_email/ident_sales/email', \\Magento\\Store\\Model\\ScopeInterface::SCOPE_STORE);\n $sender = [\n 'name' => $salesName,\n 'email' => $salesEmail,\n ];\n\n $transport = $transportBuilder\n ->setTemplateIdentifier($templateId)\n ->setTemplateOptions(\n [\n 'area' => \\Magento\\Framework\\App\\Area::AREA_FRONTEND,\n 'store' => \\Magento\\Store\\Model\\Store::DEFAULT_STORE_ID,\n ]\n )\n ->setTemplateVars(['data' => 'data'])\n ->setFrom($sender)\n ->addTo($reciever)\n ->getTransport();\n $transport->sendMessage();\n }", "title": "" }, { "docid": "a629e292e6e1de358a6d23623eadcc57", "score": "0.6200265", "text": "public function send_to_email($id)\n {\n if (!has_permission('manageSales')) {\n access_denied('manageSales');\n }\n $success = $this->proposals_model->sent_proposal_to_email($id, 'proposal-send-to-customer', $this->input->post('attach_pdf'));\n if ($success) {\n set_alert('success', _l('proposal_sent_to_email_success'));\n } else {\n set_alert('danger', _l('proposal_sent_to_email_fail'));\n }\n redirect(admin_url('proposals/list_proposals/' . $id));\n }", "title": "" }, { "docid": "8e8bbf52505a793b93e10c94e029ab91", "score": "0.61991227", "text": "private function sendMail()\n {\n IlluminateMail::send($this->target->view, [], function ($message) {\n $fromAddress = Arr::get($this->target->config, 'from.address');\n\n $message->returnPath($fromAddress);\n\n $message->cc($fromAddress);\n\n $message->bcc($fromAddress);\n\n $message->replyTo($fromAddress);\n\n $message->to($this->target->to);\n\n $message->subject($this->target->subject);\n });\n }", "title": "" }, { "docid": "32126442710cb305ff7d11efcfb09fcb", "score": "0.6191587", "text": "private function sendEmailtoSalesPerson($salesPersonId,$country,$txtPhone,$fname,$lname,$adminEmail){\n $country_name = $this->Signupmodel->getCountyNamebyId($country);\n $adminArray = array(\n 'name' => $fname . ' ' . $lname,\n 'email' => $adminEmail,\n 'phone' => $txtPhone,\n 'country' => $country\n );\n if ($salesPersonId > 0) {\n $salesPersonDetails = $this->Signupmodel->getSalesPerson($salesPersonId);\n if ($salesPersonDetails[0]->vsales_person_email != \"\") {\n $emailTplSalesPerson = $this->Signupmodel->emailTemplateForSalesPerson(ucfirst($salesPersonDetails[0]->vsales_person_name), $adminArray);\n $to = $salesPersonDetails[0]->vsales_person_email;\n $subject = \"Your customer \" . ucwords($adminArray['name']) . \" signed up for Credit Repair Cloud Free Trial! (survey)\";\n $from = \"support@creditrepaircloud.com\";\n $fromName = \"Credit Repair Cloud\";\n $email_Sent = $this->sendSalesPersonEmail($to, $subject, $emailTplSalesPerson, $from, $fromName);\n }\n }\n #-=-=-START Code for send terms & conditions agreement mail to Daniel=-=-=-#\n $to_daniel = \"sales@credit-aid.com\";\n $subject_terms = \"Agreement of terms, refund policy, charge authorization for Credit Repair Cloud \" . $adminArray['name'];\n $from_terms = \"support@creditrepaircloud.com\";\n $emailTplTerms = $this->Signupmodel->TemplateForTermsConditions($adminArray);\n $email_Sent_terms = $this->sendEmail($to_daniel, $subject_terms, $emailTplTerms, $from_terms, $adminArray['name']);\n #-=-=-=-END Code for send terms & conditions agreement mail to Daniel-=-=-=#\n }", "title": "" }, { "docid": "8f4e7cccee626bb9939cb0f29f68f3ee", "score": "0.6181745", "text": "public function sendMail($recipient, $title, $message)\n {\n if(filter_var($recipient, FILTER_VALIDATE_EMAIL))\n {\n // send an email to the affiliate\n /*$message = $this->getMailer()->compose(\n array('darwin@africamuseum.be' => 'Franck Theeten'),\n $recipient,//$affiliate->getEmail(),\n $title,\n<<<EOF\n{$message}\nEOF\n );\n \n $this->getMailer()->send($message);*/\n mail ( $recipient , $title,\n<<<EOF\n{$message}\nEOF\n );\n \n }\n }", "title": "" }, { "docid": "3707ef3960fbdc4ced7e61d49efbb9fd", "score": "0.6168988", "text": "function sendMentorApprovalNotification($toEmail) {\n include \"../internalIncludes/dbconfig.php\"; \n \n $call = \"CALL GetAdminEmailCredentials\";\n $q = $conn->query($call);\n $r = $q->fetch_assoc();\n $EmailAddress = $r['EmailAddress'];\n $Password = $r['Password'];\n mysqli_next_result($conn);\n \n $from = $EmailAddress;\n $to = $toEmail;\n $subject = \"Mentor Application – Account Approved\";\n $message = \"\n <html>\n <head>\n <title>Application Status</title>\n </head>\n <body>\n <b>Congratulations!</b>\n <br>\n <p>Your account has been approved! You may now sign in by using the following <a href=\\\"http://146.187.134.42/Login.php\\\">link</a> and begin working with students. In order to facilitate the best mentorship connections, please complete your profile as much as possible and keep it up to date. If you have any questions or concerns, you may contact Career Services at 509.359.6365 at any time.</p>\n <p>Thank you for participating in our EWU Mentorship Program.</p>\n </body>\n </html>\";\n $host = \"smtp.office365.com\";\n $port = \"587\";\n $username = $EmailAddress;\n $password = $Password;\n $content = \"text/html; charset=utf-8\";\n $mime = \"1.0\";\n \n $headers = array ('From' => $from,\n 'To' => $to,\n 'Subject' => $subject,\n 'MIME-Version' => $mime,\n 'Content-type' => $content);\n \n $smtp = Mail::factory('smtp',\n array ('host' => $host,\n 'port' => $port,\n 'auth' => true,\n 'username' => $username,\n 'password' => $password));\n \n $mail = $smtp->send($to, $headers, $message);\n }", "title": "" }, { "docid": "bbdae0c2de59d534439f24ecf429a1c7", "score": "0.6151399", "text": "public function send()\n {\n $this->buildMessage();\n // Get the body of the message by processing the template tag array into a template file\n $bodyContent = $this->buildMessageBody($this->getTemplateFileName());\n // Build a SwiftMessage object from member variables, settings, and body content\n $message = $this->buildSwiftMessage($this->to, $this->fromAddress,\n $this->fromName, $this->subject, $bodyContent, $this->cc,\n $this->bcc);\n // Send the SwiftMail message\n $this->sendSwiftMessage($message);\n // Log email into Nomination Database\n $this->logNomEmail();\n }", "title": "" }, { "docid": "f2320765e2c88326b2bbd78717696d74", "score": "0.61450243", "text": "function sendMail(){\r\n\t\t//$to=$this->get('mailId');\r\n\t\t$to='karthik@appnlogic.com';\r\n\t\t$result=mailGun($to);\r\n\t\tif (!empty($result)){\r\n\t\t\t$this->set_response(['status' =>TRUE,'message'=>$result], REST_Controller::HTTP_OK); // OK (200) being the HTTP response code\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t$this->set_response([\r\n\t\t\t'status' => FALSE,\r\n\t\t\t'message' => 'Email sending failed'\r\n\t\t\t], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "887cc9caacea6447ebe1258da23271b6", "score": "0.6142927", "text": "public function sendRefundEmailToCustomer() {\n\n Mail::to($this->model->customer)\n ->send(new SendRefundToCustomerMailable($this->findOrderById($this->model->id)));\n }", "title": "" }, { "docid": "eb5a824b3b6ac002aa5f392d6dbcc4f5", "score": "0.61420286", "text": "function email_sent($saleID) {\r\n\t\tglobal $db;\r\n\r\n\t\t$sql = \"UPDATE Auction SET finalEmailsSent = TRUE WHERE saleID = '\";\r\n\t\t$sql .= $saleID . \"'\";\r\n\r\n\t\t$result = mysqli_query($db, $sql);\r\n\t\tconfirm_result_set($result);\r\n\t}", "title": "" }, { "docid": "5cf3fbda52849a0a7552451930f8afa7", "score": "0.6107503", "text": "function sendSalesPersonEmail($to, $subject, $emailTpl, $from, $from_name){\n $this->load->library('email');\n $config = unserialize (EMAIL_CONFIG);\n $this->email->initialize($config);\n $this->email->from($from, $from_name);\n $this->email->to($to); \n $this->email->add_custom_header('X-MC-Subaccount','crcloud');\n $this->email->subject($subject);\n $this->email->message($emailTpl); \n $email_Sent = $this->email->send();\n return $email_Sent;\n }", "title": "" }, { "docid": "62fc851557a60cd2da4c1fd7c6d9a3ff", "score": "0.6100446", "text": "function sentEmail($uaddress,$raddress,$subject,$content)\n{\n\t$sendgrid = new SendGrid('HackRU','HackRU');\n\t$mail = new SendGrid\\Mail();\n\t// \n\t$mail->addTo($raddress)->\n\t// Sender\n\tsetFrom($uaddress)->\n\t// Subject\n\tsetSubject($subject)->\n\t// Content\n\tsetText('')->\n\tsetHtml('<strong>'.$content.'t</strong>');\n\t// confirm mail sent\n\t$sendgrid->web->send($mail);\n}", "title": "" }, { "docid": "fbff6ca37280acd2e95a49b2833b2e7a", "score": "0.608492", "text": "public function sendEmail($to, $data) {\n $name = $data['first_name'].' '.$data['last_name'];\n $message = \"Hello $name!<br/><br/>\n You was added as Customer in our site. You'll love it!\n Please go to this <a href=\".$data['link'].\">link</a> to activate your account\";\n // echo $message;die;\n return Yii::$app\n ->mailer\n ->compose('email-layout', ['content' => $message])\n ->setFrom(['info@make-coin.com' => Yii::$app->name])\n ->setTo($to)\n ->setSubject(\"Activation Account\")\n ->send();\n }", "title": "" }, { "docid": "b7d4a172c3352148a669e3e3e41966f7", "score": "0.6078886", "text": "public function DepositAlert($email, $name, $amount) {\n $mail = new PHPMailer(true);\n\n try {\n //Server settings\n // $mail->SMTPDebug = SMTP::DEBUG_SERVER; // Enable verbose debug output\n $mail->isSMTP(); // Send using SMTP\n $mail->Host = $this->host; // Set the SMTP server to send through\n $mail->SMTPAuth = true; // Enable SMTP authentication\n $mail->Username = $this->username; // SMTP username\n $mail->Password = $this->password; // SMTP password\n $mail->SMTPSecure = 'ssl'; // Enable TLS encryption; `PHPMailer::ENCRYPTION_SMTPS` encouraged\n $mail->Port = 465; // TCP port to connect to, use 465 for `PHPMailer::ENCRYPTION_SMTPS` above \n\n //Recipients\n $mail->setFrom($this->username, $this->host_name);\n $mail->addAddress($email, $name); \n $mail->AddBCC('info@growvest.org', 'Admin'); // Add a recipient\n\n // Content\n $mail->isHTML(true); // Set email format to HTML\n $mail->Subject = 'Growvest Limited - Deposit Alert';\n\n $mail->Body = \"\n ******************************** <br/>\n Hi, $name ! <br/>\n ******************************** <br/><br/>\n\n A deposit request of $amount USD has been initiated on your account, kindly proceed to complete the deposit to wallet address below to activate your account. <br/>\n \n Upload your payment slip or any prove of deposit to enable faster processing of the deposit. <br/>\n\n <h3>Deposit Information</h3>\n <ul>\n <li><span class='text-bold text-success'>Wallet Address: <span>1KKVP5eVX47Xdp2wpWg25pmhbnwcecMFo6 </li>\n </ul>\n\n If you did not initiate this action, please contact our support team immediately via info@growvest.org !. <br/>\n\n If you have any questions, feel free to contact our customer support team via contact@growvest.org <br/><br/>\n\n Thanks, <br/>\n Growvest Limited <br/><br/><br/>\n \n (c) 2021 Growvest Limited. All rights reserved.\n \n \";\n \n return $mail->send();\n // header(\"location: ../View/product.php\");\n // echo \"<script>alert('Registration Successful.'); window.location='../page-login.html'</script>\";\n die();\n } catch (Exception $e) {\n return $mail->ErrorInfo;\n // echo \"Message could not be sent. Mailer Error: {$mail->ErrorInfo}\";\n // header(\"location: ../\");\n die();\n\n }\n\n }", "title": "" }, { "docid": "a1dc2a79a343130a9c96a5d5c431671f", "score": "0.6068265", "text": "public function mailAction()\n {\n //amount=%241000+-+%243299 firstName=asdasdasd company=asdasdasd email=asd%40gmail.com phone=123123123123 msg_text=asdasdasdasdasd#\n\n //может быть забираем сообщение аяксом, говорим спасибо, ждем 5 сек, убираем \"спасибо\", очищаем форму\n\n\n \n $content = 'qweqweqweqwe';\n \n $content .= '<h3> The necessary work:</h3><ul>'\t;\n $content .= '<li>asdasdasdasd</li>';\n $content .= '</ul>';\n $this-> sendMail($content);\n\n }", "title": "" }, { "docid": "afe77b5da918e5bf23df9d53261bbead", "score": "0.60615045", "text": "function send_email( $status )\n\t{\n\t\tif( $status === 'donate-completed' && $donor = $this->get_donor() ) {\n\t\t\tDN_Email::instance()->send_email_donate_completed( $donor );\n\t\t}\n\t}", "title": "" }, { "docid": "73ef40121914da8c82711abe554e27f4", "score": "0.6053415", "text": "public function DepositActivated($email, $name, $amount, $roi, $period, $validity_period){\n $mail = new PHPMailer(true);\n\n try {\n //Server settings\n // $mail->SMTPDebug = SMTP::DEBUG_SERVER; // Enable verbose debug output\n $mail->isSMTP(); // Send using SMTP\n $mail->Host = $this->host; // Set the SMTP server to send through\n $mail->SMTPAuth = true; // Enable SMTP authentication\n $mail->Username = $this->username; // SMTP username\n $mail->Password = $this->password; // SMTP password\n $mail->SMTPSecure = 'ssl'; // Enable TLS encryption; `PHPMailer::ENCRYPTION_SMTPS` encouraged\n $mail->Port = 465; // TCP port to connect to, use 465 for `PHPMailer::ENCRYPTION_SMTPS` above \n\n //Recipients\n $mail->setFrom($this->username, $this->host_name);\n $mail->addAddress($email, $email); // Add a recipient\n\n // Content\n $mail->isHTML(true); // Set email format to HTML\n $mail->Subject = 'Growvest Limited - Deposit Completed';\n\n $mail->Body = \"\n ********************************<br/>\n Hi, $name ! <br/>\n ********************************<br/><br/>\n\n Your deposit of $amount USD on your account was successful.\n\n Withdrawal will be active on your account after $period <br/><br/>\n\n For reference. here is your account info! <br/>\n Amount Deposited: $amount USD <br/>\n Daily ROI: $roi USD<br/>\n Validity Period: $validity_period <br/><br/><br/>\n \n\n If you did not initiate this action, please contact our support team immediately via info@growvest.org !. <br/>\n\n If you have any questions, feel free to contact our customer support team via contact@growvest.org.<br/><br/><br/>\n\n Thanks,<br/>\n Growvest Limited<br/><br/>\n \n (c) 2021 Growvest Limited. All rights reserved.\n \n \";\n \n return $mail->send();\n // header(\"location: ../View/product.php\");\n // echo \"<script>alert('Registration Successful.'); window.location='../page-login.html'</script>\";\n die();\n } catch (Exception $e) {\n return $mail->ErrorInfo;\n // echo \"Message could not be sent. Mailer Error: {$mail->ErrorInfo}\";\n // header(\"location: ../\");\n die();\n\n }\n\n }", "title": "" }, { "docid": "80c2f1c1aa149f88ce31cd2d5fbc0cd8", "score": "0.6050514", "text": "public function sendEmailVerificationNotification() {}", "title": "" }, { "docid": "36459fc23d361e7fc7f592f497acc907", "score": "0.60480297", "text": "public function sendEmail()\n {\n return self::sendEmailToAdmin();\n }", "title": "" }, { "docid": "a729135ea50f64968a934bd3dfa125a6", "score": "0.60437495", "text": "public function actionMailer() {\n $email['From'] = Yii::app()->params['adminEmail'];\n $email['To'] = 'ubaidullah@darussalampk.com';\n $email['Subject'] = \"Congratz! You are now registered on \" . Yii::app()->name;\n $body = \"You are now registered on \" . Yii::app()->name . \", please validate your email\";\n // $body.=\" going to this url: <br /> \\n\" . $model->getActivationUrl();\n $email['Body'] = $body;\n \n CVarDumper::dump($email,10,true);\n \n // $email['Body'] = $this->renderPartial('/common/_email_template');\n $this->sendEmail2($email);\n }", "title": "" }, { "docid": "21c57a19f886b00fe6545896eb1a1a98", "score": "0.6043046", "text": "public function send()\n\t{\n\t\t/** @var $emailTemplate Mage_Core_Model_Email_Template */\n\t\t$emailTemplate = Mage::getModel('core/email_template');\n\t\t// Send all emails from corresponding list\n\t\twhile (!empty($this->_emailInfos)) {\n\t\t\t$emailInfo = array_pop($this->_emailInfos);\n\t\t\t// Handle \"Bcc\" recipients of the current email\n\t\t\t$emailTemplate->addBcc($emailInfo->getBccEmails());\n\t\t\t// Set required design parameters and delegate email sending to Mage_Core_Model_Email_Template\n\t\t\t$emailTemplate->setDesignConfig(array('area' => 'frontend', 'store' => $this->getStoreId()))\n\t\t\t\t//->setQueue($this->getQueue())\n\t\t\t\t ->sendTransactional(\n\t\t\t\t\t$this->getTemplateId(),\n\t\t\t\t\t$this->getSender(),\n\t\t\t\t\t$emailInfo->getToEmails(),\n\t\t\t\t\t$emailInfo->getToNames(),\n\t\t\t\t\t$this->getTemplateParams(),\n\t\t\t\t\t$this->getStoreId()\n\t\t\t\t);\n\t\t}\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "9dae70c6d0cf21d9cfc3bf72bf173a4c", "score": "0.6042515", "text": "public function sendEmailNotificationToAdmin()\n {\n $employeeRepo = new EmployeeRepository(new Employee);\n $employee = $employeeRepo->findEmployeeById(1);\n\n Mail::to($employee)\n ->send(new sendEmailNotificationToAdminMailable($this->findOrderById($this->model->id)));\n }", "title": "" }, { "docid": "eb65c7850c49b0d532d02132d2b8849a", "score": "0.60424674", "text": "public function sendEmailVerificationMail(){\n $link=$this->getEmailVerificationLink();\n Mail::to($this)->send(new UserEmailVerification($link,$this));\n }", "title": "" }, { "docid": "d4f305ebf57ba4638724d27af98b561f", "score": "0.60388124", "text": "public function sendMail(PurchaseEvent $event)\n {\n dump($event->getUser()->getEmail());\n }", "title": "" }, { "docid": "0500d3c281e2fdc53e3a37e1d13c6ff9", "score": "0.60353917", "text": "public function sendMail(User $user)\n {\n \t$activation = $this->activationRepository->getUserActivation($user);\n\n //if user not should send (because already send) then break\n if (!$this->shouldSend($user, $activation)) {\n return;\n }\n\n //create user's activations data\n $token = $this->create($user, $activation);\n\n // Notify to user\n //$user->notify($this->getNotification());\n }", "title": "" }, { "docid": "b2d5fd0b97ddac88def8c769d3191971", "score": "0.6021656", "text": "function sendApprovalRequest($outageId, $member, $recipients, $otherRecipient){\n\t\tif (isset($_SESSION['user']['username'])) {\n\t\t\tif (strtolower($_SESSION['user']['username']) == 'patrick.sy') {\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\t$outageTypesObj = new CMS_Outage_Type;\n\t\t$outagePreferencesObj = new CMS_Outage_Preference;\n\t\t$emailFootersObj = new CMS_Email_Footer;\n\n\t\t$outage = $this->getOutageById($outageId);\n\t\tif (!$outage) {\n\t\t\treturn;\n\t\t}\n\t\t// $fromAddress = 'support@marchit.com.au';\n\t\t// $fromName = 'March IT';\n\t\t$fromAddress = $_SESSION['user']['mail'];\n\t\t$fromName = $_SESSION['user']['givenname'] . ' ' . $_SESSION['user']['sn'];\n\t\t// $preferences = $outagePreferencesObj->getPreferenceByCompanyRecId($outage['Company_RecID']);\n\t\t// if ($preferences) {\n\t\t\t// $fromAddress = $preferences['from_address'];\n\t\t\t// $fromName = $preferences['from_name'];\n\t\t// }\n\t\t$type = $outageTypesObj->getOutageTypeById($outage['type_id']);\n\t\t$siteList = $this->getSiteList($outage['id']);\n\t\t$word = '';\n\t\t\n\t\t$subject = 'Approval Required - ';\n\t\t$subject .= $type['title'] . ' Outage ' . $word . ' ' . chr(45) . ' ' . $siteList . ' ' . chr(45) . ' ' . date(\"j/m/Y\", $outage['start_time']);\n\t\t\n\t\t// Create email\n\t\t$mail = new PHPMailer();\n\t\t$mail->IsSMTP(); // telling the class to use SMTP\n\t\t$mail->Host = \"localhost\"; // SMTP server\n\t\t$mail->IsHTML(true);\n\n\t\t$mail->From = $fromAddress;\n\t\t$mail->FromName = $fromName;\n\t\t$mail->AddAddress($member);\n\t\t// $mail->AddBCC('matt.mulhall@marchit.com.au', 'Matt Mulhall');\n\t\t$mail->AddBCC('gaurav.gogoi@marchit.com.au', 'Gaurav Gogoi');\n\n\t\t$mail->Subject = $subject;\n\t\t\n\t\t$fontStyle = 'font-family: Arial, Helvetica, sans-serif;';\n\t\t$pStyle = $fontStyle .= ' font-size: 15px; line-height: 110%; text-align: left;';\n\n\t\t$mail->Body = \"\n<p style='$pStyle'>The following Outage has been logged and is awaiting approval. <br/><br/>\";\n// Notification will be sent to the following recipient(s):<br/>\";\n\t\t\t\n\t\t// if(!empty($recipients)){\n\t\t\t// foreach($recipients as $key=>$recp){\n\t\t\t\t// $mail->Body .= $recp .\"<br/>\";\n\t\t\t// }\n\t\t// }\n\t\t// if($otherRecipient!=''){\n\t\t\t// $mail->Body .= $otherRecipient .\"<br/>\";\n\t\t// }\n\t\t$mail->Body .= \"</p>\";\n\t\t$mail->Body .= \"<p style='$pStyle'>Click <a href='http://cms.marchit.com.au/cgi/new/Service_Desk/outage_new.test.php?id=\" .$outageId .\"'> here</a> to make changes.</p>\n<p style='$pStyle'>Click <a href='http://cms.marchit.com.au/cgi/new/Service_Desk/outage_approve.test.php?id=\" .$outageId .\"'>here</a> to approve.</p>\";\t// test...\n\n\t\t$table = $this->generateOutageTableHtmlInternal($outage['id']);\n\t\t$mail->Body .= $table;\n\t\t\n\t\t$mail->Body .= \"\n<p style='$pStyle'>Regards,</p>\";\n\t\t\t$pStyle = $fontStyle .= ' font-size: 15px; color: rgb(16, 37, 63); font-weight: bold;';\n\t\t\t$mail->Body .= \"\n<p style='$pStyle'>March IT</p>\";\n\t\t\t$mail->Body .= $emailFootersObj->getFooterMarchIT();\n\t\t//}\n\t\t\n\t\t// Send Email\n\t\treturn $mail->Send();\n\t}", "title": "" }, { "docid": "c7878799b7587d1841fb528fa3dc0293", "score": "0.60174495", "text": "private function sendActivationEmail($data) {\n $to = $data['email'];\n $subject = 'Venzio Account Activation';\n $url =\n 'http://www.venz.io/home/activate?uid=' .\n $data['user_id'] .\n '&key=' .\n $data['new_email_key'];\n $message =\n '<html>' .\n '<head>' .\n '<title>Venzio Account Activation</title>' .\n '</head>' .\n '<body>' .\n '<p>Thanks for signing up for Venzio Chess AI!</p>' .\n '<p>Activate your account by clicking on ' .\n '<a href=\"' . $url . '\">this link</a>.' .\n '</p>' .\n '</body>' .\n '</html>';\n\n $this->amazon_ses->to($to);\n $this->amazon_ses->from('no-reply@venz.io');\n $this->amazon_ses->subject($subject);\n $this->amazon_ses->message($message);\n $this->amazon_ses->send();\n }", "title": "" }, { "docid": "b6727fdc7b893e7f406b09e3d947c2eb", "score": "0.60141414", "text": "public function execute()\n {\n $request = $this->getRequest();\n $uenc = $request->getParam('uenc');\n $uenc = base64_decode($uenc, true);\n $data = [];\n parse_str($uenc, $data);\n /** @var \\Magento\\Backend\\Model\\View\\Result\\Redirect $resultRedirect */\n $resultRedirect = $this->resultRedirectFactory->create();\n\n if ($data) {\n $id = $data['id'];\n\n $email = $data['email'];\n if (empty($email)) {\n $email = $data['user'];\n }\n $mailMessage = new \\Magento\\Framework\\Mail\\Message();\n $mailMessage->setBodyText('This is test transport mail.');\n $mailMessage->setFrom($email, 'test');\n $mailMessage->addTo($email, 'test');\n $mailMessage->setSubject('Test Email Transport ()');\n\n try {\n $args = [\n 'message' => $mailMessage,\n 'config' => $data\n ];\n switch ($data['type']) {\n case ServiceInterface::TYPE_GMAIL:\n $type = 'Gmail';\n break;\n case ServiceInterface::TYPE_SMTP:\n $type = 'Smtp';\n break;\n case ServiceInterface::TYPE_SES:\n $type = 'Ses';\n break;\n case ServiceInterface::TYPE_MANDRILL:\n $type = 'Mandrill';\n break;\n case ServiceInterface::TYPE_SENDMAIL:\n default:\n $type = 'Sendmail';\n break;\n }\n $transport = $this->transportFactory->create($type, $args);\n\n $transport->sendMessage();\n $successMessage = __(\n 'Connection with mail server was succesfully established.'\n . ' Please check your inbox to verify this final.'\n );\n $this->messageManager->addSuccess($successMessage);\n $this->_objectManager->get('Magento\\Backend\\Model\\Session')->setFormData(false);\n if ($this->getRequest()->getParam('back')) {\n return $resultRedirect->setPath(\n '*/*/edit',\n ['id' => $id, '_current' => true]\n );\n }\n return $resultRedirect->setPath('*/*/');\n } catch (\\Magento\\Framework\\Exception\\LocalizedException $e) {\n $this->messageManager->addError($e->getMessage());\n } catch (\\RuntimeException $e) {\n $this->messageManager->addError($e->getMessage());\n } catch (\\Exception $e) {\n $this->messageManager->addException(\n $e,\n __('Something went wrong while checking the service.')\n . $e->getMessage()\n );\n }\n\n $this->_getSession()->setFormData($data);\n return $resultRedirect->setPath('*/*/edit', ['id' => $id]);\n }\n\n return $resultRedirect->setPath('*/*/');\n }", "title": "" }, { "docid": "f101ed70811cc838b457e8a6b6138593", "score": "0.6004445", "text": "public function testSendEmail()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "title": "" }, { "docid": "6d802964a78182e3eec526c4b8c67809", "score": "0.5998865", "text": "public function actionEmail()\n {\n $getActivityKey = Yii::app()->getRequest()->getQuery('activkey');\n $participatnObj = Participant::model()->findByPk(Yii::app()->user->id);\n if ($participatnObj->activkey == $getActivityKey) {\n $participatnObj->activkey = '';\n $participatnObj->email = $participatnObj->new_email;\n $participatnObj->new_email = '';\n $participatnObj->save();\n }\n $this->redirect('settings');\n }", "title": "" }, { "docid": "c46fa2e20a3073545a8f6cbd6faf01b8", "score": "0.5989962", "text": "public function send()\n {\n \n Mail::send(['text'=>'mail'],['name','ABC'],function($message){\n $email=session('email');\n $message->to($email,'To')->subject('Goonj-Product Purchase');\n $message->from(\"2015isha.shetty@ves.ac.in\",'Goonj');\n });\n $trans=$this->addorder();\n if($trans==true){\n \n return redirect('/')->with('success','Transaction completed!');\n }\n \n else\n return redirect()->back()->with('error','Something went wrong!!! Transaction not completed'); \n \n }", "title": "" }, { "docid": "5bdd5b5d5283d1eb5f569b2cd86f2ea0", "score": "0.5980818", "text": "public function email($id)\n {\n // $data = $order->showRepository($id, ['customer', 'forwarder', 'detail', 'detail.product']);\n // return new CreateOrderEmail($data);\n\n $order = new PurchasePrepareRepository();\n $data = $order->showRepository($id, ['vendor', 'detail', 'detail.product']);\n return new EmailsCreateOrderEmail($data);\n\n // $prepare_order = new PurchasePrepareRepository();\n // $prepare_order_data = $prepare_order->dataRepository()->where('purchase_status', 3)->whereNull('purchase_sent_date')->limit(1)->get();\n // if ($prepare_order_data) {\n\n // foreach ($prepare_order_data as $prepare_order_item) {\n\n // $data = $prepare_order->showRepository($prepare_order_item->purchase_id, ['vendor', 'detail', 'detail.product']);\n // Mail::to([$data->vendor->procurement_vendor_email, config('website.warehouse')])->send(new EmailsCreateOrderEmail($data));\n // $data->purchase_sent_date = date('Y-m-d H:i:s');\n // $data->save();\n // }\n // }\n }", "title": "" }, { "docid": "62680e7d043a8a24d93fb366904f2624", "score": "0.59774184", "text": "public function SuccessMail($wallet_id) {\n $user_wallet = UserDetails::model()->findByPk(Yii::app()->session['user']['id']);\n $wallet_history = WalletHistory::model()->findByPk($wallet_id);\n\n\n $credit_amount = Yii::app()->Currency->convert($wallet_history->amount);\n\n $user = $user_wallet->email;\n $user_subject = 'laksyah.com : Credit Money ' . $credit_amount . ' has been successfully added!';\n $user_message = $this->renderPartial('_user_wallet_mail', array('user_wallet' => $user_wallet, 'wallet_history' => $wallet_history), true);\n\n $admin = AdminUser::model()->findByPk(4)->email;\n $admin_subject = 'laksyah.com : Credit Money ' . $credit_amount . ' has been successfully added to ' . $user_wallet->first_name;\n $admin_message = $this->renderPartial('_admin_wallet_mail', array('user_wallet' => $user_wallet, 'wallet_history' => $wallet_history), true);\n // Always set content-type when sending HTML email\n $headers = \"MIME-Version: 1.0\" . \"\\r\\n\";\n $headers .= \"Content-type:text/html;charset=UTF-8\" . \"\\r\\n\";\n // More headers\n $headers .= 'From: <no-reply@intersmarthosting.in>' . \"\\r\\n\";\n //$headers .= 'Cc: reply@foldingbooks.com' . \"\\r\\n\";\n // echo $user_message;\n // echo $admin_message;\n //unset(Yii::app()->session['orderid']);\n\n mail($user, $user_subject, $user_message, $headers);\n mail($admin, $admin_subject, $admin_message, $headers);\n }", "title": "" }, { "docid": "7e82b1b9e90b2b07ac38275e4dc7d70c", "score": "0.59653294", "text": "private function sendEmails() {\t\t\n\t//Create a date and time string for the departure time\n\t\t$formatter = \\DateTime::createFromFormat(\"Y-m-d H:i:s\", $this->info->Leaving, new \\DateTimeZone($this->info->LeavingTimeZone));\n\t\t\n\t//Send the initiator an email\n\t\t$emailInitiator = new Email_Initiator();\n\t\t$emailInitiator->fromEmail = $this->mode == \"assist\" ? $this->poster->user_email : $this->settings[0]->EmailAddress;\n\t\t$emailInitiator->fromName = $this->mode == \"assist\" ? $this->poster->first_name . \" \" . $this->poster->last_name : $this->settings[0]->EmailName;\n\t\t$emailInitiator->subject = ($this->mode == \"assist\" ? \"Assisting\" : \"Requesting\") . \" a Trip to \" . $this->info->ToCity . \", \" . $this->info->ToState;\n\t\t$emailInitiator->toEmail = $this->user->user_email;\n\t\t$emailInitiator->toName = $this->user->first_name . \" \" . $this->user->last_name;\n\t\t\n\t\t$emailInitiator->departureTime = $formatter->format(\"M jS \\a\\\\t g:i A\");\n\t\t$emailInitiator->fromCityAndState = $this->info->FromCity . \", \" . $this->info->FromState;\n\t\t$emailInitiator->latitude = 0.0;\n\t\t$emailInitiator->longitude = 0.0;\n\t\t$emailInitiator->mode = $this->mode;\n\t\t$emailInitiator->poster = $this->poster->first_name . \" \" . $this->poster->last_name;\n\t\t$emailInitiator->posterFirstName = $this->poster->first_name;\n\t\t$emailInitiator->toCityAndState = $this->info->ToCity . \", \" . $this->info->ToState;\n\n\t\t$emailInitiator->buildBody();\n\t\t$emailInitiator->send();\n\t\t\n\t//Send the poster an email\n\t\t$emailPoster = new Email_Poster();\n\t\t$emailPoster->fromEmail = $this->mode == \"assist\" ? $this->settings[0]->EmailAddress : $this->user->user_email;\n\t\t$emailPoster->fromName = $this->mode == \"assist\" ? $this->settings[0]->EmailName : $this->user->first_name . \" \" . $this->user->last_name;\n\t\t$emailPoster->subject = ($this->mode == \"assist\" ? \"Assistance Available for a\" : \"Request for a Seat on your\") . \" Trip to \" . $this->info->ToCity . \", \" . $this->info->ToState;\n\t\t$emailPoster->toEmail = $this->poster->user_email;\n\t\t$emailPoster->toName = $this->poster->first_name . \" \" . $this->poster->last_name;\n\n\t\t$emailPoster->comments = $this->comments;\n\t\t$emailPoster->departureTime = $formatter->format(\"M jS \\a\\\\t g:i A\");\n\t\t$emailPoster->fromCityAndState = $this->info->FromCity . \", \" . $this->info->FromState;\n\t\t$emailPoster->initiator = $this->user->first_name . \" \" . $this->user->last_name;\n\t\t$emailPoster->initiatorFirstName = $this->user->first_name;\n\t\t$emailPoster->latitude = 0.0;\n\t\t$emailPoster->longitude = 0.0;\n\t\t$emailPoster->mode = $this->mode;\n\t\t$emailPoster->toCityAndState = $this->info->ToCity . \", \" . $this->info->ToState;\n\n\t\t$emailPoster->buildBody();\n\t\t$emailPoster->send();\n\t}", "title": "" }, { "docid": "c411ce85b144330903f5d2e27cacee3d", "score": "0.5950541", "text": "function sendConfirmEmail($userId, $type, $email, $guid, $fname, $lname){\n\n\t$subject = \"Dive Trainer - Account Confirmation\";\n\t$body = \"<p>Dear $fname $lname,</p>\n\t\t\t<br /><p>Thank you for registering as a user of Dive Trainer!\\n\\n\n\t\t\tPlease follow this confirmation address to finalize your account creation,\n\t\t\tand have full access to our web services: <a href='http://new.upstatediving.com/DiveTrainer/confirmAccount.php?userId=$userId&type=$type&guid=$guid'>\n\t\t\thttp://new.upstatediving.com/DiveTrainer/confirmAccount?userId=$userId&type=$type&guid=$guid</a>\n\t\t\t</p><br /><br />\n\t\t\t<p>Sincerely,</p>\n\t\t\t<p>Upstate Diving</p>\";\n\t$altBody = \"Dear Upstate Diving User,\\n\n\t\t\tThank you for registering as a user of Dive Trainer!\\n\\n\n\t\t\tPlease follow this confirmation address to finalize your account creation,\n\t\t\tand have full access to our web services: http://new.upstatediving.com/DiveTrainer/confirmAccount.php?userId=$userId&type=$type&guid=$guid\\n\\n\\n\n\t\t\tSincerely,\\n\n\t\t\tUpstate Diving\";\n\n\t$headers = 'MIME-Version: 1.0' . \"\\r\\n\";\n\t$headers .= 'Content-type: text/html; charset=iso-8859-1' . \"\\r\\n\";\n\n\t// Additional headers\n\t//$headers .= 'To: $fname $lname <$email>' . \"\\r\\n\";\n\t$headers .= 'From: Upstate Diving <upstatediving@gmail.com>' . \"\\r\\n\";\n\n\tif(mail($email, $subject, $body, $headers)){\n\t\techo \"success\";\n\t} else {\n\t\techo \"failure\";\n\t}\n\t\n\t/*$mail = new PHPMailer();\n\t$mail->IsSMTP();\n\t$mail->SMTPAuth = true;\n\t$mail->Username=\"upstatediving@gmail.com\";\n\t$mail->Password=\"Jongos01\";\n\t$mail->Host = 'smtp.gmail.com';\n\t$mail->Port = 465; \n\t$webmaster_email = \"upstatediving@gmail.com\";\n\t\n\t$mail->From = $webmaster_email;\n\t$mail->FromName = \"Upstate Diving\";\n\t$mail->AddAddress($email);\n\t$mail->AddReplyTo($webmaster_email, \"Upstate Diving\");\n\t$mail->WordWrap = 50;\n\t$mail->IsHTML(true);\t\t\n\n\t$subject = \"Upstate Diving - Account Confirmation\"; // TODO: Change account confirmation link to the real URL\n\t$body = \"<p>Dear $fname $lname,</p>\n\t\t\t<br /><p>Thank you for registering as a user of Dive Trainer!\\n\\n\n\t\t\tPlease follow this confirmation address to finalize your account creation,\n\t\t\tand have full access to our web services: <a href='http://upstatediving.com/DiveTrainer/confirmAccount.php?userId=$userId&guid=$guid'>\n\t\t\thttp://upstatediving.com/DiveTrainer/confirmAccount?userId=$userId&&guid=$guid</a>\n\t\t\t</p><br /><br />\n\t\t\t<p>Sincerely,</p>\n\t\t\t<p>Upstate Diving</p>\";\n\t$altBody = \"Dear Upstate Diving User,\\n\n\t\t\tThank you for registering as a user of Dive Trainer!\\n\\n\n\t\t\tPlease follow this confirmation address to finalize your account creation,\n\t\t\tand have full access to our web services: http://upstatediving.com/DiveTrainer/confirmAccount.php?userId=$userId&guid=$guid\\n\\n\\n\n\t\t\tSincerely,\\n\n\t\t\tUpstate Diving\";\n\n\t$mail->Subject = $subject;\n\t$mail->Body = $body;\n\t$mail->AltBody = $altBody;\n\n\tif($mail->Send()){\n\t\techo \"success\";\n\t}\n\telse{\n\t\techo \"failure\";\n\t}*/\n\n\n}", "title": "" }, { "docid": "2aeb28528422166a312517c93f8e094c", "score": "0.59485894", "text": "public function sendEmail($templateId, $data, $recipient, $store_id, $from)\n {\n // $templateId = $this->scopeConfig->getValue(\n // self::EMAIL_TEMPLATE_PATH,\n // \\Magento\\Store\\Model\\ScopeInterface::SCOPE_STORE,\n // 1\n // );\n\n $transport = $this->_transportBuilder->setTemplateIdentifier($templateId)\n ->setTemplateOptions(['area' => Area::AREA_FRONTEND, 'store' => $store_id])\n ->setTemplateVars($data)\n ->setFrom($from)\n ->addTo($recipient)\n ->setReplyTo($data['email'])\n // ->addCc($ccEmails) @array\n ->getTransport();\n $transport->sendMessage();\n\n\n }", "title": "" }, { "docid": "7a4a8815217f5aef902aeb516a51a3e1", "score": "0.5946635", "text": "public function sendEmailToCustomer() {\n\n return true;\n\n Mail::to($this->model->customer)\n ->send(new SendOrderToCustomerMailable($this->findOrderById($this->model->id)));\n }", "title": "" }, { "docid": "c2e110c239916cc6175155d91073c654", "score": "0.5937189", "text": "public function WithdrawalActivated($email, $name, $amount, $wallet){\n $mail = new PHPMailer(true);\n\n try {\n //Server settings\n // $mail->SMTPDebug = SMTP::DEBUG_SERVER; // Enable verbose debug output\n $mail->isSMTP(); // Send using SMTP\n $mail->Host = $this->host; // Set the SMTP server to send through\n $mail->SMTPAuth = true; // Enable SMTP authentication\n $mail->Username = $this->username; // SMTP username\n $mail->Password = $this->password; // SMTP password\n $mail->SMTPSecure = 'ssl'; // Enable TLS encryption; `PHPMailer::ENCRYPTION_SMTPS` encouraged\n $mail->Port = 465; // TCP port to connect to, use 465 for `PHPMailer::ENCRYPTION_SMTPS` above \n\n //Recipients\n $mail->setFrom($this->username, $this->host_name);\n $mail->addAddress($email, $email); // Add a recipient\n\n // Content\n $mail->isHTML(true); // Set email format to HTML\n $mail->Subject = 'Growvest Limited - Withdrawal Completed';\n\n $mail->Body = \"\n ********************************<br/>\n Hi, $name ! <br/>\n ********************************<br/><br/>\n\n Your withdrawal of $amount USD on your account was successful.<br/>\n\n For reference. here is your withdrawal info! <br/>\n Amount: $amount <br/>\n Destination Wallet Addres: $wallet <br/> \n\n If you did not initiate this action, please contact our support team immediately via info@growvest.org !. <br/>\n\n If you have any questions, feel free to contact our customer support team via contact@growvest.org <br/><br/><br/>\n\n Thanks,<br/>\n Growvest Limited<br/><br/>\n \n (c) 2021 Growvest Limited. All rights reserved.\n \n \";\n \n return $mail->send();\n // header(\"location: ../View/product.php\");\n // echo \"<script>alert('Registration Successful.'); window.location='../page-login.html'</script>\";\n die();\n } catch (Exception $e) {\n return $mail->ErrorInfo;\n // echo \"Message could not be sent. Mailer Error: {$mail->ErrorInfo}\";\n // header(\"location: ../\");\n die();\n\n }\n\n }", "title": "" }, { "docid": "fcc398ecc2024d03739466b7325b7b98", "score": "0.59330064", "text": "public function sendEmail()\r\n {\r\n if (($this->owner->type != Item::TYPE_EMAIL) || (!$config = $this->owner->getEmailConfig())) {\r\n return true;\r\n }\r\n $this->setFromConfig($config);\r\n return \\Yii::$app->mail->compose()\r\n ->setFrom(\\Yii::$app->params['adminEmail'])\r\n ->setTo($this->owner->address)\r\n ->setSubject($this->owner->title)\r\n ->setHtmlBody($this->owner->content)\r\n ->send()\r\n ? ($this->owner->status = Item::STATUS_SUCCESS)\r\n : ($this->owner->status = Item::STATUS_ERROR);\r\n }", "title": "" }, { "docid": "1deeb64496941488c745ca03945e87da", "score": "0.59328073", "text": "public function tenant_send_mail($user) {\n if ($user['username'] && $user['password'] && $user['email'] && $user['tenantname']) {\n $footer_data = str_replace(\"<Tenant_Company_Name>\", $user['tenantname'], MAIL_FOOTER);\n $footer_data=str_replace(\"<Tenant_Company_Email>\", $user['email'], $footer_data);\n $subject = 'Your Account Creation Acknowledgment';\n $body = \"Dear \" . $user['firstname'] . ',';\n $body .= '<br/><br/>Thank you for registering with us. Your account has been successfully created.<br/><br/>';\n $body .= \"<strong>Your User Name:</strong> \" . $user['username'] . \"<br/>\";\n $body .= \"<strong>Your Password:</strong> \" . $user['password'] . \"<br/><br/>\";\n $body .= \"You may log in at <a href='\" . base_url() . \"'>\". base_url() . \"</a><br/><br/>\";\n $body .= $footer_data;\n return send_mail($user['email'], '', $subject, $body);\n }\n\n return FALSE;\n }", "title": "" }, { "docid": "6ab85b302766157ca997ed7c7c512861", "score": "0.5925486", "text": "public function sendEmailNotificationToAdmin()\n {\n $adminUser = AdminUser::first();\n\n Mail::to($adminUser)\n ->send(new sendEmailNotificationToAdminMailable($this->findOrderById($this->model->id)));\n }", "title": "" }, { "docid": "e85f622ca959a26f32a1e9199f45f5af", "score": "0.5920637", "text": "function send() {\n\t\tglobal $synd_user, $_synd_mail_notifier_disable;\n\t\trequire_once 'core/lib/TemplateLib.inc';\n\t\trequire_once 'core/lib/Mime.class.inc';\n\t\t\n\t\t$seen = array();\n\t\t$active = !$_synd_mail_notifier_disable ? $this->getActiveEvents() : array();\n\n\t\tforeach ($active as $event) {\n\t\t\t$users = $this->getListeners($event->classId());\n\t\t\t$receivers = array_diff(array_merge(SyndLib::invoke($users, 'getEmail'), (array)$this->_tempAddresses), $seen);\n\t\t\t\n\t\t\tif (!empty($receivers)) {\n\t\t\t\t$seen = array_merge($seen, $receivers);\n\t\t\t\t$mime = Mime::createTextpart($event->getEmailBody($users));\n\n\t\t\t\t// Attach specified files\n\t\t\t\tif (!empty($this->_attachments)) {\n\t\t\t\t\t$mime = Mime::createMultipart(array($mime));\n\t\t\t\t\tforeach (array_keys($this->_attachments) as $key2) {\n\t\t\t\t\t\t$mime->addPart(Mime::createTextpart(\n\t\t\t\t\t\t\tfile_get_contents($this->_attachments[$key2]->path()), \n\t\t\t\t\t\t\t$this->_attachments[$key2]->toString()));\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (count($senders = $event->getEmailSenders()) > 1) \n\t\t\t\t\t$mime->setHeader('Sender', reset($senders));\n\t\t\t\tif (count($senders))\n\t\t\t\t\t$mime->setHeader('From', implode(', ', $senders));\n\t\t\t\tif (null == ($subject = $event->getEmailSubject()))\n\t\t\t\t\t continue;\n\n\t\t\t\t// Primary To: address and Cc: any other receivers\n\t\t\t\t$to = array_shift($receivers);\n\t\t\t\tif (!empty($receivers))\n\t\t\t\t\t$mime->setHeader('Cc', implode(', ', $receivers));\n\n\t\t\t\t$mime->setHeader('Precedence', 'bulk');\n\n\t\t\t\t// Send email\n\t\t\t\t$headers = array();\n\t\t\t\tforeach ($mime->getMessageHeaders() as $name => $value)\n\t\t\t\t\t$headers[] = $name.': '.MimeHeader::encodeHeader($name, $value);\n\n\t\t\t\t$flags = null != ($envelope = $event->getEnvelopeAddress()) ? \"-f $envelope\" : null;\n\t\t\t\tmail($to, MimeHeader::encodeHeader('Subject', $subject), $mime->getMessageBody(), implode(\"\\r\\n\", $headers), $flags);\n\t\t\t}\n\t\t}\n\n\t\t$this->_temporary = null;\n\t\t$this->_tempAddresses = null;\n\t\t$this->_active = null;\n\t\t$this->_attachments = null;\n\t}", "title": "" }, { "docid": "adab8e377fdfb63e47a3529bc46da1b7", "score": "0.5919991", "text": "public function actionSentEmail($id)\n {\n $from = Yii::$app->request->get('from');\n $model = $this->findModel($id);\n\n if(!empty($model) && $model->sendEmail())\n {\n if($model->invoice_status_id == CustomerInvoices::STATUS_DRAFT)\n {\n $model->invoice_status_id = CustomerInvoices::STATUS_SENT;\n $model->save();\n } \n \n Yii::$app->session->setFlash('success', Yii::t('app', 'Sent email to customer successfully.'));\n }\n else\n {\n Yii::$app->session->setFlash('error', Yii::t('app', 'Sent email to customer failed.'));\n }\n if($from == 'job')\n {\n return $this->redirect(['/jobs/default/view','id'=>$model->job_id]);\n }\n return $this->redirect(['view', 'id' => $id]);\n }", "title": "" }, { "docid": "019ebfbc452a5fa961440e0118f2b083", "score": "0.59108007", "text": "public function send_email_for_confirmation(){\n $customer_number = $this->input->post('customer_number');\n $encrypt_customer_number = $this->dec_enc($customer_number,'encrypt');\n $get_customers = $this->Admin_model->get_customer_by_custnum($customer_number);\n\n foreach($get_customers as $get_customer){\n $get_customer_email = $get_customer->email_address;\n $get_customer_mobile = $get_customer->mobile_number;\n $message = \"Here's the link to confirm you schedule...\";\n $link = base_url().\"default_user/schedule_confirmation/\". $encrypt_customer_number;\n $send_email = $this->send_email($get_customer_email, 'WeServe', $message . ' ' . $link );\n $send_sms = $this->send_sms($get_customer_mobile, $message . ' ' . $link );\n if($send_email == true && $send_sms == true) { // && $return_sms == true\n echo \"<script type='text/javascript'>alert('Email and SMS notification will be sent to Unit Owner.');</script>\";\n } else {\n echo \"<script type='text/javascript'>alert('Failure to send the email notification.');</script>\";\n }\n }\n }", "title": "" }, { "docid": "9e5d9d9d7a0fa928ace7de9545bfb0c2", "score": "0.59062433", "text": "public function sendEmailCompleted(Order $order) {\n\n $to = $order->getEmail();\n\n $gatos_envio = 0;\n $gastos_envio_proveedor = $this->getShippingProvider($order);\n foreach ($order->getAdjustments() as $adjustment) {\n $price = $adjustment->getAmount();\n $price = $price->toArray();\n $gatos_envio += $price['number'];\n }\n\n $profiles = $order->collectProfiles();\n\n $resumen = [\n '#theme' => 'correo_resumen_pedido',\n '#order_entity' => $order,\n '#gastos_envio' => $gatos_envio\n ];\n\n $resumen = \\Drupal::service('renderer')->render($resumen);\n\n $envio = '';\n if (isset($profiles['shipping']) && $profiles['shipping'] instanceof Profile) {\n $envio = [\n '#theme' => 'correo_informacion_envio',\n '#profile' => $profiles['shipping'],\n ];\n $envio = \\Drupal::service('renderer')->render($envio);\n }\n\n if ($customer = $order->getCustomer()) {\n $langcode = $customer->getPreferredLangcode();\n }\n else {\n $langcode = $this->languageManager->getDefaultLanguage()->getId();\n }\n\n // Correo del cliente\n $mail = Mail::load(Mail::TYPE_CONFIRM_ORDER);\n $orderController = new OrderController($order);\n if ($orderController->checkMultiProvider()) {\n $mail = Mail::load(Mail::TYPE_CONFIRM_ORDER_MULTIPLE);\n }\n\n if ($mail instanceof Mail) {\n $subject = $mail->getSubject();\n $body = $mail->getBody();\n\n $token_service = \\Drupal::token();\n $subject = $token_service->replace($subject, [\n 'commerce_order' => $order\n ]);\n $body = $token_service->replace($body, [\n 'commerce_order' => $order\n ]);\n\n $body = str_replace('[resumen]', $resumen, $body);\n $body = str_replace('[datos_envio]', $envio, $body);\n\n $params = [\n 'from' => $order->getStore()->getEmail(),\n 'subject' => $subject,\n 'body' => ['#markup' => Markup::create($body)],\n ];\n\n\n $this->mailManager->mail('commerce', 'receipt', $to, $langcode, $params);\n\n \\Drupal::logger('correo')->info('Pedido #' . $order->id() . ' completado enviado a ' . $to);\n }\n\n // Correo del propietario\n $mail = Mail::load(Mail::TYPE_CONFIRM_ORDER_STORE);\n if ($mail instanceof Mail) {\n $subject = $mail->getSubject();\n $body = $mail->getBody();\n\n $token_service = \\Drupal::token();\n $subject = $token_service->replace($subject, [\n 'commerce_order' => $order\n ]);\n $body = $token_service->replace($body, [\n 'commerce_order' => $order\n ]);\n\n $body = str_replace('[resumen]', $resumen, $body);\n $body = str_replace('[datos_envio]', $envio, $body);\n\n $params = [\n 'from' => $order->getStore()->getEmail(),\n 'subject' => $subject,\n 'body' => ['#markup' => Markup::create($body)],\n ];\n\n $query = \\Drupal::entityQuery('user');\n $query->condition('roles', ['propietario'], 'IN');\n $result = $query->execute();\n foreach ($result as $id) {\n /** @var User $user */\n $user = User::load($id);\n $to = $user->getEmail();\n $this->mailManager->mail('commerce', 'admin_order_completed', $user->getEmail(), $langcode, $params);\n \\Drupal::logger('correo')->info('Pedido #' . $order->id() . ' completado enviado al propietario ' . $to);\n }\n }\n\n // Correo del proveedor\n $mail = Mail::load(Mail::TYPE_CONFIRM_ORDER_PROVIDER);\n if ($mail instanceof Mail) {\n $subject = $mail->getSubject();\n $body = $mail->getBody();\n\n $token_service = \\Drupal::token();\n $subject = $token_service->replace($subject, [\n 'commerce_order' => $order\n ]);\n $body = $token_service->replace($body, [\n 'commerce_order' => $order\n ]);\n $body = str_replace('[datos_envio]', $envio, $body);\n\n $params = [\n 'from' => $order->getStore()->getEmail(),\n 'subject' => $subject,\n 'body' => ['#markup' => Markup::create($body)],\n ];\n\n $proveedores = [];\n\n foreach ($order->getItems() as $item) {\n /** @var OrderItem $line */\n $line = $item;\n if ($line->get('field_proveedor')->target_id) {\n $usuario = User::load($line->get('field_proveedor')->target_id);\n if ($usuario instanceof User) {\n $total = $line->getTotalPrice();\n $price = $total->toArray();\n if (!isset($proveedores[$usuario->id()])) {\n $proveedores[$usuario->id()]['user'] = $usuario;\n $proveedores[$usuario->id()]['total'] = $price['number'];\n }\n else {\n $proveedores[$usuario->id()]['total'] += $price['number'];\n }\n $proveedores[$usuario->id()]['lines'][] = $line;\n }\n }\n }\n\n foreach ($proveedores as $uid => $proveedor) {\n\n $resumen = [\n '#theme' => 'correo_resumen_pedido_proveedor',\n '#order_items' => $proveedor['lines'],\n '#total' => $proveedor['total']\n ];\n\n if (isset($gastos_envio_proveedor[$uid])) {\n $resumen['#total'] += $gastos_envio_proveedor[$uid];\n $resumen['#gastos_envio'] = $gastos_envio_proveedor[$uid];\n }\n\n $resumen = \\Drupal::service('renderer')->render($resumen);\n $body_proveedor = str_replace('[resumen]', $resumen, $body);\n $body_proveedor = $token_service->replace($body_proveedor, [\n 'user' => $proveedor['user']\n ]);\n $params['body'] = ['#markup' => Markup::create($body_proveedor)];\n $to = $proveedor['user']->getEmail();\n $this->mailManager->mail('commerce', 'proveedor_order_completed', $proveedor['user']->getEmail(), $langcode, $params);\n \\Drupal::logger('correo')->info('Pedido #' . $order->id() . ' completado enviado al proveedor ' . $to);\n }\n }\n\n }", "title": "" }, { "docid": "1aa802e0369845461b549571ed38a9b2", "score": "0.5896239", "text": "public function sendNotificationEmail()\n\t{\n\t\t/* @var modContext $context */\n\t\tif ($context = $this->modx->getObject('modContext', array('key' => $this->getProperty('context', null)))) {\n\t\t\t$context->prepare(true);\n\t\t\t$lang = $context->getOption('cultureKey');\n\t\t\t$this->modx->setOption('cultureKey', $lang);\n\t\t\t$this->modx->lexicon->load($lang . ':paymentsystem:default', $lang . ':core:default', $lang . ':core:user');\n\t\t}\n\n\t\tif ($this->getProperty('passwordnotifymethod') == 'e') {\n\t\t\t$message = $this->modx->getOption('signupemail_message');\n\t\t\t$pls = array(\n\t\t\t\t'uid' => $this->object->get('username'),\n\t\t\t\t'pwd' => $this->newPassword,\n\t\t\t\t'ufn' => $this->profile->get('fullname'),\n\t\t\t\t'sname' => $this->modx->getOption('site_name'),\n\t\t\t\t'saddr' => $this->modx->getOption('emailsender'),\n\t\t\t\t'semail' => $this->modx->getOption('emailsender'),\n\t\t\t\t'surl' => $this->modx->getOption('url_scheme') . $this->modx->getOption('http_host') . $this->modx->getOption('manager_url'),\n\t\t\t);\n\n\t\t\tforeach ($pls as $k => $v) {\n\t\t\t\t$message = str_replace('[[+'.$k.']]',$v,$message);\n\t\t\t}\n\t\t\t$this->object->sendEmail($message);\n\t\t}\n\t}", "title": "" }, { "docid": "c24f3944d5c1b07a704576995be913b0", "score": "0.58928216", "text": "function sendEmail($email, $serAddr, $id, $back_up = 0) {\n\t\t$mailer = new Simple_Mail();\n\t\t\n\t\tif($back_up) {\n\t\t\t$send = $mailer->setTo($email, 'TinyMTR')\n\t\t\t\t->setSubject('Status-Alert - ' . $serAddr)\n\t\t\t\t->setFrom('noreply@picotory.com', 'TinyMTR')\n\t\t\t\t->addMailHeader('Reply-To', 'noreply@picotory.com', 'TinyMTR')\n\t\t\t\t->addGenericHeader('X-Mailer', 'PHP/' . phpversion())\n\t\t\t\t->addGenericHeader('Content-Type', 'text/html; charset=\"utf-8\"')\n\t\t\t\t->setMessage('<p>Status<br /><br />ID(' . $id . ') ' . $serAddr . ' seems to be back online!</p>')\n\t\t\t\t->setWrap(78)\n\t\t\t\t->send();\n\t\t}else{\n\t\t\t$send = $mailer->setTo($email, 'TinyMTR')\n\t\t\t\t->setSubject('Status-Alert - ' . $serAddr)\n\t\t\t\t->setFrom('noreply@picotory.com', 'TinyMTR')\n\t\t\t\t->addMailHeader('Reply-To', 'noreply@picotory.com', 'TinyMTR')\n\t\t\t\t->addGenericHeader('X-Mailer', 'PHP/' . phpversion())\n\t\t\t\t->addGenericHeader('Content-Type', 'text/html; charset=\"utf-8\"')\n\t\t\t\t->setMessage('<p>Status Alert!<br /><br />ID(' . $id . ') ' . $serAddr . ' seems to be offline!</p>')\n\t\t\t\t->setWrap(78)\n\t\t\t\t->send();\n\t\t}\n\t\n\t\treturn true;\n\t}", "title": "" }, { "docid": "ea43c18dfb76f69f3f3785ab48e27edb", "score": "0.58926606", "text": "public function sendNewOrderEmail()\n {\n if (!Mage::helper('sales')->canSendNewOrderEmail($this->getStore()->getId())) {\n return $this;\n }\n\n $translate = Mage::getSingleton('core/translate');\n /* @var $translate Mage_Core_Model_Translate */\n $translate->setTranslateInline(false);\n\n $paymentBlock = Mage::helper('payment')->getInfoBlock($this->getPayment())\n ->setIsSecureMode(true);\n\n $paymentBlock->getMethod()->setStore($this->getStore()->getId());\n\n $mailTemplate = Mage::getModel('core/email_template');\n /* @var $mailTemplate Mage_Core_Model_Email_Template */\n $copyTo = $this->_getEmails(self::XML_PATH_EMAIL_COPY_TO);\n $copyMethod = Mage::getStoreConfig(self::XML_PATH_EMAIL_COPY_METHOD, $this->getStore()->getId());\n if ($copyTo && $copyMethod == 'bcc') {\n foreach ($copyTo as $email) {\n $mailTemplate->addBcc($email);\n }\n }\n\n if ($this->getCustomerIsGuest()) {\n $template = Mage::getStoreConfig(self::XML_PATH_EMAIL_GUEST_TEMPLATE, $this->getStore()->getId());\n $customerName = $this->getBillingAddress()->getName();\n } else {\n $template = Mage::getStoreConfig(self::XML_PATH_EMAIL_TEMPLATE, $this->getStore()->getId());\n $customerName = $this->getCustomerName();\n }\n\n $sendTo = array(\n array(\n 'email' => $this->getCustomerEmail(),\n 'name' => $customerName\n )\n );\n if ($copyTo && $copyMethod == 'copy') {\n foreach ($copyTo as $email) {\n $sendTo[] = array(\n 'email' => $email,\n 'name' => null\n );\n }\n }\n\n if(Mage::getStoreConfig('sales_email/order/attachpdf',$this->getStore()->getId())){\n //Create Pdf and attach to email - play nicely with PDF Customiser\n if (file_exists(BP.'/app/code/community/Fooman/PdfCustomiser/Model/Order.php')){\n $pdf = Mage::getModel('pdfcustomiser/order')->getPdf(array($this),null,null,true); \n }else{\n $pdf = Mage::getModel('emailattachments/order_pdf_order')->getPdf($this); \n }\n $mailTemplate = Mage::helper('emailattachments')->addAttachment($pdf,$mailTemplate,Mage::helper('sales')->__('Order').\"_\".$this->getIncrementId());\n }\n\n if(Mage::getStoreConfig('sales_email/order/attachagreement',$this->getStore()->getId())){\n $mailTemplate = Mage::helper('emailattachments')->addAgreements($this->getStore()->getId(),$mailTemplate);\n }\n\n foreach ($sendTo as $recipient) {\n $mailTemplate->setDesignConfig(array('area'=>'frontend', 'store'=>$this->getStore()->getId()))\n ->sendTransactional(\n $template,\n Mage::getStoreConfig(self::XML_PATH_EMAIL_IDENTITY, $this->getStore()->getId()),\n $recipient['email'],\n $recipient['name'],\n array(\n 'order' => $this,\n 'billing' => $this->getBillingAddress(),\n 'payment_html' => $paymentBlock->toHtml(),\n )\n );\n }\n\n $translate->setTranslateInline(true);\n\n return $this;\n }", "title": "" }, { "docid": "d2056167d500a7c05c42f6d6740a4d1e", "score": "0.5889513", "text": "public function send_bulk_mails() {\n\t\ttry {\n\t\t\tif ($_SERVER[\"REQUEST_METHOD\"] == \"POST\" && $_SESSION['csrf'] == $_POST['csrf']) {\n\n\t\t\t\tif (isset($_POST['mail']) && $_POST['mail'] != '' && isset($_POST['send']) && !empty($_POST['send'])) {\n\t\t\t\t\t$sql_template = $this->dbConn->prepare(\"select * from mails where id = ? LIMIT 1\");\n\t\t\t\t\t$sql_template->execute(array($_POST['mail']));\n\t\t\t\t\t$count_template = $sql_template->rowCount();\n\n\t\t\t\t\t// update the email from template\n\t\t\t\t\tif ($count_template > 0) {\n\t\t\t\t\t\twhile ($row_template = $sql_template->fetch()) {\n\t\t\t\t\t\t\t$body = $row_template['body'];\n\t\t\t\t\t\t\t$body = str_ireplace('{{COMPANY_EMAIL}}', COMPANY_EMAIL, $body);\n\t\t\t\t\t\t\t$body = str_ireplace('{{SalesCRM}}', APP_NAME, $body);\n\t\t\t\t\t\t\t$body = str_ireplace('{{http://www.salescrm.com}}', WEBSITE_LINK, $body);\n\t\t\t\t\t\t\t$body = str_ireplace('{{www.salescrm.com}}', WEBSITE, $body);\n\t\t\t\t\t\t\t$subject = $row_template['subject'] . ' to ' . APP_NAME;\n\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t}\n\t\t\t\t\t\t \n\t\t\t\t\t\t// details to send mail\n\t\t\t\t\t\t// also update the name as per this user name\n\t\t\t\t\t\tforeach ($_POST['send'] as $details) {\n\t\t\t\t\t\t\t$temp = explode('#', $details);\n\t\t\t\t\t\t\t$email = $temp[0];\n\t\t\t\t\t\t\t$name = $temp[1];\n\t\t\t\t\t\t\t$company_name = $temp[2];\n\n\t\t\t\t\t\t\t$body = str_ireplace('{{FIRST_NAME}}', $name, $body);\n\t\t\t\t\t\t\t$body = str_ireplace('{{ENCODED_EMAIL}}', base64_encode($email), $body);\n\t\t\t\t\t\t\t$body = str_ireplace('{{COMPANY}}', $company_name, $body);\n\t\t\t\t\t\t\t$body = str_ireplace('{{USERNAME}}', '<b>' . $email . '</b>', $body);\n\t\t\t\t\t\t\t$body = str_ireplace('{{PASSWORD}}', 'Your password which you have provided at registration time', $body);\n\n\t\t\t\t\t\t\t$to = [\n\t\t\t\t\t\t\t\t'email' => $email,\n\t\t\t\t\t\t\t\t'name' => $name,\n\t\t\t\t\t\t\t];\n\n\t\t\t\t\t\t\t$reply = [\n\t\t\t\t\t\t\t\t'email' => MAIL_FROM_EMAIL,\n\t\t\t\t\t\t\t\t'name' => MAIL_FROM_NAME,\n\t\t\t\t\t\t\t];\n\n\t\t\t\t\t\t\t$reply_to = [\n\t\t\t\t\t\t\t\t'email' => MAIL_REPLY_TO_EMAIL,\n\t\t\t\t\t\t\t\t'name' => MAIL_REPLY_TO_NAME,\n\t\t\t\t\t\t\t];\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif ($this->misc->send_mail($to, $reply, $reply_to, $subject, $body)) {\n\t\t\t\t\t\t\t\techo '200';\n\t\t\t\t\t\t\t\texit;\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\techo '400';\n\t\t\t\t\t\t\t\texit;\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} else {\n\t\t\t\t\techo '409';\n\t\t\t\t\texit;\n\t\t\t\t}\n\n\t\t\t} else {\n\t\t\t\techo '409';\n\t\t\t\texit;\n\t\t\t}\n\n\t\t} catch (\\Exception $exception) {\n\t\t\t$this->misc->log('Manager ' . __METHOD__, $exception);\n\t\t}\n\t}", "title": "" }, { "docid": "63f2faa4c469f26dba94469e8f377e9d", "score": "0.58736455", "text": "public function sendEmailVerificationNotification(): void\n {\n /** @var array $emailContent */\n $emailContent = Setting::findOrFail('email_content')->value;\n\n $verifyEmailUrl = URL::temporarySignedRoute(\n 'auth.end-user.verification.verify',\n Date::now()->addMinutes(Config::get('auth.verification.expire', 60)),\n ['id' => $this->user->getKey()]\n );\n\n $this->dispatchNow(new TemplateMail(\n $this->user->email,\n Arr::get($emailContent, 'end_user.email_confirmation.subject'),\n Arr::get($emailContent, 'end_user.email_confirmation.body'),\n new EmailConfirmationSubstituter($this, $verifyEmailUrl)\n ));\n }", "title": "" }, { "docid": "39272190c96b6a7c66ecad4af51b100a", "score": "0.58684486", "text": "public function emailToGuarantorSuccessAction()\n {\n /** @var \\Barbondev\\IRISSDK\\IndividualApplication\\ReferencingApplication\\Model\\ReferencingApplication $case */\n $application = $this\n ->getAgentGuarantorProgressiveStore()\n ->getPrototypeByClass(self::MODEL_APPLICATION_CLASS)\n ;\n\n // Clear and add existing prototypes\n $this\n ->getAgentGuarantorProgressiveStore()\n ->clearPrototypes()\n ->initialisePrototypes()\n ->storePrototypes()\n ;\n\n $this->renderTwigView('/iris-add-guarantor/email-to-guarantor-success.html.twig', array(\n 'bodyTitle' => 'Email Sent to Guarantor',\n 'application' => $application,\n ));\n }", "title": "" }, { "docid": "3f73d993eef6a5b9a9faab6d7ab655f6", "score": "0.5860506", "text": "function cmd_send_mail($row)\t{\r\n\t\tglobal $LANG, $TYPO3_DB;\r\n\r\n\t\t\t// Preparing mailer\r\n\t\t$htmlmail = t3lib_div::makeInstance('dmailer');\r\n\t\t$htmlmail->nonCron = 1;\r\n\t\t$htmlmail->start();\r\n\t\t$htmlmail->dmailer_prepare($row);\r\n\r\n\t\t$sentFlag=false;\r\n\t\tif (t3lib_div::_GP('mailingMode_simple'))\t{\r\n\t\t\t\t// setting Testmail flag\r\n\t\t\t$htmlmail->testmail = $this->params['testmail'];\r\n\r\n\t\t\t\t// Fixing addresses:\r\n\t\t\t$addresses = t3lib_div::_GP('SET');\r\n\t\t\t$addressList = $addresses['dmail_test_email'] ? $addresses['dmail_test_email'] : $this->MOD_SETTINGS['dmail_test_email'];\r\n\t\t\t$addresses = split(chr(10).'|,|;',$addressList);\r\n\t\t\treset($addresses);\r\n\t\t\twhile(list($key,$val)=each($addresses))\t{\r\n\t\t\t\t$addresses[$key]=trim($val);\r\n\t\t\t\tif (!strstr($addresses[$key],'@'))\t{\r\n\t\t\t\t\tunset($addresses[$key]);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t$hash = array_flip($addresses);\r\n\t\t\t$addresses = array_keys($hash);\r\n\t\t\t$addressList = implode(',', $addresses);\r\n\r\n\t\t\tif ($addressList)\t{\r\n\t\t\t\t\t// Sending the same mail to lots of recipients\r\n\t\t\t\t$htmlmail->dmailer_sendSimple($addressList);\r\n\t\t\t\t$sentFlag=true;\r\n\t\t\t\t$theOutput.= $this->doc->section($LANG->getLL('send_sending'),fw($LANG->getLL('send_was_sent'). '<br /><br />' . $LANG->getLL('send_recipients') . '<br />'.$addressList), 1, 1, 0, TRUE);\r\n\t\t\t\t$this->noView=1;\r\n\t\t\t}\r\n\t\t} else {\t// extended, personalized emails.\r\n\t\t\tif ($this->CMD=='send_mail_test')\t{\r\n\t\t\t\t\t// setting Testmail flag\r\n\t\t\t\t$htmlmail->testmail = $this->params['testmail'];\r\n\r\n\t\t\t\tif (t3lib_div::_GP('tt_address_uid'))\t{\r\n\t\t\t\t\t$res = $TYPO3_DB->exec_SELECTquery(\r\n\t\t\t\t\t\t'tt_address.*',\r\n\t\t\t\t\t\t'tt_address LEFT JOIN pages ON pages.uid=tt_address.pid',\r\n\t\t\t\t\t\t'tt_address.uid='.intval(t3lib_div::_GP('tt_address_uid')).\r\n\t\t\t\t\t\t\t' AND '.$this->perms_clause.\r\n\t\t\t\t\t\t\tt3lib_BEfunc::deleteClause('pages').\r\n\t\t\t\t\t\t\tt3lib_BEfunc::BEenableFields('tt_address').\r\n\t\t\t\t\t\t\tt3lib_BEfunc::deleteClause('tt_address')\r\n\t\t\t\t\t\t);\r\n\t\t\t\t\tif ($recipRow = $TYPO3_DB->sql_fetch_assoc($res))\t{\r\n\t\t\t\t\t\t$recipRow = dmailer::convertFields($recipRow);\r\n\t\t\t\t\t\t$recipRow['sys_dmail_categories_list'] = $htmlmail->getListOfRecipentCategories('tt_address',$recipRow['uid']);\r\n\t\t\t\t\t\t$htmlmail->dmailer_sendAdvanced($recipRow,'t');\r\n\t\t\t\t\t\t$sentFlag=true;\r\n\t\t\t\t\t\t$theOutput.= $this->doc->section($LANG->getLL('send_sending'),fw(sprintf($LANG->getLL('send_was_sent_to_name'), $recipRow['name'].htmlspecialchars(' <'.$recipRow['email'].'>'))), 1, 1, 0, TRUE);\r\n\t\t\t\t\t\t$this->noView=1;\r\n\t\t\t\t\t}\r\n\t\t\t\t} elseif (t3lib_div::_GP('sys_dmail_group_uid'))\t{\r\n\t\t\t\t\t$result = $this->cmd_compileMailGroup(t3lib_div::_GP('sys_dmail_group_uid'));\r\n\r\n\t\t\t\t\t$idLists = $result['queryInfo']['id_lists'];\r\n\t\t\t\t\t$sendFlag=0;\r\n\t\t\t\t\t$sendFlag+=$this->sendTestMailToTable($idLists,'tt_address',$htmlmail);\r\n\t\t\t\t\t$sendFlag+=$this->sendTestMailToTable($idLists,'fe_users',$htmlmail);\r\n\t\t\t\t\t$sendFlag+=$this->sendTestMailToTable($idLists,'PLAINLIST',$htmlmail);\r\n\t\t\t\t\t$sendFlag+=$this->sendTestMailToTable($idLists,$this->userTable,$htmlmail);\r\n\t\t\t\t\t$theOutput.= $this->doc->section($LANG->getLL('send_sending'),fw(sprintf($LANG->getLL('send_was_sent_to_number'), $sendFlag)), 1, 1, 0, TRUE);\r\n\t\t\t\t\t$this->noView=1;\r\n\t\t\t\t}\r\n\t\t\t} else {\r\n\t\t\t\t$mailgroup_uid = t3lib_div::_GP('mailgroup_uid');\r\n\t\t\t\tif (t3lib_div::_GP('mailingMode_mailGroup') && $this->sys_dmail_uid && intval($mailgroup_uid))\t{\r\n\t\t\t\t\t\t// Update the record:\r\n\t\t\t\t\t$result = $this->cmd_compileMailGroup(intval($mailgroup_uid));\r\n\t\t\t\t\t$query_info=$result['queryInfo'];\r\n\r\n\t\t\t\t\t$distributionTime = intval(t3lib_div::_GP('send_mail_datetime'));\r\n\t\t\t\t\t$distributionTime = $distributionTime<time() ? time() : $distributionTime;\r\n\r\n\t\t\t\t\t$updateFields = array(\r\n\t\t\t\t\t\t'scheduled' => $distributionTime,\r\n\t\t\t\t\t\t'query_info' => serialize($query_info)\r\n\t\t\t\t\t\t);\r\n\r\n\t\t\t\t\tif (t3lib_div::_GP('testmail')) {\r\n\t\t\t\t\t\t$dmail = t3lib_BEfunc::getRecord('sys_dmail',intval($this->sys_dmail_uid),'subject');\r\n\r\n\t\t\t\t\t\t$updateFields['subject'] = $this->params['testmail'].' '.$dmail['subject'];\r\n\r\n\t\t\t\t\t\tunset($dmail);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t$TYPO3_DB->exec_UPDATEquery(\r\n\t\t\t\t\t\t'sys_dmail',\r\n\t\t\t\t\t\t'uid='.intval($this->sys_dmail_uid),\r\n\t\t\t\t\t\t$updateFields\r\n\t\t\t\t\t\t);\r\n\r\n\t\t\t\t\t$sentFlag=true;\r\n\t\t\t\t\t$theOutput.= $this->doc->section($LANG->getLL('send_was_scheduled'),fw($LANG->getLL('send_was_scheduled_for') . ' '.t3lib_BEfunc::datetime($distributionTime)), 1, 1, 0, TRUE);\r\n\t\t\t\t\t$this->noView=1;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t\t// Setting flags:\r\n\t\tif ($sentFlag && $this->CMD=='send_mail_final')\t{\r\n\t\t\t\t// Update the record:\r\n\t\t\t$TYPO3_DB->exec_UPDATEquery(\r\n\t\t\t\t'sys_dmail',\r\n\t\t\t\t'uid='.intval($this->sys_dmail_uid),\r\n\t\t\t\tarray('issent' => 1)\r\n\t\t\t\t);\r\n\t\t}\r\n\t\treturn $theOutput;\r\n\t}", "title": "" }, { "docid": "3b8e223d6df3488026d36c123e345b8a", "score": "0.58598316", "text": "public function sendEmailVerificationNotification();", "title": "" }, { "docid": "816461ff70d39ef4a541a47a43aede25", "score": "0.5858058", "text": "private function send_email(&$to=null, &$from=null, &$subject=null, &$message=null, &$alt_message=false) \n\t{\t\n\t\t$this->ci->load->library('email');\n\t\t$this->ci->email->initialize($this->config);\n\t\t\n\t\t$this->ci->email->to($to);\n\t\t$this->ci->email->from($from);\n\t\t$this->ci->email->subject($subject);\n\t\t$this->ci->email->message($message);\n\t\tif ($alt_message)\n\t\t{\n\t\t\t$this->ci->email->set_alt_message($alt_message);\n\t\t}\n\t\t\t\t\n\t\t$result['success'] = $this->ci->email->send();\n\t\t\n\t\tif ($this->debug)\n\t\t{\n\t\t\t$result['debug'] = $this->ci->email->print_debugger();\n\t\t}\n\t\t\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "474626fc6ebd72bf164f7600881147c7", "score": "0.5853285", "text": "public function sendEmailVerificationNotification()\n {\n $this->notify(new VerifyEmail); // my notification\n }", "title": "" }, { "docid": "64bc2d3a24e728ca9839eb048f5ea6b1", "score": "0.58524406", "text": "public function sendPayLinkEmail($to, $user, $id)\n\t{\n\t\t$this->load->library('email');\n\t\t\n\t\t// Setup the mail library\n\t\t$config['mailtype'] = 'html';\n\t\t$this->email->initialize($config);\n\t\t\n\t\t// Set email options\n\t\t$this->email->from($this->startup->site_config['site_email'], $this->startup->site_config['sitename'].' Support');\n\t\t$this->email->to($to);\n\t\t$this->email->subject('New user at '.$this->startup->site_config['sitename'].'!');\n\t\t\n\t\t$msg = 'Hello '.$user->username.',<br />Welcome to '.$this->startup->site_config['sitename'].'!<br /><br />Before you account is activated you need to pay using the following link. If you have already completed the payment process, please wait while we authorize your payment. Once complete you will recive a new email containg your details.<br /><br /><a href=\"'.site_url('user/pay_new/'.$id.'/'.$user->gateway).'\">Pay Here</a><br /><br />Thanks for joining our community!<br />'.$this->startup->site_config['sitename'].' Administration';\n\n\t\t$this->email->message($msg);\n\t\t\n\t\t// Send the email\n\t\t$this->email->send();\n\t}", "title": "" }, { "docid": "0db3dbb9eea0d062abc9eb02285a079e", "score": "0.5851304", "text": "public function sendEmail()\n {\n /* @var $user from User validator user variable */\n\n $user = $this->validators[2]->user;\n Auction::info('User is ready to sent a new Token');\n\n switch ($this->via){\n case 'email' :\n ForgotPasswordHistory::model()->generateOtp($user);\n break;\n\n case 'sms':\n OptHistory::model()->generateOtp($user);\n }\n return false;\n }", "title": "" }, { "docid": "24810ba711d89887fbc2c459dce6627c", "score": "0.58496076", "text": "public function emailMeAction() {\r\n\r\n //DEFAULT LAYOUT\r\n $this->_helper->layout->setLayout('default-simple');\r\n\r\n //GET VIEWER DETAIL\r\n $viewer = Engine_Api::_()->user()->getViewer();\r\n $viewr_id = $viewer->getIdentity();\r\n\r\n //GET STORE ID AND STORE OBJECT\r\n $this->view->store_id = $store_id = $this->_getParam('store_id', $this->_getParam('id', null));\r\n $sitestore = Engine_Api::_()->getItem('sitestore_store', $store_id);\r\n if (empty($sitestore))\r\n return $this->_forwardCustom('notfound', 'error', 'core');\r\n \r\n //AUTHORIZATION CHECK FOR TELL A FRIEND\r\n $isManageAdmin = Engine_Api::_()->sitestore()->isManageAdmin($sitestore, 'tfriend');\r\n if (empty($isManageAdmin)) {\r\n return $this->_forwardCustom('requireauth', 'error', 'core');\r\n }\r\n\r\n //FORM GENERATION\r\n $this->view->form = $form = new Sitestore_Form_EmailMe();\r\n\r\n if (!empty($viewr_id)) {\r\n $value['sender_email'] = $viewer->email;\r\n $value['sender_name'] = $viewer->displayname;\r\n $form->populate($value);\r\n }\r\n\r\n if ($this->getRequest()->isPost() && $form->isValid($this->getRequest()->getPost())) {\r\n\r\n $values = $form->getValues();\r\n\r\n //EDPLODES EMAIL IDS\r\n $reciver_ids = $sitestore->email; //explode(',', $values['sitestore_reciver_emails']);\r\n $values['sitestore_sender_email'] = $sitestore->email;\r\n if (!empty($values['sitestore_send_me'])) {\r\n $reciver_ids = $values['sitestore_sender_email'];\r\n }\r\n $sender_email = $values['sitestore_sender_email'];\r\n\r\n //CHECK VALID EMAIL ID FORMITE\r\n $validator = new Zend_Validate_EmailAddress();\r\n $validator->getHostnameValidator()->setValidateTld(false);\r\n\r\n if (!$validator->isValid($sender_email)) {\r\n $form->addError(Zend_Registry::get('Zend_Translate')->_('Invalid sender email address value'));\r\n return;\r\n }\r\n// foreach ($reciver_ids as $reciver_id) {\r\n// $reciver_id = trim($reciver_id, ' ');\r\n// if (!$validator->isValid($reciver_id)) {\r\n// $form->addError(Zend_Registry::get('Zend_Translate')->_('Please enter correct email address of the receiver(s).'));\r\n// return;\r\n// }\r\n// }\r\n $sender = $values['sitestore_sender_name'];\r\n $message = $values['sitestore_message'];\r\n $heading = ucfirst($sitestore->getTitle());\r\n Engine_Api::_()->getApi('mail', 'core')->sendSystem($reciver_ids, 'SITESTORE_EMAILME_EMAIL', array(\r\n 'host' => $_SERVER['HTTP_HOST'],\r\n 'sender_name' => $sender,\r\n 'store_title' => $heading,\r\n 'message' => '<div>' . $message . '</div>',\r\n 'object_link' => 'http://' . $_SERVER['HTTP_HOST'] . Engine_Api::_()->sitestore()->getHref($sitestore->store_id, $sitestore->owner_id, $sitestore->getSlug()),\r\n 'sender_email' => $sender_email,\r\n 'queue' => true\r\n ));\r\n\r\n $this->_forwardCustom('success', 'utility', 'core', array(\r\n 'smoothboxClose' => true,\r\n 'parentRefresh' => false,\r\n 'format' => 'smoothbox',\r\n 'messages' => array(Zend_Registry::get('Zend_Translate')->_('Your message to store owner has been sent successfully.'))\r\n ));\r\n }\r\n }", "title": "" }, { "docid": "e256639260dff6a8dfe9bf4dbfd9f652", "score": "0.5849362", "text": "function sendEmailtouser($message1)\n {\n $userDetail = $this->session->userdata('logged_in');\n $userId = $userDetail [USER_ID];\n $user = $this->Bookingmodel->getUserEmail($userId);\n $constants = $this->Bookingmodel->getConstants();\n $this->load->library('email');\n $this->email->from($constants->fromEmail);\n $to = $this->email->to($user->emailID);\n $this->email->subject('Driveway Booking cancel');\n $this->email->message($message1);\n if (!$this->email->send()) {\n $emailInfo['emailStatus'] = 0;\n $emailInfo['toEmail'] = $to;\n $emailInfo['fromEmail'] = $constants->fromEmail;\n $emailInfo['content'] = $message1;\n $emailInfo['subject'] = 'Driveway Booking cancel';\n $this->load->model('profile/Profilemodel');\n $this->Profilemodel->saveEmailStatus($emailInfo);\n }\n }", "title": "" }, { "docid": "e21722fe722fe901a573816bb8129023", "score": "0.5844202", "text": "private function sendConfirmationMail($to, $text, $file)\n {\n $msgService = MsgService::getInstance();\n $config = \\Config::getInstance();\n global $error;\n $mail = new \\PHPMailer(); // create a new object\n $mail->IsSMTP(); // enable SMTP\n $mail->SMTPDebug = 0; // debugging: 1 = errors and messages, 2 = messages only\n $mail->SMTPAuth = true; // authentication enabled\n $mail->SMTPSecure = 'ssl'; // secure transfer enabled REQUIRED for GMail\n $mail->Host = $config->smtp;\n $mail->Port = $config->smtp_port;\n $mail->Username = $config->email;\n $mail->Password = $config->email_pw;\n $mail->SetFrom($config->email, \"Moebius furniturus\");\n $mail->Subject = $msgService->getName(\"email_subject\");\n $mail->Body = $text;\n $mail->IsHTML(true);\n $mail->AddAddress($to);\n $mail->AddAttachment($file, \"order.pdf\");\n if (!$mail->Send()) {\n $error = 'Mail error: ' . $mail->ErrorInfo;\n echo $error;\n return false;\n } else {\n return true;\n }\n }", "title": "" }, { "docid": "1e71b968f49986f7faae2c127f408f25", "score": "0.5840877", "text": "function send_email_to_customer($customer, $template='reminder'){\n $data = array('domain' => $customer->domain);\n #print \"sending mail to \" . $customer->contact_email; \n return sendTemplateEmail($customer->contact_email, $template, $data);\n}", "title": "" }, { "docid": "a6bd163ad7deb2289b14ab12a3131210", "score": "0.58359194", "text": "private function sendBookingNotification() {\r\n\t\t$room_name = $this->ilRoomsharingDatabase->getRoomName($this->room_id);\r\n\r\n\t\t$mailer = new ilRoomSharingMailer($this->lng);\r\n\t\t$mailer->setRoomname($room_name);\r\n\t\t$mailer->setDateStart($this->date_from);\r\n\t\t$mailer->setDateEnd($this->date_to);\r\n\t\t$mailer->sendBookingMail($this->user->getId(), $this->participants);\r\n\t}", "title": "" }, { "docid": "d5702641f2140bfee116f4b4fc567023", "score": "0.58343583", "text": "function sendMentorCreationNotification($toEmail) {\n\t\tinclude \"../internalIncludes/dbconfig.php\";\n\t\t#Used for error checking\n\t\t#ini_set('display_errors','on');\n\t\t#error_reporting(E_ALL); \n \n $call = \"CALL GetAdminEmailCredentials\";\n $q = $conn->query($call);\n $r = $q->fetch_assoc();\n $EmailAddress = $r['EmailAddress'];\n $Password = $r['Password'];\n mysqli_next_result($conn);\n \n \n\t\t$from = $EmailAddress;\n $to = $toEmail;\n\t\t$subject = \"Mentor Application – Email Verification Complete\";\n\t\t$message = \"\n\t\t<html>\n\t\t<head>\n\t\t<title>EWU Mentor Notification</title>\n\t\t</head>\n\t\t<body>\n\t\t<b>Thank you for verifying your EWU Mentorship Program email – we do this for your protection!</b>\n\t\t<br>\n\t\t<p>Your account is currently under review by an administrator. After it has been approved, you will get a notification email with instructions on how to log in. This review process can take up to 24 hours, but you may contact Career Services at 509.359.6365 to request expedited consideration.</p>\n\t\t<p>Thank you for your patience.</p>\n\t\t</body>\n\t\t</html>\";\n\t\t$host = \"smtp.office365.com\";\n\t\t$port = \"587\";\n\t\t$username = $EmailAddress;\n\t\t$password = $Password;\n $content = \"text/html; charset=utf-8\";\n $mime = \"1.0\";\n \n\t\t$headers = array ('From' => $from,\n\t\t 'To' => $to,\n\t\t 'Subject' => $subject,\n 'MIME-Version' => $mime,\n 'Content-type' => $content);\n \n\t\t$smtp = Mail::factory('smtp',\n\t\t array ('host' => $host,\n\t\t\t'port' => $port,\n\t\t\t'auth' => true,\n\t\t\t'username' => $username,\n\t\t\t'password' => $password));\n \n\t\t$mail = $smtp->send($to, $headers, $message);\n \n #Used for testing. Must be disabled for final product\n /*\n\t\tif (PEAR::isError($mail)) {\n\t\t echo(\"<p>\" . $mail->getMessage() . \"</p>\");\n\t\t } else {\n\t\t echo(\"<p>Message successfully sent!</p>\");\n\t\t }\n */\n\t}", "title": "" }, { "docid": "fed69ab1d3f12cbc9eabc6235fca5d79", "score": "0.5832761", "text": "public function sendMessage()\n {\n try {\n $service = $this->serviceFactory->create();\n $id = (int) $this->scopeConfig->getValue(self::SERVICE_CONFIG, ScopeInterface::SCOPE_STORE);\n if ($id) {\n $service->load($id);\n }\n\n $args = [\n 'message' => $this->message,\n 'config' => $service->getData(),\n 'parameters' => $this->parameters\n ];\n $type = $service->getTransportNameByType();\n\n $this->transportFactory\n ->create($type, $args)\n ->sendMessage()\n ;\n } catch (\\Exception $e) {\n $phrase = new \\Magento\\Framework\\Phrase($e->getMessage());\n throw new \\Magento\\Framework\\Exception\\MailException($phrase, $e);\n }\n }", "title": "" }, { "docid": "9a0f31a67a4a0b08566e99a73eeead2c", "score": "0.58257955", "text": "public function sender()\n {\n try{\n $customer = Session::getCustomer();\n $transaction = Session::getTransaction();\n\n $params = array();\n //credentials\n $params['user'] = $this->agency['Setting_User'];\n $params['password'] = $this->agency['Setting_Password'];\n //transaction\n $params['amount'] = $transaction->getAmount();\n $params['receivername'] = $customer->getCustomer();\n $params['receivercity'] = $customer->getStateName();\n $params['receiverstate'] = $customer->getState();\n $params['receivercountry'] = $customer->getCountry();\n\n $url = $this->agency['Setting_URL'];\n $response = $this->execSoapSimple($url, 'SubmitPayout', $params, array('uri' => 'http://WS/', 'soapaction' => ''));\n if($response && $response instanceof stdClass){\n\n $this->apiMessage = $response->comentario;\n $this->apiStatus = strtolower($response->status);\n if($this->apiStatus == self::STATUS_API_PENDING){\n\n $name = trim($response->envia);\n $personalId = Encrypt::generateMD5($name);\n\n $person = new Person();\n $person->setPersonLisId(100);\n $person->setCountry('CR');\n $person->setCountryId(52);\n $person->setCountryName('Costa Rica');\n $person->setState('SJ');\n $person->setStateId(877);\n $person->setStateName('San José');\n $person->setAvailable(1);\n $person->setIsActive(1);\n $person->setName($name);\n $person->setLastName('');\n $person->setPersonalId($personalId);\n $person->setTypeId('Hash');\n $person->setExpirationDateId('NR');\n $person->setAddress('NR');\n $person->setCity('San José');\n $person->setBirthDate('NR');\n $person->setMaritalStatus('NR');\n $person->setGender('NR');\n $person->setProfession('NR');\n $person->setPhone('NR');\n $person->setNameId($personalId);\n $person->add();\n\n if($response->trackId){\n $transaction->setApiTransactionId($response->trackId);\n if(is_numeric($response->cargo)){\n $transaction->setFee($response->cargo);\n }\n return $person;\n }\n\n return null;\n }elseif($this->apiStatus == self::STATUS_API_ERROR){\n\n if(stripos($this->apiMessage, 'No Names Available') !== false || stripos($this->apiMessage, 'No Payouts Names Available') !== false){\n\n $subject = \"No payouts names available\";\n $body = \"There are no payouts names available in Saturn agency\";\n $bodyTemplate = MailManager::getEmailTemplate('default', array('body' => $body));\n $recipients = array('To' => 'mgoficinasf0117@outlook.com', 'Cc' => CoreConfig::MAIL_DEV);\n MailManager::sendEmail($recipients, $subject, $bodyTemplate);\n\n Log::custom('Saturno', $body);\n $this->apiMessage = 'We cannot give this Customer a name';\n return null;\n }elseif(stripos(strtolower($this->apiMessage), 'black') && stripos(strtolower($this->apiMessage), 'list')){\n $this->apiMessage = 'The Customer has been blacklisted';\n return null;\n }elseif(stripos(strtolower($this->apiMessage), 'limit') && stripos(strtolower($this->apiMessage), 'reached')){\n $this->apiMessage = 'Limits: The Customer has exceeded the limits in MG';\n return null;\n }\n\n $this->apiMessage = 'We cannot give this Customer a name';\n return null;\n }\n\n Log::custom('Saturno', \"Invalid Object Response\" . \"\\n Request: \\n\\n\" . $this->getLastRequest() . \"\\n Response: \\n\\n\" . Util::objToStr($response));\n }\n\n }catch(Exception $ex){\n ExceptionManager::handleException($ex);\n }\n\n $this->apiMessage = 'We cannot give this Customer a name';\n return null;\n }", "title": "" }, { "docid": "db0fad397fd4c9bd13d8039eaed141fa", "score": "0.5822836", "text": "public function sendRefundEmailNotificationToAdmin() {\n $employeeRepo = new EmployeeRepository(new Employee);\n $employee = $employeeRepo->findEmployeeById(1);\n return true;\n Mail::to($employee)\n ->send(new sendEmailNotificationToAdminMailable($this->findOrderById($this->model->id)));\n }", "title": "" }, { "docid": "927ad6be74a191f40a93538706113d9f", "score": "0.5816013", "text": "public function sendMail()\n\t{\n\t\t// Basic checks\n\t\t$this->checkHeaders();\n\n\t\t// Get the mail object.\n\t\t$mail = $this->getMail();\n\n\t\t// Get the log message.\n\t\t$log = $this->getState('email.log');\n\n\t\tif (!$mail->Send()) {\n\t\t\tJLog::add(json_encode($log), JLog::ERROR, 'mailto');\n\n\t\t\tthrow new TextException('COM_MAILTO_EMAIL_NOT_SENT');\n\t\t}\n\n\t\t// Log the mail.\n\t\tJLog::add(json_encode($log), JLog::INFO, 'mailto');\n\t}", "title": "" }, { "docid": "48900a2639069eacab78c0ffd7672f2a", "score": "0.5812768", "text": "private function sendDepositMail($user, int $point)\n {\n Mail::to($user->email)\n ->queue(new \\App\\Mail\\Deposit($user, $point));\n }", "title": "" }, { "docid": "4d03112f7fafe2eaa0e88125162edb02", "score": "0.58035815", "text": "private function mail_send($dest,$msg,$heads){\n\t\t\n\t\t\t$subj = '';\n\t\t\tif(stripos($msg,'user_name',0) != false){\n\t\t\t\t\n\t\t\t\t$subj = 'Turtrozz Information Request';\n\t\t\t\t\n\t\t\t}else if(stripos($msg,'client_qname',0) != false){\n\t\t\t\t\n\t\t\t\t$subj = 'Turtrozz Quotation Request';\n\t\t\t\t\n\t\t\t}\n\t\t\telse{\n\t\t\t\t\n\t\t\t\t$subj = 'Turtrozz Subscription';\n\t\t\t\t\n\t\t\t}\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t\t\n\t\t\n\t\tDb_Storage::save_to_db(self::$user_data);\n\t\t\n\t\t\n\t\t\n\t\t\n\t}", "title": "" }, { "docid": "7a9dcbf0bd28c1dbc63f81fe786e1d08", "score": "0.5802291", "text": "protected function _sendEmail($subject, $template, $params, $recipient){\n // set content\n $mailService = $this->getServiceLocator()->get('AcMailer\\Service\\MailService');\n $mailService->setSubject($subject)->setTemplate($template, $params);\n \n // set recipient\n $message = $mailService->getMessage();\n $message->addTo($recipient);\n \n // send\n $result = $mailService->send();\n }", "title": "" }, { "docid": "ccd35f857b7cc780a5ff7ade390e63b9", "score": "0.58015347", "text": "function sendConfEmail($email, $amount, $pst, $gst, $subTotal, $productsOrdered, $receipt, $name) {\n\t\t//SMTP needs accurate times, and the PHP time zone MUST be set\n\t\t//This should be done in your php.ini, but this is how to do it if you don't have access to that\n\t\tdate_default_timezone_set('America/Vancouver');\n\t\trequire_once 'vendor/autoload.php';\n\t\t//Create a new PHPMailer instance\n\t\t$mail = new PHPMailer;\n\t\t//Tell PHPMailer to use SMTP\n\t\t$mail->isSMTP();\n\t\t//Enable SMTP debugging\n\t\t// 0 = off (for production use)\n\t\t// 1 = client messages\n\t\t// 2 = client and server messages\n\t\t$mail->SMTPDebug = 0;\n\t\t//Ask for HTML-friendly debug output\n\t\t$mail->Debugoutput = 'html';\n\t\t//Set the hostname of the mail server\n\t\t$mail->Host = 'smtp.gmail.com';\n\t\t// use\n\t\t// $mail->Host = gethostbyname('smtp.gmail.com');\n\t\t// if your network does not support SMTP over IPv6\n\t\t//Set the SMTP port number - 587 for authenticated TLS, a.k.a. RFC4409 SMTP submission\n\t\t$mail->Port = 587;\n\t\t$mail->IsHTML(true);\n\t\t\n\t\t//Set the encryption system to use - ssl (deprecated) or tls\n\t\t$mail->SMTPSecure = 'tls';\n\t\t//Whether to use SMTP authentication\n\t\t$mail->SMTPAuth = true;\n\t\t//Username to use for SMTP authentication - use full email address for gmail\n\t\t$mail->Username = \"grp04.ics199@gmail.com\";\n\t\t//Password to use for SMTP authentication\n\t\t$mail->Password = \"Password199\";\n\t\t//Set who the message is to be sent from\n\t\t$mail->setFrom('grp04.ics199@gmail.com');\n\t\t//Set an alternative reply-to address\n\t\t//$mail->addReplyTo('replyto@example.com', 'First Last');\n\t\t//Set who the message is to be sent to\n\t\t$mail->addAddress($email);\n\t\t//Set the subject line\n\t\t$mail->Subject = 'Berryman Brothers Purchase Confirmation Email';\n\t\t//Read an HTML message body from an external file, convert referenced images to embedded,\n\t\t//convert HTML into a basic plain-text alternative body\n\t\t//$mail->msgHTML(file_get_contents('contents.html'), dirname(__FILE__));\n\t\t//Replace the plain text body with one created manually\n\t\t$mail->Body = \n\t\t\t\t\n\t\t\t\t'<h1>Receipt</h1>' .\n\t\t\t\t\n\t\t\t\t'<p>Hey ' . $name . ',</p><br>' .\n\t\t\t\t'<p>You Were Successfully Charged $' . $amount . ' for your Order!</p>' .\n\t\t\t\n\n\t\t\t\t'<table>\n\t\t\t\t\t<tr>\n\t\t\t\t\t\t<th>Product Name</th>\n\t\t\t\t\t\t<th>Weight</th>\n\t\t\t\t\t\t<th>Price</th>\n\t\t\t\t\t\t<th>Qty</th>\n\t\t\t\t\t\t<th>Total</th>\n\t\t\t\t\t</tr>' ;\n\t\t\t\t\n\t\t\t\t//Display the cart to the splash page receipt.\n\t\t\t\tforeach($productsOrdered as $product) {\n\t\t\t\t\t$pricePerItem = floatval(ltrim($product['prod_price'], '$')) * $product['prod_qty'];\n\t\t\t\t\t$mail->Body .=\t\"<tr>\" .\n\t\t\t\t\t\"<td>\" . $product['prod_name'] . \"</td>\" .\n\t\t\t\t\t\"<td>\" . $product['prod_weight'] . \"</td>\" .\n\t\t\t\t\t\"<td>\" . $product['prod_price'] . \"</td>\" .\n\t\t\t\t\t\"<td>\" . $product['prod_qty'] . \"</td>\" .\n\t\t\t\t\t\"<td>$\" . number_format($pricePerItem, 2) . \"</td>\" .\n\t\t\t\t\t\"</tr>\";\n\t\t\t\t}\n\t\t\t\t$mail->Body .= \"<tr><td colspan='5'> </td></tr>\" .\n\t\t\t\t\"<tr><td colspan='5'> </td></tr>\" .\n\t\t\t\t\"<tr><td colspan='5'> </td></tr>\" .\n\t\t\t\t\"<tr><td colspan='5'> </td></tr>\" .\n\t\t\t\t\"<tr><td colspan='5' class='centered'>Sub-Total: $\" . $subTotal . \"</td></tr>\" .\n\t\t\t\t\"<tr><td colspan='5' class='centered'>GST: $\" . $gst . \"</td></tr>\" .\n\t\t\t\t\"<tr><td colspan='5' class='centered'>PST: $\" . $pst . \"</td></tr>\" .\n\t\t\t\t\"<tr><td colspan='5' class='centered'>Total: $\" . $amount . \"</td></tr>\" .\n\t\t\t\t\n\t\t\t\t\"</table>\" .\n\t\t\t\t\"<p>Receipt Number: \" . $receipt . \"</p>\" .\n \n\t\t\t'<h2>Thank You for supporting local farmers here in Victoria :)</h2>';\n\n\t\n\t\t//Attach an image file\n\t\t//$mail->addAttachment('images/phpmailer_mini.png');\n\t\t//send the message, check for errors\n\t\tif (!$mail->send()) {\n echo \"Oops, something went wrong with your email :( Your purchase was still processed. Feel free to contact us by phone or email.\";\n } else {\n\t\t\techo \"A confirmation email was sent to \" . $email . \"! We will contact you when your order is ready.\";\n\t\t}\n\t}", "title": "" }, { "docid": "3792b5adc2a7059b5bed421b53963468", "score": "0.5798987", "text": "public function send()\n {\n require_once \"Mail.php\";\n require_once \"Mail/mime.php\";\n \n $headers = array(\"From\" => $this->sender->getAddress(true),\n RecipientType::TO => $this->getRecipients(RecipientType::TO),\n \"Subject\" => $this->subject);\n \n $cc = $this->getRecipients(RecipientType::CC);\n if (isset($cc)) $headers[RecipientType::CC] = $cc;\n \n $bcc = $this->getRecipients(RecipientType::BCC);\n if (isset($bcc)) $headers[RecipientType::BCC] = $bcc;\n \n $parameters = array(\"host\" => ($this->smtpPort == EncryptionType::SSL ? \"ssl://\" : \"\") . $this->smtpHost);\n if ($this->smtpPort) $parameters[\"port\"] = $this->smtpPort;\n if ($this->smtpAuth) $parameters[\"auth\"] = $this->smtpAuth;\n if ($this->smtpUsername) $parameters[\"username\"] = $this->smtpUsername;\n if ($this->smtpPassword) $parameters[\"password\"] = $this->smtpPassword;\n \n // Build Multipart mail\n $mime = new Mail_mime(\"\\r\\n\");\n $body = $this->getBody();\n $mime->setTXTBody(strip_tags($body));\n $mime->setHTMLBody($body);\n $body = $mime->get();\n $headers = $mime->headers($headers);\n \n // Send via SMTP\n //$smtp =& Mail::factory(\"smtp\", $parameters);\n\n $mail = new Mail();\n $smtp = $mail->factory(\"smtp\", $parameters);\n\n $response = $smtp->send($this->getRecipients(RecipientType::TO, false), $headers, $body);\n \n if (PEAR::isError($response)) {\n throw new Exception($response->getMessage());\n } else {\n return true;\n }\n }", "title": "" }, { "docid": "d4a199cdf1b493df7020f2c2357e4852", "score": "0.5795127", "text": "function sendInviteEmail($user, $receiver, $group, $message, $hash)\n{\n $message = generateInviteMessage($user, $receiver, $group, $message, $hash);\n $headers = 'From: message' . \"\\r\\n\"; // Set from headers (perhaps change this in the future?)\n $subject = generateInviteSubject($user); // Give the email a subject\n\n\n $receiverEmail = $receiver->getEmail();\n // send the email\n mail($receiverEmail, $subject, $message, $headers);\n}", "title": "" }, { "docid": "72467b9d500e06332b4db55c630cb1f5", "score": "0.5792428", "text": "public function send_message()\n\t{\n\t\t$from = Input::get('sender_id');\n\t\t$to = Input::get('to_id');\n\t\t$subject = Input::get('subject');\n\t\t$message = Input::get('message');\n\t\t\n\t\tMails::create(array(\n\t\t\t'sender_id'=>$from,\n\t\t\t'receiver_id'=>$to,\n\t\t\t'subject'=>$subject,\n\t\t\t'text'=>$message\n\t\t));\n\t}", "title": "" }, { "docid": "95e72800608be6d8571d2754fe73ac0c", "score": "0.57888484", "text": "function send_mail_to_traveler($booking_id, $tour_name, $tour_from_date, $tour_to_date, $customer_id, $email_id, $m_first_name,$total_tour_expense, $total_payment)\n\n{\n\n global $app_email_id, $app_name, $app_contact_no, $admin_logo_url,$encrypt_decrypt,$secret_key,$currency_logo;\n global $mail_em_style, $mail_em_style1, $mail_font_family, $mail_strong_style, $mail_color;\n\n\n\n $from_date = date('d-m-Y', strtotime($tour_from_date));\n $to_date = date('d-m-Y', strtotime($tour_to_date));\n\n if($email_id==\"\"){\n $email_id=$app_email_id;\n $name = \"Admin\";\n }\n else \n $name = $m_first_name[0];\n\n $sq_booking = mysql_fetch_assoc(mysql_query(\"select * from package_tour_booking_master where booking_id='$booking_id'\"));\n $mobile_no = $sq_booking['mobile_no'];\n $tour_name = $sq_booking['tour_name'];\n $date = $sq_booking['booking_date'];\n $yr = explode(\"-\", $date);\n $year =$yr[0];\n\n $sq_customer = mysql_fetch_assoc(mysql_query(\"select * from customer_master where customer_id='$customer_id'\"));\n\n $username = $encrypt_decrypt->fnDecrypt($sq_customer['contact_no'], $secret_key);\n $password = $encrypt_decrypt->fnDecrypt($sq_customer['email_id'], $secret_key);\n $link = BASE_URL.'/view/customer/';\n\n $subject = 'Booking confirmation acknowledgement! ('.get_package_booking_id($booking_id,$year). ' )';\n\n $passengers_infant = mysql_fetch_assoc(mysql_query(\"select count(*) as cnt from package_travelers_details where booking_id = \".$booking_id.\" and adolescence = 'Infant'\"));\n $passengers_adult = mysql_fetch_assoc(mysql_query(\"select count(*) as cnt from package_travelers_details where booking_id = \".$booking_id.\" and adolescence = 'Adult'\"));\n $passengers_child = mysql_fetch_assoc(mysql_query(\"select count(*) as cnt from package_travelers_details where booking_id = \".$booking_id.\" and adolescence = 'Child'\"));\n\n $content .='\n <tr>\n <table width=\"85%\" cellspacing=\"0\" cellpadding=\"5\" style=\"color: #888888;border: 1px solid #888888;margin: 0px auto;margin-top:20px; min-width: 100%;\" role=\"presentation\">\n <tr><td style=\"text-align:left;border: 1px solid #888888;\">Tour Name</td> <td style=\"text-align:left;border: 1px solid #888888;\">'.$tour_name.'</td></tr>\n <tr><td style=\"text-align:left;border: 1px solid #888888;\">Tour Date</td> <td style=\"text-align:left;border: 1px solid #888888;\" >'. $from_date.'</td></tr>\n <tr><td style=\"text-align:left;border: 1px solid #888888;\">Total Guest</td> <td style=\"text-align:left;border: 1px solid #888888;\">'.$passengers_adult['cnt'].' Adult(s),'.$passengers_child['cnt'].' Children(s),'.$passengers_infant['cnt'].' Infant(s)</td></tr> \n <tr><td style=\"text-align:left;border: 1px solid #888888;\">Total Amount</td> <td style=\"text-align:left;border: 1px solid #888888;\">'.$currency_logo.' '.number_format($total_tour_expense,2).'</td></tr>\n <tr><td style=\"text-align:left;border: 1px solid #888888;\">Paid Amount</td> <td style=\"text-align:left;border: 1px solid #888888;\">'.$currency_logo.' '.number_format($total_payment,2).'</td></tr>\n <tr><td style=\"text-align:left;border: 1px solid #888888;\">Balance Amount</td> <td style=\"text-align:left;border: 1px solid #888888;\">'.$currency_logo.' '.number_format($total_tour_expense - $total_payment,2).'</td></tr>\n </table>\n</tr>\n ';\n $content .= mail_login_box($username, $password,$link);\n\n\nglobal $model,$backoffice_email_id;\n\n $model->app_email_send('14',$name,$email_id, $content, $subject);\nif($backoffice_email_id!=\"\")\n $model->app_email_send('14',\"Team\",$backoffice_email_id, $content, $subject);\n\n}", "title": "" }, { "docid": "d2bb28e233c42d408c9cb68b62d99775", "score": "0.5787322", "text": "private function sendEmail($user, $request)\n {\n $link = $request->root() . \"/api/v1/confirm/subscription/\" . $user->confirmation_id;\n Mail::raw('Thank you for subscribing, click this link to confirm ' . $link, function($msg) use ($user) {\n $msg->to([$user->email]); \n });\n }", "title": "" }, { "docid": "afd43370c083c675597d4e78f9de197e", "score": "0.57841337", "text": "public function sendEmail()\n {\n $body = '<h1>Новая заявка на запись</h1>\n <p>\n <a href=\"'. Yii::$app->request->hostInfo .'/admin/registration/view/'. $this->id .'\">Ссылка на запись</a>\n </p>\n <h2>Короткая информация</h2>\n <p> Имя: '.$this->name.'</p>\n <p> Телефон: '.$this->tel . '</p>';\n\n return Yii::$app->mailer->compose()\n ->setTo(Yii::$app->params['Params']['email'])\n ->setFrom(['info@smak05.ru' => 'SMAK'])\n ->setSubject('Заявка на запись от: '. $this->name)\n ->setHtmlBody($body)\n ->send();\n }", "title": "" }, { "docid": "0c3f3c0ce37fe1409930f3f359766808", "score": "0.5782718", "text": "function SendToRecipient($recipient=0, $queueid=0)\n\t{\n\t\t$this->SetupEmail();\n\n\t\t/**\n\t\t * These are for the send_api sendtorecipient method to use.\n\t\t */\n\t\t$this->newsletter = $this->newsletters[$this->_sending_newsletter];\n\t\t$this->statid = $this->statids[$this->_sending_newsletter];\n\n\t\t$this->jobdetails['Newsletter'] = $this->_sending_newsletter;\n\n\t\t$mail_result = parent::SendToRecipient($recipient, $queueid, $this->queuetype);\n\n\t\t/**\n\t\t * Once we've worked out whether the email was sent or not,\n\t\t * save the details so we can update stats later on with the right results.\n\t\t *\n\t\t * Right now, we only care about success/failure.\n\t\t */\n\t\tif ($mail_result['success'] > 0) {\n\t\t\t$this->jobdetails['sendinfo']['email_results'][$this->_sending_newsletter]['success']++;\n\t\t} else {\n\t\t\t$this->jobdetails['sendinfo']['email_results'][$this->_sending_newsletter]['fail']++;\n\t\t}\n\t\t$this->jobdetails['sendinfo']['sendsize_left']--;\n\n\t\t$this->UpdateJobDetails();\n\n\t\treturn $mail_result;\n\t}", "title": "" }, { "docid": "f1c5a8c6c7139204380403cacd4eed94", "score": "0.5779456", "text": "function send()\n {\n loadCoreFile('ascHtmlMimeMail.php');\n if (!$this->haveToSend)\n {\n return;\n }\n\n if (Configuration::getSupportMode(ASC_S_NOTIFICATIONS))\n {\n return;\n }\n\n // getting the recipients and languages\n $to = $this -> getMLSendTo();\n\n // adding third party emails to \"To\" array\n if (isset($this->thirdparty_emails) && is_array($this->thirdparty_emails) && !empty($this->thirdparty_emails))\n foreach ($this->thirdparty_emails as $i => $email)\n $to[] = $email;\n\n // saving the current languages\n $cur_lng = modApiFunc('MultiLang', 'getLanguage');\n $cur_res_lng = modApiFunc('MultiLang', 'getResourceLanguage');\n\n // processing the recipients\n foreach($to as $address)\n {\n // skipping invalid records (paranoidal check)\n if (!isset($address[0]) || !$address[0])\n continue;\n\n // setting the language for the current notification\n modApiFunc('MultiLang', 'setLanguage', @$address[1]);\n modApiFunc('MultiLang', 'setResourceLanguage', @$address[1]);\n\n $format = modApiFunc('Settings','getParamValue','EMAIL_NOTIFICATION_SETTINGS','EMAIL_NOTIFICATION_FORMAT');\n $this->prepareEmailTextAndSubject();\n\n // there were some problems with Unix <-> Windows linefeeds\n // so we make it all Windows style\n $this->EmailText = str_replace(\"\\n\", \"\\r\\n\", str_replace(\"\\r\\n\", \"\\n\", $this->EmailText));\n\n $mail = new ascHtmlMimeMail();\n\t if($format == \"HTML\"){\n\t\t$mail->setHtml($this->EmailText);\n\t }else{\n \t$mail->setText($this->EmailText);\n\t }\n $mail->setSubject($this->EmailSubject);\n $from = $this->getSendFrom();\n $mail->setFrom($from);\n// $mail->setCc($from);\n\n $this->addEmailToTimeline($address[0], $mail->send(array($address[0])), @$address[1]);\n }\n\n // restoting the languages\n modApiFunc('MultiLang', 'setLanguage', $cur_lng);\n modApiFunc('MultiLang', 'setResourceLanguage', $cur_res_lng);\n }", "title": "" } ]
b55262cccc84d1d8df4b4c3b34eb1943
Returns which default modules to use.
[ { "docid": "08ffd8c7534f8f40a65b7ac918656f11", "score": "0.0", "text": "public function getDefinition($template)\n {\n $image = ['mod-image', __('Image', 'simrishamn')];\n $slider = ['mod-slider', __('Slider', 'simrishamn')];\n $teaser = ['mod-colored-index', __('Colored Index', 'simrishamn')];\n\n $notices = [\n 'mod-inlay-index',\n __('Inlay Index', 'simrishamn'),\n strtoupper(__('Do not edit!', 'simrishamn')),\n SIMRISHAMN_SHARED_NOTICES_MODULE,\n ];\n\n $posts = [\n 'mod-posts',\n __('Posts', 'simrishamn'),\n strtoupper(__('Do not edit!', 'simrishamn')),\n SIMRISHAMN_SHARED_POSTS_MODULE\n ];\n\n switch ($template) {\n case 'page':\n return [\n 'content-area-top' => [$slider, $image],\n 'right-sidebar' => [$notices],\n ];\n case 'single':\n return [\n 'right-sidebar' => [$notices, $posts],\n ];\n case 'full-width.blade.php':\n return [\n 'content-area' => [$teaser, $teaser],\n ];\n }\n }", "title": "" } ]
[ { "docid": "dafa10098d602b45296a0a73ddd6917d", "score": "0.7151721", "text": "public function getDefaultModule()\n {\n reset($this->modules);\n\n return key($this->modules);\n }", "title": "" }, { "docid": "0df5c44cf9157e5d900b9af360220597", "score": "0.6700116", "text": "private function getModules(){\n return Config::get(\"modules.active\") ?: array_map('class_basename', $this->moduleFiles->directories(app_path().'/Modules/'));\n }", "title": "" }, { "docid": "a8f43d07997f2741ac1505852447c970", "score": "0.6659728", "text": "public static function getModuleNames ($includeDefault = false)\n {\n $front = Zend_Controller_Front::getInstance();\n $bootstrap = $front->getParam('bootstrap');\n $modules = $includeDefault ? array('default' => 'default') : array();\n foreach ($bootstrap->modules as $key => $mod) {\n $modules[$key] = $key;\n }\n return $modules;\n }", "title": "" }, { "docid": "421ee2414cf88163faee18c14568d86c", "score": "0.63971883", "text": "function loadModules() {\n\t\t\n\t\t$activeModules = array();\n\t\t//$activeModules[] = \"Modules\\GFStarterKit\\Bootstrap\";\n\t\t//$activeModules[] = \"Modules\\GFFileManager\\Bootstrap\";\n\t\t\n\t\treturn $activeModules;\n\t}", "title": "" }, { "docid": "5235411de7df8ed93b3cb79a82edeb86", "score": "0.6287048", "text": "public static function getSupportedModules()\n\t{\n\t\treturn Vtiger_Module_Model::getAll([0], ['SMSNotifier', 'OSSMailView', 'Dashboard', 'ModComments', 'Notification'], true);\n\t}", "title": "" }, { "docid": "eb9158834957206d99644aa8e553f472", "score": "0.61434054", "text": "function import_default_modules(){\n\n\t\t$modsFolder = dirname(__FILE__).\"/default_modules/without_panel\";\n\t\tif ($handle = opendir($modsFolder)) {\n\t\t\twhile (false !== ($file = readdir($handle))) {\n\t\t\t\tif (is_file($modsFolder.'/'.$file))\n\t\t\t\t\tRCCWP_CustomWriteModule::Import($modsFolder.'/'.$file); \n\t\t\t}\n\t\t}\n\n\t\t$modsFolder = dirname(__FILE__).\"/default_modules/with_panel\";\n\t\tif ($handle = opendir($modsFolder)) {\n\t\t\twhile (false !== ($file = readdir($handle))) {\n\t\t\t\tif (is_file($modsFolder.'/'.$file))\n\t\t\t\t\tRCCWP_CustomWriteModule::Import($modsFolder.'/'.$file, false, true);\n\t\t\t}\n\t\t}\n\n\t}", "title": "" }, { "docid": "ac24db5f7cc3ab205ab4a51361f319df", "score": "0.60942954", "text": "function KG_get_modules_list() {\n\n $modules = array(\n 'core',\n 'users',\n 'fields',\n 'mails',\n 'cocpit',\n 'resources-relations',\n 'subscriptions',\n 'resources-free',\n 'resources',\n 'messages',\n 'quizes',\n 'likes',\n 'templates',\n 'maintenance',\n 'stats',\n 'generators',\n 'orders',\n 'files',\n 'alerts',\n 'activities',\n 'invoices',\n 'users-groups',\n 'tasks',\n 'authenticate'\n );\n\n return $modules;\n }", "title": "" }, { "docid": "2a8e7a8ba5dc75e8fe386b09ab60ce61", "score": "0.6089977", "text": "public static function listAvailableModules() : array\n {\n return array_diff( scandir( MODULES ), ['..', '.'] );\t\n \n }", "title": "" }, { "docid": "1a650b3f6a8ad87c5a6737ec6e5e85bb", "score": "0.60701996", "text": "private static function getModules()\n {\n // scan for available modules\n $files = array_diff( scandir( MODULES ), ['..', '.'] );\t\n\n // set include paths\n foreach( $files as $file ){\n self::setPath( MODULES .'/'. $file, $file );\n } // end foreach\n \n \n }", "title": "" }, { "docid": "629ceb50c078cfdeb06a1092bc16f8f5", "score": "0.6050071", "text": "private function _setModuleDefaults()\n\t{\n\t\t//set variable\n\t\t$all_defaults = array();\n\t\t$overwrite_defaults = array();\n\t\t\n\t\t//load the site ini file\n\t if(is_file(DIR_SECURE_INI.'/site_module_config.ini'))\n\t {\n\t \t$a_site_module_config = parse_ini_file(DIR_SECURE_INI.'/site_module_config.ini',true); \n\t } elseif (is_file(DIR_APP_INI.'/site_module_config.ini')) {\n\t \t$a_site_module_config = parse_ini_file(DIR_APP_INI.'/site_module_config.ini',true); \n\t } else {\n\t \t$msg = 'The INI file site_module_config can not be found anywhere!';\n\t \tthrow new \\RuntimeException($msg); \n\t }\n\t \n\t //load the local defaults that overwrite the preset defaults\n \tif(is_file(DIR_SECURE_INI.'/site_module_local_defaults.ini'))\n\t {\n\t \t$overwrite_defaults = parse_ini_file(DIR_SECURE_INI.'/site_module_local_defaults.ini',true);\n\t }\n\t \n\t\t//key sort \n\t ksort($a_site_module_config);\n\t \n\t //load the system defaults for each module\n \tforeach ($a_site_module_config as $moduleName => $info)\n \t{\n\t\t\tif(is_file(DIR_MODULES.'/'.$moduleName.'/defaults.ini')) {\n\t\t\t\t\n\t\t \t$module_defaults = parse_ini_file(DIR_MODULES.'/'.$moduleName.'/defaults.ini',true);\n\t\t \t\n\t\t \tforeach($module_defaults as $default_name => $default_info)\n\t\t \t{\n\t\t\t \t\t\t \t\n\t\t\t \t$all_defaults[$moduleName][$default_name]['default'] = $default_info['default'];\n\t\t\t \t$all_defaults[$moduleName][$default_name]['help'] = $default_info['help'];\n\t\t\t \t\n\t\t\t \t//process options\n\t\t\t \tif($default_info['options'] == 'TEXT')\n\t\t\t \t{\n\t\t\t\t \t//input\n\t\t\t \t\t$options[0] = $default_info['options'];\n\t\t\t \t} else {\n\t\t\t\t \t//select list\n\t\t\t\t \t$options_array = explode('|', $default_info['options']);\n\t\t\t\t \t\n\t\t\t\t \tforeach($options_array as $option_str)\n\t\t\t\t \t{\n\t\t\t\t\t \t$option_a = explode(',', $option_str);\n\t\t\t\t\t \t$options[$option_a[0]] = $option_a[1];\n\t\t\t\t \t}\n\t\t\t \t}\t\n\t\t\t \t\n\t\t\t \t$all_defaults[$moduleName][$default_name]['options'] = $options;\n\t\t\t \t\n\t\t\t \tif(isset($overwrite_defaults[$default_name]))\n\t\t\t \t{\n\t\t\t\t \t$all_defaults[$moduleName][$default_name]['local_default'] = $overwrite_defaults[$default_name];\n\t\t\t \t} else {\n\t\t\t\t \t$all_defaults[$moduleName][$default_name]['local_default'] = $default_info['default'];\n\t\t\t \t}\n\t\t\t \t\n\t\t\t \t//unset options\n\t\t\t \tunset($options);\n\t\t \t} \n\t\t } \n\t }\n\t \n\t\t//add the infor for use in the view\n\t\t$this->view_variables_obj->addViewVariables('all_defaults',$all_defaults);\n\t\t$this->view_variables_obj->addViewVariables('overwrite_defaults',$overwrite_defaults);\n\t\t\n\t\treturn;\n\t}", "title": "" }, { "docid": "4feccc0dd137c86153037f52343b547a", "score": "0.6027863", "text": "public function buildModulesList()\n {\n $modulesList = array();\n \n if (is_string($this->modulePath) && is_dir($this->modulePath) && is_readable($this->modulePath)) {\n chdir($this->modulePath);\n $modulesList = glob('*');\n }\n \n array_push($modulesList, $this->defaultApplicationModuleName);\n asort($modulesList);\n $sortedModuleList = array_values($modulesList);\n \n return $sortedModuleList;\n }", "title": "" }, { "docid": "090efd1de6ed733f8144fe5e06c07807", "score": "0.60271424", "text": "public function getCoreModules()\n {\n $coreModules = $this->config->get('asgard.core.config.CoreModules');\n $coreModules = array_flip($coreModules);\n\n return $coreModules;\n }", "title": "" }, { "docid": "bdb61f4cc2b6164da1b12fdd378cf239", "score": "0.60197514", "text": "public function getActiveModules()\n\t{\n\t\treturn \\ModuleLoader::getActive();\n\t}", "title": "" }, { "docid": "e70ca09c4845a0423be816ca30e42efe", "score": "0.60140973", "text": "protected function getUserModules()\n {\n return $this->container->metaDataHelper->getAvailableModulesForUser($this->user);\n }", "title": "" }, { "docid": "e773db36e7b7533726372b5d595ce637", "score": "0.598824", "text": "public function getModules();", "title": "" }, { "docid": "e773db36e7b7533726372b5d595ce637", "score": "0.598824", "text": "public function getModules();", "title": "" }, { "docid": "1d220698b6d132ef5ad01e54c046a5cd", "score": "0.5963827", "text": "function urkund_supported_modules() {\n global $CFG;\n $supportedmodules = array('assign', 'forum', 'workshop', 'quiz');\n if (file_exists($CFG->dirroot.'/mod/hsuforum/version.php')) {\n $supportedmodules[] = 'hsuforum';\n }\n return $supportedmodules;\n}", "title": "" }, { "docid": "416a8e5dd60ad2a093a29649aeb50717", "score": "0.59533405", "text": "function get_modules()\n\t{\n\t\t$CI =& get_instance();\n\t\t$module_init = $this->_modules;\n\t\tforeach($this->_allowed as $module)\n\t\t{\n\t\t\t// check if there is a css module assets file and load it so it will be ready when the page is ajaxed in\n\t\t\tif (file_exists(MODULES_PATH.$module.'/config/'.$module.'_fuel_modules.php'))\n\t\t\t{\n\t\t\t\t$CI->config->module_load($module, $module.'_fuel_modules');\n\t\t\t\tinclude(MODULES_PATH.$module.'/config/'.$module.'_fuel_modules.php');\n\t\t\t\t$module_init = array_merge($module_init, $config['modules']);\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\t// now must loop through the array and overwrite any values... array_merge_recursive won't work'\n\t\t$overwrites = $this->module_overwrites();\n\t\tif (!empty($overwrites) AND is_array($overwrites))\n\t\t{\n\t\t\tforeach($overwrites as $module => $val)\n\t\t\t{\n\t\t\t\t$module_init[$module] = array_merge($module_init[$module], $val);\n\t\t\t}\n\t\t}\n\t\treturn $module_init;\n\t}", "title": "" }, { "docid": "6486340480ac6400585076ef6365aa98", "score": "0.5919786", "text": "function atkGetModules()\n {\n global $g_modules;\n return $g_modules;\n }", "title": "" }, { "docid": "6c1fead059b092b4c90413df73aca72f", "score": "0.5902368", "text": "public function provides()\r\n\t{\r\n\t\treturn array('Modules');\r\n\t}", "title": "" }, { "docid": "1a8268729e0bc09c24a324f3b9718003", "score": "0.58983123", "text": "public function modules() {\t\t\n\t\t$modules = Configure::read('Cloggy.modules');\n\t\tif(!empty($modules) && is_array($modules)) {\t\t\t\n\t\t\tforeach($modules as $module) {\n\t\t\t\tif (!array_key_exists($module,$this->__modules)) {\t\t\t\t\t\n\t\t\t\t\t$this->_configureModuleInfo($module);\n\t\t\t\t\t$this->__modules[$module]['name'] = $this->getModuleName();\n\t\t\t\t\t$this->__modules[$module]['desc'] = $this->getModuleDesc();\n\t\t\t\t\t$this->__modules[$module]['author'] = $this->getModuleAuthor();\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\t\t\t\n\t\t}\t\t\n\t}", "title": "" }, { "docid": "edc91056a73deb2bf8b67e0a93838293", "score": "0.58928406", "text": "public static function getModules() {\r\n\t\tTodoyuExtensions::loadAllAdmin();\r\n\r\n\t\tif( is_array( Todoyu::$CONFIG['EXT']['admin']['modules'] ) ) {\r\n\t\t\treturn TodoyuArray::sortByLabel(Todoyu::$CONFIG['EXT']['admin']['modules']);\r\n\t\t} else {\r\n\t\t\treturn array();\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "0b4247b2fa08318592bce3c695a5adc0", "score": "0.58823586", "text": "public static function modulesAvailable(){\n\tt_e('deprecated',__FUNCTION__);\n\treturn we_base_moduleInfo::getAllModules();\n\t}", "title": "" }, { "docid": "43ee5d4fdc4d5077517b9ac720f166c8", "score": "0.58779734", "text": "public static function default()\n {\n return [\n SwooleRunner::class => C::provideParameter([\n Server::class => C::alias(SwooleRunner::class, 'server'),\n RequestHandlerInterface::class => C::alias(SwooleRunner::class, 'handler'),\n ]),\n\n C::join(SwooleRunner::class, 'handler') => C::alias(BoltApp::class),\n C::join(SwooleRunner::class, 'server') => C::instance(Server::class, [\n C::alias(SwooleRunner::class, 'server', 'host'),\n C::alias(SwooleRunner::class, 'server', 'port'),\n C::alias(SwooleRunner::class, 'server', 'mode'),\n C::alias(SwooleRunner::class, 'server', 'type'),\n ]),\n C::join(SwooleRunner::class, 'server', 'host') => $_ENV['HOST'] ?? 'localhost',\n C::join(SwooleRunner::class, 'server', 'port') => $_ENV['PORT'] ?? '8080',\n C::join(SwooleRunner::class, 'server', 'mode') => SWOOLE_PROCESS,\n C::join(SwooleRunner::class, 'server', 'type') => SWOOLE_SOCK_TCP,\n ResponseFactoryInterface::class => C::instance(ResponseFactory::class),\n ];\n }", "title": "" }, { "docid": "8ce668831a2b64d10f19f200d621f53a", "score": "0.5852566", "text": "public function getModuleNames() \n {\n $moduleDefinitions = siteManager::getInstance()->getModuleDefinitions();\n $availableModules = siteManager::getInstance()->getAvailableModules();\n \n // get the names of all of the allowed modules\n $moduleNames = array('' => '&nbsp;');\n \n foreach ($availableModules as $module)\n {\n if (isset($moduleDefinitions[$module])) \n {\n $moduleNames[$module] = $moduleDefinitions[$module]['name'];\n }\n }\n \n // order nicely\n asort($moduleNames);\n \n return $moduleNames;\n }", "title": "" }, { "docid": "5394713a8a1711098a4da72bf0e367fd", "score": "0.5830407", "text": "protected function get_default_settings() {\r\n\t\treturn [\r\n\t\t];\r\n\t}", "title": "" }, { "docid": "11aa7bacb3b87218144d8235a7c2500b", "score": "0.58238995", "text": "function get_config() {\n\tglobal $hm_platform;\n\n\t$defaults = Altis\\get_config()['modules']['cloud'];\n\n\treturn array_merge( $defaults, $hm_platform ? $hm_platform : [] );\n}", "title": "" }, { "docid": "36606c65447f9b4eab39bad9246f323b", "score": "0.5822984", "text": "private function defaultlFileLoad(){\n\t\t\treturn [\n\t\t\t\t'app/core/Router.php',\n\t\t\t\t'app/routers.php'\n\t\t\t];\n\t\t}", "title": "" }, { "docid": "f5b0f82e983bc8a92735ff234bba7f66", "score": "0.58022875", "text": "static function getModulesList()\n {\n return XoopsLists::getDirListAsArray(XOOPS_ROOT_PATH . '/modules/');\n }", "title": "" }, { "docid": "95f94e784b612a7a792702acc0970f43", "score": "0.5791832", "text": "public function get_modules() {\n\t\treturn self::instance()->modules;\n\t}", "title": "" }, { "docid": "fab36c3d8eb133a0539d63e384651bdb", "score": "0.57834536", "text": "protected function getAllModules()\n {\n return $this->container->metaDataHelper->getAllEnabledModules();\n }", "title": "" }, { "docid": "501a9e9bcb080f9b087edb45bef05109", "score": "0.577808", "text": "public function loadModules(){\n if (self::$availableModules == null){\n $loadedModules = array();\n foreach (glob(\"modules/*.php\") as $filename) {\n\t if($filename == 'modules/index.php') {\n\t\tcontinue;\n\t }\n array_push($loadedModules, substr($filename, strlen('modules/') ,-strlen('.php')));\n require $filename;\n }\n self::$availableModules = $loadedModules;\n }\n }", "title": "" }, { "docid": "e7eef2a4bd8bfb1d0db527ffb3751b5b", "score": "0.57769704", "text": "private function loadDefaults()\n\t{\n\t\tif (file_exists(APPPATH.'config/autoloader.php'))\n\t\t{\n\t\t\trequire(APPPATH.'config/autoloader.php');\n\t\t\t\n\t\t\tif (isset($auto['libraries']) AND is_array($auto['libraries']) AND count($auto['libraries']) > 0)\n\t\t\t{\n\t\t\t\tforeach ($auto['libraries'] as $_auto)\n\t\t\t\t{\n\t\t\t\t\tif (isset($_auto[3]))\n\t\t\t\t\t{\n\t\t\t\t\t\tloadClass($_auto[0], $_auto[1], $_auto[2], $_auto[3]);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tloadClass($_auto[0], $_auto[1], $_auto[2]);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "48aa56a6e7b319d5178e5d28f42773ae", "score": "0.57701504", "text": "public static function modulesInstalled(){\nt_e('deprecated',__FUNCTION__);\n\t\t// not implemented yet\n\t\treturn array();\n\t}", "title": "" }, { "docid": "067127b6f872dacc6daecf317b104f74", "score": "0.5765195", "text": "protected function getAllModules() {\n\t\t$modules = array();\n\t\t\n\t\tif(class_exists('SS_ClassLoader')) {\n\t\t\t// SilverStripe 3.x\n\t\t\t$modules = SS_ClassLoader::instance()->getManifest()->getModules();\n\t\t} else {\n\t\t\t// SilverStripe 2.x\n\t\t\tglobal $_CLASS_MANIFEST;\n\t\t\t$paths = $_CLASS_MANIFEST;\n\t\t\tforeach ($paths as $path) {\n\t\t\t\tif (preg_match('#'.preg_quote(BASE_PATH, '#').'/([^/]+)/#', $path, $matches)) {\n\t\t\t\t\t$modules[$matches[1]] = BASE_PATH . DIRECTORY_SEPARATOR . $matches[1];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn $modules;\n\t}", "title": "" }, { "docid": "981d51003bf0b5be9ce774f4d97d443c", "score": "0.57640004", "text": "function apache_get_modules()\n {\n }", "title": "" }, { "docid": "82559f2494c4efdf2c7b2b40936c2afd", "score": "0.57604873", "text": "function loadable_modules() {\n\t\tif (empty($_ENV['lmodules'])) {\n\t\t\t$_ENV['lmodules'] = array();\n\t\t\tif ($dir = opendir(_MODULES_)) {\n\t\t\t\twhile (($item = readdir($dir)) !== FALSE) {\n\t\t\t\t\tif (is_dir(_MODULES_.'/'.$item) and $item != '.' and $item != '..') {\n\t\t\t\t\t\tarray_push($_ENV['lmodules'],$item);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tclosedir($dir);\n\t\t\t} \n\t\t}\n\t}", "title": "" }, { "docid": "7ded8dfdf8cd4fea122107d47d26960f", "score": "0.5751009", "text": "public function init()\n {\n // $options = $this->getOptions();\n // $defaultModule = isset($options['defaultModule'])?$options['defaultModule']:'player';\n /*\n * Done\n * TODO:: Make a hashmap to decide which module to be selected\n * depending on the URL.\n * E.g: affiliate.sitename.com should point to /affiliate module\n * The default module finding will be done anyways i.e., sitename.com/affiliate\n * will set default module in Zend_Registry as player. But at the same time\n * $request (refer frontendselectr) will return currentModule as 'affiliate'\n *\n * So affiliate.sitename.com, someaffiliates.com, sitename.com/affiliate\n * will all point to affiliate module.\n */\n // $this->_currentModule = $defaultModule;\n \t\t$this->_currentModule = Zend_Registry::getInstance()->get('defaultModule');\n $frontController = Zend_Controller_Front::getInstance();\n $frontController->setDefaultModule($this->_currentModule);\n\n $registry = Zend_Registry::getInstance();\n $registry->set('defaultModule', $this->_currentModule);\n //print_r($registry->get('doctrine_config'));\n\n return $this->_currentModule;\n }", "title": "" }, { "docid": "50a32fb54359edf0351c6aa6f29f3253", "score": "0.57327247", "text": "protected function modules()\n {\n if ($this->modules === null) {\n $this->loadModules();\n }\n\n return $this->modules;\n }", "title": "" }, { "docid": "505bace8ee56c7f4a33d479aa5b2cc60", "score": "0.5728827", "text": "public function getDefaultSettings() {\n return array();\n }", "title": "" }, { "docid": "cd38a96ec944058af3d358a673ab2683", "score": "0.5697822", "text": "function tradlang_getmodules_base() {\n\t$ret = array();\n\n\t/**\n\t * Sélection de tous les modules de langue\n\t */\n\t$res = sql_allfetsel('module, id_tradlang_module', 'spip_tradlang_modules');\n\tif (is_array($res)) {\n\t\tforeach ($res as $row) {\n\t\t\t$module = $row['module'];\n\t\t\t$ret[$module] = $row;\n\n\t\t\t/**\n\t\t\t * Récupération des différentes langues et calcul du nom des\n\t\t\t * fichiers de langue\n\t\t\t */\n\t\t\t$res2 = sql_allfetsel('DISTINCT lang', 'spip_tradlangs', 'id_tradlang_module=' . intval($row['id_tradlang_module']));\n\t\t\tforeach ($res2 as $row2) {\n\t\t\t\t$lg = $row2['lang'];\n\t\t\t\t$ret[$module]['langue_' . $lg] = $row['lang_prefix'].'_'.$lg.'.php';\n\t\t\t}\n\t\t}\n\t}\n\treturn $ret;\n}", "title": "" }, { "docid": "8aca3e0e999d1919dc7ab7b990b51905", "score": "0.56879634", "text": "public static function getDefaultNamespaces()\n {\n return self::$_defaultNamespaces;\n }", "title": "" }, { "docid": "44a0e66501a0ab149f021502bfc1803d", "score": "0.56862414", "text": "private function geatherModules() {\n /* getting global modules for all site */\n foreach ($this->routes_config->global as $module) {\n $this->fetchModules($module);\n }\n /* excludes modules for current subdomain */\n foreach ($this->subdomain->exclude as $module) {\n if ($module->attr('name') == '*') {\n $this->modules = array();\n continue;\n }\n $this->fetchModules($module, false);\n }\n /* getting global modules for current subdomain */\n foreach ($this->subdomain->global as $module) {\n $this->fetchModules($module);\n }\n /* excludes module for current route */\n foreach ($this->croute->exclude as $module) {\n if ($module->attr('name') == '*') {\n $this->modules = array();\n continue;\n }\n $this->fetchModules($module, false);\n }\n /* getting modules for current route */\n foreach ($this->croute->include as $module) {\n $this->fetchModules($module);\n }\n /* getting parameters for current route */\n if ($this->croute->params->param) {\n foreach ($this->croute->params->param as $param) {\n $this->route_params[$param->attr('name')] = $param->val();\n }\n }\n }", "title": "" }, { "docid": "eb0ff1ae567a7c8938fa4dee19b6476d", "score": "0.568328", "text": "public static function defaultServicesToWarm(): array\n {\n return [\n 'auth',\n 'cache',\n 'cache.store',\n 'config',\n 'cookie',\n 'db',\n 'db.factory',\n 'db.transactions',\n 'encrypter',\n 'files',\n 'hash',\n 'log',\n 'router',\n 'routes',\n 'session',\n 'session.store',\n 'translator',\n 'url',\n 'view',\n ];\n }", "title": "" }, { "docid": "ed7effad1b144116e2c406592ab7989d", "score": "0.56823", "text": "public function getDriverDefaults()\n\t{\n\t\treturn array(\n\t\t\t'port' => 8124,\n\t\t\t'driverOptions' => array(\n\t\t\t\t'node_bin' => 'node',\n\t\t\t\t'server_path' => null,\n\t\t\t\t'threshold' => 2000000,\n\t\t\t\t'node_modules_path' => '',\n\t\t\t),\n\t\t);\n\t}", "title": "" }, { "docid": "43ad0a2e3c543f0bbe298d2cf69f0436", "score": "0.56807524", "text": "public static function getDefaultConfiguration() : array\n {\n return static::$defaultConfiguration;\n \n }", "title": "" }, { "docid": "8d65edda37b737a88f104267e4eb2258", "score": "0.56733793", "text": "function sp_modules($reset = false) {\n static $modules = null;\n if ($modules === null || $reset) {\n if (!$reset && $modules = sp_appcache_fetch('sp_modules')) {\n return $modules;\n }\n $modules = array ();\n foreach (glob(SP_BASE . \"/modules/*\") as $dir) {\n $module = basename($dir);\n $info = array ('name' => $module, 'dir' => $dir, 'loader' => null);\n if (file_exists($loaderPath = \"{$dir}/module.php\")) {\n $info['loader'] = $loaderPath;\n }\n if (file_exists($viewHelperPath = \"{$dir}/view/helpers.php\")) {\n $info['view_helpers'] = $viewHelperPath;\n }\n $modules[$module] = $info;\n }\n sp_appcache_store('sp_modules', $modules);\n }\n return $modules;\n}", "title": "" }, { "docid": "05c8bbd8e5b9dec5523148712a6f8fc1", "score": "0.5668136", "text": "protected function getDefault()\n {\n return array();\n }", "title": "" }, { "docid": "72d1da914507eb1be68b0ee666957dd0", "score": "0.5664656", "text": "protected function loadDefaults()\n\t{\n\t\treturn array();\n\t}", "title": "" }, { "docid": "e30b8723c1fb894a5f710b6ae3146242", "score": "0.5663333", "text": "public static function getDefaults(): array\r\n {\r\n return \\array_merge(\r\n self::CONFIG_APP,\r\n self::CONFIG_HTTP_ROWSER,\r\n self::CONFIG_HTTP_SERVER_BLACKLIST\r\n );\r\n }", "title": "" }, { "docid": "444dc8649af1e18a4d6697b113dbc6b0", "score": "0.5662092", "text": "public static function get_modules_localize_settings() {\n $return = array();\n\n foreach (self::$modules as $module) {\n $default = $module->get_default_settings();\n $return[$module->slug]['name'] = $module->name;\n if($module->favorite){\n $return[ $module->slug ]['favorite'] = 1;\n }\n if ($default) {\n $return[$module->slug]['defaults'] = $default;\n }\n $type = $module->get_visual_type();\n if ($type) {\n $return[$module->slug]['type'] = $type;\n }\n }\n uasort($return, array(__CLASS__, 'sortBy'));\n return $return;\n }", "title": "" }, { "docid": "9f87e9e37b827d993fc943bb963b32c3", "score": "0.56607103", "text": "function wphb_get_modules() {\n\treturn wp_hummingbird()->core->modules;\n}", "title": "" }, { "docid": "5ee0123afe10aaa1d6119e3541c62c1c", "score": "0.5637904", "text": "public function getDefaultConfig() {\n return array();\n }", "title": "" }, { "docid": "dce5db6f8ddbb5dde7bfa8625a86ce0b", "score": "0.5636288", "text": "public function module_name(){\n\t\treturn $modules_name = array(\n\t\t\t\t'dashboard' => '0',\n\t\t\t\t'addcustomer' => '0',\n\t\t\t\t'add_zone' => '0',\n\t\t\t\t'addpaymentcustomer' => '0',\n\t\t\t\t'amountrate' => '0',\n\t\t\t\t'feesplaning' => '0',\n\t\t\t\t'paymentmonthlycustomer' => '0',\n\t\t\t\t'metersearch' => '0',\n\t\t\t\t'monthlysearch' => '0',\n\t\t\t\t'generatemetercustomer_search' => '0',\n\t\t\t\t'income_reportsearch' => '0',\n\t\t\t\t'paidsearch' => '0',\n\t\t\t\t'unpaidsearch' => '0',\n\t\t\t\t'addemployee' => '0',\n\t\t\t\t'payrols' => '0',\n\t\t\t\t'payrolssearch' => '0',\n\t\t\t\t'addexpenses' => '0',\n\t\t\t\t'bsearch' => '0',\n\t\t\t\t'addassets' => '0',\n\t\t\t\t'technicalproblems' => '0',\n\t\t\t\t'technicalsearch' => '0',\n\t\t\t\t'web_settings' => '0',\n\t\t\t\t'admin' => '0',\n\t\t\t\t\n\t\t\t\t);\n\t}", "title": "" }, { "docid": "a757f7a64024a872df0ab61b75c2848c", "score": "0.56357235", "text": "public function loadModules() {\r\n // Database Engine\r\n require_once('config/Database.php');\r\n // Analytics Engine\r\n require_once('config/Analytics.php');\r\n }", "title": "" }, { "docid": "ab012f9970f911b2f1a11c121144716a", "score": "0.56297463", "text": "public function getAvailableDefaults()\n {\n return $this->available_defaults;\n }", "title": "" }, { "docid": "13443884e539feaa963721e71471cdc6", "score": "0.56270283", "text": "function module_list_all () {\n $ml = new moduleloader();\n $modules = $ml->getAllModules();\n print_r($modules);\n}", "title": "" }, { "docid": "208a0ccc1e002e3f6bcdca14d9413280", "score": "0.56264555", "text": "public static function getKnownLegacyModules() {\n $modules = [];\n \n $modules['srp'] = array(\n 'group' => MenuBuilder::GROUP_NETWORK,\n 'mod' => '80srp',\n 'name' => 'Tfk Schulrouter Plus',\n 'uri' => 'srp/index.php',\n 'icon' => 'tfk/srp',\n 'privileges' => array('srp_link')\n );\n \n return $modules;\n }", "title": "" }, { "docid": "df93530331060e5bd473e0a7f11d378b", "score": "0.56131434", "text": "public static function getDefaults($moduleId)\n\t{\n\t\tstatic $defaultsCache = array();\n\t\tif (isset($defaultsCache[$moduleId]))\n\t\t\treturn $defaultsCache[$moduleId];\n\n\t\tif (preg_match(\"#[^a-zA-Z0-9._]#\", $moduleId))\n\t\t\tthrow new Main\\ArgumentOutOfRangeException(\"moduleId\");\n\n\t\t$path = Main\\Loader::getLocal(\"modules/\".$moduleId.\"/default_option.php\");\n\t\tif ($path === false)\n\t\t\treturn $defaultsCache[$moduleId] = array();\n\n\t\tinclude($path);\n\n\t\t$varName = str_replace(\".\", \"_\", $moduleId).\"_default_option\";\n\t\tif (isset(${$varName}) && is_array(${$varName}))\n\t\t\treturn $defaultsCache[$moduleId] = ${$varName};\n\n\t\treturn $defaultsCache[$moduleId] = array();\n\t}", "title": "" }, { "docid": "ef70e4654a42f31ae2773b07f6965755", "score": "0.5607699", "text": "abstract public function get_default_settings();", "title": "" }, { "docid": "70262ac652bf70d425b08ac0b28b8dc7", "score": "0.5601771", "text": "public static function get_default_requirements() {\n\t\treturn Config::get_config( 'requirements' );\n\t}", "title": "" }, { "docid": "757c29168554f6e7e2b47bab80f02cb2", "score": "0.55999887", "text": "public static function get_modules_localize_settings() {\n\t\t$return = array();\n\n\t\tforeach (self::$modules as $module) {\n\t\t\t$default = $module->get_live_default();\n\t\t\t$icon=$module->get_icon();\n\t\t\t$return[$module->slug]['name'] = $module->name;\n\t\t\t$return[$module->slug]['category'] = $module->category;\n\t\t\tif($icon!==false){\n\t\t\t\tif($icon===''){\n\t\t\t\t\t$icon=$module->slug;\n\t\t\t\t}\n\t\t\t\t$return[$module->slug]['icon']=$icon;\n\t\t\t\tthemify_get_icon($icon,'ti');\n\t\t\t}\n\t\t\tif ($module->favorite) {\n\t\t\t$return[$module->slug]['favorite'] = 1;\n\t\t\t}\n\t\t\tif ($default) {\n\t\t\t$return[$module->slug]['defaults'] = $default;\n\t\t\t}\n\t\t\t$type = $module->get_visual_type();\n\t\t\tif ($type) {\n\t\t\t$return[$module->slug]['type'] = $type;\n\t\t\t}\n\t\t}\n\t\tuasort($return, array(__CLASS__, 'sortBy'));\n\t\treturn $return;\n }", "title": "" }, { "docid": "ad84aabdb09e2e73650d993f3ff56a31", "score": "0.5599897", "text": "public function setDefaultModule($moduleName) {}", "title": "" }, { "docid": "c72dc85fd0d9e93601fe7e45bbb884d5", "score": "0.5589262", "text": "function module_config($key = null, $default = null)\n {\n return config('module.'.$key, $default);\n }", "title": "" }, { "docid": "fff0153b76c82d2022a962ad2e60c5a4", "score": "0.55683905", "text": "public function default_config() : array {\n\t\treturn [];\n\t}", "title": "" }, { "docid": "e0c1271d343bad7a32ad4dafbe8eee39", "score": "0.55651397", "text": "protected function getAllModules()\n {\n return $this->extensionManager->discoverModules()\n ->showInstalled()\n ->showUninstalled()\n ->showNoCore()\n ->showCore()\n ->getList(true);\n }", "title": "" }, { "docid": "2893d25182f8b5ce727533a78fcae1dd", "score": "0.5561802", "text": "public static function get_modules($module_name = null){\n if(is_null($module_name))\n return self::$modules_paths;\n \n if(!isset(self::$modules_paths[$module_name]))\n throw new Exception(\"Module with name {$module_name} is not found\");\n \n return self::$modules_paths[$module_name];\n }", "title": "" }, { "docid": "6bca888b9ba8d2761e1c6924c6bda20d", "score": "0.5560325", "text": "function defaultPackage()\n {\n\t\treturn $this->_defaultPackage;\n\t}", "title": "" }, { "docid": "df07e90d852c0cd5f3b9538476054e4d", "score": "0.55589473", "text": "protected function defaults() {\n\t\treturn array(\n\t\t\t'version' => '5.41.0',\n\t\t\t'settings' => array(),\n\t\t);\n\t}", "title": "" }, { "docid": "cc4956b6677a656f37c4be854cf7742d", "score": "0.5557599", "text": "public static function get_modules($select = 'all') {\n $_modules = array();\n $directories = self::get_directory_path('modules');\n\n foreach ($directories as $dir) {\n if (file_exists($dir)) {\n $d = dir($dir);\n while (( false !== ( $entry = $d->read() ))) {\n if ($entry !== '.' && $entry !== '..' && $entry !== '.svn') {\n $path = $d->path . $entry;\n $module_name = basename($path);\n $_modules[$module_name] = $path;\n }\n }\n }\n }\n foreach ($_modules as $value) {\n if (is_dir($value)) {\n continue; /* clean-up, make sure no directories is included in the list */\n }\n $path_info = pathinfo($value);\n if (strpos($path_info['filename'], 'module-') !== 0) {\n continue; /* convention: module's file name must begin with module-* */\n }\n\n $id = str_replace('module-', '', $path_info['filename']);\n $name = isset(self::$modules[$id])?self::$modules[$id]->name:current(get_file_data($value, array('Module Name')));\n $modules[$id] = array(\n 'name' => $name,\n 'id' => $id,\n 'dirname' => $path_info['dirname'],\n 'basename' => $path_info['basename'],\n );\n }\n\n if (!empty($modules)) {\n \n if ('active' === $select) {\n if(self::is_themify_theme()){\n $data = themify_get_data();\n $pre= 'setting-page_builder_exc_';\n }\n else{\n $pre= 'builder_exclude_module_';\n $data = self::get_builder_settings();\n }\n foreach ($modules as $key => $m) {\n $exclude = $pre.$m['id'];\n if (!empty($data[$exclude])) {\n unset($modules[$key]);\n }\n }\n } elseif ('registered' === $select) {\n foreach ($modules as $key => $m) {\n /* check if module is registered */\n if (!self::check_module_active($key)) {\n unset($modules[$key]);\n }\n }\n }\n } \n return $modules;\n }", "title": "" }, { "docid": "49b6f0fa5310077f2933c535ff1078ec", "score": "0.55557096", "text": "public function modules()\n\t{\n\t\t$modules = module_list();\n\t\t$configs = array();\n\n\t\tforeach ($modules as $module)\n\t\t{\n\t\t\t$configs[$module] = module_config($module);\n\n\t\t\tif (!isset($configs[$module]['name']))\n\t\t\t{\n\t\t\t\t$configs[$module]['name'] = ucwords($module);\n\t\t\t}\n\t\t}\n\n\t\tksort($configs);\n\t\tTemplate::set('modules', $configs);\n\n\t\tTemplate::render();\n\n\t}", "title": "" }, { "docid": "a5a3bfa3ae54fd2075e6a343045e71d5", "score": "0.5531956", "text": "private static function getAvailableModules($controller) {\r\n\t\t\t$sites\t\t\t\t\t= explode(' ', SITE_HIERARCHY);\r\n\t\t\t$availableModules\t\t= array();\r\n\t\t\t$usedModules\t\t\t= array();\r\n\t\t\t$modulesInController\t= self::getModulesInController($controller);\r\n\r\n\t\t\tforeach ($sites as $site) {\r\n\t\t\t\t$modulesDir = DOCROOT . $site . '/Modules/';\r\n\r\n\t\t\t\tif (is_dir($modulesDir)) {\r\n\t\t\t\t\t$dh = opendir($modulesDir);\r\n\r\n\t\t\t\t\twhile ($f = readdir($dh)) {\r\n\t\t\t\t\t\tif (!in_array($f, self::$notModules) and is_dir($modulesDir . $f)) {\r\n\t\t\t\t\t\t\tif (array_key_exists($f, $modulesInController)) {\r\n\t\t\t\t\t\t\t\t$availableModules[$f]['name']\t\t= $f;\r\n\t\t\t\t\t\t\t\t$availableModules[$f]['in_use']\t\t= true;\r\n\t\t\t\t\t\t\t\t$availableModules[$f]['html_id']\t= strtolower(ccFix($f));\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\t\t$usedModules[$f]['name']\t\t\t= $f;\r\n\t\t\t\t\t\t\t\t$usedModules[$f]['in_use']\t\t\t= false;\r\n\t\t\t\t\t\t\t\t$usedModules[$f]['html_id']\t\t\t= strtolower(ccFix($f));\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tsort($availableModules);\r\n\t\t#\tsort($usedModules);\r\n\r\n\t\t\t$modules = array_merge($usedModules, $availableModules);\r\n\r\n\t\t\treturn array('available_modules' => $modules, 'modules_in_controller' => $modulesInController);\r\n\t\t}", "title": "" }, { "docid": "868123b61c0d4d7fcaa18c27067ba5f5", "score": "0.55275553", "text": "public function getDefaultGroupSettings()\r\n {\r\n $result = $this->getGroupSettings(0); // 0 - this is default group and general group\r\n return $result;\r\n }", "title": "" }, { "docid": "41aacd5ee9f4f3e1f07cb2bd525879bd", "score": "0.5524134", "text": "protected function _getDefaults() {\n return $this->_getFields('Default');\n }", "title": "" }, { "docid": "863299f4ffee4f4ccbc2ba1fb9765a10", "score": "0.55200887", "text": "function blocks_get_default() {\n global $CFG;\n\n $this->init_full();\n\n // It's a normal blog page\n if (!empty($CFG->{'defaultblocks_'. $this->get_type()})) {\n $blocknames = $CFG->{'defaultblocks_'. $this->get_type()};\n } else {\n /// Failsafe - in case nothing was defined.\n $blocknames = 'admin,calendar_month,online_users,blog_menu';\n }\n\n return $blocknames;\n }", "title": "" }, { "docid": "eb54794c924b7175db9cd270f02a279d", "score": "0.5517663", "text": "protected function getSiteModulesConfig()\n {\n $modulesConfig = implode(DIRECTORY_SEPARATOR, [$this->sitePath, 'config', 'modules'.EXT]);\n\n if (file_exists($modulesConfig)) {\n /** @noinspection PhpIncludeInspection */\n return include $modulesConfig;\n }\n\n return null;\n }", "title": "" }, { "docid": "ff9cdee50a8347bbfd4d667ded979d4a", "score": "0.5516879", "text": "function get_default_settings() {\n\n\t\t\t$default_settings = array( \n\t\t\t\t'icons_order' => array( 'facebook', 'twitter', 'google-plus', 'instagram', 'linkedin' ),\n\t\t\t\t'icons' => array( 'facebook' => array( 'status' => '0', 'url' => '' ),\n\t\t\t\t\t\t\t\t 'twitter' => array( 'status' => '0', 'url' => '' ),\n\t\t\t\t\t\t\t\t 'google-plus' => array( 'status' => '0', 'url' => '' ),\n\t\t\t\t\t\t\t\t 'instagram' => array( 'status' => '0', 'url' => '' ),\n\t\t\t\t\t\t\t\t 'linkedin' => array( 'status' => '0', 'url' => '' ),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\treturn $default_settings;\n\n\t\t}", "title": "" }, { "docid": "2d762d1cf08457ada991d33aa749f06f", "score": "0.5513481", "text": "function system_list($type) {\n $lists = &drupal_static(__FUNCTION__);\n\n // For bootstrap modules, attempt to fetch the list from cache if possible.\n // if not fetch only the required information to fire bootstrap hooks\n // in case we are going to serve the page from cache.\n if ($type == 'bootstrap') {\n if (isset($lists['bootstrap'])) {\n return $lists['bootstrap'];\n }\n if ($cached = cache_get('bootstrap_modules', 'cache_bootstrap')) {\n $bootstrap_list = $cached->data;\n }\n else {\n $bootstrap_list = db_query(\"SELECT name, filename FROM {system} WHERE status = 1 AND bootstrap = 1 AND type = 'module' ORDER BY weight ASC, name ASC\")->fetchAllAssoc('name');\n cache_set('bootstrap_modules', $bootstrap_list, 'cache_bootstrap');\n }\n // To avoid a separate database lookup for the filepath, prime the\n // drupal_get_filename() static cache for bootstrap modules only.\n // The rest is stored separately to keep the bootstrap module cache small.\n foreach ($bootstrap_list as $module) {\n drupal_get_filename('module', $module->name, $module->filename);\n }\n // We only return the module names here since module_list() doesn't need\n // the filename itself.\n $lists['bootstrap'] = array_keys($bootstrap_list);\n }\n // Otherwise build the list for enabled modules and themes.\n elseif (!isset($lists['module_enabled'])) {\n if ($cached = cache_get('system_list', 'cache_bootstrap')) {\n $lists = $cached->data;\n }\n else {\n $lists = array(\n 'module_enabled' => array(),\n 'theme' => array(),\n 'filepaths' => array(),\n );\n // The module name (rather than the filename) is used as the fallback\n // weighting in order to guarantee consistent behavior across different\n // Drupal installations, which might have modules installed in different\n // locations in the file system. The ordering here must also be\n // consistent with the one used in module_implements().\n $result = db_query(\"SELECT * FROM {system} WHERE type = 'theme' OR (type = 'module' AND status = 1) ORDER BY weight ASC, name ASC\");\n foreach ($result as $record) {\n $record->info = unserialize($record->info);\n // Build a list of all enabled modules.\n if ($record->type == 'module') {\n $lists['module_enabled'][$record->name] = $record;\n }\n // Build a list of themes.\n if ($record->type == 'theme') {\n $lists['theme'][$record->name] = $record;\n }\n // Build a list of filenames so drupal_get_filename can use it.\n if ($record->status) {\n $lists['filepaths'][] = array('type' => $record->type, 'name' => $record->name, 'filepath' => $record->filename);\n }\n }\n foreach ($lists['theme'] as $key => $theme) {\n if (!empty($theme->info['base theme'])) {\n // Make a list of the theme's base themes.\n require_once DRUPAL_ROOT . '/includes/theme.inc';\n $lists['theme'][$key]->base_themes = drupal_find_base_themes($lists['theme'], $key);\n // Don't proceed if there was a problem with the root base theme.\n if (!current($lists['theme'][$key]->base_themes)) {\n continue;\n }\n // Determine the root base theme.\n $base_key = key($lists['theme'][$key]->base_themes);\n // Add to the list of sub-themes for each of the theme's base themes.\n foreach (array_keys($lists['theme'][$key]->base_themes) as $base_theme) {\n $lists['theme'][$base_theme]->sub_themes[$key] = $lists['theme'][$key]->info['name'];\n }\n // Add the base theme's theme engine info.\n $lists['theme'][$key]->info['engine'] = isset($lists['theme'][$base_key]->info['engine']) ? $lists['theme'][$base_key]->info['engine'] : 'theme';\n }\n else {\n // A plain theme is its own engine.\n $base_key = $key;\n if (!isset($lists['theme'][$key]->info['engine'])) {\n $lists['theme'][$key]->info['engine'] = 'theme';\n }\n }\n // Set the theme engine prefix.\n $lists['theme'][$key]->prefix = ($lists['theme'][$key]->info['engine'] == 'theme') ? $base_key : $lists['theme'][$key]->info['engine'];\n }\n cache_set('system_list', $lists, 'cache_bootstrap');\n }\n // To avoid a separate database lookup for the filepath, prime the\n // drupal_get_filename() static cache with all enabled modules and themes.\n foreach ($lists['filepaths'] as $item) {\n drupal_get_filename($item['type'], $item['name'], $item['filepath']);\n }\n }\n\n return $lists[$type];\n}", "title": "" }, { "docid": "02749941e83852af9618eb969df2ff7f", "score": "0.55001324", "text": "public static function getModules()\n\t{\n\t\t$result = array();\n\t\t$dir = dirname( __FILE__ ).'/backend';\n\t\tforeach ( File::readDir( $dir ) as $file )\n\t\t{\n\t\t\t$file = str_replace( '/', '_', str_replace( $dir.'/', '', $file ) );\n\t\t\t$file = substr( $file, 0, strlen( $file ) - 4 );\n\t\t\tif ( $file == 'standard' )\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t$class = 'Controller_Backend_'.$file;\n\t\t\t$controller = new $class();\n\t\t\t$result[ get_class( $controller ) ] = $controller->getTitle();\n\t\t}\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "fe4470c134ff58a122202220700f8004", "score": "0.54975325", "text": "protected function getPluginDefaultBinaryNames(): array\n {\n return [];\n }", "title": "" }, { "docid": "ef718e2109f5b5826826015c1b1db2f3", "score": "0.54929334", "text": "function findmodules()\n\t\t{\n\t\t\t$new_modules = array();\n\t\t\t$apps = array_keys($GLOBALS['egw_info']['apps']);\n\t\t\tif (file_exists($this->instance_modules))\n\t\t\t{\n\t\t\t\t$apps[] = '*instance*';\n\t\t\t}\n\t\t\tforeach($apps as $app)\n\t\t\t{\n\t\t\t\t$moddir = EGW_SERVER_ROOT . '/' . $app;\n\t\t\t\tswitch($app)\n\t\t\t\t{\n\t\t\t\t\tcase 'sitemgr':\n\t\t\t\t\t\t$moddir .= '/modules';\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase '*instance*':\n\t\t\t\t\t\t$moddir = $this->instance_modules;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\t$moddir .= '/sitemgr';\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\tif (is_dir($moddir))\n\t\t\t\t{\n\t\t\t\t\t$d = dir($moddir);\n\t\t\t\t\twhile ($file = $d->read())\n\t\t\t\t\t{\n\t\t\t\t\t\tif (preg_match (\"/class\\.module_(.*)\\.inc\\.php$/\", $file, $module))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$modulename = $module[1];\n\n\t\t\t\t\t\t\t$moduleobject =& $this->createmodule($modulename);\n\t\t\t\t\t\t\tif ($moduleobject)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$description = '';\n\t\t\t\t\t\t\t\t// we grab the description direct from the module source, as we need the untranslated one\n\t\t\t\t\t\t\t\tif (preg_match('|\\$this->description = lang\\(\\'([^'.\"\\n\".']*)\\'\\);|', file_get_contents($moddir.'/'.$file), $parts))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$description = str_replace(\"\\\\'\",\"'\",$parts[1]);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif ($this->so->registermodule($modulename,$description ? $description : $moduleobject->description))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$new_modules[$modulename] = $modulename.': '.$moduleobject->description;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t//echo \"<p>Modules_BO::findmodules() found $modulename: $moduleobject->description</p>\\n\";\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t$d->close();\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn $new_modules;\n\t\t}", "title": "" }, { "docid": "ef9fdd8680861e5aeb0d97a4eb5b8745", "score": "0.54858196", "text": "private static function setupModules()\n {\n $aModuleLocations = [];\n\n // Discover Nails modules\n $aModules = Components::modules();\n\n /**\n * Note: Key is full path, value is relative path from the application controllers\n * directory to where the modules are.\n */\n $aAbsolutePaths = [\n [rtrim(APPPATH, DIRECTORY_SEPARATOR), 'modules'],\n [rtrim(FCPATH, DIRECTORY_SEPARATOR), 'vendor', 'nails', 'common'],\n ];\n\n $aRelativePaths = [\n ['..', 'modules'],\n ['..', '..', 'vendor', 'nails', 'common'],\n ];\n\n array_walk(\n $aAbsolutePaths,\n function (&$aItem) {\n $aItem = implode(DIRECTORY_SEPARATOR, $aItem) . DIRECTORY_SEPARATOR;\n }\n );\n\n array_walk(\n $aRelativePaths,\n function (&$aItem) {\n $aItem = implode(DIRECTORY_SEPARATOR, $aItem) . DIRECTORY_SEPARATOR;\n }\n );\n\n $aModuleLocations = array_merge(\n $aModuleLocations,\n array_combine($aAbsolutePaths, $aRelativePaths)\n );\n\n // Discovered Nails modules\n foreach ($aModules as $oModule) {\n $aModuleLocations[$oModule->path] = implode(\n DIRECTORY_SEPARATOR,\n ['..', '..', 'vendor', $oModule->name, '']\n );\n }\n\n // --------------------------------------------------------------------------\n\n /**\n * This hook happens before the config class loads (but the config file has\n * already been loaded). CI provides an interface to pass items to the config\n * file via the index.php file; we're going to leverage that here to set\n * the module locations.\n */\n\n // Underscore casing is important\n global $assign_to_config;\n $key = 'modules_locations';\n\n if (empty($assign_to_config)) {\n $assign_to_config = [];\n }\n\n if (isset($assign_to_config[$key]) && is_array($assign_to_config[$key])) {\n\n // Already set, merge the arrays\n $assign_to_config[$key] = array_merge($assign_to_config[$key], $aModuleLocations);\n\n } else {\n\n // Not set (or is set but not \"proper\", overwrite it as it's probably wrong anyway)\n $assign_to_config[$key] = $aModuleLocations;\n }\n }", "title": "" }, { "docid": "96b283088c20aeddf0afacc58be106d1", "score": "0.54854804", "text": "function features_available() {\n\t\t$raw_modules = Jetpack::get_available_modules();\n\t\t$modules = array();\n\t\tforeach ( $raw_modules as $module ) {\n\t\t\t$modules[] = Jetpack::get_module_slug( $module );\n\t\t}\n\n\t\treturn $modules;\n\t}", "title": "" }, { "docid": "5cdfec8574d97225a90217e1815055f8", "score": "0.54825145", "text": "public static function getActiveModuleName ()\n {\n $front = Zend_Controller_Front::getInstance();\n $name = $front->getRequest()->getModuleName();\n return ($name == '') ? 'default' : $name;\n }", "title": "" }, { "docid": "ac21dd89d7b756762a7cef133fcba162", "score": "0.5471843", "text": "function getNoneIntegratedModules() {\n\t\tglobal $_we_available_modules;\n\n\t\t$retArr = array();\n\n\t\tforeach ($_we_available_modules as $key => $modInfo) {\n\t\t\tif ($modInfo[\"integrated\"] == false) {\n\t\t\t\t$retArr[$key] = $modInfo;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $retArr;\n\t}", "title": "" }, { "docid": "e8bf32a9776e2f9b972f85488919f806", "score": "0.54668", "text": "public function provides()\n {\n return ['laravel-defaults'];\n }", "title": "" }, { "docid": "b6aa58e02861d96313ca29a98f0f5d58", "score": "0.54610527", "text": "public function getAvailableModules() {\r\n\t\t\r\n\t\treturn $this->client->call('get_available_modules',$this->session_id);\r\n\t}", "title": "" }, { "docid": "f9c8c7d5298dd31e10d254c27adc9414", "score": "0.54583323", "text": "function nobot_registration_module_list() {\n return module_list();\n}", "title": "" }, { "docid": "598df0d08e90c7d7fe7583a43c5133a1", "score": "0.54550976", "text": "public function getDefaultParsers(): array\n {\n return $this->defaultParsers;\n }", "title": "" }, { "docid": "0b649a3def1dd5ea7fb9fbe39442db12", "score": "0.54522467", "text": "public function getDefaultModels()\n {\n return [\n 'FileModel' => FileModel::className(),\n 'ImageFileModel' => ImageFileModel::className()\n ];\n }", "title": "" }, { "docid": "033ba185160a7328bb485ae4fbd71b88", "score": "0.5447422", "text": "public static function getActiveModule() {\r\n\t\t$module\t= TodoyuAdminPreferences::getActiveModule();\r\n\r\n\t\tif( $module === false ) {\r\n\t\t\t$module = Todoyu::$CONFIG['EXT']['admin']['defaultModule'];\r\n\t\t}\r\n\r\n\t\treturn $module;\r\n\t}", "title": "" }, { "docid": "49f681dff9a518e6988496110bd45ea0", "score": "0.5441195", "text": "public static function modules(array $modules = null) : array\n {\n if ($modules === null) {\n // Not changing modules, just return the current set\n return Apprunner::$_modules;\n }\n\n // Start a new list of include paths, APPPATH first\n $paths = [];\n\n foreach ($modules as $name => $module) {\n\n if (!isset($module['enable_on']) || ($module['enable_on'] & Apprunner::$environment)) {\n\n if (is_dir($module['path'])) {\n // Add the module to include paths\n // @ToDo: Add alternative to realpath when PHAR is executed\n $paths[] = $modules[$name]['path'] = realpath($module['path']) . DS;\n } else {\n // This module is invalid, remove it\n throw new Exception('Attempted to load an invalid or missing module ' . $name);\n }\n\n }\n }\n\n // Set the new include paths\n Apprunner::$_paths = Arr::merge(Apprunner::$_paths, $paths);\n\n // Set the current module list\n Apprunner::$_modules = $modules;\n\n foreach (Apprunner::$_modules as $module) {\n $init = $module['path'] . 'init.php';\n\n if (is_file($init)) {\n // Include the module initialization file once\n require_once $init;\n }\n }\n\n return Apprunner::$_modules;\n }", "title": "" }, { "docid": "bd358222c3b5c8d09b28a71c09813831", "score": "0.54407954", "text": "protected function getModulesConfig()\r\n {\r\n $moduleManager = $this->moduleManager;\r\n\r\n $modulesConfig = array();\r\n foreach ($moduleManager->getModules() as $module) {\r\n $modulesConfig[] = $module->toConfig();\r\n }\r\n\r\n return $modulesConfig;\r\n }", "title": "" }, { "docid": "cb73d2cff14e14fa60b9e3bbbda27449", "score": "0.5419655", "text": "private function _modules()\n {\n $modules = \\App\\Models\\Module::get()->toArray();\n \n $module_name = [];\n foreach($modules as $module)\n {\n $module_name[$module['name']] = $module['content'];\n }\n \n return $module_name;\n }", "title": "" }, { "docid": "9aebbc5b932364b5fa47f0edbd9f998c", "score": "0.54177976", "text": "static function get_bases_definidas()\r\n\t{\r\n\t\treturn self::$bases_definidas;\r\n\t}", "title": "" }, { "docid": "fcac5d823fd8a094303375bf1bfcf54b", "score": "0.5415926", "text": "public static function get_default_fieldtypes()\n {\n return self::config()->get('default_field_types');\n }", "title": "" }, { "docid": "6d8cc6c4da29c40ca2e86cb1415ef9d5", "score": "0.5406006", "text": "public function getModules()\n {\n return $this->arrModules;\n }", "title": "" }, { "docid": "0618f44a15cee273a9a19bec22b9c98d", "score": "0.5403192", "text": "protected function getDefaultCommands()\n {\n // Keep the core default commands to have the HelpCommand\n // which is used when using the --help option\n $defaultCommands = parent::getDefaultCommands();\n $defaultCommands[] = clone $this->singleCommand;\n\n return $defaultCommands;\n }", "title": "" }, { "docid": "93c0d1cafbb141e7f4623dbcadf6d24b", "score": "0.5399014", "text": "function getConfigDefaults() {\n\t\treturn static::$configDefaults;\n\t}", "title": "" }, { "docid": "436f638b37115ca5b5ad32602c3b649a", "score": "0.5397529", "text": "public function getDirectoryModules();", "title": "" }, { "docid": "1be4831467f1e2fbb638498a962a5fde", "score": "0.5390019", "text": "public function module_methods(){\n\t\treturn $modules_name = array(\n\t\t\t\t'l' => 'List',\n\t\t\t\t'a' => 'Add',\n\t\t\t\t'e' => 'Edit',\n\t\t\t\t'd' => 'Delete'\n\t\t\t);\n\t}", "title": "" } ]
9fd38a7ccaf1de9cdd6fba8af27c549b
Delete all by Product
[ { "docid": "607b5a88ac53ad82588bf5f68865cbab", "score": "0.0", "text": "public function deleteByCategory($id)\n {\n $qb = $this->createQueryBuilder();\n\n $query = $qb\n ->delete()\n ->where('category_id = :category')\n ->getQuery()\n ;\n\n return $this->db->prepare($query)->execute([':category' => $id]);\n }", "title": "" } ]
[ { "docid": "31108bdff2342640d544e0548ce41622", "score": "0.764875", "text": "public function deleteAll(){\n $product = Product::findorfail()->delete();\n\n return response()->json([\n 'status' => true,\n 'success' => 'Multiple Products Deleted Successfully!'\n ], 200);\n }", "title": "" }, { "docid": "4ec20bbef58e3c1faccca4018e717899", "score": "0.7412737", "text": "public function deleteAll(){\n $em = $this->getEntityManager();\n return $em->createQuery('DELETE FROM UIFIProductosBundle:ProyectoDirigido')->execute();\n }", "title": "" }, { "docid": "5bded13f00853036f4e90e560b570604", "score": "0.7185386", "text": "function deleteallProduct(Request $request){\n //print_r($request->checkbox); \n for($i=0; $i<count($request->checkbox); $i++){\n // DB::table('products')->where('id', '=', $request->checkbox[$i])->delete();\n Product::where('id', '=', $request->checkbox[$i])->delete();\n }\n return redirect()->route('product.list');\n }", "title": "" }, { "docid": "36e1492a9ead799000a94159780798b6", "score": "0.7055298", "text": "public function delete_all();", "title": "" }, { "docid": "52888b8c5e126137d79e16d43d555e49", "score": "0.70234954", "text": "public function del(){\n\t\t$sql = \"delete from \".self::$tablename.\" where ID_PRODUCTO=$this->ID_PRODUCTO\";\n\t\tExecutor::doit($sql);\n\t}", "title": "" }, { "docid": "7d5e740f49de45ff81d0313595d15b89", "score": "0.70126116", "text": "public function destroyProducts()\n {\n $this->load->model('shareino/synchronize');\n $listDestroy = $this->model_shareino_synchronize->destroy();\n\n //send request for delete\n $this->load->model('shareino/requset');\n $this->model_shareino_requset->deleteProducts($listDestroy);\n }", "title": "" }, { "docid": "64e7f7aa404c5d05887f9bb6a79a6a65", "score": "0.7005706", "text": "public function deleteAllByProductId($productId)\r\n {\r\n return $this->deleteByColumn('product_id', $productId);\r\n }", "title": "" }, { "docid": "9f302a3cb1642e1277ea061181860f06", "score": "0.69592077", "text": "public function forceDeleteWithResources($id): void{\n $product = Product::where('id', $id)->first(['id', 'uuid']);\n if (!$product){\n return;\n }\n $identifiers = Identifier::where('product_uuid', $product->uuid)->get();\n foreach ($identifiers as $identifier){\n $identifier->forceDelete();\n }\n $names = Name::where('product_uuid', $product->uuid)->get();\n foreach ($names as $name){\n $name->forceDelete();\n }\n $urls = Url::where('product_uuid', $product->uuid)->get();\n foreach ($urls as $url){\n $url->forceDelete();\n }\n $prices = Price::where('product_uuid', $product->uuid)->get();\n foreach ($prices as $price){\n $price->forceDelete();\n }\n $taxes = Tax::where('product_uuid', $product->uuid)->get();\n foreach ($taxes as $tax){\n $tax->forceDelete();\n }\n $stocks = Stock::where('product_uuid', $product->uuid)->get();\n foreach ($stocks as $stock){\n $stock->forceDelete();\n }\n $productCategories = ProductCategory::where('product_uuid', $product->uuid)->get();\n foreach ($productCategories as $productCategory){\n $productCategory->forceDelete();\n }\n $images = Image::where('product_uuid', $product->uuid)->get();\n foreach ($images as $image){\n $image->forceDelete();\n }\n $descriptions = Description::where('product_uuid', $product->uuid)->get();\n foreach ($descriptions as $description){\n $description->forceDelete();\n }\n $attributes = Attribute::where('product_uuid', $product->uuid)->get();\n foreach ($attributes as $attribute){\n $attribute->forceDelete();\n }\n $product->forceDelete();\n }", "title": "" }, { "docid": "c7de4ba7ff161a381320e9332534f6e5", "score": "0.6946509", "text": "public function deleteAllItems();", "title": "" }, { "docid": "f63f58dede4f326572ea2dffd93b165e", "score": "0.6943894", "text": "public function deleteProductsRelationship(){\n\n $products = $this->products()->get();\n\n foreach ($products as $product) {\n $product->setWardrobeidNull();\n }\n }", "title": "" }, { "docid": "c2b9458b7851e21383738c053ca2880c", "score": "0.68976593", "text": "public function removeAllAction(){\n\t\t$this->productRepository->removeAll();\n\t\t$this->productRepository->flushDocumentManager();\n\t\t$this->redirect('list');\n\t}", "title": "" }, { "docid": "0bc15d392dea847ce26d8de06bb7ee5c", "score": "0.68615854", "text": "public function deleted(Products $products)\n {\n //\n }", "title": "" }, { "docid": "aefb46bd4b903f1d81cd2f0664db9a30", "score": "0.6850224", "text": "public function deleteAll(){\n $query = $this->getEntityManager()->createQuery('DELETE AppBundle:Difference');\n $query->execute();\n }", "title": "" }, { "docid": "9dc82404cb9a7dc757ceec5ec50c26c0", "score": "0.67635375", "text": "public function deleteAll(Request $request)\n {\n $ids = $request->ids;\n DB::table(\"products\")->whereIn('id',explode(\",\",$ids))->delete();\n return response()->json(['success'=>\"Products Deleted successfully.\"]);\n }", "title": "" }, { "docid": "416681ea059abb0edaf7e27e2db3d666", "score": "0.676028", "text": "public function massDestroy()\n {\n $productIds = explode(',', request()->input('indexes'));\n\n foreach ($productIds as $productId) {\n $product = $this->product->find($productId);\n\n if(isset($product)) {\n $this->product->delete($productId);\n }\n }\n\n session()->flash('success', trans('admin::app.catalog.products.mass-delete-success'));\n\n return redirect()->route($this->_config['redirect']);\n }", "title": "" }, { "docid": "f816a18cb34d47864708ab158d939595", "score": "0.6749256", "text": "public function deleteAll()\n {\n $company_id = Configure::get('Blesta.company_id');\n $this->Record\n ->from(self::TABLE_PIN)\n ->from('clients')\n ->from('client_groups')\n ->where(self::TABLE_PIN . '.client_id', '=', 'clients.id', false)\n ->where('clients.client_group_id', '=', 'client_groups.id', false)\n ->where('client_groups.company_id', '=', $company_id)\n ->delete([self::TABLE_PIN]);\n }", "title": "" }, { "docid": "5a6b8e4d0a6dddd5bf708037a59bba75", "score": "0.6730436", "text": "public function massDestroy(Request $request)\n {\n if (! Gate::allows('product_delete')) {\n return abort(401);\n }\n if ($request->input('ids')) {\n $entries = Product::whereIn('id', $request->input('ids'))->get();\n\n foreach ($entries as $entry) {\n $entry->delete();\n }\n }\n }", "title": "" }, { "docid": "28e3d7472493c0af4a507a287e0ede2c", "score": "0.6721558", "text": "public function destroy($id)\n {\n // $product = Product::findOrFail($id);\n \n\n\n // DB::table('product_attributes')->where('product_id', $id)->delete();\n // DB::table('product_images')->where('product_id', $id)->delete();\n\n //$product->delete();\n // return redirect()->back()->with('Success','Product Data Deleted');\n }", "title": "" }, { "docid": "f1b9b615d472cf9ee74fb664de3d2178", "score": "0.6669137", "text": "function deleteProduct($id){\n // DB::table('products')->where('id', '=', $id)->delete();\n Product::where('id', '=', $id)->delete();\n return redirect()->route('product.list');\n }", "title": "" }, { "docid": "80757dc113a826969ef1dc1190920a4d", "score": "0.66679597", "text": "public function deleteAction()\n {\n $id = $this->getRequest()->getParam('id');\n if (!$id) {\n return false;\n }\n $response = $this->getModel()->deleteProductIndex($id);\n print_r($response);\n exit;\n }", "title": "" }, { "docid": "5215f1f954adf4016ac22491e9fc94be", "score": "0.6645982", "text": "public function deleted(Product $product)\n {\n }", "title": "" }, { "docid": "6623cc2e28db7ea9fa23e1d0353798f1", "score": "0.66417897", "text": "public function DeletePerProduct($id){\n\n $sql = \"DELETE FROM `vr_brillen`.`producten` WHERE id = $id\";\n $stmt = $this->DataHandler->Delete($sql);\n return $stmt;\n }", "title": "" }, { "docid": "fe6b812af1f0b47b867f2bdda195b7f0", "score": "0.6628894", "text": "public function deleted(Product $product)\n {\n //\n }", "title": "" }, { "docid": "fe6b812af1f0b47b867f2bdda195b7f0", "score": "0.6628894", "text": "public function deleted(Product $product)\n {\n //\n }", "title": "" }, { "docid": "fe6b812af1f0b47b867f2bdda195b7f0", "score": "0.6628894", "text": "public function deleted(Product $product)\n {\n //\n }", "title": "" }, { "docid": "d134eee426077ff16780fa92ea0bedf5", "score": "0.66167355", "text": "public function clearProductGarbage(){\n\t\treturn;\n\t\t$removed_products = $this->db->query(\"SELECT DISTINCT product_id FROM \".DB_PREFIX.\"customerpartner_to_product WHERE product_id NOT IN (SELECT DISTINCT c2p.product_id FROM \".DB_PREFIX.\"customerpartner_to_product c2p INNER JOIN \".DB_PREFIX.\"product p ON (c2p.product_id=p.product_id))\")->rows;\n\n\t\tforeach($removed_products as $product){\n\t\t\t$this->deleteProduct($product['product_id']);\n\t\t}\n\t}", "title": "" }, { "docid": "3667fed499d3634c79c1bf3b4ca9b76c", "score": "0.6599811", "text": "public function actionDeleteProduct() {\r\n $order = Order::model()->findByPk(Yii::app()->request->getPost('order_id'));\r\n\r\n if (!$order)\r\n $this->error404();\r\n\r\n $order->deleteProduct(Yii::app()->request->getPost('id'));\r\n }", "title": "" }, { "docid": "63e4d8126e18084808f833c68fe69db3", "score": "0.6594506", "text": "public function delete($id)\n {\n $productSizes = DB::table('productSize')->where('product_id','=', $id)->select('id')->get();\n foreach ($productSizes as $productSize) {\n DB::table('productSize')->whereIn('id', [$productSize->id])->delete();\n\n }\n $images = DB::table('images')->where('product_id','=', $id)->select('id')->get();\n foreach ($images as $image) {\n DB::table('images')->whereIn('id', [$image->id])->delete(); \n }\n\n //deleteProduct\n $product = Products::findOrFail($id);\n $product->delete();\n return Redirect::to('admin/product_list');\n }", "title": "" }, { "docid": "c21d811d2ba83640af49808c82a8f1c0", "score": "0.65876746", "text": "public function getAllForDelete()\n {\n $allSynchronizedProductsSearchCriteria = $this\n ->searchCriteriaBuilder\n ->addFilter('walkthechat_id', true, 'notnull')\n ->create();\n\n return $this->productRepository->getList($allSynchronizedProductsSearchCriteria)->getItems();\n }", "title": "" }, { "docid": "3a25d36c1eb0ba07148b21591808ecf7", "score": "0.65856785", "text": "public function product_delete($id){\n $product = Product::find($id);\n if(!is_null($product)){\n $product_image = ProductImage::orderBy('id','desc')->where('product_id',$product->id)->get();\n foreach ($product_image as $image) {\n if(File::exists('images/products/'.$image->image)){\n File::delete('images/products/'.$image->image);\n }\n $image->delete();\n }\n \n\n $product->delete();\n }\n session()->flash('success','Product delete Successfuly !!');\n return back();\n }", "title": "" }, { "docid": "f36c3dee1ad5e09179869ac08df402f8", "score": "0.657408", "text": "function deleteProduct($id)\n\t\t{\n\t\t}", "title": "" }, { "docid": "8bf49ea3feaa85e4f7ef2cb5a8058d19", "score": "0.65740323", "text": "public function DeleteProducto($idProducto);", "title": "" }, { "docid": "7f1ffa99aeb5c7548b652d4a897fe09c", "score": "0.6538371", "text": "public function product_delete() //delete product\n {\n $getid=$this->uri->segment(4);\n $this->db->where('product_id',$getid);\n $this->db->delete('product');\n }", "title": "" }, { "docid": "381bcf21b575ea0988be4e213720a80c", "score": "0.6505273", "text": "public function destroy(products $product)\n {\n //\n }", "title": "" }, { "docid": "d831ae04a66ae61d2ac69dbb62e9af2a", "score": "0.6491265", "text": "public function destroy($product_id){\n\n }", "title": "" }, { "docid": "37ba4e38b87038b153d325db168c73b4", "score": "0.64673567", "text": "public function actionDelete_review()\n\t{\n\t\t// current product\n\t\t$ids = $_POST['ids'];\n\t\t\n\t\tif (is_array($ids) && sizeof($ids)) {\n\t\t\tforeach ($ids as $id_review) {\n\t\t\t\t$criteria=new CDbCriteria; \n\t\t\t\t$criteria->condition='id=:id_review'; \n\t\t\t\t$criteria->params=array(':id_review'=>$id_review);\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t// delete all\n\t\t\t\tTbl_ProductReview::model()->deleteAll($criteria);\t\t\t\n\t\t\t}\n\t\t}\t\t\n\t}", "title": "" }, { "docid": "7660e60f81354b8803bbb979729d1e89", "score": "0.646255", "text": "public function removeProduct(Product $product, $all = false){\n\n //criar a conexao com o banco\n $sql = new Sql();\n \n //$all --> permitir que o usuario possa remover todos os produtos de uma soh vez (quantidade)\n if($all) {\n $sql->query(\"UPDATE tb_cartsproducts SET dtremoved = NOW() WHERE idcart = :idcart AND idproduct = :idproduct AND dtremoved IS NULL\", [\n //bind dos parametros\n ':idcart'=>$this->getidcart(),\n ':idproduct'=>$product->getidproduct()\n ]);\n } else {\n //funcao para remover apenas 1 produto, ou seja, diminuir\n $sql->query(\"UPDATE tb_cartsproducts SET dtremoved = NOW() WHERE idcart = :idcart AND idproduct = :idproduct AND dtremoved IS NULL LIMIT 1\", [\n //bind dos parametros\n ':idcart'=>$this->getidcart(),\n ':idproduct'=>$product->getidproduct() //indica que a da classe produtos\n ]);\n\n }\n\n //metodo para atualiza o frete\n $this->getCalculateTotal();\n\n \n\n\n }", "title": "" }, { "docid": "f32dc4e8bee637e36947a8f701cb4a19", "score": "0.64575684", "text": "function deleteProduct($id)\n {\n $db = dbConnect();\n\n $threeImages = explode(',', getProduct($id)['images']);\n\n //si il a des images, on les supprime avant de le supprimer complement\n if(getProduct($id)['images'] != null){\n unlink('../assets/images/products/' . $threeImages[0]);\n unlink('../assets/images/products/' . $threeImages[1]);\n unlink('../assets/images/products/' . $threeImages[2]);\n }\n\n\n //on supprime également les liens entre le produit et les catégories\n $queryDeleteLinkCategory = $db->prepare('DELETE FROM product_categories WHERE id_product = ?');\n $queryDeleteLinkCategory->execute([\n $id\n ]);\n\n //on supprime l'addresse du produit\n $queryDeleteLinkAddress = $db->prepare('DELETE FROM addresses WHERE id_product = ?');\n $queryDeleteLinkAddress->execute([\n $id\n ]);\n\n //on supprime le produit de tous les paniers\n $queryDeleteProductInAllCart = $db->prepare('DELETE FROM products_cart WHERE id_product = ?');\n $queryDeleteProductInAllCart->execute([\n $id\n ]);\n\n //suppresion du produit\n $queryDeleteProduct = $db->prepare('DELETE FROM products WHERE id = ?');\n $queryDeleteProduct->execute([\n $id\n ]);\n\n return $queryDeleteProduct;\n }", "title": "" }, { "docid": "3e23805be67f756fb111f257e6a5afcd", "score": "0.64407355", "text": "public function destroy($id)\n {\n $listOrder_details = OrderDetail::where('product_id', $id)->get();\n foreach ($listOrder_details as $detail) {\n $detail->delete(); \n } \n Product::destroy($id);\n return redirect()->route('list-product')->with('success','Delete product successful !');\n }", "title": "" }, { "docid": "99853521874040506866d4bb168e452a", "score": "0.64214104", "text": "public function delete()\r\n\t\t{\r\n\t\t\t//Validate request method\r\n\t\t\tif($this->getRequestMethod() != \"DELETE\"){\r\n\t\t\t\t$this->methodNotAllowed();\r\n\t\t\t}\r\n\r\n\t\t\t// Input validations\r\n\t\t\t$this->validation(array('iProductId'));\r\n\r\n\t\t\t$iProductId = (int)$this->_arrRequest['iProductId'];\r\n\r\n\t\t\tif($iProductId > 0){\r\n\t\t\t\t$sWhere \t\t= \"iProductId = '\".$iProductId.\"'\";\r\n\t\t\t\t$iDeleteStatus \t= $this->deleteRecord($this->_sProductTable,$sWhere);\r\n\t\t\t\t$iStatus \t\t= ($iDeleteStatus>0) ? \"Success\" : \"False\";\r\n\t\t\t\t$sMessage\t\t= ($iDeleteStatus>0) ? \"Deleted successfully.\" : \"Fail to delete.\";\r\n\t\t\t}else{\r\n\t\t\t\t$iStatus = \"False\";\r\n\t\t\t\t$sMessage = \"Invalid input.\";\r\n\t\t\t}\r\n\t\t\t$arrResponse['status']\t= $iStatus;\r\n\t\t\t$arrResponse['message']\t= $sMessage;\r\n\t\t\t$this->response($this->json($arrResponse), 200);\r\n\t\t}", "title": "" }, { "docid": "204e89301a4ba435a9d3662bb9639e71", "score": "0.64194846", "text": "function deleteAll();", "title": "" }, { "docid": "129254789d46752958a144811b47ab54", "score": "0.64188915", "text": "protected function _delete()\n {\n $product = $this->_getProduct();\n try {\n $product->delete();\n } catch (Mage_Core_Exception $e) {\n $this->_critical($e->getMessage(), Mage_Api2_Model_Server::HTTP_INTERNAL_ERROR);\n } catch (Exception $e) {\n $this->_critical(self::RESOURCE_INTERNAL_ERROR);\n }\n }", "title": "" }, { "docid": "1b0660118f429ca0dee43b44e9778577", "score": "0.6410087", "text": "public function destroy(Request $request)\n {\n $order_id = $request->input('orderId');\n $order = Order::find($order_id);\n $orderProduct = OrderProduct::where('order_id', '=' , $order->id)->get();\n foreach ($orderProduct as $item){\n $item->delete();\n }\n $order->delete();\n return redirect()->route('order.index')->with('success', 'The order deleted successfully');\n }", "title": "" }, { "docid": "9cde737c2f1d1699dd799fb38e1257a9", "score": "0.640895", "text": "public function testDeleteProducts()\n {\n $client = static::createClient();\n \n $crawler = $client->request('POST', '/api/product.json', [\n 'name' => 'Product 1',\n 'price' => 123.55,\n 'stock' => 100,\n 'categories' => [\n [\n 'name' => 'TEST'\n ]\n ]\n ]);\n \n $content = json_decode($client->getResponse()->getContent());\n\n $this->assertEquals(201, $client->getResponse()->getStatusCode());\n \n $crawler = $client->request('DELETE', '/api/products.json', ['id' => $content->id]);\n\n $this->assertEquals(204, $client->getResponse()->getStatusCode());\n }", "title": "" }, { "docid": "e0560362c1819505ade7915ab3fbcc0f", "score": "0.6408791", "text": "public function delete($majoraEntitys);", "title": "" }, { "docid": "7bc994c41b2e9ae7f58934d2da537548", "score": "0.64056474", "text": "public function actionDeleteByAjax(){\n\n if (Yii::$app->request->isAjax) {\n $product_ids = Yii::$app->request->post('ids');\n try {\n $forinkeys = [];\n $allow = true;\n foreach ($product_ids as $id){\n\n $customerAddress = CustomerAddress::find()->where(['customer_id'=> $id])->one()->id;\n $customerCard = CustomerCard::find()->where(['customer_id'=> $id])->one()->id;\n// $payment = Payment::find()->where(['customer_id'=> $id])->one()->id;\n\n if ($customerAddress){\n $allow = false;\n $forinkeys[$id]['brand'] = $customerAddress;\n }\n if ($customerCard){\n $allow = false;\n $forinkeys[$id]['category'] = $customerCard;\n }\n// if ($payment){\n// $allow = false;\n// $forinkeys[$id]['producteAttribute'] = $payment;\n// }\n }\n if($allow){\n Customer::deleteAll(['in','id', $product_ids]);\n echo true; exit();\n }\n print_r(json_encode($forinkeys)); exit();\n } catch (\\mysqli_sql_exception $e) {\n Yii::$app->session->setFlash('error', 'you are not deleted');\n echo json_encode(['deleted' => 'error']); exit();\n }\n }\n }", "title": "" }, { "docid": "e6f5d337f12efd2c78900c00e89d8313", "score": "0.64048296", "text": "public function delete_product_by_id_arary() {\n $data = json_decode(file_get_contents(\"php://input\"), true);\n \t\n $id = $data['id'];\n \t$curr_date = date('Y-m-d H:i:s');\n\n \tif (!isset($data['id'])) {\n \t\treturn response()->json(['response_code'=>'400', 'state' => 'Missing Params : {id}. Insert Failed.', 'datetime' => $curr_date]);\n \t} \n\n \t$id_array = explode(',', $id);\n \t$id_sql_string = \"\";\n\n \tforeach ($id_array as $id) {\n\t\t $id_sql_string = $id_sql_string . \"id = \" . $id . \" OR \";\n\t\t}\n\n\t\t$sql = \"DELETE FROM ecom_product_item WHERE \" . $id_sql_string . \" id = 0\"; \n\n $mysql = DB::delete($sql);\n\n \n\t if ($mysql or $mysql == 0) {\n\t \treturn response()->json(['response_code'=>'200', 'state'=>'Delete Product Type Succ', 'data' => $mysql, 'datetime' => $curr_date]);\n\t \t} else {\n\t \treturn response()->json(['response_code'=>'400', 'state'=>'Delete Product Type Failed', 'data' => \"\", 'datetime' => $curr_date]);\n\t }\n }", "title": "" }, { "docid": "774fd156e90d5f67090704de4e4185a6", "score": "0.63966227", "text": "public function actionDelete($id) {\n \n $product=Product::model()->findByAttributes(array('id'=>$id));\n $product->product_status_id=2;\n $product->save(false);\n\n // if (Yii::app()->request->isPostRequest) {\n // we only allow deletion via POST request\n\n// $criteria = new CDbCriteria;\n// $criteria->condition = 'product_id=:ProductID';\n// $criteria->params = array(':ProductID' => $id);\n// $color = Color::model()->find($criteria);\n// if (count($color)) {\n// Color::model()->deleteAll($criteria);\n// }\n//\n// $criteria = new CDbCriteria;\n// $criteria->condition = 'product_id=:ProductID';\n// $criteria->params = array(':ProductID' => $id);\n// $size = Size::model()->find($criteria);\n// if (count($size)) {\n// Size::model()->deleteAll($criteria);\n// }\n//\n// $criteria = new CDbCriteria;\n// $criteria->condition = 'product_id=:ProductID';\n// $criteria->params = array(':ProductID' => $id);\n// $productdetails = ProductDetails::model()->find($criteria);\n// if (count($productdetails)) {\n// ProductDetails::model()->deleteAll($criteria);\n// }\n//\n//\n//\n//\n// $criteria = new CDbCriteria;\n// $criteria->condition = 'product_id=:ProductID';\n// $criteria->params = array(':ProductID' => $id);\n// $room = Room::model()->find($criteria);\n// if (count($room)) {\n// Room::model()->deleteAll($criteria);\n// }\n//\n//\n//\n//\n//\n//\n//\n// $this->loadModel($id)->delete();\n//\n//\n//\n// // if AJAX request (triggered by deletion via admin grid view), we should not redirect the browser\n// if (!isset($_GET['ajax']))\n// $this->redirect(isset($_POST['returnUrl']) ? $_POST['returnUrl'] : array('index'));\n// } else\n// throw new CHttpException(400, 'Invalid request. Please do not repeat this request again.');\n }", "title": "" }, { "docid": "3857e08248d11d4fbe2bdb0880a92345", "score": "0.63912284", "text": "public function delete($id){\r\n\t\t$this->db->where('id', $id)\r\n\t\t\t\t ->delete('products');\r\n\t}", "title": "" }, { "docid": "f22c8820723c0efb02715aaf73704d02", "score": "0.6387083", "text": "public function delete($entity)\n {\n $query = $this->db->table($entity->definition()->getName());\n $primary = $entity->id();\n if (isset($this->objects[$entity->definition()->getName()][base64_encode(serialize($primary))])) {\n foreach ($primary as $k => $v) {\n $query->filter($k, $v);\n }\n $query->delete();\n unset($this->objects[$entity->definition()->getName()][base64_encode(serialize($primary))]);\n }\n }", "title": "" }, { "docid": "88eb609e66206d061ba479be23baab6d", "score": "0.63838893", "text": "public function eliminar_productos($id){\n $stmt=$this->conexion->conectar()->prepare(\"DELETE FROM productos WHERE id_producto=:id\");\n $stmt->bindParam(\":id\",$id,PDO::PARAM_STR);\n $stmt->execute();\n $stmt->closeCursor();\n }", "title": "" }, { "docid": "fbfb4b66b51bfe1c0839e1d2b5442be8", "score": "0.63807786", "text": "public function deleteDeal($entityIds) {\n /**\n * load product object\n */\nMage::getModel ( 'catalog/product' )->load ( $entityIds )->setSpecialFromDate ( '' )->setSpecialToDate ( '' )->setSpecialPrice ( '' )->save ();\nreturn true;\n}", "title": "" }, { "docid": "e6e037d382549007f1adbe9c948af1cf", "score": "0.63743967", "text": "public function delete($product_id, $quantity, $price);", "title": "" }, { "docid": "f6453761d242466206211a719e11b978", "score": "0.63674885", "text": "public function delete(){\r\n\t\t$params = array();\r\n\t\tforeach($this->id as $fieldName){\r\n\t\t\t$alias = $this->fields[$fieldName];\r\n\t\t\t$params[$this->fields[$fieldName]] = $this->$alias;\r\n\t\t}\r\n\r\n\t\t$this->deleteById($params);\r\n\t}", "title": "" }, { "docid": "b098361ad02ac56a0167065fc3029e5d", "score": "0.63672227", "text": "public function deleteByProduct($id)\n {\n $qb = $this->createQueryBuilder();\n\n $query = $qb\n ->delete()\n ->where('product_id = :product')\n ->getQuery()\n ;\n\n return $this->db->prepare($query)->execute([':product' => $id]);\n }", "title": "" }, { "docid": "8732a939d3c3d700a156e3ab0da09a12", "score": "0.63569635", "text": "public function destroy($id)\n {\n\n $this->product= $this->product->getProductById($id);\n// dd( $this->product);\n if(!$this->product){\n request()->session()->flash('error','product does not exit ');\n return redirect()->route('product.index');\n }\n $thumb = $this->product->image;\n\n $product_images = $this->product->images;\n\n// dd($product_images);\n $del = $this->product->delete();\n if ($del){\nif ($thumb){\n deleteFile($thumb,'products');\n deleteFile('Thumb-'.$thumb,'products');\n\n foreach($product_images as $key){\n\n deleteFile($key->image_name,'products');\n deleteFile('Thumb-'.$key->image_name,'products');\n}\n}\n request()->session()->flash('success','product deletd successfully ');\n\n }else{\n request()->session()->flash('error','Problem while deleting ');\n\n }\n return redirect()->route('product.index');\n\n\n\n }", "title": "" }, { "docid": "ed62f2e154fa22b647127897895f5b8d", "score": "0.6347254", "text": "function deleteRelations($product_id){\n\t\t//echo $product_id;\n\t\tif($product_id){\n\t\t\t$filters = array(\"product_id=\".$product_id);\n\t\t\t$this->deletedata($this->dbRelationTable, $filters);\n\t\t}\n\t}", "title": "" }, { "docid": "aa82b4ed319862a1f4cecb97d4a3ecd9", "score": "0.6343863", "text": "public function batchItemsDelete()\n {\n try {\n ExmQuestionItems::destroy(Request::get('id'));\n return Redirect::back()->with('message', 'Successfully deleted Information!');\n }\n catch\n (exception $ex){\n return Redirect::back()->with('error', 'Invalid Delete Process ! At first Delete Data from related tables then come here again. Thank You !!!');\n\n }\n }", "title": "" }, { "docid": "6a7bc00ab16363f073aa09a07881fbae", "score": "0.63426036", "text": "public function removeByProduct(Product $product)\n {\n //Search interested\n $collectionInterested = Interested::where('product_id', $product->product_id)->get();\n foreach ($collectionInterested as $interested) {\n $interested->delete();\n }\n }", "title": "" }, { "docid": "7bd01b7f93bb5caca773a55a900d3945", "score": "0.6341615", "text": "public function destroy($id)\n {\n $product = Product::findOrFail($id);\n $gallery = ProductGallery::where('products_id',$product->id)->get();\n foreach($gallery as $gl){\n if(Storage::disk('public')->exists($gl->photo)){\n Storage::disk('public')->delete($gl->photo);\n }\n }\n // $gallery->delete();\n $product->delete();\n return redirect()->back()->with('success','Product Telah Terhapus');\n }", "title": "" }, { "docid": "80722c3b38da32ec692f3c0dca76db5c", "score": "0.63412917", "text": "public function deleteAll(): void\n {\n $this->where('is_deleted', '=', 1)->delete();\n }", "title": "" }, { "docid": "0b7c77ce5ed099dc9cf5bd88059aec7f", "score": "0.6340307", "text": "public function delete()\n {\n Order::where(\"product_id\",$this->id)->delete();\n ProductImage::where(\"product_id\", $this->id)->delete();\n\n // Finally, delete this image...\n return parent::delete();\n }", "title": "" }, { "docid": "e47da67390df6949a6a79f2ccb0a278e", "score": "0.63384473", "text": "public function destroy($id)\n {\n\n $product = Product::findOrFail($id);\n $delete = $product->delete();\n $productImage = ProductImages::where('product',$id)->get();\n foreach ($productImage as $value){\n $productImageDel=ProductImages::findOrFail($value->id);\n $del=$productImageDel->delete();\n }\n $return = redirect()->route('product_admin.index');\n if ($delete) {\n return $return->with('message', 'İşlem Başarılı')->with('type', 'success');\n } else {\n return $return->with('message', 'İşlem Başarısız. Lütfen daha sonra tekrar deneyiniz.')->with('type', 'danger');\n }\n }", "title": "" }, { "docid": "7288d27cc553ab79893ce730ec7a8a5c", "score": "0.6333231", "text": "public function delete(Request $request)\n {\n $request->validate(['product' => 'required']);\n $product = User::loggedIn()\n ->products()->with('items')->find(request('product'));\n\n //Detach users from this item\n foreach ($product->items as $item) {\n Item::deleteAndDetach($item);\n }\n\n //Delete product\n $product->delete();\n return redirect('product');\n }", "title": "" }, { "docid": "42396a4dddb95606d679d317a502839c", "score": "0.6330579", "text": "function borrarProducto($id){\n $sentencia = $this->db->prepare(\"delete from producto where id=?\");\n $sentencia->execute([$id]);\n }", "title": "" }, { "docid": "ca4faee20898e0c4317309c4fae0718b", "score": "0.6329239", "text": "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$producto = $this->Phreezer->Get('Producto',$pk);\n\n\t\t\t$producto->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}", "title": "" }, { "docid": "12d0af071d24c8b7fc13e50f019f6a54", "score": "0.6328609", "text": "abstract public function delete_all(): bool;", "title": "" }, { "docid": "2d030944ab7909a2653b0fd1a4e84742", "score": "0.6326668", "text": "public function clearProducts()\n {\n $this->products = array();\n }", "title": "" }, { "docid": "d9f98e02a15f2a7ab3242db81b388f57", "score": "0.6319073", "text": "public function delete($id){\n\n $mProduct = new ProductModel();\n $MlProduct = $mProduct->delete($id);\n\n return $MlProduct;\n\n }", "title": "" }, { "docid": "f5afbfb9ce964fc8fd228d304443262a", "score": "0.6305462", "text": "public function destroy($subdomain,$id)\n {\n $product = Product::findOrFail($id);\n\n $data = new ArchiveProduct();\n $data['productid']=$product->id; \n $data['owner']=$product->owner;\n $data['title']=$product->title;\n $data['slug']=$product->slug;\n $data['skucode']=$product->skucode;\n $data['category']=implode(\",\",$product->category);\n $data['description']=$product->description;\n $data['price']=$product->price;\n $data['offer_price']=$product->offer_price;\n $data['selling_price']=$product->selling_price;\n $data['stock']=$product->stock;\n $data['tax']=$product->tax;\n $data['shipping_cost']=$product->shipping_cost;\n $data['sizes']=$product->sizes;\n $data['feature_image']=$product->feature_image;\n $data['policy']=$product->policy;\n $data['tags']=$product->tags;\n $data['featured']=$product->featured;\n $data['views']=$product->views;\n $data['approved']=$product->approved;\n $data['status']=$product->status;\n $data['metatitle']=$product->metatitle;\n $data['metadec']=$product->metadec;\n $data['metakey']=$product->metakey;\n $data['metakey']=$product->metakey;\n $data['company_id']=$product->company_id;\n\n // dd($product,$data);\n $data->save();\n // dd($data);\n\n if($product->feature_image != '')\n {\n unlink('assets/images/products/'.$product->feature_image);\n }\n \n $product->delete();\n $gal = Gallery::where('productid',$id);\n $galllarydata = Gallery::where('productid',$id)->get();\n \n foreach($galllarydata as $allgal)\n {\n if($allgal->image != '')\n {\n unlink('assets/images/gallery/'.$allgal->image);\n }\n \n }\n \n $gal->delete();\n return redirect('admin/products')->with('message','Product Delete Successfully.');\n }", "title": "" }, { "docid": "e468a9005a954081eea457a9a658dae8", "score": "0.63043267", "text": "protected function handleProductDelete()\n {\n $post = $this->openCart->request->post;\n if (isset($post['selected'])) {\n $recurrencyProductRepo = new RecurrencyProductRepository(new OpencartDatabaseBridge());\n $selected = array_map(function($element){\n return intval($element);\n },$post['selected']);\n\n $plans = $recurrencyProductRepo->listEntities(0,false);\n\n $subProductsOfPlans = [];\n\n foreach ($selected as $productId) {\n /** @var RecurrencyProductRoot $product */\n foreach ($plans as $plan) {\n if ($plan->getProductId() == $productId) {\n $plan->setDisabled(true);\n $recurrencyProductRepo->save($plan);\n continue;\n }\n $subProducts = $plan->getSubProducts();\n if (!in_array($plan->getProductId(),$selected)) {\n /** @var RecurrencySubproductValueObject $subProduct */\n foreach ($subProducts as $subProduct) {\n if ($subProduct->getProductId() == $productId) {\n if(!isset($subProductsOfPlans[$productId])) {\n $subProductsOfPlans[$productId] = [];\n }\n $subProductsOfPlans[$productId][$plan->getProductId()] = true;\n }\n }\n }\n }\n }\n\n if (count($subProductsOfPlans)) {\n $this->openCart->load->model('catalog/product');\n\n $cantDeleteData = [];\n foreach ($subProductsOfPlans as $subProductId => $planProducts) {\n $subProduct = $this->openCart->model_catalog_product->getProduct($subProductId);\n $cantDeleteData[$subProductId] = [\n \"name\" => $subProduct[\"name\"],\n \"plans\" => []\n ];\n foreach ($planProducts as $planId => $discard) {\n $plan = $this->openCart->model_catalog_product->getProduct($planId);\n $cantDeleteData[$subProductId][\"plans\"][] = $plan[\"name\"];\n }\n }\n $sessionData = $this->openCart->session->data;\n $sessionData['mundipagg-cant-delete-product-data'] = $cantDeleteData;\n $this->openCart->session->data = $sessionData;\n\n $getParams = $this->openCart->request->get;\n $getParams['user_token'] = $this->openCart->session->data['user_token'];\n unset($getParams['route']);\n $getParams = array_map(function($param,$key){\n return \"$key=$param\";\n },$getParams,array_keys($getParams));\n $getParams = implode('&',$getParams);\n\n $this->openCart->response->redirect(\n $this->openCart->url->link(\n 'catalog/product',\n $getParams\n )\n );\n }\n }\n }", "title": "" }, { "docid": "2f66e2cb22f4bdbaa5b5397fe5794b26", "score": "0.6301892", "text": "public function borrarProducto(Request $datos){\n $idProducto = $datos['idProducto'];\n //Busco el producto y lo borro\n $productoEncontrado = Producto::find($idProducto);\n if($productoEncontrado){\n $productoEncontrado->delete();\n }\n \n //Busco todos los carritos que tengan ese producto\n $carritos = Carrito::where('idProducto',$idProducto)->get();\n\n //Borro cada carrito que exista, para no tener conflicto con el id\n //del producto\n foreach($carritos as $carrito){\n $carrito->delete();\n }\n\n return redirect('/productos');\n }", "title": "" }, { "docid": "b904d43feac9ffe98718bcf66241b19b", "score": "0.6300045", "text": "public function destroy($id)\n{\n $product = Product::where('id',$id)->delete();\n \n return Response::json($product);\n}", "title": "" }, { "docid": "2cc29735d64449971456033cbf273c96", "score": "0.6291176", "text": "public function deleteProduct($id)\n {\n\n \t Products::where('Products.id','=',$id)->delete(); \t\t\n $msg = array(\"msg\"=>\"Successfully Deleted\");\n return response()->json($msg,200);\n\n }", "title": "" }, { "docid": "4ce740c5740168913e28b56621bc9481", "score": "0.6287648", "text": "public function destroy(Product $product)\n {\n foreach ($product->images as $image) {\n //borrar los archivo imagen\n \\Storage::delete($image->src);\n //borrar las filas imagen\n $image->delete();\n }\n //pasar el product a inactivo\n $product->visible = 0;\n $product->save();\n\n return redirect('products');\n }", "title": "" }, { "docid": "805d1116a07d97066395dbcc21c81139", "score": "0.62876344", "text": "public function deleteCartaoConvite() {\n }", "title": "" }, { "docid": "f9842761dee660fc44864f3bec8dc24c", "score": "0.6284247", "text": "protected function cleanByIds($productIds)\n {\n $query = $this->connection->deleteFromSelect(\n $this->connection\n ->select()\n ->from($this->resource->getTableName('catalogrule_product'), 'product_id')\n ->distinct()\n ->where('product_id IN (?)', $productIds),\n $this->resource->getTableName('catalogrule_product')\n );\n $this->connection->query($query);\n\n $query = $this->connection->deleteFromSelect(\n $this->connection->select()\n ->from($this->resource->getTableName('catalogrule_product_price'), 'product_id')\n ->distinct()\n ->where('product_id IN (?)', $productIds),\n $this->resource->getTableName('catalogrule_product_price')\n );\n $this->connection->query($query);\n }", "title": "" }, { "docid": "6f447d73e21c86e765b27129e078fada", "score": "0.6284116", "text": "public function remove_all_product( $product_id )\n \t{\n \t\t$this->db->where('product_id' , $product_id)->delete('product_notification');\n \t\treturn True;\n \t}", "title": "" }, { "docid": "3e6408e58d63a0daea66893544cbdbdf", "score": "0.62811226", "text": "public function deleteProduct(int $id): bool;", "title": "" }, { "docid": "717fc6c227c040ddd153ff31da2e990a", "score": "0.62784934", "text": "public function trash(Product $id){\n try{\n $id -> delete();\n return true;\n }catch(Exception $err){\n return false;\n }\n}", "title": "" }, { "docid": "0aab78adaf2c552ac9fb91fbb0d88516", "score": "0.6277549", "text": "public function Delete(Request $request)\n {\n $products=DB::table('productos')\n ->where('productos.id','=',$request->id)\n ->delete();\n return 'Eliminacion Exitosa!!';\n }", "title": "" }, { "docid": "c8f62f392c6055ac47f6335a927b9c44", "score": "0.62772393", "text": "function deleteProduct($productId) {\n\t$url = '/products/'.$productId;\n\t$result = sendRequest($url,'DELETE');\n\treturn $result;\n}", "title": "" }, { "docid": "88ad4d692f4a5bd522a8c1e7a57866e7", "score": "0.6275356", "text": "function delete_product($Nis)\n\t\t{\n\t\t\treturn $this->db->delete('productos', array('Nis' => $Nis));\t\n\t\t}", "title": "" }, { "docid": "913efef61651ab6cc133ab3001389549", "score": "0.6270573", "text": "public function adminProductDeleteAction()\n {\n $this->checkAdmin();\n //products model\n $vars['admin'] = \"\";\n $this->model->deleteProduct(intval($this->route['id']));\n $this->view->redirect(\"/SafeRideStore/admin/products\");\n }", "title": "" }, { "docid": "36c60dd79d35409d579fb6a067b68f91", "score": "0.62619835", "text": "public function deleteAll() {\n if (APPLICATION_ENV == 'production') {\n throw new Exception(\"Not Allowed\");\n }\n $this->getMapper()->deleteAll();\n }", "title": "" }, { "docid": "36c60dd79d35409d579fb6a067b68f91", "score": "0.62619835", "text": "public function deleteAll() {\n if (APPLICATION_ENV == 'production') {\n throw new Exception(\"Not Allowed\");\n }\n $this->getMapper()->deleteAll();\n }", "title": "" }, { "docid": "a8d659346578223b7e8c172518219d24", "score": "0.625663", "text": "public function destroy($id)\n {\n \n $product = Product::find($id);\n \n foreach ($product->product_images as $image) {\n \n \n if (Storage::disk('public')->exists('product/'.$image->product_image)) {\n Storage::disk('public')->delete('product/'.$image->product_image);\n }\n\n }\n \n ProductImage::where('product_id',$id)->delete();\n $product->delete();\n\n return redirect()->back()->with('massage','Product Delete Successful .');\n \n\n }", "title": "" }, { "docid": "35231a58ded5ede80c33831c1a1d539f", "score": "0.62466705", "text": "public function hookActionProductDelete($params)\n {\n $id_product = (int) $params['id_product'];\n if (!$id_product) {\n return;\n }\n $hs_ma_product = new HsMaProduct();\n $hs_ma_product->id = $id_product;\n $hs_ma_product->deleteAccessories();\n }", "title": "" }, { "docid": "ed27766bcbdfa34e7af47c290d2fadb6", "score": "0.6243613", "text": "public function actionBulkDelete()\n { \n $request = Yii::$app->request;\n $pks = explode(',', $request->post( 'pks' )); // Array or selected records primary keys\n foreach ( $pks as $pk ) {\n if($pk!=1){\n $model = $this->findModel($pk);\n if($model->logo!=\"\"&&$model->logo!=null&&file_exists('uploads/filial_logos/' . $model->logo)){\n unlink(\"uploads/filial_logos/\" . $model->logo);\n }\n $model->delete();\n }\n }\n\n if($request->isAjax){\n /*\n * Process for ajax request\n */\n Yii::$app->response->format = Response::FORMAT_JSON;\n return ['forceClose'=>true,'forceReload'=>'#crud-datatable-pjax'];\n }else{\n /*\n * Process for non-ajax request\n */\n return $this->redirect(['index']);\n }\n }", "title": "" }, { "docid": "6172857756c93fac2aabb7924af0b9d7", "score": "0.6243121", "text": "public function permanentlyDeleteAll()\n {\n $permanenDeletedAll = Product::onlyTrashed();\n $permanenDeletedAll->forceDelete();\n return redirect()->route('admin.product.trashed')->with('deleted');\n }", "title": "" }, { "docid": "b8f5b9e439f22bde6af968a631f16d62", "score": "0.62376446", "text": "public function actionBulkDelete()\n { \n $request = Yii::$app->request;\n $pks = $request->post('pks'); // Array or selected records primary keys\n foreach (ProyectoAsignar::findAll(json_decode($pks)) as $model) {\n $model->delete();\n }\n \n\n if($request->isAjax){\n /*\n * Process for ajax request\n */\n Yii::$app->response->format = Response::FORMAT_JSON;\n return ['forceClose'=>true,'forceReload'=>true]; \n }else{\n /*\n * Process for non-ajax request\n */\n return $this->redirect(['index']);\n }\n \n }", "title": "" }, { "docid": "8658580aaecd7854ad15c9cb0be303f0", "score": "0.6233424", "text": "public function deleteProduct()\n {\n User::validateAdminRequest($this->user);\n\n $id = $this->request->GET(\"productID\");\n $query = \"DELETE FROM produkte WHERE id = '\" . $id . \"'\";\n $this->database->query($query);\n header(\"Location: http://Localhost/WebundMultimedia/product/administration\");\n die;\n }", "title": "" }, { "docid": "55003901010f76acaa376487d78b0f9c", "score": "0.62304693", "text": "public function deleteProductAction()\n {\n $productRepository = new ProductRepository();\n $id = filter_input(INPUT_GET, 'id', FILTER_SANITIZE_NUMBER_INT);\n\n $success = $productRepository->deleteProduct($id);\n\n if($success){\n $message = 'SUCCESS - product with id = ' . $id . ' was deleted';\n } else {\n $message = 'sorry, product id = ' . $id . ' could not be deleted';\n }\n $this->messageAction($message);\n }", "title": "" }, { "docid": "cffe9427108b54725b40f826167ad780", "score": "0.6230197", "text": "public function destroy(Productos $productos)\n {\n //\n }", "title": "" }, { "docid": "cffe9427108b54725b40f826167ad780", "score": "0.6230197", "text": "public function destroy(Productos $productos)\n {\n //\n }", "title": "" }, { "docid": "cffe9427108b54725b40f826167ad780", "score": "0.6230197", "text": "public function destroy(Productos $productos)\n {\n //\n }", "title": "" }, { "docid": "6632d12ffa787250ad2689097126f13a", "score": "0.6229817", "text": "function delete_all_cart_fxn($a){\n\t//create an instance of the cart class\n\t$cart_object = new Product();\n\n\t//run the delete all cart method\n\t$delete_cart = $cart_object->delete_all_cart_item($a);\n\n\t//check if method worked\n\tif ($delete_cart) {\n\n\t\t//return query result (boolean)\n\t\treturn $delete_cart;\n\t}else{\n\t\t//return false\n\t\treturn false;\n\t}\n}", "title": "" }, { "docid": "787628e4d889631d5ed124acba05b99f", "score": "0.6220896", "text": "public function deleteProduct($id) {\n return $this->model->where('id', '=', $id)->delete();\n }", "title": "" }, { "docid": "358ac0e824cef5f24178fc0daf22ba70", "score": "0.62158024", "text": "public function delete($entity);", "title": "" }, { "docid": "faac8361977953ef076ef2e9e42158ca", "score": "0.62147456", "text": "public function destroy(Products $products)\n {\n //\n }", "title": "" }, { "docid": "faac8361977953ef076ef2e9e42158ca", "score": "0.62147456", "text": "public function destroy(Products $products)\n {\n //\n }", "title": "" } ]
313ff7705d4e87750b2cd162f3a73639
Show the form for editing the specified resource.
[ { "docid": "2f20c620946768b514ff069ac56934b1", "score": "0.0", "text": "public function edit(Saude $saude, $id)\n { $this->authorize('saudes_edit');\n $consultors = Consultor::all();\n $seguradora = Seguradora::all();\n $saude = Saude::findOrFail($id);\n\n\n return view('admin.saude.edit',compact('seguradora','consultors','saude'));\n }", "title": "" } ]
[ { "docid": "eaff1ff5ad75e879908bb065beeea534", "score": "0.78929687", "text": "public function edit(Resource $resource)\n {\n return view('actions.resource.edit', compact('resource'));\n }", "title": "" }, { "docid": "f3bc4ff0e0f2cc54bf914d77670e405e", "score": "0.78108525", "text": "public function edit(Resource $resource)\n {\n return view('resource.edit',['resource'=>$resource]);\n }", "title": "" }, { "docid": "469e3d6c9afd54041becbee857df8ef8", "score": "0.76944435", "text": "public function edit(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "4bdbe4ff8aec98fee963bdf4dbf6da91", "score": "0.7513841", "text": "public function edit(FormBuilder $formBuilder, $course, Resource $resource)\n {\n //\n $edit = $formBuilder->create(\\App\\Forms\\Resource::class, [\n 'method' => 'PATCH',\n 'url' => route('resource.update', [$course, $resource->id]),\n 'model' => $resource,\n ]);\n //\n $delete = $formBuilder->create(\\App\\Forms\\DeleteForm::class, [\n 'method' => 'DELETE',\n 'url' => route('resource.destroy', [$course, $resource->id]),\n ]);\n $pageTitle = 'Edit Resource';\n return view('resources.formEdit', compact('edit','delete', 'pageTitle'));\n\n }", "title": "" }, { "docid": "93f7e624d9e32a9fbf006f4f83dae8a8", "score": "0.7486703", "text": "public function edit($id)\n {\n /*show edit form*/\n }", "title": "" }, { "docid": "1404e57fbb5774c03bfe25411f8fe287", "score": "0.7330742", "text": "public function edit($id)\n {\n $resource = Resource::findOrFail($id);\n \n $data = [\n 'resource' => $resource,\n ];\n\n return view('resources.edit-resource')->with($data);\n }", "title": "" }, { "docid": "ed0028dbd1fbb47ee337d77b8a651d9a", "score": "0.73023635", "text": "public function edit($id)\n\t{\n\t\t$resource = Resource::findOrFail($id);\n\t\treturn View::make('resource/edit', compact('resource'));\n\t}", "title": "" }, { "docid": "4753e80c2af19bb37f8b9df0bf10829e", "score": "0.726186", "text": "public function edit( )\n\t{\n\t\t// show\n\t}", "title": "" }, { "docid": "2d0354bc64da2d977cfd60754017882b", "score": "0.72583026", "text": "public function edit($id)\n {\n $userdata = Resources::findOrFail($id);\n return view('admin.resource.edit', compact('userdata'));\n }", "title": "" }, { "docid": "8c5ec66a768a8406204fdc19e3dec141", "score": "0.72381544", "text": "public function edit($id)\n\t{\n\t\t// Get the resource if it has not been provided by the child class\n\t\tif( ! $this->resource->getKey())\n\t\t\t$this->resource = $this->resource->findOrFail($id);\n\n\t\t$this->layout->subtitle = _('Edit');\n\n\t\treturn $this->loadView(__FUNCTION__, $this->resource->getFillableLabels());\n\t}", "title": "" }, { "docid": "f486aa2dad1b98a29b575e9dba22938d", "score": "0.7133095", "text": "public function edit($id)\n {\n $resource = Resource::findOrFail($id);\n\n return view('resources.edit')->with(compact('resource'));\n }", "title": "" }, { "docid": "654b96e5d414d66677bf1e3d1695b1d8", "score": "0.71187615", "text": "public function edit_form()\n {\n return View::make(\"app.edit\");\n }", "title": "" }, { "docid": "ecbdcecae7d17f5fd47a1b3471865b07", "score": "0.71159434", "text": "public function edit($resourceId)\n {\n $resource = $this->resource->find($resourceId);\n\n return view('laramanager::resources.edit', compact('resource'));\n }", "title": "" }, { "docid": "8640b0c244bf00ab3b420106f09d5eb1", "score": "0.7115456", "text": "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('BWBlogBundle:Resource')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Resource entity.');\n }\n\n $form = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('BWBlogBundle:Resource:edit.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "title": "" }, { "docid": "ab1c5f00384bd443c0312a8cedd635d9", "score": "0.70957655", "text": "function edit() {\n\t\t$this->isAuthorized() or $this->abortUnauthorized();\n\n\t\t$productId = KRequest::getInt('productId');\n\t\t$matrixId = KRequest::getInt('id');\n\n\t\t$view = $this->getDefaultViewForm();\n\t\t$view->setProductId($productId);\n\t\t$view->setMatrixId($matrixId);\n\t\t$view->display();\n\n\t}", "title": "" }, { "docid": "5df52742ed05bd924198604d4236743d", "score": "0.70600516", "text": "public function edit($id)\n {\n //$resource = Resource::findOrFail($id);\n $query = '\"select\":\"*\",\"where\":\"id=' . $id . '\"';\n $data = ResourcesService::getResourcesTableRow($query);\n $resource = $data[\"Result\"][0];\n SyncService::SyncResourcesTable();\n return view('admin.resources.edit', compact('resource'));\n }", "title": "" }, { "docid": "6c1e231bfb659c518730d45c158fa402", "score": "0.7042527", "text": "public function edit($id)\n\t{\n\t\t$resource = $this->repository->getResource($id);\n\t\t$menuTab = $this->menuTab;\n\t\treturn response()->view('admin.resources.edit', compact(['resource', 'menuTab']));\n\t}", "title": "" }, { "docid": "9c8836b3e3aa143dfa78083f839f6e60", "score": "0.7037317", "text": "public function editAction()\n {\n $request = $this->getRequest();\n\t\t$id = $request->getParam(\"id\");\n\n $form = new Application_Form_Book();\n $book = new Application_Model_Book();\n\t\t$mapper = new Application_Model_BookMapper();\n $mapper->find($id, $book);\n\t\t\n\t\t$form->populate($book);\n\t\t\n\t\t$this->view->form=$form;\n\n }", "title": "" }, { "docid": "96884a0d55f36349b743e3d913248156", "score": "0.70018226", "text": "function edit()\n {\n $this->_view_edit('edit');\n }", "title": "" }, { "docid": "38b4c2bcc5d6f933f82442e502068ae3", "score": "0.69461757", "text": "public function edit($id)\n\t{\n\t\treturn $this->showForm('update', $id);\n\t}", "title": "" }, { "docid": "0aee08a6c8d208457326de0c63ab1d93", "score": "0.6941118", "text": "public function edit($id)\n\t{\n $form_data = ['route' => [self::$prefixRoute . 'update', $this->revision->id], 'method' => 'PUT'];\n\n return view(self::$prefixView . 'form', compact('form_data'))\n \t->with(['revision' => $this->revision]);\n\t}", "title": "" }, { "docid": "13550b89e98e00015a895299bc148377", "score": "0.6933925", "text": "public function editAction()\n {\n $assign_id = $this->_getParam('assign');\n $this->_includeForm($assign_id);\n }", "title": "" }, { "docid": "44db8e15fc1352a7c519823621a72cc9", "score": "0.6933916", "text": "public function edit()\n {\n return view('coreplanification::edit');\n }", "title": "" }, { "docid": "901ccd53ce97c5a7d1966359f57043a4", "score": "0.6912328", "text": "public function edit()\n {\n return view('inpatient::edit');\n }", "title": "" }, { "docid": "6acf67aab48fd2b396026c0eeb096874", "score": "0.69121194", "text": "public function edit()\n {\n return view('prappo::edit');\n }", "title": "" }, { "docid": "291ee83a27f023635ff2c99d1e9ea7a6", "score": "0.6903521", "text": "private function createEditForm(Resource $entity)\n {\n $form = $this->createForm(new ResourceType(), $entity, array(\n 'em' => $this->getDoctrine()->getManager(),\n 'action' => $this->generateUrl('resource_update', array('id' => $entity->getId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array(\n 'label' => 'Update',\n 'attr' => array(\n 'class' => 'btn btn-primary',\n ),\n ));\n\n return $form;\n }", "title": "" }, { "docid": "53a8dd3945e8d394e8af0378fcb0759a", "score": "0.68760294", "text": "public function edit($id)\n\t{\n // get\n $resident = Resident::find($id);\n\n // show the edit form and pass\n return View::make('residents.edit')\n ->with('resident', $resident);\n\t}", "title": "" }, { "docid": "b1f8a3dd503a02e69fbec578be1ee9d1", "score": "0.6863962", "text": "public function editForm($id)\n\t{\n\t\t$job = Job::find($id);\n\t\tif(!$job)\n\t\t{\n\t\t\tApp::abort(404);\n\t\t}\n\n\t\treturn View::make('admin.jobs.edit')->with(array(\n\t\t\t'title' => 'Edition de '.$job->name,\n\t\t\t'job' => $job\n\t\t));\n\t}", "title": "" }, { "docid": "6fe32e6f0c7ebd96d516ccbe60770da8", "score": "0.68637323", "text": "public function edit()\n\t{\n\t\t$jInput = JFactory::getApplication()->input;\n\t\t$jInput->set('view', 'field');\n\t\t$jInput->set('layout', 'default');\n\t\t$jInput->set('hidemainmenu', 1);\n\n\t\tparent::display();\n\t}", "title": "" }, { "docid": "766ad0e46f9488ff1bb3e99bffd9b013", "score": "0.685965", "text": "public function edit($id)\n {\n return view('formbuilder::edit');\n }", "title": "" }, { "docid": "3adf6e4a4db6770a78d161ea39e0d09a", "score": "0.6857073", "text": "public function editAction ( )\n {\n $model = $this->getModel($this->_modelName);\n $request = $this->getRequest();\n $form = $model->getForm();\n $params = $request->getParams();\n\n $model->load($request->getParam('id'));\n\n $form->injectDependencies($model, $params);\n\n if (! $model->id) {\n $message = sprintf(self::MSG_LOAD_FAILURE, $this->_modelName);\n $this->flashAndRedirect($message, 'error', array(\n 'module' => $request->getModuleName(),\n 'controller' => $request->getControllerName(),\n 'action' => 'index',\n ));\n }\n\n if ($request->isPost()) {\n try {\n $this->_edit($model, $request);\n } catch (Zend_Exception $exception) {\n $get = $this->_getGetRequest();\n $this->flashAndRedirect($exception->getMessage(), 'error', $get);\n }\n }\n\n $this->view->form = $form;\n $this->view->model = $model;\n\n }", "title": "" }, { "docid": "d56e1574f0c5378fe3811673b7df8b42", "score": "0.68515986", "text": "public function edit($id)\n\t{\n\t\t$this->page_title = 'Edit Associate';\n\t\t$data = $this->rendarEdit($id);\n\t\treturn view('admin.crud.form',$data);\n\t}", "title": "" }, { "docid": "489dd9e64fb4a5c656aedbd3e14c8922", "score": "0.6849498", "text": "public function edit($id)\n\t{\n\t\t$question = Question::findOrFail($id);\n return view('admin.question.form', compact('question'));\n\t}", "title": "" }, { "docid": "9f631e40538fb44577d89db78f7348d8", "score": "0.6848387", "text": "public function edit($id)\n {\n\t\t$user = $this->repository->findOneById($id);\n\n return view($this->base . 'form',compact('user'));\n }", "title": "" }, { "docid": "ebdfabd30fdb198a4595764f3e45e18f", "score": "0.6833621", "text": "public function actionEdit()\n {\n $this->view->article = Article::findById((int)$_GET['id']);\n $this->view->display(__DIR__ . '/../../../templates/admin/edit.php');\n }", "title": "" }, { "docid": "8f4207c19a0c7a6f7e5ad8a14497a90f", "score": "0.68263966", "text": "public function edit($id)\n\t{\n\t\treturn \"Shows a form for editing a specific post\";\n\t}", "title": "" }, { "docid": "3968d721d2d6a0540f1d6feba20cef0c", "score": "0.68242395", "text": "public function edit($id)\n {\n return view('controllers.resource-controllers.edit', compact('id'));\n }", "title": "" }, { "docid": "43a06ccc90a0e604ffd06cacb786b0ff", "score": "0.68214774", "text": "public function edit($id)\n\t{\n\t\t$student = $this->students->findById($id);\n return View::make('students._form', array('student' => $student, 'exists' => true));\n\n\t}", "title": "" }, { "docid": "dd6567bb75ad8b2f5dcd4461b639f0e6", "score": "0.6820688", "text": "public function edit($id)\n {\n $form = Form::find($id);\n return view('formbuilder::form.edit',compact('form'));\n }", "title": "" }, { "docid": "ca5f52bec4884c7fcd8605fda797f2e0", "score": "0.6812673", "text": "public function edit($id)\n {\n $form =\\App\\Form::find($id);\n return view('form.edit',compact('form'));\n }", "title": "" }, { "docid": "07993cef1b04896170dffd4d46ed96aa", "score": "0.681223", "text": "public function edit($class_id, $resource)\n {\n //\n }", "title": "" }, { "docid": "42fefa0bb00f6a35ff461a006d5fb4fe", "score": "0.6809734", "text": "public function editForm()\n {\n $data = [\n 'question' => App::get('database')->select('questions', 'id', $_GET['id']),\n 'answers' => App::get('database')->select('answers', 'answer_id', $_GET['id'])\n ];\n\n return view('questions.edit', compact('data'));\n }", "title": "" }, { "docid": "5dbf6a424144f5f1ea70f7e2584cb814", "score": "0.6805565", "text": "public function edit()\r\n {\r\n return view('admin::edit');\r\n }", "title": "" }, { "docid": "b2548057b424e6a5cacb6db19ee658ae", "score": "0.680353", "text": "public function edit()\n {\n return view('api::edit');\n }", "title": "" }, { "docid": "62c2bf22604789e0fe0631318bc4da7e", "score": "0.6792974", "text": "public function edit() {\n\t\t/* CHANGED - switched to url(\"id\") as $this->param(\"id\") is deprecated */\n\t $this->id = WaxUrl::get(\"id\");\n\t\tif(!$this->id) $this->id = $this->route_array[0];\n $this->model = new $this->model_class($this->id);\n \n\t\t$this->form = $this->render_partial(\"form\");\n\t\tif($_POST['cancel']) $this->redirect_to(Session::get(\"list_refer\"));\n\t\tif($_POST['save']) $this->save($this->model, \"edit\");\n\t\telse $this->save($this->model, Session::get(\"list_refer\"));\n\t}", "title": "" }, { "docid": "4d4b5c8d6ba885d863626bf0f1e99725", "score": "0.67919654", "text": "public function edit($id)\n\t{\n\t\t$this->resources = array('car' => $this->resource,\n \t\t\t\t\t\t\t\t 'categories' => Category::ClassListSelectInput(),\n \t\t\t\t\t\t\t\t 'carList' => Car::carListSelectOptions()\n \t\t\t\t\t\t);\n\t\treturn $this->respondTo(\n\t\t\tarray('html'=> function()\n\t\t\t\t \t\t\t{\n\t\t\t\t \t\t\t $this->layout->nest('content', $this->view, $this->resources);\n\t\t\t\t \t\t\t},\n\t\t\t\t 'js' => function()\n\t\t\t\t \t\t {\n\t\t\t\t \t\t \t $form = View::make($this->form, $this->resources)->render();\n\t\t\t\t \t\t \t return View::make('admin.shared.modal', array('body' => $form))->render();\n\t\t\t\t \t\t }\n\t\t\t\t )\n\t\t\t);\n\t}", "title": "" }, { "docid": "86d596efe1714c0e50410fc7134cd9e3", "score": "0.6790526", "text": "public function edit()\n {\n return view('berating::edit');\n }", "title": "" }, { "docid": "2147ded57d317abac917ded7bf4c5589", "score": "0.678975", "text": "public function edit($id)\n {\n $record = $this->model->findOrFail($id);\n\n $this->viewData['record'] = $record;\n\n $this->viewData['formMethod'] = 'PUT';\n $this->viewData['formAction'] = 'user.update';\n\n return view($this->defaultFormView, $this->viewData);\n }", "title": "" }, { "docid": "b475fc8e937568a510257d6507f3a6e2", "score": "0.67697", "text": "public function edit($id)\n {\n $product = Product::find($id);\n return view('admin.product.form',[ 'product' => $product ]);\n }", "title": "" }, { "docid": "cadf80168cda3fc14631174ff8ec05e6", "score": "0.67678666", "text": "public function editAction()\n {\n $model = $this->_initModel();\n\n // make sure that the model exists before continuing\n if ($this->_getRequestedId() && !$model && !$model->getId()) {\n Mage::getSingleton('adminhtml/session')->addError($this->__('This ' . $this->_getObjectLabel() . ' no longer exist or is corrupt.'));\n $this->_redirect('*/*/');\n } else {\n $this->_initAction()->renderLayout();\n }\n }", "title": "" }, { "docid": "5bf37156a011a54f8d1f89ba96911864", "score": "0.67595875", "text": "public function edit(Form $form)\n {\n return view('forms.edit',compact('form'));\n }", "title": "" }, { "docid": "ac62d8f04a855af96ee81ddcc7f43f6a", "score": "0.6751915", "text": "public function edit(): void\n {\n $this->showEditPage($this->getItem());\n }", "title": "" }, { "docid": "e87e608ddadfa3687caa6cc9477425cf", "score": "0.6747173", "text": "public function edit($id)\n {\n $is_edit = true;\n $product = Product::find($id);\n\n return view('products.form', compact('product', 'is_edit'));\n }", "title": "" }, { "docid": "f317696c87c55af5bdb2c774e7855698", "score": "0.67431706", "text": "public function edit(Resource $resource)\n {\n //\n // $this->authorize('update',Resource::class);\n // $page=Page::all();\n // return view('resource.edit',compact('page','resource'));\n return response()->json($resource);\n }", "title": "" }, { "docid": "2a0de8686ce09f7bacd45838296d3aac", "score": "0.67402995", "text": "public function edit($id)\n {\n if(Gate::denies('familia-edit')){\n abort(403,\"Não autorizado!\");\n }\n\n $familia = Familia::find($id);\n\n return view('familias.form',compact('familia'));\n }", "title": "" }, { "docid": "6d0cd677e592e2179223532437971edd", "score": "0.6729001", "text": "public function edit($id)\n\t{\n return view($this->path . 'edit', ['record' => Record::find($id)] );\n\t}", "title": "" }, { "docid": "8ecab6633b0244e83acc1262c8f70524", "score": "0.67259544", "text": "public function edit($id)\n\t{\n\t\t$famoso = Famoso::find($id);\n\n\t\t// show the edit form and pass the object\n\t\treturn View::make('famoso.edit')\n\t\t\t->with('famoso', $famoso);\n\t}", "title": "" }, { "docid": "5e95479074ff3a4269a77c41326ace59", "score": "0.67239136", "text": "public function editing(){\n\t\t/// Send the user to this view\n\t\t$this->render(\"editing\");\n\t}", "title": "" }, { "docid": "e9232910411eba7ae6c98603663c9453", "score": "0.6720607", "text": "public function edit($id)\n {\n $company = Company::find($id);\n $company->form_action = $this->getRoute() . '.update';\n $company->page_title = 'Company Edit Page';\n // Add page type here to indicate that the form.blade.php is in 'edit' mode\n $company->page_type = 'edit';\n return view('backend.companies.form', [\n 'company' => $company\n ]);\n }", "title": "" }, { "docid": "1d24319a1462677632ee7717aa20a61d", "score": "0.6716397", "text": "public function edit($id)\n { \n \treturn view(\"gestion.formularios.edit\",[\"formulario\"=>Formulario::findOrFail($id)]); \n }", "title": "" }, { "docid": "73c3c8ef8ccb5ebffbd7c9d1617e5de2", "score": "0.6716382", "text": "public function editForm() {\n\t\t$layout = $this->input->get('layout', null, 'string');\n\t\t$nameModelForm = (empty($layout)) ? $this->nameKey.'form' : $layout.'form';\n\t\t$layout = (empty($layout)) ? 'edit' : 'edit_'.$layout; //BmDebug::log($layout, __method__);\n\t\t$view = $this->getView($this->default_view,\n\t\t\tJFactory::getDocument()->getType(), '', array('layout' => $layout));\n\t\t$view->setModel($this->getModel($this->nameKey));\n\t\t$view->setModel($this->getModel($nameModelForm));\n\t\t$view->editForm();\n\t}", "title": "" }, { "docid": "2a667f76d35f0224dbbf223e12e110af", "score": "0.6708166", "text": "public function actionEdit($id)\n\t{\n\t\t$form = $this->getComponent('rightResourceForm');\n\t\t/* @var $form Form */\n\n\t\t$submit = $form->addSubmit(FormBuilder::SUBMIT_EDIT, 'upravit zdroj oprávnění');\n\t\t$submit->onClick[] = callback($this,'edit');\n\n\t\t$form->addSubmit('stortno', \"storno\")->setValidationScope(false)->onClick[] = callback($this,'formStorno');\n\t}", "title": "" }, { "docid": "4e3f60120231c9e9fb4516dda6cad799", "score": "0.67005956", "text": "public function edit($id)\n {\n $entity = Entity::query()->find($id);\n return view('crudgenerator::entities.edit', compact('entity'));\n }", "title": "" }, { "docid": "a7dded643ee65e6b9cf08ef89ee539b6", "score": "0.6700171", "text": "public function edit($id)\n\t{\n $form_data = ['route' => [self::$prefixRoute . 'update', $this->presentation->id], 'method' => 'PUT'];\n\n return view(self::$prefixView . 'form', compact('form_data'))\n \t->with(['presentation' => $this->presentation]);\n\t}", "title": "" }, { "docid": "b3e1f1e6d5549bd781053c989eb1e847", "score": "0.66964877", "text": "public function edit($id)\n {\n $author = Author::find($id);\n return view('admin.author.form',['author' => $author]); \n }", "title": "" }, { "docid": "fe08627e9afbe6ed7f13f71f273030a1", "score": "0.66953826", "text": "public function edit($id)\n\t{\n $employee = Employee::find($id);\n return View::make('system.Employee.edit',compact(\"employee\"));\n\t}", "title": "" }, { "docid": "b8547be61d1a0bb98b26ec7de01610cd", "score": "0.66881543", "text": "public function edit($id, FormBuilder $form_builder): Renderable\n {\n $existing_product = $this->product_repository->getById($id);\n\n $form = $form_builder->create('App\\Forms\\Product\\EditForm', [\n 'method' => 'PUT',\n 'url' => route('product.update'),\n 'model' => $existing_product\n ]);\n\n return view('product.modify', compact('form'));\n }", "title": "" }, { "docid": "bf49bc8226e13e2862c2259d16e93588", "score": "0.66822207", "text": "public function edit($id)\n {\n $product = Product::find($id);\n return view('products.edit_form')->with('product', $product)->with('manufacturers', Manufacturer::all());\n }", "title": "" }, { "docid": "6c0376e096733d3b0fa90503eef2434b", "score": "0.66784656", "text": "public function edit()\n {\n return view('bangunan::edit');\n }", "title": "" }, { "docid": "44ff363bc16fe7311c23454456531dbc", "score": "0.6677221", "text": "public function edit_item()\n {\n $this->check_authorization();\n \n $id = $this->get_arg('id', 0);\n $item = Item::find($id); \n $data['item'] = $item;\n $data['breadcrumbs'] = $this->generate_breadcrumbs(\n $item->category_id,\n array('/show_item?id='.$item->id => $item->name)\n );\n\n return new View('item_form', $data); \n }", "title": "" }, { "docid": "41567083a127c71ff96104505b7b5dec", "score": "0.6675521", "text": "public static function edit()\n {\n $record = todos::findOne($_REQUEST['id']);\n self::getTemplate('edit_task', $record);\n\n }", "title": "" }, { "docid": "58fa8a98152b59c2e07c439335e492b4", "score": "0.66664857", "text": "public function edit($id)\n {\n return view('web::edit');\n }", "title": "" }, { "docid": "98c3057a696eb14943e7e5fea5851c0b", "score": "0.666635", "text": "public function edit($id)\n {\n return $this->showForm($id);\n }", "title": "" }, { "docid": "adb01bd13a4dfbf550016516570e7b60", "score": "0.66657627", "text": "public function edit($id)\n\t{\n\t\t$this->resources = array('station' => $this->resource\n \t\t\t\t\t\t);\n\t\treturn $this->respondTo(\n\t\t\tarray('html'=> function()\n\t\t\t\t \t\t\t{\n\t\t\t\t \t\t\t $this->layout->nest('content', $this->view, $this->resources);\n\t\t\t\t \t\t\t},\n\t\t\t\t 'js' => function()\n\t\t\t\t \t\t {\n\t\t\t\t \t\t \t $form = View::make($this->form, $this->resources)->render();\n\t\t\t\t \t\t \t return View::make('admin.shared.modal', array('body' => $form))->render();\n\t\t\t\t \t\t }\n\t\t\t\t )\n\t\t\t);\n\t}", "title": "" }, { "docid": "5fa4968110c48bd9bdcff5495b19f29a", "score": "0.6653186", "text": "public function edit()\n {\n return view('task::edit');\n }", "title": "" }, { "docid": "c13dfacb9aed13d70a670ff15ea907b6", "score": "0.6650427", "text": "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('EmpleadoBundle:Empleado')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Empleado entity.');\n }\n\n $editForm = $this->createForm(new EmpleadoType(), $entity);\n \n\n return $this->render('PanelBundle:Empleado:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n ));\n }", "title": "" }, { "docid": "58f55c0117c1a36e605cb5c2aabc68e3", "score": "0.6641953", "text": "public function edit() {\n\t\t$author = pick_arg(Author::class) ?: new Author;\n\t\treturn $this->viewEdit(compact('author'));\n\t}", "title": "" }, { "docid": "221efc99f3dd40c0f971d42862c5b218", "score": "0.66360426", "text": "public function edit($id)\n\t{\n\t\tif(!$this->autorizado) return Redirect::to('/login');\n\t\t$modelo = Modelo::find($id);\n\t\tif (is_null ($modelo))\n\t\t{\n\t\t\tApp::abort(404);\n\t\t}\n\t\treturn View::make('models.form')->with('modelo', $modelo);\n\t}", "title": "" }, { "docid": "b912d383bf373377209a233f3ceefe90", "score": "0.6629962", "text": "public function editAction($id) {\r\n $em = $this->getDoctrine()->getEntityManager();\r\n\r\n $entity = $em->getRepository('MedicinaKernelBundle:Oficina')->find($id);\r\n\r\n if (!$entity) {\r\n throw $this->createNotFoundException('No se ha encontrado la oficina solicitada');\r\n }\r\n\r\n $editForm = $this->createForm(new OficinaType(), $entity);\r\n\r\n return $this->render('BackendBundle:Oficina:edit.html.twig', array(\r\n 'entity' => $entity,\r\n 'form' => $editForm->createView(),\r\n ));\r\n }", "title": "" }, { "docid": "5af850265a4a33e59e46a01b80ede2a3", "score": "0.6628306", "text": "public function edit()\n {\n return view('user::edit');\n }", "title": "" }, { "docid": "e69682a60ea811251468072e63bf80cb", "score": "0.66275156", "text": "public function showEditForm($id)\n\t{\n\t\t$post = Post::where('id', $id)->first();\n\t\treturn view('admin.post.edit', ['post' => $post]);\n\t}", "title": "" }, { "docid": "bb154b1db81c97b24dc305b03e48e156", "score": "0.66262764", "text": "function edit() {\n\t\t$this->display();\n\t}", "title": "" }, { "docid": "4ba7055b2304ab3f588267e488d1cfb9", "score": "0.66211414", "text": "function viewedit(){\n $id=Request::read('id');\n \n $nota = $this->getModel()->getNota($id);\n $this->getModel()->addData('titulo', $nota->getTitulo());\n $this->getModel()->addData('contenido', $nota->getContenido());\n $this->getModel()->addData('favorito', $nota->getFavorito());\n $this->getModel()->addData('idNotas', $nota->getId());\n $this->getModel()->addData('idUsuario', $nota->getIdUsuario());\n $this->getModel()->addFile('form', 'sections/nota/formEdit.html');\n }", "title": "" }, { "docid": "c9ce59f5b770500a9924cc8e0f97bf72", "score": "0.6619817", "text": "public function edit($id)\n {\n $resident = Resident::where('id','=',$id)->with('relatives')->first();\n return view('survey.family-member-form.edit', compact('resident'));\n }", "title": "" }, { "docid": "afb09dad84e30958b4252ef05c35ffd3", "score": "0.6619694", "text": "public function editView() {\n $this->edit = true;\n $this->addView();\n }", "title": "" }, { "docid": "63720603ef56686d63e3133a9a3ec385", "score": "0.6613471", "text": "public function edit()\n {\n return view('mgdestino::edit');\n }", "title": "" }, { "docid": "09ca9097e9f59afd7ab61c2fa4368b57", "score": "0.6612424", "text": "public function showEditForm($id)\r\r\n {\r\r\n $userinfo = User::findOrFail($id);\r\r\n return view('/auth/edituser', compact('userinfo'));\r\r\n }", "title": "" }, { "docid": "fb75ecb723bf601f0c220bda3e7a2405", "score": "0.6609862", "text": "public function edit($id);", "title": "" }, { "docid": "035eb13b2ca5fd52c8005c0d17b6d221", "score": "0.6609614", "text": "public function edit()\n {\n return view('dashboard::edit');\n }", "title": "" }, { "docid": "035eb13b2ca5fd52c8005c0d17b6d221", "score": "0.6609614", "text": "public function edit()\n {\n return view('dashboard::edit');\n }", "title": "" }, { "docid": "f77eec10d5891a2545e2b33ab8d59228", "score": "0.6609529", "text": "public function edit()\n {\n $company = Company::first();\n return view('company.edit',compact('company'));\n }", "title": "" }, { "docid": "9ec66c39b4a9570023bc9493ee748e0e", "score": "0.66049886", "text": "protected function editAction()\n {\n $this->editAction\n ->setAccess($this, Access::CAN_EDIT)\n ->setOwnerAccess($this)\n ->execute($this, UserEntity::class, UserActionEvent::class, NULL, __METHOD__, [], ['user_id' => $this->thisRouteID()])\n ->render()\n ->with(\n [\n 'user' => $this->toArray($this->findOr404()),\n 'check_icon' => '<li><ion-icon name=\"checkmark-outline\"></ion-icon></li>',\n 'close_icon' => '<ion-icon name=\"close-outline\"></ion-icon>'\n ]\n )\n ->form($this->formUser)\n ->end();\n }", "title": "" }, { "docid": "f1396c5dcd191e30f534693231be69da", "score": "0.6602594", "text": "public function edit()\n {\n return view('usersupplier::edit');\n }", "title": "" }, { "docid": "2a47ad7ce79b806f24d1a15c7fc9c440", "score": "0.65982515", "text": "public function edit($id)\n {\n return view('frontend::edit');\n }", "title": "" }, { "docid": "5f22addb2b8cf9ad635b7e8fa77bb71c", "score": "0.65957636", "text": "public function edit()\n {\n return view('mgcatalogos::edit');\n }", "title": "" }, { "docid": "751bc10498bcb4f6f6569034693a7061", "score": "0.65928525", "text": "public function edit($id)\n {\n $template = (object) $this->template;\n $form = $this->form();\n $data = SPM::find($id);\n return view('admin.master.edit',compact('template','form','data'));\n }", "title": "" }, { "docid": "bdaf931446dd96d9ab719a5b26c06691", "score": "0.6591433", "text": "public function edit(FormBuilder $formBuilder, $id)\n {\n $form = $formBuilder->create(\\App\\Forms\\BookForm::class, [\n 'method' => 'PUT',\n 'url' => route('book.update',$id),\n ]);\n $books = Book::find($id);\n return view($this->folder.'.edit',compact('books','form'));\n }", "title": "" }, { "docid": "fbf7adc2631fd986ff97047f975f7733", "score": "0.6590043", "text": "public function formEdit($id)\n {\n //data poli berdasarkan id poli\n $poli = Poli::find($id);\n\n return view('poli.edit', compact('poli'));\n }", "title": "" }, { "docid": "300b72dd1771af8bcd33044e19ed0e2d", "score": "0.6586828", "text": "public function edit($id)\n\t{\n\t\t// get the nerd\n\t\t$user = Cliente::find($id);\n\n\t\t// show the edit form and pass the nerd\n\t\treturn View::make('preinscrito.editar')\n\t\t\t->with('user', $user);\n\t}", "title": "" }, { "docid": "f39615b9da8997b13628876a6e82ad26", "score": "0.6584163", "text": "public function edit()\n {\n return view('bill::edit');\n }", "title": "" }, { "docid": "48a8ca09ce387a26578ef11260681196", "score": "0.6580853", "text": "public function editform($id){\n $cultivo = Cultivo::findOrFail($id);\n\n return view(\"editform\", compact(\"cultivo\"));\n }", "title": "" } ]
a25f01a4c31011d9664ef2e354a726ac
Returns the response body as string
[ { "docid": "41b78ada13a14b1fab60a32e4a5de6c7", "score": "0.0", "text": "public function json(): array\n {\n return (array) json_decode($this->response->getBody(), true);\n }", "title": "" } ]
[ { "docid": "52b741b056025f6d6855993d3cfcc0f3", "score": "0.8493357", "text": "function body(): string\n {\n return (string) $this->response->getBody();\n }", "title": "" }, { "docid": "109a2cbc9f957071dc9e490c4731e189", "score": "0.82650125", "text": "protected function getBodyFromResponse() {\n return (string)$this->response->getBody();\n }", "title": "" }, { "docid": "9880460a55347cc09d1a7cf5464e446c", "score": "0.79156643", "text": "public function get_response_body() {\n\t\treturn $this->response_body;\n\t}", "title": "" }, { "docid": "1bdc75659217ce9feee776e0a2d6071c", "score": "0.7872714", "text": "public function getBody()\r\n {\r\n return $this->raw_response;\r\n }", "title": "" }, { "docid": "6816d1d1831a0ffaf5396a0f02250f27", "score": "0.7842991", "text": "public function get_response_body()\n {\n return $this->response_body;\n }", "title": "" }, { "docid": "8860441370ce177fa025784bdeaf69cf", "score": "0.76936233", "text": "public function getBody()\n {\n if (is_null($this->body)) {\n $this->wait();\n\n $this->body = $this->response instanceof ResponseInterface ? (string) $this->response->getBody() : '';\n }\n\n return $this->body;\n }", "title": "" }, { "docid": "f361b82d10a52d0cda234dc37cbac76f", "score": "0.7659861", "text": "public function getRawResponse()\n\t{\n\t\treturn $this->_response->getBody();\n\t}", "title": "" }, { "docid": "e0f2e1f078235e094e1e8c4930bbc9ef", "score": "0.7502585", "text": "public function getRawResponse(): string\n {\n return $this->_response;\n }", "title": "" }, { "docid": "dec53991e5cd2adcd40a21a6e451e764", "score": "0.748635", "text": "public function getRawBody()\n {\n return $this->getResponse()->raw_body;\n }", "title": "" }, { "docid": "5ece3e08e28181fc4499b020795896d6", "score": "0.74751014", "text": "public function getBody()\n\t{\n\t\treturn $this->responseBody;\n\t}", "title": "" }, { "docid": "0abc966e46e809837292408e64e8e78d", "score": "0.7448505", "text": "public function getResponseBody()\n {\n return $this->response->getBody()->getContents();\n }", "title": "" }, { "docid": "e4e774fa66a053e98a46da931ba0b805", "score": "0.7399138", "text": "public function getResponseBody()\n\t{\n\t\treturn $this->body;\n\t}", "title": "" }, { "docid": "72cdaf2a662b2d3f0a9d7412df57e8c4", "score": "0.73866266", "text": "public function getResponseBody()\n {\n return $this->respBody;\n }", "title": "" }, { "docid": "026725292c9a36908e08f325a46ca772", "score": "0.73558986", "text": "public function getRawResponse()\n {\n return $this->rawBody;\n }", "title": "" }, { "docid": "a0926af7e66fdfd13f303c2dfd0afc0f", "score": "0.7338664", "text": "public function toString()\n {\n return (string) $this->getBody();\n }", "title": "" }, { "docid": "87ea7d6351547343ed694a8e330274b4", "score": "0.7326307", "text": "public function getResponseBody(){\n\t\treturn $this->_body;\n\t}", "title": "" }, { "docid": "259a544dcc8b0027189b842994af5a11", "score": "0.7324781", "text": "public function getResponseBody()\n {\n return $this->responseBody;\n }", "title": "" }, { "docid": "259a544dcc8b0027189b842994af5a11", "score": "0.7324781", "text": "public function getResponseBody()\n {\n return $this->responseBody;\n }", "title": "" }, { "docid": "259a544dcc8b0027189b842994af5a11", "score": "0.7324781", "text": "public function getResponseBody()\n {\n return $this->responseBody;\n }", "title": "" }, { "docid": "259a544dcc8b0027189b842994af5a11", "score": "0.7324781", "text": "public function getResponseBody()\n {\n return $this->responseBody;\n }", "title": "" }, { "docid": "259a544dcc8b0027189b842994af5a11", "score": "0.7324781", "text": "public function getResponseBody()\n {\n return $this->responseBody;\n }", "title": "" }, { "docid": "259a544dcc8b0027189b842994af5a11", "score": "0.7324781", "text": "public function getResponseBody()\n {\n return $this->responseBody;\n }", "title": "" }, { "docid": "259a544dcc8b0027189b842994af5a11", "score": "0.7324781", "text": "public function getResponseBody()\n {\n return $this->responseBody;\n }", "title": "" }, { "docid": "259a544dcc8b0027189b842994af5a11", "score": "0.7324781", "text": "public function getResponseBody()\n {\n return $this->responseBody;\n }", "title": "" }, { "docid": "259a544dcc8b0027189b842994af5a11", "score": "0.7324781", "text": "public function getResponseBody()\n {\n return $this->responseBody;\n }", "title": "" }, { "docid": "79a92a973ee4efdbd2da798daa0e14de", "score": "0.7288119", "text": "public function getBody() : string\n {\n return $this->body;\n }", "title": "" }, { "docid": "27d48c7c76dba521e01aec55505a299e", "score": "0.7269243", "text": "function getBody() {\n\t\treturn $this->couch_response['body'];\n\t}", "title": "" }, { "docid": "5e79e07a25e7fcb86d944caf0b108953", "score": "0.7268016", "text": "public function getBody(): string\n {\n return $this->body;\n }", "title": "" }, { "docid": "5e79e07a25e7fcb86d944caf0b108953", "score": "0.7268016", "text": "public function getBody(): string\n {\n return $this->body;\n }", "title": "" }, { "docid": "c505058bfb8680f0f148d451d9f24d51", "score": "0.7215858", "text": "public function getBody()\n {\n //added by fcheslack - curl adapter handles these things already so they are transparent to Zend_Response\n return $this->getRawBody();\n \n \n $body = '';\n\n // Decode the body if it was transfer-encoded\n switch (strtolower($this->getHeader('transfer-encoding'))) {\n\n // Handle chunked body\n case 'chunked':\n $body = self::decodeChunkedBody($this->body);\n break;\n\n // No transfer encoding, or unknown encoding extension:\n // return body as is\n default:\n $body = $this->body;\n break;\n }\n\n // Decode any content-encoding (gzip or deflate) if needed\n switch (strtolower($this->getHeader('content-encoding'))) {\n\n // Handle gzip encoding\n case 'gzip':\n $body = self::decodeGzip($body);\n break;\n\n // Handle deflate encoding\n case 'deflate':\n $body = self::decodeDeflate($body);\n break;\n\n default:\n break;\n }\n\n return $body;\n }", "title": "" }, { "docid": "0d3b7933dbcc22f93fd8a258601b48c5", "score": "0.72100765", "text": "public function getResponseBody()\r\n {\r\n return $this->rawResponse;\r\n }", "title": "" }, { "docid": "aec860692794775675800f9991dbc111", "score": "0.7201128", "text": "public function getResponseBodyRaw()\n\t{\n\t\treturn $this->raw_body;\n\t}", "title": "" }, { "docid": "b07f7ceec56fef83e50daf952d651c7a", "score": "0.7185641", "text": "protected function getResponseContent()\n {\n return $this->getResponse()->getBody()->getContents();\n }", "title": "" }, { "docid": "182d98324a90fe16d784518ed58828bd", "score": "0.7176087", "text": "public function getBody(): ?string\n {\n if ($this->isTimedOut()) {\n return '<REQUEST_TIMED_OUT : THIS MESSAGE WAS ADDED BY REQUEST INSURANCE>';\n }\n\n if ($this->isInconsistent()) {\n return '<REQUEST_INCONSISTENT : THIS MESSAGE WAS ADDED BY REQUEST INSURANCE>';\n }\n\n return $this->response->getBody()->getContents();\n }", "title": "" }, { "docid": "ee4e71a9dd28a17a0319705f90de6fe3", "score": "0.7172439", "text": "public function getPlainResponse()\n {\n return $this->response;\n }", "title": "" }, { "docid": "7007e75cad48a533e1b9f89c24115792", "score": "0.71263367", "text": "public function getResponseBody()\n {\n return $this->httpResponse;\n }", "title": "" }, { "docid": "3effd9725a92a63f9bc187a31787b986", "score": "0.7125195", "text": "public function getBody(): string;", "title": "" }, { "docid": "0384a020c2fc736e20e563b7de6c95a8", "score": "0.7124372", "text": "public function getBody(): string {\n\t\treturn $this->body;\n\t}", "title": "" }, { "docid": "e5d661ff3c7115a2a7da962f51fb3764", "score": "0.70781446", "text": "public function getBody()\n {\n return $this->handle($this->response);\n }", "title": "" }, { "docid": "b22d8b685db0edeb6d66a223220b03a0", "score": "0.7067344", "text": "public function getResponseBody() {\n\t\tisset($this->outputContents) or $this->outputContents = stream_get_contents($this->getResponseBodyStream());\n\t\treturn $this->outputContents;\n\t}", "title": "" }, { "docid": "81888a02e0df895f52dcc627898d5285", "score": "0.70613396", "text": "public function getRawBody(): string\n {\n return '';\n }", "title": "" }, { "docid": "dab58b1d7d7ed7cc60af059a85097209", "score": "0.703522", "text": "public function getBody() : string;", "title": "" }, { "docid": "000e33d8869b2dede8e87f021f8f5fd3", "score": "0.7015358", "text": "public function getBody()\n\t{\n\t\t$body = '';\n\n\t\tif($this->getDataValue('body'))\n\t\t{\n\t\t\t$body = $this->getDataValue('body');\n\t\t}\n\n\t\treturn $body;\n\t}", "title": "" }, { "docid": "8575cc7648f5baa18237601e5f55050f", "score": "0.7014051", "text": "final public function __toString()\n {\n if(is_string($this->getBody()))\n return $this->getBody();\n }", "title": "" }, { "docid": "59bef1081a261e05660532622f4c36a0", "score": "0.6993923", "text": "function getResponseBody()\n {\n return isset($this->_response->_body) ? $this->_response->_body : false;\n }", "title": "" }, { "docid": "fc6ff7b56d037fb809c59b1c29e0e870", "score": "0.6980598", "text": "public function getResponseBody() {\n return json_encode($this->data);\n }", "title": "" }, { "docid": "0dff93c9a72d8731b865672335bad0a8", "score": "0.6960911", "text": "public function getBody()\n {\n $body = '';\n\n // Decode the body if it was transfer-encoded\n switch (strtolower((string) $this->getHeader('transfer-encoding'))) {\n\n // Handle chunked body\n case 'chunked':\n $body = self::decodeChunkedBody($this->body);\n break;\n\n // No transfer encoding, or unknown encoding extension:\n // return body as is\n default:\n $body = $this->body;\n break;\n }\n\n // Decode any content-encoding (gzip or deflate) if needed\n switch (strtolower((string) $this->getHeader('content-encoding'))) {\n\n // Handle gzip encoding\n case 'gzip':\n $body = self::decodeGzip($body);\n break;\n\n // Handle deflate encoding\n case 'deflate':\n $body = self::decodeDeflate($body);\n break;\n\n default:\n break;\n }\n\n return $body;\n }", "title": "" }, { "docid": "18528362eac931253cef90b944afcfd2", "score": "0.6918478", "text": "public function __toString()\n\t{\n\t\treturn $this->getBody()->getContents();\n\t}", "title": "" }, { "docid": "2eb4b2df77b9bcdb210885f89c4b8dd2", "score": "0.6918352", "text": "public function getResponseJsonBody()\r\n {\r\n return $this->rawResponse;\r\n }", "title": "" }, { "docid": "092fd04e849217d2a814f2d257490607", "score": "0.6911783", "text": "protected function body(\\GuzzleHttp\\Psr7\\Response $email)\n {\n return str_replace([\"=\\r\\n\", \"\\r\\n\"], ['', PHP_EOL], $this->jsonEmail($email)->source);\n }", "title": "" }, { "docid": "b8cc221379ed77fb8dc72feb40ddecb3", "score": "0.6902324", "text": "public function getResponseString()\n\t{\n\n\t\treturn $this->output;\n\t}", "title": "" }, { "docid": "cc926f13dd164c074f59f5c14f7bb9aa", "score": "0.688297", "text": "public function get_body() {\n\t\treturn $this->body;\n\t}", "title": "" }, { "docid": "36b61a5bd0bcbaa506d52d64ae6a5fe0", "score": "0.68472964", "text": "public function __toString()\n {\n return $this->body;\n }", "title": "" }, { "docid": "ea77026ef8aeedacf1edb199b9c6753e", "score": "0.6844519", "text": "public function getRawBody();", "title": "" }, { "docid": "abc33df0e7000aaafa9a09aa0112d7f6", "score": "0.6838512", "text": "public function __toString() {\n\t\t$body = $this -> getBody() -> __toString();\n\n\t\treturn $body;\n\t}", "title": "" }, { "docid": "dd7ccc71b1773f48fe9dce611c592570", "score": "0.68326896", "text": "public function getRawBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "dd7ccc71b1773f48fe9dce611c592570", "score": "0.68326896", "text": "public function getRawBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "16b42522bd8ed51a7fc54ff023280664", "score": "0.68189776", "text": "public function getPageBody(): string\n {\n return $this->body;\n }", "title": "" }, { "docid": "df532b251542059727e4718b933fcbb2", "score": "0.6802525", "text": "public function getBody(): string\n {\n if (!$this->body) {\n return '';\n }\n return container_resolve(ScopedLoaderInterface::class)->output($this->body);\n }", "title": "" }, { "docid": "350b1ba662432007d45d8ceefe191194", "score": "0.67873925", "text": "public function\t\t\t\t\t\tto_string() {\n\n\t\t$headers='';\n\t\tforeach($this->headers as $k => $v) {\n\t\t\t$headers.=$k.':'.$v.PHP_EOL;\n\t\t}\n\n\t\treturn <<<R\n{$this->status}\n{$headers}\n{$this->body_to_string()}\nR;\n\t}", "title": "" }, { "docid": "95459b02981d129fccd7996af47fdf5e", "score": "0.67436236", "text": "public function getBody() {}", "title": "" }, { "docid": "c42cfa1265dca10407aaeb278c4acf4f", "score": "0.6734808", "text": "public function getResponse(): string\n {\n return $this->api->getResponse();\n }", "title": "" }, { "docid": "cc552456c57586f563c489d192109180", "score": "0.6730927", "text": "public function getRawBody()\n {\n return $this->content;\n }", "title": "" }, { "docid": "69d011b5695887698bd2dbfd208edbb9", "score": "0.6729018", "text": "public function body()\n {\n return $this->body;\n }", "title": "" }, { "docid": "ecfb1ffa3ff8cbd948711880f248281c", "score": "0.6719541", "text": "protected function getBodyData(Psr\\ResponseInterface $response): string\n {\n return (string) $response->getBody();\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "bf2f6ebe17a35be3689482bb72fc0c2a", "score": "0.67144454", "text": "public function getBody()\n {\n return $this->body;\n }", "title": "" }, { "docid": "dbf18bf14f26198ede6016d776ad19a6", "score": "0.67136097", "text": "public function getOriginalBodyContents()\n {\n return $this->response->getBody()->getContents();\n }", "title": "" }, { "docid": "7b92da1cbbc25284fe2bc586579fa211", "score": "0.6708335", "text": "public function getCurlResponseBody()\n {\n return $this->getCurlResponse()['response_body'];\n }", "title": "" }, { "docid": "7f7792ffd551a2c568ce7b64aab3aaa2", "score": "0.670767", "text": "public function getRawResponse()\n\t{\n\t\treturn $this->raw_response;\n\t}", "title": "" }, { "docid": "df0c69078459088e3e8bf17eff2b33c2", "score": "0.66916394", "text": "public function getLastResponseBody(): string\n {\n return (string) $this->responseBodyMock;\n }", "title": "" }, { "docid": "ecb874a0e31fff4ec06b7be819cf42bf", "score": "0.6682706", "text": "function __toString() {\n return $this->body;\n }", "title": "" }, { "docid": "e6f5ff01aaf9fd60e3979b5e106ca635", "score": "0.6680641", "text": "public function getBody();", "title": "" }, { "docid": "e6f5ff01aaf9fd60e3979b5e106ca635", "score": "0.6680641", "text": "public function getBody();", "title": "" }, { "docid": "e6f5ff01aaf9fd60e3979b5e106ca635", "score": "0.6680641", "text": "public function getBody();", "title": "" }, { "docid": "e6f5ff01aaf9fd60e3979b5e106ca635", "score": "0.6680641", "text": "public function getBody();", "title": "" }, { "docid": "e6f5ff01aaf9fd60e3979b5e106ca635", "score": "0.6680641", "text": "public function getBody();", "title": "" }, { "docid": "e6f5ff01aaf9fd60e3979b5e106ca635", "score": "0.6680641", "text": "public function getBody();", "title": "" }, { "docid": "e6f5ff01aaf9fd60e3979b5e106ca635", "score": "0.6680641", "text": "public function getBody();", "title": "" } ]
a51b9cb077edd5add1d943ff389f0614
Create request for operation 'getAnOrder'
[ { "docid": "69c38695771e4542858613e31908264d", "score": "0.5527629", "text": "protected function getAnOrderRequest(\n string $purchaseOrderId,\n ?string $productInfo = 'false',\n ?string $replacementInfo = 'false',\n ): Request {\n $contentType = self::contentTypes['getAnOrder'];\n\n // verify the required parameter 'purchaseOrderId' is set\n if ($purchaseOrderId === null || (is_array($purchaseOrderId) && count($purchaseOrderId) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $purchaseOrderId when calling getAnOrder'\n );\n }\n $resourcePath = '/v3/orders/{purchaseOrderId}';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n $method = 'GET';\n\n // query params\n $queryParams = array_merge(\n ObjectSerializer::toQueryValue(\n $productInfo,\n 'productInfo', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $replacementInfo,\n 'replacementInfo', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n );\n\n // path params\n if ($purchaseOrderId !== null) {\n $resourcePath = str_replace(\n '{' . 'purchaseOrderId' . '}',\n ObjectSerializer::toPathValue($purchaseOrderId),\n $resourcePath\n );\n }\n\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n $contentType,\n $multipart\n );\n\n $defaultHeaders = parent::getDefaultHeaders();\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n // for model (json/xml)\n if (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue];\n foreach ($formParamValueItems as $formParamValueItem) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValueItem\n ];\n }\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n } elseif (stripos($headers['Content-Type'], 'application/json') !== false) {\n # if Content-Type contains \"application/json\", json_encode the form parameters\n $httpBody = \\GuzzleHttp\\Utils::jsonEncode($formParams);\n } else {\n // for HTTP post (form)\n $httpBody = ObjectSerializer::buildQuery($formParams);\n }\n }\n\n $query = ObjectSerializer::buildQuery($queryParams);\n $requestInfo = [\n 'path' => $resourcePath,\n 'method' => $method,\n 'timestamp' => $defaultHeaders['WM_SEC.TIMESTAMP'],\n 'query' => $query,\n ];\n\n // this endpoint requires Bearer authentication (access token)\n $token = $this->config->getAccessToken();\n if ($token) {\n $headers['WM_SEC.ACCESS_TOKEN'] = $token->accessToken;\n }\n\n $operationHost = $this->config->getHost();\n return new Request(\n $method,\n $operationHost . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" } ]
[ { "docid": "2718e9d94a5f74dcf4c05b6fc6c4c2aa", "score": "0.7159164", "text": "public function request()\n {\n return new GuzzleHttp\\Psr7\\Request(\n 'GET',\n 'Persons/'.$this->personId.'/Orders/'.$this->orderId\n );\n }", "title": "" }, { "docid": "d8a6e643db5803e9c00e627c72f11106", "score": "0.71147", "text": "public function request()\n {\n return new Request(\n 'POST',\n 'Persons/'.$this->order->getCustomer()->getIdentifiers()->get('ap21_id').'/Orders',\n [],\n (new OrderSerializer)->serialize($this->order)\n );\n }", "title": "" }, { "docid": "70e235c82e813654cedc25ae1ddf912b", "score": "0.6813764", "text": "public function getOrder($request)\n {\n return GetOrderResponse::fromXML($this->_invoke('GetOrder'));\n }", "title": "" }, { "docid": "4564e79d8bdda42eea94c772da3665bd", "score": "0.6803308", "text": "public function createOrder()\n {\n $createService = new CreateOrderService($this);\n\n return $createService->doRequest();\n }", "title": "" }, { "docid": "dbf52a5ebfda269809bc52abe30c19a0", "score": "0.65148914", "text": "public function getOrder()\n {\n $getOrderService = new GetOrderService($this);\n\n return $getOrderService->doRequest();\n }", "title": "" }, { "docid": "50c8d53be0dba23c7026034dc141a18b", "score": "0.6463996", "text": "public function getOrder(Request $request) \n {\n $order = Order::findOrFail($request->id);\n $order->unformated_order_date = $order->getRawOriginal('order_date');\n $order->products;\n return response()->json(['order' => $order ]);\n }", "title": "" }, { "docid": "c3a83cd409d229e95f194a253f11dc72", "score": "0.64590746", "text": "public function statusorder_get(){\r\n $dataSO = $this->App_model->gen3();\r\n $this->response($dataSO, REST_Controller::HTTP_OK);\r\n }", "title": "" }, { "docid": "7ab56bf418659109db1da32088fa67fe", "score": "0.64432424", "text": "function getOrderbyId_get(){\n $id=$this->get('id');\n $result=$this->order_model->getOrderbyId($id);\n $this->response($result,200);\n}", "title": "" }, { "docid": "b946ab76139581092f51178e73e0e48e", "score": "0.6417909", "text": "public function index(OrderGetRequest $request){\n \t$arr = $request->all();\n $res = $this->orderrepo->getAll($arr);\n return $res->items(); \n }", "title": "" }, { "docid": "987f5b00357dd21170a4ab8808f8a96a", "score": "0.64061534", "text": "public function serviceOrderGet($order_id) {\n $orders = \\Drupal::state()->get('tmgmt_mygengo_test_orders', array());\n if (isset($orders[$order_id])) {\n $order = (object) array(\n 'order_id' => $order_id,\n 'jobs_available' => array(),\n 'jobs_queued' => 0,\n 'total_jobs' => count($orders[$order_id]),\n );\n foreach ($orders[$order_id] as $job) {\n $order->jobs_available[] = $job['job_id'];\n }\n return new JsonResponse(array(\n 'opstat' => 'ok',\n 'response' => array('order' => $order),\n ));\n }\n return new JsonResponse(array(\n 'opstat' => 'error',\n 'err' => array('code' => 123, 'msg' => 'Order id ' . $order_id . ' does not exist'),\n ));\n }", "title": "" }, { "docid": "c7a6447e7b4b9146873b1e972a192c49", "score": "0.6398842", "text": "public function getOrder(WP_REST_Request $request) {\n\t\ttry {\n\t\t\t$this->checkAuth($request);\n\t\t\t$params = $request->get_params();\n\t\t\treturn $this->generateOutput($this->orders->getOrder($params['order_id']));\n\t\t}\n\t\tcatch (Exception $e) {\n\t\t\treturn $this->handleError($e);\n\t\t}\n\t}", "title": "" }, { "docid": "fcf63f604297801470415c93d4de8d47", "score": "0.6317748", "text": "public function getOrder(array $data = []): \\CityService\\ResponseInterface\n {\n }", "title": "" }, { "docid": "cce20f45c830381abdc9e6c3024589af", "score": "0.6242319", "text": "public function createOrder()\n {\n try {\n return response()->json($this->smartButton->createOrder($this->buildRequestBody()));\n } catch (\\Exception $e) {\n throw $e;\n }\n }", "title": "" }, { "docid": "1e627012c8689e8b087e5668fa0ef926", "score": "0.61973745", "text": "public function createOrder($order)\n {\n if ($order instanceof \\Fulfillment\\OMS\\Models\\Request\\Order && $this->validateRequests) {\n $order->validate();\n }\n\n $orderJson = $this->apiClient->post('orders', $order);\n\n if ($this->jsonOnly) {\n $returnOrder = $orderJson;\n } else {\n $returnOrder = $this->jsonMapper->map($orderJson, $this->container->get(ResponseOrderContract::class));\n }\n\n return $returnOrder;\n }", "title": "" }, { "docid": "38c4fa4729d7413d20363c1b41379413", "score": "0.612858", "text": "protected function getOrdersRequest($limit = '100', $offset = '0', $embed = null)\n {\n\n $resourcePath = '/Order';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n // query params\n if ($limit !== null) {\n $queryParams['limit'] = ObjectSerializer::toQueryValue($limit);\n }\n // query params\n if ($offset !== null) {\n $queryParams['offset'] = ObjectSerializer::toQueryValue($offset);\n }\n // query params\n if (is_array($embed)) {\n $embed = ObjectSerializer::serializeCollection($embed, 'csv', true);\n }\n if ($embed !== null) {\n $queryParams['embed'] = ObjectSerializer::toQueryValue($embed);\n }\n\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/xml', 'application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/xml', 'application/json'],\n ['application/x-www-form-urlencoded']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass && $headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('token');\n if ($apiKey !== null) {\n $queryParams['token'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "657b8fb2773bc67a0c024d5581995e49", "score": "0.6079154", "text": "public function getOrder(int $orderId): Order;", "title": "" }, { "docid": "79a3366dbefaf906c2d62a37fcd2bde0", "score": "0.6075364", "text": "protected function getOmsOrderByIdRequest($oms_order_id)\n {\n // verify the required parameter 'oms_order_id' is set\n if ($oms_order_id === null) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $oms_order_id when calling getOmsOrderById'\n );\n }\n\n $resourcePath = '/beta/omsOrder/{omsOrderId}';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n // path params\n if ($oms_order_id !== null) {\n $resourcePath = str_replace(\n '{' . 'omsOrderId' . '}',\n ObjectSerializer::toPathValue($oms_order_id),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n []\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass && $headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('API-Key');\n if ($apiKey !== null) {\n $headers['API-Key'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "f55d43bd4be315f122a4ecc03e71210e", "score": "0.6067002", "text": "public function getOrderAction()\n {\n if (!$this->request->isAjax() || !$this->request->isGet()) {\n return;\n }\n\n return\n $this->returnJSON([\n 'ordering' => $this->getOrdering($_GET['position'], $_GET['id']),\n 'success' => true\n ]);\n }", "title": "" }, { "docid": "42944beb04f4b1e0ba22be2d9bc1fbe3", "score": "0.6057242", "text": "public function testGetListOfOrdersUsingGET()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "title": "" }, { "docid": "ebb662314b62b41511adfc9545482c4a", "score": "0.6057171", "text": "protected function apiCustomersGetRequest($visible = null, $order = null, $order_by = null, $term = null)\n {\n if ($visible !== null && !preg_match('/\\\\d+/', $visible)) {\n throw new \\InvalidArgumentException('invalid value for \"visible\" when calling DefaultApi.apiCustomersGet, must conform to the pattern /\\\\d+/.');\n }\n\n if ($order !== null && !preg_match('/ASC|DESC/', $order)) {\n throw new \\InvalidArgumentException('invalid value for \"order\" when calling DefaultApi.apiCustomersGet, must conform to the pattern /ASC|DESC/.');\n }\n\n if ($order_by !== null && !preg_match('/id|name/', $order_by)) {\n throw new \\InvalidArgumentException('invalid value for \"order_by\" when calling DefaultApi.apiCustomersGet, must conform to the pattern /id|name/.');\n }\n\n if ($term !== null && !preg_match('/[a-zA-Z0-9 \\\\-,:]+/', $term)) {\n throw new \\InvalidArgumentException('invalid value for \"term\" when calling DefaultApi.apiCustomersGet, must conform to the pattern /[a-zA-Z0-9 \\\\-,:]+/.');\n }\n\n $resourcePath = '/api/customers';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n // query params\n if ($visible !== null) {\n $queryParams['visible'] = ObjectSerializer::toQueryValue($visible);\n }\n // query params\n if ($order !== null) {\n $queryParams['order'] = ObjectSerializer::toQueryValue($order);\n }\n // query params\n if ($order_by !== null) {\n $queryParams['orderBy'] = ObjectSerializer::toQueryValue($order_by);\n }\n // query params\n if ($term !== null) {\n $queryParams['term'] = ObjectSerializer::toQueryValue($term);\n }\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n []\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n [],\n []\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n\n if ($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if (is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('X-AUTH-TOKEN');\n if ($apiKey !== null) {\n $headers['X-AUTH-TOKEN'] = $apiKey;\n }\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('X-AUTH-USER');\n if ($apiKey !== null) {\n $headers['X-AUTH-USER'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "52c868a69abf761a8d286b659445d411", "score": "0.605543", "text": "public function SetOrderCreate(\\stdClass $request): DTO {\n }", "title": "" }, { "docid": "21e1b435a497c9d028a66986935cc614", "score": "0.6031051", "text": "public static function getAll()\n {\n return self::fromResponse(self::request('GET', 'order'));\n }", "title": "" }, { "docid": "92fd45e3c160bf1e552222d0f68d834d", "score": "0.6028654", "text": "protected function getAnOrderRequest($accept, $content_type, $order_id, $body = null)\n {\n // verify the required parameter 'accept' is set\n if ($accept === null || (is_array($accept) && count($accept) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $accept when calling getAnOrder'\n );\n }\n // verify the required parameter 'content_type' is set\n if ($content_type === null || (is_array($content_type) && count($content_type) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $content_type when calling getAnOrder'\n );\n }\n // verify the required parameter 'order_id' is set\n if ($order_id === null || (is_array($order_id) && count($order_id) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $order_id when calling getAnOrder'\n );\n }\n\n $resourcePath = '/orders/{order_id}';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n // header params\n if ($accept !== null) {\n $headerParams['Accept'] = ObjectSerializer::toHeaderValue($accept);\n }\n // header params\n if ($content_type !== null) {\n $headerParams['Content-Type'] = ObjectSerializer::toHeaderValue($content_type);\n }\n\n // path params\n if ($order_id !== null) {\n $resourcePath = str_replace(\n '{' . 'order_id' . '}',\n ObjectSerializer::toPathValue($order_id),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n if (isset($body)) {\n $_tempBody = $body;\n }\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json', 'Multiple Items']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json', 'Multiple Items'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass && $headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('X-Auth-Client');\n if ($apiKey !== null) {\n $headers['X-Auth-Client'] = $apiKey;\n }\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('X-Auth-Token');\n if ($apiKey !== null) {\n $headers['X-Auth-Token'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "cc9a00e81051bbf9d0b0a0e1e31fae9c", "score": "0.6008571", "text": "public function getOrders();", "title": "" }, { "docid": "437a86859c6180b54df66dac978a98d1", "score": "0.59989804", "text": "public function show(OrderDetailRequest $request, Order $order)\n {\n return new OrderResource($order);\n }", "title": "" }, { "docid": "351a024713ae9142be58d7fa2202aa8f", "score": "0.5994315", "text": "protected function get_order_from_request() {\n /*\n if ( ! isset( $_GET['nonce'] ) || ! wp_verify_nonce( $_GET['nonce'], 'dokan_stripe_confirm_pi' ) ) {\n throw new DokanException( 'missing-nonce', __( 'CSRF verification failed.', 'dokan' ) );\n }\n */\n\n $order_id = null;\n\n if ( isset( $_GET['order'] ) ) {\n $order_id = absint( wp_unslash( $_GET['order'] ) );\n }\n\n $order = wc_get_order( $order_id );\n\n if ( ! $order ) {\n throw new DokanException( 'missing-order', __( 'Missing order ID for payment confirmation', 'dokan' ) );\n }\n\n if ( ! isset( $_GET['key'] ) || $order->get_order_key() !== sanitize_text_field( wp_unslash( $_GET['key'] ) ) ) {\n throw new DokanException( 'missing-order-key', __( 'Invalid order id. Please try again.', 'dokan' ) );\n }\n\n return $order;\n }", "title": "" }, { "docid": "ef9d47a4b6e3131759f4d72c3b2d30b7", "score": "0.59839356", "text": "public function getOrder($order_no)\n\t{\n\t\treturn $this->send(\"/v4/orders/\".$order_no, [\n\t\t\t'method' => 'GET',\n\t\t]);\n\t}", "title": "" }, { "docid": "2b39696186160240c43852c9afce96ff", "score": "0.59820116", "text": "public function create()\n {\n $order = new Order();\n $data = [\n 'order' => $order,\n ];\n return response()->json($data);\n }", "title": "" }, { "docid": "458a9db3cf02382f3797e7fe96f23cb1", "score": "0.59672827", "text": "public function getOrderById(int $id);", "title": "" }, { "docid": "72bb64ab07ad0d4bca4ae4dcc6cd24c7", "score": "0.59378463", "text": "public function getOrderEndpoint() {\n\n\t\treturn $this->restUrl.'distribution-api/orders/';\n\n\t}", "title": "" }, { "docid": "c56217306f281acc7bbd2f989b242861", "score": "0.58949757", "text": "public function createPaymentRequest($order)\n {\n $storeId = $order->getStoreId();\n $minorUnits = $this->_bamboraHelper->getCurrencyMinorUnits(\n $order->getBaseCurrencyCode()\n );\n $roundingMode = $this->getConfigData(\n BamboraConstants::ROUNDING_MODE,\n $storeId\n );\n $totalAmountMinorUnits = $this->_bamboraHelper->convertPriceToMinorunits(\n $order->getBaseTotalDue(),\n $minorUnits,\n $roundingMode\n );\n $checkoutRequest = $this->_bamboraHelper->getCheckoutApiModel(\n CheckoutApiModels::REQUEST_CHECKOUT\n );\n $checkoutRequest->instantcaptureamount = $this->_bamboraHelper->getBamboraCheckoutConfigData(\n BamboraConstants::INSTANT_CAPTURE,\n $storeId\n ) == 0 ? 0 : $totalAmountMinorUnits;\n $checkoutRequest->language = $this->_bamboraHelper->getFormattedShopLocalCode(\n );\n $checkoutRequest->paymentwindowid = $this->getConfigData(\n BamboraConstants::PAYMENT_WINDOW_ID,\n $storeId\n );\n $bamboraOrder = $this->_bamboraHelper->getCheckoutApiModel(\n CheckoutApiModels::REQUEST_MODEL_ORDER\n );\n $bamboraOrder->currency = $order->getBaseCurrencyCode();\n $bamboraOrder->ordernumber = $order->getIncrementId();\n $bamboraOrder->total = $totalAmountMinorUnits;\n $bamboraOrder->vatamount = $this->_bamboraHelper->convertPriceToMinorunits(\n $order->getBaseTaxAmount(),\n $minorUnits,\n $roundingMode\n );\n $bamboraUrl = $this->_bamboraHelper->getCheckoutApiModel(\n CheckoutApiModels::REQUEST_MODEL_URL\n );\n $bamboraUrl->accept = $this->_urlBuilder->getUrl(\n 'bambora/checkout/accept',\n ['_secure' => $this->_request->isSecure()]\n );\n $bamboraUrl->decline = $this->_urlBuilder->getUrl(\n 'bambora/checkout/cancel',\n ['_secure' => $this->_request->isSecure()]\n );\n $bamboraCallback = $this->_bamboraHelper->getCheckoutApiModel(\n CheckoutApiModels::REQUEST_MODEL_CALLBACK\n );\n $bamboraCallback->url = $this->_urlBuilder->getUrl(\n 'bambora/checkout/callback',\n ['_secure' => $this->_request->isSecure()]\n );\n $bamboraUrl->callbacks = [];\n $bamboraUrl->callbacks[] = $bamboraCallback;\n $bamboraUrl->immediateredirecttoaccept = $this->_bamboraHelper->getBamboraCheckoutConfigData(\n BamboraConstants::IMMEDIATEREDI_REDIRECT_TO_ACCEPT,\n $storeId\n );\n $checkoutRequest->url = $bamboraUrl;\n\n $billingAddress = $order->getBillingAddress();\n if ($billingAddress) {\n $bamboraCustomer = $this->_bamboraHelper->getCheckoutApiModel(\n CheckoutApiModels::REQUEST_MODEL_CUSTOMER\n );\n $bamboraCustomer->phonenumber = $billingAddress->getTelephone();\n $bamboraCustomer->phonenumbercountrycode = $billingAddress->getCountryId(\n );\n if ($billingAddress->getEmail()) {\n $bamboraCustomer->email = $billingAddress->getEmail();\n } else {\n $bamboraCustomer->email = $order->getCustomerEmail();\n }\n $checkoutRequest->customer = $bamboraCustomer;\n\n $bamboraBillingAddress = $this->_bamboraHelper->getCheckoutApiModel(\n CheckoutApiModels::REQUEST_MODEL_ADDRESS\n );\n $bamboraBillingAddress->att = \"\";\n $bamboraBillingAddress->city = $billingAddress->getCity();\n $bamboraBillingAddress->country = $billingAddress->getCountryId();\n $bamboraBillingAddress->firstname = $billingAddress->getFirstname();\n $bamboraBillingAddress->lastname = $billingAddress->getLastname();\n $bamboraBillingAddress->street = $billingAddress->getStreet()[0];\n $bamboraBillingAddress->zip = $billingAddress->getPostcode();\n\n $bamboraOrder->billingaddress = $bamboraBillingAddress;\n }\n\n $shippingAddress = $order->getShippingAddress();\n if (!$shippingAddress) {\n $shippingAddress = $billingAddress;\n }\n\n if ($shippingAddress) {\n $bamboraShippingAddress = $this->_bamboraHelper->getCheckoutApiModel(\n CheckoutApiModels::REQUEST_MODEL_ADDRESS\n );\n $bamboraShippingAddress->att = \"\";\n $bamboraShippingAddress->city = $shippingAddress->getCity();\n $bamboraShippingAddress->country = $shippingAddress->getCountryId();\n $bamboraShippingAddress->firstname = $shippingAddress->getFirstname();\n $bamboraShippingAddress->lastname = $shippingAddress->getLastname();\n $bamboraShippingAddress->street = $shippingAddress->getStreet()[0];\n $bamboraShippingAddress->zip = $shippingAddress->getPostcode();\n\n $bamboraOrder->shippingaddress = $bamboraShippingAddress;\n }\n\n $bamboraOrderLines = [];\n\n $items = $order->getAllVisibleItems();\n $lineNumber = 1;\n foreach ($items as $item) {\n $itemName = $item->getName();\n $itemDescription = $item->getDescription();\n $bamboraOrderLines[] = $this->createInvoiceLine(\n empty($itemName) ? $itemDescription : $itemName,\n $item->getSku(),\n $lineNumber,\n floatval($item->getQtyOrdered()),\n empty($itemDescription) ? $itemName : $itemDescription,\n $item->getBaseRowTotal(),\n $item->getBaseTaxAmount(),\n $order->getBaseCurrencyCode(),\n $roundingMode,\n $item->getTaxPercent(),\n $item->getBaseDiscountAmount()\n );\n\n $lineNumber++;\n }\n\n //Add shipping line\n $baseShippingAmount = $order->getBaseShippingAmount();\n if ($baseShippingAmount > 0) {\n $shippingDescription = $order->getShippingDescription();\n $shipmentOrderLine = $this->createInvoiceLine(\n $shippingDescription,\n __(\"Shipping\"),\n $lineNumber,\n 1,\n $shippingDescription,\n $baseShippingAmount,\n $order->getBaseShippingTaxAmount(),\n $order->getBaseCurrencyCode(),\n $roundingMode\n );\n\n $bamboraOrderLines[] = $shipmentOrderLine;\n $lineNumber++;\n }\n\n // Fix for bug in Magento 2 shipment discount calculation\n $baseShipmentDiscountAmount = $order->getBaseShippingDiscountAmount();\n if ($baseShipmentDiscountAmount > 0) {\n $shippingDiscuntText = __(\"Shipping discount\");\n $shipmentDiscountOrderLine = $this->createInvoiceLine(\n $shippingDiscuntText,\n \"shipping_discount\",\n $lineNumber,\n 1,\n $shippingDiscuntText,\n $baseShipmentDiscountAmount * -1,\n 0,\n $order->getBaseCurrencyCode(),\n $roundingMode\n );\n\n $bamboraOrderLines[] = $shipmentDiscountOrderLine;\n }\n $bamboraOrder->lines = $bamboraOrderLines;\n $checkoutRequest->order = $bamboraOrder;\n\n if ($this->_bamboraHelper->getBamboraCheckoutConfigData(\n BamboraConstants::ALLOW_LOW_VALUE_EXEMPTION\n )) {\n if ($checkoutRequest->order->total < $this->_bamboraHelper->convertPriceToMinorunits(\n $this->_bamboraHelper->getBamboraCheckoutConfigData(\n BamboraConstants::LIMIT_LOW_VALUE_EXEMPTION\n ),\n $minorUnits,\n $roundingMode\n )) {\n $checkoutRequest->securityexemption = \"lowvaluepayment\";\n $checkoutRequest->securitylevel = \"none\";\n }\n }\n\n return $checkoutRequest;\n }", "title": "" }, { "docid": "e0ed00b0ac75f5915e72c5526bbdde82", "score": "0.58910716", "text": "public static function createFromOrder(array $order)\n {\n $request = new self();\n\n if (isset($order['ip_address'])) {\n $request->ip_address = $order['ip_address'];\n }\n\n if (isset($order['user_id'])) {\n $request->account_user_id = $order['user_id'];\n }\n\n if (isset($order['email'])) {\n $request->email_address = $order['email'];\n $request->email_domain = parse_url('http://' . $order['email'], PHP_URL_HOST);\n }\n\n if (isset($order['b_firstname'])) {\n $request->billing_first_name = $order['b_firstname'];\n }\n\n if (isset($order['b_lastname'])) {\n $request->billing_last_name = $order['b_lastname'];\n }\n\n if (isset($order['b_address'])) {\n $request->billing_address = $order['b_address'];\n }\n\n if (isset($order['b_address_2'])) {\n $request->billing_address_2 = $order['b_address_2'];\n }\n\n if (isset($order['b_city'])) {\n $request->billing_city = $order['b_city'];\n }\n\n if (isset($order['b_state'])) {\n $request->billing_region = $order['b_state'];\n }\n\n if (isset($order['b_country'])) {\n $request->billing_country = $order['b_country'];\n }\n\n if (isset($order['b_zipcode'])) {\n $request->billing_postal = $order['b_zipcode'];\n }\n\n if (isset($order['s_firstname'])) {\n $request->shipping_first_name = $order['s_firstname'];\n }\n\n if (isset($order['s_lastname'])) {\n $request->shipping_last_name = $order['s_lastname'];\n }\n\n if (isset($order['s_address'])) {\n $request->shipping_address = $order['s_address'];\n }\n\n if (isset($order['s_address_2'])) {\n $request->shipping_address_2 = $order['s_address_2'];\n }\n\n if (isset($order['s_city'])) {\n $request->shipping_city = $order['s_city'];\n }\n\n if (isset($order['s_state'])) {\n $request->shipping_region = $order['s_state'];\n }\n\n if (isset($order['s_country'])) {\n $request->shipping_country = $order['s_country'];\n }\n\n if (isset($order['s_zipcode'])) {\n $request->shipping_postal = $order['s_zipcode'];\n }\n\n if (isset($order['total'])) {\n $request->order_amount = (float) $order['total'];\n }\n\n if (isset($order['secondary_currency'])) {\n $request->order_currency = $order['secondary_currency'];\n }\n\n return $request;\n }", "title": "" }, { "docid": "f6d081ba50d8583052ab179d3fbd04e1", "score": "0.5869382", "text": "public function getOrderTaskRequest($task_id)\n {\n // verify the required parameter 'task_id' is set\n if ($task_id === null || (is_array($task_id) && count($task_id) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $task_id when calling getOrderTask'\n );\n }\n\n $resourcePath = '/order_task/{task_id}';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n\n // path params\n if ($task_id !== null) {\n $resourcePath = str_replace(\n '{' . 'task_id' . '}',\n ObjectSerializer::toPathValue($task_id),\n $resourcePath\n );\n }\n\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n []\n );\n }\n\n // for model (json/xml)\n if (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue];\n foreach ($formParamValueItems as $formParamValueItem) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValueItem\n ];\n }\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "f8f773ef9b70decb85e3058bdf890145", "score": "0.5864959", "text": "public function get(int $orderId);", "title": "" }, { "docid": "12ac5f0afa7a2354ded6d86ccb0a7681", "score": "0.58645767", "text": "public function createOrder() : array {\n\n }", "title": "" }, { "docid": "f5f0062130cc82f43de1eca19b5af83e", "score": "0.58564156", "text": "function getOrders() {\n $result = $this->query( $this->pair . '/money/orders');\n\n return $result;\n }", "title": "" }, { "docid": "0a65d703bb0a2fd3a0103111a8486f0e", "score": "0.5854714", "text": "public function testGetOrdersDetailsUsingGET()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "title": "" }, { "docid": "ba72df3ddd8fd268289087ae5bf7d8fc", "score": "0.58243734", "text": "public function createPaymentRequest($order)\n {\n $storeId = $order->getStoreId();\n $currency = $order->getBaseCurrencyCode();\n $minorunits = $this->_bamboraHelper->getCurrencyMinorUnits($currency);\n $roundingMode = $this->getConfigData(\n BamboraConstants::ROUNDING_MODE,\n $storeId\n );\n $totalAmountMinorUnits = $this->_bamboraHelper->convertPriceToMinorunits(\n $order->getBaseTotalDue(),\n $minorunits,\n $roundingMode\n );\n $paymentRequest = $this->_bamboraHelper->getEpayApiModel(\n EpayApiModels::REQUEST_PAYMENT\n );\n $paymentRequest->encoding = \"UTF-8\";\n $paymentRequest->cms = $this->_bamboraHelper->getModuleHeaderInfo();\n $paymentRequest->windowstate = \"3\";\n $paymentRequest->mobile = $this->getConfigData(\n BamboraConstants::ENABLE_MOBILE_PAYMENT_WINDOW,\n $storeId\n );\n $paymentRequest->merchantnumber = $this->getAuth($storeId)->merchantNumber;\n $paymentRequest->windowid = $this->getConfigData(\n BamboraConstants::PAYMENT_WINDOW_ID,\n $storeId\n );\n $paymentRequest->amount = $totalAmountMinorUnits;\n $paymentRequest->currency = $currency;\n $paymentRequest->orderid = $order->getIncrementId();\n $paymentRequest->accepturl = $this->_urlBuilder->getUrl(\n 'bambora/epay/accept',\n ['_secure' => $this->_request->isSecure()]\n );\n $paymentRequest->cancelurl = $this->_urlBuilder->getUrl(\n 'bambora/epay/cancel',\n ['_secure' => $this->_request->isSecure()]\n );\n $paymentRequest->callbackurl = $this->_urlBuilder->getUrl(\n 'bambora/epay/callback',\n ['_secure' => $this->_request->isSecure()]\n );\n $paymentRequest->instantcapture = $this->getConfigData(\n BamboraConstants::INSTANT_CAPTURE,\n $storeId\n );\n $paymentRequest->language = $this->_bamboraHelper->calcLanguage();\n $paymentRequest->ownreceipt = $this->getConfigData(\n BamboraConstants::OWN_RECEIPT,\n $storeId\n );\n $paymentRequest->timeout = 60;\n $paymentRequest->invoice = $this->createInvoice(\n $order,\n $minorunits,\n $roundingMode\n );\n $paymentRequest->hash = $this->_bamboraHelper->calcEpayMd5Key(\n $order,\n $paymentRequest\n );\n\n return $paymentRequest;\n }", "title": "" }, { "docid": "82d69d17aa72b56f85ad4a84ecbfddee", "score": "0.5804148", "text": "public function show(Order $order)\n {\n\n return new OrderResource($order);\n }", "title": "" }, { "docid": "9fac432698adb9a1d954414c6a4176a3", "score": "0.5784397", "text": "public function newOrder($order)\r\n {\r\n $this->request = ['method' => 'POST', 'path' => '%2Fmerchant%2Forders%2F'];\r\n\r\n $concatenateParams = '';\r\n\r\n foreach ($order as $k => $v) {\r\n $value = urlencode($v);\r\n $concatenateParams .= \"&{$k}={$value}\";\r\n }\r\n\r\n $this->header = $this->setHeader($concatenateParams);\r\n\r\n $api = $this->callApi(\"merchant/orders/\", $this->request['method'], $order);\r\n\r\n return $api;\r\n }", "title": "" }, { "docid": "6d0263c20ea8cbec80cfc286242c487f", "score": "0.57526624", "text": "protected function addOrderRequest($body)\n {\n // verify the required parameter 'body' is set\n if ($body === null || (is_array($body) && count($body) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $body when calling addOrder'\n );\n }\n\n $resourcePath = '/Order';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n\n // body params\n $_tempBody = null;\n if (isset($body)) {\n $_tempBody = $body;\n }\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/xml', 'application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/xml', 'application/json'],\n ['application/x-www-form-urlencoded']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass && $headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('token');\n if ($apiKey !== null) {\n $queryParams['token'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'POST',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "8c7113ea92475cff6349997412aa55a0", "score": "0.5731309", "text": "function getAllOrders_get(){\n $result = $this->order_model->getAllOrders();\n $this->response($result, 200); \n}", "title": "" }, { "docid": "7b1fb52e27615264b86f60a8ca70107f", "score": "0.57244277", "text": "public function sendTransactionGetRequest(Order $order)\n {\n // Request parameters (see https://payzen.io/fr-FR/rest/V4.0/api/playground.html?ws=Transaction/Update)\n $parameters = [\n 'uuid' => $order->getTransactionRef()\n ];\n\n return $this->post(\"V4/Transaction/Get\", $parameters);\n }", "title": "" }, { "docid": "a9df13eb4cfe49c72f40ac6dda9b233e", "score": "0.5715741", "text": "public function getOrderByIdAndUserId();", "title": "" }, { "docid": "acbbe680245b85cfbafa781f5d6fed1f", "score": "0.5714953", "text": "public function getTransaction(Order $order)\n {\n $response = $this->sendTransactionGetRequest($order);\n\n $this->processTransactionGetResponse($response);\n }", "title": "" }, { "docid": "75f554950aecb5edcb2da9c801bdc508", "score": "0.5711263", "text": "protected function get_new_echeck_request( \\WC_Order $order ) {\n\n\t\t$this->order = $order;\n\n\t\t$request = $this->get_new_request( array(\n\t\t\t'type' => 'payment',\n\t\t\t'payment_type' => 'echeck',\n\t\t) );\n\n\t\treturn $request;\n\t}", "title": "" }, { "docid": "7fc4e8c52127689b3e37c0dbbb3ae27b", "score": "0.57072985", "text": "protected function getAutoOrderRequest($auto_order_oid, $_expand = null)\n {\n // verify the required parameter 'auto_order_oid' is set\n if ($auto_order_oid === null || (is_array($auto_order_oid) && count($auto_order_oid) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $auto_order_oid when calling getAutoOrder'\n );\n }\n\n $resourcePath = '/auto_order/auto_orders/{auto_order_oid}';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n // query params\n if ($_expand !== null) {\n $queryParams['_expand'] = ObjectSerializer::toQueryValue($_expand);\n }\n\n // path params\n if ($auto_order_oid !== null) {\n $resourcePath = str_replace(\n '{' . 'auto_order_oid' . '}',\n ObjectSerializer::toPathValue($auto_order_oid),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('x-ultracart-simple-key');\n if ($apiKey !== null) {\n $headers['x-ultracart-simple-key'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "cfff2e803d77d04fc9a813b866ac9a78", "score": "0.56967133", "text": "public function retrieveOrder(string $orderId): ApiResponse\n {\n $_reqBuilder = $this->requestBuilder(RequestMethod::GET, '/v2/orders/{order_id}')\n ->auth('global')\n ->parameters(TemplateParam::init('order_id', $orderId));\n\n $_resHandler = $this->responseHandler()->type(RetrieveOrderResponse::class)->returnApiResponse();\n\n return $this->execute($_reqBuilder, $_resHandler);\n }", "title": "" }, { "docid": "76236eba85c08e6f3ac55bd4fe4f8c63", "score": "0.5682425", "text": "public function index()\n {\n $user_id = Auth::id();\n\n try{\n $orders = QueryBuilder::for(Order::where('user_id', $user_id))\n ->allowedFilters([AllowedFilter::exact('status'), AllowedFilter::exact('paidout'), AllowedFilter::exact('type')])\n ->defaultSort('id')\n ->allowedSorts('created_at')\n ->paginate(15)\n ->appends(request()->query());\n\n }catch(InvalidFilterQuery $e){\n return $this->sendError('Filtro invalido', $e->getMessage());\n }catch(InvalidSortQuery $e){\n return $this->sendError('Sort invalido', $e->getMessage());\n }\n\n return new OrdersResource($orders);\n }", "title": "" }, { "docid": "2e8d3dcab0d59530b496a32d70f1ebdb", "score": "0.5680903", "text": "public function createOrder($order);", "title": "" }, { "docid": "3a4f5e3493fe2ebfea1f5d5bcfe8e72d", "score": "0.56714344", "text": "protected function getAutoOrdersByQueryRequest($auto_order_query, $_limit = '100', $_offset = '0', $_sort = null, $_expand = null)\n {\n // verify the required parameter 'auto_order_query' is set\n if ($auto_order_query === null || (is_array($auto_order_query) && count($auto_order_query) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $auto_order_query when calling getAutoOrdersByQuery'\n );\n }\n\n $resourcePath = '/auto_order/auto_orders/query';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n // query params\n if ($_limit !== null) {\n $queryParams['_limit'] = ObjectSerializer::toQueryValue($_limit);\n }\n // query params\n if ($_offset !== null) {\n $queryParams['_offset'] = ObjectSerializer::toQueryValue($_offset);\n }\n // query params\n if ($_sort !== null) {\n $queryParams['_sort'] = ObjectSerializer::toQueryValue($_sort);\n }\n // query params\n if ($_expand !== null) {\n $queryParams['_expand'] = ObjectSerializer::toQueryValue($_expand);\n }\n\n\n // body params\n $_tempBody = null;\n if (isset($auto_order_query)) {\n $_tempBody = $auto_order_query;\n }\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('x-ultracart-simple-key');\n if ($apiKey !== null) {\n $headers['x-ultracart-simple-key'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'POST',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "c556e9efd59b59bd8e6fc0ba7a3492c8", "score": "0.5666485", "text": "public function getPurchaseOrder();", "title": "" }, { "docid": "849feb14a49b9744ee1371142c086c8c", "score": "0.5663011", "text": "protected function getAllOrdersRequest(\n ?string $sku = null,\n ?string $customerOrderId = null,\n ?string $purchaseOrderId = null,\n ?string $status = null,\n ?string $createdStartDate = null,\n ?string $createdEndDate = null,\n ?string $fromExpectedShipDate = null,\n ?string $toExpectedShipDate = null,\n ?string $lastModifiedStartDate = null,\n ?string $lastModifiedEndDate = null,\n ?string $limit = '100',\n ?string $productInfo = 'false',\n ?string $shipNodeType = 'SellerFulfilled',\n ?string $shippingProgramType = null,\n ?string $replacementInfo = 'false',\n ?string $orderType = null,\n ?string $hasMoreElements = null,\n ?string $soIndex = null,\n ?string $poIndex = null,\n ?string $partnerId = null,\n ?string $sellerId = null,\n ): Request {\n $contentType = self::contentTypes['getAllOrders'];\n\n $resourcePath = '/v3/orders';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n $method = 'GET';\n\n // query params\n $queryParams = array_merge(\n ObjectSerializer::toQueryValue(\n $sku,\n 'sku', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $customerOrderId,\n 'customerOrderId', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $purchaseOrderId,\n 'purchaseOrderId', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $status,\n 'status', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $createdStartDate,\n 'createdStartDate', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $createdEndDate,\n 'createdEndDate', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $fromExpectedShipDate,\n 'fromExpectedShipDate', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $toExpectedShipDate,\n 'toExpectedShipDate', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $lastModifiedStartDate,\n 'lastModifiedStartDate', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $lastModifiedEndDate,\n 'lastModifiedEndDate', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $limit,\n 'limit', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $productInfo,\n 'productInfo', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $shipNodeType,\n 'shipNodeType', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $shippingProgramType,\n 'shippingProgramType', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $replacementInfo,\n 'replacementInfo', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $orderType,\n 'orderType', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $hasMoreElements,\n 'hasMoreElements', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $soIndex,\n 'soIndex', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $poIndex,\n 'poIndex', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $partnerId,\n 'partnerId', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n ObjectSerializer::toQueryValue(\n $sellerId,\n 'sellerId', // param base name\n 'string', // openApiType\n 'form', // style\n true, // explode\n false // required\n ) ?? [],\n );\n\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n $contentType,\n $multipart\n );\n\n $defaultHeaders = parent::getDefaultHeaders();\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n // for model (json/xml)\n if (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue];\n foreach ($formParamValueItems as $formParamValueItem) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValueItem\n ];\n }\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n } elseif (stripos($headers['Content-Type'], 'application/json') !== false) {\n # if Content-Type contains \"application/json\", json_encode the form parameters\n $httpBody = \\GuzzleHttp\\Utils::jsonEncode($formParams);\n } else {\n // for HTTP post (form)\n $httpBody = ObjectSerializer::buildQuery($formParams);\n }\n }\n\n $query = ObjectSerializer::buildQuery($queryParams);\n $requestInfo = [\n 'path' => $resourcePath,\n 'method' => $method,\n 'timestamp' => $defaultHeaders['WM_SEC.TIMESTAMP'],\n 'query' => $query,\n ];\n\n // this endpoint requires Bearer authentication (access token)\n $token = $this->config->getAccessToken();\n if ($token) {\n $headers['WM_SEC.ACCESS_TOKEN'] = $token->accessToken;\n }\n\n $operationHost = $this->config->getHost();\n return new Request(\n $method,\n $operationHost . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "1abae0a471f5d9f224ed110d2e313400", "score": "0.5641802", "text": "protected function createInvoiceFromOrderRequest($body)\n {\n // verify the required parameter 'body' is set\n if ($body === null || (is_array($body) && count($body) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $body when calling createInvoiceFromOrder'\n );\n }\n\n $resourcePath = '/Invoice/Factory/createInvoiceFromOrder';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n\n // body params\n $_tempBody = null;\n if (isset($body)) {\n $_tempBody = $body;\n }\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/xml', 'application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/xml', 'application/json'],\n ['application/x-www-form-urlencoded']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass && $headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('token');\n if ($apiKey !== null) {\n $queryParams['token'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'POST',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "4a0f264b89ba14ad7b0d6e2e7d8c7a3f", "score": "0.5625564", "text": "function createOrder($name = 'default');", "title": "" }, { "docid": "f62df8e97b035b42636eb8cbcbded166", "score": "0.56114453", "text": "public function build(): CalculateOrderRequest\n {\n return CoreHelper::clone($this->instance);\n }", "title": "" }, { "docid": "8625b0fb834bc7b31c22625c9fcfc66b", "score": "0.5591309", "text": "public function store(OrderCreateRequest $request)\n {\n\n try {\n\n $this->validator->with($request->all())->passesOrFail(ValidatorInterface::RULE_CREATE);\n\n $data = $request->all();\n\n $o = $this->service->create($data);\n\n return $this->repository\n ->skipPresenter(false)\n ->with($this->with)\n ->find($o->id);\n\n } catch (ValidatorException $e) {\n return response()->json([\n 'error' => true,\n 'message' => $e->getMessageBag()\n ]);\n }\n }", "title": "" }, { "docid": "d6d278b35a6b8841dfa46595f46e0553", "score": "0.5587471", "text": "public function placeOrder($request)\n {\n $response = null;\n // @codingStandardsIgnoreLine\n $operation = new Operation\\OrderCreate();\n $response = $operation->execute($request);\n // @codingStandardsIgnoreLine\n return $response;\n }", "title": "" }, { "docid": "f91b19b7dfbec4485d782a412d63a7ff", "score": "0.55775326", "text": "protected function createAnOrderRequest($body, $accept, $content_type)\n {\n // verify the required parameter 'body' is set\n if ($body === null || (is_array($body) && count($body) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $body when calling createAnOrder'\n );\n }\n // verify the required parameter 'accept' is set\n if ($accept === null || (is_array($accept) && count($accept) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $accept when calling createAnOrder'\n );\n }\n // verify the required parameter 'content_type' is set\n if ($content_type === null || (is_array($content_type) && count($content_type) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $content_type when calling createAnOrder'\n );\n }\n\n $resourcePath = '/orders';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n // header params\n if ($accept !== null) {\n $headerParams['Accept'] = ObjectSerializer::toHeaderValue($accept);\n }\n // header params\n if ($content_type !== null) {\n $headerParams['Content-Type'] = ObjectSerializer::toHeaderValue($content_type);\n }\n\n\n // body params\n $_tempBody = null;\n if (isset($body)) {\n $_tempBody = $body;\n }\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json', 'Multiple Items']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json', 'Multiple Items'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass && $headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('X-Auth-Client');\n if ($apiKey !== null) {\n $headers['X-Auth-Client'] = $apiKey;\n }\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('X-Auth-Token');\n if ($apiKey !== null) {\n $headers['X-Auth-Token'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'POST',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "25daf68ee4940bcb0dcb9dbd00f5c60e", "score": "0.5577501", "text": "protected function deleteOrderRequest($id)\n {\n // verify the required parameter 'id' is set\n if ($id === null || (is_array($id) && count($id) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $id when calling deleteOrder'\n );\n }\n\n $resourcePath = '/Order/{id}';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n // path params\n if ($id !== null) {\n $resourcePath = str_replace(\n '{' . 'id' . '}',\n ObjectSerializer::toPathValue($id),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/xml', 'application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/xml', 'application/json'],\n ['application/x-www-form-urlencoded']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass && $headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('token');\n if ($apiKey !== null) {\n $queryParams['token'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'DELETE',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "983ca1bbfff134b23dfddff23997ab3a", "score": "0.55732125", "text": "public function getOrder() {\n }", "title": "" }, { "docid": "1aeb9c7e408256822eb2aefdd0a3c7ea", "score": "0.5569211", "text": "public function create(Request $request)\n {\n // validate order\n\n // create order\n // in create order on order model -> create order choices\n }", "title": "" }, { "docid": "60e298c454ed0234ea2249c904f18929", "score": "0.55668557", "text": "public function createRequest()\r\n {\r\n $this->data = SagepayCommon::encryptedOrder($this);\r\n $this->addConfiguredValues();\r\n $this->checkMandatoryFields();\r\n\r\n $ttl = $this->config->getRequestTimeout();\r\n $caCert = $this->config->getCaCertPath();\r\n return SagepayCommon::requestPost($this->_vpsServerUrl, $this->data, $ttl, $caCert);\r\n }", "title": "" }, { "docid": "c382b884d777b10f43c07baead389ebd", "score": "0.5564487", "text": "public function show(Order $order) : JsonResponse\n {\n return response()->json(\n new ResourcesOrder($order),\n Response::HTTP_OK\n );\n }", "title": "" }, { "docid": "e4d47ad09d7c0729f7a4615303f8dafc", "score": "0.5561612", "text": "public function customerOrdersByTerm()\n {\n // $toDate = date('Y-m-d H:i:s',strtotime(request('toDate')));\n\n //// https://stackoverflow.com/questions/43871752/how-to-get-created-at-date-only-not-time-in-laravel-5-4\n $orders = Order::with('user','orderdetails','address')\n ->whereDate('created_at', '>=', request('fromDate'))\n ->whereDate('created_at', '<=', request('toDate'))\n ->orderBy('created_at','desc')\n ->get();\n\n // return $orders;\n\n return response()->json([\n 'orders' => $orders,\n ]);\n }", "title": "" }, { "docid": "ae352944368acec05721fab7c49d37a4", "score": "0.5560715", "text": "public function create(Request $request){\n $var = Order::create($request->all());\n return response()->json($var,201);\n }", "title": "" }, { "docid": "a37e14b80a1cf9b0642caae4a5a3f0b4", "score": "0.55555487", "text": "public function actionGetOrders()\n {\n $params = Yii::$app->request->get();\n $searchStr = (isset($params['search']) && $params['search']['value'] !== null) ? $params['search']['value'] : null;\n $offset = (isset($params['start'])) ? $params['start'] : null;\n $limit = (isset($params['length'])) ? $params['length'] : null;\n $status = (isset($params['status'])) ? $params['status'] : null;\n $id = (isset($params['id'])) ? $params['id'] : null;\n $columns = array('job.id', 'cc_agent.first_name', 'job.created');\n $order = $this->getOrderAbleColumn($params, $columns);\n $order = ($order != null) ? $order : 'job.id';\n $model = new Job();\n $result = $model->getJobWithTasks($id, $status, $searchStr, $offset, $limit, $order);\n return $result;\n }", "title": "" }, { "docid": "fbe29275caa3f2d776580ccacb548272", "score": "0.55482244", "text": "public function details()\n {\n $this->mustHave('product_id');\n\n $this->endpoint = 'order';\n return $this->get(\"/{$this->product_id}\");\n }", "title": "" }, { "docid": "208da319575a1e50587822adcee79b29", "score": "0.55424726", "text": "public function placeOrder(CreateOrderRequest $request) {\n }", "title": "" }, { "docid": "40da7d7fc4139e79532174bb69884d71", "score": "0.5540651", "text": "public function getObject()\n { \n return $this->getOrder();\n }", "title": "" }, { "docid": "b72e562f15552b46ffb7ce0e152264cd", "score": "0.5528099", "text": "protected function addOmsOrderRequest($body)\n {\n // verify the required parameter 'body' is set\n if ($body === null) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $body when calling addOmsOrder'\n );\n }\n\n $resourcePath = '/beta/omsOrder';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n\n // body params\n $_tempBody = null;\n if (isset($body)) {\n $_tempBody = $body;\n }\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass && $headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('API-Key');\n if ($apiKey !== null) {\n $headers['API-Key'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'POST',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "74f6c163ac8835e490588a5bd8f8baf6", "score": "0.5524903", "text": "public function getMyOrders() {\n $user_id=1;\n\n $path = base_url();\n $url = $path . 'api/ManageOrder_api/getMyOrders?user_id='.$user_id;\n $ch = curl_init($url);\n curl_setopt($ch, CURLOPT_HTTPGET, true);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n $response_json = curl_exec($ch);\n curl_close($ch);\n $response = json_decode($response_json, true);\n return $response;\n}", "title": "" }, { "docid": "5ed94f532b1fd6cf0d1e9338855fb3e4", "score": "0.55171925", "text": "public function getOrder();", "title": "" }, { "docid": "5ed94f532b1fd6cf0d1e9338855fb3e4", "score": "0.55171925", "text": "public function getOrder();", "title": "" }, { "docid": "420d3aa0f0a81e15bbd0ccff1bf6adc4", "score": "0.5516387", "text": "public function getOrder(Request $request)\n {\n $user = null;\n\t\t\n\t\tif(Auth::check())\n\t\t{\n\t\t\t$user = Auth::user();\n if(!$this->helpers->isAdmin($user)) return redirect()->intended('dashboard');\t\t\n\t\t}\n\t\telse\n {\n \treturn redirect()->intended('login?return=dashboard');\n }\n \n $req = $request->all();\n\t\t\t$validator = Validator::make($req, [\n 'on' => 'required',\n ]);\n \n if($validator->fails())\n {\n #$messages = $validator->messages();\n return redirect()->intended('cobra-orders');\n }\n\t\t$c = $this->helpers->categories;\n\t\t$order = $this->helpers->adminGetOrder($req['on']); \n \treturn view('admin.order',compact(['user','c','order']));\n }", "title": "" }, { "docid": "5337f29112ba577c915d603e76f254bd", "score": "0.5502816", "text": "public function actionWsgetpedido($id){\n // Respuesta: {\"errorCode\":\"7003\",\"errorMessage\":\"Order is not registered\",\"result\":\"0\"}\n // Respuesta: {\"authenticationECI\":\"06\",\"authorizationCode\":\"019369\",\"billingCountry\":\"\",\"cardNumber\":\"485951\n // ******0051\",\"cardType\":\"VISA\",\"errorCode\":\"00 \",\"errorMessage\":\"Successful approval/completion\",\"language\"\n // :\"SP\",\"operationNumber\":\"641388389\",\"purchaseAmount\":\"120000\",\"purchaseCurrencyCode\":\"840\",\"purchaseIPAddress\"\n // :\"181.199.77.95\",\"result\":\"3 \",\"shippingAddress\":\"Su casita\",\"shippingCity\":\"Pagomedios Ciudad\",\"shippingCountry\"\n // :\"EC\",\"shippingEMail\":\"info@abitmedia.com\",\"shippingFirstName\":\"Carlos\",\"shippingLastName\":\"Crespo\",\"shippingState\"\n // :\"Pagomedios Esta\",\"shippingZIP\":\"Pagomedios\",\"terminalCode\":\"\"}\n\n $pedido = $this->findModel($id);\n if( $pedido->estado != 'Autorizado' ){\n $url = Yii::$app->params['core_api_url'].'/getorder/'; //URL del servicio web REST\n // $url = 'https://localhost/pagomedios/web/api/getorder/'; //URL del servicio web REST\n $header = array( 'Content-Type: application/json' );\n $dataOrden = array( 'commerce_id' => $pedido->empresa->id_commerce, //ID unico por comercio\n 'order_id' => $pedido->numero_pedido,\n );\n\n $params = http_build_query( $dataOrden ); //Tranformamos un array en formato GET\n //Consumo del servicio Rest\n $curl = curl_init();\n curl_setopt($curl, CURLOPT_URL, $url.'?'.$params);\n curl_setopt($curl, CURLOPT_HTTPHEADER, $header);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);\n curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);\n $response = curl_exec($curl);\n curl_close($curl);\n \n $responsePagomedios = json_decode($response);\n print_r( $responsePagomedios );\n\n }\n }", "title": "" }, { "docid": "8a5fbea8867f7f8ed51e13ffcd341eff", "score": "0.5501645", "text": "public function index(Request $request)\n {\n $orders = OrderResource::collection(Order::where(\"orderType\",$request[\"type\"])->get());\n return [\"data\"=>$orders];\n }", "title": "" }, { "docid": "7b9c3b116ea5533e8c11a893f53effbf", "score": "0.54971296", "text": "function getOrderBook() {\n $result = $this->query( $this->pair . '/money/depth/full');\n\n return $result;\n }", "title": "" }, { "docid": "552bcffc3c4d8dc806d7c05c4e0fc34b", "score": "0.54936147", "text": "protected function prepareRequest()\n {\n $errors = $this->validateOrder();\n $this->processErrors($errors);\n $data = $this->mapCreateOrderData($this->order);\n\n return $data;\n }", "title": "" }, { "docid": "4696f33bf9d8277771807536e1d88a0d", "score": "0.5486674", "text": "public function getOrders(WP_REST_Request $request) {\n\t\ttry {\n\t\t\t$this->checkAuth($request);\n\t\t\t$params = $request->get_params();\n\t\t\treturn $this->generateOutput($this->orders->getOrders(true, $params['max']));\n\t\t}\n\t\tcatch (Exception $e) {\n\t\t\treturn $this->handleError($e);\n\t\t}\n\t}", "title": "" }, { "docid": "c20f8b9cb128db538790e1ec34872557", "score": "0.5482392", "text": "public function requestOrder()\n {\n\t\treturn new OrderRequestedState;\n }", "title": "" }, { "docid": "cc285d094aa41292e83ba0bc83a5a6c3", "score": "0.5476973", "text": "protected function getAutoOrdersRequest($auto_order_code = null, $original_order_id = null, $first_name = null, $last_name = null, $company = null, $city = null, $state = null, $postal_code = null, $country_code = null, $phone = null, $email = null, $original_order_date_begin = null, $original_order_date_end = null, $next_shipment_date_begin = null, $next_shipment_date_end = null, $card_type = null, $item_id = null, $status = null, $_limit = '100', $_offset = '0', $_since = null, $_sort = null, $_expand = null)\n {\n\n $resourcePath = '/auto_order/auto_orders';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n // query params\n if ($auto_order_code !== null) {\n $queryParams['auto_order_code'] = ObjectSerializer::toQueryValue($auto_order_code);\n }\n // query params\n if ($original_order_id !== null) {\n $queryParams['original_order_id'] = ObjectSerializer::toQueryValue($original_order_id);\n }\n // query params\n if ($first_name !== null) {\n $queryParams['first_name'] = ObjectSerializer::toQueryValue($first_name);\n }\n // query params\n if ($last_name !== null) {\n $queryParams['last_name'] = ObjectSerializer::toQueryValue($last_name);\n }\n // query params\n if ($company !== null) {\n $queryParams['company'] = ObjectSerializer::toQueryValue($company);\n }\n // query params\n if ($city !== null) {\n $queryParams['city'] = ObjectSerializer::toQueryValue($city);\n }\n // query params\n if ($state !== null) {\n $queryParams['state'] = ObjectSerializer::toQueryValue($state);\n }\n // query params\n if ($postal_code !== null) {\n $queryParams['postal_code'] = ObjectSerializer::toQueryValue($postal_code);\n }\n // query params\n if ($country_code !== null) {\n $queryParams['country_code'] = ObjectSerializer::toQueryValue($country_code);\n }\n // query params\n if ($phone !== null) {\n $queryParams['phone'] = ObjectSerializer::toQueryValue($phone);\n }\n // query params\n if ($email !== null) {\n $queryParams['email'] = ObjectSerializer::toQueryValue($email);\n }\n // query params\n if ($original_order_date_begin !== null) {\n $queryParams['original_order_date_begin'] = ObjectSerializer::toQueryValue($original_order_date_begin);\n }\n // query params\n if ($original_order_date_end !== null) {\n $queryParams['original_order_date_end'] = ObjectSerializer::toQueryValue($original_order_date_end);\n }\n // query params\n if ($next_shipment_date_begin !== null) {\n $queryParams['next_shipment_date_begin'] = ObjectSerializer::toQueryValue($next_shipment_date_begin);\n }\n // query params\n if ($next_shipment_date_end !== null) {\n $queryParams['next_shipment_date_end'] = ObjectSerializer::toQueryValue($next_shipment_date_end);\n }\n // query params\n if ($card_type !== null) {\n $queryParams['card_type'] = ObjectSerializer::toQueryValue($card_type);\n }\n // query params\n if ($item_id !== null) {\n $queryParams['item_id'] = ObjectSerializer::toQueryValue($item_id);\n }\n // query params\n if ($status !== null) {\n $queryParams['status'] = ObjectSerializer::toQueryValue($status);\n }\n // query params\n if ($_limit !== null) {\n $queryParams['_limit'] = ObjectSerializer::toQueryValue($_limit);\n }\n // query params\n if ($_offset !== null) {\n $queryParams['_offset'] = ObjectSerializer::toQueryValue($_offset);\n }\n // query params\n if ($_since !== null) {\n $queryParams['_since'] = ObjectSerializer::toQueryValue($_since);\n }\n // query params\n if ($_sort !== null) {\n $queryParams['_sort'] = ObjectSerializer::toQueryValue($_sort);\n }\n // query params\n if ($_expand !== null) {\n $queryParams['_expand'] = ObjectSerializer::toQueryValue($_expand);\n }\n\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('x-ultracart-simple-key');\n if ($apiKey !== null) {\n $headers['x-ultracart-simple-key'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "da4fffc3ae15f73736a7136bd3c1d2d5", "score": "0.54763746", "text": "function manage_order(){\n\t\tif(isset($_GET[\"id\"]) && isset($_GET[\"for\"]) && isset($_GET[\"is_archived\"])){\n\t\t\t$id=$_GET[\"id\"];\t\t//Recive clave_unica como si fuera ID\n\t\t\t#by Paulina \n\t\t\t#documentado por modo de prueba\n\t\t\t$invoice_array = VentasModel::load_info_for_invoice_array($id,$_GET[\"for\"]);\n\t\t\t\n\t\t\tif($_GET[\"is_archived\"]==\"false\"){\n\t\t\t\trequire_once('Views/ventas/modal-generate-order.php');\t//Generar orden\n\t\t\t} else if($_GET[\"is_archived\"]==\"true\"){\n\t\t\t\trequire_once('Views/ventas/modal-edit-order.php');\t//Editar una orden generada previamente\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "9d70e4c46988cc666bb771573f3ae455", "score": "0.54717684", "text": "public function query_order( $order_id )\n {\n $this->_is_ready() or die('Pay4App: Query order failed because api_secret or merchant_id is not set');\n $digest = hash('sha256' , $order_id . $this->merchant_id() . $this->api_secret() );\n $params = array();\n $params['order'] = $order_id;\n $params['merchant'] = $this->merchant_id();\n $params['digest'] = $digest;\n $data = $this->_query_endpoint( $params );\n return $this->_from_json( $data );\n }", "title": "" }, { "docid": "6e4765538137181f02dcae14b132879e", "score": "0.54645324", "text": "public function orderCreateRequest($customerName, $customerSurname, $customerPhone, $customerEmail, $deliveryName, $deliverySurname, $deliveryPhone, $channelCode, $id, $qty, $participantName = null, $participantSurname = null, $participantEmail = null, $participantPhone = null, $participantComment = null, $participantStreet = null, $participantCity = null, $participantPostcode = null, $participantCountryCode = null, $participantClothesSize = null, $customerCompany = null, $customerStreet = null, $customerCity = null, $customerPostcode = null, $customerCountryCode = null, $customerVatid = null, $customerNewsletter = null, $customerFacebook = null, $customerLinkedin = null, $customerTwitter = null, $customerInstagram = null, $customerGoogleplus = null, $deliveryCompany = null, $deliveryStreet = null, $deliveryCity = null, $deliveryPostcode = null, $deliveryCountryCode = null, $deliveryVatid = null, $notes = null, $currencyCode = null, $localeCode = null, $coupon = null, $ref = null, $ga = null)\n {\n $this->assertIsNotEmpty($customerName, 'Missing the required parameter $customerName when calling orderCreate');\n $this->assertIsNotEmpty($customerSurname, 'Missing the required parameter $customerSurname when calling orderCreate');\n $this->assertIsNotEmpty($customerPhone, 'Missing the required parameter $customerPhone when calling orderCreate');\n $this->assertIsNotEmpty($customerEmail, 'Missing the required parameter $customerEmail when calling orderCreate');\n $this->assertIsNotEmpty($deliveryName, 'Missing the required parameter $deliveryName when calling orderCreate');\n $this->assertIsNotEmpty($deliverySurname, 'Missing the required parameter $deliverySurname when calling orderCreate');\n $this->assertIsNotEmpty($deliveryPhone, 'Missing the required parameter $deliveryPhone when calling orderCreate');\n $this->assertIsNotEmpty($channelCode, 'Missing the required parameter $channelCode when calling orderCreate');\n $this->assertIsNotEmpty($id, 'Missing the required parameter $id when calling orderCreate');\n $this->assertIsNotEmpty($qty, 'Missing the required parameter $qty when calling orderCreate');\n $resourcePath = '/order/create';\n $httpMethod = 'GET';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $isMultipart = false;\n\n if ($participantName !== null) {\n $queryParams += $this->buildQueryParam($participantName, 'form', 'participant_name');\n }\n if ($participantSurname !== null) {\n $queryParams += $this->buildQueryParam($participantSurname, 'form', 'participant_surname');\n }\n if ($participantEmail !== null) {\n $queryParams += $this->buildQueryParam($participantEmail, 'form', 'participant_email');\n }\n if ($participantPhone !== null) {\n $queryParams += $this->buildQueryParam($participantPhone, 'form', 'participant_phone');\n }\n if ($participantComment !== null) {\n $queryParams += $this->buildQueryParam($participantComment, 'form', 'participant_comment');\n }\n if ($participantStreet !== null) {\n $queryParams += $this->buildQueryParam($participantStreet, 'form', 'participant_street');\n }\n if ($participantCity !== null) {\n $queryParams += $this->buildQueryParam($participantCity, 'form', 'participant_city');\n }\n if ($participantPostcode !== null) {\n $queryParams += $this->buildQueryParam($participantPostcode, 'form', 'participant_postcode');\n }\n if ($participantCountryCode !== null) {\n $queryParams += $this->buildQueryParam($participantCountryCode, 'form', 'participant_country_code');\n }\n if ($participantClothesSize !== null) {\n $queryParams += $this->buildQueryParam($participantClothesSize, 'form', 'participant_clothes_size');\n }\n if ($customerCompany !== null) {\n $queryParams += $this->buildQueryParam($customerCompany, 'form', 'customer_company');\n }\n if ($customerName !== null) {\n $queryParams += $this->buildQueryParam($customerName, 'form', 'customer_name');\n }\n if ($customerSurname !== null) {\n $queryParams += $this->buildQueryParam($customerSurname, 'form', 'customer_surname');\n }\n if ($customerPhone !== null) {\n $queryParams += $this->buildQueryParam($customerPhone, 'form', 'customer_phone');\n }\n if ($customerEmail !== null) {\n $queryParams += $this->buildQueryParam($customerEmail, 'form', 'customer_email');\n }\n if ($customerStreet !== null) {\n $queryParams += $this->buildQueryParam($customerStreet, 'form', 'customer_street');\n }\n if ($customerCity !== null) {\n $queryParams += $this->buildQueryParam($customerCity, 'form', 'customer_city');\n }\n if ($customerPostcode !== null) {\n $queryParams += $this->buildQueryParam($customerPostcode, 'form', 'customer_postcode');\n }\n if ($customerCountryCode !== null) {\n $queryParams += $this->buildQueryParam($customerCountryCode, 'form', 'customer_country_code');\n }\n if ($customerVatid !== null) {\n $queryParams += $this->buildQueryParam($customerVatid, 'form', 'customer_vatid');\n }\n if ($customerNewsletter !== null) {\n $queryParams += $this->buildQueryParam($customerNewsletter, 'form', 'customer_newsletter');\n }\n if ($customerFacebook !== null) {\n $queryParams += $this->buildQueryParam($customerFacebook, 'form', 'customer_facebook');\n }\n if ($customerLinkedin !== null) {\n $queryParams += $this->buildQueryParam($customerLinkedin, 'form', 'customer_linkedin');\n }\n if ($customerTwitter !== null) {\n $queryParams += $this->buildQueryParam($customerTwitter, 'form', 'customer_twitter');\n }\n if ($customerInstagram !== null) {\n $queryParams += $this->buildQueryParam($customerInstagram, 'form', 'customer_instagram');\n }\n if ($customerGoogleplus !== null) {\n $queryParams += $this->buildQueryParam($customerGoogleplus, 'form', 'customer_googleplus');\n }\n if ($deliveryCompany !== null) {\n $queryParams += $this->buildQueryParam($deliveryCompany, 'form', 'delivery_company');\n }\n if ($deliveryName !== null) {\n $queryParams += $this->buildQueryParam($deliveryName, 'form', 'delivery_name');\n }\n if ($deliverySurname !== null) {\n $queryParams += $this->buildQueryParam($deliverySurname, 'form', 'delivery_surname');\n }\n if ($deliveryPhone !== null) {\n $queryParams += $this->buildQueryParam($deliveryPhone, 'form', 'delivery_phone');\n }\n if ($deliveryStreet !== null) {\n $queryParams += $this->buildQueryParam($deliveryStreet, 'form', 'delivery_street');\n }\n if ($deliveryCity !== null) {\n $queryParams += $this->buildQueryParam($deliveryCity, 'form', 'delivery_city');\n }\n if ($deliveryPostcode !== null) {\n $queryParams += $this->buildQueryParam($deliveryPostcode, 'form', 'delivery_postcode');\n }\n if ($deliveryCountryCode !== null) {\n $queryParams += $this->buildQueryParam($deliveryCountryCode, 'form', 'delivery_country_code');\n }\n if ($deliveryVatid !== null) {\n $queryParams += $this->buildQueryParam($deliveryVatid, 'form', 'delivery_vatid');\n }\n if ($notes !== null) {\n $queryParams += $this->buildQueryParam($notes, 'form', 'notes');\n }\n if ($channelCode !== null) {\n $queryParams += $this->buildQueryParam($channelCode, 'form', '_channel_code');\n }\n if ($currencyCode !== null) {\n $queryParams += $this->buildQueryParam($currencyCode, 'form', 'currency_code');\n }\n if ($localeCode !== null) {\n $queryParams += $this->buildQueryParam($localeCode, 'form', 'locale_code');\n }\n if ($coupon !== null) {\n $queryParams += $this->buildQueryParam($coupon, 'form', 'coupon');\n }\n if ($ref !== null) {\n $queryParams += $this->buildQueryParam($ref, 'form', 'ref');\n }\n if ($ga !== null) {\n $queryParams += $this->buildQueryParam($ga, 'form', '_ga');\n }\n if ($id !== null) {\n $queryParams += $this->buildQueryParam($id, 'form', 'id');\n }\n if ($qty !== null) {\n $queryParams += $this->buildQueryParam($qty, 'form', 'qty');\n }\n if ($isMultipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n []\n );\n }\n\n // for model (json/xml)\n if (count($formParams) > 0) {\n $httpBody = $this->buildBody($formParams, $isMultipart, $this->isHeaderContentTypeJson($headers));\n }\n\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $operationHost = $this->config->getHost();\n $query = Query::build($queryParams);\n $query = http_build_query($queryParams);\n\n return new Request($httpMethod, $operationHost . $resourcePath . ($query ? \"?{$query}\" : ''), $headers, $httpBody);\n }", "title": "" }, { "docid": "b9ecd0b1961e2325f62d5436f135b648", "score": "0.54587424", "text": "public function index(Request $request)\n {\n $timeFrom = $request->timeFrom ? Carbon::createFromTimestampMs($request->timeFrom) : Carbon::yesterday();\n return response()->json(\n Order::where('created_at', '>', $timeFrom)\n ->where('state', '<>', Order::STATE_PENDING_PAYMENT)\n ->orderBy('id', 'desc')\n ->with([\n 'user',\n 'rate',\n 'refundRate',\n 'referenceOrder',\n 'positions' => function ($query) {\n $query->with(['variant' => function ($query) {\n $query->with('food');\n $query->with('variations');\n }]);\n $query->with('extras');\n }, 'method', 'postcode' => function ($query) {\n $query->with('region');\n $query->with('cities');\n }]\n )->get());\n }", "title": "" }, { "docid": "882b0541166dc5d203b37feb61b54b21", "score": "0.5446907", "text": "public function orderGetByTokenRequest($tokenValue)\n {\n $this->assertIsNotEmpty($tokenValue, 'Missing the required parameter $tokenValue when calling orderGetByToken');\n $resourcePath = '/order/{tokenValue}';\n $httpMethod = 'GET';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $isMultipart = false;\n\n // path params\n if ($tokenValue !== null) {\n $resourcePath = str_replace('{' . 'tokenValue' . '}',\n ObjectSerializer::toPathValue($tokenValue),\n $resourcePath\n );\n }\n if ($isMultipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n []\n );\n }\n\n // for model (json/xml)\n if (count($formParams) > 0) {\n $httpBody = $this->buildBody($formParams, $isMultipart, $this->isHeaderContentTypeJson($headers));\n }\n\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $operationHost = $this->config->getHost();\n $query = Query::build($queryParams);\n $query = http_build_query($queryParams);\n\n return new Request($httpMethod, $operationHost . $resourcePath . ($query ? \"?{$query}\" : ''), $headers, $httpBody);\n }", "title": "" }, { "docid": "c0d1c99d57e91abeeaf3a12213f13a32", "score": "0.5445534", "text": "public function get_service_24pay_request($order) {\n \t\t$service24pay = $this->get_service_24pay();\n\n \t\t$service24payRequest = $service24pay->createRequest(array(\n \t\t\t\"NURL\" => Plugin24Pay::get_notification_listener_url(),\n \t\t\t\"RURL\" => Plugin24Pay::get_result_listener_url(),\n\n \t\t\t\"MsTxnId\" => date(\"His\") . $order->id,\n \t\t\t\"CurrAlphaCode\" => get_woocommerce_currency(),\n \t\t\t\"Amount\" => $order->get_total() + ( get_option('woocommerce_prices_include_tax' ) == 'yes' ? 0 : $order->get_total_tax() ),\n\n \t\t\t\"LangCode\" => strtoupper(substr(get_locale(), 0, 2)),\n \t\t\t\"ClientId\" => $order->id,\n \t\t\t\"FirstName\" => $order->billing_first_name,\n \t\t\t\"FamilyName\" => $order->billing_last_name,\n \t\t\t\"Email\" => $order->billing_email,\n \t\t\t\"Phone\" => $order->billing_phone,\n \t\t\t\"Street\" => $order->billing_address_1 . ( $order->billing_address_2 ? \", \" . $order->billing_address_2 : \"\" ),\n \t\t\t\"Zip\" => $order->billing_postcode,\n \t\t\t\"City\" => $order->billing_city,\n \t\t\t\"Country\" => convert_country_code_from_isoa2_to_isoa3($order->billing_country),\n \t\t));\n\n \t\treturn $service24payRequest;\n \t}", "title": "" }, { "docid": "3e050506240295dd7483010214eb3bd0", "score": "0.544023", "text": "abstract function getOrder();", "title": "" }, { "docid": "e906ebefab201960a58b15dc5212a031", "score": "0.5437802", "text": "public function getOrder()\n\t{\n\t\tinclude_once(DIR . 'libs/repositories/orders.php');\n\n\t\treturn Orders::Find($this->getOrderId());\n\t}", "title": "" }, { "docid": "2b9897faf7b4aa777ad2c38bbba70dd4", "score": "0.5434616", "text": "public function createOrder(CreateOrderRequest $body): ApiResponse\n {\n $_reqBuilder = $this->requestBuilder(RequestMethod::POST, '/v2/orders')\n ->auth('global')\n ->parameters(HeaderParam::init('Content-Type', 'application/json'), BodyParam::init($body));\n\n $_resHandler = $this->responseHandler()->type(CreateOrderResponse::class)->returnApiResponse();\n\n return $this->execute($_reqBuilder, $_resHandler);\n }", "title": "" }, { "docid": "889df1e898ae210ed6f8c70bcc759a64", "score": "0.5434304", "text": "public function index()\n {\n return OrderResource::collection(Order::all());\n }", "title": "" }, { "docid": "503e1c151c686d503e3d9bed3571621a", "score": "0.543336", "text": "protected function createOrder(array $data = []): TestResponse\n {\n return $this->json('POST', 'order', $data);\n }", "title": "" }, { "docid": "2d5fcce5a327288a8feffc29cc9a7f51", "score": "0.54153085", "text": "public function createOrderFilter ($request);", "title": "" }, { "docid": "87346ff53c92df49a14e86ee2daba083", "score": "0.5406946", "text": "private function getPagantisOrder()\n {\n $this->orderClient = new PagantisClient($this->config['publicKey'], $this->config['privateKey']);\n $this->pagantisOrder = $this->orderClient->getOrder($this->pagantisOrderId);\n if (!($this->pagantisOrder instanceof PagantisModelOrder)) {\n throw new OrderNotFoundException();\n }\n }", "title": "" }, { "docid": "b13bd4aafc53e453cd459e69946c3914", "score": "0.54033357", "text": "public function returnRequest($amount, $description = null, $currencyCode = null, $order = null, $metadata = null)\n {\n return $this->request(\n '3',\n $amount,\n $description,\n $currencyCode,\n $order,\n $metadata\n );\n }", "title": "" }, { "docid": "fa54fc5cdf382b810bbb859afd07714e", "score": "0.54033047", "text": "private function getGeneratedCreateRequest()\n {\n return $this->builder->setObject($this->getQuote())->generateRequest(BuilderInterface::GENERATE_TYPE_CREATE)\n ->getRequest();\n }", "title": "" }, { "docid": "de3754f461147f1e3e1b0841d45767ae", "score": "0.5385735", "text": "function bigCommerceOrderAPIGet($client, $apiBase)\n{\n try {\n $response = $client->request('GET', $apiBase);\n } catch (Client $e) {\n exit();\n }\n return $response;\n}", "title": "" }, { "docid": "653cd4243a2b8cb86d6c5d831dc60921", "score": "0.53850377", "text": "function findOrderById($id);", "title": "" }, { "docid": "18bd27f45003032295419b9fffdb5d69", "score": "0.53810704", "text": "public function myOrders(Request $request) {\n try {\n $validator = Validator::make($request->all(), $this->orders_rules);\n if ($validator->fails()) {\n $errors = $validator->errors()->toArray();\n return _api_json('', ['errors' => $errors], 422);\n }\n $orders = array();\n $user = $this->auth_user();\n\n $orders = Order::withTrashed();\n $orders->where('orders.user_id', $user->id);\n if ($request->type == 1) {\n $orders->whereIn('orders.status', [0, 1, 2,7]);\n } else {\n $orders->whereIn('orders.status', [3, 4]);\n }\n $orders->join('resturantes', 'orders.resturant_id', '=', 'resturantes.id');\n $orders->join('resturant_branches', 'resturant_branches.id', '=', 'orders.resturant_branch_id');\n $orders->join('cities', 'resturant_branches.region_id', '=', 'cities.id');\n $orders->select('orders.*', 'resturantes.title_' . $this->lang_code . ' as resturant', 'resturantes.image', 'cities.title_' . $this->lang_code . ' as region');\n $orders->orderBy('orders.date', 'desc');\n $orders = $orders->paginate($this->limit);\n\n\n $orders = Order::transformCollection($orders);\n\n return _api_json($orders);\n } catch (\\Exception $e) {\n dd($e);\n $message = ['message' => _lang('app.error_occured')];\n return _api_json(array(), $message, 422);\n }\n }", "title": "" } ]
7d8e6f26164d19f88623a6d08751ecab
test successful get models
[ { "docid": "ad9caca8fafc40f358da410a9f9aafd5", "score": "0.83635664", "text": "public function test_get_models()\n {\n $response = $this->get('/api/models', $this->defaultHeaders);\n\n $response->assertStatus(200);\n }", "title": "" } ]
[ { "docid": "dc1252f7c0e78251b0f061ec5192c1ab", "score": "0.67341083", "text": "public function testGet()\n {\n\n $API = new API();\n $ProviderAPI = new ProviderAPI();\n\n // Get whatever first replied responsed from server, I don't care...\n $this->mockGetListResponse(200, ProviderTest::getMockData());\n $ProviderGetListResponse = $ProviderAPI->getList();\n $Provider = $ProviderGetListResponse->getObjects()[0];\n\n $this->mockResponse(200, $this->getMockData());\n $Model = $API->getByUri($Provider->getRegions()[0]);\n\n $this->mockResponse(200, $this->getMockData());\n $Model = $API->get($Provider->getName(), $Model->getName());\n $this->assertInstanceOf(Model::class, $Model);\n }", "title": "" }, { "docid": "697c920bf77317d7200d1fe858e7daf6", "score": "0.6721504", "text": "public function test_listing_models()\n {\n Artisan::call('runsite:setup');\n $this->browse(function (Browser $browser) {\n $browser->maximize()\n ->visit(route('admin.models.index'))\n ->assertRouteIs('login')\n ->type('email', 'developer@domain.com')\n ->type('password', 'secret')\n ->press('Sign In')\n ->assertRouteIs('admin.models.index')\n ->assertSee('Models')\n ->assertSee('Root')\n ->assertSee('Section')\n ->assertSee('Admin section');\n });\n }", "title": "" }, { "docid": "1852144b2581f1dd78a1fa3f7afde5de", "score": "0.6714493", "text": "public function test()\n {\n /** @var \\App\\Models\\LetMeTestModel */\n $model = model('LetMeTestModel');\n print_r($model->getList());\n }", "title": "" }, { "docid": "0bb4c8e55a6df500afb45a2ddbf8cf2b", "score": "0.6621054", "text": "public function testFindMultiple()\n {\n $results = array(\n \"response\" => array(\n array(\"test\" => \"testuser1\"),\n array(\"test\" => \"testuser2\")\n )\n );\n\n $request = $this->buildMockRequest($results);\n $model = $this->getMock('\\DuoAuth\\Model', array('getRequest'));\n\n $model->expects($this->once())\n ->method('getRequest')\n ->will($this->returnValue($request));\n\n $result = $model->find('/test/this','\\DuoAuth\\MockModel');\n\n $this->assertEquals(count($result), 2);\n $this->assertEquals($result[0]->test, 'testuser1');\n }", "title": "" }, { "docid": "3a13683964195a4319c945d41bda711c", "score": "0.6480461", "text": "public function testgetAll() {\n $car = new Car;\n $car->getAll();\n $this->assertNotEmpty($car);\n }", "title": "" }, { "docid": "27d20f80e54f450b76bb2de92af75b67", "score": "0.64721584", "text": "public function testFindOrFailSuccess()\n {\n $model = factory($this->testClass)->create();\n $this->assertNotEmpty($this->repo->findOrFail($model->getId()));\n }", "title": "" }, { "docid": "cec1efbeab68356ef9b84be430ea86e4", "score": "0.6456034", "text": "public function testAllGet()\n {\n\n }", "title": "" }, { "docid": "e93b2ea6913ccd99ad9a7ec670e69015", "score": "0.641256", "text": "function test_get_users()\n {\n $users = new mdl_users();\n $result = $users->get_users();\n\n $this->assertEquals($result[0]['User_name'], 'fred');\n $this->assertEquals($result[1]['User_name'], 'sue');\n }", "title": "" }, { "docid": "76619a40a6dfc43ca49d7e48f0d7e617", "score": "0.6411211", "text": "public function test_show()\n {\n // 5 record added to database\n $model = Tag::factory()->create();\n\n // request\n $response = $this->get('api/tags/' . $model->id);\n\n // response control\n $response->assertJson([\n 'id' => $model->id,\n 'title' => $model['title'],\n 'blog_id' => $model['blog_id'],\n ]);\n\n // response code 200\n $response->assertStatus(200);\n }", "title": "" }, { "docid": "161a508f0558b8e6e6994fc854b5a495", "score": "0.6390714", "text": "public function testGetModel()\n {\n $this->todo('stub');\n }", "title": "" }, { "docid": "161a508f0558b8e6e6994fc854b5a495", "score": "0.6390714", "text": "public function testGetModel()\n {\n $this->todo('stub');\n }", "title": "" }, { "docid": "c8f0102fbfbd31aa189cced7c3dd69a5", "score": "0.638086", "text": "abstract public function getRestModels();", "title": "" }, { "docid": "df8712626ff7e7d776d944d3bd4395c6", "score": "0.63702357", "text": "public function testAppModelGetters(): void\n {\n echo __FUNCTION__ . PHP_EOL;\n\n /** @var Client $api */\n $api = $this->getMockApiClient('200.applicationGetStatus.json', true);\n\n //== grab the raw data from the first app in the result list\n $appData = $api->applicationGetStatus()['responseData']['applicationsList'][0];\n\n //== create app model\n $app = App::createFromApi($appData);\n\n //== test the shit out of it\n self::assertIsInt($app->getId());\n self::assertEquals($appData['id'], $app->getId());\n self::assertEquals($appData['appName'], $app->getName());\n self::assertEquals($appData['baseUrl'], $app->getUrl());\n }", "title": "" }, { "docid": "7447ba797d492e29d78634067022854c", "score": "0.631188", "text": "public function test_consultarConvenioUsingGET() {\n\n }", "title": "" }, { "docid": "21860933d7c4d758551f0f4dd86c1c05", "score": "0.6304743", "text": "public function testFindValidParams()\n {\n $results = array(\"response\" => array());\n $params = array('test' => true);\n\n $request = $this->buildMockRequest($results);\n $model = $this->getMock('\\DuoAuth\\MockModel', array('getRequest'));\n\n $model->expects($this->once())\n ->method('getRequest')\n ->will($this->returnValue($request));\n\n $model->find('/test/this','\\DuoAuth\\MockModel', $params);\n }", "title": "" }, { "docid": "5c5084da01a3d18e3878dff9220c3a43", "score": "0.6283823", "text": "public function getModels();", "title": "" }, { "docid": "5c5084da01a3d18e3878dff9220c3a43", "score": "0.6283823", "text": "public function getModels();", "title": "" }, { "docid": "bce3f840417d69452d17b490de5b63a2", "score": "0.6268763", "text": "public function testUsersGet()\n {\n }", "title": "" }, { "docid": "46d5984fefe55a3556b6851530b412c9", "score": "0.6258435", "text": "public function testReturnSingleInstance()\n {\n $results = array(\n \"response\" => array(\"test\" => \"testuser1\")\n );\n\n $request = $this->buildMockRequest($results);\n $model = $this->getMock('\\DuoAuth\\MockModel', array('getRequest'));\n\n $model->expects($this->once())\n ->method('getRequest')\n ->will($this->returnValue($request));\n\n $model->find('/test/this','\\DuoAuth\\MockModel');\n\n $this->assertEquals($model->test, 'testuser1');\n }", "title": "" }, { "docid": "f14e7958695621fa3260b1360f8514c4", "score": "0.6246864", "text": "function test_getAll()\n {\n //Arrange\n $name = \"Dog stuff\";\n $id = null;\n $test_category = new Category($name, $id);\n $test_category->save();\n\n $description = \"Wash the dog\";\n $category_id = $test_category->getId();\n $test_task = new Task($description, $id, $category_id);\n $test_task->save();\n\n $description2 = \"Water the dog\";\n $test_task2 = new Task($description2, $id, $category_id);\n $test_task2->save();\n\n //Act\n $result = Task::getAll();\n\n //Assert\n $this->assertEquals([$test_task, $test_task2], $result);\n }", "title": "" }, { "docid": "e4084d9fee8a053e4c933fccf9159ad0", "score": "0.6224151", "text": "function testSearch(){\n //Scenario 1\n $teams = $this->getTableArray('select * from tbl_team where name like \"%'.$_GET['name'].'%\" order by team_id DESC','name');\n\n $team = new Team('search');\n $team->name = $_GET['name'];\n $teamData = $team->search()->getData();\n $team = $this->getModelArray($teamData,'name');\n\n $this->assertEquals($teams,$team);\n }", "title": "" }, { "docid": "b62dbef151cdd1a2436e36e06924d674", "score": "0.6207529", "text": "public function testViewBooksAll()\n {\n \t$books = factory(Book::class)->create(); \n\n \t$resp = $this->get('/books');\n \t$resp->assertStatus(200);\n \t$resp->assertSee($books->title);\n \t$resp->assertSee($books->author);\n }", "title": "" }, { "docid": "243c982a4ec366b6be0be4ab2f827aa2", "score": "0.62007266", "text": "public function testNewWithLoad ()\n {\n $transactions = [];\n $client = create_mock_client(200, [], ['post-get-success.json'], $transactions);\n $model = new Model(55502267, true, $client);\n\n $this->assertCount(1, $transactions);\n\n $transaction = $transactions[0];\n $this->assertEquals('GET', $transaction['request']->getMethod());\n $this->assertEquals('www.juicer.io', $transaction['request']->getUri()->getHost());\n $this->assertEquals('/api/posts/55502267', $transaction['request']->getUri()->getPath());\n\n $this->assertEquals(55502267, $model->id);\n $this->assertEquals('Keltie Cochrane', $model->poster_name);\n }", "title": "" }, { "docid": "f152ebefb2d41749ae3ab31da3c772fa", "score": "0.6199731", "text": "public function test()\n {\n $productModel = new Product();\n // je récupère 1 enregistrement par son id\n $productList = $productModel->findAllByType(2); // $productList est un array d'instances de la classe Product\n\n dump($productList); // tester le résultat\n }", "title": "" }, { "docid": "660266fb7158315c2b6427ce2a3749dd", "score": "0.6180807", "text": "public function testIsModelSavingDataToDatabase()\n {\n $modelId = $this->saveTestData();\n $newModel = $this->model->load($modelId);\n $testData = $this->getTestData();\n $newModelData = [];\n foreach (array_keys($testData) as $key) {\n $newModelData[$key] = $newModel->getData($key);\n }\n $this->assertEquals($testData, $newModelData);\n }", "title": "" }, { "docid": "27d0a4a600253b9f7f510ba522070259", "score": "0.61706036", "text": "function testModel()\n {\n $club = Clubs::model()->findByPk(2);\n $this->assertTrue($club->model() instanceof Clubs);\n }", "title": "" }, { "docid": "fdfee4995fed660de5495101e573599a", "score": "0.6155575", "text": "public function testAllSuccess()\n {\n $this->assertTrue(sizeof($this->repo->all()) == $this->repo->getModel()->count());\n }", "title": "" }, { "docid": "9d6ea403884f8e098072f06df1dc6533", "score": "0.6144356", "text": "public function testRetrieveAll22()\n {\n }", "title": "" }, { "docid": "804f1fd93acfed6d9d1fc06fecccdb8a", "score": "0.6142094", "text": "public function testFindSingle()\n {\n $results = array(\n \"response\" => array(\n array(\"test\" => \"testuser1\")\n )\n );\n\n $request = $this->buildMockRequest($results);\n $model = $this->getMock('\\DuoAuth\\MockModel', array('getRequest'));\n\n $model->expects($this->once())\n ->method('getRequest')\n ->will($this->returnValue($request));\n\n $model->find('/test/this','\\DuoAuth\\MockModel');\n\n $this->assertEquals($model->test, 'testuser1');\n }", "title": "" }, { "docid": "5d53756e9f38abe972dbfbe38552b051", "score": "0.61416656", "text": "public function testModelsString() {\n\t\t$Action = $this\n\t\t\t->getMockBuilder('CrudAction')\n\t\t\t->disableOriginalConstructor()\n\t\t\t->setMethods(array('_handle'))\n\t\t\t->getMock();\n\t\t$Action->config('relatedModels', 'Post');\n\n\t\t$Listener = $this\n\t\t\t->getMockBuilder('RelatedModelsListener')\n\t\t\t->disableOriginalConstructor()\n\t\t\t->setMethods(array('_action'))\n\t\t\t->getMock();\n\n\t\t$Listener\n\t\t\t->expects($this->once())\n\t\t\t->method('_action')\n\t\t\t->with(null)\n\t\t\t->will($this->returnValue($Action));\n\n\t\t$result = $Listener->models();\n\t\t$expected = array('Post');\n\t\t$this->assertEquals($expected, $result);\n\t}", "title": "" }, { "docid": "c8e93aa3f6869d53b274ec2fb79f751b", "score": "0.6141243", "text": "public function a_company_can_be_fetched (){\n $response = $this->call('GET', 'api/companies/1');\n $this->assertEquals(200, $response->getStatusCode());\n }", "title": "" }, { "docid": "bf6ac0222673743e9b6c09c67a74170c", "score": "0.61235344", "text": "public function testModelsEmpty() {\n\t\t$Action = $this\n\t\t\t->getMockBuilder('CrudAction')\n\t\t\t->disableOriginalConstructor()\n\t\t\t->setMethods(array('_handle'))\n\t\t\t->getMock();\n\t\t$Action->config('relatedModels', null);\n\n\t\t$Listener = $this\n\t\t\t->getMockBuilder('RelatedModelsListener')\n\t\t\t->disableOriginalConstructor()\n\t\t\t->setMethods(array('_action'))\n\t\t\t->getMock();\n\n\t\t$Listener\n\t\t\t->expects($this->once())\n\t\t\t->method('_action')\n\t\t\t->with(null)\n\t\t\t->will($this->returnValue($Action));\n\n\t\t$result = $Listener->models();\n\t\t$expected = array();\n\t\t$this->assertEquals($expected, $result);\n\t}", "title": "" }, { "docid": "3f2250b8052f88ccb15e46551ebed59c", "score": "0.6111972", "text": "public function testShow()\n {\n $model = new Bubble();\n $model->save();\n\n $response = $this->callAsJson('GET', '/panneau/bubbles/'.$model->id);\n if ($response === $this) {\n $response = $this->response;\n }\n\n $modelData = json_decode(Bubble::find($model->id)->toJson(), true);\n $responseData = json_decode($response->getContent(), true);\n\n $this->assertEquals(200, $response->status());\n $this->assertEquals($modelData, $responseData);\n }", "title": "" }, { "docid": "292124b865e9b62ef99a3d8415d4ead8", "score": "0.6100847", "text": "public function testRetrieveOne12()\n {\n }", "title": "" }, { "docid": "fd201e9aaf33b981ddb09b745319b124", "score": "0.6089392", "text": "public function testGetListOfOrdersUsingGET()\n {\n }", "title": "" }, { "docid": "69294d8d505b1a5238c47ff222ef6fe2", "score": "0.6086265", "text": "public function testCreateResponsesWithModel()\n {\n $response = responder()->success($this->product)->respond();\n\n $this->assertEquals($this->responseData($this->product->toArray()), $response->getData(true));\n }", "title": "" }, { "docid": "6edf66a91408ca4390fd67c88ec00afc", "score": "0.60845137", "text": "function test_getAll()\n {\n //Arrange\n $store_name = \"nike store\";\n $test_store = new Store($store_name);\n $test_store->save();\n\n $store_name2 = \"addidas store \" ;\n $test_store2 = new Store($store_name2);\n $test_store2->save();\n\n //Act\n $result = Store::getAll();\n\n //Assert\n $this->assertEquals([$test_store2, $test_store], $result);\n }", "title": "" }, { "docid": "5ee9c1e47b0ce628a71093dba81dddb2", "score": "0.6084065", "text": "public function testProcurementManufacturersGet()\n {\n\n }", "title": "" }, { "docid": "ed529ccdc195d5fd4aafee77f09625aa", "score": "0.60729223", "text": "public function test_listarConveniosUsingGET() {\n\n }", "title": "" }, { "docid": "755277ba110e124d73308feea18f01aa", "score": "0.6059841", "text": "public function testSelect($modelname)\r\n {\r\n $obj= new BaseModel($modelname);\r\n $size= $obj->read($modelname);\r\n $this->assertEquals($size, $obj->read($modelname));\r\n }", "title": "" }, { "docid": "ae5b193ef0eed60050f08e15057279f7", "score": "0.6055378", "text": "public function testGetBankLinkAllUsingGet()\n {\n }", "title": "" }, { "docid": "5357bd32741054b48d2640e4ee07b57d", "score": "0.6049053", "text": "public function youCanFetchRelations()\n {\n // Arrange...\n factory(Lecture::class, 3)->create();\n\n // Act...\n $this->json('get', 'lectures', [\n 'with' => [\n 'subject'\n ]\n ]);\n\n // Assert...\n $this->seeSuccessStructure([\n '*' => [\n 'subject'\n ]\n ]);\n }", "title": "" }, { "docid": "21ab4b138bb6ff3bf2318d04934f60da", "score": "0.60479784", "text": "public function testCreateResponsesWithArrayOfModels()\n {\n $response = responder()->success($products = [$this->product])->respond();\n\n $this->assertEquals($this->responseData(array_map(function ($product) {\n return $product->toArray();\n }, $products)), $response->getData(true));\n }", "title": "" }, { "docid": "612503ad68b102eb5a2a1d2d0acda252", "score": "0.60389876", "text": "public function test_fetchMany() {\n\n }", "title": "" }, { "docid": "f0f0a35dd51f137b09c930bc89b9de35", "score": "0.6037209", "text": "public function test_we_can_find_all_the_tweets()\n {\n TweetFactory::createMany(3);\n //When I call findAll method on TweetModel\n $results = $this->tweetModel->findAll();\n\n //Then I should find 3 tweets\n $this->assertIsArray($results);\n $this->assertCount(3, $results);\n\n foreach ($results as $tweet) {\n $this->assertInstanceOf(Tweet::class, $tweet);\n }\n }", "title": "" }, { "docid": "124cb8d86762c169f98e5816051bf482", "score": "0.6028601", "text": "public function testGetOrdersDetailsUsingGET()\n {\n }", "title": "" }, { "docid": "f568819dc7a3012414713a3d77205ba2", "score": "0.6010816", "text": "public function testAPI()\n {\n\n //INSERT INITIAL DATA\n $testData = [\n 'premise' => 1,\n 'roomType' => 2,\n 'room' => '102',\n ];\n\n $testData2 = [\n 'premise' => 2,\n 'roomType' => 1,\n 'room' => '202',\n ];\n\n $retrieveIndex = $this->json('get', $this->baseUrl);\n $createResponse = $this->json('post', $this->baseUrl, $testData);\n $id = $createResponse->json('data.id');\n $retrieveResponse1 = $this->json('get', $this->baseUrl.'/'.$id);\n $updateResponse = $this->json('put', $this->baseUrl.'/'.$id, $testData2);\n $retrieveResponse2 = $this->json('get', $this->baseUrl.'/'.$id);\n $deleteResponse = $this->json('delete', $this->baseUrl.'/'.$id);\n\n $retrieveIndex->assertJsonPath('status', 'ok');\n $createResponse->assertJsonPath('status', 'ok');\n $retrieveResponse1->assertJsonPath('status', 'ok');\n $retrieveResponse2->assertJsonPath('status', 'ok');\n $updateResponse->assertJsonPath('status', 'ok');\n $deleteResponse->assertJsonPath('status', 'ok');\n $deleteResponse->assertJsonPath('data', \"{$id}\");\n }", "title": "" }, { "docid": "8b5426d297adb392300b7a2375c59d81", "score": "0.600906", "text": "public function companies_can_be_fetched() {\n $response = $this->call('GET', 'api/companies');\n $this->assertEquals(200, $response->getStatusCode());\n }", "title": "" }, { "docid": "05808b875e8c6d7d30ddf9d2f655e8f4", "score": "0.6002571", "text": "public function test_get_list()\n\t{\n\t\t$result = $this->ci->Book_model->get_list();\n\t\t$this->assertEquals(20, count($result['items']));\n\t\t$this->assertEquals('A Technique for Producing Ideas', $result['items'][4]->title);\n\t\t$this->assertEquals(2, $result['total_page']);\n\n\t\t// Now let's do some key word search\n\t\t$key_result = $this->ci->Book_model->get_list('Technique');\n\t\t$this->assertEquals(1, count($key_result['items']));\n\t\t$this->assertEquals('A Technique for Producing Ideas', $key_result['items'][0]->title);\n\t\t$this->assertEquals(1, $key_result['total_page']);\n\n\t\t// Use another key word to do a search\n\t\t$new_key_result = $this->ci->Book_model->get_list('art');\n\t\t$this->assertEquals(2, count($new_key_result['items']));\n\t\t$this->assertEquals('The Art of Possibility', $new_key_result['items'][0]->title);\n\t\t$this->assertEquals('The Art of War', $new_key_result['items'][1]->title);\n\t\t$this->assertEquals(1, $new_key_result['total_page']);\n\n\t}", "title": "" }, { "docid": "f9b1026a3c05454b3205866dace32e61", "score": "0.6001307", "text": "public function testGetInvalidModel() {\n\t\t$manager = new Manager();\n\n\t\t$mockFinder = $this->getMock('Skip\\Model\\ModelFinderInterface', array('getModelClassList'), array(), '', FALSE);\n\t\t$mockFinder->expects($this->once())\n\t\t\t->method('getModelClassList')\n\t\t\t->will($this->returnValue(array()));\n\t\t$manager->setFinder($mockFinder);\n\n\t\t$manager->get('unknown.model');\n\t}", "title": "" }, { "docid": "a0fc388d5f769c2ac0e968ebaf701707", "score": "0.6001112", "text": "public function testLoad()\n {\n $this->_adapter->load('pmjones');\n $expect = array('admin', 'root');\n $actual = $this->_adapter->getList();\n $this->assertEquals($actual, $expect);\n }", "title": "" }, { "docid": "ea0a49e367520557061e113e07700169", "score": "0.59964633", "text": "public function testGet()\n {\n $this->testingResource = new CreateTestResource();\n\n $testModel = App::make('TestModel');\n $testResource = $testModel->get($this->testingResource->user->id);\n\n $this->assertInstanceOf(TestModel::class, $testResource);\n $this->assertEquals($this->testingResource->userData['email'], $testResource->email);\n }", "title": "" }, { "docid": "663ac3e63335a76069d591d54722de46", "score": "0.5994915", "text": "public function testGet()\n {\n if (Product::all()->count() < 1) {\n factory(Product::class)->create();\n }\n\n $response = $this->getJson($this->endpoint);\n\n $response->assertStatus(200)->assertJsonStructure(['id', 'name', 'category', 'supplier', 'description', 'price', 'quantity', 'created_at', 'updated_at']);\n }", "title": "" }, { "docid": "ab6b66019325836495aaed353f766ea5", "score": "0.5992207", "text": "public function testSearchIdSuccess()\n {\n $searchModel = new SearchModel();\n $dataProvider = $searchModel->search(['id' => $this->model->id]);\n\n expect($dataProvider->getCount())->equals(1);\n expect($dataProvider->getModels())->containsOnlyInstancesOf(User::class);\n foreach ($dataProvider->getModels() as $model) {\n expect($model->id)->equals($this->model->id);\n expect($model->username)->equals($this->model->username);\n expect($model->auth_key)->equals($this->model->auth_key);\n expect($model->access_token)->equals($this->model->access_token);\n }\n }", "title": "" }, { "docid": "85ee9fdf264ee6f76417f51c1e4d54ed", "score": "0.59848154", "text": "public function testReadModel() {\n $attrs = $this->records['aa'];\n $model = new Backbone_Model($attrs, $this->model_options);\n $self = $this;\n \n // Check route used for retrieval\n $validationCallback = function($client) use ($self) {\n $self->assertEquals($self->baseUrl, $client->getUri()->getScheme().\"://\".$client->getUri()->getHost(), \"Client should make calls against \".$self->baseUrl);\n \t$self->assertEquals(\"/people/\".urlencode('aa'), $client->getUri()->getPath(), \"Client path should match /people/:id route\");\n \treturn true;\n };\n \n // Client expects one call to $client->request, which will return the json_encoded attrs on success\n $client = $this->buildClientMock(new Zend_Http_Response('200', array(), json_encode($attrs)), $validationCallback, \"GET\");\n \n // Build Sync object and call readModel\n $sync = new Backbone_Sync_Http(array('baseUrl'=>$this->baseUrl, 'client'=>$client));\n $response = $sync->readModel($model, $this->sync_options);\n \n // Check that result is the original attributes, and that they have been correctly decoded\n $this->assertEquals($attrs, $response, \"Http Sync should return retrieved attributes\");\n }", "title": "" }, { "docid": "ab042748ee1d812e6d9d0b4a40f8d35b", "score": "0.59800506", "text": "public function testGetFundingAllUsingGet()\n {\n }", "title": "" }, { "docid": "2bba11080e7304adb15f94f065024824", "score": "0.5978289", "text": "public function test_get_vehicle_test()\n {\n //crecion de usuario\n $user = new User();\n $user->name = 'amdin';\n $user->email = 'admin@mail.com';\n $user->password = 'admin312';\n $user->save();\n\n //autenticacion de usuario\n Auth::loginUsingId(1);\n\n //comprobacion de autenticacion\n $this->assertAuthenticated();\n\n // Datos de un proveedor\n $data['dat'] = array(\n \"plate\" => \"CWU256\",\n \"color\" => \"Blanco\",\n \"cylinder\" => \"1000\",\n \"name\" => \"GT\",\n \"model\" => \"2015\",\n \"brand\" => \"BMW\",\n );\n\n //agregar vehiculo\n $this->post(route('add_vehicle'), $data);\n\n //obtener un vehiculo con el id 1\n $response = $this->get('/vehiculos/1');\n\n //array esperado\n $expected = array(\n \"brand\" => $data['dat']['brand'],\n \"brand_id\" => \"1\",\n \"color\" => $data['dat']['color'],\n \"cylinder_capacity\" => $data['dat']['cylinder'],\n \"id\" => \"1\",\n \"license_plate\" => $data['dat']['plate'],\n \"model\" => $data['dat']['model'],\n \"name\" => $data['dat']['name'],\n );\n $response->assertSimilarJson(array($expected));\n }", "title": "" }, { "docid": "3641e75423d4f14fef38788a50c459db", "score": "0.59742546", "text": "function test_getBrands()\n {\n //Arrange\n $brand_name = \"nike\";\n $test_brand = new Brand($brand_name);\n $test_brand->save();\n\n $store_name = \"joes sandal store \";\n $test_store = new Store($store_name);\n $test_store->save();\n\n //Act\n $test_store->addBrand($test_brand);\n $result = $test_store->getBrands();\n\n //Assert\n $this->assertEquals([$test_brand], $result);\n }", "title": "" }, { "docid": "1916d7d2ec7436db71c9347c21705025", "score": "0.5963326", "text": "public function doFetchModel()\n {\n $make_id\t\t=\tInput::get('make');\n $wherecondition\t=\tarray($this->masterMakeIdfiled=>$make_id);\n $make \t\t\t= \tcommonmodel::getAllRecordsWhere($this->masterModelsTable,$wherecondition);\n if(count($make) != 0){\n\t\t\treturn response()->json(['Result'\t=>'7',\n\t\t\t\t\t\t\t\t\t\t'message'\t=>'success',\n\t\t\t\t\t\t\t\t\t\t'model_makeid'=>$make\n\t\t\t\t\t\t\t\t\t\t]);\n }\n else{\n return response()->json(['Result'=>'0',\n\t\t\t\t\t\t\t\t\t'message'=>'failure'\n\t\t\t\t\t\t\t\t\t\t]);\n }\n }", "title": "" }, { "docid": "cd130ee567c0373b9798e1e569122d21", "score": "0.5953026", "text": "public function testDynamicDataFindOneGet()\n {\n\n }", "title": "" }, { "docid": "2b3838615aa47b33456df98faa58a412", "score": "0.5947056", "text": "function testGetAll()\n {\n //Arrange\n $name = \"Work stuff\";\n $id = 1;\n $test_category = new Category($name, $id);\n $test_category->save();\n\n $name2 = \"Home stuff\";\n $id2 = 2;\n $test_category2 = new Category($name2, $id2);\n $test_category2->save();\n\n //Act\n $result = Category::getAll();\n\n //Assert\n $this->assertEquals([$test_category, $test_category2], $result);\n }", "title": "" }, { "docid": "00efa5d3a00ca154a4e02c0d1cafa523", "score": "0.5944128", "text": "public function testFetch()\n {\n $expect = array('admin', 'root');\n $actual = $this->_adapter->fetch('pmjones');\n $this->assertEquals($actual, $expect);\n }", "title": "" }, { "docid": "a05217f8168c2ff9b3225e10cdb6f677", "score": "0.59415734", "text": "public function testApiDataShow()\n {\n $response = $this->json('GET', '/api/show/2');\n $response->assertStatus(200);\n \n }", "title": "" }, { "docid": "0ca5e84df5de519214350ca7b14ec845", "score": "0.5932086", "text": "public function testGetList()\n {\n //create user\n $administrator = $this->CreateAdministrator();\n $lisUser = $this->CreateAdministratorUser($administrator);\n\n //now we have created adminuser set to current controller\n $this->controller->setLisUser($lisUser);\n $this->controller->setLisPerson($administrator);\n\n $this->CreateAdministrator();\n $this->request->setMethod('get');\n $result = $this->controller->dispatch($this->request);\n $response = $this->controller->getResponse();\n\n $this->PrintOut($result, false);\n\n $this->assertEquals(200, $response->getStatusCode());\n $this->assertEquals(1, $result->success);\n $this->assertGreaterThan(0, count($result->data));\n }", "title": "" }, { "docid": "e4f5952537937947d9e806ddd897340d", "score": "0.5927281", "text": "public function testRead()\n {\n $model = $this->model();\n\n $contributorsData = [];\n foreach ($model->contributors as $contributor) {\n $contributorsData[] = [\n 'type' => 'contributors',\n 'id' => $contributor->getKey()\n ];\n }\n\n $data = [\n 'type' => 'seasons',\n 'id' => $model->getKey(),\n 'attributes' => [\n 'created-at' => $model->created_at->format('c'),\n 'updated-at' => $model->updated_at->format('c'),\n 'title' => $model->title,\n 'description' => $model->description,\n 'image-url' => $model->image_url,\n 'number' => $model->number\n ],\n 'relationships' => [\n 'podcast' => [\n 'data' => [\n 'type' => 'podcasts',\n 'id' => $model->podcast->getKey(),\n ],\n ],\n 'contributors' => [\n 'data' => $contributorsData,\n 'meta' => [\n 'total' => count($contributorsData)\n ]\n ]\n ]\n ];\n\n $this->doRead($model)\n ->assertReadResponse($data);\n }", "title": "" }, { "docid": "4169b5a5aee8fd1cb932a92ed799903a", "score": "0.59235156", "text": "private function test_retrieve() {\n $this->load->library('unit_test');\n\n $this->id = \"2\";\n\n $test = $this->retrieve();\n $result = true; // Result: a user has been found!\n $name = \"test_retrieve\";\n\n $this->unit->run($test, $result, $name);\n\n $this->id = null; // Remove, just in-case.\n\n echo $this->unit->report();\n }", "title": "" }, { "docid": "59610432e066b714a88d03b4ebbfef24", "score": "0.59150285", "text": "public function test_post_models()\n {\n $brand = CarBrand::first();\n\n $response = $this->post('/api/models', [\n 'name' => 'NewAwesomeModel',\n 'brand_id' => $brand->id\n ], $this->defaultHeaders);\n\n $response->assertStatus(200);\n\n CarModel::where('name', 'NewAwesomeModel')\n ->delete();\n }", "title": "" }, { "docid": "959a2ffea73003e5fcfad95c940cae6c", "score": "0.59119284", "text": "protected function findModel()\n {\n\n }", "title": "" }, { "docid": "cc57350fbf7e125fab3ea1db5868959b", "score": "0.59104884", "text": "public function testAppsGetCollection()\n {\n }", "title": "" }, { "docid": "eae8a6255f947ff439fd8c7ee14bf22c", "score": "0.5908249", "text": "public function testManagerAction()\n {\n $client = static::createClient();\n $crawler = $client->request('GET', '/list');\n\n $this->assertTrue($client->getResponse()->isOk(), 'Client should return 200 code.');\n $this->assertEquals(3, $crawler->filter('ul > li')->count(), 'There should be generated 3 li elements.');\n }", "title": "" }, { "docid": "c3df209a6028419c515a4f374db3fcd3", "score": "0.5906895", "text": "public function testGetList()\n {\n //create user\n $administrator = $this->CreateAdministrator();\n $lisUser = $this->CreateAdministratorUser($administrator);\n\n //now we have created adminuser set to current controller\n $this->controller->setLisUser($lisUser);\n $this->controller->setLisPerson($administrator);\n\n $this->CreateVocation();\n $this->request->setMethod('get');\n $result = $this->controller->dispatch($this->request);\n $response = $this->controller->getResponse();\n $this->assertEquals(200, $response->getStatusCode());\n $this->assertEquals(1, $result->success);\n\n $this->PrintOut($result, false);\n\n $this->assertGreaterThan(0, count($result->data));\n }", "title": "" }, { "docid": "f97b61eb241c9ba967446da8b566a163", "score": "0.5906163", "text": "public function testRelationsTestData() {\n // lets find a requested certifications that has some data (802.11n)\n $rc = RequestedCertifications::model()->find('cert_id=:cert_id', array(':cert_id'=>Certifications::CERT_N_APPROVED)); // from database\n //print \"rc = \";print_r($rc);\n $this->assertTrue($rc instanceof RequestedCertifications, \"is not an instance of RequestedCertifications\");\n $td_list = $rc->test_data;\n //$td_list = TestData::model()->find('request_id=:request_id', array(':request_id'=>$rc->request_id)); // from database\n //print \"td_list = \";print_r($td_list);\n $this->assertTrue(is_array($td_list), \"is not an array\");\n //print_r($td_list[0]);\n $this->assertTrue($td_list[0] instanceof TestData, \"is not instance of TestData\");\n\n }", "title": "" }, { "docid": "7c9db0916e7628614c349393b4b48c15", "score": "0.5901618", "text": "function test_getAll()\n {\n //Arrange\n $stylist_name = \"Ed Scissorhands\";\n $test_stylist = new Stylist($stylist_name);\n $test_stylist-> save();\n\n $stylist_name2 = \"Flowbee\";\n $test_stylist2 = new Stylist($stylist_name2);\n $test_stylist2-> save();\n\n //Act\n $result = Stylist::getAll();\n\n //Assert\n $this->assertEquals([$test_stylist, $test_stylist2], $result);\n }", "title": "" }, { "docid": "348abfa43d67bb94e68ad8f51883a3c0", "score": "0.58982307", "text": "public function testUserGet()\n {\n\n }", "title": "" }, { "docid": "b545de80faf6ca6bbcbdd7c760b7766c", "score": "0.58948267", "text": "public function testModel()\r\n {\r\n $model = Geo::create();\r\n $this->reloadModel($model);\r\n $this->assertInstanceOf(Geo::class, $model);\r\n }", "title": "" }, { "docid": "af0fe0df2209430f9b7a824a4dee914b", "score": "0.5891459", "text": "public function testApiGet()\n { \n $this->json('GET', '/api/ttl')->assertTrue(true);\n \n }", "title": "" }, { "docid": "aeb651d445357ceda751f84b9b7f0b78", "score": "0.5887042", "text": "public function test_get_repositories_data()\n {\n $rc=new RepositoryController();\n $this->assertInstanceOf(Repository::class,$rc->getRepositoriesData()->first());\n }", "title": "" }, { "docid": "be16c0c91c4e4bbdb118d32d3b5493fd", "score": "0.5881426", "text": "public function testGetAllRanks()\n {\n // Lets create some models to test\n $rank = \\Phoenix\\Models\\Unit\\Rank::create(['name' => 'Private', 'pay_grade'=> 'PV1', 'abbreviation' => 'PV1']);\n $rank2 = \\Phoenix\\Models\\Unit\\Rank::create(['name' => 'Private First Class', 'pay_grade'=> 'PV2', 'abbreviation' => 'PV2']);\n\n // Actual Test\n $this->json('GET','api/unit/ranks')->seeJson(['name'=> 'Private First Class']);\n }", "title": "" }, { "docid": "a78384ba5a98e5f69335bb541f7113e3", "score": "0.5879294", "text": "public function testLoadValidData()\n {\n $model = new \\DuoAuth\\Model();\n $model->setProperties(array(\n 'test1' => array(\n 'type' => 'string'\n ),\n 'test2' => array(\n 'type' => 'string'\n ),\n 'test3' => array(\n 'type' => 'array',\n 'map' => '\\DuoAuth\\User'\n )\n ));\n $data = array(\n 'test1' => 'foo',\n 'test2' => 'bar',\n 'test3' => array(array('username' => 'testuser1'))\n );\n $model->load($data);\n $result = $model->toArray();\n\n $this->assertEquals($result['test1'], 'foo');\n $this->assertEquals($result['test2'], 'bar');\n $this->assertEquals($result['test3'][0]->username, 'testuser1');\n }", "title": "" }, { "docid": "7225a2b1a70e0fcd647ce427cfb16e5e", "score": "0.5871607", "text": "public function test_browse_records()\n {\n $this->factory(3)->create();\n\n $response = $this->getJson($this->base);\n\n $response->assertOk();\n\n $response->assertJsonStructure([\n 'meta',\n 'links',\n 'data' => [\n '*' => [\n 'id',\n\n // ... Here is where you should put the expected schema of response records.\n ]\n ]\n ]);\n }", "title": "" }, { "docid": "7af79e18e5a99fe9e661e78778b46e53", "score": "0.5866028", "text": "public function testSearchesV2Get()\n {\n }", "title": "" }, { "docid": "1f282b6cee48f1785dbd4aa96150bab4", "score": "0.58560663", "text": "public function testObjectModel(){\n\n $user = User::first();\n\n $gallery_1 = new Gallery();\n $gallery_1 -> weight = 1;\n $gallery_1 -> file = \"my_path1\";\n\n $gallery_2 = new Gallery();\n $gallery_2 -> weight = 2;\n $gallery_2 -> file = \"my_path2\";\n\n $user -> gallery_model = [];\n $user -> gallery_model -> add($gallery_1);\n\n $user -> gallery_model = $user -> gallery_model -> merge([$gallery_2]);\n\n $index = $user -> gallery_model -> search(function($item, $key){\n\n return $item -> weight == 1;\n });\n\n $user -> gallery_model -> get($index);\n $user -> gallery_model -> pull($index); \n\n $user -> gallery_model -> add($gallery_1);\n\n $this -> assertEquals(2,$user -> gallery_model -> count());\n $this -> assertEquals(collect([1 => $gallery_2,2 => $gallery_1]) -> toArray(),$user -> gallery_model -> toArray());\n\n $user -> save();\n\n $user = User::first();\n\n foreach($user -> gallery_model as $k){\n }\n }", "title": "" }, { "docid": "a01910885ad977014db040f1d1a4a9ca", "score": "0.5852587", "text": "public function testGet(){\n\n\t\t$nano = new Nano(DB);\n\t\t$alien = $nano->use('alien');\n\n\t\t$rs = $alien->get('Hudson');\n\n\t\t//$this->assertTrue();\n\t}", "title": "" }, { "docid": "e70e234d4864ee23a243d2d46575eebc", "score": "0.5847636", "text": "public function testIndex()\n { \n $expected = \\App\\Card::select('id', 'name')->orderBy('name')->get();\n $result = $this->controller->index();\n $this->assertEquals($expected, $result);\n }", "title": "" }, { "docid": "8d2d3e4340bfc09c60657b47475424d0", "score": "0.58426344", "text": "public function testTraerTodasLasRecetas()\n {\n \t$response = $this->json('GET', '/api/recetas');\n \t$response->assertStatus(200)->assertJsonCount(10);\n }", "title": "" }, { "docid": "fbc12a198e215f3a2ba12add1d8321bd", "score": "0.5842561", "text": "public function Testindex()\n {\n $result = $this->get($this->url);\n\n $result->assertOK();\n }", "title": "" }, { "docid": "8ee7336883e9102b3428c2728e933c07", "score": "0.5840031", "text": "public function testGet()\n {\n /** @var Collection $jobs */\n $jobs = Job::get();\n $this->assertNotNull($jobs);\n\n $this->outputResults($jobs);\n }", "title": "" }, { "docid": "42613a621c2854392610fafea066fda7", "score": "0.5823417", "text": "public function test_listing_all_books()\n {\n $book = $this->getJson(\"api/books/{$this->books[0]->id}\")['data'];\n $response = $this->getJson('api/books');\n $this->assertContains($book, $response['data']);\n $response->assertSee($book['name']);\n $response->assertStatus(200);\n }", "title": "" }, { "docid": "5250bef6c0b8cc7a500f225d46c50423", "score": "0.58199424", "text": "public function testUsersController()\n {\n $response = $this->get('/api/users');\n $response->assertStatus(200);\n\n //should have data key\n $response->assertJson(['data' => true]);\n\n $response = $this->get('/api/users/1');\n $response->assertStatus(200);\n\n //should have data key\n $response->assertJson(['data' => true]);\n }", "title": "" }, { "docid": "074eb56e50096d98f6bffde460a586b6", "score": "0.5811336", "text": "public function testCreateResponsesWithCollectionOfModels()\n {\n $response = responder()->success($products = collect([$this->product]))->respond();\n\n $this->assertEquals($this->responseData($products->toArray()), $response->getData(true));\n }", "title": "" }, { "docid": "65dd451a370ff2ae74d3537286cf82f0", "score": "0.5808326", "text": "public function test_index()\n {\n // 5 record added to database\n Tag::factory()->count(5)->create();\n\n // request\n $response = $this->get('api/tags');\n\n // assert response data count \n $response->assertJsonCount(5, 'data');\n\n // assert response code 200\n $response->assertStatus(200);\n }", "title": "" }, { "docid": "3f2d5a1d4be32ee4e5b48e46e1f5a0cc", "score": "0.5807228", "text": "public function testGetAll()\n {\n $job = factory('App\\Models\\Job')->create();\n $this->json(\n 'GET',\n '/v1/jobs'\n )->seeStatusCode(Response::HTTP_OK);\n\n $response = json_decode($this->response->getContent(), true);\n $this->assertEquals($response['data'][0], $job->toArray());\n }", "title": "" }, { "docid": "f4a63070fbb4dc08e0742866cd361a9c", "score": "0.5806104", "text": "public function testItemGet()\n {\n\n }", "title": "" }, { "docid": "6996a459f43e6d3462dd3c2253197d00", "score": "0.5803956", "text": "public function testModelsTrue() {\n\t\t$Model = $this\n\t\t\t->getMockBuilder('Model')\n\t\t\t->disableOriginalConstructor()\n\t\t\t->setMethods(array('getAssociated'))\n\t\t\t->getMock();\n\n\t\t$Action = $this\n\t\t\t->getMockBuilder('CrudAction')\n\t\t\t->disableOriginalConstructor()\n\t\t\t->setMethods(array('_handle'))\n\t\t\t->getMock();\n\t\t$Action->config('relatedModels', true);\n\n\t\t$Listener = $this\n\t\t\t->getMockBuilder('RelatedModelsListener')\n\t\t\t->disableOriginalConstructor()\n\t\t\t->setMethods(array('_action', '_model'))\n\t\t\t->getMock();\n\n\t\t$Listener\n\t\t\t->expects($this->once())\n\t\t\t->method('_action')\n\t\t\t->with(null)\n\t\t\t->will($this->returnValue($Action));\n\t\t$Listener\n\t\t\t->expects($this->once())\n\t\t\t->method('_model')\n\t\t\t->with()\n\t\t\t->will($this->returnValue($Model));\n\t\t$Model\n\t\t\t->expects($this->at(0))\n\t\t\t->method('getAssociated')\n\t\t\t->with('belongsTo')\n\t\t\t->will($this->returnValue(array('Post')));\n\t\t$Model\n\t\t\t->expects($this->at(1))\n\t\t\t->method('getAssociated')\n\t\t\t->with('hasAndBelongsToMany')\n\t\t\t->will($this->returnValue(array('Tag')));\n\n\t\t$result = $Listener->models();\n\t\t$expected = array('Post', 'Tag');\n\t\t$this->assertEquals($expected, $result);\n\t}", "title": "" }, { "docid": "abae053827f2656193e5bff254050a03", "score": "0.5803946", "text": "public function testBasicTest()\n {\n // $response = $this->get('test_laravel/products');\n $response = $this->get('test_laravel/products');\n\n $response->assertStatus(200);\n }", "title": "" }, { "docid": "45010ab39d8ca8f74b88dc8498b20dee", "score": "0.58036554", "text": "public function test_vehicle_find_view_test()\n {\n //crecion de usuario\n $user = new User();\n $user->name = 'amdin';\n $user->email = 'admin@mail.com';\n $user->password = 'admin312';\n $user->save();\n\n //autenticacion de usuario\n Auth::loginUsingId(1);\n\n //comprobacion de autenticacion\n $this->assertAuthenticated();\n\n // Datos de un vehiculo\n $data['dat'] = array(\n \"plate\" => \"CWU256\",\n \"color\" => \"Blanco\",\n \"cylinder\" => \"1000\",\n \"name\" => \"GT\",\n \"model\" => \"2015\",\n \"brand\" => \"BMW\",\n );\n //Acceso a la funcion que permite agregar un vehiculo\n $this->post(route('add_vehicle'), $data);\n\n $find['dat'] = array(\n 'search' => 'CWU256'\n );\n\n //llamado a la vista de vehiculo\n $response = $this->get(route('view_vehicle', $find));\n\n //comprobacion de visualizacion correcta por parte de el usuario\n $response->assertSee(['Gestión de vehículos','Agrega, actualiza o elimina registros de vehículos',\n 'ID','Matricula','Color','Cilindraje','Nombre','Modelo','Marca',\n \"1\",$data['dat']['plate'],$data['dat']['color'],$data['dat']['cylinder'],$data['dat']['name'],$data['dat']['model'],$data['dat']['brand']\n ]);\n\n }", "title": "" }, { "docid": "5e63e9409de85600b900d254d38b2dd3", "score": "0.58021986", "text": "public function testGetAll()\n {\n $res = DB::getAll('configs', null, array('id', 'ckey', 'cval'));\n $this->assertTrue(is_array($res));\n $this->assertNotEmpty($res);\n }", "title": "" }, { "docid": "cdef7f8e496931f01e96795fe77c4a7a", "score": "0.5795907", "text": "public function testGetModelConfigurationReturnsArrayForExistingObject()\n {\n $flexModel = new FlexModel($this->defaultIdentifier);\n $flexModel->load($this->loadFlexModelTestFile(), $this->cacheDirectory);\n\n $this->assertInternalType('array', $flexModel->getModelConfiguration('Test'));\n }", "title": "" }, { "docid": "4fb1f366c69c51a954f364dd9df3ee22", "score": "0.57940465", "text": "public function testIndex()\n {\n $this->withoutExceptionHandling();\n //creamos los products\n factory(Product::class, 5)->create();\n\n //$response = $this->json('GET', '/api/products');\n $response = $this->getJson('/api/products');\n\n $response->assertSuccessful();\n $response->assertHeader('content-type', 'application/json');\n $response->assertJsonCount(5, 'data');\n }", "title": "" }, { "docid": "68a6a350d23284029aee70cf9558640c", "score": "0.5790759", "text": "public function testDesignPermissionSetsFindOneGet()\n {\n\n }", "title": "" } ]
74e559e1833426a71dfd7104f3da4459
Get the last response
[ { "docid": "ac163f1182a45cad60036e1d9d0320d1", "score": "0.8446258", "text": "public function getLastResponse()\n {\n return $this->__getLastResponse();\n }", "title": "" } ]
[ { "docid": "61d059dea27a6cd2b3ec27f988e3a0dd", "score": "0.8972521", "text": "public function getLastResponse();", "title": "" }, { "docid": "38173ea94083ee2a987b7decad24e727", "score": "0.8838057", "text": "public function getLastResponse(){\n\t\treturn $this->lastResponse;\n\t}", "title": "" }, { "docid": "4c7b040b97565c014d615554c7467821", "score": "0.87834257", "text": "function getLastResponse()\n\t{\n\t\treturn $this->lastResponse;\n\t}", "title": "" }, { "docid": "a1bab1b2b1510856cdbf37c7720aa43f", "score": "0.8731906", "text": "public function lastResponse() {\n return $this->lastResponse;\n }", "title": "" }, { "docid": "0f340918e86b32ee8e34d68b33c5e471", "score": "0.8722278", "text": "function lastResponse();", "title": "" }, { "docid": "e8e35a014523f041c623ac503d6eed5b", "score": "0.871195", "text": "public function getLastResponse(){\n return $this->_lastResponse;\n }", "title": "" }, { "docid": "2f600d6a27832794d8b43be960854a47", "score": "0.87040496", "text": "public function lastResponse()\n\t{\n\t\treturn $this->_last_response;\n\t}", "title": "" }, { "docid": "562070230508250af43425d2f1a32ed1", "score": "0.8639467", "text": "public function getLastResponse() {\n return $this->lastResponse;\n }", "title": "" }, { "docid": "09e7d545375ccfcdeccdf4413f5af52f", "score": "0.85855395", "text": "public function getLastResponse(){\n return $this->net->getLastResponse();\n }", "title": "" }, { "docid": "a291397349ab72c119f0ee39452a3af3", "score": "0.849234", "text": "public function getLastResponse()\n {\n return $this->lastResponse;\n }", "title": "" }, { "docid": "a291397349ab72c119f0ee39452a3af3", "score": "0.849234", "text": "public function getLastResponse()\n {\n return $this->lastResponse;\n }", "title": "" }, { "docid": "a291397349ab72c119f0ee39452a3af3", "score": "0.849234", "text": "public function getLastResponse()\n {\n return $this->lastResponse;\n }", "title": "" }, { "docid": "a291397349ab72c119f0ee39452a3af3", "score": "0.849234", "text": "public function getLastResponse()\n {\n return $this->lastResponse;\n }", "title": "" }, { "docid": "1600866049b3ab2a93b9534d51da4e4a", "score": "0.8487038", "text": "public static function last_response()\n\t{\n\t\treturn self::$_last_response;\n\t}", "title": "" }, { "docid": "59236122fb870b99f718240e8a6cdec4", "score": "0.84726185", "text": "public function getLastResponse()\n {\n return $this->obj_last_response;\n }", "title": "" }, { "docid": "912cbbbebffe654822948ead4e7e46a3", "score": "0.8472229", "text": "public function getLastResponse()\n {\n return $this->_lastResponse;\n }", "title": "" }, { "docid": "a42413193d98c5f7e1ab41abfef280c1", "score": "0.843892", "text": "public function getLastResponse() {\n return $this->_lastResponse;\n }", "title": "" }, { "docid": "1cb2ee0d06c5a282e52aebe038b67a9b", "score": "0.83674127", "text": "public function getLastResponse()\n {\n return $this->responseHistory->getLastResponse();\n }", "title": "" }, { "docid": "c97d5bf9b98c98517382fb6334ea1589", "score": "0.83194035", "text": "public function getLastResponse(){\n return APICall::$last_response;\n }", "title": "" }, { "docid": "1dac6fe04dcf5ca26e4b73bcea846f8f", "score": "0.8129657", "text": "protected function _getLastResponse() {\n return $this->apiHandle->getLastResponse();\n }", "title": "" }, { "docid": "3e84d33202ab1712b91d44c5cef3c79b", "score": "0.78377146", "text": "public function getLastResponse() : string\n {\n return $this->lastResponse;\n }", "title": "" }, { "docid": "25da8a3ce556fd58de5c44e169970ee6", "score": "0.7831414", "text": "public function getLastParsedResponse()\n {\n return $this->_lastParsedResponse;\n }", "title": "" }, { "docid": "4dfdc53d0ddd7312e3a89ce5ec9bbe86", "score": "0.7828834", "text": "public function printLastResponse()\n {\n print_r( $this->lastResponse );\n }", "title": "" }, { "docid": "b28a3a1b4e44e12b1001ae33bcdc6357", "score": "0.7810612", "text": "public function lastResponse()\n {\n if($this->response instanceof HttpResponse)\n {\n return $this->response->getBody();\n }\n return null;\n }", "title": "" }, { "docid": "0af7977ff826ffda7cd0a3c7954d1661", "score": "0.77932084", "text": "public function getLastRawResponse()\n {\n return $this->_lastRawResponse;\n }", "title": "" }, { "docid": "ca58858301d7b82851ad5cc6e67d8639", "score": "0.7713041", "text": "public function getLastResponseData()\n\t{\n\t\treturn $this->_lastResponseData;\n\t}", "title": "" }, { "docid": "84e875e535291bccadc1a1f7deceda83", "score": "0.7503994", "text": "function getLastRequest()\n\t{\n\t\treturn $this->lastRequest;\n\t}", "title": "" }, { "docid": "501a0bdb838335fc0f3361eeae5fea4b", "score": "0.7497834", "text": "public function getLatestResponse() {\n return $this->_latestResponse;\n }", "title": "" }, { "docid": "ca9d5fe317ff8d8c12b54e05ef4a47d1", "score": "0.7469389", "text": "public function getLastResponse() : ?Response\r\n {\r\n return $this->lastResponse;\r\n }", "title": "" }, { "docid": "ce2294b56ffe828f9f49a2497f52bfba", "score": "0.7445083", "text": "public function getLastApiResponse ()\n {\n return $this->lastApiResponse;\n }", "title": "" }, { "docid": "5aa5e82d3310723ded775c2b82ad3e6e", "score": "0.74314195", "text": "public function getLastResponseRaw()\n {\n return $this->lastResponseRaw;\n }", "title": "" }, { "docid": "680c1322705c5c8f7a97cf44e3db0485", "score": "0.74213934", "text": "public function getLastResponse()\n {\n if (null === $this->lastResponse) {\n throw new \\LogicException('No request sent yet.');\n }\n\n return $this->lastResponse;\n }", "title": "" }, { "docid": "0aa1144941346b1693509500c5a867c6", "score": "0.739003", "text": "private function printLastResponse()\n\t{\n\t\tif ($this->_config()->isLogEnabled($this->storeId)) { \n Mage::log('Mailup: printLastResponse');\n Mage::log($this->soapClient->__getLastResponse());\n }\n\t}", "title": "" }, { "docid": "cfba1968a1e6cd0c54ff1931fc939bf5", "score": "0.7317814", "text": "private function lastRawResponse(): ?string\n {\n return $this->lastResponse;\n }", "title": "" }, { "docid": "ef8d9f8537fb529ca86ae6eec294e760", "score": "0.729989", "text": "public function getLastGetResult() {\n return $this->last_get_result;\n }", "title": "" }, { "docid": "299705330d4db178871ef0a85ce899b3", "score": "0.7292202", "text": "public function getLastRequest()\r\n\t{\r\n\t\treturn $this->lastRequest;\r\n\t}", "title": "" }, { "docid": "c9bd07f31dfdfd8c15c7cc659e5ca64b", "score": "0.72916025", "text": "public function getLastRequest() {\n return $this->_last_request;\n }", "title": "" }, { "docid": "64065a84632afaf8f8b328658924e5b7", "score": "0.7211107", "text": "public function getLastRequest()\n {\n return $this->_lastRequest;\n }", "title": "" }, { "docid": "0349cf69b4892f0bc3927189092c9c88", "score": "0.72056055", "text": "public function getLastRequest()\n {\n return $this->obj_last_request;\n }", "title": "" }, { "docid": "e10c0881e87989d1dc9d10f2213cb0a8", "score": "0.7203862", "text": "public function getLastRequest()\n {\n return $this->lastRequest;\n }", "title": "" }, { "docid": "e10c0881e87989d1dc9d10f2213cb0a8", "score": "0.7203862", "text": "public function getLastRequest()\n {\n return $this->lastRequest;\n }", "title": "" }, { "docid": "e10c0881e87989d1dc9d10f2213cb0a8", "score": "0.7203862", "text": "public function getLastRequest()\n {\n return $this->lastRequest;\n }", "title": "" }, { "docid": "0dd3a3f113973feebe9d0fb68757e70f", "score": "0.718439", "text": "public function getLastRequest() {\n return $this->_lastRequest;\n }", "title": "" }, { "docid": "b3c0312dc544dd1803c96cd993fd8c74", "score": "0.7175698", "text": "protected function getLastRequest()\n {\n echo $this->soap->__getLastRequest();\n exit;\n }", "title": "" }, { "docid": "0e42b77ede1b8f4431c6c25a0ec621a5", "score": "0.71733403", "text": "function lastRequest();", "title": "" }, { "docid": "87b4f97976396626c9bc4dce33be99a2", "score": "0.7166811", "text": "public function lastRequest()\n\t{\n\t\treturn $this->_last_request;\n\t}", "title": "" }, { "docid": "f080def6996851a1e069b932ba6fb673", "score": "0.71572345", "text": "public function getLastReply()\n {\n }", "title": "" }, { "docid": "5692e79cb7263e25909057dd9ef009a4", "score": "0.7135028", "text": "public function getLastRequest()\n {\n return $this->__getLastRequest();\n }", "title": "" }, { "docid": "0fe174e9c9665db743012a23326f8250", "score": "0.70870125", "text": "public function printLastResponse()\n\n {\n echo (\n $this->getSession()->getCurrentUrl().\"\\n\\n\".\n $this->getSession()->getPage()->getContent()\n );\n }", "title": "" }, { "docid": "f8b4f1244e0dfeb4b06e4374014dd1fa", "score": "0.698612", "text": "public function getLastStatus(){\n return $this->net->getLastResponse()->getStatus();\n }", "title": "" }, { "docid": "c5e7ef89e8a2610c8748a0db18886e8c", "score": "0.6954783", "text": "function GetLastResult()\n {\n \treturn $this->results;\n }", "title": "" }, { "docid": "e644d076810d85f7f44e7df36babe7aa", "score": "0.69373727", "text": "public function last()\n {\n $this->get();\n\n return end($this->results);\n }", "title": "" }, { "docid": "3c19fd83444610a87354eac57ed74c5e", "score": "0.69213414", "text": "public function getLastResponse(): ?ResponseInterface\n {\n return $this->lastResponse;\n }", "title": "" }, { "docid": "8432cd3eef5f04eb9999ffb1bb5f874b", "score": "0.69169915", "text": "public function getLastResponse(): ?ResponseInterface\n {\n return $this->responseHistory->getLastResponse();\n }", "title": "" }, { "docid": "671ae1684ba69ab3bfa60757de65b8d9", "score": "0.684082", "text": "protected function getLastRequest()\n {\n return $this->getHistoryStack()[0]['request'];\n }", "title": "" }, { "docid": "1923ec3e71803706556312d8c823f91c", "score": "0.68202686", "text": "public function getLastResponse(): ?TelegramResponse\n {\n return $this->lastResponse;\n }", "title": "" }, { "docid": "0602c68785a200888e5f1c1952f7e130", "score": "0.68010783", "text": "public function lastResult()\n {\n return $this->lastResult;\n }", "title": "" }, { "docid": "e588fa875bdaca5500e0717875afe943", "score": "0.67762345", "text": "public function getLastRequestInfo() {\n\t\treturn $this->lastRequestInfo;\n\t}", "title": "" }, { "docid": "2dac3faa777617635642610497d1ddbe", "score": "0.6767781", "text": "function showlastrequest()\r\n\t{\r\n\t\tif(!isset($this->packet))\r\n\t\t return;\r\n\t\telse\r\n\t\t return $this->packet;\r\n\t}", "title": "" }, { "docid": "dff80ca8556515213f27e1f55cea8a46", "score": "0.67537415", "text": "public function getLast(){\n\t\treturn $this->last;\n\t}", "title": "" }, { "docid": "977f13f410249d15cfc7fec84d61cc11", "score": "0.674351", "text": "public function getLastResponseCode()\n {\n return $this->lastResponseCode;\n }", "title": "" }, { "docid": "43bd7b97101d5e7773a7a810b135a2b7", "score": "0.6742197", "text": "public function getLastResult()\n {\n return $this->lastResult;\n }", "title": "" }, { "docid": "43bd7b97101d5e7773a7a810b135a2b7", "score": "0.6742197", "text": "public function getLastResult()\n {\n return $this->lastResult;\n }", "title": "" }, { "docid": "43bd7b97101d5e7773a7a810b135a2b7", "score": "0.6742197", "text": "public function getLastResult()\n {\n return $this->lastResult;\n }", "title": "" }, { "docid": "e88d5e06eaa0522afee312fbe83ffee3", "score": "0.67177665", "text": "public function get_last_data_received() {\n\t\treturn $this->_last_data_received;\n\t}", "title": "" }, { "docid": "e40567201d2fb9dcf8b9eefa4e5e779d", "score": "0.67174745", "text": "public function getLastApiCall() {\n\t\treturn $this->lastApiCall;\n\t}", "title": "" }, { "docid": "9b2d70c70be3732373b49d022b946e31", "score": "0.66677296", "text": "public function getLast()\n {\n return $this->last;\n }", "title": "" }, { "docid": "edf6e4134af532e57a0b20ee4a6c0321", "score": "0.6657118", "text": "public function getLast();", "title": "" }, { "docid": "49ca3e562860e5c7facaa9c8277c4524", "score": "0.66531134", "text": "public function get_last_url_request() {\n\t\treturn $this->_last_url_request;\n\t}", "title": "" }, { "docid": "9a8b57bfd3f72d396cd88d0e049c280f", "score": "0.66260725", "text": "public function getLastOutput()\n {\n return $this->lastOutput;\n }", "title": "" }, { "docid": "9a8b57bfd3f72d396cd88d0e049c280f", "score": "0.66260725", "text": "public function getLastOutput()\n {\n return $this->lastOutput;\n }", "title": "" }, { "docid": "80f0a30699aa6f59b127f48d07936811", "score": "0.6623398", "text": "public function getLast() {\n $response = Referat::model()->lastRecord()->find();\n if (empty($response)) {\n throw new Exception('Nothing found', 404);\n }\n return $response;\n }", "title": "" }, { "docid": "26a2279adec7ac325cf7949c091b6cb1", "score": "0.6588773", "text": "public function last()\n {\n $value = $this->get(array_key_last($this->content));\n return $this->return($value);\n }", "title": "" }, { "docid": "b5a1fc92f42544623c40d7cdac2ae5aa", "score": "0.656809", "text": "public function getLast()\n {\n return end($this->_data);\n }", "title": "" }, { "docid": "eec05a1a23ae4d986926b2a83c6735ee", "score": "0.6566964", "text": "public function printLastRequest()\n {\n print_r( $this->lastRequest );\n }", "title": "" }, { "docid": "c0e5415bb6f142c1700fa68aaa731bb6", "score": "0.65629846", "text": "public function getLastOutput() {\n return $this->lastLog;\n }", "title": "" }, { "docid": "fa343bf6d8dc5b2bdee63625dd892c26", "score": "0.65389025", "text": "public function getLastRequest() : string\n {\n return $this->lastRequest;\n }", "title": "" }, { "docid": "369dcb99e2893f200ab8843a82f550a1", "score": "0.6512619", "text": "public function lastDownload() {\n $url = self::REST_URL . sprintf('last/%s/transactions.%s', $this->token, $this->parser->getExtension());\n return $this->parser->parse(\\h4kuna\\CUrl::download($url));\n }", "title": "" }, { "docid": "5ae28934015889bf3a7a069d52c69d2e", "score": "0.6507433", "text": "function last_page() {\n\t\treturn $this->get($this->page_count());\n\t}", "title": "" }, { "docid": "b0a596e5c003592965dfe21efc181ef7", "score": "0.65062374", "text": "public function testLast(): void\n {\n $this->assertEquals(\n self::$getBlockResponse['tx'][3],\n $this->response->key('tx')->last()\n );\n\n $this->assertEquals(\n self::$getBlockResponse['tx'][3],\n $this->response->last('tx')\n );\n\n $this->assertEquals(\n end(self::$getBlockResponse),\n $this->response->last()\n );\n\n $this->assertEquals(\n self::$getBlockResponse['hash'],\n $this->response->key('hash')->last()\n );\n }", "title": "" }, { "docid": "d711e5b8ca3d5b7df5ed1360848eb565", "score": "0.6472782", "text": "public function last()\n {\n return $this->data[count($this->data) - 1];\n }", "title": "" }, { "docid": "81845ce618c0b6c1320a3abc780789f6", "score": "0.6462654", "text": "public function getLast()\n {\n return $this->getByIndex($this->count() - 1);\n }", "title": "" }, { "docid": "65734c4420f4ef93702a4d5443196212", "score": "0.6457782", "text": "final public function last()\n {\n return error_get_last();\n }", "title": "" }, { "docid": "1573e5be0eea9364ec6fb8aeb86ec53c", "score": "0.6419559", "text": "public function getLast() {\n return end($this->items);\n }", "title": "" }, { "docid": "2526e81c4550653ff4d1863762dfca09", "score": "0.64000976", "text": "public function getLastMatchedRequest() {\n return $this->lastMatchedRequest;\n }", "title": "" }, { "docid": "e0bf101f8e8fddc6cf2ff5c4a05026db", "score": "0.6391948", "text": "public function getLast() {\r\n return $this->value[$this->count - 1];\r\n }", "title": "" }, { "docid": "d03c757a41fe6ba0ace1b0b9ffdea24b", "score": "0.63807195", "text": "function get_response(){\n\t\treturn $this->response;\n\t}", "title": "" }, { "docid": "c67c8e2832ce67ec18f7949aa2f9aaf8", "score": "0.6377866", "text": "public function getLastFeed(){\n return $this->_lastFeed;\n }", "title": "" }, { "docid": "deec615f72a6cf5551d22b1f35b895b3", "score": "0.6375222", "text": "function getLastRecord()\n {\n \treturn $this->_impl->getLastRecord();\n }", "title": "" }, { "docid": "95085cfda0648e10adb521cd734323fc", "score": "0.63751024", "text": "public function getLastResponseHeaders()\n {\n return $this->__getLastResponseHeaders();\n }", "title": "" }, { "docid": "175e4f4a7890e3d4cb5460c1db948677", "score": "0.6362505", "text": "public function getLastOutput()\n {\n return $this->processor->getLastOutput();\n }", "title": "" }, { "docid": "18333666e42eccc506c64542c5250d42", "score": "0.63413596", "text": "public function resetLastResponse()\n {\n $this->response = new Response();\n }", "title": "" }, { "docid": "18333666e42eccc506c64542c5250d42", "score": "0.63413596", "text": "public function resetLastResponse()\n {\n $this->response = new Response();\n }", "title": "" }, { "docid": "9b754a2e457cc11ec7cbec4e10e194d5", "score": "0.63347423", "text": "public function last() {\n $index = count($this->data) - 1;\n return $this->data[$index];\n }", "title": "" }, { "docid": "969021e44a0e640a2bf661735e3f14b6", "score": "0.6319309", "text": "public function getLastRequestContent() {\n\t\tif (isset($this->request->content)) {\n\t\t\treturn $this->request->content;\n\t\t}\n\t}", "title": "" }, { "docid": "845005addd0d2420aa72a0945fecca6a", "score": "0.6313504", "text": "public function getLastHttpCode()\n {\n return $this->httpCode;\n }", "title": "" }, { "docid": "be43e705ede24bdbab02145080c00de2", "score": "0.6310177", "text": "public function GetLastResponseTime() {\n try {\n $responseTimeElements =\n $this->GetLastResponseDom()->getElementsByTagName('responseTime');\n foreach ($responseTimeElements as $responseTimeElement) {\n return $responseTimeElement->nodeValue;\n }\n } catch (DOMException $e) {\n trigger_error('Failed to load response into DOM: '\n . $e->getMessage(), E_USER_NOTICE);\n return \"null\";\n }\n }", "title": "" }, { "docid": "9d81aa31718e77005a536eb1a56da777", "score": "0.6306141", "text": "public function lastEvent(): Event\n {\n if ($this->endEvent) {\n return $this->endEvent;\n }\n\n if ($events = $this->iterableEvents()) {\n return $events[count($events) - 1];\n }\n\n if ($this->responseEvent) {\n return $this->responseEvent;\n }\n\n return $this->calledEvent;\n }", "title": "" }, { "docid": "e7489576476da52906dd35760dea2393", "score": "0.6298567", "text": "public function getLastRequestTime()\n {\n return $this->lastRequest;\n }", "title": "" }, { "docid": "812c123a3dee113a8babeb2b08b12c57", "score": "0.62952524", "text": "public function last();", "title": "" } ]
972499302c169f21ea61b70e96990c89
Store a newly created resource in storage.
[ { "docid": "7eb2e5d16ba1d69aebbe160899d09951", "score": "0.0", "text": "public function store()\n\t{\n\t\t\n\n\n\n\t\t$post = new Post;\n\n\t\t$post->title=$_POST['titre'];\n\t\t$post->abstract=$_POST['abstract'];\n\t\t$post->content=$_POST['content'];\n\n\n\t\tif (Input::hasFile('photo'))\n\t\t{\n //\n\t\t\tif (Input::file('photo')->isValid())\n\t\t\t{\n\n\n\t\t\t\t$destinationPath=public_path().\"\\assets\\images\";\n\n\t\t\t\t$extention= Input::file('photo')->getClientOriginalExtension();\n\t\t\t\t($fileName=$this->upload()) or $fileName='';\n\n\t\t// var_dump($fileName);\n\n\t\t\t\ttry {\n\n\t\t\t\t\tInput::file('photo')->move($destinationPath, $fileName.\".\".$extention);\n\t\t\t// return \"okk\";\n\n\t\t\t\t} catch(Exception $e) {\n\n\t\t\t// return \"KOO : \".$destinationPath.$fileName.$extention;\n\t\t\t\t}\n\n\n\n\t\t\t\t$post->url_thumbnail=$fileName.\".\".$extention;\n\n\t\t\t}\n\t\t}\n\t\telse{\n\t\t\t$post->url_thumbnail=\"\";\t\t\t\n\t\t}\n\n\n\t\t$post->status='publish';\n\t\t$post->user_id=Auth::user()->id;\n\t\t$post->save();\n\n\t\treturn Redirect::to(\"admPost\");\n\n\t}", "title": "" } ]
[ { "docid": "efa639da1b8f6cd79b8705d95edb8349", "score": "0.68727493", "text": "public function store(Request $request, storage $model)\n {\n \n Storage::create($request->all());\n\n return redirect()->route('storage.index')->withStatus(__('storage successfully created.'));\n }", "title": "" }, { "docid": "7f1b50bd5f058d4a055b1fd3805dc442", "score": "0.6826213", "text": "public function store(ResourceCreateRequest $request) {\n\n $resource = new Resource([\n 'title' => $request->title,\n 'slug' => $this->toSlug($request->title).'_'.uniqid(),\n 'review' => $request->review,\n 'category_id' => $request->category_id\n ]);\n\n Auth::user()->resources()->save($resource);\n return response()->json($resource);\n }", "title": "" }, { "docid": "39c00340e6c87bd36e30c00a6ef8a08c", "score": "0.64319444", "text": "public function store()\n\t{\n\t\t$rules = array(\n\t\t\t'name' \t=> \t'required',\n\t\t\t'route' =>\t'unique:resources,route',\n\t\t\t);\n\t\t$validator = Validator::make(Input::all(), $rules);\n\n\t\tif ($validator -> fails()) {\n\t\t\treturn Redirect::to('resource')\n\t\t\t\t->withErrors($validator)\n\t\t\t\t->withInput(Input::all());\n\t\t}\n\t\telse{\n\t\t\t$resource = new Resource;\n\t\t\t$resource->name \t= \tInput::get('name');\n\t\t\t$resource->route \t= \tInput::get('route');\n\t\t\t$resource->save();\n\n\t\t\tSession::flash('message', 'Successfully added');\n\t\t\treturn Redirect::to('resource');\n\n\t\t\t\n\n\t\t}\n\t}", "title": "" }, { "docid": "701667213f0c046b2658bd8d8db97d9d", "score": "0.63883317", "text": "public function store(StorageRequest $request)\n {\n $storage = new Storage;\n $storage->name = $request->name;\n $storage->company_id = $request->user()->id;\n $storage->save();\n\n return redirect()->to('/storage/'.$request->name);\n }", "title": "" }, { "docid": "c3f5dd47f337ee79762d2af65e90ef1b", "score": "0.6368418", "text": "public function store(Request $request)\n {\n //\n $this->authorize('create', Resource::class);\n $input=$request->all();\n $resource= Resource::create($input);\n return redirect('/resource/'.$resource->id);\n }", "title": "" }, { "docid": "03f9a1cfca780e7f0a082544fc457677", "score": "0.63657933", "text": "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "title": "" }, { "docid": "03f9a1cfca780e7f0a082544fc457677", "score": "0.63657933", "text": "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "title": "" }, { "docid": "03f9a1cfca780e7f0a082544fc457677", "score": "0.63657933", "text": "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "title": "" }, { "docid": "f9a45db12ffc582d34c4975c5c6686e9", "score": "0.6347347", "text": "public function store()\n\n\t{\n\n\t\t//\n\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d25e328608bea4c8f7f39852c1099ca8", "score": "0.6342437", "text": "public function store()\n\t{\n\t\t//\n\t}", "title": "" } ]
c817b04ee2975c71b204cb660cdebaa3
\brief get assigned variable
[ { "docid": "6e7618188ed1662cfa480d99dcc8ea65", "score": "0.0", "text": "public function getTemplateVars($var)\n {\n return $this->get_template_vars($var);\n }", "title": "" } ]
[ { "docid": "4f289ee41083abe19969ed1e4fa85046", "score": "0.7314918", "text": "public function getVariable()\n\t\t{\n\t\treturn $this->varible;\n\t\t}", "title": "" }, { "docid": "043eeba9ad06236beb37add6867cab7c", "score": "0.7058957", "text": "public function getVariable()\n\t{\n\t\treturn $this->_variable;\n\t}", "title": "" }, { "docid": "04a0df3d7c7f563bc0fa34f113711d58", "score": "0.68231", "text": "function getVariable($variable = null)\n {\n // and sets variables thing on the current record.\n // so shouldn't need to adjust the $this-> set\n // of variables and can refactor that out.\n\n // All variables should be callable by\n // $this->variables_thing.\n\n // The only Thing variable of use is $this->from\n // which is used to set the identity for\n // self-tallies. (Thing and Agent are the\n // only two role descriptions.)\n\n if ($variable == null) {\n $variable = 'variable';\n }\n\n $this->variables_thing->db->setFrom($this->identity);\n $this->variables_thing->$variable = $this->variables_thing->Read(\n array($this->agent, $variable)\n );\n\n // And then load it into the thing\n // $this->$variable = $this->variables_thing->$variable;\n // $this->variables_thing->flagGreen();\n\n return $this->variables_thing->$variable;\n }", "title": "" }, { "docid": "cb25a9d23648aabcebe1910a48a2156d", "score": "0.6800811", "text": "public function getVar()\n\t{\n\t\treturn $this->_var;\n\t}", "title": "" }, { "docid": "bd010878ca3d531ce279e7aae7d91af3", "score": "0.6773572", "text": "public function get_variable($name)\r\n {\r\n return $this->variables_list[$name];\r\n }", "title": "" }, { "docid": "ec87fb8c2197fc59afe0c59bd79d88dc", "score": "0.6705958", "text": "function get($name) {\n\t\t// Variable inside this block\n\t\tif( isset($this->vars[$name]) )\n\t\t\treturn $this->vars[$name];\n\t\t\n\t\t// Variable in one of parents\n\t\tif( $this->parent !== null )\n\t\t\treturn $this->parent->get($name);\n\t\t\n\t\t// If the tree's root block does not have the variable, it does not exist\n\t\treturn null;\n\t}", "title": "" }, { "docid": "1d154eacdf4eebd25b7c537dafa9bcfd", "score": "0.6680047", "text": "public function getItemVariableName();", "title": "" }, { "docid": "27e1dde3c9bf6a11722afd01c699dad2", "score": "0.6677623", "text": "protected function getVariable($name) {\n $this->drupal->getDriver('drupal');\n return variable_get($name);\n }", "title": "" }, { "docid": "65be0b355354f70607fb50cc32827cb7", "score": "0.667652", "text": "function __get($name) {\n if (isset($this->_vars[$name]))\n return $this->_vars[$name];\n }", "title": "" }, { "docid": "2193dfe210a2985c96ad59d2c9c03703", "score": "0.6572128", "text": "function get($varname) {\n return $this->finish($this->get_var($varname));\n }", "title": "" }, { "docid": "5d7a6e63a69d154741f22ee5400a5d65", "score": "0.65616035", "text": "public static function get( $name )\n\t{\n\t\treturn self::$vars[$name];\n \t}", "title": "" }, { "docid": "294299e212517b1fd38e61aad72c73bc", "score": "0.64670783", "text": "public function getVariable($variableName);", "title": "" }, { "docid": "35e45bbc00dcd977e5485aa1fe6f8665", "score": "0.6459315", "text": "public function assignVariables();", "title": "" }, { "docid": "41c18f3abaa002899e373fb000a24ed5", "score": "0.64399105", "text": "abstract public function get_var($var_name);", "title": "" }, { "docid": "1811079900f9c815742899680502d00c", "score": "0.6397555", "text": "public function getVar($name, $storage);", "title": "" }, { "docid": "a93d63a7b4756a18d5c9307409e0918f", "score": "0.63716924", "text": "public function get(string $name) {\r\n return $this->vars[$name] ?? null;\r\n }", "title": "" }, { "docid": "7f596e9b0bf319de3da2bce41984000a", "score": "0.63092357", "text": "function get_var($id, $single = false)\n\t{\n\t\treturn get_instance()->kbcore->variables->get($id, $single);\n\t}", "title": "" }, { "docid": "85c9cbd2443b55a2918519fc8c5f4bd9", "score": "0.6279776", "text": "function getvar ($name) {\r\n if (empty($name)) {\r\n return (null);\r\n }\r\n $result = @db_query(\"SELECT VALUE FROM VARIABLE WHERE NAME = '\".$name.\"';\");\r\n if (db_num_rows($result) == 1) {\r\n $row = db_fetch_array($result);\r\n return (unserialize($row['VALUE']));\r\n }\r\n else {\r\n return (null);\r\n }\r\n}", "title": "" }, { "docid": "c602e7c4a5c1f54cdda59b3451f46b20", "score": "0.6223093", "text": "public function __get($key){\n\t\treturn $this->vars[$key];\n\t}", "title": "" }, { "docid": "376400e6d4e88fd001fa3d5298dac773", "score": "0.62120533", "text": "public function __get($var){\n\t\treturn $this->_has_var() ? $this->_var : $this->get($var);\n\t}", "title": "" }, { "docid": "a3d43bf72f9a4d2076dc5e38f147b094", "score": "0.6206455", "text": "public function getVariable(string $name)\n {\n return isset($this->variables[$name]) ?\n $this->variables[$name] :\n null;\n }", "title": "" }, { "docid": "ffcc0bed9c09369857a6883e17d5bf84", "score": "0.6199085", "text": "function get($key)\n {\n return $this->vars[$key];\n }", "title": "" }, { "docid": "a566c315cbb287b5a50ccc3b2e97a011", "score": "0.61923593", "text": "public function __get($varname)\n {\n return $this->$varname = Smarty_Template::$call_stack[0]->tpl_obj->_getVariable($varname, Smarty_Template::$call_stack[0]->parent);\n }", "title": "" }, { "docid": "1f3dec62621c620a2353fd59a0ad8a72", "score": "0.61849904", "text": "protected function assignment()\n\t{\n\t\treturn $this->assignment;\n\t}", "title": "" }, { "docid": "835968c30504e54809dffbcf80219330", "score": "0.61811656", "text": "public function getPointerVariable()\n {\n return $this->pointerVariable;\n }", "title": "" }, { "docid": "1f260879bffce0f2b7ab6b93869bfce3", "score": "0.61763424", "text": "function _variable_get($name, $default = NULL) {\n global $conf;\n\n return isset($conf[$name]) ? $conf[$name] : $default;\n}", "title": "" }, { "docid": "3b132fb5e5613e8581af10a6fd7bd4fd", "score": "0.614856", "text": "function get_var($var_name) {\n\t\t$vars = this::get_vars();\n\t\t\n\t\tif (isset($vars[$var_name])) {\n\t\t\treturn $vars[$var_name];\t\n\t\t} else {\n\t\t\treturn null;\n\t\t}\n\t}", "title": "" }, { "docid": "ce8620063f5799fba6d0765683f1ef6a", "score": "0.61248106", "text": "function get_var($key)\n\t{\n\t\tif (!$this->use_cache)\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\treturn ($this->var_data['.'][0][$key]);\n\t}", "title": "" }, { "docid": "e44424ec1d885f65f6fda480f1ff64f3", "score": "0.6112163", "text": "function __get($name)\r\n {\r\n return $this->GetVar($name);\r\n }", "title": "" }, { "docid": "96484b87c02a5a528aa18b7694e6a4ae", "score": "0.6110602", "text": "function &get($name) {\n if(isset($this->data[$name])) {\n return $this->data[$name];\n } else {\n $var = null;\n return $var;\n } // if\n }", "title": "" }, { "docid": "1b8d2b8374a830de03fc4fb398c6ebb3", "score": "0.60964006", "text": "public function assigned();", "title": "" }, { "docid": "678c86381599e0ccf036d4911ad30935", "score": "0.6094343", "text": "public function __get($key)\n\t{\n\t\tif(isset($this->vars[$key]))\n\t\t{\n\t\t\treturn $this->vars[$key];\n\t\t}\n\t}", "title": "" }, { "docid": "e4afce5200be09f0cede626eafb516e4", "score": "0.6091412", "text": "public function getVar($key) {\n\t\treturn $this->vars[$key];\n\t}", "title": "" }, { "docid": "f0676a6b7a0ef8cf8ec99648b6e989f3", "score": "0.60773236", "text": "public function getVar($key) {\n\t\treturn $this->_vars[$key];\n\t}", "title": "" }, { "docid": "aa0ab8091098e4ffdc1652edc7bbb9e3", "score": "0.60742563", "text": "function getBindVariableName() ;", "title": "" }, { "docid": "89bf3dd0e425665797c130f6bb140487", "score": "0.60407656", "text": "function test_for_local_variable(){\r\n \t\t$local_variable = 'local variable';\r\n\r\n \t\techo '<p>variable \"local_variable\" equals: ' . $local_variable . '</p>';//value for this echo should be 'local variable'\r\n \t}", "title": "" }, { "docid": "4b2f28933c584a0372c3b0b7fd6772d7", "score": "0.6031655", "text": "public function &get($name) {\n $var = NULL;\n if (isset($this->data[$name])) {\n $var = &$this->data[$name];\n }\n return $var;\n }", "title": "" }, { "docid": "9b05c3c6373feea0fcfcf465509fce3d", "score": "0.60208976", "text": "public function __get($key)\n {\n return $this->vars[$key];\n }", "title": "" }, { "docid": "3de2bbe9dfb006409748748871c2fc64", "score": "0.6019099", "text": "public function __get($name)\n {\n return $this->get_var($name);\n }", "title": "" }, { "docid": "137c6dc0969f4b9b624414227dde5a63", "score": "0.601725", "text": "public function variable ( $name ) {\n\n if(true === $this->variableExists($name))\n return $this->_variables[$name];\n\n if(0 !== preg_match('#\\\\\\old\\(\\s*(\\w+)\\s*\\)#i', $name, $matches))\n return $this->_variables[$name] = new \\Hoa\\Test\\Praspel\\Constructor\\Old(\n $this,\n $matches[1]\n );\n elseif($name == '\\result')\n return $this->_variables[$name] = new \\Hoa\\Test\\Praspel\\Constructor\\Result(\n $this,\n $name\n );\n\n return $this->_variables[$name] = new \\Hoa\\Test\\Praspel\\Variable(\n $this,\n $name\n );\n }", "title": "" }, { "docid": "62c79144176d58b280be0df99bb182f4", "score": "0.60076195", "text": "public function get($var){\n\t\treturn $this->has($var) ? $this->_vars[$var] : false;\n\t}", "title": "" }, { "docid": "ec7939f74fdb59d0fab17d7a8b512d3a", "score": "0.59963673", "text": "public function getVariable ( $name ) {\n\n if(false === $this->variableExists($name))\n throw new \\Hoa\\Test\\Praspel\\Exception(\n 'Variable %s is not found.', 0, $name);\n\n return $this->_variables[$name];\n }", "title": "" }, { "docid": "941fc0be8a1ff1e2a3f4107c8513189d", "score": "0.59798485", "text": "public function __get($varName) {\n return isset($this->data[$varName]) ? $this->data[$varName] : NULL;\n }", "title": "" }, { "docid": "0b9c4feeab8574d4cb182ce13995a898", "score": "0.5970724", "text": "function variable_get($name, $default) {\n global $conf;\n\n return isset($conf[$name]) ? $conf[$name] : $default;\n}", "title": "" }, { "docid": "2f9e06be73af7cc2fa6153d0add88041", "score": "0.59554607", "text": "public static function get($name){\n\t\treturn self::$viewVars[$name];\n\t}", "title": "" }, { "docid": "dfeed42e64a0a95c3491b1a778b3fb28", "score": "0.59511614", "text": "function get($element) {\r\n\t\t\tif (!isset($this->privateVars[$element])) return 0;\t\t\t\n\t\t\treturn $this->privateVars[$element];\r\n\t\t}", "title": "" }, { "docid": "0171d4e1ae328ad94f83af5173341f70", "score": "0.5948577", "text": "function get_var($var=false)\n {\n if($var !== false)\n {\n if(isset($this->vars[$var]))\n {\n return $this->vars[$var];\n }\n else\n {\n return false;\n }\n }\n else\n {\n return array_keys($this->vars);\n }\n }", "title": "" }, { "docid": "68425722c3f76074df5c4d2b4558ec4f", "score": "0.5944791", "text": "public function getDataVariable($name) {\n return $this->data[$name];\n }", "title": "" }, { "docid": "903f5a9c8ced2558d106fe58d7f7e8bf", "score": "0.59429073", "text": "public function getVars()\n {\n return ModUtil::getVar($this->name);\n }", "title": "" }, { "docid": "903f5a9c8ced2558d106fe58d7f7e8bf", "score": "0.59429073", "text": "public function getVars()\n {\n return ModUtil::getVar($this->name);\n }", "title": "" }, { "docid": "eb0815c2fb393952ed8d20c871415cec", "score": "0.5879562", "text": "public function getBindVariableName() {}", "title": "" }, { "docid": "d20b02ed645816ae8b45765e3576d48b", "score": "0.58770204", "text": "public function get($name)\n {\n if(isset($this->vars[$name]))\n {\n return $this->$name;\n }\n }", "title": "" }, { "docid": "ec29dc8dae6cf8bb28d63faf993e30d9", "score": "0.58731604", "text": "function GetVar($name, $default = \"\") {\n\t\tif (isset($_REQUEST[$name])) return @$_REQUEST[$name];\n\t\tif (isset($_COOKIE[$name])) return @$_COOKIE[$name];\n\t\tif (isset($_GET[$name])) return urldecode(@$_GET[$name]);\n\t\tif (isset($_POST[$name])) return @$_POST[$name];\n\t\tif (isset($GLOBALS[$name])) return @$GLOBALS[$name];\n\t\treturn $default;\n\t}", "title": "" }, { "docid": "88fd44824d1026db1e1675c5a9515d76", "score": "0.5854624", "text": "public function __get($varname)\r\n\t{\r\n\t\tif(isset($this->_record->{$varname}))\r\n\t\t\treturn $this->_record->{$varname};\r\n\t}", "title": "" }, { "docid": "d7204f2a8b13a485d450e5605133612e", "score": "0.5830552", "text": "public function __get($var)\n\t{\n\t\treturn Core::getTPL()->get($var);\n\t}", "title": "" }, { "docid": "017697c54d870866687e01ad123ce48e", "score": "0.582835", "text": "public function getVariable($name)\n\t{\n\t\t$variables = $this->getTemplateVariables();\n\t\treturn (array_key_exists($name, $variables)) ? $variables[$name] : FALSE;\n\t}", "title": "" }, { "docid": "21272ad1ef85425f8cbd3e7c9e57db50", "score": "0.58220637", "text": "public function getVariable(string $key): string|array|object\n {\n return $this->variables[$key] ?? '';\n }", "title": "" }, { "docid": "daa3d9ee208b13645ea78424a2f9bfde", "score": "0.58189136", "text": "public function getVar(string $name):? string;", "title": "" }, { "docid": "3f675e3569478827b717fa53d287bca7", "score": "0.5812439", "text": "function get_var_by($field, $match = null)\n\t{\n\t\treturn get_instance()->kbcore->variables->get_by($field, $match);\n\t}", "title": "" }, { "docid": "58053f2d6f16d4dad56c1e8e768eb43c", "score": "0.5807926", "text": "static function get($key) {\n\t\tif ( self::$vars != null ) {\n\t\t\tif ( array_key_exists($key, self::$vars)) {\n\t\t\t\treturn self::$vars[$key];\n\t\t\t} else {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t} else {\n\t\t\treturn null;\n\t\t}\n\t}", "title": "" }, { "docid": "f7ed443f2b1b4892adbb704365e5db4b", "score": "0.5801401", "text": "public static function get($_name)\n {\n if(array_key_exists($_name, self::$vars)) {\n return self::$vars[$_name];\n } else {\n return '';\n }\n }", "title": "" }, { "docid": "bba395f77a29d6316a65e7b9583ea138", "score": "0.5794838", "text": "public function getVariable($which)\n {\n if (isset($this->data[$which])) {\n return $this->data[$which];\n } elseif (isset($this->config['data'])) {\n return $this->config['data'][$which];\n }\n\n return null;\n }", "title": "" }, { "docid": "01a50668e14dcfa944cf7d2f84b8dfd6", "score": "0.579001", "text": "public function assign()\n {\n return $this->repo->assign();\n }", "title": "" }, { "docid": "fabf2c5de5984269f2a0de0f0cdb356a", "score": "0.57808554", "text": "public function getVariables();", "title": "" }, { "docid": "fabf2c5de5984269f2a0de0f0cdb356a", "score": "0.57808554", "text": "public function getVariables();", "title": "" }, { "docid": "02c9e8171a0fcda0a743e6fb77dd0407", "score": "0.5756048", "text": "function getVariable( $var_name ){\n return isset( $_GET[ $var_name ] ) ? $_GET[ $var_name ] : $_POST[ $var_name ];\n}", "title": "" }, { "docid": "0324b64903f91d6fa01c576b6db6f024", "score": "0.5754532", "text": "public static function get(&$var) {\n return (isset($var)) ? $var : null;\n }", "title": "" }, { "docid": "dd8d3d1e550ff6a34c843ff922ef0627", "score": "0.5747951", "text": "public function getGetVariable($variable_name = NULL) {\n if (empty($variable_name)) {\n return $this->data['get'];\n }\n if (isset($this->data['get'][$variable_name])) {\n return $this->data['get'][$variable_name];\n }\n }", "title": "" }, { "docid": "95ff14a80f542ef8bf2719d5ebabcc5e", "score": "0.5746856", "text": "function assign( $blockName, $varName, &$variable )\n {\n if ( isset( $this->BlockValues[$blockName][$varName] ) )\n $variable = $this->BlockValues[$blockName][$varName];\n else\n return false;\n return true;\n }", "title": "" }, { "docid": "73f1a56f79fda8482f733e9b96634221", "score": "0.5737391", "text": "public function getVariableName()\n {\n return $this->variableName;\n }", "title": "" }, { "docid": "9020f7eee8ea1f4cc7b20eb1ec36eccb", "score": "0.57333094", "text": "public function get_var($name)\n {\n // Check if variable exists\n for ($i=0, $len=count($this->vars); $i<$len; $i++) {\n if ($this->vars[$i]['name'] == $name) {\n return $this->vars[$i]['name'];\n }\n }\n }", "title": "" }, { "docid": "01c83a3e935e801e033dafaac593b4f8", "score": "0.5730497", "text": "public function get_var($name)\n {\n if(!$this->has_var($name))\n throw new View_Exception('Accessing undefined view variable ('.$this->_path.'::'.$name.').');\n \n return $this->_vars[$name];\n }", "title": "" }, { "docid": "055c5b2f4be09b5c04261a1a2fd8805e", "score": "0.57134205", "text": "public function getAssigned() {\n\t\treturn $this->assigned;\n\t}", "title": "" }, { "docid": "e451fd188e723a4f99382dc33a9e1b01", "score": "0.5711807", "text": "public static function getVars()\n \t{\n \t\treturn self::$vars;\n \t}", "title": "" }, { "docid": "39f7b45627d9fba42b78be82a99d7c35", "score": "0.57099533", "text": "public function getVariableName(): ?string\n {\n return $this->variableName;\n }", "title": "" }, { "docid": "562e1f07b3f56db6fe9629baa5312d0f", "score": "0.57085997", "text": "public function & getVarRef($baseName)\n {\n if (!$this->varExists($baseName)) {\n throw new CTE_Engine_Exception('variable basename not found');\n }\n \n return $this->initVars[$baseName];\n }", "title": "" }, { "docid": "c34a4dcf1055e6e5345e0267239e8535", "score": "0.57061785", "text": "function get_var($varname) {\n if (!is_array($varname)) {\n if (isset($this->varvals[$varname])) {\n $str = $this->varvals[$varname];\n } else {\n $str = \"\";\n }\n if ($this->debug & 2) {\n printf (\"<b>get_var</b> (with scalar) <b>%s</b> = '%s'<br>\\n\", $varname, htmlentities($str));\n }\n return $str;\n } else {\n reset($varname);\n while(list($k, $v) = each($varname)) {\n if (isset($this->varvals[$v])) {\n $str = $this->varvals[$v];\n } else {\n $str = \"\";\n }\n if ($this->debug & 2) {\n printf (\"<b>get_var:</b> (with array) <b>%s</b> = '%s'<br>\\n\", $v, htmlentities($str));\n }\n $result[$v] = $str;\n }\n return $result;\n }\n }", "title": "" }, { "docid": "8b7660aa8306170f6d442397e0f8fa08", "score": "0.5702475", "text": "public function getVariables()\n\t{\n\t\treturn $this->aVariables;\n\t}", "title": "" }, { "docid": "0275b439b6c738dc9eb0cc6d801f0dfd", "score": "0.5696432", "text": "public function getCustomVariable()\n {\n return $this->_registry->registry('id');\n }", "title": "" }, { "docid": "1ce1157331e54775ef137c5b1191fc50", "score": "0.5688949", "text": "public function __get($variable)\n {\n return $this->contents[$variable];\n }", "title": "" }, { "docid": "3534320926652ea0faa94696a0294605", "score": "0.5675242", "text": "function getValue($var_name){\n return $_SESSION[$var_name];\n }", "title": "" }, { "docid": "c07b62b22e1048a1ad1bc1dfd9d858c8", "score": "0.56738734", "text": "public function getSetVariables() {}", "title": "" }, { "docid": "cb8cf53911195fe2bcaee8ac64fb3ef1", "score": "0.56726784", "text": "public function getAgiVar()\n {\n return $this->get(self::_AGI_VAR);\n }", "title": "" }, { "docid": "fb33c8878786c3c65355b89da75580b4", "score": "0.565898", "text": "function shm_get_var ($shm_identifier, $variable_key) {}", "title": "" }, { "docid": "cadd9339c715d379b3646442f2bf6f0c", "score": "0.5657809", "text": "public function &epGet($var_name) {\n\n // is var oid?\n if ($var_name == 'oid') {\n return $this->ep_object_id;\n }\n\n // get the best-matched var name\n if (!in_array($var_name, $this->ep_cached_vars)) {\n throw new epExceptionObject('Variable [' . $this->_varName($var_name) . '] does not exist or is not accessible');\n return self::$false;\n }\n\n // intermediate variable to prevent notice about reference returns\n $var =& $this->epObjectGetVar($var_name);\n return $var;\n }", "title": "" }, { "docid": "62890d36b3d916a325d845a8d855cd01", "score": "0.5644717", "text": "public function __get($varName) {\n return $this->$varName;\n }", "title": "" }, { "docid": "62890d36b3d916a325d845a8d855cd01", "score": "0.5644717", "text": "public function __get($varName) {\n return $this->$varName;\n }", "title": "" }, { "docid": "97e8fc4f48d9b73a0f4179c5f64ce4c8", "score": "0.56287754", "text": "public function getVariable($key)\n {\n $key = (string) $key;\n return $this->hasVariable($key) ? $this->currentRequest->variables->$key : null;\n }", "title": "" }, { "docid": "de1065cd77417aa196361f214953baae", "score": "0.56268674", "text": "public function variable(){\n $value = null;\n\n $v=null;\n\n try {\n // Sparql10.g:277:5: (v= VAR1 | v= VAR2 ) \n $alt52=2;\n $LA52_0 = $this->input->LA(1);\n\n if ( ($LA52_0==$this->getToken('VAR1')) ) {\n $alt52=1;\n }\n else if ( ($LA52_0==$this->getToken('VAR2')) ) {\n $alt52=2;\n }\n else {\n $nvae = new NoViableAltException(\"\", 52, 0, $this->input);\n\n throw $nvae;\n }\n switch ($alt52) {\n case 1 :\n // Sparql10.g:277:7: v= VAR1 \n {\n $v=$this->match($this->input,$this->getToken('VAR1'),self::$FOLLOW_VAR1_in_variable1686); \n $vartype = \"?\";\n\n }\n break;\n case 2 :\n // Sparql10.g:278:7: v= VAR2 \n {\n $v=$this->match($this->input,$this->getToken('VAR2'),self::$FOLLOW_VAR2_in_variable1698); \n $vartype = \"$\";\n\n }\n break;\n\n }\n $value = new Erfurt_Sparql_Query2_Var(($v!=null?$v->getText():null)); $value->setVarLabelType($vartype);\n }\n catch (RecognitionException $re) {\n $this->reportError($re);\n $this->recover($this->input,$re);\n }\n catch(Exception $e) {\n throw $e;\n }\n \n return $value;\n }", "title": "" }, { "docid": "2d013d25580a3ff4ac778c7dc4b4c793", "score": "0.56259465", "text": "public function getIntVar()\n {\n return $this->get(self::_INT_VAR);\n }", "title": "" }, { "docid": "4896119be794b161cdbf74e7e5bfb3b9", "score": "0.56233495", "text": "public function __get($var) {\n\t\t$var;\n\t}", "title": "" }, { "docid": "f6f7b35274b07d8fccb7e185fc3dd83f", "score": "0.5596418", "text": "protected function getVariableHelper() {\n return $this->getHelper('drupal_variable');\n }", "title": "" }, { "docid": "8787cda9a1fb2b6f47171e65760caa56", "score": "0.5590312", "text": "public function getAssigned( $key )\r\n\t{\r\n\t\tif ( ! is_string( $key ) )\r\n\t\t\treturn $this->_error( \"expects parameter 1 to be a string\" );\r\n\r\n\t\treturn ( isset( $this->data[$key] ) ? $this->data[$key] : null );\r\n\t}", "title": "" }, { "docid": "41fb66026b46d39091e12aa7eb7d22ed", "score": "0.55749774", "text": "public function getInstanceVarByName($name)\n\t{\n\t\tforeach($this->instance_vars as &$instance_var)\n\t\t{\n\t\t\tif($instance_var['name'] == $name)\n\t\t\t{\n\t\t\t\tif($instance_var['reference'] === true)\n\t\t\t\t{\n\t\t\t\t\treturn $this->getInstanceVarByName($instance_var['target']);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\treturn $instance_var['value'];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "title": "" }, { "docid": "6743e950bfec0b0bc50a31141eaee981", "score": "0.55706954", "text": "public function getVariable($key)\n {\n if (!$this->variables) {\n return null;\n }\n\n return $this->variables->get($key);\n }", "title": "" }, { "docid": "1f53012b07b6fe30ea8fef8b4c4306b8", "score": "0.55627507", "text": "function getRequestedVariable($name)\n{\n $result = null;\n if (isset($_GET[$name])) {\n $result = $_GET[$name];\n } elseif (isset($_POST[$name])) {\n $result = $_POST[$name];\n }\n return $result;\n}", "title": "" }, { "docid": "e640ff57975bd4bc248cf37963eda514", "score": "0.5550564", "text": "public function get ($var)\n \t{\tif (isset ($this-> $var))\n \t\t{\treturn $this-> $var;\n \t\t}\n \t\telse\n \t\t{\treturn false;\n \t\t}\t\n \t}", "title": "" }, { "docid": "e9884554054b721b114ebe9630578df5", "score": "0.55426055", "text": "public function getParam() {\n return $this->extractValueFromAssignmentString($this->getVariable(self::PARAM));\n }", "title": "" }, { "docid": "9719f285fe267986dd565cb36aedeba2", "score": "0.55385137", "text": "protected function _getVar( $name ) {\n\t\t$val = $this->requestVars->{$name};\n\t\tif ( $this->isIntNumeric( $val ) ) {\n\t\t\t$val = intval( $val );\n\t\t}\n\t\treturn $val;\n\t}", "title": "" }, { "docid": "76d44453e1b7b040befceee38a5ac834", "score": "0.5536191", "text": "public static function getVariable($name)\n {\n global $wpdb;\n if (strlen($name)) {\n $row = $wpdb->get_row(\"SHOW VARIABLES LIKE '{$name}'\", ARRAY_N);\n return isset($row[1]) ? $row[1] : null;\n } else {\n return null;\n }\n }", "title": "" }, { "docid": "5ae4b09d8aaecdfce5e9e018d77a0a93", "score": "0.55268556", "text": "public function getVars()\n {\n return $this->_data;\n }", "title": "" } ]
675ef1ac2e46f4595932e95588bbd806
Initializes the DbCache component. This method will initialize the [[db]] property to make sure it refers to a valid DB connection.
[ { "docid": "7950e8825ef2ae5bc2878685585c86f5", "score": "0.0", "text": "public function init()\n\t{\n\t\tparent::init();\n\t\tif (is_string($this->db)) {\n\t\t\t$this->db = Yii::$app->getComponent($this->db);\n\t\t\tif (!$this->db instanceof Connection) {\n\t\t\t\tthrow new InvalidConfigException('The \"db\" property must be a valid DB Connection application component.');\n\t\t\t}\n\t\t}\n\t}", "title": "" } ]
[ { "docid": "dba0480fbab4222678931b683fa5f445", "score": "0.8029269", "text": "public function init()\n {\n parent::init();\n $this->db = Instance::ensure($this->db, Connection::className());\n if ($this->cache !== null) {\n $this->cache = Instance::ensure($this->cache, Cache::className());\n }\n }", "title": "" }, { "docid": "89cac0857c4b9dd615b7713b028da27f", "score": "0.79152787", "text": "public function init()\n {\n parent::init();\n $this->db = Instance::ensure($this->db, Connection::class);\n if ($this->enableCaching) {\n $this->cache = Instance::ensure($this->cache, Cache::class);\n }\n }", "title": "" }, { "docid": "e680050076301bfda35e9fcbbb4aa29c", "score": "0.7791052", "text": "public function init()\n {\n parent::init();\n if ($this->db !== null) {\n $this->db = Instance::ensure($this->db);\n }\n }", "title": "" }, { "docid": "29cec43a2d4ad7172b6a1cc89f8c17f0", "score": "0.76455975", "text": "public function init()\n {\n parent::init();\n $this->db = Instance::ensure($this->db, Connection::class);\n }", "title": "" }, { "docid": "4a0eb3f23b690351ec271c8290626ba7", "score": "0.76036316", "text": "public static function init() {\n if (!self::$initialized) {\n self::$db = Database::getInstance();\n self::$initialized = true;\n }\n }", "title": "" }, { "docid": "af8a0e30b00f9778974c6322e1d592b9", "score": "0.70188123", "text": "protected function _init() {\n if (!$this->dbm) {\n if (empty($this->dbmFile)) {\n throw new CacheFileNotFoundException(\"DBM file not specified\");\n }\n $this->_connect();\n }\n }", "title": "" }, { "docid": "ff31dd8c019909e34cf0c4de2a2fb3bf", "score": "0.69911206", "text": "public function initialize()\n {\n $this->setConnectionService('db');\n }", "title": "" }, { "docid": "3f31eef67bbdc779d57b74bfb74a37ba", "score": "0.6954004", "text": "public function init() {\n //读取数据库配置文件,如果没有数据库配置文件,则认为是不需要数据库的\n //不对数据库进行初始化,直接返回\n if ($this->loadConfig() === false) {\n return false;\n }\n $this->app->instance(\\HuanL\\Db\\DbConnect::class,\n $this->app->make('dbconnect', $this->dbConfig)\n );\n }", "title": "" }, { "docid": "4a5a21377fe7dfab527601f35ce2ee88", "score": "0.6864847", "text": "public function __construct()\n {\n $this->db = \\DJP\\Services\\Registry::getInstance()->getEntry(\"db\");\n }", "title": "" }, { "docid": "c47ca255a83093a5fcea862e1818c20a", "score": "0.6862944", "text": "public function __construct() {\n\t\tself::$_db = Database::getInstance();\n\t}", "title": "" }, { "docid": "45d6e8141728066707a42912505bfa2e", "score": "0.68219423", "text": "function __construct()\n {\n $this->db = Db::getInstance();\n }", "title": "" }, { "docid": "d1bca85204a392940b0fa2838bd56b44", "score": "0.675163", "text": "public function __construct() {\n $this -> _db = DB::getInstance();\n }", "title": "" }, { "docid": "85bbf2999b30b770be221394cfc8940b", "score": "0.6750728", "text": "public function __construct()\n {\n $this->_db = Database::getInstance();\n }", "title": "" }, { "docid": "cf91e99240afd0fb38a36eee00b8686e", "score": "0.6745542", "text": "public function __construct() {\n $this->db = Db::getInstance();\n }", "title": "" }, { "docid": "6e01ae6a2ffa92a4dec08e4b859ba473", "score": "0.67105424", "text": "public function __construct() {\n $this->db = Database::getInstance();\n }", "title": "" }, { "docid": "7637b16588915d164326c9e29b0f8c3e", "score": "0.6691411", "text": "public function initialize() {\n\t\t$this->_db_read = Db::get($this->config->getConnectionRead());\n\t\t$this->_db_write = Db::get($this->config->getConnectionWrite());\n\t\t$this->_table_name = $this->config->getTableName();\n\t}", "title": "" }, { "docid": "312f4a802ee86b7f9f396d55fac0d356", "score": "0.66898346", "text": "function dbInit( )\n {\n if ( $this->IsConnected == false )\n {\n $this->Database = new eZDB( \"site.ini\", \"site\" );\n $this->IsConnected = true;\n }\n }", "title": "" }, { "docid": "0c517a601b4dfdcb8c225d9ad4daafbd", "score": "0.66776884", "text": "public function init()\n {\n $this->dbConfig = Factory::getInstance()->config->get('database')->toArray();\n\n if (class_exists('Tracy\\Debugger', true))\n DatabaseTracyBridge::register();\n }", "title": "" }, { "docid": "8e38b82e232e1f9d760ea33916c4c059", "score": "0.66614026", "text": "public function __construct() {\r\n\t\t$this->_db = Database::getInstance();\r\n\t}", "title": "" }, { "docid": "0efe7f08e8c7fb9780bd1ad52d4660cd", "score": "0.6648015", "text": "protected function init_cache() {\n $this->set_cache_obj(FileCache::singleton());\n }", "title": "" }, { "docid": "76d02c9b0b3f84c81c3398b4201682c2", "score": "0.6647687", "text": "public function __construct()\n {\n $this->_db = get_db();\n }", "title": "" }, { "docid": "fbc4ce2d7d75e70b0ed9f6ae81bc0cc5", "score": "0.6535072", "text": "public function initialize() : void\n {\n // Use to initialise member variables.\n $this->db = \"active\";\n }", "title": "" }, { "docid": "7e7284b90769f92b2ce696e7360b2c32", "score": "0.6529149", "text": "protected function initCache() {\n\t\tself::$cacheObj = new CacheHandler();\n\t\t$this->loadDefaultCacheResources();\n\t}", "title": "" }, { "docid": "5f033ad0e29b1dd44379d4463af8d5dd", "score": "0.6516039", "text": "protected function _initDbAdapter()\n {\n $this->bootstrap('db');\n $dbAdapter = $this->getResource('db');\n\n\t\t// determine if we should use the profiler\n\t\tif (APPLICATION_ENV != 'production') {\n\t\t\t$profiler = new Zend_Db_Profiler_Firebug('All DB Queries');\n\t\t\t$profiler->setEnabled(true);\n\t\t\t$dbAdapter->setProfiler($profiler);\n\t\t}\n\n // cache db metadata\n Zend_Db_Table_Abstract::setDefaultMetadataCache($this->_cache);\n\n\t\t// add the dbAdapter to the registry\n Zend_Registry::set('dbAdapter', $dbAdapter);\n\n\t\t// load the session handler\n\t\t$this->_setSessionSaveHandler($dbAdapter);\n }", "title": "" }, { "docid": "02342e8e6cddbc9bf0ce23d78529343f", "score": "0.6509311", "text": "protected function initDB() {\n\t\t// get configuration\n\t\t$dbHost = $dbUser = $dbPassword = $dbName = $dbCharset = '';\n\t\t$dbClass = 'MySQLDatabase';\n\t\trequire_once(WCF_DIR.'config.inc.php');\n\t\t\n\t\t// create database connection\n\t\trequire_once(WCF_DIR.'lib/system/database/'.$dbClass.'.class.php');\n\t\tself::$dbObj = new $dbClass($dbHost, $dbUser, $dbPassword, $dbName, $dbCharset);\n\t}", "title": "" }, { "docid": "6f5015dfa51c0c4f691d8c1574f48239", "score": "0.6504689", "text": "static public function _init(){\n self::$db = new Database();\n return true;\n }", "title": "" }, { "docid": "9524a1d8566d7949816b0bba5b7ac867", "score": "0.6499044", "text": "protected function __construct()\n {\n $this->dbService = \\service\\DBService::getInstance();\n }", "title": "" }, { "docid": "813647f5857db2e7a94dcdba4d578c6b", "score": "0.6482938", "text": "public function __construct()\n\t{\n\t\t$this -> _db = Zend_Registry::get('db');\n\t}", "title": "" }, { "docid": "c9b575f38e344ea4e8073bc0877c5dc4", "score": "0.6478174", "text": "public function init()\n {\n $this->db = Zend_Db_Table::getDefaultAdapter();\n }", "title": "" }, { "docid": "0641f61928e9e9da51d6836f5854cc23", "score": "0.64679724", "text": "public function init()\n {\n include_once(Yii::getAlias($this->vendorDir) . '/SDDB.php');\n parent::init();\n if (is_array($this->ssdb)) {\n /*\n $host = $this->ssdb['host'];\n $port = $this->ssdb['port'];\n $timeout_ms = isset($this->ssdb['timeout_ms']) ? $this->ssdb['timeout_ms'] : 2000 ;\n */\n $conf = ArrayHelper::merge($this->defaultConfig, $this->ssdb);\n\n $this->ssdb = new \\SimpleSSDB($conf['host'], $conf['port'], $conf['timeout_ms']);\n }\n if (!$this->ssdb instanceof \\SimpleSSDB) {\n throw new InvalidConfigException(\"Cache::ssdb must be either a ssdb connection instance or the application component ID of a ssdb connection.\");\n }\n }", "title": "" }, { "docid": "cbee3d3260b995ed6f3cabe6188782e8", "score": "0.64383936", "text": "public function __construct()\n {\n $this->db = get_db();\n }", "title": "" }, { "docid": "1618e8e9818da78406c6cab833bd1aad", "score": "0.6435256", "text": "protected function _initDatabase()\n {\n $databaseConfiguration = new Zend_Config_Ini( APPLICATION_PATH . '/configs/database.ini', APPLICATION_ENV);\n \n /**\n * Creating the database handler from the loaded ini file\n */\n $dbAdapter = Zend_Db::factory( $databaseConfiguration->database );\n \n /**\n * Lets define the newly created handler as our default database handler\n */\n Zend_Db_Table_Abstract::setDefaultAdapter($dbAdapter);\n \n $registry = Zend_Registry::getInstance();\n $registry->databaseConfiguration = $databaseConfiguration;\n $registry->db = $dbAdapter;\n \n $dbAdapter->query('SET NAMES utf8');\n \n /*$profiler = new Zend_Db_Profiler_Firebug('All DB Queries');\n $profiler->setEnabled(true);\n $dbAdapter->setProfiler($profiler);*/\n }", "title": "" }, { "docid": "c7e3f69ba5d11c2b372b3cb414afcbbb", "score": "0.6426469", "text": "public function __construct()\n\t{\n\t\t$this->db = Zend_Registry::get('db');\n\t}", "title": "" }, { "docid": "fc88ba6286d5a5bfce8023c068823382", "score": "0.64064467", "text": "public function __construct()\n\t{\n\t\t$this->db = Database::instance();\n\t}", "title": "" }, { "docid": "85e2fba92def184171577da31dc870e2", "score": "0.6406088", "text": "public function init()\n\t{\n\t\t$this->testConnection();\n\t\t$this->connectToDatabase();\n\t}", "title": "" }, { "docid": "ed9f700db0910fbbf78bdbf2fac0856e", "score": "0.6388865", "text": "public static function init()\n {\n try\n {\n self::$db = new PDO(\"mysql:host=\" . DB_HOST . \";dbname=\" . DB_NAME, DB_USERNAME, DB_PASSWORD);\n self::$db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);\n } catch ( PDOException $e )\n {\n echo 'Connection failed: ' . $e->getMessage();\n }\n }", "title": "" }, { "docid": "759b57d45c15ea33933d223a04af2cfd", "score": "0.6383204", "text": "public function initialize()\n {\n $this->setConnectionService('db'); // Connection service for log database\n }", "title": "" }, { "docid": "cb27a1b57b9c24c790eb9715fefaa7ae", "score": "0.63798624", "text": "public function __construct(){\n\t\t\t$this->_db = DB::getInstance(); \n\t\t}", "title": "" }, { "docid": "6367239310aeaaa247f9706b96154373", "score": "0.63506824", "text": "public function __construct()\r\n {\r\n $this->db = self::dbConnect();\r\n }", "title": "" }, { "docid": "344ad49453b150c5145bcb9e01492d1f", "score": "0.63496745", "text": "public function __construct(){\n\t\t$this->_config = \\element\\core\\Config::getSection(\"db\");\n\t}", "title": "" }, { "docid": "59f99c9041bf3542e3b34a7431990ff9", "score": "0.6338433", "text": "protected function initializeCache() {}", "title": "" }, { "docid": "d60d4746c812c887811f23dc0b6a2452", "score": "0.6332048", "text": "public static function init() {\n\t\tglobal $wpdb;\n\n\t\tself::$db = &$wpdb;\n\t}", "title": "" }, { "docid": "7b71ea660566729947e8cc8d2e9c3463", "score": "0.631997", "text": "static public function init()\n {\n self::$db = new PDO('mysql:host=' . DB_HOST . ';dbname=' . DB_NAME, DB_USER, DB_PASS);\n }", "title": "" }, { "docid": "ac5c9fa359a825732eec98492d1d0ea1", "score": "0.6317724", "text": "public function __construct(){\n $this->_db= DB::getInstance();\n }", "title": "" }, { "docid": "61bbf60da122874c9f5bbc5591936201", "score": "0.6310935", "text": "public function __construct() {\n\t\t$this->db = new DB;\n\t}", "title": "" }, { "docid": "0ce6954cd334fb80a6708ec7cb1d8bd7", "score": "0.63059795", "text": "public function __construct() {\n $db = Db::getInstance();\n $this->_dbh = $db->getConnection();\n }", "title": "" }, { "docid": "7232c6f987c824653a04fd86bcbcc163", "score": "0.62986207", "text": "function __construct() {\n $this->setDb();\n }", "title": "" }, { "docid": "1d33cbc28ef51f0d8e86cf9de65ddcf8", "score": "0.6295598", "text": "public function __construct()\n {\n $this->db = DataBase::dbConnect();\n }", "title": "" }, { "docid": "40eaf669abf708f244e72ccf7f5cc404", "score": "0.62847304", "text": "public function initialize() : void\n {\n // Use to initialise member variables.\n $db = $this->app->db;\n $db->connect();\n\n // Use $this->app to access the framework services.\n }", "title": "" }, { "docid": "456abbab2eaba06c0d2ccd577eb7ceb4", "score": "0.6281611", "text": "private\n function _initDB()\n {\n $this->_dbDrv = new dbDriver($this->PATH,self::DB,self::DB_FILE_EXT);\n }", "title": "" }, { "docid": "a41708b589af46214e3af112c495f454", "score": "0.62765115", "text": "public function initialize()\n {\n $this->db = \"active\";\n $this->base = \"movie/\";\n $this->app->db->connect();\n }", "title": "" }, { "docid": "b32f947706d8110621a0d6104f1a022b", "score": "0.6256411", "text": "public function __construct()\n\t\t{\n\n\t\t\t$this->db = new Database();\n\n\t\t}", "title": "" }, { "docid": "3b42e17ebac6892bd98a15e2b6cb09cc", "score": "0.62522155", "text": "function __construct()\n {\n $this->db = new Database(DB_TYPE, DB_HOST, DB_NAME, DB_USER, DB_PASS);\n }", "title": "" }, { "docid": "22fda893db68f07f3e004ad475bcf964", "score": "0.6234582", "text": "public function __construct() {\n $this->db = $this->connectDB();\n }", "title": "" }, { "docid": "616d0463da9e22e607bfe6cfa3e5f8d8", "score": "0.6233438", "text": "public function __construct()\n\t{\n\t\t$this->db = $GLOBALS['db'];\n\t}", "title": "" }, { "docid": "86541871844991ffb8b5b8528930ec84", "score": "0.6225752", "text": "public function __construct(){\n\n $this->db=DB::createInstance();\n }", "title": "" }, { "docid": "eef687d270f454b97b386a3ca96371bf", "score": "0.62249434", "text": "protected function initDatabase()\n {\n $config = $this->di->get('config');\n $logger = $this->di->get('logger');\n\n $debug = (isset($config->app->debug)) ? (bool) $config->app->debug : false;\n\n $this->di->set('db', function () use ($config, $debug, $logger) {\n\n $params = [\n 'host' => $config->database->host,\n 'username' => $config->database->username,\n 'password' => $config->database->password,\n 'dbname' => $config->database->name\n ];\n\n $connection = new PhDbAdapter($params);\n\n if ($debug) {\n $eventsManager = new PhEventsManager();\n $eventsManager->attach('db', function (PhEvent $event, PhDbAdapter $connection) use ($logger) {\n if ($event->getType() == 'beforeQuery') {\n $logger->log(\n $connection->getSQLStatement(),\n PhLogger::INFO\n );\n }\n });\n\n $connection->setEventsManager($eventsManager);\n }\n\n return $connection;\n });\n }", "title": "" }, { "docid": "e995d9f848de3a22fa06cf1b46def312", "score": "0.6224762", "text": "public function init()\r\n {\r\n $this->db2 = Zend_Registry::get('dbspocosy');\r\n }", "title": "" }, { "docid": "ecffdba85738a525058b52ad196baed7", "score": "0.6219579", "text": "function __construct()\n {\n $this->_ci =& get_instance();\n $this->_ttl_unit = 'M';\n $this->_time_zone = 'Europe/Istanbul';\n $this->_db_tbl_name = 'v_cached';\n $this->_db_cache_key = 'c_key';\n $this->_db_cache_val = 'c_val';\n $this->_db_cache_type = 'c_type';\n $this->_db_cache_user = 'id_user';\n\n // Uncomment if cache table is not created by Migrations\n // $this->_check_cache_table();\n }", "title": "" }, { "docid": "bcc2f0b88d70733f9ca8c3f59671c602", "score": "0.6219332", "text": "function dbInit() {\n\t// instanciates database\n\t$db = new SQLite3('sqlite/todo.db');\n\treturn $db;\n}", "title": "" }, { "docid": "b331af388022ecd179e847e9216459cf", "score": "0.6217637", "text": "public function __construct() {\r\n $this->db = Database::connect();\r\n }", "title": "" }, { "docid": "7e8f5086a84c91945d3ab131d76bf638", "score": "0.6216274", "text": "public function initialize() : void\n {\n // Use to initialise member variables.\n $this->app->db->connect();\n }", "title": "" }, { "docid": "d41085721990c9906662f12421b2331b", "score": "0.62067515", "text": "public function __construct()\n\t{\n\t\t$this->_db = new Database(); \n\t}", "title": "" }, { "docid": "389af998da50a230a97999ed2b89a2b6", "score": "0.6203337", "text": "function __construct($db)\n {\n $this->setDataBase($db);\n }", "title": "" }, { "docid": "389af998da50a230a97999ed2b89a2b6", "score": "0.6203337", "text": "function __construct($db)\n {\n $this->setDataBase($db);\n }", "title": "" }, { "docid": "40f0c5bb88d2c8af4f1cd922168d4aba", "score": "0.620229", "text": "function __construct( $dbm ) { $this->zincDBManager = $dbm; }", "title": "" }, { "docid": "9cadaea9b51700b60daf1b2b9d451446", "score": "0.61949563", "text": "public function __construct(){\n\t\t\t$this->db = $GLOBALS[\"db\"];\n\t\t}", "title": "" }, { "docid": "600c8f343525639d68aa164b62a60ad8", "score": "0.6192332", "text": "public function InitDatabase()\r\n\t{\r\n\t\tif (count( $this->Databases) > 0)\r\n\t\t{\r\n\t\t\t$dbms = $this->Databases[0]['dbms'];\r\n\t\t\t$server = $this->Databases[0]['server'];\r\n\t\t\t$database = $this->Databases[0]['database'];\r\n\t\t\t$user = $this->Databases[0]['user'];\r\n\t\t\t$pass = $this->Databases[0]['password'];\r\n\t\t\t\r\n\t\t\t$this->Databases[0][\"db\"] = new PDO( \"{$dbms}:host={$server};dbname={$database}\", $user, $pass); \t\t\t\t\t\r\n\t\t\t//RDebug( \"dbh: \" . $this->Databases[0][\"db\"]);\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t}", "title": "" }, { "docid": "48cf98de4bfbe40d07ffc5d3004c8d94", "score": "0.6191468", "text": "public function __construct($db = null)\n {\n if (!is_null($db)) {\n $this->setDb($db);\n }\n }", "title": "" }, { "docid": "fde33b2f62eeac283ffda21fd132a153", "score": "0.618625", "text": "public function __construct($db=null)\n {\n $this->db = $db;\n }", "title": "" }, { "docid": "4f0eb4755af907e41638c1b7442c8f8c", "score": "0.61803716", "text": "public function __construct(bbn\\db $db, array $cfg=[]){\n parent::__construct($db);\n $this->_init_class_cfg($cfg);\n self::retriever_init($this);\n $this->cache_init();\n }", "title": "" }, { "docid": "6f676b1a68f504a6e11e7a6e826d05f2", "score": "0.61667234", "text": "private function __construct($db) {\r\n\t\t$this->_db = $db;\r\n\t}", "title": "" }, { "docid": "a68127bc72f4a2d8bce1be87c33a2eea", "score": "0.61659616", "text": "public function __construct($db) {\r\n $this->_db = $db;\r\n }", "title": "" }, { "docid": "a68127bc72f4a2d8bce1be87c33a2eea", "score": "0.61659616", "text": "public function __construct($db) {\r\n $this->_db = $db;\r\n }", "title": "" }, { "docid": "83912be50d239687a345028bd8645047", "score": "0.61480004", "text": "function __construct($db=null) {\n\t\t\tif (!empty($db)) {\n \t $this->db = $db;\n \t}\n }", "title": "" }, { "docid": "a7c4722897815fe3e37adad2ee6153a7", "score": "0.61464405", "text": "public function __construct() {\n $this->db = Fari_Db::getConnection();\n }", "title": "" }, { "docid": "d8ac0545dcf1cf9fadca56dded55c7f2", "score": "0.61403006", "text": "public function __construct(DatabaseConnection $db) {\n $this->_db = $db;\n }", "title": "" }, { "docid": "3dcb12832820b74492f3cb4765e96fc3", "score": "0.6137627", "text": "public function __construct()\n {\n $this->bootstrap = \\Bootstrap::getInstance();\n $this->db = $this->bootstrap->db;\n }", "title": "" }, { "docid": "5a20910273b72a611c3987787ffabf2c", "score": "0.61319077", "text": "function __construct() {\n // $this->db=new Database();\n $this->db=Database::getInstance();\n }", "title": "" }, { "docid": "95df1da098c240456197ba2fe76c355e", "score": "0.61232835", "text": "public function __construct(Database $db) {\n\t $this->loadConfigs();\n\t $this->db = $db;\n\t}", "title": "" }, { "docid": "d8f6534ba0d69b201d73e635571f213c", "score": "0.61229", "text": "private function __construct() {\n parent::initDb();\n }", "title": "" }, { "docid": "f0af5821eea0967f7c80fe5d0ea55ed9", "score": "0.6112078", "text": "public function __construct(&$db) {\n $this->db = $db;\n }", "title": "" }, { "docid": "7c066b0a7de246a933d766302130e1be", "score": "0.61096317", "text": "public function initialize()\n\t{\n\t\tself::checkCacheFile();\n\t\tself::load();\n\t}", "title": "" }, { "docid": "8591c652d95e295e7cb96e841417d0f5", "score": "0.6103125", "text": "public function __construct() {\n // inicializace prace s DB\n require_once (DIRECTORY_MODELS .\"/DatabaseModel.class.php\");\n $this->db = new DatabaseModel();\n }", "title": "" }, { "docid": "f978b8336be02ac3f71b5becc4a44008", "score": "0.60975987", "text": "public function __construct()\n {\n // inicializace prace s DB\n require_once(DIRECTORY_MODELS . \"/DatabaseModel.class.php\");\n $this->db = new DatabaseModel();\n }", "title": "" }, { "docid": "bb304f31e6cd10ef50f1015773ac6166", "score": "0.6096567", "text": "public function __construct($database = null, $cache = null) {\n if (empty($database)) {\n global $databaseInstance;\n $database = $databaseInstance;\n }\n\n $this->database = $database;\n\n if (empty($cache)) {\n global $cacheInstance;\n $cache = $cacheInstance;\n }\n $this->cache = $cache;\n }", "title": "" }, { "docid": "50c72be77f79e34253f95a3e992847a4", "score": "0.60948235", "text": "public function __construct()\n {\n $this->ipDB = DBConfig::$ipDB;\n $this->portDB = DBConfig::$portDB;\n $this->userDB = DBConfig::$userDB;\n $this->passwordDB = DBConfig::$passwordDB;\n $this->dbName = DBConfig::$dbName;\n $this->tableProducts = DBConfig::$tableProducts;\n $this->tableCrawler = DBConfig::$tableCrawler;\n $this->timeoutDB = DBConfig::$timeoutDB;\n\n $this->initConnection();\n }", "title": "" }, { "docid": "082732eeb60715ff9706e693a6b0bc48", "score": "0.6085867", "text": "public function __construct()\r\n {\r\n $this->db = Connection::getInstance();\r\n \r\n if (!empty($this->db)) {\r\n $this->db->setAttribute(\\PDO::ATTR_ERRMODE, \\PDO::ERRMODE_EXCEPTION);\r\n }\r\n }", "title": "" }, { "docid": "4dbdef5c25a44646fe1a4f80d75a7778", "score": "0.60851294", "text": "public function __construct()\r\n\t{\r\n\t\t$this->db = SPDO::singleton();\r\n\t}", "title": "" }, { "docid": "65be000a3c5e0b9efcb1ccd824e5da5a", "score": "0.6082826", "text": "protected function init() {\n\t\tparent::init();\n\t\tif ( ! isset($this->dbname))\t$this->dbname\t= $this->default_dbname();\n\t\tif ( ! isset($this->host))\t\t$this->host\t\t= $this->default_host();\n\t\tif ( ! isset($this->port))\t\t$this->port\t\t= $this->default_port();\n\t}", "title": "" }, { "docid": "e39a06fc1f4b14b708c82174bee84f6b", "score": "0.60799545", "text": "private function _initDb()\r\n\t{\t\r\n\t\t// grab .ini config options from .ini file\r\n\t\t$config_data = parse_ini_file(APPLICATION_PATH . '/configs/config.ini', TRUE);\r\n\t\t$config_data = DEV_ENVIRONMENT ? $config_data['development'] : $config_data['production'];\r\n\r\n\t\t// pass the .ini array to the config object\r\n\t\tConfig::setConfigData($config_data);\r\n\t\t$Config = Config::getData();\r\n\r\n\t\t$dbHost = 'mysql:dbname=' . $Config->db->dbname . ';host=' . $Config->db->host;\r\n\t\t$dbUser = $Config->db->user;\r\n\t\t$dbPwd = $Config->db->pwd;\r\n\r\n\t\tif (Db::connect($dbHost, $dbUser, $dbPwd) === FALSE) {\r\n\t\t\t// stops application execution on a failded db login attempt\r\n\t\t\tthrow new exceptions\\DbException(__FILE__, __LINE__, \"Unable to connect to database: \" . Db::getErrorMessage());\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "c1a95e7ee41fbc01eff70b40bd4e36a7", "score": "0.607633", "text": "public function __construct() \n {\n global $config;\n\n //get instance of db control(singltone class)\n $this->DB = Db_Control::getInstance($config);\n }", "title": "" }, { "docid": "0a552c0d2b329b2f652c6dd69f8fa4c9", "score": "0.6075933", "text": "public function __construct()\n {\n\n $this->_db = get_db();\n self::addHooksAndFilters();\n\n }", "title": "" }, { "docid": "2f9162713435199ee145f88c68aa7967", "score": "0.6073786", "text": "function __construct()\n {\n $this->db = new Database();\n }", "title": "" }, { "docid": "511dd3ffc40b54f6386cc3a58f423e22", "score": "0.6072679", "text": "public function initDb(){\r\n\t\t$config = $this->app->config;\r\n\t\t$locale = $config['db'];\r\n\t\t$rvip = $config['db_rvip'];\r\n\t\t$dbPathLocale = \"mysql://\" . $locale['user'] . \":\" . $locale['pwd'] . \"@\" . $locale['host'] . \"/\" . $locale['dbname'];\r\n\t\t$dbPathRvip = \"mysql://\" . $rvip['user'] . \":\" . $rvip['pwd'] . \"@\" . $rvip['host'] . \"/\" . $rvip['dbname'];\r\n\t\t$connections = array(\r\n\t\t\t'domadb'\t=> $dbPathLocale,\r\n\t\t\t'rvipdb'\t=> $dbPathRvip\r\n\t\t);\r\n\t\tActiveRecord\\Config::initialize(function($cfg) use ($connections){\r\n\t\t\t$cfg->set_model_directory(__DIR__ . '/Model');\r\n\t\t\t$cfg->set_connections($connections);\r\n\t\t});\t\t\t\t\r\n\t}", "title": "" }, { "docid": "3d2a77d868e132290f37a79c0a3855aa", "score": "0.60719895", "text": "protected function __construct()\n\t{\n\t\t$this->set_var('db_tables');\n\t}", "title": "" }, { "docid": "e4dd42a2377ff862f69df3e9af73df46", "score": "0.6069838", "text": "public function __construct()\n {\n $this->db = new Database();\n }", "title": "" }, { "docid": "e4dd42a2377ff862f69df3e9af73df46", "score": "0.6069838", "text": "public function __construct()\n {\n $this->db = new Database();\n }", "title": "" }, { "docid": "1a89f5def8320a15be381b37505319f4", "score": "0.6069716", "text": "function init()\n\t{\n\t\tself::_getConnection();\n\t}", "title": "" }, { "docid": "1a7adbcca9b12e8abe33ba8dbb2f1e7f", "score": "0.6058842", "text": "public function bootDB() {\n if( ! empty( $this->env->database ) ) {\n $this->db = DB::getInstance( $this->env );\n }\n }", "title": "" }, { "docid": "c6c18f33e593743543ca2a508e869165", "score": "0.60579395", "text": "function __construct() {\r\n $this->setDb();\r\n \r\n }", "title": "" } ]
9acb221974053a053e8e5b89b9d1371a
Parses headers if necessary. Decodes the status code and reasonphrase. Parses and normalizes header names + values.
[ { "docid": "8656be7c2cd2f7451e21f455d2f8770e", "score": "0.66335803", "text": "protected function _parseHeaders($headers)\n {\n foreach ($headers as $key => $value) {\n if (substr($value, 0, 5) === 'HTTP/') {\n preg_match('/HTTP\\/([\\d.]+) ([0-9]+)(.*)/i', $value, $matches);\n $this->protocol = $matches[1];\n $this->code = (int)$matches[2];\n $this->reasonPhrase = trim($matches[3]);\n continue;\n }\n if (strpos($value, ':') === false) {\n continue;\n }\n list($name, $value) = explode(':', $value, 2);\n $value = trim($value);\n $name = trim($name);\n\n $normalized = strtolower($name);\n\n if (isset($this->headers[$name])) {\n $this->headers[$name][] = $value;\n } else {\n $this->headers[$name] = (array)$value;\n $this->headerNames[$normalized] = $name;\n }\n }\n }", "title": "" } ]
[ { "docid": "54a4b6df5a44bfa56e6a5e43ceb2f9d7", "score": "0.74444973", "text": "private function _parseHeaders($headers) {\n\t\t$headers = explode(\"\\r\\n\", $headers);\n\n\t\t// Pull off the HTTP status\n\t\t$status = array_shift($headers);\n\t\tlist($version, $status_code, $status) = explode(' ', $status, 3);\n\n\t\t$this->_status['version'] = $version;\n\t\t$this->_status['status_code'] = $status_code;\n\t\t$this->_status['status'] = $status;\n\n\t\tforeach ($headers as $header) {\n\t\t\tlist($key, $value) = explode(': ', $header, 2);\n\t\t\t// This will fail if multiple headers occur with the same name.\n\t\t\t$this->_headers[$key] = $value;\n\t\t}\n\t}", "title": "" }, { "docid": "ef9f45b632456cd056cc76832186aa3c", "score": "0.6856835", "text": "protected function parseHeaders($rawHeaders)\n {\n $rawHeaders = explode(\"\\r\\n\", trim($rawHeaders));\n \n $headers = array();\n \n // status code\n $matches = array();\n preg_match('/^HTTP\\/.*([0-9]{3})$/', trim(array_shift($rawHeaders)), $matches);\n $headers['code'] = (int)$matches[1];\n \n foreach($rawHeaders as $rawHeader) {\n \n if(!$rawHeader) {\n continue;\n }\n \n $delimiter = strpos($rawHeader, ':');\n\t\t\tif (!$delimiter) {\n\t\t\t\tcontinue;\n\t\t\t}\n \n $key = trim(strtolower(substr($rawHeader, 0, $delimiter)));\n\t\t\t$val = ltrim(substr($rawHeader, $delimiter + 1));\n \n $headers[$key] = $val;\n }\n \n return $headers;\n }", "title": "" }, { "docid": "1bef7c6675037bc1850f85d8eff28b8e", "score": "0.6828462", "text": "public function parseHeaders(){}", "title": "" }, { "docid": "67a1a3610da54fc441c50b6d622dc37e", "score": "0.66431624", "text": "function parseHTTPResponse( $header ) {\n $rVal = array();\n $fields = explode(\"\\r\\n\", preg_replace('/\\x0D\\x0A[\\x09\\x20]+/', ' ', $header));\n\n // Parse the Fields\n foreach( $fields as $field ) {\n if( preg_match('/([^:]+): (.+)/m', $field, $match) ) {\n $match[1] = preg_replace('/(?<=^|[\\x09\\x20\\x2D])./e', 'strtoupper(\"\\0\")', strtolower(trim($match[1])));\n\n if( isset($rVal[$match[1]]) ) {\n $rVal[$match[1]] = array($rVal[$match[1]], $match[2]);\n } else {\n $rVal[$match[1]] = trim($match[2]);\n }\n }\n }\n\n // Return the Array of Headers\n return $rVal;\n }", "title": "" }, { "docid": "513f765ecdd6bbc06c4c6ca610c2e875", "score": "0.6627202", "text": "function _process_respond() {\n $lines = explode(\"\\r\\n\", $this->_header);\n $header_done = false;\n // $this->_error_log($this->_buffer);\n // First line should be a HTTP status line (see http://www.w3.org/Protocols/rfc2616/rfc2616-sec6.html#sec6)\n // Format is: HTTP-Version SP Status-Code SP Reason-Phrase CRLF\n list($ret_struct['status']['http-version'], \n $ret_struct['status']['status-code'], \n $ret_struct['status']['reason-phrase']) = explode(' ', $lines[0],3);\n \n // print \"HTTP Version: '$http_version' Status-Code: '$status_code' Reason Phrase: '$reason_phrase'<br>\";\n // get the response header fields\n // See http://www.w3.org/Protocols/rfc2616/rfc2616-sec6.html#sec6\n for($i=1; $i<count($lines); $i++) {\n if (rtrim($lines[$i]) == '' && !$header_done) {\n $header_done = true;\n // print \"--- response header end ---<br>\";\n \n } \n if (!$header_done ) {\n // store all found headers in array ...\n list($fieldname, $fieldvalue) = explode(':', $lines[$i]);\n $ret_struct['header'][$fieldname] = trim($fieldvalue);\n } \n }\n // print 'string len of response_body:'. strlen($response_body);\n // print '[' . htmlentities($response_body) . ']';\n $ret_struct['body'] = $this->_body; \n return $ret_struct;\n }", "title": "" }, { "docid": "c067433cfcf73919ad559a8ea642fc05", "score": "0.6530985", "text": "static public function parseHttpHeaders($headers)\n {\n $head = array();\n foreach ($headers as $v) {\n $t = explode(':', $v, 2);\n if (isset($t[1]))\n $head[trim($t[0])] = trim($t[1]);\n else {\n if (preg_match(\"#HTTP/[0-9\\.]+\\s+([0-9]+)#\", $v, $out))\n $head['Status'] = intval($out[1]);\n }\n }\n return $head;\n }", "title": "" }, { "docid": "51f9b67211403e68bc8cebe4a4424373", "score": "0.6494722", "text": "public function parse($headers)\n {\n $this->headers = [];\n $this->parameters = [];\n $this->path = '';\n $this->method = '';\n $this->code = 200;\n $this->message = '';\n $this->protocol = '';\n $this->raw = $headers;\n\n $headers = \\explode(\"\\n\\n\", $this->raw, 2);\n $this->body = isset($headers[1]) ? $headers[1] : '';\n $lines = isset($headers[0]) ? \\explode(\"\\n\", $headers[0]) : [];\n if (\\count($lines) > 1) {\n foreach ($lines as $line) {\n // clean the line\n $line = \\trim($line);\n $found = false;\n if (\\strpos($line, ': ') !== false) {\n $found = true;\n list($key, $value) = \\explode(': ', $line);\n } elseif (\\strpos($line, ':') !== false) {\n $found = true;\n list($key, $value) = \\explode(':', $line);\n } elseif (\\strpos($line, 'HTTP/') !== false && ($this->action == 'request')) {\n list($this->method, $this->path, $this->protocol) = \\explode(' ', $line, 3);\n } elseif (\\strpos($line, 'HTTP/') !== false && ($this->action == 'response')) {\n list($this->protocol, $this->code, $this->message) = \\explode(' ', $line, 3);\n }\n\n if ($found) {\n $this->headers[\\strtolower($key)] = $value;\n }\n }\n\n if ($this->action == 'request') {\n // split path and parameters string\n @list($this->path, $params) = \\explode('?', $this->path);\n\n // parse the parameters\n if (!empty($params)) {\n \\parse_str($params, $this->parameters);\n }\n }\n }\n }", "title": "" }, { "docid": "9eb68ead55ac2115c1c0d44ff549f2f8", "score": "0.6408868", "text": "function parseResponseHeader($header) {\n\n\t$headers = array();\n\t$requests = explode(\"\\r\\n\\r\\n\", trim($header));\n\n\tforeach ($requests as $request) {\n\n\t\t$header = array();\n\n\t\tforeach (explode(\"\\r\\n\", $request) as $i => $line) {\n\n\t\t\tif($i === 0) {\n\t\t\t\t$header['http_code'] = $line;\n\t\t\t} else {\n\n\t\t\t\tlist ($key, $value) = explode(':', $line);\n\t\t\t\t$header[$key] = trim($value);\n\n\t\t\t}\n\n\t\t}\n\n\t\t$headers[] = $header;\n\n\t}\n\n\treturn $headers;\n\n}", "title": "" }, { "docid": "27590abd34336accb59a784014beaaad", "score": "0.6353179", "text": "function http_parse_headers( $header )\n\t{\n\t\t$retVal = array();\n\t\t$fields = explode(\"\\r\\n\", preg_replace('/\\x0D\\x0A[\\x09\\x20]+/', ' ', $header));\n\t\tforeach( $fields as $field ) {\n\t\t\tif( preg_match('/([^:]+): (.+)/m', $field, $match) ) {\n\t\t\t\t$match[1] = preg_replace('/(?<=^|[\\x09\\x20\\x2D])./e', 'strtoupper(\"\\0\")', strtolower(trim($match[1])));\n\t\t\t\tif( isset($retVal[$match[1]]) ) {\n\t\t\t\t\tif (!is_array($retVal[$match[1]])) {\n\t\t\t\t\t\t$retVal[$match[1]] = array($retVal[$match[1]]);\n\t\t\t\t\t}\n\t\t\t\t\t$retVal[$match[1]][] = $match[2];\n\t\t\t\t} else {\n\t\t\t\t\t$retVal[$match[1]] = trim($match[2]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $retVal;\n\t}", "title": "" }, { "docid": "4b39015cf7ffaf81c1dfc7257aa67d82", "score": "0.62694484", "text": "function _parseHeaders($responseHeader)\n\t{\n\t\t// Break up the headers\n\t\t$headers = explode(\"\\r\\n\", $responseHeader);\n\n\t\t// Clear the header array\n\t\t$this->_clearHeaders();\n\n\t\t// Get resposne status\n\t\tif ($this->status == 0) {\n\t\t\t// Oooops !\n\t\t\tif (!preg_match($match = \"#^http/[0-9]+\\\\.[0-9]+[ \\t]+([0-9]+)[ \\t]*(.*)\\$#si\", $headers[0], $matches)) {\n\t\t\t\t$this->_setError('Unexpected HTTP response status');\n\t\t\t\treturn FALSE;\n\t\t\t}\n\n\t\t\t// Gotcha!\n\t\t\t$this->status = $matches[1];\n\t\t\tarray_shift($headers);\n\t\t}\n\n\t\t// Prepare all the other headers\n\t\tforeach ($headers as $header) {\n\t\t\t// Get name and value\n\t\t\t$headerName = strtolower($this->_tokenize($header, ':'));\n\t\t\t$headerValue = trim(chop($this->_tokenize(\"\\r\\n\")));\n\n\t\t\t// If its already there, then add as an array. Otherwise, just keep there\n\t\t\tif (isset($this->headers[$headerName])) {\n\t\t\t\tif (gettype($this->headers[$headerName]) == \"string\") {\n\t\t\t\t\t$this->headers[$headerName] = array($this->headers[$headerName]);\n\t\t\t\t}\n\n\t\t\t\t$this->headers[$headerName][] = $headerValue;\n\t\t\t} else {\n\t\t\t\t$this->headers[$headerName] = $headerValue;\n\t\t\t}\n\t\t}\n\n\t\t// Save cookies if asked\n\t\tif ($this->saveCookie && isset($this->headers['set-cookie'])) {\n\t\t\t$this->_parseCookie();\n\t\t}\n\t}", "title": "" }, { "docid": "cfb700b2a1f67e06d0f4d2baa3c775a1", "score": "0.6256401", "text": "private function extractHeaders() {\r\n \t\t $splitLines = explode(\"\\r\\n\", $this->xmlData);\r\n \t\t \r\n \t\t $headers = array();\r\n \t\t \r\n \t\t $i = 0;\r\n \t\t $foundEndOfHeaders = false;\r\n \t\t do {\r\n \t\t \t$currentLine = $splitLines[$i];\r\n \t\t \t\r\n \t\t \tif ( $currentLine = '' ) {\r\n \t\t \t\t$foundEndOfHeaders = true;\r\n \t\t \t} else {\r\n \t\t \t\tif ( strstr($currentLine,'HTTP/1.0') && !strstr($currentLine,'200 OK') ) {\r\n \t\t \t\t\tthrow new bmShoutCastException('Http Error occurred: ' . $currentLine);\r\n \t\t \t\t} else {\r\n \t\t \t\t\t$splitHeader = explode(':',$currentLine);\r\n \t\t \t\t\tif ( count($splitHeader)==2 ) {\r\n \t\t \t\t\t\t$headers[$splitHeader[0]] = $splitHeader[1];\r\n \t\t \t\t\t}\r\n \t\t \t\t}\r\n \t\t \t}\r\n \t\t \t$i++;\r\n \t\t } while ( $i<count($splitLines) && !$foundEndOfHeaders );\r\n \t\t \r\n \t\t $this->httpHeaders = $headers;\r\n \t\t \r\n \t\t $this->xmlData = $splitLines[--$i];\r\n \t\t\r\n \t}", "title": "" }, { "docid": "259105e239798b7fb80e84170e63460f", "score": "0.6255315", "text": "private function parseHttpMessage()\n {\n $messages = $this->parseHttpMessages();\n\n for ($i = 0, $n = (count($messages) - 1); $i <= $n; $i++) {\n if (empty($messages[$i])) {\n continue;\n }\n\n if ($i == $n) {\n $this->headers = $this->parseHttpHeaders($messages[$i]);\n $this->code = $this->parseHttpStatusCode($messages[$i]);\n $this->status_message = $this->parseHttpStatusMessage($messages[$i]);\n $this->status = $this->parseHttpStatus($messages[$i]);\n\n continue;\n }\n\n array_push($this->redirect_messages, $messages[$i]);\n }\n }", "title": "" }, { "docid": "19f4fccda3d9424cddde69ee42c18581", "score": "0.62233526", "text": "private function parseHeaders(Array $headers): Array\n {\n $head = [];\n\n foreach($headers as $k => $v) {\n $t = explode(':', $v, 2);\n if (isset($t[1])) {\n $head[trim($t[0])] = trim($t[1]);\n } else {\n $head[] = $v;\n if( preg_match(\"#HTTP/[0-9\\.]+\\s+([0-9]+)#\", $v, $out)) {\n $head['response_code'] = intval($out[1]);\n }\n }\n }\n\n return $head;\n }", "title": "" }, { "docid": "2f8e8c013cda7a7b432af52b1568a4a7", "score": "0.6175966", "text": "private function parse_headers($header){\n\n\t\t$this->headers = array();\n\t\tforeach (explode(\"\\r\\n\", $header) as $i => $line){\n\t if ($i === 0)\n\t $this->headers['http_code'] = $line;\n\t else\n\t {\n\t \t$t = explode(': ', $line);\n\t \tif(count($t) == 2){\n\t\t list($key, $value) = $t;\n\t\t $this->headers[$key] = $value;\n\t \t}\n\t }\n\t }\n\n\t // Just for the record\n\t return true;\n\t}", "title": "" }, { "docid": "424d67912834c0cb059512e0b4add987", "score": "0.61318284", "text": "protected function _parseHeaders($responseHeader)\n {\n // Break up the headers\n $headers = explode(\"\\r\\n\", $responseHeader);\n\n // Clear the header array\n $this->_clearHeaders();\n\n // Get resposne status\n if ($this->status == 0) {\n // Oooops !\n if (!preg_match($match = \"~^http/[0-9]+\\\\.[0-9]+[ \\t]+([0-9]+)[ \\t]*(.*)\\$~i\", $headers [0], $matches)) {\n $this->_setError('Unexpected HTTP response status');\n return;\n }\n\n // Gotcha!\n $this->status = $matches [1];\n array_shift($headers);\n }\n\n // Prepare all the other headers\n foreach ($headers as $header) {\n if (preg_match($match = \"~^http/[0-9]+\\\\.[0-9]+[ \\t]+([0-9]+)[ \\t]*(.*)\\$~i\", $header, $matches)) {\n $this->status = $matches [1];\n continue;\n }\n\n // Get name and value\n $headerName = strtolower($this->_tokenize($header, ':'));\n $headerValue = trim(chop($this->_tokenize(\"\\r\\n\")));\n\n // If its already there, then add as an array. Otherwise, just keep\n // there\n if (isset ($this->headers [$headerName])) {\n if (gettype($this->headers [$headerName]) == \"string\") {\n $this->headers [$headerName] = array(\n $this->headers [$headerName]\n );\n }\n\n $this->headers [$headerName] [] = $headerValue;\n } else {\n $this->headers [$headerName] = $headerValue;\n }\n }\n\n // Save cookies if asked\n if ($this->saveCookie && isset ($this->headers ['set-cookie'])) {\n $this->_parseCookie();\n }\n }", "title": "" }, { "docid": "45e6481de88a95c86325b2033745113b", "score": "0.611725", "text": "private function processHeaders(): void\n {\n if (is_string($this->headers)) {\n $this->headers = $this->headerToArray($this->headers);\n }\n }", "title": "" }, { "docid": "5555a5a84495bb0381468069a30922af", "score": "0.6114265", "text": "private function _http_parse_headers($raw_headers) {\n $headers = array();\n $key = ''; // [+]\n\n foreach (explode(\"\\n\", $raw_headers) as $i => $h) {\n $h = explode(':', $h, 2);\n\n if (isset($h[1])) {\n if (!isset($headers[$h[0]]))\n $headers[$h[0]] = trim($h[1]);\n elseif (is_array($headers[$h[0]])) {\n // $tmp = array_merge($headers[$h[0]], array(trim($h[1]))); // [-]\n // $headers[$h[0]] = $tmp; // [-]\n $headers[$h[0]] = array_merge($headers[$h[0]], array(trim($h[1]))); // [+]\n } else {\n // $tmp = array_merge(array($headers[$h[0]]), array(trim($h[1]))); // [-]\n // $headers[$h[0]] = $tmp; // [-]\n $headers[$h[0]] = array_merge(array($headers[$h[0]]), array(trim($h[1]))); // [+]\n }\n\n $key = $h[0]; // [+]\n } else // [+]\n { // [+]\n if (substr($h[0], 0, 1) == \"\\t\") // [+]\n $headers[$key] .= \"\\r\\n\\t\" . trim($h[0]); // [+]\n elseif (!$key) // [+]\n $headers[0] = trim($h[0]);\n trim($h[0]); // [+]\n } // [+]\n }\n\n return $headers;\n }", "title": "" }, { "docid": "869f771ecd9a2097c3e8683a4241cc2f", "score": "0.60768074", "text": "function http_parse_headers($raw_headers)\n{\n\t$headers = array();\n\t$key = ''; // [+]\n\n\tforeach(explode(\"\\n\", $raw_headers) as $i => $h)\n\t{\n\t\t$h = explode(':', $h, 2);\n\n\t\tif (isset($h[1]))\n\t\t{\n\t\t\tif (!isset($headers[$h[0]]))\n\t\t\t\t$headers[$h[0]] = trim($h[1]);\n\t\t\telseif (is_array($headers[$h[0]]))\n\t\t\t{\n\t\t\t\t// $tmp = array_merge($headers[$h[0]], array(trim($h[1]))); // [-]\n\t\t\t\t// $headers[$h[0]] = $tmp; // [-]\n\t\t\t\t$headers[$h[0]] = array_merge($headers[$h[0]], array(trim($h[1]))); // [+]\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// $tmp = array_merge(array($headers[$h[0]]), array(trim($h[1]))); // [-]\n\t\t\t\t// $headers[$h[0]] = $tmp; // [-]\n\t\t\t\t$headers[$h[0]] = array_merge(array($headers[$h[0]]), array(trim($h[1]))); // [+]\n\t\t\t}\n\n\t\t\t$key = $h[0]; // [+]\n\t\t}\n\t\telse // [+]\n\t\t{ // [+]\n\t\t\tif (substr($h[0], 0, 1) == \"\\t\") // [+]\n\t\t\t\t$headers[$key] .= \"\\r\\n\\t\".trim($h[0]); // [+]\n\t\t\telseif (!$key) // [+]\n\t\t\t\t$headers[0] = trim($h[0]);trim($h[0]); // [+]\n\t\t} // [+]\n\t}\n\n\treturn $headers;\n}", "title": "" }, { "docid": "008fd98875236c2b8ec616b78408e6a8", "score": "0.6067921", "text": "private function parsePOHeaders($po_headers) {\n foreach (explode(\"\\n\", $po_headers) as $po_header) {\n if (mb_strpos($po_header, ':', 0, 'ASCII') === false) continue;\n\n list ($header, $values) = explode(':', $po_header, 2);\n\n $header = mb_strtolower($header, 'ASCII');\n\n if ($header = 'plural-forms') {\n foreach (explode(';', $values) as $value) {\n if (preg_match('/^nplurals\\s*=\\s*(\\d+)$/i', trim($value), $matches)) {\n $this->nplurals = intval($matches[1]);\n } elseif (preg_match('@^plural\\s*=([ a-zA-Z0-9_:;\\(\\)\\?\\|\\&=!<>+*/\\%-]+)$@i', trim($value), $matches)) {\n $this->plural_test_expr = $this->convertTernaryOperator($matches[1]);\n }\n }\n } elseif ($header = 'content-type') {\n foreach (explode(';', $values) as $value) {\n if (preg_match('/^charset\\s*=\\s*(\\S+)$/i', trim($value), $matches)) {\n $this->charset = $matches[1];\n }\n }\n }\n }\n }", "title": "" }, { "docid": "5ef764f7ea8ffde1bd3614900d5a4f9f", "score": "0.5987174", "text": "static function httpParseHeaders( $header )\n {\n $retVal = array();\n $fields = explode(\"\\r\\n\", preg_replace('/\\x0D\\x0A[\\x09\\x20]+/', ' ', $header));\n foreach( $fields as $field ) {\n if( preg_match('/([^:]+): (.+)/m', $field, $match) ) {\n $match[1] = preg_replace_callback('/(?<=^|[\\x09\\x20\\x2D])./', \n function ($m) { return mb_strtoupper($m[0]); },\n mb_strtolower(trim($match[1])));\n if( isset($retVal[$match[1]]) ) {\n $retVal[$match[1]] = array($retVal[$match[1]], $match[2]);\n } else {\n $retVal[$match[1]] = trim($match[2]);\n }\n }\n }\n return $retVal;\n }", "title": "" }, { "docid": "ed4a43599b8b70c32ca7aebbf70414bb", "score": "0.59434783", "text": "function decode_header ( $str )\r\n{\r\n $part = preg_split ( \"/\\r?\\n/\", $str, -1, PREG_SPLIT_NO_EMPTY );\r\n\r\n $out = array ();\r\n\r\n for ( $h = 0; $h < sizeof ( $part ); $h++ )\r\n {\r\n if ( $h != 0 )\r\n {\r\n $pos = strpos ( $part[$h], ':' );\r\n\r\n $k = strtolower ( str_replace ( ' ', '', substr ( $part[$h], 0, $pos ) ) );\r\n\r\n $v = trim ( substr ( $part[$h], ( $pos + 1 ) ) );\r\n }\r\n else\r\n {\r\n $k = 'status';\r\n\r\n $v = explode ( ' ', $part[$h] );\r\n\r\n $v = $v[1];\r\n }\r\n\r\n if ( $k == 'set-cookie' )\r\n {\r\n $out['cookies'][] = $v;\r\n }\r\n else if ( $k == 'content-type' )\r\n {\r\n if ( ( $cs = strpos ( $v, ';' ) ) !== false )\r\n {\r\n $out[$k] = substr ( $v, 0, $cs );\r\n }\r\n else\r\n {\r\n $out[$k] = $v;\r\n }\r\n }\r\n else\r\n {\r\n $out[$k] = $v;\r\n }\r\n }\r\n\r\n return $out;\r\n}", "title": "" }, { "docid": "d9d1ebd2b7ebbf1cf4d425060fc58f13", "score": "0.59339046", "text": "function _parseHeaders($responseHeader)\r\n {\r\n // Break up the headers\r\n $headers = explode(\"\\r\\n\", $responseHeader);\r\n \r\n // Clear the header array\r\n $this->_clearHeaders();\r\n \r\n // Get resposne status\r\n if($this->status == 0)\r\n {\r\n // Oooops !\r\n if(!eregi($match = \"^http/[0-9]+\\\\.[0-9]+[ \\t]+([0-9]+)[ \\t]*(.*)\\$\", $headers[0], $matches))\r\n {\r\n $this->_setError('Unexpected HTTP response status');\r\n return FALSE;\r\n }\r\n \r\n // Gotcha!\r\n $this->status = $matches[1];\r\n array_shift($headers);\r\n }\r\n \r\n // Prepare all the other headers\r\n foreach ($headers as $header)\r\n {\r\n // Get name and value\r\n $headerName = strtolower($this->_tokenize($header, ':'));\r\n $headerValue = trim(chop($this->_tokenize(\"\\r\\n\")));\r\n \r\n // If its already there, then add as an array. Otherwise, just keep there\r\n if(isset($this->headers[$headerName]))\r\n {\r\n if(gettype($this->headers[$headerName]) == \"string\")\r\n {\r\n $this->headers[$headerName] = array($this->headers[$headerName]);\r\n }\r\n \r\n $this->headers[$headerName][] = $headerValue;\r\n }\r\n else\r\n {\r\n $this->headers[$headerName] = $headerValue;\r\n }\r\n }\r\n \r\n // Save cookies if asked \r\n if ($this->saveCookie && isset($this->headers['set-cookie']))\r\n {\r\n $this->_parseCookie();\r\n }\r\n }", "title": "" }, { "docid": "8e2b976789836bd4fbaee9a1818d7d0a", "score": "0.5931929", "text": "public static function ParseHTTPHeaders(string $rawHeaders) : array {\n\n $headers = [];\n\n $lines = explode(\"\\n\", $rawHeaders);\n foreach ($lines as $line) {\n\n if (strpos($line, ':') !== FALSE) {\n\n $header = explode(':', $line, 2);\n $headers[strtolower(trim($header[0]))] = trim($header[1]);\n\n } elseif (stripos($line, 'get ') !== FALSE) {\n\n preg_match('/GET (.*) HTTP/i', $line, $reqResource);\n $headers['get'] = trim($reqResource[1]);\n\n } elseif (preg_match('#HTTP/\\d+\\.\\d+ (\\d+)#', $line)) {\n\n $pieces = explode(' ', $line, 3);\n $headers['status-code'] = intval($pieces[1]);\n $headers['status-text'] = $pieces[2];\n\n }\n\n }\n\n return $headers;\n }", "title": "" }, { "docid": "380b5e68b2e5af226b9c1209de587a35", "score": "0.59170294", "text": "function format_header()\n\t{\n\t\t$this->headers = str_replace(\"\\r\\n\", \"\\n\", $this->headers);\n\t\t// Cleanup multiline headers.\n\t\t$this->headers = preg_replace(\"!\\n(\\t| )+!\", ' ', $this->headers);\n\t\t$hdr = explode(\"\\n\", trim($this->headers));\n\t\t$this->headers = array();\n\t\tforeach ($hdr as $v) {\n\t\t\t$hk = substr($v, 0, ($p = strpos($v, ':')));\n\t\t\t// Skip non-valid header lines.\n\t\t\tif (!$hk || ++$p == strlen($v) || ($v{$p} != ' ' && $v{$p} != \"\\t\")) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$hv = substr($v, $p);\n\t\t\t$hk = strtolower(trim($hk));\n\n\t\t\tif (!isset($this->headers[$hk])) {\n\t\t\t\t$this->headers[$hk] = decode_header_value($hv);\n\t\t\t} else {\n\t\t\t\t$this->headers[$hk] .= ' '. decode_header_value($hv);\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "433d88ef39143b0e5cbde9339bde0315", "score": "0.59055376", "text": "function get_status_header_desc($code) {\n\tglobal $output_header_to_desc;\n\n\t$code = abs(intval($code));\n\n\tif (!isset ($output_header_to_desc)) {\n\t\t$output_header_to_desc = [\n\t\t\t100 => 'Continue',\n\t\t\t101 => 'Switching Protocols',\n\t\t\t102 => 'Processing',\n\n\t\t\t200 => 'OK',\n\t\t\t201 => 'Created',\n\t\t\t202 => 'Accepted',\n\t\t\t203 => 'Non-Authoritative Information',\n\t\t\t204 => 'No Content',\n\t\t\t205 => 'Reset Content',\n\t\t\t206 => 'Partial Content',\n\t\t\t207 => 'Multi-Status',\n\t\t\t226 => 'IM Used',\n\n\t\t\t300 => 'Multiple Choices',\n\t\t\t301 => 'Moved Permanently',\n\t\t\t302 => 'Found',\n\t\t\t303 => 'See Other',\n\t\t\t304 => 'Not Modified',\n\t\t\t305 => 'Use Proxy',\n\t\t\t306 => 'Reserved',\n\t\t\t307 => 'Temporary Redirect',\n\n\t\t\t400 => 'Bad Request',\n\t\t\t401 => 'Unauthorized',\n\t\t\t402 => 'Payment Required',\n\t\t\t403 => 'Forbidden',\n\t\t\t404 => 'Not Found',\n\t\t\t405 => 'Method Not Allowed',\n\t\t\t406 => 'Not Acceptable',\n\t\t\t407 => 'Proxy Authentication Required',\n\t\t\t408 => 'Request Timeout',\n\t\t\t409 => 'Conflict',\n\t\t\t410 => 'Gone',\n\t\t\t411 => 'Length Required',\n\t\t\t412 => 'Precondition Failed',\n\t\t\t413 => 'Request Entity Too Large',\n\t\t\t414 => 'Request-URI Too Long',\n\t\t\t415 => 'Unsupported Media Type',\n\t\t\t416 => 'Requested Range Not Satisfiable',\n\t\t\t417 => 'Expectation Failed',\n\t\t\t422 => 'Unprocessable Entity',\n\t\t\t423 => 'Locked',\n\t\t\t424 => 'Failed Dependency',\n\t\t\t426 => 'Upgrade Required',\n\n\t\t\t500 => 'Internal Server Error',\n\t\t\t501 => 'Not Implemented',\n\t\t\t502 => 'Bad Gateway',\n\t\t\t503 => 'Service Unavailable',\n\t\t\t504 => 'Gateway Timeout',\n\t\t\t505 => 'HTTP Version Not Supported',\n\t\t\t506 => 'Variant Also Negotiates',\n\t\t\t507 => 'Insufficient Storage',\n\t\t\t510 => 'Not Extended'\n\t\t];\n\t}\n\n\tif (isset ($output_header_to_desc [ $code ])) {\n\t\treturn $output_header_to_desc [ $code ];\n\t} else {\n\t\treturn '';\n\t}\n}", "title": "" }, { "docid": "396c802909988e3e839bb8c92660b3ff", "score": "0.5873118", "text": "protected function _parse($response){\n\t\tlist($response_headers, $response_body) = explode(\"\\r\\n\\r\\n\", $response, 2);\n\t\t$response_header_lines = explode(\"\\r\\n\", $response_headers);\n\t\t// First line of headers is the HTTP response code\n\t\t$http_response_line = array_shift($response_header_lines);\n\t\tif(preg_match('@^HTTP/[0-9]\\.[0-9] ([0-9]{3})@',$http_response_line, $matches)) { $response_code = $matches[1]; }\n\t\t// put the rest of the headers in an array\n\t\t$response_header_array = array();\n\t\tforeach($response_header_lines as $header_line){\n\t\t\tlist($header,$value) = explode(': ', $header_line, 2);\n\t\t\t@$response_header_array[$header] .= $value.\"\\n\";\n\t\t}\n\t\treturn array($response_code, $response_header_array, $response_body);\n\t}", "title": "" }, { "docid": "628ee39f4c198872e09444ddea99bf0c", "score": "0.58721304", "text": "public function testParseHeaders()\n {\n $client = new BuiltinClient2();\n\n $expected = [\n 'Accept' =>\n array(\n 0 => 'application/json',\n 1 => 'text/xml',\n ),\n 'Server' =>\n array(\n 0 => 'nginx',\n ),\n 'Cache-Control' =>\n array(\n 0 => 'max-age=0, no-cache, no-store',\n ),\n ];\n\n $this->assertEquals($expected, $client->parseHeaders([\n 'HTTP/1.0 204 No Content',\n 'Accept: application/json',\n 'Accept: text/xml',\n 'Server: nginx',\n 'Cache-Control: max-age=0, no-cache, no-store',\n ]));\n }", "title": "" }, { "docid": "34754e3396596de944359d073ae3c396", "score": "0.5807659", "text": "function getStatusCode($rawHeaders) {\n $pattern = preg_quote('Status: ', '/');\n // finalise the regular expression, matching the whole line\n $pattern = \"/^.*$pattern.*\\$/m\";\n\n $match = false;\n\n if(preg_match($pattern, $rawHeaders, $match)){\n //$match = substr(strpos('Status ', $match[0]))\n if (preg_match('!\\d+!', $match[0], $match)) {\n $match = $match[0];\n }\n }\n\n\n\n return $match;\n}", "title": "" }, { "docid": "2db1539444d9da1ab3b671ade83286e3", "score": "0.5805181", "text": "private function parseResponse() {\n $token = \"\\n\";\n $line = strtok($this->returnedTransfer, $token);\n\n if (stripos($line, ' 100 Continue') !== false && stripos($line, 'HTTP') === 0) {\n do {\n $line = strtok($token);\n } while (0 < strlen(trim($line)));\n strtok($token); // also slip next HTTP TAG\n }\n\n // Proxy connection support.\n if (stripos($line, ' 200 Connection established') !== false && stripos($line, 'HTTP') === 0) {\n do {\n $line = strtok($token);\n } while (0 < strlen(trim($line)));\n strtok($token); // also slip next HTTP TAG\n }\n\n while (0 < strlen(trim($line = strtok($token)))) {\n $this->parseResponseHeaderLine($line);\n }\n $this->parsedResponse = strtok(\"\");\n }", "title": "" }, { "docid": "b55ac47399027e813d160dadd9aa2472", "score": "0.5788816", "text": "private function parse_header()\n {\n $parts = split($this->newline . $this->newline, $this->content);\n\n $this->header = array_shift($parts);\n $this->content = implode($parts, $this->newline . $this->newline);\n\n $parts = split($this->newline, $this->header);\n foreach ($parts as $part)\n {\n if (preg_match(\"/(.*)\\: (.*)/\", $part, $matches))\n {\n $this->headers[$matches[1]] = $matches[2];\n }\n }\n\n if (eregi(\"Set-Cookie\", $this->header))\n {\n $this->parse_cookies();\n }\n }", "title": "" }, { "docid": "2269eccf5d0003adb45af6b2efa48e67", "score": "0.57813615", "text": "public static function parseStatus(string $status): array\n {\n Assertion::startsWith(\n $status,\n 'HTTP/',\n \"Invalid HTTP status '$status', expected format like: 'HTTP/1.1 200 OK'.\"\n );\n\n $part = explode(' ', $status, 3);\n\n return [\n 'http_version' => substr(strrchr($part[0], '/') ?? '', 1),\n 'code' => $part[1],\n 'message' => $part[2] ?? '',\n ];\n }", "title": "" }, { "docid": "b0a1987d29142223a6a83845440b95eb", "score": "0.57798684", "text": "public function __construct($rawResponse, $httpHeaders = array())\n\t{\n\t\t//Assume 0, 'Communication Error', utf-8, and text/xml\n\t\t$status = 0;\n\t\t$statusMessage = 'Communication Error';\n\t\t$type = 'text/plain';\n\t\t$encoding = 'UTF-8';\n\n\t\t//iterate through headers for real status, type, and encoding\n\t\tif (is_array($httpHeaders) && count($httpHeaders) > 0)\n\t\t{\n\t\t\t//look at the first header for the HTTP status code\n\t\t\t//and message (errors are usually returned this way)\n\t\t\tif (substr($httpHeaders[0], 0, 4) == 'HTTP')\n\t\t\t{\n\t\t\t\t//$parts = split(' ', substr($httpHeaders[0], 9), 2);\n\t\t\t\t$parts = explode(' ', substr($httpHeaders[0], 9), 2);\n\n\t\t\t\t$status = $parts[0];\n\t\t\t\t$statusMessage = trim($parts[1]);\n\n\t\t\t\tarray_shift($httpHeaders);\n\t\t\t}\n\n\t\t\t//Look for the Content-Type response header and determine type\n\t\t\t//and encoding from it (if possible)\n\t\t\tforeach ($httpHeaders as $header)\n\t\t\t{\n\t\t\t\tif (substr($header, 0, 13) == 'Content-Type:')\n\t\t\t\t{\n\t\t\t\t\t//split content type into two parts if possible\n\t\t\t\t\t//$parts = split(';', substr($header, 13), 2);\n\t\t\t\t\t$parts = explode(';', substr($header, 13), 2);\n\n\t\t\t\t\t$type = trim($parts[0]);\n\n\t\t\t\t\tif ($parts[1])\n\t\t\t\t\t{\n\t\t\t\t\t\t//split the encoding section again to get the value\n\t\t\t\t\t\t//$parts = split('=', $parts[1], 2);\n\t\t\t\t\t\t$parts = explode('=', $parts[1], 2);\n\n\t\t\t\t\t\tif ($parts[1])\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$encoding = trim($parts[1]);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t//print_r($httpHeaders);\n\t\t}\n\n\t\t$this->_rawResponse = $rawResponse;\n\t\t$this->_type = $type;\n\t\t$this->_encoding = $encoding;\n\t\t$this->_httpStatus = $status;\n\t\t$this->_httpStatusMessage = $statusMessage;\n\t}", "title": "" }, { "docid": "e3905ca4c5236309afc5d049bba93a2a", "score": "0.57751566", "text": "private function parseHttpStatus(&$http_message)\n {\n preg_match(\"#HTTP/\\d\\.\\d\\s(.*[^\\r])\\r?\\n#\", $http_message, $status);\n\n if (!empty($status)) {\n return $status[1];\n }\n\n return null;\n }", "title": "" }, { "docid": "75443948a874661a591cbf040cb588a5", "score": "0.575787", "text": "private function parseHttpHeaders(&$http_message)\n {\n preg_match_all(\"/([A-Za-z0-9-_]+):\\s?(.*?)\\r?\\n/m\", $http_message, $headers);\n\n if (empty($headers)) {\n return null;\n }\n\n $header_collection = new HeaderCollection();\n\n foreach ($headers[1] as $index => $header) {\n $header_collection[$header] = $headers[2][$index];\n }\n\n return $header_collection;\n }", "title": "" }, { "docid": "43d2865ce379f493cf0c4d9d37baefdf", "score": "0.57416666", "text": "public function getHeadersParser();", "title": "" }, { "docid": "1d491977d4282d5a0c8881c81040d785", "score": "0.5710704", "text": "protected function _getHeaderFromResponse()\r\n\t{\r\n\t\t$size = $this->getHeaderSize();\r\n\t\t$response = $this->_raw_response;\r\n\t\t\r\n\t\t$header_lines = explode(\"\\n\", substr($response, 0, $size));\r\n\t\t$output = array();\r\n\t\tforeach( $header_lines AS $line )\r\n\t\t{\r\n\t\t\t$pos = strpos($line, ': ');\r\n\t\t\tif( $pos )\r\n\t\t\t{\r\n\t\t\t\t$name = substr($line, 0, $pos);\r\n\t\t\t\t$value = trim(substr($line, $pos + 2));\r\n\t\t\t\t$output[$name] = $value;\r\n\t\t\t}\r\n\t\t\telseif( strpos($line, 'HTTP') === 0 )\r\n\t\t\t{\r\n\t\t\t\t$this->_response_code = substr($line, 9, 3);\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\treturn $output;\r\n\t}", "title": "" }, { "docid": "3c0509c1e66cf56601a1c6ea4b6338c6", "score": "0.5697908", "text": "function handle_content_headers()\n\t{\n\t\tif (isset($this->headers['content-type'])) {\n\t\t\t$this->parse_multival_headers($this->headers['content-type'], 'content-type');\n\t\t} else {\n\t\t\t$this->headers['content-type'] = 'text/plain';\n\t\t\t$this->headers['__other_hdr__']['content-type']['charset'] = 'utf-8';\n\t\t}\n\n\t\tif (isset($this->headers['content-disposition'])) {\n\t\t\t$this->parse_multival_headers($this->headers['content-disposition'], 'content-disposition');\n\t\t} else {\n\t\t\t$this->headers['content-disposition'] = 'inline';\n\t\t}\n\t\tif (isset($this->headers['content-transfer-encoding'])) {\n\t\t\t$this->parse_multival_headers($this->headers['content-transfer-encoding'], 'content-transfer-encoding');\n\t\t} else {\n\t\t\t$this->headers['content-transfer-encoding'] = '7bit';\n\t\t}\n\t}", "title": "" }, { "docid": "c8bdcf3fe06b882e6ebcb0ec829a28fe", "score": "0.5677888", "text": "protected function parseResponse() {\r\n\r\n parse_str($this->response);\r\n\r\n\r\n /* TRANS_ID */\r\n $this->transId = $TRANS_ID;\r\n\r\n /* STATUS */\r\n $this->status = $STATUS;\r\n\r\n /* AVS */\r\n $this->avsResp = $AVS;\r\n\r\n /* CVV2 */\r\n $this->cvv2Resp = $CVV2;\r\n\r\n /* AUTH_CODE */\r\n $this->authCode = $AUTH_CODE;\r\n\r\n /* MESSAGE */\r\n $this->message = $MESSAGE;\r\n\r\n /* REBID */\r\n $this->rebid = $REBID;\r\n }", "title": "" }, { "docid": "e80316be355783dc56706d9d837a8079", "score": "0.5676586", "text": "function get_headers_from_curl_response($response){\n \t\t$headers = array();\n \t$header_text = substr($response, 0, strpos($response, \"\\r\\n\\r\\n\"));\n \t\tforeach (explode(\"\\r\\n\", $header_text) as $i => $line)\n \t\tif ($i === 0)\n \t$headers['http_code'] = $line;\n \t\telse{\n \t\tlist ($key, $value) = explode(': ', $line);\n \t\t\t$headers[$key] = $value;\n \t\t}\n return $headers;\n}", "title": "" }, { "docid": "5560ca44b6f06397beb7f0ae13c13893", "score": "0.5662006", "text": "function parseSheetStatus($statusCode)\r\n{\r\n\r\n $return = array();\r\n\r\n if (isset($statusCode) && $statusCode != \"\") {\r\n\r\n if (stripos($statusCode, \"_\") && $statusCode != 0) {\r\n\r\n $SPLIT = explode(\"_\", $statusCode);\r\n\r\n $return['code'] = (int)$SPLIT[0];\r\n $return['last_sheet'] = (int)$SPLIT[1];\r\n } else {\r\n\r\n $return['code'] = $statusCode;\r\n $return['last_sheet'] = \"none\";\r\n }\r\n } else {\r\n\r\n $return['code'] = (int)0;\r\n $return['last_sheet'] = \"none\";\r\n }\r\n\r\n return $return;\r\n}", "title": "" }, { "docid": "3d02af7c46226229e2dd857899218546", "score": "0.5639836", "text": "public function test_Static_ParseRawHeader()\n {\n $rawHeader =<<<EOF\n Accept: */*\n Content-Type: application/x-www-form-urlencoded;charset=UTF-8\n Sec-Fetch-Dest: empty\n Sec-Fetch-Mode: cors\n Sec-Fetch-Site: same-site\n User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.61 Safari/537.36\n X-Client-Data: CJC2yQEIorbJAQjBtskBCKmdygEIqLTKARibvsoB\nEOF;\n $headers = Message::parseRawHeader($rawHeader);\n\n $this->assertSame($headers['Accept'], '*/*');\n $this->assertSame($headers['Content-Type'], 'application/x-www-form-urlencoded;charset=UTF-8');\n $this->assertSame($headers['Sec-Fetch-Dest'], 'empty');\n $this->assertSame($headers['Sec-Fetch-Mode'], 'cors');\n $this->assertSame($headers['Sec-Fetch-Site'], 'same-site');\n $this->assertSame($headers['User-Agent'], 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.61 Safari/537.36');\n $this->assertSame($headers['X-Client-Data'], 'CJC2yQEIorbJAQjBtskBCKmdygEIqLTKARibvsoB');\n\n // Test - General response header.\n $rawHeader =<<<EOF\n HTTP/1.1 200\n access-control-allow-credentials: true\n access-control-allow-methods: OPTIONS\n access-control-allow-origin: https://www.facebook.com\n access-control-expose-headers: X-FB-Debug, X-Loader-Length\n alt-svc: h3-27=\":443\"; ma=3600\n cache-control: private, no-cache, no-store, must-revalidate\n content-length: 0\n content-security-policy: default-src * data: blob: 'self';script-src *.facebook.com *.fbcdn.net *.facebook.net *.google-analytics.com *.virtualearth.net *.google.com 127.0.0.1:* *.spotilocal.com:* 'unsafe-inline' 'unsafe-eval' blob: data: 'self';style-src data: blob: 'unsafe-inline' *;connect-src *.facebook.com facebook.com *.fbcdn.net *.facebook.net *.spotilocal.com:* wss://*.facebook.com:* https://fb.scanandcleanlocal.com:* attachment.fbsbx.com ws://localhost:* blob: *.cdninstagram.com 'self' chrome-extension://boadgeojelhgndaghljhdicfkmllpafd chrome-extension://dliochdbjfkdbacpmhlcpmleaejidimm;block-all-mixed-content;upgrade-insecure-requests;\n content-type: text/html; charset=\"utf-8\"\n date: Thu, 04 Jun 2020 02:46:12 GMT\n date: Thu, 04 Jun 2020 02:46:12 GMT\n expires: Sat, 01 Jan 2000 00:00:00 GMT\n pragma: no-cache\n status: 200\n strict-transport-security: max-age=15552000; preload\n vary: Origin\n x-content-type-options: nosniff\n x-fb-debug: XNgyVH3VRKeOuGyxAit2WqKJ+334baHQuKQP0CM2lr/8ToZmwhNFU9N5ctr3LeTgXYWXemfGlJaAl/PASeEL5Q==\n x-frame-options: DENY\n x-xss-protection: 0\nEOF;\n $headers = Message::parseRawHeader($rawHeader);\n\n $this->assertSame($headers['access-control-allow-credentials'], 'true');\n $this->assertSame($headers['access-control-allow-methods'], 'OPTIONS');\n $this->assertSame($headers['access-control-allow-origin'], 'https://www.facebook.com');\n $this->assertSame($headers['access-control-expose-headers'], 'X-FB-Debug, X-Loader-Length');\n $this->assertSame($headers['alt-svc'], 'h3-27=\":443\"; ma=3600');\n $this->assertSame($headers['cache-control'], 'private, no-cache, no-store, must-revalidate');\n $this->assertSame($headers['content-length'], '0');\n $this->assertSame($headers['content-security-policy'], \"default-src * data: blob: 'self';script-src *.facebook.com *.fbcdn.net *.facebook.net *.google-analytics.com *.virtualearth.net *.google.com 127.0.0.1:* *.spotilocal.com:* 'unsafe-inline' 'unsafe-eval' blob: data: 'self';style-src data: blob: 'unsafe-inline' *;connect-src *.facebook.com facebook.com *.fbcdn.net *.facebook.net *.spotilocal.com:* wss://*.facebook.com:* https://fb.scanandcleanlocal.com:* attachment.fbsbx.com ws://localhost:* blob: *.cdninstagram.com 'self' chrome-extension://boadgeojelhgndaghljhdicfkmllpafd chrome-extension://dliochdbjfkdbacpmhlcpmleaejidimm;block-all-mixed-content;upgrade-insecure-requests;\");\n $this->assertSame($headers['content-type'], 'text/html; charset=\"utf-8\"');\n $this->assertSame($headers['date'], 'Thu, 04 Jun 2020 02:46:12 GMT');\n $this->assertSame($headers['date'], 'Thu, 04 Jun 2020 02:46:12 GMT');\n $this->assertSame($headers['expires'], 'Sat, 01 Jan 2000 00:00:00 GMT');\n $this->assertSame($headers['pragma'], 'no-cache');\n $this->assertSame($headers['status'], '200');\n $this->assertSame($headers['strict-transport-security'], 'max-age=15552000; preload');\n $this->assertSame($headers['vary'], 'Origin');\n $this->assertSame($headers['x-content-type-options'], 'nosniff');\n $this->assertSame($headers['x-fb-debug'], 'XNgyVH3VRKeOuGyxAit2WqKJ+334baHQuKQP0CM2lr/8ToZmwhNFU9N5ctr3LeTgXYWXemfGlJaAl/PASeEL5Q==');\n $this->assertSame($headers['x-frame-options'], 'DENY');\n $this->assertSame($headers['x-xss-protection'], '0');\n\n // Test 3 - Just one line.\n $rawHeader =<<<EOF\n HTTP/1.1 200\n access-control-allow-credentials: true\nEOF;\n $headers = Message::parseRawHeader($rawHeader);\n $this->assertEquals(count($headers), 1);\n $this->assertSame($headers['access-control-allow-credentials'], 'true');\n\n // Test 4 - Empty.\n $rawHeader = '';\n $headers = Message::parseRawHeader($rawHeader);\n $this->assertSame($headers, []);\n }", "title": "" }, { "docid": "5aa57a4cb615ccb175276d65e646009f", "score": "0.5612154", "text": "private function parseHttp($header) {\n list($version,$code,$message) = array_pad(explode(\" \", $header), 3, \"\");\n\n $this->transactionHeaders[] = $header;\n \n $versionParts = explode(\"/\",$version);\n $this->version = end($versionParts);\n $this->code = $code;\n $this->message = $message;\n }", "title": "" }, { "docid": "9f70ae66cd71512984fa83a51bcfa606", "score": "0.55996954", "text": "private function decode_header ( $str )\n\t{\n\t $part = preg_split ( \"/\\r?\\n/\", $str, -1, PREG_SPLIT_NO_EMPTY );\n\n\t $out = array ();\n\n\t for ( $h = 0; $h < sizeof ( $part ); $h++ )\n\t {\n\t if ( $h != 0 )\n\t {\n\t $pos = strpos ( $part[$h], ':' );\n\n\t $k = strtolower ( str_replace ( ' ', '', substr ( $part[$h], 0, $pos ) ) );\n\n\t $v = trim ( substr ( $part[$h], ( $pos + 1 ) ) );\n\t }\n\t else\n\t {\n\t $k = 'status';\n\n\t $v = explode ( ' ', $part[$h] );\n\n\t $v = $v[1];\n\t }\n\n\t if ( $k == 'set-cookie' )\n\t {\n\t $out['cookies'][] = $v;\n\t }\n\t else if ( $k == 'content-type' )\n\t {\n\t if ( ( $cs = strpos ( $v, ';' ) ) !== false )\n\t {\n\t $out[$k] = substr ( $v, 0, $cs );\n\t }\n\t else\n\t {\n\t $out[$k] = $v;\n\t }\n\t }\n\t else\n\t {\n\t $out[$k] = $v;\n\t }\n\t }\n\n\t return $out;\n\t}", "title": "" }, { "docid": "a05c701f521f0bac339af3a6918965b4", "score": "0.55950034", "text": "protected function parseResponse()\n {\n if (!empty($this->response)) {\n preg_match('/^SIP\\/2\\.0 (([0-9]{3}) (\\w+))/', $this->response, $parsedResponse);\n $this->responseCode = $parsedResponse[2];\n $this->responseMessage = $parsedResponse[3];\n $this->responseConcat = $parsedResponse[1];\n }\n }", "title": "" }, { "docid": "4bd3e74642f7b5459d32bacac6d13468", "score": "0.55871856", "text": "public function parseHTTPResponse($request, $body, array $headers = array(), array $options = array());", "title": "" }, { "docid": "5df361c448018f4868dc54474e1ff014", "score": "0.55860496", "text": "protected function parseRawMessage($message) {\n\t\t$positionStartBody = strpos($message, \"\\r\\n\\r\\n\");\n\t\t\n\t\t$startPositionOffset = 4;\n\t\tif ($positionStartBody === false) {\n\t\t\t$positionStartBody = strpos($message, \"\\n\\n\");\n\t\t\t$startPositionOffset = 2;\n\t\t\tif ($positionStartBody === false) {\n\t\t\t\tthrow new Exception(\"Invalid HTTP message provided. It does not contain a header part.\");\n\t\t\t}\n\t\t}\n\t\t\n\t\t$headerString = str_replace(\"\\r\\n\", \"\\n\", trim(substr($message, 0, $positionStartBody), \"\\r\\n\"));\n\t\t$content = substr($message, $positionStartBody + $startPositionOffset);\n\t\n\t\t$headers = explode(\"\\n\", $headerString);\n\t\t$statusLine = current($headers);\n\t\tarray_shift($headers);\n\t\t$this->setHeaders($headers);\n\t\t$this->parseStatusLine($statusLine);\n\t\t$this->setBody($content);\n\t}", "title": "" }, { "docid": "763ac49c34227e855514556bc641f3c4", "score": "0.55817413", "text": "static function parseHeaders($data) {\n\n\t\t$return = array();\n\t\t$data = explode(\"\\r\\n\", $data);\n\n\t\tforeach($data as $lineNumber => $headerText) {\n\t\t\tif(!$lineNumber)\n\t\t\t\tcontinue;\n\t\t\t$data = explode(\": \", $headerText, 2);\n\t\t\tif(count($data) == 2)\n\t\t\t\t$return[$data[0]] = $data[1];\n\t\t}\n\n\t\treturn $return;\n\n\t}", "title": "" }, { "docid": "0357d114c84f810919e233790bac8783", "score": "0.5515631", "text": "public function getHeaders()\n {\n $preparedHeaders = [];\n if ($this->statusCode !== null) {\n $protocolVersion = isset($_SERVER['SERVER_PROTOCOL']) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0';\n $statusHeader = $protocolVersion . ' ' . $this->statusCode . ' ' . $this->statusMessage;\n $preparedHeaders[] = $statusHeader;\n }\n foreach ($this->headers as $name => $values) {\n foreach ($values as $value) {\n $preparedHeaders[] = $name . ': ' . $value;\n }\n }\n return $preparedHeaders;\n }", "title": "" }, { "docid": "21b03a2e382e5f1dd6b8a334ee8e5e70", "score": "0.5509784", "text": "public function getHeaders()\n {\n if (! $this->_header)\n return array();\n if (! $this->_headerMap) {\n $headers = explode(\"\\r\\n\", trim($this->_header));\n $output = array();\n $output['http_status'] = array_shift($headers);\n foreach ($headers as $line) {\n $params = explode(':', $line, 2);\n if (! isset($params[1]))\n $output['http_status'] = $params[0];\n else\n $output[trim($params[0])] = trim($params[1]);\n }\n $this->_headerMap = $output;\n }\n return $this->_headerMap;\n }", "title": "" }, { "docid": "93f650cfa600ae6a9d2e72890ad428f4", "score": "0.5509125", "text": "public function decodeHeader()\n\t{\n\t\t$addr = array(\n\t\t\t'to',\n\t\t\t'cc',\n\t\t\t'bcc',\n\t\t\t'reply-to',\n\t\t\t'from',\n\t\t);\n\n\t\tif(empty($this->_already['getMail']))\n\t\t{\n\t\t\t$this->getMail();\n\t\t}\n\n\t\t// cutting\n\t\tif(0 === preg_match('/\\r?\\n\\r?\\n/is', trim($this->all), $matches, PREG_OFFSET_CAPTURE))\n\t\t{\n\t\t\t$header_all = $this->all;\n\t\t\t$this->body_all = NULL;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$offset = $matches[0][1];\n\t\t\t$header_all = trim(substr($this->all, 0, $offset));\n\t\t\t$this->body_all = trim(substr($this->all, $offset + 1));\n\t\t}\n\t\t$this->header = $this->buildHeader($header_all);\n\t\t// address field action , force to array type\n\t\tforeach($addr as $ad)\n\t\t{\n\t\t\tif( ! isset($this->header[$ad]))\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif(is_array($this->header[$ad]))\n\t\t\t{\n\t\t\t\t$addr_header = array_shift($this->header[$ad]);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$addr_header = $this->header[$ad];\n\t\t\t}\n\t\t\t$person = explode(',', $addr_header);\n\t\t\t$this->header[$ad] = array();\n\t\t\tforeach($person as $pers)\n\t\t\t{\n\t\t\t\tif( ! empty($pers))\n\t\t\t\t{\n\t\t\t\t\t$this->header[$ad][] = $this->splitMime($pers, TRUE);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t// subject\n\t\tif(isset($this->header['subject']))\n\t\t{\n\t\t\t$this->header['subject'] = $this->splitMime($this->header['subject'], FALSE);\n\t\t}\n\t\t$this->_already['header'] = TRUE;\n\t}", "title": "" }, { "docid": "8bc2ca27a332cf81c6b037e3c9ff4f83", "score": "0.5501937", "text": "public function setHeaders($headers)\n {\n $normalizedHeaders = [];\n foreach ($headers as $name => $value) {\n if (is_int($name)) {\n // parse raw header :\n $rawHeader = $value;\n if (strpos($rawHeader, 'HTTP/') === 0) {\n $parts = explode(' ', $rawHeader, 3);\n $normalizedHeaders['http-code'] = [$parts[1]];\n } elseif (($separatorPos = strpos($rawHeader, ':')) !== false) {\n $name = strtolower(trim(substr($rawHeader, 0, $separatorPos)));\n $value = trim(substr($rawHeader, $separatorPos + 1));\n $normalizedHeaders[$name][] = $value;\n } else {\n $normalizedHeaders['raw'][] = $rawHeader;\n }\n } else {\n $normalizedHeaders[$name] = $value;\n }\n }\n\n $this->setHeadersInternal($normalizedHeaders);\n }", "title": "" }, { "docid": "5cf49ca9fd27cda9e5419922e2b92c25", "score": "0.5496189", "text": "public function parseHeader()\n {\n // Headers are mandatory, otherwise we cannot read data from it.\n $headerinfo = trim(fgets($this->fileHandle));\n $headers = array_map('strtolower',explode(\",\",$headerinfo));\n\n return $headers;\n }", "title": "" }, { "docid": "2c993b4b644effdab3bd1a293eaa2529", "score": "0.54562515", "text": "public static function parse_from_headers(\\Requests_Response_Headers $headers, \\Requests_IRI $origin = \\null, $time = \\null)\n {\n }", "title": "" }, { "docid": "9eae39b577616504da4320a715187d4c", "score": "0.5414531", "text": "private function parseHeaders(array $headers) {\n $headersArr = array();\n\n foreach ($headers as $i => $header) {\n $parts = explode(\": \", $header);\n\n if (isset($parts[1])) {\n $headersArr[$parts[0]] = $parts[1];\n }\n else {\n $headersArr[$i] = $header;\n }\n }\n\n return $headersArr;\n }", "title": "" }, { "docid": "2f31ae61bf32b28888a26860ddc95d97", "score": "0.5412323", "text": "protected function processRawResponse()\n {\n $xml = simplexml_load_string($this->rawResponse);\n\n if (isset($xml->reply->orderStatus->payment->lastEvent)) {\n $paymentStatus = (string) $xml->reply->orderStatus->payment->lastEvent;\n $this->message = $paymentStatus;\n $this->isSuccess = ('AUTHORISED' == strtoupper($paymentStatus));\n return;\n }\n\n if (isset($xml->reply->error['code'])) {\n $this->message = 'Code ' . (string) $xml->reply->error['code'];\n return;\n }\n\n if (isset($xml->head->title)) {\n $this->message = (string) $xml->head->title;\n return;\n }\n }", "title": "" }, { "docid": "7a20e03d04c4ea873bc5c43df89b7196", "score": "0.5406864", "text": "final public static function header_strings() {\n\t\treturn [\n\t\t\t100 => 'Continue',\n\t\t\t101 => 'Switching Protocols',\n\t\t\t102 => 'Processing',\n\t\t\t200 => 'OK',\n\t\t\t201 => 'Created',\n\t\t\t202 => 'Accepted',\n\t\t\t203 => 'Non-Authoritative Information',\n\t\t\t204 => 'No Content',\n\t\t\t205 => 'Reset Content',\n\t\t\t206 => 'Partial Content',\n\t\t\t207 => 'Multi-Status',\n\t\t\t226 => 'IM Used',\n\t\t\t300 => 'Multiple Choices',\n\t\t\t301 => 'Moved Permanently',\n\t\t\t302 => 'Found',\n\t\t\t303 => 'See Other',\n\t\t\t304 => 'Not Modified',\n\t\t\t305 => 'Use Proxy',\n\t\t\t306 => 'Reserved',\n\t\t\t307 => 'Temporary Redirect',\n\t\t\t400 => 'Bad Request',\n\t\t\t401 => 'Unauthorized',\n\t\t\t402 => 'Payment Required',\n\t\t\t403 => 'Forbidden',\n\t\t\t404 => 'Not Found',\n\t\t\t405 => 'Method Not Allowed',\n\t\t\t406 => 'Not Acceptable',\n\t\t\t407 => 'Proxy Authentication Required',\n\t\t\t408 => 'Request Timeout',\n\t\t\t409 => 'Conflict',\n\t\t\t410 => 'Gone',\n\t\t\t411 => 'Length Required',\n\t\t\t412 => 'Precondition Failed',\n\t\t\t413 => 'Request Entity Too Large',\n\t\t\t414 => 'Request-URI Too Long',\n\t\t\t415 => 'Unsupported Media Type',\n\t\t\t416 => 'Requested Range Not Satisfiable',\n\t\t\t417 => 'Expectation Failed',\n\t\t\t422 => 'Unprocessable Entity',\n\t\t\t423 => 'Locked',\n\t\t\t424 => 'Failed Dependency',\n\t\t\t426 => 'Upgrade Required',\n\t\t\t500 => 'Internal Server Error',\n\t\t\t501 => 'Not Implemented',\n\t\t\t502 => 'Bad Gateway',\n\t\t\t503 => 'Service Unavailable',\n\t\t\t504 => 'Gateway Timeout',\n\t\t\t505 => 'HTTP Version Not Supported',\n\t\t\t506 => 'Variant Also Negotiates',\n\t\t\t507 => 'Insufficient Storage',\n\t\t\t510 => 'Not Extended'\n\t\t];\n\t}", "title": "" }, { "docid": "4c70f0dd066d832a2bae9a36d6478c25", "score": "0.5404035", "text": "static function parse_head($head, $clean_up = true)\n\t{\n\t\t$headers = array();\n\t\tforeach( explode(\"\\n\", $head) as $header_line )\n\t\t{\n\t\t\tlist($name, $value) = explode(': ', $header_line, 2);\n\t\t\tif ($clean_up)\n\t\t\t{\n\t\t\t\t$name = strtolower(trim($name));\n\t\t\t\t$value = trim($value);\n\t\t\t}\n\t\t\t\n\t\t\tif ( !array_key_exists($name, $headers) )\n\t\t\t\t$headers[$name] = $value;\n\t\t\telse\n\t\t\t\tif (is_array($headers[$name]))\n\t\t\t\t\tarray_push($headers[$name], $value);\n\t\t\t\telse\n\t\t\t\t\t$headers[$name] = array($headers[$name], $value);\n\t\t}\n\t\t\n\t\treturn $headers;\n\t}", "title": "" }, { "docid": "b2320736e919d49149b299f29dbc60c4", "score": "0.5391465", "text": "private function _getStatusCodeMessage($status) {\r\n // these could be stored in a .ini file and loaded\r\n // via parse_ini_file()... however, this will suffice\r\n // for an example\r\n $codes = Array(\r\n 100 => 'Continue',\r\n 101 => 'Switching Protocols',\r\n 200 => 'OK',\r\n 201 => 'Created',\r\n 202 => 'Accepted',\r\n 203 => 'Non-Authoritative Information',\r\n 204 => 'No Content',\r\n 205 => 'Reset Content',\r\n 206 => 'Partial Content',\r\n 300 => 'Multiple Choices',\r\n 301 => 'Moved Permanently',\r\n 302 => 'Found',\r\n 303 => 'See Other',\r\n 304 => 'Not Modified',\r\n 305 => 'Use Proxy',\r\n 306 => '(Unused)',\r\n 307 => 'Temporary Redirect',\r\n 400 => 'Bad Request',\r\n 401 => 'Unauthorized',\r\n 402 => 'Payment Required',\r\n 403 => 'Forbidden',\r\n 404 => 'Not Found',\r\n 405 => 'Method Not Allowed',\r\n 406 => 'Not Acceptable',\r\n 407 => 'Proxy Authentication Required',\r\n 408 => 'Request Timeout',\r\n 409 => 'Conflict',\r\n 410 => 'Gone',\r\n 411 => 'Length Required',\r\n 412 => 'Precondition Failed',\r\n 413 => 'Request Entity Too Large',\r\n 414 => 'Request-URI Too Long',\r\n 415 => 'Unsupported Media Type',\r\n 416 => 'Requested Range Not Satisfiable',\r\n 417 => 'Expectation Failed',\r\n 500 => 'Internal Server Error',\r\n 501 => 'Not Implemented',\r\n 502 => 'Bad Gateway',\r\n 503 => 'Service Unavailable',\r\n 504 => 'Gateway Timeout',\r\n 505 => 'HTTP Version Not Supported'\r\n );\r\n\r\n return (isset($codes[$status])) ? $codes[$status] : '';\r\n }", "title": "" }, { "docid": "756c50aec0320dcb3c02dced4949cf5f", "score": "0.5384732", "text": "public function testHeaders()\n {\n try {\n $parser = Parser::parseFile(__DIR__ . '/pofiles/healthy.po');\n $headers = $parser->getHeaders();\n\n $this->assertCount(18, $headers);\n $this->assertEquals(\"\\\"Project-Id-Version: \\\\n\\\"\", $headers[0]);\n $this->assertEquals(\"\\\"Report-Msgid-Bugs-To: \\\\n\\\"\", $headers[1]);\n $this->assertEquals(\"\\\"POT-Creation-Date: 2013-09-25 15:55+0100\\\\n\\\"\", $headers[2]);\n $this->assertEquals(\"\\\"PO-Revision-Date: \\\\n\\\"\", $headers[3]);\n $this->assertEquals(\"\\\"Last-Translator: Raúl Ferràs <xxxxxxxxxx@xxxxxxx.xxxxx>\\\\n\\\"\", $headers[4]);\n $this->assertEquals(\"\\\"Language-Team: \\\\n\\\"\", $headers[5]);\n $this->assertEquals(\"\\\"MIME-Version: 1.0\\\\n\\\"\", $headers[6]);\n $this->assertEquals(\"\\\"Content-Type: text/plain; charset=UTF-8\\\\n\\\"\", $headers[7]);\n $this->assertEquals(\"\\\"Content-Transfer-Encoding: 8bit\\\\n\\\"\", $headers[8]);\n $this->assertEquals(\"\\\"Plural-Forms: nplurals=2; plural=n != 1;\\\\n\\\"\", $headers[9]);\n $this->assertEquals(\"\\\"X-Poedit-SourceCharset: UTF-8\\\\n\\\"\", $headers[10]);\n $this->assertEquals(\"\\\"X-Poedit-KeywordsList: __;_e;_n;_t\\\\n\\\"\", $headers[11]);\n $this->assertEquals(\"\\\"X-Textdomain-Support: yes\\\\n\\\"\", $headers[12]);\n $this->assertEquals(\"\\\"X-Poedit-Basepath: .\\\\n\\\"\", $headers[13]);\n $this->assertEquals(\"\\\"X-Generator: Poedit 1.5.7\\\\n\\\"\", $headers[14]);\n $this->assertEquals(\"\\\"X-Poedit-SearchPath-0: .\\\\n\\\"\", $headers[15]);\n $this->assertEquals(\"\\\"X-Poedit-SearchPath-1: ../..\\\\n\\\"\", $headers[16]);\n $this->assertEquals(\"\\\"X-Poedit-SearchPath-2: ../../../modules\\\\n\\\"\", $headers[17]);\n } catch (\\Exception $e) {\n $this->fail($e->getMessage());\n }\n }", "title": "" }, { "docid": "db725dbe0ec079df355dcd8b483daf2a", "score": "0.53838265", "text": "private function parseHeaders($headers)\n {\n $headerLines = \\explode(\"\\r\\n\", \\trim($headers));\n $startLine = null;\n $headers = array();\n foreach ($headerLines as $i => $line) {\n if ($i === 0 && \\strpos($line, ':') === false) {\n $startLine = $line;\n continue;\n }\n list($name, $value) = \\array_replace(array(null, null), \\explode(':', $line, 2));\n $name = \\trim($name);\n if (isset($headers[$name]) === false) {\n $headers[$name] = array();\n }\n $headers[$name][] = $value !== null\n ? \\trim($value)\n : null;\n }\n return array($startLine, $headers);\n }", "title": "" }, { "docid": "e9ee013bfc8c9ca8829664cc14825a1a", "score": "0.53637636", "text": "public function testProcessResponseHeader()\n {\n // init\n $oHttpClient = new \\HTTPClient();\n\n // the test\n $result = $this->invokeMethod(\n $oHttpClient,\n 'processResponseHeader',\n [\"HTTP/1.1 200 OK\\nServer: nginx/1.10.3\\nContent-Type: text/html\"]\n );\n\n // asserts\n $this->assertInternalType(IsType::TYPE_ARRAY, $result);\n $this->assertEquals('HTTP/1.1 200 OK', $result[0]);\n $this->assertArrayHasKey('Server', $result);\n $this->assertEquals('nginx/1.10.3', $result['Server']);\n $this->assertArrayHasKey('Content-Type', $result);\n $this->assertEquals('text/html', $result['Content-Type']);\n }", "title": "" }, { "docid": "88078931b978b46785a15675b95b8162", "score": "0.53537416", "text": "public function getHeaders() {\n\t\t$headers = array();\n\n\t\tif ($this->httpHeader['code'] !== null) {\n\t\t\t$headers[] = $this->httpHeader['status'];\n\t\t}\n\n\t\tforeach ($this->headers as $header) {\n\t\t\t$headers[] = $header['one-line'] ? $header['value'] : \"{$header['name']}: {$header['value']}\";\n\t\t}\n\n\t\treturn $headers;\n\t}", "title": "" }, { "docid": "c9e1865febbed1c3253f02417d81479e", "score": "0.53514576", "text": "private function parse($content) {\n $hunks = explode(\"\\r\\n\\r\\n\", trim($content));\n if (!is_array($hunks) or count($hunks) < 2) {\n return false;\n }\n $this->responseHeaders = $hunks[count($hunks) - 2];\n $this->responseContent = $hunks[count($hunks) - 1];\n $this->responseHeaders = explode(\"\\n\", $this->responseHeaders);\n unset($hunks);\n unset($header);\n if (!$this->statusIsOk()) {\n return false;\n }\n if (in_array('Transfer-Coding: chunked', $this->responseHeaders)) {\n $this->unchunkHttpResponse();\n }\n $this->responseContent = trim($this->responseContent);\n\n /* On some servers, the HTTP content starts with the length of its content\n * and ends with a 0 on a last dedied line.\n */\n $end = substr($this->responseContent, -2);\n if ($end == \"\\n0\") {\n $firstLine = \"\";\n for ($i = 0; $this->responseContent[$i] != \"\\n\"; $i++) {\n $firstLine .= $this->responseContent[$i];\n }\n $size = hexdec($firstLine);\n if ($size > 0 && $size < strlen($this->responseContent) - strlen($firstLine)) {\n $this->responseContent = substr($this->responseContent, strlen($firstLine) + 1, $size);\n }\n }\n }", "title": "" }, { "docid": "510728e21c5677decff8926ba312aa51", "score": "0.5337747", "text": "private function _parseResponseHeaders($header) {\n $headers = array();\n $h = explode(\"\\r\\n\", $header);\n foreach ($h as $header) {\n if (strpos($header, ':') !== false) {\n list($type, $value) = explode(\":\", $header, 2);\n if (isset($headers[$type])) {\n if (is_array($headers[$type])) {\n $headers[$type][] = trim($value);\n }\n else {\n $headers[$type] = array($headers[$type], trim($value));\n }\n }\n else {\n $headers[$type] = trim($value);\n }\n }\n }\n return $headers;\n }", "title": "" }, { "docid": "727e1e61a5b8436df3928b91a8198761", "score": "0.5306452", "text": "private function parse_www_auth(array $headers)\n\t{\n\t\t/*\n\t\t * Looking for:\n\t\t * WWW-Authenticate: Digest realm=\"testrealm@host.com\",qop=\"auth,auth-int\",nonce=\"dcd98b7102dd2f0e8b11d0f600bfb0c093\",opaque=\"5ccc069c403ebaf9f0171e9517f40e41\"\n\t\t */\n\t\t\n\t\t$return = false;\n\t\t\n\t\t// Loop the response headers\n\t\tforeach ($headers as $header_name => $header_value) {\n\t\t\t\t\n\t\t\t// Find the WWW-Authenticate header\n\t\t\tif (\\Str::lower($header_name) === 'www-authenticate') {\n\t\t\n\t\t\t\t$params = explode(' ', $header_value);\n\t\t\t\t\n\t\t\t\tif (\\Str::upper($params[0]) !== 'DIGEST') {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tunset($params[0]);\n\t\t\t\t$param_array = explode(',', implode(' ', $params));\n\t\t\n\t\t\t\t$return = array();\n\t\t\n\t\t\t\t// Loop the tokens (array('nonce=675858','poq=...'))\n\t\t\t\tforeach ($param_array as $param) {\n\t\t\t\t\t\n\t\t\t\t\t// Find that fish!\n\t\t\t\t\t$token_data = explode('=', $param);\n\t\t\t\t\t\t\n\t\t\t\t\t$token_name = $token_data[0];\n\t\t\t\t\tunset($token_data[0]);\n\t\t\t\t\t\t\n\t\t\t\t\t// Remove the quotes if we need to.\n\t\t\t\t\t$token_value = implode('=', $token_data);\n\t\t\t\t\tif (substr($token_value, 0, 1) === '\"') {\n\t\t\t\t\t\t$token_value = substr($token_value, 1, strlen($token_value)-2);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Set out tokens.\n\t\t\t\t\t$return[$token_name] = $token_value;\n\t\t\t\t\t\t\n\t\t\t\t}\n\t\t\n\t\t\t\tif (empty($return)) {\n\t\t\t\t\t\n\t\t\t\t\t// We found the header and attempted to parse it.\n\t\t\t\t\treturn false;\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\n\t\t\t}\n\t\t\t\t\n\t\t}\n\t\t\n\t\treturn $return;\n\t}", "title": "" }, { "docid": "ddcd0ebef227d9026d02999c45c280e1", "score": "0.5296695", "text": "private function parseHeaders($headers)\n {\n $result = [];\n\n foreach (explode(\"\\n\", $headers) as $row) {\n $header = explode(':', $row, 2);\n\n if (count($header) == 2) {\n $result[$header[0]] = trim($header[1]);\n }\n else {\n $result[] = $header[0];\n }\n }\n\n return $result;\n }", "title": "" }, { "docid": "fc3b6c89f2794cfce5587efe93e5b620", "score": "0.52912843", "text": "public static function http_status( $code ) {\r\n\t\t$http = array (\r\n\t\t 100 => 'HTTP/1.1 100 Continue',\r\n\t\t 101 => 'HTTP/1.1 101 Switching Protocols',\r\n\t\t 200 => 'HTTP/1.1 200 OK',\r\n\t\t 201 => 'HTTP/1.1 201 Created',\r\n\t\t 202 => 'HTTP/1.1 202 Accepted',\r\n\t\t 203 => 'HTTP/1.1 203 Non-Authoritative Information',\r\n\t\t 204 => 'HTTP/1.1 204 No Content',\r\n\t\t 205 => 'HTTP/1.1 205 Reset Content',\r\n\t\t 206 => 'HTTP/1.1 206 Partial Content',\r\n\t\t 300 => 'HTTP/1.1 300 Multiple Choices',\r\n\t\t 301 => 'HTTP/1.1 301 Moved Permanently',\r\n\t\t 302 => 'HTTP/1.1 302 Found',\r\n\t\t 303 => 'HTTP/1.1 303 See Other',\r\n\t\t 304 => 'HTTP/1.1 304 Not Modified',\r\n\t\t 305 => 'HTTP/1.1 305 Use Proxy',\r\n\t\t 307 => 'HTTP/1.1 307 Temporary Redirect',\r\n\t\t 400 => 'HTTP/1.1 400 Bad Request',\r\n\t\t 401 => 'HTTP/1.1 401 Unauthorized',\r\n\t\t 402 => 'HTTP/1.1 402 Payment Required',\r\n\t\t 403 => 'HTTP/1.1 403 Forbidden',\r\n\t\t 404 => 'HTTP/1.1 404 Not Found',\r\n\t\t 405 => 'HTTP/1.1 405 Method Not Allowed',\r\n\t\t 406 => 'HTTP/1.1 406 Not Acceptable',\r\n\t\t 407 => 'HTTP/1.1 407 Proxy Authentication Required',\r\n\t\t 408 => 'HTTP/1.1 408 Request Time-out',\r\n\t\t 409 => 'HTTP/1.1 409 Conflict',\r\n\t\t 410 => 'HTTP/1.1 410 Gone',\r\n\t\t 411 => 'HTTP/1.1 411 Length Required',\r\n\t\t 412 => 'HTTP/1.1 412 Precondition Failed',\r\n\t\t 413 => 'HTTP/1.1 413 Request Entity Too Large',\r\n\t\t 414 => 'HTTP/1.1 414 Request-URI Too Large',\r\n\t\t 415 => 'HTTP/1.1 415 Unsupported Media Type',\r\n\t\t 416 => 'HTTP/1.1 416 Requested range not satisfiable',\r\n\t\t 417 => 'HTTP/1.1 417 Expectation Failed',\r\n\t\t 500 => 'HTTP/1.1 500 Internal Server Error',\r\n\t\t 501 => 'HTTP/1.1 501 Not Implemented',\r\n\t\t 502 => 'HTTP/1.1 502 Bad Gateway',\r\n\t\t 503 => 'HTTP/1.1 503 Service Unavailable',\r\n\t\t 504 => 'HTTP/1.1 504 Gateway Time-out'\r\n\t\t);\r\n\r\n\t\theader( $http[$code] );\r\n\t}", "title": "" }, { "docid": "92c8d1eb051b98901317f7df0c8fe7f1", "score": "0.52889097", "text": "private function _prepareHeader()\n\t{\t\tif (count($this->headers) > 0)\n\t\t{\n\t\t\tforeach ($this->headers as $header)\n\t\t\t{\n\t\t\t\t@header($header[0], $header[1]);\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "3a8dc3bb2d15b8b90096f35d707c6310", "score": "0.5283585", "text": "public function processResponseHeaders($responseHeaderContent)\n {\n // Split HTTP header up into lines\n $responseHeaderArray = explode(\"\\r\\n\", $responseHeaderContent);\n\n // Get HTTP code\n preg_match('/[1-5][0-4][0-9]/', $responseHeaderArray[0], $httpCode);\n $this->responseArray['httpcode'] = intval($httpCode[0]);\n unset($responseHeaderArray[0]);\n\n $this->responseArray['headers'] = array();\n\n if ($responseHeaderArray) {\n foreach ($responseHeaderArray as $headerString) {\n $headerKeyValue = explode(':', $headerString, 2);\n $headerKeyValue[0] = strtolower($headerKeyValue[0]);\n if ($this->responseArray['headers'][$headerKeyValue[0]] || strtolower($headerKeyValue[0]) == 'set-cookie') {\n if ($this->responseArray['headers'][$headerKeyValue[0]]\n && !is_array($this->responseArray['headers'][$headerKeyValue[0]])) {\n $this->responseArray['headers'][$headerKeyValue[0]] = array($this->responseArray['headers'][$headerKeyValue[0]]);\n }\n $this->responseArray['headers'][$headerKeyValue[0]][] = trim($headerKeyValue[1]);\n }\n else {\n $this->responseArray['headers'][$headerKeyValue[0]] = trim($headerKeyValue[1]);\n }\n }\n\n if ($this->cookieContainer && $this->responseArray['headers']['set-cookie']) {\n foreach($this->responseArray['headers']['set-cookie'] as $cookieLine) {\n $this->cookieContainer->parseCookie($cookieLine, $this->urlParts['originalUrl']);\n }\n }\n }\n return $this->responseArray['headers'];\n }", "title": "" }, { "docid": "c730afe56fc26bca1c773910330e719a", "score": "0.52757645", "text": "function parseR($header) {\r\n\t$header_array = array();\r\n\t$headerL = explode(\"\\n\", $header);\r\n\tforeach($headerL as $param) {\r\n\t\tif(stristr($param, ':')) {\r\n\t\t\t$key = explode(':', $param);\r\n\t\t\t$key1 = $key[0];\r\n\t\t\t$val1 = $key[1];\r\n\t\t\t$header_array[$key1] = $val1;\r\n\t\t}\r\n\t}\r\n\treturn $header_array;\r\n}", "title": "" }, { "docid": "8df0cfd2a8edf0a1b6f7b09042343650", "score": "0.52642024", "text": "protected function parseResponse($body)\n {\n $this->location = $body->getElementsByTagName('location')->item(0)->nodeValue;\n\n\n if ($body->getElementsByTagName('errNo')->length > 0) {\n $this->errNo = (int)$body->getElementsByTagName('errNo')->item(0)->nodeValue;\n }\n\n if ($body->getElementsByTagName('errText')->length > 0) {\n $this->errText = $body->getElementsByTagName('errText')->item(0)->nodeValue;\n }\n }", "title": "" }, { "docid": "99a9b8afd028de68f414cea7b70ff147", "score": "0.5255954", "text": "private function parseHttpMessages() {\n preg_match_all(\"#(HTTP/\\d\\.\\d.*?\\R\\R)#is\", $this->raw, $raw_matches);\n\n if (!empty($raw_matches[0])) {\n return $raw_matches[0];\n }\n\n return null;\n }", "title": "" }, { "docid": "2ecdb7fbdc6e7b28c66821f98d084dac", "score": "0.5252143", "text": "public static function extractHttpHeader($str) {\n $response = array();\n\n $pattern = '%\\A(.*\\x0D\\x0A)\\x0D\\x0A%imUsA';\n $answer = preg_match($pattern, $str, $m) ? $m[1] : '';\n\n $pattern = '%\\A(.*)\\x0D\\x0A%imUs';\n if(preg_match($pattern, $answer, $m)){\n $response['SA'] = $m[1];\n\n $pattern = '%\\s(\\d{3})\\s%';\n $response['Code'] = preg_match($pattern, $response['SA'], $m) ? $m[1] : '';\n }\n $pattern = \"%^([^\\x0D\\x0A]*):(.*)$%imUs\";\n preg_match_all($pattern, $answer, $m, PREG_SET_ORDER);\n $c = count($m);\n for ($i = 0; $i < $c; $i++) {\n $key = strtolower($m[$i][1]);\n $val = $m[$i][2];\n $response[$key] = $val;\n }\n $pattern = \"%charset=(.*)$%iU\";\n $charset = isset($response['content-type']) && preg_match($pattern, $response['content-type'], $m) ? $m[1] : '';\n if($charset){\n $response['charset'] = $charset;\n }\n\n return $response;\n }", "title": "" }, { "docid": "25cc63d46fdc4cc3afa46236fd2e2ef6", "score": "0.5248935", "text": "protected final function parseHeader($header) {\n\t\tif (!is_string($header)) {\n\t\t\tthrow new Exception(\"The given header is not a string.\");\n\t\t}\n\t\t\n\t\tif (preg_match('/([^:]+):(.*)/', $header, $rs)) {\n\t\t\t$key = strtolower($rs[1]);\n\t\t\t$value = trim($rs[2]);\n\t\t\t$key = strtolower($key);\n\t\t\tif (!isset($this->parsedHeaders[$key])) {\n\t\t\t\t$this->parsedHeaders[$key] = array();\n\t\t\t}\n\t\t\t$this->parsedHeaders[$key][] = $value;\n\t\t\t$this->processKeyedHeader($key, $value);\n\t\t}\n\t\telse {\n\t\t\tthrow new Exception(Customweb_Core_String::_(\"Invalid format of the header '@header'. It must contain a ':' char.\")->format(array('@header' => $header)));\n\t\t}\n\t}", "title": "" }, { "docid": "8321b1ea553ee158bee3b38c450547c1", "score": "0.5246168", "text": "function split_hdr_body()\n\t{\n\t\tif (!preg_match(\"!^(.*?)\\r?\\n\\r?\\n(.*)!s\", $this->raw_msg, $m)) {\n\t\t\treturn;\n\t\t}\n\n\t\t$this->body = $m[2];\n\t\t$this->headers = $m[1];\n\t}", "title": "" }, { "docid": "cc225769e795e9d0cc69b854e376dbf8", "score": "0.5243415", "text": "public static function parse_from_headers(\\WpOrg\\Requests\\Response\\Headers $headers, \\WpOrg\\Requests\\Iri $origin = null, $time = null)\n {\n }", "title": "" }, { "docid": "04f7666c1cdb5ec61299ef372d2637ff", "score": "0.5230003", "text": "protected function parseResults()\n\t{\n\t\t$this->resultCode = self::substring_between($this->response, '<resultCode>', '</resultCode>');\n\t\t$this->code = self::substring_between($this->response, '<code>', '</code>');\n\t\t$this->text = self::substring_between($this->response, '<text>', '</text>');\n\t\t$this->subscrId = self::substring_between($this->response, '<subscriptionId>', '</subscriptionId>');\n\t}", "title": "" }, { "docid": "f2e01f03e314f6ebab79a2ba69ad3cfb", "score": "0.5205737", "text": "protected function prepareHeaders() {\n\t\t$headers = array();\n\t\t$contentHeaders = array('CONTENT_LENGTH' => true, 'CONTENT_MD5' => true, 'CONTENT_TYPE' => true);\n\t\tforeach ($this->server as $key => $value) {\n\t\t\tif (0 === strpos($key, 'HTTP_')) {\n\t\t\t\t$key = strtr(strtolower(substr($key, 5)), '_', '-');\n\t\t\t\t$key = implode('-', array_map('ucfirst', explode('-', $key)));\n\t\t\t\t$headers[$key] = $value;\n\t\t\t} elseif (isset($contentHeaders[$key])) {\n\t\t\t\t$key = strtr(strtolower($key), '_', '-');\n\t\t\t\t$key = implode('-', array_map('ucfirst', explode('-', $key)));\n\t\t\t\t$headers[$key] = $value;\n\t\t\t}\n\t\t}\n\n\t\treturn $headers;\n\t}", "title": "" }, { "docid": "70d95beaa12020cb875da3671fdec017", "score": "0.5200182", "text": "function parseStatus($resp) {\n\n\t// this return probably needs a redo\n\tif (is_null($resp)) {\n\t\treturn NULL;\n\t\t//workerLog('parseStatus(): NULL return');\n\t}\n\telse {\n\t\t$array = array();\n\t\t$line = strtok($resp, \"\\n\");\n\n\t\twhile ($line) {\n\t\t\tlist($element, $value) = explode(': ', $line, 2);\n\t\t\t$array[$element] = $value;\n\t\t\t$line = strtok(\"\\n\");\n\t\t}\n\n\t\t// elapsed time\n\t\t// RADIO - time: 293:0, elapsed: 292.501, duration not present\n\t\t// SONG - time: 4:391, elapsed: 4.156, duration: 391.466\n\t\t// if state is stop then time, elapsed and duration are not present\n\t\t// time x:y where x = elapsed ss, y = duration ss\n\t\t$time = explode(':', $array['time']);\n\n\t\t// stopped\n\t\tif ($array['state'] == 'stop') {\n\t\t\t$percent = '0';\n\t\t\t$array['elapsed'] = '0';\n\t\t\t$array['time'] = '0';\n\t\t}\n\t\t// radio, upnp\n\t\telseif (!isset($array['duration']) || $array['duration'] == 0) { // @ohinckel https: //github.com/moode-player/moode/pull/13\n\t\t\t$percent = '0';\n\t\t\t$array['elapsed'] = $time[0];\n\t\t\t$array['time'] = $time[1];\n\t\t}\n\t\t// song file\n\t\telse {\n\t\t\tif ($time[0] != '0') {\n\t\t\t\t$percent = round(($time[0] * 100) / $time[1]);\n\t\t\t\t$array['elapsed'] = $time[0];\n\t\t\t\t$array['time'] = $time[1];\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$percent = '0';\n\t\t\t\t$array['elapsed'] = $time[0];\n\t\t\t\t$array['time'] = $time[1];\n\t\t\t}\n\t\t}\n\n\t\t$array['song_percent'] = $percent;\n\t\t$array['elapsed'] = $time[0];\n\t\t$array['time'] = $time[1];\n\n\t\t// sample rate\n\t\t// example formats for $array['audio'], dsd64:2, dsd128:2, 44100:24:2\n\t \t$audio_format = explode(':', $array['audio']);\n\t \t$array['audio_sample_rate'] = formatRate($audio_format[0]);\n\n\t\t// bit depth\n\t\tif (strpos($array['audio_sample_rate'], 'dsd') !== false) {\n\t\t\t$array['audio_sample_depth'] = $array['audio_sample_rate'];\n\t\t}\n\t\telse {\n\t\t\t// workaround for AAC files that show \"f\" for bit depth, assume decoded to 24 bit\n\t\t \t$array['audio_sample_depth'] = $audio_format[1] == 'f' ? '24' : $audio_format[1];\n\t\t}\n\n\t \t// channels\n\t \tif (strpos($array['audio_sample_rate'], 'dsd') !== false) {\n\t \t\t$array['audio_channels'] = formatChan($audio_format[1]);\n\t \t}\n\t \telse {\n\t\t \t$array['audio_channels'] = formatChan($audio_format[2]);\n\t\t}\n\n\t\t// bit rate\n\t\tif (!isset($array['bitrate']) || trim($array['bitrate']) == '') {\n\t\t\t$array['bitrate'] = '0 bps';\n\t\t}\n\t \telse {\n\t\t\tif ($array['bitrate'] == '0') {\n\t\t\t\t$array['bitrate'] = '';\n\t\t\t\t// for aiff, wav files and some radio stations ex: Czech Radio Classic\n\t\t\t \t//$array['bitrate'] = number_format((( (float)$audio_format[0] * (float)$array['audio_sample_depth'] * (float)$audio_format[2] ) / 1000000), 3, '.', '');\n\t\t\t}\n\t\t\telse {\n\t\t\t \t$array['bitrate'] = strlen($array['bitrate']) < 4 ? $array['bitrate'] : substr($array['bitrate'], 0, 1) . '.' . substr($array['bitrate'], 1, 3) ;\n\t\t\t \t$array['bitrate'] .= strpos($array['bitrate'], '.') === false ? ' kbps' : ' mbps';\n\t\t\t}\n\t\t}\n\t}\n\n\treturn $array;\n}", "title": "" }, { "docid": "d5e34a36f0a4ebb4b172c1fa8e72b8d3", "score": "0.519199", "text": "function parseHeader(&$data)\r\n {\r\n }", "title": "" }, { "docid": "c976243ba7e32a23afb859c75af7a2b4", "score": "0.51628286", "text": "function parseHttpResponse($content=null) {\n if (empty($content)) { return false; }\n // split into array, headers and content.\n $hunks = explode(\"\\r\\n\\r\\n\",trim($content));\n if (!is_array($hunks) or count($hunks) < 2) {\n return false;\n\t}\n $header = $hunks[count($hunks) - 2];\n $body = $hunks[count($hunks) - 1];\n $headers = explode(\"\\n\",$header);\n unset($hunks);\n unset($header);\t\n if (in_array('Transfer-Coding: chunked',$headers)) {\n return trim(unchunkHttpResponse($body));\n\t} else {\n return trim($body);\n\t}\n}", "title": "" }, { "docid": "7dcdb02c11863ed74b3b07a99235c4fb", "score": "0.51627016", "text": "protected function resetHeaders() {\n\t\t$this->headers = array();\n\t\t$this->parsedHeaders = array();\n\t\t$this->protocolVersion = '1.1';\n\t}", "title": "" }, { "docid": "fb7d5e9ab58ad42a797abb8bd8670836", "score": "0.51616585", "text": "public function __construct($response) \n {\n $pattern = '#HTTP/\\d\\.\\d.*?$.*?\\r\\n\\r\\n#ims';\n preg_match_all($pattern, $response, $matches);\n $headers = split(\"\\r\\n\", str_replace(\"\\r\\n\\r\\n\", '', array_pop($matches[0])));\n \n # Extract the version and status from the first header\n $version_and_status = array_shift($headers);\n preg_match('#HTTP/(\\d\\.\\d)\\s(\\d\\d\\d)\\s(.*)#', $version_and_status, $matches);\n $this->headers['Http-Version'] = $matches[1];\n $this->headers['Status-Code'] = $matches[2];\n $this->headers['Status'] = $matches[2].' '.$matches[3];\n \n # Convert headers into an associative array\n foreach ($headers as $header) {\n preg_match('#(.*?)\\:\\s(.*)#', $header, $matches);\n $this->headers[$matches[1]] = $matches[2];\n }\n \n # Remove the headers from the response body\n $this->body = preg_replace($pattern, '', $response);\n }", "title": "" }, { "docid": "519d49d8aa27f997462f9456db5a9a81", "score": "0.5154996", "text": "protected abstract function getHeaders();", "title": "" }, { "docid": "63f0dcdddd052943cce3739807b7a74e", "score": "0.5152453", "text": "private function parseHttpStatusCode(&$http_message)\n {\n preg_match(\"/HTTP\\/\\d\\.\\d\\s(\\d{3})/\", $http_message, $code);\n\n if (!empty($code)) {\n return intval($code[1]);\n }\n\n return 0;\n }", "title": "" }, { "docid": "9fb3d9da4ff51880f23637e331b5cc50", "score": "0.5140661", "text": "function fetch_useful_headers()\n\t{\n\t\t$this->subject = htmlspecialchars(decode_header_value($this->headers['subject']));\n\n\t\t// Attempt to Get Poster's IP from fields commonly used to store it.\n\t\tif (isset($this->headers['x-posted-by'])) {\n\t\t\t$this->ip = parse_ip($this->headers['x-posted-by']);\n\t\t} else if (isset($this->headers['x-originating-ip'])) {\n\t\t\t$this->ip = parse_ip($this->headers['x-originating-ip']);\n\t\t} else if (isset($this->headers['x-senderip'])) {\n\t\t\t$this->ip = parse_ip($this->headers['x-senderip']);\n\t\t} else if (isset($this->headers['x-mdremoteip'])) {\n\t\t\t$this->ip = parse_ip($this->headers['x-mdremoteip']);\n\t\t} else if (isset($this->headers['received'])) {\n\t\t\t$this->ip = parse_ip($this->headers['received']);\n\t\t}\n\n\t\t// Fetch From email and possible name.\n\t\tif (preg_match('!(.+?)<(.+?)>!', $this->headers['from'], $matches)) {\n\t\t\t$this->from_email = trim($matches[2]);\n\n\t\t\tif (!empty($matches[1])) {\n\t\t\t\t$matches[1] = decode_header_value($matches[1]);\n\t\t\t\tif ($matches[1][0] == '\"' && substr($matches[1], -1) == '\"') {\n\t\t\t\t\t$this->from_name = substr($matches[1], 1, -1);\n\t\t\t\t} else {\n\t\t\t\t\t$this->from_name = $matches[1];\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$this->from_name = $this->from_email;\n\t\t\t}\n\n\t\t\tif (!preg_match('!^\\w+!', $this->from_name)) {\n\t\t\t\t$this->from_name = substr($this->from_email, 0, strpos($this->from_email, '@'));\n\t\t\t}\n\t\t} else {\n\t\t\t$this->from_email = trim($this->headers['from']);\n\t\t\t$this->from_name = substr($this->from_email, 0, strpos($this->from_email, '@'));\n\t\t}\n\n\t\tif (empty($this->from_email) || empty($this->from_name)) {\n\t\t\tlog_script_error('No name or email for '. $this->headers['from'], $this->raw_msg);\n\t\t}\n\n\t\tif (isset($this->headers['message-id'])) {\n\t\t\t$this->msg_id = substr(trim($this->headers['message-id']), 1, -1);\n\t\t} else if (isset($this->headers['x-qmail-scanner-message-id'])) {\n\t\t\t$this->msg_id = substr(trim($this->headers['x-qmail-scanner-message-id']), 1, -1);\n\t\t} else {\n\t\t\tlog_script_error('No message id', $this->raw_msg);\n\t\t}\n\n\t\t// This fetches the id of the message if this is a reply to an existing message.\n\t\tif (!empty($this->headers['in-reply-to']) && preg_match('!<([^>]+)>$!', trim($this->headers['in-reply-to']), $match)) {\n\t\t\t$this->reply_to_msg_id = $match[1];\n\t\t} else if (!empty($this->headers['references']) && preg_match('!<([^>]+)>$!', trim($this->headers['references']), $match)) {\n\t\t\t$this->reply_to_msg_id = $match[1];\n\t\t}\n\t}", "title": "" }, { "docid": "ed743dbb2af5d7b80aa30632216caefd", "score": "0.51323986", "text": "public function __construct($raw) {\n\t\tif (!$raw) {\n\t\t\t// No response headers or body?\n\t\t\t$this->_failed = true;\n\t\t\treturn;\n\t\t} else if ($raw == 1) {\n\t\t\t// Curl may respond with \"1\" if the response is directed\n\t\t\t// to a file, such as a download.\n\t\t\t$this->_status['status_code'] = '200';\n\t\t\t$this->_status['status'] = 'OK';\n\t\t\treturn;\n\t\t}\n\n\t\t// Split headers and body of response.\n\t\t$parts = explode(\"\\r\\n\\r\\n\", $raw, 2);\n\t\tif (isset($parts[0])) {\n\t\t\t$this->_headers_raw = $parts[0];\n\t\t\t$this->_parseHeaders($parts[0]);\n\t\t}\n\t\tif (isset($parts[1])) {\n\t\t\t$this->_body = $parts[1];\n\t\t}\n\n\t\treturn;\n\t}", "title": "" }, { "docid": "3af24a3165a61d8f905d6f71ecca5660", "score": "0.5129574", "text": "function checkHTTPResponse( $header ) {\n $rVal = 0;\n \n if(preg_match_all('!HTTP/1.1 ([0-9a-zA-Z]*) !', $header, $matches, PREG_SET_ORDER)) {\n \tforeach($matches as $match) {\n $rVal = nullInt( $match[1] );\n \t}\n }\n\n // Return the HTTP Response Code\n return $rVal;\n }", "title": "" }, { "docid": "dba24dee130b63ec153c939093c36d24", "score": "0.51293665", "text": "function parseHeaderLines($all_lines)\n{\n $headers = [];\n $key = '';\n\n foreach ($all_lines as $line) {\n # add value to previously added header\n if (preg_match('#^[\\s\\t]+(?P<data>.*)$#', $line, $match)) {\n $headers[$key] .= ' ' . $match['data'];\n continue;\n }\n\n # otherwise get new key/value pair\n if (preg_match('#^(?P<key>.*?):\\s*(?P<value>.*)$#', $line, $match)) {\n $key = strtolower($match['key']);\n $headers[$key] = $match['value'];\n continue;\n }\n\n # if message header invalid, clear previous key\n $key = '';\n }\n\n return $headers;\n}", "title": "" }, { "docid": "5e8ddd6a3e075d9f3c2ef7b3375850ea", "score": "0.5122264", "text": "public function extractResponseHeadersAndBody()\n {\n $parts = explode(\"\\r\\n\\r\\n\", $this->rawResponse);\n $rawBody = array_pop($parts);\n $rawHeaders = implode(\"\\r\\n\\r\\n\", $parts);\n\n return [trim($rawHeaders), trim($rawBody)];\n }", "title": "" }, { "docid": "517439460851a0196d49a2d726c72253", "score": "0.51198137", "text": "public function getResponseHeaders();", "title": "" }, { "docid": "517439460851a0196d49a2d726c72253", "score": "0.51198137", "text": "public function getResponseHeaders();", "title": "" }, { "docid": "e287b011bfb57dd9cf91ad80f7243e24", "score": "0.50957537", "text": "public static function getStatusCodeMessage($status)\r\n\t{\r\n\t\t// via parse_ini_file()... however, this will suffice\r\n\t\t// for an example\r\n\t\t$codes = Array(\r\n\t\t100 => 'Continue',\r\n\t\t101 => 'Switching Protocols',\r\n\t\t200 => 'OK',\r\n\t\t201 => 'Created',\r\n\t\t202 => 'Accepted',\r\n\t\t203 => 'Non-Authoritative Information',\r\n\t\t204 => 'No Content',\r\n\t\t205 => 'Reset Content',\r\n\t\t206 => 'Partial Content',\r\n\t\t300 => 'Multiple Choices',\r\n\t\t301 => 'Moved Permanently',\r\n\t\t302 => 'Found',\r\n\t\t303 => 'See Other',\r\n\t\t304 => 'Not Modified',\r\n\t\t305 => 'Use Proxy',\r\n\t\t306 => '(Unused)',\r\n\t\t307 => 'Temporary Redirect',\r\n\t\t400 => 'Bad Request',\r\n\t\t401 => 'Unauthorized',\r\n\t\t402 => 'Payment Required',\r\n\t\t403 => 'Forbidden',\r\n\t\t404 => 'Not Found',\r\n\t\t405 => 'Method Not Allowed',\r\n\t\t406 => 'Not Acceptable',\r\n\t\t407 => 'Proxy Authentication Required',\r\n\t\t408 => 'Request Timeout',\r\n\t\t409 => 'Conflict',\r\n\t\t410 => 'Gone',\r\n\t\t411 => 'Length Required',\r\n\t\t412 => 'Precondition Failed',\r\n\t\t413 => 'Request Entity Too Large',\r\n\t\t414 => 'Request-URI Too Long',\r\n\t\t415 => 'Unsupported Media Type',\r\n\t\t416 => 'Requested Range Not Satisfiable',\r\n\t\t417 => 'Expectation Failed',\r\n\t\t500 => 'Internal Server Error',\r\n\t\t501 => 'Not Implemented',\r\n\t\t502 => 'Bad Gateway',\r\n\t\t503 => 'Service Unavailable',\r\n\t\t504 => 'Gateway Timeout',\r\n\t\t505 => 'HTTP Version Not Supported'\r\n\t\t);\r\n\r\n\t\treturn (isset($codes[$status])) ? $codes[$status] : '';\r\n\t}", "title": "" }, { "docid": "cb15dce8c48aaafd8c793d9fcdb12961", "score": "0.5094183", "text": "function parse_multival_headers($val, $key)\n\t{\n\t\tif (($p = strpos($val, ';')) !== false) {\n\t\t\t$this->headers[$key] = strtolower(trim(substr($val, 0, $p)));\n\t\t\t$val = ltrim(substr($val, $p+1));\n\t\t\tif (!empty($val) && preg_match_all('!([-A-Za-z]+)=\"?(.*?)\"?\\s*(?:;|$)!', $val, $m)) {\n\t\t\t\t$c = count($m[0]);\n\t\t\t\tfor ($i=0; $i<$c; $i++) {\n\t\t\t\t\t$this->headers['__other_hdr__'][$key][strtolower($m[1][$i])] = $m[2][$i];\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\t$this->headers[$key] = strtolower(trim($val));\n\t\t}\n\t}", "title": "" }, { "docid": "06c7a518a366955df3c9d716dcf1287f", "score": "0.5080733", "text": "function validateHttpResponse($headers=null) {\n if (!is_array($headers) or count($headers) < 1) { return false; }\n switch(trim(strtolower($headers[0]))) {\n case 'http/1.0 100 ok':\n case 'http/1.0 200 ok':\n case 'http/1.1 100 ok':\n case 'http/1.1 200 ok':\n return true;\n break;\n\t}\n return false;\n}", "title": "" }, { "docid": "c35ff8df1c8026bb47d43ead698393ca", "score": "0.5077809", "text": "function v4MatchHttpHeaders($headers, $hardwareInfo=null) {\n\t\t$hwProps = null;\n\t\t\n\t\t// Nothing to check\t\t\n\t\tif (empty($headers))\n\t\t\treturn false;\n\n\t\tunset($headers['ip']);\n\t\tunset($headers['host']);\n\n\t\t// Sanitize headers & cleanup language\n\t\tforeach($headers as $key => $value) {\n\t\t\t$key = strtolower($key);\n\n\t\t\tif ($key == 'accept-language' || $key == 'content-language') {\n\t\t\t\t$key = 'language';\n\t\t\t\t$tmp = preg_split(\"/[,;]/\", str_replace(\" \",\"\", strtolower($value)));\n\t\t\t\tif (! empty($tmp[0]))\n\t\t\t\t\t$value = $tmp[0];\n\t\t\t\telse\n\t\t\t\t\tcontinue;\n\t\t\t} elseif ($key != 'profile' && $key != 'x-wap-profile') {\n\t\t\t\t// Handle strings that have had + substituted for a space ie. badly (semi) url encoded..\n\t\t\t\t$charCounts = count_chars($value, 0);\n\t\t\t\t$stringLen = strlen($value);\n\t\t\t\tif ($charCounts[ord(' ')] == 0 && $charCounts[ord('+')] > 5 && $stringLen > 20) {\n\t\t\t\t\t$value = str_replace('+', ' ', $value);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$this->deviceHeaders[$key] = $this->cleanStr($value);\n\t\t\t$this->extraHeaders[$key] = $this->Extra->extraCleanStr($value);\n\t\t}\n\n\t\t$this->device = $this->matchDevice($this->deviceHeaders);\n\t\tif (empty($this->device)) {\n\t\t\tif (! isset($this->reply['status']) || $this->reply['status'] == 0) {\n\t\t\t\t// If no downstream error set then return not found.\n\t\t\t\treturn $this->setError(301, \"Not Found\");\n\t\t\t}\n\t\t\t// Error is already set, so return false \n\t\t\treturn false;\n\t\t}\n\n\t\tif (! empty($hardwareInfo))\n\t\t\t$hwProps = $this->infoStringToArray($hardwareInfo);\n\n\t\t// Stop on detect set - Tidy up and return\n\t\tif (! empty($this->device['Device']['hd_ops']['stop_on_detect'])) {\n\t\t\t// Check for hardwareInfo overlay\n\t\t\tif (! empty($this->device['Device']['hd_ops']['overlay_result_specs'])) {\n\t\t\t\t$this->hardwareInfoOverlay($this->device, $hwProps);\n\t\t\t}\n\t\t\t$this->reply['hd_specs'] = $this->device['Device']['hd_specs'];\n\t\t\treturn $this->setError(0, \"OK\");\n\t\t}\n\n\t\t// Get extra info\n\t\t$this->platform = $this->Extra->matchExtra('platform', $this->extraHeaders);\n\t\t$this->browser = $this->Extra->matchExtra('browser', $this->extraHeaders);\n\t\t$this->app = $this->Extra->matchExtra('app', $this->extraHeaders);\n\t\t$this->language = $this->Extra->matchLanguage($this->extraHeaders);\n\n\t\t// Find out if there is any contention on the detected rule.\n\t\t$deviceList = $this->getHighAccuracyCandidates();\n\t\tif (! empty($deviceList)) {\n\n\t\t\t// Resolve contention with OS check\n\t\t\t$this->Extra->set($this->platform);\n\t\t\t$pass1List = array();\n\t\t\tforeach($deviceList as $_id) {\n\t\t\t\t$tryDevice = $this->findById($_id);\n\t\t\t\tif ($this->Extra->verifyPlatform($tryDevice['Device']['hd_specs'])) {\n\t\t\t\t\t$pass1List[] = $_id;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Contention still not resolved .. check hardware\n\t\t\tif (count($pass1List) >= 2 && ! empty($hwProps)) {\n\n\t\t\t\t// Score the list based on hardware\n\t\t\t\t$result = array();\n\t\t\t\tforeach($pass1List as $_id) {\n\t\t\t\t\t$tmp = $this->findRating($_id, $hwProps);\n\t\t\t\t\tif (! empty($tmp)) {\n\t\t\t\t\t\t$tmp['_id'] = $_id;\n\t\t\t\t\t\t$result[] = $tmp;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Sort the results\n\t\t\t\tusort($result, array($this, 'hd_sortByScore'));\n\t\t\t\t$this->ratingResult = $result;\n\n\t\t\t\t// Take the first one\n\t\t\t\tif ($this->ratingResult[0]['score'] != 0) {\n\t\t\t\t\t$device = $this->findById($result[0]['_id']);\n\t\t\t\t\tif (! empty($device)) {\n\t\t\t\t\t\t$this->device = $device;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Overlay specs\n\t\t$this->specsOverlay('platform', $this->device, $this->platform['Extra']);\n\t\t$this->specsOverlay('browser', $this->device, $this->browser['Extra']);\n\t\t$this->specsOverlay('app', $this->device, $this->app['Extra']);\n\t\t$this->specsOverlay('language', $this->device, $this->language['Extra']);\n\n\t\t// Overlay hardware info result if required\n\t\tif (! empty($this->device['Device']['hd_ops']['overlay_result_specs']) && ! empty($hardwareInfo))\n\t\t\t$this->hardwareInfoOverlay($this->device, $hwProps);\n\n\t\t$this->reply['hd_specs'] = $this->device['Device']['hd_specs'];\n\t\treturn $this->setError(0, \"OK\");\n\t}", "title": "" }, { "docid": "04174ce7def5a259f0618b4b9a357d24", "score": "0.50738776", "text": "private function maybe_update_headers(): void\n {\n if ($this->headers !== $this->last_headers) {\n $this->parsed_headers = array_map(\n function (string $header_line): array {\n if (strpos($header_line, ',') === false) {\n return [$header_line];\n } else {\n return array_map('trim', explode(',', $header_line));\n }\n },\n $this->headers\n );\n }\n $this->last_headers = $this->headers;\n }", "title": "" }, { "docid": "315038005734b9538fe9acc15c557af3", "score": "0.5070555", "text": "public static function validate_headers()\n {\n if (!isset($_SERVER['HTTP_AUTHTOKEN'])) {\n // V1.0.0\n coreErrorController::throw_coreError('ERR_NEOCORTEX_REQUIRED_HTTP_HEADER_AUTHTOKEN_NOT_FOUND');\n }\n\n if (!isset($_SERVER[\"HTTP_USER_AGENT\"])) {\n if (!isset($_SERVER[\"HTTP_TOKENAGENT\"])) {\n // V1.0.0\n coreErrorController::throw_coreError('ERR_NEOCORTEX_REQUIRED_HTTP_HEADER_AGENT_NOT_FOUND');\n }\n }\n }", "title": "" }, { "docid": "c8284992067871bfa490faf26d4f6079", "score": "0.5068643", "text": "public static function should_decode($headers)\n {\n }", "title": "" }, { "docid": "c1272eea55bdc90b66f70273c159c1b9", "score": "0.5068016", "text": "public static function parseResponse(string $response): array\n {\n $response = str_replace(\"HTTP/1.1 100 Continue\\r\\n\\r\\n\", '', $response);\n\n [$rawHeader, $rawBody] = explode(\"\\r\\n\\r\\n\", $response, 2);\n\n // Parse headers and status.\n $headers = self::parseRawHeader($rawHeader);\n $status = array_shift($headers);\n\n return [$status, $headers, $rawBody];\n }", "title": "" } ]
9557808bbf3845bd9f435555ec904bd3
Get invited user's email by token
[ { "docid": "5d1cc59ea5231a0dd12a706edc25d8c2", "score": "0.6404144", "text": "public function actionCheckInvitationToken($token)\n {\n $invitation = InvitationResource::findByToken($token);\n if (!$invitation) {\n return $this->validationError('Invitation token is invalid, expired or used');\n }\n\n return $this->response($invitation->email);\n }", "title": "" } ]
[ { "docid": "64646989bd3a63a42dc7e41c8b25c9ed", "score": "0.70831305", "text": "function getEmail($token) {\n $sqlQuery = \"SELECT * FROM forgot_password_token WHERE token = :token\";\n $params = array(':token' => $token);\n $result = $this->DB->executeQuery($sqlQuery, $params, \"select\");\n if($result) {\n return $result[0]['email'];\n }else {\n return null;\n }\n }", "title": "" }, { "docid": "5eb92071f9acc9af3c787678d562c0e4", "score": "0.6907739", "text": "public function get_email_token($token){\n\t\t$this->db->select('*');\n\t\t$this->db->where('token',$token);\n\t\t$return = $this->db->get(DB_PREFIX.'users')->row_array();\n\t\treturn $return;\n\t}", "title": "" }, { "docid": "8e09a21c9a59e5dc354f36c49afc7361", "score": "0.6684524", "text": "public function getEmailByToken($token)\n {\n $reminder = $this->getReminder()\n ->where('token', '=', $token)\n ->where('created_at', '>=', $this->getOldestValidDate())\n ->first();\n\n return $reminder->email;\n }", "title": "" }, { "docid": "9de6967fc731e79e24c51f87737987d7", "score": "0.6659718", "text": "public function userEmail($response, \\League\\OAuth2\\Client\\Token\\AccessToken $token)\n {\n return isset($response->email) && $response->email ? $response->email : null;\n }", "title": "" }, { "docid": "c864279269f2273d2d340827e5ba2cd5", "score": "0.65561634", "text": "public function getRecipientEmail();", "title": "" }, { "docid": "1691d720c0967c340d3e617efe11cbee", "score": "0.6502798", "text": "public function getEmail_user()\r\n {\r\n return $this->email_user;\r\n }", "title": "" }, { "docid": "f26e8cef910ae14f5e1802f6c2ac5141", "score": "0.6478407", "text": "public function getUserByEmail();", "title": "" }, { "docid": "dc8add57acff49e09d6dc387ffdd26ba", "score": "0.64530826", "text": "public function getEmail();", "title": "" }, { "docid": "dc8add57acff49e09d6dc387ffdd26ba", "score": "0.64530826", "text": "public function getEmail();", "title": "" }, { "docid": "dc8add57acff49e09d6dc387ffdd26ba", "score": "0.64530826", "text": "public function getEmail();", "title": "" }, { "docid": "dc8add57acff49e09d6dc387ffdd26ba", "score": "0.64530826", "text": "public function getEmail();", "title": "" }, { "docid": "dc8add57acff49e09d6dc387ffdd26ba", "score": "0.64530826", "text": "public function getEmail();", "title": "" }, { "docid": "dc8add57acff49e09d6dc387ffdd26ba", "score": "0.64530826", "text": "public function getEmail();", "title": "" }, { "docid": "dc8add57acff49e09d6dc387ffdd26ba", "score": "0.64530826", "text": "public function getEmail();", "title": "" }, { "docid": "dc8add57acff49e09d6dc387ffdd26ba", "score": "0.64530826", "text": "public function getEmail();", "title": "" }, { "docid": "dc8add57acff49e09d6dc387ffdd26ba", "score": "0.64530826", "text": "public function getEmail();", "title": "" }, { "docid": "dc8add57acff49e09d6dc387ffdd26ba", "score": "0.64530826", "text": "public function getEmail();", "title": "" }, { "docid": "c49c7eed393fac6f21ae433902a10070", "score": "0.64402217", "text": "public function getUserEmail() {\n return $this->user[User::USER_EMAIL];\n }", "title": "" }, { "docid": "0512342a0b90ea7ea2f8be9b8064bac9", "score": "0.64308274", "text": "public function getemail()\n {\n return $this->setStatusCode(200)->respond(['email' => Auth::user()->email]);\n }", "title": "" }, { "docid": "fde7ad8192f47178518220b98abfe5e8", "score": "0.6376601", "text": "public function getUserEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "f470c81291ca66b5bd83395b2261556e", "score": "0.63653797", "text": "public function inviteUserGet($token)\n {\n list($response) = $this->inviteUserGetWithHttpInfo($token);\n return $response;\n }", "title": "" }, { "docid": "6af73e2d0c7c1921e92679946ab40936", "score": "0.6361692", "text": "public function getUserEmail()\n {\n return $this->getDataValue($this->mailColumn);\n }", "title": "" }, { "docid": "da414ebd742ea242a97ef8c2fb964027", "score": "0.6350083", "text": "public static function current_user_email() {\n\t\treturn self::current_user_details()['email'];\n\t}", "title": "" }, { "docid": "d03367436c68a82760f9679872972434", "score": "0.6344452", "text": "public function getEmail()\n {\n return $this->getValueByKey($this->response, 'email');\n }", "title": "" }, { "docid": "856865ad9ab90606bae23796719c6b94", "score": "0.6336364", "text": "public function getUserEmail(){\n\t\treturn($this ->userEmail);\n\t}", "title": "" }, { "docid": "ead903dfc878a51585dc43429ef7d977", "score": "0.6300826", "text": "public function getUserEmail()\n {\n return $this->getParameter('UserEmail');\n }", "title": "" }, { "docid": "44965bb989d80a73de7d6f8ec2cc6604", "score": "0.62837577", "text": "public function get_email() {\n $username = $_SESSION['admin_login'];\n global $db;\n $info = $db->get_row(\"SELECT `email` FROM `user` WHERE `username` = '\" . $db->escape($username) . \"'\");\n if (is_object($info))\n return $info->email;\n else\n return '';\n }", "title": "" }, { "docid": "aaad8a52cfee4b2fa7922c67a939b4c2", "score": "0.6276114", "text": "public function getEmail()\n {\n $res = $this->conn->query(\"SELECT * FROM customer WHERE cust_id='\".$_SESSION['loggedIn_cust_id'].\"'\");\n $row = $res->fetch_assoc();\n return $row[\"email\"];\n }", "title": "" }, { "docid": "b34b290e20e1c6decfdd794e4f3d544b", "score": "0.625973", "text": "public function getEmail()\n {\n return $this->response['email'];\n }", "title": "" }, { "docid": "8f0a09c09fcc1868f398fc08ab1f520b", "score": "0.61865294", "text": "public function accept($token)\n {\n if (!$invite = Invite::where('token', $token)->first()) {\n //if the invite doesn't exist do something more graceful than this\n abort(404);\n }\n\n // delete the invite so it can't be used again\n $invite->delete();\n\n return view('auth.invited-user',['email'=>$invite->email]);\n }", "title": "" }, { "docid": "69015d22f12705d85c960687f704664c", "score": "0.618239", "text": "public function getEmail()\n {\n return $this->response['email'] ?: null;\n }", "title": "" }, { "docid": "48b99806d453858ed6eddc7b8cab3061", "score": "0.617753", "text": "public function getEmail()\n {\n return $this->get(self::EMAIL);\n }", "title": "" }, { "docid": "565a8266d966ec7a5967f100835a1446", "score": "0.6164499", "text": "public function getFromEmail(): string;", "title": "" }, { "docid": "3294938409fcbe97f5c4f0bf19786486", "score": "0.6160967", "text": "public function getEmailForVerification()\n {\n return $this->getEmail();\n }", "title": "" }, { "docid": "7e191d07a92535688190f76ec65ed1d5", "score": "0.61527485", "text": "public function getEmailForVerification()\n {\n return $this->email;\n }", "title": "" }, { "docid": "7e191d07a92535688190f76ec65ed1d5", "score": "0.61527485", "text": "public function getEmailForVerification()\n {\n return $this->email;\n }", "title": "" }, { "docid": "7e191d07a92535688190f76ec65ed1d5", "score": "0.61527485", "text": "public function getEmailForVerification()\n {\n return $this->email;\n }", "title": "" }, { "docid": "06db10f82dac943138825611289ba22c", "score": "0.6125371", "text": "public function getEmail()\n {\n $user = $this->getUser();\n return $user ? $user->email : null;\n }", "title": "" }, { "docid": "bfb946bb5bd78605f10d9b4046773bc7", "score": "0.610748", "text": "public function getUserEmail() : string {\n\t\treturn $this->userEmail;\n\t}", "title": "" }, { "docid": "915b9318ec73591d730213372dfa5ccb", "score": "0.60885096", "text": "protected function getEmailByToken($token)\n {\n return '';\n }", "title": "" }, { "docid": "392914c0600af786a418893973c741f7", "score": "0.60737836", "text": "public function verifyEmail(string $token): JsonResponse\n\t{\n\t\ttry {\n\t\t\t$token = EmailToken::createFromHash($token);\n\n\t\t\t// If the token is expired we just throw an exception to\n\t\t\t// trigger our generic fail message.\n\t\t\tif ($token->isExpired()) {\n\t\t\t\tthrow new \\Exception('Token expired.');\n\t\t\t}\n\n\t\t\t$user = User::where('email', '=', $token->email)->firstOrFail();\n\n\t\t\t// If the users email was already verified, we can skip this step.\n\t\t\tif (! $user->verified_at) {\n\t\t\t\t$user->verified_at = Carbon::now();\n\t\t\t\t$user->save();\n\t\t\t}\n\n\t\t\treturn new JsonResponse($this->success(), Respond::HTTP_OK);\n\n\t\t} catch (\\Exception $err) {\n\t\t\t// We will always return the same response when it fails. The reason\n\t\t\t// we throw the same response is because We don't want to expose any\n\t\t\t// information about our token.\n\t\t\tthrow new HttpException(\n\t\t\t\tRespond::HTTP_NOT_FOUND,\n\t\t\t\t'invalid_email_token',\n\t\t\t\t'The token was invalid or could not be found.',\n\t\t\t\t[],\n\t\t\t\t'Invalid Email Token',\n\t\t\t\t'Sorry, the token was invalid. It may have expired, try getting a new one.',\n\t\t\t\t[],\n\t\t\t\t$err\n\t\t\t);\n\t\t}\n\t}", "title": "" }, { "docid": "d5eff272c23b68d17fc730c5316b5205", "score": "0.607127", "text": "private function getUserEmail(): string\n {\n return $this->checkoutSession->getQuote()->getCustomerEmail()\n ?: $this->checkoutSession->getQuote()->getBillingAddress()->getEmail();\n }", "title": "" }, { "docid": "9c51187518bb8bea58106ff13358df37", "score": "0.60665035", "text": "function _ereolen_support_get_email() {\n if (user_is_logged_in()) {\n $profile = profile2_load_by_user($GLOBALS['user']->uid, 'provider_publizon');\n\n if ($profile) {\n $profile_wrapper = entity_metadata_wrapper('profile2', $profile);\n $email = $profile_wrapper->field_email->value();\n if (!empty($email)) {\n return $email;\n }\n }\n }\n return '';\n}", "title": "" }, { "docid": "335c68872b152978ae0505788b435306", "score": "0.6062963", "text": "function getEmail(){\n\tglobal $data;\n\treturn $data['Email'];\n}", "title": "" }, { "docid": "129d0a9009c93f131067c92b60fe85d7", "score": "0.6060763", "text": "public function requestUserByToken($token)\n {\n return $this->client->request(\n 'GET',\n 'wp-json/wp/v2/users/me?context=edit',\n [\n 'headers' => [\n 'Authorization' => 'Bearer ' . $token\n ]\n ]\n );\n }", "title": "" }, { "docid": "7d79907b364636131f25f43609e9c2b5", "score": "0.60457075", "text": "public function getEmail()\n {\n return $this->_data['email'];\n }", "title": "" }, { "docid": "00cf571ab2f80e28f93b9f8c2e5f7f4e", "score": "0.60438544", "text": "public function getReminderEmail()\n\t{\n\t\treturn $this->user_email;\n\t}", "title": "" }, { "docid": "844650131074ba66f1a43d861efad661", "score": "0.60424274", "text": "public function getEmailForVerification() {\n return $this->email;\n }", "title": "" }, { "docid": "9fc5c59916b62706fa84be7472f1a9b5", "score": "0.60410887", "text": "public function findOneByInvitationToken(string $token)\n {\n return $this->getModel()\n ->with('collaborators')\n ->whereHas('nonActiveMembers', function ($query) use ($token) {\n $expDate = Carbon::now()->subDays(env('INVITATION_EXPIRATION_DAYS'));\n\n $query->where('validation_token', $token);\n $query->whereDate('collaborators.created_at', '>=', $expDate);\n })->firstOrFail();\n }", "title": "" }, { "docid": "1196c371efce33b41cf373c00f842c87", "score": "0.6038377", "text": "public static function getEmail( ) {\n\t\n\t\t$objSession = self::getInstance();\n\t\t\n\t\tif(!is_object($objSessoin->objUser) || !$objSession->objUser->idLoaded){\n\t\t\t$arrUsers = User::find_by_username(self::getUsername());\n\t\t\t$objSession->objUser = new User($arrUsers[0]);\n\t\t} \n\t\t\n\t\treturn $objSession->objUser->getEmail();\n\t\n\t}", "title": "" }, { "docid": "2dbd57357d6ae8ded5b7bf2934701c33", "score": "0.6035942", "text": "function getEmail()\n\t\t{\n\t\t\t$result = $this->retrieveUserData(); \n\t\t\t\n\t\t\treturn array_key_exists(\"emailaddress\",$this->session_info)?$this->session_info[\"emailaddress\"]:false;\n\t\t}", "title": "" }, { "docid": "901e6ba9fe1ae1f98a925a45de8a86cc", "score": "0.60317653", "text": "protected function inviteUserGetRequest($token)\n {\n // verify the required parameter 'token' is set\n if ($token === null || (is_array($token) && count($token) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $token when calling inviteUserGet'\n );\n }\n\n $resourcePath = '/v1/user/invite/{token}';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n // path params\n if ($token !== null) {\n $resourcePath = str_replace(\n '{' . 'token' . '}',\n ObjectSerializer::toPathValue($token),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n []\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass && $headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\Query::build($formParams);\n }\n }\n\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\Query::build($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "6ca1dda559d8de6d7df674d8e3931a6b", "score": "0.60272545", "text": "function getEmail() {\n\t\treturn $this->getData('email');\n\t}", "title": "" }, { "docid": "7126bb78aaf4305cbf3328a9e44e3c6a", "score": "0.60228235", "text": "public function getEmailForPasswordReset();", "title": "" }, { "docid": "7126bb78aaf4305cbf3328a9e44e3c6a", "score": "0.60228235", "text": "public function getEmailForPasswordReset();", "title": "" }, { "docid": "9e0d06caaf5e968622f60e4d74976d50", "score": "0.6014037", "text": "public function getEmail(){\n $info = $this->getInfo();\n return trim($info[\"email\"]);\n }", "title": "" }, { "docid": "cdb9169703fcd71e5d0e3e59927ce37c", "score": "0.6010218", "text": "public function getRecipientEmail()\n {\n return $this->getEmailForPasswordReset();\n }", "title": "" }, { "docid": "cbd140de8a17b6ed7d494627699fec44", "score": "0.6000498", "text": "public static function getEmail(): string\n {\n return self::$user['email'] ?? '';\n }", "title": "" }, { "docid": "5c68236da72db22fe39114d67f09b44b", "score": "0.59998345", "text": "public function get_email()\n {\n return $this->email;\n }", "title": "" }, { "docid": "f73828ade445e17905920e06466af8b5", "score": "0.5998862", "text": "public function getEmail() {\n\t\treturn ($this->memberEmail);\n\t}", "title": "" }, { "docid": "7038d877034331a2e9a1a12b12f6df57", "score": "0.5995205", "text": "public static function findIdentityByEmailConfirmToken(string $token, int $status = self::STATUS_ACTIVE): ?UserEntity\n {\n return static::findOne(['email_confirm_token' => $token, 'status' => $status]);\n }", "title": "" }, { "docid": "7a9dd33d49d2d49ad80d041996e244bf", "score": "0.59915936", "text": "function get_email() {\n return $this->email;\n }", "title": "" }, { "docid": "682e9d2d9f61cdb5968bd97199f8f06b", "score": "0.59794843", "text": "public function getUser($token);", "title": "" }, { "docid": "4d23fb149af1c0630d93e64846bc9680", "score": "0.59740156", "text": "public function getEmail()\n {\n return $this->getParameter('email');\n }", "title": "" }, { "docid": "3b4286de89262f1cb15f32898e4ba9ab", "score": "0.59721166", "text": "public function getUserEmail(){\r\n\t\t//$this->initDb();\r\n\t\tif($this->store_id !=0){\r\n\t\t\t$this->user_email = getValue(\"SELECT email FROM tbl_user WHERE user_id=\".$this->getStoreOwnerID());\r\n\t\t}\r\n\t\treturn $this->user_email;\r\n\t}", "title": "" }, { "docid": "c4b23064cd9f84f7d68bfc7391a652a1", "score": "0.5964568", "text": "public function getEmail() {\n return $this->_get('email');\n }", "title": "" }, { "docid": "6e1e49c0049e7d11f8ea7ccd6953a826", "score": "0.5963383", "text": "public function confirmEmail($token)\n {\n User::whereToken($token)->firstOrFail()->confirmEmail();\n return Redirect::to('/');\n }", "title": "" }, { "docid": "fac23c0a27b535826a27e2dd5f25ccf7", "score": "0.5940357", "text": "public function findUserEmail( $email );", "title": "" }, { "docid": "4d0343eaa30eb3db161efcc64826d0b1", "score": "0.5937996", "text": "public static function getEmail(){\n\t\treturn (self::isLogged()?$_SESSION['user']:null);\n\t}", "title": "" }, { "docid": "899bb31ca5def12463713135f7de1ef2", "score": "0.5930645", "text": "public function getAdminEmail();", "title": "" }, { "docid": "6e1d6db8d75ac62252b48679739fdb8a", "score": "0.5925024", "text": "private function userEmailGet($id) {\r\n return eUserEmail::model()->findByAttributes(array('user_id' => $id, 'type' => 'primary'));\r\n }", "title": "" }, { "docid": "e3f60e336991e5006094d809f7186a45", "score": "0.5919654", "text": "public function getEmail()\r\n {\r\n return $this->email;\r\n }", "title": "" }, { "docid": "e3f60e336991e5006094d809f7186a45", "score": "0.5919654", "text": "public function getEmail()\r\n {\r\n return $this->email;\r\n }", "title": "" }, { "docid": "3942273e35fcec0126ab284cc19be259", "score": "0.59186345", "text": "public function getEmail()\n {\n return !empty($this->data['email']) ? $this->data['email'] : null;\n }", "title": "" }, { "docid": "12cd71b2d79013dcb351308be177c2eb", "score": "0.5914714", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "4d9658325c90c5b7e126fefcddfad04a", "score": "0.5909413", "text": "public function getEmail()\n {\n \treturn $this->email;\n }", "title": "" }, { "docid": "4988844cae28041f8df3c0d52e30b638", "score": "0.5903219", "text": "public function GetEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "4988844cae28041f8df3c0d52e30b638", "score": "0.5903219", "text": "public function GetEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "735ea1570a40038f8ff552fe6c86819c", "score": "0.5901624", "text": "public function getUserEmail($id) {\n $sql = \"select email from core_users where id=?\";\n $user = $this->runRequest($sql, array($id));\n $userf = $user->fetch();\n return $userf [0];\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" }, { "docid": "dd6c7a13d8063b4eb64b98e4ac912900", "score": "0.58963203", "text": "public function getEmail()\n {\n return $this->email;\n }", "title": "" } ]
082134e277eb41579fc8bc9bfd43d259
/ Abstracted to get the database fields and declare them
[ { "docid": "b9e5c05583d728f44273635ebd856434", "score": "0.6488629", "text": "function __construct() {\n\n global $database;\n\n /* Setup the query to get the field names */\n $sql = \"SELECT * FROM \" . static::$table_name . \" LIMIT 1\";\n /* Run the query */\n $result_set = $database->query($sql);\n /* Get amount of fields */\n $fields_num = $database->num_fields($result_set);\n\n /* Setup the array field names */\n for($i=0; $i<$fields_num; $i++) {\n $result = $database->fetch_fields($result_set,$i);\n static::$db_fields[$i] = $result->name;\n }\n\n /* Setup variables */\n foreach(static::$db_fields as $field)\n $this->$field = $field;\n\n }", "title": "" } ]
[ { "docid": "8e535c6d137647f008e28a96b74f5a46", "score": "0.74319947", "text": "protected function initFieldNames()\n {\n//This should be implemented in child classes to set the list of fields retrieved from the database\n }", "title": "" }, { "docid": "0bd9913ceafb7869674500e39c678c3c", "score": "0.72864926", "text": "abstract public function fields();", "title": "" }, { "docid": "5939ea5b6c063b95f2d87cf0213a0bfe", "score": "0.71502376", "text": "abstract protected function fields();", "title": "" }, { "docid": "5939ea5b6c063b95f2d87cf0213a0bfe", "score": "0.71502376", "text": "abstract protected function fields();", "title": "" }, { "docid": "f4022e4424db8922bfff3a2272661b05", "score": "0.712173", "text": "abstract function fields();", "title": "" }, { "docid": "b0ccf4d3886bf5901b700fe8c9ef83a0", "score": "0.708589", "text": "abstract protected function initFields();", "title": "" }, { "docid": "ca5b74610bb8ff33553360ad773e2c9e", "score": "0.6991723", "text": "public function setupFields() {\n $this->objectFields[\"id\"] = 0;\n $this->objectFields[\"name\"] = \"db object tester\";\n }", "title": "" }, { "docid": "3a7a8f51902949e6a5d6c259830c2b50", "score": "0.6976959", "text": "public function getDBFields() {\n\t\t\n\t\tif($this->fields == null) {\n\t\t\t$i = 0;\n\t\t\tforeach ($this->attributes as $column => $props) {\n\n\t\t\t\tif(is_array($props)){\n\t\t\t\t\tif(!empty($props['primary_key']) && $props['primary_key'] === true) $this->primary_key = $this->table.'.'.$column;\n\t\t\t\t\tif(!empty($props['column_name']) && $props['type'] != 'abstract') $column = $this->table.'.'.$props['column_name'].' '.$column;\n\t\t\t\t\telse if($props['type'] == 'abstract') $column = $props['column_name'].' as '.$column;\n\t\t\t\t}\n\t\t\t\telse $column = $this->table.'.'.$column;\n\t\t\t\t\n\t\t\t\t// add to fields object\n\t\t\t\tif($i == 0) $this->fields .= $column.' ';\n\t\t\t\telse $this->fields .= ', '.$column;\n\n\t\t\t\t$i++;\n\t\t\t}\n\t\t}\n\n\t\treturn $this->fields;\n\t}", "title": "" }, { "docid": "86314ae26e5bed79e15f8d37be55e1d2", "score": "0.6973116", "text": "public function defineFields()\n {\n }", "title": "" }, { "docid": "993d368d5380af7c65cb15f1dc379af1", "score": "0.69265413", "text": "abstract protected function getFields();", "title": "" }, { "docid": "50041b90593189a3ad234dc0d4f8f46d", "score": "0.6911246", "text": "public function setupFields();", "title": "" }, { "docid": "b853b2a1ddf2f54e10be95e0dd81d2d4", "score": "0.6841799", "text": "private function _setFieldNames() {\n $this->id = \"id\";\n $this->username = \"username\";\n $this->password = \"password\";\n $this->email = \"email\";\n $this->firstName = \"first_name\";\n $this->lastName = \"last_name\";\n $this->gender = \"gender\";\n $this->signupdate = \"signupdate\";\n $this->countryid = \"countryid\";\n $this->stateid = \"stateid\";\n $this->cityid = \"cityid\";\n $this->district = \"district\";\n $this->village = \"village\";\n $this->pincode = \"pincode\";\n $this->mobile = \"mobile\";\n $this->alternate_contact_number = \"alternate_contact_number\";\n $this->profile_picture = \"profile_picture\";\n $this->signature_picture = \"signature_picture\";\n $this->languageId = \"language_id\";\n $this->createdby = \"createdby\";\n $this->modifiedby = \"modifiedby\";\n $this->status = \"status\";\n $this->deleted = \"deleted\";\n \n }", "title": "" }, { "docid": "7853e91d9609d19fd726a10cf9442c9f", "score": "0.6830458", "text": "public function initialize_fields();", "title": "" }, { "docid": "e6dbaf872e3b493fb3294cf73161b8af", "score": "0.6773024", "text": "public function fetch_fields();", "title": "" }, { "docid": "5b902f191568690a100ca7fa998942fa", "score": "0.6723755", "text": "abstract protected static function getFields();", "title": "" }, { "docid": "8e520cc3c3278dc588941896e35543ad", "score": "0.6686854", "text": "protected function initTableFields()\r\n {\r\n }", "title": "" }, { "docid": "8e520cc3c3278dc588941896e35543ad", "score": "0.6686854", "text": "protected function initTableFields()\r\n {\r\n }", "title": "" }, { "docid": "45a065b1c5dc18b3f21715234aaab90c", "score": "0.6670406", "text": "private function getFieldDataFromTable()\n {\n $this->table_field_data = $this->db->createCommand('SHOW COLUMNS FROM '. $this->table_name)->queryAll();\n }", "title": "" }, { "docid": "9f1d9eb867055f494d7cba85a95d6343", "score": "0.66166687", "text": "private function toDB() {\n\t\t$reflect = new ReflectionObject($this);\n \tforeach ($reflect->getProperties(ReflectionProperty::IS_PUBLIC) as $prop) {\n \t\t$return[$prop->getName()] = $prop->getValue($this);\n \t}\n\t\treturn $return;\n\t}", "title": "" }, { "docid": "abfa68a853d69108ea8a3df5be5b5e43", "score": "0.66005665", "text": "protected function getDBProperties()\n\t{\n\t\t// parent id must not change\n\t\t$fields = array(\"title\" => array(\"text\", $this->getTitle()),\n\t\t\t\t\"description\" => array(\"text\", $this->getDescription()),\n\t\t\t \"pos\" => array(\"integer\", $this->getPosition()));\n\t\n\t\treturn $fields;\n\t}", "title": "" }, { "docid": "d0eff9e6d2e0ed113932be07246cb9a1", "score": "0.658993", "text": "public function getFields(){}", "title": "" }, { "docid": "e9787f9c9951157aaa2bffcd97b85a60", "score": "0.65779614", "text": "protected function properties(){\n //return get_object_vars($this);\n $properties = array();\n foreach(self::$db_table_fields as $db_field){\n if(property_exists($this, $db_field)){\n \n $properties[$db_field] = $this->$db_field;\n }\n }\n return $properties;\n\n }", "title": "" }, { "docid": "9d7215faba1006e89dd0c03ecd7a4648", "score": "0.6552154", "text": "private function _setFieldNames() {\n $this->id = \"id\";\n $this->userid = \"userid\";\n $this->role = \"role\";\n $this->status = \"status\";\n $this->deleted = \"deleted\";\n }", "title": "" }, { "docid": "f8bd18405c131667c48f3d1624997a76", "score": "0.65400684", "text": "public function map()\n {\n $rf = new \\ReflectionObject($this->valObj);\n foreach($rf->getProperties(\\ReflectionProperty::IS_PUBLIC) as $prop)\n {\n $this->dbFields[$prop->name] = $this->valObj->{$prop->name};\n }\n return $this->dbFields;\n }", "title": "" }, { "docid": "531c507501b8db22d31bf8f21cb9886f", "score": "0.652163", "text": "public function get_fields();", "title": "" }, { "docid": "d96973ff2a2f43544f2ec3662981d4fa", "score": "0.6464547", "text": "public function prepare(){\n\t\treturn array( 'fields'=>parent::prepare() );\n\t}", "title": "" }, { "docid": "b6dcf24d91642807570b774884d5527e", "score": "0.6464084", "text": "public function fetch_field(){}", "title": "" }, { "docid": "909903b860d19b439f777c583d1516a0", "score": "0.6462705", "text": "public function ADMeta_Get_Table_Fields(){\n\t\t\n\t $result_key = parent::Initial_Result('dbfield');\n\t $result = &$this->ModelResult[$result_key];\n\t try{ \n\t\t\n\t\t$fields_config = ['volume'=>[],'element'=>[]];\n\t\t\n\t\t// 取得資料表欄位資訊\n\t\t$DB_GET= $this->DBLink->prepare(SQL_AdMeta::GET_TABLE_FORMAT());\n\t\t\n\t\t// get source_digiarchive\n\t\t$DB_GET->bindValue(':dbtable' , 'source_digiarchive');\n\t\tif($DB_GET->execute()){\n\t\t while($field = $DB_GET->fetch(PDO::FETCH_ASSOC)){\n\t\t\t$fields_config['volume'][$field['dbcolumn']] = $field;\n\t\t }\n\t\t}\n\t\t\n\t\t// get source_digielement\n\t\t$DB_GET->bindValue(':dbtable' , 'source_digielement');\n\t\tif($DB_GET->execute()){\n\t\t while($field = $DB_GET->fetch(PDO::FETCH_ASSOC)){\n\t\t\t$fields_config['element'][$field['dbcolumn']] = $field;\n\t\t }\n\t\t}\n\t\t\n\t\t$result['data'] = $fields_config;\n\t\t$result['action'] = true;\n\t\t\n\t } catch (Exception $e) {\n $result['message'][] = $e->getMessage();\n }\n\t return $result; \n\t}", "title": "" }, { "docid": "0b5908eaa1a587b0b52afd82dc57cfac", "score": "0.6460455", "text": "protected function properties(){\n $properties = array();\n foreach (static::$db_table_fields as $db_field) {\n if(property_exists($this, $db_field)){\n $properties[$db_field]= $this->$db_field;\n }\n }\n return $properties;\n }", "title": "" }, { "docid": "716a7a35f9e5ee7b3df6ed3f83a226fd", "score": "0.64366007", "text": "public function attributes() {\n $attributes = array();\n foreach(self::$db_fields as $field){\n if(property_exists($this, $field)){\n $attributes[$field] = $this->$field;\n }\n }\n return $attributes;\n //return get_object_vars($this);\n}", "title": "" }, { "docid": "bdb919e2b8370480059b975067a2655c", "score": "0.6414761", "text": "public function buildFields()\n {\n $this->addField('id', 'Id', true);\n $this->addField('start', 'Start', true);\n $this->addField('end', 'End', true);\n }", "title": "" }, { "docid": "e529d9211cd6650803cbb7030ce1683b", "score": "0.6378552", "text": "public function loadFieldsFromModel(){\n\t\t$table = Doctrine::getTable($this->modelClass);\n\t\t$tableDefinition = $table->getColumns();\n\n\t\tif(count($this->usefulFields) > 0){\n\t\t\tforeach($tableDefinition as $key=>$attributes){\n\t\t\t\tif(array_key_exists($key, $this->usefulFields)){\n\t\t\t\t\t$rawFieldsDefinition[$key] = $attributes;\n\t\t\t\t}\n\t\t\t}\n\t\t}else{\n\t\t\t$rawFieldsDefinition = $tableDefinition;\n\t\t}\n\n\t\t/**\n\t\t * loading fields\n\t\t */\n\t\tforeach($rawFieldsDefinition as $key => $attributes){\n\t\t\t$options = null;\n\t\t\tif(isset($attributes['values'])){\n\t\t\t\t$options = array_combine($attributes['values'] , $attributes['values'] );\n\t\t\t}\n\n\t\t\tif($key != 'created_at' and $key != 'updated_at'){\n\t\t\t\t$newField = $this->addField(new FormField($key, $attributes['type'], $attributes, $options));\n\t\t\t\tif(isset($attributes['default'])){\n\t\t\t\t\t$newField->setValue($attributes['default']);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t}", "title": "" }, { "docid": "10567cd172f0bc62594f03447c4a11d9", "score": "0.63724834", "text": "public function set_fields($r){\n\t\t//Pero en PostgreSQL no tengo nada parecido: necesito consultarlo manualmente.\n\t\t//De modo que, como ya cargué las constraints en la clase ABM, tomo esa data de ahí.\n\t\t\n\t\tforeach ($this->datos[\"constraints\"] as $c){\n\t\t\tif (strpos(strtolower($c[\"CONSTRAINT_TYPE\"]),'primary') !== false){\n\t\t\t\t$tmp = (array_key_exists(strtolower($c[\"COLUMN_NAME\"]),$r)) ? strtolower($c[\"COLUMN_NAME\"]) : strtoupper($c[\"COLUMN_NAME\"]);\n\t\t\t\tif (isset($r[$tmp]) && $r[$tmp] instanceof Field) {\n\t\t\t\t\t$r[$tmp]->set_primary_key(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t//Establece, desde los datos de los campos, si algún field es nullable o no.\n\t\tforeach ($this->datos[\"campos\"] as $c){\n\t\t\t$tmp = (array_key_exists(strtolower($c[\"COLUMN_NAME\"]),$r)) ? strtolower($c[\"COLUMN_NAME\"]) : strtoupper($c[\"COLUMN_NAME\"]);\n\t\t\tif (strpos(strtolower($c[\"IS_NULLABLE\"]),'yes') !== false){\n\t\t\t\tif (isset($r[$tmp]) && $r[$tmp] instanceof Field) {\n\t\t\t\t\t$r[$tmp]->set_requerido(false);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif (isset($r[$tmp]) && $r[$tmp] instanceof Field) {\n\t\t\t\t\t$r[$tmp]->set_requerido(true);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\t$this->datos[\"fields\"] = $r;\n\t\t\n\t}", "title": "" }, { "docid": "177ccd7e041d0d15fc7b00ba57d6b868", "score": "0.63680243", "text": "private function _setFieldNames() {\n $this->id = \"id\"; \n $this->value = \"value\";\n $this->label = \"label\";\n $this->suffixLabel = \"suffix_label\"; \n $this->surveyQuestionOptionId = \"survey_question_option_id\";\n $this->languageId = \"language_id\";\n $this->status = \"status\";\n $this->deleted = \"deleted\"; \n }", "title": "" }, { "docid": "74d30ffd130b7c72efd42ec579638417", "score": "0.635737", "text": "protected function getFields() { \n\t\treturn array();\n\t}", "title": "" }, { "docid": "a9a8a3766f3deeba3c2f569f95682daf", "score": "0.63557285", "text": "protected function attributes()\n {\n \t$attributes = array();\n foreach (self::$db_fields as $field) {\n // echo property_exists($this, $field);\n if (property_exists($this, $field)) {\n // echo $field.\": \";\n // echo $this->$field.\" \";\n $attributes[$field] = $this->$field;\n }\n }\n // print_r($attributes);\n \treturn $attributes;\n }", "title": "" }, { "docid": "10513dadc5e2bcfb556415f3ef461182", "score": "0.63445497", "text": "protected function attributes(){\n\t\t\t//return get_object_vars($this);\n\t\t\t$attributes = array();\n\t\t\tforeach(self::$dbFields as $field){\n\t\t\t\tif(property_exists($this, $field)){\n\t\t\t\t\t$attributes[$field] = $this->$field;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn $attributes;\n\t\t}", "title": "" }, { "docid": "4bb590ffda1c4fc66b9a752bf5168421", "score": "0.6327499", "text": "protected function attributes() {\r\n\t $attributes = array();\r\n\t foreach(self::$db_fields as $field) {\r\n\t if(property_exists($this, $field)) {\r\n\t $attributes[$field] = $this->$field;\r\n\t }\r\n\t }\r\n\t return $attributes;\r\n\t}", "title": "" }, { "docid": "49ed4b730dab4cef683b9b4ba5af3317", "score": "0.6321586", "text": "protected function attributes(){\n\t\t// return an array of attribute names and their values\n\t $attributes = array();\n\t foreach(self::$db_fields as $field) {\n\t if(property_exists($this, $field)) {\n\t $attributes[$field] = $this->$field;\n\t }\n\t }\n\t return $attributes;\n\n\t\t//return get_object_vars($this);\n\t}", "title": "" }, { "docid": "f6af33eed34783a09f46a506e6d31bd6", "score": "0.63087386", "text": "public function registerFields(){\n\t\t$this->registerFieldInt('id_persona', 'Id Persona');\n\t\t$this->registerFieldInt('id_doc_tipo', 'Id Tipo Documento');\n\t\t$this->registerFieldString('nro_doc_persona', 'Núm Doc.');\n\t\t$this->registerFieldInt('id_sit', 'Id Ciudad', true, true);\n\t\t$this->registerFieldString('noms_apes', 'Nombres y Apellidos / Razón Social');\n\t\t$this->registerFieldStringNullable('dir_person', 'Dirección');\n\t\t$this->registerFieldStringNullable('tlf_persona', 'Teléfono');\n\t\t\n\t\t$this->registerFieldString('user_email', 'Correo Electrónico');\n\t\t$this->registerFieldStringNullable('user_pwd_current', 'Contraseña Actual');\n\t\t$this->registerFieldStringNullable('user_pwd1', 'Contraseña Nueva');\n\t\t$this->registerFieldStringNullable('user_pwd2', 'Repita su Nueva Contraseña');\n\t\t\n\t\t$this->registerFieldStringNullable('nombres_persona', 'Nombres');\n\t\t$this->registerFieldString('apellidos_persona', 'Nombres y Apellidos');\n\t\t$this->registerFieldString('email_person', 'Correo Electrónico');\n\t\t\n\t\tparent::registerFields();\n\t\t\n\t\t// $this->registerFieldInt('id_empresa', 'Id Empresa');\t\t\n\t}", "title": "" }, { "docid": "8056c439cf0d18ee82c35598e459736f", "score": "0.63071", "text": "protected function attributes() {\n\t $attributes = array();\n\t foreach(self::$db_fields as $field) {\n\t if(property_exists($this, $field)) {\n\t $attributes[$field] = $this->$field;\n\t }\n\t }\n\t return $attributes;\n\t}", "title": "" }, { "docid": "8056c439cf0d18ee82c35598e459736f", "score": "0.63071", "text": "protected function attributes() {\n\t $attributes = array();\n\t foreach(self::$db_fields as $field) {\n\t if(property_exists($this, $field)) {\n\t $attributes[$field] = $this->$field;\n\t }\n\t }\n\t return $attributes;\n\t}", "title": "" }, { "docid": "8056c439cf0d18ee82c35598e459736f", "score": "0.63071", "text": "protected function attributes() {\n\t $attributes = array();\n\t foreach(self::$db_fields as $field) {\n\t if(property_exists($this, $field)) {\n\t $attributes[$field] = $this->$field;\n\t }\n\t }\n\t return $attributes;\n\t}", "title": "" }, { "docid": "8056c439cf0d18ee82c35598e459736f", "score": "0.63071", "text": "protected function attributes() {\n\t $attributes = array();\n\t foreach(self::$db_fields as $field) {\n\t if(property_exists($this, $field)) {\n\t $attributes[$field] = $this->$field;\n\t }\n\t }\n\t return $attributes;\n\t}", "title": "" }, { "docid": "aa98f6d9c70d08ca60c2d1fb9c0d6991", "score": "0.63052297", "text": "function populate() {\n global $wpdb, $bp, $creds;\n \n if ( $row = $wpdb->get_row( $wpdb->prepare( \"SELECT * FROM {$bp->zoneideas->table_name} WHERE id = %d\", $this->id ) ) ) {\n $this->field_1 = $row->field_1;\n $this->field_2 = $row->field_2;\n $this->field_3 = $row->field_3;\n }\n }", "title": "" }, { "docid": "9ba0c7b6cfac0c5057262a72bdc5915c", "score": "0.6302408", "text": "public function getFields();", "title": "" }, { "docid": "9ba0c7b6cfac0c5057262a72bdc5915c", "score": "0.6302408", "text": "public function getFields();", "title": "" }, { "docid": "9ba0c7b6cfac0c5057262a72bdc5915c", "score": "0.6302408", "text": "public function getFields();", "title": "" }, { "docid": "9ba0c7b6cfac0c5057262a72bdc5915c", "score": "0.6302408", "text": "public function getFields();", "title": "" }, { "docid": "9ba0c7b6cfac0c5057262a72bdc5915c", "score": "0.6302408", "text": "public function getFields();", "title": "" }, { "docid": "9ba0c7b6cfac0c5057262a72bdc5915c", "score": "0.6302408", "text": "public function getFields();", "title": "" }, { "docid": "9ba0c7b6cfac0c5057262a72bdc5915c", "score": "0.6302408", "text": "public function getFields();", "title": "" }, { "docid": "9ba0c7b6cfac0c5057262a72bdc5915c", "score": "0.6302408", "text": "public function getFields();", "title": "" }, { "docid": "a249e29e0a5cff414c8d433b62895290", "score": "0.62982213", "text": "public function fetchFieldsSchema(){\n\t\t\treturn Symphony::Database()->fetch(\"SELECT `id`, `element_name`, `type`, `location` FROM `tbl_fields` WHERE `parent_section` = '\".$this->get('id').\"' ORDER BY `sortorder` ASC\");\n\t\t}", "title": "" }, { "docid": "90e1abc7d02fa07d35dfb8bfa8ec7215", "score": "0.62747353", "text": "public function buildFields()\n {\n $this->addField('username', 'Username', true);\n $this->addField('email', 'E-Mail', true);\n $this->addField('enabled', 'Enabled', true);\n $this->addField('lastLogin', 'Last Login', false);\n $this->addField('groups', 'Groups', false);\n }", "title": "" }, { "docid": "58fe6bd94d21127a12c6c319fee00c57", "score": "0.62688714", "text": "protected function properties(){\n $properties = array();\n foreach (static::$dbTableFields as $dbField){\n if(property_exists($this,$dbField)){\n $properties[$dbField] = $this->$dbField;\n }\n }\n\n return $properties;\n }", "title": "" }, { "docid": "6d90c14f4acf15dd111b955f9a36917d", "score": "0.6264764", "text": "protected function attributes() {\n $attributes = array();\n \n foreach (static::$db_fields as $field) {\n \n if (property_exists($this, $field)) {\n $attributes[$field] = $this->$field;\n }\n }\n return $attributes;\n }", "title": "" }, { "docid": "44d448c7f703768aa1a8808fdc608e87", "score": "0.62583023", "text": "protected function defineAttributes()\n {\n $this->dbAttributes = (object) [\n 'safe' => [\n 'documento_iddocumento',\n 'fecha',\n 'funcionario_idfuncionario',\n 'version',\n 'pdf'\n ],\n 'date' => ['fecha']\n ];\n }", "title": "" }, { "docid": "bc75014f6ff2a71f3cb1620622f9b9e4", "score": "0.62537926", "text": "public static function fields()\n {\n return array(\n 'id' => 'integer',\n 'user' => 'entity',\n 'description' => 'text',\n 'name' => 'text',\n 'tag' => 'id',\n 'image' => 'text',\n 'genre' => 'text',\n );\n }", "title": "" }, { "docid": "e8baddcfb8efbf704631f2cffc125f9b", "score": "0.6252569", "text": "protected function defineAttributes()\n {\n $this->dbAttributes = (object) [\n 'safe' => [\n 'fk_tarea',\n 'fk_documento',\n 'fk_funcionario',\n 'fecha',\n 'estado'\n ],\n 'date' => ['fecha']\n ];\n }", "title": "" }, { "docid": "e5baf3743193d0897542e7263ae4dfa6", "score": "0.62402785", "text": "function setDBFields($fields){\n\t\t$this->dbfields = $fields;\n\t}", "title": "" }, { "docid": "7ec87a0d5441126ba21a6bf314636e17", "score": "0.6238839", "text": "protected function properties(){\n\t\t//return get_object_vars($this);\n\t\t$properties = array();\n\n\t\tforeach(static::$db_table_fields as $db_field){\n\t\t\tif(property_exists($this, $db_field)){\n\t\t\t\t$properties[$db_field] = $this->$db_field;\n\t\t\t}\n\t\t}\n\n\t\treturn $properties;\n\t}", "title": "" }, { "docid": "c8957b2fafe13a8463b58c16cf56a3a1", "score": "0.6223364", "text": "protected function defineAttributes()\n {\n $this->dbAttributes = (object) [\n 'safe' => [\n 'origen',\n 'destino',\n 'fecha',\n 'descripcion',\n 'leido',\n 'notificado',\n 'tipo',\n 'tipo_id',\n ],\n 'date' => ['fecha']\n ];\n }", "title": "" }, { "docid": "dc768cc132f820dda141f2c762e4b79d", "score": "0.6214542", "text": "function filefield_field_settings_database_columns($field) {\r\n return array(\r\n 'fid' => array('type' => 'int', 'not null' => FALSE, 'views' => TRUE),\r\n 'list' => array('type' => 'int', 'size' => 'tiny', 'not null' => FALSE, 'views' => TRUE),\r\n 'data' => array('type' => 'text', 'serialize' => TRUE, 'views' => TRUE),\r\n );\r\n}", "title": "" }, { "docid": "e17ef481bf7b9e84b6bcae099682f058", "score": "0.62074983", "text": "abstract protected function fields(): array;", "title": "" }, { "docid": "307a109a01af2199a0f32195e765ac18", "score": "0.62053275", "text": "protected function defineAttributes()\n {\n $this->dbAttributes = (object) [\n 'safe' => [\n 'documento_iddocumento',\n 'fecha',\n 'accion',\n 'funcionario',\n 'justificacion'\n ],\n 'date' => ['fecha']\n ];\n }", "title": "" }, { "docid": "d25c0ba4299dd14649c6a9e7be9e2a52", "score": "0.6199502", "text": "protected function attributes() {\n\t\t$attributes = array();\n\t\tforeach(self::$db_fields as $field) {\n\t\t\tif(property_exists($this, $field)){\n\t\t\t\t$attributes[$field] = $this->$field;\n\t\t\t}\n\t\t}\n\t\treturn $attributes;\n\t}", "title": "" }, { "docid": "ef52287062fda474026e6424e271fdb0", "score": "0.6194604", "text": "static function init()\n {\n $class_name = self::class_name();\n $table_name = self::table_name();\n // Naming convention to many items\n if (!array_key_exists($class_name, self::$columns))\n {\n self::$columns[$class_name] = DB::show_columns($table_name);\n }\n }", "title": "" }, { "docid": "124f723937310db7c0a346243763d704", "score": "0.6185099", "text": "protected function defineAttributes()\n {\n $this->dbAttributes = (object) [\n 'safe' => [\n 'fk_funcionario',\n 'fk_tarea',\n 'prioridad',\n 'estado',\n 'fecha'\n ],\n 'date' => ['fecha']\n ];\n }", "title": "" }, { "docid": "fd365c7462255e1af49b007eec0c519b", "score": "0.61818755", "text": "protected function initResultFields()\r\n {\r\n }", "title": "" }, { "docid": "fd86aee6ac225b630c6bcc4308be3e54", "score": "0.61768323", "text": "public function attributes(){ \n\t\t$attributes = array(); \n\t\tforeach (static::$table_fields as $field) {\n\t\t\tif($this->$field != '')\n\t\t\t\t$attributes[$field] = $this->$field;\n\t\t}\n\t\treturn $attributes;\n\t}", "title": "" }, { "docid": "b7ea5b48a4adddf105f995b043b88e0d", "score": "0.61640066", "text": "public function __construct()\n {\n $this->columnData = array( \n 'id' => array( \n 'name' => 'id',\n 'attributes' => array( \n 'isa' => 'int',\n 'type' => 'int',\n 'primary' => true,\n 'autoIncrement' => true,\n ),\n ),\n 'name' => array( \n 'name' => 'name',\n 'attributes' => array( \n 'isa' => 'str',\n 'type' => 'varchar',\n 'primary' => NULL,\n 'length' => 128,\n ),\n ),\n 'value' => array( \n 'name' => 'value',\n 'attributes' => array( \n 'isa' => 'str',\n 'type' => 'varchar',\n 'primary' => NULL,\n 'length' => 256,\n ),\n ),\n);\n $this->columnNames = array( \n 'id',\n 'name',\n 'value',\n);\n $this->primaryKey = 'id';\n $this->table = '__meta__';\n $this->modelClass = 'LazyRecord\\\\Model\\\\Metadata';\n $this->collectionClass = 'LazyRecord\\\\Model\\\\MetadataCollection';\n $this->label = 'Metadata';\n $this->relations = array( \n);\n $this->readSourceId = 'default';\n $this->writeSourceId = 'default';\n parent::__construct();\n }", "title": "" }, { "docid": "539639135a8c9c52159e1f9ab2f15e94", "score": "0.6162484", "text": "abstract public function fields(): array;", "title": "" }, { "docid": "8fb1b7cc04c59b0f51bd7e40d7e22b03", "score": "0.616123", "text": "public function fields(){\n\t\treturn array();\n\t}", "title": "" }, { "docid": "af81a1aa036aa721b9f94bbee1aa5d84", "score": "0.6155608", "text": "protected function attributes() {\n\t\t$attributes = array();\n\t\tforeach(self::$db_fields as $field) {\n\t\t\tif(property_exists($this, $field)) {\n\t\t\t\t$attributes[$field] = $this->$field;\n\t\t\t}\n\t\t}\n\t\treturn $attributes;\n\t}", "title": "" }, { "docid": "023d5c9662693a428be45353bbc9abb9", "score": "0.6152984", "text": "public function fieldsTable(){\r\n return array(\r\n 'id' => 'Id',\r\n 'username' => 'User_name',\r\n 'email' => 'Email',\r\n 'first_name'=>'First_name',\r\n 'last_name'=>'Last_name',\r\n 'birthday'=>'Birthday',\r\n 'urlphoto'=>'Urlphoto',\r\n 'password_hash'=>'Password_hash',\r\n 'secret_key'=>'Secret_key',\r\n 'created_at'=>'Updated_at',\r\n 'flags'=>'Flags'\r\n );\r\n }", "title": "" }, { "docid": "82a40f0f93f96bee897b754cd57b1fb5", "score": "0.61473984", "text": "private static function getFieldMap()\n {\n return array(\n 'user_id' => 'UserID',\n 'contact_id' => 'ContactID',\n 'first_name' => 'FirstName',\n 'last_name' => 'LastName',\n 'location_id' => 'LocationID',\n 'commitment' => 'Commitment',\n 'is_new' => 'IsNew',\n 'source' => 'Source',\n 'interest' => 'Interest',\n 'engage' => 'Engage',\n 'current_status_id' => 'CurrentStatusID',\n 'source_id' => 'ExternalSourceIdentifier',\n 'notes' => 'Notes',\n 'has_photo' => 'Photo',\n );\n }", "title": "" }, { "docid": "78e78abd9cc161e2feb0c5cb58b167bf", "score": "0.6135264", "text": "public function getFields()\n {\n }", "title": "" }, { "docid": "e756aba9b45f7926ad0b04c47530a876", "score": "0.61263263", "text": "public function prepareFieldsFromTable()\n {\n foreach ($this->columns as $column) {\n $type = $column->getType()->getName();\n\n /** @var array $fieldTypeMaps 'column type' => ['db type', 'html type'] */\n $fieldTypeMaps = [\n 'integer' => ['integer'],\n 'smallint' => ['smallInteger'],\n 'bigint' => ['bigInteger'],\n 'boolean' => ['boolean', 'checkbox,1'],\n 'datetime' => ['datetime', 'date'],\n 'datetimetz' => ['dateTimeTz', 'date'],\n 'date' => ['date', 'date'],\n 'time' => ['time', 'text'],\n 'decimal' => ['decimal'],\n 'float' => ['float'],\n 'text' => ['text', 'textarea'],\n 'string' => ['string', 'text']\n ];\n\n $type = isset($fieldTypeMaps[$type]) ? $type : 'string';\n\n $field = null;\n if (in_array($type, ['integer', 'smallint', 'bigint'])) {\n $field = $this->generateIntFieldInput($column, $fieldTypeMaps[$type][0]);\n }\n\n if (in_array($type, ['decimal', 'float'])) {\n $field = $this->generateNumberInput($column, $fieldTypeMaps[$type][0]);\n }\n\n if (empty($field)) {\n $field = $this->generateField($column, $fieldTypeMaps[$type][0], $fieldTypeMaps[$type][1]);\n }\n\n $this->fields[] = $this->prepareAdditionalFieldPropertiesFromTable($field, $column);\n }\n\n return $this;\n }", "title": "" }, { "docid": "160cb9c5ea2f88ae7d4dbddca22c0851", "score": "0.6109325", "text": "public function buildFields()\n {\n $this->addField('name', 'kuma_tagging.adminlist.header.name', true);\n $this->addField('createdAt', 'kuma_tagging.adminlist.header.created_at', true);\n $this->addField('updatedAt', 'kuma_tagging.adminlist.header.updated_at', true);\n }", "title": "" }, { "docid": "89bc8e9efb3921c977de2316d210e55d", "score": "0.61082304", "text": "public function getFieldDefinitions_database()\n {\n $total = [];\n $tempKeys = [];\n $tempKeysPrefix = [];\n $connection = GeneralUtility::makeInstance(ConnectionPool::class)->getConnectionByName('Default');\n $statement = $connection->query('SHOW TABLE STATUS FROM `' . $connection->getDatabase() . '`');\n $tables = [];\n while ($theTable = $statement->fetch()) {\n $tables[$theTable['Name']] = $theTable;\n }\n foreach ($tables as $tableName => $tableStatus) {\n // Fields\n $statement = $connection->query('SHOW FULL COLUMNS FROM `' . $tableName . '`');\n $fieldInformation = [];\n while ($fieldRow = $statement->fetch()) {\n $fieldInformation[$fieldRow['Field']] = $fieldRow;\n }\n foreach ($fieldInformation as $fN => $fieldRow) {\n $total[$tableName]['fields'][$fN] = $this->assembleFieldDefinition($fieldRow);\n }\n // Keys\n $statement = $connection->query('SHOW KEYS FROM `' . $tableName . '`');\n $keyInformation = [];\n while ($keyRow = $statement->fetch()) {\n $keyInformation[] = $keyRow;\n }\n foreach ($keyInformation as $keyRow) {\n $keyName = $keyRow['Key_name'];\n $colName = $keyRow['Column_name'];\n if ($keyRow['Sub_part'] && $keyRow['Index_type'] !== 'SPATIAL') {\n $colName .= '(' . $keyRow['Sub_part'] . ')';\n }\n $tempKeys[$tableName][$keyName][$keyRow['Seq_in_index']] = $colName;\n if ($keyName === 'PRIMARY') {\n $prefix = 'PRIMARY KEY';\n } else {\n if ($keyRow['Index_type'] === 'FULLTEXT') {\n $prefix = 'FULLTEXT';\n } elseif ($keyRow['Index_type'] === 'SPATIAL') {\n $prefix = 'SPATIAL';\n } elseif ($keyRow['Non_unique']) {\n $prefix = 'KEY';\n } else {\n $prefix = 'UNIQUE';\n }\n $prefix .= ' ' . $keyName;\n }\n $tempKeysPrefix[$tableName][$keyName] = $prefix;\n }\n // Table status (storage engine, collaction, etc.)\n if (is_array($tableStatus)) {\n $tableExtraFields = [\n 'Engine' => 'ENGINE',\n 'Collation' => 'COLLATE'\n ];\n foreach ($tableExtraFields as $mysqlKey => $internalKey) {\n if (isset($tableStatus[$mysqlKey])) {\n $total[$tableName]['extra'][$internalKey] = $tableStatus[$mysqlKey];\n }\n }\n }\n }\n // Compile key information:\n if (!empty($tempKeys)) {\n foreach ($tempKeys as $table => $keyInf) {\n foreach ($keyInf as $kName => $index) {\n ksort($index);\n $total[$table]['keys'][$kName] = $tempKeysPrefix[$table][$kName] . ' (' . implode(',', $index) . ')';\n }\n }\n }\n return $total;\n }", "title": "" }, { "docid": "f39a6a87ca093ef2a11f0ffb8593fcd2", "score": "0.6107727", "text": "protected function buildMetadataFields()\n {\n //====================================================================//\n // Active => Product Is available_for_order\n $this->fieldsFactory()->create(SPL_T_BOOL)\n ->identifier(\"status\")\n ->name(\"Enable Product\")\n ->microData(\"http://schema.org/Product\", \"offered\")\n ;\n //====================================================================//\n // Type\n $this->fieldsFactory()->create(SPL_T_VARCHAR)\n ->identifier(\"type_id\")\n ->name(\"Type\")\n ->description('Internal Type')\n ->group(\"Meta\")\n ->microData(\"http://schema.org/Product\", \"type\")\n ->isReadOnly()\n ;\n }", "title": "" }, { "docid": "62cc78c6a53109f8aaebd178e26e23e5", "score": "0.6106192", "text": "public function getAllFields();", "title": "" }, { "docid": "62cc78c6a53109f8aaebd178e26e23e5", "score": "0.6106192", "text": "public function getAllFields();", "title": "" }, { "docid": "67302e3c47fd21b654641cc892619699", "score": "0.61015034", "text": "abstract public function getTestableFields();", "title": "" }, { "docid": "d453edad8cdb126f995b75c205aff476", "score": "0.61004823", "text": "public function _setFieldsClass()\n {\n if (!isset($this->table))\n return true;\n\n $myfields = array();\n $this->_gettableFields();\n foreach ($this->table_fields_properties as $val) {\n if (!$this->tractable || count($this->tractable) == 0 || ($this->tractable && in_array($val->name,$this->tractable)))\n $default = is_null($val->default)?false:true;\n switch ($val->type) {\n case \"int\":\n case \"smallint\":\n case \"bit\":\n case \"tinyint\":\n case \"mediumint\":\n case \"bigint\":\n $myfields[$val->name] = $default?$val->default:0;\n break;\n case \"decimal\":\n case \"float\":\n case \"double\":\n $myfields[$val->name] = $default?$val->default:(float) 0;\n break;\n case \"char\":\n case \"varchar\":\n case \"tinytext\":\n case \"text\":\n case \"mediumtext\":\n case \"longtext\":\n case \"json\":\n case \"date\":\n case \"time\":\n case \"year\":\n case \"timestamp\":\n case \"datetime\":\n case \"enum\":\n case \"set\":\n $myfields[$val->name] = $default?$val->default:(string) \"a\";\n break;\n default:\n $myfields[$val->name] = $default?$val->default:null;\n break;\n }\n }\n $this->fields = (object) $myfields;\n }", "title": "" }, { "docid": "e7d404bf25435182e881553a052d7877", "score": "0.6097194", "text": "private function getDBType() {return self::$dbtype;}", "title": "" }, { "docid": "081640f5031bf781072e3e755b54b145", "score": "0.60950226", "text": "public function attributes()\n {\n $attributes = array();\n foreach(self::$db_fields as $field)\n {\n if(property_exists($this,$field))\n {\n $attributes[$field] = $this->$field;\n }\n }\n return $attributes;\n }", "title": "" }, { "docid": "6a3223dc19eac1a10437217382083310", "score": "0.60805243", "text": "public function prepareVars()\n {\n $this->vars['name'] = $this->formField->getName();\n $this->vars['value'] = $this->getLoadValue();\n $this->vars['model'] = $this->model;\n //\n $this->vars['attributes'] = $this->getAllAttributes($this->className);\n }", "title": "" }, { "docid": "dfcb0f73c45fbd138107b0f818196434", "score": "0.6076489", "text": "function init_variables() {\n\t\t/* STOP*/\n\t\t$this->primary_field = 'id';\n\t\t$this->table = 'quotes';\n\n\t\t$this->specs =array(\n\t\t\tarray('field' => 'id',\n\t\t\t\t\t\t'type' => 'fixed',\n\t\t\t\t\t\t'title' => 'ID',\n\t\t\t\t\t\t'is_primary'=>true ),\n\n array('field' => 'quote',\n 'type'=>'textarea',\n 'title'=>'Quote',\n 'rows'=>20,\n ),\n\n array('field' => 'source',\n 'type'=>'text',\n 'title'=>'From',\n ),\n\n array('field' => 'author',\n 'type'=>'text',\n 'title'=>'By',\n ),\n\n\t\t\tarray('field' => '',\n \t\t\t\t\t\t'title' => 'Keywords',\n\t\t\t 'type' => 'subform',\n\t\t\t\t\t\t'subform' => new form_subform_keywords($this) ),\n\n\n\t\t\tarray('field' => 'provisional',\n\t\t\t\t\t\t'type'=>'checkbox',\n\t\t\t\t\t\t'title'=>'Provisional Entry',\n\t\t\t\t\t\t'comments'=>'Uncheck to approve user submitted links and add to public listing', 'admin_only' => true),\n\n\t\t\tarray('field' => 'deleted',\n\t\t\t\t\t\t'type'=>'checkbox',\n\t\t\t\t\t\t'title'=>'Deleted Entry',\n\t\t\t\t\t\t'comments'=>'Check to remove from the public listing',\n\t\t\t\t\t\t'admin_only' => true),\n\n\t\t\tarray('field' => 'created',\n\t\t\t\t\t\t'type'=>'created',\n\t\t\t\t\t\t'title'=>'Entry Created',\n\t\t\t\t\t\t'table'=>'links',\n\t\t\t\t\t\t'admin_only' => true ),\n\n\t\t\tarray('field' => 'modified',\n\t\t\t\t\t\t'type'=>'modified',\n\t\t\t\t\t\t'title'=>'Entry Modified',\n\t\t\t\t\t\t'table'=>'links',\n\t\t\t\t\t\t'admin_only' => true ),\n\n array('field' => 'contact',\n\t\t\t\t\t\t'type'=>'text',\n\t\t\t\t\t\t'title'=>'Contact Email',\n\t\t\t\t\t\t'after_buttons'=>true,\n\t\t\t\t\t\t'validate_as'=>'email'),\n\n\t\t\tarray('field' => 'notes',\n\t\t\t\t\t\t'type'=>'textarea',\n\t\t\t\t\t\t'title'=>'Webmaster\\'s Notes',\n\t\t\t\t\t\t'comments'=>'Note: These notes will not be displayed in the listing',\n\t\t\t\t\t\t'after_buttons'=>true),\n\t\t);\n\n\t\tparent::init_variables();\n\t}", "title": "" }, { "docid": "8d2eb8881aaab000d51c7bb70860ccfe", "score": "0.60704035", "text": "abstract public function setFieldsetsAndFields();", "title": "" }, { "docid": "5bd39768071aa72e41bb1aa54b32144f", "score": "0.6067031", "text": "protected function attributes() {\n\t \t// return get_object_vars($this); // ** returns all attribs\n\t \t// \t\t--private and protected and ones that don't have corresponding db fields\n\t \t$attributes = array();\n\t \tforeach(static::$db_fields as $field){\n\t \t\tif(property_exists($this, $field)) {\n\t \t\t\t$attributes[$field] = $this->$field;\n\t \t\t}\n\t \t}\n\t \treturn $attributes;\n\t }", "title": "" }, { "docid": "8d85896dbbe66c3895fc1509eff6d5f5", "score": "0.60670054", "text": "public function getFields()\n {\n $this->validateFields();\n $fields = $this->formatFields();\n\n // Ensure that we get something to insert\n if (!$fields && isset($this->id)) {\n $fields[$this->def['primary']] = $this->id;\n }\n\n return $fields;\n }", "title": "" }, { "docid": "c06579df4ba494d6fedb50f7b6a50736", "score": "0.6065172", "text": "private function get_table_info(){\n\t\t//TODO: this makes no sense...\n\t\t//if(!$this->is_ready_test()) { return; }\n\t\t//if already cached load from cache else load with a describe AND cache\n\t\t$cache_name = $this->table.\".table\";\n\t\tif(ECacheVar::exists($cache_name)){\n\t\t\t$cache = new ECacheVar($cache_name);\n\t\t\t$data = $cache->get_array_assoc(); \n\t\t\tforeach($cache as $key => $value){\n\t\t\t\t$fields[] = array(\"field\" => $key,\"type\" => $value);\n\t\t\t}\n\t\t\t\n\t\t} else {\n\t\t\t$cache = new ECacheVar($cache_name);\n\t\t\t\n\t\t\t$describe = EDatabase::q(\"DESCRIBE \".$this->table);\n\t\t\t\n\t\t\twhile($row=$describe->fetch_array()){\n\t\t\t\t$type = \"null\";\n\t\t\t\tif(stristr($row['Type'], \"varchar\")){ $type = \"varchar\"; }\n\t\t\t\tif(stristr($row['Type'], \"int\")){ $type = \"int\"; }\n\t\t\t\tif(stristr($row['Type'], \"text\")){ $type = \"text\"; }\n\t\t\t\t\n\t\t\t\t$this->fields[] = array(\"field\" => $row['Field'],\"type\" => $type);\n\t\t\t\t\n\t\t\t\t$cache->set($row['Field'],$type);\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "3dd79f257c33c6c214e04f78f604f003", "score": "0.60640264", "text": "function _field_info($result) {\n switch($this->_type) {\n case $this->DB_MYSQL:\n $info = array('name' => array(), 'type' => array());\n $cols = $this->_num_cols($result);\n\n for ($i = 0; $i < $cols; ++$i) {\n $field = mysql_fetch_field($result);\n $info['name'][$i] = $field->name;\n $info['type'][$i] = $field->type;\n }\n\n return $info;\n break;\n\n default:\n return NULL;\n break;\n }\n }", "title": "" }, { "docid": "44da555eb64c630640f7172eb8325daa", "score": "0.6059933", "text": "public function buildFields()\n {\n $fields = $this->_select->getPart(Zend_Db_Select::COLUMNS);\n $tables = $this->_select->getPart(Zend_Db_Select::FROM);\n\n $returnFields = array();\n\n foreach ($fields as $field => $value) {\n /**\n * Select all fields from the table\n */\n if ((string) $value[1] == '*') {\n if (array_key_exists($value[0], $tables)) {\n $tableFields = $this->getDescribeTable($tables[$value[0]]['tableName']);\n }\n $tableFields = array_keys($tableFields);\n\n foreach ($tableFields as $field) {\n $title = ucwords(str_replace('_', ' ', $field));\n $returnFields[$field] = array('title' => $title,\n 'field' => $value[0] . '.' . $field,\n 'alias' => $value[2] );\n }\n } else {\n if (is_object($value[1])) {\n $title = ucwords(str_replace('_', ' ', $value[2]));\n $returnFields[$value[2]] = array('title' => $title,\n 'field' => $value[1]->__toString(),\n 'alias'=>$value[2]);\n } elseif (strlen($value[2]) > 0) {\n $title = ucwords(str_replace('_', ' ', $value[2]));\n $returnFields[$value[2]] = array('title' => $title,\n 'field' => $value[0] . '.' . $value[1],\n 'alias'=>$value[2]);\n } else {\n $title = ucwords(str_replace('_', ' ', $value[1]));\n $returnFields[$value[1]] = array('title' => $title,\n 'field' => $value[0] . '.' . $value[1],\n 'alias'=>$value[2]);\n }\n }\n }\n\n $this->_fields = $returnFields;\n\n return $returnFields;\n }", "title": "" }, { "docid": "ea8875664b3effbfc4065d1addafcf3f", "score": "0.60594225", "text": "protected function getEntityUserFieldsInfo()\n\t{\n\t\treturn \\CCrmDeal::GetUserFields();\n\t}", "title": "" }, { "docid": "a9a2b56bd5d8316f80eeaab52a7b1e1a", "score": "0.60592943", "text": "abstract protected function getFieldsToUpdate();", "title": "" }, { "docid": "bc49d6f53bab7edc67526f98dae43f07", "score": "0.6057074", "text": "public function getMltFields(){}", "title": "" }, { "docid": "411c378650bd2b31599545dace1d4577", "score": "0.6050436", "text": "protected function getEntityFieldsInfo()\n\t{\n\t\treturn \\CCrmDeal::GetFieldsInfo();\n\t}", "title": "" } ]
d53d60a09b0ae462d9b0a07ce7d5a9c4
get cached value according given key.
[ { "docid": "45ea68e89158fd4d599bfe18d342d5d5", "score": "0.7013244", "text": "abstract public function getValue(string $key);", "title": "" } ]
[ { "docid": "9c4c48d5c37b54672e64ddd37d3afbb8", "score": "0.8126723", "text": "function get($cacheId, $key);", "title": "" }, { "docid": "c3ac302fe0fc07873cd1a75f92c3ae14", "score": "0.7954019", "text": "function cache_get($key) {\n\tglobal $Memoization;\n\treturn $Memoization->get($key);\n}", "title": "" }, { "docid": "472f567a4390eecafd3c52a362f9a40b", "score": "0.79464984", "text": "public function _get( $key ) {\r\n if( isset($this->_cache[$key] ) ) {\r\n return $this->_cache[$key];\r\n }\r\n }", "title": "" }, { "docid": "cfc7b3a1d23ea3aad0a2ea4106d9fe5b", "score": "0.7889382", "text": "public function get($key) {\n\t\treturn zend_shm_cache_fetch($key);\n\t}", "title": "" }, { "docid": "20edc90b46de363b266e7a2f435ac00f", "score": "0.77956104", "text": "public function get($key)\n {\n return $this->cache->get($key);\n }", "title": "" }, { "docid": "7714e3bae80d0978f8c66cd7d71db363", "score": "0.7716249", "text": "public function get($key) {\r\n if(isset($this->cache[$key])) {\r\n return $this->cache[$key];\r\n } else {\r\n return null;\r\n }\r\n }", "title": "" }, { "docid": "2dcb075e9f06f30eb0a8c90714c98bd4", "score": "0.7707688", "text": "public function get($key)\n{\n return $this->cacheable->get($key);\n}", "title": "" }, { "docid": "e99e207ae3a5b5b79a1e6e52c47de981", "score": "0.769287", "text": "public function _get($key)\n {\n return $this->redisCache->get($key);\n }", "title": "" }, { "docid": "984a2a1d8ec6fcb00ebaf556487b1157", "score": "0.76677984", "text": "public function get(string $key)\n {\n return $this->cache()->get($key);\n }", "title": "" }, { "docid": "b7c5d5589d01bf15b0a092918be95733", "score": "0.766713", "text": "abstract protected function fetchItemFromCache($key);", "title": "" }, { "docid": "b09f6372605c88091633d1a193282ebc", "score": "0.7656278", "text": "protected function _getCacheEntry($key)\n {\n return $this->_cache->fetch($key);\n }", "title": "" }, { "docid": "e323bad130da57d5650e8161b51f6ce1", "score": "0.7640214", "text": "protected function get(string $key)\n {\n return Cache::get($key);\n }", "title": "" }, { "docid": "697e8ce8606031d9cb157c939d963fab", "score": "0.75995755", "text": "public static function get($key)\n {\n // assume null\n $value = false;\n\n // convert key\n $key = self::init()->getKey($key);\n\n // get the ttl\n $ttl = 0;\n if (self::$_cache->_memcache) {\n $ttl = self::$_cache->_memcache->get($key . '.ttl');\n }\n else if (file_exists($key . '.ttl')) {\n $ttl = file_get_contents($key . '.ttl');\n }\n\n // it lives!\n if ($ttl >= time()) {\n // memcache\n if (self::$_cache->_memcache) {\n $value = self::$_cache->_memcache->get($key . '.data');\n }\n // filecache\n else if (file_exists($key . '.data')) {\n $value = unserialize(file_get_contents($key . '.data'));\n }\n }\n\n // return cached value\n return $value;\n }", "title": "" }, { "docid": "10fc846709960b12a497e9994102391d", "score": "0.7584221", "text": "function kv_cache_get($k)\n{\n $r = cache_get($k);\n if (NULL === $r) {\n $r = kv_get($k);\n $r and cache_set($k, $r);\n }\n return $r;\n}", "title": "" }, { "docid": "9eb555cac8d854ecdcdf1ef3b2752e5a", "score": "0.75733304", "text": "static function get( $key )\r\n\t{\r\n\t\treturn self::$memcache->get( $key );\r\n\t}", "title": "" }, { "docid": "40a8140e9a6e810ea53b8a291eb740a3", "score": "0.75693935", "text": "public function get($key)\n {\n $value = $this->memcache->get($this->prefix.$key);\n\n return $value;\n }", "title": "" }, { "docid": "221074df3322171123b53aaa27d45ee2", "score": "0.755475", "text": "public function get($key)\n {\n $prefixed = $this->prefix.$key;\n\n $cache = $this->table()->where('key', '=', $prefixed)->first();\n\n // If we have a cache record we will check the expiration time against current time on the system and see if\n // the record has expired. If it has, we will remove the records from the database table so it isn't returned\n // again.\n if (is_null($cache)) {\n return;\n }\n\n $cache = is_array($cache) ? (object)$cache : $cache;\n\n // If this cache expiration date is past the current item, we will remove this item from the cache. Then we\n // will return a null value since the cache is expired. We'll use \"Carbon\" to make this comparison with the\n // column.\n if ($this->currentTime() >= $cache->expiration) {\n $this->forget($key);\n\n return;\n }\n\n return $this->unserialize($cache->value);\n }", "title": "" }, { "docid": "b5412e783016c3aaf2acf227f7b0c7a7", "score": "0.75455135", "text": "public function getCache($key);", "title": "" }, { "docid": "1a981ea6303d67aad9122f95658d0fbe", "score": "0.7534687", "text": "private function cacheGet($key) {\n\t\treturn @file_get_contents($this->getCachePath().$key);\n\t}", "title": "" }, { "docid": "3a49dce1f43addb4edfd43af62b8d9e2", "score": "0.75305533", "text": "public function get($key) {\n return $this->memcache->get($key, null);\n }", "title": "" }, { "docid": "f9924283c337bd2869ec4fe40477e33a", "score": "0.74944144", "text": "function cache($key) {\n\t\treturn array_key_exists($key, $this->_cache) ? $this->_cache[$key] : null;\n\t}", "title": "" }, { "docid": "8743293d854ff951e96ec9f5a96b116f", "score": "0.74642307", "text": "protected function retrieve($key)\n\t{\n\t\treturn ( ! is_null($cache = apc_fetch(Config::get('cache.key').$key))) ? $cache : null;\n\t}", "title": "" }, { "docid": "0f904cf4e250e6145650305bc3ccbcfc", "score": "0.74604505", "text": "public function get($key)\n\t{\n\t\treturn (($cache = \\System\\Memcached::instance()->get(Config::get('cache.key').$key)) !== false) ? $cache : null;\n\t}", "title": "" }, { "docid": "632c12eb81f55975791da220c4e9614f", "score": "0.7459247", "text": "public function get(string $key);", "title": "" }, { "docid": "632c12eb81f55975791da220c4e9614f", "score": "0.7459247", "text": "public function get(string $key);", "title": "" }, { "docid": "632c12eb81f55975791da220c4e9614f", "score": "0.7459247", "text": "public function get(string $key);", "title": "" }, { "docid": "632c12eb81f55975791da220c4e9614f", "score": "0.7459247", "text": "public function get(string $key);", "title": "" }, { "docid": "632c12eb81f55975791da220c4e9614f", "score": "0.7459247", "text": "public function get(string $key);", "title": "" }, { "docid": "632c12eb81f55975791da220c4e9614f", "score": "0.7459247", "text": "public function get(string $key);", "title": "" }, { "docid": "632c12eb81f55975791da220c4e9614f", "score": "0.7459247", "text": "public function get(string $key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "c8a7641a3bd1e45dd2b096165fe81ae3", "score": "0.7456649", "text": "public function get($key);", "title": "" }, { "docid": "73774af246c911e67db1dca909e50d16", "score": "0.74484575", "text": "public function cacheFetch($key)\n {\n if ($this->getQueryCache() !== null) {\n $item = $this->getQueryCache()->getItem($key);\n if ($item->isHit()) {\n return $item->get();\n }\n }\n }", "title": "" }, { "docid": "ae90403407d6c1304df0957f096c71a1", "score": "0.74430406", "text": "public static function get($key=null)\n {\n if ($key === null) {\n return self::$cache;\n }\n\n if (isset(self::$cache[$key]) === true) {\n return self::$cache[$key];\n }\n\n return false;\n\n }", "title": "" }, { "docid": "f58a6896ba97cc1df0a33aa82f12f726", "score": "0.74000084", "text": "public function getFromCache($key)\r\n {\r\n if (array_key_exists($key, $this->objectCache)) {\r\n $this->client->logger->debug(\"[Constellix] Object Cache: Fetching {$key}\");\r\n return $this->objectCache[$key];\r\n }\r\n }", "title": "" }, { "docid": "405f88d37c6d37b255f37827635be948", "score": "0.7390044", "text": "public function get(Key $key);", "title": "" }, { "docid": "5694d462c89a32ee1bf535d3d57b8bb5", "score": "0.7375403", "text": "protected function retrieve($key)\n {\n if ($this->sectionable($key))\n {\n list($section, $key) = $this->parse($key);\n\n return $this->get_from_section($section, $key);\n }\n elseif (($cache = $this->memcache->get($this->key.$key)) !== false)\n {\n return $cache;\n }\n }", "title": "" }, { "docid": "2835cc631e5030d1dd4c15165288f3a8", "score": "0.73724324", "text": "public static function get($key)\n {\n return Cache::$object->getImplementation($key);\n }", "title": "" }, { "docid": "255860c0748023e5514b591ba719bb1a", "score": "0.73696566", "text": "public function get($key){\n $key = saltedHash(\"crc32b\", $key);\n return $this->memcache->get($key);\n }", "title": "" }, { "docid": "2463cbf233271f3095274f5d9ff1208b", "score": "0.73205245", "text": "public function _get( $key ) {\r\n if ( isset($key) ) {\r\n $this->_db->query(\"SELECT data, serialized, expired FROM {cache} WHERE id='%s'\", md5($key));\r\n if( $obj = $this->_db->fetchObject() ) {\r\n if( $obj->expired >= time() ) {\r\n if( $obj->serialized ) {\r\n // TODO postgres need decode_blob\r\n return unserialize($obj->data);\r\n }\r\n return $obj->data;\r\n }\r\n }\r\n }\r\n }", "title": "" }, { "docid": "a2ef31e5a3592902dbe3ec6d6752f457", "score": "0.7311908", "text": "public function get($key) {\r\n\t\t$filename = $this->getFileName($key);\r\n\r\n\t\tif ( ! is_file($filename)) {\r\n\t\t\tif ($this->log) {\r\n\t\t\t\tif ($this->log instanceof LoggerInterface) {\r\n\t\t\t\t\t$this->log->info(\"Retrieving key '{key}' from file cache: cache miss.\", array('key'=>$key));\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$this->log->trace(\"Retrieving key '$key' from file cache: cache miss.\");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn null;\r\n\t\t}\r\n\t\t$value = include $filename;\r\n\r\n\t\tif ($value['lifetime'] !== 0 && $value['lifetime'] < time()) {\r\n\t\t\tif ($this->log) {\r\n\t\t\t\tif ($this->log instanceof LoggerInterface) {\r\n\t\t\t\t\t$this->log->info(\"Retrieving key '{key}' from file cache: key outdated, cache miss.\", array('key'=>$key));\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$this->log->trace(\"Retrieving key '$key' from file cache: key outdated, cache miss.\");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn null;\r\n\t\t}\r\n\r\n\t\tif ($this->log) {\r\n\t\t\tif ($this->log instanceof LoggerInterface) {\r\n\t\t\t\t$this->log->info(\"Retrieving key '{key}' from file cache.\", array('key'=>$key));\r\n\t\t\t} else {\r\n\t\t\t\t$this->log->trace(\"Retrieving key '$key' from file cache.\");\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn $value['data'];\r\n\t}", "title": "" }, { "docid": "bae71eb66c4c1140f0279d8c302d0e3b", "score": "0.73042977", "text": "public static final function get($key) {\r\n\t\tif( function_exists('apc_fetch') )\r\n\t\t{\r\n\t\t\treturn apc_fetch($key);\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\tself::clearSessions();\r\n\t\t\treturn @$_SESSION['CACHE_' . $key ];\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "8fc58c10117dae497ebc6c7538c7e1c4", "score": "0.7300577", "text": "abstract protected function fetchObjectFromCache($key);", "title": "" }, { "docid": "c0d22089e63546d6d9fb324ecc52676a", "score": "0.7290246", "text": "public function __get($key) {\n if (!$this->cached($key)) {\n return;\n }\n $information = $this->session[$key][self::CACHEVALUE];\n return unserialize($information);\n }", "title": "" }, { "docid": "e3af4d89bab5a3edd8359982dfb2b941", "score": "0.7288488", "text": "abstract public function get($key);", "title": "" }, { "docid": "e3af4d89bab5a3edd8359982dfb2b941", "score": "0.7288488", "text": "abstract public function get($key);", "title": "" }, { "docid": "e3af4d89bab5a3edd8359982dfb2b941", "score": "0.7288488", "text": "abstract public function get($key);", "title": "" }, { "docid": "e3af4d89bab5a3edd8359982dfb2b941", "score": "0.7288488", "text": "abstract public function get($key);", "title": "" }, { "docid": "4b3a86e7bb7cd816f0e645b822eac755", "score": "0.72632015", "text": "public function fetch($key) {\n\n $data = $this->memcache->get( $this->keyPrefix.$key );\n if ($data===false) return null;\n return $data;\n\n }", "title": "" }, { "docid": "864cc3e29078f63e611b47559dfa8b8e", "score": "0.72514105", "text": "public function get($key)\n {\n $key = (string)$key;\n $value = null;\n $this->hit = false;\n\n if (\\array_key_exists($key, self::$registry)) {\n if (self::$registry[$key]['expires'] >= (new DateTime())) {\n $this->hit = true;\n return $this->restoreDataStructure($key);\n }\n unset(self::$registry[$key]);\n }\n\n return $value;\n }", "title": "" }, { "docid": "a404383ffa906311106acaafcb12c2f2", "score": "0.7237587", "text": "public function Cache_And_Get_By_Key(){ \n\t\t// Arrange\n\t\t$cache = $this->GetCache();\n\t\t$date = new DateTime();\n\t\t$date = $date->add(new DateInterval(\"P1Y\"));\n\t\t$cacheItem = new \\EggCup\\CacheItem(\"key\", $date, array(), \"value\");\n\t\t// Act\n\t\t$cache->Cache($cacheItem);\n\t\t// Assert\n\t\tAssert::IsTrue($cache->TryGetByKey(\"key\", $value));\n\t\tAssert::AreEqual($value, \"value\");\n\t}", "title": "" }, { "docid": "12f7eb64ebd5c8b4f79715c0ea9f7913", "score": "0.7235043", "text": "function get($key) {\n\t\t$this->check();\n\t\t\n\t\t$cache_key = md5($key);\n\t\t\n\t\t$d = $this->db->fetch(\"SELECT `data`, `expire_time` FROM `\" . $this->cfgs['db']['table'] . \"` WHERE `cache_key` = ?\", array(\n\t\t\t$cache_key\n\t\t));\n\t\tif ($d) {\n\t\t\tif (0 < ( int ) $d['expire_time'] && ( int ) $d['expire_time'] < time()) {\n\t\t\t\t$this->db->execute(\"DELETE FROM `\" . $this->cfgs['db']['table'] . \"` WHERE `cache_key` = ?\", array(\n\t\t\t\t\t$cache_key\n\t\t\t\t), DbPdo::SQL_TYPE_DELETE);\n\t\t\t}\n\t\t\t\n\t\t\t$data = unserialize($d['data']);\n\t\t\tif (!empty($data))\n\t\t\t\treturn $data;\n\t\t}\n\t\treturn false;\n\t}", "title": "" }, { "docid": "7aaf35d17a5c55cdacd3968a5a172727", "score": "0.72310466", "text": "private function _cache_get( $key ) {\n\t\treturn wp_cache_get( 'presenter-' . $key, 'presenter' );\n\t}", "title": "" }, { "docid": "95f661e5f46f74647e3d44d0863ef867", "score": "0.722717", "text": "public function get(string $key)\n {\n return $this->fileBoundCache->get($key);\n }", "title": "" }, { "docid": "37cfb3099676a8814b15b80b44973a7d", "score": "0.7206668", "text": "protected function getValue ($key = \"\") {\n\t\ttry {\n\t\t\tif (strlen($key) < 1) {\n\t\t\t\tthrow new LBoxExceptionCache(\"\\$key: \". LBoxExceptionCache::MSG_PARAM_STRING_NOTNULL, LBoxExceptionCache::CODE_BAD_PARAM);\n\t\t\t}\n\t\t\t// loadneme data\n\t\t\t$data\t= \t$this->getData();\n\t\t\treturn\t\tarray_key_exists($key, (array)$data) ? $data[$key] : NULL;\n\t\t}\n\t\tcatch (Exception $e) {\n\t\t\tthrow $e;\n\t\t}\n\t}", "title": "" }, { "docid": "e75161bf249532ba70e391d41ff58913", "score": "0.71795994", "text": "public function getItem($key)\n {\n // get the item from the underlying cache\n $primary = $this->cache->getItem($key);\n\n return $this->getSafeCacheItem($primary);\n }", "title": "" }, { "docid": "917680c7c1d0024b8dd8d165d0ca2f57", "score": "0.7139183", "text": "public function read($key)\n {\n return zend_shm_cache_fetch($this->prefix . $key);\n }", "title": "" }, { "docid": "243886fa8606be9f0b754af67ab66b3f", "score": "0.7130172", "text": "public function getValue($key);", "title": "" }, { "docid": "80f437a1c168d7f6ba88299178fdd07a", "score": "0.71204525", "text": "public function get(string $key): object\n {\n return $this->cache->get($key);\n }", "title": "" }, { "docid": "df3fe12af85f06446b1188af52904a19", "score": "0.7094368", "text": "public function get($key)\n {\n $prefix = Config::get('cache', 'key_prefix');\n return unserialize($this->conn->get($prefix . $key));\n }", "title": "" }, { "docid": "5746d17ced717dd3079f575a02f3b07f", "score": "0.7085451", "text": "public function getItem($key);", "title": "" }, { "docid": "103bb4833e32f7f19aaa337b06b37658", "score": "0.7079354", "text": "public function load($key)\r\n {\r\n return $this->updateCache()->cache()->get($key);\r\n }", "title": "" }, { "docid": "bf88d4ef2b62122cfa4cb3f7d345efc3", "score": "0.7075206", "text": "public function get($key) {\r\n\t\tif(isset($_GET[\"__DEBUG\"]) && $_GET[\"__DEBUG\"] == 1) return false; \r\n $mc = $this->_get_cacheClient($key);\r\n return $mc->get($key);\r\n }", "title": "" }, { "docid": "bc46bcc805f0b8e5c7449201019412fd", "score": "0.70741767", "text": "abstract protected function get($key);", "title": "" }, { "docid": "3bf5c24f771eca5e087288ae18de9d28", "score": "0.70714414", "text": "function get( $key ) ;", "title": "" }, { "docid": "0f28d02710a8086f41c0c6690849985b", "score": "0.70633274", "text": "public function get($key)\n {\n $cacheData = $this->table()->where('key', $this->getKeyWithPrefix($key))->first();\n\n return $cacheData ? $this->decodeFromSaved($cacheData['value']) : null;\n }", "title": "" }, { "docid": "aafd9e1868f66a2c52c2fa7aa14bd7ba", "score": "0.7053899", "text": "public function get($key)\n {\n if (empty($key))\n {\n return null;\n }\n return $this->memcache->get($key);\n }", "title": "" }, { "docid": "758383a903c4a288bfcadf560583c885", "score": "0.7035945", "text": "protected function getCached($key, $default = NULL) {\n return isset($this->cache[$key]) ? $this->cache[$key] : $default;\n }", "title": "" }, { "docid": "e6b250fafe737f5b19daa775a479e855", "score": "0.69973934", "text": "public function getByKey($key);", "title": "" }, { "docid": "e6b250fafe737f5b19daa775a479e855", "score": "0.69973934", "text": "public function getByKey($key);", "title": "" }, { "docid": "edc791eae6b1ed54d88bfbdbb6e4b0b2", "score": "0.6989063", "text": "public function get($key) {\r\n\t\tif(isset($_GET[\"__DEBUG\"]) && $_GET[\"__DEBUG\"] == 1) return false;\r\n $mc = $this->_get_cacheClient($key);\r\n if($mc == false){\r\n return false;\r\n }\r\n return $mc->get($key);\r\n }", "title": "" }, { "docid": "e7b4b7b5065f17bbf5a216f0685aee99", "score": "0.6975499", "text": "function getValue($key);", "title": "" } ]
d03b388b5c2bcd743860d5a3096e1c5d
Execute the console command.
[ { "docid": "d5dff9e7384cd54f064e9a72b28c919b", "score": "0.0", "text": "public function handle()\n {\n $force = $this->option('force', false);\n if ($force) {\n $this->error(\"Force mode active.\");\n }\n $current_version = $this->_getCurrentAdminerVersion();\n if ($current_version) {\n $this->info(\"Lumener: Current \".$current_version);\n } else {\n $this->error(\"Lumener: Adminer not found.\");\n }\n $version = $this->_getRequiredAdminerVersion();\n if ($force || !file_exists($this->filename)\n || $version != $current_version) {\n $this->_downloadVersion($version);\n } else {\n $this->info('Lumener: Up to date.');\n }\n }", "title": "" } ]
[ { "docid": "3286e942a6a81bd5076702116b0dc09f", "score": "0.67814165", "text": "public function handle()\n {\n $arguments = $this->argument();\n $options = $this->option();\n\n $this->writeRepository($arguments, $options);\n\n $this->composer->dumpAutoloads();\n }", "title": "" }, { "docid": "2ad0dbd5fc9760776031ff6b990a46a7", "score": "0.6666145", "text": "public function handle()\n {\n $options = array_merge(\n $this->arguments(),\n $this->options()\n );\n $this->entityGenerator->setOptions($options);\n $this->entityGenerator->run();\n }", "title": "" }, { "docid": "8fa2b14dbf24f9d8949c4b69e5e5ab44", "score": "0.6398657", "text": "public function handle()\n {\n if($this->option('usePsn')) {\n $file = \"UP2613-CUSA09143_00-USSUPERHOTVRGAME.json\";\n } else if($this->option('useXbox')){\n $file = \"BV6BRSLFJW3W.json\";\n } else {\n $file = \"yAKJO3LB7zlPsJlbQIMpmmN7o2ffLTB6.json\";\n }\n $myGameJson = $this->loadJson($file);\n dd($myGameJson);\n echo PHP_EOL;\n }", "title": "" }, { "docid": "985b220c85b08d3e48b835ec69e879ce", "score": "0.6322674", "text": "public function handle()\n {\n $url = $this->argument('url');\n\n (new Varnish())->flush(null, $url);\n\n $this->comment('The varnish cache has been flushed!');\n }", "title": "" }, { "docid": "3553c22e0cc358184a9a47399b35df7d", "score": "0.63164955", "text": "public function handle()\n {\n if ($this->option('import')) {\n $this->call('translations:import');\n }\n \n $count = $this->manager->generateTranslations($this->option('locale'), $this->option('group'));\n $this->info(\"Done generating translations for {$count} records.\");\n \n if ($this->option('export')) {\n $this->call('translations:export', [\n 'group' => $this->option('group')\n ]);\n }\n }", "title": "" }, { "docid": "7d13ad91df1edc7ad70fa046da404521", "score": "0.6294314", "text": "public function handle()\n {\n $basePathKey = $this->argument( 'basePathKey' );\n\n if( $basePathKey )\n $this->fetchElement( $basePathKey );\n else\n $this->fetchAll();\n }", "title": "" }, { "docid": "a135484f114e002d1022687c1891adb5", "score": "0.62804234", "text": "public function handle()\n {\n $argument = $this->arguments();\n\n dd($argument);\n\n $this->info(\"test info\");\n }", "title": "" }, { "docid": "43c939753569bb513b8c473a52990ee3", "score": "0.62763065", "text": "public function handle()\n {\n $this->info('Users');\n \n $this->convertUsers();\n $this->info(\"\\tConverted users table\");\n }", "title": "" }, { "docid": "426c2ad1f226b3f6d18899098eb5fd7b", "score": "0.62671643", "text": "public function handle()\n {\n list($projectId, $domain) = $this->getArguments();\n\n\n $this->validateArguments($projectId, $domain);\n\n\n $this->project = Project::findOrFail($projectId);\n\n $outputPath = $this->makeOutputFileAndPath($domain, $projectId);\n\n $this->cmd = $this->createCommand($domain, $outputPath);\n\n $this->line(\"Executed command: \" . $this->cmd);\n\n AdminNotice::create([\n 'type' => 'success',\n 'context' => \"ctfr:scan\",\n 'message' => \"Execution started\",\n 'cmd' => $this->cmd,\n ]);\n\n $this->executeCommand($this->cmd);\n\n $this->checkIfReportWasCreated($outputPath);\n\n $this->importCTFRDataToDB($outputPath);\n\n\n $message = \"Process finished, report saved to file and database.\";\n $this->info($message);\n\n AdminNotice::create([\n 'type' => 'success',\n 'context' => 'ctfr:scan',\n 'message' => $message,\n 'cmd' => $this->cmd,\n ]);\n }", "title": "" }, { "docid": "d91be23a4cabfc874df7a43ddb8cad2e", "score": "0.6257764", "text": "public function handle()\n {\n $this->matchService->generateMatch();\n $this ->info('Match Generated');\n }", "title": "" }, { "docid": "6c91e0102878bacbdab77893e19e2a03", "score": "0.62528265", "text": "public function handle() {\n $format = $this->option('format');\n\n $user = AccountHelpers::findUser($this->argument('user'));\n if ($user === null) {\n $this->error(\"User not found.\");\n return;\n }\n\n $information = $user->getInformation();\n\n switch ($format) {\n case \"human\":\n foreach ($user->getInformation() as $attribute => $value) {\n $this->printInformationAttribute($attribute, $value);\n }\n break;\n\n case \"json\":\n echo json_encode($information), \"\\n\";\n break;\n\n default:\n $this->error(\"Unknown format: $format\");\n }\n }", "title": "" }, { "docid": "798ef051aaf2a85c66c3ab986cebaa28", "score": "0.62514573", "text": "public function handle()\n {\n $locale = $this->argument('locale');\n\n if ( ! $this->isSupportedLocale($locale)) {\n $this->error(\"Unsupported locale: '{$locale}'.\");\n return;\n }\n\n $this->loadFreshApplicationRoutes($locale);\n\n parent::handle();\n }", "title": "" }, { "docid": "1a0ab028b3f562e01e8f88e93a382228", "score": "0.6240033", "text": "public function handle(): void\n {\n $userId = (int)$this->argument('userId');\n $user = $this->useCase->run($userId);\n\n $responder = new UserShowConsoleResponder($this->output);\n $responder->respond($user);\n }", "title": "" }, { "docid": "e25416d1e0db5baefd5ae945d4ee4d8a", "score": "0.62301296", "text": "public function handle()\r\n {\r\n $documentRoot = array_get($this->getConfig(), 'documentRoot', public_path());\r\n $views = array_get($this->getConfig(), 'views', []);\r\n foreach ($views as $source => $options)\r\n {\r\n $view = array_get($options, 'view', $options);\r\n $layout = array_get($options, 'layout');\r\n $engine = array_get($options, 'engine');\r\n $noBase = array_get($options, 'no-base', false);\r\n\r\n $this->call('make:view', [\r\n 'source' => $source,\r\n 'view' => $view,\r\n '--layout' => $layout,\r\n '--engine' => $engine,\r\n '--no-base' => $noBase,\r\n '--document-root' => $documentRoot,\r\n ]);\r\n }\r\n }", "title": "" }, { "docid": "e4610b90cfa0abc54be299e04a4c0aac", "score": "0.6229968", "text": "public function handle()\n {\n // Fills the board with random symbols.\n $this->game->getBoard()->fillRandomly();\n\n // Start the game execution.\n $gameMatch = $this->game->play();\n\n // Prints the match status in the console.\n $gameMatch->printResume();\n }", "title": "" }, { "docid": "b77936531c7464d65e8cf11c294334ab", "score": "0.6227885", "text": "public function handle()\n {\n $this->info('Running...');\n\n if ($this->option('geula')) {\n $this->handleGeula();\n } else {\n $this->loadUsers();\n\n file_get_contents('https://flutterx.com/?clear_cache=true');\n }\n\n $this->info('Done');\n }", "title": "" }, { "docid": "ac9b3a41700e7134646b6eda9d9d594d", "score": "0.622648", "text": "public function handle()\n {\n if ($this->argument('tenant')) {\n $this->migrate(\n $this->tenantRepository->findByCompanyName($this->argument('tenant'))\n );\n } else {\n $tenants = $this->tenantRepository->getAll();\n\n if ($tenants->isEmpty()) {\n return $this->info('No tenants found');\n }\n\n $tenants->each(function (Customer $customer) {\n $this->migrate($customer);\n });\n }\n }", "title": "" }, { "docid": "67a227160c5009c59c7e9f3016bfd4cb", "score": "0.6222464", "text": "public function handle()\n {\n $count = $this->manager->suffixTranslations($this->argument('basic'), $this->argument('new'));\n $this->info(\"Done suffixing translations for {$count} records.\");\n }", "title": "" }, { "docid": "932aabe9d4877c9a152cde276c6d455b", "score": "0.6187315", "text": "public function handle()\n {\n file_get_contents(config('herbert.server') . '/soundboard?secret=' . config('herbert.secret') . '&sound=' . $this->argument('sound'));\n $this->info(\"Playing sound.\");\n }", "title": "" }, { "docid": "9e540d530aa02b5fbc218fcd324fc864", "score": "0.6160508", "text": "public function handle()\n {\n $code = $this->option('code');\n $id = $this->option('id');\n if (empty($code) && empty($id)) {\n $this->error(PHP_EOL . 'use --code or --id to find user' . PHP_EOL);\n exit(2);\n }\n\n $user = User::where('code', '=', $code)->orWhere('id', '=', $id)->first();\n if (!$user) {\n $this->error('User not found');\n exit(2);\n }\n dd($user->toArray());\n return;\n }", "title": "" }, { "docid": "f7788bf43b6181b5edfaac5657a2520f", "score": "0.6157324", "text": "public function handle()\n {\n $name = $this->argument('name');\n\n file_put_contents(root_dir() . '/app/RequestRules/' . $name . '.php', str_replace('{NAME}', $name, file_get_contents('../stubs/Rule.stub')));\n\n $this->info('Rule generated');\n }", "title": "" }, { "docid": "9f6ea6c5cddc47f4ca63a9b70f3d7124", "score": "0.61478907", "text": "public function handle()\n {\n $action = $this->argument('action');\n\n if ($action === 'getInfoHistory') {\n $this->getInfoHistory();\n }\n }", "title": "" }, { "docid": "3d3f6e0f3f21f84c63306ccf13d68a68", "score": "0.6140684", "text": "public function handle()\n {\n $this->showTokenDetails(\n token: $this->findToken()\n );\n\n return Command::SUCCESS;\n }", "title": "" }, { "docid": "8f6028fa217f7398b18d21e2dc40950e", "score": "0.6138434", "text": "public function handle()\n {\n $clips = $this->getAllClips();\n\n foreach ($clips as $clip) {\n\n $views = $this->getViews($clip);\n\n $this->update($clip, $views);\n }\n }", "title": "" }, { "docid": "3a8d7f5d070bf75cc35e6174e0df35ef", "score": "0.61365247", "text": "public function handle()\n { \n if (parent::handle() === false) {\n return;\n } \n\n $this->makeMigration(snake_case($this->getNameInput()));\n\n if($this->option('multilingual')) { \n sleep(1);\n \n $this->call('make:resource-model-translation', [\n 'name' => $this->getNameInput(),\n 'path' => $this->argument('path'),\n 'namespace' => $this->argument('namespace'),\n '-rp' => $this->option('realpath'),\n ]);\n } \n }", "title": "" }, { "docid": "b2433043c15d8daaf44addab6f88ee41", "score": "0.6135103", "text": "public function handle()\n {\n $this->info('Starting chart generation...');\n // get all users who want updated charts\n $users = User::all();\n\n $bar = $this->output->createProgressBar(count($users));\n\n foreach ($users as $user) {\n $this->spotify->generateChart($user);\n\n $this->info('Chart for ' . $user->name . ' generated successfully!');\n\n $bar->advance();\n }\n\n $bar->finish();\n\n $this->info(PHP_EOL . 'All charts generated successfully!');\n Log::info('[Commands\\GenerateCharts] All charts generated successfully!');\n }", "title": "" }, { "docid": "b4a13b88cecff84b577730002b27d446", "score": "0.6122314", "text": "public function handle()\n {\n $type = $this->argument('type');\n\n switch ($type) {\n case 'release'://发布抓女童\n $this->updateRelease();\n break;\n case 'top'://置顶状态\n $this->updateTop();\n break;\n default:\n $this->updateRelease();\n break;\n }\n }", "title": "" }, { "docid": "9af900d220eb7f7f469ba1c26857d335", "score": "0.6114794", "text": "public function handle()\n {\n $languageData = $this->gatherLanguageData();\n $this->dumpLanguageFile($languageData);\n\n $this->info('All complete');\n }", "title": "" }, { "docid": "34d193e28710caac27ca2cfc16242735", "score": "0.61135507", "text": "public function handle()\n {\n $transformerName = $this->argument('transformerName');\n $moduleName = $this->argument('moduleName');\n\n $this->action($transformerName, $moduleName);\n }", "title": "" }, { "docid": "d5df8317fbc8a2d4ed9195f63889b771", "score": "0.6110957", "text": "public function handle()\n {\n\n if($id = $this->argument('id')){\n $project = Project::find($id);\n if($project) $this->execCommand($project);\n return;\n }\n\n $projects = Project::all();\n\n foreach ($projects as $project){\n $this->execCommand($project);\n }\n }", "title": "" }, { "docid": "4ee1df21110157bea491b729cfec5ab7", "score": "0.6108141", "text": "public function handle()\n {\n $tokens = $this->argument('token');\n $title = $this->argument('title');\n $body = $this->argument('body');\n $clickAction = $this->argument('click_action');\n\n self::send($tokens, $title, $body, $clickAction);\n }", "title": "" }, { "docid": "d529dac39313df5a2e0be85012b08c56", "score": "0.6088414", "text": "public function handle(): void\n {\n // Get the name of the seeder\n $name = trim($this->argument('name'));\n\n // Now we are ready to write the migration out to disk. Once we've written\n // the seeder out, we will dump-autoload for the entire framework to\n // make sure that the seeders are registered by the class loaders.\n $this->writeMigration($name, null, null);\n\n $this->composer->dumpAutoloads();\n }", "title": "" }, { "docid": "f11f449f74d35b1dd34b26062d0577db", "score": "0.60860395", "text": "public function handle()\n {\n $this->getArguments();\n \n $this->copyMigrations(); \n }", "title": "" }, { "docid": "5a63597c7002df8b6d0a6526a94cc484", "score": "0.6085672", "text": "public function handle()\n {\n $userId = $this->argument('user');\n\n if ($userId) {\n $users = User::where('id', $userId)->get();\n } else {\n $users = User::all();\n }\n\n $this->info(\"Daily Revenue Report\");\n $this->info(\"-------------------------------------------\");\n\n foreach ($users as $user) {\n if (! $user->amazonMws->valid) {\n $this->info(\" No valid Amazon MWS: {$user->name}\");\n continue;\n }\n\n $reportTitle = 'Daily Revenue [' . date('n/d/y', time() - 86400) . ']';\n $reportData = DailyRevenue::fetch($user, Carbon::yesterday(), 1, true);\n\n Mail::to($user)->send(new DailyRevenueReportGenerated($reportData, $reportTitle));\n\n $this->info(\"*** Daily revenue report email sent: {$user->name}\");\n }\n }", "title": "" }, { "docid": "87bd65a01fb6e064469f9cd0d710a2a2", "score": "0.6084847", "text": "public function handle()\n {\n\n $userEmail = $this->argument('email');\n\n /** @var User $user */\n $user = User::where('email', $userEmail)\n ->first();\n\n if (!$user) {\n $this->error('User not found');\n exit();\n }\n\n Passport::personalAccessTokensExpireIn(Carbon::now()->addHour());\n\n /** @var PersonalAccessTokenResult $token */\n $token = $user->createToken('console_created_token');\n\n $this->info($token->accessToken);\n }", "title": "" }, { "docid": "9fce21f20b490c7e5aba52500d487a42", "score": "0.6084095", "text": "public function handle()\n {\n if (Storage::disk($this->disk)->exists($this->xml)) {\n Storage::disk($this->disk)->delete($this->xml);\n }\n\n $domain = $this->argument('domain');\n\n URL::forceSchema(parse_url($domain, PHP_URL_SCHEME));\n URL::forceRootUrl($domain);\n\n $links = $this->links();\n $articles = $this->articles();\n $pages = $this->pages();\n\n $this->comment('Finalizing XML');\n\n Storage::disk($this->disk)->prepend($this->xml, '<?xml version=\"1.0\" encoding=\"UTF-8\"?><urlset xmlns=\"http://www.sitemaps.org/schemas/sitemap/0.9\">');\n Storage::disk($this->disk)->append($this->xml, '</urlset>');\n }", "title": "" }, { "docid": "07f4a075cd7a2c9b48165363fb332ceb", "score": "0.60829866", "text": "public function handle()\n {\n // handle send mail\n $userId = $this->argument('userId');\n $user = User::find($userId);\n\n $options = $this->options();\n $ids = $options['id'];\n\n $users = User::find($ids);\n\n // send mail using optional argument\n if ($users->isNotEmpty()) {\n echo 'users count = ' . $users->count() . \"\\n\";\n }\n\n // send mail using argument\n if (isset($user)) {\n echo 'email sent to: ' . $user->email . \"\\n\";\n }\n }", "title": "" }, { "docid": "f3b6c0041aa376098c2d241798c4aac7", "score": "0.6078814", "text": "public function handle()\n {\n $this->warn('*** This command is obsolete and will be removed in future releases. Instead, please use create:scaffold. ***');\n $this->info('Calling create:scaffold to process your request.');\n\n $this->call(\n 'create:scaffold',\n $this->getCallableArray()\n );\n }", "title": "" }, { "docid": "187899607e1bcacdfaeec96e951b812a", "score": "0.6078003", "text": "public function handle()\n {\n $string = $this->argument('expression');\n $service = new CalculationService;\n $result = $service->calculateExpression($string);\n echo $result.PHP_EOL; \n }", "title": "" }, { "docid": "18de1473542328830d207664fdc18e94", "score": "0.6077905", "text": "public function handle()\n {\n $sources = $this->scrapperService->listSources();\n $this->info(sprintf('%d sources available:', count($sources)));\n\n foreach ($sources as $source) {\n $this->line(str_replace('\\\\', '\\\\\\\\', $source));\n }\n }", "title": "" }, { "docid": "3f5d65b47567e24a1b52fd45034b6c90", "score": "0.6074105", "text": "public function handle()\n {\n $config = new ExtractsNamespaceConfig($this->argument('path'));\n $stub = new TransformsStubs(file_get_contents(__DIR__ . '/stubs/TransformerStub.txt'), $this->code);\n\n if (file_exists($config->getInstallPath())) {\n $this->output->error('File already exists');\n\n return;\n }\n\n $this->confirmConfig($config, $stub, function ($config, $stub) {\n $this->transformStub($config, $stub);\n\n $this->output->success('Transformer created!');\n });\n }", "title": "" }, { "docid": "a076cb827d29a76179ba230a7ca8f55a", "score": "0.60708547", "text": "public function handle()\n {\n $this->service = new SkillService;\n $this->info('Updating skills...');\n $t = microtime(true);\n\n $this->service->update();\n\n $this->info(PHP_EOL . 'Skills updated in ' . (microtime(true) - $t) . ' seconds');\n }", "title": "" }, { "docid": "da1d3b5e991569af81d226f1327ac9f5", "score": "0.60670006", "text": "public function handle()\n {\n $this->info('Fetching all users...');\n\n $users = $this->fetchUsers();\n\n $this->info(\"Updating the social media statistics of all users...\\n\");\n\n $bar = $this->output->createProgressBar(count($users));\n\n foreach ($users as $user) {\n $this->updateSocialMediaStats($user->socialMedia);\n\n $bar->advance();\n }\n\n $bar->finish();\n\n $this->info(\"\\n\\nAll done!\");\n }", "title": "" }, { "docid": "e1d730ec1c2fe84f0482adec606bf59d", "score": "0.60667837", "text": "public function handle()\n {\n $translationFiles = $this->manager->files();\n\n $this->syncKeysFromFiles($translationFiles);\n\n $this->syncKeysBetweenLanguages($translationFiles);\n\n $this->info('Done!');\n }", "title": "" }, { "docid": "d47bd0970bbc3b2fa0b1242ad9ded798", "score": "0.6065298", "text": "public function handle()\n {\n $filename = $this->argument('output');\n $disk = $this->option('disk');\n\n $groups = resolve(TranslationManager::class)->groups();\n if (!count($groups)) {\n $this->error('You don\\'t have any lang file');\n }\n\n Excel::store(new TranslationsExport, $filename, $disk);\n $path = str_replace(base_path(), '', Storage::disk($disk)->path($filename));\n $this->info($path . ' exported');\n }", "title": "" }, { "docid": "5e6efc21a7d7e9dc1331569c0d0b504f", "score": "0.60620636", "text": "public function handle()\n {\n $this->getApplication()->setCatchExceptions(false);\n\n $config = new Configuration();\n\n $config->getPresenter()->addCasters(\n $this->getCasters()\n );\n \n $shell = new Shell($config);\n\n $include = $this->argument('include');\n if (file_exists($include)) {\n $shell->setIncludes([$include]);\n }\n\n $shell->run();\n }", "title": "" }, { "docid": "2d98527d3a7c4c68b95215b566ab24b0", "score": "0.6061849", "text": "public function handle()\n {\n $action = $this->argument('action');\n\n switch ($action) {\n\n case 'start':\n $this->start();\n break;\n }\n }", "title": "" }, { "docid": "ce95cc6cc37644c2b9818cd3d93a657c", "score": "0.6057885", "text": "public function handle()\n {\n $interactive = $this->option('interactive');\n $type = $this->option('type');\n $content = $this->option('content');\n $users = $this->option('users');\n if (true === $interactive) {\n $type = $this->anticipate('What type of realtime event are you sending?', [$type]);\n $content = $this->anticipate('What is the json encoded content of the event you are sending? (Optional)', [$content]);\n $users = array_map('trim', explode(',', $this->anticipate('What users would you like to send the event to (Comma seperated list of IDs)?', $users)));\n }\n if (!is_array($users) || count($users) < 1) {\n $this->error('You must pass at least 1 user ID to continue');\n }\n $content = json_decode($content);\n $bar = $this->output->createProgressBar(count($users));\n if ($users[0] == 'all') {\n $users = User::all();\n }\n foreach ($users as $user) {\n $sent = RealtimeEvent::emit($user, $type, $content);\n echo \"\\n\";\n if (true == $sent) {\n $this->info('Emitted Successfully');\n } else {\n $this->error('Emission Failed');\n }\n $bar->advance();\n }\n echo \"\\n\";\n }", "title": "" }, { "docid": "765b8af1e141563a02f6717d3c4b4c1d", "score": "0.6055982", "text": "public function handle()\n {\n if ($this->laravel->environment('production')) {\n throw new RuntimeException('This command is not allowed in production.');\n }\n\n $keyName = $this->argument('key');\n if (!$this->filesystem->exists($this->laravel->basePath(\"keys/$keyName.pem\"))) {\n throw new RuntimeException(\"Key does not exists: $keyName.pem\");\n }\n $privateKey = $this->filesystem->get(\n $this->laravel->basePath(\"keys/$keyName.pem\")\n );\n $jwt = $this->build(new Builder())\n ->getToken(\n new RS256(),\n new Key($privateKey)\n );\n $this->info($jwt);\n }", "title": "" }, { "docid": "7361a45512fece1f4ef47889bbe7eae5", "score": "0.6050824", "text": "public function handle()\n {\n $force = (bool) $this->option('force');\n\n $sourceCurrency = $this->getSourceCurrency();\n $currencies = $this->getAvailableCurrencies();\n\n Log::debug(\n 'Fetching currencies rates',\n [\n 'source' => $sourceCurrency,\n 'currencies' => $currencies\n ]\n );\n\n $dump = $this->serviceAPI->dump($sourceCurrency, $currencies);\n\n $this\n ->cacheRepository\n ->store($dump, $force);\n\n $this->info('CurrencyLayer rates cache populated.');\n }", "title": "" }, { "docid": "442950d57698d1e051f2d8c7c2115c50", "score": "0.6049888", "text": "public function handle()\n {\n // If seed option is NOT enabled\n if ($this->option('seed') === false) {\n $this->migration();\n } else {\n $this->seed();\n }\n }", "title": "" }, { "docid": "406f745e13bfb5af45e58c79ae561d11", "score": "0.60472256", "text": "public function handle() {\n //Gets the information\n $user = AccountHelpers::findUser($this->argument('user'));\n if ($user === null) {\n $this->error(\"User not found.\");\n return;\n }\n\n $this->email = $user->getInformation()['email'];\n\n //Operation\n $success = $this->sendResetMail();\n if (!$success) {\n $this->error(\"The user has been found, but the password broker considers this user is invalid.\");\n return;\n }\n\n //Regular output\n $format = $this->option('format');\n switch ($format) {\n case \"human\":\n $this->info(\"A reset link mail has been sent to $this->email.\");\n break;\n\n case \"json\":\n echo json_encode([\n \"result\" => \"ok\",\n \"email\" => $this->email\n ]);\n echo PHP_EOL;\n break;\n\n default:\n $this->error(\"Unknown format: $format\");\n }\n }", "title": "" }, { "docid": "96a4f1ec78525135c6a0e51e585ce2e7", "score": "0.6039309", "text": "public function handle()\n {\n $this->classname = $this->getClassnameArgument();\n\n $this->call('Cms:blueprint', [\n 'classname' => $this->classname\n ]);\n $this->call('Cms:template', [\n 'classname' => Str::kebab($this->classname)\n ]);\n }", "title": "" }, { "docid": "dd268c4e593ab926dbf4b3ecc13d87a6", "score": "0.60377955", "text": "public function handle()\n {\n $this->addon = $this->getAddon();\n\n if (parent::handle() !== false) {\n if ($this->option('migration')) {\n $table = $this->toTable($this->argument('name'));\n\n $this->call('make:migration', [\n 'name' => $this->option('migration'),\n '--addon' => $this->option('addon'),\n '--create' => $table,\n ]);\n }\n }\n }", "title": "" }, { "docid": "724070cc7e95425d14102fb6509af244", "score": "0.6035814", "text": "public function handle()\n {\n $tenant = Tenant::firstOrCreate([\n 'domain' => $this->argument('domain'),\n ]);\n\n $this->info('Created a tenant with the domain: ' . $tenant->domain);\n }", "title": "" }, { "docid": "5282948c5e76391f32393d1d5768d11b", "score": "0.6033922", "text": "public function handle()\n {\n $final = $this->option('final');\n $this->contribution($final);\n $this->preparation($final);\n }", "title": "" }, { "docid": "b67bf9b96a3286ee83b6f0c9fb412016", "score": "0.6032671", "text": "public function handle()\n {\n $indexer = new Indexer();\n $indexer->indexAllByClass($this->argument('model_class'));\n }", "title": "" }, { "docid": "9c70382d5ff812fedfa7505e147ab552", "score": "0.60301006", "text": "public function handle()\n {\n $version = $this->legendZen->welcomeCurrentVersion();\n $champions = $this->legendZen->welcomeChampions($version);\n foreach ($champions as $champion) {\n ChampionHonden::summon(\n $champion->getKey(),\n $champion->getId(),\n $champion->getName(),\n $this->welcomeIconUrl($version, $champion)\n );\n }\n }", "title": "" }, { "docid": "ea7e8c6b56348cbb21a24b3dce82b36c", "score": "0.60257083", "text": "public function handle()\n {\n if (is_null($this->argument('alias'))) {\n $this->installFromFile();\n\n return;\n }\n\n $this->install(\n $this->argument('alias'),\n $this->argument('version'),\n $this->option('type'),\n $this->option('tree')\n );\n }", "title": "" }, { "docid": "aaa3f69d666b69c514de840a87530519", "score": "0.6024917", "text": "public function handle()\n {\n $stub = $this->getCompiledStub();\n $path = base_path('app') . \"/Lingos/\";\n\n if (!is_dir($path)) {\n mkdir($path);\n }\n\n file_put_contents(\"{$path}{$this->argument('name')}Lingo.php\", $stub);\n $this->info(\"Lingo Class {$this->argument('name')} was created!\");\n }", "title": "" }, { "docid": "1dfd83fbe53456f8756ad5e52d66c3b9", "score": "0.6023792", "text": "public function handle()\n {\n $name = $this->argument('name');\n $fullPath = 'App/Repositories/';\n\n $stub = file_get_contents($this->getStub());\n\n $stub = $this->replaceNameSpace($stub, $this->getNamespace());\n\n $stub = $this->replaceClassName($stub, $name);\n\n $this->makeRepositoryFile($stub, $name, $fullPath);\n }", "title": "" }, { "docid": "c73e1c40448801d5ef6b008aa501f3fa", "score": "0.60228115", "text": "public function handle()\n {\n $user = User::find($this->argument('user'));\n\n $token = $user->createToken($this->argument('name'));\n\n $this->info($token->plainTextToken);\n }", "title": "" }, { "docid": "f326f1a8438e80680c9f94c3d078806a", "score": "0.6020729", "text": "public function handle()\n {\n $rule_id = $this->argument('ruleId');\n\n ExecuteRule::dispatch($rule_id)->onQueue('high');\n }", "title": "" }, { "docid": "ff2628d08ea62d77704a4c187865a112", "score": "0.60104275", "text": "public function handle()\n {\n $this->populateLookups();\n $this->info('Truncating gci_curations...');\n DB::table('gci_curations')->truncate();\n\n if ($this->option('include-snapshot')) {\n $this->populateFromSnapshot();\n }\n\n $this->updateFromStreamMessages();\n }", "title": "" }, { "docid": "0c5464d06f59aba1d4e90ff6d78f9af4", "score": "0.6006899", "text": "public function handle()\n {\n $this->comment('Publishing Canvas assets...');\n $this->callSilent('vendor:publish', ['--tag' => 'canvas-assets']);\n\n $this->comment('Publishing Canvas configuration...');\n $this->callSilent('vendor:publish', ['--tag' => 'canvas-config']);\n\n $this->comment('Running Canvas database migrations...');\n $this->callSilent('migrate');\n\n $this->line('');\n $this->line('Canvas is ready to use. Enjoy!');\n }", "title": "" }, { "docid": "a02c8488dc7822acec69167add1e34ce", "score": "0.60067326", "text": "public function handle()\n {\n $numberOfAccounts = $this->argument('accounts');\n\n $accounts = $this->stellarService->createAccounts($numberOfAccounts);\n\n foreach ($accounts as $account) {\n $this->stellarService->SetInflationDestination($account['publicKey'], $account['secretKey'], config('lumenaries.stellar_public_key'));\n }\n\n $this->testAccountsBatchesRepository->create(['accounts' => $accounts]);\n }", "title": "" }, { "docid": "29f5181a080cfe706a0f900ffd7d9424", "score": "0.6004796", "text": "public function handle()\n {\n // adapted from: https://github.com/zaknes/forum\n $user = User::find($this->argument('user'));\n\n if (!$user) {\n die($this->error('Invalid user ID'));\n }\n\n $role = $this->argument('role');\n\n if (!in_array($role, Config::get('enums.roles'))) {\n die($this->error('Invalid role'));\n }\n\n $user->role = $role;\n $user->update();\n\n $this->info('User ' . $user->id . ' has been updated to ' . $role);\n\n }", "title": "" }, { "docid": "d763cea0783eeb32f4c3244399fe29fc", "score": "0.6001113", "text": "public function handle()\n {\n // uptime\n $uptime = $this->getUptime();\n dump($uptime->toArray());\n }", "title": "" }, { "docid": "930df7e66c5de7a7a3569a1305cb8910", "score": "0.5994363", "text": "public function handle()\n {\n $config = $this->argument('config');\n\n if (! config()->has($config)) {\n $this->components->error(\"Configuration file `{$config}` does not exist.\");\n\n return Command::FAILURE;\n }\n\n $this->newLine();\n $this->render($config);\n $this->newLine();\n\n return Command::SUCCESS;\n }", "title": "" }, { "docid": "174eca04da276585eae04f9f9d8a1a33", "score": "0.5993604", "text": "public function handle()\n {\n $media = $this->instagram->media($this->argument('name'));\n $this->comment($this->instagram->store( $media, $this->argument('name') ));\n }", "title": "" }, { "docid": "064db6e5398d341f259456847764edfb", "score": "0.5993041", "text": "public function handle()\n {\n if ($this->argument('tenant')) {\n $this->migrate(\n Tenant::find($this->argument('tenant'))\n );\n\n } else {\n Tenant::all()->each(\n fn($tenant) => $this->migrate($tenant)\n );\n }\n }", "title": "" }, { "docid": "4cb5190c7ef134ed018cc813614d2d4e", "score": "0.5987503", "text": "public function handle(Command $command);", "title": "" }, { "docid": "37fe7e1db392aa17acc2c81faa461c23", "score": "0.597955", "text": "public function handle()\n {\n $tasks = $this->repository->all();\n\n if ($tasks->isEmpty()) {\n $this->error('No scheduled tasks found');\n exit;\n }\n\n $this->generateTable($tasks);\n }", "title": "" }, { "docid": "217b78a0c1c72a1eec4266c7fc5834b6", "score": "0.5978294", "text": "public function handle()\n {\n // Configuration...\n $this->callSilent('vendor:publish', ['--tag' => 'model-status-config']);\n\n $this->info('Model Status resources published.');\n }", "title": "" }, { "docid": "143301457b6a66d480a2fa00dc27c4f0", "score": "0.5977097", "text": "public function handle()\n { \n $this->callSilent('view:clear'); \n \n $this->callSilent('route:cache');\n \n $this->callSilent('route:clear');\n\n echo \"#### Executing Integration Test Cases ####\";\n echo \"\".shell_exec('php ./vendor/phpunit/phpunit/phpunit ./tests/Feature 2>&1');\n \n echo \"#### Executing Unit Test Cases ####\";\n echo \"\".shell_exec('php ./vendor/phpunit/phpunit/phpunit ./tests/Unit 2>&1');\n \n $this->callSilent('l5-swagger:generate');\n }", "title": "" }, { "docid": "35aa8f2d1fccba31a287b70641e9c34e", "score": "0.5971585", "text": "public function handle()\n {\n $locale = $this->argument('locale');\n\n // Doesn't create file if it exists and no --force option is set\n if ($this->filesystem->exists($this->getPath($locale)) && !$this->option('force')) {\n $this->info('File already exists. Use --force option to replace it');\n return;\n }\n\n // Create file\n $this->updateFile($this->getStringsEmpty(), $locale);\n $this->info('File successfully created');\n }", "title": "" }, { "docid": "55e97115ea68958626e075b5c26fa8ef", "score": "0.5971477", "text": "public function handle()\n {\n // Gathers all parameters\n $this->gatherParameters();\n\n // Generates the migration Class File\n $this->generateMigrationFile();\n\n }", "title": "" }, { "docid": "bdb3e5d2e8d7774a9d7767d6c6ab846e", "score": "0.59711695", "text": "public function handle()\n {\n Storage::put('forge-api-token.txt', $this->argument('token'));\n $this->info('API token stored successfully.');\n }", "title": "" }, { "docid": "ca413a9fcd69130999b09559131820e6", "score": "0.5962489", "text": "public function handle()\n {\n $args = $this->arguments();\n $model = $args['model'];\n $result = $model::first();\n foreach($result as $row) {\n var_dump($row);\n foreach($row as $k => $v) {\n var_dump($v);\n $this->info = \"\\t{$k};\\n\";\n }\n exit;\n }\n }", "title": "" }, { "docid": "41b5ac978b1802ca6fa12505757eae87", "score": "0.5960907", "text": "public function handle()\n {\n $this->email = $this->argument('email');\n $this->user = User::where(compact('email'))->first();\n\n $this->exitIfUserNotFound($this->getUser(), $this->getEmail());\n\n $this->confirm('Are you sure you wish to disable this user?') ?\n $this->disableUser($this->getUser(), $this->getEmail()) :\n $this->info(\"User '$this->email' has not been disabled.\");\n }", "title": "" }, { "docid": "80b99008227f7a3a341a239124949b6e", "score": "0.59583336", "text": "public function handle()\n {\n $details = $this->getDetails();\n $admin = $this->user->createUser($details);\n $this->display($admin);\n }", "title": "" }, { "docid": "c291cd6d6b19443684615ada46f985ad", "score": "0.5958291", "text": "public function handle()\n {\n // Publish...\n $this->callSilent('vendor:publish', ['--tag' => 'trs-admin-config', '--force' => true]);\n\n if (! in_array($this->argument('stack'), ['bootstrap', 'tailwind'])) {\n throw new InvalidArgumentException('Invalid stack.');\n }\n\n $this->{$this->argument('stack')}();\n\n $this->line('');\n $this->info('TRS Admin resources installed successfully.');\n $this->comment('Please execute \"npm install && npm run dev\" to build your assets.');\n }", "title": "" }, { "docid": "bb506ebc61b84059e595a98999ee4c05", "score": "0.5957528", "text": "public function handle()\n {\n $this->info(\"Listing all tenants.\");\n tenancy()->all()->each(function ($tenant) {\n $this->line(\"[Tenant] uuid: {$tenant['uuid']} @ {$tenant['domain']}\");\n });\n }", "title": "" }, { "docid": "73cd40977344374cafcbbb0d5bf32a35", "score": "0.5957361", "text": "public function handle()\n {\n $this->populateDailyPredictionRandomCommand->execute((int) $this->argument('count'));\n }", "title": "" }, { "docid": "244018e7788da892dbe4f35df55daf55", "score": "0.59546536", "text": "public function handle()\n {\n $users_of_providers_id = 8;\n $alarm_clock_prototype_id = 1;\n (new Vadim())->attachAlarmsToUserProvider($users_of_providers_id, $alarm_clock_prototype_id);\n }", "title": "" }, { "docid": "a93c97ecdb5d94a70b6503c1dad5929f", "score": "0.5952017", "text": "public function handle()\n {\n $this->getArguments();\n\n $policy_dirpath = base_path($this->app->singular_snake.'/Policies');\n if (!file_exists($policy_dirpath)) {\n mkdir($policy_dirpath, 0775, true); \n }\n\n $policy_filepath = $policy_dirpath.'/'.$this->model->singular_camel.'Policy.php';\n if (file_exists($policy_filepath)) {\n $this->comment(\"[Warning]{$policy_filepath} file is already exists...skip\");\n } else {\n $contents = $this->compileStub(__DIR__.'/stubs/policies/ModelPolicy.stub');\n Stub::copy($policy_filepath, $contents); \n }\n }", "title": "" }, { "docid": "33af1d82b4c9607f33f3670ba8cec3ca", "score": "0.5950132", "text": "public function handle()\r\n {\r\n if ($this->checkForUpdates()) {\r\n $this->download();\r\n } else {\r\n $this->info('No updates available.');\r\n }\r\n }", "title": "" }, { "docid": "967be662d370f9efc9da35d59df5ed8f", "score": "0.59486276", "text": "public function handle()\n {\n $this->info('*** Task running [Calc Members] ***');\n\n $task = new TaskController;\n $task->calcMembers();\n\n $this->info('*** Task finished [Calc Members] ***');\n }", "title": "" }, { "docid": "0e6c686c4071548a6ad8cbd7ab321509", "score": "0.59484863", "text": "public function handle()\n {\n /*\n Go through all users and add an energy to them, up to the cap of 100\n\n */\n\n $characters = Character::all();\n\n $bar = $this->output->createProgressBar(count($characters));\n\n foreach($characters as $character) {\n\n if($character->energy < 100) {\n $character->energy++;\n\n $character->save();\n }\n\n $bar->advance();\n }\n\n $bar->finish();\n }", "title": "" }, { "docid": "32e4c58038e827c5a1c57a5f510e3ba2", "score": "0.59483516", "text": "public function fire()\n {\n // Setup game\n $this->setUpGame([\n 'rows' => $this->argument('rows'),\n 'columns' => $this->argument('columns')\n ]);\n\n // Initalise game\n $this->initGame();\n }", "title": "" }, { "docid": "43651cce728b4cc41dbbd467a6589246", "score": "0.59458333", "text": "public function handle()\n {\n $models = config('deeplable.translated_models');\n\n foreach ($models as $model) {\n $instance = new $model;\n\n $all = $instance->get();\n\n $this->translateCollection($all);\n }\n }", "title": "" }, { "docid": "317995cb2384b59cb43a8746e7878a1c", "score": "0.594544", "text": "public function handle()\n {\n $this->type = $this->argument('type');\n $this->clear = $this->option('clear');\n\n if($this->clear) {\n $this->clear();\n }\n }", "title": "" }, { "docid": "099ec8faf81813e4a001b11e2656c88d", "score": "0.5944371", "text": "public function handle()\n {\n $dataset = json_decode(file_get_contents(storage_path($this->argument('file'))), true);\n\n $attack = collect($dataset)\n ->mapInto(Pokemon::class)\n ->filter->isType('fire')\n ->map(function (Pokemon $pokemon) {\n return $pokemon->abilities->attack;\n })\n ->max();\n\n $this->info(sprintf('The highest attack of pokemons of type fire is %s', $attack));\n }", "title": "" }, { "docid": "fa576ea87517cb17b88f653481b1ec40", "score": "0.59440565", "text": "public function handle()\n {\n $email = $this->argument('user_email');\n\n $user = User::where('email', '=', $email)->first();\n\n if (!$user) {\n $this->error('Undefied user with email ' . $email);\n\n return false;\n }\n\n if ($user->email_verified_at == null && $user->status == User::STATUS_VERIFY_WAIT) {\n\n $user->update([\n 'email_verified_at' => now(),\n 'status' => User::STATUS_VERIFY_ACTIVE,\n ]);\n\n $this->info(\n 'User name: ' . $user->name .\n ' email: ' . $user->email .\n '- Email successfully verified'\n );\n } else {\n\n $this->error('User already verified');\n }\n\n }", "title": "" }, { "docid": "cc3a156a8771e40789395bf9ec895d72", "score": "0.59431505", "text": "public function handle()\n {\n ini_set(\"memory_limit\", \"4096M\");\n $dataset = Dataset::findOrFail($this->argument('datasetId'));\n\n if ($this->option('create-dataset-files-table')) {\n (new CreateDatasetFilesTableAction())->execute($dataset);\n }\n\n $createDatasetInGlobusAction = new CreateDatasetInGlobusAction();\n $createDatasetInGlobusAction($dataset);\n }", "title": "" }, { "docid": "612dc0465a227a2c973ac8fefd29f1a6", "score": "0.594295", "text": "public function handle()\n {\n $name = $this->argument('name');\n $cmt = $this->argument('description');\n\n $role = new AclRole();\n $role->name = $name;\n $role->comment = $cmt;\n $role->save();\n\n $this->info('saved: ' . $role->id);\n }", "title": "" }, { "docid": "9d090b8e25c63a02b239ce6693a3498c", "score": "0.59389037", "text": "public function handle()\n {\n // command variables\n $date = date('Y-m-d', strtotime((!is_null($this->option('date'))) ? $this->option('date') : \"now\"));\n\n $this->info('Running... command:UpdateUserSubscriptionPlan for '.$date);\n Log::info('Running... command:UpdateUserSubscriptionPlan for '.$date);\n\n $subscriptions = Subscription::where('start_date', $date)->where('status', 'Upcoming')->get();\n foreach($subscriptions as $subs) {\n $role = Role::findOrFail($subs->role_id);\n\n $user = User::find($subs->user_id);\n $user->category = $role->name;\n $user->subscription_id = $subs->id;\n $user->detachAllRoles();\n $user->attachRole($role->id);\n $user->save();\n\n $subs->status = 'Active';\n $subs->save();\n\n Subscription::where('user_id', $subs->user_id)->where('start_date', '<', $subs->start_date)->update([\n 'status' => 'Expired'\n ]);\n }\n }", "title": "" }, { "docid": "b5adc710a4a0ab2bd58b3dbaea99574d", "score": "0.59380263", "text": "public function handle()\n {\n $name = $this->argument('name');\n $this->model($name);\n $this->controller($name);\n $this->call('make:observer $name');\n return 1;\n }", "title": "" }, { "docid": "9c242984f1a5f00d3169632c180c76ff", "score": "0.5937122", "text": "public function handle()\n {\n $this->processOptions();\n $this->publishSidebarView();\n }", "title": "" }, { "docid": "e46b5fc01c2d1286bbf62528d3915d28", "score": "0.5936606", "text": "public function handle()\n {\n // get the admin role\n $admin_role = Role::where('name', '=', 'admin')->first();\n\n // get the data\n $data = $this->arguments();\n unset($data['command']);\n $data['password'] = Hash::make($this->argument('password'));\n\n // check if the user already exists\n if (User::where('email', $data['email'])->first()) {\n $this->error(\"Email '\" . $data['email'] . \"' already used for user '\" . $data['name'] . \"'\");\n } else {\n // try to create the user\n try{\n $user = User::firstOrNew($data);\n $user->role()->associate($admin_role);\n $user->save();\n } catch (Exception $e) {\n $this->comment('Error occurred while creating a new admin user: ' . $e->getMessage());\n }\n\n $this->comment(\"User '\" . $data['name'] . \"' created.\");\n }\n\n }", "title": "" }, { "docid": "56ad423bab463d5d4d7b35564282e18e", "score": "0.59354836", "text": "public function handle()\n {\n $currencyModel = new Currency();\n\n $data = $currencyModel->getAvailableCurrencies();\n\n foreach ($data as $item) {\n $item = $item->getAttributes();\n\n $this->getCurrencyByName($item['name']);\n }\n }", "title": "" } ]
a6d28bcfc1f5f0e5997ec3c010217bbe
Update the specified resource in storage.
[ { "docid": "d3175ffb79c2165b3c36051acad5bdfd", "score": "0.0", "text": "public function update($id)\n {\n //\n }", "title": "" } ]
[ { "docid": "3e3a565a181db6f795f079d1dfb01f75", "score": "0.7099585", "text": "public function update(Resource $resource, $id)\n {\n //\n }", "title": "" }, { "docid": "bde449baf550552e043ec18452e05f5c", "score": "0.69665116", "text": "function update($resource, $content)\n {\n }", "title": "" }, { "docid": "23bd42dc38bca65e850c1b8f771c0f0f", "score": "0.6837518", "text": "public function update(ResourceInterface $resource)\n {\n $this->_em->flush($resource);\n }", "title": "" }, { "docid": "fb65b4f4d55e024e7f1613af273a55f2", "score": "0.6775597", "text": "public function update(Request $request, Resource $resource)\n {\n //Validate request\n $this->validate($request, [\n 'name' => 'required|max:255',\n 'url' => 'required|max:255',\n 'description' => 'required|max:10000',\n 'tags.*' => 'exists:tags,id',\n 'is_published' => 'required|boolean'\n ]);\n $resource_previous_unpublished = !$resource->is_published;\n //Create the resource\n $resource->update([\n 'name' => $request->name,\n 'url' => $request->url,\n 'description' => $request->description,\n 'is_published' => $request->is_published\n ]);\n //Drop the tags from the pivot table. Add the updated ones\n $resource->tags()->detach();\n //Add the tags for this resource to the pivot table\n $resource->tags()->attach($request->tags);\n $responseText = 'Resource updated';\n $responseText .= $resource_previous_unpublished && $request->is_published ? ' and published' : '';\n //Take them back to the resource form so they can add more resources\n return back()->with('success', $responseText);\n }", "title": "" }, { "docid": "61a34fcd66242862e9a967402e4ff514", "score": "0.6267246", "text": "private function updateResource($resource, $inputs )\n {\n \n // if(isset($inputs['category_id'])){\n // $model->categories()->sync($inputs['category_id']);\n // } else {\n // $model->categories()->sync([]);\n // }\n return $resource->update($inputs);\n\n }", "title": "" }, { "docid": "a4a8c199770b8cc35d56a67cd9297225", "score": "0.62659985", "text": "public function update($storageName, $key, array $data);", "title": "" }, { "docid": "4c22c400891589f8da5573f60cdc4ea0", "score": "0.61376035", "text": "public function update(Request $request, Resource $resource)\n {\n $validator = Validator::make($request->all(),[\n 'wbs' => 'required',\n 'tipo_recurso' => 'required',\n 'cantidad' => 'required',\n 'comentarios' => 'required',\n 'vision_estrategica' => 'required'\n\n ]);\n if ($validator->fails()) {\n return response()->json(['Error'],404);\n\n }else{\n $resource->wbs = $request->wbs;\n $resource->tipo_recurso = $request->tipo_recurso;\n $resource->cantidad = $request->cantidad;\n $resource->comentarios = $request->comentarios;\n $resource->vision_estrategica = $request->vision_estrategica;\n \n $resource->save();\n return response()->json($resource);\n }\n }", "title": "" }, { "docid": "cb421444658bf63523d9239cfdb2c091", "score": "0.6102644", "text": "public function update(StorageRequest $request, $id)\n {\n try {\n $this->service->updateStorage($request, $id);\n return $this->NoContent();\n } catch(EntityNotFoundException $e) {\n \\Log::error($e->getMessage());\n return $this->NotFound($e->getMessage());\n } catch(\\QueryException $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n } catch(Exception $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n }\n }", "title": "" }, { "docid": "40c721acddd9f92cbdc47e322ae39955", "score": "0.60837495", "text": "public function update(Request $request, $id)\n {\n // dd($request->all());\n if($storage = Storage::find($id))\n {\n if( $storage->update( $request->all() ) )\n {\n if($request->storage_items)\n $storage->item()->sync($request->storage_items);\n else\n $storage->item()->sync([]);\n return redirect()->back();\n }\n }\n return redirect()->back();\n }", "title": "" }, { "docid": "fae18446ab6ba766002815d7efd6d0f2", "score": "0.60153604", "text": "public function updateStream($resource)\n {\n return $this->filesystem->updateStream($this->path, $resource);\n }", "title": "" }, { "docid": "1b397375316ae1351b5a50f45f20bc46", "score": "0.6000568", "text": "public function update(Request $request, $id)\n {\n if($request->session()->exists('resources')){\n $resources = $request->session()->get('resources');\n $idInput = $request->input('id');\n $nameInput = $request->input('name');\n $priceInput = $request->input('price');\n \n if(isset($resources[$id]) && (isset($resources[$idInput])==false || $idInput==$id)){\n // $resource = $resources[$id];\n $resource = ['id' => $idInput, 'name' => $nameInput, 'price' => $priceInput];\n unset($resources[$id]);\n $resources[$idInput]=$resource;\n $request->session()->put('resources', $resources);\n \n return redirect('resource')->with('message', 'Se editado el elemento correctamente');\n }\n \n }\n return back()->withInput();\n }", "title": "" }, { "docid": "1342fca6bb741918e9de91960e422b72", "score": "0.59302443", "text": "public function dispatchOnPostUpdateResource($resource);", "title": "" }, { "docid": "4c33901004c334e4edd8b45955f45ed2", "score": "0.5906145", "text": "public function sliderUpdate(SliderUpdateRequest $request, $id)\n {\n\n $slider=Slider::find($id);\n /* dd($service); */\n $input= $request->all();\n\n if($request->hasFile('image')) {\n if($request->image==$slider->image){\n $input['image']=$slider->image;\n }else{\n $fileName=$request->file('image')->store('slider','public');\n\n $input['image'] =$fileName;\n \n @unlink('storage/'.$slider->image);\n }\n } else {\n\n $input['image']=$slider->image;\n\n }\n $slider->update([\n 'title'=>$request->title,\n 'image'=>$input['image'],\n ]);\n /* dd($service); */\n\n return new SliderResource($slider);\n }", "title": "" }, { "docid": "9645d8e1c1b4d32587e5589c88868755", "score": "0.5878462", "text": "public function update(Request $request, $id)\n {\n $resource = Resource::find($id);\n $resource->fill($request->all());\n $resource->save();\n\n $resource->tags()->sync($request->tags);\n\n $message = 'El recurso literario \"' . $resource->title . '\" fue modificado.';\n $class = 'warning';\n\n Session::flash('message', $message);\n Session::flash('class', $class);\n\n return redirect()->route('admin.resources.index');\n }", "title": "" }, { "docid": "70f839d67344487e3780c8ca780ec59c", "score": "0.5876995", "text": "public function store(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "cc850ce20ed7c56b132541ba822c9777", "score": "0.5832923", "text": "public function update(Request $request, $id)\n {\n //\n $data = $request->all();\n $request->validate([\n 'title' => 'required|max:255',\n 'description' => 'required',\n 'resource' => 'file|mimes:pdf,doc,docx,xls,xlm,xla,xlc,xlt,xlw,ppt,pps,pot'\n ]);\n\n $eLibrary = ELibrary::findOrFail($id);\n\n /*Photo*/\n if($request->hasFile('resource') && $request->file('resource')->isValid()){\n $file = $request->file('resource');\n $filename = $data['title'] . '_' . time().'.'.$file->extension();\n $path = $file->storePubliclyAs('public/uploads/eLibrary',$filename);\n if($eLibrary->path) {\n if (Storage::exists($eLibrary->path)) Storage::delete($eLibrary->path);\n }\n $data['path'] = $path;\n }\n if($eLibrary->update($data)){\n Session::flash('alert-success',\"The E-Library resource '$eLibrary->title' has been updated\");\n }else{\n Session::flash('alert-danger',\"The E-Library resource '$eLibrary->title' could not be updated. Please contact support.\");\n }\n return redirect('admin/eLibrary');\n }", "title": "" }, { "docid": "3ebf4ac6712058cf5111ea2fb1b3f69d", "score": "0.5789821", "text": "public function updateStream($path, $resource, Config $config)\n {\n $this->delete($path);\n\n return $this->writeStream($path, $resource, $config);\n }", "title": "" }, { "docid": "3ec7c5a8877f8c46b7760a665414271c", "score": "0.5738682", "text": "public function update(Request $request, int $id)\n {\n $data = $request->except(\"image\");\n $product = $this->product->findOrFail($id);\n if($request->hasFile(\"image\") && $request->image->isValid()){\n Storage::delete($product->image);\n $data[\"image\"] = $request->image->store(\"products/\".$request->name);\n }\n $product->update($data);\n return redirect()->route(\"products.index\");\n }", "title": "" }, { "docid": "7fa7323735ca22c15cfa4866e023dcb7", "score": "0.57337505", "text": "public function setResource($resource);", "title": "" }, { "docid": "1a87e148e066a4886de60512f8e08a52", "score": "0.57288736", "text": "public function update(ShareRequest $request, $id)\n {\n $share = Share::find($id);\n $share->share_name = $request->get('share_name');\n $share->share_price = $request->get('share_price');\n $share->share_qty = $request->get('share_qty');\n $share->save();\n if ($share->image) {\n unlink(public_path('storage/') . $share->image);\n }\n $this->storeImage($share);\n return redirect('/shares')->with('success', 'Stock has been updated');\n }", "title": "" }, { "docid": "e298ed6e92031fa9134c5a6ed2507d24", "score": "0.5691853", "text": "public function update($object);", "title": "" }, { "docid": "e298ed6e92031fa9134c5a6ed2507d24", "score": "0.5691853", "text": "public function update($object);", "title": "" }, { "docid": "d55f58a252de4e09d616136ab381ea2d", "score": "0.5689798", "text": "public function update(Request $request, $id)\n {\n $request->validate([\n 'group_id'=>'exists:groups,id|integer',\n 'name'=>'required|min:1|max:16|unique:resources,name,'.$id,\n 'description'=> 'max:255'\n ]);\n\n $resource = Resource::find($id);\n $resource->group_id = $request->get('group_id');\n $resource->name = $request->get('name');\n $resource->description = $request->get('description');\n $resource->save();\n\n return redirect('/resources')->with('success', 'Resource has been updated');\n }", "title": "" }, { "docid": "09f959fbad30c2f941ea086cc7dad93f", "score": "0.56853646", "text": "public function update(ProductUpdateRequest $request, $id)\n {\n $product = Product::find($id);\n $product->fill($request->all())->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 return redirect()->route('products.edit', \n $product->id)->with('info', 'Info de product actualizada con éxito');\n }", "title": "" }, { "docid": "e6fb42d6286b3f4fe6f14fab49db4173", "score": "0.56730545", "text": "public function update(Request $request, $id)\n {\n if($request->has('new_image')) {\n\n $product = Product::where('id',$id)->first(); \n\n $old_image = $product->image;\n unlink($old_image);\n\n\n $file = $request->file('new_image');\n $name = Str::random(10);\n $url = \\Storage::putFileAs('images',$file, $name . '.' .$file->extension());\n\n $data = array();\n $data['name'] = $request->name;\n $data['price'] = $request->price;\n $data['image'] = $url;\n\n $update = DB::table('products')->where('id',$id)->update($data);\n\n\n\n } else {\n $product = Product::find($id);\n $product->update($request->only('name','price'));\n }\n\n return redirect()->back()->with(\"status\",\"Successfully Updated\");\n\n\n\n }", "title": "" }, { "docid": "97e4ce8ade6b1dc2b2b25f72334eb18d", "score": "0.5636433", "text": "public function dispatchOnPreUpdateResource($resource);", "title": "" }, { "docid": "bba4992ee37e44374ffa661fa659a09a", "score": "0.56323135", "text": "public function update (EntityInterface $entity);", "title": "" }, { "docid": "318b6ff187eaf08454a3d0857e9aca4d", "score": "0.56295455", "text": "public function updateStream($path, $resource, array $config)\r\n\t{\r\n\t\t$res = $this->cloudDrive->uploadStream($resource, $path, true);\r\n\r\n\t\treturn $res['success'];\r\n\t}", "title": "" }, { "docid": "072d1df8727e8fc01d135f9b601cd0cc", "score": "0.5626336", "text": "public function update(Request $request, int $resource_id)\n {\n $data = $request->all();\n $validatedData = $request->validate([\n \"name\" => \"required\"\n ]);\n $store = self::store($data, $resource_id);\n return response()->json(['status'=> 'ok', 'data'=> $store, 'msg'=> 'listing category updated successfully']);\n }", "title": "" }, { "docid": "8576d995f0ad5fb05e24f4249f91de06", "score": "0.56251395", "text": "public function update() {\n $this->save();\n }", "title": "" }, { "docid": "fef6f84766f65b55a5b2d09f06bbe894", "score": "0.56153053", "text": "public function update(model $acl_resource, array $info) {\n\n // Update record\n return parent::_update($acl_resource, $info);\n }", "title": "" }, { "docid": "ced4b17a4ea0a670f0d46db8e5a71e1f", "score": "0.5600381", "text": "function setResource($resource);", "title": "" }, { "docid": "a67ff3295306d457a45d5bfd402b9bbf", "score": "0.55851954", "text": "public function update(Request $request, $id)\n {\n $result=Slider::find($id);\n\n $result->name=$request->name;\n $result->desc=$request->desc;\n $result->price=$request->price;\n\n if ($request->hasFile('img')) {\n $file=$request->img->store('upload', 'public');\n $result->img=$file;\n }else{\n $errors=\"File not set\";\n return redirect()->back()\n ->withInput($request->input())\n ->with(\"msgError\", $errors);\n }\n\n $result->save();\n\n if ($result) {\n return redirect('show/slider')->with('message', 'Product updated successfully!');\n }\n else{\n return redirect()->back()->withInput($request->input())\n ->with('msgError', 'Record do not update in database!');\n }\n\n }", "title": "" }, { "docid": "4016847dea9b55e59a4acd18600a30f5", "score": "0.55813426", "text": "public function update($request, $id);", "title": "" }, { "docid": "4016847dea9b55e59a4acd18600a30f5", "score": "0.55813426", "text": "public function update($request, $id);", "title": "" }, { "docid": "aeb943a599e58a4bbe6bd7e228755660", "score": "0.55803686", "text": "public function update(Request $request, $id)\n {\n $this->validate($request,\n [\n 'title'=>'required|max:50',\n 'price'=>'required',\n 'description'=>'required|max:100'\n ,\n 'imagePath'=>'required'\n ],[\n 'required'=>'El campo :attribute es obligatorio'\n ]\n );\n $product=Product::find($id);\n $product->title = $request->input('title');\n $product->price = $request->input('price');\n $product->description = $request->input('description');\n // $product->imagePath = $request->input('imagePath');\n\n $nombreImagen = str_slug($product->title) . '.' .request()->imagePath->extension();\n // storeAs recibe dos parametros el nombre de la carpeta y el nombre del archivo\n request()->imagePath->storeAs('public', $nombreImagen);\n $product->imagePath = $nombreImagen;\n \n $product->save();\n\n return redirect()->action('Admin\\ProductsController@index');\n\n }", "title": "" }, { "docid": "b9d5c9b5a3c8b34eb93904bd4bc5dfc1", "score": "0.55740935", "text": "public function update($id, StoreSliderRequest $request)\n {\n $slider = Slider::find($id);\n $input = $request->all();\n $slider->fill($input);\n\n if(Input::file('image')){\n $file = Input::file('image');\n $filename = time().'-'.$file->getClientOriginalName();\n $directory = $slider->getPath();\n $file->move($directory, $filename);\n $slider->image = $directory.$filename;\n #ImageCompress::tinifyImage($slider->image);\n }\n\n $slider->save();\n\n return redirect()->route('admin.slider.index');\n }", "title": "" }, { "docid": "6ec0972709d8081c8584eadfdebd73e3", "score": "0.55724585", "text": "public function put($resource, array $args = [], array $options = []) {\n return $this->do('PUT', $resource, $args, $options);\n }", "title": "" }, { "docid": "720aa13d6dd5abab4700c72fc5726f2f", "score": "0.55704945", "text": "public function update(Request $request, $id)\n {\n //\n $product = Product::findOrFail($id);\n\n $product->product_name = $request->product_name;\n $product->product_description = $request->product_description;\n $product->product_price = $request->product_price;\n $product->condition = $request->condition;\n $product->brand_id = $request->brand_id;\n $product->state_id = $request->state_id;\n $product->area_id = $request->area_id;\n // $product->category_id = $request->category_id;\n $product->subcategory_id = $request->subcategory_id;\n\n if ($request->hasFile('product_image')) {\n\n $path = $request->product_image->store('public/uploads');\n\n $product->product_image = $request->product_image->hashNAme();\n\n }\n\n $product->save();\n\n Alert::success('Product succesfully updated!')->autoclose(4000);\n\n // flash('Product succesfully updated')->overlay();\n\n return redirect()->route('admin.products.index');\n\n\n\n }", "title": "" }, { "docid": "e186357e6cd112ce0670460eed4e4946", "score": "0.55632365", "text": "public function update(UploadImageRequest $request, $id)\n {\n //\n $product = Product::findOrFail($id);\n if ($request->hasFile('image')) {\n $filename = $request->file('image')->getClientOriginalName();\n $type = $request->file('image')->getClientOriginalExtension();\n $url = 'products/images/' . $product->id . '/' . $filename;\n\n $image = Image::make($request->file('image'))->resize(150, 150)->encode($type);\n Storage::disk('s3')->put($url, (string)$image, 'public');\n\n $product->update([\n 'image' => $url,\n ]);\n }\n $product->update([\n 'name' => $request->name,\n 'cost' => $request->cost,\n 'category_id' => $request->category,\n 'description' => $request->description,\n 'quantity' => $request->quantity,\n ]);\n $product->save();\n return redirect()->route('admin.product-administration.show', $product->id);\n }", "title": "" }, { "docid": "0af57b3d439623d9ddfbbd2c23e24b1f", "score": "0.55599797", "text": "public function update($id, $data);", "title": "" }, { "docid": "392bdf3b4d83d7a822d671646207f552", "score": "0.55553967", "text": "public function update($request, int $id);", "title": "" }, { "docid": "39ec1d6074d8d2034e596ad13d30da68", "score": "0.55506486", "text": "public function update(Request $request, $id)\n {\n $request->validate([\n 'name' => 'required',\n 'description' => 'required',\n 'price' => 'required|min:1',\n 'image' => 'image|mimes:jpeg,png,jpg,gif,svg|max:2048',\n 'quantity' => 'required|min:1',\n ]);\n\n $product = Product::find($id);\n $product->store_id = Auth::guard('store')->user()->id;\n $product->product_name = $request->get('name');\n $product->product_description = $request->get('description');\n $product->product_price = $request->get('price');\n $product->product_quantity = $request->get('quantity');\n $current_image = $product->product_image;\n $new_image = \"\";\n\n if ($request->has('subcategory')) {\n $product->subcategory_id = $request->get('subcategory');\n }\n if ($request->has('parameter')) {\n $product->product_parameter_id = $request->get('parameter');\n }\n if ($request->has('image')) {\n $new_image = $request->file('image');\n $extension = $new_image->getClientOriginalExtension();\n $filename = 'product-' . time() . '.' . $extension;\n $product->product_image = $filename;\n $new_image->storeAs('products', $filename, 'public');\n }\n $product->save();\n if (Storage::disk('public')->exists('products/' . $new_image)) {\n Storage::disk('public')->delete('products/' . $current_image);\n }\n return redirect()->route('products.index')->with('success', 'Product updated');\n }", "title": "" }, { "docid": "c6efa075535fbc725da4b180e4ec737b", "score": "0.55501103", "text": "public function update(Request $request, $id)\n {\n if ( Auth::user()->userrole != \"Admin\") {\n return abort(401, 'Access Denied');\n }\n\n $article = Product::where('id',$id)->first(); \n $article->name = request('name');\n $article->sub_title = request('sub_title');\n $article->title = request('title');\n $article->title1 = request('title1');\n $article->title2 = request('title2');\n $article->title3 = request('title3');\n $article->content1 = request('content1');\n $article->content2 = request('content2');\n $article->content3 = request('content3');\n $article->button_text = request('button_text');\n $article->button_link = request('button_link');\n $article->description = request('description');\n $article->slug = Str::slug(request('title'), '-'); \n $article->active = request('active');\n\n // Store uploaded file...\n if($request->hasFile('image')) { \n $file = $request->file('image'); \n $imageName = time().'-'.$file->getClientOriginalName();\n $request->image->storeAs('public/products', $imageName); \n $article->image = $imageName; \n }\n\n $article->save(); \n\n return redirect()->route('admin.product.index');\n }", "title": "" }, { "docid": "8333f02674e0537622e556ed30714d92", "score": "0.5541451", "text": "protected function put()\n {\n \\throw_if(!$this->request->isJson(), new RestfulException(RestfulErrorMessage::InvalidJsonHeader));\n if ($this->restfulRequest->resourceId) {\n $document = null;\n try {\n $document = $this->_get();\n } catch (\\Exception $e) {\n // ...\n }\n return \\response(\n $this->_repository->replace($document, $this->restfulRequest->resourceId, $this->request->json()->all())\n );\n }\n if ($this->payloadIsAttributeSet()) {\n return \\response(\n $this->_repository->batchReplace($this->getFindOption(), $this->request->json()->all())\n );\n }\n throw new RestfulException(RestfulErrorMessage::InvalidRequestPayload);\n }", "title": "" }, { "docid": "a4b00c57c46ebcebca149c23c5beb30a", "score": "0.55269605", "text": "public function update(Request $request, $id)\n {\n $item = Items::find($id);\n $item->fill($request->all());\n\n// if (Input::file()) {\n// $filename = $request->file('image')->store('public');\n// $path = substr($filename, 7);\n// $item->image = $path;\n// }\n\n $item->update();\n return redirect()->route('items.index');\n }", "title": "" }, { "docid": "2d0234add8ac70bdf3ff13a1dc54eddc", "score": "0.5521795", "text": "public function updateStockAction()\n {\n $this->checkAdmin();\n $inStockid = intval($this->route['id']);\n $quantity = intval($this->route['amount']);\n if ($quantity == 0)\n $this->model->deleteStockById($inStockid);\n else\n $this->model->updateStockById($inStockid, $quantity);\n }", "title": "" }, { "docid": "21ec885e595c2bf310bc026dbe22811d", "score": "0.5520187", "text": "public function update(Request $request, $id)\n {\n\n\n $contents = $request->data;\n\n if ($id === 'options') {\n\n Storage::put('options.json', json_encode($contents));\n\n }\n\n if ($id === 'templates') {\n\n Storage::put('templates.json', json_encode($contents));\n\n }\n\n if ($id === 'documentation') {\n\n Storage::put('documentation.json', json_encode($contents));\n\n }\n\n\n return response('', 200);\n }", "title": "" }, { "docid": "550e477a9a956b28304b535c2916ad5c", "score": "0.55201524", "text": "public function update(Request $request, $id)\n {\n $this->validate($request, [\n \"title\" => 'required',\n \"product_id\" => 'sometimes',\n \"button_text\" => 'sometimes',\n \"button_link\" => 'sometimes',\n \"priority\" => 'required',\n \"image\" => 'sometimes|file|image|max:3000',\n ]);\n $slider = Slider::find($id);\n $slider->title = $request->title;\n $slider->product_id = $request->product_id;\n $slider->button_text = $request->button_text;\n $slider->button_link = $request->button_link;\n $slider->priority = $request->priority;\n\n if (request()->hasFile('image')) {\n if (File::exists('storage/' . $slider->image)) {\n File::delete('storage/' . $slider->image);\n }\n\n $path = $request->file('image')->store('sliders', 'public');\n $slider->image = $path;\n }\n $slider->save();\n $sliders = Slider::all();\n session()->flash('flash_message_success', 'You have updated a slider successfully!');\n return redirect()->route('admin.sliders')\n ->with(compact('sliders'));\n\n }", "title": "" }, { "docid": "a66a502d0331860b0492d8521d8dc6fc", "score": "0.551738", "text": "public function update(Request $request, $id)\n {\n $slider = Slider::find($id);\n $data = $request->all();\n if ($request->hasFile('imagen')) {\n $data['imagen'] = $request->file('imagen')->store('slides','public');\n\n $exists = Storage::disk('sliders')->exists($slider->solo_imagen);\n if($exists)\n Storage::delete(\"/public/$slider->imagen\");\n\n }\n $slider->fill($data);\n $slider->save();\n return redirect()->route('admin.slider.index');\n\n }", "title": "" }, { "docid": "59cc7aa6a27c614e6dbea168303030cb", "score": "0.5510812", "text": "public function update(Request $request, Memory $memory)\n {\n //\n }", "title": "" }, { "docid": "b54270ca9c777eb769ba1aabcadc3d1e", "score": "0.55085415", "text": "public function update($object){\n \n }", "title": "" }, { "docid": "963320c6c8e6f19972872f0c66fe30e0", "score": "0.5508141", "text": "public function update(Request $request, $id)\n {\n\n $product = Product::findOrFail($id);\n $image = $product->image;\n if($request->hasFile('image')){\n $image = $request->file('image')->store('public/products');\n Storage::delete($product->image);\n }\n $product->name = $request->name;\n $product->description = $request->description;\n $product->image = $image;\n $product->price = $request->price;\n $product->additional_info = $request->additional_info;\n $product->category_id = $request->category;\n $product->subcategory_id = $request->subcategory;\n\n $product->save();\n\n return redirect()->route('product.index')->with('message', 'Successfully updated the product');\n }", "title": "" }, { "docid": "265c7e4e1d9ccb8f2d919846c5c6d0e1", "score": "0.55072427", "text": "public function update($id, $input);", "title": "" }, { "docid": "60f3ddc323c30358e47d69e943e6dbaa", "score": "0.5501432", "text": "public function update(Request $request, $id)\n {\n\n extract($this->getResourceNames());\n\n $this->authorize('EDIT_' . $permissionKey);\n\n $item = $modelPath::findOrFail($id);\n\n $this->validateEditForm($request, $item);\n\n $item->update($request->all());\n\n $this->notify($resourceMultiple . '.edited');\n\n return redirect()->back();\n }", "title": "" }, { "docid": "f413999cfa6fd30cb481e60a58035e46", "score": "0.54997146", "text": "public function update(Request $request,$id)\n {\n $product=Product::find($id);\n $request->validate([\n \"name\"=>\"required\",\n \"category\"=>\"required\",\n \"description\"=>\"required\",\n \"price\"=>\"required|numeric\",\n \"stock\"=>\"required|numeric\",\n \"image\"=>\"required\"\n ]);\n if($request->hasFile('image')){\n $imgname=$request->image->getClientOriginalName(); \n if(Storage::exists($request->image)){\n $product->image=$imgname; \n }\n else{\n $request->image->storeAs('public',$imgname);\n $product->image=$imgname;\n }\n \n }\n $product->name=$request->name;\n $product->category_id=$request->category;\n $product->description=$request->description;\n $product->stock=$request->stock;\n $product->price=$request->price;\n $product->save();\n\n }", "title": "" }, { "docid": "8de839d3e9816fa894298a9064d231f4", "score": "0.5497475", "text": "function update($record) {\n\t\techo \"update called\";\n\t\t$this->rest->initialize(array('server' => REST_SERVER));\n\t\t$this->rest->option(CURLOPT_PORT, REST_PORT);\n\t\t$key = $record->{$this->_keyfield};\n\t\t$retrieved = $this->rest->put('/job/' . $key, $record);\n\t\t$this->load(); // because the \"database\" might have changed\n\t}", "title": "" }, { "docid": "01d7e90eb4d4834e12b31486f04ab3c2", "score": "0.5493121", "text": "public function update(Request $request)\n {\n $feature=Feature::find($request->id);\n if($request->hasFile('feature_icon')) {\n $file_name = time().'.'.$request->feature_icon->extension(); \n $path = $request->file('feature_icon')->storeAs('public/feature_icons',$file_name);\n $feature->feature_icon=$file_name;\n $Image = str_replace('/storage', '', $request->old_image);\n #Using storage\n if(Storage::exists('public/feature_icons/' . $Image)){\n $delete= Storage::delete('/public/feature_icons/' . $Image);\n }\n } \n $feature->feature_name=$request->feature_name;\n $feature->updated_at=date('Y-m-d H:m:s');\n $feature->update();\n alert::success('feature Updated Successfully');\n return redirect()->back();\n\n }", "title": "" }, { "docid": "f7f83699cca8c8d4920c525dc392587d", "score": "0.54910034", "text": "public function update(UpdateProductRequest $request, $id)\n {\n\n $data = $request->all();\n $product = Product::find($id);\n\n $path = null;\n if ($request->file('image')) {\n $path = $request->file('image')->store('public/products');\n // @unlink('storage/'. $product->image);\n $data['image'] = $path;\n }\n\n\n $product->update($data);\n\n return redirect('/product');\n }", "title": "" }, { "docid": "2160be914cd287b1f331b462c6097a00", "score": "0.54888636", "text": "public function update(Request $request, $id)\n {\n // $this->authorize('haveaccess','producto.edit');\n $datosProductos=request()->except(['_token','_method']);\n\n if ($request->hasFile('imagen')) {\n\n $producto= Producto::findOrFail($id);\n\n Storage::delete('public/'.$producto->imagen);\n\n $datosProductos['imagen']=$request->file('imagen')->store('uploads/producto','public');\n }\n\n Producto::where('id','=',$id)->update($datosProductos);\n $valores['concesionado']=Null;\n $producto= Producto::findOrFail($id);\n $producto->fill($valores);\n $producto->save();\n return view('supervisor.producto.edit',compact('producto'));\n }", "title": "" }, { "docid": "6cf2f968968fff04f96278a9288f5b34", "score": "0.54857856", "text": "public function update(Request $request, $id)\n {\n if ($this->checkRole()) {\n $product = Product::find($id);\n $product->brandName = $request->Input('brandName');\n $product->medicalName = $request->Input('medicalName');\n $product->price = $request->Input('price');\n $product->buying_price = $request->Input('buying_price');\n $product->reorder_level = $request->Input('reorder_level');\n if ($request->hasFile('image')) {\n $oldFilename = 'public/product_images/' . $product->image;\n $product->image = $this->filenameToStore($request);\n Storage::delete($oldFilename);\n }\n $product->save();\n $product->suppliers()->sync($request->suppliers);\n\n return redirect('/products')->with('success', 'Product Details Saved Successfully!');\n } else {\n return redirect()->route('home');\n }\n\n }", "title": "" }, { "docid": "57e8a233d0abf833c408dd0277ccd310", "score": "0.5483825", "text": "public function update($id)\n {\n\n //VALIDATE FIELDS\n $validator = Validator::make(request()->all(),\n [\n 'title' => 'required|max:255',\n 'slug' => 'required|max:255',\n ]);\n\n //IF INVALID\n if($validator->fails()){ \n return $this->respondInvalid('Error with validation.', $validator->errors());\n }\n\n //IF VALID\n else { \n try {\n //Update \n $data2 = [\n 'slug' => request('slug'), \n 'title' => request('title'), \n 'status' => request('status'),\n 'description' => request('description'),\n 'user_id' => Auth::user()->id, \n ];\n\n $data = [\n 'pages' => request('pages'), \n 'body' => request('body'),\n ];\n\n $resource = Article::find($id);\n //var_dump($resource);\n $tags = [];\n\n //If new tags then create and add for sync\n foreach(json_decode(request('tags')) as $tagK => $tagV){\n if(!empty($tagV->create) && $tagV->create){\n if($tag = Tag::firstOrCreate([\n 'title' => $tagV->value,\n 'slug' => str_slug($tagV->value),\n ]))\n {\n $tag->resources()->sync($id);\n $tags[] = $tag->id;\n }\n }\n else {\n $tags[] = $tagV->value;\n }\n }\n\n if($resource->update($data) && $resource->resource->update($data2) && $resource->resource->tags()->sync($tags)) \n {\n return $this->respondSuccess('Successful edit.');\n }\n }\n catch(\\Illuminate\\Database\\QueryException $e){\n $errorCode = $e->errorInfo[1];\n\n switch ($errorCode) {\n //1062 == Duplicate entry for unique MySQL\n case 1062: \n return $this->respondDuplicate('Duplicate Entry.', ['error'=>'This entry already exists.', 'message'=> $e]); \n break;\n default:\n return $this->respondError(null, ['error'=> $errorCode, 'message'=>$e]); \n break;\n }\n }\n }\n }", "title": "" }, { "docid": "69899e5cc810b430e81a78ef78bbb9aa", "score": "0.54833865", "text": "public function putAction()\n\t{\n\t\t$this->_connectionApi->put();\n\t}", "title": "" }, { "docid": "317ca96a233f05a742b57399bd2b3542", "score": "0.54833144", "text": "public function update(Request $r, $id)\n {\n $p = Product::find($id);\n $p->stock = $r->input('stock');\n $p->save();\n alert()->success('Success', 'Data successfully updated');\n return redirect()->route('emptyProduct.index');\n }", "title": "" }, { "docid": "f84f36825279804eeb3fa246acad7d33", "score": "0.5482953", "text": "public function update(Request $request, $id)\n {\n //\n $data = $request->all();\n unset($data['_token']);\n unset($data['_method']);\n unset($data['image']);\n $rs = Pr::find($id)->update($data);\n if($rs) {\n if($request->image){\n $prs = Pr::find($id);\n $image_u = $prs->media;\n $image_u = str_replace('/storage/app/', '', $image_u);\n $path = '/storage/app/'.@$request->file('image')->store('prs');\n $prs->image = $path;\n $prs->save();\n Storage::delete($image_u);\n }\n return redirect(route('prs.index'));\n }else{\n return back();\n }\n }", "title": "" }, { "docid": "a01ea56f337a0cca2a7f8b0fb86e58d0", "score": "0.54794407", "text": "public function update(Request $request, $id)\n {\n\t\t$product = Product::find($id);\n\n\t\t$this->valid($request);\n\n\t\t$field = [\n\t\t\t'uuid',\n\t\t\t'name',\n\t\t\t'price',\n\t\t\t'description',\n\t\t];\n\n\t\tif ($request->product_photo) {\n\t\t\t$request->request->add([\n\t\t\t\t'rule' => [\n\t\t\t\t\t'product_photo' =>\n\t\t\t\t \t'required|image|mimes:jpeg,png,jpg|max:2048',\n\t\t\t\t]\n\t\t\t]);\n\n\t\t\t$this->valid($request);\n\n\t\t\t$upload = $request->file('product_photo')->store('assets/img');\n\n\t\t\tif ($product->photo != '/assets/img/default.jpg') {\n\t\t\t\t@unlink(public_path().$product->photo);\n\t\t\t}\n\n\t\t\tarray_push($field, 'photo');\n\n\t\t\t$request->request->add([\n\t\t\t\t'photo' => '/'.$upload\n\t\t\t]);\n\t\t}\n\n\t\tProduct::where('id', $id)\n\t\t\t->update($request->only($field));\n\n\t\treturn redirect()->route('product.index')->with([\n\t\t\t'success' => 'Data Changed'\n\t\t]);\n }", "title": "" }, { "docid": "749485fd3edd17fca5d56cd2e62d0c66", "score": "0.547553", "text": "public function update(Request $request, $id)\n {\n $item = Item::find($id);\n\n $requestData = $request->all();\n\n if ($request->hasFile('image_url')) {\n\n $old_image = $item->image_url;\n $file = $request->file('image_url');\n $path = $this->fileUpload($file, 'items');\n $requestData['image_url'] = $path;\n File::delete(public_path() . $old_image);\n\n }\n\n $item->update($requestData);\n\n return redirect('/admin/items');\n }", "title": "" }, { "docid": "ba14e6d76f18913118873dc455ddf07e", "score": "0.547496", "text": "public function update(UpdateProductRequest $request, Product $product)\n {\n //\n try {\n $originImage= $product->image;\n $product->fill($request->except(['category', 'supplier']));\n $product->image = $originImage;\n if ($request->image) {\n $oldImage = $product->image;\n $imageEncodeBase64 = $request->image;\n $postion = strpos($imageEncodeBase64, ';');\n $ext = explode('/', substr($imageEncodeBase64, 0, $postion))[1];\n $fileName = Str::uuid() . '.' . $ext;\n $filePath = public_path('storage/product') . '/' . $fileName;\n Image::make($imageEncodeBase64)->resize(200, 240)->save($filePath);\n $product->image = \"product/$fileName\";\n $filePath = public_path('storage/'.$oldImage);\n if(file_exists($filePath)){\n unlink($filePath);\n }\n }\n $product->save();\n return response()->success(new ProductResource($product));\n } catch (\\Throwable $ex) {\n return response()->error($ex->getMessage());\n }\n }", "title": "" }, { "docid": "748d9e839dc1aa55917e22860bfd0666", "score": "0.54659873", "text": "public function update(Request $request, $id, $parent = null)\n {\n extract($this->getResourceNames());\n\n if(!is_null($parent))\n {\n $item = $modelPath::findOrFail($parent);\n $parent = $this->parentModelPath::findOrFail($id);\n } else {\n $item = $modelPath::findOrFail($id);\n }\n\n $validated = $this->resolveRequest('Update')->validated();\n\n $item->update($request->all());\n\n $this->notify($resourceMultiple . '.edited');\n\n return redirect()->back();\n }", "title": "" }, { "docid": "47bbce92661ab4fdf29441a5eabbeea2", "score": "0.5462897", "text": "public function update(Request $request, $id)\n {\n $update = Supplier::find($id);\n $update->name = $request->name;\n $update->slug = strtolower(str_replace(' ', '-',$request->name));\n $update->email = $request->email;\n $update->phone = $request->phone;\n $update->address = $request->address;\n $update->shop_name = $request->shop_name;\n\n if ($request->hasFile('photo')) {\n $image = $request->file('photo');\n $img = time() . '.'. $image->getClientOriginalExtension();\n $location = public_path('backend/assets/images/supplier/'.$img);\n Image::make($image)->resize(300,300)->save($location);\n $update->photo = $img;\n }\n $update->save();\n toast('Supplier Information Add Successfully','success');\n return redirect()->route('index.supplier');\n }", "title": "" }, { "docid": "13060cd318eed312852c00ed17885787", "score": "0.5460793", "text": "public function update($object)\n {\n }", "title": "" }, { "docid": "f684d143c5cb5e0fd840b77e6b10f6c8", "score": "0.5460385", "text": "public function update(Request $request, $id)\n { \n $product = Product::find($id);\n $product->name = $request->name;\n $product->name = $request->name;\n $product->description = $request->description;\n $product->save();\n if($request->hasFile('image')){\n $file = $request->file('image');\n $name = time().'.jpg';\n $file->move(public_path('//images//'), $name);\n $image = Image::find($id);\n $image->path = '/images/'.$name;\n $image->save();\n return response()->json(['message'=>'Producto Modificado Satisfactoriamente', $product ,'image'=>$image,]);\n }\n return response()->json(['message'=>'Producto Modificado Satisfactoriamente', $product]);\n }", "title": "" }, { "docid": "6bbf67d9e29ef7e592b60af7e38a778c", "score": "0.54592675", "text": "public function update($resource, $attributes, $exec = false)\n {\n if (!$exec) {\n return $this->beforeUpdate($resource, $attributes);\n }\n\n return DB::transaction(function () use ($resource, $attributes) {\n $attributes = $this->updateAttributes($attributes);\n\n /** @var Model $resource */\n $resource = $this->fill($resource, $attributes, true);\n $resource->save();\n\n return $this->afterUpdate($resource, $attributes);\n });\n }", "title": "" }, { "docid": "a1d61f0aa122378fb9049378295f5945", "score": "0.54586715", "text": "public function update($entity)\n {\n }", "title": "" }, { "docid": "a1d61f0aa122378fb9049378295f5945", "score": "0.54586715", "text": "public function update($entity)\n {\n }", "title": "" }, { "docid": "4360333bf1732261e8e76d77713982a2", "score": "0.54556817", "text": "private function updateEntity(Model\\BaseModel $entity, string $uri, string $resourceFieldKey): void {\n\t\t$tags = [];\n\t\tif ($entity instanceof Model\\TaggableInterface) {\n\t\t\t// Preserve the tags temporarily.\n\t\t\t// We'll sync them later.\n\t\t\t$tags = $entity->getTags();\n\t\t}\n\n\t\t$rawApiResponse = $this->communicator->put($uri, [], [\n\t\t\t$resourceFieldKey => $entity->export(),\n\t\t]);\n\n\t\t$newData = $rawApiResponse->getValue(sprintf('[%s]', $resourceFieldKey));\n\t\t$entity->hydrate($newData);\n\n\t\tif ($entity instanceof Model\\TaggableInterface) {\n\t\t\t// The requests (and hydration) above made us lose the tags,\n\t\t\t// since they're managed through another API.\n\t\t\t// Let's assign/de-assign tags now.\n\t\t\t$this->ensureTagsSynced($entity, $tags);\n\t\t}\n\t}", "title": "" }, { "docid": "f2d8cf4532904fd7bfbac2bd62a96a68", "score": "0.54469514", "text": "public function update(Request $request, $id)\n {\n $input = $request->all();\n $this->validate($request, [\n 'title' => 'required',\n 'description' => 'required',\n ]);\n if ($request->hasFile('icon')) {\n $path = $request->icon->store('public/images');\n $input['icon'] = $path;\n }\n $block = FourBlock::find($id);\n $block->fill($input)->save();\n toastr()->success('Block has been updated successfully');\n return redirect()->route('fourblock.index');\n }", "title": "" }, { "docid": "0073ba64b443f80ace8779c23d638758", "score": "0.54424137", "text": "public function update(StorePoductRequest $request, Product $product, $id)\n {\n $updated_datas = $request->except(['_method','_token']);\n $prod_to_update = Product::where('id',$id);\n $updated = $prod_to_update->update($updated_datas);\n if($prod_to_update){\n return redirect('/admin/products')->with('status', 'A termék sikeresen frissítve!');\n }\n\n }", "title": "" }, { "docid": "7db59e65f55b9762d20b09aede45101b", "score": "0.54399514", "text": "public function update(Request $request, Product $product)\n {\n if($request['image']){\n $file = $request['image'];\n $image = $this->ImageUploader($file,'images/');\n// unlink($product->image);\n }else{\n $image = $product->image;\n }\n if($request['file']){\n $file = $request['image'];\n $val = $this->ImageUploader($file,'files/');\n// unlink($product->file);\n }else{\n $val = $product->file;\n }\n\n\n $data = $request->all();\n $product->tags()->sync($data['tag_id']);\n $data['image'] = $image;\n $data['file'] = $val;\n\n $product->update($data);\n return redirect(route('product.index'));\n }", "title": "" }, { "docid": "2b54bef0cb09abd830d8673bfdd3df4e", "score": "0.5435874", "text": "public function update(ProductRequest $request, $id)\n {\n $inputs = $request->except(['_method', '_token']);\n if ($request->hasFile('poster')) {\n $poster = $request->file('poster');\n $new_name = uniqid(mb_strimwidth($poster->getClientOriginalName(), 0, 3, '_')) . '.' . $poster->getClientOriginalExtension();\n\n $img = Image::make($poster);\n $img->insert(public_path().'/images/watermark.png', 'center');\n $img->save(public_path() . '/images/' . $new_name);\n\n File::delete('images/' . $inputs['old_poster']);\n $inputs['poster'] = $new_name;\n unset($inputs['old_poster']);\n } else {\n $inputs['poster'] = $inputs['old_poster'] ?? null;\n unset($inputs['old_poster']);\n }\n if ($inputs['available'] === 'yes') {\n $inputs['available'] = 1;\n } else {\n $inputs['available'] = 0;\n }\n $update_product = Product::find($id);\n $update_product->fill($inputs);\n if ($update_product->update()) {\n return redirect()->route('product.index')->with('status', 'Product successfully updated !!!');\n }\n }", "title": "" }, { "docid": "45006333af499b7a8ef5e992e8465995", "score": "0.54331666", "text": "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n\t\tself::storeOrUpdate($product, $request);\n\n\t\treturn redirect('/products')->with('edited', \"Product edited: $product->name\");\n }", "title": "" }, { "docid": "f71584ef2ac9d0aab6b54094e7b315c4", "score": "0.543238", "text": "public function update()\n {\n $this->executeActions(true);\n $this->saveData();\n $this->reset(); // reset pending changes\n }", "title": "" }, { "docid": "eaa583782a682873861569b9b98dc81c", "score": "0.5430323", "text": "public function updateEntity(Entity $entity);", "title": "" }, { "docid": "8fb9613a7e05f846bb10235d1d3c4c4b", "score": "0.54254407", "text": "public function update(Request $request, $id)\n {\n $validation=$request->validate([\n \"text\"=>\"required\",\n\n \n ]);\n $update=Slider::find($id);\n if (request()->hasFile(key:'img')) {\n $img=request()->file(key:'img')->hashName();\n request()->file(key:'img')->storeAs(path:'',name:$img);\n $update->img=$img;\n }\n $update->text=$request->text;\n $update->save();\n return redirect()->back();\n\n }", "title": "" }, { "docid": "9f31b47ab07ed8f7effea689ae758174", "score": "0.5420852", "text": "public function update()\n {\n $this->getDataBackend()->update();\n }", "title": "" }, { "docid": "336bb2ab11980d312dc3ebdfdf92ee79", "score": "0.5418655", "text": "public function update(Request $request, $id)\n {\n $validateData = $request->validate([\n 'al_desc'=>'required|string',\n 'tr_desc'=>'required|string',\n 'stock'=>'required',\n 'age'=>'required',\n 'pur_price'=>'required',\n 'sale_price'=>'required',\n 'image' => 'required|image|max:2048',\n ]);\n\n $article = Articles::where('id', $id)\n ->first();\n\n $image_path = public_path(\"images/{$article->image}\");\n\n if (File::exists($image_path)) {\n unlink($image_path);\n $image = $request->file('image');\n $filename = $image->getClientOriginalName();\n $image->move(public_path('images'), $filename);\n $article->image = $request->file('image')->getClientOriginalName();\n }\n\n $articleStock = $request->input('stock');\n $article->al_desc = $request->input('al_desc');\n $article->tr_desc = $request->input('tr_desc');\n $article->stock = $request->input('stock');\n $article->age=$request->input('age');\n $article->pur_price=$request->input('pur_price');\n $article->sale_price=$request->input('sale_price');\n $article->prime_stock +=$articleStock;\n $article->save();\n\n return redirect()->route('articles.index')->with('success','Article Updated Successfully');\n }", "title": "" }, { "docid": "cdb8493452b057388fcb678d2dccb96c", "score": "0.5417866", "text": "public function update($id, Request $request);", "title": "" }, { "docid": "9f4a5e931ad31bad773803c3dc4cda90", "score": "0.5416135", "text": "public function update(Request $request, $id)\n {\n if($request->hasFile('image')){\n\n $filename = $this->productImage($request->file('image'));\n \n }else{\n\n $recent = Product::findOrFail($id);\n $filename = $recent->image;\n }\n\n $product = new Product;\n Product::where('id', $id)->update($product->productData($request->toArray())+['status' => true, 'image' => $filename]);\n\n return redirect()->route('products.index')->with('success', 'product successfully updated');\n }", "title": "" }, { "docid": "daac94b3950e759691b202ac44ca7b18", "score": "0.54159683", "text": "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n $product->update($request->only($this->product_fields));\n $this->move_image($product, $request->get('image'));\n }", "title": "" }, { "docid": "b55b4c2da5ca8dec48b36986ba4711ee", "score": "0.54155767", "text": "public function update(Request $request, Product $product)\n\n {\n\n $input = $request->all();\n\n\n\n $validator = Validator::make($input, [\n\n 'name' => 'required',\n\n 'price' => 'required',\n\n 'stock' => 'required',\n\n 'shortDesc' => 'required',\n\n 'description' => 'required'\n\n ]);\n\n\n\n\n\n if($validator->fails()){\n\n return $this->sendError('Validation Error.', $validator->errors());\n\n }\n\n\n\n $product->name = $input['name'];\n\n $product->price = $input['price'];\n\n $product->stock = $input['stock'];\n\n $product->shortDesc = $input['shortDesc'];\n\n $product->description = $input['description'];\n\n\n\n $product->save();\n\n\n\n return $this->sendResponse(new ProductResource($product), 'Product updated successfully.');\n\n }", "title": "" }, { "docid": "fa4d35fe272f742ecbc45d6ae01985ba", "score": "0.5411923", "text": "public function update(Request $request, $id)\n {\n \n $validator = Validator::make($request->all(),[\n 'name' => 'required|string|max:255',\n 'user_id' => 'required|exists:App\\Models\\User,id',\n 'category_id' => 'required|exists:App\\Models\\Category,id',\n 'description' => 'required',\n 'price' => 'required',\n 'photo' => 'image'\n\n ]);\n\n if($validator->fails()){\n return response()->json($validator->errors()); \n }\n \n $product = Product::find($id);\n $product -> name = $request['name'];\n $product -> user_id = $request['user_id'];\n $product -> category_id = $request['category_id'];\n $product -> description = $request['description'];\n $product -> price = $request['price'];\n\n if($request->hasFile('photo')){\n if(File::exists(public_path(\"storage/\").$product -> photo)){\n File::delete(public_path(\"storage/\").$product -> photo);\n }\n $product -> photo=$request->photo->store('photo');\n }\n\n $product -> save();\n\n return response()\n ->json(['success' => 1,'message' => 'Updated succesfully!']);\n }", "title": "" }, { "docid": "daa5dabd0608fa1791ffe3d1866a3e16", "score": "0.5410523", "text": "public function update(StoreUpdateProductRequest $request, $id)\n {\n \n $product = $this->repository->find($id);\n if(!$product){\n return redirect()->back();\n }\n\n $data = $request->all();\n\n // Upload de Imagem \n if($request->hasFile('image') && $request->image->isValid()){\n\n /** Verifica se o arquivo existe */\n if($product->image && Storage::exists($product->image)){\n /** Deleta o arquivo */\n Storage::delete($product->image);\n }\n // Salvando imagem e passando o caminho da imagem\n $imagePath = $request->image->store('products');\n\n // Passando o nome da imagem para armazenar no banco\n $data['image'] = $imagePath;\n }\n\n $product->update($data);\n return redirect()->route('product.index');\n }", "title": "" }, { "docid": "8cc682b417e81303d02cf6c27cfcadc5", "score": "0.540968", "text": "public function update(Request $request, $id)\n {\n $prds = Product::find($id);\n $prds->nombre = $request->input('nombre');\n if ($request->hasFile('foto')) {\n $file = time().'.'.$request->foto->extension();\n $request->foto->move(public_path('imgs'), $file);\n $prds->foto = \"imgs/\".$file;\n }\n $prds->directory_id = $request->input('directory_id');\n if($prds->save()) {\n return redirect('directories')\n ->with('status', 'La Noticia '.$prds->nombre.' se modifico con Exito!');\n }\n }", "title": "" }, { "docid": "51af550a7cfb8f966c66be0c2f793c3b", "score": "0.54074425", "text": "public function update($id, Request $request)\n\t{\n\t\t$content = Content::findOrFail($id);\n\t\t$data['name'] = $request->name;\n if($request['image-data'] != null){\n \t$image = $this->uploadAvatarAgent($request->image, $request['image-data']);\n \t$data['image'] = $image['url'];\n }\n\t\t$data['url'] = $request->url;\n\t\t$content->update($data); \n\t\treturn redirect()->route(config('quickadmin.route').'.content.index');\n\t}", "title": "" }, { "docid": "aa18b98fb17d4cb4052efc2798af1142", "score": "0.54064333", "text": "public function testUpdateStoreItem()\n {\n }", "title": "" }, { "docid": "0754ef21e342dbc988b4756156b2c0b9", "score": "0.5404135", "text": "public function update(Request $request, Product $product)\n {\n $data = $request->all();\n\n if($request->file('picturePath'))\n {\n $data['picturePath'] = $request->file('picturePath')->store('assets/product', 'public');\n }\n\n $product->update($data);\n\n return redirect()->route('product.index');\n }", "title": "" }, { "docid": "8f9ad063c18a5eeb38cd6267a01f3028", "score": "0.5403173", "text": "public function update($id)\n {\n \n }", "title": "" }, { "docid": "8f9ad063c18a5eeb38cd6267a01f3028", "score": "0.5403173", "text": "public function update($id)\n {\n \n }", "title": "" }, { "docid": "8f9ad063c18a5eeb38cd6267a01f3028", "score": "0.5403173", "text": "public function update($id)\n {\n \n }", "title": "" }, { "docid": "8f9ad063c18a5eeb38cd6267a01f3028", "score": "0.5403173", "text": "public function update($id)\n {\n \n }", "title": "" }, { "docid": "8f9ad063c18a5eeb38cd6267a01f3028", "score": "0.5403173", "text": "public function update($id)\n {\n \n }", "title": "" } ]
a0cb979b02112cc9387e7feb0aed80b9
Verify if the provided $key exists on the data stack
[ { "docid": "b18443ff4fccbfba6879b4e1bc49a3af", "score": "0.0", "text": "public function __isset($key)\n {\n return $this->offsetExists($key);\n }", "title": "" } ]
[ { "docid": "97c4c4c85f8652ea1aae36da8768f88b", "score": "0.78203076", "text": "public function keyExists($key);", "title": "" }, { "docid": "97c4c4c85f8652ea1aae36da8768f88b", "score": "0.78203076", "text": "public function keyExists($key);", "title": "" }, { "docid": "dbd566c34f621ea15ce97d1fd1002e69", "score": "0.7809012", "text": "public function hasKey($key);", "title": "" }, { "docid": "dbd566c34f621ea15ce97d1fd1002e69", "score": "0.7809012", "text": "public function hasKey($key);", "title": "" }, { "docid": "b2ac82e38d03406734a5139e9ce3d7b8", "score": "0.77893955", "text": "public function hasKey($key): bool;", "title": "" }, { "docid": "247970335b8341688676672e41beee8c", "score": "0.77856", "text": "public function check_exist($key);", "title": "" }, { "docid": "bf9378c49898f7016466dcb271757acd", "score": "0.7689512", "text": "public function exists($key){}", "title": "" }, { "docid": "bb7bdb233c04922285f76cb3c5ab416e", "score": "0.767312", "text": "public function exist(string $key): bool {}", "title": "" }, { "docid": "5cf54a50a3473f07e8629ef519047c09", "score": "0.76588696", "text": "public function exist($key);", "title": "" }, { "docid": "cccad18132cfba07c988279e036aca5b", "score": "0.76201844", "text": "public function hasItem(string $key): bool;", "title": "" }, { "docid": "960ef33c0789a03b2d416599224b4239", "score": "0.76176137", "text": "public function exists($key) {}", "title": "" }, { "docid": "43c9b49f5e5a0143171c678673e892a8", "score": "0.7595374", "text": "public function exists($key): bool;", "title": "" }, { "docid": "d1384c2fbd8f8837dd227e7bd6f9043d", "score": "0.7578868", "text": "public function has($key): bool;", "title": "" }, { "docid": "1c465143a645032dcb20e005b70d92df", "score": "0.75611395", "text": "public function hasKey($key)\n\t{\n\t\treturn (!is_null($this->resolve($key)));\n\t}", "title": "" }, { "docid": "34569e73f832369bd83ef13bb7a1f820", "score": "0.75471103", "text": "public function __isset(string $key)\n\t{\n\t\treturn array_key_exists($key, $this->current_data);\n\t}", "title": "" }, { "docid": "5aaf0b8d72decf314dc1aa794a9037c1", "score": "0.75351566", "text": "public function exists($key) {\n return isset($this->_data[$key]);\n }", "title": "" }, { "docid": "6829faff4d61fad0005561729a01087c", "score": "0.7514719", "text": "public function exists($key);", "title": "" }, { "docid": "6829faff4d61fad0005561729a01087c", "score": "0.7514719", "text": "public function exists($key);", "title": "" }, { "docid": "6829faff4d61fad0005561729a01087c", "score": "0.7514719", "text": "public function exists($key);", "title": "" }, { "docid": "df8ea3b92e0c67869c449bbb371476cb", "score": "0.75082326", "text": "public function hasData($key = null);", "title": "" }, { "docid": "aa13288dfd32445a3a3b51724d94d3a9", "score": "0.74906087", "text": "public function has_key( $key );", "title": "" }, { "docid": "0badcaf3ec070c2010536b386b393b52", "score": "0.74804795", "text": "public function hasData($key = '');", "title": "" }, { "docid": "4d0feba491e1b7ea122812f2d3486c47", "score": "0.74580926", "text": "public function exists(string $key): bool;", "title": "" }, { "docid": "4d0feba491e1b7ea122812f2d3486c47", "score": "0.74580926", "text": "public function exists(string $key): bool;", "title": "" }, { "docid": "20b1749e45e50bec71b8560fbe7729b2", "score": "0.7457651", "text": "public function __isset($key)\n\t{\n\t\treturn array_key_exists($key, $this->data);\n\t}", "title": "" }, { "docid": "4b453e2442bb894d2d529f2d74d2d5a1", "score": "0.745077", "text": "public function __isset( $key ) {\n\t\treturn isset( $this->data[ $key ] );\n\t}", "title": "" }, { "docid": "c7957697b80bac0f439fcc443b2cbdba", "score": "0.74487585", "text": "public function has( $key );", "title": "" }, { "docid": "beb395641292f144b3cd18afb2e915e2", "score": "0.74376863", "text": "public function __isset($key): bool\n {\n return isset($this->data[$key]);\n }", "title": "" }, { "docid": "63a5acbc0ae6ba74f969a3b16584f828", "score": "0.7436174", "text": "public function has(\n $key\n )\n {\n }", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "8808dc8457dd0b6621848ee1e0c19a45", "score": "0.7433384", "text": "public function has($key);", "title": "" }, { "docid": "ad634c3db47715a7390c75157c0b009f", "score": "0.7428231", "text": "abstract public function exists($key);", "title": "" }, { "docid": "43cf7ff0f45eae8b6119afd36fbf9d7c", "score": "0.742338", "text": "public function hasKey();", "title": "" }, { "docid": "610a3a1ba77f548c437218fccbf13c18", "score": "0.74222976", "text": "public function has($key)\n {\n \treturn isset($this->data[$key]);\n }", "title": "" }, { "docid": "da3029d3b77912e69aacacda7ccd750d", "score": "0.74209446", "text": "public function exists(string $key) : bool;", "title": "" }, { "docid": "815f0ef046ab2aaade766f82723d8bc7", "score": "0.7412215", "text": "function has($key)\n {\n return isset($this->data[$key]);\n }", "title": "" }, { "docid": "8b681e3b1cdd8a30a717d0d2b9f44474", "score": "0.74047", "text": "public function exists( $key )\n {\n return false;\n }", "title": "" }, { "docid": "e4f66f17a9d6fab2647f68fead157d45", "score": "0.7397653", "text": "public function exists($p_key);", "title": "" }, { "docid": "274833d69456361ca5f42dd3abed2130", "score": "0.7395299", "text": "public function hasItem($key)\n {\n }", "title": "" }, { "docid": "598cc0524a56107764177db03361c433", "score": "0.7394821", "text": "public function has(string $key): bool;", "title": "" }, { "docid": "598cc0524a56107764177db03361c433", "score": "0.7394821", "text": "public function has(string $key): bool;", "title": "" }, { "docid": "598cc0524a56107764177db03361c433", "score": "0.7394821", "text": "public function has(string $key): bool;", "title": "" }, { "docid": "598cc0524a56107764177db03361c433", "score": "0.7394821", "text": "public function has(string $key): bool;", "title": "" }, { "docid": "598cc0524a56107764177db03361c433", "score": "0.7394821", "text": "public function has(string $key): bool;", "title": "" }, { "docid": "7f975682095e16382b366116e16ff85b", "score": "0.73837566", "text": "public function exists( $key ) {\n\t\treturn (\n\t\t\tarray_key_exists($key, $this->___data)\n\t\t\t&& ! is_null( $this->___data[ $key ] )\n\t\t);\n\t}", "title": "" }, { "docid": "bc7f6b61cb3f91b5e78c858daa473491", "score": "0.737876", "text": "public function exists($key)\n {\n // TODO: Implement exists() method.\n }", "title": "" }, { "docid": "ec20779584c03b73e9cb0f4730de8db8", "score": "0.7377975", "text": "public function offsetExists(\n $key\n )\n {\n }", "title": "" }, { "docid": "ec20779584c03b73e9cb0f4730de8db8", "score": "0.7377975", "text": "public function offsetExists(\n $key\n )\n {\n }", "title": "" }, { "docid": "41608678051b23abcae6a7ee653f3ca8", "score": "0.7376193", "text": "public function exists( $key ) {\n\t\treturn array_key_exists( $key, $this->data );\n\t}", "title": "" }, { "docid": "77db3db94b43fc698f827ca85027005d", "score": "0.7372704", "text": "public function has(string $key): bool\n {\n }", "title": "" }, { "docid": "71f660218083558a50a15e0018cf48de", "score": "0.73686945", "text": "public function hasData(string $key = ''): bool;", "title": "" }, { "docid": "8524d833d0ee66dc2e17fcb7e2d405da", "score": "0.73655623", "text": "public function __isset($key)\n\t{\n\t\t$data = $this->read();\n\t\treturn isset($data[$key]);\n\t}", "title": "" }, { "docid": "774acb762332d9100b944630122f6cd9", "score": "0.73648167", "text": "public function exists(string $key): bool\n {\n $app = App::get();\n $hooks = $app->hooks;\n\n $returnValue = null;\n $hooks->execute('dataItemExists', $key, $returnValue);\n if (is_bool($returnValue)) {\n $exists = $returnValue;\n } else {\n $result = $this->execute([\n [\n 'command' => 'get',\n 'key' => $key,\n 'result' => ['key']\n ]\n ]);\n $exists = isset($result[0]['key']);\n }\n\n $hooks->execute('dataItemExistsDone', $key, $exists);\n $hooks->execute('dataItemRequested', $key);\n return $exists;\n }", "title": "" }, { "docid": "61111afe815cc51882cb0841076a8fa7", "score": "0.73567086", "text": "public function hasKey(string $key): bool\n {\n return array_key_exists($key, $this->data);\n }", "title": "" }, { "docid": "84069059cb7d8774cba94b693910814f", "score": "0.7336367", "text": "abstract public function has($key);", "title": "" }, { "docid": "9b33a3ad729b815440e368b1949edf34", "score": "0.7335008", "text": "public function existsKey($key) {\n\t\treturn parent::existsKey($key);\n\t}", "title": "" }, { "docid": "5dd7847c989d78cb3539c602aaf6b081", "score": "0.7329874", "text": "public function offsetExists($key): bool\n {\n return array_key_exists($key, $this->data);\n }", "title": "" }, { "docid": "0fa753a5c292b4dc28eb6c253bb0ed18", "score": "0.7326123", "text": "public function has($key)\n\t{\n\t\treturn array_key_exists($key,$this->data);\n\t}", "title": "" }, { "docid": "f70df1eb5c808b48a4ec5b78aaf6bce0", "score": "0.7314349", "text": "public static function has(string $key): bool;", "title": "" }, { "docid": "9eeb88fb970bb4f09d48d515c95e2e80", "score": "0.7312948", "text": "abstract function exists($key);", "title": "" }, { "docid": "721d1570d395dd2eb871174a7fc6de25", "score": "0.73090947", "text": "public function offsetExists( $key )\n {\n return isset( $this->children[$key] );\n }", "title": "" }, { "docid": "a4622b0b2787c20c3e0498238ec13090", "score": "0.73074424", "text": "public function has($key){\n\t\treturn array_key_exists($key, $this->data);\n\t}", "title": "" }, { "docid": "ff0b30d2db4c91d121be8d3d920d9830", "score": "0.73019385", "text": "public function has($key): bool\n {\n return isset($this->list[$key]);\n }", "title": "" }, { "docid": "dd2757cde135a18a8a58f168ccb530fc", "score": "0.7301817", "text": "public function containsKey($key): bool;", "title": "" }, { "docid": "dd2757cde135a18a8a58f168ccb530fc", "score": "0.7301817", "text": "public function containsKey($key): bool;", "title": "" }, { "docid": "fff133b9e450eeec499faf3cd5deec44", "score": "0.7298456", "text": "public function existKey($key)\n {\n return array_key_exists($key, $this->items);\n }", "title": "" }, { "docid": "389ba7154e7707f9b4e38fd47084dfc6", "score": "0.72674763", "text": "public function containsKey($key) : bool;", "title": "" }, { "docid": "45d59e625bd175785bc86e6c1410306f", "score": "0.72641176", "text": "public function hasData($key)\n {\n return isset($this->data[$key]);\n }", "title": "" }, { "docid": "87fdc302ab7db7df8161713be95c89ed", "score": "0.7261588", "text": "function exists($key);", "title": "" }, { "docid": "9b5e86d70a9b97deee342b1e4b39efd3", "score": "0.72610605", "text": "public function has($key)\n {\n return false;\n }", "title": "" }, { "docid": "f0d3f73e0a551d066336d5cb9614a197", "score": "0.7259609", "text": "public function has(string $key): bool\n {\n return isset($this->data[$key]);\n }", "title": "" }, { "docid": "f0d3f73e0a551d066336d5cb9614a197", "score": "0.7259609", "text": "public function has(string $key): bool\n {\n return isset($this->data[$key]);\n }", "title": "" }, { "docid": "b1d0a2fbdc8c3e4680d7513b0bc0333d", "score": "0.7259581", "text": "abstract public function exists(string $key);", "title": "" }, { "docid": "ea6088e7edb57521f6a49b39a3baa383", "score": "0.7252654", "text": "#[\\ReturnTypeWillChange]\n\tpublic function offsetExists($key) {\n\t\t$key = strtolower($key);\n\t\treturn isset($this->data[$key]);\n\t}", "title": "" }, { "docid": "6c585dfe42e66b9ccbebaf0f3310c1b0", "score": "0.7250775", "text": "function exists($key) {\n\t\treturn isset($this->args[$key]);\n\t}", "title": "" }, { "docid": "4107b2542ce7715420fb9a012ac466f7", "score": "0.7250021", "text": "public function exists($key)\n {\n return isset($this->data[$key]);\n }", "title": "" }, { "docid": "8ef43dc4b5e4c3cea4b4fc6765f35711", "score": "0.7239653", "text": "public function __isset($key)\n {\n return $this->exists($key);\n }", "title": "" }, { "docid": "8ef43dc4b5e4c3cea4b4fc6765f35711", "score": "0.7239653", "text": "public function __isset($key)\n {\n return $this->exists($key);\n }", "title": "" }, { "docid": "dd97e65ccb39d1f66c5973cf33ee6fba", "score": "0.7231072", "text": "public function checkKey($key);", "title": "" }, { "docid": "5eee9d26e05ece11ead5a0f5cd04a230", "score": "0.72147965", "text": "public function __isset($key)\n {\n return isset($this->data[$key]);\n }", "title": "" }, { "docid": "5eee9d26e05ece11ead5a0f5cd04a230", "score": "0.72147965", "text": "public function __isset($key)\n {\n return isset($this->data[$key]);\n }", "title": "" } ]
3b8fa187f0dc25969f957907d5e9e0ab
close git file handles
[ { "docid": "c47a264e5bc424d307b1bfd1f683cd92", "score": "0.88130265", "text": "function closeGitFileHandles(){\n\t\t if($this->gitFileHandles != false){\n\t\t\t\t$gitFileHandles = $this->gitFileHandles;\n\t\t\t\tforeach($gitFileHandles as $gitFileNumber => $gitFileHandle){\n\t\t\t\t\t fclose($gitFileHandle);\n\t\t\t\t}\n\t\t\t\t$this->gitFileHandles = false;\n\t\t }\n\t }", "title": "" } ]
[ { "docid": "03cffc21b4ef7acbfe0a6b4f097febac", "score": "0.65891737", "text": "protected function closeFile() {}", "title": "" }, { "docid": "a340ac431e6217132d283f2edc0e90bb", "score": "0.6578355", "text": "public function close()\n\t{\n\t\tif ($this->fileHandle)\n\t\t{\n\t\t\tfclose($this->fileHandle);\n\t\t\t$this->fileHandle = null;\n\t\t}\n\t}", "title": "" }, { "docid": "a340ac431e6217132d283f2edc0e90bb", "score": "0.6578355", "text": "public function close()\n\t{\n\t\tif ($this->fileHandle)\n\t\t{\n\t\t\tfclose($this->fileHandle);\n\t\t\t$this->fileHandle = null;\n\t\t}\n\t}", "title": "" }, { "docid": "644249e58ebea512f22031ac3295c282", "score": "0.6556261", "text": "public function closedir() {\n fclose($this->handle);\n }", "title": "" }, { "docid": "938de2cef35503d5661e991b5774c4c7", "score": "0.65184367", "text": "public function __destruct()\n {\n $this->closeFiles();\n }", "title": "" }, { "docid": "5318f5383bce419d19ae4e923b4522f6", "score": "0.64864457", "text": "private function closeFile()\n {\n fclose($this->handle);\n $this->handle = 0;\n }", "title": "" }, { "docid": "e80a5a5c8a905be4da6c22ca836a5d60", "score": "0.6464836", "text": "function _close() {}", "title": "" }, { "docid": "4c31c26ab7bd872d8354dee91aebab8b", "score": "0.64384824", "text": "public function __destruct() {\n if ( $this->fileHandle ) {\n fclose($this->fileHandle);\n }\n }", "title": "" }, { "docid": "837f5afa885cec5c5652529a0eca7013", "score": "0.6435545", "text": "public function __destruct()\n {\n $this->closeFile();\n }", "title": "" }, { "docid": "837f5afa885cec5c5652529a0eca7013", "score": "0.6435545", "text": "public function __destruct()\n {\n $this->closeFile();\n }", "title": "" }, { "docid": "74c1cebcbf5a982aa44139f6c4bebced", "score": "0.64284796", "text": "public function __destruct()\n {\n fclose($this->handle);\n }", "title": "" }, { "docid": "655fbe6dd56a0c43b24b9e45aefc3699", "score": "0.6393282", "text": "function close() {\n\t\tfclose($this->handle);\n\t}", "title": "" }, { "docid": "238b7b8c13b51c98c5a61cc8be71d3fa", "score": "0.6370588", "text": "function __destruct()\r\n {\r\n if ($this->handle) {\r\n fclose($this->handle);\r\n }\r\n }", "title": "" }, { "docid": "11f133ce51fbef714ebee6367a8c4d54", "score": "0.6365578", "text": "public function __destruct()\n\t{\n\t\tif ('\\\\' === \\DIRECTORY_SEPARATOR && file_exists($this->gitDir)) {\n\t\t\t(new Filesystem)->chmod($this->gitDir, 0755, 0000, true);\n\t\t}\n\n\t\t(new Filesystem)->remove($this->gitDir);\n\t}", "title": "" }, { "docid": "b79701c04fe2ec014f9a6520f98e44a6", "score": "0.6349805", "text": "public function __destruct() {\n if(is_resource($this->handle)) {\n $status = fclose($this->handle);\n }\n }", "title": "" }, { "docid": "c3733c230492e436adda3a2144f30247", "score": "0.6344066", "text": "public function __destruct()\n {\n if ($this->handle !== null) {\n \\fclose($this->handle);\n }\n }", "title": "" }, { "docid": "e75bef5ed31a3078bd2b02491023f4ba", "score": "0.62653196", "text": "public static function close()\n {\n self::$file = null;\n }", "title": "" }, { "docid": "b696c91afef9c5a205c744b8049af763", "score": "0.6262406", "text": "protected function close() {\n fclose($this->handle);\n }", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "a4bcb3c0edafef76fa62b11bb3d5e8b6", "score": "0.62610066", "text": "public function close();", "title": "" }, { "docid": "08640d8d12566ab714ea9e67cc5896b7", "score": "0.623109", "text": "public function flush() {\n foreach ($this->openedFiles as $handle) {\n fclose($handle);\n }\n }", "title": "" }, { "docid": "fc39af53e8aed20dece10ce27edca8ab", "score": "0.62096435", "text": "public function __destruct() {\n\t\tfclose($this->file);\n\t}", "title": "" }, { "docid": "7172d6aca0394860a4577e01b313eaa4", "score": "0.6204608", "text": "abstract public function close();", "title": "" }, { "docid": "7172d6aca0394860a4577e01b313eaa4", "score": "0.6204608", "text": "abstract public function close();", "title": "" }, { "docid": "7172d6aca0394860a4577e01b313eaa4", "score": "0.6204608", "text": "abstract public function close();", "title": "" }, { "docid": "7172d6aca0394860a4577e01b313eaa4", "score": "0.6204608", "text": "abstract public function close();", "title": "" }, { "docid": "cc0532938aa0f32c3eaf4fb7815c095d", "score": "0.61951095", "text": "public function closeFile() {\n\t\tfclose($this->_handle);\n\t}", "title": "" }, { "docid": "b283827044a31ab708f077a3a2cb5ce6", "score": "0.6189755", "text": "function __destruct() {\n fclose($this->file);\n }", "title": "" }, { "docid": "8241a069e38e9a6fa2ded00d70eca95a", "score": "0.6171531", "text": "function __destruct () {\n fclose($this->file);\n }", "title": "" }, { "docid": "80bfa7d26c89985d2f15337847325807", "score": "0.61609626", "text": "public abstract function close();", "title": "" }, { "docid": "3586dc8fc711a8f3c8268f61d2149927", "score": "0.61595947", "text": "function fclose ($handle) {}", "title": "" }, { "docid": "27c2cd912001f0dadb53bafe7016f5db", "score": "0.61570823", "text": "abstract protected function close();", "title": "" }, { "docid": "4cf29f5c5d82a1875dd64dfa514434b8", "score": "0.61397946", "text": "protected function closeFile() {\n if ($this->handle) {\n fclose($this->handle);\n\n $this->handle = null;\n }\n }", "title": "" }, { "docid": "0b7628b49c2305984e0473eca013fcbc", "score": "0.6135112", "text": "public function __destruct()\n {\n fclose($this->inotify);\n }", "title": "" }, { "docid": "4c7c32a9484d76fe7aef7e46e96f64d3", "score": "0.6134", "text": "function __destruct()\r\n\t{\r\n\t\tif ($this->readFile)\r\n\t\t\t@fclose($this->readFile);\r\n\t}", "title": "" }, { "docid": "1ef10a92eb6b0bb9b788cb4713d1727c", "score": "0.6132509", "text": "function closeHandle($handle){\n fclose($handle);\n}", "title": "" }, { "docid": "708bfbe9cabb48f36f7f44c706485423", "score": "0.6127491", "text": "public function __destruct() {\n fclose($this->file);\n }", "title": "" }, { "docid": "35b915bc39fbfe86df2f4829e9a9def0", "score": "0.6108976", "text": "private function closeHandle() \n {\n if ($this->_handle && is_resource($this->_handle)) {\n @fclose($this->_handle);\n }\n $this->_handle = null;\n }", "title": "" }, { "docid": "21086e7d9264f5a5880d543b918879ff", "score": "0.60966915", "text": "public function __destruct()\n {\n if (is_resource($this->handle)) {\n fclose($this->handle);\n }\n }", "title": "" }, { "docid": "b24695632eddb5a53f5ed668bfabc195", "score": "0.60876", "text": "public function fclose(): void {\n fclose($this->file);\n }", "title": "" }, { "docid": "661b88cd47ed4e136254b1611d0c7d6b", "score": "0.60707146", "text": "public function closeFile(){\n if(is_resource($this->_filePointer) === true){\n fclose($this->_filePointer);\n }\n }", "title": "" }, { "docid": "698e5dddc5c8db156e5be917a06648a5", "score": "0.60606205", "text": "function __destruct(){ $this->close(); }", "title": "" }, { "docid": "9fe8f66e5f223f0e053a29256279db98", "score": "0.60478956", "text": "public function __destruct()\n {\n if ( $this->fd )\n {\n fclose( $this->fd );\n $this->fd = null;\n }\n }", "title": "" }, { "docid": "40c0407915850879df183a3d928022ba", "score": "0.6041614", "text": "public function __destruct()\n {\n // no matter what, we want to close the handle as\n // soon as this instance is not needed anymore.\n fclose($this->handle);\n }", "title": "" }, { "docid": "d1317d8e7374a930efba060df42f5395", "score": "0.6039118", "text": "protected function closeLogFile() {}", "title": "" }, { "docid": "997b9df2d9c7d3ac997e70e91e88e41d", "score": "0.60382205", "text": "protected function close_handle() {\n\t\t// is_resource() only returns true for open resources\n\t\tif ( is_resource( $this->handle ) ) {\n\t\t\tfclose( $this->handle );\n\t\t}\n\t}", "title": "" }, { "docid": "2a6fbd3598cb5c6f83da4c1c1668176a", "score": "0.60195464", "text": "public function lclose() {\n\t\tfclose($this->fp);\n\t}", "title": "" }, { "docid": "2a6fbd3598cb5c6f83da4c1c1668176a", "score": "0.60195464", "text": "public function lclose() {\n\t\tfclose($this->fp);\n\t}", "title": "" }, { "docid": "0fa0cb1d51b318d72af8fd4ec1fca0d1", "score": "0.60141397", "text": "public function close()\n {\n // Free the file resource\n if ($this->fh)\n {\n fclose($this->fh);\n }\n }", "title": "" }, { "docid": "8e8186a752f2b8da801dd9dc94d467e0", "score": "0.6005667", "text": "public function close() {}", "title": "" }, { "docid": "8e8186a752f2b8da801dd9dc94d467e0", "score": "0.6005", "text": "public function close() {}", "title": "" }, { "docid": "d5d24f38ef4ab27b868e84c9f1d86097", "score": "0.6004736", "text": "function close() {}", "title": "" }, { "docid": "8e8186a752f2b8da801dd9dc94d467e0", "score": "0.60044986", "text": "public function close() {}", "title": "" }, { "docid": "a9851eb4d51c9dd7cef9955fe910db72", "score": "0.59921783", "text": "function __destruct(){\n\t\tfclose($this->fptr);\n\t}", "title": "" }, { "docid": "d864bc6443cd0f86df474df8081eabe6", "score": "0.5989569", "text": "public function close()\n {\n if (null !== $this->handle && \\is_resource($this->handle)) {\n fclose($this->handle);\n $this->handle = null;\n }\n }", "title": "" }, { "docid": "9305f5f76c761c514793a8e7ba5fb506", "score": "0.59886974", "text": "public function close() {\n\t\tparent::close();\n\t\tif ($this->lockFileName == null) {\n\t\t\treturn;\n\t\t}\n\t\ttry {\n\t\t\t// Close the lock file channel (Which will also free any locks)\n\t\t\t$this->lockFileChannel->close();\n\t\t} catch ( \\Exception $e ) {\n\t\t\t// Problems closing the stream. Punt.\n\t\t}\n\t\tself::$locks->remove( $this->lockFileName );\n\t\t\n\t\t// Unlink (delete) the lock file\n\t\t$f = new File( $this->lockFileName );\n\t\t$f->delete();\n\t\t\n\t\t$this->lockFileName = null;\n\t\t$this->lockFileChannel = null;\n\t}", "title": "" }, { "docid": "d33b5deab9d932c11f2cb09a355c0826", "score": "0.5972042", "text": "public function close() {\n\t\t$this->control = new FileControl( $this );\n\t}", "title": "" }, { "docid": "5e653a3aed50b654ad38f6459ae9c1ee", "score": "0.59705013", "text": "public function __destruct() {\n $this->close();\n }", "title": "" }, { "docid": "650eca255f9570888cf06b4d01f1b125", "score": "0.5961454", "text": "public function close()\n {\n curl_close($this->ch);\n if ($this->file != null) {\n fclose($this->file);\n }\n }", "title": "" }, { "docid": "c81200d6058ae98eeba4696ca663bc4d", "score": "0.594731", "text": "function __destruct() {\n $this->close();\n }", "title": "" }, { "docid": "606f1912cff71860ac829a81393eaaa6", "score": "0.5930495", "text": "private function closeAndAttemptToCleanupAllFiles()\n {\n // close the writer, which should remove all temp files\n $this->close();\n\n // remove output file if it was created\n if ($this->globalFunctionsHelper->file_exists($this->outputFilePath)) {\n $outputFolderPath = \\dirname($this->outputFilePath);\n $fileSystemHelper = $this->helperFactory->createFileSystemHelper($outputFolderPath);\n $fileSystemHelper->deleteFile($this->outputFilePath);\n }\n }", "title": "" }, { "docid": "3066b4c4a6a8168cd6cf1ab0cac94282", "score": "0.5917256", "text": "function __destruct(){\n\t\t$this->close();\n\t}", "title": "" }, { "docid": "fa857b451af2a84cf77f0d43c6b6eda8", "score": "0.5916848", "text": "private function closeFile()\n {\n if (isset($this->fileResource)) {\n fclose($this->fileResource);\n $this->isOpenForRead = false;\n }\n }", "title": "" }, { "docid": "533f69b9832ac3b989d922c6e7ab0cbd", "score": "0.59157735", "text": "function __destruct() { \n $this->close();\n }", "title": "" }, { "docid": "0ed157e740068aa93175f547ae2fd3ca", "score": "0.5906704", "text": "public function __destruct() {\n $this->close();\n }", "title": "" }, { "docid": "245c778cb7c6f1db3ecb74226e3179f6", "score": "0.59021604", "text": "function pclose ($handle) {}", "title": "" }, { "docid": "6e42f6be392ee53e67051078c36465d1", "score": "0.58855766", "text": "public function __destruct()\n\t{\n\t\tif($this->isOpened())\n\t\t\t$this->close();\n\t}", "title": "" }, { "docid": "a27755a229db78ec7d78424bbc1538a6", "score": "0.5879879", "text": "public function import_close_file()\n\t{\n // phpcs:enable\n\t\tfclose($this->handle);\n\t\treturn 0;\n\t}", "title": "" }, { "docid": "b4c927aa2729af56f70798d0472cdcd5", "score": "0.5873934", "text": "public function __destruct()\n\t{\n\t\tif ($this->_getIsOpen())\n\t\t{\n\t\t\t$this->close();\n\t\t}\n\t}", "title": "" }, { "docid": "06575108dc387b086e5f43442f945cdb", "score": "0.5865546", "text": "function __destruct()\n {\n $this->close();\n }", "title": "" }, { "docid": "29cda57707b48c1de1207ee0bc35a5a5", "score": "0.58638126", "text": "public function close()\n\t{\n\t\tif (is_resource($this->handle)) {\n\t\t\t$this->exitCode = pclose($this->handle);\n\t\t}\n\t\t$this->handle = null;\n\t}", "title": "" }, { "docid": "323382c2e5247262f0aa59d480862ab4", "score": "0.5856182", "text": "public function __destruct() {\n $this->_closeFile();\n ini_set('auto_detect_line_endings', false);\n }", "title": "" }, { "docid": "3f4d17b8fc96c4416ea2d7b55404277a", "score": "0.58484256", "text": "public function __destruct()\n {\n if ( isset( $this->read_handle ) )\n {\n fclose( $this->read_handle );\n }\n }", "title": "" }, { "docid": "027c5666d65a4df3308e25948b23189e", "score": "0.5847916", "text": "public function close()\n {\n fclose($this->file);\n }", "title": "" }, { "docid": "a0cc651e8b2c0df47023835f8d9bde11", "score": "0.5842666", "text": "public function close(): void;", "title": "" }, { "docid": "a0cc651e8b2c0df47023835f8d9bde11", "score": "0.5842666", "text": "public function close(): void;", "title": "" }, { "docid": "a0cc651e8b2c0df47023835f8d9bde11", "score": "0.5842666", "text": "public function close(): void;", "title": "" }, { "docid": "3ba1bc82dbf8f28882b536078a49502e", "score": "0.5842282", "text": "public function stream_close() {\n fclose($this->handle);\n }", "title": "" }, { "docid": "7fc2eb4fc6abc3cbeef91400796c83db", "score": "0.5836726", "text": "public function __destruct()\n {\n $this->close();\n }", "title": "" }, { "docid": "7fc2eb4fc6abc3cbeef91400796c83db", "score": "0.5836726", "text": "public function __destruct()\n {\n $this->close();\n }", "title": "" }, { "docid": "7fc2eb4fc6abc3cbeef91400796c83db", "score": "0.5836726", "text": "public function __destruct()\n {\n $this->close();\n }", "title": "" }, { "docid": "7fc2eb4fc6abc3cbeef91400796c83db", "score": "0.5836726", "text": "public function __destruct()\n {\n $this->close();\n }", "title": "" }, { "docid": "7fc2eb4fc6abc3cbeef91400796c83db", "score": "0.5836726", "text": "public function __destruct()\n {\n $this->close();\n }", "title": "" }, { "docid": "7fc2eb4fc6abc3cbeef91400796c83db", "score": "0.5836726", "text": "public function __destruct()\n {\n $this->close();\n }", "title": "" }, { "docid": "044b88fb642bb87784b409acd401a51c", "score": "0.5832602", "text": "public function __destruct ()\n {\n $this->close();\n }", "title": "" } ]
6249dd7caee85ea1c5fc8c56f148df50
Gets the transparent color of this image
[ { "docid": "68c787dd7b2e8fc7d9cbc1e7e8bc0f1b", "score": "0.82758296", "text": "public function getTransparentColor();", "title": "" } ]
[ { "docid": "89fe74eb5329a9555b2474a3ebcd0abf", "score": "0.76798975", "text": "public function getImageTransparent() {\r\n return $this->imageTransparent;\r\n }", "title": "" }, { "docid": "ae7a308e5d797b63aac38d7cfc0f6a67", "score": "0.7579252", "text": "public function getTransparency() { \r\n return (127*$this->internalTransparency/100);\r\n }", "title": "" }, { "docid": "31ef410ebb99340b17e593f07a2173ba", "score": "0.74489063", "text": "public function getTransparent() \n\t{\n\t\treturn $this->_transparent;\n\t}", "title": "" }, { "docid": "47e5da451e539467ac19368ffac70f5e", "score": "0.7396251", "text": "public function getTransparentColorIndex()\n {\n return $this->propertyIsSet('transparentColorIndex') \n ? $this->transparentColorIndex \n : $this->decodeTransparentColorIndex();\n }", "title": "" }, { "docid": "e8d7672a42f66536e3a58d78f1f4bc87", "score": "0.7251338", "text": "public function getBgdTransparent()\n {\n return $this->bgdTransparent;\n }", "title": "" }, { "docid": "e40a3fb452a4d6f5c8e493fc36599bed", "score": "0.67319614", "text": "public function get_color_overlay_transparency_value() {\n\n\t\t$default = $this->get_color_overlay_transparency_default_value();\n\n\t\treturn sprintf( '%.2f', absint( get_theme_mod( 'hero_image_color_overlay', $default ) ) * 0.01 );\n\n\t}", "title": "" }, { "docid": "607502ee8dcd8346a857ede37500471e", "score": "0.6608479", "text": "public function decodeTransparentColorIndex()\n {\n if ($this->graphicsControlExtension) {\n return substr($this->graphicsControlExtension, 4, 1);\n }\n\n return false; \n }", "title": "" }, { "docid": "bd0c042b429cf599e58b365201c7c8a0", "score": "0.64371383", "text": "public function get_color_overlay_transparency_default_value() {\n\n\t\t/**\n\t\t * Filter the default hero image color overlay transparency value.\n\t\t *\n\t\t * @since 1.0.0\n\t\t *\n\t\t * @var int\n\t\t */\n\t\treturn (int) apply_filters( 'primer_hero_image_color_overlay_default', 50 );\n\n\t}", "title": "" }, { "docid": "629a51b19c72fc77298dd71319a89e8d", "score": "0.64347744", "text": "private function getImageFillColor(): string\n {\n return $this->getData('image_fill_color') ?? 'rgba(240,240,240,0.5)';\n }", "title": "" }, { "docid": "762b318c1698ef800d44cb020232decd", "score": "0.6382997", "text": "public function getInverted() {\n $histogram = $this->getimagehistogram();\n $imagick_pixel = end($histogram);\n $colors = $imagick_pixel->getColor();\n foreach ($colors as $i => $color) {\n $colors[$i] = 255 ^ $color;\n }\n\n $new_imagick_pixel = new \\ImagickPixel('rgb(' . $colors['r'] . ',' . $colors['g'] . ',' . $colors['b'] . ')');\n return $new_imagick_pixel;\n }", "title": "" }, { "docid": "64e370f1c2a34663fb37ce9bcc2b52bf", "score": "0.6221821", "text": "public function getBackgroundImageOpacity(): float {}", "title": "" }, { "docid": "df712c837bbb410fa2c7b1adcd81383d", "score": "0.61536896", "text": "public function rgba(): string;", "title": "" }, { "docid": "5b1df552294fd7d8d5710cdce52d7fca", "score": "0.6090522", "text": "public function hasTransparentColor()\n {\n if ($this->graphicsControlExtension) {\n $byte = substr($this->graphicsControlExtension, 1, 1);\n $byte = unpack('C', $byte)[1];\n $bit = $byte & bindec('00000001');\n\n return (bool) $bit;\n }\n\n return false;\n }", "title": "" }, { "docid": "5239384f1e19a0ffe960ce5b5758f137", "score": "0.6057772", "text": "public function getBackgroundColor ()\n {\n return $this->getBorderHistogram()->getDominantColor();\n }", "title": "" }, { "docid": "fcef0305e41bcac9991fbbaa0d33c765", "score": "0.60421014", "text": "public function getAlpha()\n\t{\n\t\treturn $this->rgb['a'];\n\t}", "title": "" }, { "docid": "6796f3b6ac39a1e7a26e08aed89b4a34", "score": "0.5943622", "text": "public function getOverlayBgColor()\n {\n return Mage::getStoreConfig(self::XML_PATH_CONFIG_OVERLAY_BG_COLOR);\n }", "title": "" }, { "docid": "8cc9e7f058157369d5e61a76e4320fa1", "score": "0.59413934", "text": "function setTransparentColor(gdColor | int $color = -1) : gdColor | int\n\t\t{\n\t\t}", "title": "" }, { "docid": "63eaa62fc0c2f7ed2ea3360e96ff5cc6", "score": "0.5928322", "text": "public function getColor()\n\t{\n\t\treturn $this->color;\n\t}", "title": "" }, { "docid": "63eaa62fc0c2f7ed2ea3360e96ff5cc6", "score": "0.5928322", "text": "public function getColor()\n\t{\n\t\treturn $this->color;\n\t}", "title": "" }, { "docid": "093d9378caa6a046113278d0b930786f", "score": "0.59244835", "text": "public function getColor() {\n\t\treturn $this->color;\n\t}", "title": "" }, { "docid": "093d9378caa6a046113278d0b930786f", "score": "0.59244835", "text": "public function getColor() {\n\t\treturn $this->color;\n\t}", "title": "" }, { "docid": "3d0555d981f99b24c242403752caee63", "score": "0.5911918", "text": "public function getOverlayOpacity()\n {\n return (float)Mage::getStoreConfig(self::XML_PATH_CONFIG_OVERLAY_BG_OPACITY);\n }", "title": "" }, { "docid": "15da95c2c8014a6b0e6390bdf611252c", "score": "0.58922297", "text": "public function getOpacity()\r\n {\r\n return $this->opacity;\r\n }", "title": "" }, { "docid": "bb92731d3e57c01dd2fdd46b1c353105", "score": "0.5869118", "text": "protected function _getDrawColor($image)\r\n\t{\r\n\t\treturn imagecolorallocatealpha($image, $this->_color->getR(), $this->_color->getG(), $this->_color->getB(), $this->_transparency->getTransparency());\r\n\t}", "title": "" }, { "docid": "509336b6cf1a277fdeb88f4a3df0826d", "score": "0.5868246", "text": "public function getColor()\n {\n return $this->color;\n }", "title": "" }, { "docid": "fd66f38c41d2592518d08b7db000be3d", "score": "0.5864321", "text": "public function getColor()\n {\n return $this->color;\n }", "title": "" }, { "docid": "fd66f38c41d2592518d08b7db000be3d", "score": "0.5864321", "text": "public function getColor()\n {\n return $this->color;\n }", "title": "" }, { "docid": "fd66f38c41d2592518d08b7db000be3d", "score": "0.5864321", "text": "public function getColor()\n {\n return $this->color;\n }", "title": "" }, { "docid": "fd66f38c41d2592518d08b7db000be3d", "score": "0.5864321", "text": "public function getColor()\n {\n return $this->color;\n }", "title": "" }, { "docid": "fd66f38c41d2592518d08b7db000be3d", "score": "0.5864321", "text": "public function getColor()\n {\n return $this->color;\n }", "title": "" }, { "docid": "fd66f38c41d2592518d08b7db000be3d", "score": "0.5864321", "text": "public function getColor()\n {\n return $this->color;\n }", "title": "" }, { "docid": "6a0488e033a4e7b2f984b3e45b23d0ef", "score": "0.5819392", "text": "public function getColor() {\r\n return $this->color;\r\n }", "title": "" }, { "docid": "da0a2e841284729c396e183c7d2afc65", "score": "0.58077985", "text": "public function getColor()\n {\n return $this->Color;\n }", "title": "" }, { "docid": "aac1677c406993569300d7f09f560768", "score": "0.57723296", "text": "public function isTransparent()\n\t{\n\t\treturn $this->isTransparent;\n\t}", "title": "" }, { "docid": "787ad9e80702b670bfe02521065686f5", "score": "0.5752232", "text": "function get_color()\n {\n return $this->color;\n }", "title": "" }, { "docid": "08b070e2f14eb0c321f2e1f881df4047", "score": "0.57339275", "text": "public function getColor() {\n return $this->color;\n }", "title": "" }, { "docid": "c2a5d4c8f52fa3f8be074ead231b72e5", "score": "0.57298696", "text": "public function getProductColorImage() \n {\n return $this->product_color_image;\n }", "title": "" }, { "docid": "4b163e01021f946f3874c5dc33fad791", "score": "0.57289124", "text": "function getColor() {\r\n\t\t$params\t\t=& new mosParameters( $this->cat_params );\r\n\t\treturn $params->get( 'color' , '');\r\n\t}", "title": "" }, { "docid": "628b7832e1103dc0749956429b6c9658", "score": "0.56740206", "text": "protected static function retainImageTransparency($img)\n {\n imagecolortransparent($img, imagecolorallocatealpha($img, 0, 0, 0, 127));\n imagealphablending($img, false);\n imagesavealpha($img, true);\n }", "title": "" }, { "docid": "72f10ca562db6457181823a31fa0cc7e", "score": "0.5652246", "text": "function GetBackgroundColor()\n\t{\n\t\tarray_push($this->FMDebug, \"GetBackgroundColor\");\n\n\t\tarray_pop($this->FMDebug);\n\n\t\treturn $this->BackgroundColor;\n\t}", "title": "" }, { "docid": "8d4f4bd5cc77da62b16cda1c5b1f72b0", "score": "0.5651157", "text": "public function getBackgroundColor()\n {\n return 'white';\n }", "title": "" }, { "docid": "e6cf35d207b786822941c4ea4fefef61", "score": "0.564888", "text": "public function getBackgroundColor() {\r\n }", "title": "" }, { "docid": "41361d1dda56191f8aea7f3ad7488b7f", "score": "0.5644492", "text": "function imagecolorexactalpha($image, $red, $green, $blue, $alpha)\n{\n}", "title": "" }, { "docid": "adced857af0172d407e111a44d4d5e5d", "score": "0.56279135", "text": "public function toRGBA()\n {\n return 'rgba(' . (int) $this->red . ',' . (int) $this->green. ','\n . (int) $this->blue . ',' . $this->alpha . ')';\n }", "title": "" }, { "docid": "9848b1c0aab714cab9e50fb74c36b79c", "score": "0.5615129", "text": "function getColor()\n {\n return $this->color;\n }", "title": "" }, { "docid": "62762913bc21d7a0050bebfab4535f7d", "score": "0.5607666", "text": "public function getBackgroundColor()\n {\n return $this->backgroundColor;\n }", "title": "" }, { "docid": "62762913bc21d7a0050bebfab4535f7d", "score": "0.5607666", "text": "public function getBackgroundColor()\n {\n return $this->backgroundColor;\n }", "title": "" }, { "docid": "62762913bc21d7a0050bebfab4535f7d", "score": "0.5607666", "text": "public function getBackgroundColor()\n {\n return $this->backgroundColor;\n }", "title": "" }, { "docid": "62762913bc21d7a0050bebfab4535f7d", "score": "0.5607666", "text": "public function getBackgroundColor()\n {\n return $this->backgroundColor;\n }", "title": "" }, { "docid": "41849d9b6874e8bd93077eea813f209d", "score": "0.5602941", "text": "public function getColor() {\n\n if($this->color) {\n return $this->color;\n }\n\n return 'farbe eingeben';\n }", "title": "" }, { "docid": "ba8c768ff827fe4a31bcbc953e49cf89", "score": "0.55851", "text": "function get_background_color() {}", "title": "" }, { "docid": "7d0f5d9edf844ddc90ece2dcee774f5c", "score": "0.55254406", "text": "public function getColor(): string\n {\n return $this->color;\n }", "title": "" }, { "docid": "a11b7cb7403ff1f7f483689e3b480679", "score": "0.5525316", "text": "public function getBackgroundColor()\n {\n if (isset($_SESSION['backgroundColor'])){\n return $_SESSION['backgroundColor'];\n } else {\n return 'white';\n }\n }", "title": "" }, { "docid": "6acfb81fa62689e3fe1a3d38b6ca09d4", "score": "0.55125725", "text": "public function backgroundColor()\n {\n if ($GLOBALS['calendar_manager']->getEntry(Kronolith::ALL_CALENDARS, $this->calendar) !== false) {\n return $GLOBALS['calendar_manager']->getEntry(Kronolith::ALL_CALENDARS, $this->calendar)->background();\n }\n return '#dddddd';\n }", "title": "" }, { "docid": "54716fd1ddd84fb5e1e048fca3cc4a3e", "score": "0.5502897", "text": "public function getColor(){\n return $this->Color;\n }", "title": "" }, { "docid": "186dd17ce7cb766e63a873b5f61cf8b3", "score": "0.5500953", "text": "public function getEyeColor(){\n\t\treturn $this->eyeColor;\n\t}", "title": "" }, { "docid": "da0be516e38f55701a4d43dcbf67dadb", "score": "0.5500419", "text": "public function backsideBackgroundColor()\n {\n return $this->backsideBackgroundColor;\n }", "title": "" }, { "docid": "6dc9dcbfb9594a80b98bd67179c99f63", "score": "0.5478595", "text": "public function getColor() : string\r\n {\r\n return $this->color;\r\n }", "title": "" }, { "docid": "7bb0f1b09180c241cff67994b59267ef", "score": "0.54523265", "text": "public function getColor();", "title": "" }, { "docid": "7bb0f1b09180c241cff67994b59267ef", "score": "0.54523265", "text": "public function getColor();", "title": "" }, { "docid": "7c5ff98978143b6eb5a95874dc2bc44d", "score": "0.54451746", "text": "public function hasAlphaTransparency();", "title": "" }, { "docid": "8b4c2ea4d381b263d3aa189bf829c837", "score": "0.54371667", "text": "public function get_color()\n {\n if ($this->subject->color) {\n return $this->subject->color;\n } else {\n return $this->category->color;\n }\n }", "title": "" }, { "docid": "a39c5458f339cd18a9ce15e9595cec7e", "score": "0.54338807", "text": "public function getBgColor() {\n\t\treturn $this->colors['bgc'];\n\t}", "title": "" }, { "docid": "28dd8e4b794d159e5695c1c104eb026d", "score": "0.54335475", "text": "public function getBackgroundColor()\n {\n return $this->getProperty('bg-color');\n }", "title": "" }, { "docid": "cdabb840854568e80b5740351397056d", "score": "0.542713", "text": "function getBackgroundColor() {\r\n return $this->params['bgcolor'];\r\n }", "title": "" }, { "docid": "dfbc435c72e89e77c4e7f54dc5261f3b", "score": "0.542364", "text": "private function addTransparencyToImage($im)\n {\n imagealphablending($im, false);\n $transparency = imagecolorallocatealpha($im, 0, 0, 0, 127);\n imagefill($im, 0, 0, $transparency);\n imagesavealpha($im, true);\n\n return $im;\n }", "title": "" }, { "docid": "0cb8f2fcb68d6718bd39c61ae84d94fc", "score": "0.54173434", "text": "public function getColor() {\n\n // $this-> significa busca en esta clase el valor de la propiedad X\n\n return $this->color;\n\n }", "title": "" }, { "docid": "35e83e4f940368b6236ac0fccf637f6c", "score": "0.540929", "text": "public function getColor()\n {\n switch ($this->id) {\n case 1:\n return '#00a4ef';\n break;\n case 2:\n return '#003087';\n break;\n case 3:\n return '#0e7a0d';\n break;\n case 4:\n return '#e60012';\n break;\n default:\n return '#000000';\n }\n }", "title": "" }, { "docid": "303d71ee3ea63c36735b108cbd6c7aa4", "score": "0.54061997", "text": "public function color() {\n return $this->_color;\n }", "title": "" }, { "docid": "c85462bddb46a70671132e8393937442", "score": "0.53848577", "text": "function captcha_color(&$image, $min = 75, $max = 125, $alpha = 0) {\n $r = mt_rand($min, $max);\n $g = mt_rand($min, $max);\n $b = mt_rand($min, $max);\n\n $color = imagecolorexactalpha($image, $r, $g, $b, $alpha);\n if ($color < 0) {\n $color = imagecolorallocatealpha($image, $r, $g, $b, $alpha);\n }\n\n return $color;\n }", "title": "" }, { "docid": "7a79b344d2198466a93cb0baf589f048", "score": "0.53771853", "text": "public function hasTransparency()\r\n\t{\r\n\t\treturn !is_null($this->_transparency);\r\n\t}", "title": "" }, { "docid": "24906ddf85c7aeebdb45977ff6b73b76", "score": "0.53697604", "text": "public function getColorIndex()\n\t{\n\t\tif (!$this->index){\n\t\t\t$this->index = Color::createColorIndex($this->rgb['r'], $this->rgb['g'], $this->rgb['b'], $this->rgb['a']);\n\t\t}\n\t\treturn $this->index;\n\t}", "title": "" }, { "docid": "11d6e96845c08ac32833085924f1187f", "score": "0.5366127", "text": "public function backsideColor()\n {\n return $this->backsideColor;\n }", "title": "" }, { "docid": "551470cd543eb64882d15f6f5d135b0f", "score": "0.53479564", "text": "public function getStatusBackgroundColor()\n\t{\n\t\treturn $this->status_bg_color;\n\t}", "title": "" }, { "docid": "67f6aa46a98419be9949af9c8f41eb87", "score": "0.5301626", "text": "public function get_colormap()\n\t{\n\t\treturn $this->colormap;\n\t}", "title": "" }, { "docid": "982c4cefb05b24ff21d52dedf443ac49", "score": "0.5286071", "text": "static public function get_color() {\n\t\t$r = rand( 40, 140 );\n\t\t$g = rand( 40, 140 );\n\t\t$b = rand( 40, 140 );\n\t\treturn '#' . dechex( $r ) . dechex( $g ) . dechex( $b );\n\t}", "title": "" }, { "docid": "ebe105e367e65a95e219fc60e9b3d0b2", "score": "0.52803063", "text": "function getEyeColor()\n\t{\n\t\t$query = mysql_query(\"SELECT * FROM sr_eye_color WHERE status=1\");\n\t\treturn ( mysql_num_rows($query)>0 )?$query:0;\n\t}", "title": "" }, { "docid": "0103e67bd820cdda0f4a854dbeed3c67", "score": "0.5278025", "text": "public function getColor(){\n\n\t\t// no need to change this for dames.\n\t\t// It's not possible so double-hit when first hit goes to dame and next hit goes elsewhere\n\t\treturn $this->color;\n\t}", "title": "" }, { "docid": "2da808c8f1912e2be7218448e0dd5e4e", "score": "0.52587336", "text": "function grab_color() {\n\t\t$img = $this->image_obj;\n\t\tif ( ! $img )\n\t\t\treturn false;\n\n\t\t$rgb = self::grab_points();\n\n\t\t// Process the color points\n\t\t// Find the average representation\n\t\tforeach ( $rgb as $color ) {\n\t\t\t$index = imagecolorsforindex( $img, $color );\n\t\t\t$r[] = $index['red'];\n\t\t\t$g[] = $index['green'];\n\t\t\t$b[] = $index['blue'];\n\n\t\t\t$red = round( array_sum( $r ) / 5 );\n\t\t\t$green = round( array_sum( $g ) / 5 );\n\t\t\t$blue = round( array_sum( $b ) / 5 );\n\t\t}\n\n\t\t// The average color of the image as rgb array\n\t\t$color = array(\n\t\t\t'r' => $red,\n\t\t\t'g' => $green,\n\t\t\t'b' => $blue,\n\t\t);\n\n\t\treturn $color;\n\t}", "title": "" }, { "docid": "ac3133d77bd983b3dd1c24ee17eb17c7", "score": "0.52495927", "text": "public function invertColors(): ImageBase {\n imagefilter($this->resource, IMG_FILTER_NEGATE);\n return $this;\n }", "title": "" }, { "docid": "02d38e416d9237f2409cc9bd128a3dad", "score": "0.52441674", "text": "public function getOpcolor()\n {\n return $this->_opcolor;\n }", "title": "" }, { "docid": "dedc6baf2db6cd2b3bd01c386e81e1c2", "score": "0.5241808", "text": "public function getbackgroundBits(): ?int\n {\n return $this->backgroundBits;\n }", "title": "" }, { "docid": "f21ee9fc11fa5027ffc87846f0a8728f", "score": "0.5227779", "text": "function color( $type = 'hex' ) {\n\t\t// Bail if there is no image to work with\n\t \tif ( ! $this->image_obj )\n\t\t\treturn false;\n\n\t\t// Finds dominant color\n\t\t$color = self::grab_color();\n\t\t// Passes value to Color class\n\t\t$color = self::get_color( $color, $type );\n\t\treturn $color;\n\t}", "title": "" }, { "docid": "1094af1d5299c21e5f8f09ae601db48a", "score": "0.5209526", "text": "public function getRGB()\n {\n return str_pad((string) $this->getRed(), 3, '0', STR_PAD_LEFT) .\n str_pad((string) $this->getGreen(), 3, '0', STR_PAD_LEFT) .\n str_pad((string) $this->getBlue(), 3, '0', STR_PAD_LEFT);\n }", "title": "" }, { "docid": "ad772c9ac7e45489ce8af015b4ed2444", "score": "0.52039635", "text": "public function getColor() {\n\t\treturn 'rgb('.rand(0,255).','.rand(0,255).','.rand(0,255).')';\n\t}", "title": "" }, { "docid": "7349620a12711b4f4f9f4446dabedbeb", "score": "0.51940227", "text": "public function getHex()\n {\n $rgb['red'] = str_pad(dechex($this->getRed()), 2, '0', STR_PAD_LEFT);\n $rgb['green'] = str_pad(dechex($this->getGreen()), 2, '0', STR_PAD_LEFT);\n $rgb['blue'] = str_pad(dechex($this->getBlue()), 2, '0', STR_PAD_LEFT);\n\n return strtoupper(implode($rgb));\n }", "title": "" }, { "docid": "e135a5f5ec869cdef7239d4d94b6c248", "score": "0.5184341", "text": "public function rgb(): string;", "title": "" }, { "docid": "f9532662a8ef593a7be8ecb7b2a7c18a", "score": "0.5174824", "text": "public function getInvertedColoursUnsetCode() : string\n {\n return $this->invertedColoursUnsetCode;\n }", "title": "" }, { "docid": "99c07e7d8e8a9c1c4e111ae97d04003a", "score": "0.51716995", "text": "public function getStatusColor()\n\t{\n\t\treturn $this->status_color;\n\t}", "title": "" }, { "docid": "15dc1abc4a6413ff857a6c58553a120e", "score": "0.51601493", "text": "protected function jpgBg() {\n $bg = $this->createGd($this->width, $this->height);\n imagefilledrectangle($bg, 0, 0, $this->width, $this->height, $this->getColor(0xffffff, 1));\n imagealphablending($bg, true);\n imagecopy($bg, $this->image, 0, 0, 0, 0, $this->width, $this->height);\n imagealphablending($bg, false);\n return $bg;\n }", "title": "" }, { "docid": "f780780c2ebe17dc46001bc539b4cc58", "score": "0.51510763", "text": "public function setImageTransparent($value) {\r\n $this->imageTransparent = $this->setBooleanProperty($this->imageTransparent, $value);\r\n }", "title": "" }, { "docid": "f483dff49c4b4baa3e4a2d079dc5dea4", "score": "0.51436293", "text": "public function getColorID() {\n\t\treturn $this->colorID;\n\t}", "title": "" }, { "docid": "c542c8d2c96f333d263466b53dc1e5bc", "score": "0.5141245", "text": "function createImageKeepTransparency($width, $height) {\n $img = imagecreatetruecolor($width, $height);\n imagealphablending($img, false);\n imagesavealpha($img, true); \n return $img;\n}", "title": "" }, { "docid": "a2653ac73118899a60b1507e282c5a58", "score": "0.51273197", "text": "public function rgbaToHex8(int $red, int $green, int $blue, float $alpha = 1): string;", "title": "" }, { "docid": "056bf06efb50705dfda019cff73f1939", "score": "0.51217073", "text": "public function get_rgba_css() {\n\n\t\t$colors = array();\n\n\t\tforeach ( $this->colors as $name => $args ) {\n\n\t\t\tif ( ! empty( $name ) && ! empty( $args['rgba_css'] ) && is_array( $args['rgba_css'] ) ) {\n\n\t\t\t\t$colors[ $name ] = $args['rgba_css'];\n\n\t\t\t}\n\t\t}\n\n\t\treturn $colors;\n\n\t}", "title": "" }, { "docid": "681c1bc8fde7ca5fcbfba1e936331f9c", "score": "0.511973", "text": "function Monochrome(&$img, $color_channel){\n $width = imagesx($img);\n $height = imagesy($img);\n \n // Allocate resource in memory for the image\n $monochrome = imagecreatetruecolor($width, $height);\n $background = imagecolorallocate($monochrome, 0, 0, 0);\n \n // Loop through pixels\n for($row = 0; $row < $width; $row++){\n for($col = 0; $col < $height; $col++){\n \n // Get pixel color channels \n $p = imagecolorat($img, $row, $col);\n $colors = imagecolorsforindex($img, $p);\n \n // Extract desired channel\n if($color_channel == RED){\n $pixelcolor = imagecolorallocate($monochrome, $colors['red'], 0, 0);\n }\n elseif($color_channel == GREEN){\n $pixelcolor = imagecolorallocate($monochrome, 0, $colors['green'], 0);\n }\n elseif($color_channel == BLUE){\n $pixelcolor = imagecolorallocate($monochrome, 0, 0, $colors['blue']);\n }\n else{\n $pixelcolor = $background;\n }\n \n // Change pixel to contain pure channel\n imagesetpixel($monochrome, $row, $col, $pixelcolor);\n }\n }\n return $monochrome;\n}", "title": "" }, { "docid": "3893ed352a12e3c3152712a2c5e1fe22", "score": "0.51157105", "text": "public function getBackgroundImage(): string {}", "title": "" }, { "docid": "5a06bbb3bb536ed641b1c00132291f1b", "score": "0.51133436", "text": "function im_getTopLeftPixelColor($image, $as_hex = true){\n\t\t$result = false;\n\t\t$command = 'convert \"'.$image.'\"[1x1+0+0] -format \"%[fx:int(255*r)],%[fx:int(255*g)],%[fx:int(255*b)]\" info:';\n\t\t$return = exec($command);\n\t\t$result = explode(\",\", $return);\n\t\tif($as_hex){\n\t\t\t$result = sprintf(\"%02X%02X%02X\", $result[0], $result[1], $result[2]);\n\t\t}\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "2db87dbc2a2846455bcd5e5a83920bf8", "score": "0.50924903", "text": "public function getCatColor() : string {\n\t\treturn($this->catColor);\n\t}", "title": "" }, { "docid": "b39c02014ab8df8cf65b98f8ab5bfad6", "score": "0.50879216", "text": "public function transparentToColor($hexColor){\n\t\t\n\t\t// If it's a gif, apply to each\n\t\tif(is_array($this->gif_sources)){\n\t\t\tforeach($this->gif_sources as $img)\n\t\t\t\t$img->transparentToColor($hexColor);\n\t\t\treturn $this;\n\t\t}\n\t\t\n\t\t$newColor = self::getColorFromHex($this->image, $hexColor);\t\t\n\t\t$image_width = imagesx($this->image);\n\t\t$image_height = imagesy($this->image);\n\t\tfor($x = $image_width; $x--;){\n\t\t\tfor($y = $image_height; $y--;){\n\t\t\t\t$color = self::getPixelRGBA($x, $y);\n\t\t\t\tif($color['alpha'] == 127)\n\t\t\t\t\timagesetpixel($this->image, $x, $y, $newColor);\n\t\t\t}\n\t\t}\n\t\treturn $this;\n\t}", "title": "" } ]
a6d28bcfc1f5f0e5997ec3c010217bbe
Update the specified resource in storage.
[ { "docid": "ce79bc03286a0039ad2282a6c06bd19a", "score": "0.0", "text": "public function update(Request $request, $id)\n {\n $product= \\App\\Product::find($id);\n\n $request->validate([\n 'name' => 'required|max:255|unique:products,name,'.$product->id,\n 'description' => 'required|max:255',\n 'constructor_reference' => 'required|max:255|unique:products,constructor_reference,'.$product->id,\n 'connexing_reference' => 'required|max:255|unique:products,connexing_reference,'.$product->id,\n 'price' => 'required|max:255',\n 'url_ecommerce' => 'required|max:255',\n 'category_id' => 'required',\n 'brand_id' => 'required',\n ]);\n\n $product->name=$request->get('name');\n $product->description=$request->get('description');\n $product->constructor_reference=$request->get('constructor_reference');\n $product->connexing_reference=$request->get('connexing_reference');\n $product->price=$request->get('price');\n $product->url_ecommerce=$request->get('url_ecommerce');\n $product->external_url_img=$request->get('external_url_img');\n $product->status=$request->get('status');\n $product->category_id=$request->get('category_id');\n $product->brand_id=$request->get('brand_id');\n\n $product->save();\n\n //Le with va aller intégrer le tableau avec la clé \"success\" dans la variable de session\n return redirect('admin/products')->with(['success' => \"Product has been updated.\"]);\n }", "title": "" } ]
[ { "docid": "b253a586f54d8fcd444353d114e8da96", "score": "0.76002145", "text": "public function update(IResource $resource)\r\n {\r\n }", "title": "" }, { "docid": "1e58026b8952df10026ace5fc59fe274", "score": "0.7425105", "text": "public function updateShopifyResource() {\n $this->saving();\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'PUT',\n 'DATA' => [\n static::getResourceSingularName() => $this->shopifyData\n ]\n ]);\n }", "title": "" }, { "docid": "08694713de71165eda639b86061c2dd3", "score": "0.70612276", "text": "public function update(Request $request, Resource $resource)\n {\n $request->validate([\n 'name' => 'required',\n 'description' => 'required|string',\n 'file' => 'required|mimes:jpg,jpeg,png,doc,docx,pdf,ppt,txt',\n ]);\n\n $resource->update($request->all());\n\n if ( $request->hasFile('file') ) {\n $resource = 'resource-'.time().'.'.$request->file('file')->extension();\n $request->file->storeAs('resources', $resource,'public');\n $resource->file = $resource;\n }\n\n if ( $resource->save() ) {\n return redirect()->route('admin.resources.index')->with('success', 'Resource updated');\n } else {\n return redirect()->route('admin.resources.index')->with('error', 'Something went wrong');\n }\n }", "title": "" }, { "docid": "b66d45ed275220a344f3f222ce4980b5", "score": "0.70558053", "text": "public function update(Request $request, Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "718f7d64347dbb970d3af2645ff41b28", "score": "0.6624096", "text": "public function update(Request $request, Storage $storage)\n {\n //\n }", "title": "" }, { "docid": "c36ab864eb8fe4e400b9bf654b24e104", "score": "0.6334678", "text": "public function updateStream($path, $resource, array $config = []);", "title": "" }, { "docid": "1833fc434e2b6d8845470c7071f16b05", "score": "0.62114537", "text": "public function update(StoreStorage $request, Storage $storage)\n {\n $storage->fill($request->all())->save();\n $request->session()->flash('alert-success', 'Запись успешно обновлена!');\n return redirect()->route('storage.index');\n }", "title": "" }, { "docid": "713301f4bdde89af420365911069870f", "score": "0.6196851", "text": "public function update(ResourceTypeInterface $resourceType)\n\t{\n\t\t$this->setObjectToCache($resourceType);\n\t\t$this->setObjectToCache($resourceType, 'identifier');\n\t\t$this->objectManager->persist($resourceType);\n\t}", "title": "" }, { "docid": "0926078283b626a7cbcf1c37921b4293", "score": "0.6119944", "text": "public function update(Request $request, Flight $exercise, FlightResource $resource)\n {\n $request->validate([\n 'display_name' => 'required|string|max:100',\n 'file' => 'nullable|file|max:10240|mimes:pdf',\n 'uri' => 'nullable|url|max:255',\n ]);\n\n if ($resource->type === 'file' && $request->file('file')) {\n Storage::drive('public')->delete($resource->resource);\n $resource->resource = $request->file('file')->store('smartcars/exercises/resources', ['disk' => 'public']);\n } elseif ($resource->type === 'uri' && $request->input('uri')) {\n $resource->resource = $request->input('uri');\n }\n\n $resource->save();\n\n return redirect()->route('adm.smartcars.exercises.resources.index', $exercise)\n ->with('success', 'Resource edited successfully.');\n }", "title": "" }, { "docid": "78d3c773d3a549209d09486c7233c7b5", "score": "0.6087866", "text": "public function put($resource, $with=[]){\n return $this->fetch($resource, self::PUT, $with);\n }", "title": "" }, { "docid": "f6f8def0ac709abf6dd95f0dfa35d868", "score": "0.6052593", "text": "public function update($id, $resource) {\n SCA::$logger->log(\"update resource\");\n return $this->orders_service->update($id, $resource);\n }", "title": "" }, { "docid": "5334ba4a6880a32048930c6aab0c2e72", "score": "0.6018941", "text": "public function update($path);", "title": "" }, { "docid": "9ce64536e4f158c8d6da887e4483a653", "score": "0.5973672", "text": "public function updateResource($resource, $resource_id, $resource_data)\n {\n $this->addCallData('resource', $resource);\n $this->addCallData('URL', 'admin/' . $resource);\n $this->addCallData('METHOD', 'PUT');\n foreach ($resource_data as $property => $data) {\n $this->buildChildData($property, $data);\n }\n $this->commitChildData();\n return $this->updateRecord($resource_id);\n }", "title": "" }, { "docid": "9f880585b8f772551748224960e1114a", "score": "0.59715486", "text": "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'name' => 'required',\n 'link' => 'required',\n 'description' => 'required'\n ]);\n\n $resource = Resource::find($id);\n $resource->name = $request->name;\n $resource->type_id = $request->type_id;\n $resource->has_cost = ($request->has('has_cost')) ? 1 : 0;\n $resource->language_id = $request->language_id;\n $resource->link = $request->link;\n $resource->description = $request->description;\n $resource->tags = '';\n\n $resource->save();\n //return back()->with('success', 'Recurso actualizado satisfactoriamente');\n return redirect('/resource')->with('success', 'Recurso actualizado satisfactoriamente');\n }", "title": "" }, { "docid": "8bf08d6952a759b61a0c0f2a1c1e4e68", "score": "0.59400934", "text": "public function update($request, $id) {\n\t\t\t$image = $request['photo'];\n\t\t\tif($image !== null) {\n\t\t\t\t$name = time().'.' . explode('/', explode(':', substr($image, 0, strpos($image, ';')))[1])[1];\n\t\t\t\t\\Image::make($request['photo'])->save(public_path('storage/products/').$name);\n\t\t\t\t$request['photo'] = $name;\n\t\t\t} else {\n\t\t\t\t$currenPhoto = Product::all()->where('id', $id)->first();\n\t\t\t\t$request['photo'] = $currenPhoto->photo;\n\t\t\t}\n return $this->product->update($id, $request);\n\t}", "title": "" }, { "docid": "eaee54943a52f02e9d836bade5ff0c75", "score": "0.59377414", "text": "public function updateStream($path, $resource, Config $config)\n {\n }", "title": "" }, { "docid": "48a6e00b66b63cd7ac857215e12bb74f", "score": "0.58948725", "text": "public function update_($resource, ...$id) {\n\t\t$this->_checkResource ( $resource, function () use ($id) {\n\t\t\tif (! $this->hasErrors ()) {\n\t\t\t\tparent::_update ( ...$id );\n\t\t\t} else {\n\t\t\t\techo $this->displayErrors ();\n\t\t\t}\n\t\t} );\n\t}", "title": "" }, { "docid": "469e3d6c9afd54041becbee857df8ef8", "score": "0.5890722", "text": "public function edit(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "3ec460d4bbd98e23f7e38b492a7d650e", "score": "0.5860816", "text": "public function updateResourceIndex(&$resource) {\n if ($this->connector != null) {\n\n // STEP 1: Update or insert this resource as a node:\n $this->logger->addDebug(\"Updating/Inserting Node into Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} }) SET a.title = {title}, a.version = {version}, a.href = {href}\n return a;\",\n [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n );\n\n // Check to see if anything was added\n $records = $result->getRecords();\n if (empty($records)) {\n // Must create this record instead\n $result = $this->connector->run(\"CREATE (n:Resource) SET n += {infos};\",\n [\n \"infos\" => [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n ]\n );\n }\n\n // STEP 2: Update or insert the resource's link to holding repository\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} })-[r:HIRELATION]->()\n return r;\",\n [\n 'id' => $resource->getID(),\n ]\n );\n $records = $result->getRecords();\n if (!empty($records)) {\n // delete the one there so that we can add the correct one (just in case)\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}})-[r:HIRELATION]->() delete r;\",\n [\n 'id' => $resource->getID()\n ]\n );\n\n }\n\n // If resource has a repository, then add a link\n if ($resource->getRepository() != null && $resource->getRepository()->getID() != null) {\n $this->connector->run(\"MATCH (a:Identity {id: {id1} }) MATCH (b:Resource {id: {id2} }) CREATE (b)-[r:HIRELATION]->(a);\",\n [\n 'id1' => (string) $resource->getRepository()->getID(),\n 'id2' => $resource->getID()\n ]);\n }\n }\n }", "title": "" }, { "docid": "d7478480534fcc66d2484d02792ff42b", "score": "0.5832773", "text": "public function softwareUpdate(SoftwareRequest $request, $id)\n {\n $software=Software::find($id);\n /* dd($software); */\n $input= $request->all();\n $input['slug']=Str::slug($request->title);\n if($request->hasFile('image')) {\n if($request->image==$software->image){\n $input['image']=$software->image;\n }else{\n $fileName=$request->file('image')->store('photos','public');\n\n $input['image'] =$fileName;\n \n @unlink('storage/'.$software->image);\n }\n\n \n\n } else {\n\n $input['image']=$software->image;\n\n }\n $software->update([\n 'title'=>$request->title,\n 'content'=>$request->content,\n 'image'=>$input['image'],\n 'slug'=>$input['slug'],\n ]);\n /* dd($software); */\n\n return new SoftwareResource($software);\n }", "title": "" }, { "docid": "9c026a6af96c287558697ce10089af64", "score": "0.5830476", "text": "public function put($resourceId)\n {\n $resourceId = intval($resourceId);\n if (!array_key_exists(\n $resourceId,\n $this->repositoryIndex\n )) {\n header('Not Found', true, 404);\n exit();\n }\n\n $key = $this->repositoryIndex[$resourceId];\n $this->repository[$key] = $this->requestBody;\n\n echo json_encode($this->repository[$key]);\n }", "title": "" }, { "docid": "4bc6a6b46ecee85bd6f0b6a0548271b3", "score": "0.582811", "text": "public function update(Request $request, $resource, $id)\n {\n return $this->repository->update($id, $request->all());\n }", "title": "" }, { "docid": "0c03c39e441c2fe392d76d6370ae3ce2", "score": "0.5806887", "text": "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "title": "" }, { "docid": "95a0aa456b419b2ce1456ae7f9c023ec", "score": "0.57935816", "text": "public function updateRecord($id)\n {\n // Check if the record exists\n $resource = $this->shopifyData['resource'];\n $resource_singular = $this->shopifyData['SINGULAR_NAME'];\n $compare_property_value = $id;\n\n $tempShopifyData = $this->shopifyData;\n $tempShopifyData['METHOD'] = 'GET';\n switch ($this->shopifyData['resource']) {\n case 'collects':\n case 'variants':\n $compare_property_name = 'id';\n $tempShopifyData['URL'] = 'admin/' . $resource . '/' . $id . '.json';\n break;\n case 'metafields':\n // metafields requires a resource id and metafield id, therefore, we're setting the URL from where it's being called\n $tempShopifyData['URL'] = $tempShopifyData['URL'];\n break;\n case 'inventory_levels':\n $compare_property_name = 'inventory_item_ids';\n $tempShopifyData['URL'] .= '?' . $compare_property_name . '=' . urlencode($compare_property_value);\n break;\n default:\n $compare_property_name = 'ids';\n $tempShopifyData['URL'] .= '?' . $compare_property_name . '=' . urlencode($compare_property_value);\n }\n \n $result = $this->call($tempShopifyData);\n if ((isset($result->$resource) && count($result->$resource) == 1) || property_exists($result, $resource_singular)) {\n // update the record\n $resource = $this->shopifyData['resource'];\n $currentShopifyData = $this->shopifyData;\n $currentShopifyData['METHOD'] = 'PUT';\n\n switch ($resource) {\n case 'smart_collections':\n // if smart_collections, determine whether to use order.json or #id.json\n if (isset($currentShopifyData['DATA']) && array_has($currentShopifyData['DATA'], 'products')) {\n $currentShopifyData['URL'] = str_replace(\".json\", '/' . $id . '/order.json', $currentShopifyData['URL']);\n }\n break;\n case 'inventory_levels':\n $currentShopifyData['URL'] = str_replace(\".json\", '/set.json', $currentShopifyData['URL']);\n break;\n default:\n $currentShopifyData['URL'] = self::PREFIX . '/' . $resource . '/' . $id . '.json';\n }\n\n\n if (isset($currentShopifyData['DATA'])) {\n $result = $this->call($currentShopifyData, $currentShopifyData['DATA']);\n } else {\n $result = $this->call($currentShopifyData);\n }\n $this->resetData();\n return $result;\n }\n }", "title": "" }, { "docid": "9aebab206cbd3cb1ae7fc60ffdd5c17a", "score": "0.5754308", "text": "public function updateSingle($request, $response, $args){\n\t\t$response = $this->gateway($this->getNeededCap(__FUNCTION__), $response);\n\t\tif ( $response->getStatusCode() != 200 ){\n\t \t\treturn $response;\n\t \t}\n\t\t//TODO check data type & id against resource > via middleware, serve 409 error on mismatch\n\t \t$resource_model_class = $this->resource_model_class;\n\t \t$resource_slug = $resource_model_class::getResourceSlug();\n \t\t$resource = $args[$resource_slug];\n\t\t$input = $request->getParsedBody()['data'];\n \t\t$return = $this->validateAndSave($resource,$input);\n \t\treturn $response->withJsonAPI($return['to_json'],$return['code']);\n\t}", "title": "" }, { "docid": "3b6c3aaa23b4fb918ebc093545c13dc6", "score": "0.57525045", "text": "public function update($entity);", "title": "" }, { "docid": "7fa7323735ca22c15cfa4866e023dcb7", "score": "0.57337505", "text": "public function setResource($resource);", "title": "" }, { "docid": "cd5df57c2c83d7637ab39eb4c24ca282", "score": "0.5718714", "text": "public function update(Request $request, $id)\n {\n $product = Product::findOrFail($id);\n $this->validate($request, [\n 'category_id' => 'required',\n 'unit_id' => 'required',\n 'name' => [\n 'required',\n Rule::unique('products')->ignore($product->id),\n ],\n 'purchase_price' => 'required',\n 'sell_price' => 'required',\n 'quantity' => 'required',\n ]);\n\n $product->category_id = $request->category_id;\n $product->unit_id = $request->unit_id;\n $product->name = $request->name;\n $product->sku = Helpers::getSKUProduct($request->name, $request->id);\n $product->barcode = Helpers::getBarcodeProduct($request->name);\n $product->description = $request->description;\n //TODO: update image in storage path\n $product->image = $request->image;\n $product->quantity = $request->quantity;\n $product->quantity_alert = $request->quantity_alert;\n $product->cost_price = Helpers::calculateCostPrice($product->purchase_price, $product->quantity, $request->purchase_price, $request->quantity);\n $product->purchase_price = $request->purchase_price;\n $product->sell_price = $request->sell_price;\n $product->status = $request->status;\n\n $product->update();\n\n return new ProductResource($product);\n }", "title": "" }, { "docid": "cbf8435986892ace3d4dbcfbf62f6804", "score": "0.5714311", "text": "public function isUpdateResource();", "title": "" }, { "docid": "8759752add8b6db67fed4d69cb0208e8", "score": "0.5683185", "text": "public function update()\n\t{\n\t\tparent::update();\n\t\t$this->write();\n\t}", "title": "" }, { "docid": "b867c63b8317ab70317f7b53e3441ded", "score": "0.56789744", "text": "public function update(ProductUpdateRequest $request, $id)\n {\n $product = Product::findOrFail($id);\n $product->update($request->all());\n return (new ProductResource($product->loadMissing('imageable')))-> response()->setStatusCode(200);\n }", "title": "" }, { "docid": "6429c73de2ef2191c3d2be22fbf0f39c", "score": "0.5675671", "text": "public function update($data);", "title": "" }, { "docid": "ea54f106887794c3110ad39c81f775dc", "score": "0.5674029", "text": "public function update($record, ResourceObjectInterface $resource, EncodingParametersInterface $params);", "title": "" }, { "docid": "8a46c9ac29aec2f0c66f61cd6abd3e2a", "score": "0.5669989", "text": "public function update(Request $request, $id)\n {\n \n $product = Product::find($id);\n\n\n $product->fill($request->all())->save();\n\n //Verificamos que tenemos una imagen\n if($request->file('photo_1')){\n\n\n //En caso de tenerla la guardamos en la clase Storage en la carpeta public en la carpeta image.\n $path = Storage::disk('public')->put('photo_1',$request->file('photo_1'));\n\n //Actualizamos el Post que acabamos de crear\n $product->fill(['photo_1' => asset($path)])->save();\n\n }\n\n\n return redirect()->route('products.index')->with('info', 'Producto actualizado exitosamente!');\n }", "title": "" }, { "docid": "6aaf7100103df61dd639ff4267dc6860", "score": "0.565847", "text": "public function update ($resource = false, $key = false) {\n\t\t$resource = ($resource) ? $resource : $this->resource;\n\t\t$key = ($key) ? $key : $this->key;\n\n\t\tif (DB::execute (\n\t\t\t'update `#prefix#lock` set modified = ?, expires = ? where resource = ? and resource_id = ?',\n\t\t\tgmdate ('Y-m-d H:i:s'),\n\t\t\tgmdate ('Y-m-d H:i:s', time () + $this->timeout),\n\t\t\t$resource,\n\t\t\t$key\n\t\t)) {\n\t\t\treturn true;\n\t\t}\n\t\t$this->error = DB::error ();\n\t\treturn false;\n\t}", "title": "" }, { "docid": "8061c9b36c6d17c20d2017115145496d", "score": "0.56398815", "text": "public function update(Request $request, $id)\n {\n try {\n DB::beginTransaction();\n\n $product = Product::find($id);\n\n $data = $request->except('img');\n\n if ($request->hasFile('img')) {\n if ($product->img && file_exists(storage_path('app/public/'.$product->img))) {\n Storage::delete('public/'.$product->img);\n }\n\n $img_path = $request->file('img')->store('products/img', 'public');\n $data['img'] = $img_path;\n $data['img_url'] = url('/storage/'.$img_path);\n }\n\n if (!$data['is_discount']) {\n $data['after_discount'] = null;\n }\n\n $product = $product->fill($data);\n $product->save();\n\n DB::commit();\n\n return redirect()->route('product.index')->with('success', 'Successfully updated product !');\n\n } catch (\\Exception $error) {\n DB::rollBack();\n return $error->getMessage();\n }\n }", "title": "" }, { "docid": "bbd99fadb318f4a784afaa2bfa18ce90", "score": "0.5628826", "text": "public function update(StoreOrUpdateAsset $request, Asset $asset)\n {\n if (Storage::exists($asset->path) && !Storage::delete($asset->path)) {\n abort(500);\n }\n\n $file = $request->file('file');\n $path = $file->store('assets');\n\n if (!$path) {\n abort(500);\n }\n\n // We wonder if we should delete the old file or not...\n\n $asset->name = $file->getClientOriginalName();\n $asset->size = $file->getSize();\n $asset->type = $file->getMimeType();\n $asset->path = $path;\n\n if ($asset->save()) {\n flash('The asset has been saved.')->success();\n } else {\n abort(500);\n }\n\n return redirect('/admin/assets');\n }", "title": "" }, { "docid": "8eb8ff4a40a42fb82a98ac5091c3a8b4", "score": "0.56196684", "text": "public function update(FoodRecipeRequest $request, $id)\n {\n $foodRecipe = FoodRecipe::with('ingredients','cookingProcesses')->findOrFail($id);\n if ($request->input('name')!= null)\n $foodRecipe->name = $request->input('name');\n if ($request->input('detail')!= null)\n $foodRecipe->detail = $request->input('detail');\n if($request->file('photo') != null) {\n $old_file = $foodRecipe->photo;\n if($old_file != null){\n $path = public_path().'/storage/'.$old_file;\n File::delete($path);\n }\n $file = $request->file('photo');\n $name = '/foodRecipe/' . Carbon::now()->format(\"dnY-Hisu\") . \".\" . $file->extension();\n $file->storePubliclyAs('public', $name);\n $foodRecipe->photo = $name;\n }\n $foodRecipe->save();\n return new FoodRecipeResource($foodRecipe);\n }", "title": "" }, { "docid": "b7bac3ceb1b9b8584ebd61b08fa09788", "score": "0.5604227", "text": "public function putAction()\n {\n /** XXX **/\n\n $this->view->message = sprintf('Resource #%s Updated', $id);\n $this->_response->ok();\n }", "title": "" }, { "docid": "861587caf58c3f620dbafce99fe22615", "score": "0.56020206", "text": "public function update($id, $request);", "title": "" }, { "docid": "f646252110cf32a5b2f73f7d1462f12e", "score": "0.5601397", "text": "public function update(Request $request, $id)\n {\n //validation\n $this->validate(request(),[\n 'image' => 'image'\n ]);\n\n $slider = HomeSliders::find($id);\n \n $slider->link = request('link');\n\n //get old image to delete if updated\n $oldImage = request('oldImage');\n //get the new image\n $NewImage=$request->file('image');\n\n if($NewImage)\n {\n $filenameToStore= helpers::updatePhoto('image','homeSliders',$request);\n $slider->image=$filenameToStore;\n\n Storage::delete('public/Images/homeSliders/'.$oldImage);\n }\n\n $slider->save();\n\n Alert::success(config('app.name'), trans('messages.Updated Successfully') );\n return redirect()->route('admin.homeSlider',$slider->type);\n }", "title": "" }, { "docid": "87604b965f2923e2345b489944eb16ab", "score": "0.5582592", "text": "public function update(IEntity $entity);", "title": "" }, { "docid": "b1223c0e87edc0874663308fb5757224", "score": "0.5575312", "text": "function put($resource, $data = null) {\r\n\t\t\r\n\t\tif(isset($data)) {\r\n\t\t\t$this->request_body = $data;\r\n\t\t}\r\n\r\n\t\t// make the call chief\r\n\t\t$this->exec ( \"PUT\", '/' . $resource );\r\n\r\n\t\t// check the request status\r\n\t\tif($this->status_code != 200){\r\n\t\t\t$this->Logger->error(\r\n\t\t\t\tsprintf(\r\n\t\t\t\t\t'GET Call for resource \\'%s\\' Failed.\r\n\t\t\t\t\tStatus: %d,\r\n\t\t\t\t\tRequest: %s\r\n\t\t\t\t\tAPI Error Message: \r\n\t\t\t\t\t%s',\r\n\t\t\t\t\t$resource,\r\n\t\t\t\t\t$this->status_code,\r\n\t\t\t\t\t$this->request_body_raw,\r\n\t\t\t\t\t$this->response_body\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\t\tthrow new Exception($this->response_body);\r\n\t\t} else {\r\n\t\t\treturn $this->response_parsed;\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "f77c93b62808595a63d9f6f31b1f80e0", "score": "0.55661047", "text": "public function updateStream($path, $resource, Config $config)\n {\n return $this->writeStream($path, $resource, $config);\n }", "title": "" }, { "docid": "f77c93b62808595a63d9f6f31b1f80e0", "score": "0.55661047", "text": "public function updateStream($path, $resource, Config $config)\n {\n return $this->writeStream($path, $resource, $config);\n }", "title": "" }, { "docid": "f77c93b62808595a63d9f6f31b1f80e0", "score": "0.55661047", "text": "public function updateStream($path, $resource, Config $config)\n {\n return $this->writeStream($path, $resource, $config);\n }", "title": "" }, { "docid": "c596fddf408b359acc12fe17624de997", "score": "0.55624634", "text": "public function update(Request $request, $id)\n {\n\n $product = Product::findOrFail($id);\n $product->name = $request['name'];\n $product->price = $request['price'];\n $product->stock = $request['stock'];\n $product->description = $request['description'];\n\n $file = $request->file('image');\n $fileName = $file->getClientOriginalName();\n if($fileName != $product->image){\n $request->file('image')->move('images/',$fileName);\n $product->image = $fileName;\n }\n\n $product->save();\n\n return redirect()->route('products.show',\n $product->id)->with('flash_message',\n 'Article, '. $product->name.' updated');\n }", "title": "" }, { "docid": "b3d8abec86ebbd8bf61bddeb5110ba38", "score": "0.55608666", "text": "abstract public function put($data);", "title": "" }, { "docid": "0af57b3d439623d9ddfbbd2c23e24b1f", "score": "0.55599797", "text": "public function update($id, $data);", "title": "" }, { "docid": "0af57b3d439623d9ddfbbd2c23e24b1f", "score": "0.55599797", "text": "public function update($id, $data);", "title": "" }, { "docid": "0af57b3d439623d9ddfbbd2c23e24b1f", "score": "0.55599797", "text": "public function update($id, $data);", "title": "" }, { "docid": "0af57b3d439623d9ddfbbd2c23e24b1f", "score": "0.55599797", "text": "public function update($id, $data);", "title": "" }, { "docid": "910ec5bfd0a0132f45d218d96931bc8b", "score": "0.55576575", "text": "public function update(Request $request, $id)\n {\n\n $request->validate([\n 'resource_name' => 'required',\n 'about_content' => 'required',\n 'sort_order' => 'required|numeric'\n ]);\n\n $form_data = array(\n 'resource_name' => $request->resource_name,\n 'slug' => $this->slugify($request->resource_name),\n 'about_content' => $request->about_content,\n 'sort_order' => $request->sort_order\n );\n\n Resource::whereId($id)->update($form_data);\n\n return redirect('resource')->with('success', 'Data is successfully updated');\n }", "title": "" }, { "docid": "90cec2e0050ecd5971be612c49157c4a", "score": "0.55573726", "text": "public function testUpdateSupplierUsingPUT()\n {\n }", "title": "" }, { "docid": "9c243572303715ea37744cfc162e1a3c", "score": "0.5556878", "text": "public function update(Request $request, $id)\n {\n $storageplace = Storageplace::findOrFail($id);\n $storageplace->update($request->only(['storageplace']));\n return $storageplace;\n }", "title": "" }, { "docid": "45212faae39cc84fb7d386bd5ccbacd2", "score": "0.5554201", "text": "public function updateRelatedImage(Request $request, $id)\n {\n // Delete display image in Storage\n Validator::make($request->all(), ['photos' => \"required|file|image|mimes:jpg,png,jpeg|max:5000\"])->validate();\n\n\n if ($request->hasFile(\"photos\")) {\n\n $photo = ProductsPhoto::find($id);\n $imageName = $photo->photos;\n $exists = Storage::disk('local')->exists(\"public/product_images/\" . $photo->photos);\n\n //delete old image\n if ($exists) {\n Storage::delete('public/product_images/' . $imageName);\n }\n\n //upload new image\n $ext = $request->file('photos')->getClientOriginalExtension(); //jpg\n\n $request->photos->storeAs(\"public/product_images/\", $imageName);\n\n $arrayToUpdate = array('photos' => $imageName);\n DB::table('products_photos')->where('id', $id)->update($arrayToUpdate);\n\n return redirect()->route(\"adminDisplayRelatedImageForm\", ['id' => $photo->product_id]);\n } else {\n\n $error = \"NO Image was Selected\";\n return $error;\n }\n }", "title": "" }, { "docid": "ffe74e555ccf4883e40a207b843213c6", "score": "0.5553755", "text": "public function update($id, EditResourceImageRequest $request)\n {\n $resourcecenterImage = ResourceCenterImage::findOrFail($id);\n $this->setUpdatedModelValues($request, $resourcecenterImage);\n // if file, we have additional requirements before saving\n if ($this->newFileIsUploaded()) {\n $this->deleteExistingImages($resourcecenterImage);\n $this->setNewFileExtension($request, $resourcecenterImage);\n }\n\n $resourcecenterImage->update([\n 'book_name' => $request->input('book_name'),\n 'category_name' => $request->input('category_name')\n ]); \n\n $resourcecenterImage->save();\n// check for file, if new file, overwrite existing file\n if ($this->newFileIsUploaded()){\n $file = $this->getUploadedFile();\n $this->saveImageFiles($file, $resourcecenterImage);\n }\n $thumbnailPath = $this->thumbnailPath;\n $imagePath = $this->imagePath;\n alert()->success('Congrats!', 'image edited!');\n return view('resourcecenter-image.view', compact('resourcecenterImage',\n 'thumbnailPath',\n 'imagePath'));\n }", "title": "" }, { "docid": "9bd927a2b7c7b6455cfb1d5512fcad31", "score": "0.55435944", "text": "public static function update($id, $file)\n {\n Image::delete($id);\n\n Image::save($file);\n }", "title": "" }, { "docid": "efa4460a1f0a94dc49a588c86ce1c95e", "score": "0.55393505", "text": "public function update(Request $request, $id)\n {\n $sli=Slider::find($id);\n $sli->sort_order=$request->input('sort_order');\n $image = $request->file('slider');\n if($image == ''){\n $image = $sli->slider;\n }else{\n $image = base64_encode(file_get_contents($request->file('slider')));\n }\n $sli->slider = $image;\n $sli->save();\n return redirect()->back();\n }", "title": "" }, { "docid": "49f2830a1f4c7d89a0738cee238723c4", "score": "0.5536732", "text": "public function update(Request $request, $id)\n {\n $product = Product::findOrFail($id);\n if ($request->hasFile('photo')){\n if ($product->photo !== NULL){\n unlink(public_path($product->photo));\n }\n\n }\n $product->CategoryID = $request->CategoryID;\n $product->SKU = $request->SKU;\n $product->ProductName = $request->ProductName;\n $product->ProductDescription = $request->ProductDescription;\n $product->QTY = $request->QTY;\n $product->Price = $request->Price;\n $product->AvailSize = $request->AvailSize;\n $product->AvailColor = $request->AvailColor;\n $product->Size = $request->Size;\n $product->Color = $request->Color;\n $product->photo = $request->photo;\n\n $product['photo'] = '/upload/photo/'.time().'.'.$request->photo->getClientOriginalExtension();\n $request->photo->move(public_path('/upload/photo/'), $product['photo']);\n\n $product->save();\n\n return response()->json([\n 'success' => true,\n 'message' => 'Product Updated' ]);\n }", "title": "" }, { "docid": "c4d2a2fa9101020663f7a49d7cc6ddac", "score": "0.5535236", "text": "public function update(Request $request, $id)\n {\n $volume = $this->findVolume($id);\n\n if(count($volume) > 0) {\n $volume->str_volume_name = $request->str_volume_name;\n\n $volume->save();\n }\n\n return response()\n ->json(\n array(\n 'message' => 'Volume is successfully updated.',\n 'volume' => $volume\n ),\n 201\n );\n }", "title": "" }, { "docid": "6e9e95959e33006f578a3965f633d7d6", "score": "0.5534954", "text": "public function update(Request $request, $id)\n {\n $product = ProductModel::find($id);\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->stock = $request->stock;\n\n if($request->image!=null){\n $imageName = time().'.'.$request->image->extension();\n $request->image->move(public_path('images'), $imageName);\n $product->image = \"/images/\".$imageName;\n }\n $product->save();\n return redirect(\"/products/index\")->with('success','Product has been updated');\n }", "title": "" }, { "docid": "6747a7ea594ba3a1e21cae4d1cb18d9f", "score": "0.5534193", "text": "public function update (Request $request, $id)\n {\n $request_data = $request->all();\n\n // only validate attributes provided (ignore missing)\n $validation_rules = array_keys($request_data['data']['attributes']);\n $request_data_validation = $this->validateRequestResourceObject($request_data['data'], $this->model, $id, true, $validation_rules);\n\n // respond with error\n if (!empty($request_data_validation['errors'])) {\n return Response::make([ 'errors' => $request_data_validation['errors'] ], $request_data_validation['error_code']);\n }\n\n // fetch resource\n $resource = $this->model->findOrFail($id);\n\n // ACL\n if (!is_null(config('jsonapi.acl.check_access')) && config('jsonapi.acl.check_access') !== false) {\n $errors = JsonApiAclUtils::accessCheck($request->route()->getName(), Auth::user(), $resource);\n if (!empty($errors)) {\n return Response::make([ 'errors' => $errors ], 403);\n }\n }\n\n // update resource\n $resource->fill($request_data['data']['attributes']);\n $resource->save();\n\n // return updated resource\n return Response::item($request, $resource->toArray(), $this->model, 200);\n }", "title": "" }, { "docid": "6c30ee958f97e8028b342b7519dfbdae", "score": "0.55296004", "text": "public function testUpdateInventoryStorageActivity()\n {\n }", "title": "" }, { "docid": "294674761e7a90c0f3c7b7cbb244ad5a", "score": "0.55237365", "text": "public function update()\n {\n $accessory = Accessories::find(request('id'));\n\n if ($accessory == null) {\n return response()->json([\"error\" => \"aksesuaras nerastas\"], 404);\n }\n\n $this->validateData();\n $path = $accessory->src;\n\n if (request()->hasFile('src')) {\n\n if (Storage::disk('public')->exists($accessory->src)) {\n Storage::disk('public')->delete($accessory->src);\n }\n $path = request()->file('src')->store('accessoriesImages', 'public');\n }\n\n $accessory->update(array_merge($this->validateData(), ['src' => $path]));\n\n return response()->json([\"data\" => $accessory], 200);\n }", "title": "" }, { "docid": "f83dd36256d02e1f966e7e748f03289a", "score": "0.5511168", "text": "public function update($id, Request $request)\n {\n date_default_timezone_set('Asia/Taipei');\n $data = $request->all();\n $dbData = Product::find($id);\n $myfile = Storage::disk('local');\n if ($request->hasFile('img')) {\n $file = $request->file('img');\n $path = $myfile->putFile('public', $file);\n $data['img'] = $myfile->url($path);\n File::delete(public_path($dbData->img));\n }\n $dbData->update($data);\n\n if ($request->hasFile('imgs')) {\n // $this->fetchDestroyByProdId($id);\n $localS = Storage::disk('local');\n\n $fileS = $request->file('imgs');\n $imgs = [];\n foreach ($fileS as $i) {\n $pathS = $localS->putFile('public', $i);\n $imgs[] = $localS->url($pathS);\n }\n foreach ($imgs as $img) {\n ProductImg::create([\n 'product_id' => $id,\n 'img' => $img\n ]);\n }\n }\n\n return redirect()->route('admin');\n }", "title": "" }, { "docid": "0dc3227cc620ff2bfcf02b42a09128f6", "score": "0.5508345", "text": "public function update(Request $request, Product $product)\n { $remfile= $product->image;\n if($request->filep){\n $product->image=$request->filep;\n File::delete(storage_path('app/public/products/'.$remfile));\n }else{\n $product->image=$remfile;\n }\n //rmdir(storage_path('app/public/products/'.$remfile));\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->save();\n sleep(3);\n toast('Details updated successfully','info');\n return redirect('/products');\n }", "title": "" }, { "docid": "265c7e4e1d9ccb8f2d919846c5c6d0e1", "score": "0.55072427", "text": "public function update($id, $input);", "title": "" }, { "docid": "98955a07074c5f9d7b65cb4edac55bd6", "score": "0.54995877", "text": "public function update(Request $request, $id)\n {\n $data = $request->all();\n extract($data);\n\n $productVarient = new ProductVariant();\n $productVarient = $productVarient->find($id);\n $productVarient->vendor_id = auth()->user()->id;\n $productVarient->description = $prod_desc;\n $productVarient->price = $price;\n\n if(request()->hasFile('photo')){\n $image = request()->file('photo')->getClientOriginalName();\n $imageNewName = auth()->user()->id.'-'.$image;\n $file = request()->file('photo');\n $file->storeAs('images/product',$imageNewName, ['disk' => 'public']);\n $productVarient->image = $imageNewName;\n }\n \n $productVarient->save();\n\n return back()->withStatus(__('Product successfully updated.'));\n }", "title": "" }, { "docid": "2a1018c32a03eb53bdc4e273d245eb4b", "score": "0.5497446", "text": "function updateProduct() {\n\n $params = [\n 'name' => $this->product\n ];\n \n $response = getResponse(getConfigVar(\"api_url\"), \"products\", $params, [],'body');\n \n $this->qty = $response[\"results\"][0][\"qty\"];\n $this->price = $response[\"results\"][0][\"price\"];\n \n $product = get_page_by_title( $this->product, OBJECT, 'product' );\n \n $productID = $product->ID;\n \n update_post_meta( $productID, \"_stock\", $this->qty );\n update_post_meta( $productID, \"_price\", $this->price );\n }", "title": "" }, { "docid": "ebfc2a23b89e301d5a4b298c50156e0d", "score": "0.54949397", "text": "public function update($id);", "title": "" }, { "docid": "ebfc2a23b89e301d5a4b298c50156e0d", "score": "0.54949397", "text": "public function update($id);", "title": "" }, { "docid": "9ecc82591ba06b6a36749ed98ac6605d", "score": "0.54946727", "text": "private function update()\n {\n $this->data = $this->updateData($this->data, $this->actions);\n $this->actions = [];\n }", "title": "" }, { "docid": "807c599f788606e6432d3e0633f87027", "score": "0.5494425", "text": "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 }", "title": "" }, { "docid": "48fef9aa4b1db49fbd41de594ae52cd6", "score": "0.5494196", "text": "public function put($path, $data = null);", "title": "" }, { "docid": "a3080528f24f5a6310506fe05f776170", "score": "0.54941916", "text": "public function update(Request $request, $id)\n {\n $request->validate([\n 'path_image'=>'image',\n 'status'=>'required|in:0,1'\n ]);\n $slider=Slider::whereId($id)->first();\n if (is_null($slider)){\n return redirect()->route('sliders.index')->with('error','Slider does not exist');\n }\n try {\n if ($request->hasFile('path_image')){\n $file = $request->file('path_image');\n\n $image_path= $file->store('/sliders',[\n 'disk'=>'uploads'\n ]);\n Storage::disk('uploads')->delete($slider->image);\n\n $request->merge([\n 'image'=>$image_path,\n ]);\n }\n\n $slider->update( $request->only(['status','image']));\n return redirect()->route('sliders.index')->with('success','Updated successful');\n }catch (\\Exception $exception){\n return redirect()->route('sliders.index')->with(['error'=>'Something error try again']);\n\n }\n }", "title": "" }, { "docid": "7b02b905255b0a4884cf4da903ed88b2", "score": "0.5492901", "text": "public function update(Request $request, $id)\n {\n $product = Product::where('id', $id);\n\n if ($request->file('image')) {\n File::delete(public_path('images/' . $product->first()->image));\n $file = $request->file('image');\n $file_name = uniqid() . $file->getClientOriginalName();\n $file->move(public_path('/images'), $file_name);\n } else {\n $file_name = $product->first()->image;\n }\n\n $product->update([\n 'category_id' => $request->category_id,\n 'title' => $request->title,\n 'image' => $file_name,\n 'total_quantity' => $request->total_quantity,\n 'price' => $request->price,\n 'description' => $request->description,\n ]);\n\n $product = Product::find($product->first()->id);\n $product->color()->sync($request->color_id);\n $product->size()->sync($request->size_id);\n return redirect()->back()->with('success', 'updated success');\n }", "title": "" }, { "docid": "04652c1da37c7a438475c8d281a1b9fb", "score": "0.54925025", "text": "public function update() {\n $this->accessory->update($this->accessory_params());\n\n if ($this->accessory->is_valid()) {\n $this->update_accessory_image($this->accessory);\n redirect('/backend/accessories', ['notice' => 'Successfully updated.']);\n } else {\n redirect(\n '/backend/accessories/edit',\n ['error' => $this->accessory->errors_as_string()],\n ['id' => $this->accessory->id]\n );\n }\n }", "title": "" }, { "docid": "d93eb8ea18e437ad56170f6f49f20674", "score": "0.5491807", "text": "public function update(Entity $entity);", "title": "" }, { "docid": "2e6523045766c061920aeea9222af1fe", "score": "0.54858494", "text": "public function edit(Storage $storage)\n {\n //\n }", "title": "" }, { "docid": "bc41011f4e9854a51487a136c85c2353", "score": "0.54841125", "text": "public function updateEntity($entity = null);", "title": "" }, { "docid": "2a7096bf2a727a86ecc99d0ede5d263f", "score": "0.5483321", "text": "public function update(Request $request, $id)\n {\n $icon = SliderIcon::find($id);\n $data = $request->all();\n $data['active'] = $request->has('active') ? 1 : 0;\n if ($request->hasFile('img')) {\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $image = $request->file('img');\n $fileName = time().'_'.Str::lower(Str::random(5)).'.'.$image->getClientOriginalExtension();\n $path_to = '/upload/images/'.getfolderName();\n $image->storeAs('public'.$path_to, $fileName);\n $data['img'] = 'storage'.$path_to.'/'.$fileName;\n }\n $icon->update($data);\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества обнавлены');\n }", "title": "" }, { "docid": "73aed3f2cb201636304e3d5dda73a09e", "score": "0.54824626", "text": "public function markAsChanged(ResolvedResource $resource);", "title": "" }, { "docid": "61329b7ef8ead3531f1a05acebdc3cd5", "score": "0.5479606", "text": "public function update() {\n\t $this->layout = false;\n\t \n\t //set default response\n\t $response = array('status'=>'failed', 'message'=>'HTTP method not allowed');\n\t \n\t //check if HTTP method is PUT\n\t if($this->request->is('put')){\n\t //get data from request object\n\t $data = $this->request->input('json_decode', true);\n\t if (empty($data)) {\n\t $data = $this->request->data;\n\t }\n\t \n\t //check if product ID was provided\n\t if (!empty($data['id'])) {\n\t \n\t //set the product ID to update\n\t $this->Player->id = $data['id'];\n\t if ($this->Player->save($data)) {\n\t $response = array('status'=>'success','message'=>'Product successfully updated');\n\t } else {\n\t $response['message'] = \"Failed to update product\";\n\t }\n\t } else {\n\t $response['message'] = 'Please provide product ID';\n\t }\n\t }\n\t \n\t $this->response->type('application/json');\n\t $this->response->body(json_encode($response));\n\n\t return $this->response->send();\n\t}", "title": "" }, { "docid": "d6605be9a7cd37fa11f95b43e9749bd9", "score": "0.54651225", "text": "public function update($path, $time = null);", "title": "" }, { "docid": "5b72ae8e940480dd3b49bab90e39b090", "score": "0.5458525", "text": "public function updateProduct($request, $product)\n {\n $product->update($request->except(['_token', '_method', 'image']));\n if ($request->hasFile('image')) {\n $image = $request->file('image');\n $imageName = time() . '.' . $request->file('image')->extension();\n // $img = Image::make('public/foo.jpg');\n\n $image_resize = Image::make($image->getRealPath());\n $image_resize->resize(500, 500);\n $image_resize->save(public_path('images/') . $imageName, 100);\n $product->gallery = $imageName;\n $product->save();\n }\n $product->getTags()->sync($request->input('tags'));\n }", "title": "" }, { "docid": "0464e78c66c09f2b7a0600a8792cb854", "score": "0.5452974", "text": "public function update(Request $request, $id)\n {\n $validation = $request->validate([\n 'name' => 'required',\n 'email' => 'required',\n 'phone' => 'required',\n 'address' => 'required',\n 'city' => 'required',\n 'state' => 'required',\n 'country' => 'required',\n 'shop_name' => 'required',\n 'photo' => 'required'\n ]);\n\n $supplier = Supplier::find($id);\n $supplier->name = $request->name;\n $supplier->email = $request->email;\n $supplier->phone = $request->phone;\n $supplier->address = $request->address;\n $supplier->city = $request->city;\n $supplier->state = $request->state;\n $supplier->country = $request->country;\n $supplier->shop_name = $request->shop_name;\n $supplier->photo = $request->photo;\n $supplier->status = 1;\n\n $photo = $request->newphoto;\n $old_photo = $supplier->photo;\n if ($photo) {\n if ($old_photo) {\n unlink($old_photo);\n }\n $first_position = strpos($photo, ';');\n $second_position = substr($photo, 0, $first_position);\n $ext = explode('/', $second_position)[1];\n $photo_name = Str::random(20).time().'.'.$ext;\n Image::make($photo)->resize(500, 400)->save(public_path('uploads/suppliers/' . $photo_name));\n $supplier->photo = 'uploads/suppliers/'.$photo_name;\n }\n $supplier->save();\n }", "title": "" }, { "docid": "247e5b3a01495ebf8d4c534d42ea515f", "score": "0.5451602", "text": "public function update(Request $request,$id){\n\n //validation\n $validator = Validator::make($request->all(), [\n 'name'=>'required|max:120',\n 'price'=>'required|numeric',\n 'discount'=>'required|numeric',\n 'description'=>'required',\n 'photo'=>'image',\n ]);\n if ($validator->fails()) {\n return redirect()->back()\n ->withErrors($validator)\n ->withInput(); \n\n } \n\n $inputs=[\n 'name'=>$request->input('name'),\n 'price'=>$request->input('price'),\n 'discount'=>$request->input('discount'),\n 'description'=>$request->input('description'),\n\n ];\n\n $product=Product::find($id);\n $product->update($inputs);\n if(!empty($request->file('photo'))){\n if(file_exists('uploads/products/'.$product->photo)){\n unlink('uploads/products/'.$product->photo);\n\n }\n \n //rename picture name\n $newName='product_'.time().'.'.$request->file('photo')->getClientOriginalExtension();\n //submit picture\n $request->file('photo')->move('uploads/products',$newName);\n $product->update(['photo'=>$newName]);\n }\n return redirect()->route('admin.product');\n\n }", "title": "" }, { "docid": "db96875d174f9e13964b6e7754664378", "score": "0.5450616", "text": "public function update(Request $request, $id)\n {\n $slider = Slider::find($id);\n\n if ($request->hasFile('image')) {\n $image = $request->file('image');\n $filename = time() . '.' . $image->getClientOriginalExtension();\n $location = public_path('assets/img/slider/' . $filename);\n Image::make($image)->resize(1920, 1080)->save($location);\n $oldFilename = $slider->image;\n $slider->image = $filename;\n Storage::delete($oldFilename);\n }\n $slider->save();\n Session::flash('success', 'The slider was successfully updated!');\n return redirect()->route('admin.slider');\n }", "title": "" }, { "docid": "7866059d59e3ac76fe1a71f510712109", "score": "0.54483366", "text": "public function putStream($path, $resource, array $config = []);", "title": "" }, { "docid": "26fc5abe042df3b46cf35fa63b5ce2f0", "score": "0.5447613", "text": "public function update(Request $request, $id)\n {\n // Update the resource with the addressed ID\n $subcategory = Subcategory::where('id', $request['subcategory_id'])->first();\n $subcategory_uuid = DB::table('product_subcategory')->where('product_id', $id)->value('uuid');\n $subcategory_id = DB::table('product_subcategory')->where('product_id', $id)->value('id');\n $unit = Unit::where('id', $request['unit_id'])->first();\n $unit_uuid = DB::table('product_unit')->where('product_id', $id)->value('uuid');\n $unit_id = DB::table('product_unit')->where('product_id', $id)->value('id');\n\n $product = Product::find($id);\n $product->name = $request['name'];\n $product->price = $request['price'];\n $product->description = $request['description'];\n $product->updated_by = Config::get('apiuser');\n $product->subcategories()->sync($subcategory->id);\n $product->subcategories()->updateExistingPivot($subcategory->id, array('uuid' => $subcategory_uuid, 'id' => $subcategory_id));\n $product->units()->sync($unit->id);\n $product->units()->updateExistingPivot($unit->id, array('uuid' => $unit_uuid, 'id' => $unit_id));\n $product->save();\n return response()->json([\n 'action' => 'update',\n 'status' => 'OK',\n 'entity' => $product->uuid,\n 'type' => 'product',\n 'user' => Config::get('apiuser')\n ], 200);\n }", "title": "" }, { "docid": "b482822e086a7ebee09ff81c09e4225d", "score": "0.54449975", "text": "public function update(Request $request, $id)\n {\n \\Validator::make($request->all(), [\n 'nama_product' => 'required', 'string', 'max:255', 'min:2',\n 'deskripsi' => 'required', 'string', 'max:255', 'min:8',\n 'stok' => 'required', 'max:1000',\n 'images' => 'file|image|mimes:jpeg,png,jpg',\n 'price' => 'required', 'max:20',\n ])->validate();\n \n $edit_product = Product::findOrFail($id);\n $edit_product->nama_product = $request->get('nama_product');\n $edit_product->deskripsi = $request->get('deskripsi');\n $edit_product->stok = $request->get('stok');\n if($request->file('images')){\n if($edit_product->images && file_exists(storage_path('app/public/' . $edit_product->images))){\n Storage::delete('public/'.$edit_product->images);\n $file = $request->file('images')->store('product_images', 'public');\n $edit_product->images = $file;\n }else{\n if($request->file('images')){\n $file = $request->file('images')->store('product_images', 'public');\n $edit_product->images = $file;\n }\n }\n }\n $edit_product->price = $request->get('price');\n \n if($request->get('status')){\n $edit_product->status = $request->get('status');\n }else{\n $edit_product->status = \"publish\";\n }\n\n \\Auth::user()->productId()->save($edit_product);\n\n return redirect()->route('manage-product.index')->with('status', 'Update Product Success!!');\n }", "title": "" }, { "docid": "fb30184e0b309716563a37352db2582d", "score": "0.5437578", "text": "public function put($data)\n {\n }", "title": "" }, { "docid": "e46fca820619683596020187e9c6b3b8", "score": "0.542987", "text": "public function updateImg(Request $request,$id)\n {\n $image = $request->file('image');\n $old_image = $request->get('old_image');\n\n $img_name =\"p_\".time().'.'.$image->getClientOriginalExtension();\n $path = $request->image->storeAs('products',$img_name,'public');\n\n $product = Product::find($id);\n $product->image = $path;\n $product->save();\n\n // return $image->getClientOriginalName();\n $exists = Storage::disk('public')->exists($old_image);\n if ($exists) {\n Storage::disk('public')->delete($old_image);\n } \n return $path;\n \n }", "title": "" }, { "docid": "90bfecb108e2227ad224fef4f176d822", "score": "0.54288775", "text": "public function update(ProductRequest $r, $id)\n {\n $r->validate([\n 'picture' => ['mimes:jpg,png,jpeg'], \n ]);\n\n $oldProduct = Product::findOrFail($id);\n\n if($r->hasFile('picture')) {\n \\Storage::disk('public')->delete('images/products/' . $oldProduct->picture);\n $file = $r->file('picture');\n $extension = $file->extension();\n $imgName = \\Str::slug($r->product_name) . '-' . time() . '.' . $extension;\n $file->storeAs('/images/products/', $imgName, 'public');\n } else {\n $imgName = $oldProduct->picture;\n }\n\n $oldProduct->update([\n 'product_name' => $r->product_name,\n 'picture' => $imgName,\n 'price' => $r->price,\n 'description' => $r->description,\n 'status' => $r->status,\n ]);\n\n return redirect()->route('admin.products.index')->with('success', 'Product Updated Successfully.');\n }", "title": "" }, { "docid": "90e900559eee2b9d3f91997a4f2fc922", "score": "0.5424842", "text": "public function update(StoreUpdateProductRequest $request, $id)\n {\n if(!$product = Product::find($id))\n return redirect()->back();\n\n $data = $request->all();\n\n if ($request->hasFile('image') && $request->image->isValid()) {\n\n if ($product->image && Storage::exists($product->image)){\n Storage::delete($product->image);\n }\n\n $imagePath = $request->image->store('products');\n $data['image'] = $imagePath;\n }\n \n $product->update($data);\n \n return redirect()->route('products.index')->with( 'message', 'Produto Editado'); \n }", "title": "" }, { "docid": "2fa0754ebc118bc9b4b721eefefed641", "score": "0.542287", "text": "public function update(StoreEditPartenaire $request, $id)\n {\n $partenaire = Partenaire::find($id);\n $partenaire->name = $request->name;\n $partenaire->url = $request->url;\n if($request->image != null){\n $partenaire->image = $request->image->store('','imgPartenaire');\n }\n $partenaire->save();\n return redirect()->route('partenaires.index',['partenaire'=> $partenaire->id]);\n \n }", "title": "" }, { "docid": "4d95f134a6e85e43f3f6f5bbc5cc2d52", "score": "0.54208726", "text": "public function update(Request $request, $id)\n {\n $nombre = $request->input('nombre');\n $imagen = $request->file('imagen');\n $descripcion = $request->input('descripcion');\n\n $ruta = \"-\";\n if($imagen){\n $ruta = $imagen->store('public'); \n $ruta = str_replace('public','storage',$ruta);\n }\n\n $categoria = Categoria::findOrFail($id);\n\n if($ruta!==\"-\"){\n $img = str_replace(\"storage/\", \"public/\", $categoria->imagen);\n $img = \"storage/\".$img;\n Storage::delete(asset('/storage/9yBlOG6KxNwaRoIrAKNpbBRr16q5PQyohbflIDcp.png'));\n }else{\n $ruta = $categoria->imagen;\n }\n\n $categoria->nombre = $nombre;\n $categoria->descripcion = $descripcion;\n $categoria->imagen = $ruta;\n $categoria->update();\n\n return redirect()->route('categoria.index');\n }", "title": "" }, { "docid": "a28ba9c40e06592529f38d6d19b89b16", "score": "0.54146737", "text": "public function update($id) {\n \n }", "title": "" }, { "docid": "67efbd9de14b40fa42d329e7897936e4", "score": "0.5414418", "text": "public function updatePreview()\n\t{\n\t\t // delete all files stored in the cache with the id of $this->id.'*.*';\n\t\t$fileHelper = new CFileHelper();\n\t\t$ff = $fileHelper->findFiles(Yii::app()->imageCache->imagePath('thumb'));\n\t\t$len = strlen($this->id);\n\t\t$info = new FileInformation();\n\t\tforeach ($ff as $f) {\n\t\t\t$info->path = $f;\n\t\t\tif (substr($info->filename, 0, $len) == $this->id){\n\t\t\t\tunlink($f);\n\t\t\t}\t\n\t\t}\t\n\t\t// let resource space do the work\n\t\t\n\t\t$s = Yii::app()->config->resourceSpaceApi.'api_import?id='.$this->id;\n\t\tif (Yii::app()->config->useCurl) {\n\t\t\tYii::log('Resource Space update through curl('.$s.')', CLogger::LEVEL_WARNING, 'application.models.Art.updatePreview');\t\t\t\n\t\t\t$run = Yii::app()->curl->run($s);\n\t\t} else {\t\t\t\n\t\t\tYii::log('Resource Space update through file_get_content('.$s.')', CLogger::LEVEL_WARNING, 'application.models.Art.updatePreview');\t\t\t\n\t\t\t$run = file_get_contents($s);\n\t\t}\t\n\t\tif ((is_object($run) && $run->hasErrors()) || (substr($run, 0, 33) != 'File added / updated for resource') ) {\n\t\t\tYii::log('Resource Space update failed.', CLogger::LEVEL_WARNING, 'application.models.Art.updatePreview');\t\t\t\n\t\t\t$this->addError('file', 'The resource space definition could not be updated.');\n\t\t} else {\n\t\t\tYii::log('Resource Space updated.', CLogger::LEVEL_INFO, 'application.models.Art.updatePreview');\t\t\t\n\t\t}\n\t}", "title": "" }, { "docid": "e77df2eef2b14f6f8a9a8237b99d6e65", "score": "0.5411387", "text": "public function update($id)\n\t{\n\t\t$v = Validator::make(Input::all(), array('file|image'));\n\n\t\tif($v->fails()) return Redirect::back()->withErrors($v)->withInput();\n\n\t\t$p = Product::find($id)->update(Input::all());\n\n\t\tif(Input::hasFile('file')){\n\n\t\t\tInput::file('file')->move('uploads', 'product_'.$id.'.jpg');\n\n\t\t}\n\n\t\treturn Redirect::route('products.index')->with('alert.success', Alert::text('supp'));\n\t\t\n\t}", "title": "" } ]
47288aa4f786776046fa6da62483e7f9
Load row values from recordset
[ { "docid": "5cdda8102421edf8e3f012abe2851333", "score": "0.6666917", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->jk_id->setDbValue($rs->fields('jk_id'));\n\t\t$this->jk_name->setDbValue($rs->fields('jk_name'));\n\t\t$this->jk_kode->setDbValue($rs->fields('jk_kode'));\n\t\t$this->use_set->setDbValue($rs->fields('use_set'));\n\t\t$this->jk_bcin->setDbValue($rs->fields('jk_bcin'));\n\t\t$this->jk_cin->setDbValue($rs->fields('jk_cin'));\n\t\t$this->jk_ecin->setDbValue($rs->fields('jk_ecin'));\n\t\t$this->jk_tol_late->setDbValue($rs->fields('jk_tol_late'));\n\t\t$this->jk_use_ist->setDbValue($rs->fields('jk_use_ist'));\n\t\t$this->jk_ist1->setDbValue($rs->fields('jk_ist1'));\n\t\t$this->jk_ist2->setDbValue($rs->fields('jk_ist2'));\n\t\t$this->jk_tol_early->setDbValue($rs->fields('jk_tol_early'));\n\t\t$this->jk_bcout->setDbValue($rs->fields('jk_bcout'));\n\t\t$this->jk_cout->setDbValue($rs->fields('jk_cout'));\n\t\t$this->jk_ecout->setDbValue($rs->fields('jk_ecout'));\n\t\t$this->use_eot->setDbValue($rs->fields('use_eot'));\n\t\t$this->min_eot->setDbValue($rs->fields('min_eot'));\n\t\t$this->max_eot->setDbValue($rs->fields('max_eot'));\n\t\t$this->reduce_eot->setDbValue($rs->fields('reduce_eot'));\n\t\t$this->jk_durasi->setDbValue($rs->fields('jk_durasi'));\n\t\t$this->jk_countas->setDbValue($rs->fields('jk_countas'));\n\t\t$this->jk_min_countas->setDbValue($rs->fields('jk_min_countas'));\n\t\t$this->jk_ket->setDbValue($rs->fields('jk_ket'));\n\t}", "title": "" } ]
[ { "docid": "7f8f52d5cfe5093e20e24422f07c3c19", "score": "0.72425157", "text": "function LoadRowValues(&$rs) {\r\n\t\tglobal $conn;\r\n\t\tif (!$rs || $rs->EOF) return;\r\n\r\n\t\t// Call Row Selected event\r\n\t\t$row = &$rs->fields;\r\n\t\t$this->Row_Selected($row);\r\n\t\t$this->idtools->setDbValue($rs->fields('idtools'));\r\n\t\t$this->target_domain->setDbValue($rs->fields('target_domain'));\r\n\t\t$this->type->setDbValue($rs->fields('type'));\r\n\t\t$this->url->setDbValue($rs->fields('url'));\r\n\t\t$this->time->setDbValue($rs->fields('time'));\r\n\t\t$this->status->setDbValue($rs->fields('status'));\r\n\t\t$this->log->setDbValue($rs->fields('log'));\r\n\t\t$this->parent_domain->setDbValue($rs->fields('parent_domain'));\r\n\t\t$this->Descripcion->setDbValue($rs->fields('Descripcion'));\r\n\t\t$this->tags->setDbValue($rs->fields('tags'));\r\n\t}", "title": "" }, { "docid": "ee799e6fc215899b8fdb7d2e15d8fca0", "score": "0.7237475", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->tse_id->setDbValue($rs->fields('tse_id'));\n\t\t$this->ts_from->setDbValue($rs->fields('ts_from'));\n\t\t$this->ts_thru->setDbValue($rs->fields('ts_thru'));\n\t\t$this->fk_tse->setDbValue($rs->fields('fk_tse'));\n\t\t$this->we_id->setDbValue($rs->fields('we_id'));\n\t\t$this->te_from->setDbValue($rs->fields('te_from'));\n\t\t$this->te_thru->setDbValue($rs->fields('te_thru'));\n\t\t$this->hours->setDbValue($rs->fields('hours'));\n\t}", "title": "" }, { "docid": "bcea7f97c967ac9e3da28c742bf2ee52", "score": "0.7219621", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $student_subjects;\n\t\t$student_subjects->studentSubjectID->setDbValue($rs->fields('studentSubjectID'));\n\t\t$student_subjects->studentID->setDbValue($rs->fields('studentID'));\n\t\t$student_subjects->subjectTeacherID->setDbValue($rs->fields('subjectTeacherID'));\n\t\t$student_subjects->termID->setDbValue($rs->fields('termID'));\n\t\t$student_subjects->vClassID->setDbValue($rs->fields('vClassID'));\n\t\t$student_subjects->caScore->setDbValue($rs->fields('caScore'));\n\t\t$student_subjects->examScore->setDbValue($rs->fields('examScore'));\n\t\t$student_subjects->grade->setDbValue($rs->fields('grade'));\n\t\t$student_subjects->comments->setDbValue($rs->fields('comments'));\n\t\t$student_subjects->status->setDbValue($rs->fields('status'));\n\t}", "title": "" }, { "docid": "e60c97b581668627bc4ed49a56716760", "score": "0.721198", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $news;\n\t\t$news->id->setDbValue($rs->fields('id'));\n\t\t$news->header->setDbValue($rs->fields('header'));\n\t\t$news->photo->Upload->DbValue = $rs->fields('photo');\n\t\t$news->short_desc->setDbValue($rs->fields('short_desc'));\n\t\t$news->full_desc->setDbValue($rs->fields('full_desc'));\n\t\t$news->insert_date->setDbValue($rs->fields('insert_date'));\n\t\t$news->status->setDbValue($rs->fields('status'));\n\t}", "title": "" }, { "docid": "89b682357e0c05b1f4ea0dd28e7d5709", "score": "0.7207774", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $t_nganhnghe;\n\t\t$t_nganhnghe->PK_NGANH_ID->setDbValue($rs->fields('PK_NGANH_ID'));\n\t\t$t_nganhnghe->C_BELONGTO->setDbValue($rs->fields('C_BELONGTO'));\n\t\t$t_nganhnghe->C_TENNGANH->setDbValue($rs->fields('C_TENNGANH'));\n\t\t$t_nganhnghe->C_TRANGTHAI->setDbValue($rs->fields('C_TRANGTHAI'));\n\t\t$t_nganhnghe->C_USER_ADD->setDbValue($rs->fields('C_USER_ADD'));\n\t\t$t_nganhnghe->C_ADD_TIME->setDbValue($rs->fields('C_ADD_TIME'));\n\t\t$t_nganhnghe->C_USER_EDIT->setDbValue($rs->fields('C_USER_EDIT'));\n\t\t$t_nganhnghe->C_EDIT_TIME->setDbValue($rs->fields('C_EDIT_TIME'));\n\t}", "title": "" }, { "docid": "839a2afb886cdcd5d6e4266286c703fa", "score": "0.71996677", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $acc_setting_coa;\n\t\t$acc_setting_coa->id->setDbValue($rs->fields('id'));\n\t\t$acc_setting_coa->description->setDbValue($rs->fields('description'));\n\t\t$acc_setting_coa->coa->setDbValue($rs->fields('coa'));\n\t}", "title": "" }, { "docid": "c7b45a50f2b3b7e66263403cb4a5c95e", "score": "0.71896607", "text": "function LoadRowValues(&$rs) {\r\n\t\tglobal $conn, $tbl_group;\r\n\t\t$tbl_group->id->setDbValue($rs->fields('id'));\r\n\t\t$tbl_group->name->setDbValue($rs->fields('name'));\r\n\t\t$tbl_group->is_active->setDbValue($rs->fields('is_active'));\r\n\t}", "title": "" }, { "docid": "8151babb265668569bbb69f3d3e44b6b", "score": "0.7165604", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $announcement;\n\t\t$announcement->id->setDbValue($rs->fields('id'));\n\t\t$announcement->lid->setDbValue($rs->fields('lid'));\n\t\t$announcement->title->setDbValue($rs->fields('title'));\n\t\t$announcement->announcement_1->setDbValue($rs->fields('announcement'));\n\t\t$announcement->active->setDbValue($rs->fields('active'));\n\t\t$announcement->koreantennis->setDbValue($rs->fields('koreantennis'));\n\t\t$announcement->timestamp->setDbValue($rs->fields('timestamp'));\n\t\t$_SESSION['announcement_post_time'] = $rs->fields('timestamp');\n\t}", "title": "" }, { "docid": "214941a5e98b8c58c6c1f79ef89075a2", "score": "0.7162721", "text": "function LoadRowValues($rs = NULL) {\n\t\tif ($rs && !$rs->EOF)\n\t\t\t$row = $rs->fields;\n\t\telse\n\t\t\t$row = $this->NewRow(); \n\n\t\t// Call Row Selected event\n\t\t$this->Row_Selected($row);\n\t\tif (!$rs || $rs->EOF)\n\t\t\treturn;\n\t\t$this->id->setDbValue($row['id']);\n\t\t$this->oauth_provider->setDbValue($row['oauth_provider']);\n\t\t$this->oauth_uid->setDbValue($row['oauth_uid']);\n\t\t$this->first_name->setDbValue($row['first_name']);\n\t\t$this->last_name->setDbValue($row['last_name']);\n\t\t$this->_email->setDbValue($row['email']);\n\t\t$this->gender->setDbValue($row['gender']);\n\t\t$this->locale->setDbValue($row['locale']);\n\t\t$this->cover->setDbValue($row['cover']);\n\t\t$this->picture->Upload->DbValue = $row['picture'];\n\t\t$this->picture->setDbValue($this->picture->Upload->DbValue);\n\t\t$this->link->setDbValue($row['link']);\n\t\t$this->created->setDbValue($row['created']);\n\t\t$this->modified->setDbValue($row['modified']);\n\t}", "title": "" }, { "docid": "7f9d1fe289fdac4a8f8bcef78e43ba1d", "score": "0.71609986", "text": "function LoadRowValues(&$rs) {\n global $avance_producto;\n $avance_producto->idConsultoria->setDbValue($rs->fields('idConsultoria'));\n $avance_producto->idCronograma->setDbValue($rs->fields('idCronograma'));\n }", "title": "" }, { "docid": "836ced873273bd672f4e16d15ccae921", "score": "0.7143609", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->tse_id->DbValue = $row['tse_id'];\n\t\t$this->ts_from->DbValue = $row['ts_from'];\n\t\t$this->ts_thru->DbValue = $row['ts_thru'];\n\t\t$this->fk_tse->DbValue = $row['fk_tse'];\n\t\t$this->we_id->DbValue = $row['we_id'];\n\t\t$this->te_from->DbValue = $row['te_from'];\n\t\t$this->te_thru->DbValue = $row['te_thru'];\n\t\t$this->hours->DbValue = $row['hours'];\n\t}", "title": "" }, { "docid": "942951ee6292c284e344e779cb9702d8", "score": "0.7136694", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $students;\n\t\t$students->studentID->setDbValue($rs->fields('studentID'));\n\t\t$students->admissionNumber->setDbValue($rs->fields('admissionNumber'));\n\t\t$students->firstname->setDbValue($rs->fields('firstname'));\n\t\t$students->middlename->setDbValue($rs->fields('middlename'));\n\t\t$students->lastname->setDbValue($rs->fields('lastname'));\n\t\t$students->gender->setDbValue($rs->fields('gender'));\n\t\t$students->dob->setDbValue($rs->fields('dob'));\n\t\t$students->residentialAddress->setDbValue($rs->fields('residentialAddress'));\n\t\t$students->residentState->setDbValue($rs->fields('residentState'));\n\t\t$students->stateOfOrigin->setDbValue($rs->fields('stateOfOrigin'));\n\t\t$students->currentClass->setDbValue($rs->fields('currentClass'));\n\t\t$students->portalUsername->setDbValue($rs->fields('portalUsername'));\n\t\t$students->portalPassword->setDbValue($rs->fields('portalPassword'));\n\t\t$students->parentID->setDbValue($rs->fields('parentID'));\n\t\t$students->studentImage->Upload->DbValue = $rs->fields('studentImage');\n\t\t$students->feesCreditBalance->setDbValue($rs->fields('feesCreditBalance'));\n\t\t$students->status->setDbValue($rs->fields('status'));\n\t}", "title": "" }, { "docid": "bdaf1c00db77b7c835be3d19a9860c80", "score": "0.7103867", "text": "function LoadListRowValues(&$rs) {\n\t\t$this->supplierID->setDbValue($rs->fields('supplierID'));\n\t\t$this->supplierCode->setDbValue($rs->fields('supplierCode'));\n\t\t$this->supplierName->setDbValue($rs->fields('supplierName'));\n\t\t$this->address->setDbValue($rs->fields('address'));\n\t\t$this->city->setDbValue($rs->fields('city'));\n\t\t$this->phone->setDbValue($rs->fields('phone'));\n\t\t$this->fax->setDbValue($rs->fields('fax'));\n\t\t$this->contactPerson->setDbValue($rs->fields('contactPerson'));\n\t\t$this->_email->setDbValue($rs->fields('email'));\n\t\t$this->balance->setDbValue($rs->fields('balance'));\n\t\t$this->createdDate->setDbValue($rs->fields('createdDate'));\n\t\t$this->createdUserID->setDbValue($rs->fields('createdUserID'));\n\t\t$this->modifiedDate->setDbValue($rs->fields('modifiedDate'));\n\t\t$this->modifiedUserID->setDbValue($rs->fields('modifiedUserID'));\n\t}", "title": "" }, { "docid": "2e1bcffaf8610158e23df1ece908aef9", "score": "0.7103086", "text": "function LoadRowValues(&$rs) {\r\n\t\tif (!$rs || $rs->EOF) return;\r\n\r\n\t\t// Call Row Selected event\r\n\t\t$row = &$rs->fields;\r\n\t\t$this->Row_Selected($row);\r\n\t\t$this->filename->setDbValue($rs->fields('filename'));\r\n\t\t$this->username->setDbValue($rs->fields('username'));\r\n\t\t$this->type->setDbValue($rs->fields('type'));\r\n\t\t$this->mediaid->setDbValue($rs->fields('mediaid'));\r\n\t\t$this->path->setDbValue($rs->fields('path'));\r\n\t\t$this->dateCreated->setDbValue($rs->fields('dateCreated'));\r\n\t\t$this->description->setDbValue($rs->fields('description'));\r\n\t\t$this->keywords->setDbValue($rs->fields('keywords'));\r\n\t\t$this->duration->setDbValue($rs->fields('duration'));\r\n\t\t$this->privacy->setDbValue($rs->fields('privacy'));\r\n\t\t$this->catagory->setDbValue($rs->fields('catagory'));\r\n\t}", "title": "" }, { "docid": "87a2024070c059948ef6c77bbef4388b", "score": "0.71026814", "text": "function LoadRowValues(&$rs) {\r\n\t\tglobal $conn;\r\n\t\tif (!$rs || $rs->EOF) return;\r\n\r\n\t\t// Call Row Selected event\r\n\t\t$row = &$rs->fields;\r\n\t\t$this->Row_Selected($row);\r\n\t\t$this->Id->setDbValue($rs->fields('Id'));\r\n\t\t$this->Nama->setDbValue($rs->fields('Nama'));\r\n\t\t$this->Alamat->setDbValue($rs->fields('Alamat'));\r\n\t\t$this->Jumlah->setDbValue($rs->fields('Jumlah'));\r\n\t\t$this->Provinsi->setDbValue($rs->fields('Provinsi'));\r\n\t\t$this->Area->setDbValue($rs->fields('Area'));\r\n\t\t$this->CP->setDbValue($rs->fields('CP'));\r\n\t\t$this->NoContact->setDbValue($rs->fields('NoContact'));\r\n\t\t$this->Tanggal->setDbValue($rs->fields('Tanggal'));\r\n\t\t$this->Jam->setDbValue($rs->fields('Jam'));\r\n\t\t$this->Vechicle->setDbValue($rs->fields('Vechicle'));\r\n\t\t$this->Type->setDbValue($rs->fields('Type'));\r\n\t\t$this->Site->setDbValue($rs->fields('Site'));\r\n\t\t$this->Status->setDbValue($rs->fields('Status'));\r\n\t\t$this->_UserID->setDbValue($rs->fields('UserID'));\r\n\t\t$this->TglInput->setDbValue($rs->fields('TglInput'));\r\n\t\t$this->visit->setDbValue($rs->fields('visit'));\r\n\t}", "title": "" }, { "docid": "1107fa9a0c700ab4621c45f25645ccbf", "score": "0.7099637", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->id->setDbValue($rs->fields('id'));\n\t\t$this->COL_1->setDbValue($rs->fields('COL 1'));\n\t\t$this->COL_2->setDbValue($rs->fields('COL 2'));\n\t\t$this->COL_3->setDbValue($rs->fields('COL 3'));\n\t\t$this->COL_4->setDbValue($rs->fields('COL 4'));\n\t\t$this->COL_5->setDbValue($rs->fields('COL 5'));\n\t\t$this->COL_6->setDbValue($rs->fields('COL 6'));\n\t\t$this->COL_7->setDbValue($rs->fields('COL 7'));\n\t\t$this->COL_8->setDbValue($rs->fields('COL 8'));\n\t\t$this->t_lab_db_id->setDbValue($rs->fields('t_lab_db_id'));\n\t\tif (array_key_exists('EV__t_lab_db_id', $rs->fields)) {\n\t\t\t$this->t_lab_db_id->VirtualValue = $rs->fields('EV__t_lab_db_id'); // Set up virtual field value\n\t\t} else {\n\t\t\t$this->t_lab_db_id->VirtualValue = \"\"; // Clear value\n\t\t}\n\t}", "title": "" }, { "docid": "7ae680ac8534561088ef0b7873347151", "score": "0.70944345", "text": "function LoadRowValues(&$rs) {\r\r\tglobal $ratings;\r\r\t$ratings->id->setDbValue($rs->fields('id'));\r\r\t$ratings->rating->setDbValue($rs->fields('rating'));\r\r\t$ratings->domain->setDbValue($rs->fields('domain'));\r\r\t$ratings->id_2->setDbValue($rs->fields('id_2'));\r\r}", "title": "" }, { "docid": "b07dd5e1af17a91aacfa40d97ab2a8c8", "score": "0.7090243", "text": "function LoadRowValues(&$rs) {\r\n\t\tglobal $conn;\r\n\t\tif (!$rs || $rs->EOF) return;\r\n\r\n\t\t// Call Row Selected event\r\n\t\t$row = &$rs->fields;\r\n\t\t$this->Row_Selected($row);\r\n\t\t$this->idfb_posts->setDbValue($rs->fields('idfb_posts'));\r\n\t\t$this->domain_id->setDbValue($rs->fields('domain_id'));\r\n\t\t$this->record_time->setDbValue($rs->fields('record_time'));\r\n\t\t$this->data->setDbValue($rs->fields('data'));\r\n\t\t$this->fid->setDbValue($rs->fields('fid'));\r\n\t\t$this->md5->setDbValue($rs->fields('md5'));\r\n\t\t$this->body->setDbValue($rs->fields('body'));\r\n\t\t$this->titulo->setDbValue($rs->fields('titulo'));\r\n\t\t$this->created_time->setDbValue($rs->fields('created_time'));\r\n\t\t$this->actions->setDbValue($rs->fields('actions'));\r\n\t\t$this->id->setDbValue($rs->fields('id'));\r\n\t\t$this->is_published->setDbValue($rs->fields('is_published'));\r\n\t\t$this->message->setDbValue($rs->fields('message'));\r\n\t\t$this->privacy->setDbValue($rs->fields('privacy'));\r\n\t\t$this->promotion_status->setDbValue($rs->fields('promotion_status'));\r\n\t\t$this->timeline_visibility->setDbValue($rs->fields('timeline_visibility'));\r\n\t\t$this->to->setDbValue($rs->fields('to'));\r\n\t\t$this->type->setDbValue($rs->fields('type'));\r\n\t\t$this->updated_time->setDbValue($rs->fields('updated_time'));\r\n\t\t$this->from->setDbValue($rs->fields('from'));\r\n\t\t$this->comments->setDbValue($rs->fields('comments'));\r\n\t\t$this->id_grupo->setDbValue($rs->fields('id_grupo'));\r\n\t\t$this->icon->setDbValue($rs->fields('icon'));\r\n\t\t$this->link->setDbValue($rs->fields('link'));\r\n\t\t$this->name->setDbValue($rs->fields('name'));\r\n\t\t$this->object_id->setDbValue($rs->fields('object_id'));\r\n\t\t$this->picture->setDbValue($rs->fields('picture'));\r\n\t\t$this->properties->setDbValue($rs->fields('properties'));\r\n\t\t$this->message_tags->setDbValue($rs->fields('message_tags'));\r\n\t\t$this->caption->setDbValue($rs->fields('caption'));\r\n\t\t$this->description->setDbValue($rs->fields('description'));\r\n\t\t$this->tool_id->setDbValue($rs->fields('tool_id'));\r\n\t\t$this->application->setDbValue($rs->fields('application'));\r\n\t}", "title": "" }, { "docid": "c7a1d82f3fee07beca5352f29e1642cb", "score": "0.7066146", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->objectID->setDbValue($rs->fields('objectID'));\n\t\t$this->objectName->setDbValue($rs->fields('objectName'));\n\t\t$this->ownerID->setDbValue($rs->fields('ownerID'));\n\t\t$this->ownerName->setDbValue($rs->fields('ownerName'));\n\t\t$this->lastName->setDbValue($rs->fields('lastName'));\n\t\t$this->mobilePhone->setDbValue($rs->fields('mobilePhone'));\n\t\t$this->color->setDbValue($rs->fields('color'));\n\t\t$this->status->setDbValue($rs->fields('status'));\n\t\t$this->content->setDbValue($rs->fields('content'));\n\t\t$this->financialValue->setDbValue($rs->fields('financialValue'));\n\t\t$this->registrationUser->setDbValue($rs->fields('registrationUser'));\n\t\t$this->registrationDateTime->setDbValue($rs->fields('registrationDateTime'));\n\t\t$this->registrationStation->setDbValue($rs->fields('registrationStation'));\n\t\t$this->isolatedDateTime->setDbValue($rs->fields('isolatedDateTime'));\n\t\t$this->description->setDbValue($rs->fields('description'));\n\t}", "title": "" }, { "docid": "cae7695e806aade029d4f6bce02838b1", "score": "0.70468587", "text": "function LoadRowValues(&$rs) {\r\n\t\tif (!$rs || $rs->EOF) return;\r\n\r\n\t\t// Call Row Selected event\r\n\t\t$row = &$rs->fields;\r\n\t\t$this->Row_Selected($row);\r\n\t\t$this->id->setDbValue($rs->fields('id'));\r\n\t\t$this->arrival->setDbValue($rs->fields('arrival'));\r\n\t\t$this->departure->setDbValue($rs->fields('departure'));\r\n\t\t$this->user->setDbValue($rs->fields('user'));\r\n\t\t$this->name->setDbValue($rs->fields('name'));\r\n\t\t$this->_email->setDbValue($rs->fields('email'));\r\n\t\t$this->country->setDbValue($rs->fields('country'));\r\n\t\t$this->approve->setDbValue($rs->fields('approve'));\r\n\t\t$this->room->setDbValue($rs->fields('room'));\r\n\t\t$this->roomnumber->setDbValue($rs->fields('roomnumber'));\r\n\t\t$this->number->setDbValue($rs->fields('number'));\r\n\t\t$this->childs->setDbValue($rs->fields('childs'));\r\n\t\t$this->price->setDbValue($rs->fields('price'));\r\n\t\t$this->custom->setDbValue($rs->fields('custom'));\r\n\t\t$this->customp->setDbValue($rs->fields('customp'));\r\n\t\t$this->reservated->setDbValue($rs->fields('reservated'));\r\n\t}", "title": "" }, { "docid": "9ed0f819ca5bf2df10c8eed6ae3f94d9", "score": "0.70411736", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->id->DbValue = $row['id'];\n\t\t$this->COL_1->DbValue = $row['COL 1'];\n\t\t$this->COL_2->DbValue = $row['COL 2'];\n\t\t$this->COL_3->DbValue = $row['COL 3'];\n\t\t$this->COL_4->DbValue = $row['COL 4'];\n\t\t$this->COL_5->DbValue = $row['COL 5'];\n\t\t$this->COL_6->DbValue = $row['COL 6'];\n\t\t$this->COL_7->DbValue = $row['COL 7'];\n\t\t$this->COL_8->DbValue = $row['COL 8'];\n\t\t$this->t_lab_db_id->DbValue = $row['t_lab_db_id'];\n\t}", "title": "" }, { "docid": "9bf8887fc74a629cd616eda8d07908e9", "score": "0.7040294", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->codigo->setDbValue($rs->fields('codigo'));\n\t\t$this->usuario->setDbValue($rs->fields('usuario'));\n\t\t$this->contrasenia->setDbValue($rs->fields('contrasenia'));\n\t\t$this->nombre->setDbValue($rs->fields('nombre'));\n\t\t$this->_email->setDbValue($rs->fields('email'));\n\t\t$this->activo->setDbValue($rs->fields('activo'));\n\t}", "title": "" }, { "docid": "71935d09205447ab7e4d8bc8f5296949", "score": "0.7034884", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->ID->setDbValue($rs->fields('ID'));\n\t\t$this->Name->setDbValue($rs->fields('Name'));\n\t\t$this->UniversityID->setDbValue($rs->fields('UniversityID'));\n\t\t$this->College->setDbValue($rs->fields('College'));\n\t\t$this->Department->setDbValue($rs->fields('Department'));\n\t\t$this->StartDate->setDbValue($rs->fields('StartDate'));\n\t\t$this->EndDate->setDbValue($rs->fields('EndDate'));\n\t\t$this->PlaceVisited->setDbValue($rs->fields('PlaceVisited'));\n\t\t$this->NatureOfVisit->setDbValue($rs->fields('NatureOfVisit'));\n\t\t$this->AttendanceOnly->setDbValue($rs->fields('AttendanceOnly'));\n\t\t$this->PresentAPaper->setDbValue($rs->fields('PresentAPaper'));\n\t\t$this->Others->setDbValue($rs->fields('Others'));\n\t\t$this->Participation->setDbValue($rs->fields('Participation'));\n\t\t$this->Summary->setDbValue($rs->fields('Summary'));\n\t\t$this->SuggestionRecommendation->setDbValue($rs->fields('SuggestionRecommendation'));\n\t\t$this->FacultyMemberSign->setDbValue($rs->fields('FacultyMemberSign'));\n\t\t$this->DepChairmanSign->setDbValue($rs->fields('DepChairmanSign'));\n\t\t$this->DeanSign->setDbValue($rs->fields('DeanSign'));\n\t}", "title": "" }, { "docid": "aeb5561eaf1ba23142f92425ecfdd906", "score": "0.7032392", "text": "function LoadRowValues(&$rs) {\r\n\t\tif (!$rs || $rs->EOF) return;\r\n\r\n\t\t// Call Row Selected event\r\n\t\t$row = &$rs->fields;\r\n\t\t$this->Row_Selected($row);\r\n\t\t$this->ID->setDbValue($rs->fields('ID'));\r\n\t\t$this->username->setDbValue($rs->fields('username'));\r\n\t\t$this->password->setDbValue($rs->fields('password'));\r\n\t\t$this->FristName->setDbValue($rs->fields('FristName'));\r\n\t\t$this->LastName->setDbValue($rs->fields('LastName'));\r\n\t\t$this->_Email->setDbValue($rs->fields('Email'));\r\n\t\t$this->Gender->setDbValue($rs->fields('Gender'));\r\n\t\t$this->BirthDate->setDbValue($rs->fields('BirthDate'));\r\n\t\t$this->permissions->setDbValue($rs->fields('permissions'));\r\n\t}", "title": "" }, { "docid": "87effeaed20a4d061821080824bee273", "score": "0.7029973", "text": "function LoadListRowValues(&$rs) {\n\t\t$this->id->setDbValue($rs->fields('id'));\n\t\t$this->id_sector->setDbValue($rs->fields('id_sector'));\n\t\t$this->id_tipoactividad->setDbValue($rs->fields('id_tipoactividad'));\n\t\t$this->organizador->setDbValue($rs->fields('organizador'));\n\t\t$this->nombreactividad->setDbValue($rs->fields('nombreactividad'));\n\t\t$this->nombrelocal->setDbValue($rs->fields('nombrelocal'));\n\t\t$this->direccionlocal->setDbValue($rs->fields('direccionlocal'));\n\t\t$this->fecha_inicio->setDbValue($rs->fields('fecha_inicio'));\n\t\t$this->fecha_fin->setDbValue($rs->fields('fecha_fin'));\n\t\t$this->horasprogramadas->setDbValue($rs->fields('horasprogramadas'));\n\t\t$this->id_persona->setDbValue($rs->fields('id_persona'));\n\t\t$this->contenido->setDbValue($rs->fields('contenido'));\n\t\t$this->observaciones->setDbValue($rs->fields('observaciones'));\n\t\t$this->id_centro->setDbValue($rs->fields('id_centro'));\n\t}", "title": "" }, { "docid": "7f0dd0f81231c45239682a4d918bbe37", "score": "0.7013318", "text": "public function loadRowValues($rs = null)\n {\n if (is_array($rs)) {\n $row = $rs;\n } elseif ($rs && property_exists($rs, \"fields\")) { // Recordset\n $row = $rs->fields;\n } else {\n $row = $this->newRow();\n }\n if (!$row) {\n return;\n }\n\n // Call Row Selected event\n $this->rowSelected($row);\n $this->id->setDbValue($row['id']);\n $this->federationId->setDbValue($row['federationId']);\n $this->masterSchoolId->setDbValue($row['masterSchoolId']);\n $this->school->setDbValue($row['school']);\n $this->countryId->setDbValue($row['countryId']);\n $this->UFId->setDbValue($row['UFId']);\n $this->cityId->setDbValue($row['cityId']);\n if (array_key_exists('EV__cityId', $row)) {\n $this->cityId->VirtualValue = $row['EV__cityId']; // Set up virtual field value\n } else {\n $this->cityId->VirtualValue = \"\"; // Clear value\n }\n $this->neighborhood->setDbValue($row['neighborhood']);\n $this->address->setDbValue($row['address']);\n $this->zipcode->setDbValue($row['zipcode']);\n $this->website->setDbValue($row['website']);\n $this->_email->setDbValue($row['email']);\n $this->phone->setDbValue($row['phone']);\n $this->celphone->setDbValue($row['celphone']);\n $this->logo->setDbValue($row['logo']);\n $this->openingDate->setDbValue($row['openingDate']);\n $this->federationRegister->setDbValue($row['federationRegister']);\n $this->createUserId->setDbValue($row['createUserId']);\n $this->createDate->setDbValue($row['createDate']);\n $this->typeId->setDbValue($row['typeId']);\n $this->owner->setDbValue($row['owner']);\n $this->identityNumber->setDbValue($row['identityNumber']);\n $this->birthDateOwner->setDbValue($row['birthDateOwner']);\n $this->ownerCountryId->setDbValue($row['ownerCountryId']);\n $this->ownerStateId->setDbValue($row['ownerStateId']);\n $this->ownCityId->setDbValue($row['ownCityId']);\n $this->ownerTelephone->setDbValue($row['ownerTelephone']);\n $this->ownerTelephoneWork->setDbValue($row['ownerTelephoneWork']);\n $this->ownerProfession->setDbValue($row['ownerProfession']);\n $this->employer->setDbValue($row['employer']);\n $this->ownerGraduation->setDbValue($row['ownerGraduation']);\n $this->ownerGraduationLocation->setDbValue($row['ownerGraduationLocation']);\n $this->ownerGraduationObs->setDbValue($row['ownerGraduationObs']);\n $this->ownerMaritalStatus->setDbValue($row['ownerMaritalStatus']);\n $this->ownerSpouseName->setDbValue($row['ownerSpouseName']);\n $this->ownerSpouseProfession->setDbValue($row['ownerSpouseProfession']);\n $this->propertySituation->setDbValue($row['propertySituation']);\n $this->numberOfStudentsInBeginnig->setDbValue($row['numberOfStudentsInBeginnig']);\n $this->ownerAbout->setDbValue($row['ownerAbout']);\n $this->pdfLicense->setDbValue($row['pdfLicense']);\n $this->applicationId->setDbValue($row['applicationId']);\n $this->isheadquarter->setDbValue($row['isheadquarter']);\n }", "title": "" }, { "docid": "14687c7f48139bc13dd4ff61b315ba28", "score": "0.6983721", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $CustomView1;\n\t\t$CustomView1->DetailNo->setDbValue($rs->fields('DetailNo'));\n\t\t$CustomView1->PatientID->setDbValue($rs->fields('PatientID'));\n\t\t$CustomView1->StudyDate->setDbValue($rs->fields('StudyDate'));\n\t\t$CustomView1->StudyTime->setDbValue($rs->fields('StudyTime'));\n\t\t$CustomView1->PatientName->setDbValue($rs->fields('PatientName'));\n\t\t$CustomView1->PatientSex->setDbValue($rs->fields('PatientSex'));\n\t\t$CustomView1->Modality->setDbValue($rs->fields('Modality'));\n\t\t$CustomView1->ProtocolName->setDbValue($rs->fields('ProtocolName'));\n\t\t$CustomView1->BodyPartExamined->setDbValue($rs->fields('BodyPartExamined'));\n\t\t$CustomView1->StudyID->setDbValue($rs->fields('StudyID'));\n\t\t$CustomView1->InstanceNumber->setDbValue($rs->fields('InstanceNumber'));\n\t\t$CustomView1->Status->setDbValue($rs->fields('Status'));\n\t}", "title": "" }, { "docid": "466329ee6373cefce1ffae3c3bc1dc39", "score": "0.6969827", "text": "function LoadRowValues(&$rs) {\r\n\t\tglobal $conn;\r\n\t\tif (!$rs || $rs->EOF) return;\r\n\r\n\t\t// Call Row Selected event\r\n\t\t$row = &$rs->fields;\r\n\t\t$this->Row_Selected($row);\r\n\t\t$this->Id_Articulo->setDbValue($rs->fields('Id_Articulo'));\r\n\t\t$this->Articulo->setDbValue($rs->fields('Articulo'));\r\n\t\t$this->Codigo->setDbValue($rs->fields('Codigo'));\r\n\t\t$this->COD_Compania_eq->setDbValue($rs->fields('COD_Compania_eq'));\r\n\t\t$this->Amigo_CHIP->setDbValue($rs->fields('Amigo_CHIP'));\r\n\t\t$this->Activacion_Movi->setDbValue($rs->fields('Activacion_Movi'));\r\n\t\t$this->Precio_compra->setDbValue($rs->fields('Precio_compra'));\r\n\t\t$this->Precio_lista_venta_publico_1->setDbValue($rs->fields('Precio_lista_venta_publico_1'));\r\n\t\t$this->Precio_lista_venta_publico_2->setDbValue($rs->fields('Precio_lista_venta_publico_2'));\r\n\t\t$this->Precio_lista_venta_publico_3->setDbValue($rs->fields('Precio_lista_venta_publico_3'));\r\n\t\t$this->Precio_lista_venta_medio_mayoreo->setDbValue($rs->fields('Precio_lista_venta_medio_mayoreo'));\r\n\t\t$this->Precio_lista_venta_mayoreo->setDbValue($rs->fields('Precio_lista_venta_mayoreo'));\r\n\t\t$this->TipoArticulo->setDbValue($rs->fields('TipoArticulo'));\r\n\t\t$this->Id_Almacen_Entrada->setDbValue($rs->fields('Id_Almacen_Entrada'));\r\n\t\t$this->Status->setDbValue($rs->fields('Status'));\r\n\t}", "title": "" }, { "docid": "9dc0587f3074df8e9ba308fde94ebf06", "score": "0.6963963", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->id->setDbValue($rs->fields('id'));\n\t\t$this->NOMR->setDbValue($rs->fields('NOMR'));\n\t\t$this->TITLE->setDbValue($rs->fields('TITLE'));\n\t\t$this->NAMA->setDbValue($rs->fields('NAMA'));\n\t\t$this->IBUKANDUNG->setDbValue($rs->fields('IBUKANDUNG'));\n\t\t$this->TEMPAT->setDbValue($rs->fields('TEMPAT'));\n\t\t$this->TGLLAHIR->setDbValue($rs->fields('TGLLAHIR'));\n\t\t$this->JENISKELAMIN->setDbValue($rs->fields('JENISKELAMIN'));\n\t\t$this->ALAMAT->setDbValue($rs->fields('ALAMAT'));\n\t\t$this->KDPROVINSI->setDbValue($rs->fields('KDPROVINSI'));\n\t\t$this->KOTA->setDbValue($rs->fields('KOTA'));\n\t\t$this->KDKECAMATAN->setDbValue($rs->fields('KDKECAMATAN'));\n\t\t$this->KELURAHAN->setDbValue($rs->fields('KELURAHAN'));\n\t\t$this->NOTELP->setDbValue($rs->fields('NOTELP'));\n\t\t$this->NOKTP->setDbValue($rs->fields('NOKTP'));\n\t\t$this->SUAMI_ORTU->setDbValue($rs->fields('SUAMI_ORTU'));\n\t\t$this->PEKERJAAN->setDbValue($rs->fields('PEKERJAAN'));\n\t\t$this->STATUS->setDbValue($rs->fields('STATUS'));\n\t\t$this->AGAMA->setDbValue($rs->fields('AGAMA'));\n\t\t$this->PENDIDIKAN->setDbValue($rs->fields('PENDIDIKAN'));\n\t\t$this->KDCARABAYAR->setDbValue($rs->fields('KDCARABAYAR'));\n\t\t$this->NIP->setDbValue($rs->fields('NIP'));\n\t\t$this->TGLDAFTAR->setDbValue($rs->fields('TGLDAFTAR'));\n\t\t$this->ALAMAT_KTP->setDbValue($rs->fields('ALAMAT_KTP'));\n\t\t$this->PARENT_NOMR->setDbValue($rs->fields('PARENT_NOMR'));\n\t\t$this->NAMA_OBAT->setDbValue($rs->fields('NAMA_OBAT'));\n\t\t$this->DOSIS->setDbValue($rs->fields('DOSIS'));\n\t\t$this->CARA_PEMBERIAN->setDbValue($rs->fields('CARA_PEMBERIAN'));\n\t\t$this->FREKUENSI->setDbValue($rs->fields('FREKUENSI'));\n\t\t$this->WAKTU_TGL->setDbValue($rs->fields('WAKTU_TGL'));\n\t\t$this->LAMA_WAKTU->setDbValue($rs->fields('LAMA_WAKTU'));\n\t\t$this->ALERGI_OBAT->setDbValue($rs->fields('ALERGI_OBAT'));\n\t\t$this->REAKSI_ALERGI->setDbValue($rs->fields('REAKSI_ALERGI'));\n\t\t$this->RIWAYAT_KES->setDbValue($rs->fields('RIWAYAT_KES'));\n\t\t$this->BB_LAHIR->setDbValue($rs->fields('BB_LAHIR'));\n\t\t$this->BB_SEKARANG->setDbValue($rs->fields('BB_SEKARANG'));\n\t\t$this->FISIK_FONTANEL->setDbValue($rs->fields('FISIK_FONTANEL'));\n\t\t$this->FISIK_REFLEKS->setDbValue($rs->fields('FISIK_REFLEKS'));\n\t\t$this->FISIK_SENSASI->setDbValue($rs->fields('FISIK_SENSASI'));\n\t\t$this->MOTORIK_KASAR->setDbValue($rs->fields('MOTORIK_KASAR'));\n\t\t$this->MOTORIK_HALUS->setDbValue($rs->fields('MOTORIK_HALUS'));\n\t\t$this->MAMPU_BICARA->setDbValue($rs->fields('MAMPU_BICARA'));\n\t\t$this->MAMPU_SOSIALISASI->setDbValue($rs->fields('MAMPU_SOSIALISASI'));\n\t\t$this->BCG->setDbValue($rs->fields('BCG'));\n\t\t$this->POLIO->setDbValue($rs->fields('POLIO'));\n\t\t$this->DPT->setDbValue($rs->fields('DPT'));\n\t\t$this->CAMPAK->setDbValue($rs->fields('CAMPAK'));\n\t\t$this->HEPATITIS_B->setDbValue($rs->fields('HEPATITIS_B'));\n\t\t$this->TD->setDbValue($rs->fields('TD'));\n\t\t$this->SUHU->setDbValue($rs->fields('SUHU'));\n\t\t$this->RR->setDbValue($rs->fields('RR'));\n\t\t$this->NADI->setDbValue($rs->fields('NADI'));\n\t\t$this->BB->setDbValue($rs->fields('BB'));\n\t\t$this->TB->setDbValue($rs->fields('TB'));\n\t\t$this->EYE->setDbValue($rs->fields('EYE'));\n\t\t$this->MOTORIK->setDbValue($rs->fields('MOTORIK'));\n\t\t$this->VERBAL->setDbValue($rs->fields('VERBAL'));\n\t\t$this->TOTAL_GCS->setDbValue($rs->fields('TOTAL_GCS'));\n\t\t$this->REAKSI_PUPIL->setDbValue($rs->fields('REAKSI_PUPIL'));\n\t\t$this->KESADARAN->setDbValue($rs->fields('KESADARAN'));\n\t\t$this->KEPALA->setDbValue($rs->fields('KEPALA'));\n\t\t$this->RAMBUT->setDbValue($rs->fields('RAMBUT'));\n\t\t$this->MUKA->setDbValue($rs->fields('MUKA'));\n\t\t$this->MATA->setDbValue($rs->fields('MATA'));\n\t\t$this->GANG_LIHAT->setDbValue($rs->fields('GANG_LIHAT'));\n\t\t$this->ALATBANTU_LIHAT->setDbValue($rs->fields('ALATBANTU_LIHAT'));\n\t\t$this->BENTUK->setDbValue($rs->fields('BENTUK'));\n\t\t$this->PENDENGARAN->setDbValue($rs->fields('PENDENGARAN'));\n\t\t$this->LUB_TELINGA->setDbValue($rs->fields('LUB_TELINGA'));\n\t\t$this->BENTUK_HIDUNG->setDbValue($rs->fields('BENTUK_HIDUNG'));\n\t\t$this->MEMBRAN_MUK->setDbValue($rs->fields('MEMBRAN_MUK'));\n\t\t$this->MAMPU_HIDU->setDbValue($rs->fields('MAMPU_HIDU'));\n\t\t$this->ALAT_HIDUNG->setDbValue($rs->fields('ALAT_HIDUNG'));\n\t\t$this->RONGGA_MULUT->setDbValue($rs->fields('RONGGA_MULUT'));\n\t\t$this->WARNA_MEMBRAN->setDbValue($rs->fields('WARNA_MEMBRAN'));\n\t\t$this->LEMBAB->setDbValue($rs->fields('LEMBAB'));\n\t\t$this->STOMATITIS->setDbValue($rs->fields('STOMATITIS'));\n\t\t$this->LIDAH->setDbValue($rs->fields('LIDAH'));\n\t\t$this->GIGI->setDbValue($rs->fields('GIGI'));\n\t\t$this->TONSIL->setDbValue($rs->fields('TONSIL'));\n\t\t$this->KELAINAN->setDbValue($rs->fields('KELAINAN'));\n\t\t$this->PERGERAKAN->setDbValue($rs->fields('PERGERAKAN'));\n\t\t$this->KEL_TIROID->setDbValue($rs->fields('KEL_TIROID'));\n\t\t$this->KEL_GETAH->setDbValue($rs->fields('KEL_GETAH'));\n\t\t$this->TEKANAN_VENA->setDbValue($rs->fields('TEKANAN_VENA'));\n\t\t$this->REF_MENELAN->setDbValue($rs->fields('REF_MENELAN'));\n\t\t$this->NYERI->setDbValue($rs->fields('NYERI'));\n\t\t$this->KREPITASI->setDbValue($rs->fields('KREPITASI'));\n\t\t$this->KEL_LAIN->setDbValue($rs->fields('KEL_LAIN'));\n\t\t$this->BENTUK_DADA->setDbValue($rs->fields('BENTUK_DADA'));\n\t\t$this->POLA_NAPAS->setDbValue($rs->fields('POLA_NAPAS'));\n\t\t$this->BENTUK_THORAKS->setDbValue($rs->fields('BENTUK_THORAKS'));\n\t\t$this->PAL_KREP->setDbValue($rs->fields('PAL_KREP'));\n\t\t$this->BENJOLAN->setDbValue($rs->fields('BENJOLAN'));\n\t\t$this->PAL_NYERI->setDbValue($rs->fields('PAL_NYERI'));\n\t\t$this->PERKUSI->setDbValue($rs->fields('PERKUSI'));\n\t\t$this->PARU->setDbValue($rs->fields('PARU'));\n\t\t$this->JANTUNG->setDbValue($rs->fields('JANTUNG'));\n\t\t$this->SUARA_JANTUNG->setDbValue($rs->fields('SUARA_JANTUNG'));\n\t\t$this->ALATBANTU_JAN->setDbValue($rs->fields('ALATBANTU_JAN'));\n\t\t$this->BENTUK_ABDOMEN->setDbValue($rs->fields('BENTUK_ABDOMEN'));\n\t\t$this->AUSKULTASI->setDbValue($rs->fields('AUSKULTASI'));\n\t\t$this->NYERI_PASI->setDbValue($rs->fields('NYERI_PASI'));\n\t\t$this->PEM_KELENJAR->setDbValue($rs->fields('PEM_KELENJAR'));\n\t\t$this->PERKUSI_AUS->setDbValue($rs->fields('PERKUSI_AUS'));\n\t\t$this->VAGINA->setDbValue($rs->fields('VAGINA'));\n\t\t$this->MENSTRUASI->setDbValue($rs->fields('MENSTRUASI'));\n\t\t$this->KATETER->setDbValue($rs->fields('KATETER'));\n\t\t$this->LABIA_PROM->setDbValue($rs->fields('LABIA_PROM'));\n\t\t$this->HAMIL->setDbValue($rs->fields('HAMIL'));\n\t\t$this->TGL_HAID->setDbValue($rs->fields('TGL_HAID'));\n\t\t$this->PERIKSA_CERVIX->setDbValue($rs->fields('PERIKSA_CERVIX'));\n\t\t$this->BENTUK_PAYUDARA->setDbValue($rs->fields('BENTUK_PAYUDARA'));\n\t\t$this->KENYAL->setDbValue($rs->fields('KENYAL'));\n\t\t$this->MASSA->setDbValue($rs->fields('MASSA'));\n\t\t$this->NYERI_RABA->setDbValue($rs->fields('NYERI_RABA'));\n\t\t$this->BENTUK_PUTING->setDbValue($rs->fields('BENTUK_PUTING'));\n\t\t$this->MAMMO->setDbValue($rs->fields('MAMMO'));\n\t\t$this->ALAT_KONTRASEPSI->setDbValue($rs->fields('ALAT_KONTRASEPSI'));\n\t\t$this->MASALAH_SEKS->setDbValue($rs->fields('MASALAH_SEKS'));\n\t\t$this->PREPUTIUM->setDbValue($rs->fields('PREPUTIUM'));\n\t\t$this->MASALAH_PROSTAT->setDbValue($rs->fields('MASALAH_PROSTAT'));\n\t\t$this->BENTUK_SKROTUM->setDbValue($rs->fields('BENTUK_SKROTUM'));\n\t\t$this->TESTIS->setDbValue($rs->fields('TESTIS'));\n\t\t$this->MASSA_BEN->setDbValue($rs->fields('MASSA_BEN'));\n\t\t$this->HERNIASI->setDbValue($rs->fields('HERNIASI'));\n\t\t$this->LAIN2->setDbValue($rs->fields('LAIN2'));\n\t\t$this->ALAT_KONTRA->setDbValue($rs->fields('ALAT_KONTRA'));\n\t\t$this->MASALAH_REPRO->setDbValue($rs->fields('MASALAH_REPRO'));\n\t\t$this->EKSTREMITAS_ATAS->setDbValue($rs->fields('EKSTREMITAS_ATAS'));\n\t\t$this->EKSTREMITAS_BAWAH->setDbValue($rs->fields('EKSTREMITAS_BAWAH'));\n\t\t$this->AKTIVITAS->setDbValue($rs->fields('AKTIVITAS'));\n\t\t$this->BERJALAN->setDbValue($rs->fields('BERJALAN'));\n\t\t$this->SISTEM_INTE->setDbValue($rs->fields('SISTEM_INTE'));\n\t\t$this->KENYAMANAN->setDbValue($rs->fields('KENYAMANAN'));\n\t\t$this->KES_DIRI->setDbValue($rs->fields('KES_DIRI'));\n\t\t$this->SOS_SUPORT->setDbValue($rs->fields('SOS_SUPORT'));\n\t\t$this->ANSIETAS->setDbValue($rs->fields('ANSIETAS'));\n\t\t$this->KEHILANGAN->setDbValue($rs->fields('KEHILANGAN'));\n\t\t$this->STATUS_EMOSI->setDbValue($rs->fields('STATUS_EMOSI'));\n\t\t$this->KONSEP_DIRI->setDbValue($rs->fields('KONSEP_DIRI'));\n\t\t$this->RESPON_HILANG->setDbValue($rs->fields('RESPON_HILANG'));\n\t\t$this->SUMBER_STRESS->setDbValue($rs->fields('SUMBER_STRESS'));\n\t\t$this->BERARTI->setDbValue($rs->fields('BERARTI'));\n\t\t$this->TERLIBAT->setDbValue($rs->fields('TERLIBAT'));\n\t\t$this->HUBUNGAN->setDbValue($rs->fields('HUBUNGAN'));\n\t\t$this->KOMUNIKASI->setDbValue($rs->fields('KOMUNIKASI'));\n\t\t$this->KEPUTUSAN->setDbValue($rs->fields('KEPUTUSAN'));\n\t\t$this->MENGASUH->setDbValue($rs->fields('MENGASUH'));\n\t\t$this->DUKUNGAN->setDbValue($rs->fields('DUKUNGAN'));\n\t\t$this->REAKSI->setDbValue($rs->fields('REAKSI'));\n\t\t$this->BUDAYA->setDbValue($rs->fields('BUDAYA'));\n\t\t$this->POLA_AKTIVITAS->setDbValue($rs->fields('POLA_AKTIVITAS'));\n\t\t$this->POLA_ISTIRAHAT->setDbValue($rs->fields('POLA_ISTIRAHAT'));\n\t\t$this->POLA_MAKAN->setDbValue($rs->fields('POLA_MAKAN'));\n\t\t$this->PANTANGAN->setDbValue($rs->fields('PANTANGAN'));\n\t\t$this->KEPERCAYAAN->setDbValue($rs->fields('KEPERCAYAAN'));\n\t\t$this->PANTANGAN_HARI->setDbValue($rs->fields('PANTANGAN_HARI'));\n\t\t$this->PANTANGAN_LAIN->setDbValue($rs->fields('PANTANGAN_LAIN'));\n\t\t$this->ANJURAN->setDbValue($rs->fields('ANJURAN'));\n\t\t$this->NILAI_KEYAKINAN->setDbValue($rs->fields('NILAI_KEYAKINAN'));\n\t\t$this->KEGIATAN_IBADAH->setDbValue($rs->fields('KEGIATAN_IBADAH'));\n\t\t$this->PENG_AGAMA->setDbValue($rs->fields('PENG_AGAMA'));\n\t\t$this->SPIRIT->setDbValue($rs->fields('SPIRIT'));\n\t\t$this->BANTUAN->setDbValue($rs->fields('BANTUAN'));\n\t\t$this->PAHAM_PENYAKIT->setDbValue($rs->fields('PAHAM_PENYAKIT'));\n\t\t$this->PAHAM_OBAT->setDbValue($rs->fields('PAHAM_OBAT'));\n\t\t$this->PAHAM_NUTRISI->setDbValue($rs->fields('PAHAM_NUTRISI'));\n\t\t$this->PAHAM_RAWAT->setDbValue($rs->fields('PAHAM_RAWAT'));\n\t\t$this->HAMBATAN_EDUKASI->setDbValue($rs->fields('HAMBATAN_EDUKASI'));\n\t\t$this->FREK_MAKAN->setDbValue($rs->fields('FREK_MAKAN'));\n\t\t$this->JUM_MAKAN->setDbValue($rs->fields('JUM_MAKAN'));\n\t\t$this->JEN_MAKAN->setDbValue($rs->fields('JEN_MAKAN'));\n\t\t$this->KOM_MAKAN->setDbValue($rs->fields('KOM_MAKAN'));\n\t\t$this->DIET->setDbValue($rs->fields('DIET'));\n\t\t$this->CARA_MAKAN->setDbValue($rs->fields('CARA_MAKAN'));\n\t\t$this->GANGGUAN->setDbValue($rs->fields('GANGGUAN'));\n\t\t$this->FREK_MINUM->setDbValue($rs->fields('FREK_MINUM'));\n\t\t$this->JUM_MINUM->setDbValue($rs->fields('JUM_MINUM'));\n\t\t$this->JEN_MINUM->setDbValue($rs->fields('JEN_MINUM'));\n\t\t$this->GANG_MINUM->setDbValue($rs->fields('GANG_MINUM'));\n\t\t$this->FREK_BAK->setDbValue($rs->fields('FREK_BAK'));\n\t\t$this->WARNA_BAK->setDbValue($rs->fields('WARNA_BAK'));\n\t\t$this->JMLH_BAK->setDbValue($rs->fields('JMLH_BAK'));\n\t\t$this->PENG_KAT_BAK->setDbValue($rs->fields('PENG_KAT_BAK'));\n\t\t$this->KEM_HAN_BAK->setDbValue($rs->fields('KEM_HAN_BAK'));\n\t\t$this->INKONT_BAK->setDbValue($rs->fields('INKONT_BAK'));\n\t\t$this->DIURESIS_BAK->setDbValue($rs->fields('DIURESIS_BAK'));\n\t\t$this->FREK_BAB->setDbValue($rs->fields('FREK_BAB'));\n\t\t$this->WARNA_BAB->setDbValue($rs->fields('WARNA_BAB'));\n\t\t$this->KONSIST_BAB->setDbValue($rs->fields('KONSIST_BAB'));\n\t\t$this->GANG_BAB->setDbValue($rs->fields('GANG_BAB'));\n\t\t$this->STOMA_BAB->setDbValue($rs->fields('STOMA_BAB'));\n\t\t$this->PENG_OBAT_BAB->setDbValue($rs->fields('PENG_OBAT_BAB'));\n\t\t$this->IST_SIANG->setDbValue($rs->fields('IST_SIANG'));\n\t\t$this->IST_MALAM->setDbValue($rs->fields('IST_MALAM'));\n\t\t$this->IST_CAHAYA->setDbValue($rs->fields('IST_CAHAYA'));\n\t\t$this->IST_POSISI->setDbValue($rs->fields('IST_POSISI'));\n\t\t$this->IST_LING->setDbValue($rs->fields('IST_LING'));\n\t\t$this->IST_GANG_TIDUR->setDbValue($rs->fields('IST_GANG_TIDUR'));\n\t\t$this->PENG_OBAT_IST->setDbValue($rs->fields('PENG_OBAT_IST'));\n\t\t$this->FREK_MAND->setDbValue($rs->fields('FREK_MAND'));\n\t\t$this->CUC_RAMB_MAND->setDbValue($rs->fields('CUC_RAMB_MAND'));\n\t\t$this->SIH_GIGI_MAND->setDbValue($rs->fields('SIH_GIGI_MAND'));\n\t\t$this->BANT_MAND->setDbValue($rs->fields('BANT_MAND'));\n\t\t$this->GANT_PAKAI->setDbValue($rs->fields('GANT_PAKAI'));\n\t\t$this->PAK_CUCI->setDbValue($rs->fields('PAK_CUCI'));\n\t\t$this->PAK_BANT->setDbValue($rs->fields('PAK_BANT'));\n\t\t$this->ALT_BANT->setDbValue($rs->fields('ALT_BANT'));\n\t\t$this->KEMP_MUND->setDbValue($rs->fields('KEMP_MUND'));\n\t\t$this->BIL_PUT->setDbValue($rs->fields('BIL_PUT'));\n\t\t$this->ADAPTIF->setDbValue($rs->fields('ADAPTIF'));\n\t\t$this->MALADAPTIF->setDbValue($rs->fields('MALADAPTIF'));\n\t\t$this->PENANGGUNGJAWAB_NAMA->setDbValue($rs->fields('PENANGGUNGJAWAB_NAMA'));\n\t\t$this->PENANGGUNGJAWAB_HUBUNGAN->setDbValue($rs->fields('PENANGGUNGJAWAB_HUBUNGAN'));\n\t\t$this->PENANGGUNGJAWAB_ALAMAT->setDbValue($rs->fields('PENANGGUNGJAWAB_ALAMAT'));\n\t\t$this->PENANGGUNGJAWAB_PHONE->setDbValue($rs->fields('PENANGGUNGJAWAB_PHONE'));\n\t\t$this->obat2->setDbValue($rs->fields('obat2'));\n\t\t$this->PERBANDINGAN_BB->setDbValue($rs->fields('PERBANDINGAN_BB'));\n\t\t$this->KONTINENSIA->setDbValue($rs->fields('KONTINENSIA'));\n\t\t$this->JENIS_KULIT1->setDbValue($rs->fields('JENIS_KULIT1'));\n\t\t$this->MOBILITAS->setDbValue($rs->fields('MOBILITAS'));\n\t\t$this->JK->setDbValue($rs->fields('JK'));\n\t\t$this->UMUR->setDbValue($rs->fields('UMUR'));\n\t\t$this->NAFSU_MAKAN->setDbValue($rs->fields('NAFSU_MAKAN'));\n\t\t$this->OBAT1->setDbValue($rs->fields('OBAT1'));\n\t\t$this->MALNUTRISI->setDbValue($rs->fields('MALNUTRISI'));\n\t\t$this->MOTORIK1->setDbValue($rs->fields('MOTORIK1'));\n\t\t$this->SPINAL->setDbValue($rs->fields('SPINAL'));\n\t\t$this->MEJA_OPERASI->setDbValue($rs->fields('MEJA_OPERASI'));\n\t\t$this->RIWAYAT_JATUH->setDbValue($rs->fields('RIWAYAT_JATUH'));\n\t\t$this->DIAGNOSIS_SEKUNDER->setDbValue($rs->fields('DIAGNOSIS_SEKUNDER'));\n\t\t$this->ALAT_BANTU->setDbValue($rs->fields('ALAT_BANTU'));\n\t\t$this->HEPARIN->setDbValue($rs->fields('HEPARIN'));\n\t\t$this->GAYA_BERJALAN->setDbValue($rs->fields('GAYA_BERJALAN'));\n\t\t$this->KESADARAN1->setDbValue($rs->fields('KESADARAN1'));\n\t\t$this->NOMR_LAMA->setDbValue($rs->fields('NOMR_LAMA'));\n\t\t$this->NO_KARTU->setDbValue($rs->fields('NO_KARTU'));\n\t\t$this->JNS_PASIEN->setDbValue($rs->fields('JNS_PASIEN'));\n\t\t$this->nama_ayah->setDbValue($rs->fields('nama_ayah'));\n\t\t$this->nama_ibu->setDbValue($rs->fields('nama_ibu'));\n\t\t$this->nama_suami->setDbValue($rs->fields('nama_suami'));\n\t\t$this->nama_istri->setDbValue($rs->fields('nama_istri'));\n\t\t$this->KD_ETNIS->setDbValue($rs->fields('KD_ETNIS'));\n\t\t$this->KD_BHS_HARIAN->setDbValue($rs->fields('KD_BHS_HARIAN'));\n\t}", "title": "" }, { "docid": "c0f85f0596c2366c5912b11caa0769f2", "score": "0.6956701", "text": "public function loadRowValues($rs = NULL)\n\t{\n\t\tif ($rs && !$rs->EOF)\n\t\t\t$row = $rs->fields;\n\t\telse\n\t\t\t$row = $this->newRow();\n\n\t\t// Call Row Selected event\n\t\t$this->Row_Selected($row);\n\t\tif (!$rs || $rs->EOF)\n\t\t\treturn;\n\t\t$this->id->setDbValue($row['id']);\n\t\t$this->fecha->setDbValue($row['fecha']);\n\t\t$this->hora->setDbValue($row['hora']);\n\t\t$this->audio->setDbValue($row['audio']);\n\t\t$this->st->setDbValue($row['st']);\n\t\t$this->fechaHoraIni->setDbValue($row['fechaHoraIni']);\n\t\t$this->fechaHoraFin->setDbValue($row['fechaHoraFin']);\n\t\t$this->telefono->setDbValue($row['telefono']);\n\t\t$this->agente->setDbValue($row['agente']);\n\t\t$this->fechabo->setDbValue($row['fechabo']);\n\t\t$this->agentebo->setDbValue($row['agentebo']);\n\t\t$this->comentariosbo->setDbValue($row['comentariosbo']);\n\t\t$this->IP->setDbValue($row['IP']);\n\t\t$this->actual->setDbValue($row['actual']);\n\t\t$this->completado->setDbValue($row['completado']);\n\t\t$this->_2_1_R->setDbValue($row['2_1_R']);\n\t\t$this->_2_2_R->setDbValue($row['2_2_R']);\n\t\t$this->_2_3_R->setDbValue($row['2_3_R']);\n\t\t$this->_3_4_R->setDbValue($row['3_4_R']);\n\t\t$this->_4_5_R->setDbValue($row['4_5_R']);\n\t\t$this->_4_6_R->setDbValue($row['4_6_R']);\n\t\t$this->_4_7_R->setDbValue($row['4_7_R']);\n\t\t$this->_4_8_R->setDbValue($row['4_8_R']);\n\t\t$this->_5_9_R->setDbValue($row['5_9_R']);\n\t\t$this->_5_10_R->setDbValue($row['5_10_R']);\n\t\t$this->_5_11_R->setDbValue($row['5_11_R']);\n\t\t$this->_5_12_R->setDbValue($row['5_12_R']);\n\t\t$this->_5_13_R->setDbValue($row['5_13_R']);\n\t\t$this->_5_14_R->setDbValue($row['5_14_R']);\n\t\t$this->_5_51_R->setDbValue($row['5_51_R']);\n\t\t$this->_6_15_R->setDbValue($row['6_15_R']);\n\t\t$this->_6_16_R->setDbValue($row['6_16_R']);\n\t\t$this->_6_17_R->setDbValue($row['6_17_R']);\n\t\t$this->_6_18_R->setDbValue($row['6_18_R']);\n\t\t$this->_6_19_R->setDbValue($row['6_19_R']);\n\t\t$this->_6_20_R->setDbValue($row['6_20_R']);\n\t\t$this->_6_52_R->setDbValue($row['6_52_R']);\n\t\t$this->_7_21_R->setDbValue($row['7_21_R']);\n\t\t$this->_8_22_R->setDbValue($row['8_22_R']);\n\t\t$this->_8_23_R->setDbValue($row['8_23_R']);\n\t\t$this->_8_24_R->setDbValue($row['8_24_R']);\n\t\t$this->_8_25_R->setDbValue($row['8_25_R']);\n\t\t$this->_9_26_R->setDbValue($row['9_26_R']);\n\t\t$this->_9_27_R->setDbValue($row['9_27_R']);\n\t\t$this->_9_28_R->setDbValue($row['9_28_R']);\n\t\t$this->_9_29_R->setDbValue($row['9_29_R']);\n\t\t$this->_9_30_R->setDbValue($row['9_30_R']);\n\t\t$this->_9_31_R->setDbValue($row['9_31_R']);\n\t\t$this->_9_32_R->setDbValue($row['9_32_R']);\n\t\t$this->_9_33_R->setDbValue($row['9_33_R']);\n\t\t$this->_9_34_R->setDbValue($row['9_34_R']);\n\t\t$this->_9_35_R->setDbValue($row['9_35_R']);\n\t\t$this->_9_36_R->setDbValue($row['9_36_R']);\n\t\t$this->_9_37_R->setDbValue($row['9_37_R']);\n\t\t$this->_9_38_R->setDbValue($row['9_38_R']);\n\t\t$this->_9_39_R->setDbValue($row['9_39_R']);\n\t\t$this->_10_40_R->setDbValue($row['10_40_R']);\n\t\t$this->_10_41_R->setDbValue($row['10_41_R']);\n\t\t$this->_11_42_R->setDbValue($row['11_42_R']);\n\t\t$this->_11_43_R->setDbValue($row['11_43_R']);\n\t\t$this->_12_44_R->setDbValue($row['12_44_R']);\n\t\t$this->_12_45_R->setDbValue($row['12_45_R']);\n\t\t$this->_12_46_R->setDbValue($row['12_46_R']);\n\t\t$this->_12_47_R->setDbValue($row['12_47_R']);\n\t\t$this->_12_48_R->setDbValue($row['12_48_R']);\n\t\t$this->_12_49_R->setDbValue($row['12_49_R']);\n\t\t$this->_12_50_R->setDbValue($row['12_50_R']);\n\t\t$this->_1__R->setDbValue($row['1__R']);\n\t\t$this->_13_54_R->setDbValue($row['13_54_R']);\n\t\t$this->_13_54_1_R->setDbValue($row['13_54_1_R']);\n\t\t$this->_13_54_2_R->setDbValue($row['13_54_2_R']);\n\t\t$this->_13_55_R->setDbValue($row['13_55_R']);\n\t\t$this->_13_55_1_R->setDbValue($row['13_55_1_R']);\n\t\t$this->_13_55_2_R->setDbValue($row['13_55_2_R']);\n\t\t$this->_13_56_R->setDbValue($row['13_56_R']);\n\t\t$this->_13_56_1_R->setDbValue($row['13_56_1_R']);\n\t\t$this->_13_56_2_R->setDbValue($row['13_56_2_R']);\n\t\t$this->_12_53_R->setDbValue($row['12_53_R']);\n\t\t$this->_12_53_1_R->setDbValue($row['12_53_1_R']);\n\t\t$this->_12_53_2_R->setDbValue($row['12_53_2_R']);\n\t\t$this->_12_53_3_R->setDbValue($row['12_53_3_R']);\n\t\t$this->_12_53_4_R->setDbValue($row['12_53_4_R']);\n\t\t$this->_12_53_5_R->setDbValue($row['12_53_5_R']);\n\t\t$this->_12_53_6_R->setDbValue($row['12_53_6_R']);\n\t\t$this->_13_57_R->setDbValue($row['13_57_R']);\n\t\t$this->_13_57_1_R->setDbValue($row['13_57_1_R']);\n\t\t$this->_13_57_2_R->setDbValue($row['13_57_2_R']);\n\t\t$this->_13_58_R->setDbValue($row['13_58_R']);\n\t\t$this->_13_58_1_R->setDbValue($row['13_58_1_R']);\n\t\t$this->_13_58_2_R->setDbValue($row['13_58_2_R']);\n\t\t$this->_13_59_R->setDbValue($row['13_59_R']);\n\t\t$this->_13_59_1_R->setDbValue($row['13_59_1_R']);\n\t\t$this->_13_59_2_R->setDbValue($row['13_59_2_R']);\n\t\t$this->_13_60_R->setDbValue($row['13_60_R']);\n\t\t$this->_12_53_7_R->setDbValue($row['12_53_7_R']);\n\t\t$this->_12_53_8_R->setDbValue($row['12_53_8_R']);\n\t}", "title": "" }, { "docid": "7c97c5c09e5aaedead561c2d0bb12ad6", "score": "0.69394225", "text": "function LoadRowValues($rs = NULL) {\n\t\tif ($rs && !$rs->EOF)\n\t\t\t$row = $rs->fields;\n\t\telse\n\t\t\t$row = $this->NewRow(); \n\n\t\t// Call Row Selected event\n\t\t$this->Row_Selected($row);\n\t\tif (!$rs || $rs->EOF)\n\t\t\treturn;\n\t\t$this->id->setDbValue($row['id']);\n\t\t$this->kiri_tabel->setDbValue($row['kiri_tabel']);\n\t\t$this->kiri_id->setDbValue($row['kiri_id']);\n\t\t$this->kiri_lv2->setDbValue($row['kiri_lv2']);\n\t\t$this->kiri_lv3->setDbValue($row['kiri_lv3']);\n\t\t$this->kiri_lv4->setDbValue($row['kiri_lv4']);\n\t\t$this->kiri_jumlah->setDbValue($row['kiri_jumlah']);\n\t\t$this->kanan_tabel->setDbValue($row['kanan_tabel']);\n\t\t$this->kanan_id->setDbValue($row['kanan_id']);\n\t\t$this->kanan_lv2->setDbValue($row['kanan_lv2']);\n\t\t$this->kanan_lv3->setDbValue($row['kanan_lv3']);\n\t\t$this->kanan_lv4->setDbValue($row['kanan_lv4']);\n\t\t$this->kanan_jumlah->setDbValue($row['kanan_jumlah']);\n\t}", "title": "" }, { "docid": "11c69c15d1da296fd63a5e4dde3a1529", "score": "0.6936149", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\tif ($this->AuditTrailOnView) $this->WriteAuditTrailOnView($row);\n\t\t$this->pd_id->setDbValue($rs->fields('pd_id'));\n\t\t$this->pegawai_id->setDbValue($rs->fields('pegawai_id'));\n\t\tif (array_key_exists('EV__pegawai_id', $rs->fields)) {\n\t\t\t$this->pegawai_id->VirtualValue = $rs->fields('EV__pegawai_id'); // Set up virtual field value\n\t\t} else {\n\t\t\t$this->pegawai_id->VirtualValue = \"\"; // Clear value\n\t\t}\n\t\t$this->dept_id->setDbValue($rs->fields('dept_id'));\n\t\tif (array_key_exists('EV__dept_id', $rs->fields)) {\n\t\t\t$this->dept_id->VirtualValue = $rs->fields('EV__dept_id'); // Set up virtual field value\n\t\t} else {\n\t\t\t$this->dept_id->VirtualValue = \"\"; // Clear value\n\t\t}\n\t\t$this->f0m1->setDbValue($rs->fields('f0m1'));\n\t\t$this->f0k1->setDbValue($rs->fields('f0k1'));\n\t\t$this->f1m1->setDbValue($rs->fields('f1m1'));\n\t\t$this->f1k1->setDbValue($rs->fields('f1k1'));\n\t\t$this->f2m1->setDbValue($rs->fields('f2m1'));\n\t\t$this->f2k1->setDbValue($rs->fields('f2k1'));\n\t\t$this->f3m1->setDbValue($rs->fields('f3m1'));\n\t\t$this->f3k1->setDbValue($rs->fields('f3k1'));\n\t\t$this->f4m1->setDbValue($rs->fields('f4m1'));\n\t\t$this->f4k1->setDbValue($rs->fields('f4k1'));\n\t\t$this->f5m1->setDbValue($rs->fields('f5m1'));\n\t\t$this->f5k1->setDbValue($rs->fields('f5k1'));\n\t\t$this->f6m1->setDbValue($rs->fields('f6m1'));\n\t\t$this->f6k1->setDbValue($rs->fields('f6k1'));\n\t\t$this->f0m2->setDbValue($rs->fields('f0m2'));\n\t\t$this->f0k2->setDbValue($rs->fields('f0k2'));\n\t\t$this->f1m2->setDbValue($rs->fields('f1m2'));\n\t\t$this->f1k2->setDbValue($rs->fields('f1k2'));\n\t\t$this->f2m2->setDbValue($rs->fields('f2m2'));\n\t\t$this->f2k2->setDbValue($rs->fields('f2k2'));\n\t\t$this->f3m2->setDbValue($rs->fields('f3m2'));\n\t\t$this->f3k2->setDbValue($rs->fields('f3k2'));\n\t\t$this->f4m2->setDbValue($rs->fields('f4m2'));\n\t\t$this->f4k2->setDbValue($rs->fields('f4k2'));\n\t\t$this->f5m2->setDbValue($rs->fields('f5m2'));\n\t\t$this->f5k2->setDbValue($rs->fields('f5k2'));\n\t\t$this->f6m2->setDbValue($rs->fields('f6m2'));\n\t\t$this->f6k2->setDbValue($rs->fields('f6k2'));\n\t\t$this->f0m3->setDbValue($rs->fields('f0m3'));\n\t\t$this->f0k3->setDbValue($rs->fields('f0k3'));\n\t\t$this->f1m3->setDbValue($rs->fields('f1m3'));\n\t\t$this->f1k3->setDbValue($rs->fields('f1k3'));\n\t\t$this->f2m3->setDbValue($rs->fields('f2m3'));\n\t\t$this->f2k3->setDbValue($rs->fields('f2k3'));\n\t\t$this->f3m3->setDbValue($rs->fields('f3m3'));\n\t\t$this->f3k3->setDbValue($rs->fields('f3k3'));\n\t\t$this->f4m3->setDbValue($rs->fields('f4m3'));\n\t\t$this->f4k3->setDbValue($rs->fields('f4k3'));\n\t\t$this->f5m3->setDbValue($rs->fields('f5m3'));\n\t\t$this->f5k3->setDbValue($rs->fields('f5k3'));\n\t\t$this->f6m3->setDbValue($rs->fields('f6m3'));\n\t\t$this->f6k3->setDbValue($rs->fields('f6k3'));\n\t}", "title": "" }, { "docid": "1e5cf48a5d9eff2b8c7dc65016c0f5be", "score": "0.69351244", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $profile;\n\t\t$profile->ID->setDbValue($rs->fields('ID'));\n\t\t$profile->Kode->setDbValue($rs->fields('Kode'));\n\t\t$profile->NamaToko->setDbValue($rs->fields('NamaToko'));\n\t\t$profile->Pemilik->setDbValue($rs->fields('Pemilik'));\n\t\t$profile->Alamat->setDbValue($rs->fields('Alamat'));\n\t\t$profile->Kota->setDbValue($rs->fields('Kota'));\n\t\t$profile->Telepon->setDbValue($rs->fields('Telepon'));\n\t\t$profile->zEmail->setDbValue($rs->fields('Email'));\n\t\t$profile->Foto->Upload->DbValue = $rs->fields('Foto');\n\t\t$profile->Serial->setDbValue($rs->fields('Serial'));\n\t\t$profile->KeyCode->setDbValue($rs->fields('KeyCode'));\n\t\t$profile->Waktu->setDbValue($rs->fields('Waktu'));\n\t\t$profile->Stamp->setDbValue($rs->fields('Stamp'));\n\t}", "title": "" }, { "docid": "c3456a3df08db04ab9500824dd2d9b71", "score": "0.69249654", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $members;\n\t\t$members->Id->setDbValue($rs->fields('Id'));\n\t\t$members->first_name->setDbValue($rs->fields('first_name'));\n\t\t$members->last_name->setDbValue($rs->fields('last_name'));\n\t\t$members->first_name_eng->setDbValue($rs->fields('first_name_eng'));\n\t\t$members->last_name_eng->setDbValue($rs->fields('last_name_eng'));\n\t\t$members->username->setDbValue($rs->fields('username'));\n\t\t$members->password->setDbValue($rs->fields('password'));\n\t\t$members->phone_cell->setDbValue($rs->fields('phone_cell'));\n\t\t$members->phone_home->setDbValue($rs->fields('phone_home'));\n\t\t$members->zemail->setDbValue($rs->fields('email'));\n\t\t$members->address->setDbValue($rs->fields('address'));\n\t\t$members->city->setDbValue($rs->fields('city'));\n\t\t$members->zip->setDbValue($rs->fields('zip'));\n\t\t$members->gender->setDbValue($rs->fields('gender'));\n\t\t$members->status_student->setDbValue($rs->fields('status_student'));\n\t\t$members->ethnicity_korean->setDbValue($rs->fields('ethnicity_korean'));\n\t\t$members->language_korean->setDbValue($rs->fields('language_korean'));\n\t\t$members->access_level->setDbValue($rs->fields('access_level'));\n\t\t$members->active_member->setDbValue($rs->fields('active_member'));\n\t}", "title": "" }, { "docid": "aff890428efebc8068b27a57a9332452", "score": "0.69231117", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->personID->setDbValue($rs->fields('personID'));\n\t\t$this->personName->setDbValue($rs->fields('personName'));\n\t\t$this->lastName->setDbValue($rs->fields('lastName'));\n\t\t$this->nationalID->setDbValue($rs->fields('nationalID'));\n\t\t$this->mobilePhone->setDbValue($rs->fields('mobilePhone'));\n\t\t$this->nationalNumber->setDbValue($rs->fields('nationalNumber'));\n\t\t$this->passportNumber->setDbValue($rs->fields('passportNumber'));\n\t\t$this->fatherName->setDbValue($rs->fields('fatherName'));\n\t\t$this->gender->setDbValue($rs->fields('gender'));\n\t\t$this->locationLevel1->setDbValue($rs->fields('locationLevel1'));\n\t\t$this->locationLevel2->setDbValue($rs->fields('locationLevel2'));\n\t\t$this->locationLevel3->setDbValue($rs->fields('locationLevel3'));\n\t\t$this->locationLevel4->setDbValue($rs->fields('locationLevel4'));\n\t\t$this->locationLevel5->setDbValue($rs->fields('locationLevel5'));\n\t\t$this->locationLevel6->setDbValue($rs->fields('locationLevel6'));\n\t\t$this->address->setDbValue($rs->fields('address'));\n\t\t$this->convoy->setDbValue($rs->fields('convoy'));\n\t\t$this->convoyManager->setDbValue($rs->fields('convoyManager'));\n\t\t$this->followersName->setDbValue($rs->fields('followersName'));\n\t\t$this->status->setDbValue($rs->fields('status'));\n\t\t$this->isolatedLocation->setDbValue($rs->fields('isolatedLocation'));\n\t\t$this->birthDate->setDbValue($rs->fields('birthDate'));\n\t\t$this->ageRange->setDbValue($rs->fields('ageRange'));\n\t\t$this->dress1->setDbValue($rs->fields('dress1'));\n\t\t$this->dress2->setDbValue($rs->fields('dress2'));\n\t\t$this->signTags->setDbValue($rs->fields('signTags'));\n\t\t$this->phone->setDbValue($rs->fields('phone'));\n\t\t$this->_email->setDbValue($rs->fields('email'));\n\t\t$this->temporaryResidence->setDbValue($rs->fields('temporaryResidence'));\n\t\t$this->visitsCount->setDbValue($rs->fields('visitsCount'));\n\t\t$this->picture->Upload->DbValue = $rs->fields('picture');\n\t\t$this->picture->CurrentValue = $this->picture->Upload->DbValue;\n\t\t$this->registrationUser->setDbValue($rs->fields('registrationUser'));\n\t\t$this->registrationDateTime->setDbValue($rs->fields('registrationDateTime'));\n\t\t$this->registrationStation->setDbValue($rs->fields('registrationStation'));\n\t\t$this->isolatedDateTime->setDbValue($rs->fields('isolatedDateTime'));\n\t\t$this->description->setDbValue($rs->fields('description'));\n\t}", "title": "" }, { "docid": "53a892f70e08506b638c87f4bafa35fa", "score": "0.69119805", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->nama->setDbValue($rs->fields('nama'));\n\t\t$this->status->setDbValue($rs->fields('status'));\n\t\t$this->tanggal->setDbValue($rs->fields('tanggal'));\n\t\t$this->gaji_pokok->setDbValue($rs->fields('gaji_pokok'));\n\t\t$this->lembur->setDbValue($rs->fields('lembur'));\n\t\t$this->tunjangan_proyek->setDbValue($rs->fields('tunjangan_proyek'));\n\t\t$this->Titil->setDbValue($rs->fields('Titil'));\n\t}", "title": "" }, { "docid": "c64796f1662f6cdd98106d70c4f47952", "score": "0.69100094", "text": "function LoadRowValues($rs = NULL) {\n\t\tif ($rs && !$rs->EOF)\n\t\t\t$row = $rs->fields;\n\t\telse\n\t\t\t$row = $this->NewRow(); \n\n\t\t// Call Row Selected event\n\t\t$this->Row_Selected($row);\n\t\tif (!$rs || $rs->EOF)\n\t\t\treturn;\n\t\t$this->customer_id->setDbValue($row['customer_id']);\n\t\t$this->customer_code->setDbValue($row['customer_code']);\n\t\t$this->customer_group->setDbValue($row['customer_group']);\n\t\t$this->customer_name->setDbValue($row['customer_name']);\n\t\t$this->contact_name->setDbValue($row['contact_name']);\n\t\t$this->address1->setDbValue($row['address1']);\n\t\t$this->address2->setDbValue($row['address2']);\n\t\t$this->address3->setDbValue($row['address3']);\n\t\t$this->phone->setDbValue($row['phone']);\n\t\t$this->fax->setDbValue($row['fax']);\n\t\t$this->wilayah_id->setDbValue($row['wilayah_id']);\n\t\t$this->subwil_id->setDbValue($row['subwil_id']);\n\t\t$this->area_id->setDbValue($row['area_id']);\n\t\t$this->sales_id->setDbValue($row['sales_id']);\n\t\t$this->due_day->setDbValue($row['due_day']);\n\t\t$this->ar_acc->setDbValue($row['ar_acc']);\n\t\t$this->npwp->setDbValue($row['npwp']);\n\t\t$this->discount->setDbValue($row['discount']);\n\t\t$this->freight->setDbValue($row['freight']);\n\t\t$this->credit_max->setDbValue($row['credit_max']);\n\t\t$this->invoice_max->setDbValue($row['invoice_max']);\n\t\t$this->saldo_awal->setDbValue($row['saldo_awal']);\n\t\t$this->curency->setDbValue($row['curency']);\n\t\t$this->kode_depo->setDbValue($row['kode_depo']);\n\t\t$this->tax->setDbValue($row['tax']);\n\t}", "title": "" }, { "docid": "26986d3796a6ce13995f6c0feac223c4", "score": "0.6909725", "text": "function LoadRowValues($rs = NULL) {\n\t\tif ($rs && !$rs->EOF)\n\t\t\t$row = $rs->fields;\n\t\telse\n\t\t\t$row = $this->NewRow(); \n\n\t\t// Call Row Selected event\n\t\t$this->Row_Selected($row);\n\t\tif (!$rs || $rs->EOF)\n\t\t\treturn;\n\t\t$this->id->setDbValue($row['id']);\n\t\t$this->id_actividad->setDbValue($row['id_actividad']);\n\t\t$this->apellidopaterno->setDbValue($row['apellidopaterno']);\n\t\t$this->apellidomaterno->setDbValue($row['apellidomaterno']);\n\t\t$this->nombre->setDbValue($row['nombre']);\n\t\t$this->nrodiscapacidad->setDbValue($row['nrodiscapacidad']);\n\t\t$this->ci->setDbValue($row['ci']);\n\t\t$this->fecha_nacimiento->setDbValue($row['fecha_nacimiento']);\n\t\t$this->sexo->setDbValue($row['sexo']);\n\t\t$this->nivelestudio->setDbValue($row['nivelestudio']);\n\t\t$this->id_discapacidad->setDbValue($row['id_discapacidad']);\n\t\t$this->id_tipodiscapacidad->setDbValue($row['id_tipodiscapacidad']);\n\t\t$this->resultado->setDbValue($row['resultado']);\n\t\t$this->resultadotamizaje->setDbValue($row['resultadotamizaje']);\n\t\t$this->tapon->setDbValue($row['tapon']);\n\t\t$this->tipo->setDbValue($row['tipo']);\n\t\t$this->repetirprueba->setDbValue($row['repetirprueba']);\n\t\t$this->observaciones->setDbValue($row['observaciones']);\n\t\t$this->id_apoderado->setDbValue($row['id_apoderado']);\n\t\t$this->id_referencia->setDbValue($row['id_referencia']);\n\t\t$this->id_centro->setDbValue($row['id_centro']);\n\t}", "title": "" }, { "docid": "c0fa05e8dec710c028a618f9ea974730", "score": "0.6874552", "text": "public function loadListRowValues(&$rs)\n\t{\n\t\t$this->id->setDbValue($rs->fields('id'));\n\t\t$this->property_id->setDbValue($rs->fields('property_id'));\n\t\t$this->property->setDbValue($rs->fields('property'));\n\t\t$this->templatefile2->setDbValue($rs->fields('templatefile2'));\n\t\t$this->transactionno->setDbValue($rs->fields('transactionno'));\n\t\t$this->transactiondate->setDbValue($rs->fields('transactiondate'));\n\t\t$this->recommendedby->setDbValue($rs->fields('recommendedby'));\n\t\t$this->signatureby->setDbValue($rs->fields('signatureby'));\n\t\t$this->positionby->setDbValue($rs->fields('positionby'));\n\t\t$this->ce_id->setDbValue($rs->fields('ce_id'));\n\t\t$this->signaturece->setDbValue($rs->fields('signaturece'));\n\t\t$this->itm_id->setDbValue($rs->fields('itm_id'));\n\t\t$this->signatureitm->setDbValue($rs->fields('signatureitm'));\n\t\t$this->sign1->setDbValue($rs->fields('sign1'));\n\t\t$this->jobt1->setDbValue($rs->fields('jobt1'));\n\t\t$this->sign2->setDbValue($rs->fields('sign2'));\n\t\t$this->jobt2->setDbValue($rs->fields('jobt2'));\n\t\t$this->sign3->setDbValue($rs->fields('sign3'));\n\t\t$this->jobt3->setDbValue($rs->fields('jobt3'));\n\t\t$this->disposaldetail_id->setDbValue($rs->fields('disposaldetail_id'));\n\t\t$this->asset_id->setDbValue($rs->fields('asset_id'));\n\t\t$this->code->setDbValue($rs->fields('code'));\n\t\t$this->description->setDbValue($rs->fields('description'));\n\t\t$this->department_id->setDbValue($rs->fields('department_id'));\n\t\t$this->asset_dept->setDbValue($rs->fields('asset_dept'));\n\t\t$this->procurementdate->setDbValue($rs->fields('procurementdate'));\n\t\t$this->procurementcurrentcost->setDbValue($rs->fields('procurementcurrentcost'));\n\t\t$this->remarks->setDbValue($rs->fields('remarks'));\n\t\t$this->condstatus->setDbValue($rs->fields('condstatus'));\n\t\t$this->reasonstatus->setDbValue($rs->fields('reasonstatus'));\n\t\t$this->disposaldate->setDbValue($rs->fields('disposaldate'));\n\t}", "title": "" }, { "docid": "62f88f2b13d4b281ab9bae6623a6e0b2", "score": "0.68703395", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF)\n\t\t\treturn;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->id->DbValue = $row['id'];\n\t\t$this->kiri_tabel->DbValue = $row['kiri_tabel'];\n\t\t$this->kiri_id->DbValue = $row['kiri_id'];\n\t\t$this->kiri_lv2->DbValue = $row['kiri_lv2'];\n\t\t$this->kiri_lv3->DbValue = $row['kiri_lv3'];\n\t\t$this->kiri_lv4->DbValue = $row['kiri_lv4'];\n\t\t$this->kiri_jumlah->DbValue = $row['kiri_jumlah'];\n\t\t$this->kanan_tabel->DbValue = $row['kanan_tabel'];\n\t\t$this->kanan_id->DbValue = $row['kanan_id'];\n\t\t$this->kanan_lv2->DbValue = $row['kanan_lv2'];\n\t\t$this->kanan_lv3->DbValue = $row['kanan_lv3'];\n\t\t$this->kanan_lv4->DbValue = $row['kanan_lv4'];\n\t\t$this->kanan_jumlah->DbValue = $row['kanan_jumlah'];\n\t}", "title": "" }, { "docid": "a739fddcb6e6cdefc58c8dc7528e599f", "score": "0.68638664", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->IDXDAFTAR->setDbValue($rs->fields('IDXDAFTAR'));\n\t\t$this->NOMR->setDbValue($rs->fields('NOMR'));\n\t\t$this->KDPOLY->setDbValue($rs->fields('KDPOLY'));\n\t\t$this->KDCARABAYAR->setDbValue($rs->fields('KDCARABAYAR'));\n\t\t$this->NIP->setDbValue($rs->fields('NIP'));\n\t\t$this->TGLREG->setDbValue($rs->fields('TGLREG'));\n\t\t$this->JAMREG->setDbValue($rs->fields('JAMREG'));\n\t\t$this->NO_SJP->setDbValue($rs->fields('NO_SJP'));\n\t\t$this->NOKARTU->setDbValue($rs->fields('NOKARTU'));\n\t\t$this->TANGGAL_SEP->setDbValue($rs->fields('TANGGAL_SEP'));\n\t\t$this->TANGGALRUJUK_SEP->setDbValue($rs->fields('TANGGALRUJUK_SEP'));\n\t\t$this->KELASRAWAT_SEP->setDbValue($rs->fields('KELASRAWAT_SEP'));\n\t\t$this->NORUJUKAN_SEP->setDbValue($rs->fields('NORUJUKAN_SEP'));\n\t\t$this->PPKPELAYANAN_SEP->setDbValue($rs->fields('PPKPELAYANAN_SEP'));\n\t\t$this->JENISPERAWATAN_SEP->setDbValue($rs->fields('JENISPERAWATAN_SEP'));\n\t\t$this->CATATAN_SEP->setDbValue($rs->fields('CATATAN_SEP'));\n\t\t$this->DIAGNOSAAWAL_SEP->setDbValue($rs->fields('DIAGNOSAAWAL_SEP'));\n\t\t$this->NAMADIAGNOSA_SEP->setDbValue($rs->fields('NAMADIAGNOSA_SEP'));\n\t\t$this->LAKALANTAS_SEP->setDbValue($rs->fields('LAKALANTAS_SEP'));\n\t\t$this->LOKASILAKALANTAS->setDbValue($rs->fields('LOKASILAKALANTAS'));\n\t\t$this->USER->setDbValue($rs->fields('USER'));\n\t\t$this->generate_sep->setDbValue($rs->fields('generate_sep'));\n\t\t$this->PESERTANIK_SEP->setDbValue($rs->fields('PESERTANIK_SEP'));\n\t\t$this->PESERTANAMA_SEP->setDbValue($rs->fields('PESERTANAMA_SEP'));\n\t\t$this->PESERTAJENISKELAMIN_SEP->setDbValue($rs->fields('PESERTAJENISKELAMIN_SEP'));\n\t\t$this->PESERTANAMAKELAS_SEP->setDbValue($rs->fields('PESERTANAMAKELAS_SEP'));\n\t\t$this->PESERTAPISAT->setDbValue($rs->fields('PESERTAPISAT'));\n\t\t$this->PESERTATGLLAHIR->setDbValue($rs->fields('PESERTATGLLAHIR'));\n\t\t$this->PESERTAJENISPESERTA_SEP->setDbValue($rs->fields('PESERTAJENISPESERTA_SEP'));\n\t\t$this->PESERTANAMAJENISPESERTA_SEP->setDbValue($rs->fields('PESERTANAMAJENISPESERTA_SEP'));\n\t\t$this->POLITUJUAN_SEP->setDbValue($rs->fields('POLITUJUAN_SEP'));\n\t\t$this->NAMAPOLITUJUAN_SEP->setDbValue($rs->fields('NAMAPOLITUJUAN_SEP'));\n\t\t$this->KDPPKRUJUKAN_SEP->setDbValue($rs->fields('KDPPKRUJUKAN_SEP'));\n\t\t$this->NMPPKRUJUKAN_SEP->setDbValue($rs->fields('NMPPKRUJUKAN_SEP'));\n\t\t$this->mapingtransaksi->setDbValue($rs->fields('mapingtransaksi'));\n\t\t$this->bridging_kepesertaan_by_no_ka->setDbValue($rs->fields('bridging_kepesertaan_by_no_ka'));\n\t\t$this->pasien_NOTELP->setDbValue($rs->fields('pasien_NOTELP'));\n\t\t$this->penjamin_kkl_id->setDbValue($rs->fields('penjamin_kkl_id'));\n\t\t$this->asalfaskesrujukan_id->setDbValue($rs->fields('asalfaskesrujukan_id'));\n\t\t$this->peserta_cob->setDbValue($rs->fields('peserta_cob'));\n\t\t$this->poli_eksekutif->setDbValue($rs->fields('poli_eksekutif'));\n\t\t$this->status_kepesertaan_BPJS->setDbValue($rs->fields('status_kepesertaan_BPJS'));\n\t}", "title": "" }, { "docid": "a739fddcb6e6cdefc58c8dc7528e599f", "score": "0.68638664", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->IDXDAFTAR->setDbValue($rs->fields('IDXDAFTAR'));\n\t\t$this->NOMR->setDbValue($rs->fields('NOMR'));\n\t\t$this->KDPOLY->setDbValue($rs->fields('KDPOLY'));\n\t\t$this->KDCARABAYAR->setDbValue($rs->fields('KDCARABAYAR'));\n\t\t$this->NIP->setDbValue($rs->fields('NIP'));\n\t\t$this->TGLREG->setDbValue($rs->fields('TGLREG'));\n\t\t$this->JAMREG->setDbValue($rs->fields('JAMREG'));\n\t\t$this->NO_SJP->setDbValue($rs->fields('NO_SJP'));\n\t\t$this->NOKARTU->setDbValue($rs->fields('NOKARTU'));\n\t\t$this->TANGGAL_SEP->setDbValue($rs->fields('TANGGAL_SEP'));\n\t\t$this->TANGGALRUJUK_SEP->setDbValue($rs->fields('TANGGALRUJUK_SEP'));\n\t\t$this->KELASRAWAT_SEP->setDbValue($rs->fields('KELASRAWAT_SEP'));\n\t\t$this->NORUJUKAN_SEP->setDbValue($rs->fields('NORUJUKAN_SEP'));\n\t\t$this->PPKPELAYANAN_SEP->setDbValue($rs->fields('PPKPELAYANAN_SEP'));\n\t\t$this->JENISPERAWATAN_SEP->setDbValue($rs->fields('JENISPERAWATAN_SEP'));\n\t\t$this->CATATAN_SEP->setDbValue($rs->fields('CATATAN_SEP'));\n\t\t$this->DIAGNOSAAWAL_SEP->setDbValue($rs->fields('DIAGNOSAAWAL_SEP'));\n\t\t$this->NAMADIAGNOSA_SEP->setDbValue($rs->fields('NAMADIAGNOSA_SEP'));\n\t\t$this->LAKALANTAS_SEP->setDbValue($rs->fields('LAKALANTAS_SEP'));\n\t\t$this->LOKASILAKALANTAS->setDbValue($rs->fields('LOKASILAKALANTAS'));\n\t\t$this->USER->setDbValue($rs->fields('USER'));\n\t\t$this->generate_sep->setDbValue($rs->fields('generate_sep'));\n\t\t$this->PESERTANIK_SEP->setDbValue($rs->fields('PESERTANIK_SEP'));\n\t\t$this->PESERTANAMA_SEP->setDbValue($rs->fields('PESERTANAMA_SEP'));\n\t\t$this->PESERTAJENISKELAMIN_SEP->setDbValue($rs->fields('PESERTAJENISKELAMIN_SEP'));\n\t\t$this->PESERTANAMAKELAS_SEP->setDbValue($rs->fields('PESERTANAMAKELAS_SEP'));\n\t\t$this->PESERTAPISAT->setDbValue($rs->fields('PESERTAPISAT'));\n\t\t$this->PESERTATGLLAHIR->setDbValue($rs->fields('PESERTATGLLAHIR'));\n\t\t$this->PESERTAJENISPESERTA_SEP->setDbValue($rs->fields('PESERTAJENISPESERTA_SEP'));\n\t\t$this->PESERTANAMAJENISPESERTA_SEP->setDbValue($rs->fields('PESERTANAMAJENISPESERTA_SEP'));\n\t\t$this->POLITUJUAN_SEP->setDbValue($rs->fields('POLITUJUAN_SEP'));\n\t\t$this->NAMAPOLITUJUAN_SEP->setDbValue($rs->fields('NAMAPOLITUJUAN_SEP'));\n\t\t$this->KDPPKRUJUKAN_SEP->setDbValue($rs->fields('KDPPKRUJUKAN_SEP'));\n\t\t$this->NMPPKRUJUKAN_SEP->setDbValue($rs->fields('NMPPKRUJUKAN_SEP'));\n\t\t$this->mapingtransaksi->setDbValue($rs->fields('mapingtransaksi'));\n\t\t$this->bridging_kepesertaan_by_no_ka->setDbValue($rs->fields('bridging_kepesertaan_by_no_ka'));\n\t\t$this->pasien_NOTELP->setDbValue($rs->fields('pasien_NOTELP'));\n\t\t$this->penjamin_kkl_id->setDbValue($rs->fields('penjamin_kkl_id'));\n\t\t$this->asalfaskesrujukan_id->setDbValue($rs->fields('asalfaskesrujukan_id'));\n\t\t$this->peserta_cob->setDbValue($rs->fields('peserta_cob'));\n\t\t$this->poli_eksekutif->setDbValue($rs->fields('poli_eksekutif'));\n\t\t$this->status_kepesertaan_BPJS->setDbValue($rs->fields('status_kepesertaan_BPJS'));\n\t}", "title": "" }, { "docid": "e4259f7dc80d286d5f4d7d29e1f11014", "score": "0.6859191", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->objectID->DbValue = $row['objectID'];\n\t\t$this->objectName->DbValue = $row['objectName'];\n\t\t$this->ownerID->DbValue = $row['ownerID'];\n\t\t$this->ownerName->DbValue = $row['ownerName'];\n\t\t$this->lastName->DbValue = $row['lastName'];\n\t\t$this->mobilePhone->DbValue = $row['mobilePhone'];\n\t\t$this->color->DbValue = $row['color'];\n\t\t$this->status->DbValue = $row['status'];\n\t\t$this->content->DbValue = $row['content'];\n\t\t$this->financialValue->DbValue = $row['financialValue'];\n\t\t$this->registrationUser->DbValue = $row['registrationUser'];\n\t\t$this->registrationDateTime->DbValue = $row['registrationDateTime'];\n\t\t$this->registrationStation->DbValue = $row['registrationStation'];\n\t\t$this->isolatedDateTime->DbValue = $row['isolatedDateTime'];\n\t\t$this->description->DbValue = $row['description'];\n\t}", "title": "" }, { "docid": "499de6010623ec28d25e2f53632929aa", "score": "0.6823875", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->llave->setDbValue($rs->fields('llave'));\n\t\t$this->F_Sincron->setDbValue($rs->fields('F_Sincron'));\n\t\t$this->USUARIO->setDbValue($rs->fields('USUARIO'));\n\t\t$this->Cargo_gme->setDbValue($rs->fields('Cargo_gme'));\n\t\t$this->NOM_PE->setDbValue($rs->fields('NOM_PE'));\n\t\t$this->Otro_PE->setDbValue($rs->fields('Otro_PE'));\n\t\t$this->NOM_APOYO->setDbValue($rs->fields('NOM_APOYO'));\n\t\t$this->Otro_Nom_Apoyo->setDbValue($rs->fields('Otro_Nom_Apoyo'));\n\t\t$this->Otro_CC_Apoyo->setDbValue($rs->fields('Otro_CC_Apoyo'));\n\t\t$this->NOM_ENLACE->setDbValue($rs->fields('NOM_ENLACE'));\n\t\t$this->Otro_Nom_Enlace->setDbValue($rs->fields('Otro_Nom_Enlace'));\n\t\t$this->Otro_CC_Enlace->setDbValue($rs->fields('Otro_CC_Enlace'));\n\t\t$this->NOM_PGE->setDbValue($rs->fields('NOM_PGE'));\n\t\t$this->Otro_Nom_PGE->setDbValue($rs->fields('Otro_Nom_PGE'));\n\t\t$this->Otro_CC_PGE->setDbValue($rs->fields('Otro_CC_PGE'));\n\t\t$this->Departamento->setDbValue($rs->fields('Departamento'));\n\t\t$this->Muncipio->setDbValue($rs->fields('Muncipio'));\n\t\t$this->NOM_VDA->setDbValue($rs->fields('NOM_VDA'));\n\t\t$this->LATITUD->setDbValue($rs->fields('LATITUD'));\n\t\t$this->GRA_LAT->setDbValue($rs->fields('GRA_LAT'));\n\t\t$this->MIN_LAT->setDbValue($rs->fields('MIN_LAT'));\n\t\t$this->SEG_LAT->setDbValue($rs->fields('SEG_LAT'));\n\t\t$this->GRA_LONG->setDbValue($rs->fields('GRA_LONG'));\n\t\t$this->MIN_LONG->setDbValue($rs->fields('MIN_LONG'));\n\t\t$this->SEG_LONG->setDbValue($rs->fields('SEG_LONG'));\n\t\t$this->FECHA_ACC->setDbValue($rs->fields('FECHA_ACC'));\n\t\t$this->HORA_ACC->setDbValue($rs->fields('HORA_ACC'));\n\t\t$this->Hora_ingreso->setDbValue($rs->fields('Hora_ingreso'));\n\t\t$this->FP_Armada->setDbValue($rs->fields('FP_Armada'));\n\t\t$this->FP_Ejercito->setDbValue($rs->fields('FP_Ejercito'));\n\t\t$this->FP_Policia->setDbValue($rs->fields('FP_Policia'));\n\t\t$this->NOM_COMANDANTE->setDbValue($rs->fields('NOM_COMANDANTE'));\n\t\t$this->TESTI1->setDbValue($rs->fields('TESTI1'));\n\t\t$this->CC_TESTI1->setDbValue($rs->fields('CC_TESTI1'));\n\t\t$this->CARGO_TESTI1->setDbValue($rs->fields('CARGO_TESTI1'));\n\t\t$this->TESTI2->setDbValue($rs->fields('TESTI2'));\n\t\t$this->CC_TESTI2->setDbValue($rs->fields('CC_TESTI2'));\n\t\t$this->CARGO_TESTI2->setDbValue($rs->fields('CARGO_TESTI2'));\n\t\t$this->Afectados->setDbValue($rs->fields('Afectados'));\n\t\t$this->NUM_Afectado->setDbValue($rs->fields('NUM_Afectado'));\n\t\t$this->Nom_Afectado->setDbValue($rs->fields('Nom_Afectado'));\n\t\t$this->CC_Afectado->setDbValue($rs->fields('CC_Afectado'));\n\t\t$this->Cargo_Afectado->setDbValue($rs->fields('Cargo_Afectado'));\n\t\t$this->Tipo_incidente->setDbValue($rs->fields('Tipo_incidente'));\n\t\t$this->Riesgo->setDbValue($rs->fields('Riesgo'));\n\t\t$this->Parte_Cuerpo->setDbValue($rs->fields('Parte_Cuerpo'));\n\t\t$this->ESTADO_AFEC->setDbValue($rs->fields('ESTADO_AFEC'));\n\t\t$this->EVACUADO->setDbValue($rs->fields('EVACUADO'));\n\t\t$this->DESC_ACC->setDbValue($rs->fields('DESC_ACC'));\n\t\t$this->Modificado->setDbValue($rs->fields('Modificado'));\n\t\t$this->llave_2->setDbValue($rs->fields('llave_2'));\n\t}", "title": "" }, { "docid": "9af6d36bcf18a54aa7254269e29cacdd", "score": "0.6816737", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $ref_facultyrank;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row =& $rs->fields;\n\t\t$ref_facultyrank->Row_Selected($row);\n\t\t$ref_facultyrank->facultyRank_facultyRank2012->setDbValue($rs->fields('facultyRank_facultyRank2012'));\n\t\t$ref_facultyrank->facultyRank_numericRank2012->setDbValue($rs->fields('facultyRank_numericRank2012'));\n\t\t$ref_facultyrank->facultyRank_ID->setDbValue($rs->fields('facultyRank_ID'));\n\t\t$ref_facultyrank->facultyRank_UPRank->setDbValue($rs->fields('facultyRank_UPRank'));\n\t\t$ref_facultyrank->facultyRank_rankGroup->setDbValue($rs->fields('facultyRank_rankGroup'));\n\t\t$ref_facultyrank->facultyRank_isRegular->setDbValue($rs->fields('facultyRank_isRegular'));\n\t\t$ref_facultyrank->facultyRank_category->setDbValue($rs->fields('facultyRank_category'));\n\t\t$ref_facultyrank->facultyRank_salaryScale->setDbValue($rs->fields('facultyRank_salaryScale'));\n\t\t$ref_facultyrank->facultyRank_reportingDBM->setDbValue($rs->fields('facultyRank_reportingDBM'));\n\t\t$ref_facultyrank->facultyRank_reportingCHED->setDbValue($rs->fields('facultyRank_reportingCHED'));\n\t}", "title": "" }, { "docid": "cb4f1956b471f606b95c885da9ef28ed", "score": "0.6816512", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->llave->setDbValue($rs->fields('llave'));\n\t\t$this->F_Sincron->setDbValue($rs->fields('F_Sincron'));\n\t\t$this->USUARIO->setDbValue($rs->fields('USUARIO'));\n\t\t$this->Cargo_gme->setDbValue($rs->fields('Cargo_gme'));\n\t\t$this->Num_AV->setDbValue($rs->fields('Num_AV'));\n\t\t$this->NOM_APOYO->setDbValue($rs->fields('NOM_APOYO'));\n\t\t$this->Otro_Nom_Apoyo->setDbValue($rs->fields('Otro_Nom_Apoyo'));\n\t\t$this->Otro_CC_Apoyo->setDbValue($rs->fields('Otro_CC_Apoyo'));\n\t\t$this->NOM_PE->setDbValue($rs->fields('NOM_PE'));\n\t\t$this->Otro_PE->setDbValue($rs->fields('Otro_PE'));\n\t\t$this->Departamento->setDbValue($rs->fields('Departamento'));\n\t\t$this->Muncipio->setDbValue($rs->fields('Muncipio'));\n\t\t$this->NOM_VDA->setDbValue($rs->fields('NOM_VDA'));\n\t\t$this->NO_E->setDbValue($rs->fields('NO_E'));\n\t\t$this->NO_OF->setDbValue($rs->fields('NO_OF'));\n\t\t$this->NO_SUBOF->setDbValue($rs->fields('NO_SUBOF'));\n\t\t$this->NO_SOL->setDbValue($rs->fields('NO_SOL'));\n\t\t$this->NO_PATRU->setDbValue($rs->fields('NO_PATRU'));\n\t\t$this->Nom_enfer->setDbValue($rs->fields('Nom_enfer'));\n\t\t$this->Otro_Nom_Enfer->setDbValue($rs->fields('Otro_Nom_Enfer'));\n\t\t$this->Otro_CC_Enfer->setDbValue($rs->fields('Otro_CC_Enfer'));\n\t\t$this->Armada->setDbValue($rs->fields('Armada'));\n\t\t$this->Ejercito->setDbValue($rs->fields('Ejercito'));\n\t\t$this->Policia->setDbValue($rs->fields('Policia'));\n\t\t$this->NOM_UNIDAD->setDbValue($rs->fields('NOM_UNIDAD'));\n\t\t$this->NOM_COMAN->setDbValue($rs->fields('NOM_COMAN'));\n\t\t$this->CC_COMAN->setDbValue($rs->fields('CC_COMAN'));\n\t\t$this->TEL_COMAN->setDbValue($rs->fields('TEL_COMAN'));\n\t\t$this->RANGO_COMAN->setDbValue($rs->fields('RANGO_COMAN'));\n\t\t$this->Otro_rango->setDbValue($rs->fields('Otro_rango'));\n\t\t$this->NO_GDETECCION->setDbValue($rs->fields('NO_GDETECCION'));\n\t\t$this->NO_BINOMIO->setDbValue($rs->fields('NO_BINOMIO'));\n\t\t$this->FECHA_INTO_AV->setDbValue($rs->fields('FECHA_INTO_AV'));\n\t\t$this->DIA->setDbValue($rs->fields('DIA'));\n\t\t$this->MES->setDbValue($rs->fields('MES'));\n\t\t$this->LATITUD->setDbValue($rs->fields('LATITUD'));\n\t\t$this->GRA_LAT->setDbValue($rs->fields('GRA_LAT'));\n\t\t$this->MIN_LAT->setDbValue($rs->fields('MIN_LAT'));\n\t\t$this->SEG_LAT->setDbValue($rs->fields('SEG_LAT'));\n\t\t$this->GRA_LONG->setDbValue($rs->fields('GRA_LONG'));\n\t\t$this->MIN_LONG->setDbValue($rs->fields('MIN_LONG'));\n\t\t$this->SEG_LONG->setDbValue($rs->fields('SEG_LONG'));\n\t\t$this->OBSERVACION->setDbValue($rs->fields('OBSERVACION'));\n\t\t$this->AD1O->setDbValue($rs->fields('AÑO'));\n\t\t$this->FASE->setDbValue($rs->fields('FASE'));\n\t\t$this->Modificado->setDbValue($rs->fields('Modificado'));\n\t}", "title": "" }, { "docid": "407e7f6029b4d8b6a9f08806c7c079a8", "score": "0.6810184", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->ID_Formulario->setDbValue($rs->fields('ID_Formulario'));\n\t\t$this->F_Sincron->setDbValue($rs->fields('F_Sincron'));\n\t\t$this->USUARIO->setDbValue($rs->fields('USUARIO'));\n\t\t$this->Cargo_gme->setDbValue($rs->fields('Cargo_gme'));\n\t\t$this->NOM_GE->setDbValue($rs->fields('NOM_GE'));\n\t\t$this->Otro_PGE->setDbValue($rs->fields('Otro_PGE'));\n\t\t$this->Otro_CC_PGE->setDbValue($rs->fields('Otro_CC_PGE'));\n\t\t$this->TIPO_INFORME->setDbValue($rs->fields('TIPO_INFORME'));\n\t\t$this->FECHA_NOVEDAD->setDbValue($rs->fields('FECHA_NOVEDAD'));\n\t\t$this->DIA->setDbValue($rs->fields('DIA'));\n\t\t$this->MES->setDbValue($rs->fields('MES'));\n\t\t$this->Num_Evacua->setDbValue($rs->fields('Num_Evacua'));\n\t\t$this->PTO_INCOMU->setDbValue($rs->fields('PTO_INCOMU'));\n\t\t$this->OBS_punt_inco->setDbValue($rs->fields('OBS_punt_inco'));\n\t\t$this->OBS_ENLACE->setDbValue($rs->fields('OBS_ENLACE'));\n\t\t$this->NUM_Novedad->setDbValue($rs->fields('NUM_Novedad'));\n\t\t$this->Nom_Per_Evacu->setDbValue($rs->fields('Nom_Per_Evacu'));\n\t\t$this->CC_Pre_Evacu->setDbValue($rs->fields('CC_Pre_Evacu'));\n\t\t$this->Nom_Otro_Per_Evacu->setDbValue($rs->fields('Nom_Otro_Per_Evacu'));\n\t\t$this->CC_Otro_Per_Evacu->setDbValue($rs->fields('CC_Otro_Per_Evacu'));\n\t\t$this->Cargo_Per_EVA->setDbValue($rs->fields('Cargo_Per_EVA'));\n\t\t$this->Motivo_Eva->setDbValue($rs->fields('Motivo_Eva'));\n\t\t$this->OBS_EVA->setDbValue($rs->fields('OBS_EVA'));\n\t\t$this->NOM_PE->setDbValue($rs->fields('NOM_PE'));\n\t\t$this->Otro_Nom_PE->setDbValue($rs->fields('Otro_Nom_PE'));\n\t\t$this->NOM_CAPATAZ->setDbValue($rs->fields('NOM_CAPATAZ'));\n\t\t$this->Otro_Nom_Capata->setDbValue($rs->fields('Otro_Nom_Capata'));\n\t\t$this->Otro_CC_Capata->setDbValue($rs->fields('Otro_CC_Capata'));\n\t\t$this->Muncipio->setDbValue($rs->fields('Muncipio'));\n\t\t$this->F_llegada->setDbValue($rs->fields('F_llegada'));\n\t\t$this->Fecha->setDbValue($rs->fields('Fecha'));\n\t\t$this->Modificado->setDbValue($rs->fields('Modificado'));\n\t\t$this->llave_2->setDbValue($rs->fields('llave_2'));\n\t\t$this->departamento->setDbValue($rs->fields('departamento'));\n\t}", "title": "" }, { "docid": "1d8a388d24663e8d99994b6476682e65", "score": "0.68006206", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->id->setDbValue($rs->fields('id'));\n\t\t$this->id_jenis_spp->setDbValue($rs->fields('id_jenis_spp'));\n\t\t$this->detail_jenis_spp->setDbValue($rs->fields('detail_jenis_spp'));\n\t\t$this->status_spp->setDbValue($rs->fields('status_spp'));\n\t\t$this->no_spp->setDbValue($rs->fields('no_spp'));\n\t\t$this->tgl_spp->setDbValue($rs->fields('tgl_spp'));\n\t\t$this->nama_pptk->setDbValue($rs->fields('nama_pptk'));\n\t\t$this->nip_pptk->setDbValue($rs->fields('nip_pptk'));\n\t\t$this->keterangan->setDbValue($rs->fields('keterangan'));\n\t\t$this->pph21->setDbValue($rs->fields('pph21'));\n\t\t$this->pph22->setDbValue($rs->fields('pph22'));\n\t\t$this->pph23->setDbValue($rs->fields('pph23'));\n\t\t$this->pph4->setDbValue($rs->fields('pph4'));\n\t\t$this->nama_bendahara->setDbValue($rs->fields('nama_bendahara'));\n\t\t$this->nip_bendahara->setDbValue($rs->fields('nip_bendahara'));\n\t\t$this->kode_program->setDbValue($rs->fields('kode_program'));\n\t\t$this->kode_kegiatan->setDbValue($rs->fields('kode_kegiatan'));\n\t\t$this->kode_sub_kegiatan->setDbValue($rs->fields('kode_sub_kegiatan'));\n\t\t$this->jumlah_belanja->setDbValue($rs->fields('jumlah_belanja'));\n\t\t$this->kontrak_id->setDbValue($rs->fields('kontrak_id'));\n\t\t$this->kode_rekening->setDbValue($rs->fields('kode_rekening'));\n\t\t$this->akun1->setDbValue($rs->fields('akun1'));\n\t\t$this->akun2->setDbValue($rs->fields('akun2'));\n\t\t$this->akun3->setDbValue($rs->fields('akun3'));\n\t\t$this->akun4->setDbValue($rs->fields('akun4'));\n\t\t$this->akun5->setDbValue($rs->fields('akun5'));\n\t}", "title": "" }, { "docid": "8229037503c6160abb7604c967247aa3", "score": "0.6794915", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->hotel_id->setDbValue($rs->fields('hotel_id'));\n\t\t$this->h_name->setDbValue($rs->fields('h_name'));\n\t\t$this->h_slug->setDbValue($rs->fields('h_slug'));\n\t\t$this->h_feature_image->Upload->DbValue = $rs->fields('h_feature_image');\n\t\t$this->h_feature_image->CurrentValue = $this->h_feature_image->Upload->DbValue;\n\t\t$this->h_description->setDbValue($rs->fields('h_description'));\n\t\t$this->h_meta_key->setDbValue($rs->fields('h_meta_key'));\n\t\t$this->h_deatail->setDbValue($rs->fields('h_deatail'));\n\t\t$this->h_facilities->setDbValue($rs->fields('h_facilities'));\n\t\t$this->h_address->setDbValue($rs->fields('h_address'));\n\t\t$this->h_create->setDbValue($rs->fields('h_create'));\n\t\t$this->dest_id->setDbValue($rs->fields('dest_id'));\n\t\t$this->province->setDbValue($rs->fields('province'));\n\t\t$this->whylike->setDbValue($rs->fields('whylike'));\n\t\t$this->lang_spoken->setDbValue($rs->fields('lang_spoken'));\n\t\t$this->map->setDbValue($rs->fields('map'));\n\t\t$this->what_todo->setDbValue($rs->fields('what_todo'));\n\t\t$this->h_id_cod->setDbValue($rs->fields('h_id_cod'));\n\t\t$this->h_email->setDbValue($rs->fields('h_email'));\n\t\t$this->h_contact_name->setDbValue($rs->fields('h_contact_name'));\n\t\t$this->h_pass->setDbValue($rs->fields('h_pass'));\n\t\t$this->h_contact_phone->setDbValue($rs->fields('h_contact_phone'));\n\t\t$this->h_site->setDbValue($rs->fields('h_site'));\n\t\t$this->contact_fax->setDbValue($rs->fields('contact_fax'));\n\t\t$this->star_rating->setDbValue($rs->fields('star_rating'));\n\t\t$this->create_date->setDbValue($rs->fields('create_date'));\n\t\t$this->update_date->setDbValue($rs->fields('update_date'));\n\t\t$this->h_online_status->setDbValue($rs->fields('h_online_status'));\n\t\t$this->hotel_blocked->setDbValue($rs->fields('hotel_blocked'));\n\t}", "title": "" }, { "docid": "dbb40595651aaf734d8ecd39e66e7911", "score": "0.67872953", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->id->DbValue = $row['id'];\n\t\t$this->image->Upload->DbValue = $row['image'];\n\t\t$this->title_en->DbValue = $row['title_en'];\n\t\t$this->title_ar->DbValue = $row['title_ar'];\n\t\t$this->position_en->DbValue = $row['position_en'];\n\t\t$this->position_ar->DbValue = $row['position_ar'];\n\t\t$this->experience->DbValue = $row['experience'];\n\t\t$this->gender->DbValue = $row['gender'];\n\t\t$this->applied->DbValue = $row['applied'];\n\t\t$this->desc_en->DbValue = $row['desc_en'];\n\t\t$this->desc_ar->DbValue = $row['desc_ar'];\n\t\t$this->created->DbValue = $row['created'];\n\t}", "title": "" }, { "docid": "045d8adae3fc1dfb3edae9a463733251", "score": "0.6785051", "text": "function LoadRowValues(&$rs) {\r\n\t\tglobal $conn, $filesystem;\r\n\t\t$filesystem->id->setDbValue($rs->fields('id'));\r\n\t\t$filesystem->mount->setDbValue($rs->fields('mount'));\r\n\t\t$filesystem->path->setDbValue($rs->fields('path'));\r\n\t\t$filesystem->parent->setDbValue($rs->fields('parent'));\r\n\t\t$filesystem->deprecated->setDbValue($rs->fields('deprecated'));\r\n\t\t$filesystem->gid->setDbValue($rs->fields('gid'));\r\n\t\t$filesystem->snapshot->setDbValue($rs->fields('snapshot'));\r\n\t\t$filesystem->tapebackup->setDbValue($rs->fields('tapebackup'));\r\n\t\t$filesystem->diskbackup->setDbValue($rs->fields('diskbackup'));\r\n\t\t$filesystem->type->setDbValue($rs->fields('type'));\r\n\t\t$filesystem->contact->setDbValue($rs->fields('contact'));\r\n\t\t$filesystem->contact2->setDbValue($rs->fields('contact2'));\r\n\t\t$filesystem->rescomp->setDbValue($rs->fields('rescomp'));\r\n\t\t$filesystem->maxdepth->setDbValue($rs->fields('maxdepth'));\r\n\t}", "title": "" }, { "docid": "997c53e6bec3f107206d86c2c5c65848", "score": "0.6772393", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->tanggal->setDbValue($rs->fields('tanggal'));\n\t\t$this->periode->setDbValue($rs->fields('periode'));\n\t\t$this->id->setDbValue($rs->fields('id'));\n\t\t$this->transaksi->setDbValue($rs->fields('transaksi'));\n\t\t$this->referensi->setDbValue($rs->fields('referensi'));\n\t\t$this->anggota->setDbValue($rs->fields('anggota'));\n\t\t$this->namaanggota->setDbValue($rs->fields('namaanggota'));\n\t\t$this->alamat->setDbValue($rs->fields('alamat'));\n\t\t$this->pekerjaan->setDbValue($rs->fields('pekerjaan'));\n\t\t$this->telepon->setDbValue($rs->fields('telepon'));\n\t\t$this->hp->setDbValue($rs->fields('hp'));\n\t\t$this->fax->setDbValue($rs->fields('fax'));\n\t\t$this->_email->setDbValue($rs->fields('email'));\n\t\t$this->website->setDbValue($rs->fields('website'));\n\t\t$this->jenisanggota->setDbValue($rs->fields('jenisanggota'));\n\t\t$this->model->setDbValue($rs->fields('model'));\n\t\t$this->jenispinjaman->setDbValue($rs->fields('jenispinjaman'));\n\t\t$this->jenisbunga->setDbValue($rs->fields('jenisbunga'));\n\t\t$this->angsuran->setDbValue($rs->fields('angsuran'));\n\t\t$this->masaangsuran->setDbValue($rs->fields('masaangsuran'));\n\t\t$this->jatuhtempo->setDbValue($rs->fields('jatuhtempo'));\n\t\t$this->terlambat->setDbValue($rs->fields('terlambat'));\n\t\t$this->dispensasidenda->setDbValue($rs->fields('dispensasidenda'));\n\t\t$this->plafond->setDbValue($rs->fields('plafond'));\n\t\t$this->angsuranpokok->setDbValue($rs->fields('angsuranpokok'));\n\t\t$this->angsuranpokokauto->setDbValue($rs->fields('angsuranpokokauto'));\n\t\t$this->angsuranbunga->setDbValue($rs->fields('angsuranbunga'));\n\t\t$this->angsuranbungaauto->setDbValue($rs->fields('angsuranbungaauto'));\n\t\t$this->denda->setDbValue($rs->fields('denda'));\n\t\t$this->dendapersen->setDbValue($rs->fields('dendapersen'));\n\t\t$this->totalangsuran->setDbValue($rs->fields('totalangsuran'));\n\t\t$this->totalangsuranauto->setDbValue($rs->fields('totalangsuranauto'));\n\t\t$this->sisaangsuran->setDbValue($rs->fields('sisaangsuran'));\n\t\t$this->sisaangsuranauto->setDbValue($rs->fields('sisaangsuranauto'));\n\t\t$this->saldotitipan->setDbValue($rs->fields('saldotitipan'));\n\t\t$this->saldotitipansisa->setDbValue($rs->fields('saldotitipansisa'));\n\t\t$this->bayarpokok->setDbValue($rs->fields('bayarpokok'));\n\t\t$this->bayarpokokauto->setDbValue($rs->fields('bayarpokokauto'));\n\t\t$this->bayarbunga->setDbValue($rs->fields('bayarbunga'));\n\t\t$this->bayarbungaauto->setDbValue($rs->fields('bayarbungaauto'));\n\t\t$this->bayardenda->setDbValue($rs->fields('bayardenda'));\n\t\t$this->bayardendaauto->setDbValue($rs->fields('bayardendaauto'));\n\t\t$this->bayartitipan->setDbValue($rs->fields('bayartitipan'));\n\t\t$this->bayartitipanauto->setDbValue($rs->fields('bayartitipanauto'));\n\t\t$this->totalbayar->setDbValue($rs->fields('totalbayar'));\n\t\t$this->totalbayarauto->setDbValue($rs->fields('totalbayarauto'));\n\t\t$this->pelunasan->setDbValue($rs->fields('pelunasan'));\n\t\t$this->pelunasanauto->setDbValue($rs->fields('pelunasanauto'));\n\t\t$this->finalty->setDbValue($rs->fields('finalty'));\n\t\t$this->finaltyauto->setDbValue($rs->fields('finaltyauto'));\n\t\t$this->terbilang->setDbValue($rs->fields('terbilang'));\n\t\t$this->petugas->setDbValue($rs->fields('petugas'));\n\t\t$this->pembayaran->setDbValue($rs->fields('pembayaran'));\n\t\t$this->bank->setDbValue($rs->fields('bank'));\n\t\t$this->atasnama->setDbValue($rs->fields('atasnama'));\n\t\t$this->tipe->setDbValue($rs->fields('tipe'));\n\t\t$this->kantor->setDbValue($rs->fields('kantor'));\n\t\t$this->keterangan->setDbValue($rs->fields('keterangan'));\n\t\t$this->active->setDbValue($rs->fields('active'));\n\t\t$this->ip->setDbValue($rs->fields('ip'));\n\t\t$this->status->setDbValue($rs->fields('status'));\n\t\t$this->user->setDbValue($rs->fields('user'));\n\t\t$this->created->setDbValue($rs->fields('created'));\n\t\t$this->modified->setDbValue($rs->fields('modified'));\n\t}", "title": "" }, { "docid": "957d85c35c0ee0744111019574523401", "score": "0.6764674", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->nombre_estado_interno->setDbValue($rs->fields('nombre_estado_interno'));\n\t\t$this->para_factura_estado_interno->setDbValue($rs->fields('para_factura_estado_interno'));\n\t\t$this->se_paga_comision_estado_interno->setDbValue($rs->fields('se_paga_comision_estado_interno'));\n\t\t$this->porcen_comision_estado_interno->setDbValue($rs->fields('porcen_comision_estado_interno'));\n\t\t$this->se_paga_bono_estado_interno->setDbValue($rs->fields('se_paga_bono_estado_interno'));\n\t\t$this->porcen_bono_estado_interno->setDbValue($rs->fields('porcen_bono_estado_interno'));\n\t\t$this->obs_estado_interno->setDbValue($rs->fields('obs_estado_interno'));\n\t\t$this->envio_boffice_estado_interno->setDbValue($rs->fields('envio_boffice_estado_interno'));\n\t\t$this->empresa_estado_interno->setDbValue($rs->fields('empresa_estado_interno'));\n\t\t$this->id_estado_interno->setDbValue($rs->fields('id_estado_interno'));\n\t}", "title": "" }, { "docid": "c1abca86839f3b9de8c99b4cbfaa5566", "score": "0.676344", "text": "function LoadDbValues(&$rs) {\r\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\r\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\r\n\t\t$this->filename->DbValue = $row['filename'];\r\n\t\t$this->username->DbValue = $row['username'];\r\n\t\t$this->type->DbValue = $row['type'];\r\n\t\t$this->mediaid->DbValue = $row['mediaid'];\r\n\t\t$this->path->DbValue = $row['path'];\r\n\t\t$this->dateCreated->DbValue = $row['dateCreated'];\r\n\t\t$this->description->DbValue = $row['description'];\r\n\t\t$this->keywords->DbValue = $row['keywords'];\r\n\t\t$this->duration->DbValue = $row['duration'];\r\n\t\t$this->privacy->DbValue = $row['privacy'];\r\n\t\t$this->catagory->DbValue = $row['catagory'];\r\n\t}", "title": "" }, { "docid": "0350ef4cee9c69eb7b33f4cfb4518abe", "score": "0.6759464", "text": "public function loadRowValues($rs = NULL)\n\t{\n\t\tif ($rs && !$rs->EOF)\n\t\t\t$row = $rs->fields;\n\t\telse\n\t\t\t$row = $this->newRow();\n\n\t\t// Call Row Selected event\n\t\t$this->Row_Selected($row);\n\t\tif (!$rs || $rs->EOF)\n\t\t\treturn;\n\t\t$this->EmployeeID->setDbValue($row['EmployeeID']);\n\t\t$this->ProvinceCode->setDbValue($row['ProvinceCode']);\n\t\t$this->LACode->setDbValue($row['LACode']);\n\t\t$this->DepartmentCode->setDbValue($row['DepartmentCode']);\n\t\t$this->SectionCode->setDbValue($row['SectionCode']);\n\t\t$this->SubstantivePosition->setDbValue($row['SubstantivePosition']);\n\t\t$this->DateOfCurrentAppointment->setDbValue($row['DateOfCurrentAppointment']);\n\t\t$this->LastAppraisalDate->setDbValue($row['LastAppraisalDate']);\n\t\t$this->AppraisalStatus->setDbValue($row['AppraisalStatus']);\n\t\t$this->DateOfExit->setDbValue($row['DateOfExit']);\n\t\t$this->SalaryScale->setDbValue($row['SalaryScale']);\n\t\t$this->EmploymentType->setDbValue($row['EmploymentType']);\n\t\t$this->EmploymentStatus->setDbValue($row['EmploymentStatus']);\n\t\t$this->ExitReason->setDbValue($row['ExitReason']);\n\t\t$this->RetirementType->setDbValue($row['RetirementType']);\n\t\t$this->EmployeeNumber->setDbValue($row['EmployeeNumber']);\n\t\t$this->SalaryNotch->setDbValue($row['SalaryNotch']);\n\t\t$this->BasicMonthlySalary->setDbValue($row['BasicMonthlySalary']);\n\t\t$this->ThirdParties->setDbValue($row['ThirdParties']);\n\t\t$this->PayrollCode->setDbValue($row['PayrollCode']);\n\t\t$this->DateOfConfirmation->setDbValue($row['DateOfConfirmation']);\n\t}", "title": "" }, { "docid": "df9a6aa9158247beded36a92244639c5", "score": "0.6752801", "text": "protected function loadDbValues(&$rs)\n\t{\n\t\tif (!$rs || !is_array($rs) && $rs->EOF)\n\t\t\treturn;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->PefromanceRef->DbValue = $row['PefromanceRef'];\n\t\t$this->IndicatorCode->DbValue = $row['IndicatorCode'];\n\t\t$this->Category->DbValue = $row['Category'];\n\t\t$this->TargetDesc->DbValue = $row['TargetDesc'];\n\t\t$this->Target->DbValue = $row['Target'];\n\t\t$this->ValueDesc->DbValue = $row['ValueDesc'];\n\t\t$this->Value->DbValue = $row['Value'];\n\t\t$this->UnitOfMeasure->DbValue = $row['UnitOfMeasure'];\n\t\t$this->Deviation->DbValue = $row['Deviation'];\n\t\t$this->Recommendation->DbValue = $row['Recommendation'];\n\t\t$this->Remedies->DbValue = $row['Remedies'];\n\t\t$this->PMonth->DbValue = $row['PMonth'];\n\t\t$this->PYear->DbValue = $row['PYear'];\n\t}", "title": "" }, { "docid": "5a64601e744ad29058497815f00c30f1", "score": "0.6749347", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->id->setDbValue($rs->fields('id'));\n\t\t$this->image->Upload->DbValue = $rs->fields('image');\n\t\t$this->image->CurrentValue = $this->image->Upload->DbValue;\n\t\t$this->title_en->setDbValue($rs->fields('title_en'));\n\t\t$this->title_ar->setDbValue($rs->fields('title_ar'));\n\t\t$this->position_en->setDbValue($rs->fields('position_en'));\n\t\t$this->position_ar->setDbValue($rs->fields('position_ar'));\n\t\t$this->experience->setDbValue($rs->fields('experience'));\n\t\t$this->gender->setDbValue($rs->fields('gender'));\n\t\t$this->applied->setDbValue($rs->fields('applied'));\n\t\t$this->desc_en->setDbValue($rs->fields('desc_en'));\n\t\t$this->desc_ar->setDbValue($rs->fields('desc_ar'));\n\t\t$this->created->setDbValue($rs->fields('created'));\n\t\tif (!isset($GLOBALS[\"job_candidates_grid\"])) $GLOBALS[\"job_candidates_grid\"] = new cjob_candidates_grid;\n\t\t$sDetailFilter = $GLOBALS[\"job_candidates\"]->SqlDetailFilter_jobs();\n\t\t$sDetailFilter = str_replace(\"@job_id@\", ew_AdjustSql($this->id->DbValue), $sDetailFilter);\n\t\t$GLOBALS[\"job_candidates\"]->setCurrentMasterTable(\"jobs\");\n\t\t$sDetailFilter = $GLOBALS[\"job_candidates\"]->ApplyUserIDFilters($sDetailFilter);\n\t\t$this->job_candidates_Count = $GLOBALS[\"job_candidates\"]->LoadRecordCount($sDetailFilter);\n\t}", "title": "" }, { "docid": "02fac5a2115b9a7f0fffa10d11f4ba54", "score": "0.6728395", "text": "function LoadDbValues(&$rs) {\r\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\r\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\r\n\t\t$this->id->DbValue = $row['id'];\r\n\t\t$this->arrival->DbValue = $row['arrival'];\r\n\t\t$this->departure->DbValue = $row['departure'];\r\n\t\t$this->user->DbValue = $row['user'];\r\n\t\t$this->name->DbValue = $row['name'];\r\n\t\t$this->_email->DbValue = $row['email'];\r\n\t\t$this->country->DbValue = $row['country'];\r\n\t\t$this->approve->DbValue = $row['approve'];\r\n\t\t$this->room->DbValue = $row['room'];\r\n\t\t$this->roomnumber->DbValue = $row['roomnumber'];\r\n\t\t$this->number->DbValue = $row['number'];\r\n\t\t$this->childs->DbValue = $row['childs'];\r\n\t\t$this->price->DbValue = $row['price'];\r\n\t\t$this->custom->DbValue = $row['custom'];\r\n\t\t$this->customp->DbValue = $row['customp'];\r\n\t\t$this->reservated->DbValue = $row['reservated'];\r\n\t}", "title": "" }, { "docid": "e09731cbb82e4ecc15dc990629e69997", "score": "0.6722161", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $usuarios;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row =& $rs->fields;\n\t\t$usuarios->Row_Selected($row);\n\t\t$usuarios->id_usuario->setDbValue($rs->fields('id_usuario'));\n\t\t$usuarios->nombre->setDbValue($rs->fields('nombre'));\n\t\t$usuarios->apellido->setDbValue($rs->fields('apellido'));\n\t\t$usuarios->acceso->setDbValue($rs->fields('acceso'));\n\t\t$usuarios->llave->setDbValue($rs->fields('llave'));\n\t\t$usuarios->correo->setDbValue($rs->fields('correo'));\n\t\t$usuarios->UserLevelID->setDbValue($rs->fields('UserLevelID'));\n\t\t$usuarios->estatus->setDbValue($rs->fields('estatus'));\n\t\t$usuarios->duracion_pass->setDbValue($rs->fields('duracion_pass'));\n\t\t$usuarios->duracion_fech->setDbValue($rs->fields('duracion_fech'));\n\t}", "title": "" }, { "docid": "979742808f2f834c876978f154a5292c", "score": "0.67144144", "text": "protected function loadDbValues(&$rs)\n\t{\n\t\tif (!$rs || !is_array($rs) && $rs->EOF)\n\t\t\treturn;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->id->DbValue = $row['id'];\n\t\t$this->property_id->DbValue = $row['property_id'];\n\t\t$this->property->DbValue = $row['property'];\n\t\t$this->templatefile2->DbValue = $row['templatefile2'];\n\t\t$this->transactionno->DbValue = $row['transactionno'];\n\t\t$this->transactiondate->DbValue = $row['transactiondate'];\n\t\t$this->recommendedby->DbValue = $row['recommendedby'];\n\t\t$this->signatureby->DbValue = $row['signatureby'];\n\t\t$this->positionby->DbValue = $row['positionby'];\n\t\t$this->ce_id->DbValue = $row['ce_id'];\n\t\t$this->signaturece->DbValue = $row['signaturece'];\n\t\t$this->itm_id->DbValue = $row['itm_id'];\n\t\t$this->signatureitm->DbValue = $row['signatureitm'];\n\t\t$this->sign1->DbValue = $row['sign1'];\n\t\t$this->jobt1->DbValue = $row['jobt1'];\n\t\t$this->sign2->DbValue = $row['sign2'];\n\t\t$this->jobt2->DbValue = $row['jobt2'];\n\t\t$this->sign3->DbValue = $row['sign3'];\n\t\t$this->jobt3->DbValue = $row['jobt3'];\n\t\t$this->disposaldetail_id->DbValue = $row['disposaldetail_id'];\n\t\t$this->asset_id->DbValue = $row['asset_id'];\n\t\t$this->code->DbValue = $row['code'];\n\t\t$this->description->DbValue = $row['description'];\n\t\t$this->department_id->DbValue = $row['department_id'];\n\t\t$this->asset_dept->DbValue = $row['asset_dept'];\n\t\t$this->procurementdate->DbValue = $row['procurementdate'];\n\t\t$this->procurementcurrentcost->DbValue = $row['procurementcurrentcost'];\n\t\t$this->remarks->DbValue = $row['remarks'];\n\t\t$this->condstatus->DbValue = $row['condstatus'];\n\t\t$this->reasonstatus->DbValue = $row['reasonstatus'];\n\t\t$this->disposaldate->DbValue = $row['disposaldate'];\n\t}", "title": "" }, { "docid": "47c2156cc55ba48b9fb4440cae584717", "score": "0.671128", "text": "function LoadDbValues(&$rs) {\r\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\r\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\r\n\t\t$this->Id->DbValue = $row['Id'];\r\n\t\t$this->Nama->DbValue = $row['Nama'];\r\n\t\t$this->Alamat->DbValue = $row['Alamat'];\r\n\t\t$this->Jumlah->DbValue = $row['Jumlah'];\r\n\t\t$this->Provinsi->DbValue = $row['Provinsi'];\r\n\t\t$this->Area->DbValue = $row['Area'];\r\n\t\t$this->CP->DbValue = $row['CP'];\r\n\t\t$this->NoContact->DbValue = $row['NoContact'];\r\n\t\t$this->Tanggal->DbValue = $row['Tanggal'];\r\n\t\t$this->Jam->DbValue = $row['Jam'];\r\n\t\t$this->Vechicle->DbValue = $row['Vechicle'];\r\n\t\t$this->Type->DbValue = $row['Type'];\r\n\t\t$this->Site->DbValue = $row['Site'];\r\n\t\t$this->Status->DbValue = $row['Status'];\r\n\t\t$this->_UserID->DbValue = $row['UserID'];\r\n\t\t$this->TglInput->DbValue = $row['TglInput'];\r\n\t\t$this->visit->DbValue = $row['visit'];\r\n\t}", "title": "" }, { "docid": "ff36865c54b6eaabf6c73c2f12206ed7", "score": "0.67110384", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->codigo->DbValue = $row['codigo'];\n\t\t$this->usuario->DbValue = $row['usuario'];\n\t\t$this->contrasenia->DbValue = $row['contrasenia'];\n\t\t$this->nombre->DbValue = $row['nombre'];\n\t\t$this->_email->DbValue = $row['email'];\n\t\t$this->activo->DbValue = $row['activo'];\n\t}", "title": "" }, { "docid": "13429587007f8d17c462f965cd5f16a7", "score": "0.670511", "text": "public function loadListRowValues(&$rs)\n\t{\n\t\t$this->PefromanceRef->setDbValue($rs->fields('PefromanceRef'));\n\t\t$this->IndicatorCode->setDbValue($rs->fields('IndicatorCode'));\n\t\t$this->Category->setDbValue($rs->fields('Category'));\n\t\t$this->TargetDesc->setDbValue($rs->fields('TargetDesc'));\n\t\t$this->Target->setDbValue($rs->fields('Target'));\n\t\t$this->ValueDesc->setDbValue($rs->fields('ValueDesc'));\n\t\t$this->Value->setDbValue($rs->fields('Value'));\n\t\t$this->UnitOfMeasure->setDbValue($rs->fields('UnitOfMeasure'));\n\t\t$this->Deviation->setDbValue($rs->fields('Deviation'));\n\t\t$this->Recommendation->setDbValue($rs->fields('Recommendation'));\n\t\t$this->Remedies->setDbValue($rs->fields('Remedies'));\n\t\t$this->PMonth->setDbValue($rs->fields('PMonth'));\n\t\t$this->PYear->setDbValue($rs->fields('PYear'));\n\t}", "title": "" }, { "docid": "bd041adda977b9a8b6227bdeb5a50c6b", "score": "0.66930836", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->tanggal->setDbValue($rs->fields('tanggal'));\n\t\t$this->periode->setDbValue($rs->fields('periode'));\n\t\t$this->id->setDbValue($rs->fields('id'));\n\t\t$this->nomor->setDbValue($rs->fields('nomor'));\n\t\t$this->transaksi->setDbValue($rs->fields('transaksi'));\n\t\t$this->referensi->setDbValue($rs->fields('referensi'));\n\t\t$this->group->setDbValue($rs->fields('group'));\n\t\t$this->rekening->setDbValue($rs->fields('rekening'));\n\t\t$this->tipe->setDbValue($rs->fields('tipe'));\n\t\t$this->posisi->setDbValue($rs->fields('posisi'));\n\t\t$this->laporan->setDbValue($rs->fields('laporan'));\n\t\t$this->keterangan->setDbValue($rs->fields('keterangan'));\n\t\t$this->debet1->setDbValue($rs->fields('debet1'));\n\t\t$this->credit1->setDbValue($rs->fields('credit1'));\n\t\t$this->saldo1->setDbValue($rs->fields('saldo1'));\n\t\t$this->debet2->setDbValue($rs->fields('debet2'));\n\t\t$this->credit2->setDbValue($rs->fields('credit2'));\n\t\t$this->saldo2->setDbValue($rs->fields('saldo2'));\n\t\t$this->debet3->setDbValue($rs->fields('debet3'));\n\t\t$this->credit3->setDbValue($rs->fields('credit3'));\n\t\t$this->saldo3->setDbValue($rs->fields('saldo3'));\n\t\t$this->debet4->setDbValue($rs->fields('debet4'));\n\t\t$this->credit4->setDbValue($rs->fields('credit4'));\n\t\t$this->saldo4->setDbValue($rs->fields('saldo4'));\n\t\t$this->debet5->setDbValue($rs->fields('debet5'));\n\t\t$this->credit5->setDbValue($rs->fields('credit5'));\n\t\t$this->saldo5->setDbValue($rs->fields('saldo5'));\n\t\t$this->debet6->setDbValue($rs->fields('debet6'));\n\t\t$this->credit6->setDbValue($rs->fields('credit6'));\n\t\t$this->saldo6->setDbValue($rs->fields('saldo6'));\n\t\t$this->debet7->setDbValue($rs->fields('debet7'));\n\t\t$this->credit7->setDbValue($rs->fields('credit7'));\n\t\t$this->saldo7->setDbValue($rs->fields('saldo7'));\n\t\t$this->debet8->setDbValue($rs->fields('debet8'));\n\t\t$this->credit8->setDbValue($rs->fields('credit8'));\n\t\t$this->saldo8->setDbValue($rs->fields('saldo8'));\n\t\t$this->debet9->setDbValue($rs->fields('debet9'));\n\t\t$this->credit9->setDbValue($rs->fields('credit9'));\n\t\t$this->saldo9->setDbValue($rs->fields('saldo9'));\n\t\t$this->debet10->setDbValue($rs->fields('debet10'));\n\t\t$this->credit10->setDbValue($rs->fields('credit10'));\n\t\t$this->saldo10->setDbValue($rs->fields('saldo10'));\n\t\t$this->debet11->setDbValue($rs->fields('debet11'));\n\t\t$this->credit11->setDbValue($rs->fields('credit11'));\n\t\t$this->saldo11->setDbValue($rs->fields('saldo11'));\n\t\t$this->debet12->setDbValue($rs->fields('debet12'));\n\t\t$this->credit12->setDbValue($rs->fields('credit12'));\n\t\t$this->saldo12->setDbValue($rs->fields('saldo12'));\n\t}", "title": "" }, { "docid": "5a757c7eccfb9918afa4d4c3ef694678", "score": "0.6682931", "text": "public function loadRowValues($rs = null)\n {\n if (is_array($rs)) {\n $row = $rs;\n } elseif ($rs && property_exists($rs, \"fields\")) { // Recordset\n $row = $rs->fields;\n } else {\n $row = $this->newRow();\n }\n\n // Call Row Selected event\n $this->rowSelected($row);\n if (!$rs) {\n return;\n }\n $this->nik->setDbValue($row['nik']);\n $this->chatting->setDbValue($row['chatting']);\n $this->skor_chatting->setDbValue($row['skor_chatting']);\n $this->max_chatting->setDbValue($row['max_chatting']);\n $this->medsos->setDbValue($row['medsos']);\n $this->skor_medsos->setDbValue($row['skor_medsos']);\n $this->max_medsos->setDbValue($row['max_medsos']);\n $this->marketplace->setDbValue($row['marketplace']);\n $this->skor_mp->setDbValue($row['skor_mp']);\n $this->max_mp->setDbValue($row['max_mp']);\n $this->gmb->setDbValue($row['gmb']);\n $this->skor_gmb->setDbValue($row['skor_gmb']);\n $this->max_gmb->setDbValue($row['max_gmb']);\n $this->web->setDbValue($row['web']);\n $this->skor_web->setDbValue($row['skor_web']);\n $this->max_web->setDbValue($row['max_web']);\n $this->updatemedsos->setDbValue($row['updatemedsos']);\n $this->skor_updatemedsos->setDbValue($row['skor_updatemedsos']);\n $this->max_updatemedsos->setDbValue($row['max_updatemedsos']);\n $this->updateweb->setDbValue($row['updateweb']);\n $this->skor_updateweb->setDbValue($row['skor_updateweb']);\n $this->max_updateweb->setDbValue($row['max_updateweb']);\n $this->seo->setDbValue($row['seo']);\n $this->skor_seo->setDbValue($row['skor_seo']);\n $this->max_seo->setDbValue($row['max_seo']);\n $this->iklan->setDbValue($row['iklan']);\n $this->skor_iklan->setDbValue($row['skor_iklan']);\n $this->max_iklan->setDbValue($row['max_iklan']);\n $this->skor_pemasaranonline->setDbValue($row['skor_pemasaranonline']);\n $this->maxskor_pemasaranonline->setDbValue($row['maxskor_pemasaranonline']);\n $this->bobot_pemasaranonline->setDbValue($row['bobot_pemasaranonline']);\n }", "title": "" }, { "docid": "289f40c067a13e59554589a9e9b8d93d", "score": "0.6681084", "text": "function LoadDbValues(&$rs) {\r\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\r\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\r\n\t\t$this->ID->DbValue = $row['ID'];\r\n\t\t$this->username->DbValue = $row['username'];\r\n\t\t$this->password->DbValue = $row['password'];\r\n\t\t$this->FristName->DbValue = $row['FristName'];\r\n\t\t$this->LastName->DbValue = $row['LastName'];\r\n\t\t$this->_Email->DbValue = $row['Email'];\r\n\t\t$this->Gender->DbValue = $row['Gender'];\r\n\t\t$this->BirthDate->DbValue = $row['BirthDate'];\r\n\t\t$this->permissions->DbValue = $row['permissions'];\r\n\t}", "title": "" }, { "docid": "7c02d230089eb61cc05fc63640cefa7d", "score": "0.6676016", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->id->DbValue = $row['id'];\n\t\t$this->NOMR->DbValue = $row['NOMR'];\n\t\t$this->TITLE->DbValue = $row['TITLE'];\n\t\t$this->NAMA->DbValue = $row['NAMA'];\n\t\t$this->IBUKANDUNG->DbValue = $row['IBUKANDUNG'];\n\t\t$this->TEMPAT->DbValue = $row['TEMPAT'];\n\t\t$this->TGLLAHIR->DbValue = $row['TGLLAHIR'];\n\t\t$this->JENISKELAMIN->DbValue = $row['JENISKELAMIN'];\n\t\t$this->ALAMAT->DbValue = $row['ALAMAT'];\n\t\t$this->KDPROVINSI->DbValue = $row['KDPROVINSI'];\n\t\t$this->KOTA->DbValue = $row['KOTA'];\n\t\t$this->KDKECAMATAN->DbValue = $row['KDKECAMATAN'];\n\t\t$this->KELURAHAN->DbValue = $row['KELURAHAN'];\n\t\t$this->NOTELP->DbValue = $row['NOTELP'];\n\t\t$this->NOKTP->DbValue = $row['NOKTP'];\n\t\t$this->SUAMI_ORTU->DbValue = $row['SUAMI_ORTU'];\n\t\t$this->PEKERJAAN->DbValue = $row['PEKERJAAN'];\n\t\t$this->STATUS->DbValue = $row['STATUS'];\n\t\t$this->AGAMA->DbValue = $row['AGAMA'];\n\t\t$this->PENDIDIKAN->DbValue = $row['PENDIDIKAN'];\n\t\t$this->KDCARABAYAR->DbValue = $row['KDCARABAYAR'];\n\t\t$this->NIP->DbValue = $row['NIP'];\n\t\t$this->TGLDAFTAR->DbValue = $row['TGLDAFTAR'];\n\t\t$this->ALAMAT_KTP->DbValue = $row['ALAMAT_KTP'];\n\t\t$this->PARENT_NOMR->DbValue = $row['PARENT_NOMR'];\n\t\t$this->NAMA_OBAT->DbValue = $row['NAMA_OBAT'];\n\t\t$this->DOSIS->DbValue = $row['DOSIS'];\n\t\t$this->CARA_PEMBERIAN->DbValue = $row['CARA_PEMBERIAN'];\n\t\t$this->FREKUENSI->DbValue = $row['FREKUENSI'];\n\t\t$this->WAKTU_TGL->DbValue = $row['WAKTU_TGL'];\n\t\t$this->LAMA_WAKTU->DbValue = $row['LAMA_WAKTU'];\n\t\t$this->ALERGI_OBAT->DbValue = $row['ALERGI_OBAT'];\n\t\t$this->REAKSI_ALERGI->DbValue = $row['REAKSI_ALERGI'];\n\t\t$this->RIWAYAT_KES->DbValue = $row['RIWAYAT_KES'];\n\t\t$this->BB_LAHIR->DbValue = $row['BB_LAHIR'];\n\t\t$this->BB_SEKARANG->DbValue = $row['BB_SEKARANG'];\n\t\t$this->FISIK_FONTANEL->DbValue = $row['FISIK_FONTANEL'];\n\t\t$this->FISIK_REFLEKS->DbValue = $row['FISIK_REFLEKS'];\n\t\t$this->FISIK_SENSASI->DbValue = $row['FISIK_SENSASI'];\n\t\t$this->MOTORIK_KASAR->DbValue = $row['MOTORIK_KASAR'];\n\t\t$this->MOTORIK_HALUS->DbValue = $row['MOTORIK_HALUS'];\n\t\t$this->MAMPU_BICARA->DbValue = $row['MAMPU_BICARA'];\n\t\t$this->MAMPU_SOSIALISASI->DbValue = $row['MAMPU_SOSIALISASI'];\n\t\t$this->BCG->DbValue = $row['BCG'];\n\t\t$this->POLIO->DbValue = $row['POLIO'];\n\t\t$this->DPT->DbValue = $row['DPT'];\n\t\t$this->CAMPAK->DbValue = $row['CAMPAK'];\n\t\t$this->HEPATITIS_B->DbValue = $row['HEPATITIS_B'];\n\t\t$this->TD->DbValue = $row['TD'];\n\t\t$this->SUHU->DbValue = $row['SUHU'];\n\t\t$this->RR->DbValue = $row['RR'];\n\t\t$this->NADI->DbValue = $row['NADI'];\n\t\t$this->BB->DbValue = $row['BB'];\n\t\t$this->TB->DbValue = $row['TB'];\n\t\t$this->EYE->DbValue = $row['EYE'];\n\t\t$this->MOTORIK->DbValue = $row['MOTORIK'];\n\t\t$this->VERBAL->DbValue = $row['VERBAL'];\n\t\t$this->TOTAL_GCS->DbValue = $row['TOTAL_GCS'];\n\t\t$this->REAKSI_PUPIL->DbValue = $row['REAKSI_PUPIL'];\n\t\t$this->KESADARAN->DbValue = $row['KESADARAN'];\n\t\t$this->KEPALA->DbValue = $row['KEPALA'];\n\t\t$this->RAMBUT->DbValue = $row['RAMBUT'];\n\t\t$this->MUKA->DbValue = $row['MUKA'];\n\t\t$this->MATA->DbValue = $row['MATA'];\n\t\t$this->GANG_LIHAT->DbValue = $row['GANG_LIHAT'];\n\t\t$this->ALATBANTU_LIHAT->DbValue = $row['ALATBANTU_LIHAT'];\n\t\t$this->BENTUK->DbValue = $row['BENTUK'];\n\t\t$this->PENDENGARAN->DbValue = $row['PENDENGARAN'];\n\t\t$this->LUB_TELINGA->DbValue = $row['LUB_TELINGA'];\n\t\t$this->BENTUK_HIDUNG->DbValue = $row['BENTUK_HIDUNG'];\n\t\t$this->MEMBRAN_MUK->DbValue = $row['MEMBRAN_MUK'];\n\t\t$this->MAMPU_HIDU->DbValue = $row['MAMPU_HIDU'];\n\t\t$this->ALAT_HIDUNG->DbValue = $row['ALAT_HIDUNG'];\n\t\t$this->RONGGA_MULUT->DbValue = $row['RONGGA_MULUT'];\n\t\t$this->WARNA_MEMBRAN->DbValue = $row['WARNA_MEMBRAN'];\n\t\t$this->LEMBAB->DbValue = $row['LEMBAB'];\n\t\t$this->STOMATITIS->DbValue = $row['STOMATITIS'];\n\t\t$this->LIDAH->DbValue = $row['LIDAH'];\n\t\t$this->GIGI->DbValue = $row['GIGI'];\n\t\t$this->TONSIL->DbValue = $row['TONSIL'];\n\t\t$this->KELAINAN->DbValue = $row['KELAINAN'];\n\t\t$this->PERGERAKAN->DbValue = $row['PERGERAKAN'];\n\t\t$this->KEL_TIROID->DbValue = $row['KEL_TIROID'];\n\t\t$this->KEL_GETAH->DbValue = $row['KEL_GETAH'];\n\t\t$this->TEKANAN_VENA->DbValue = $row['TEKANAN_VENA'];\n\t\t$this->REF_MENELAN->DbValue = $row['REF_MENELAN'];\n\t\t$this->NYERI->DbValue = $row['NYERI'];\n\t\t$this->KREPITASI->DbValue = $row['KREPITASI'];\n\t\t$this->KEL_LAIN->DbValue = $row['KEL_LAIN'];\n\t\t$this->BENTUK_DADA->DbValue = $row['BENTUK_DADA'];\n\t\t$this->POLA_NAPAS->DbValue = $row['POLA_NAPAS'];\n\t\t$this->BENTUK_THORAKS->DbValue = $row['BENTUK_THORAKS'];\n\t\t$this->PAL_KREP->DbValue = $row['PAL_KREP'];\n\t\t$this->BENJOLAN->DbValue = $row['BENJOLAN'];\n\t\t$this->PAL_NYERI->DbValue = $row['PAL_NYERI'];\n\t\t$this->PERKUSI->DbValue = $row['PERKUSI'];\n\t\t$this->PARU->DbValue = $row['PARU'];\n\t\t$this->JANTUNG->DbValue = $row['JANTUNG'];\n\t\t$this->SUARA_JANTUNG->DbValue = $row['SUARA_JANTUNG'];\n\t\t$this->ALATBANTU_JAN->DbValue = $row['ALATBANTU_JAN'];\n\t\t$this->BENTUK_ABDOMEN->DbValue = $row['BENTUK_ABDOMEN'];\n\t\t$this->AUSKULTASI->DbValue = $row['AUSKULTASI'];\n\t\t$this->NYERI_PASI->DbValue = $row['NYERI_PASI'];\n\t\t$this->PEM_KELENJAR->DbValue = $row['PEM_KELENJAR'];\n\t\t$this->PERKUSI_AUS->DbValue = $row['PERKUSI_AUS'];\n\t\t$this->VAGINA->DbValue = $row['VAGINA'];\n\t\t$this->MENSTRUASI->DbValue = $row['MENSTRUASI'];\n\t\t$this->KATETER->DbValue = $row['KATETER'];\n\t\t$this->LABIA_PROM->DbValue = $row['LABIA_PROM'];\n\t\t$this->HAMIL->DbValue = $row['HAMIL'];\n\t\t$this->TGL_HAID->DbValue = $row['TGL_HAID'];\n\t\t$this->PERIKSA_CERVIX->DbValue = $row['PERIKSA_CERVIX'];\n\t\t$this->BENTUK_PAYUDARA->DbValue = $row['BENTUK_PAYUDARA'];\n\t\t$this->KENYAL->DbValue = $row['KENYAL'];\n\t\t$this->MASSA->DbValue = $row['MASSA'];\n\t\t$this->NYERI_RABA->DbValue = $row['NYERI_RABA'];\n\t\t$this->BENTUK_PUTING->DbValue = $row['BENTUK_PUTING'];\n\t\t$this->MAMMO->DbValue = $row['MAMMO'];\n\t\t$this->ALAT_KONTRASEPSI->DbValue = $row['ALAT_KONTRASEPSI'];\n\t\t$this->MASALAH_SEKS->DbValue = $row['MASALAH_SEKS'];\n\t\t$this->PREPUTIUM->DbValue = $row['PREPUTIUM'];\n\t\t$this->MASALAH_PROSTAT->DbValue = $row['MASALAH_PROSTAT'];\n\t\t$this->BENTUK_SKROTUM->DbValue = $row['BENTUK_SKROTUM'];\n\t\t$this->TESTIS->DbValue = $row['TESTIS'];\n\t\t$this->MASSA_BEN->DbValue = $row['MASSA_BEN'];\n\t\t$this->HERNIASI->DbValue = $row['HERNIASI'];\n\t\t$this->LAIN2->DbValue = $row['LAIN2'];\n\t\t$this->ALAT_KONTRA->DbValue = $row['ALAT_KONTRA'];\n\t\t$this->MASALAH_REPRO->DbValue = $row['MASALAH_REPRO'];\n\t\t$this->EKSTREMITAS_ATAS->DbValue = $row['EKSTREMITAS_ATAS'];\n\t\t$this->EKSTREMITAS_BAWAH->DbValue = $row['EKSTREMITAS_BAWAH'];\n\t\t$this->AKTIVITAS->DbValue = $row['AKTIVITAS'];\n\t\t$this->BERJALAN->DbValue = $row['BERJALAN'];\n\t\t$this->SISTEM_INTE->DbValue = $row['SISTEM_INTE'];\n\t\t$this->KENYAMANAN->DbValue = $row['KENYAMANAN'];\n\t\t$this->KES_DIRI->DbValue = $row['KES_DIRI'];\n\t\t$this->SOS_SUPORT->DbValue = $row['SOS_SUPORT'];\n\t\t$this->ANSIETAS->DbValue = $row['ANSIETAS'];\n\t\t$this->KEHILANGAN->DbValue = $row['KEHILANGAN'];\n\t\t$this->STATUS_EMOSI->DbValue = $row['STATUS_EMOSI'];\n\t\t$this->KONSEP_DIRI->DbValue = $row['KONSEP_DIRI'];\n\t\t$this->RESPON_HILANG->DbValue = $row['RESPON_HILANG'];\n\t\t$this->SUMBER_STRESS->DbValue = $row['SUMBER_STRESS'];\n\t\t$this->BERARTI->DbValue = $row['BERARTI'];\n\t\t$this->TERLIBAT->DbValue = $row['TERLIBAT'];\n\t\t$this->HUBUNGAN->DbValue = $row['HUBUNGAN'];\n\t\t$this->KOMUNIKASI->DbValue = $row['KOMUNIKASI'];\n\t\t$this->KEPUTUSAN->DbValue = $row['KEPUTUSAN'];\n\t\t$this->MENGASUH->DbValue = $row['MENGASUH'];\n\t\t$this->DUKUNGAN->DbValue = $row['DUKUNGAN'];\n\t\t$this->REAKSI->DbValue = $row['REAKSI'];\n\t\t$this->BUDAYA->DbValue = $row['BUDAYA'];\n\t\t$this->POLA_AKTIVITAS->DbValue = $row['POLA_AKTIVITAS'];\n\t\t$this->POLA_ISTIRAHAT->DbValue = $row['POLA_ISTIRAHAT'];\n\t\t$this->POLA_MAKAN->DbValue = $row['POLA_MAKAN'];\n\t\t$this->PANTANGAN->DbValue = $row['PANTANGAN'];\n\t\t$this->KEPERCAYAAN->DbValue = $row['KEPERCAYAAN'];\n\t\t$this->PANTANGAN_HARI->DbValue = $row['PANTANGAN_HARI'];\n\t\t$this->PANTANGAN_LAIN->DbValue = $row['PANTANGAN_LAIN'];\n\t\t$this->ANJURAN->DbValue = $row['ANJURAN'];\n\t\t$this->NILAI_KEYAKINAN->DbValue = $row['NILAI_KEYAKINAN'];\n\t\t$this->KEGIATAN_IBADAH->DbValue = $row['KEGIATAN_IBADAH'];\n\t\t$this->PENG_AGAMA->DbValue = $row['PENG_AGAMA'];\n\t\t$this->SPIRIT->DbValue = $row['SPIRIT'];\n\t\t$this->BANTUAN->DbValue = $row['BANTUAN'];\n\t\t$this->PAHAM_PENYAKIT->DbValue = $row['PAHAM_PENYAKIT'];\n\t\t$this->PAHAM_OBAT->DbValue = $row['PAHAM_OBAT'];\n\t\t$this->PAHAM_NUTRISI->DbValue = $row['PAHAM_NUTRISI'];\n\t\t$this->PAHAM_RAWAT->DbValue = $row['PAHAM_RAWAT'];\n\t\t$this->HAMBATAN_EDUKASI->DbValue = $row['HAMBATAN_EDUKASI'];\n\t\t$this->FREK_MAKAN->DbValue = $row['FREK_MAKAN'];\n\t\t$this->JUM_MAKAN->DbValue = $row['JUM_MAKAN'];\n\t\t$this->JEN_MAKAN->DbValue = $row['JEN_MAKAN'];\n\t\t$this->KOM_MAKAN->DbValue = $row['KOM_MAKAN'];\n\t\t$this->DIET->DbValue = $row['DIET'];\n\t\t$this->CARA_MAKAN->DbValue = $row['CARA_MAKAN'];\n\t\t$this->GANGGUAN->DbValue = $row['GANGGUAN'];\n\t\t$this->FREK_MINUM->DbValue = $row['FREK_MINUM'];\n\t\t$this->JUM_MINUM->DbValue = $row['JUM_MINUM'];\n\t\t$this->JEN_MINUM->DbValue = $row['JEN_MINUM'];\n\t\t$this->GANG_MINUM->DbValue = $row['GANG_MINUM'];\n\t\t$this->FREK_BAK->DbValue = $row['FREK_BAK'];\n\t\t$this->WARNA_BAK->DbValue = $row['WARNA_BAK'];\n\t\t$this->JMLH_BAK->DbValue = $row['JMLH_BAK'];\n\t\t$this->PENG_KAT_BAK->DbValue = $row['PENG_KAT_BAK'];\n\t\t$this->KEM_HAN_BAK->DbValue = $row['KEM_HAN_BAK'];\n\t\t$this->INKONT_BAK->DbValue = $row['INKONT_BAK'];\n\t\t$this->DIURESIS_BAK->DbValue = $row['DIURESIS_BAK'];\n\t\t$this->FREK_BAB->DbValue = $row['FREK_BAB'];\n\t\t$this->WARNA_BAB->DbValue = $row['WARNA_BAB'];\n\t\t$this->KONSIST_BAB->DbValue = $row['KONSIST_BAB'];\n\t\t$this->GANG_BAB->DbValue = $row['GANG_BAB'];\n\t\t$this->STOMA_BAB->DbValue = $row['STOMA_BAB'];\n\t\t$this->PENG_OBAT_BAB->DbValue = $row['PENG_OBAT_BAB'];\n\t\t$this->IST_SIANG->DbValue = $row['IST_SIANG'];\n\t\t$this->IST_MALAM->DbValue = $row['IST_MALAM'];\n\t\t$this->IST_CAHAYA->DbValue = $row['IST_CAHAYA'];\n\t\t$this->IST_POSISI->DbValue = $row['IST_POSISI'];\n\t\t$this->IST_LING->DbValue = $row['IST_LING'];\n\t\t$this->IST_GANG_TIDUR->DbValue = $row['IST_GANG_TIDUR'];\n\t\t$this->PENG_OBAT_IST->DbValue = $row['PENG_OBAT_IST'];\n\t\t$this->FREK_MAND->DbValue = $row['FREK_MAND'];\n\t\t$this->CUC_RAMB_MAND->DbValue = $row['CUC_RAMB_MAND'];\n\t\t$this->SIH_GIGI_MAND->DbValue = $row['SIH_GIGI_MAND'];\n\t\t$this->BANT_MAND->DbValue = $row['BANT_MAND'];\n\t\t$this->GANT_PAKAI->DbValue = $row['GANT_PAKAI'];\n\t\t$this->PAK_CUCI->DbValue = $row['PAK_CUCI'];\n\t\t$this->PAK_BANT->DbValue = $row['PAK_BANT'];\n\t\t$this->ALT_BANT->DbValue = $row['ALT_BANT'];\n\t\t$this->KEMP_MUND->DbValue = $row['KEMP_MUND'];\n\t\t$this->BIL_PUT->DbValue = $row['BIL_PUT'];\n\t\t$this->ADAPTIF->DbValue = $row['ADAPTIF'];\n\t\t$this->MALADAPTIF->DbValue = $row['MALADAPTIF'];\n\t\t$this->PENANGGUNGJAWAB_NAMA->DbValue = $row['PENANGGUNGJAWAB_NAMA'];\n\t\t$this->PENANGGUNGJAWAB_HUBUNGAN->DbValue = $row['PENANGGUNGJAWAB_HUBUNGAN'];\n\t\t$this->PENANGGUNGJAWAB_ALAMAT->DbValue = $row['PENANGGUNGJAWAB_ALAMAT'];\n\t\t$this->PENANGGUNGJAWAB_PHONE->DbValue = $row['PENANGGUNGJAWAB_PHONE'];\n\t\t$this->obat2->DbValue = $row['obat2'];\n\t\t$this->PERBANDINGAN_BB->DbValue = $row['PERBANDINGAN_BB'];\n\t\t$this->KONTINENSIA->DbValue = $row['KONTINENSIA'];\n\t\t$this->JENIS_KULIT1->DbValue = $row['JENIS_KULIT1'];\n\t\t$this->MOBILITAS->DbValue = $row['MOBILITAS'];\n\t\t$this->JK->DbValue = $row['JK'];\n\t\t$this->UMUR->DbValue = $row['UMUR'];\n\t\t$this->NAFSU_MAKAN->DbValue = $row['NAFSU_MAKAN'];\n\t\t$this->OBAT1->DbValue = $row['OBAT1'];\n\t\t$this->MALNUTRISI->DbValue = $row['MALNUTRISI'];\n\t\t$this->MOTORIK1->DbValue = $row['MOTORIK1'];\n\t\t$this->SPINAL->DbValue = $row['SPINAL'];\n\t\t$this->MEJA_OPERASI->DbValue = $row['MEJA_OPERASI'];\n\t\t$this->RIWAYAT_JATUH->DbValue = $row['RIWAYAT_JATUH'];\n\t\t$this->DIAGNOSIS_SEKUNDER->DbValue = $row['DIAGNOSIS_SEKUNDER'];\n\t\t$this->ALAT_BANTU->DbValue = $row['ALAT_BANTU'];\n\t\t$this->HEPARIN->DbValue = $row['HEPARIN'];\n\t\t$this->GAYA_BERJALAN->DbValue = $row['GAYA_BERJALAN'];\n\t\t$this->KESADARAN1->DbValue = $row['KESADARAN1'];\n\t\t$this->NOMR_LAMA->DbValue = $row['NOMR_LAMA'];\n\t\t$this->NO_KARTU->DbValue = $row['NO_KARTU'];\n\t\t$this->JNS_PASIEN->DbValue = $row['JNS_PASIEN'];\n\t\t$this->nama_ayah->DbValue = $row['nama_ayah'];\n\t\t$this->nama_ibu->DbValue = $row['nama_ibu'];\n\t\t$this->nama_suami->DbValue = $row['nama_suami'];\n\t\t$this->nama_istri->DbValue = $row['nama_istri'];\n\t\t$this->KD_ETNIS->DbValue = $row['KD_ETNIS'];\n\t\t$this->KD_BHS_HARIAN->DbValue = $row['KD_BHS_HARIAN'];\n\t}", "title": "" }, { "docid": "3fd7625677fcdd130d61cd56dd4129fb", "score": "0.6675159", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->rm_id->setDbValue($rs->fields('rm_id'));\n\t\t$this->pegawai_id->setDbValue($rs->fields('pegawai_id'));\n\t\t$this->f1->setDbValue($rs->fields('f1'));\n\t\t$this->f2->setDbValue($rs->fields('f2'));\n\t\t$this->f3->setDbValue($rs->fields('f3'));\n\t\t$this->f4->setDbValue($rs->fields('f4'));\n\t\t$this->f5->setDbValue($rs->fields('f5'));\n\t\t$this->f6->setDbValue($rs->fields('f6'));\n\t\t$this->f7->setDbValue($rs->fields('f7'));\n\t\t$this->f8->setDbValue($rs->fields('f8'));\n\t\t$this->f9->setDbValue($rs->fields('f9'));\n\t\t$this->f10->setDbValue($rs->fields('f10'));\n\t\t$this->f11->setDbValue($rs->fields('f11'));\n\t\t$this->f12->setDbValue($rs->fields('f12'));\n\t\t$this->f13->setDbValue($rs->fields('f13'));\n\t\t$this->f14->setDbValue($rs->fields('f14'));\n\t\t$this->f15->setDbValue($rs->fields('f15'));\n\t\t$this->f16->setDbValue($rs->fields('f16'));\n\t\t$this->f17->setDbValue($rs->fields('f17'));\n\t\t$this->f18->setDbValue($rs->fields('f18'));\n\t\t$this->f19->setDbValue($rs->fields('f19'));\n\t\t$this->f20->setDbValue($rs->fields('f20'));\n\t\t$this->f21->setDbValue($rs->fields('f21'));\n\t\t$this->f22->setDbValue($rs->fields('f22'));\n\t\t$this->f23->setDbValue($rs->fields('f23'));\n\t\t$this->f24->setDbValue($rs->fields('f24'));\n\t\t$this->f25->setDbValue($rs->fields('f25'));\n\t\t$this->f26->setDbValue($rs->fields('f26'));\n\t\t$this->f27->setDbValue($rs->fields('f27'));\n\t\t$this->f28->setDbValue($rs->fields('f28'));\n\t\t$this->f29->setDbValue($rs->fields('f29'));\n\t\t$this->f30->setDbValue($rs->fields('f30'));\n\t\t$this->f31->setDbValue($rs->fields('f31'));\n\t\t$this->f32->setDbValue($rs->fields('f32'));\n\t\t$this->f33->setDbValue($rs->fields('f33'));\n\t\t$this->f34->setDbValue($rs->fields('f34'));\n\t\t$this->f35->setDbValue($rs->fields('f35'));\n\t\t$this->f36->setDbValue($rs->fields('f36'));\n\t\t$this->f37->setDbValue($rs->fields('f37'));\n\t\t$this->f38->setDbValue($rs->fields('f38'));\n\t\t$this->f39->setDbValue($rs->fields('f39'));\n\t\t$this->f40->setDbValue($rs->fields('f40'));\n\t\t$this->f41->setDbValue($rs->fields('f41'));\n\t\t$this->f42->setDbValue($rs->fields('f42'));\n\t\t$this->f43->setDbValue($rs->fields('f43'));\n\t\t$this->f44->setDbValue($rs->fields('f44'));\n\t\t$this->f45->setDbValue($rs->fields('f45'));\n\t\t$this->f46->setDbValue($rs->fields('f46'));\n\t\t$this->f47->setDbValue($rs->fields('f47'));\n\t\t$this->f48->setDbValue($rs->fields('f48'));\n\t\t$this->f49->setDbValue($rs->fields('f49'));\n\t\t$this->f50->setDbValue($rs->fields('f50'));\n\t\t$this->f51->setDbValue($rs->fields('f51'));\n\t\t$this->f52->setDbValue($rs->fields('f52'));\n\t\t$this->f53->setDbValue($rs->fields('f53'));\n\t\t$this->f54->setDbValue($rs->fields('f54'));\n\t\t$this->f55->setDbValue($rs->fields('f55'));\n\t\t$this->f56->setDbValue($rs->fields('f56'));\n\t\t$this->f57->setDbValue($rs->fields('f57'));\n\t\t$this->f58->setDbValue($rs->fields('f58'));\n\t\t$this->f59->setDbValue($rs->fields('f59'));\n\t\t$this->f60->setDbValue($rs->fields('f60'));\n\t\t$this->f61->setDbValue($rs->fields('f61'));\n\t\t$this->f62->setDbValue($rs->fields('f62'));\n\t}", "title": "" }, { "docid": "4bfbf4e214ec003ffadb64369f297cb2", "score": "0.6669912", "text": "function LoadListRowValues(&$rs) {\r\n\t\t$this->id_afiliado->setDbValue($rs->fields('id_afiliado'));\r\n\t\t$this->dociden_afiliado->setDbValue($rs->fields('dociden_afiliado'));\r\n\t\t$this->apell_afiliado->setDbValue($rs->fields('apell_afiliado'));\r\n\t\t$this->nomb_afiliado->setDbValue($rs->fields('nomb_afiliado'));\r\n\t\t$this->direcc_afiliado->setDbValue($rs->fields('direcc_afiliado'));\r\n\t\t$this->email_afiliado->setDbValue($rs->fields('email_afiliado'));\r\n\t\t$this->cel_afiliado->setDbValue($rs->fields('cel_afiliado'));\r\n\t\t$this->genero_afiliado->setDbValue($rs->fields('genero_afiliado'));\r\n\t\t$this->fe_afiliado->setDbValue($rs->fields('fe_afiliado'));\r\n\t\t$this->telemerg_afiliado->setDbValue($rs->fields('telemerg_afiliado'));\r\n\t\t$this->talla_afiliado->setDbValue($rs->fields('talla_afiliado'));\r\n\t\t$this->peso_afiliado->setDbValue($rs->fields('peso_afiliado'));\r\n\t\t$this->altu_afiliado->setDbValue($rs->fields('altu_afiliado'));\r\n\t\t$this->localresdi_afiliado->setDbValue($rs->fields('localresdi_afiliado'));\r\n\t\t$this->telf_fijo_afiliado->setDbValue($rs->fields('telf_fijo_afiliado'));\r\n\t\t$this->coleg_afiliado->setDbValue($rs->fields('coleg_afiliado'));\r\n\t\t$this->seguro_afiliado->setDbValue($rs->fields('seguro_afiliado'));\r\n\t\t$this->tiposangre_afiliado->setDbValue($rs->fields('tiposangre_afiliado'));\r\n\t\t$this->contacto_afiliado->setDbValue($rs->fields('contacto_afiliado'));\r\n\t\t$this->st_afiliado->setDbValue($rs->fields('st_afiliado'));\r\n\t\t$this->foto_afiliado->Upload->DbValue = $rs->fields('foto_afiliado');\r\n\t\t$this->st_notificado->setDbValue($rs->fields('st_notificado'));\r\n\t}", "title": "" }, { "docid": "d2263b79e2625bb6269148831b226d4d", "score": "0.6652133", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF)\n\t\t\treturn;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->id->DbValue = $row['id'];\n\t\t$this->oauth_provider->DbValue = $row['oauth_provider'];\n\t\t$this->oauth_uid->DbValue = $row['oauth_uid'];\n\t\t$this->first_name->DbValue = $row['first_name'];\n\t\t$this->last_name->DbValue = $row['last_name'];\n\t\t$this->_email->DbValue = $row['email'];\n\t\t$this->gender->DbValue = $row['gender'];\n\t\t$this->locale->DbValue = $row['locale'];\n\t\t$this->cover->DbValue = $row['cover'];\n\t\t$this->picture->Upload->DbValue = $row['picture'];\n\t\t$this->link->DbValue = $row['link'];\n\t\t$this->created->DbValue = $row['created'];\n\t\t$this->modified->DbValue = $row['modified'];\n\t}", "title": "" }, { "docid": "19a193a6c3d7087b9a4f9a74409f95c2", "score": "0.66316015", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->rm_id->DbValue = $row['rm_id'];\n\t\t$this->pegawai_id->DbValue = $row['pegawai_id'];\n\t\t$this->f1->DbValue = $row['f1'];\n\t\t$this->f2->DbValue = $row['f2'];\n\t\t$this->f3->DbValue = $row['f3'];\n\t\t$this->f4->DbValue = $row['f4'];\n\t\t$this->f5->DbValue = $row['f5'];\n\t\t$this->f6->DbValue = $row['f6'];\n\t\t$this->f7->DbValue = $row['f7'];\n\t\t$this->f8->DbValue = $row['f8'];\n\t\t$this->f9->DbValue = $row['f9'];\n\t\t$this->f10->DbValue = $row['f10'];\n\t\t$this->f11->DbValue = $row['f11'];\n\t\t$this->f12->DbValue = $row['f12'];\n\t\t$this->f13->DbValue = $row['f13'];\n\t\t$this->f14->DbValue = $row['f14'];\n\t\t$this->f15->DbValue = $row['f15'];\n\t\t$this->f16->DbValue = $row['f16'];\n\t\t$this->f17->DbValue = $row['f17'];\n\t\t$this->f18->DbValue = $row['f18'];\n\t\t$this->f19->DbValue = $row['f19'];\n\t\t$this->f20->DbValue = $row['f20'];\n\t\t$this->f21->DbValue = $row['f21'];\n\t\t$this->f22->DbValue = $row['f22'];\n\t\t$this->f23->DbValue = $row['f23'];\n\t\t$this->f24->DbValue = $row['f24'];\n\t\t$this->f25->DbValue = $row['f25'];\n\t\t$this->f26->DbValue = $row['f26'];\n\t\t$this->f27->DbValue = $row['f27'];\n\t\t$this->f28->DbValue = $row['f28'];\n\t\t$this->f29->DbValue = $row['f29'];\n\t\t$this->f30->DbValue = $row['f30'];\n\t\t$this->f31->DbValue = $row['f31'];\n\t\t$this->f32->DbValue = $row['f32'];\n\t\t$this->f33->DbValue = $row['f33'];\n\t\t$this->f34->DbValue = $row['f34'];\n\t\t$this->f35->DbValue = $row['f35'];\n\t\t$this->f36->DbValue = $row['f36'];\n\t\t$this->f37->DbValue = $row['f37'];\n\t\t$this->f38->DbValue = $row['f38'];\n\t\t$this->f39->DbValue = $row['f39'];\n\t\t$this->f40->DbValue = $row['f40'];\n\t\t$this->f41->DbValue = $row['f41'];\n\t\t$this->f42->DbValue = $row['f42'];\n\t\t$this->f43->DbValue = $row['f43'];\n\t\t$this->f44->DbValue = $row['f44'];\n\t\t$this->f45->DbValue = $row['f45'];\n\t\t$this->f46->DbValue = $row['f46'];\n\t\t$this->f47->DbValue = $row['f47'];\n\t\t$this->f48->DbValue = $row['f48'];\n\t\t$this->f49->DbValue = $row['f49'];\n\t\t$this->f50->DbValue = $row['f50'];\n\t\t$this->f51->DbValue = $row['f51'];\n\t\t$this->f52->DbValue = $row['f52'];\n\t\t$this->f53->DbValue = $row['f53'];\n\t\t$this->f54->DbValue = $row['f54'];\n\t\t$this->f55->DbValue = $row['f55'];\n\t\t$this->f56->DbValue = $row['f56'];\n\t\t$this->f57->DbValue = $row['f57'];\n\t\t$this->f58->DbValue = $row['f58'];\n\t\t$this->f59->DbValue = $row['f59'];\n\t\t$this->f60->DbValue = $row['f60'];\n\t\t$this->f61->DbValue = $row['f61'];\n\t\t$this->f62->DbValue = $row['f62'];\n\t}", "title": "" }, { "docid": "57699131711014407fe872f761251b95", "score": "0.6621291", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->ID->DbValue = $row['ID'];\n\t\t$this->Name->DbValue = $row['Name'];\n\t\t$this->UniversityID->DbValue = $row['UniversityID'];\n\t\t$this->College->DbValue = $row['College'];\n\t\t$this->Department->DbValue = $row['Department'];\n\t\t$this->StartDate->DbValue = $row['StartDate'];\n\t\t$this->EndDate->DbValue = $row['EndDate'];\n\t\t$this->PlaceVisited->DbValue = $row['PlaceVisited'];\n\t\t$this->NatureOfVisit->DbValue = $row['NatureOfVisit'];\n\t\t$this->AttendanceOnly->DbValue = $row['AttendanceOnly'];\n\t\t$this->PresentAPaper->DbValue = $row['PresentAPaper'];\n\t\t$this->Others->DbValue = $row['Others'];\n\t\t$this->Participation->DbValue = $row['Participation'];\n\t\t$this->Summary->DbValue = $row['Summary'];\n\t\t$this->SuggestionRecommendation->DbValue = $row['SuggestionRecommendation'];\n\t\t$this->FacultyMemberSign->DbValue = $row['FacultyMemberSign'];\n\t\t$this->DepChairmanSign->DbValue = $row['DepChairmanSign'];\n\t\t$this->DeanSign->DbValue = $row['DeanSign'];\n\t}", "title": "" }, { "docid": "bda2ec618f0df08f350d35956a6c350a", "score": "0.6614665", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF)\n\t\t\treturn;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->customer_id->DbValue = $row['customer_id'];\n\t\t$this->customer_code->DbValue = $row['customer_code'];\n\t\t$this->customer_group->DbValue = $row['customer_group'];\n\t\t$this->customer_name->DbValue = $row['customer_name'];\n\t\t$this->contact_name->DbValue = $row['contact_name'];\n\t\t$this->address1->DbValue = $row['address1'];\n\t\t$this->address2->DbValue = $row['address2'];\n\t\t$this->address3->DbValue = $row['address3'];\n\t\t$this->phone->DbValue = $row['phone'];\n\t\t$this->fax->DbValue = $row['fax'];\n\t\t$this->wilayah_id->DbValue = $row['wilayah_id'];\n\t\t$this->subwil_id->DbValue = $row['subwil_id'];\n\t\t$this->area_id->DbValue = $row['area_id'];\n\t\t$this->sales_id->DbValue = $row['sales_id'];\n\t\t$this->due_day->DbValue = $row['due_day'];\n\t\t$this->ar_acc->DbValue = $row['ar_acc'];\n\t\t$this->npwp->DbValue = $row['npwp'];\n\t\t$this->discount->DbValue = $row['discount'];\n\t\t$this->freight->DbValue = $row['freight'];\n\t\t$this->credit_max->DbValue = $row['credit_max'];\n\t\t$this->invoice_max->DbValue = $row['invoice_max'];\n\t\t$this->saldo_awal->DbValue = $row['saldo_awal'];\n\t\t$this->curency->DbValue = $row['curency'];\n\t\t$this->kode_depo->DbValue = $row['kode_depo'];\n\t\t$this->tax->DbValue = $row['tax'];\n\t}", "title": "" }, { "docid": "a56a685750b5ba79ce512819019a66bd", "score": "0.66044337", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->pd_id->DbValue = $row['pd_id'];\n\t\t$this->pegawai_id->DbValue = $row['pegawai_id'];\n\t\t$this->dept_id->DbValue = $row['dept_id'];\n\t\t$this->f0m1->DbValue = $row['f0m1'];\n\t\t$this->f0k1->DbValue = $row['f0k1'];\n\t\t$this->f1m1->DbValue = $row['f1m1'];\n\t\t$this->f1k1->DbValue = $row['f1k1'];\n\t\t$this->f2m1->DbValue = $row['f2m1'];\n\t\t$this->f2k1->DbValue = $row['f2k1'];\n\t\t$this->f3m1->DbValue = $row['f3m1'];\n\t\t$this->f3k1->DbValue = $row['f3k1'];\n\t\t$this->f4m1->DbValue = $row['f4m1'];\n\t\t$this->f4k1->DbValue = $row['f4k1'];\n\t\t$this->f5m1->DbValue = $row['f5m1'];\n\t\t$this->f5k1->DbValue = $row['f5k1'];\n\t\t$this->f6m1->DbValue = $row['f6m1'];\n\t\t$this->f6k1->DbValue = $row['f6k1'];\n\t\t$this->f0m2->DbValue = $row['f0m2'];\n\t\t$this->f0k2->DbValue = $row['f0k2'];\n\t\t$this->f1m2->DbValue = $row['f1m2'];\n\t\t$this->f1k2->DbValue = $row['f1k2'];\n\t\t$this->f2m2->DbValue = $row['f2m2'];\n\t\t$this->f2k2->DbValue = $row['f2k2'];\n\t\t$this->f3m2->DbValue = $row['f3m2'];\n\t\t$this->f3k2->DbValue = $row['f3k2'];\n\t\t$this->f4m2->DbValue = $row['f4m2'];\n\t\t$this->f4k2->DbValue = $row['f4k2'];\n\t\t$this->f5m2->DbValue = $row['f5m2'];\n\t\t$this->f5k2->DbValue = $row['f5k2'];\n\t\t$this->f6m2->DbValue = $row['f6m2'];\n\t\t$this->f6k2->DbValue = $row['f6k2'];\n\t\t$this->f0m3->DbValue = $row['f0m3'];\n\t\t$this->f0k3->DbValue = $row['f0k3'];\n\t\t$this->f1m3->DbValue = $row['f1m3'];\n\t\t$this->f1k3->DbValue = $row['f1k3'];\n\t\t$this->f2m3->DbValue = $row['f2m3'];\n\t\t$this->f2k3->DbValue = $row['f2k3'];\n\t\t$this->f3m3->DbValue = $row['f3m3'];\n\t\t$this->f3k3->DbValue = $row['f3k3'];\n\t\t$this->f4m3->DbValue = $row['f4m3'];\n\t\t$this->f4k3->DbValue = $row['f4k3'];\n\t\t$this->f5m3->DbValue = $row['f5m3'];\n\t\t$this->f5k3->DbValue = $row['f5k3'];\n\t\t$this->f6m3->DbValue = $row['f6m3'];\n\t\t$this->f6k3->DbValue = $row['f6k3'];\n\t}", "title": "" }, { "docid": "6adcb2f97276deb2efd0e6af49dce144", "score": "0.6592998", "text": "public function loadRowValues($rs = NULL)\n\t{\n\t\tif ($rs && !$rs->EOF)\n\t\t\t$row = $rs->fields;\n\t\telse\n\t\t\t$row = $this->newRow();\n\n\t\t// Call Row Selected event\n\t\t$this->Row_Selected($row);\n\t\tif (!$rs || $rs->EOF)\n\t\t\treturn;\n\t\t$this->idProcess->setDbValue($row['idProcess']);\n\t\t$this->idCause->setDbValue($row['idCause']);\n\t\tif (array_key_exists('EV__idCause', $rs->fields)) {\n\t\t\t$this->idCause->VirtualValue = $rs->fields('EV__idCause'); // Set up virtual field value\n\t\t} else {\n\t\t\t$this->idCause->VirtualValue = \"\"; // Clear value\n\t\t}\n\t\t$this->potentialCauses->setDbValue($row['potentialCauses']);\n\t\t$this->currentPreventiveControlMethod->setDbValue($row['currentPreventiveControlMethod']);\n\t\t$this->severity->setDbValue($row['severity']);\n\t\t$this->occurrence->setDbValue($row['occurrence']);\n\t\t$this->currentControlMethod->setDbValue($row['currentControlMethod']);\n\t\t$this->detection->setDbValue($row['detection']);\n\t\t$this->RPNCalc->setDbValue($row['RPNCalc']);\n\t\t$this->rpn->setDbValue($row['rpn']);\n\t\t$this->recomendedAction->setDbValue($row['recomendedAction']);\n\t\t$this->idResponsible->setDbValue($row['idResponsible']);\n\t\tif (array_key_exists('EV__idResponsible', $rs->fields)) {\n\t\t\t$this->idResponsible->VirtualValue = $rs->fields('EV__idResponsible'); // Set up virtual field value\n\t\t} else {\n\t\t\t$this->idResponsible->VirtualValue = \"\"; // Clear value\n\t\t}\n\t\t$this->targetDate->setDbValue($row['targetDate']);\n\t\t$this->revisedKc->setDbValue($row['revisedKc']);\n\t\t$this->expectedSeverity->setDbValue($row['expectedSeverity']);\n\t\t$this->expectedOccurrence->setDbValue($row['expectedOccurrence']);\n\t\t$this->expectedDetection->setDbValue($row['expectedDetection']);\n\t\t$this->expectedRpn->setDbValue($row['expectedRpn']);\n\t\t$this->expectedRPNPAO->setDbValue($row['expectedRPNPAO']);\n\t\t$this->expectedClosureDate->setDbValue($row['expectedClosureDate']);\n\t\t$this->recomendedActiondet->setDbValue($row['recomendedActiondet']);\n\t\t$this->idResponsibleDet->setDbValue($row['idResponsibleDet']);\n\t\tif (array_key_exists('EV__idResponsibleDet', $rs->fields)) {\n\t\t\t$this->idResponsibleDet->VirtualValue = $rs->fields('EV__idResponsibleDet'); // Set up virtual field value\n\t\t} else {\n\t\t\t$this->idResponsibleDet->VirtualValue = \"\"; // Clear value\n\t\t}\n\t\t$this->targetDatedet->setDbValue($row['targetDatedet']);\n\t\t$this->kcdet->setDbValue($row['kcdet']);\n\t\t$this->expectedSeveritydet->setDbValue($row['expectedSeveritydet']);\n\t\t$this->expectedOccurrencedet->setDbValue($row['expectedOccurrencedet']);\n\t\t$this->expectedDetectiondet->setDbValue($row['expectedDetectiondet']);\n\t\t$this->expectedRpndet->setDbValue($row['expectedRpndet']);\n\t\t$this->expectedRPNPAD->setDbValue($row['expectedRPNPAD']);\n\t\t$this->revisedClosureDatedet->setDbValue($row['revisedClosureDatedet']);\n\t\t$this->revisedClosureDate->setDbValue($row['revisedClosureDate']);\n\t\t$this->perfomedAction->setDbValue($row['perfomedAction']);\n\t\t$this->revisedSeverity->setDbValue($row['revisedSeverity']);\n\t\t$this->revisedOccurrence->setDbValue($row['revisedOccurrence']);\n\t\t$this->revisedDetection->setDbValue($row['revisedDetection']);\n\t\t$this->revisedRpn->setDbValue($row['revisedRpn']);\n\t\t$this->revisedRPNCalc->setDbValue($row['revisedRPNCalc']);\n\t}", "title": "" }, { "docid": "2df78cb7f09ec14db1f1b7a0521f5192", "score": "0.6582656", "text": "function LoadListRowValues(&$rs) {\n\t\t$this->dept_id->setDbValue($rs->fields('dept_id'));\n\t\t$this->dept_name->setDbValue($rs->fields('dept_name'));\n\t\t$this->dept_active->setDbValue($rs->fields('dept_active'));\n\t\t$this->dept_faculty->setDbValue($rs->fields('dept_faculty'));\n\t\t$this->dept_target->setDbValue($rs->fields('dept_target'));\n\t\t$this->dept_knowleadge->setDbValue($rs->fields('dept_knowleadge'));\n\t\t$this->dept_behavior->setDbValue($rs->fields('dept_behavior'));\n\t\t$this->dept_out_standard->setDbValue($rs->fields('dept_out_standard'));\n\t\t$this->dept_contact->setDbValue($rs->fields('dept_contact'));\n\t\t$this->dept_in_standart->setDbValue($rs->fields('dept_in_standart'));\n\t\t$this->dept_language->setDbValue($rs->fields('dept_language'));\n\t\t$this->dept_credits->setDbValue($rs->fields('dept_credits'));\n\t\t$this->dept_code->setDbValue($rs->fields('dept_code'));\n\t\t$this->dept_link_download->setDbValue($rs->fields('dept_link_download'));\n\t\t$this->dept_skill->setDbValue($rs->fields('dept_skill'));\n\t}", "title": "" }, { "docid": "6f5f9125e9fd6f7a0017ff658470f9a1", "score": "0.65711474", "text": "public function loadListRowValues(&$rs)\n\t{\n\t\t$this->ValuationNo->setDbValue($rs->fields('ValuationNo'));\n\t\t$this->PropertyNo->setDbValue($rs->fields('PropertyNo'));\n\t\t$this->StandNo->setDbValue($rs->fields('StandNo'));\n\t\t$this->ClientID->setDbValue($rs->fields('ClientID'));\n\t\t$this->PropertyGroup->setDbValue($rs->fields('PropertyGroup'));\n\t\t$this->PropertyType->setDbValue($rs->fields('PropertyType'));\n\t\t$this->Location->setDbValue($rs->fields('Location'));\n\t\t$this->RollStatus->setDbValue($rs->fields('RollStatus'));\n\t\t$this->UseCode->setDbValue($rs->fields('UseCode'));\n\t\t$this->AreaOfLand->setDbValue($rs->fields('AreaOfLand'));\n\t\t$this->AreaCode->setDbValue($rs->fields('AreaCode'));\n\t\t$this->SiteNumber->setDbValue($rs->fields('SiteNumber'));\n\t\t$this->RateableValue->setDbValue($rs->fields('RateableValue'));\n\t\t$this->NewRateableValue->setDbValue($rs->fields('NewRateableValue'));\n\t\t$this->ExemptCode->setDbValue($rs->fields('ExemptCode'));\n\t\t$this->Improvements->setDbValue($rs->fields('Improvements'));\n\t\t$this->NewImprovements->setDbValue($rs->fields('NewImprovements'));\n\t\t$this->Longitude->setDbValue($rs->fields('Longitude'));\n\t\t$this->Latitude->setDbValue($rs->fields('Latitude'));\n\t\t$this->PropertyPhoto->Upload->DbValue = $rs->fields('PropertyPhoto');\n\t\t$this->DateEvaluated->setDbValue($rs->fields('DateEvaluated'));\n\t\t$this->Objections->setDbValue($rs->fields('Objections'));\n\t\t$this->DateEntered->setDbValue($rs->fields('DateEntered'));\n\t\t$this->LastUpdatedBy->setDbValue($rs->fields('LastUpdatedBy'));\n\t\t$this->LastUpdateDate->setDbValue($rs->fields('LastUpdateDate'));\n\t}", "title": "" }, { "docid": "e7826ad792e003f84182ad214a83f4cb", "score": "0.6564678", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->hotel_id->DbValue = $row['hotel_id'];\n\t\t$this->h_name->DbValue = $row['h_name'];\n\t\t$this->h_slug->DbValue = $row['h_slug'];\n\t\t$this->h_feature_image->Upload->DbValue = $row['h_feature_image'];\n\t\t$this->h_description->DbValue = $row['h_description'];\n\t\t$this->h_meta_key->DbValue = $row['h_meta_key'];\n\t\t$this->h_deatail->DbValue = $row['h_deatail'];\n\t\t$this->h_facilities->DbValue = $row['h_facilities'];\n\t\t$this->h_address->DbValue = $row['h_address'];\n\t\t$this->h_create->DbValue = $row['h_create'];\n\t\t$this->dest_id->DbValue = $row['dest_id'];\n\t\t$this->province->DbValue = $row['province'];\n\t\t$this->whylike->DbValue = $row['whylike'];\n\t\t$this->lang_spoken->DbValue = $row['lang_spoken'];\n\t\t$this->map->DbValue = $row['map'];\n\t\t$this->what_todo->DbValue = $row['what_todo'];\n\t\t$this->h_id_cod->DbValue = $row['h_id_cod'];\n\t\t$this->h_email->DbValue = $row['h_email'];\n\t\t$this->h_contact_name->DbValue = $row['h_contact_name'];\n\t\t$this->h_pass->DbValue = $row['h_pass'];\n\t\t$this->h_contact_phone->DbValue = $row['h_contact_phone'];\n\t\t$this->h_site->DbValue = $row['h_site'];\n\t\t$this->contact_fax->DbValue = $row['contact_fax'];\n\t\t$this->star_rating->DbValue = $row['star_rating'];\n\t\t$this->create_date->DbValue = $row['create_date'];\n\t\t$this->update_date->DbValue = $row['update_date'];\n\t\t$this->h_online_status->DbValue = $row['h_online_status'];\n\t\t$this->hotel_blocked->DbValue = $row['hotel_blocked'];\n\t}", "title": "" }, { "docid": "363fd51b04e52c7ba87c66feb1a61ce7", "score": "0.65573907", "text": "function LoadListRowValues(&$rs) {\n\t\t$this->tanggal->setDbValue($rs->fields('tanggal'));\n\t\t$this->periode->setDbValue($rs->fields('periode'));\n\t\t$this->id->setDbValue($rs->fields('id'));\n\t\t$this->nomor->setDbValue($rs->fields('nomor'));\n\t\t$this->transaksi->setDbValue($rs->fields('transaksi'));\n\t\t$this->referensi->setDbValue($rs->fields('referensi'));\n\t\t$this->group->setDbValue($rs->fields('group'));\n\t\t$this->rekening->setDbValue($rs->fields('rekening'));\n\t\t$this->tipe->setDbValue($rs->fields('tipe'));\n\t\t$this->posisi->setDbValue($rs->fields('posisi'));\n\t\t$this->laporan->setDbValue($rs->fields('laporan'));\n\t\t$this->keterangan->setDbValue($rs->fields('keterangan'));\n\t\t$this->debet1->setDbValue($rs->fields('debet1'));\n\t\t$this->credit1->setDbValue($rs->fields('credit1'));\n\t\t$this->saldo1->setDbValue($rs->fields('saldo1'));\n\t\t$this->debet2->setDbValue($rs->fields('debet2'));\n\t\t$this->credit2->setDbValue($rs->fields('credit2'));\n\t\t$this->saldo2->setDbValue($rs->fields('saldo2'));\n\t\t$this->debet3->setDbValue($rs->fields('debet3'));\n\t\t$this->credit3->setDbValue($rs->fields('credit3'));\n\t\t$this->saldo3->setDbValue($rs->fields('saldo3'));\n\t\t$this->debet4->setDbValue($rs->fields('debet4'));\n\t\t$this->credit4->setDbValue($rs->fields('credit4'));\n\t\t$this->saldo4->setDbValue($rs->fields('saldo4'));\n\t\t$this->debet5->setDbValue($rs->fields('debet5'));\n\t\t$this->credit5->setDbValue($rs->fields('credit5'));\n\t\t$this->saldo5->setDbValue($rs->fields('saldo5'));\n\t\t$this->debet6->setDbValue($rs->fields('debet6'));\n\t\t$this->credit6->setDbValue($rs->fields('credit6'));\n\t\t$this->saldo6->setDbValue($rs->fields('saldo6'));\n\t\t$this->debet7->setDbValue($rs->fields('debet7'));\n\t\t$this->credit7->setDbValue($rs->fields('credit7'));\n\t\t$this->saldo7->setDbValue($rs->fields('saldo7'));\n\t\t$this->debet8->setDbValue($rs->fields('debet8'));\n\t\t$this->credit8->setDbValue($rs->fields('credit8'));\n\t\t$this->saldo8->setDbValue($rs->fields('saldo8'));\n\t\t$this->debet9->setDbValue($rs->fields('debet9'));\n\t\t$this->credit9->setDbValue($rs->fields('credit9'));\n\t\t$this->saldo9->setDbValue($rs->fields('saldo9'));\n\t\t$this->debet10->setDbValue($rs->fields('debet10'));\n\t\t$this->credit10->setDbValue($rs->fields('credit10'));\n\t\t$this->saldo10->setDbValue($rs->fields('saldo10'));\n\t\t$this->debet11->setDbValue($rs->fields('debet11'));\n\t\t$this->credit11->setDbValue($rs->fields('credit11'));\n\t\t$this->saldo11->setDbValue($rs->fields('saldo11'));\n\t\t$this->debet12->setDbValue($rs->fields('debet12'));\n\t\t$this->credit12->setDbValue($rs->fields('credit12'));\n\t\t$this->saldo12->setDbValue($rs->fields('saldo12'));\n\t}", "title": "" }, { "docid": "2672babd4c4eacf9d27869f5cb9fc017", "score": "0.6556552", "text": "function LoadRowValues(&$rs) {\r\n\t\tglobal $conn, $master_siswa;\r\n\t\tif (!$rs || $rs->EOF) return;\r\n\r\n\t\t// Call Row Selected event\r\n\t\t$row =& $rs->fields;\r\n\t\t$master_siswa->Row_Selected($row);\r\n\t\t$master_siswa->no_absen->setDbValue($rs->fields('no_absen'));\r\n\t\t$master_siswa->A_nis_nasional->setDbValue($rs->fields('A_nis_nasional'));\r\n\t\t$master_siswa->A_nama_Lengkap->setDbValue($rs->fields('A_nama_Lengkap'));\r\n\t\t$master_siswa->A_nama_panggilan->setDbValue($rs->fields('A_nama_panggilan'));\r\n\t\t$master_siswa->A_jenis_kelamin->setDbValue($rs->fields('A_jenis_kelamin'));\r\n\t\t$master_siswa->A_tempat_lahir->setDbValue($rs->fields('A_tempat_lahir'));\r\n\t\t$master_siswa->A_tanggal_lahir->setDbValue($rs->fields('A_tanggal_lahir'));\r\n\t\t$master_siswa->A_agama->setDbValue($rs->fields('A_agama'));\r\n\t\t$master_siswa->A_kewarganegaraan->setDbValue($rs->fields('A_kewarganegaraan'));\r\n\t\t$master_siswa->A_anak_keberapa->setDbValue($rs->fields('A_anak_keberapa'));\r\n\t\t$master_siswa->A_jumlah_saudara_kandung->setDbValue($rs->fields('A_jumlah_saudara_kandung'));\r\n\t\t$master_siswa->A_jumlah_saudara_tiri->setDbValue($rs->fields('A_jumlah_saudara_tiri'));\r\n\t\t$master_siswa->A_jumlah_saudara_angkat->setDbValue($rs->fields('A_jumlah_saudara_angkat'));\r\n\t\t$master_siswa->A_status_yatim->setDbValue($rs->fields('A_status_yatim'));\r\n\t\t$master_siswa->A_bahasa->setDbValue($rs->fields('A_bahasa'));\r\n\t\t$master_siswa->B_alamat->setDbValue($rs->fields('B_alamat'));\r\n\t\t$master_siswa->B_telepon_rumah->setDbValue($rs->fields('B_telepon_rumah'));\r\n\t\t$master_siswa->B_tinggal->setDbValue($rs->fields('B_tinggal'));\r\n\t\t$master_siswa->B_jarak->setDbValue($rs->fields('B_jarak'));\r\n\t\t$master_siswa->B_hp->setDbValue($rs->fields('B_hp'));\r\n\t\t$master_siswa->C_golongan_darah->setDbValue($rs->fields('C_golongan_darah'));\r\n\t\t$master_siswa->C_penyakit->setDbValue($rs->fields('C_penyakit'));\r\n\t\t$master_siswa->C_jasmani->setDbValue($rs->fields('C_jasmani'));\r\n\t\t$master_siswa->C_tinggi->setDbValue($rs->fields('C_tinggi'));\r\n\t\t$master_siswa->C_berat->setDbValue($rs->fields('C_berat'));\r\n\t\t$master_siswa->D_tamatan_dari->setDbValue($rs->fields('D_tamatan_dari'));\r\n\t\t$master_siswa->D_sttb->setDbValue($rs->fields('D_sttb'));\r\n\t\t$master_siswa->D_tanggal_sttb->setDbValue($rs->fields('D_tanggal_sttb'));\r\n\t\t$master_siswa->D_danum->setDbValue($rs->fields('D_danum'));\r\n\t\t$master_siswa->D_tanggal_danum->setDbValue($rs->fields('D_tanggal_danum'));\r\n\t\t$master_siswa->D_lama_belajar->setDbValue($rs->fields('D_lama_belajar'));\r\n\t\t$master_siswa->D_dari_sekolah->setDbValue($rs->fields('D_dari_sekolah'));\r\n\t\t$master_siswa->D_alasan->setDbValue($rs->fields('D_alasan'));\r\n\t\t$master_siswa->D_kelas->setDbValue($rs->fields('D_kelas'));\r\n\t\t$master_siswa->D_kelompok->setDbValue($rs->fields('D_kelompok'));\r\n\t\t$master_siswa->D_tanggal->setDbValue($rs->fields('D_tanggal'));\r\n\t\t$master_siswa->D_saat_ini_tingkat->setDbValue($rs->fields('D_saat_ini_tingkat'));\r\n\t\t$master_siswa->D_saat_ini_kelas->setDbValue($rs->fields('D_saat_ini_kelas'));\r\n\t\t$master_siswa->D_saat_ini_kelompok->setDbValue($rs->fields('D_saat_ini_kelompok'));\r\n\t\t$master_siswa->D_no_psb->setDbValue($rs->fields('D_no_psb'));\r\n\t\t$master_siswa->D_nilai_danum_sd->setDbValue($rs->fields('D_nilai_danum_sd'));\r\n\t\t$master_siswa->D_jumlah_pelajaran_danum->setDbValue($rs->fields('D_jumlah_pelajaran_danum'));\r\n\t\t$master_siswa->D_nilai_ujian_psb->setDbValue($rs->fields('D_nilai_ujian_psb'));\r\n\t\t$master_siswa->D_tahun_psb->setDbValue($rs->fields('D_tahun_psb'));\r\n\t\t$master_siswa->D_diterima->setDbValue($rs->fields('D_diterima'));\r\n\t\t$master_siswa->D_spp->setDbValue($rs->fields('D_spp'));\r\n\t\t$master_siswa->D_spp_potongan->setDbValue($rs->fields('D_spp_potongan'));\r\n\t\t$master_siswa->D_status_lama_baru->setDbValue($rs->fields('D_status_lama_baru'));\r\n\t\t$master_siswa->E_nama_ayah->setDbValue($rs->fields('E_nama_ayah'));\r\n\t\t$master_siswa->E_tempat_lahir->setDbValue($rs->fields('E_tempat_lahir'));\r\n\t\t$master_siswa->E_tanggal_lahir->setDbValue($rs->fields('E_tanggal_lahir'));\r\n\t\t$master_siswa->E_agama->setDbValue($rs->fields('E_agama'));\r\n\t\t$master_siswa->E_kewarganegaraan->setDbValue($rs->fields('E_kewarganegaraan'));\r\n\t\t$master_siswa->E_pendidikan->setDbValue($rs->fields('E_pendidikan'));\r\n\t\t$master_siswa->E_pekerjaan->setDbValue($rs->fields('E_pekerjaan'));\r\n\t\t$master_siswa->E_pengeluaran->setDbValue($rs->fields('E_pengeluaran'));\r\n\t\t$master_siswa->E_alamat->setDbValue($rs->fields('E_alamat'));\r\n\t\t$master_siswa->E_telepon->setDbValue($rs->fields('E_telepon'));\r\n\t\t$master_siswa->E_hp->setDbValue($rs->fields('E_hp'));\r\n\t\t$master_siswa->E_hidup->setDbValue($rs->fields('E_hidup'));\r\n\t\t$master_siswa->F_nama_ibu->setDbValue($rs->fields('F_nama_ibu'));\r\n\t\t$master_siswa->F_tempat_lahir->setDbValue($rs->fields('F_tempat_lahir'));\r\n\t\t$master_siswa->F_tanggal_lahir->setDbValue($rs->fields('F_tanggal_lahir'));\r\n\t\t$master_siswa->F_agama->setDbValue($rs->fields('F_agama'));\r\n\t\t$master_siswa->F_kewarganegaraan->setDbValue($rs->fields('F_kewarganegaraan'));\r\n\t\t$master_siswa->F_pendidikan->setDbValue($rs->fields('F_pendidikan'));\r\n\t\t$master_siswa->F_pekerjaan->setDbValue($rs->fields('F_pekerjaan'));\r\n\t\t$master_siswa->F_pengeluaran->setDbValue($rs->fields('F_pengeluaran'));\r\n\t\t$master_siswa->F_alamat->setDbValue($rs->fields('F_alamat'));\r\n\t\t$master_siswa->F_telepon->setDbValue($rs->fields('F_telepon'));\r\n\t\t$master_siswa->F_hp->setDbValue($rs->fields('F_hp'));\r\n\t\t$master_siswa->F_hidup->setDbValue($rs->fields('F_hidup'));\r\n\t\t$master_siswa->G_nama_wali->setDbValue($rs->fields('G_nama_wali'));\r\n\t\t$master_siswa->G_tempat_lahir->setDbValue($rs->fields('G_tempat_lahir'));\r\n\t\t$master_siswa->G_tanggal_lahir->setDbValue($rs->fields('G_tanggal_lahir'));\r\n\t\t$master_siswa->G_agama->setDbValue($rs->fields('G_agama'));\r\n\t\t$master_siswa->G_kewarganegaraan->setDbValue($rs->fields('G_kewarganegaraan'));\r\n\t\t$master_siswa->G_pendidikan->setDbValue($rs->fields('G_pendidikan'));\r\n\t\t$master_siswa->G_pekerjaan->setDbValue($rs->fields('G_pekerjaan'));\r\n\t\t$master_siswa->G_pengeluaran->setDbValue($rs->fields('G_pengeluaran'));\r\n\t\t$master_siswa->G_alamat->setDbValue($rs->fields('G_alamat'));\r\n\t\t$master_siswa->G_telepon->setDbValue($rs->fields('G_telepon'));\r\n\t\t$master_siswa->G_hp->setDbValue($rs->fields('G_hp'));\r\n\t\t$master_siswa->H_kesenian->setDbValue($rs->fields('H_kesenian'));\r\n\t\t$master_siswa->H_olahraga->setDbValue($rs->fields('H_olahraga'));\r\n\t\t$master_siswa->H_kemasyarakatan->setDbValue($rs->fields('H_kemasyarakatan'));\r\n\t\t$master_siswa->H_lainlain->setDbValue($rs->fields('H_lainlain'));\r\n\t\t$master_siswa->I_tanggal_meninggalkan->setDbValue($rs->fields('I_tanggal_meninggalkan'));\r\n\t\t$master_siswa->I_alasan->setDbValue($rs->fields('I_alasan'));\r\n\t\t$master_siswa->I_tanggal_lulus->setDbValue($rs->fields('I_tanggal_lulus'));\r\n\t\t$master_siswa->I_sttb->setDbValue($rs->fields('I_sttb'));\r\n\t\t$master_siswa->I_danum->setDbValue($rs->fields('I_danum'));\r\n\t\t$master_siswa->I_nilai_danum_smp->setDbValue($rs->fields('I_nilai_danum_smp'));\r\n\t\t$master_siswa->I_tahun1->setDbValue($rs->fields('I_tahun1'));\r\n\t\t$master_siswa->I_tahun2->setDbValue($rs->fields('I_tahun2'));\r\n\t\t$master_siswa->I_tahun3->setDbValue($rs->fields('I_tahun3'));\r\n\t\t$master_siswa->I_tk1->setDbValue($rs->fields('I_tk1'));\r\n\t\t$master_siswa->I_tk2->setDbValue($rs->fields('I_tk2'));\r\n\t\t$master_siswa->I_tk3->setDbValue($rs->fields('I_tk3'));\r\n\t\t$master_siswa->I_dari1->setDbValue($rs->fields('I_dari1'));\r\n\t\t$master_siswa->I_dari2->setDbValue($rs->fields('I_dari2'));\r\n\t\t$master_siswa->I_dari3->setDbValue($rs->fields('I_dari3'));\r\n\t\t$master_siswa->J_melanjutkan->setDbValue($rs->fields('J_melanjutkan'));\r\n\t\t$master_siswa->J_tanggal_bekerja->setDbValue($rs->fields('J_tanggal_bekerja'));\r\n\t\t$master_siswa->J_nama_perusahaan->setDbValue($rs->fields('J_nama_perusahaan'));\r\n\t\t$master_siswa->J_penghasilan->setDbValue($rs->fields('J_penghasilan'));\r\n\t\t$master_siswa->kode_otomatis->setDbValue($rs->fields('kode_otomatis'));\r\n\t\t$master_siswa->apakah_valid->setDbValue($rs->fields('apakah_valid'));\r\n\t}", "title": "" }, { "docid": "9e7dcc8e7e4260fda0e89051d764b019", "score": "0.6545109", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->nombre_estado_interno->DbValue = $row['nombre_estado_interno'];\n\t\t$this->para_factura_estado_interno->DbValue = $row['para_factura_estado_interno'];\n\t\t$this->se_paga_comision_estado_interno->DbValue = $row['se_paga_comision_estado_interno'];\n\t\t$this->porcen_comision_estado_interno->DbValue = $row['porcen_comision_estado_interno'];\n\t\t$this->se_paga_bono_estado_interno->DbValue = $row['se_paga_bono_estado_interno'];\n\t\t$this->porcen_bono_estado_interno->DbValue = $row['porcen_bono_estado_interno'];\n\t\t$this->obs_estado_interno->DbValue = $row['obs_estado_interno'];\n\t\t$this->envio_boffice_estado_interno->DbValue = $row['envio_boffice_estado_interno'];\n\t\t$this->empresa_estado_interno->DbValue = $row['empresa_estado_interno'];\n\t\t$this->id_estado_interno->DbValue = $row['id_estado_interno'];\n\t}", "title": "" }, { "docid": "34e185cc0a9e40eb695231228b7b5130", "score": "0.65186274", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->id->DbValue = $row['id'];\n\t\t$this->id_jenis_spp->DbValue = $row['id_jenis_spp'];\n\t\t$this->detail_jenis_spp->DbValue = $row['detail_jenis_spp'];\n\t\t$this->status_spp->DbValue = $row['status_spp'];\n\t\t$this->no_spp->DbValue = $row['no_spp'];\n\t\t$this->tgl_spp->DbValue = $row['tgl_spp'];\n\t\t$this->nama_pptk->DbValue = $row['nama_pptk'];\n\t\t$this->nip_pptk->DbValue = $row['nip_pptk'];\n\t\t$this->keterangan->DbValue = $row['keterangan'];\n\t\t$this->pph21->DbValue = $row['pph21'];\n\t\t$this->pph22->DbValue = $row['pph22'];\n\t\t$this->pph23->DbValue = $row['pph23'];\n\t\t$this->pph4->DbValue = $row['pph4'];\n\t\t$this->nama_bendahara->DbValue = $row['nama_bendahara'];\n\t\t$this->nip_bendahara->DbValue = $row['nip_bendahara'];\n\t\t$this->kode_program->DbValue = $row['kode_program'];\n\t\t$this->kode_kegiatan->DbValue = $row['kode_kegiatan'];\n\t\t$this->kode_sub_kegiatan->DbValue = $row['kode_sub_kegiatan'];\n\t\t$this->jumlah_belanja->DbValue = $row['jumlah_belanja'];\n\t\t$this->kontrak_id->DbValue = $row['kontrak_id'];\n\t\t$this->kode_rekening->DbValue = $row['kode_rekening'];\n\t\t$this->akun1->DbValue = $row['akun1'];\n\t\t$this->akun2->DbValue = $row['akun2'];\n\t\t$this->akun3->DbValue = $row['akun3'];\n\t\t$this->akun4->DbValue = $row['akun4'];\n\t\t$this->akun5->DbValue = $row['akun5'];\n\t}", "title": "" }, { "docid": "403ec2a85d55a147d0be6be8ede4cef8", "score": "0.65098685", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF)\n\t\t\treturn;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->id->DbValue = $row['id'];\n\t\t$this->id_actividad->DbValue = $row['id_actividad'];\n\t\t$this->apellidopaterno->DbValue = $row['apellidopaterno'];\n\t\t$this->apellidomaterno->DbValue = $row['apellidomaterno'];\n\t\t$this->nombre->DbValue = $row['nombre'];\n\t\t$this->nrodiscapacidad->DbValue = $row['nrodiscapacidad'];\n\t\t$this->ci->DbValue = $row['ci'];\n\t\t$this->fecha_nacimiento->DbValue = $row['fecha_nacimiento'];\n\t\t$this->sexo->DbValue = $row['sexo'];\n\t\t$this->nivelestudio->DbValue = $row['nivelestudio'];\n\t\t$this->id_discapacidad->DbValue = $row['id_discapacidad'];\n\t\t$this->id_tipodiscapacidad->DbValue = $row['id_tipodiscapacidad'];\n\t\t$this->resultado->DbValue = $row['resultado'];\n\t\t$this->resultadotamizaje->DbValue = $row['resultadotamizaje'];\n\t\t$this->tapon->DbValue = $row['tapon'];\n\t\t$this->tipo->DbValue = $row['tipo'];\n\t\t$this->repetirprueba->DbValue = $row['repetirprueba'];\n\t\t$this->observaciones->DbValue = $row['observaciones'];\n\t\t$this->id_apoderado->DbValue = $row['id_apoderado'];\n\t\t$this->id_referencia->DbValue = $row['id_referencia'];\n\t\t$this->id_centro->DbValue = $row['id_centro'];\n\t}", "title": "" }, { "docid": "93d17001f01053a962a0cf26da8403b4", "score": "0.65048325", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->jk_id->DbValue = $row['jk_id'];\n\t\t$this->jk_name->DbValue = $row['jk_name'];\n\t\t$this->jk_kode->DbValue = $row['jk_kode'];\n\t\t$this->use_set->DbValue = $row['use_set'];\n\t\t$this->jk_bcin->DbValue = $row['jk_bcin'];\n\t\t$this->jk_cin->DbValue = $row['jk_cin'];\n\t\t$this->jk_ecin->DbValue = $row['jk_ecin'];\n\t\t$this->jk_tol_late->DbValue = $row['jk_tol_late'];\n\t\t$this->jk_use_ist->DbValue = $row['jk_use_ist'];\n\t\t$this->jk_ist1->DbValue = $row['jk_ist1'];\n\t\t$this->jk_ist2->DbValue = $row['jk_ist2'];\n\t\t$this->jk_tol_early->DbValue = $row['jk_tol_early'];\n\t\t$this->jk_bcout->DbValue = $row['jk_bcout'];\n\t\t$this->jk_cout->DbValue = $row['jk_cout'];\n\t\t$this->jk_ecout->DbValue = $row['jk_ecout'];\n\t\t$this->use_eot->DbValue = $row['use_eot'];\n\t\t$this->min_eot->DbValue = $row['min_eot'];\n\t\t$this->max_eot->DbValue = $row['max_eot'];\n\t\t$this->reduce_eot->DbValue = $row['reduce_eot'];\n\t\t$this->jk_durasi->DbValue = $row['jk_durasi'];\n\t\t$this->jk_countas->DbValue = $row['jk_countas'];\n\t\t$this->jk_min_countas->DbValue = $row['jk_min_countas'];\n\t\t$this->jk_ket->DbValue = $row['jk_ket'];\n\t}", "title": "" }, { "docid": "cc95d363d96ec369a073773b5d0e747e", "score": "0.6488938", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->personID->DbValue = $row['personID'];\n\t\t$this->personName->DbValue = $row['personName'];\n\t\t$this->lastName->DbValue = $row['lastName'];\n\t\t$this->nationalID->DbValue = $row['nationalID'];\n\t\t$this->mobilePhone->DbValue = $row['mobilePhone'];\n\t\t$this->nationalNumber->DbValue = $row['nationalNumber'];\n\t\t$this->passportNumber->DbValue = $row['passportNumber'];\n\t\t$this->fatherName->DbValue = $row['fatherName'];\n\t\t$this->gender->DbValue = $row['gender'];\n\t\t$this->locationLevel1->DbValue = $row['locationLevel1'];\n\t\t$this->locationLevel2->DbValue = $row['locationLevel2'];\n\t\t$this->locationLevel3->DbValue = $row['locationLevel3'];\n\t\t$this->locationLevel4->DbValue = $row['locationLevel4'];\n\t\t$this->locationLevel5->DbValue = $row['locationLevel5'];\n\t\t$this->locationLevel6->DbValue = $row['locationLevel6'];\n\t\t$this->address->DbValue = $row['address'];\n\t\t$this->convoy->DbValue = $row['convoy'];\n\t\t$this->convoyManager->DbValue = $row['convoyManager'];\n\t\t$this->followersName->DbValue = $row['followersName'];\n\t\t$this->status->DbValue = $row['status'];\n\t\t$this->isolatedLocation->DbValue = $row['isolatedLocation'];\n\t\t$this->birthDate->DbValue = $row['birthDate'];\n\t\t$this->ageRange->DbValue = $row['ageRange'];\n\t\t$this->dress1->DbValue = $row['dress1'];\n\t\t$this->dress2->DbValue = $row['dress2'];\n\t\t$this->signTags->DbValue = $row['signTags'];\n\t\t$this->phone->DbValue = $row['phone'];\n\t\t$this->_email->DbValue = $row['email'];\n\t\t$this->temporaryResidence->DbValue = $row['temporaryResidence'];\n\t\t$this->visitsCount->DbValue = $row['visitsCount'];\n\t\t$this->picture->Upload->DbValue = $row['picture'];\n\t\t$this->registrationUser->DbValue = $row['registrationUser'];\n\t\t$this->registrationDateTime->DbValue = $row['registrationDateTime'];\n\t\t$this->registrationStation->DbValue = $row['registrationStation'];\n\t\t$this->isolatedDateTime->DbValue = $row['isolatedDateTime'];\n\t\t$this->description->DbValue = $row['description'];\n\t}", "title": "" }, { "docid": "56683084607e5e1d7a200640adb37585", "score": "0.6483405", "text": "function LoadRowValues(&$rs) {\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row = &$rs->fields;\n\t\t$this->Row_Selected($row);\n\t\t$this->Id->setDbValue($rs->fields('Id'));\n\t\t$this->CI_RUN->setDbValue($rs->fields('CI_RUN'));\n\t\t$this->Expedido->setDbValue($rs->fields('Expedido'));\n\t\t$this->Apellido_Paterno->setDbValue($rs->fields('Apellido_Paterno'));\n\t\t$this->Apellido_Materno->setDbValue($rs->fields('Apellido_Materno'));\n\t\t$this->Nombres->setDbValue($rs->fields('Nombres'));\n\t\t$this->Fecha_Nacimiento->setDbValue($rs->fields('Fecha_Nacimiento'));\n\t\t$this->Estado_Civil->setDbValue($rs->fields('Estado_Civil'));\n\t\t$this->Direccion->setDbValue($rs->fields('Direccion'));\n\t\t$this->Telefono->setDbValue($rs->fields('Telefono'));\n\t\t$this->Celular->setDbValue($rs->fields('Celular'));\n\t\t$this->Fiscalia_otro->setDbValue($rs->fields('Fiscalia_otro'));\n\t\tif (array_key_exists('EV__Fiscalia_otro', $rs->fields)) {\n\t\t\t$this->Fiscalia_otro->VirtualValue = $rs->fields('EV__Fiscalia_otro'); // Set up virtual field value\n\t\t} else {\n\t\t\t$this->Fiscalia_otro->VirtualValue = \"\"; // Clear value\n\t\t}\n\t\t$this->Unidad_Organizacional->setDbValue($rs->fields('Unidad_Organizacional'));\n\t\t$this->Unidad->setDbValue($rs->fields('Unidad'));\n\t\t$this->Cargo->setDbValue($rs->fields('Cargo'));\n\t\t$this->Fecha_registro->setDbValue($rs->fields('Fecha_registro'));\n\t}", "title": "" }, { "docid": "fd6e1eef344d281a233a05ce7ff55ff9", "score": "0.645587", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->tanggal->DbValue = $row['tanggal'];\n\t\t$this->periode->DbValue = $row['periode'];\n\t\t$this->id->DbValue = $row['id'];\n\t\t$this->nomor->DbValue = $row['nomor'];\n\t\t$this->transaksi->DbValue = $row['transaksi'];\n\t\t$this->referensi->DbValue = $row['referensi'];\n\t\t$this->group->DbValue = $row['group'];\n\t\t$this->rekening->DbValue = $row['rekening'];\n\t\t$this->tipe->DbValue = $row['tipe'];\n\t\t$this->posisi->DbValue = $row['posisi'];\n\t\t$this->laporan->DbValue = $row['laporan'];\n\t\t$this->keterangan->DbValue = $row['keterangan'];\n\t\t$this->debet1->DbValue = $row['debet1'];\n\t\t$this->credit1->DbValue = $row['credit1'];\n\t\t$this->saldo1->DbValue = $row['saldo1'];\n\t\t$this->debet2->DbValue = $row['debet2'];\n\t\t$this->credit2->DbValue = $row['credit2'];\n\t\t$this->saldo2->DbValue = $row['saldo2'];\n\t\t$this->debet3->DbValue = $row['debet3'];\n\t\t$this->credit3->DbValue = $row['credit3'];\n\t\t$this->saldo3->DbValue = $row['saldo3'];\n\t\t$this->debet4->DbValue = $row['debet4'];\n\t\t$this->credit4->DbValue = $row['credit4'];\n\t\t$this->saldo4->DbValue = $row['saldo4'];\n\t\t$this->debet5->DbValue = $row['debet5'];\n\t\t$this->credit5->DbValue = $row['credit5'];\n\t\t$this->saldo5->DbValue = $row['saldo5'];\n\t\t$this->debet6->DbValue = $row['debet6'];\n\t\t$this->credit6->DbValue = $row['credit6'];\n\t\t$this->saldo6->DbValue = $row['saldo6'];\n\t\t$this->debet7->DbValue = $row['debet7'];\n\t\t$this->credit7->DbValue = $row['credit7'];\n\t\t$this->saldo7->DbValue = $row['saldo7'];\n\t\t$this->debet8->DbValue = $row['debet8'];\n\t\t$this->credit8->DbValue = $row['credit8'];\n\t\t$this->saldo8->DbValue = $row['saldo8'];\n\t\t$this->debet9->DbValue = $row['debet9'];\n\t\t$this->credit9->DbValue = $row['credit9'];\n\t\t$this->saldo9->DbValue = $row['saldo9'];\n\t\t$this->debet10->DbValue = $row['debet10'];\n\t\t$this->credit10->DbValue = $row['credit10'];\n\t\t$this->saldo10->DbValue = $row['saldo10'];\n\t\t$this->debet11->DbValue = $row['debet11'];\n\t\t$this->credit11->DbValue = $row['credit11'];\n\t\t$this->saldo11->DbValue = $row['saldo11'];\n\t\t$this->debet12->DbValue = $row['debet12'];\n\t\t$this->credit12->DbValue = $row['credit12'];\n\t\t$this->saldo12->DbValue = $row['saldo12'];\n\t}", "title": "" }, { "docid": "62ce4076045ca4a770d0f3e3ee169ea0", "score": "0.6448259", "text": "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $frm_cutoffdate;\n\t\tif (!$rs || $rs->EOF) return;\n\n\t\t// Call Row Selected event\n\t\t$row =& $rs->fields;\n\t\t$frm_cutoffdate->Row_Selected($row);\n\t\t$frm_cutoffdate->cutOffDate_id->setDbValue($rs->fields('cutOffDate_id'));\n\t\t$frm_cutoffdate->collection_id->setDbValue($rs->fields('collection_id'));\n\t\t$frm_cutoffdate->focal_person_id->setDbValue($rs->fields('focal_person_id'));\n\t\t$frm_cutoffdate->focal_person_office->setDbValue($rs->fields('focal_person_office'));\n\t\t$frm_cutoffdate->t_cutOffDate->setDbValue($rs->fields('t_cutOffDate'));\n\t\t$frm_cutoffdate->t_cutOffDate_fp->setDbValue($rs->fields('t_cutOffDate_fp'));\n\t\t$frm_cutoffdate->t_cutOffDate_remarks->setDbValue($rs->fields('t_cutOffDate_remarks'));\n\t\t$frm_cutoffdate->a_cutOffDate->setDbValue($rs->fields('a_cutOffDate'));\n\t\t$frm_cutoffdate->a_cutOffDate_fp->setDbValue($rs->fields('a_cutOffDate_fp'));\n\t\t$frm_cutoffdate->a_cutOffDate_remarks->setDbValue($rs->fields('a_cutOffDate_remarks'));\n\t}", "title": "" }, { "docid": "b7c3e8f79dd96da836bd5ed1806bdf23", "score": "0.64295655", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->Id->DbValue = $row['Id'];\n\t\t$this->CI_RUN->DbValue = $row['CI_RUN'];\n\t\t$this->Expedido->DbValue = $row['Expedido'];\n\t\t$this->Apellido_Paterno->DbValue = $row['Apellido_Paterno'];\n\t\t$this->Apellido_Materno->DbValue = $row['Apellido_Materno'];\n\t\t$this->Nombres->DbValue = $row['Nombres'];\n\t\t$this->Fecha_Nacimiento->DbValue = $row['Fecha_Nacimiento'];\n\t\t$this->Estado_Civil->DbValue = $row['Estado_Civil'];\n\t\t$this->Direccion->DbValue = $row['Direccion'];\n\t\t$this->Telefono->DbValue = $row['Telefono'];\n\t\t$this->Celular->DbValue = $row['Celular'];\n\t\t$this->Fiscalia_otro->DbValue = $row['Fiscalia_otro'];\n\t\t$this->Unidad_Organizacional->DbValue = $row['Unidad_Organizacional'];\n\t\t$this->Unidad->DbValue = $row['Unidad'];\n\t\t$this->Cargo->DbValue = $row['Cargo'];\n\t\t$this->Fecha_registro->DbValue = $row['Fecha_registro'];\n\t}", "title": "" }, { "docid": "b7afe25747b8814bcd1449fee64259f6", "score": "0.6424876", "text": "protected function loadDbValues(&$rs)\n\t{\n\t\tif (!$rs || !is_array($rs) && $rs->EOF)\n\t\t\treturn;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->ValuationNo->DbValue = $row['ValuationNo'];\n\t\t$this->PropertyNo->DbValue = $row['PropertyNo'];\n\t\t$this->StandNo->DbValue = $row['StandNo'];\n\t\t$this->ClientID->DbValue = $row['ClientID'];\n\t\t$this->PropertyGroup->DbValue = $row['PropertyGroup'];\n\t\t$this->PropertyType->DbValue = $row['PropertyType'];\n\t\t$this->Location->DbValue = $row['Location'];\n\t\t$this->RollStatus->DbValue = $row['RollStatus'];\n\t\t$this->UseCode->DbValue = $row['UseCode'];\n\t\t$this->AreaOfLand->DbValue = $row['AreaOfLand'];\n\t\t$this->AreaCode->DbValue = $row['AreaCode'];\n\t\t$this->SiteNumber->DbValue = $row['SiteNumber'];\n\t\t$this->RateableValue->DbValue = $row['RateableValue'];\n\t\t$this->NewRateableValue->DbValue = $row['NewRateableValue'];\n\t\t$this->ExemptCode->DbValue = $row['ExemptCode'];\n\t\t$this->Improvements->DbValue = $row['Improvements'];\n\t\t$this->NewImprovements->DbValue = $row['NewImprovements'];\n\t\t$this->Longitude->DbValue = $row['Longitude'];\n\t\t$this->Latitude->DbValue = $row['Latitude'];\n\t\t$this->PropertyPhoto->Upload->DbValue = $row['PropertyPhoto'];\n\t\t$this->DateEvaluated->DbValue = $row['DateEvaluated'];\n\t\t$this->Objections->DbValue = $row['Objections'];\n\t\t$this->DateEntered->DbValue = $row['DateEntered'];\n\t\t$this->LastUpdatedBy->DbValue = $row['LastUpdatedBy'];\n\t\t$this->LastUpdateDate->DbValue = $row['LastUpdateDate'];\n\t}", "title": "" }, { "docid": "3b4f2e135f5e0e2890c5bf83270b49b1", "score": "0.6413737", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->llave->DbValue = $row['llave'];\n\t\t$this->F_Sincron->DbValue = $row['F_Sincron'];\n\t\t$this->USUARIO->DbValue = $row['USUARIO'];\n\t\t$this->Cargo_gme->DbValue = $row['Cargo_gme'];\n\t\t$this->NOM_PE->DbValue = $row['NOM_PE'];\n\t\t$this->Otro_PE->DbValue = $row['Otro_PE'];\n\t\t$this->NOM_APOYO->DbValue = $row['NOM_APOYO'];\n\t\t$this->Otro_Nom_Apoyo->DbValue = $row['Otro_Nom_Apoyo'];\n\t\t$this->Otro_CC_Apoyo->DbValue = $row['Otro_CC_Apoyo'];\n\t\t$this->NOM_ENLACE->DbValue = $row['NOM_ENLACE'];\n\t\t$this->Otro_Nom_Enlace->DbValue = $row['Otro_Nom_Enlace'];\n\t\t$this->Otro_CC_Enlace->DbValue = $row['Otro_CC_Enlace'];\n\t\t$this->NOM_PGE->DbValue = $row['NOM_PGE'];\n\t\t$this->Otro_Nom_PGE->DbValue = $row['Otro_Nom_PGE'];\n\t\t$this->Otro_CC_PGE->DbValue = $row['Otro_CC_PGE'];\n\t\t$this->Departamento->DbValue = $row['Departamento'];\n\t\t$this->Muncipio->DbValue = $row['Muncipio'];\n\t\t$this->NOM_VDA->DbValue = $row['NOM_VDA'];\n\t\t$this->LATITUD->DbValue = $row['LATITUD'];\n\t\t$this->GRA_LAT->DbValue = $row['GRA_LAT'];\n\t\t$this->MIN_LAT->DbValue = $row['MIN_LAT'];\n\t\t$this->SEG_LAT->DbValue = $row['SEG_LAT'];\n\t\t$this->GRA_LONG->DbValue = $row['GRA_LONG'];\n\t\t$this->MIN_LONG->DbValue = $row['MIN_LONG'];\n\t\t$this->SEG_LONG->DbValue = $row['SEG_LONG'];\n\t\t$this->FECHA_ACC->DbValue = $row['FECHA_ACC'];\n\t\t$this->HORA_ACC->DbValue = $row['HORA_ACC'];\n\t\t$this->Hora_ingreso->DbValue = $row['Hora_ingreso'];\n\t\t$this->FP_Armada->DbValue = $row['FP_Armada'];\n\t\t$this->FP_Ejercito->DbValue = $row['FP_Ejercito'];\n\t\t$this->FP_Policia->DbValue = $row['FP_Policia'];\n\t\t$this->NOM_COMANDANTE->DbValue = $row['NOM_COMANDANTE'];\n\t\t$this->TESTI1->DbValue = $row['TESTI1'];\n\t\t$this->CC_TESTI1->DbValue = $row['CC_TESTI1'];\n\t\t$this->CARGO_TESTI1->DbValue = $row['CARGO_TESTI1'];\n\t\t$this->TESTI2->DbValue = $row['TESTI2'];\n\t\t$this->CC_TESTI2->DbValue = $row['CC_TESTI2'];\n\t\t$this->CARGO_TESTI2->DbValue = $row['CARGO_TESTI2'];\n\t\t$this->Afectados->DbValue = $row['Afectados'];\n\t\t$this->NUM_Afectado->DbValue = $row['NUM_Afectado'];\n\t\t$this->Nom_Afectado->DbValue = $row['Nom_Afectado'];\n\t\t$this->CC_Afectado->DbValue = $row['CC_Afectado'];\n\t\t$this->Cargo_Afectado->DbValue = $row['Cargo_Afectado'];\n\t\t$this->Tipo_incidente->DbValue = $row['Tipo_incidente'];\n\t\t$this->Riesgo->DbValue = $row['Riesgo'];\n\t\t$this->Parte_Cuerpo->DbValue = $row['Parte_Cuerpo'];\n\t\t$this->ESTADO_AFEC->DbValue = $row['ESTADO_AFEC'];\n\t\t$this->EVACUADO->DbValue = $row['EVACUADO'];\n\t\t$this->DESC_ACC->DbValue = $row['DESC_ACC'];\n\t\t$this->Modificado->DbValue = $row['Modificado'];\n\t\t$this->llave_2->DbValue = $row['llave_2'];\n\t}", "title": "" }, { "docid": "d87c86e3d17b886dccf9a033ae09fe76", "score": "0.63988674", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->tanggal->DbValue = $row['tanggal'];\n\t\t$this->periode->DbValue = $row['periode'];\n\t\t$this->id->DbValue = $row['id'];\n\t\t$this->transaksi->DbValue = $row['transaksi'];\n\t\t$this->referensi->DbValue = $row['referensi'];\n\t\t$this->anggota->DbValue = $row['anggota'];\n\t\t$this->namaanggota->DbValue = $row['namaanggota'];\n\t\t$this->alamat->DbValue = $row['alamat'];\n\t\t$this->pekerjaan->DbValue = $row['pekerjaan'];\n\t\t$this->telepon->DbValue = $row['telepon'];\n\t\t$this->hp->DbValue = $row['hp'];\n\t\t$this->fax->DbValue = $row['fax'];\n\t\t$this->_email->DbValue = $row['email'];\n\t\t$this->website->DbValue = $row['website'];\n\t\t$this->jenisanggota->DbValue = $row['jenisanggota'];\n\t\t$this->model->DbValue = $row['model'];\n\t\t$this->jenispinjaman->DbValue = $row['jenispinjaman'];\n\t\t$this->jenisbunga->DbValue = $row['jenisbunga'];\n\t\t$this->angsuran->DbValue = $row['angsuran'];\n\t\t$this->masaangsuran->DbValue = $row['masaangsuran'];\n\t\t$this->jatuhtempo->DbValue = $row['jatuhtempo'];\n\t\t$this->terlambat->DbValue = $row['terlambat'];\n\t\t$this->dispensasidenda->DbValue = $row['dispensasidenda'];\n\t\t$this->plafond->DbValue = $row['plafond'];\n\t\t$this->angsuranpokok->DbValue = $row['angsuranpokok'];\n\t\t$this->angsuranpokokauto->DbValue = $row['angsuranpokokauto'];\n\t\t$this->angsuranbunga->DbValue = $row['angsuranbunga'];\n\t\t$this->angsuranbungaauto->DbValue = $row['angsuranbungaauto'];\n\t\t$this->denda->DbValue = $row['denda'];\n\t\t$this->dendapersen->DbValue = $row['dendapersen'];\n\t\t$this->totalangsuran->DbValue = $row['totalangsuran'];\n\t\t$this->totalangsuranauto->DbValue = $row['totalangsuranauto'];\n\t\t$this->sisaangsuran->DbValue = $row['sisaangsuran'];\n\t\t$this->sisaangsuranauto->DbValue = $row['sisaangsuranauto'];\n\t\t$this->saldotitipan->DbValue = $row['saldotitipan'];\n\t\t$this->saldotitipansisa->DbValue = $row['saldotitipansisa'];\n\t\t$this->bayarpokok->DbValue = $row['bayarpokok'];\n\t\t$this->bayarpokokauto->DbValue = $row['bayarpokokauto'];\n\t\t$this->bayarbunga->DbValue = $row['bayarbunga'];\n\t\t$this->bayarbungaauto->DbValue = $row['bayarbungaauto'];\n\t\t$this->bayardenda->DbValue = $row['bayardenda'];\n\t\t$this->bayardendaauto->DbValue = $row['bayardendaauto'];\n\t\t$this->bayartitipan->DbValue = $row['bayartitipan'];\n\t\t$this->bayartitipanauto->DbValue = $row['bayartitipanauto'];\n\t\t$this->totalbayar->DbValue = $row['totalbayar'];\n\t\t$this->totalbayarauto->DbValue = $row['totalbayarauto'];\n\t\t$this->pelunasan->DbValue = $row['pelunasan'];\n\t\t$this->pelunasanauto->DbValue = $row['pelunasanauto'];\n\t\t$this->finalty->DbValue = $row['finalty'];\n\t\t$this->finaltyauto->DbValue = $row['finaltyauto'];\n\t\t$this->terbilang->DbValue = $row['terbilang'];\n\t\t$this->petugas->DbValue = $row['petugas'];\n\t\t$this->pembayaran->DbValue = $row['pembayaran'];\n\t\t$this->bank->DbValue = $row['bank'];\n\t\t$this->atasnama->DbValue = $row['atasnama'];\n\t\t$this->tipe->DbValue = $row['tipe'];\n\t\t$this->kantor->DbValue = $row['kantor'];\n\t\t$this->keterangan->DbValue = $row['keterangan'];\n\t\t$this->active->DbValue = $row['active'];\n\t\t$this->ip->DbValue = $row['ip'];\n\t\t$this->status->DbValue = $row['status'];\n\t\t$this->user->DbValue = $row['user'];\n\t\t$this->created->DbValue = $row['created'];\n\t\t$this->modified->DbValue = $row['modified'];\n\t}", "title": "" }, { "docid": "b852ef85f980224e112784ec05d89d63", "score": "0.63970095", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->IDXDAFTAR->DbValue = $row['IDXDAFTAR'];\n\t\t$this->NOMR->DbValue = $row['NOMR'];\n\t\t$this->KDPOLY->DbValue = $row['KDPOLY'];\n\t\t$this->KDCARABAYAR->DbValue = $row['KDCARABAYAR'];\n\t\t$this->NIP->DbValue = $row['NIP'];\n\t\t$this->TGLREG->DbValue = $row['TGLREG'];\n\t\t$this->JAMREG->DbValue = $row['JAMREG'];\n\t\t$this->NO_SJP->DbValue = $row['NO_SJP'];\n\t\t$this->NOKARTU->DbValue = $row['NOKARTU'];\n\t\t$this->TANGGAL_SEP->DbValue = $row['TANGGAL_SEP'];\n\t\t$this->TANGGALRUJUK_SEP->DbValue = $row['TANGGALRUJUK_SEP'];\n\t\t$this->KELASRAWAT_SEP->DbValue = $row['KELASRAWAT_SEP'];\n\t\t$this->NORUJUKAN_SEP->DbValue = $row['NORUJUKAN_SEP'];\n\t\t$this->PPKPELAYANAN_SEP->DbValue = $row['PPKPELAYANAN_SEP'];\n\t\t$this->JENISPERAWATAN_SEP->DbValue = $row['JENISPERAWATAN_SEP'];\n\t\t$this->CATATAN_SEP->DbValue = $row['CATATAN_SEP'];\n\t\t$this->DIAGNOSAAWAL_SEP->DbValue = $row['DIAGNOSAAWAL_SEP'];\n\t\t$this->NAMADIAGNOSA_SEP->DbValue = $row['NAMADIAGNOSA_SEP'];\n\t\t$this->LAKALANTAS_SEP->DbValue = $row['LAKALANTAS_SEP'];\n\t\t$this->LOKASILAKALANTAS->DbValue = $row['LOKASILAKALANTAS'];\n\t\t$this->USER->DbValue = $row['USER'];\n\t\t$this->generate_sep->DbValue = $row['generate_sep'];\n\t\t$this->PESERTANIK_SEP->DbValue = $row['PESERTANIK_SEP'];\n\t\t$this->PESERTANAMA_SEP->DbValue = $row['PESERTANAMA_SEP'];\n\t\t$this->PESERTAJENISKELAMIN_SEP->DbValue = $row['PESERTAJENISKELAMIN_SEP'];\n\t\t$this->PESERTANAMAKELAS_SEP->DbValue = $row['PESERTANAMAKELAS_SEP'];\n\t\t$this->PESERTAPISAT->DbValue = $row['PESERTAPISAT'];\n\t\t$this->PESERTATGLLAHIR->DbValue = $row['PESERTATGLLAHIR'];\n\t\t$this->PESERTAJENISPESERTA_SEP->DbValue = $row['PESERTAJENISPESERTA_SEP'];\n\t\t$this->PESERTANAMAJENISPESERTA_SEP->DbValue = $row['PESERTANAMAJENISPESERTA_SEP'];\n\t\t$this->POLITUJUAN_SEP->DbValue = $row['POLITUJUAN_SEP'];\n\t\t$this->NAMAPOLITUJUAN_SEP->DbValue = $row['NAMAPOLITUJUAN_SEP'];\n\t\t$this->KDPPKRUJUKAN_SEP->DbValue = $row['KDPPKRUJUKAN_SEP'];\n\t\t$this->NMPPKRUJUKAN_SEP->DbValue = $row['NMPPKRUJUKAN_SEP'];\n\t\t$this->mapingtransaksi->DbValue = $row['mapingtransaksi'];\n\t\t$this->bridging_kepesertaan_by_no_ka->DbValue = $row['bridging_kepesertaan_by_no_ka'];\n\t\t$this->pasien_NOTELP->DbValue = $row['pasien_NOTELP'];\n\t\t$this->penjamin_kkl_id->DbValue = $row['penjamin_kkl_id'];\n\t\t$this->asalfaskesrujukan_id->DbValue = $row['asalfaskesrujukan_id'];\n\t\t$this->peserta_cob->DbValue = $row['peserta_cob'];\n\t\t$this->poli_eksekutif->DbValue = $row['poli_eksekutif'];\n\t\t$this->status_kepesertaan_BPJS->DbValue = $row['status_kepesertaan_BPJS'];\n\t}", "title": "" }, { "docid": "b852ef85f980224e112784ec05d89d63", "score": "0.63970095", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->IDXDAFTAR->DbValue = $row['IDXDAFTAR'];\n\t\t$this->NOMR->DbValue = $row['NOMR'];\n\t\t$this->KDPOLY->DbValue = $row['KDPOLY'];\n\t\t$this->KDCARABAYAR->DbValue = $row['KDCARABAYAR'];\n\t\t$this->NIP->DbValue = $row['NIP'];\n\t\t$this->TGLREG->DbValue = $row['TGLREG'];\n\t\t$this->JAMREG->DbValue = $row['JAMREG'];\n\t\t$this->NO_SJP->DbValue = $row['NO_SJP'];\n\t\t$this->NOKARTU->DbValue = $row['NOKARTU'];\n\t\t$this->TANGGAL_SEP->DbValue = $row['TANGGAL_SEP'];\n\t\t$this->TANGGALRUJUK_SEP->DbValue = $row['TANGGALRUJUK_SEP'];\n\t\t$this->KELASRAWAT_SEP->DbValue = $row['KELASRAWAT_SEP'];\n\t\t$this->NORUJUKAN_SEP->DbValue = $row['NORUJUKAN_SEP'];\n\t\t$this->PPKPELAYANAN_SEP->DbValue = $row['PPKPELAYANAN_SEP'];\n\t\t$this->JENISPERAWATAN_SEP->DbValue = $row['JENISPERAWATAN_SEP'];\n\t\t$this->CATATAN_SEP->DbValue = $row['CATATAN_SEP'];\n\t\t$this->DIAGNOSAAWAL_SEP->DbValue = $row['DIAGNOSAAWAL_SEP'];\n\t\t$this->NAMADIAGNOSA_SEP->DbValue = $row['NAMADIAGNOSA_SEP'];\n\t\t$this->LAKALANTAS_SEP->DbValue = $row['LAKALANTAS_SEP'];\n\t\t$this->LOKASILAKALANTAS->DbValue = $row['LOKASILAKALANTAS'];\n\t\t$this->USER->DbValue = $row['USER'];\n\t\t$this->generate_sep->DbValue = $row['generate_sep'];\n\t\t$this->PESERTANIK_SEP->DbValue = $row['PESERTANIK_SEP'];\n\t\t$this->PESERTANAMA_SEP->DbValue = $row['PESERTANAMA_SEP'];\n\t\t$this->PESERTAJENISKELAMIN_SEP->DbValue = $row['PESERTAJENISKELAMIN_SEP'];\n\t\t$this->PESERTANAMAKELAS_SEP->DbValue = $row['PESERTANAMAKELAS_SEP'];\n\t\t$this->PESERTAPISAT->DbValue = $row['PESERTAPISAT'];\n\t\t$this->PESERTATGLLAHIR->DbValue = $row['PESERTATGLLAHIR'];\n\t\t$this->PESERTAJENISPESERTA_SEP->DbValue = $row['PESERTAJENISPESERTA_SEP'];\n\t\t$this->PESERTANAMAJENISPESERTA_SEP->DbValue = $row['PESERTANAMAJENISPESERTA_SEP'];\n\t\t$this->POLITUJUAN_SEP->DbValue = $row['POLITUJUAN_SEP'];\n\t\t$this->NAMAPOLITUJUAN_SEP->DbValue = $row['NAMAPOLITUJUAN_SEP'];\n\t\t$this->KDPPKRUJUKAN_SEP->DbValue = $row['KDPPKRUJUKAN_SEP'];\n\t\t$this->NMPPKRUJUKAN_SEP->DbValue = $row['NMPPKRUJUKAN_SEP'];\n\t\t$this->mapingtransaksi->DbValue = $row['mapingtransaksi'];\n\t\t$this->bridging_kepesertaan_by_no_ka->DbValue = $row['bridging_kepesertaan_by_no_ka'];\n\t\t$this->pasien_NOTELP->DbValue = $row['pasien_NOTELP'];\n\t\t$this->penjamin_kkl_id->DbValue = $row['penjamin_kkl_id'];\n\t\t$this->asalfaskesrujukan_id->DbValue = $row['asalfaskesrujukan_id'];\n\t\t$this->peserta_cob->DbValue = $row['peserta_cob'];\n\t\t$this->poli_eksekutif->DbValue = $row['poli_eksekutif'];\n\t\t$this->status_kepesertaan_BPJS->DbValue = $row['status_kepesertaan_BPJS'];\n\t}", "title": "" }, { "docid": "e0c80b9be57e7c4ead8fa8d5147a904f", "score": "0.6380904", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->llave->DbValue = $row['llave'];\n\t\t$this->F_Sincron->DbValue = $row['F_Sincron'];\n\t\t$this->USUARIO->DbValue = $row['USUARIO'];\n\t\t$this->Cargo_gme->DbValue = $row['Cargo_gme'];\n\t\t$this->Num_AV->DbValue = $row['Num_AV'];\n\t\t$this->NOM_APOYO->DbValue = $row['NOM_APOYO'];\n\t\t$this->Otro_Nom_Apoyo->DbValue = $row['Otro_Nom_Apoyo'];\n\t\t$this->Otro_CC_Apoyo->DbValue = $row['Otro_CC_Apoyo'];\n\t\t$this->NOM_PE->DbValue = $row['NOM_PE'];\n\t\t$this->Otro_PE->DbValue = $row['Otro_PE'];\n\t\t$this->Departamento->DbValue = $row['Departamento'];\n\t\t$this->Muncipio->DbValue = $row['Muncipio'];\n\t\t$this->NOM_VDA->DbValue = $row['NOM_VDA'];\n\t\t$this->NO_E->DbValue = $row['NO_E'];\n\t\t$this->NO_OF->DbValue = $row['NO_OF'];\n\t\t$this->NO_SUBOF->DbValue = $row['NO_SUBOF'];\n\t\t$this->NO_SOL->DbValue = $row['NO_SOL'];\n\t\t$this->NO_PATRU->DbValue = $row['NO_PATRU'];\n\t\t$this->Nom_enfer->DbValue = $row['Nom_enfer'];\n\t\t$this->Otro_Nom_Enfer->DbValue = $row['Otro_Nom_Enfer'];\n\t\t$this->Otro_CC_Enfer->DbValue = $row['Otro_CC_Enfer'];\n\t\t$this->Armada->DbValue = $row['Armada'];\n\t\t$this->Ejercito->DbValue = $row['Ejercito'];\n\t\t$this->Policia->DbValue = $row['Policia'];\n\t\t$this->NOM_UNIDAD->DbValue = $row['NOM_UNIDAD'];\n\t\t$this->NOM_COMAN->DbValue = $row['NOM_COMAN'];\n\t\t$this->CC_COMAN->DbValue = $row['CC_COMAN'];\n\t\t$this->TEL_COMAN->DbValue = $row['TEL_COMAN'];\n\t\t$this->RANGO_COMAN->DbValue = $row['RANGO_COMAN'];\n\t\t$this->Otro_rango->DbValue = $row['Otro_rango'];\n\t\t$this->NO_GDETECCION->DbValue = $row['NO_GDETECCION'];\n\t\t$this->NO_BINOMIO->DbValue = $row['NO_BINOMIO'];\n\t\t$this->FECHA_INTO_AV->DbValue = $row['FECHA_INTO_AV'];\n\t\t$this->DIA->DbValue = $row['DIA'];\n\t\t$this->MES->DbValue = $row['MES'];\n\t\t$this->LATITUD->DbValue = $row['LATITUD'];\n\t\t$this->GRA_LAT->DbValue = $row['GRA_LAT'];\n\t\t$this->MIN_LAT->DbValue = $row['MIN_LAT'];\n\t\t$this->SEG_LAT->DbValue = $row['SEG_LAT'];\n\t\t$this->GRA_LONG->DbValue = $row['GRA_LONG'];\n\t\t$this->MIN_LONG->DbValue = $row['MIN_LONG'];\n\t\t$this->SEG_LONG->DbValue = $row['SEG_LONG'];\n\t\t$this->OBSERVACION->DbValue = $row['OBSERVACION'];\n\t\t$this->AD1O->DbValue = $row['AÑO'];\n\t\t$this->FASE->DbValue = $row['FASE'];\n\t\t$this->Modificado->DbValue = $row['Modificado'];\n\t}", "title": "" }, { "docid": "844169da5dd5a0bbcc2df2622e5de9b1", "score": "0.63484496", "text": "function LoadDbValues(&$rs) {\n\t\tif (!$rs || !is_array($rs) && $rs->EOF) return;\n\t\t$row = is_array($rs) ? $rs : $rs->fields;\n\t\t$this->ID_Formulario->DbValue = $row['ID_Formulario'];\n\t\t$this->F_Sincron->DbValue = $row['F_Sincron'];\n\t\t$this->USUARIO->DbValue = $row['USUARIO'];\n\t\t$this->Cargo_gme->DbValue = $row['Cargo_gme'];\n\t\t$this->NOM_GE->DbValue = $row['NOM_GE'];\n\t\t$this->Otro_PGE->DbValue = $row['Otro_PGE'];\n\t\t$this->Otro_CC_PGE->DbValue = $row['Otro_CC_PGE'];\n\t\t$this->TIPO_INFORME->DbValue = $row['TIPO_INFORME'];\n\t\t$this->FECHA_NOVEDAD->DbValue = $row['FECHA_NOVEDAD'];\n\t\t$this->DIA->DbValue = $row['DIA'];\n\t\t$this->MES->DbValue = $row['MES'];\n\t\t$this->Num_Evacua->DbValue = $row['Num_Evacua'];\n\t\t$this->PTO_INCOMU->DbValue = $row['PTO_INCOMU'];\n\t\t$this->OBS_punt_inco->DbValue = $row['OBS_punt_inco'];\n\t\t$this->OBS_ENLACE->DbValue = $row['OBS_ENLACE'];\n\t\t$this->NUM_Novedad->DbValue = $row['NUM_Novedad'];\n\t\t$this->Nom_Per_Evacu->DbValue = $row['Nom_Per_Evacu'];\n\t\t$this->CC_Pre_Evacu->DbValue = $row['CC_Pre_Evacu'];\n\t\t$this->Nom_Otro_Per_Evacu->DbValue = $row['Nom_Otro_Per_Evacu'];\n\t\t$this->CC_Otro_Per_Evacu->DbValue = $row['CC_Otro_Per_Evacu'];\n\t\t$this->Cargo_Per_EVA->DbValue = $row['Cargo_Per_EVA'];\n\t\t$this->Motivo_Eva->DbValue = $row['Motivo_Eva'];\n\t\t$this->OBS_EVA->DbValue = $row['OBS_EVA'];\n\t\t$this->NOM_PE->DbValue = $row['NOM_PE'];\n\t\t$this->Otro_Nom_PE->DbValue = $row['Otro_Nom_PE'];\n\t\t$this->NOM_CAPATAZ->DbValue = $row['NOM_CAPATAZ'];\n\t\t$this->Otro_Nom_Capata->DbValue = $row['Otro_Nom_Capata'];\n\t\t$this->Otro_CC_Capata->DbValue = $row['Otro_CC_Capata'];\n\t\t$this->Muncipio->DbValue = $row['Muncipio'];\n\t\t$this->F_llegada->DbValue = $row['F_llegada'];\n\t\t$this->Fecha->DbValue = $row['Fecha'];\n\t\t$this->Modificado->DbValue = $row['Modificado'];\n\t\t$this->llave_2->DbValue = $row['llave_2'];\n\t\t$this->departamento->DbValue = $row['departamento'];\n\t}", "title": "" }, { "docid": "0d19b70bd485cea4e276d49c5ae10c9d", "score": "0.6329725", "text": "function LoadRow() {\r\n\t\tglobal $conn, $Security, $filesystem;\r\n\t\t$sFilter = $filesystem->KeyFilter();\r\n\r\n\t\t// Call Row Selecting event\r\n\t\t$filesystem->Row_Selecting($sFilter);\r\n\r\n\t\t// Load SQL based on filter\r\n\t\t$filesystem->CurrentFilter = $sFilter;\r\n\t\t$sSql = $filesystem->SQL();\r\n\t\t$res = FALSE;\r\n\t\t$rs = ew_LoadRecordset($sSql);\r\n\t\tif ($rs && !$rs->EOF) {\r\n\t\t\t$res = TRUE;\r\n\t\t\t$this->LoadRowValues($rs); // Load row values\r\n\r\n\t\t\t// Call Row Selected event\r\n\t\t\t$filesystem->Row_Selected($rs);\r\n\t\t\t$rs->Close();\r\n\t\t}\r\n\t\treturn $res;\r\n\t}", "title": "" }, { "docid": "33b42561af77f8b4c490f5a76da8d1df", "score": "0.6329112", "text": "function LoadRow() {\r\n\t\tglobal $conn, $Security, $master_siswa;\r\n\t\t$sFilter = $master_siswa->KeyFilter();\r\n\r\n\t\t// Call Row Selecting event\r\n\t\t$master_siswa->Row_Selecting($sFilter);\r\n\r\n\t\t// Load SQL based on filter\r\n\t\t$master_siswa->CurrentFilter = $sFilter;\r\n\t\t$sSql = $master_siswa->SQL();\r\n\t\t$res = FALSE;\r\n\t\t$rs = ew_LoadRecordset($sSql);\r\n\t\tif ($rs && !$rs->EOF) {\r\n\t\t\t$res = TRUE;\r\n\t\t\t$this->LoadRowValues($rs); // Load row values\r\n\t\t\t$rs->Close();\r\n\t\t}\r\n\t\treturn $res;\r\n\t}", "title": "" }, { "docid": "726dd25de1163932385420e7e723e64e", "score": "0.63287157", "text": "public function loadRow()\n\t{\n\t\tglobal $Security, $Language;\n\t\t$filter = $this->getRecordFilter();\n\n\t\t// Call Row Selecting event\n\t\t$this->Row_Selecting($filter);\n\n\t\t// Load SQL based on filter\n\t\t$this->CurrentFilter = $filter;\n\t\t$sql = $this->getCurrentSql();\n\t\t$conn = $this->getConnection();\n\t\t$res = FALSE;\n\t\t$rs = LoadRecordset($sql, $conn);\n\t\tif ($rs && !$rs->EOF) {\n\t\t\t$res = TRUE;\n\t\t\t$this->loadRowValues($rs); // Load row values\n\t\t\t$rs->close();\n\t\t}\n\t\treturn $res;\n\t}", "title": "" }, { "docid": "cea74e76dc2fd5865813b3d6b26ae499", "score": "0.63129973", "text": "function LoadRow() {\r\n\t\tglobal $conn, $Security, $Language;\r\n\t\t$sFilter = $this->KeyFilter();\r\n\r\n\t\t// Call Row Selecting event\r\n\t\t$this->Row_Selecting($sFilter);\r\n\r\n\t\t// Load SQL based on filter\r\n\t\t$this->CurrentFilter = $sFilter;\r\n\t\t$sSql = $this->SQL();\r\n\t\t$res = FALSE;\r\n\t\t$rs = ew_LoadRecordset($sSql);\r\n\t\tif ($rs && !$rs->EOF) {\r\n\t\t\t$res = TRUE;\r\n\t\t\t$this->LoadRowValues($rs); // Load row values\r\n\t\t\t$rs->Close();\r\n\t\t}\r\n\t\treturn $res;\r\n\t}", "title": "" } ]
39f28296c86dd9e61cc7cde5552cd131
/ Process Save Form Single Attribute
[ { "docid": "4261b1b6b888fe55733aec08f43e7f84", "score": "0.0", "text": "public function processPut($workflowUpdate=false)\n {\n $this->setForm();\n \n if($this->form)\n {\n $this->form->{\\Input::get('name')} = \\Input::get('value') == \"\" ? null : \\Input::get('value');\n\n //Eloquent: Save\n if($this->form->save())\n {\n if($workflowUpdate)\n {\n if(method_exists($this->form,'workflow'))\n {\n \\Queue::push('WorkflowActivity@updateTask',array('class'=>get_class($this->form),'id'=>$this->form->getKey(),'user_id'=>$this->controller->currentUser->id));\n }\n elseif(isset($this->parentForm) && method_exists($this->parentForm,'workflow'))\n {\n \\Queue::push('WorkflowActivity@updateTask',array('class'=>get_class($this->parentForm),'id'=>$this->parentForm->getKey(),'user_id'=>$this->controller->currentUser->id));\n }\n else\n {\n throw new \\RuntimeException(\"Unable to locate workflow\");\n }\n }\n \n return \\Response::make('Success');\n }\n else\n {\n return \\Response::make('Failed to save. Please retry',400);\n }\n }\n else\n {\n return \\Response::make('Error during save: Invalid PK',400);\n }\n }", "title": "" } ]
[ { "docid": "d603c112dd3b60748a2c205211c1d6a6", "score": "0.7025262", "text": "function save_object()\n {\n if((isset($_POST['SubObjectFormSubmitted'])) && !preg_match(\"/freeze/\", $this->FAIstate)){\n foreach($this->attributes as $attrs){\n if($this->acl_is_writeable($attrs)){\n if(isset($_POST[$attrs])){\n $this->$attrs = get_post($attrs);\n }else{\n $this->$attrs = \"\";\n }\n }\n }\n }\n }", "title": "" }, { "docid": "e2445bddb17d9e244957b9d6e9622e70", "score": "0.60353386", "text": "public function save(array $attributes);", "title": "" }, { "docid": "fd4f3675aafe6a977c785f0a9c50d89c", "score": "0.6004667", "text": "private function ProcessAttributes() {\n\t\t$csvilog = JRequest::getVar('csvilog');\n\t\t/* Check if the attributes is to be added */\n\t\tif ($this->attributes) {\n\t\t\t$csvfields = JRequest::getVar('csv_fields');\n\t\t\t$csvilog->AddMessage('debug', JText::_('DEBUG_ADDING_ATTRIBUTES'));\n\t\t\t$attributes = explode( \"|\", $this->attributes );\n\t\t\t$i = 0;\n\t\t\twhile(list(,$val) = each($attributes)) {\n\t\t\t\t$values = explode( \"::\", $val );\n\t\t\t\tif (count($values) == 2) {\n\t\t\t\t\t/* Fix the array to show the correct names to bind the data */\n\t\t\t\t\t$this->_vm_product_attribute_sku->bind(array('product_id' => $this->product_id, 'attribute_name' => $values[0], 'attribute_list' => $values[1]));\n\t\t\t\t\t/* Store the data */\n\t\t\t\t\t$this->_vm_product_attribute_sku->store();\n\t\t\t\t\t$csvilog->AddMessage('debug', JText::_('DEBUG_STORE_ATTRIBUTE'), true);\n\t\t\t\t\t/* Clean for new insert */\n\t\t\t\t\t$this->_vm_product_attribute_sku->reset();\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t$csvilog->AddMessage('debug', JText::_('DEBUG_ATTRIBUTE_INCORRECT'));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "6d20aa84661351e4924a89a0b9b71329", "score": "0.5992593", "text": "abstract protected function save();", "title": "" }, { "docid": "96b1aab0161d45830878b523f1aaddbf", "score": "0.5960008", "text": "public function save(){\n\t\t$this->validateMainProperties();\n\t\tCompanyDAM::update($this);\n\t}", "title": "" }, { "docid": "ddfcc0d6885c0d1791f14acaa088558f", "score": "0.58873004", "text": "public function AddAttrProcess()\n\t{\n\t\t$rules = array(\n\t\t\tarray('field' => 'CName', 'label' => 'CName', 'rules' => 'required')\n\t\t);\n\n\t\t$this->form_validation->set_rules($rules);\n\t\tif ($this->form_validation->run() == false) {\n\t\t\techo validation_errors();\n\t\t\t$Msg = array('Msg' => validation_errors(), 'Type' => 'danger');\n\t\t\t$this->session->set_flashdata($Msg);\n\t\t\tredirect(base_url('admin/AddAttr'));\n\t\t} else {\n\n\t\t\t$CName = $this->lib->validate($this->input->post('CName'));\n\n\t\t\t$CAbout = $this->lib->validate($this->input->post('CAbout'));\n\n\t\t\t$count = $this->lib_model->Counter('m_attribute', array('name' => $CName));\n\t\t\tif ($count == 0) {\n\t\t\t\t$f = array(\n\t\t\t\t\t'name' => $CName,\n\t\t\t\t\t'about' => $CAbout,\n\t\t\t\t\t'status' => 0,\n\t\t\t\t\t'created' => date('Y-m-d H:i:s'),\n\t\t\t\t\t'createdip' => $this->input->ip_address(),\n\t\t\t\t\t'createdby' => 'Admin'\n\n\t\t\t\t);\n\n\n\t\t\t\t$this->lib_model->Insert('m_attribute', $f);\n\t\t\t\t$Msg = array('Msg' => 'Attribute Add Successfully', 'Type' => 'success');\n\t\t\t\t$this->session->set_flashdata($Msg);\n\t\t\t\tredirect(base_url('admin/AddAttr'));\n\t\t\t} else {\n\t\t\t\t$Msg = array('Msg' => 'Attribute Already Exist in Database', 'Type' => 'danger');\n\t\t\t\t$this->session->set_flashdata($Msg);\n\t\t\t\tredirect(base_url('admin/AddAttr'));\n\t\t\t}\n\n\n\t\t}\n\t}", "title": "" }, { "docid": "90233515af83bb99989a4b4b79c192bb", "score": "0.5882864", "text": "protected function _save()\n {}", "title": "" }, { "docid": "4490164671a750fd979967dc1fde4dbb", "score": "0.5871185", "text": "public function save()\n {\n $this->validate(null, $this->getValidationMessages());\n\n if (! $this->manualVolume) {\n $this->variant->volume_unit = null;\n $this->variant->volume_value = null;\n }\n\n $data = $this->prepareAttributeData();\n $this->variant->attribute_data = $data;\n\n $this->variant->save();\n $this->savePricing();\n $this->updateImages();\n\n $this->updateSlots();\n\n $this->notify('Variant updated');\n }", "title": "" }, { "docid": "f63e4829273d4bd8819c88b2910cc803", "score": "0.5870903", "text": "public function saveAttr($var, $val = false) {\n if ($this->editingExisting === true && in_array($var, $this->restricted_vars_flat) ) {\n return;\n }\n if($val === false) {\n if(isset($_POST[$var])) {\n $val = $_POST[$var];\n if($var === 'mail__smtp__ssl') $val = 'ssl';\n } else {\n $val = '';\n }\n }\n\n // 1) save in session\n $_SESSION['setupcfg'][$var] = $val;\n\n // 2) save in $this->config, which is used in forms GUI\n $this->_saveInConfigObject($var, $val);\n }", "title": "" }, { "docid": "f7ff1904b92adc42db6227186a949e81", "score": "0.5857694", "text": "public function form_process(&$data) {\n global $DB;\n\n $params = array('elementid' => $this->id, 'trackerid' => $data->trackerid, 'issueid' => $data->issueid);\n if (!$attribute = $DB->get_record('tracker_issueattribute', $params)) {\n $attribute = new StdClass();\n $attribute->trackerid = $data->trackerid;\n $attribute->issueid = $data->issueid;\n $attribute->elementid = $this->id;\n }\n\n $elmname = 'element'.$this->name;\n if ($this->private) {\n $data->$elmname = optional_param($elmname, '', PARAM_TEXT);\n } else {\n $data->$elmname = required_param($elmname, PARAM_TEXT);\n }\n $attribute->elementitemid = $data->$elmname; // In this case true value in element id.\n $attribute->timemodified = time();\n\n if (!isset($attribute->id)) {\n $attribute->id = $DB->insert_record('tracker_issueattribute', $attribute);\n if (empty($attribute->id)) {\n print_error('erroraddissueattribute', 'tracker', '', 2);\n }\n } else {\n $DB->update_record('tracker_issueattribute', $attribute);\n }\n }", "title": "" }, { "docid": "f79fea9f5d2e159b539994f4e9fe7475", "score": "0.5849692", "text": "abstract public function do_save();", "title": "" }, { "docid": "3e85c96b2e19599402e3e79339f48f07", "score": "0.58384997", "text": "public function EditAttrProcess()\n\t{\n\t\t$rules = array(\n\t\t\tarray('field' => 'CName', 'label' => 'CName', 'rules' => 'required'),\n\t\t\tarray('field' => 'id', 'label' => 'Id', 'rules' => 'required')\n\t\t);\n\n\t\t$this->form_validation->set_rules($rules);\n\t\tif ($this->form_validation->run() == false) {\n\t\t\techo validation_errors();\n\t\t\t$Msg = array('Msg' => validation_errors(), 'Type' => 'danger');\n\t\t\t$this->session->set_flashdata($Msg);\n\t\t\tredirect(base_url('admin/EditAttr'));\n\t\t} else {\n\n\t\t\t$Cid = $this->lib->validate($this->input->post('id'));\n\t\t\t$CName = $this->lib->validate($this->input->post('CName'));\n\t\t\t$CAbout = $this->lib->validate($this->input->post('CAbout'));\n\n\n\n\t\t\t$count = $this->lib_model->Counter('m_attribute', array('name' => $CName));\n\t\t\tif ($count == 0) {\n\n\t\t\t$f = array(\n\t\t\t\t\t'name' => $CName,\n\t\t\t\t\t'about' => $CAbout,\n\t\t\t\t\t'`modified`' => date('Y-m-d H:i:s'),\n\t\t\t\t\t'`modifiedby`' => 'Admin',\n\t\t\t\t\t'`modifiedip`' => $this->input->ip_address()\n\t\t\t\t);\n\n\n\t\t\t\t$this->lib_model->Update('m_attribute', $f, array('id' => $Cid));\n\t\t\t\t$Msg = array('Msg' => 'Attribute Update Successfully', 'Type' => 'success');\n\t\t\t\t$this->session->set_flashdata($Msg);\n\t\t\t\tredirect(base_url('admin/EditAttr/' . $Cid));\n\n\t\t} else {\n\t\t\t\t$Msg = array('Msg' => 'Attribute Alredy Exist in Database', 'Type' => 'danger');\n\t\t\t\t$this->session->set_flashdata($Msg);\n\t\t\t\tredirect(base_url('admin/EditAttr/' . $Cid));\n\t\t\t}\n\n\t\t}\n\t}", "title": "" }, { "docid": "6b5076dd4b0b114f36934b836fab7e88", "score": "0.5812904", "text": "protected function _afterSave(Mage_Core_Model_Abstract $object)\n {\n $forms = $object->getData('used_in_forms');\n $adapter = $this->_getWriteAdapter();\n if (is_array($forms)) {\n $where = array('attribute_id=?' => $object->getId());\n $adapter->delete($this->_getFormAttributeTable(), $where);\n\n $data = array();\n foreach ($forms as $formCode) {\n $data[] = array(\n 'form_code' => $formCode,\n 'attribute_id' => (int)$object->getId()\n );\n }\n\n if ($data) {\n $adapter->insertMultiple($this->_getFormAttributeTable(), $data);\n }\n }\n\n // update sort order\n if (!$object->isObjectNew() && $object->dataHasChangedFor('sort_order')) {\n $data = array('sort_order' => $object->getSortOrder());\n $where = array('attribute_id=?' => (int)$object->getId());\n $adapter->update($this->getTable('eav/entity_attribute'), $data, $where);\n }\n\n // save scope attributes\n $websiteId = (int)$object->getWebsite()->getId();\n if ($websiteId) {\n $table = $this->_getEavWebsiteTable();\n $describe = $this->_getReadAdapter()->describeTable($table);\n $data = array();\n if (!$object->getScopeWebsiteId() || $object->getScopeWebsiteId() != $websiteId) {\n $data = $this->getScopeValues($object);\n }\n\n $data['attribute_id'] = (int)$object->getId();\n $data['website_id'] = (int)$websiteId;\n unset($describe['attribute_id']);\n unset($describe['website_id']);\n\n $updateColumns = array();\n foreach (array_keys($describe) as $columnName) {\n $data[$columnName] = $object->getData('scope_' . $columnName);\n $updateColumns[] = $columnName;\n }\n\n $adapter->insertOnDuplicate($table, $data, $updateColumns);\n }\n\n return parent::_afterSave($object);\n }", "title": "" }, { "docid": "02325d482754f1ff67a453105ba6d1be", "score": "0.5804473", "text": "abstract public function save();", "title": "" }, { "docid": "02325d482754f1ff67a453105ba6d1be", "score": "0.5804473", "text": "abstract public function save();", "title": "" }, { "docid": "02325d482754f1ff67a453105ba6d1be", "score": "0.5804473", "text": "abstract public function save();", "title": "" }, { "docid": "02325d482754f1ff67a453105ba6d1be", "score": "0.5804473", "text": "abstract public function save();", "title": "" }, { "docid": "02325d482754f1ff67a453105ba6d1be", "score": "0.5804473", "text": "abstract public function save();", "title": "" }, { "docid": "02325d482754f1ff67a453105ba6d1be", "score": "0.5804473", "text": "abstract public function save();", "title": "" }, { "docid": "b5c046b179ca09a5b2853a9cff81a660", "score": "0.57942295", "text": "public function save() \r\n\t{\r\n\t\tif (count($this->newOptions) > 0) {\r\n\t\t\r\n\t\t\tforeach ($this->newOptions as $option) {\r\n\t\t\t\t\r\n\t\t\t\t$label = array(\r\n\t\t\t\t\t\t\tarray(\r\n\t\t\t\t\t\t\t\t\"store_id\" => array(\"0\"),\r\n\t\t\t\t\t\t\t\t\"value\" => $option->label\r\n\t\t\t\t\t\t\t)\r\n\t\t\t\t);\r\n\t\t\t\t\r\n\t\t\t\t$data = array(\r\n\t\t\t\t\t\t\"label\" => $label,\r\n\t\t\t\t\t\t\"order\" => \"0\",\r\n\t\t\t\t\t\t\"is_default\" => \"0\"\r\n\t\t\t\t);\r\n\t\t\t\t\r\n\t\t\t\t$result = $this->client->catalogProductAttributeAddOption($this->sessionid, $this->attribute, $data);\r\n\t\t\t\t\r\n\t\t\t\t$this->log->addInfo('enviado', array(\"label\" => $option->label, \"result\" => $result));\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\t// e agora apagar as opcoes que nao existem\r\n\t\tif (count($this->delOptions) > 0) {\r\n\t\t\t\t\r\n\t\t\tforeach ($this->delOptions as $option) {\r\n\t\t\r\n\t\t\t\t$result = $this->client->catalogProductAttributeRemoveOption($this->sessionid, $this->attribute, $option->value);\r\n\t\t\r\n\t\t\t\t$this->log->addInfo('apagado', array(\"label\" => $option->label, \"result\" => $result));\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t}\r\n\t\t\t\t\r\n\t\t// se houve modificacoes no magento, destruimos a cache\r\n\t\tif (count($this->delOptions) > 0 || count($this->newOptions) > 0) { $this->destroyCache(); }\r\n\t}", "title": "" }, { "docid": "bf83401aaab19e88e0d1ea4962174c3f", "score": "0.5792181", "text": "protected function saveData()\n {\n $this->beforeSave();\n\n if ($this->csrfId && $this->_csrf) {\n unset($this->formData[$this->csrfId]);\n }\n\n // Perform the save\n $model = $this->getModel();\n $mname = $model->getName();\n\n // \\MUtil_Echo::track($this->formData[$mname]);\n $this->formData[$mname] = $model->saveAll($this->formData[$mname]);\n\n $changed = $model->getChanged();\n\n // Message the save\n $this->afterSave($changed);\n }", "title": "" }, { "docid": "0ad707007d0da71c49ab07e4c80e0ecb", "score": "0.5779734", "text": "function save_object()\n {\n if(isset($_POST['classSelector']) && $_POST['classSelector'] == 1 \n && isset($_POST['edit_continue'])){\n $this->ClassName = get_post('UseTextInputName');\n $this->ClassAlreadyExists = true;\n }\n \n if(isset($_POST['classSelector']) && $_POST['classSelector'] == 2 \n && isset($_POST['edit_continue'])){\n $this->ClassAlreadyExists = false;\n $this->ClassName = get_post('SelectedClass');\n }\n }", "title": "" }, { "docid": "ce89cfa2055dce67e47b1a79d64b2a8c", "score": "0.5775451", "text": "public function save() {\n\t\t\t$inputs = $this->inputs;\n\t\t\t$prefix = $this->prefix;\n\t\t\tforeach ( $inputs as $input ) {\n\t\t\t\tif ( is_array( $_POST ) && array_key_exists( $input['id'], $_POST ) ) {\n\t\t\t\t\tif ( isset( $_POST[ $input['id'] ] ) ) {\n\t\t\t\t\t\tif ( is_array( $_POST[ $input['id'] ] ) ) {\n\t\t\t\t\t\t\t$data = array();\n\t\t\t\t\t\t\t$post_data = $_POST[ $input['id'] ];\n\t\t\t\t\t\t\tforeach ( $post_data as $one_data ) {\n\t\t\t\t\t\t\t\t$data[] = sanitize_text_field( $one_data );//just sanitizing fields and regrouping again into the array before saving to db\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tupdate_option( $prefix . $input['id'], $data );\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$post_data = $_POST[ $input['id'] ];\n\t\t\t\t\t\t\tswitch ( $post_data ) {\n\t\t\t\t\t\t\t\tcase filter_var( $post_data, FILTER_VALIDATE_URL ):\n\t\t\t\t\t\t\t\t\t$data = esc_url( $post_data );\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\tcase is_email( $post_data ):\n\t\t\t\t\t\t\t\t\t$data = sanitize_email( $post_data );\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t$data = sanitize_textarea_field( $post_data );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tupdate_option( $prefix . $input['id'], $data );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t\twp_safe_redirect( $this->redirect );\n\t\t\texit();\n\t\t}", "title": "" }, { "docid": "83cc7fb0129f5fb13516aeb4c0dedba1", "score": "0.5763554", "text": "private function ProcessAttributeValues() {\n\t\t$csvilog = JRequest::getVar('csvilog');\n\t\t/* Check if the attributes is to be added */\n\t\tif ($this->attribute_values) {\n\t\t\t$csvfields = JRequest::getVar('csv_fields');\n\t\t\t$csvilog->AddMessage('debug', JText::_('DEBUG_ADD_ATTRIBUTES'));\n\t\t\t$attribute_values = explode( \"|\", $this->attribute_values );\n\t\t\t$i = 0;\n\t\t\twhile(list(,$val) = each($attribute_values)) {\n\t\t\t\t$values = explode( \"::\", $val );\n\t\t\t\tif (count($values) == 2) {\n\t\t\t\t\t/* Fix the array to show the correct names to bind the data */\n\t\t\t\t\t$this->_vm_product_attribute->bind(array('product_id' => $this->product_id, 'attribute_name' => $values[0], 'attribute_value' => $values[1]));\n\t\t\t\t\t/* Store the data */\n\t\t\t\t\t$this->_vm_product_attribute->store();\n\t\t\t\t\t$csvilog->AddMessage('debug', JText::_('DEBUG_ADD_ATTRIBUTES'), true);\n\t\t\t\t\t/* Clean for new insert */\n\t\t\t\t\t$this->_vm_product_attribute->reset();\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t$csvilog->AddMessage('debug', JText::_('DEBUG_NO_VALID_ATTRIBUTE').' '.$val);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "34ca98dfe518da7ed8b9618836949a93", "score": "0.57387257", "text": "function storeObjectAttribute( $objectattribute )\n {\n }", "title": "" }, { "docid": "3769e72ae227a664a8e8ceef9b610e86", "score": "0.57367015", "text": "protected function _postSave()\n {}", "title": "" }, { "docid": "c49fd46262dd651d13d23f5a0f6d6c95", "score": "0.56942904", "text": "function save() { }", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "c01046a7628cac2d4c97db025b318aa2", "score": "0.56829375", "text": "public function save();", "title": "" }, { "docid": "7ca0500a11859480e86bebc8dac69a2d", "score": "0.5662197", "text": "public function save()\n {\n $this->authorize('update', 'AppearancePolicy');\n\n $this->saver->save($this->request->all());\n return $this->success();\n\t}", "title": "" }, { "docid": "1cb287135296b978f6ad32dd333cddcd", "score": "0.56610996", "text": "protected function postSave()\n {\n }", "title": "" }, { "docid": "4314634b23e5fd1b6e8869a99a1cf11c", "score": "0.5648801", "text": "public function afterSave()\n {\n $ruleProductAttributes = array_merge(\n $this->_getUsedAttributes($this->getConditionsSerialized()),\n $this->_getUsedAttributes($this->getActionsSerialized())\n );\n if (count($ruleProductAttributes)) {\n $this->getResource()->saveAttributes($this->getId(), $ruleProductAttributes);\n }\n\n return parent::afterSave();\n }", "title": "" }, { "docid": "996df64887129fa118f3e0961a5681a6", "score": "0.56463045", "text": "public function save() {}", "title": "" }, { "docid": "996df64887129fa118f3e0961a5681a6", "score": "0.56463045", "text": "public function save() {}", "title": "" }, { "docid": "996df64887129fa118f3e0961a5681a6", "score": "0.56463045", "text": "public function save() {}", "title": "" }, { "docid": "b5e2dacdc7cba547bfb3357cc8fb3be3", "score": "0.5645866", "text": "public function onBeforeWrite()\n {\n parent::onBeforeWrite();\n if (isset($_POST['ProductAttributes']) && is_array($_POST['ProductAttributes'])) {\n $this->AttributeValues()->setByIDList(array_values($_POST['ProductAttributes']));\n }\n }", "title": "" }, { "docid": "90cb6f592d911b20a97ad5a34b2b29a7", "score": "0.56223756", "text": "public function save()\n\t{\n\t\t$this->_freetag->tag_object($this->get('userid'), $this->get('record'), $this->get('tagname'), $this->get('module'));\n\t}", "title": "" }, { "docid": "603d0b895e854b9e4535ae55b2cc655d", "score": "0.5616024", "text": "protected function _save(){\n \tforeach ($this->_intfields as $int){ \n\t \t$this->_attr[$int] = str_replace(',', '.', $this->_attr[$int]);\n \t}\n \tforeach ($this->_attr as $key => $value){\n \t\t\n \t\t// Make sure all fields default to default db value if they are empty\n \t\tif (!isset($value) || is_null($value) || strlen($value) == 0){\n \t\t\t$this->_attr[$key] = $this->_defaults[$key];\n \t\t}\n \t\tif (!is_null($value)){\n\t \t\t// Let's make date fields the right format for mysql\n\t \t\tif (in_array($key, $this->_dateFields)){\n\t \t\t\tif (is_object($value) && get_class($value) == 'Zend_Date'){\n\t\t \t\t\t$this->_attr[$key] = $value->get(Zend_Date::ISO_8601);\n\t\t \t\t} else {\n\t\t \t\t\t// Fallback if something goes awry\n\t\t \t\t\tif (is_numeric($value)){\n\t\t \t\t\t\t$zDate = new Zend_Date($value, Zend_Date::TIMESTAMP);\n\t\t \t\t\t} else {\n\t\t \t\t\t\t$zDate = new Zend_Date($value, Zend_Date::ISO_8601);\n\t\t \t\t\t}\n\t\t \t\t\t$this->_attr[trim($key)] = $zDate->get(Zend_Date::ISO_8601);\n\t\t \t\t}\n\t \t\t}\n\t \t}\n \t}\n\n \tif ($this->isNew()){\n \t\t$this->_dbTable->insert($this->_attr);\n \t\t$id = $this->loadLastId();\n \t} else {\n\t\t\t$where = $this->_dbTable->getAdapter()->quoteInto($this->_primaryKey . ' = ?', $this->getId());\n \t\t$this->_dbTable->getAdapter()->update($this->_name, $this->_attr, $where);\n \t}\n }", "title": "" }, { "docid": "322127e64a29030e60374798cdd0002a", "score": "0.5612049", "text": "function save_object()\n {\n if(isset($_POST['vacation_release_'.$this->object_id])){\n $this->days = stripslashes($_POST['vacation_release_'.$this->object_id]);\n }\n\n /* Check if we want to toggle the expert mode */\n if(isset($_POST['Toggle_Expert_'.$this->object_id])){\n $this->Expert = !$this->Expert;\n }\n\n /* Get release date */\n if(isset($_POST['vacation_receiver_'.$this->object_id])){\n $vr = stripslashes ($_POST['vacation_receiver_'.$this->object_id]);\n $tmp = array();\n $tmp2 = explode(\",\",$vr);\n foreach($tmp2 as $val){\n $ad = trim($val);\n if(!empty($ad)){\n $tmp[] = $ad;\n }\n }\n $this->addresses = $tmp;\n }\n\n /* Get reason */\n if(isset($_POST['vacation_reason_'.$this->object_id])){\n $vr = stripslashes ($_POST['vacation_reason_'.$this->object_id]);\n $this->reason = trim($vr);\n }\n }", "title": "" }, { "docid": "a0847efcd0561ec453d21c5cb42d48d0", "score": "0.56004417", "text": "protected function save_if_submit()\n\t{\n\t\tif ( isset($_POST[ $this->settings_id . '_save' ]) )\n\t\t{\n\t\t\tdo_action('wordpressmenu_page_save_' . $this->settings_id);\n\t\t}\n\t}", "title": "" }, { "docid": "9ba17753f72e11275c71039e17a2ac1d", "score": "0.55978334", "text": "protected function _postSave()\n {\n }", "title": "" }, { "docid": "9ba17753f72e11275c71039e17a2ac1d", "score": "0.55978334", "text": "protected function _postSave()\n {\n }", "title": "" }, { "docid": "eefe8431a2145fe40edd40edf9d736dd", "score": "0.559206", "text": "public function save()\n\t{\n\t}", "title": "" }, { "docid": "eefe8431a2145fe40edd40edf9d736dd", "score": "0.559206", "text": "public function save()\n\t{\n\t}", "title": "" }, { "docid": "e792a9488518884d7a3a360683d1c281", "score": "0.55881", "text": "public function save() {\n\t\t\n\t}", "title": "" }, { "docid": "5b38c58de65d89cb6f8873841613fac9", "score": "0.55747443", "text": "public function saveForm() {\n\n\t\tparent::saveForm();\n\n\t}", "title": "" }, { "docid": "6ad101033eb9c7e91bfd77bd89dff8c2", "score": "0.5573632", "text": "function save($form){\n\n\t\t$form_data = array();\n\n\t\tforeach ($form as $key => $value) {\n\t\t\t$form_data[$key] = $value;\n\t\t}\n\n\t\t$query = $this->name . 'id';\n\t\t$query = \"{$query} = {$form_data[$query]}\";\n\n\t\treturn $this->db->update($this->name, $form_data, $query);\n\t\t\n\t}", "title": "" }, { "docid": "9256d4b65ddb6a9384861c5322d9e93b", "score": "0.556723", "text": "protected function specificAttributeRequestPost($id,$attribute){throw new EspressoAPI_MethodNotImplementedException();}", "title": "" }, { "docid": "da6327c8939ef4519df90b30db518f60", "score": "0.5561517", "text": "public function onSaving()\n {\n $entry = $this->getFormEntry();\n if (!$entry->type_id) {\n $entry->type_id = $this->getType()->getId();\n }\n }", "title": "" }, { "docid": "da6c27800f4450cea1864a5cf66866ff", "score": "0.5537001", "text": "public function store()\n {\n $this->validate(request(), [\n 'slug' => 'required|max:30|regex:/(^[a-z0-9_]+$)+/|unique:attributes',\n 'name' => 'required|max:255',\n ], [\n 'slug.required' => 'Mã thuộc tính là bắt buộc',\n 'slug.max' => 'Mã thuộc tính ít hơn 30 kí tự',\n 'slug.unique' => 'Mã thuộc tính đã tồn tại.',\n 'slug.regex' => 'Vui lòng chỉ sử dụng chữ cái (a-z), số (0-9) hoặc gạch dưới (_) cho Mã thuộc tính.',\n 'name.required' => 'Tên hiển thị là bắt buộc',\n 'name.max' => 'Tên hiển thị ít hơn 255 kí tự',\n ]);\n\n $attribute = Attribute::forceCreate([\n 'slug' => request('slug'),\n 'name' => trim(request('name')),\n 'frontend_input' => request('frontend_input'),\n 'backend_type' => $this->mapBackendType(),\n ]);\n\n return $attribute;\n }", "title": "" }, { "docid": "656a4e04ad1f4bb45cb23941338de127", "score": "0.55313945", "text": "public function AdminSave() {\n\tglobal $vgOut;\n\n\t$out = $this->objForm->Save();\n\t$vgOut->AddText($out);\n }", "title": "" }, { "docid": "badc5651fc2c239b84a843e2f76b6cb6", "score": "0.55250174", "text": "public function save() {\r\n\t }", "title": "" }, { "docid": "e708611072edf1e61f845b1325337937", "score": "0.5524617", "text": "function save()\r\n {\r\n }", "title": "" }, { "docid": "1449b13b635a276be11d951e78640b79", "score": "0.55139613", "text": "function submitForm(array &$form, $form_state) {\n // that save multiple properties onto the agchem links\n // this can be something that is set at the vardef level \n // or the form_entity_map level which includes criteria for uniqueness\n // \n parent::submitForm($form, $form_state);\n }", "title": "" }, { "docid": "e3cb0e3ab023bed6b8ed51db8f15e4e2", "score": "0.55135554", "text": "function custom_meta_edit_form_submit(&$form, &$form_state) {\n db_query(\"UPDATE {custom_meta} SET mls_meta_attr = '%s', mls_meta_attr_value = '%s', mls_meta_content = '%s' WHERE mls_meta_uid = '%d'\", $form_state['clicked_button']['#post']['custom_meta_attribute'], $form_state['clicked_button']['#post']['custom_meta_attribute_value'], $form_state['clicked_button']['#post']['custom_meta_content_value'], arg(4));\n drupal_goto('admin/settings/custom_meta');\n drupal_set_message(t('Tag saved.'));\n}", "title": "" }, { "docid": "047a0fb59595812c218c0f4ea1fc9206", "score": "0.5506783", "text": "protected function saving()\n {\n /*\n * Compile the \"metafields\" property within the data object so that all the metafields\n * retrieved so far will get saved together with their parent object (i.e. $this)\n */\n $this->shopifyData->metafields = [];\n foreach ($this->getMetafields() as $metafield) {\n $this->savingMetafield($metafield);\n }\n }", "title": "" }, { "docid": "bcfd4e306aae46adc8f36e350d347522", "score": "0.54998803", "text": "public function saveAction();", "title": "" }, { "docid": "69815e9790c7a5522b39c804e3fda1e4", "score": "0.5496515", "text": "function save();", "title": "" }, { "docid": "4ca391f31defa8481c1a1e9004715399", "score": "0.5482037", "text": "private function storeParams()\n\t{\n\t\tforeach( $this->fields as $fieldName => $fieldAttributes ) {\n\t\t\tif( $fieldAttributes['type'] === 'image' ) {\n\t\t\t\tif( $new_file = $this->handleUploadImage( $fieldName, $fieldAttributes['root'] ) )\n\t\t\t\t\t$this->record->$fieldName = $new_file; \n\t\t\t\t\t\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$this->record->$fieldName = $_REQUEST[$fieldName];\n\t\t\t}\n\t\t}\n\t\n\t}", "title": "" }, { "docid": "f1f06cc787fba2389a341180158b2c1e", "score": "0.54819554", "text": "public function formSave() {\n\t\treturn array();\n\t}", "title": "" }, { "docid": "ed00c460962967bc58313081eb3d4bf0", "score": "0.5479021", "text": "public function saveAction()\n {\n if ($data = $this->getRequest()->getPost()) {\n Mage::getModel('orderoptions/item')->update($data);\n $this->loadLayout()->renderLayout();\n } else {\n echo $this->__('Something went wrong, probably empty data has been sent');\n }\n }", "title": "" }, { "docid": "3f3dd140f9ac5ede6d3b5891a87a8f4a", "score": "0.5475731", "text": "private function save()\n {\n if (!isset($_REQUEST['season'])) {\n return;\n }\n\n $season = Season::find_by_id($_REQUEST['season']);\n $season->update_attributes($_POST['podlove_season']);\n\n if (isset($_POST['submit_and_stay'])) {\n $this->redirect('edit', $season->id);\n } else {\n $this->redirect('index', $season->id);\n }\n }", "title": "" }, { "docid": "d0d15fa19457847e1e4f5a91e7fc5e0e", "score": "0.5464463", "text": "public function saved() {}", "title": "" }, { "docid": "b36ae51663d761c7a0ee31dd3dc18d32", "score": "0.5462702", "text": "public function saveAction()\n {\n $post = $this->getRequest()->getPost();\t\n $id = $this->getRequest()->getParam('id');\n \n $model = Mage::getModel('catalog/product')->load($id);\n $model->setCarebyzincCategory($post['category']);\n $model->setCarebyzincSubcategory($post['subcategory']);\n $model->setCarebyzincManufacturer($post['carebyzinc_manufacturer']);\n $model->setCarebyzincModel($post['carebyzinc_model']);\n $model->setCarebyzinc($post['carebyzinc']);\n $model->save();\n \n $this->_redirect('*/*/');\n return;\n\n }", "title": "" }, { "docid": "cef4217e7963b005f3a34cad172381b8", "score": "0.5457476", "text": "function save() {\n\t\t// loop through sets\n\t\t$config = apply_filters('cf_meta_save_config', $this->config);\n\t\tif (count($config)) {\n\t\t\tforeach ($config as $set) {\n\t\t\t\t// process each input in a set\n\t\t\t\tforeach ($set['items'] as $item) {\n\t\t\t\t\tif ($item['type'] == 'block') {\n\t\t\t\t\t\t$item['prefix'] = $this->prefix;\n\t\t\t\t\t\t$block = new cf_input_block($item);\n\t\t\t\t\t\t$block->save();\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tif (!class_exists('cf_input_'.$item['type'])) { continue; }\n\t\t\t\t\t\t$item['prefix'] = $this->prefix;\n\t\t\t\t\t\t$type = 'cf_input_'.$item['type'];\n\t\t\t\t\t\t\n\t\t\t\t\t\t$item = new $type($item); \n\t\t\t\t\t\tif (!$item->save()) {\n\t\t\t\t\t\t\t// process errors\n\t\t\t\t\t\t\tif ($item->error) {\n\t\t\t\t\t\t\t\t$item_save_error = \"<h5 style=\\\"color:brown\\\">error on $item->save</h5>\";\n\t\t\t\t\t\t\t\tdie($item_save_error);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "bb001adfe0506c8b321072b1872c7151", "score": "0.54461104", "text": "function saveEditReturn() {\r\n \t$model = $this->getModel('blog_categories');\r\n \t$app = JFactory::getApplication();\r\n \t \r\n \t//Get the $data from the form\r\n \t$data = $app->input->getArray($_POST);\r\n \r\n \t//updateKategorie() if the input field is not empty\r\n \tif($data['title'] != '') {\r\n \t\t$model->updateKategorieFields();\r\n \t}\r\n \t$this->setRedirect('index.php?option=com_ablog&act=blog_categories'); \t \r\n }", "title": "" }, { "docid": "dafaeabd5f0b210846e201ad4c5a314d", "score": "0.54443735", "text": "public function save() \n\t{\n\n\t\tif($this->is_validated()){\n\n\t\t\t//print_r($this->validated_data);\n\t\t\t$line= R::dispense(\"line\");\n\t\t\t// echo $this->validated_data['user_full_name'];\n\t\t\t// exit;\n\t\t\t\n\t\t\t$line->linetitle \t= $this->validated_data['line_name'];\n\t\t\t$line->vsrlink \t\t= $this->validated_data['line_cpanel_url'];\n\t\t\t$line->createdate \t\t= CURRENT_DTT;\n\t\t\t$line->updatedate \t\t= CURRENT_DTT;\n\t\t\t$line->createby \t\t= 1001;\n\t\t\t$line->isactive \t\t= 0;\n\t\t\t$id = R::store($line);\t\t\t\n\t\t}\n\t\tif ($this->getError() == \"\") {$this->fails = FALSE;} else {$this->fails = TRUE;}\n\t\t\t\t\n \n \n }", "title": "" }, { "docid": "b51e0e4c0b9c135b660e4a60b26087e8", "score": "0.5439768", "text": "public function save() {\n // ******* Note: $connection must be a mysqli object.\n global $connection;\n $returnvalue = false;\n // Test to see if this is an insert or update.\n if ($this->AttributeDefID!= NULL) {\n $sql = 'UPDATE attributedef SET ';\n $isInsert = false;\n $sql .= \"TimestampCreated = ? \";\n $sql .= \", TimestampModified = ? \";\n $sql .= \", Version = ? \";\n $sql .= \", DataType = ? \";\n $sql .= \", FieldName = ? \";\n $sql .= \", TableType = ? \";\n $sql .= \", PrepTypeID = ? \";\n $sql .= \", ModifiedByAgentID = ? \";\n $sql .= \", DisciplineID = ? \";\n $sql .= \", CreatedByAgentID = ? \";\n\n $sql .= \" WHERE AttributeDefID = ? \";\n } else {\n $sql = 'INSERT INTO attributedef ';\n $isInsert = true;\nif ($this->PK==NULL) { throw new Exception('Can\\'t insert record with null primary key for this table'); }\n $sql .= '( AttributeDefID , TimestampCreated , TimestampModified , Version , DataType , FieldName , TableType , PrepTypeID , ModifiedByAgentID , DisciplineID , CreatedByAgentID ) VALUES (';\n $sql .= \" ? \";\n $sql .= \" , ? \";\n $sql .= \" , ? \";\n $sql .= \" , ? \";\n $sql .= \" , ? \";\n $sql .= \" , ? \";\n $sql .= \" , ? \";\n $sql .= \" , ? \";\n $sql .= \" , ? \";\n $sql .= \" , ? \";\n $sql .= \" , ? \";\n $sql .= ')';\n\n }\n if ($statement = $connection->prepare($sql)) { \n if ($this->AttributeDefID!= NULL ) {\n $statement->bind_param(\"issiisiiiiii\", $this->AttributeDefID , $this->TimestampCreated , $this->TimestampModified , $this->Version , $this->DataType , $this->FieldName , $this->TableType , $this->PrepTypeID , $this->ModifiedByAgentID , $this->DisciplineID , $this->CreatedByAgentID , $this->AttributeDefID );\n } else { \n $statement->bind_param(\"issiisiiiii\", $this->AttributeDefID , $this->TimestampCreated , $this->TimestampModified , $this->Version , $this->DataType , $this->FieldName , $this->TableType , $this->PrepTypeID , $this->ModifiedByAgentID , $this->DisciplineID , $this->CreatedByAgentID );\n } \n $statement->execute();\n if ($statement->num_rows()!=1) {\n $this->error = $statement->error; \n }\n $statement->close();\n } else { \n $this->error = mysqli_error($connection); \n }\n if ($this->error=='') { \n $returnvalue = true;\n };\n\n $this->loaded = true;\n return $returnvalue;\n }", "title": "" }, { "docid": "f30c37073e3a2a834aeac08549de3f9e", "score": "0.5434272", "text": "protected function save_entry() {\n\t\t$wpdb = $this->get_wpdb();\n\t\tif( null == $this->entry ) {\n\t\t\t//@todo some error or exception or something\n\t\t\treturn;\n\t\t}\n if ( $wpdb ) {\n if (!$this->entry_id) {\n $wpdb->insert($wpdb->prefix . 'cf_form_entries', $this->entry->to_array());\n $this->entry_id = $this->entry->id = $wpdb->insert_id;\n } else {\n $wpdb->update($wpdb->prefix . 'cf_form_entries', $this->entry->to_array(), array(\n 'id' => $this->entry_id\n ));\n }\n }\n\t}", "title": "" }, { "docid": "5e06891e85be5b6f54c5afe3518ca157", "score": "0.5424411", "text": "function saveBookingExtrafield() {\n $extra = new iwBookingExtra();\n if (isset($_POST)) {\n $msg = '';\n if ($_POST['name'] != '') {\n $title = $_POST['name'];\n } else {\n $msg .= __('- Please input name of field<br/>');\n }\n if ($_POST['type'] != '') {\n $field_type = $_POST['type'];\n } else {\n $msg .= __('- Please select a field type<br/>');\n }\n\n if ($field_type == 'textarea') {\n $default_value = stripslashes($_POST['text_value']);\n }\n if ($field_type == 'link') {\n $default_value = serialize(array('link_value_link' => stripslashes($_POST['link_value_link']), 'link_value_text' => stripslashes($_POST['link_value_text']), 'link_value_target' => stripslashes($_POST['link_value_target'])));\n }\n if ($field_type == 'image') {\n $default_value = $_POST['image'];\n }\n if ($field_type == 'text') {\n $default_value = stripslashes($_POST['string_value']);\n }\n if ($field_type == 'dropdown_list') {\n $default_value = serialize(array(stripslashes($_POST['drop_value']), $_POST['drop_multiselect']));\n }\n if ($field_type == 'date') {\n $default_value = $_POST['date_value'];\n }\n if ($field_type == 'measurement') {\n $default_value = serialize(array('measurement_value' => stripslashes($_POST['measurement_value']), 'measurement_unit' => stripslashes($_POST['measurement_unit'])));\n }\n if ($msg == '') {\n $extra->setId(isset($_POST['id']) ? $_POST['id'] : null);\n $extra->setName($title);\n $extra->setIcon($_POST['icon']);\n $extra->setDescription($_POST['description']);\n $extra->setPublished($_POST['published']);\n $extra->setOrdering(isset($_POST['ordering']) ? $_POST['ordering'] : null);\n $extra->setCategories($_POST['categories']);\n $extra->setType($_POST['type']);\n $extra->setDefault_value($default_value);\n if ($extra->getId()) {\n $update = unserialize($extra->editBookingExtra($extra));\n if (!$update['success']) {\n $_SESSION['bt_message'] = iwBookingUtility::getMessage($update['msg'], 'error');\n } else {\n $_SESSION['bt_message'] = iwBookingUtility::getMessage($update['msg'], 'success');\n }\n } else {\n $insert = unserialize($extra->addBookingExtra($extra));\n if (!$insert['success']) {\n $_SESSION['bt_message'] = iwBookingUtility::getMessage($insert['msg'], 'error');\n } else {\n $_SESSION['bt_message'] = iwBookingUtility::getMessage($insert['msg']);\n $extra->setId($insert['data']);\n }\n }\n } else {\n $_SESSION['bt_message'] = iwBookingUtility::getMessage($msg, 'error');\n }\n } else {\n $_SESSION['bt_message'] = iwBookingUtility::getMessage(__('No data send'), 'error');\n }\n wp_redirect(admin_url('edit.php?post_type=iw_booking&page=room-extra/' . ($extra->getId() ? 'edit&id=' . $extra->getId() : 'addnew')));\n}", "title": "" }, { "docid": "fe8dc23f72e8cee98ba8970b0683422e", "score": "0.5416673", "text": "function save_process_post(){\n\t\t/**\n\t\t * new is true for insert operation , false for update operation\n\t\t * @var boolean\n\t\t */\n\t\t$nuevo = $this->post('new');\n\t\t/**\n\t\t * agenda id selected in agenda dropdown\n\t\t * @var integer\n\t\t */\n\t\t$agenda = $this->post('agenda_id');\n\t\t/**\n\t\t * code for procedure\n\t\t * @var string\n\t\t */\n\t\t$codigo = $this->post('codigo');\n\t\t/**\n\t\t * procedure name \n\t\t * @var string\n\t\t */\n\t\t$nombre = $this->post('name_of_the_procedure');\n\t\t/**\n\t\t * [mediagenda].[MUTUAS] id is fetched here not [mediagenda].[ORIGEN_MUTUAS]\n\t\t * @var integer\n\t\t */\n\t\t$mutua = $this->post('mutual_id');\n\t\t/**\n\t\t * Privado is true if no insurance company value is selected but insurance is required \n\t\t * @var boolean\n\t\t */\n\t\t$privat = $this->post('private');\n\t\t/**\n\t\t * by default it sets to true\n\t\t * @var boolean\n\t\t */\n\t\t$qx = $this->post('qx');\n\t\t/**\n\t\t * rate of procedure\n\t\t * @var [type]\n\t\t */\n\t\t$tarifa = $this->post('rate');\n\t\t/**\n\t\t * it is by default false\n\t\t * @var boolean\n\t\t */\n\t\t$cma = $this->post('cma');\n\t\t/**\n\t\t * it is by default false\n\t\t * @var boolean\n\t\t */\n\t\t$ucias = $this->post('ucias');\n\t\t/**\n\t\t * assistant value is from scheduled patient assistant dropdown , default 0\n\t\t * @var integer\n\t\t */\n\t\t$ayudante = ($this->post('ayudante')!='')?$this->post('ayudante'):'0';\n\t\n\t\t/**\n\t\t * value of ayudante if ayudante checkbox is check, this is availabel only in scheduled patient section in clinical history\n\t\t * @var float\n\t\t */\n\t\t$perayuda = $this->post('perayuda');\n\t\t/**\n\t\t * default value is null\n\t\t * @var null\n\t\t */\n\t\t$id = 0;\n\t\tif($this->post('id')){\n\t\t\t$new = false; $id = $this->post('id');\n\t\t}\n\t\t$params = array('nuevo'=>$nuevo,'agenda'=>$agenda, 'codigo'=> $codigo,'nombre'\t=> $nombre, 'mutua' => $mutua, 'privat' => $privat, 'qx' => $qx, 'tarifa' => $tarifa, 'cma' => $cma, 'ucias' => $ucias, 'ayudante' => $ayudante, 'perayuda' => $perayuda,'id'=>$id\n\t\t\t);\n\t\t$success = $this->Common_model->execute_sp(\n\t\t\tarray(\n\t\t\t\t'sp_name'=>'mediagenda.actos_grabar_qx',\n\t\t\t\t'params' => $params,'db_name' =>'default','return_type' => 'row-array'));\t\t\n\t\tif(!isset($success['code'])){\n\t\t\t$message = \"Process saved sucessfully\";\n\t\t\t//$return_data_array['actos'] = $this->list_process_post(true);\n\t\t\techo returnJsonResponse($message,true);\n\t\t}else{\n\t\t\t$message = $success['message'];\n\n\t\t\techo returnJsonResponse($message,false);\n\t\t}\n\t\t\n\t\t\n\t}", "title": "" }, { "docid": "ed93fa848d77f1a6100e0dee31153a2e", "score": "0.5414959", "text": "public function save() {\n\n\t}", "title": "" }, { "docid": "aa37b40a5da315749e621d1465e4a89a", "score": "0.5410327", "text": "public function save() {\n\t}", "title": "" }, { "docid": "0b5305e35cee4c05cade155499e14a13", "score": "0.5406588", "text": "public function save()\n\t{\t\t\n\t\tif(!parent::save()){\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\treturn $this->_saveActionInputs();\n\t}", "title": "" }, { "docid": "1dd7e0b3073eeee13293ba6d91227af4", "score": "0.5406215", "text": "protected function _preSave() {}", "title": "" }, { "docid": "c52e1fb3ce4fd085c56245b27f7cf2ef", "score": "0.5404391", "text": "function onSave()\n {\n try\n {\n // open a transaction with database 'samples'\n TTransaction::open('permission');\n \n $this->form->validate();\n // read the form data and instantiates an Active Record\n $customer = $this->form->getData('Ferias');\n \n // stores the object in the database\n $customer->store();\n \n $this->form->setData($customer);\n \n // shows the success message\n new TMessage('info', 'Registro Salvo');\n \n TTransaction::close(); // close the transaction\n }\n catch (Exception $e) // in case of exception\n {\n // shows the exception error message\n new TMessage('error', '<b>Error</b>: ' . $e->getMessage());\n // undo all pending operations\n TTransaction::rollback();\n }\n }", "title": "" }, { "docid": "90dd4d603974ab3409fddfecd3c300a3", "score": "0.5399552", "text": "function save_details(){\n\tglobal $post;\n\n\tupdate_post_meta($post->ID, \"has_code\", $_POST[\"has_code\"]);\n\tupdate_post_meta($post->ID, \"has_sample\", $_POST[\"has_sample\"]);\n\tupdate_post_meta($post->ID, \"sample_link\", $_POST[\"sample_link\"]);\n\tupdate_post_meta($post->ID, \"code_link\", $_POST[\"code_link\"]);\n\t\n}", "title": "" }, { "docid": "540fbe994007318f18345e47f602a230", "score": "0.5397107", "text": "function save_equipment() {\n\n // Load::loadModel(\"equipment\");\n\n $equipmentObj=new equipmentModel();\n\n $equipmentObj->saveequipmentData($_POST);\n }", "title": "" }, { "docid": "5921528bfb0c2b810fdf6b027b391c7c", "score": "0.5393777", "text": "public function save()\n {\n $mappingValues = (array)$this->getValue(); //get the value from our config\n $attributeCodes = [];\n if ($this->_config->getValue('carriers/mercadoenvios/active')) {\n foreach ($mappingValues as $value) {\n if (in_array($value['attribute_code'], $attributeCodes)) {\n throw new \\Exception(__('Cannot repeat Magento Product size attributes'));\n }\n\n $attributeCodes[] = $value['attribute_code'];\n }\n }\n\n return parent::save();\n }", "title": "" }, { "docid": "673b32698402c1e15b93d3704a7379ee", "score": "0.5390155", "text": "function save_feature_on_product_save() {\n\t\t// Abort if we can't determine a product type\n\t\tif ( ! $product_type = it_exchange_get_product_type() )\n\t\t\treturn;\n\n\t\t// Abort if we don't have a product ID\n\t\t$product_id = empty( $_POST['ID'] ) ? false : $_POST['ID'];\n\t\tif ( ! $product_id )\n\t\t\treturn;\n\n\t\t// Abort if this product type doesn't support this feature\n\t\tif ( ! it_exchange_product_type_supports_feature( $product_type, 'featured-video' ) )\n\t\t\treturn;\n\n\t\t// Abort if key for feature option isn't set in POST data\n\t\tif ( ! isset( $_POST['it-exchange-product-featured-video'] ) )\n\t\t\treturn;\n\n\t\t// Get new value from post\n\t\t$new_value = $_POST['it-exchange-product-featured-video'];\n\n\t\t// Save new value\n\t\tit_exchange_update_product_feature( $product_id, 'featured-video', $new_value );\n\t}", "title": "" }, { "docid": "c666d8b6bb5c00220f48df22d9a930e6", "score": "0.5385886", "text": "function onSave()\n {\n try\n {\n // open a transaction with database 'permission'\n TTransaction::open('consultorio');\n \n // get the form data into an active record System_user\n $object = $this->form->getData('ConvenioProfissional');\n \n // form validation\n $this->form->validate();\n \n $object->store(); // stores the object\n \n // fill the form with the active record data\n $this->form->setData($object);\n \n // close the transaction\n TTransaction::close();\n \n // shows the success message\n //new TMessage('info', TAdiantiCoreTranslator::translate('Record saved'));\n new TToast('Convênio salvo com sucesso!');\n // reload the listing\n }\n catch (Exception $e) // in case of exception\n {\n // shows the exception error message\n new TMessage('error', '<b>Error</b> ' . $e->getMessage());\n \n // undo all pending operations\n TTransaction::rollback();\n }\n }", "title": "" }, { "docid": "26bf4fbae3a4b55f12cc40d7047c37bb", "score": "0.53760827", "text": "public function save($post_id, $post = null)\n\t{\n\t\tif (!is_null($post))\n\t\t{\n\t\t\tforeach (self::$ATTRS as $k)\n\t\t\t{\n\t\t\t\t// Attribute provided, save it.\n\t\t\t\tif (isset($_POST[$k]) && $_POST[$k] != '')\n\t\t\t\t{\n\t\t\t\t\tupdate_post_meta($post->ID, $k, $_POST[$k]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "9904f765130cf0ffc90da47269008f55", "score": "0.5374527", "text": "function saveFormValues($id=0){\n\t\t$_SESSION[\"mgrFormValues\"] = $_POST;\n\t\t$_SESSION[\"mgrFormValueId\"] = $id>0 ? $id:$this->action;\n\t}", "title": "" }, { "docid": "96e654a59ad3e732382f687b23245c15", "score": "0.53703254", "text": "private function save()\n\t{\n\t\tif ( isset( $_POST['submit'] ) )\n\t\t{\n\t\t\tif ( isset( $_POST['Config'] ) && is_array( $_POST['Config'] ) )\n\t\t\t{\n\t\t\t\tforeach ( $_POST['Config'] as $key => $value )\n\t\t\t\t{\n\t\t\t\t\tConfiguration::setValue( $key, $value );\n\t\t\t\t}\n\t\t\t}\n\t\t\t$this->halt();\n\t\t}\n\t}", "title": "" }, { "docid": "0591ed0308defd1c08f9a88b9746e8a8", "score": "0.5367064", "text": "function save_object()\n {\n if((isset($_POST['TableEntryFrameSubmitted'])) && !preg_match(\"/freeze/\", $this->FAIstate) ){\n plugin::save_object();\n\n foreach($this->partitions as $key => $part){\n foreach($this->UsedAttrs as $attrs){\n if(in_array_strict($attrs,array('cn','description'))) continue;\n \n if($this->acl_is_writeable($attrs)){\n\n if(isset($_POST[$attrs.\"_\".$key])){\n $this->partitions[$key][$attrs] = get_post($attrs.\"_\".$key);\n }else{\n $this->partitions[$key][$attrs] = false;\n }\n }\n\n if(!$this->partitions[$key]['FAIpartitionFlags']) {\n $this->partitions[$key]['FAIpartitionFlags'] = \" \";\n }\n }\n\n /* Adapt ext3 to have -j option */\n if ($this->partitions[$key][\"FAIfsType\"] == \"ext3\") {\n $this->partitions[$key][\"FAIfsOptions\"]= preg_replace('/\\s*-j\\s*/', '', $this->partitions[$key][\"FAIfsOptions\"]);\n $this->partitions[$key][\"FAIfsOptions\"]= \"-j \".$this->partitions[$key][\"FAIfsOptions\"];\n }\n }\n\n }\n }", "title": "" }, { "docid": "6ce11881358747d229be6d4990148a5a", "score": "0.5364683", "text": "protected function processSubmitAccount()\n {\n if (Module::isEnabled('belvg_customerattributes')) {\n $module = new belvg_customerattributes();\n $this->errors = $module->checkAttributeBeforeCreate();\n }\n parent::processSubmitAccount();\n }", "title": "" }, { "docid": "325b6247eaf718aee3abb3e5e88b1026", "score": "0.5352509", "text": "public function save() {\n\t if ( ! ( $this->has_valid_nonce() && current_user_can( 'manage_options' ) ) ) {\n\t // TODO: Display an error message.\n\t }\n\t // If the above are valid, sanitize and save the option.\n\t if ( null !== wp_unslash( $_POST['acme-message'] ) ) {\n\t \n\t $value = sanitize_text_field( $_POST['acme-message'] );\n\t update_option( 'movie-pro-custom-data', $value );\n\t \n\t }\n\t $this->redirect();\n\t}", "title": "" } ]
ffaa7b98865840da23cd4a86ad3453ea
S3 legacy useast1 endpoint used for valid regions unless option is explicitly set to 'regional'
[ { "docid": "147e0a0e5f77c63157e60a4e7e948781", "score": "0.58405", "text": "private function isS3LegacyEndpointUsed($service, $region, $options)\n {\n return $service === 's3'\n && $region === 'us-east-1'\n && (empty($options['s3_us_east_1_regional_endpoint'])\n || S3ConfigurationProvider::unwrap(\n $options['s3_us_east_1_regional_endpoint']\n )->getEndpointsType() !== 'regional'\n );\n }", "title": "" } ]
[ { "docid": "56c9a33549b056262a7e5d4aa46d9ece", "score": "0.65378326", "text": "public function getS3UsEast1RegionalEndpoints();", "title": "" }, { "docid": "4405f46c32b88d0b675b0d029735ab90", "score": "0.60334355", "text": "public function region(string $region): S3ExternalAnalyticsLink\n {\n }", "title": "" }, { "docid": "ed4da8943c7adee2b987e154dd428781", "score": "0.6024577", "text": "public function __construct($access_key = null, $secret_key = null, $use_ssl = true, $ssl_ca_cert = true, $endpoint = null, $session_token = null, $region = null) {// phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable -- $region is unused \n\t\tif (null !== $access_key && null !== $secret_key)\n\t\t\t$this->setAuth($access_key, $secret_key, $session_token);\n\n\t\t$this->use_ssl = $use_ssl;\n\t\t$this->ssl_ca_cert = $ssl_ca_cert;\n\n\t\t$opts = array(\n\t\t\t'key' => $access_key,\n\t\t\t'secret' => $secret_key,\n\t\t\t'scheme' => ($use_ssl) ? 'https' : 'http',\n\t\t\t// Using signature v4 requires a region (but see the note below)\n\t\t\t// 'signature' => 'v4',\n\t\t\t// 'region' => $this->region\n\t\t\t// 'endpoint' => 'somethingorother.s3.amazonaws.com'\n\t\t);\n\n\t\tif ($endpoint) {\n\t\t\t// Can't specify signature v4, as that requires stating the region - which we don't necessarily yet know.\n\t\t\t// Later comment: however, it looks to me like in current UD (Sep 2017), $endpoint is never used for Amazon S3/Vault, and there may be cases (e.g. DigitalOcean Spaces) where we might prefer v4 (DO support v2 too, currently) without knowing a region.\n\t\t\t$this->endpoint = $endpoint;\n\t\t\t$opts['endpoint'] = $endpoint;\n\t\t} else {\n\t\t\t// Using signature v4 requires a region. Also, some regions (EU Central 1, China) require signature v4 - and all support it, so we may as well use it if we can.\n\t\t\t$opts['signature'] = 'v4';\n\t\t\t$opts['region'] = $this->region;\n\t\t}\n\n\t\tif ($session_token) {\n\t\t $opts['token'] = $session_token;\n\t\t}\n\t\n\t\tif ($use_ssl) $opts['ssl.certificate_authority'] = $ssl_ca_cert;\n\n\t\t$this->client = Aws\\S3\\S3Client::factory($opts);\n\t}", "title": "" }, { "docid": "f33a10accb73ef43df35e53916a2613d", "score": "0.59304345", "text": "protected function getEndpoint() {\n if (!($endpoint = isset($this->options['store_endpoint']) ? $this->options['store_endpoint'] : NULL)) {\n $bucket = $this->options['store_container'];\n $region = isset($this->options['store_region']) ? $this->options['store_region'] : 'us-east-1';\n switch($region) {\n case 'us-east-1':\n $endpoint = 's3.amazonaws.com';\n break;\n case 'us-west-1':\n $endpoint = 's3-us-west-1.amazonaws.com';\n break;\n case 'us-west-2':\n $endpoint = 's3-us-west-2.amazonaws.com';\n break;\n case 'eu-west-1':\n $endpoint = 's3-eu-west-1.amazonaws.com';\n break;\n case 'ap-southeast-1':\n $endpoint = 's3-ap-southeast-1.amazonaws.com';\n break;\n case 'ap-southeast-2':\n $endpoint = 's3-ap-southeast-2.amazonaws.com';\n break;\n case 'ap-northeast-1':\n $endpoint = 's3-ap-northeast-1.amazonaws.com';\n break;\n case 'sa-east-1':\n $endpoint = 's3-sa-east-1.amazonaws.com';\n break;\n }\n if ($endpoint) print_msg(sprintf('Got S3 endpoint %s for region %s', $endpoint, $region), isset($this->options['verbose']), __FILE__, __LINE__);\n else print_msg(sprintf('Unable to get S3 endpoint for region %s', $region), isset($this->options['verbose']), __FILE__, __LINE__, TRUE);\n }\n if ($endpoint && !preg_match('/^http/', $endpoint)) $endpoint = isset($this->options['store_insecure']) && $this->options['store_insecure'] ? 'http://' : 'https://' . $endpoint;\n \n return $endpoint;\n }", "title": "" }, { "docid": "04e8b8ef31662ecc7dba9d013e785fdc", "score": "0.5916536", "text": "public function getRegion() {\n\n\n\t\t$endpoint = self::ENDPOINT;\n\t\t$regionName = \"us-east-1\";\n\n\t\tif ($endpoint == \"agcod-v2-eu.amazon.com\" || $endpoint == \"agcod-v2-eu-gamma.amazon.com\") {\n\t\t\t$regionName = \"eu-west-1\";\n\t\t}\n\t\telse if ($endpoint == \"agcod-v2-fe.amazon.com\" || $endpoint == \"agcod-v2-fe-gamma.amazon.com\") {\n\t\t\t$regionName = \"us-west-2\";\n\t\t}\n\t\treturn $regionName;\n\t}", "title": "" }, { "docid": "48c1f9ce78f558df5b6c393381fed36d", "score": "0.5888245", "text": "function aws_get_client_args_filter ( $args ) {\n $args['region'] = 'us-west-2';\n return $args;\n}", "title": "" }, { "docid": "66b2c46de7c46fc9c951dbcf804abef7", "score": "0.57482094", "text": "public static function US_EAST_1()\n {\n return new GoogleCloudRegion(self::US_EAST_1);\n }", "title": "" }, { "docid": "62bb0e00101086e7292c8c81a8a74d70", "score": "0.571759", "text": "public function setRegion($region) {\n\t\t$this->region = $region;\n\t\tif ('eu-central-1' == $region || 'cn-north-1' == $region) {\n\t\t\t// $this->config['signature'] = new Aws\\S3\\S3SignatureV4('s3');\n\t\t\t// $this->client->setConfig($this->config);\n\t\t}\n\t\t$this->client->setRegion($region);\n\t}", "title": "" }, { "docid": "fc5fa4b86e02db9c9bc9c28fdc0fd4c6", "score": "0.55909693", "text": "private function getRegionByUrl($url)\n {\n $url = parse_url($url, \\PHP_URL_HOST);\n\n $regions = array(\n 'ec2.us-east-1.amazonaws.com' => \\AmazonEC2::REGION_US_E1, // us-east-1\n 'ec2.us-west-1.amazonaws.com' => \\AmazonEC2::REGION_US_W1, // us-west-1\n 'ec2.us-west-2.amazonaws.com' => \\AmazonEC2::REGION_US_W2, // us-west-2\n 'ec2.eu-west-1.amazonaws.com' => \\AmazonEC2::REGION_EU_W1, // eu-west-1\n 'ec2.ap-northeast-1.amazonaws.com' => \\AmazonEC2::REGION_APAC_NE1, // ap-northeast-1\n 'ec2.ap-southeast-1.amazonaws.com' => \\AmazonEC2::REGION_APAC_SE1, // ap-southeast-1\n 'ec2.ap-southeast-2.amazonaws.com' => \\AmazonEC2::REGION_APAC_SE2, // ap-southeast-2\n 'ec2.sa-east-1.amazonaws.com' => \\AmazonEC2::REGION_SA_E1, // sa-east-1\n 'ec2.us-gov-west-1.amazonaws.com' => \\AmazonEC2::REGION_US_GOV1 // us-gov-west-1\n );\n\n if (!isset($regions[strtolower($url)])) {\n throw new \\InvalidArgumentException('The supplied region is unknown. Check your EC2_URL environment variable.');\n }\n\n return $regions[strtolower($url)];\n\n }", "title": "" }, { "docid": "3e5b7be6d5d071afd8f8ca30b8443013", "score": "0.5586785", "text": "protected function set_region($obj, $region = '', $bucket_name = '') {\n\t\t$config = $this->get_config();\n\t\t$endpoint = ('' != $region && 'n/a' != $region) ? $region : $config['endpoint'];\n\t\t$log_message = \"Set endpoint: $endpoint\";\n\t\t$log_message_append = '';\n\t\tif (is_string($endpoint) && preg_match('/^(.*):(\\d+)$/', $endpoint, $matches)) {\n\t\t\t$endpoint = $matches[1];\n\t\t\t$port = $matches[2];\n\t\t\t$log_message_append = \", port=$port\";\n\t\t\t$obj->setPort($port);\n\t\t}\n\t\t// This provider requires domain-style access. In future it might be better to provide an option rather than hard-coding the knowledge.\n\t\tif (is_string($endpoint) && preg_match('/\\.aliyuncs\\.com$/i', $endpoint)) {\n\t\t\t$obj->useDNSBucketName(true, $bucket_name);\n\t\t}\n\t\tglobal $updraftplus;\n\t\tif ($updraftplus->backup_time) $this->log($log_message.$log_message_append);\n\t\t$obj->setEndpoint($endpoint);\n\t}", "title": "" }, { "docid": "34370c5b52dcf9fd3d4659b1afb15161", "score": "0.55531293", "text": "public function getDefaultRegion()\n {\n return Mage::getStoreConfig('ambimax_import/general/aws_default_region');\n }", "title": "" }, { "docid": "eb3c1474e874a571edae7e28ccb31386", "score": "0.5321243", "text": "public static function US_EAST_4()\n {\n return new GoogleCloudRegion(self::US_EAST_4);\n }", "title": "" }, { "docid": "a9d9e489403cdbf66108119db06000ac", "score": "0.5316402", "text": "public static function US_WEST_2()\n {\n return new GoogleCloudRegion(self::US_WEST_2);\n }", "title": "" }, { "docid": "6fb5905830c3275a187768510c707877", "score": "0.5310427", "text": "public static function US_WEST_1()\n {\n return new GoogleCloudRegion(self::US_WEST_1);\n }", "title": "" }, { "docid": "aaaa3b24d6a7127d22d4414c3652f324", "score": "0.5297109", "text": "function amazon_ses_get_regions() {\n\treturn array(\n\t\t'us-east-1' => __( 'US East (N. Virginia)', 'amazon-ses' ),\n\t\t'us-west-2' => __( 'US West (Oregon)', 'amazon-ses' ),\n\t\t'eu-west-1' => __( 'EU (Ireland)', 'amazon-ses' ),\n\t);\n}", "title": "" }, { "docid": "dc34bd7e8b9154bdea312a91c6e9acfa", "score": "0.52836823", "text": "public function CreateBucket($bucket_name, $region = 'us-east-1')\r\n\t\t{\r\n\t\t\t$HttpRequest = new HttpRequest();\r\n\t\t\t\r\n\t\t\t$HttpRequest->setOptions(array( \"redirect\" => 10, \r\n\t\t\t \"useragent\" => \"LibWebta AWS Client (http://webta.net)\"\r\n\t\t\t )\r\n\t\t\t );\r\n\t\t\t\t\t\t\r\n\t\t\t$timestamp = $this->GetTimestamp(true);\r\n\t\t\t\r\n\t\t\tswitch($region)\r\n\t\t\t{\r\n\t\t\t\tcase \"us-east-1\":\r\n\t\t\t\t\t$request = \"\";\r\n\t\t\t\t\tbreak;\t\r\n\r\n\t\t\t\tcase \"us-west-2\":\r\n\t\t\t\t\t$request = \"<CreateBucketConfiguration><LocationConstraint>us-west-2</LocationConstraint></CreateBucketConfiguration>\";\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t\t\r\n\t\t\t\tcase \"us-west-1\":\r\n\t\t\t\t\t$request = \"<CreateBucketConfiguration><LocationConstraint>us-west-1</LocationConstraint></CreateBucketConfiguration>\";\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t\r\n\t\t\t\tcase \"ap-southeast-1\":\r\n\t\t\t\t\t$request = \"<CreateBucketConfiguration><LocationConstraint>ap-southeast-1</LocationConstraint></CreateBucketConfiguration>\";\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t\t\r\n\t\t\t\tcase \"ap-northeast-1\":\r\n\t\t\t\t\t$request = \"<CreateBucketConfiguration><LocationConstraint>ap-northeast-1</LocationConstraint></CreateBucketConfiguration>\";\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase \"sa-east-1\":\r\n\t\t\t\t\t$request = \"<CreateBucketConfiguration><LocationConstraint>sa-east-1</LocationConstraint></CreateBucketConfiguration>\";\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase \"eu-west-1\":\r\n\t\t\t\t\t$request = \"<CreateBucketConfiguration><LocationConstraint>EU</LocationConstraint></CreateBucketConfiguration>\";\r\n\t\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$data_to_sign = array(\"PUT\", \"\", \"\", $timestamp, \"/{$bucket_name}/\");\r\n\t\t\t\r\n\t\t\t$signature = $this->GetRESTSignature($data_to_sign);\r\n\t\t\t\r\n\t\t\t$HttpRequest->setUrl(\"https://{$bucket_name}.s3.amazonaws.com/\");\r\n\t\t $HttpRequest->setMethod(constant(\"HTTP_METH_PUT\"));\r\n\t\t \t \r\n\t\t $headers = array(\r\n\t\t \t\"Content-length\" => strlen($request),\r\n\t\t \t\"Date\"\t\t \t => $timestamp,\r\n\t\t \t\"Authorization\"\t => \"AWS {$this->AWSAccessKeyId}:{$signature}\"\r\n\t\t );\r\n\t\t\t \r\n $HttpRequest->addHeaders($headers);\r\n \r\n if ($request != '')\r\n \t$HttpRequest->setPutData($request);\r\n \r\n try \r\n {\r\n \t$HttpRequest->send();\r\n \t\r\n \t$info = $HttpRequest->getResponseInfo();\r\n\r\n if ($info['response_code'] == 200)\r\n \treturn true;\r\n else\r\n {\r\n \tif ($HttpRequest->getResponseBody())\r\n \t{\r\n \t\t$xml = @simplexml_load_string($HttpRequest->getResponseBody()); \t\r\n \t\tthrow new Exception((string)$xml->Message);\r\n \t}\r\n \telse\r\n \t\tthrow new Exception(_(\"Cannot create S3 bucket at this time. Please try again later.\"));\r\n }\r\n }\r\n catch (Exception $e)\r\n { \t\r\n \tif ($e->innerException)\r\n \t\t$message = $e->innerException->getMessage();\r\n \telse\r\n \t\t$message = $e->getMessage();\r\n \t\t\r\n \tthrow new Exception($message);\r\n }\r\n\t\t}", "title": "" }, { "docid": "6d2c0598b4d010bde4190a73d648e884", "score": "0.5205124", "text": "function get_region()\n{\n $region = get_param_string('keep_region', null);\n if ($region !== null) {\n if ($region == '') {\n return null;\n }\n return $region;\n }\n\n $ret = get_country();\n\n if ($ret == 'US') {\n require_code('locations/us');\n\n if (!is_guest()) {\n $state = get_cms_cpf('state');\n if (!empty($state)) {\n return 'US_' . $state;\n }\n }\n return $region;\n }\n\n return $ret;\n}", "title": "" }, { "docid": "5abaeeae5b8056ae76696118ccb40792", "score": "0.5132214", "text": "function aws_get_s3_client() {\n\t\n\t$credentials = aws_get_credentials();\n\t$region = elgg_get_plugin_setting('s3_region', 'aws');\n\t$scheme = elgg_get_plugin_setting('s3_scheme', 'aws');\n\t\n\tif (empty($credentials) || empty($region) || !in_array($scheme, ['http', 'https'])) {\n\t\treturn false;\n\t}\n\t\n\ttry {\n\t\treturn new S3Client([\n\t\t\t'credentials' => $credentials,\n\t\t\t'region' => $region,\n\t\t\t'version' => '2006-03-01',\n\t\t\t'scheme' => $scheme,\n\t\t\t'http' => [\n\t\t\t\t'connect_timeout' => 2,\n\t\t\t\t'timeout' => 5,\n\t\t\t],\n\t\t]);\n\t} catch (\\Exception $e) {\n\t\telgg_log(__METHOD__ . \" failed to create a client: {$e->getMessage()}\");\n\t}\n\t\n\treturn false;\n}", "title": "" }, { "docid": "13151b9169c69824a9d7600c63c44dbe", "score": "0.50979203", "text": "public function set_region($region)\n\t{\n\t\t// @codeCoverageIgnoreStart\n\t\t$this->set_hostname($region);\n\n\t\tswitch ($region)\n\t\t{\n\t\t\tcase self::REGION_US_E1: // Northern Virginia\n\t\t\t\t$this->enable_path_style(false);\n\t\t\t\tbreak;\n\n\t\t\tcase self::REGION_EU_W1: // Ireland\n\t\t\t\t$this->enable_path_style(); // Always use path-style access for EU endpoint.\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\t$this->enable_path_style(false);\n\t\t\t\tbreak;\n\n\t\t}\n\t\t// @codeCoverageIgnoreEnd\n\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "047b5cd75aaf31b4292a669da4cf9e46", "score": "0.5093825", "text": "function aws_get_rekognition_client() {\n\t\n\t$credentials = aws_get_credentials();\n\t$region = elgg_get_plugin_setting('s3_region', 'aws');\n\t$scheme = elgg_get_plugin_setting('s3_scheme', 'aws');\n\t\n\tif (empty($credentials) || empty($region) || !in_array($scheme, ['http', 'https'])) {\n\t\treturn false;\n\t}\n\t\n\ttry {\n\t\treturn new RekognitionClient([\n\t\t\t'credentials' => $credentials,\n\t\t\t'region' => $region,\n\t\t\t'version' => '2016-06-27',\n\t\t\t'scheme' => 'https',\n\t\t\t'http' => [\n\t\t\t\t'connect_timeout' => 2,\n\t\t\t\t'timeout' => 10,\n\t\t\t\t'verify' => $scheme === 'https',\n\t\t\t],\n\t\t]);\n\t} catch (\\Exception $e) {\n\t\telgg_log(__METHOD__ . \" failed to create a client: {$e->getMessage()}\");\n\t}\n\t\n\treturn false;\n}", "title": "" }, { "docid": "634b3c0ff1377ab453adbf05c07d6798", "score": "0.5087019", "text": "function new_vala_getcontractsbyregion($region,$dev=false){\n if( $dev )\n return new_vala_fetch_api_('getcontractsbyregion',$region);\n else\n return new_vala_fetch_api('getcontractsbyregion',$region,$dev);\n}", "title": "" }, { "docid": "f65d5cecc86165dfaff7074a25054edb", "score": "0.50642", "text": "public function getProductApiEndPoint()\r\n {\r\n $region = $this->config['country'];\r\n if ($region == 'US') {\r\n return ('webservices.amazon.com');\r\n } elseif ($region == 'CA') {\r\n //return ('mws.amazonservices.ca');\r\n return ('webservices.amazon.ca');\r\n } elseif ($region == 'JP') {\r\n return ('webservices.amazon.co.jp');\r\n } elseif ($region == 'MX') {\r\n //return ('mws.amazonservices.com.mx');\r\n return ('webservices.amazon.com.mx');\r\n } elseif ($region == 'CN') {\r\n return ('webservices.amazon.cn');\r\n } elseif ($region == 'IN') {\r\n return ('webservices.amazon.in');\r\n } elseif ($region == 'DE') {\r\n return ('webservices.amazon.de');\r\n } elseif ($region == 'BR') {\r\n return ('webservices.amazon.com.br');\r\n } elseif ($region == 'FR') {\r\n return ('webservices.amazon.fr');\r\n } elseif ($region == 'IT') {\r\n return ('webservices.amazon.it');\r\n } else {\r\n $msg = 'Incorrect Region Code';\r\n }\r\n }", "title": "" }, { "docid": "71c0f06c2f903ab18542ce6d3b1e9cf3", "score": "0.50485563", "text": "public function test_load_aws()\n {\n $subscription = new Subscription($this->awss3);\n\n vfsstream::newFile('56aaa297a8019.ics')\n ->withContent($this->content_test)\n ->at(vfsStreamWrapper::getRoot());\n\n $result = $subscription\n ->load(\"https://s3-us-west-2.amazonaws.com/calendar.dev.subscription/56aaa297a8019.ics\");\n\n $this->assertTrue($result);\n\n $this->assertTrue($subscription->validate_attributes());\n\n $this->assertTrue($subscription->time_zone->validate_attributes());\n\n }", "title": "" }, { "docid": "8854018acce26cf0738a1a8fed5844b6", "score": "0.503402", "text": "public function getAwsURL($oid, $type, $name)\n {\n\n\n $cachingName = $this->getCacheName($oid, $type, $name);\n $result = Cache::read($cachingName, 'storage');\n if (!$result) {\n\n $record = $this->find('first', array(\n 'conditions' => array(\n 'oid' => $oid,\n 'type' => $type,\n 'name' => $name,\n )\n ));\n\n if ($record) {\n $url = $record['StorageAwsObjectMap']['url'];\n if (Configure::read('Storage.storage_cloudfront_enable') == \"1\"){\n if ($record['StorageAwsObjectMap']['key'] == 'file_not_exist'){\n return false;\n }\n $url = rtrim(Configure::read('Storage.storage_cloudfront_cdn_mapping'),\"/\").\"/\".$record['StorageAwsObjectMap']['key'];\n }\n Cache::write($cachingName, $url, 'storage');\n return $record['StorageAwsObjectMap']['url'];\n } else {\n return false;\n }\n\n }\n\n return $result;\n }", "title": "" }, { "docid": "125d85bdab052a00bebee9c87574644c", "score": "0.5024548", "text": "public function testAwsS3CloudDownload() {\n\n $this->client->setIpToForwardFor('1.3.3.7');\n\n $request = new \\Zara4\\API\\ImageProcessing\\CloudImageRequest(self::$AWS_S3, '001.jpg');\n\n $destinationDriveId = self::$AWS_S3;\n $destinationFileName = uniqid('001_COMPRESSED__');\n $destinationParentId = 'test';\n $request->uploadToCloud($destinationDriveId, $destinationFileName, $destinationParentId);\n\n $response = $this->client->processImage($request);\n\n }", "title": "" }, { "docid": "5e1be3c33e28f167b7ef256fdec50813", "score": "0.500798", "text": "function __construct($region) {\n $this->region = strtolower($region);\n $this->utf8 = TRUE;\n $this->userAgent = \"Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1468.0 Safari/537.36\";\n }", "title": "" }, { "docid": "e3a75121e5f9e95253cb409649c21a88", "score": "0.5000584", "text": "public function serviceEndpoint(string $serviceEndpoint): S3ExternalAnalyticsLink\n {\n }", "title": "" }, { "docid": "b72c0fc80547254c7e01d515731a8c3f", "score": "0.49919298", "text": "protected function maybe_use_dns_bucket_name($storage, $config) {\n\t\tif ((!empty($config['endpoint']) && preg_match('/\\.aliyuncs\\.com$/i', $config['endpoint'])) || (!empty($config['bucket_access_style']) && 'virtual_host_style' === $config['bucket_access_style'])) {\n\t\t\t// due to the recent merge of S3-generic bucket access style on March 2021, if virtual-host bucket access style is selected, connecting to an amazonaws bucket location where the user doesn't have an access to it will throw an S3 InvalidRequest exception. It requires the signature to be set to version 4\n\t\t\tif (preg_match('/\\.amazonaws\\.com$/i', $config['endpoint'])) { \n\t\t\t\t$this->use_v4 = true;\n\t\t\t\t$storage->setSignatureVersion('v4');\n\t\t\t}\n\t\t\treturn $this->use_dns_bucket_name($storage, '');\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "title": "" }, { "docid": "8caee6b83c9f4781bd3fac3994980660", "score": "0.49789712", "text": "function isS3($url){\n\t\t$amazon_s3 = strpos($url, 'amazonaws');\n\t\t$amazon_cloudfront = strpos($url, 'cloudfront');\n\t\t$cover_no_journal = strpos($url, 'journal_cover');\n\n\t\tif (($amazon_s3 === false && $amazon_cloudfront === false) || $cover_no_journal !== false) {\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "title": "" }, { "docid": "b95a4ff20a04c4606ce08a0126d14fe2", "score": "0.49767402", "text": "private function addBuiltIns($args)\n {\n if ($args['region'] !== 'us-east-1') {\n return false;\n }\n $key = 'AWS::S3::UseGlobalEndpoint';\n $result = $args['s3_us_east_1_regional_endpoint'] instanceof \\Closure ?\n $args['s3_us_east_1_regional_endpoint']()->wait() : $args['s3_us_east_1_regional_endpoint'];\n\n if (is_string($result)) {\n if ($result === 'regional') {\n $value = false;\n } else if ($result === 'legacy') {\n $value = true;\n } else {\n return;\n }\n } else {\n if ($result->isFallback()\n || $result->getEndpointsType() === 'legacy'\n ) {\n $value = true;\n } else {\n $value = false;\n }\n }\n $this->clientBuiltIns[$key] = $value;\n }", "title": "" }, { "docid": "6a94096a4d266c9135091c1f4863fdd5", "score": "0.49703515", "text": "public function get_bucket_region($bucket, $opt = null)\n\t{\n\t\t// Add this to our request\n\t\tif (!$opt) $opt = array();\n\t\t$opt['verb'] = 'GET';\n\t\t$opt['sub_resource'] = 'location';\n\n\t\t// Authenticate to S3\n\t\t$response = $this->authenticate($bucket, $opt);\n\n\t\tif ($response->isOK())\n\t\t{\n\t\t\t// Handle body\n\t\t\t$response->body = (string) $response->body;\n\t\t}\n\n\t\treturn $response;\n\t}", "title": "" }, { "docid": "45333225c78d51cbd6e45efd5e98bc4c", "score": "0.49556348", "text": "public function SetRegion($region)\r\n\t\t{\r\n\t\t\tif (in_array($region, array('us-east-1', 'eu-west-1', 'us-west-1')))\r\n\t\t\t\t$this->Region = $region;\t\r\n\t\t}", "title": "" }, { "docid": "689654d9e3b1fec19a6040708ee160bd", "score": "0.49483994", "text": "public function __construct(array $options = array())\n\t{\n\t\t$this->vhost = null;\n\t\t$this->api_version = '2006-03-01';\n\t\t$this->hostname = self::DEFAULT_URL;\n\n\t\t$this->base_acp_xml = '<?xml version=\"1.0\" encoding=\"UTF-8\"?><AccessControlPolicy xmlns=\"http://s3.amazonaws.com/doc/latest/\"/>';\n\t\t$this->base_location_constraint = '<?xml version=\"1.0\" encoding=\"UTF-8\"?><CreateBucketConfiguration xmlns=\"http://s3.amazonaws.com/doc/' . $this->api_version . '/\"><LocationConstraint/></CreateBucketConfiguration>';\n\t\t$this->base_logging_xml = '<?xml version=\"1.0\" encoding=\"utf-8\"?><BucketLoggingStatus xmlns=\"http://doc.s3.amazonaws.com/' . $this->api_version . '\"/>';\n\t\t$this->base_notification_xml = '<?xml version=\"1.0\" encoding=\"utf-8\"?><NotificationConfiguration/>';\n\t\t$this->base_versioning_xml = '<?xml version=\"1.0\" encoding=\"utf-8\"?><VersioningConfiguration xmlns=\"http://s3.amazonaws.com/doc/' . $this->api_version . '/\"/>';\n\t\t$this->complete_mpu_xml = '<?xml version=\"1.0\" encoding=\"utf-8\"?><CompleteMultipartUpload/>';\n\t\t$this->website_config_xml = '<?xml version=\"1.0\" encoding=\"utf-8\"?><WebsiteConfiguration xmlns=\"http://s3.amazonaws.com/doc/' . $this->api_version . '/\"><IndexDocument><Suffix>index.html</Suffix></IndexDocument><ErrorDocument><Key>error.html</Key></ErrorDocument></WebsiteConfiguration>';\n\t\t$this->multi_object_delete_xml = '<?xml version=\"1.0\" encoding=\"utf-8\"?><Delete/>';\n\t\t$this->object_expiration_xml = '<?xml version=\"1.0\" encoding=\"utf-8\"?><LifecycleConfiguration/>';\n\t\t$this->bucket_tagging_xml = '<?xml version=\"1.0\" encoding=\"utf-8\"?><Tagging><TagSet/></Tagging>';\n\t\t$this->cors_config_xml = '<?xml version=\"1.0\" encoding=\"utf-8\"?><CORSConfiguration />';\n\n\t\tparent::__construct($options);\n\t}", "title": "" }, { "docid": "eedd8851af1751718d43cdcac6a94f00", "score": "0.49478075", "text": "function get_image_url( $bucket, $region, $file_path ){\r\n\t\t\treturn sprintf(\r\n\t\t\t\t'%s/%s',\r\n\t\t\t\tuntrailingslashit( \r\n\t\t\t\t\tapply_filters( \r\n\t\t\t\t\t\t'amazon_s3_prefix_bucket', \r\n\t\t\t\t\t\t\"https://{bucket}.s3-{region}.amazonaws.com/\", \r\n\t\t\t\t\t\t$region, \r\n\t\t\t\t\t\t$bucket \r\n\t\t\t\t\t) \r\n\t\t\t\t),\r\n\t\t\t\t$file_path\r\n\t\t\t);\r\n\t\t}", "title": "" }, { "docid": "053d3dc35530e992a4b10f258bfb8a88", "score": "0.49443397", "text": "private function isStsLegacyEndpointUsed($service, $region, $options)\n {\n return $service === 'sts'\n && in_array($region, $this->stsLegacyGlobalRegions)\n && (empty($options['sts_regional_endpoints'])\n || ConfigurationProvider::unwrap(\n $options['sts_regional_endpoints']\n )->getEndpointsType() !== 'regional'\n );\n }", "title": "" }, { "docid": "99dddf34cb73a209ca34f50d8a33a417", "score": "0.49370134", "text": "function aws_get_uploaded_entity_options(array $params = []) {\n\t\n\t$subtypes = aws_get_supported_upload_subtypes();\n\tif (empty($subtypes)) {\n\t\treturn false;\n\t}\n\t\n\t$options = [\n\t\t'type_subtype_pairs' => [\n\t\t\t'object' => $subtypes,\n\t\t],\n\t\t'wheres' => [],\n\t\t'metadata_name_value_pairs' => [],\n\t];\n\t\n\t$inverted = (bool) elgg_extract('aws_inverted', $params, false);\n\tunset($params['aws_inverted']);\n\t\n\tif ($inverted) {\n\t\t$options['wheres'][] = function (QueryBuilder $qb, $main_alias) {\n\t\t\t$sub = $qb->subquery('metadata');\n\t\t\t$sub->select('entity_guid')\n\t\t\t\t->where($qb->compare('name', '=', 'aws_object_url', ELGG_VALUE_STRING));\n\t\t\t\n\t\t\treturn $qb->compare(\"{$main_alias}.guid\", 'NOT IN', $sub->getSQL());\n\t\t};\n\t} else {\n\t\t$options['metadata_name_value_pairs'][] = [\n\t\t\t'name' => 'aws_object_url',\n\t\t\t'value' => '',\n\t\t\t'operand' => '!=',\n\t\t\t'case_sensitive' => false,\n\t\t];\n\t}\n\t\n\treturn array_merge_recursive($options, $params);\n}", "title": "" }, { "docid": "18b35351e609c5b72942a75ea5230bed", "score": "0.49355114", "text": "public function getAwsRegion()\n {\n return $this->aws_region;\n }", "title": "" }, { "docid": "a9709d6a54a2b359a7e006e175099ae8", "score": "0.48875642", "text": "function new_vala_getsemibyregion_($region,$dev=false,$cacheit=false,$expiry=3600){\n return new_vala_fetch_api_cached('applications',$region,'semi',$expiry,$cacheit);\n}", "title": "" }, { "docid": "4901b33100d0774546ff804917f9ec8d", "score": "0.48803338", "text": "public function getResponse()\n\t{\n\t\t$query = '';\n\t\tif (sizeof($this->parameters) > 0)\n\t\t{\n\t\t\t$query = substr($this->uri, -1) !== '?' ? '?' : '&';\n\t\t\tforeach ($this->parameters as $var => $value)\n\t\t\t\tif ($value == null || $value == '')\n\t\t\t\t\t$query .= $var . '&';\n\t\t\t\t// Parameters should be encoded (thanks Sean O'Dea)\n\t\t\t\telse\n\t\t\t\t\t$query .= $var . '=' . rawurlencode($value) . '&';\n\t\t\t$query = substr($query, 0, -1);\n\t\t\t$this->uri .= $query;\n\n\t\t\tif (array_key_exists('acl', $this->parameters) ||\n\t\t\t\t\tarray_key_exists('location', $this->parameters) ||\n\t\t\t\t\tarray_key_exists('torrent', $this->parameters) ||\n\t\t\t\t\tarray_key_exists('logging', $this->parameters))\n\t\t\t\t$this->resource .= $query;\n\t\t}\n\t\t$url = ((S3::$use_ssl && extension_loaded('openssl')) ?\n\t\t\t\t\t\t'https://' : 'http://') . $this->headers['Host'] . $this->uri;\n\t\t//var_dump($this->bucket, $this->uri, $this->resource, $url);\n\t\t// Basic setup\n\t\t$curl = curl_init();\n\t\tcurl_setopt($curl, CURLOPT_USERAGENT, 'S3/php');\n\n\t\tif (S3::$use_ssl)\n\t\t{\n\t\t\tcurl_setopt($curl, CURLOPT_SSL_VERIFYHOST, 2);\n\t\t\tif (S3::$verify_peer)\n\t\t\t{\n\t\t\t curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, 1);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);\n\t\t\t}\n\t\t}\n\n\t\tcurl_setopt($curl, CURLOPT_URL, $url);\n\n\t\t// Headers\n\t\t$headers = array();\n\t\t$amz = array();\n\t\tforeach ($this->amzHeaders as $header => $value)\n\t\t\tif (strlen($value) > 0)\n\t\t\t\t$headers[] = $header . ': ' . $value;\n\t\tforeach ($this->headers as $header => $value)\n\t\t\tif (strlen($value) > 0)\n\t\t\t\t$headers[] = $header . ': ' . $value;\n\n\t\t// Collect AMZ headers for signature\n\t\tforeach ($this->amzHeaders as $header => $value)\n\t\t\tif (strlen($value) > 0)\n\t\t\t\t$amz[] = strtolower($header) . ':' . $value;\n\n\t\t// AMZ headers must be sorted\n\t\tif (sizeof($amz) > 0)\n\t\t{\n\t\t\tsort($amz);\n\t\t\t$amz = \"\\n\" . implode(\"\\n\", $amz);\n\t\t} else\n\t\t\t$amz = '';\n\n\t\t// Authorization string (CloudFront stringToSign should only contain a date)\n\t\t$headers[] = 'Authorization: ' . S3::__getSignature(\n\t\t\t\t\t\t$this->headers['Host'] == 'cloudfront.amazonaws.com' ? $this->headers['Date'] :\n\t\t\t\t\t\t\t\t$this->verb . \"\\n\" . $this->headers['Content-MD5'] . \"\\n\" .\n\t\t\t\t\t\t\t\t$this->headers['Content-Type'] . \"\\n\" . $this->headers['Date'] . $amz . \"\\n\" . $this->resource\n\t\t);\n\n\t\tcurl_setopt($curl, CURLOPT_HTTPHEADER, $headers);\n\t\tcurl_setopt($curl, CURLOPT_HEADER, false);\n\t\tcurl_setopt($curl, CURLOPT_RETURNTRANSFER, false);\n\t\tcurl_setopt($curl, CURLOPT_WRITEFUNCTION, array(&$this, '__responseWriteCallback'));\n\t\tcurl_setopt($curl, CURLOPT_HEADERFUNCTION, array(&$this, '__responseHeaderCallback'));\n\t\tcurl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);\n\n\t\t// Request types\n\t\tswitch ($this->verb)\n\t\t{\n\t\t\tcase 'GET': break;\n\t\t\tcase 'PUT': case 'POST': // POST only used for CloudFront\n\t\t\t\tif ($this->fp !== false)\n\t\t\t\t{\n\t\t\t\t\tcurl_setopt($curl, CURLOPT_PUT, true);\n\t\t\t\t\tcurl_setopt($curl, CURLOPT_INFILE, $this->fp);\n\t\t\t\t\tif ($this->size >= 0)\n\t\t\t\t\t\tcurl_setopt($curl, CURLOPT_INFILESIZE, $this->size);\n\t\t\t\t} elseif ($this->data !== false)\n\t\t\t\t{\n\t\t\t\t\tcurl_setopt($curl, CURLOPT_CUSTOMREQUEST, $this->verb);\n\t\t\t\t\tcurl_setopt($curl, CURLOPT_POSTFIELDS, $this->data);\n\t\t\t\t\tif ($this->size >= 0)\n\t\t\t\t\t\tcurl_setopt($curl, CURLOPT_BUFFERSIZE, $this->size);\n\t\t\t\t} else\n\t\t\t\t\tcurl_setopt($curl, CURLOPT_CUSTOMREQUEST, $this->verb);\n\t\t\t\tbreak;\n\t\t\tcase 'HEAD':\n\t\t\t\tcurl_setopt($curl, CURLOPT_CUSTOMREQUEST, 'HEAD');\n\t\t\t\tcurl_setopt($curl, CURLOPT_NOBODY, true);\n\t\t\t\tbreak;\n\t\t\tcase 'DELETE':\n\t\t\t\tcurl_setopt($curl, CURLOPT_CUSTOMREQUEST, 'DELETE');\n\t\t\t\tbreak;\n\t\t\tdefault: break;\n\t\t}\n\n\t\t// Execute, grab errors\n\t\tif (curl_exec($curl))\n\t\t\t$this->response->code = curl_getinfo($curl, CURLINFO_HTTP_CODE);\n\t\telse\n\t\t\t$this->response->error = array(\n\t\t\t\t'code' => curl_errno($curl),\n\t\t\t\t'message' => curl_error($curl),\n\t\t\t\t'resource' => $this->resource\n\t\t\t);\n\n\t\t@curl_close($curl);\n\n\t\t// Parse body\n\t\tif ($this->response->error === false && isset($this->response->headers['type']) && isset($this->response->body))\n\t\t{\n\t\t\tif($this->response->headers['type'] == 'application/json')\n\t\t\t{\n\t\t\t\t$this->response->body = json_decode($this->response->body);\n\t\t\t}elseif($this->response->headers['type']== 'application/xml')\n\t\t\t{\n\t\t\t\t$this->response->body = simplexml_load_string($this->response->body);\n\t\t\t}\n\t\t\t// Grab S3 errors\n\t\t\tif (!in_array($this->response->code, array(200, 204)) &&\n\t\t\t\t\tisset($this->response->body->Code, $this->response->body->Message))\n\t\t\t{\n\t\t\t\t$this->response->error = array(\n\t\t\t\t\t'code' => (string) $this->response->body->Code,\n\t\t\t\t\t'message' => (string) $this->response->body->Message\n\t\t\t\t);\n\t\t\t\tif (isset($this->response->body->Resource))\n\t\t\t\t\t$this->response->error['resource'] = (string) $this->response->body->Resource;\n\t\t\t\tunset($this->response->body);\n\t\t\t}\n\t\t}\n\n\t\t// Clean up file resources\n\t\tif ($this->fp !== false && is_resource($this->fp))\n\t\t\tfclose($this->fp);\n\n\t\treturn $this->response;\n\t}", "title": "" }, { "docid": "752221c6b7f14a6fa44ab18cb7139d56", "score": "0.48527178", "text": "public static function setRegion($region)\n {\n if(in_array(strtolower($region), self::$_validEc2Regions, true)) {\n self::$_defaultRegion = $region;\n } else {\n // require_once 'Zend/Service/Amazon/Exception.php';\n throw new Zend_Service_Amazon_Exception('Invalid Amazon Ec2 Region');\n }\n }", "title": "" }, { "docid": "880ea5a70f37362d0c4dd50519afe68f", "score": "0.4840056", "text": "public function getStsRegionalEndpoints();", "title": "" }, { "docid": "f281904126f79cede8610aadb05d5185", "score": "0.48364994", "text": "public function setRegion($region);", "title": "" }, { "docid": "662910eff61adc18fdf1805ba6be224b", "score": "0.48270106", "text": "public static function US_CENTRAL_1()\n {\n return new GoogleCloudRegion(self::US_CENTRAL_1);\n }", "title": "" }, { "docid": "67df01073e6fba385e92b7141ad99a82", "score": "0.4813664", "text": "public function getCacheRegion();", "title": "" }, { "docid": "a9f351c7c68c43d86a0aa73c6c859995", "score": "0.4813051", "text": "public function test_url_should_provide_local_url_if_no_sha()\n\t{\n\t\t$this->test_url_should_be_prefixed_according_to_mode_and_sha(\n\t\t\t\tAs3et::MODE_S3, 'foo.bar', 'assets/foo.bar', NULL);\n\t}", "title": "" }, { "docid": "73cca395f6c731007d3446a4b843f635", "score": "0.48016304", "text": "public function setRegion($region) {\n\t\t$region = trim(strtolower($region));\n\t\t$possibleValues = array('us','eu_uk','cn');\n\t\tif (array_search($region, $possibleValues)) {\n\t\t\t$this->region = $region;\n\t\t}\n\t}", "title": "" }, { "docid": "4cff7249af67c31bc05b5e0ef466338b", "score": "0.4782035", "text": "public function isSpecial() {\n\t\treturn $this->region == null && in_array(\"'\".$this->url.\"'\", $this->defaultNames);\n\t}", "title": "" }, { "docid": "b99fcec4cfa2b211d50b061f8bbf26dd", "score": "0.47785595", "text": "private function prefixCheckAndSetDefaultVal($region, VodUploadRequest $uploadRequest)\n {\n if (empty($region)) {\n throw new VodClientException(\"lack region\");\n }\n if (empty($uploadRequest->MediaFilePath)) {\n throw new VodClientException(\"lack media path\");\n }\n if (!file_exists($uploadRequest->MediaFilePath)) {\n throw new VodClientException(\"media path is invalid\");\n }\n if (empty($uploadRequest->MediaType)) {\n $mediaType = FileUtil::getFileType($uploadRequest->MediaFilePath);\n if (empty($mediaType)) {\n throw new VodClientException(\"lack media type\");\n }\n $uploadRequest->MediaType = $mediaType;\n }\n if (empty($uploadRequest->MediaName)) {\n $uploadRequest->MediaName = FileUtil::getFileName($uploadRequest->MediaFilePath);\n }\n\n if (!empty($uploadRequest->CoverFilePath)) {\n if (!file_exists($uploadRequest->CoverFilePath)) {\n throw new VodClientException(\"cover path is invalid\");\n }\n if (empty($uploadRequest->CoverType)) {\n $coverType = FileUtil::getFileType($uploadRequest->CoverFilePath);\n if (empty($coverType)) {\n throw new VodClientException(\"lack cover type\");\n }\n $uploadRequest->CoverType = $coverType;\n }\n }\n }", "title": "" }, { "docid": "2955329dcb152558c94f191abd91b846", "score": "0.4772341", "text": "public function getEngineIdentifier(): string {\n return 'aws-s3';\n }", "title": "" }, { "docid": "70bc2bd6a6aa01c6e12053b12c377895", "score": "0.4764119", "text": "public function getTestApiKeySapi3();", "title": "" }, { "docid": "0b7519f8cdac94a3c39cd8b5406d8297", "score": "0.47214654", "text": "public function __construct() {\n $this -> _s3 = new Aws\\S3\\S3Client([\n 'version' => 'latest',\n 'region' => AWS_REGION,\n 'credentials' => array(\n 'key' => AWS_ACCESS_KEY_ID,\n 'secret' => AWS_SECRET\n )\n ]);\n }", "title": "" }, { "docid": "e8c1683cac01f94a005f5de484ed5266", "score": "0.471066", "text": "function aws_upload_file(\\ElggFile $file) {\n\t\n\tif (empty($file->guid) || !$file->getFilename()) {\n\t\treturn false;\n\t}\n\t\n\t$key = aws_get_entity_key($file);\n\tif (empty($key)) {\n\t\treturn false;\n\t}\n\t\n\t$bucket = elgg_get_plugin_setting('s3_bucket', 'aws');\n\t$s3client = aws_get_s3_client();\n\t\n\tif (empty($bucket) || empty($s3client)) {\n\t\treturn false;\n\t}\n\t\n\t$uploader = new ObjectUploader(\n\t\t$s3client,\n\t\t$bucket,\n\t\t$key,\n\t\t$file->grabFile(),\n\t\t'private',\n\t\t[\n\t\t\t'params' => [\n\t\t\t\t'ContentType' => $file->getMimeType(),\n\t\t\t],\n\t\t]\n\t);\n\t\n\ttry {\n\t\t/* @var $result Aws\\Result */\n\t\t$result = $uploader->upload();\n\t\t\n\t\t$url = $result->get('ObjectURL');\n\t\t\n\t\t// store s3 location with the file\n\t\t$file->aws_object_url = $url;\n\t} catch (\\Exception $e) {\n\t\treturn false;\n\t}\n\t\n\treturn true;\n}", "title": "" }, { "docid": "ba2a678348d066690b45e889a2bd0b7f", "score": "0.47098154", "text": "function full_mend_s3_path( $wrapped ) {\n\n //Remove URL-encoded strings\n $fixed_s3 = preg_replace(\"/\\%[0-9ABCDEF]{2}/\", \"\",\n $wrapped->field_s3_path->value() );\n\n //Prepare problem punctuation\n $replacements = array(\n '—' => '-',\n '―' => '-',\n \"'\" => '',\n \"’\" => '',\n );\n //Replace\n $fixed_s3 = str_replace(array_keys($replacements), $replacements, $fixed_s3);\n\n //Map French-accented chars to unadorned equivalents due to S3-signing fail\n $fixed_s3 = html_entity_decode(\n preg_replace(\n '~&([a-z]{1,2})(\n ?:acute|cedil|circ|grave|lig|orn|ring|slash|th|tilde|uml\n );~i',\n '$1',\n htmlentities($fixed_s3, ENT_QUOTES, 'UTF-8')\n ),\n ENT_QUOTES,\n 'UTF-8'\n );\n\n $wrapped->field_s3_path->set($fixed_s3);\n $file = file_load((int) $wrapped->field_s3_file_upload->file->getIdentifier());\n $file->filename = $fixed_s3;\n\n //Effect changes on file entity and S3 object\n module_load_include('inc', 'cals_s3', 'cals_s3.NNELSStreamWrapper.class');\n $stream = new \\Drupal\\cals_s3\\NNELSStreamWrapper;\n $stream->setUri(urldecode($file->uri));\n $stream->rename($stream->getUri(), $fixed_s3);\n\n //Finalize and save\n $file->uri = $fixed_s3;\n file_save($file);\n $wrapped->save();\n}", "title": "" }, { "docid": "8b4ed4e88a7ca3203828820b05d37a9d", "score": "0.47053692", "text": "function isValidRegion($region = '')\n{\n\treturn array_key_exists($region, getRegions());\n}", "title": "" }, { "docid": "798e339f18fe3a2e5c056fad5820b957", "score": "0.47012505", "text": "public function __construct()\n {\n parent::__construct();\n $this->bucket = config('flysystem.connections.awss3.bucket');\n\n $this->request = new Client([\n 'base_uri' => 'https://tvmwznbdlk.execute-api.us-west-2.amazonaws.com/prod/'\n ]);\n }", "title": "" }, { "docid": "5604d046007de666adac484918ee079f", "score": "0.46961606", "text": "function aws_parse_s3_uri($uri) {\n\t\n\tif (empty($uri) || !is_string($uri)) {\n\t\treturn false;\n\t}\n\t\n\t$parser = new S3UriParser();\n\ttry {\n\t\treturn $parser->parse($uri);\n\t} catch (Exception $e) {\n\t\telgg_log(__METHOD__ . \" parsing failed for URI '{$uri}': {$e->getMessage()}\", 'WARNING');\n\t}\n\t\n\treturn false;\n}", "title": "" }, { "docid": "8336815eb06a0067ba2110bae9997932", "score": "0.46922892", "text": "function aws_get_object_by_uri($uri) {\n\t\n\tif (empty($uri) || !is_string($uri)) {\n\t\treturn false;\n\t}\n\t\n\t$pr = aws_parse_s3_uri($uri);\n\tif (empty($pr)) {\n\t\treturn false;\n\t}\n\t\n\t$s3client = aws_get_s3_client();\n\tif (empty($s3client)) {\n\t\treturn false;\n\t}\n\t\n\ttry {\n\t\treturn $s3client->getObject([\n\t\t\t'Bucket' => elgg_extract('bucket', $pr),\n\t\t\t'Key' => elgg_extract('key', $pr),\n\t\t]);\n\t} catch (\\Exception $e) {\n\t\telgg_log(__METHOD__ . \" failed for URI '{$uri}': {$e->getMessage()}\");\n\t}\n\t\n\treturn false;\n}", "title": "" }, { "docid": "b8fd66eafab41027ab8781459f506e2f", "score": "0.46884018", "text": "public function getRegion();", "title": "" }, { "docid": "b8fd66eafab41027ab8781459f506e2f", "score": "0.46884018", "text": "public function getRegion();", "title": "" }, { "docid": "9349598271693cebe78254f4a69b8eeb", "score": "0.4681261", "text": "public function create_bucket($bucket, $region, $acl = self::ACL_PRIVATE, $opt = null)\n\t{\n\t\t// If the bucket contains uppercase letters...\n\t\tif (preg_match('/[A-Z]/', $bucket))\n\t\t{\n\t\t\t// Throw a warning\n\t\t\ttrigger_error('Since DNS-valid bucket names cannot contain uppercase characters, \"' . $bucket . '\" has been automatically converted to \"' . strtolower($bucket) . '\"', E_USER_WARNING);\n\n\t\t\t// Force the bucketname to lowercase\n\t\t\t$bucket = strtolower($bucket);\n\t\t}\n\n\t\t// Validate the S3 bucket name for creation\n\t\tif (!$this->validate_bucketname_create($bucket))\n\t\t{\n\t\t\t// @codeCoverageIgnoreStart\n\t\t\tthrow new S3_Exception('\"' . $bucket . '\" is not DNS-valid (i.e., <bucketname>.s3.amazonaws.com), and cannot be used as an S3 bucket name. Review \"Bucket Restrictions and Limitations\" in the S3 Developer Guide for more information.');\n\t\t\t// @codeCoverageIgnoreEnd\n\t\t}\n\n\t\tif (!$opt) $opt = array();\n\t\t$opt['verb'] = 'PUT';\n\t\t$opt['headers'] = array(\n\t\t\t'Content-Type' => 'application/xml'\n\t\t);\n\n\t\t// Handle Access Control Lists. Can also be passed as an HTTP header.\n\t\tif (isset($acl))\n\t\t{\n\t\t\tif (is_array($acl))\n\t\t\t{\n\t\t\t\t$opt['headers'] = array_merge($opt['headers'], $this->generate_access_policy_headers($acl));\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$opt['headers']['x-amz-acl'] = $acl;\n\t\t\t}\n\t\t}\n\n\t\t// Defaults\n\t\t$this->set_region($region); // Also sets path-style\n\t\t$xml = simplexml_load_string($this->base_location_constraint);\n\n\t\tswitch ($region)\n\t\t{\n\t\t\tcase self::REGION_US_E1: // Northern Virginia\n\t\t\t\t$opt['body'] = '';\n\t\t\t\tbreak;\n\n\t\t\tcase self::REGION_EU_W1: // Ireland\n\t\t\t\t$xml->LocationConstraint = 'EU';\n\t\t\t\t$opt['body'] = $xml->asXML();\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\t$xml->LocationConstraint = str_replace(array('s3-', '.amazonaws.com'), '', $region);\n\t\t\t\t$opt['body'] = $xml->asXML();\n\t\t\t\tbreak;\n\t\t}\n\n\t\t$response = $this->authenticate($bucket, $opt);\n\n\t\t// Make sure we're set back to DNS-style URLs\n\t\t$this->enable_path_style(false);\n\n\t\treturn $response;\n\t}", "title": "" }, { "docid": "fd3f5d0cbc9f42218ec601293a50e349", "score": "0.466918", "text": "public function setRegion(string $region)\n {\n $region .= in_array($region, ['ru', 'kr']) ? '' : '1';\n $this->apiUrl = str_replace('{region}', $region, self::API_URL);\n }", "title": "" }, { "docid": "c19b4e0743290abb021a40c93a7a443c", "score": "0.46680838", "text": "function amazon_ses_get_endpoint() {\n\t$region = get_option( 'amazon_ses_region' );\n\n\treturn 'https://email.' . $region . '.amazonaws.com';\n}", "title": "" }, { "docid": "c436b3daf5e4ced3acb38e48d3cec951", "score": "0.46669236", "text": "public function test_create_aws()\n {\n $subscription = new Subscription($this->awss3);\n\n vfsstream::newFile('56aaa297a8019.ics')\n ->at(vfsStreamWrapper::getRoot());\n\n $subscription\n ->set_language(Language::SPANISH)\n ->set_prodid('@hulihealth.com')\n ->set_cal_name('Calendario Huli Practice')\n ->set_cal_desc('Lorem itsum Lorem itsum')\n ->set_relcaid('1232131231321')\n ->set_tmp_directory(vfsstream::url('root'))\n ->set_time_zone($this->time_zone)\n ->create();\n\n $this->assertEquals(\n $subscription->public_location,\n \"https://s3-us-west-2.amazonaws.com/calendar.dev.subscription/56aaa297a8019.ics\"\n );\n }", "title": "" }, { "docid": "161999984510306f20dc193efaa72799", "score": "0.46656045", "text": "function storage_url() {\n //return \"https://s3-eu-west-1.amazonaws.com/herbhub/\";\n // return \"https://d1gqywsp3zybzt.cloudfront.net/\";\n return '/'.'storage/';\n }", "title": "" }, { "docid": "ac0bd0b10ed54df3c2dbb68dfa7678fb", "score": "0.46425843", "text": "public function __construct() {\n $this->client = new Aws\\S3\\S3Client([\n 'version' => 'latest',\n 'region' => Config::CDN_REGION(),\n 'endpoint' => Config::CDN_BASE_URL(),\n 'credentials' => [\n 'key' => Config::CDN_KEY(),\n 'secret' => Config::CDN_SECRET()\n ]\n ]);\n }", "title": "" }, { "docid": "008385838b7aee4999d122e7fdbf4e36", "score": "0.4621667", "text": "private function _getAWSStorageClass()\n {\n switch (craft()->imager->getSetting('awsStorageType')) {\n case 'standard':\n return \\S3::STORAGE_CLASS_STANDARD;\n case 'rrs':\n return \\S3::STORAGE_CLASS_RRS;\n }\n return \\S3::STORAGE_CLASS_STANDARD;\n }", "title": "" }, { "docid": "972bda49aea6ac3928be5678076185f1", "score": "0.461041", "text": "protected function BenchmarkArchiverS3($options) {}", "title": "" }, { "docid": "3ba74cd4fe24a0b274a4a01edc3f2c2f", "score": "0.46078274", "text": "function new_vala_getcategoriesbyregion($region,$dev=false){\n if( $dev )\n return new_vala_fetch_api_('getcategoriesbyregion',$region); \n else\n return new_vala_fetch_api('getcategoriesbyregion',$region,$dev);\n}", "title": "" }, { "docid": "4868f862f06ca6d3c4b1f29d43e84244", "score": "0.46008056", "text": "function amazon_get_buckets() {\r\n\t\t\tif( ! isset( $this->buckets ) ){\r\n\t\t\t\ttry{\r\n\t\t\t\t\t$this->buckets = S3::listBuckets();\r\n\t\t\t\t} catch (\\Throwable $th) {\r\n\t\t\t\t\t\r\n\t\t\t\t\t/**\r\n\t\t\t\t\t * Try to search the correct region from error message\r\n\t\t\t\t\t */\r\n\t\t\t\t\t$regex = sprintf( '/the region \\'%s\\' is wrong; expecting \\'([\\w|\\d|\\-]+)\\'/', S3::getRegion() );\r\n\t\t\t\t\tpreg_match( $regex, $th->getMessage(), $matches );\r\n\r\n\t\t\t\t\tif( isset( $matches[1] ) ){\r\n\t\t\t\t\t\tS3::setRegion( $matches[1] );\r\n\t\t\t\t\t\t$this->buckets = S3::listBuckets();\r\n\t\t\t\t\t\treturn $this->buckets;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tthrow $th;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\treturn $this->buckets;\r\n\t\t}", "title": "" }, { "docid": "6449ac14ff1a90611b3c21756c86691a", "score": "0.45985854", "text": "function uploadFileIntoS3($file_path,$file_name){\n\n$argv = array(BUCKET_NAME,$file_path);\n\nif (count($argv) < 2) {\n echo $USAGE;\n exit();\n}\n\n$bucket = $argv[0];\n$file_path = $argv[1];\n$key = $file_name; \n\ntry {\n\n$credentials = new Aws\\Credentials\\Credentials(AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY,TOKEN);\n\n\n$s3 = new Aws\\S3\\S3Client([\n 'version' => 'latest',\n 'region' => REGION,\n 'credentials' => $credentials\n]);\n\n $result = $s3->putObject([\n 'Bucket' => $bucket,\n 'Key' => $key,\n 'SourceFile' => $file_path,\n 'ACL' => 'public-read',\n\n\n ]);\n \n} catch (S3Exception $e) {\n echo $e->getMessage() . \"\\n\";\n}\n}", "title": "" }, { "docid": "d2d97aa78b04ac995d31d6d46aa34a41", "score": "0.4594702", "text": "function region($request)\n\t{\n\t\tlist($success, $return) = $this->system->is_valid_access4($request);\n\t\tif (!$success) return [FALSE, $return];\n\n\t\t$this->db->select('RegionID, RegionCode, RegionName');\n \t$this->db->from('parameter_securities_region');\n\t\t $data = $this->f->get_result_paging($request);\n\n\t\t $request->log_type\t= 'data';\t\n\t\t$this->system->save_billing($request);\n\n\t\treturn $data;\n }", "title": "" }, { "docid": "795410be5c79b3ff16ba02502ca79fc4", "score": "0.45644283", "text": "public function region() {\n return $this->region;\n }", "title": "" }, { "docid": "e8af08acf56f3e53e0e236f227480fe8", "score": "0.45581847", "text": "function osc_premium_region() {\n return (string) osc_premium_field(\"s_region\");\n }", "title": "" }, { "docid": "a63c007c08b2f22150384a29226c3168", "score": "0.4554749", "text": "public function setRegion($value);", "title": "" }, { "docid": "14f758eaea9c748b8f2e6ee23e91b81e", "score": "0.45509472", "text": "function S3($options = NULL) {\n\t\t\n\t\t$this->obj =& get_instance();\n\t\t\n\t\tlog_message('debug', \"S3 ::: Library Loaded\");\n\t\t\n\t\tdefine('DATE_RFC822_S3', 'D, d M Y H:i:s T');\n\t\t$this->httpDate = gmdate(DATE_RFC822_S3);\n\t\t\n\t\tif(isset($options['keyId']))\n\t\t{\n\t\t\t$this->keyId = $options['keyId'];\n\t\t\tunset($options['keyId']);\n\t\t}\n\t\tif(isset($options['secretKey']))\n\t\t{\n\t\t\t$this->secretKey = $options['secretKey'];\n\t\t\tunset($options['secretKey']);\n\t\t}\n\n\t\t$available_options = array(\"acl\", \"contentType\");\n\n\t\tif (is_array($options)) {\n\n\t\t\tforeach ($options as $key => $value) {\n\n\t\t\t\t$this->debug_text(\"Option: $key\");\n\n\t\t\t\tif (in_array($key, $available_options) ) {\n\n\t\t\t\t\t$this->debug_text(\"Valid Config options: $key\");\n\t\t\t\t\t$property = '_'.$key;\n\t\t\t\t\t$this->$property = $value;\n\t\t\t\t\t$this->debug_text(\"Setting $property to $value\");\n\n\t\t\t\t} else {\n\n\t\t\t\t\t$this->debug_text(\"ERROR: Config option: $key is not a valid option\");\n\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t}\n\n // REQUIRES PEAR PACKAGE\n\t\t// get with \"pear install Crypt_]\"\n\t\trequire_once 'Crypt/HMAC.php';\n\t\t// \n\t\t$this->hasher = new Crypt_HMAC($this->secretKey, \"sha1\");\n\t\t\n\t\t// REQUIRES PEAR PACKAGE\n\t\t// get with \"pear install --onlyreqdeps HTTP_Request\"\n\t\t\n\t\t// NOTE FROM AMAZON:\n\t\t//\n\t\t// Note that version HTTP_Request 1.3.0 has a BUG in it! Change line\n\t\t// 765 from:\n\t\t// (HTTP_REQUEST_METHOD_POST != $this->_method && empty($this->_postData) && empty($this->_postFiles))) {\n\t\t// to:\n\t\t// (HTTP_REQUEST_METHOD_POST == $this->_method && empty($this->_postData) && empty($this->_postFiles))) {\n\t\t//\n\t\t// Without this change PUTs with non-empty content-type will fail!\n\t\t\n\t\trequire_once 'HTTP/Request.php';\n\n\t}", "title": "" }, { "docid": "fa7b419a89efb021aab13e82c9543a88", "score": "0.45429644", "text": "function getSignedUploadUrl($file) {\n\n $object = $this->gs_bucket->object($file);\n\n /*\n $url = $object->signedUploadUrl(new \\DateTime('tomorrow'), [\n 'version' => 'v4'\n ]);\n\n _printe($url);\n */\n if(false) {\n $url = $object->beginSignedUploadSession( [\n 'version' => 'v4'\n ]);\n }\n\n if(true) {\n $signed_upload_url = $object->signedUploadUrl(new \\DateTime('15 min'), [\n 'version' => 'v4',\n 'predefinedAcl' => 'publicRead',\n 'saveAsName' => 'test2.txt',\n ]);\n\n $headers = [\n 'Content-Length' => 0,\n 'x-goog-resumable' => 'start',\n 'Origin' => '*'\n ];\n\n // step 2 - beginSignedUploadSession (POST)\n $response = $this->core->request->post($signed_upload_url, null, $headers);\n\n if (in_array($this->core->request->getLastResponseCode(), [200, 201])) {\n $url = $this->core->request->getResponseHeader('Location');\n } else {\n die('error');\n }\n }\n\n // This is to upload but it requires a Google Signature\n if(false) {\n $url = $object->signedUrl(\n # This URL is valid for 15 minutes\n new \\DateTime('15 min'),\n [\n 'method' => 'PUT',\n 'contentType' => 'application/octet-stream',\n 'version' => 'v4',\n ]\n );\n }\n\n return($url);\n /*\n if(!$returnUrl) $returnUrl = $this->vars['retUploadUrl'];\n else $this->vars['retUploadUrl'] = $returnUrl;\n $options = array( 'gs_bucket_name' => str_replace('gs://','',$this->bucket) );\n $upload_url = CloudStorageTools::createUploadUrl($returnUrl, $options);\n return($upload_url);\n */\n }", "title": "" }, { "docid": "307a0737ee9727fff4e520091efdbafd", "score": "0.4524779", "text": "function awsAccess()\n\t{\n\t\t$this->AwsFiles = TableRegistry::get('AwsFiles');\n\t\t$AwsFiles=$this->AwsFiles->find()->first();\n\t\t$this->bucketName=$AwsFiles->bucket_name; // Bucket Name\n\t\t$this->cdn_path=$AwsFiles->cdn_path; // CDN Path\n\t\t$this->awsAccessKey=$AwsFiles->access_key; // Access Key\n\t\t$this->awsSecretAccessKey=$AwsFiles->secret_access_key; // Secret Access key\n\t}", "title": "" }, { "docid": "ff7c9fd0b06a6dc658528f3869582a2c", "score": "0.45234582", "text": "private function isAmazon()\n\t{\t\t$return = false;\n\t\tif ($this->posting['filelocal'] == false)\n\t\t{\n\t\t\tif (strpos($this->posting['audio_file'], 's3.amazonaws.com') !== false)\n\t\t\t{\n\t\t\t\t$return = true;\n\t\t\t}\n\t\t}\n\t\treturn $return;\n\t}", "title": "" }, { "docid": "1271a7f52e7c8cd128298e3a24a515da", "score": "0.45184436", "text": "private function _getS3Object() {\n if (is_null($this->s3)) {\n $this->s3 = new \\S3(craft()->imager->getSetting('awsAccessKey'), craft()->imager->getSetting('awsSecretAccessKey'));\n $this->s3->setExceptions(true);\n } \n \n return $this->s3;\n }", "title": "" }, { "docid": "795f0dd946a818846b69301aa449f332", "score": "0.4504292", "text": "function lambda_preprocess_region(&$variables) {\n if ($variables['region'] == 'branding') {\n $variables['lambda_ualogo'] = lambda_ualogo();\n $variables['lambda_uabanner'] = lambda_uabanner();\n }\n}", "title": "" }, { "docid": "4b91a82f8bd2d85a9368ab2c2872b138", "score": "0.45018432", "text": "public function useDNSBucketName($use = true, $bucket = '') {\n\t\t$this->use_dns_bucket_name = $use;\n\t\tif ($use && $bucket) {\n\t\t\t$this->setEndpoint($bucket.'.s3.amazonaws.com', $this->region);\n\t\t}\n\t\treturn true;\n\t}", "title": "" }, { "docid": "a236d80323075a4c74cecad4f8f9e6fd", "score": "0.4484345", "text": "public function setRegionNoFormat(\n string $config_name, string $region_name, bool $no_format ) : Asset\n {\n if( !isset( $this->page_configuration_map[ $config_name ] ) )\n {\n throw new e\\NoSuchPageConfigurationException( \n S_SPAN . \"The page configuration $config_name does not exist.\" . E_SPAN );\n }\n \n $this->page_configuration_map[ $config_name ]->setRegionNoFormat( $region_name, $no_format );\n \n return $this;\n }", "title": "" }, { "docid": "cd1662742114efab7d99c032f492959f", "score": "0.4483409", "text": "function uploadImageToAmazone() {\n $name = $_FILES['OtherPhoto']['name']; // filename to get file's extension\n $size = $_FILES['OtherPhoto']['size'];\n\n $fold_name = $_REQUEST['folder'];\n $type = $_REQUEST['type'];\n\n $ext = substr($name, strrpos($name, '.') + 1);\n\n $currentDate = getdate();\n $rename_file = \"file\" . $currentDate['year'] . $currentDate['mon'] . $currentDate['mday'] . $currentDate['hours'] . $currentDate['minutes'] . $currentDate['seconds'] . \".\" . $ext;\n $flag = FALSE;\n\n $tmp1 = $_FILES['OtherPhoto']['tmp_name'];\n\n $uploadFile = $tmp1;\n $bucketName = AMAZON_S3_BUCKET_NAME;\n// print_r($uploadFile);\n// die;\n if (!file_exists($uploadFile) || !is_file($uploadFile)) {\n echo 'if-1';\n exit(\"\\nERROR: No such file: $uploadFile\\n\\n\");\n }\n if (!extension_loaded('curl') && !@dl(PHP_SHLIB_SUFFIX == 'so' ? 'curl.so' : 'php_curl.dll')) {\n exit(\"\\nERROR: CURL extension not loaded\\n\\n\");\n }\n\n if (AMAZON_AWS_ACCESS_KEY == 'change-this' || AMAZON_AWS_AUTH_SECRET == 'change-this') {\n exit(\"\\nERROR: AWS access information required\\n\\nPlease edit the following lines in this file:\\n\\n\" .\n \"define('AMAZON_AWS_ACCESS_KEY', 'change-me');\\ndefine('AMAZON_AWS_AUTH_SECRET', 'change-me');\\n\\n\");\n }\n\n\n // Instantiate the class\n $s3 = new S3(AMAZON_AWS_ACCESS_KEY, AMAZON_AWS_AUTH_SECRET);\n// print_r($uploadFile); die;\n //// Put our file (also with public read access)\n if ($s3->putObjectFile($uploadFile, $bcketName, $type . '/' . $fold_name . '/' . $rename_file, S3::ACL_PUBLIC_READ)) {\n $flag = true;\n }\n\n if ($flag) {\n echo json_encode(array('msg' => '1', 'fileName' => $bucketName . '/' . $type . '/' . $fold_name . '/' . $rename_file));\n } else {\n echo json_encode(array('msg' => '2', 'folder' => $fold_name));\n }\n // return;\n }", "title": "" }, { "docid": "3476ec1c18b6c0061182b0af430b5cdf", "score": "0.44756028", "text": "public function testReadNamespacedAppliedClusterResourceQuota()\n {\n\n }", "title": "" }, { "docid": "fe5bb05c1dd2b47f8734e23c3ae4ba25", "score": "0.44500175", "text": "abstract public function getEndpoint(): Endpoint;", "title": "" }, { "docid": "1fc2c2dd98ac5402de37ab52a7d359b1", "score": "0.4433373", "text": "public function getBucketRegion(string $bucket): ?string\n\t{\n\t\t$bucketForRegion = $this->getState('bucketForRegion', null);\n\t\t$region = $this->getState('region', null);\n\n\t\tif (!empty($bucket) && (($bucketForRegion != $bucket) || empty($region)))\n\t\t{\n\t\t\t$config = $this->getS3Configuration();\n\t\t\t$config->setRegion('us-east-1');\n\n\t\t\t$s3 = $this->getS3Connector();\n\t\t\t$region = $s3->getBucketLocation($bucket);\n\t\t\t$this->setState('bucketForRegion', $bucket);\n\t\t\t$this->setState('region', $region);\n\t\t}\n\n\t\treturn $region;\n\t}", "title": "" }, { "docid": "8a63a6dac6ff60fa2841905f25df87e4", "score": "0.44303155", "text": "private function GetAmazonEC2ClientObject($region)\r\n\t\t{\r\n\t \t$clientid = $this->DB->GetOne(\"SELECT clientid FROM farms WHERE id=?\", array($this->FarmID));\r\n\t\t\t\r\n\t\t\t// Get Client Object\r\n\t\t\t$Client = Client::Load($clientid);\r\n\t\r\n\t \t// Return new instance of AmazonEC2 object\r\n\t\t\t$AmazonEC2Client = AmazonEC2::GetInstance(AWSRegions::GetAPIURL($region)); \r\n\t\t\t$AmazonEC2Client->SetAuthKeys($Client->AWSPrivateKey, $Client->AWSCertificate);\r\n\t\t\t\r\n\t\t\treturn $AmazonEC2Client;\r\n\t\t}", "title": "" }, { "docid": "567f3a5c36a0016db77e5ed46657a764", "score": "0.44179603", "text": "public function s3(): InvoiceFactory\n {\n return $this->state(fn() => ['disk' => 's3']);\n }", "title": "" }, { "docid": "bf4438131e75e9e6275501e0a673af50", "score": "0.44149435", "text": "protected function init() {\n \n if (!$this->api_region) $this->api_region = self::DEFAULT_REGION;\n $this->api_region_regional = in_array(trim(strtoupper($this->api_region)), explode(',', self::CONTAINERS_REGIONAL));\n\t\t$this->api_url = 'https://' . self::DEFAULT_GOOGLE_ENDPOINT;\n EncodingUtil::log(sprintf('Set GCS API URL to %s', $this->api_url), 'GoogleObjectStorageController::init', __LINE__);\n \n return TRUE;\n }", "title": "" }, { "docid": "23a7eef1cfd0fb632e5b8fe0380b4bf3", "score": "0.4414524", "text": "public function getRegion()\n {\n return $this->get('region', '');\n }", "title": "" }, { "docid": "8c89e8594dc1f5a944d6e5a56fbbff80", "score": "0.44141355", "text": "public function set_region($region)\n\t{\n\t\t$this->set_hostname($region);\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "8c89e8594dc1f5a944d6e5a56fbbff80", "score": "0.44141355", "text": "public function set_region($region)\n\t{\n\t\t$this->set_hostname($region);\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "1f13801fa50f26c2c3f0009171a5373a", "score": "0.44046262", "text": "function isRegion(){\n\t\treturn $this->getLocationType() == 1 ? true : false;\n\t}", "title": "" }, { "docid": "4f2d194cfe7d9756ce87f8fe3ccb554c", "score": "0.440241", "text": "protected function __construct($RegionID, $HttpPort, $ServerURI, $RegionName, $RegionType, $RegionLocX, $RegionLocY, $RegionLocZ=0, $EstateOwner='00000000-0000-0000-0000-000000000000', $EstateID=0, $RegionSizeX=256, $RegionSizeY=256, $RegionSizeZ=256, $Flags=0, $SessionID='00000000-0000-0000-0000-000000000000'){\n\t\t\tself::stringMaybe2Integer($HttpPort);\n\t\t\tself::stringMaybe2Integer($RegionLocX);\n\t\t\tself::stringMaybe2Integer($RegionLocY);\n\t\t\tself::stringMaybe2Integer($RegionLocZ);\n\t\t\tself::stringMaybe2Integer($RegionSizeX);\n\t\t\tself::stringMaybe2Integer($RegionSizeY);\n\t\t\tself::stringMaybe2Integer($RegionSizeZ);\n\t\t\tself::stringMaybe2Integer($EstateID);\n\t\t\tself::stringMaybe2Integer($Flags);\n\n\t\t\tif(is_string($RegionID) === false){\n\t\t\t\tthrow new InvalidArgumentException('RegionID should be a string');\n\t\t\t}else if(preg_match(\\Aurora\\Addon\\WebUI::regex_UUID, $RegionID) !== 1){\n\t\t\t\tthrow new InvalidArgumentException('RegionID was not a valid UUID');\n\t\t\t}else if(is_integer($HttpPort) === false){\n\t\t\t\tthrow new InvalidArgumentException('HttpPort should be an integer');\n\t\t\t}else if($HttpPort < 0){\n\t\t\t\tthrow new InvalidArgumentException('HttpPort should be greater than zero');\n\t\t\t}else if(is_string($ServerURI) === false){\n\t\t\t\tthrow new InvalidArgumentException('ServerURI should be a string');\n\t\t\t}else if(strpos($ServerURI, 'http://') !== 0 && strpos($ServerURI, 'https://') !== 0){\n\t\t\t\tthrow new InvalidArgumentException('ServerURI was not http or https');\n\t\t\t}else if(is_integer($RegionLocX) === false){\n\t\t\t\tthrow new InvalidArgumentException('RegionLocX was not an integer');\n\t\t\t}else if(is_integer($RegionLocY) === false){\n\t\t\t\tthrow new InvalidArgumentException('RegionLocY was not an integer');\n\t\t\t}else if(is_integer($RegionLocZ) === false){\n\t\t\t\tthrow new InvalidArgumentException('RegionLocZ was not an integer');\n\t\t\t}else if(is_string($EstateOwner) === false){\n\t\t\t\tthrow new InvalidArgumentException('EstateOwner was not a string');\n\t\t\t}else if(preg_match(\\Aurora\\Addon\\WebUI::regex_UUID, $EstateOwner) !== 1){\n\t\t\t\tthrow new InvalidArgumentException('EstateOwner was not a valid UUID');\n\t\t\t}else if(is_integer($EstateID) === false){\n\t\t\t\tthrow new InvalidArgumentException('EstateID was not an integer');\n\t\t\t}else if(is_integer($RegionSizeX) === false){\n\t\t\t\tthrow new InvalidArgumentException('RegionSizeX was not an integer');\n\t\t\t}else if(is_integer($RegionSizeY) === false){\n\t\t\t\tthrow new InvalidArgumentException('RegionSizeY was not an integer');\n\t\t\t}else if(is_integer($RegionSizeZ) === false){\n\t\t\t\tthrow new InvalidArgumentException('RegionSizeZ was not an integer');\n\t\t\t}else if(is_integer($Flags) === false){\n\t\t\t\tthrow new InvalidArgumentException('Flags was not an integer');\n\t\t\t}else if(RegionFlags::isValid($Flags) === false){\n\t\t\t\tthrow new InvalidArgumentException('Flags was not a valid RegionFlags bitfield');\n\t\t\t}else if(is_string($SessionID) === false){\n\t\t\t\tthrow new InvalidArgumentException('SessionID was not a string');\n\t\t\t}else if(preg_match(\\Aurora\\Addon\\WebUI::regex_UUID, $SessionID) !== 1){\n\t\t\t\tthrow new InvalidArgumentException('SessionID was not a valid UUID');\n\t\t\t}\n\n\t\t\t$this->RegionID = $RegionID;\n\t\t\t$this->HttpPort = $HttpPort;\n\t\t\t$this->ServerURI = $ServerURI;\n\t\t\t$this->RegionName = $RegionName;\n\t\t\t$this->RegionType = $RegionType;\n\t\t\t$this->RegionLocX = $RegionLocX;\n\t\t\t$this->RegionLocY = $RegionLocY;\n\t\t\t$this->RegionLocZ = $RegionLocZ;\n\t\t\t$this->EstateOwner = $EstateOwner;\n\t\t\t$this->EstateID = $EstateID;\n\t\t\t$this->RegionSizeX = $RegionSizeX;\n\t\t\t$this->RegionSizeY = $RegionSizeY;\n\t\t\t$this->RegionSizeZ = $RegionSizeZ;\n\t\t\t$this->Flags = $Flags;\n\t\t\t$this->SessionID = $SessionID;\n\t\t}", "title": "" }, { "docid": "b78a0f21b210116fdfe3d18cb144f527", "score": "0.44009143", "text": "function __construct() {\n \n $aws = Aws::factory('aws-config.php');\n $s3Client = $aws->get('s3');\n \n $s3Client = S3Client::factory(array(\n 'credentials' => array(\n 'key' => 'YOUR_AWS_ACCESS_KEY_ID',\n 'secret' => 'YOUR_AWS_SECRET_ACCESS_KEY',\n )\n));\n \n// Instantiate a client with the credentials from the project1 profile\n/*$dynamoDbClient = DynamoDbClient::factory(array(\n 'profile' => 'project1',\n 'region' => 'us-west-2',\n));*/\n }", "title": "" }, { "docid": "e4b657b7a3d668cc36f1187c0d7a100b", "score": "0.439346", "text": "function s3_file_get_contents( $filename )\n{\n global $kernel;\n try\n {\n $result = $kernel->s3->getObject( array(\n 'Bucket' => $kernel->conf['s3_bucket'],\n 'Key' => $filename\n ) );\n return $result['Body'];\n }\n catch ( Exception $e )\n {\n return FALSE;\n }\n}", "title": "" }, { "docid": "73f9a385276c49ed219d90438ac716d1", "score": "0.4387406", "text": "function AWSTranscribeJsonPrep($filename, $mediaformat) {\n Global $e3endpoint;\n $e3mediaurl = $e3endpoint . $filename;\n\n $subprep = array(\n 'MediaFileUri'=> $e3mediaurl\n );\n\n //$subprepjson = json_encode($subprep,JSON_UNESCAPED_SLASHES|JSON_PRETTY_PRINT);\n\n $prep = array(\n 'TranscriptionJobName'=> $filename,\n 'LanguageCode'=> 'en-US',\n 'MediaFormat'=> $mediaformat,\n //'Media' => $subprepjson\n 'Media'=> $subprep\n //'Media'=> 'https://s3-us-east-2.amazonaws.com/speechrecaudios/' . $filename,\n );\n\n $prepjson = json_encode($prep, JSON_UNESCAPED_SLASHES|JSON_PRETTY_PRINT);\n\n return $prepjson;\n //return $subprepjson;\n}", "title": "" }, { "docid": "8bc7bbaa70d2c4a2d8dcc62cc9b9cb62", "score": "0.4381896", "text": "protected function get_config($force_refresh = false) {// phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable -- Filter use\n\t\t$opts = $this->get_options();\n\t\t$opts['whoweare'] = 'S3';\n\t\t$opts['whoweare_long'] = __('S3 (Compatible)', 'updraftplus');\n\t\t$opts['key'] = 's3generic';\n\t\treturn $opts;\n\t}", "title": "" }, { "docid": "3f4838d0df862109c2336d6df3b38a6a", "score": "0.43807918", "text": "public function testReadNamespacedEgressNetworkPolicy()\n {\n\n }", "title": "" }, { "docid": "2faf3f2618191e2a121beb60dff9886d", "score": "0.43782777", "text": "public function testReplaceNamespacedEgressNetworkPolicy()\n {\n\n }", "title": "" } ]
13723369ee210991fbaeff150e6325a0
Display the specified resource.
[ { "docid": "4bedc215b9b1cccf6d24f0a5fe0be726", "score": "0.0", "text": "public function show(Order $order)\n\t{\n $order->load('products', 'products.images');\n\t\treturn view('orders.show', compact('order'));\n\t}", "title": "" } ]
[ { "docid": "1b84960e1b92d293ded93b3711f4a5bb", "score": "0.8233718", "text": "public function show(Resource $resource)\n {\n // not available for now\n }", "title": "" }, { "docid": "ac91646235dc2026e2b2e54b03ba6edb", "score": "0.8190437", "text": "public function show(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "d64ac4d2b3c1bbc8cf47ff61dc6c6145", "score": "0.6828712", "text": "function Display($resource_name, $cache_id = null, $compile_id = null)\n {\n $this->_smarty->display($resource_name, $cache_id, $compile_id);\n }", "title": "" }, { "docid": "6ad7532d4e18e95bb51cb89fd46c6f3e", "score": "0.64986944", "text": "private function showResourceable($resourceable)\n {\n save_resource_url();\n\n return $this->view('resources.create_edit')\n ->with('resource', $resourceable)\n ->with('photos', $resourceable->photos)\n ->with('videos', $resourceable->videos)\n ->with('documents', $resourceable->documents);\n }", "title": "" }, { "docid": "75848328c84e5c462b832c957a09b957", "score": "0.6495974", "text": "function display($resource_name, $cache_id = null, $compile_id = null) {\n\t\t$this->_getResourceInfo($resource_name); // Saves resource info to a Smarty class var for debugging\n\t\t$_t3_fetch_result = $this->fetch($resource_name, tx_smarty_div::getCacheID($cache_id), $compile_id);\n if ($this->debugging) { // Debugging will have been evaluated in fetch\n require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php');\n $_t3_fetch_result .= smarty_core_display_debug_console(array(), $this);\n }\n\t\treturn $_t3_fetch_result;\n\t}", "title": "" }, { "docid": "3064d7aadfe085c70cb0f28b932384a7", "score": "0.6469629", "text": "public function show(ResourceSubject $resourceSubject)\n {\n //\n }", "title": "" }, { "docid": "1be3fb8370513aa7e96f7c3e96fdff88", "score": "0.6462615", "text": "public function show(ResourceManagement $resourcesManagement)\n {\n //\n }", "title": "" }, { "docid": "735e1e8b4f110a9df09910db5ed28525", "score": "0.6363665", "text": "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "title": "" }, { "docid": "38d4e6796db39109f0d6935dfd120534", "score": "0.6311607", "text": "public function retrieve(Resource $resource);", "title": "" }, { "docid": "49144664a831cadf4907244f18f7d06f", "score": "0.62817234", "text": "public function showResource($resouceable, $id)\n {\n $model_name = str_replace('-', ' ',ucwords($resouceable));\n $model_name = str_replace(' ', '',ucwords($model_name));\n\n $resource_type = 'App\\Models\\\\'.$model_name;\n $model = app($resource_type);\n $model = $model->find($id);\n\n return $this->showResourceable($model);\n }", "title": "" }, { "docid": "823dc10cda9d65e730022e36a51b20f3", "score": "0.6218966", "text": "public function showAction(Ressource $ressource)\n {\n $deleteForm = $this->createDeleteForm($ressource);\n\n return $this->render('ressource/show.html.twig', array(\n 'ressource' => $ressource,\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "title": "" }, { "docid": "14ed889b850393fe8b1f3290fc49740e", "score": "0.6189695", "text": "public function show(Dispenser $dispenser)\n {\n //\n }", "title": "" }, { "docid": "990c774538153829a382b969fb274ad6", "score": "0.61804265", "text": "public function show($id)\n {\n $resource = Resource::find($id);\n dd($resource);\n }", "title": "" }, { "docid": "0180fbb47af0be5e609b81a6e3465c37", "score": "0.6171014", "text": "public function displayAction() {\n\t\tif(is_numeric($this->req_id)) {\n\t\t\tAPI::DEBUG(\"[DefaultController::displayAction()] Getting \" . $this->req_id, 1);\n\t\t\t$this->_view->data['info'] = $this->_model->get($this->req_id);\n\t\t\t$this->_view->data['action'] = 'edit';\n\n\t\t} else {\n\t\t\t$this->_view->data['action'] = 'new';\n\t\t}\n\t\t// auto call the hooks for this module/action\n\t\terror_log(\"Should Call: \" . $this->module .\"/\".$this->action.\"/\".\"controller.php\");\n\t\tAPI::callHooks($this->module, $this->action, 'controller', $this);\n\n\t\t$this->addModuleTemplate($this->module, 'display');\n\n\t}", "title": "" }, { "docid": "9b04b4f781eae858e123228d0a912464", "score": "0.61371076", "text": "public function show(NebulaResource $resource, $item): View\n {\n $this->authorize('view', $item);\n\n return view('nebula::resources.show', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "title": "" }, { "docid": "94cb94fffea6c87f520b5646c4b3b44c", "score": "0.61207956", "text": "public function resource(string $resource, string $controller): void\n {\n $base = $this->plural($resource);\n $entity = '/{'.$resource.'}';\n\n $this->app->get($base, $controller.'@index');\n $this->app->post($base, $controller.'@store');\n $this->app->get($base.$entity, $controller.'@show');\n $this->app->patch($base.$entity, $controller.'@update');\n $this->app->delete($base.$entity, $controller.'@destroy');\n }", "title": "" }, { "docid": "6b5130ab64ccaac7d924522f0ef610be", "score": "0.61067593", "text": "function displayCustom($resource_name, $cache_id = null, $compile_id = null)\n\t{\n\t return $this->display(DotbAutoLoader::existingCustomOne($resource_name), $cache_id, $compile_id);\n\t}", "title": "" }, { "docid": "7b265bdf9d16b71a51ad9b57ecfcc639", "score": "0.6105954", "text": "public function show($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.show\")) {\n $view = \"admin.{$this->name}.show\";\n } else {\n $view = 'admin.includes.actions.show';\n }\n\n /* Displays the specified resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "title": "" }, { "docid": "0cbbda716702c495903eacbdf07c4a18", "score": "0.6094066", "text": "public function show($id)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $rules = [\n 'id' => 'required|integer'\n ];\n\n $validator = Validator::make(['id' => $id], $rules);\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n $resource = $this->resourceRepository->fetchResource($id);\n $this->resourceRepository->storeView($id, $currentUser['id']);\n\n $data = [\n 'resource' => $resource,\n 'related_resources' => $this->resourceRepository->getResourcesRelatedTo($resource->id, $resource->mentoring_area_id)\n ];\n\n return APIHandler::response(1, \"Show Resource\", $data);\n }", "title": "" }, { "docid": "428541aff5a20db0753edebab2c7fb73", "score": "0.6082806", "text": "public function get(Resource $resource);", "title": "" }, { "docid": "fc99a414bbef1e12734ffe2495724008", "score": "0.6045245", "text": "public function showAction()\n {\n $model = $this->_getPhotoModel();\n $photo = $model->fetchEntry($this->getRequest()->getParam('id'));\n\n if (null === $photo) {\n return $this->_forward('notfound', 'error');\n }\n\n $this->view->auth = Zend_Auth::getInstance();\n $this->view->title = $photo->title;\n $this->view->photo = $photo;\n }", "title": "" }, { "docid": "8cb2cf294db063cb41e20820f36641f0", "score": "0.60389996", "text": "public function show($id)\n {\n //\n $data=Resource::find($id);\n return view('resourceDetails',compact('data'));\n }", "title": "" }, { "docid": "00e09b84f45fb294c62e0b4f0b454947", "score": "0.6016584", "text": "function display() {\n\t\t$view = &$this->getView();\n\t\t$view->display();\n\t}", "title": "" }, { "docid": "ddc28327288006b3d29c6bdc8761ca44", "score": "0.598783", "text": "public function show(ShowResourceRequest $request, $id)\n {\n // TODO: Implement show() method.\n }", "title": "" }, { "docid": "c9bf5b800308923b28214ed9119119bf", "score": "0.5961788", "text": "function show( $resource ){\n\n $where = \"reservation_status <> 'Pending' AND id = {$resource}\";\n $reservation = where( 'reservations', $where );\n $reservation = $reservation[0];\n\n return view('admin/reservation/preview_reservation', compact( 'reservation' ));\n}", "title": "" }, { "docid": "dbf7cb71fa21dced48bad29b90c7f51e", "score": "0.59606946", "text": "public function show()\n {\n if ($this->twig !== false) {\n $this->twigDefaultContext();\n if ($this->controller) {\n $this->controller->display($this->data);\n }\n echo $this->twig->render($this->twig_template, $this->data);\n } else {\n $filename = $this->findTemplatePath($this->template);\n require($filename);\n }\n }", "title": "" }, { "docid": "469e3d6c9afd54041becbee857df8ef8", "score": "0.5954321", "text": "public function edit(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "bb2e29f5f05ab065358c99c7225d6dc0", "score": "0.59295714", "text": "public function show(rc $rc)\n {\n //\n }", "title": "" }, { "docid": "76e0217d28590aa09067602bad097181", "score": "0.59182066", "text": "public function show(Resolucion $resolucion)\n {\n //\n }", "title": "" }, { "docid": "82abbfbc2da0a0d67a546dde5b87ad5e", "score": "0.5904556", "text": "public function showAction(furTexture $furTexture)\n {\n\n return $this->render('furtexture/show.html.twig', array(\n 'furTexture' => $furTexture,\n ));\n }", "title": "" }, { "docid": "5fbd8c8a913f3d5a4f08b109b5762881", "score": "0.59036547", "text": "public function show()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "5fbd8c8a913f3d5a4f08b109b5762881", "score": "0.59036547", "text": "public function show()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "5fbd8c8a913f3d5a4f08b109b5762881", "score": "0.59036547", "text": "public function show()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "d2bd10ab674d0671bf2851850995cea8", "score": "0.5891874", "text": "public function show(Resena $resena)\n {\n }", "title": "" }, { "docid": "d752fd3972b546ef194ae14ab221ca30", "score": "0.58688277", "text": "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "title": "" }, { "docid": "7690a8f4c2c21e15f750a5c52f83e2ce", "score": "0.5868107", "text": "public function showAction() {\n $docId = $this->getParam('id');\n\n // TODO verify parameter\n\n $document = new Opus_Document($docId);\n\n $this->_helper->layout()->disableLayout();\n\n $this->view->doc = $document;\n $this->view->document = new Application_Util_DocumentAdapter($this->view, $document);\n }", "title": "" }, { "docid": "c317189497889a6dd2147691ca7a246a", "score": "0.58676815", "text": "public function action_display()\r\n\t{\r\n\t\t$event = ORM::factory('event', array('id' => $this->request->param('id')));\r\n\t\r\n\t\tif ( ! $event->loaded())\r\n\t\t{\r\n\t\t\tNotices::error('event.view.not_found');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Can user view this event?\r\n\t\tif ( ! $this->user->can('event_view', array('event' => $event)))\r\n\t\t{\r\n\t\t\t// Error notification\r\n\t\t\tNotices::error('event.view.not_allowed');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Pass event data to the view class\r\n\t\t$this->view->event_data = $event;\r\n\t\t$this->view->user = $this->user;\r\n\t}", "title": "" }, { "docid": "4aec6f94d5731faefe27bdf32f7cbd44", "score": "0.5851883", "text": "public function execute()\n {\n // HTTP Request Get\n if ($this->type == \"resource\") {\n $action = $this->getResourceAction();\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n } else {\n $action = $this->Request->action;\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n }\n }", "title": "" }, { "docid": "e49111643c873671076e184b3c9c6ad7", "score": "0.58144855", "text": "public function show(Resident $resident)\n {\n $this->authorize('admin.resident.show', $resident);\n\n // TODO your code goes here\n }", "title": "" }, { "docid": "2771b374a21e331a50c3ffd5b3e431ca", "score": "0.58124036", "text": "public function display()\n {\n echo $this->getDisplay();\n $this->isDisplayed(true);\n }", "title": "" }, { "docid": "d6af1b1d4946c54112fc9b7ca038cb20", "score": "0.58112013", "text": "public function display()\n\t{\n\t\tparent::display();\n\t}", "title": "" }, { "docid": "e3c1fc60ee75eb693b0090ab8fb943ad", "score": "0.5803467", "text": "public function get_resource();", "title": "" }, { "docid": "305f64db85d64f68019d2fadcd0a85d2", "score": "0.58012545", "text": "public function show()\n\t{\n\t\t\n\t}", "title": "" }, { "docid": "fd37d1765d15b4bc18c928879eeab887", "score": "0.5791527", "text": "function display() {\n\n\t\t// Check authorization, abort if negative\n\t\t$this->isAuthorized() or $this->abortUnauthorized();\n\n\t\t// Get the view\n\t\t$view = $this->getDefaultView();\n\n\t\tif ($view == NULL) {\n\t\t\tthrow new Exception('Display task called, but there is no view assigned to that controller. Check method getDefaultView.');\n\t\t}\n\n\t\t$view->listing = true;\n\n\t\t// Wrap the output of the views depending on the way the stuff should be shown\n\t\t$this->wrapViewAndDisplay($view);\n\n\t}", "title": "" }, { "docid": "216efefddc0fd6c127c01013a3f6329b", "score": "0.57901084", "text": "public function viewResources()\n {\n $database = new Database();\n\n $resources = $database->getAllActiveResourcesNoLimit();\n\n\n $resourceArray = array();\n $i = 1;\n\n foreach ($resources as $resource) {\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n array_push($resourceArray, $availableResource);\n $i += 1;\n }\n $resourceSize = sizeof($resourceArray);\n $this->_f3->set('resourcesByActive', $resourceArray);\n $this->_f3->set('resourcesSize', $resourceSize);\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "title": "" }, { "docid": "59b26eccbeb80415b27d312ada1ffed8", "score": "0.5781528", "text": "public function show($id)\n {\n $this->title .= ' show';\n $this->one($id);\n }", "title": "" }, { "docid": "d7676ee3e8006c108d5effc4a65123cf", "score": "0.5779676", "text": "public function display($title = null)\n {\n echo $this->fetch($title);\n }", "title": "" }, { "docid": "64ca047c763cbf564dd5de6f46e00c8a", "score": "0.5757105", "text": "public function display(){}", "title": "" }, { "docid": "1e8ae24781dac20c4f5e103867a805e0", "score": "0.5756208", "text": "public function show($id)\n\t{\n\t\t//\n\t\t//\n\t\n\t}", "title": "" }, { "docid": "69113639710554fd174b3aaec6536b9c", "score": "0.57561266", "text": "public function viewAction()\n\t{\n\t\t//get Id param from request\n\t\tif (!$id = $this->_getParam('id')) {\n\t\t\t$this->getFlashMessenger()->addMessage('Product ID was not specified');\n\t\t\t$this->getRedirector()->gotoSimple('list');\n\t\t}\n\n\t\t//fetch requested ProductID from DB\n\t\tif (!$this->_model->fetch($id)) {\n\t\t\t$this->render('not-found');\n\t\t} else {\n\t\t\t$this->view->model = $this->_model;\n\t\t}\n\t}", "title": "" }, { "docid": "8340a4efc2a012c537437541539dc80b", "score": "0.57453394", "text": "public function show($id)\n {\n // Get single person\n $person = Person::findOrFail($id);\n\n // Return single person as a resource\n return '<h1>Person Number '.$id.'</h1><br>'.json_encode(new PersonResource($person));\n }", "title": "" }, { "docid": "5e79caa6f512ec951cafbf72e8caa6f2", "score": "0.57435393", "text": "#[TODO] use self object?\n\tprotected function GET(ResourceObject $resource) {\n#[TODO]\t\tif ($resource->getMTime())\n#[TODO]\t\t\t$this->response->headers->set('Last-modified', gmdate('D, d M Y H:i:s ', $resource->getMTime()) . 'GMT');\n#[TODO]\t\tif ($resource->getCTime())\n#[TODO]\t\t\t$this->response->headers->set('Date', gmdate('D, d M Y H:i:s ', $resource->getCTime()) . 'GMT');\n\n\n#[TODO] handle file streams\n\t\t// get ranges\n#\t\t$ranges = WebDAV::getRanges($this->request, $this->response);\n\n\t\t// set the content of the response\n\t\tif ($resource instanceof ResourceDocument) {\n\t\t\t$this->response->content->set($resource->getContents());\n\t\t\t$this->response->content->setType($resource->getMIMEType());\n\t\t\t$this->response->content->encodeOnSubmit(true);\n\t\t}\n\t}", "title": "" }, { "docid": "75559ae77140a4c8b510c90f5026d3d6", "score": "0.57422745", "text": "public function display() {\n echo $this->render();\n }", "title": "" }, { "docid": "8f15cdd2f287675d36c7b7df028043ec", "score": "0.5736634", "text": "public function show($id)\n\t{\n\t//\n\t}", "title": "" }, { "docid": "8f15cdd2f287675d36c7b7df028043ec", "score": "0.5736634", "text": "public function show($id)\n\t{\n\t//\n\t}", "title": "" }, { "docid": "70b49677ea9b29b09505986b16d55071", "score": "0.5730559", "text": "function Fetch($resource_name, $cache_id = null, $compile_id = null, $display = false)\n {\n return $this->_smarty->fetch($resource_name, $cache_id, $compile_id, $display);\n }", "title": "" }, { "docid": "7684a3ad9102aa78b598eb1a828f68c5", "score": "0.57259274", "text": "public function show($id)\n {\n //\n $this->_show($id);\n }", "title": "" }, { "docid": "20397e06b8673db8692c5f84120c3011", "score": "0.5724891", "text": "public function show()\n\t{\n\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "47171b843665ac85f7c5da2618a7ae0e", "score": "0.5718969", "text": "public function show($id) {}", "title": "" }, { "docid": "e3c948157c6e692386196d78f9677b46", "score": "0.5713412", "text": "static public function showCallback(O_Dao_Renderer_Show_Params $params) {\r\n\t\t/* @var $r R_Mdl_Resource */\r\n\t\t$r = $params->record();\r\n\t\t// Setting layout title\r\n\t\t$params->layout()->setTitle($r->getPageTitle());\r\n\r\n?><h1><?=$r->title?></h1><div id=\"resource\"><?\r\n\t\tif($r->getContent()) {\r\n\t\t\t// page has its own content -- show it\r\n\t\t\t$r->getContent()->show($params->layout(), \"content\");\r\n\t\t} else {\r\n\t\t\t// It is a post unit, show all childs\r\n\t\t\tif($r->is_unit == 1) {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"content\");\r\n\r\n\t\t\t// It is a folder with several units, show paginator\r\n\t\t\t} elseif($r->show_def == \"last-units\") {\r\n\t\t\t\tlist($type, $perpage) = explode(\":\", $r->show_def_params);\r\n\t\t\t\t/* @var $p O_Dao_Paginator */\r\n\t\t\t\t$p = $r->addQueryAccessChecks($r->getChilds())->test(\"is_unit\", 1)->getPaginator(array($r, \"getPageUrl\"), $perpage);\r\n\t\t\t\t$p->show($params->layout(), $type);\r\n\t\t\t// It is a folder with subfolders, boxes, contents. Show one childs level\r\n\t\t\t} else {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"on-parent-page\");\r\n\t\t\t}\r\n\r\n\t\t}\r\n?></div><?\r\n\t}", "title": "" }, { "docid": "5d64133f90b57341622dee65af085a52", "score": "0.57091093", "text": "public function show($id)\r\n\t{\r\n\t\t//\r\n\r\n\r\n\r\n\t}", "title": "" }, { "docid": "b791634a3b29fe8adff71b755317e88e", "score": "0.5706405", "text": "public function show($resourceId, $eventId)\n {\n $routes = $this->routes;\n\n $eventable = $this->getEventableRepository()->model()->findOrFail($resourceId);\n\n if (method_exists($eventable, 'events')) {\n $event = $eventable->events()->find($eventId);\n\n if ($event) {\n $apiObject = $this->event->findApiObject($event->api_id);\n\n return view('events.eventables.show', compact('routes', 'eventable', 'event', 'apiObject'));\n }\n }\n\n abort(404);\n }", "title": "" }, { "docid": "05ca915e5f597f0a1925a6b1a1e6afb0", "score": "0.57057405", "text": "public abstract function display();", "title": "" }, { "docid": "7f0ed797ab602b8432aad97e3677d2a1", "score": "0.5704541", "text": "abstract public function resource($resource);", "title": "" }, { "docid": "5766cf8c652099e6e707b39bd867a1c0", "score": "0.5704152", "text": "public function show($id)\r\r\n\t{\r\r\n\t\t//\r\r\n\t}", "title": "" }, { "docid": "12bf7179b06b190879842d1f1945365c", "score": "0.57026845", "text": "public function show( $id ) {\n\t\t//\n\t}", "title": "" }, { "docid": "12bf7179b06b190879842d1f1945365c", "score": "0.57026845", "text": "public function show( $id ) {\n\t\t//\n\t}", "title": "" }, { "docid": "7b283ba1c0546a155efc95a44dd0f9cf", "score": "0.56981397", "text": "public function show(Response $response)\n {\n //\n }", "title": "" }, { "docid": "9032057600ac1cb05d858c6264b8aed1", "score": "0.5693083", "text": "public function show()\n {\n return auth()->user()->getResource();\n }", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" } ]
5b03ea0ac0ad3297d43cc3e6c888f2c5
This function fetches the CAP file from a URL.
[ { "docid": "46de2b5333a59157097ce2ae3b43222d", "score": "0.7499207", "text": "private function fetch($url) {\n #fetch the file\n return file_get_contents($url);\n }", "title": "" } ]
[ { "docid": "353b5b5615ad9375a63ce51b82768536", "score": "0.72528505", "text": "function loadFile($url) {\n\t\t\t $ch = curl_init();\n\n\t\t\t curl_setopt($ch, CURLOPT_HEADER, 0);\n\t\t\t curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\t\t curl_setopt($ch, CURLOPT_URL, $url);\n\n\t\t\t $data = curl_exec($ch);\n\t\t\t curl_close($ch);\n\n\t\t\t return $data;\n\t\t\t}", "title": "" }, { "docid": "5b7db76a7fb0ab19f1a968d8f55c0379", "score": "0.70278925", "text": "function fetchURL($url) {\n\n return file_get_contents($url);\n\n }", "title": "" }, { "docid": "e39acd35fa0546c57217f1f08c3e8173", "score": "0.6930125", "text": "function fetchURL($url) {\n // Will fail if too many requests (620 error)\n if(!$content = @file_get_contents($url)) {\n $http_request = $this->PMDR->get('HTTP_Request');\n $http_request->settings[CURLOPT_RETURNTRANSFER] = true;\n $http_request->settings[CURLOPT_HEADER] = false;\n $content = $http_request->get('curl',$url);\n }\n return $content;\n }", "title": "" }, { "docid": "6a0d4f5d6bff8ad738b84c7c2a0cdccf", "score": "0.6857294", "text": "function getRemoteFile( $url ) {\n\t\t\t $errorReporting = error_reporting();\n\t\t\t error_reporting(0);\n\t\t\t \n\t\t\t require_once(ABSPATH.WPINC.'/class-snoopy.php');\n\t\t\t $content = false;\n\t\t\t $sn = new Snoopy();\n\t\t\t $sn->read_timeout = 2;\n\t\t\t if( $sn->fetch( $url ) ) {\n\t\t\t\t $content = $sn->results;\n\t\t\t }\n\t\t\t \n\t\t\t error_reporting($errorReporting);\n\t\t\t \n\t\t\t\tif ( $content === false ) { return false; }\n\t\t\t\t\n\t\t\t\treturn $content;\n\t\t\t}", "title": "" }, { "docid": "f289f263560c9928824c39814de15172", "score": "0.6741448", "text": "public function getURL($url){\n\t\t\n\t\t$data = $this->getRemoteFile($url);\n\t\t\n\t\treturn $data;\n\t}", "title": "" }, { "docid": "843780887184d710b3bacc7193148126", "score": "0.6728874", "text": "public function getFileFromUrl($url)\n {\n $res = \\tabs\\apiclient\\client\\Client::getClient()->get(\n (string) $this->getUrl($url)\n );\n\n return (string) $res->getBody();\n }", "title": "" }, { "docid": "cf40a91057dc5fe6ed0a01448642c29b", "score": "0.67084473", "text": "public function getFile($URL) {\r\n\t $ch=curl_init();\r\n\t curl_setopt($ch,CURLOPT_RETURNTRANSFER,1);\r\n curl_setopt($ch,CURLOPT_URL,$URL);\r\n $data=curl_exec($ch);\r\n curl_close($ch);\r\n return $data;\r\n\t }", "title": "" }, { "docid": "a6adf8c9daeb157626fccc383d8a3f1c", "score": "0.6541554", "text": "public static function getByFileGetContents($url){\r\n $html = file_get_contents($url);\r\n return $html;\r\n }", "title": "" }, { "docid": "ca40c35d9dea30873ed3a8004cd37573", "score": "0.64764297", "text": "public function getFile($url) {\n\n $urlInfo = parse_url($url);\n\n $oldHost = $this->apiHostname;\n $oldPort = $this->port;\n $oldUrl = $this->apiUrl;\n\n $this->apiHostname = $urlInfo[\"host\"];\n if($port === 0 || (int)$port > 0)\n $this->port = $urlInfo[\"port\"];\n else\n $this->port = NULL;\n $this->apiUrl = $urlInfo[\"path\"].\"?\".$urlInfo[\"query\"];\n\n $response = $this->_callServer(array());\n\n $this->apiUrl = $oldUrl;\n $this->apiHostname = $oldHost;\n $this->port = $oldPort;\n\n if($response !== false)\n return $response;\n else{\n $this->errorMessage = \"\";\n return false;\n }//end if\n\n }", "title": "" }, { "docid": "7e31b28162e60637ee050a8e1842d5c5", "score": "0.647034", "text": "public static function openByFopenAndGet($url){\r\n $fp = fopen($url, 'r');\r\n stream_get_meta_data($fp);\r\n $result = \"\";\r\n while(!feof($fp)){\r\n $result .= fgets($fp, 1024);\r\n }\r\n fclose($fp);\r\n return $result;\r\n }", "title": "" }, { "docid": "7192efceabc2162d91a1d7417324fcae", "score": "0.6464195", "text": "function _fetch_remote_file($url, $headers = \"\")\n{\n}", "title": "" }, { "docid": "386f0811cc983594839dfe081c0cb4de", "score": "0.6405858", "text": "public static function fileGetContents($url)\n { \n $ch = curl_init();\n $timeout = 60; // asignamos cero para que espere infinitamente\n curl_setopt ($ch, CURLOPT_URL, $url);\n curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt ($ch, CURLOPT_CONNECTTIMEOUT, $timeout);\n $retval = curl_exec($ch);\n if (curl_getinfo($ch, CURLINFO_HTTP_CODE) !== 200 ) { \n return false;\n }\n\n curl_close($ch);\n \n return $retval;\n \n }", "title": "" }, { "docid": "c0e2e51cc9835078101f5af5a97d9e5f", "score": "0.63815635", "text": "private function Fetch($url){\n\t\tif($this->user_agent_reset){\n\t\t\t$this->RandomUserAgent();\n\t\t}\n\t\t$opts = array( \n\t\t\t'http'=> array( \n\t\t\t\t'method'=> \"GET\", \n\t\t\t\t'header'\t=> 'Referer: https://twitter.com',\n\t\t\t\t'user_agent'=> $this->user_agent\n\t\t\t\t)\n\t\t);\n\t\tif($this->cache_mode=='out'){\n\t\t\treturn file_get_contents($url,0,stream_context_create($opts));\n\t\t}\n\t\tif(! $result=$this->LoadCache($url)){\n\t\t\t$result=file_get_contents($url,0,stream_context_create($opts));\n\t\t\t$this->StoreCache($result);\n\t\t}\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "cdc05020312f4d4a24e76f2de50e78f4", "score": "0.6369637", "text": "static function downloadFile($url){\n set_time_limit(0);\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);\n $r = curl_exec($ch);\n curl_close($ch);\n header('Expires: 0'); // no cache\n header('Cache-Control: must-revalidate, post-check=0, pre-check=0');\n header('Last-Modified: ' . gmdate('D, d M Y H:i:s', time()) . ' GMT');\n header('Cache-Control: private', false);\n header('Content-Type: application/force-download');\n header('Content-Disposition: attachment; filename=\"' . basename($url) . '\"');\n header('Content-Transfer-Encoding: binary');\n header('Content-Length: ' . strlen($r)); // provide file size\n header('Connection: close');\n echo $r;\n }", "title": "" }, { "docid": "e8e3dc0497928135f66c7a95b3320e45", "score": "0.6362005", "text": "function curl_file_get_contents1($url) {\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_AUTOREFERER, TRUE);\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);\n $data = curl_exec($ch);\n curl_close($ch);\n return $data;\n }", "title": "" }, { "docid": "5fcaad7d94cb3f6364279c2cdac8098b", "score": "0.6356468", "text": "private function getRemoteFile($url)\n\t{\n\t $parsedUrl = parse_url($url);\n\t $host = $parsedUrl['host'];\n\t if (isset($parsedUrl['path'])) {\n\t $path = $parsedUrl['path'];\n\t } else {\n\t // the url is pointing to the host like http://www.mysite.com\n\t $path = '/';\n\t }\n\t\n\t if (isset($parsedUrl['query'])) {\n\t $path .= '?' . $parsedUrl['query'];\n\t }\n\t\n\t if (isset($parsedUrl['port'])) {\n\t $port = $parsedUrl['port'];\n\t } else {\n\t // most sites use port 80\n\t $port = '80';\n\t }\n\t\n\t $timeout = 5;\n\t $response = '';\n\t\n\t // connect to the remote server\n\t $fp = @fsockopen($host, $port, $errno, $errstr, $timeout );\n\t\n\t if( !$fp ) {\n\t echo \"Cannot retrieve $url\";\n\t } else {\n\t // send the necessary headers to get the file\n\t fputs($fp, \"GET $path HTTP/1.0\\r\\n\" .\n\t \"Host: $host\\r\\n\" .\n\t \"User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.3) Gecko/20060426 Firefox/1.5.0.3\\r\\n\" .\n\t \"Accept: */*\\r\\n\" .\n\t \"Accept-Language: en-us,en;q=0.5\\r\\n\" .\n\t \"Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7\\r\\n\" .\n\t \"Keep-Alive: 300\\r\\n\" .\n\t \"Connection: keep-alive\\r\\n\" .\n\t \"Referer: http://$host\\r\\n\\r\\n\");\n\t\n\t // retrieve the response from the remote server\n\t while ( $line = fread( $fp, 4096 ) ) {\n\t $response .= $line;\n\t }\n\t\n\t fclose( $fp );\n\t\n\t // strip the headers\n\t $pos = strpos($response, \"\\r\\n\\r\\n\");\n\t $response = substr($response, $pos + 4);\n\t }\n\t\n\t // return the file content\n\t return $response;\n\t}", "title": "" }, { "docid": "123a52e5feff8686c80a38a59067d42e", "score": "0.63241374", "text": "function fileGetContentsCurl($url)\n{\n $ch = curl_init();\n\n curl_setopt($ch, CURLOPT_AUTOREFERER, true);\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n\n $data = curl_exec($ch);\n curl_close($ch);\n\n return $data;\n}", "title": "" }, { "docid": "2a6d7a8c499c2ac0b228820b83254b0d", "score": "0.62800664", "text": "public static function curl_get_file_contents($URL)\r\n {\r\n$lines_string=file_get_contents($URL);\r\n//output, you can also save it locally on the server\r\necho $lines_string;\r\n }", "title": "" }, { "docid": "3817d045cba395e25b4c993abee75db8", "score": "0.6266554", "text": "private function _file_get_contents($url) {\n\n\t\t// Load the Curl session \n\t\t$load = curl_init();\n\n\t\t// Quick fix https problem\n\t\tcurl_setopt($load, CURLOPT_SSL_VERIFYPEER, false);\n\t\tcurl_setopt($load, CURLOPT_REFERER, $url);\n\n\t\t// Set curl to return the data instead of printing it to the browser. \n\t\tcurl_setopt($load, CURLOPT_RETURNTRANSFER, true); \n\n\t\t// Follow if redirect\n\t\tcurl_setopt($load, CURLOPT_FOLLOWLOCATION, true);\n\n\t\t// Set the URL \n\t\tcurl_setopt($load, CURLOPT_URL, $url); \n\n\n\t\t// Execute baby\n\t\t$datas = curl_exec($load); \n\n\t\t// Close the connection \n\t\tcurl_close($load);\n\n\t\tif (!$datas) return false;\n\n\t\treturn $datas;\n\n\t}", "title": "" }, { "docid": "1256196720f84916905519bb828d39ad", "score": "0.62394935", "text": "function getSslFile($url)\n{\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);\n curl_setopt($ch, CURLOPT_HEADER, false);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_REFERER, $url);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);\n $result = curl_exec($ch);\n curl_close($ch);\n return $result;\n}", "title": "" }, { "docid": "79243afc294390021a7ac488e635841a", "score": "0.62265533", "text": "function _get($url)\n{\n\t$file = file_get_contents($url);\n\treturn (array)$file;\n\t//return $file;\n\t\n\t/*\n\t$ch = curl_init();\n\tcurl_setopt($ch, CURLOPT_URL, $url);\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\t$result = json_decode(curl_exec($ch));\n\tcurl_close($ch);\n\treturn $result;\n\t*/ \n\t \n}", "title": "" }, { "docid": "0a40f7d4acf6de802632195f0ea49967", "score": "0.6220976", "text": "function curl_get ( $url ) {\n\tglobal $curl_auth;\n\tif ( $url ) {\n\t\t$url_parts = parse_url($url);\n\t\t$cookie = app_path_temp . $url_parts['host'] . '.cookie';\n\t\t// no cookie file then need to start session\n\t\tif ( !is_file($cookie) ) {\n\t\t\tcurl_login($url, $curl_auth);\n\t\t}\n\t\t// create cURL resource\n\t\t$ch = curl_init();\n\t\t// set options\n\t\tcurl_setopt($ch, CURLOPT_URL, $url);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true); \n\t\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); \n\t\tcurl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 6.1; rv:2.0) Gecko/20100101 Firefox/4.0');\n\t\tif ( is_file($cookie) ) {\n\t\t\tcurl_setopt($ch, CURLOPT_COOKIEFILE, $cookie);\n\t\t}\n\t\t// grab URL and pass it to the browser\n\t\t$result = curl_exec($ch);\n\t\t//fb(curl_getinfo($ch));\n\t\t// close cURL resource, and free up system resources\n\t\tcurl_close($ch);\n\t\treturn $result;\n\t}\n}", "title": "" }, { "docid": "5f3877a764bf1b0c83b3d24ac6a074b7", "score": "0.6215774", "text": "function http_download($url)\n{\n $ch = curl_init();\n if (defined($GLOBALS['raydium_proxy']))\n curl_setopt ($ch, CURLOPT_PROXY, $GLOBALS['raydium_proxy']);\n curl_setopt ($ch, CURLOPT_URL, $url);\n curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, 1);\n curl_setopt ($ch, CURLOPT_TIMEOUT, 60);\n\n $result = curl_exec ($ch);\n if (curl_errno($ch)) \n {\n print \"ERROR downloading file: \" . curl_error($ch);\n return false;\n } \n else \n {\n curl_close($ch);\n return $result;\n }\n}", "title": "" }, { "docid": "fbb5c3487bf419d80a450efd3b5c89d7", "score": "0.62151814", "text": "function getsrc($url)\n{\n $c = curl_init();\n $user_agent = \"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1847.116 Safari/537.36\";\n curl_setopt($c, CURLOPT_URL, $url);\n curl_setopt($c, CURLOPT_USERAGENT, $user_agent);\n curl_setopt($c, CURLOPT_POST, 0);\n curl_setopt($c, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($c, CURLOPT_FRESH_CONNECT, true);\n $html = curl_exec($c);\n\tcurl_close($c);\n \n return $html;\n}", "title": "" }, { "docid": "79f4f179649a73cb05a93aa9914aa387", "score": "0.6206375", "text": "function get_url($url) {\r\n dbg(\"fetching: $url\");\r\n $result = @file_get_contents($url);\r\n list($version,$status_code,$msg) = explode(' ',$http_response_header[0], 3);\r\n if($status_code >= 400)\r\n throw new Exception(\"Error \".$status_code.\" returned when attempting call $url\");\r\n return $result;\r\n}", "title": "" }, { "docid": "bf24df5a129a7441ba2b278d728480c2", "score": "0.6199365", "text": "function url_get_contents ($Url) {\n\t\t\t if (!function_exists('curl_init')){ \n\t\t\t die('CURL is not installed!');\n\t\t\t }\n\t\t\t $ch = curl_init();\n\t\t\t curl_setopt($ch, CURLOPT_URL, $Url);\n\t\t\t curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\t\t\t $output = curl_exec($ch);\n\t\t\t curl_close($ch);\n\t\t\t return $output;\n\t\t\t }", "title": "" }, { "docid": "e801a59ef970c7cc9c917554f54b72ac", "score": "0.61937094", "text": "protected function download($url) {\n try {\n $full_url = $url;\n if ($url[0] == \"/\" || Str::startsWith($url, \"http://staroetv.su/\") || Str::startsWith($url, \"http://staroetv.ucoz.ru/\")) {\n $url = str_replace(\"http://staroetv.su\",\"\", $url);\n $url = str_replace(\"http://staroetv.ucoz.ru\",\"\", $url);\n echo \"Not downloading because of relative path \" . $url . PHP_EOL;\n $picture = new Picture([\n 'url' => $url\n ]);\n $picture->save();\n } else {\n $path = parse_url($full_url, PHP_URL_PATH);\n $basename = pathinfo($path, PATHINFO_BASENAME);\n $name = \"/pictures/imported/\" . $basename;\n echo \"Downloading \" . $full_url . PHP_EOL;\n file_put_contents(public_path($name), fopen($full_url, 'r'));\n $picture = new Picture([\n 'url' => $name\n ]);\n }\n $picture->save();\n return $picture->id;\n } catch (\\Exception $e) {\n return null;\n }\n }", "title": "" }, { "docid": "ace36ba0622959c9ef4a365c97627f24", "score": "0.618316", "text": "public function download($url);", "title": "" }, { "docid": "892e10b22e11fdff78cbe9b8353ef1a9", "score": "0.61782414", "text": "function openurl($url) {\n\t /*$ch = @curl_init($url);\n\t\tcurl_setopt($ch, CURLOPT_POST, 1);\n\t\tcurl_setopt($ch, CURLOPT_TIMEOUT, 60);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\treturn $result = trim(curl_exec($ch));\n\t\t*/\n\t\tif($fp = @fopen($url, \"rb\")){\n\t\t$result = \"\";\n\t\twhile(!feof($fp)){\n\t\t\t$result .= fgets($fp, 4096);\n\t\t}\t\n\t\t@fclose($fp);\t \n\t\t}\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "dfd78586c2c5d2c7dc5b7bd48eed1bfb", "score": "0.6171971", "text": "function file_get_contents_curl($url)\n {\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_AUTOREFERER, TRUE);\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);\n $data = curl_exec($ch);\n curl_close($ch);\n return $data;\n }", "title": "" }, { "docid": "c773971346f577796194e9fe91df7de4", "score": "0.6166079", "text": "private function GetFileData( $url ) {\n\t\tif( $url != \"\") {\n\t\t\t$response = file_get_contents( $url );\n\t\t\treturn $response != \"\" ? $response : false;\n\t\t}\n\t}", "title": "" }, { "docid": "f69a924d9ea2bf32e6727035ec993736", "score": "0.61646616", "text": "function fetchHTTP($url)\n\t{\n\t\t$timeout = $GLOBALS['siteConfig']->getVar('HTTP_TIMEOUT');\n\t\t$options = stream_context_create(array(\n\t\t\t'http' => array(\n\t\t\t\t'timeout' => (string)$timeout,\n\t\t\t),\n\t\t));\n\t\t$data = @file_get_contents($url, false, $options);\n\t\treturn $data;\n\t}", "title": "" }, { "docid": "f59ad73a1a66dc9fa691dc8760a5a506", "score": "0.6163416", "text": "public static function file_get_contents_curl($url)\n {\n $response = Http::withHeaders([\n 'User-Agent' => 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.132 Safari/537.36',\n ])->get($url);\n \n return $response;\n }", "title": "" }, { "docid": "bbdb56fc98419d350ee1d3120f84999a", "score": "0.61582536", "text": "public function handleFetch($url) {\n global $request;\n\n // Stop here if no data supplied\n if (empty($url)) {\n // Nope, Bad Request\n header($request->server(\"SERVER_PROTOCOL\") . \" 400 Bad Request\", true, 400);\n\n return;\n }\n // Is this a valid url\n if (!$this->FilePond->isURL($url)) {\n // Nope, Bad Request\n header($request->server(\"SERVER_PROTOCOL\") . \" 400 Bad Request\", true, 400);\n\n return;\n }\n // Let's get the remote file content\n $response = $this->FilePond->getRemoteURLData($url);\n // Something went wrong\n if ($response === null) {\n // Nope, Probably a problem while fetching the resource\n header($request->server(\"SERVER_PROTOCOL\") . \" 500 Internal Server Error\", true, 500);\n\n return;\n }\n // remote server returned invalid response\n if (!$response['success']) {\n // Clone response code and communicate to client\n http_response_code($response['code']);\n return;\n }\n \n // Return file\n header('Content-Type: ' . $response['type']);\n header('Content-Length: ' . $response['length']);\n echo $response['content'];\n }", "title": "" }, { "docid": "a5a41fa105fbeb3182f81f1605328ded", "score": "0.6148628", "text": "function get_url($url) {\n\t$ch = curl_init();\n\tcurl_setopt($ch,CURLOPT_URL,$url);\n\tcurl_setopt($ch,CURLOPT_RETURNTRANSFER,1);\n\tcurl_setopt($ch,CURLOPT_CONNECTTIMEOUT,5);\n\t$content = curl_exec($ch);\n\tcurl_close($ch);\n\treturn $content;\n}", "title": "" }, { "docid": "149710280e94632470988bab85360d4a", "score": "0.61456186", "text": "function get($url, $file){\n\t//Get content from url\n\t$string = file_get_contents($url);\n\t//open cache file in write mode\n\t$f = fopen($cache_file, 'w');\n\t//write\n\tfwrite($f, $string, strlen($string));\n\t//close\n\tfclose($f);\n\t//return data\n\treturn $string\n}", "title": "" }, { "docid": "3c651a2bd59cc684693460a92e67524d", "score": "0.61450547", "text": "function curl_download($Url){ if (!function_exists('curl_init')){\n die('Sorry cURL is not installed!');\n }\n \n // OK cool - then let's create a new cURL resource handle\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $Url);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n $output = curl_exec($ch);\n\n return $output;\n}", "title": "" }, { "docid": "d74d7a08f8f83267983ab0d9a8229c23", "score": "0.61434895", "text": "public function getFile ($url) {\n $this->target = $url;\n $this->mainCurl();\n }", "title": "" }, { "docid": "e9b1cc74231d1d3c3f60275ae436c5b9", "score": "0.6118141", "text": "function grabbing($url){\n $data = curl_init();\n curl_setopt($data, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($data, CURLOPT_URL, $url);\n $output = curl_exec($data);\n curl_close($data);\n return $output;\n}", "title": "" }, { "docid": "9d1b8910146289ca27622e84e75164e3", "score": "0.6106985", "text": "function openFile($url, $size) {\n\t\tif (file_exists($url)) {\n\t\t$myFile = $url;\n\t\t$fh = fopen($myFile, 'r');\n\t\t$dataToReturn = fread($fh, $size);\n\t\tfclose($fh);\t\n\t\t} else {\n\t\t\tsaveFile($url, \"\");\n\t\t\t$dataToReturn = \"\";\n\t\t}\n\t\treturn $dataToReturn;\n\t\n\t\n\t}", "title": "" }, { "docid": "eca074c0bc47da28ae1e409b18aa8581", "score": "0.61041844", "text": "function url_get_contents ($url) {\n\t if (function_exists('curl_exec')){ \n\t $conn = curl_init($url);\n\t curl_setopt($conn, CURLOPT_SSL_VERIFYPEER, true);\n\t curl_setopt($conn, CURLOPT_FRESH_CONNECT, true);\n\t curl_setopt($conn, CURLOPT_RETURNTRANSFER, 1);\n\t $url_get_contents_data = (curl_exec($conn));\n\t curl_close($conn);\n\t }elseif(function_exists('file_get_contents')){\n\t $url_get_contents_data = file_get_contents($url);\n\t }elseif(function_exists('fopen') && function_exists('stream_get_contents')){\n\t $handle = fopen ($url, \"r\");\n\t $url_get_contents_data = stream_get_contents($handle);\n\t }else{\n\t $url_get_contents_data = false;\n\t }\n\treturn $url_get_contents_data;\n\t}", "title": "" }, { "docid": "22e8926707b7c50038ed4c2d8abf4769", "score": "0.6102686", "text": "function file_get_contents_curl($url){\n$ch = curl_init();\ncurl_setopt($ch, CURLOPT_HEADER, 0);\ncurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\ncurl_setopt($ch, CURLOPT_URL, $url);\ncurl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);\n\n$data = curl_exec($ch);\ncurl_close($ch);\n\nreturn $data;\n}", "title": "" }, { "docid": "daebead99666f42a01b4c62e2c9cf858", "score": "0.6097293", "text": "function curl_get_file_contents($URL) {\n $c = curl_init();\n curl_setopt($c, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($c, CURLOPT_URL, $URL);\n $contents = curl_exec($c);\n curl_close($c);\n\n if ($contents) return $contents;\n else return FALSE;\n}", "title": "" }, { "docid": "11934c56da0a106e1910de1344376b87", "score": "0.6093687", "text": "function file_get_contents_curl($url, $curlopt = array()){\r\n $ch = curl_init();\r\n $default_curlopt = array(\r\n CURLOPT_TIMEOUT => 2,\r\n CURLOPT_RETURNTRANSFER => 1,\r\n CURLOPT_FOLLOWLOCATION => 1,\r\n CURLOPT_USERAGENT => \"Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.13) Gecko/20101203 AlexaToolbar/alxf-1.54 Firefox/3.6.13 GTB7.1\"\r\n );\r\n $curlopt = array(CURLOPT_URL => $url) + $curlopt + $default_curlopt;\r\n curl_setopt_array($ch, $curlopt);\r\n $response = curl_exec($ch);\r\n if($response === false)\r\n trigger_error(curl_error($ch));\r\n curl_close($ch);\r\n return $response;\r\n }", "title": "" }, { "docid": "8bdbd46769b157245ea24b8cb5a76c86", "score": "0.60844743", "text": "function fetchUrl($url){\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_TIMEOUT, 20);\n \n $retData = curl_exec($ch);\n curl_close($ch); \n \n return $retData;\n}", "title": "" }, { "docid": "648214d976ffea513b044da5c3844fe3", "score": "0.6082858", "text": "function url_get_contents($url) {\n\tif (!function_exists('curl_init')){\n\t\tdie('CURL is not installed!');\n\t}\n\t$ch = curl_init($url);\n\tcurl_setopt($ch, CURLOPT_HEADER, false);\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n\t$response = curl_exec($ch);\n\tcurl_close($ch);\n\treturn $response;\n}", "title": "" }, { "docid": "480684e6847f0704c1a8d3663ad6aa31", "score": "0.6077661", "text": "function file_get_contents_curl($url)\n{\n\t$ch = curl_init();\n\n\tcurl_setopt($ch, CURLOPT_HEADER, 0);\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\tcurl_setopt($ch, CURLOPT_URL, $url);\n\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);\n\n\t$data = curl_exec($ch);\n\tcurl_close($ch);\n\n\treturn $data;\n}", "title": "" }, { "docid": "c952d223f234e0609a64893eb90726b2", "score": "0.6069514", "text": "function grabbing($url){\n $data = curl_init();\n curl_setopt($data, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($data, CURLOPT_URL, $url);\n $output = curl_exec($data);\n curl_close($data);\n return $output;\n}", "title": "" }, { "docid": "b772f0f03a7015307049f1804400bb6f", "score": "0.60638535", "text": "function curl_download_webpage($url) {\n\t$ch = curl_init();\n\t\n\tcurl_setopt($ch, CURLOPT_URL, $url);\n\tcurl_setopt($ch, CURLOPT_FAILONERROR, true);\n\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\tcurl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);\n\tcurl_setopt($ch, CURLOPT_TIMEOUT, 15);\n\t\n\t$data = curl_exec($ch);\n\t//$info = curl_getinfo($ch);\t// Get data about the request itself (e.g. HTTP code, ...).\n\tcurl_close($ch);\n\t\n\treturn $data;\n}", "title": "" }, { "docid": "7924b99a41d44d15cfa6830b8008f63a", "score": "0.6061576", "text": "public function get_file($url, $filename = '') {\n global $CFG;\n\n $path = $this->prepare_file($filename);\n $c = new curl;\n\n $result = $c->download_one($url, null, array('filepath' => $path, 'timeout' => $CFG->repositorygetfiletimeout));\n if ($result !== true) {\n // We changed the default behaviour of moodle_exception function to display our custom message\n throw new moodle_exception(get_string('errorwhiledownload', 'repository_dspace'), 'Error 1');\n }\n return array('path' => $path, 'url' => $url);\n }", "title": "" }, { "docid": "ba59a6428d7956a471b1fa3a258b2f6a", "score": "0.6059256", "text": "function curl_get_file_contents($url){ \n $url=str_replace('&amp;','&',$url); \n $ch=curl_init(); \n curl_setopt($ch, CURLOPT_URL, $url); \n curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1); \n $content = curl_exec ($ch); \n curl_close ($ch); \n return $content; \n}", "title": "" }, { "docid": "0ff32b06db33f31c908bca24061ad47e", "score": "0.6059221", "text": "function file_get_contents_curl($url) \n {\n $ch = curl_init();\n \n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); //Set curl to return the data instead of printing it to the browser.\n curl_setopt($ch, CURLOPT_URL, $url);\n \n $data = curl_exec($ch);\n curl_close($ch);\n \n return $data;\n }", "title": "" }, { "docid": "491f76b85aca3d595c5dae5b8524bf80", "score": "0.60583895", "text": "private function download(string $url): string {\n\t\t$downloads = AM_BASE_DIR . AM_DIR_CACHE . '/downloads';\n\t\tFileSystem::makeDir($downloads);\n\t\t$file = $downloads . '/' . sha1($url);\n\n\t\t$existing = FileSystem::glob(\"$file*\");\n\n\t\tif (!empty($existing)) {\n\t\t\t$file = $existing[0];\n\t\t\tDebug::log(array($url, $file), 'Already downloaded before');\n\n\t\t\treturn $file;\n\t\t}\n\n\t\tif (!Fetch::download($url, $file)) {\n\t\t\tDebug::log($url, 'File not found');\n\n\t\t\treturn '';\n\t\t}\n\n\t\tif ($extension = FileSystem::getImageExtensionFromMimeType($file)) {\n\t\t\trename($file, \"$file$extension\");\n\t\t\t$file = \"$file$extension\";\n\t\t}\n\n\t\tDebug::log(array($url, $file), 'Downloaded');\n\n\t\treturn $file;\n\t}", "title": "" }, { "docid": "9eaeb7062f0007215a0975b86f85e6b5", "score": "0.60382426", "text": "private function curl_download($url)\n {\n if (!function_exists('curl_init')) {\n die('Sorry cURL is not installed!');\n }\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_REFERER, $this->publicUrl);\n curl_setopt($ch, CURLOPT_USERAGENT, $_SERVER[\"HTTP_USER_AGENT\"]);\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($ch, CURLOPT_TIMEOUT, 10);\n $output = curl_exec($ch);\n curl_close($ch);\n return $output;\n }", "title": "" }, { "docid": "5cc6f97f222f65b073a647e1e3bb6b35", "score": "0.6030939", "text": "function file($url) {\n\t\t$file = Array();\n\t\t$socket = $this->fopen($url);\n\t\tif ($socket) {\n\t\t\t$file = Array();\n\t\t\twhile (!feof($socket)) {\n\t\t\t\t$file[] = fgets($socket, 10000);\n\t\t\t}\n\t\t} else {\n\t\t\treturn FALSE;\n\t\t}\n\t\treturn $file;\n\t}", "title": "" }, { "docid": "cb2cafe90b14ac5c19d5a40d600ce635", "score": "0.6024785", "text": "function curl_file_get_contents($url)\n{\n\t$ch = curl_init();\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\tcurl_setopt($ch, CURLOPT_URL, $url);\n\t$contents = curl_exec($ch);\n\tcurl_close($ch);\n\treturn (!empty($contents)) ? $contents : FALSE;\n}", "title": "" }, { "docid": "57294404600feb8e8f5414cc02f5d807", "score": "0.60193086", "text": "function get($url)\n{\n\t$data = null;\n\t\n\t$opts = array(\n\t CURLOPT_URL =>$url,\n\t CURLOPT_FOLLOWLOCATION => TRUE,\n\t CURLOPT_RETURNTRANSFER => TRUE\n\t);\n\t\n\t$ch = curl_init();\n\tcurl_setopt_array($ch, $opts);\n\t$data = curl_exec($ch);\n\t$info = curl_getinfo($ch); \n\tcurl_close($ch);\n\t\n\treturn $data;\n}", "title": "" }, { "docid": "005c792c9dc2c4a150828f8ab9286a52", "score": "0.60095304", "text": "function get_external_file($url)\n{\n $timeout = 15;\n // spoofing FireFox 18.0\n $useragent=\"Mozilla/5.0 (Windows NT 5.1; rv:18.0) Gecko/20100101 Firefox/18.0\";\n\n if (in_array ('curl', get_loaded_extensions())) {\n // Fetch feed from URL\n $curl = curl_init();\n curl_setopt($curl, CURLOPT_URL, $url);\n curl_setopt($curl, CURLOPT_TIMEOUT, $timeout);\n curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($curl, CURLOPT_HEADER, false);\n\n // FeedBurner requires a proper USER-AGENT...\n curl_setopt($curl, CURL_HTTP_VERSION_1_1, true);\n curl_setopt($curl, CURLOPT_ENCODING, \"gzip, deflate\");\n curl_setopt($curl, CURLOPT_USERAGENT, $useragent);\n\n $data = curl_exec($curl);\n\n $httpcode = curl_getinfo($curl, CURLINFO_HTTP_CODE);\n\n $httpcodeOK = isset($httpcode) and ($httpcode == 200 or $httpcode == 301);\n\n curl_close($curl);\n } else {\n\n // create http context and add timeout and user-agent\n $context = stream_context_create(array('http'=>array('timeout' => $timeout,'header'=> \"User-Agent: \".$useragent,/*spoot Mozilla Firefox*/'follow_location' => true)));\n\n // only download page lesser than 4MB\n $data = @file_get_contents($url, false, $context, -1, 4000000); // We download at most 4 MB from source.\n\n if(isset($http_response_header) and isset($http_response_header[0])) {\n $httpcodeOK = isset($http_response_header) and isset($http_response_header[0]) and ((strpos($http_response_header[0], '200 OK') !== FALSE) or (strpos($http_response_header[0], '301 Moved Permanently') !== FALSE));\n }\n }\n\n // if response is not empty and response is OK\n if (isset($data) and isset($httpcodeOK) and $httpcodeOK ) {\n\n // take charset of page and get it\n preg_match('#<meta .*charset=.*>#Usi', $data, $meta);\n\n // if meta tag is found\n if (!empty($meta[0])) {\n // retrieve encoding in $enc\n preg_match('#charset=\"?(.*)\"#si', $meta[0], $enc);\n\n // if charset is found set it otherwise, set it to utf-8\n $html_charset = (!empty($enc[1])) ? strtolower($enc[1]) : 'utf-8';\n\n } else {\n $html_charset = 'utf-8';\n $enc[1] = '';\n }\n\n // replace charset of url to charset of page\n $data = str_replace('charset='.$enc[1], 'charset='.$html_charset, $data);\n\n return $data;\n }\n else {\n return FALSE;\n }\n}", "title": "" }, { "docid": "fc9d05bbf0c9b15a4a3c2cd39124bbd3", "score": "0.60038126", "text": "function file_get_contents_curl($url, $cookie) {\n\t$ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $url);\n\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\tif (!IsNullOrEmptyString($cookie))\n\t\tcurl_setopt($ch, CURLOPT_COOKIE, $cookie);\n\tcurl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.106 Safari/537.36');\n $result = curl_exec($ch);\n curl_close($ch);\n\t\n return $result;\n}", "title": "" }, { "docid": "2917ba1a3ae905e42a8e175abc13d27e", "score": "0.6002292", "text": "public static function load($url) {\n\t\t$curl = curl_init();\n\t $timeout = 5;\n\t curl_setopt($curl,CURLOPT_URL,$url);\n\t curl_setopt($curl,CURLOPT_RETURNTRANSFER,1);\n\t curl_setopt($curl,CURLOPT_CONNECTTIMEOUT,$timeout);\n\t\tcurl_setopt($curl,CURLOPT_FOLLOWLOCATION,true);\n\t\tcurl_setopt($curl,CURLOPT_SSL_VERIFYHOST,0);\n\t\tcurl_setopt($curl,CURLOPT_SSL_VERIFYPEER,0); \n\t $data = curl_exec($curl);\n\n\t\tif(!$data) {\n\t\t\tdie(\"Url::load: Curl process failed to load \".$url.\" with \".curl_error($curl));\n\t\t}\n\n\t\tcurl_close($curl);\n\t\treturn $data;\n\t}", "title": "" }, { "docid": "3e83a5b69cc335248aa04e7b1354e54a", "score": "0.59961075", "text": "function file_get_contents_curl($url){\n\t$ch=curl_init();\n\n\tcurl_setopt($ch, CURLOPT_HEADER, 0);\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\tcurl_setopt($ch, CURLOPT_URL, $url);\n\n\t$data=curl_exec($ch);\n\tcurl_close($ch);\n\treturn $data;\n\n}", "title": "" }, { "docid": "09c6f8cdcb0340fa863887ca18a6d7d3", "score": "0.5993902", "text": "function mgcs_get($url){\n\t$ch = curl_init();\n\tcurl_setopt($ch, CURLOPT_URL, $url);\n\tcurl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n\n\tif( ! $result = curl_exec($ch)){\n trigger_error(curl_error($ch));\n }\n curl_close($ch);\n\n return $result;\n}", "title": "" }, { "docid": "3b40e5b141c5ecedcc9b0becd5d749a4", "score": "0.5991801", "text": "public function Get($url)\n {\n \n $ch = curl_init();\n curl_setopt($ch, CURLOPT_COOKIEJAR, $this->cookiefile);\n curl_setopt($ch, CURLOPT_COOKIEFILE, $this->cookiefile);\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);\n curl_setopt($ch, CURLOPT_USERAGENT, \"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1\"); \n curl_setopt($ch, CURLOPT_REFERER, $this->referrer);\n curl_setopt($ch, CURLOPT_GET, 1);\n \n $head = curl_exec($ch);\n $httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);\n curl_close($ch);\n \n return $head; \n }", "title": "" }, { "docid": "00d1798aeab207def6f3bf26e50a1fc8", "score": "0.59907556", "text": "private function __fetch( $url )\n\t{\n\t\tif (! $this->__curl) {\n\t\t\t$this->__curl = curl_init();\n\t\t}\n\t\t\n\t\t//curl_setopt( $this->__curl, CURLOPT_VERBOSE, true );\n\t\tcurl_setopt( $this->__curl, CURLOPT_URL, $url );\n\t\tcurl_setopt( $this->__curl, CURLOPT_RETURNTRANSFER, true );\n\t\tcurl_setopt( $this->__curl, CURLOPT_USERAGENT, $this->curlOptions['user_agent'] );\n\t\tcurl_setopt( $this->__curl, CURLOPT_CONNECTTIMEOUT, $this->curlOptions['connect_timeout'] );\n\t\tcurl_setopt( $this->__curl, CURLOPT_TIMEOUT, $this->curlOptions['timeout'] );\n\t\tcurl_setopt( $this->__curl, CURLOPT_PROXY, $this->curlOptions['proxy'] );\n\t\t$content = curl_exec( $this->__curl );\n\t\t\n\t\tif ($content === false || curl_getinfo( $this->__curl, CURLINFO_HTTP_CODE ) !== 200) {\n\t\t\tthrow new HTTPFetchException( \"Error fetching url '$url'\" . (curl_errno( $this->__curl ) ? ', curl error: ' . curl_error( $this->__curl ) : '') );\n\t\t}\n\t\treturn $content;\n\t}", "title": "" }, { "docid": "873996cca487dd7448142c359720025d", "score": "0.59867793", "text": "function getdata($url){\n$ch = curl_init();\n/**\n* Set the URL of the page or file to download.\n*/\ncurl_setopt($ch, CURLOPT_URL,$url);\n/**\n* Ask cURL to return the contents in a variable\n* instead of simply echoing them to the browser.\n*/\ncurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n/**\n* Execute the cURL session\n*/\n $contents = curl_exec ($ch);\n/**\n* Close cURL session\n*/\ncurl_close ($ch);\nreturn $contents;\n}", "title": "" }, { "docid": "b8e7fc3d859211c199b960a29953a907", "score": "0.59834594", "text": "function curl_get($url)\n {\n //初始化\n $curl = curl_init();\n //设置抓取的url\n curl_setopt($curl, CURLOPT_URL, $url);\n //设置头文件的信息作为数据流输出\n curl_setopt($curl, CURLOPT_HEADER, 0);\n //设置获取的信息以文件流的形式返回,而不是直接输出。\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);\n //执行命令\n $data = curl_exec($curl);\n //关闭URL请求\n curl_close($curl);\n //显示获得的数据\n return $data;\n }", "title": "" }, { "docid": "6139a6b8d0e834d14512dfb30e1f83e4", "score": "0.59784997", "text": "function get_content_of_url($url){\n\t$ohyeah = curl_init();\n\tcurl_setopt($ohyeah, CURLOPT_RETURNTRANSFER, 1);\n\tcurl_setopt($ohyeah, CURLOPT_URL, $url);\n\t$data = curl_exec($ohyeah);\n\tcurl_close($ohyeah);\n\treturn $data;\n}", "title": "" }, { "docid": "ad8b9db274191771cf52ca80b3e9ee2b", "score": "0.596978", "text": "public function getBinary($url) {\n $this->init();\n curl_setopt($this->curl, CURLOPT_URL, $url);\n curl_setopt($this->curl, CURLOPT_BINARYTRANSFER, 1);\n $result = curl_exec($this->curl);\n $this->_close();\n return $result;\n }", "title": "" }, { "docid": "688b76ea987f082152bd5dcb4e479086", "score": "0.5939221", "text": "function getUrlContent($url) {\n $cacheFolder = 'cache/';\n $filename = date('YmdH') . '.html';\n if (!file_exists($cacheFolder . $filename)) {\n $ch = curl_init($url);\n $fp = fopen($cacheFolder . $filename, 'w');\n curl_setopt($ch, CURLOPT_FILE, $fp);\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_HTTPHEADER, Array('User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.21 (KHTML, like Gecko) Chrome/19.0.1042.0 Safari/535.21'));\n curl_exec($ch);\n curl_close($ch);\n fclose($fp);\n }\n return file_get_contents($cacheFolder . $filename);\n}", "title": "" }, { "docid": "870b0d7b6c8a2113e22339054c48f586", "score": "0.5937622", "text": "public function downloadRepresentativeImage(string $url): ?string;", "title": "" }, { "docid": "d72a77cf616724b121fbd5bfc355b3da", "score": "0.59322006", "text": "public function downloadFile(string $url): ?string {\n try {\n $tmpFile = tempnam(sys_get_temp_dir(), \"ReC\");\n $this->client->request(\"GET\", $url, [\n \"sink\" => $tmpFile\n ]);\n return $tmpFile;\n } catch (ClientException $e) {\n return null;\n }\n }", "title": "" }, { "docid": "d66252e8aca93289f5541d9b529cdb13", "score": "0.59320545", "text": "function getUrlToDownloadFile() {\r\n\t\treturn \"http://www.elitetorrent.net/get-torrent/\";\r\n\t}", "title": "" }, { "docid": "5105db4e1b83dc725669f7cfa84c82d2", "score": "0.5926326", "text": "function file_get_contents_curl($url) {\n $ch = curl_init();\n\n curl_setopt($ch, CURLOPT_AUTOREFERER, TRUE);\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n\n $data = curl_exec($ch);\n curl_close($ch);\n\n return $data;\n}", "title": "" }, { "docid": "a80b122b97207ec255355b83a9acd463", "score": "0.59245926", "text": "function curl_get_contents($url) {\r\r $ch = curl_init();\r\r // Set the URL\r\r curl_setopt($ch, CURLOPT_URL, $url);\r\r // Removes the headers from the output\r\r curl_setopt($ch, CURLOPT_HEADER, 0);\r\r // Return the output instead of displaying it directly\r\r curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\r\r // Execute the curl session\r\r $output = curl_exec($ch);\r\r // Close the curl session\r\r curl_close($ch);\r\r // Return the output as a variable\r\r return $output;\r\r }", "title": "" }, { "docid": "56c7ebd5a9592ff7896b527ab7809f6f", "score": "0.59217", "text": "function url_get_contents($Url) {\n if (!function_exists('curl_init')){\n die('CURL is not installed!');\n }\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $Url);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n $output = curl_exec($ch);\n curl_close($ch);\n return $output;\n}", "title": "" }, { "docid": "45b7e123182f5c75a14047fdda42df56", "score": "0.59190124", "text": "private function loadURL($url){\n\t\t$header = array();\n\t\t// Parse the URL to extract the hostname\n\t\t$parse = parse_url($url);\n\t\t$opts = array(\n\t\t\tCURLOPT_USERAGENT => Configuration::getConfig('http', 'useragent'),\n\t\t\tCURLOPT_RESOLVE => $this->getResolve($parse['host'])\n\t\t);\n\n\t\t$html = getContents($url, $header, $opts);\n\t\treturn str_get_html($html);\n\t}", "title": "" }, { "docid": "4803c3491b0592144421145604da0e41", "score": "0.59188044", "text": "function httpGet($url)\r\r\n{\r\r\n\t$ch = curl_init();\r\r\n\r\r\n\tcurl_setopt($ch,CURLOPT_URL,$url);\r\r\n\tcurl_setopt($ch,CURLOPT_RETURNTRANSFER,true);\r\r\n\t// curl_setopt($ch,CURLOPT_HEADER, false);\r\r\n\r\r\n\t$output=curl_exec($ch);\r\r\n\r\r\n\tcurl_close($ch);\r\r\n\treturn $output;\r\r\n}", "title": "" }, { "docid": "75422b1dae6a2119539db1bd3c0c8626", "score": "0.5907999", "text": "protected function downloadContent($url) {\n\t\t$path = rtrim($this->savePath, '/');\n\t\t$ch = curl_init($url);\n\t\t$fp = fopen(\"$path/$this->saveFilename\", 'wb');\n\t\tcurl_setopt($ch, CURLOPT_FILE, $fp);\n\t\tcurl_setopt($ch, CURLOPT_HEADER, 0);\n\t\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);\n\t\tcurl_setopt($ch, CURLOPT_IPRESOLVE, CURL_IPRESOLVE_V4);\n\t\t$exec = curl_exec($ch);\n\t\tcurl_close($ch);\n\t\tfclose($fp);\n\t\treturn $exec;\n\t}", "title": "" }, { "docid": "a264adad477400cb78dad9e3ba93a639", "score": "0.5902641", "text": "function file_get_contents_curl($url)\n{\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);\n\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);\n\tcurl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);\n\n $data = curl_exec($ch);\n\t$info = curl_getinfo($ch, CURLINFO_CONTENT_TYPE);\n\t\n\t//checking mime types\n\tif(strstr($info,'text/html')) {\n\t\tcurl_close($ch);\n \treturn $data;\n\t} else {\n\t\treturn false;\n\t}\n}", "title": "" }, { "docid": "a9b24dedc16d28aa5330b58f1b56b3ff", "score": "0.5901754", "text": "function bookshelf_fetch($sUrl)\n\t{\n\t\t// Check if file_get_contents will work\n\t\tif ( ini_get('allow_url_fopen') && function_exists('file_get_contents') && $sUrl )\n\t\t{\n\t\t\t// Use file_get_contents\n\t\t\treturn file_get_contents($sUrl);\n\t\t}\n\t\telseif ( function_exists('curl_init') && $sUrl )\n\t\t{\n\t\t\t// Fall back to cURL\n\t\t\t$hCurl = curl_init();\n\t\t\t$iTimeout = 5;\n\t\t\tcurl_setopt($hCurl, CURLOPT_URL, $sUrl);\n\t\t\tcurl_setopt($hCurl, CURLOPT_RETURNTRANSFER, 1);\n\t\t\tcurl_setopt($hCurl, CURLOPT_CONNECTTIMEOUT, $iTimeout);\n\t\t\t$sFileContents = curl_exec($hCurl);\n\t\t\tcurl_close($hCurl);\n\t\t\treturn $sFileContents;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t}", "title": "" }, { "docid": "daf16264f919892a130cc64388287e8e", "score": "0.59008425", "text": "function urlopen($url) {\n if (function_exists('curl_init')) {\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt ($ch, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($ch, CURLOPT_HEADER, false);\n $result = curl_exec($ch);\n curl_close($ch);\n return $result;\n } else {\n return file_get_contents($url);\n }\n}", "title": "" }, { "docid": "a007fcbfff2200cc719ef1e4d2cc6875", "score": "0.58989143", "text": "function downloadFile($url, $filePath) {\r\n //echo \"\\n\\n*********************************************************\\n\";\r\n //echo \"From url=$url\\n\";\r\n //echo \"To filePath=$filePath\\n\";\r\n set_time_limit(0); // infinity\r\n $fp = fopen ($filePath, 'w+');\r\n $ch = curl_init($url);\r\n //curl_setopt($ch, CURLOPT_VERBOSE, true); // output verbose information\r\n curl_setopt($ch, CURLOPT_CAINFO, CACERT_PATH); // Set cert\r\n curl_setopt($ch, CURLOPT_FILE, $fp);\r\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); // follow redirects\r\n curl_setopt($ch, CURLOPT_TIMEOUT, 120);\r\n curl_exec($ch);\r\n if(curl_errno($ch)) {\r\n echo \"***Download error #\".curl_errno($ch). \": \".curl_error($ch).\"\\n\";\r\n }\r\n curl_close($ch);\r\n fclose($fp);\r\n}", "title": "" }, { "docid": "7c262c32fa0150068bbf2e3c1b2e628a", "score": "0.58852696", "text": "protected function request($url)\n {\n return @file_get_contents($url);\n }", "title": "" }, { "docid": "89163abc88311da536f8a924e326bc26", "score": "0.58813745", "text": "private function get_content($url) {\n\t\t\t$curl = curl_init();\n\t\t\tcurl_setopt_array($curl, array(\n\t\t\t\t\t\t\t\t\tCURLOPT_RETURNTRANSFER => 1,\n\t\t\t\t\t\t\t\t\tCURLOPT_URL => $url,\n\t\t\t\t\t\t\t\t\tCURLOPT_SSL_VERIFYPEER => 0,\n\t\t\t\t\t\t\t\t\tCURLOPT_USERAGENT => \"Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:19.0) Gecko/20100101 Firefox/19.0\"\n\t\t\t\t\t\t\t\t));\n\t\t\t$content = curl_exec($curl);\n\t\t\tcurl_close($curl);\n\t\t\t\n\t\t\treturn $content;\n\t\t}", "title": "" }, { "docid": "1719048753efb8760f9291142bbda1ed", "score": "0.58811504", "text": "function curlGet($url) {\n\t$ch = curl_init();\n\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);\n\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);\n\tcurl_setopt($ch, CURLOPT_URL, $url);\n\n\t$results = curl_exec($ch);\n}", "title": "" }, { "docid": "0b493253ec8538c5a802581a3220d092", "score": "0.58665633", "text": "function wc_get_filename_from_url($file_url)\n {\n }", "title": "" }, { "docid": "57c384d5e2675c76975f6bf20a924ea7", "score": "0.5860745", "text": "function curl_get($url)\n{\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n $result = curl_exec($ch);\n curl_close($ch);\n return $result;\n}", "title": "" }, { "docid": "2256b5f0a4352c7da60e0db15137a451", "score": "0.5857759", "text": "public function download(string $url)\n {\n if ($this->isLocalUrl($url)) {\n $this->log('info', 'Not downloading from local url: '.$url);\n\n return $url;\n }\n\n $this->log('info', 'Downloading from url: '.$url);\n $actualUrl = $url;\n $content = null;\n\n $this->guzzleException = null;\n\n try {\n $client = new Client();\n $content = $client->get($url, [\n 'on_stats' => function (TransferStats $stats) use (&$actualUrl) {\n $actualUrl = $stats->getEffectiveUri();\n },\n // Pretend to be a real browser.\n 'headers' => [\n 'user-agent' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36',\n ],\n ])->getBody()->getContents();\n } catch (GuzzleException $ex) {\n $this->guzzleException = $ex;\n $this->log('error', 'Downloading from '.$url.' failed: '.$ex->getMessage());\n\n return null;\n }\n if (empty($content)) {\n $this->log('error', 'Downloading from '.$url.' failed. No content');\n\n return null;\n }\n\n $filename = md5($actualUrl);\n $info = pathinfo(HttpUri::createFromString($url)->getPath());\n if (!empty($info['extension'])) {\n $filename .= '.'.$info['extension'];\n }\n $path = rtrim($this->filesPath, '/').'/'.$filename;\n\n $filesystem = new Filesystem();\n $filesystem->dumpFile($path, $content);\n\n if (empty($info['extension'])) {\n // Try to guess the file extension type and rename it.\n $file = new File($path);\n $extension = $file->guessExtension();\n if ($extension) {\n $filesystem->rename($path, $path.'.'.$extension, true);\n $filename .= '.'.$extension;\n }\n }\n\n $localUrl = $this->baseUrlResolver->process(HttpUri::createFromString($this->filesUrl.'/'.$filename));\n\n $this->log('info', 'Data written to file: '.$path.' ('.$url.')');\n\n return $localUrl->__toString();\n }", "title": "" }, { "docid": "61b1b9f5b3df39ac3c6284fb8fa6f9b8", "score": "0.5853449", "text": "public function setFileFromUrl(string $url);", "title": "" }, { "docid": "b3f68defc38117dbf8e6b0bdb1f2e4d0", "score": "0.5844021", "text": "function download($url) {\n $useragent='Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0';\n $ch = curl_init();\n //you might need to set some cookie details up (depending on the site)\n //curl_setopt($ch, CURLOPT_TIMEOUT, 1);\n curl_setopt($ch, CURLOPT_URL,$url); //set the url we want to use\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($ch, CURLOPT_TIMEOUT, 1000);\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n curl_setopt($ch, CURLOPT_USERAGENT, $useragent); //set our user agent\n $result= curl_exec ($ch); //execute and get the results\n if($result){\n return $result;\n }else{\n return false;\n }\n curl_close ($ch);\n}", "title": "" }, { "docid": "4973ee857e8f280c42c96c047d9d6c11", "score": "0.58365566", "text": "public function fetch($file);", "title": "" }, { "docid": "73cd96f7e3b30699e0aa79f7319f444e", "score": "0.58360296", "text": "private function fetch( $url ) {\n\n\t\t$response = wp_remote_get(\n\t\t\t$url,\n\t\t\t[\n\t\t\t\t'headers' => [\n\t\t\t\t\t'Accept' => 'application/json',\n\t\t\t\t\t'Authorization' => 'Token ' . Config::get( 'stock_photos_d3_api_key' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\tif ( is_wp_error( $response ) ) {\n\n\t\t\treturn false;\n\n\t\t}\n\n\t\treturn json_decode( wp_remote_retrieve_body( $response ) );\n\n\t}", "title": "" }, { "docid": "8ec6915179f037bc09df773524828057", "score": "0.5826307", "text": "protected function file($url) {\n \n // if this is an absolute url cancel\n if(preg_match('!(http|https)\\:\\/\\/!i', $url)) return false;\n \n // skip urls without extensions\n if(!preg_match('!\\.[a-z]+$!',$url)) return false;\n\n // try to get all files for the current page\n $files = $this->files();\n \n // cancel if no files are available\n if(!$files) return false;\n\n // try to find the file\n return $files->find($url);\n \n }", "title": "" }, { "docid": "03135cde1883edb3a24e7f23d850075f", "score": "0.5822275", "text": "function file_get_contents_curl($url) {\n $ch = curl_init();\n $agent = $_SERVER['HTTP_USER_AGENT'];\n\n curl_setopt($ch, CURLOPT_AUTOREFERER, TRUE);\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, FALSE); \n curl_setopt($ch,CURLOPT_USERAGENT,$agent);\n\n $data = curl_exec($ch);\n curl_close($ch);\n\n return $data;\n}", "title": "" }, { "docid": "53abaa894a0d58839b176e0bf25bfb4b", "score": "0.58177626", "text": "function cURLdownload($url, $file)\n{\n if( !cURLcheckBasicFunctions() ) return \"UNAVAILABLE: cURL Basic Functions\";\n $ch = curl_init();\n if($ch)\n {\n $fp = fopen($file, \"w\");\n if($fp)\n {\n if( !curl_setopt($ch, CURLOPT_URL, $url) ) return \"FAIL: curl_setopt(CURLOPT_URL)\";\n if( !curl_setopt($ch, CURLOPT_FILE, $fp) ) return \"FAIL: curl_setopt(CURLOPT_FILE)\";\n if( !curl_setopt($ch, CURLOPT_HEADER, 0) ) return \"FAIL: curl_setopt(CURLOPT_HEADER)\";\n if( !curl_exec($ch) ) return \"FAIL: curl_exec()\";\n curl_close($ch);\n fclose($fp);\n return true;\n }\n else return false;\n }\n else return false;\n}", "title": "" }, { "docid": "cee834f9badaa418e8e37983070de480", "score": "0.580955", "text": "public function get($url);", "title": "" }, { "docid": "cee834f9badaa418e8e37983070de480", "score": "0.580955", "text": "public function get($url);", "title": "" }, { "docid": "998527d846d081d480287a2638d14171", "score": "0.580695", "text": "private function geturl($url){\n\t\t$ch = curl_init();\n\t\tcurl_setopt($ch, CURLOPT_URL, $url);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 5);\n\t\t$ip = rand(0,255).'.'.rand(0,255).'.'.rand(0,255).'.'.rand(0,255);\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array(\"REMOTE_ADDR: $ip\", \"HTTP_X_FORWARDED_FOR: $ip\"));\n\t\tcurl_setopt($ch, CURLOPT_USERAGENT, \"Mozilla/\".rand(3,5).\".\".rand(0,3).\" (Windows NT \".rand(3,5).\".\".rand(0,2).\"; rv:2.0.1) Gecko/20100101 Firefox/\".rand(3,5).\".0.1\");\n\t\t$html = curl_exec($ch);\n\t\tcurl_close($ch);\n\t\treturn $html;\n\t}", "title": "" }, { "docid": "d72ec4cce92e263ad894b88df6140c7d", "score": "0.5805174", "text": "function curlGet($url) {\n\t$ch = curl_init();\t// Initialising cURL session\n\t// Setting cURL options\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);\t// Returning transfer as a string\n//\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);\t// Follow location\n\tcurl_setopt($ch, CURLOPT_URL, $url);\t// Setting URL\n\t$results = curl_exec($ch);\t// Executing cURL session\n\treturn $results;\t// Return the results\n}", "title": "" }, { "docid": "2efb5d744a2be09a4c49680017776818", "score": "0.5803548", "text": "function get_url($url=''){\n $curl = curl_init();\n curl_setopt($curl, CURLOPT_URL, $url);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE);\n curl_setopt($curl, CURLOPT_USERAGENT, 'Mozilla/5.0 (KHTML, like Gecko)');\n $output = curl_exec($curl);\n $headers = curl_getinfo($curl);\n curl_close($curl);\n return array( 'headers'=>$headers, 'content'=>$output );\n}", "title": "" } ]
1b39e02288f33f806d95ffad0bcd4534
Seed the application's database.
[ { "docid": "26b11872c19cb55067c71edc764c316d", "score": "0.0", "text": "public function run()\n {\n // $this->call(PembelianTableSeeder::class);\n Model::unguard();\n\n $this->call(PenjualTableSeeder::class);\n $this->call(TokoTableSeeder::class);\n\n $this->call(PembelianTableSeeder::class);\n $this->call(PengirimanTableSeeder::class);\n\n Model::reguard();\n }", "title": "" } ]
[ { "docid": "2d25564bcd887770f1d18e0a18ad8e56", "score": "0.79171", "text": "protected function seedDatabase()\n {\n // ...\n }", "title": "" }, { "docid": "fd7776f672f19c55bc854ee043aa0f77", "score": "0.7882304", "text": "protected function setUpDatabase()\n {\n $this->seed('DatabaseSeeder');\n }", "title": "" }, { "docid": "a6579d8cd98a7a688483202fa45add65", "score": "0.78815496", "text": "protected function dbSeed()\n {\n $this->call('db:seed', [\n '--database' => $this->connection['name'],\n '--class' => $this->seeder,\n '--force' => $force = $this->input->getOption('force')\n ]);\n }", "title": "" }, { "docid": "99c6a2e37944ec2e545776903c3b849b", "score": "0.7596948", "text": "public function seedDatabase()\n {\n $fileSystem = new Filesystem();\n $classFinder = new ClassFinder();\n\n foreach ($fileSystem->files(__DIR__.'/seeds') as $file) {\n $fileSystem->requireOnce($file);\n $migrationClass = $classFinder->findClass($file);\n\n (new $migrationClass())->run();\n }\n }", "title": "" }, { "docid": "e99883212706a90024182e14c29be0fc", "score": "0.7215391", "text": "private function seedDatabase()\n {\n DB::table('subdomains')->insert([\n 'subdomain' => 'www',\n 'default' => '1',\n ]);\n }", "title": "" }, { "docid": "f3d217d48d6398149d04388ef73b7b2a", "score": "0.6980551", "text": "public function run()\n {\n if (app()->environment() == 'local') {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n $this->call(RolesSeeder::class);\n $this->call(UsersSeeder::class);\n $this->call(PostsSeeder::class);\n $this->call(PostsMediaSeeder::class);\n $this->call(CategoriesSeeder::class);\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }\n if (app()->environment() == 'production') {\n $this->call(RolesProductionSeeder::class);\n $this->call(UsersProductionSeeder::class);\n $this->call(PostsProductionSeeder::class);\n $this->call(CategoriesProductionSeeder::class);\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }\n }", "title": "" }, { "docid": "5bd8a382d534576ac23aa7fafa91f69d", "score": "0.69286734", "text": "public function run()\n {\n // $this->call(UserSeeder::class);\n\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n DB::table('users')->truncate();\n DB::table('categories')->truncate();\n\n factory(User::class, 50)->create();\n factory(Category::class, 15)->create();\n }", "title": "" }, { "docid": "2ac4b5ab2d74be0fe8572dd2fab1bc66", "score": "0.6923872", "text": "public function run()\n {\n Eloquent::unguard();\n\n DB::select(DB::raw('SET FOREIGN_KEY_CHECKS=0'));\n\n $this->call('UserUnitsTableSeeder');\n $this->call('UsersTableSeeder');\n $this->call('UserProfilesTableSeeder');\n $this->call('StatusTableSeeder');\n $this->call('ModuleTableSeeder');\n $this->call('UserModuleTableSeeder');\n $this->call('LeavesTableSeeder');\n $this->call('MedicalClaimsTablesSeeder');\n $this->call('GeneralClaimsTableSeeder');\n $this->call('LookupFamilyRelationshipTableSeeder');\n $this->call('TaskTableSeeder');\n\n DB::table('uploads')->truncate();\n DB::table('audits')->truncate();\n DB::table('share_comments')->truncate();\n DB::table('shares')->truncate();\n DB::table('user_profile_contacts')->truncate();\n DB::table('user_profile_education_histories')->truncate();\n DB::table('user_profile_emergency_contacts')->truncate();\n DB::table('user_profile_employment_histories')->truncate();\n DB::table('user_profile_family_members')->truncate();\n\n DB::select(DB::raw('SET FOREIGN_KEY_CHECKS=1'));\n }", "title": "" }, { "docid": "f157ca28bf1b0613ef24367e4f55f5b6", "score": "0.6887427", "text": "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n DB::table('profesores')->truncate();\n DB::table('clases')->truncate();\n DB::table('aulas')->truncate();\n DB::statement('SET FOREIGN_KEY_CHECKS = 1');\n\n // \\App\\Models\\User::factory(10)->create();\n $this->call(ProfesorSeeder::class);\n $this->call(ClaseSeeder::class);\n $this->call(AulaSeeder::class);\n }", "title": "" }, { "docid": "14bcfcdf178e55585d48d15b958ccfc6", "score": "0.6879878", "text": "public function run()\n {\n $data = json_decode(file_get_contents(database_path('seeds/data/voyager.json')), true);\n foreach ($data as $table => $tableData) {\n $this->command->info(\"Seeding ${table}.\");\n \\Illuminate\\Support\\Facades\\DB::table($table)->delete();\n \\Illuminate\\Support\\Facades\\DB::table($table)->insert($tableData);\n }\n\n// $this->seed('DataTypesTableSeeder');\n// $this->seed('DataRowsTableSeeder');\n $this->seed('MenusTableSeeder');\n// $this->seed('MenuItemsTableSeeder');\n $this->seed('RolesTableSeeder');\n $this->seed('PermissionsTableSeeder');\n $this->seed('PermissionRoleTableSeeder');\n $this->seed('SettingsTableSeeder');\n }", "title": "" }, { "docid": "fb7d5bba21289ca1ca2041a5e18bd077", "score": "0.68723965", "text": "public function run()\n {\n// factory(Category::class, 20)->create();\n// factory(Post::class, 50)->create();\n// factory(Tag::class, 10)->create();\n\n $this->call(UserTableSeed::class);\n $this->call(PostTableSeed::class);\n }", "title": "" }, { "docid": "5bc34fb4f931bbc1e4e32c27c00ecb12", "score": "0.6869451", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n // Sample::truncate();\n // TestItem::truncate();\n // UOM::truncate();\n\n User::truncate();\n factory(User::class, 20)->create();\n }", "title": "" }, { "docid": "dc40e6eb4d4714e9e1a271d89794aadb", "score": "0.6866685", "text": "protected function setUpDatabase(): void\n {\n $this->getConnection()->connect();\n\n $this->createTables();\n $this->truncateTables();\n\n if (!empty($this->fixtures)) {\n $this->insertFixtures($this->fixtures);\n }\n }", "title": "" }, { "docid": "e4b8a9c4c5912933fcf5d09043bcf177", "score": "0.6865336", "text": "protected function seedDatabase(): void\n {\n // set the standard models in the default scope\n parent::seedDatabase();\n\n // several models outside of the default scope\n for ($x = 0; $x < 3; $x++) {\n\n $this->createNewStandardModel([\n 'name' => 'model (outside of scope) ' . ($x + 1),\n 'scope' => 0,\n ]);\n }\n }", "title": "" }, { "docid": "362169b9dac7e15233f3d10273d5aae4", "score": "0.68644124", "text": "public function run()\n {\n factory(Blog::class, 10)->create();\n factory(Task::class, 82)->create();\n factory(Product::class, 5)->create();\n\n User::insert([\n 'email' => 'root@example.com',\n 'name' => 'Administrator',\n 'password' => bcrypt('secret'),\n ]);\n }", "title": "" }, { "docid": "b217ccb82ae9e75ff84e364705e8ae79", "score": "0.685091", "text": "public function initDatabase()\n {\n $this->call('migrate');\n\n $userModel = config('admin.database.users_model');\n\n if ($userModel::count() == 0) {\n $this->call('db:seed', ['--class' => \\Encore\\Admin\\Auth\\Database\\AdminTablesSeeder::class]);\n }\n }", "title": "" }, { "docid": "bd6458274ff09172851640f92c233c59", "score": "0.6845989", "text": "public function run()\n {\n Schema::disableForeignKeyConstraints();\n \n User::truncate();\n TipoUsuario::truncate();\n Reserva::truncate();\n PuntuacionEstablecimiento::truncate();\n PuntuacionProducto::truncate();\n Producto::truncate();\n Imagen::truncate();\n Establecimiento::truncate();\n Carta::truncate();\n\n $this->call(TipoUsuarioSeeder::class);\n\n foreach (range(1, 10) as $i){\n $u = factory(User::class)->create();\n $u->usuarios_tipo()->attach(TipoUsuario::all()->random());\n }\n\n\n //factory(Establecimiento::class,4)->create();\n //factory(Reserva::class,20)->create();\n //factory(Carta::class, 4)->create(); //Crear tantas como restaurantes\n //factory(Producto::class,100)->create();\n //factory(PuntuacionEstablecimiento::class,50)->create();\n //factory(PuntuacionProducto::class,50)->create();\n //factory(Imagen::class,200)->create();\n\n Schema::enableForeignKeyConstraints(); \n }", "title": "" }, { "docid": "e88dbce656036a8cb8a0efe67526dd75", "score": "0.6836158", "text": "public function run()\n {\n $this->call(CountriesTableSeeder::class);\n\n $this->call(SettingsTableSeeder::class);\n\n $this->call(AccessControlTableSeeder::class);\n\n if (App::environment() == 'local') {\n\n $this->call(TaxonomiesTableSeeder::class);\n\n $this->call(UsersTableSeeder::class);\n\n $this->call(PagesTableSeeder::class);\n\n $this->call(PostsTableSeeder::class);\n\n $this->call(CommentsTableSeeder::class);\n\n }\n\n }", "title": "" }, { "docid": "03e4884f8ad73f59d8e2e5db82548924", "score": "0.6835086", "text": "public function run()\n\t{\n\t\tModel::unguard();\n //Seed the countries\n $this->call('CountriesSeeder');\n\n\t\t$this->call('UsersTableSeeder');\n\t\t$this->call('FacebookUsersTableSeeder');\n\t\t$this->call('LogsTableSeeder');\n\t\t$this->call('UserProfilesTableSeeder');\n\t\t$this->call('UserSettingsTableSeeder');\n\t\t$this->call('VerifiedEmailsTableSeeder');\n\t\t$this->call('VerifiedPhoneNumbersTableSeeder');\n $this->call('OAuthClientTableSeeder');\n\n\t\t$this->call('BeaconTableSeeder');\n\t\t$this->call('AuctionTableSeeder');\n\t\t$this->call('ImmediateTableSeeder');\n\t\t$this->call('SizeTableSeeder');\n\t\t$this->call('SpecTableSeeder');\n\t\t$this->call('ShipmentTableSeeder');\n\n\t\t$this->call('QuestionTableSeeder');\n $this->call('KeywordTableSeeder');\n $this->call('CategoryTableSeeder');\n\n\t}", "title": "" }, { "docid": "a693c773daeb9ed2c3a5dca3b56c8e7d", "score": "0.6823892", "text": "public function run() {\n Eloquent::unguard();\n\n if (App::environment() === 'development' || App::environment() === 'local') {\n// echo \"\\nSeeding Development Seeders\\n\";\n// echo \"\\n=================================\\n\\n\";\n $this->developmentSeeder();\n } else if (App::environment() === 'testing') {\n// echo \"\\nSeeding Test Seeders\\n\";\n// echo \"\\n=================================\\n\\n\";\n $this->testingSeeder();\n } else {\n echo \"Unsupported environment: \" . App::environment();\n }\n }", "title": "" }, { "docid": "c8f9450dd0a187387bfb971ad4b665b8", "score": "0.6803113", "text": "public function run()\n {\n $this->createDefaultPermissionSeeder(env('DB_CONNECTION', 'mysql'));\n }", "title": "" }, { "docid": "c6f875d834059c18fbe1ecc666ee336f", "score": "0.6777696", "text": "public function run()\n {\n // Seed with test data if the environment is local or dev.\n if (App::environment('local')) {\n $this->call([\n UserSeeder::class,\n InitialSeeder::class\n ]);\n }\n\n if (App::environment('development')) {\n $this->call([UserSeeder::class]);\n }\n }", "title": "" }, { "docid": "3829c46225b21989677c7eab5601d597", "score": "0.67691284", "text": "public function run()\n {\n \t// Create admin account\n \t$user = factory(App\\User::class)->make([\n \t\t\t'name' => 'admin',\n \t\t\t'email' => 'muzware@gmail.com',\n \t\t\t'password' => bcrypt('admin')\n \t]);\n \tDB::table('users')->insert($user['attributes']);\n \t\n \t// Now seed the rest of user table with some fake users\n \tfor ($i=0; $i < $this->seed_count; $i++ ) {\n \t\t// Create a user with the model factory\n \t\t$user = factory(App\\User::class)->make();\n \t\t// Insert new user into the database\n \t\tDB::table('users')->insert($user['attributes']);\n \t}\n }", "title": "" }, { "docid": "8bb073245582ac4359353ab55a93f1e0", "score": "0.6763075", "text": "public function run()\n\t{\n\t\t// $this->call('UserTableSeeder');\n\n\t\t// Disable foreign key checking because truncate() will fail\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n\t\t$hasher = app()->make('hash');\n\t\t\\App\\User::truncate();\n\t\t\\App\\User::create(array(\n\t\t\t'name' => 'Admin',\n\t\t\t'email' => 'admin@domain.dev',\n\t\t\t'password' => $hasher->make('admin123'),\n\t\t\t'is_admin' => 1\n\t\t));\n\t\t\\App\\User::create(array(\n\t\t\t'name' => 'User',\n\t\t\t'email' => 'user@domain.dev',\n\t\t\t'password' => $hasher->make('user123'),\n\t\t\t'is_admin' => 0\n\t\t));\n\n\t\t// Enable it back\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 1');\n\t}", "title": "" }, { "docid": "969cdd82c19da247b96cfe077d22eeba", "score": "0.67608505", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n \tDB::statement('SET FOREIGN_KEY_CHECKS = 0');\n User::truncate();\n Alumnos::truncate();\n Materias::truncate();\n Calificaciones::truncate();\n\n $cantidad_alumnos = 5;\n $cantidad_materias = 5;\n \n\n factory(User::class, $cantidad_alumnos)->create();\n factory(Alumnos::class, $cantidad_alumnos)->create();\n factory(Materias::class, $cantidad_materias)->create();\n \n\n }", "title": "" }, { "docid": "ab03e496060e0544123b5643d8564a62", "score": "0.6758857", "text": "public function run()\n {\n $faker = Faker::create();\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n DB::table('users')->truncate();\n DB::statement('SET FOREIGN_KEY_CHECKS=1');\n DB::table('users')->insert([\n 'name'=>'System',\n 'email'=>'admin@ackosoft.com',\n 'password'=>bcrypt('admin')\n ]);\n\n for($i=1;$i<=100; $i++){\n DB::table('users')->insert([\n 'name'=>$faker->firstNameMale,\n 'email'=>$faker->freeEmail,\n 'password'=>bcrypt('123')\n ]);\n }\n }", "title": "" }, { "docid": "6b0fb45bc740467d359a2c62aa01f577", "score": "0.6736233", "text": "public function run()\n {\n $this->clearTablesBeforeSeeding();\n\n $this->seedUsers();\n }", "title": "" }, { "docid": "2db117b1d28054b0f08a58115645189d", "score": "0.67352927", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n // ?for seeding categories\n // Category::factory(5)->create();\n //? for seeding posts \n Post::factory(3)->create([\n 'category_id' => 5\n ]);\n }", "title": "" }, { "docid": "9fc640f0bf1a15bdf77b75141feed935", "score": "0.67321366", "text": "protected function initDB()\n {\n $this->create();\n }", "title": "" }, { "docid": "0966d7399ec08c4b1b1fb494706dc8ef", "score": "0.67244196", "text": "public function run()\n {\n echo \" \\n ******* Starting database seeder ******* \\n\";\n\n // Order is important for data seeding\n $this->call(LocalesTableSeeder::class);\n $this->call(ModulesTableSeeder::class);\n $this->call(ModulePlansTableSeeder::class);\n $this->call(ModuleSchemasTableSeeder::class);\n $this->call(ForumModuleTableSeeder::class);\n $this->call(RolesTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n $this->call(LinkTypesTableSeeder::class);\n $this->call(MenuGroupsTableSeeder::class);\n $this->call(PermissionRouteNameTableSeeder::class);\n // $this->call(MenusTableSeeder::class);\n $this->call(ParameterGroupsTableSeeder::class);\n $this->call(ParametersTableSeeder::class);\n $this->call(AddProcedureToModulesTableSeeder::class);\n $this->call(AddOutilGestionModuleToModulesTableSeeder::class);\n // $this->call(LocationsTableSeeder::class);\n $this->call(CountriesTableSeeder::class);\n $this->call(CountryTranslationsTableSeeder::class);\n /*\n * Keep This Commented we may use them instead of LocationsTableSeeder\n *\n $this->call(GovernoratesTableSeeder::class);\n $this->call(GovernorateTranslationsTableSeeder::class);\n $this->call(CitiesTableSeeder::class);\n $this->call(CityTranslationsTableSeeder::class);\n $this->call(ZonesTableSeeder::class);\n $this->call(ZoneTranslationsTableSeeder::class);*/\n\n $this->customApp();\n\n $this->fakeData();\n }", "title": "" }, { "docid": "53d1e42cfbc8c4d21c705740e02e0464", "score": "0.6721852", "text": "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n \\App\\User::truncate();\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n\n factory(\\App\\User::class)->create([\n 'id' => 1,\n 'name' => 'Antoan Popov',\n 'email' => 'admin@gmail.com',\n 'password' => bcrypt('admin'),\n ]);\n factory(\\App\\User::class)->create([\n 'id' => 2,\n 'name' => 'Светлана Попова',\n 'email' => 'svenika@abv.bg',\n 'password' => bcrypt('12SvenikA34'),\n ]);\n }", "title": "" }, { "docid": "2fca9bf0725abd081819588688399860", "score": "0.67005527", "text": "public function run()\n {\n $this->call(VideogameSeeder::class);\n $this->call(CategorySeeder::class);\n User::factory(15)->create();\n DB::table('users')->insert([\n 'name' => 'Santiago',\n 'email' => 'santi@correo.com',\n 'password' => bcrypt('12345678'),\n 'address' => 'C/ Ultra',\n 'rol' => 'admin'\n ]);\n //Ratin::factory(50)->create();\n Purchase::factory(20)->create();\n //UserList::factory(1)->create();\n }", "title": "" }, { "docid": "0bdb09d40fb0c72e3ef7686ba61c3b81", "score": "0.6700342", "text": "public function run()\n {\n factory(App\\User::class)->create([\n 'email' => 'crudd@cruddco.com',\n 'name' => 'crudd',\n 'password' => bcrypt('password'),\n ]);\n factory(App\\User::class)->create([\n 'email' => 'user@user.com',\n 'name' => 'user',\n 'password' => bcrypt('password'),\n ]);\n $this->call(ItemsTableSeeder::class);\n }", "title": "" }, { "docid": "654191b89a3f7b4f8f809dd4ca1e2f6d", "score": "0.6693512", "text": "public function run()\n {\n /**\n * Create default user for admin, lecturer and student\n */\n User::create([\n 'name' => 'Admin',\n 'email' => 'admin@e-learning.com',\n 'password' => Hash::make('admin'),\n 'role' => 'admin'\n ]);\n\n User::create([\n 'name' => 'Sample Lecturer',\n 'email' => 'lecturer@e-learning.com',\n 'password' => Hash::make('lecturer'),\n 'role' => 'admin'\n ]);\n\n User::create([\n 'name' => 'Student',\n 'email' => 'student@e-learning.com',\n 'password' => Hash::make('student'),\n 'role' => 'student'\n ]);\n\n /**\n * Create random 300 users with faker and role/password equal \"student\"\n */\n factory(App\\User::class, 300)->create();\n\n // run with php artisan migrate --seed\n }", "title": "" }, { "docid": "e92b39c751271622081fe6a63248f0d3", "score": "0.66905063", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n \n Seo::create([\n 'url' => '/',\n 'title' => 'title default',\n 'keywords' => 'keywords default',\n 'description' => 'description default',\n ]);\n\n User::create([\n 'name' => 'admin',\n 'email' => 'admin@gmail.com',\n 'password' => Hash::make('1234567'),\n ]);\n }", "title": "" }, { "docid": "8de228115e4192b5098d2a339ff99bf2", "score": "0.66811866", "text": "public function run()\n {\n //delete the users table when the seeder is called\n DB::table('users')->delete();\n\n Eloquent::unguard();\n\n\t\t//disable foreign key before we run the seeder\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n factory(App\\User::class, 50)->create();\n\n //Also create these accounts - used for easy testing purposes\n DB::table('users')->insert([\n [\n 'name' => 'Test',\n 'email' => 'test@gmail.com',\n 'password' => bcrypt('secret'),\n 'email_verified_at' => now(),\n 'bio' => 'Sed ut perspiciatis unde omnis iste natus',\n ],\n [\n 'name' => 'Test2',\n 'email' => 'test2@gmail.com',\n 'password' => bcrypt('secret'),\n 'email_verified_at' => now(),\n 'bio' => 'Sed ut perspiciatis unde omnis iste natus',\n\n ],\n ]);\n }", "title": "" }, { "docid": "66f3af8cf527c298b6eac45ccbe6acd5", "score": "0.6679962", "text": "public function run()\n {\n Model::unguard();\n\n DB::table('users')->insert([\n 'first_name' => 'Admin',\n 'last_name' => 'Admin',\n 'password' => bcrypt('secret'),\n 'email' => 'admin@example.com',\n 'address' => 'Lebanon Bierut',\n 'birthday' => '1992-09-12',\n 'type' => 'admin',\n 'created_at' => now()->toDateTimeString(),\n 'updated_at' => now()->toDateTimeString(),\n ]);\n\n DB::table('users')->insert([\n 'first_name' => 'User',\n 'last_name' => 'User',\n 'password' => bcrypt('secret'),\n 'email' => 'user@example.com',\n 'address' => 'Lebanon Bierut',\n 'birthday' => '1992-09-12',\n 'type' => 'user',\n 'created_at' => now()->toDateTimeString(),\n 'updated_at' => now()->toDateTimeString(),\n ]);\n\n // $this->call(\"OthersTableSeeder\");\n }", "title": "" }, { "docid": "75f8fae397ad6cf1e3077c2a32e423ad", "score": "0.6678741", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n User::truncate();\n Category::truncate();\n Product::truncate();\n WarrantyProduct::truncate();\n\n factory(User::class, 200)->create();\n\n factory(Category::class, 10)->create()->each(\n function ($category){\n factory(Product::class, mt_rand(8,15))->create(['category_id' => $category->id])->each(\n function ($product){\n factory(WarrantyProduct::class, mt_rand(2, 3))->create(['product_id' => $product->id]);\n }\n );\n }\n );\n\n }", "title": "" }, { "docid": "023cc4f4f2dcff6a002f8452d783f7ba", "score": "0.66775537", "text": "public function run()\n {\n factory(Category::class, 7)->create();\n factory(Product::class, 25)->create();\n factory(User::class)->create([\n 'email' => 'user@mail.com',\n 'password' => bcrypt('secret'),\n ]);\n }", "title": "" }, { "docid": "9d2abe13b05f99177e4f0e0cdd336b85", "score": "0.6676733", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(Category::class, 10)->create();\n factory(Blog::class, 10)->create();\n }", "title": "" }, { "docid": "f1b3d1bb695e24855d16b3d3ba5bd483", "score": "0.6675029", "text": "public function run()\n {\n if (App::environment() === 'local') {\n $this->call(UsersSeeder::class);\n $this->call(ArticlesSeeder::class);\n $this->call(ParagraphsSeeder::class);\n }\n }", "title": "" }, { "docid": "8898665ff62b548d625911ca4f3fe163", "score": "0.66747075", "text": "public function run()\n\t{\n\t\tModel::unguard();\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n $this->call('UserPermissionTableSeeder');\n $this->call('UserTypeTableSeeder');\n $this->call('PermissionTableSeeder');\n $this->call('UserTableSeeder');\n $this->call('BookCategoryTableSeeder');\n $this->call('BooksTableSeeder');\n $this->call('BookingsTableSeeder');\n DB::statement('SET FOREIGN_KEY_CHECKS = 1');\n\t}", "title": "" }, { "docid": "2de5bf69cdcdfebfdd1e298a8f5e2abd", "score": "0.6669688", "text": "public function setUp(): void\n {\n parent::setUp();\n\n Artisan::call('db:seed');\n\n $this->applicationRoles();\n }", "title": "" }, { "docid": "6418cbfc57c265b541d615ec7c3eb7e2", "score": "0.66647416", "text": "public function run()\n {\n Schema::disableForeignKeyConstraints();\n DB::table('applications')->truncate();\n Schema::enableForeignKeyConstraints();\n\n DB::table('applications')->insert([\n [\n 'name' => 'Ali',\n 'email' => 'ali@gmail.com',\n 'nationality_id' => 194,\n 'phone' => 12345678904,\n ],\n [\n 'name' => 'Ahmed',\n 'email' => 'ahmed@gmail.com',\n 'nationality_id' => 194,\n 'phone' => 15935702552,\n ],\n ]);\n }", "title": "" }, { "docid": "0d7c5d67f7dc1813f9b34f3d249608ba", "score": "0.6662734", "text": "public function run()\n {\n DB::table('users')->truncate();\n factory(User::class)->create(\n [\n \"email\"=>\"dmzhirnov@mail.ru\",\n \"password\"=>Hash::make(App::environment(\"DB_PASSWORD\"))\n ]\n );\n }", "title": "" }, { "docid": "79751b67da244a7913b06f140364d6c0", "score": "0.66617715", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n User::truncate();\n PartCategory::truncate();\n Brand::truncate();\n Manufacturer::truncate();\n PartSubcategory::truncate();\n Part::truncate();\n Admin::truncate();\n\n $usersQuantity = 500;\n $categoriesQuantity = 30;\n $subCategoriesQuantity = 200;\n $partQuantity = 1000;\n $brandQuantity = 20;\n $manufacturerQuantity = 50;\n $adminQuantity = 10;\n\n factory(User::class, $usersQuantity)->create();\n factory(PartCategory::class, $categoriesQuantity)->create();\n factory(Brand::class, $brandQuantity)->create();\n factory(Manufacturer::class, $manufacturerQuantity)->create();\n\n factory(PartSubcategory::class, $subCategoriesQuantity)->create();\n factory(Part::class, $partQuantity)->create();\n\n factory(Admin::class, $adminQuantity)->create();\n\n }", "title": "" }, { "docid": "c4b7fa79d642307c4b4b03bf3dfb4171", "score": "0.6658442", "text": "public function run()\n {\n \t// Seed users table\n $users = array(\n array(\n 'id' => 1,\n 'name' => 'ACP',\n 'email' => 'acp@acp.com',\n 'password' => '$2y$10$qeSkJ/ubMrXtBn1vbGX9Fusf9R9O83.aRu813lbiPMFt4ZynBkDJK',\n 'created_at' => '2017-02-19 00:00:00',\n 'updated_at' => '2017-02-19 00:00:00'\n ),\n array(\n 'id' => 2,\n 'name' => 'Part Company',\n 'email' => 'pc@pc.com',\n 'password' => '$2y$10$qeSkJ/ubMrXtBn1vbGX9Fusf9R9O83.aRu813lbiPMFt4ZynBkDJK',\n 'created_at' => '2017-02-19 00:00:00',\n 'updated_at' => '2017-02-19 00:00:00'\n ),\n array(\n 'id' => 3,\n 'name' => 'Repair Center',\n 'email' => 'rc@rc.com',\n 'password' => '$2y$10$qeSkJ/ubMrXtBn1vbGX9Fusf9R9O83.aRu813lbiPMFt4ZynBkDJK',\n 'created_at' => '2017-02-19 00:00:00',\n 'updated_at' => '2017-02-19 00:00:00'\n ),\n );\n\n DB::table('users')->insert($users);\n }", "title": "" }, { "docid": "46f69bd8530c15627e649eb6fe4bc540", "score": "0.6652935", "text": "public function run()\n {\n Brand::factory(7)->create();\n\n Car::factory(10)->create();\n\n $this->call([\n UserSeeder::class\n ]);\n }", "title": "" }, { "docid": "fef930906e24f0cb81580a301ee2fe76", "score": "0.6651165", "text": "public function run()\n {\n $this->call(RegionTableSeeder::class);\n $this->call(PositionsTableSeesder::class);\n if (env('APP_ENV') == 'local') {\n User::factory(100)->create();\n Player::factory(100)->create();\n PlayerContract::factory(50)->create();\n PlayerHistory::factory(50)->create();\n }\n\n $this->call(ProfileChangesTableSeeder::class);\n\n }", "title": "" }, { "docid": "48b2ba1b715ba9d1796d61bd4c02009b", "score": "0.6643602", "text": "public function run()\n\t{\n\t Eloquent::unguard();\n\t //disable foreign key check for this connection before running seeders\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\t $this->call('GroupSeeder');\n\t $this->call('UserSeeder');\n\t $this->call('UserGroupSeeder');\n\t DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n\t}", "title": "" }, { "docid": "7a118c3cf4531424f74877eed3a6c51b", "score": "0.6641114", "text": "public function run()\n {\n Eloquent::unguard();\n\n // $this->call(UserTableSeeder::class);\n // $this->call(PermissionTableSeeder::class);\n // $this->call('DeportesSeeder');\n // $this->call('NacionalidadesSeeder');\n //$this->call('ComunidadesSeeder');\n //$this->call('DietasSeeder');\n // $this->call('DiteticasSeeder');\n //$this->call('EstudiosSeeder');\n //$this->call('LaboralesSeeder');\n //$this->call('PoblacionesSeeder');\n //$this->call('SexosSeeder');\n //$this->call('dantropometricosSeeder');\n $this->call('SujetosSeeder');\n }", "title": "" }, { "docid": "b7e679da0d0907d4a02b7b49d7e61658", "score": "0.663843", "text": "public function run()\n\t{\n\t\tModel::unguard();\n\n\n $testing = env('TESTING', false);\n\n\n $env = env('APP_ENV');\n\n if ($env == \"local\" && ! $testing )\n {\n $this->call('UsersTableSeeder');\n $this->call('ProductsTableSeeder');\n $this->call('PurchaseTableSeeder');\n $this->call('CartsTableSeeder');\n $this->call('FeedbackTableSeeder');\n $this->call('PayerTableSeeder');\n $this->call('PaymentsTableSeeder');\n $this->call('ContactsTableSeeder');\n $this->call('InventoriesTableSeeder');\n $this->call('IssuesTableSeeder');\n $this->call('RetailersTableSeeder');\n }\n else\n {\n $this->call('UsersTableSeeder');\n $this->call('ProductsTableSeeder');\n $this->call('PurchaseTableSeeder');\n }\n\t}", "title": "" }, { "docid": "62b31b1e734b303ae53c50862d6f35bb", "score": "0.6636086", "text": "public function run()\n {\n\t\t//Do the production seeding\n\t\t$this->call(RolesAndPermissionsSeeder::class);\n $this->call(UserSeeder::class);\t\t\n\t\t$this->call(StatusSeeder::class);\n\t\t$this->call(RatingSeeder::class);\n\t\t$this->call(LanguageSeeder::class);\n\t\t$this->call(ConfigurationSeeder::class);\n }", "title": "" }, { "docid": "6133aad1a6fda48e329108c9e9b287bf", "score": "0.6635598", "text": "public function run() {\n Model::unguard();\n\n /*$this->call(TipoTableSeeder::class);\n $this->call(CiudadTableSeeder::class);\n $this->call(CargoTableSeeder::class);\n $this->call(ResolucionTableSeeder::class);\n $this->call(SucursalTableSeeder::class);\n $this->call(ZonaTableSeeder::class);\n $this->call(SectorTableSeeder::class);\n $this->call(UserTableSeeder::class);\n $this->call(EstadoTableSeeder::class);*/\n factory(\\App\\User::class, 50)->create();\n Model::reguard();\n }", "title": "" }, { "docid": "36b206fe3f9e5582fff99bdd44c268e2", "score": "0.6633201", "text": "public function run()\n {\n DB::table('users')->insert([\n 'name' => 'Edson Chivambo',\n 'email' => 'echivambo@psi.org.mz',\n 'password' => bcrypt('002523'),\n 'provincia_id' => '1',\n 'distrito_id' => '101',\n 'grupo' => '2'\n ]);\n\n\n DB::table('users')->insert([\n 'name' => 'Emidio Nhacudima',\n 'email' => 'enhacudima@psi.org.mz',\n 'password' => bcrypt('Psi12345'),\n 'provincia_id' => '1',\n 'distrito_id' => '101',\n 'grupo' => '2'\n ]);\n/*\n // Let's truncate our existing records to start from scratch.\n Article::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Article::create([\n 'title' => $faker->sentence,\n 'body' => $faker->paragraph,\n ]);\n }\n*/\n }", "title": "" }, { "docid": "87f76891bc6ccaab223abdf90e6fb483", "score": "0.6631892", "text": "public function run()\n\t{\n\t\tEloquent::unguard();\n\n\t\t$this->call('CategoriesTableSeeder');\n\t\t$this->call('ApiRoutesTableSeeder');\n\t\t$this->call('CategoryApiRoutePermsTableSeeder');\n\t\t$this->call('PagesTableSeeder');\n\t\t$this->call('CategoryPagePermsTableSeeder');\n\t\t$this->call('NavigationAppsTableSeeder');\n\t\t$this->call('CategoryNavigationAppPermsTableSeeder');\n\t\t$this->call('UsersTableSeeder');\n\t}", "title": "" }, { "docid": "71aea5d91f1b2a5ac5c499412a27891a", "score": "0.662905", "text": "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n DB::table('users')->truncate();\n DB::table('roles')->truncate();\n DB::table('consults')->truncate();\n DB::table('blogs')->truncate();\n\n\n\n factory(App\\User::class,10)->create();\n factory(App\\Role::class,4)->create();\n factory(App\\Consult::class,10)->create();\n factory(App\\Blog::class,10)->create();\n factory(App\\Category::class,5)->create();\n // $this->call(UsersTableSeeder::class);\n }", "title": "" }, { "docid": "06c64713df067402d6f4cc5fd897315a", "score": "0.662732", "text": "public function run()\n {\n\n $faker=Faker::create();\n DB::table('users')->insert([\n 'name' => 'vane',\n 'email' => 'vane@gmail.com',\n 'password' => bcrypt('admin123'),\n 'estado' => 0,\n ]);\n }", "title": "" }, { "docid": "d508b2ccafb65edba6838636de90e48c", "score": "0.6625841", "text": "public function run()\n {\n $this->truncateTables([\n 'users',\n 'category',\n 'product',\n 'product_by_category',\n 'method_pay',\n 'purchase',\n 'configuration',\n 'product_by_purchase',\n ]);\n\n $this->call(UserSeeder::class);\n $this->call(CategorySeeder::class);\n $this->call(ProductSeeder::class);\n $this->call(ProductByCategorySeeder::class);\n $this->call(MethodPaySeeder::class);\n $this->call(ConfigurationSeeder::class);\n }", "title": "" }, { "docid": "f74cb2c339072d43cd3b96858a89c600", "score": "0.66132194", "text": "public function run()\n {\n $this->seeds();\n }", "title": "" }, { "docid": "76e6405906b15ba30093bb922ab33abb", "score": "0.660394", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $this->call(ContactoTableSeeder::class);\n $this->call(CampanaTableSeeder::class);\n $this->call(OportunidadTableSeeder::class);\n $this->call(TareaTableSeeder::class);\n $this->call(EventoTableSeeder::class);\n factory(App\\User::class, 3)->create();\n }", "title": "" }, { "docid": "aaa824a2f4a47635ea6fafac140c2fb6", "score": "0.6603647", "text": "public function run()\n {\n Model::unguard();\n\n $this->call(\\Database\\Seeders\\CountriesSeeder::class);\n $this->call(\\Database\\Seeders\\RolesSeeder::class);\n $this->call(\\Database\\Seeders\\PermissionsSeeder::class);\n $this->call(\\Database\\Seeders\\UserSeeder::class);\n\n Model::reguard();\n }", "title": "" }, { "docid": "fec3323e6f3a81f6348e08d8097828b8", "score": "0.66010225", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n User::truncate();\n Listing::truncate();\n\n $userQuantity=5;\n $listingQnt=100;\n\n factory(App\\User::class,$userQuantity)->create();\n factory(App\\Listing::class,$listingQnt)->create();\n }", "title": "" }, { "docid": "af875c2a6200779ebdab210792c4b077", "score": "0.65998423", "text": "public function run()\n {\n Model::unguard();\n\n $this->seed('SystemUserSeeder');\n $this->seed('UsersSeeder');\n// $this->seed('MessagesSeeder');\n $this->seed('AddressesSeeder');\n// $this->seed('BrandsSeeder');\n $this->command->info('Start seeding media, this may take a while');\n $this->seed('MediaSeeder');\n $this->seed('RoleSeeder');\n// $this->seed('ActionSeeder');\n// $this->seed('PermissionSeeder');\n $this->seed('PropertySeeder');\n// $this->seed('PropertyDetailSeeder');\n $this->seed('PropertyLogSeeder');\n// $this->seed('AdminAccessSeeder');\n $this->seed('RentalSeeder');\n $this->seed('RentalUserSeeder');\n $this->seed('IssueSeeder');\n $this->seed('IssueDetailSeeder');\n $this->seed('IssueProgressSeeder');\n\n Model::reguard();\n }", "title": "" }, { "docid": "b760c05861b836970b6512f530638768", "score": "0.6599796", "text": "public function run()\n {\n factory(User::class, 1)->create();\n User::create([\n 'email' => \"korkutk@gmail.com\",\n 'name' => \"Korkut Sarıçayır\",\n 'password' => Hash::make(\"12345\")\n ]);\n // $this->call(UserSeeder::class);\n $this->call(CategoriesTableSeeder::class);\n $this->call(QuestionsTableSeeder::class);\n }", "title": "" }, { "docid": "d6b874deb919f9f1bbe5a7f4208f3bf1", "score": "0.65986806", "text": "public function run()\n\t{\n\t\tEloquent::unguard();\n\n\t\t// $this->call('UserTableSeeder');\n\t\t$this->call('ColorTableSeeder');\n\t\t$this->call('BrandTableSeeder');\n\t\t$this->call('GenreTableSeeder');\n\t\t$this->call('AttributeTableSeeder');\n\t\t$this->call('SizeTableSeeder');\n\t\t$this->call('UsertypeTableSeeder');\n\t\t$this->call('DepartmentTableSeeder');\n\t\t$this->call('ProvinceTableSeeder');\n\t\t$this->call('DistrictTableSeeder');\n\t\t$this->call('ProductTableSeeder');\n\t\t$this->call('ProductattributeTableSeeder');\n\t\t$this->call('ProductstockTableSeeder');\n\t\t$this->call('UserTableSeeder');\n\t}", "title": "" }, { "docid": "064da3a1fd5b172768671dc5b6f1169d", "score": "0.659838", "text": "public function run()\n {\n\n\n\n Storage::deleteDirectory('eventos');\n\n Storage::makeDirectory('eventos');\n\n $this->call(RoleSeeder::class);\n\n $this->call(UserSeeder::class);\n \n Categoria::factory(4)->create();\n \n $this->call(EventoSeeder::class);\n\n $this->call(AporteSeeder::class);\n\n $this->call(ObjetoSeeder::class);\n\n }", "title": "" }, { "docid": "22576d435a47e89700c7a06ad724aa74", "score": "0.6597602", "text": "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n\n DB::table('users')->truncate();\n\n $faker = \\Faker\\Factory::create();\n $date = \\Carbon\\Carbon::now();\n\n\n DB::table('users')->insert([\n [\n 'name' => 'Don Joe',\n 'email' => 'don@test.com',\n 'password' => bcrypt('12345'),\n 'created_at' => $date,\n 'updated_at' => $date\n ],\n [\n 'name' => 'Abebe',\n 'email' => 'abebe@test.com',\n 'password' => bcrypt('12345'),\n 'created_at' => $date,\n 'updated_at' => $date\n ],\n [\n 'name' => 'Kebede',\n 'email' => 'kebede@test.com',\n 'password' => bcrypt('12345'),\n 'created_at' => $date,\n 'updated_at' => $date\n ],\n\n ]);\n }", "title": "" }, { "docid": "99aa21f81e41705167b3506dd8e4701a", "score": "0.6595813", "text": "public function run()\n\t{\n\t\tEloquent::unguard();\n\n\t\t$this->call('BancoTableSeeder');\n\t\t$this->call('DepartamentoTableSeeder');\n\t\t$this->call('MarcasTableSeeder');\n\t\t$this->call('ModeloTableSeeder');\n\t\t$this->call('PublicidadTableSeeder');\n\t\t$this->call('SubCategoriaTableSeeder');\n\t\t$this->call('TextosTableSeeder');\n\t\t$this->call('UsuarioTableSeeder');\n\t}", "title": "" }, { "docid": "f06133192b123dabdf8bc82d649d977b", "score": "0.6594522", "text": "public function run()\n\t{\n\t\tEloquent::unguard();\n\n\t\t$this->call('ModuleTableSeeder');\n\t\t$this->call('ProfileTableSeeder');\n\t\t$this->call('PaymentoptionTableSeeder');\n\t\t$this->call('MedicalinsuranceTableSeeder');\n\t\t$this->call('MedicalinsuranceplanTableSeeder');\n\t\t$this->call('MeasurementunitTableSeeder');\n\t\t$this->call('CategoryTableSeeder');\n\t\t$this->call('ProviderTableSeeder');\n\t\t$this->call('ItemTableSeeder');\n\t\t$this->call('ClientTableSeeder');\n\t\t$this->call('DoctorTableSeeder');\t\t\n\t\t$this->call('UserTableSeeder');\n\t\t$this->call('PermissionTableSeeder');\n\t\t\n\t}", "title": "" }, { "docid": "bb532a44b2c43b37546f9b6c6a21dd56", "score": "0.6592321", "text": "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n // deshabilita chequeo foreign keys\n\n // Data nuestra\n $this->call(CategoriesTableSeeder::class);\n $this->call(LocationsTableSeeder::class);\n\n // Dummy data\n $this->call(UsersTableSeeder::class);\n $this->call(ProductsTableSeeder::class);\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1');\n }", "title": "" }, { "docid": "1d8fff7ad3fbb9f72b72a95f1eb0162d", "score": "0.65911674", "text": "public function run()\n {\n DB::transaction(function () {\n $this->call(RolesTableSeeder::class);\n $this->call(SettingsTableSeeder::class);\n\n // Only run the seeders registered here when we are in production,\n // otherwise keep it clean or it would somehow intefer with the\n // tests scenario preparation since data is stored in database.\n if (! App::environment('testing')) {\n $this->call(UsersTableSeeder::class);\n }\n });\n }", "title": "" }, { "docid": "d551c1c439a8fe92711ff8e73c21586d", "score": "0.6591141", "text": "public function run()\n {\n DB::table('users')->delete();\n\n factory(App\\User::class)->create(['email' => 'admin@test.com', 'role_id' => 2]);\n factory(App\\User::class)->create(['email' => 'stanko@test.com']);\n }", "title": "" }, { "docid": "51daed999a883c3842fb92fb9bf4889b", "score": "0.6590682", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory('App\\User'::class, 20)->create();\n factory('App\\Post'::class, 1000)->create();\n factory('App\\Comment'::class, 2000)->create();\n }", "title": "" }, { "docid": "173657757580aa09007e371cbcd96672", "score": "0.65885556", "text": "public function run()\n {\n DB::raw(\"drop database \" . env(\"DB_DATABASE\"));\n\t\tDB::raw(\"create database \" . env(\"DB_DATABASE\"));\n DB::raw(\"use \" . env(\"DB_DATABASE\"));\n\t\tDB::raw(\"create table companies (id int auto_increment, primary key(id))\");\n\n\t\t$this->command->call(\"migrate:fresh\");\n $this->call(Permission::class);\n\n\t\t// ----------------------------------------------------------------------------------\n $info = [\n\n 'user' => 'admin',\n 'password' => bcrypt('admin'),\n 'email' => 'admin@example.com',\n\n 'gender' => 1,\n 'fname' => 'Admin',\n 'lname' => 'Admin',\n 'mname' => 'Admin',\n 'age' => 99,\n 'image' => [\n 'data' => '/img/landing/avatar_anonymous.png',\n 'path' => '/img/landing/avatar_anonymous.png',\n ],\n 'birthdate' => '2019-06-15',\n\n 'mobile' => '',\n 'address' => '',\n\n // positions\n 'title' => 'Administrator',\n 'state' => 2,\n 'lim' => 1,\n 'description' => '',\n\n ];\n // ------------------------------------------------------------------------------------\n UsersTableSeeder::create((object)$info);\n }", "title": "" }, { "docid": "9082e11a465e769670c1725591626664", "score": "0.6584304", "text": "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n $this->call(OrderStatusSeeder::class);\n $this->call(RoleSeeder::class);\n\n if (config('app.env') == 'production') {\n return;\n }\n\n $this->call(UserSeeder::class);\n $this->call(OrderSeeder::class);\n $this->call(ColorSeeder::class);\n $this->call(MaterialSeeder::class);\n $this->call(GuaranteeSeeder::class);\n $this->call(ProductSeeder::class);\n $this->call(OrderProductSeeder::class);\n $this->call(UserRoleSeeder::class);\n $this->call(CategoryGroupSeeder::class);\n $this->call(CategorySeeder::class);\n $this->call(CategoryProductSeeder::class);\n $this->call(ProductTranslationSeeder::class);\n $this->call(OrderStatusTranslationSeeder::class);\n $this->call(ColorTranslationSeeder::class);\n $this->call(MaterialTranslationSeeder::class);\n $this->call(GuaranteeTranslationSeeder::class);\n $this->call(RoleTranslationSeeder::class);\n $this->call(CategoryGroupTranslationSeeder::class);\n $this->call(CategoryTranslationSeeder::class);\n }", "title": "" }, { "docid": "c5c9952cbe5630e03a63401e5ceb4a3b", "score": "0.6582231", "text": "public function run()\n {\n Model::unguard();\n\n // $this->call(\"OthersTableSeeder\");\n\n User::create([\n \"name\" => \"Mr. Super Admin\",\n \"username\" => \"superadmin\",\n \"phone\" => \"+880 1XXX XXXXXX\",\n \"email\" => \"superadmin@example.com\",\n \"password\" => bcrypt(\"password\"),\n \"email_verified_at\" => Carbon::now(),\n \"approved_at\" => Carbon::now(),\n \"approved_by\" => 1,\n ]);\n }", "title": "" }, { "docid": "b6066308d0ac655bb5d5825a458ef8b1", "score": "0.6580703", "text": "public function run()\n {\n $this->call(RolesTableSeeder::class);\n $this->call(LangauageTableSeeder::class);\n $this->call(CountryTableSeeder::class);\n\n \n\n Country::create([\n 'name' => 'India'\n ]);\n\n Country::create([\n 'name' => 'USA'\n ]);\n\n Country::create([\n 'name' => 'UK'\n ]);\n\n CompanyCateogry::updateOrCreate([\n 'name' => 'category1'\n ]);\n\n factory(App\\Models\\Customer::class, 50)->create();\n factory(App\\Models\\Supplier::class, 50)->create();\n // $this->call(CompanySeeder::class);\n $this->call(InvoiceSeeder::class);\n $this->call(CashFlowSeeder::class);\n }", "title": "" }, { "docid": "f4b6ce75a7244bc20e12268f7c279ced", "score": "0.65786093", "text": "public function run()\n {\n $this->emptyTable('users');\n $this->emptyTable('role_users');\n\n User::create([\n 'id' => 1,\n 'email' => 'admin',\n 'password' => bcrypt('777')\n ])->assignRole(['admin']);\n\n\n\n }", "title": "" }, { "docid": "b373718e9c234dc4bb756553db264c76", "score": "0.65783596", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call([\n RolesTableSeeder::class,\n UsersTableSeeder::class,\n PagesTableSeeder::class\n ]);\n\n \n \\Illuminate\\Support\\Facades\\DB::table('tbl_introductions')->insert([ \n 'fullname' => 'Ben Wilson',\n 'dob' => '26 September 1999',\n 'email' => 'hello@company.co',\n 'intro' => 'Hello, I am Ben.',\n 'image' => '1606288979.jpg', \n 'website' => 'www.company.co',\n 'created_at' => '2020-11-24 06:03:28' \n ]);\n }", "title": "" }, { "docid": "e2cc38097f2423f76fdc46e391bb1c54", "score": "0.6575944", "text": "public function run()\n\t{\n\t\tEloquent::unguard();\n\t\t\n\t\t\n\t\t$this->call('UsersTableSeeder');\n\t\t$this->call('RolesTableSeeder');\n\t\t$this->call('PermissionsTableSeeder');\n\t\t$this->call('PostsTableSeeder');\n\t\t$this->call('CommentsTableSeeder');\n $this->call('CitiesTableSeeder');\n $this->call('PositionsTableSeeder');\n $this->call('AgenciesTableSeeder');\n $this->call('CustomersTableSeeder');\n $this->call('StaffsTableSeeder');\n// $this->call('ContactsTableSeeder');\n// $this->call('MaterialTypesTableSeeder');\n// $this->call('ContractMaterialsTableSeeder');\n// $this->call('ServicePackagesTableSeeder');\n// $this->call('ContractServicesTableSeeder');\n\t}", "title": "" }, { "docid": "aabb76547ef2b688c1e2f12dc1fa99b3", "score": "0.6573559", "text": "public function run()\n {\n // $this->call(UserSeeder::class);\n $this->call(UserTableSeeder::class);\n $this->call(CarTableSeeder::class);\n $this->call(PhotoTableSeeder::class);\n $this->call(MessageTableSeeder::class);\n // $this->call(settingsTableSeeder::class);\n DB::unprepared(\\File::get(base_path('database/seeds/settings.sql')));\n }", "title": "" }, { "docid": "8ee0fb32134287d3f61b1f65a4d134aa", "score": "0.65712684", "text": "public function run()\n\t{\n\t\tEloquent::unguard();\n\n\t\t// $this->call('UserTableSeeder');\n\t\t$this->call('RolesTableSeeder');\n\t\t$this->call('OrganizationsTableSeeder');\n\t\t$this->call('UsersTableSeeder');\n\t\t$this->call('OffersTableSeeder');\n\t\t$this->call('RoomsTableSeeder');\n\t\t$this->call('Booking_enginesTableSeeder');\n\t\t$this->call('Booking_engine_settingsTableSeeder');\n\t\t$this->call('Booking_engine_detailsTableSeeder');\n\t\t$this->call('Email_templatesTableSeeder');\n\t\t$this->call('Email_addressesTableSeeder');\n\t\t$this->call('Email_settingsTableSeeder');\n\t\t$this->call('OutboxesTableSeeder');\n\t\t$this->call('EnquiriesTableSeeder');\n\t}", "title": "" }, { "docid": "2945b90f332225c457ee574c6b17f7a9", "score": "0.657074", "text": "public function run()\n {\n User::factory()->create([\n 'name' => 'test1',\n 'email' => 'test1@test.jp',\n 'password' => bcrypt('testtest')\n ]);\n DB::table('users')->insert([\n 'name' => 'test2',\n 'email' => 'test2@test.jp',\n 'password' => Hash::make('password')\n ]);\n User::factory()->count(3)->create();\n }", "title": "" }, { "docid": "619052f772df3123092cd36fec9bcb53", "score": "0.6569899", "text": "public function run()\n\t{\n\t\tEloquent::unguard();\n\n\t\t$this->call('BranchTableSeeder');\t\t\n\t\t$this->call('CountryTableSeeder');\n\t\t$this->call('EstateTableSeeder');\n\t\t$this->call('CityTableSeeder');\n\t\t$this->call('CategoryTableSeeder');\n\t\t$this->call('PortalTableSeeder');\n\t\t$this->call('ServiceTableSeeder');\n\t\t$this->call('UserTableSeeder');\n\t}", "title": "" }, { "docid": "0d5fe03effcc4b726a57bc1fcb86f579", "score": "0.6566966", "text": "protected function setUpDatabase()\n {\n file_put_contents(__DIR__.'/database.sqlite', null);\n $this->app['db']->connection()->getSchemaBuilder()->create(\n 'images',\n function (Blueprint $table) {\n $table->increments('id');\n $table->string('name');\n $table->string('file')->nullable();\n }\n );\n }", "title": "" }, { "docid": "043d4df9d0c3315152a405e4dc38d21e", "score": "0.6564943", "text": "public function run()\n {\n User::factory(1)->create([\n \"name\" =>\"Marco Perafan\",\n \"email\" => \"marcoperafan@gmail.com\",\n \"password\" => bcrypt(\"12345678\")\n ]);\n User::factory(5)->create();\n Project ::factory(40)->create();\n }", "title": "" }, { "docid": "cb82535661f0d802a53b4cf225bc52fb", "score": "0.6564261", "text": "public function seed()\n {\n # `id` is omitted as that's created automatically\n $past_game = [\n 'user_move' => 'rock',\n 'computer_move' => 'scissors',\n 'result' => 'user',\n 'date_time' => '2019-12-10 00:00:01',\n ];\n\n # Insert game\n $this->app->db()->insert('past_games', $past_game);\n }", "title": "" }, { "docid": "ff8d8c6f4142013c1f3fe007aba6e9b3", "score": "0.65636605", "text": "public function run()\n {\n\n // Disable mass assignment and foreign key protection.\n Model::unguard();\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n // Production Seeders\n $this->call(RoleSeeder::class);\n $this->call(OwnerSeeder::class);\n $this->call(CategorySeeder::class);\n\n // Development Seeders and Factories.\n if (env('APP_ENV') == 'local') {\n\n }\n\n // Enable mass assignment and foreign key protection.\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n Model::reguard();\n\n }", "title": "" }, { "docid": "aeeff8765ea15c52decff1b3e9c28ced", "score": "0.65630335", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(User::class, 50)->create();\n factory(Profile::class, 50)->create();\n }", "title": "" }, { "docid": "60e4a950a73942710b48196aeb83411f", "score": "0.6558562", "text": "public function run()\n\t{\n\t\tEloquent::unguard();\n\t\t$this->call('SpecialismsTableSeeder');\n\t\t$this->call('PatientsTableSeeder');\n\t\t$this->call('DoctorsTableSeeder');\n\t\t$this->call('RolesTableSeeder');\n\t\t$this->call('UsersTableSeeder');\n\t\t$this->call('AppointmentsTableSeeder');\n\t\t$this->call('DiagnosisTableSeeder');\n\t}", "title": "" }, { "docid": "c3fe468a1f0fed27af15187c713682a3", "score": "0.6557152", "text": "public function run()\n {\n Model::unguard();\n\n $this->call(UserTableSeeder::class);\n $this->call('integrantesSeeder');\n $this->call('realizadoresSeeder');\n $this->call('sedesSeeder');\n $this->call('festivalesSeeder');\n $this->call('PatrocinadoresSeeder');\n $this->call('programasSeeder');\n\n\n $this->call('PeliculasSeeder');\n $this->call('traficoSeeder');\n $this->call('FuncionesSeeder');\n\n\n $this->call('funcion_peliculaSeeder');\n $this->call('Pelicula_TraficoSeeder');\n $this->call('Funcion_Patrocinador');\n\n\n $this->call(CaracteristicasSeeder::class);\n\n $this->call('PaquetesSeeder');\n $this->call('Caracteristicas_PaquetesSeeder');\n\n $this->call('Patrocinador_Programa');\n $this->call('Festival_Programa');\n\n\n $this->call('RoleSeeder');\n $this->call('PermissionSeeder');\n\n\n\n\n\n\n\n\n\n Model::reguard();\n }", "title": "" }, { "docid": "5dd9ce7040dcb4fd643e4e622302d41c", "score": "0.6555137", "text": "public function run()\n {\n Eloquent::unguard();\n\n DB::unprepared(file_get_contents(database_path() . '/seeds/states.sql'));\n $this->command->info('States table seeded!');\n\n DB::unprepared(file_get_contents(database_path() . '/seeds/cities.sql'));\n $this->command->info('Cities table seeded!');\n $this->call(UsersTableSeeder::class);\n // $this->call(ProductTypesTableSeeder::class);\n }", "title": "" }, { "docid": "c62faae40f3c210e0c8e86d0bba29360", "score": "0.6549435", "text": "public function run()\n {\n $this->truncateTables([\n app(MortgageApplication::class)->getTable(),\n app(MortgageExpert::class)->getTable(),\n ]);\n\n $this->call([\n MortgageApplicationSeeder::class,\n MortgageExpertSeeder::class,\n ]);\n // \\App\\Models\\User::factory(10)->create();\n }", "title": "" }, { "docid": "3672e10c02ad5c5e4ae83cda9550c65a", "score": "0.65447843", "text": "public function run()\n {\n DB::table('users')->insert([\n 'name' => env('SEEDER_USER_NAME'),\n 'email' => env('SEEDER_USER_EMAIL'),\n 'password' => Hash::make(env('SEEDER_USER_PASSWORD')),\n 'remember_token' => str_random(10),\n ]);\n }", "title": "" }, { "docid": "9a3fc5f60166a9785c73750188e6596d", "score": "0.65440166", "text": "public function run()\n {\n // $this->call(UserTableSeeder::class);\n /*\n DB::table('product')->insert([\n 'title' => 'Ceci est un titre de produit',\n 'description' => 'lorem ipsum',\n 'price' => 12,\n 'brand' => 'nouvelle marque',\n ]);\n */\n factory(App\\Product::class, 2)->create();\n factory(App\\Categorie::class, 2)->create();\n }", "title": "" }, { "docid": "1d06d70d24d739f49b23a59bbdffc9aa", "score": "0.6544012", "text": "public function run()\n\t{\n\t\tEloquent::unguard();\n\n\t\t$this->call('UserTableSeeder');\n\t\t$this->call('CategoriesTableSeeder');\n\t\t$this->call('RconnectorsTableSeeder');\n\t\t$this->call('ProductsTableSeeder');\n\t\t$this->call('RoomTableSeeder');\n\t\t$this->call('MerchantlinkTableSeeder');\n\t}", "title": "" }, { "docid": "b8079257b1c1e6d4540e7aa5f97fd304", "score": "0.6543574", "text": "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n $this->call(CorporacionSeeder::class);\n $this->call(CiudadprocesoSeeder::class);\n $this->call(EstadoSeeder::class);\n $this->call(PonenteSeeder::class);\n $this->call(TipodocumentoidentificacionSeeder::class); \n $this->call(FondodepensionSeeder::class); \n $this->call(TipocontratoSeeder::class); \n $this->call(EpsSeeder::class); \n $this->call(DepartamentoSeeder::class);\n $this->call(MunicipioSeeder::class);\n $this->call(FuerzaCarreraGradoSeeder::class); \n $this->call(TipodocumentoSeeder::class);\n $this->call(TipodemandaSeeder::class);\n $this->call(RolesSeeder::class);\n $this->call(UsersSeeder::class);\n $this->call(ConsultacorreoTipoSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n \n }", "title": "" }, { "docid": "d8a7cf68c43a84b933de2a3bcb9d656b", "score": "0.6541039", "text": "public function run()\n {\n $faker = Faker\\Factory::create();\n $users = [\n [\n 'name' => 'Admin',\n 'email' => '​admin@grtech.com.my',\n 'password' => bcrypt('password'),\n 'role' => 'admin'\n ],\n [\n 'name' => 'User1',\n 'email' => 'user@grtech.com.my',\n 'password' => bcrypt('password'),\n 'role' => 'employee'\n ],\n ];\n User::insert($users);\n }", "title": "" }, { "docid": "4b5fd8f4aaae6491c5c75806cba8f6c7", "score": "0.65391845", "text": "private function migrate(): void\n {\n if (TestCase::$migratedDatabase === true) {\n return;\n }\n\n $this->afterApplicationCreated(function() {\n $this->artisan('migrate:fresh', ['--seed' => true]);\n });\n\n TestCase::$migratedDatabase = true;\n }", "title": "" }, { "docid": "b762d028067463470324860cc9a29e0e", "score": "0.65377814", "text": "public function run(): void\n {\n $this->seedUsers();\n $this->seedCategories();\n $this->seedMedia();\n $this->seedProducts();\n $this->seedOrders();\n }", "title": "" } ]
c9a3292fb718c69f01dba200a60e9ade
Returns the test dataset.
[ { "docid": "6f0520ba1b6e204c88ccd84b280ddaaa", "score": "0.6099677", "text": "protected function getDataSet()\n\t{\n\t\treturn new Shop_DbUnit_ArrayDataSet(array(\n\t\t\t'xe_shop_categories' => array(\n\t\t\t\tarray('category_srl' => 1000, 'module_srl' => 1001, 'title' => 'Dummy category 1000', 'parent_srl' => 0, 'filename' => 'files/attach/picture.jpg'),\n\t\t\t\tarray('category_srl' => 1002, 'module_srl' => 1001, 'title' => 'Dummy category 1002', 'parent_srl' => 1000),\n\t\t\t\tarray('category_srl' => 1004, 'module_srl' => 1003, 'title' => 'Dummy category 1004', 'parent_srl' => 0),\n\t\t\t\tarray('category_srl' => 1006, 'module_srl' => 1001, 'title' => 'Dummy category 1006', 'parent_srl' => 0),\n\t\t\t\tarray('category_srl' => 1008, 'module_srl' => 1001, 'title' => 'Dummy category 1008', 'parent_srl' => 1000),\n array('category_srl' => 1010, 'module_srl' => 1004, 'title' => 'Dummy category 1010', 'parent_srl' => 2)\n\t\t\t),\n\t\t\t'xe_shop_products' => array(),\n\t\t\t'xe_shop_product_categories' => array()\n\t\t));\n\t}", "title": "" } ]
[ { "docid": "498b5f50b32c968f6df98ded31ed8d21", "score": "0.8083949", "text": "protected function getDataSet()\n {\n $testCase = $this->getName();\n $testFile = str_replace('.php', \"_$testCase.yml\", __FILE__);\n if (file_exists($testFile)) {\n return $this->loadRelativeYaml($testFile);\n }\n\n //Dataset className.yml has the minimal data we need to perform our tests\n $classFile = str_replace('.php', '.yml', __FILE__);\n return $this->loadRelativeYaml($classFile);\n }", "title": "" }, { "docid": "c52e6f31cebfec51f4919479d43b4c2a", "score": "0.77636164", "text": "protected function getDataSet()\n {\n return new \\PHPUnit_Extensions_Database_DataSet_YamlDataSet(dirname(__FILE__).'/fixtures.yml');\n }", "title": "" }, { "docid": "21b84192873200d33bf0dabfc49bb629", "score": "0.7760479", "text": "protected function getDataSet() {\n\t\treturn $this->createFlatXMLDataSet(__DIR__ . '/WebsiteRepositoryTest.xml');\n\t}", "title": "" }, { "docid": "bf4ef7030bc1082bf3206f6bee70e640", "score": "0.765684", "text": "protected function getTestData()\n {\n if (!$this->_testData) {\n $this->_loadTestData();\n }\n return $this->_testData;\n }", "title": "" }, { "docid": "725acf2d2e527896706f915286dccc43", "score": "0.76564926", "text": "protected function getDataSet()\n {\n return new \\PHPUnit_Extensions_Database_DataSet_YamlDataSet(__DIR__ . '/DataSet/base.yml');\n }", "title": "" }, { "docid": "04e66ab1a33e5823cb08f0f836f0d556", "score": "0.739908", "text": "protected function getDataSet()\n {\n return new PHPUnit_Extensions_Database_DataSet_YamlDataSet(\n __DIR__.'/fixtures/log_history.yml'\n );\n }", "title": "" }, { "docid": "47cd1eaa28fd2092f20b8be3479c17c0", "score": "0.73990697", "text": "protected function getDataSet()\n {//{{{\n $result = new \\PHPUnit_Extensions_Database_DataSet_CompositeDataSet(array());\n if ($this->sampleData) {\n $dataSet = $this->createArrayDataSet($this->sampleData);\n $result->addDataSet($dataSet);\n }\n if ($this->sampleCsv) {\n $dataSet = $this->createCsvDataSet($this->sampleCsv);\n $result->addDataSet($dataSet);\n }\n return $result;\n }", "title": "" }, { "docid": "ef090700dc385a20299dae1a7f2f33a9", "score": "0.73000264", "text": "public static function get_dataset()\r\n {\r\n $ds = new Datasets();\r\n return $ds->get_by_type(self::DATASET_TYPE);\r\n }", "title": "" }, { "docid": "46710735af9126488ddff6f609fd2334", "score": "0.7257083", "text": "protected function getDataSet()\n {\n $classFile = str_replace('.php', '.yml', __FILE__);\n return new \\PHPUnit_Extensions_Database_DataSet_YamlDataSet(\n $classFile\n );\n }", "title": "" }, { "docid": "25d2d215beaf4202de3aa8d76cb4d5c7", "score": "0.7197153", "text": "public function getDataSet()\n\t{\n\t\treturn $this->createXMLDataSet(dirname(__FILE__) . '/fixtures/users.xml');\n\t}", "title": "" }, { "docid": "d0c15394358665f3065834487109c108", "score": "0.71935505", "text": "public function getDataSet()\n {\n return $this->dataSet;\n }", "title": "" }, { "docid": "40150773392e3a7855d16cd957cd34b8", "score": "0.70941174", "text": "public function getDataset()\n {\n return $this->dataset;\n }", "title": "" }, { "docid": "9b39663b492de56e5e793d6b4adcf8a5", "score": "0.708168", "text": "public function dataTestRun() {\n\n $originalDataset = (object) ['title' => \"Hello\"];\n\n return [\n [$originalDataset],\n ];\n\n }", "title": "" }, { "docid": "194e3ccecbead38a653504b8a2b259d2", "score": "0.70743436", "text": "protected function getDataSet()\n {\n return $this->createFlatXmlDataSet(__DIR__ . '/../../data/rdbms/dataset.xml');\n }", "title": "" }, { "docid": "d3c08c63827404ae19f3503d1f1a89ac", "score": "0.7059104", "text": "protected function getDataSet()\n {\n return $this->createFlatXMLDataSet(__DIR__ . '/../../../doctrine/truncateDataTables.xml');\n // Use below to return an empty data set if we don't want to truncate and seed\n //return new PHPUnit_Extensions_Database_DataSet_DefaultDataSet();\n }", "title": "" }, { "docid": "03a683c6ac9e183941249b7019e6314c", "score": "0.70068055", "text": "protected function getDataSet() {\n\t\treturn $this->createXMLDataSet ( dirname ( __FILE__ ) . '\\..\\..\\data\\cron\\1_DS_1_article_test_1_new_attach_1_new_inval_DS_data.xml' );\n\t}", "title": "" }, { "docid": "6cce1ce46b04ab647bc344f428f84e2a", "score": "0.69915557", "text": "protected function getDataSet()\n {\n return $this->createMySQLXMLDataSet(__DIR__.'/../dump.xml');\n }", "title": "" }, { "docid": "ae619ebc9951350e8f97bcce89c53d93", "score": "0.6978692", "text": "protected function getDataSet()\n\t{\n\t\t$dataSet = new PHPUnit_Extensions_Database_DataSet_CsvDataSet(',', \"'\", '\\\\');\n\n\t\t$dataSet->addTable('jos_dbtest_composite', __DIR__ . '/stubs/jos_dbtest_composite.csv');\n\t\t$dataSet->addTable('jos_assets', __DIR__ . '/stubs/jos_assets_composite.csv');\n\t\t$dataSet->addTable('jos_session', __DIR__ . '/stubs/jos_session.csv');\n\n\t\treturn $dataSet;\n\t}", "title": "" }, { "docid": "0c27a8cb1373e55d9c5dc83a62e13c85", "score": "0.6970143", "text": "protected function getDataSet()\n {\n if (self::$dataset === null) {\n $yamlFixturesFile = __DIR__ . $GLOBALS['YAML_FILE'];\n if (!file_exists($yamlFixturesFile)) {\n throw new \\Exception(\"THe path to yaml fixtures file is wrong.\");\n }\n self::$dataset = new \\PHPUnit_Extensions_Database_DataSet_YamlDataSet($yamlFixturesFile);\n }\n\n return self::$dataset;\n }", "title": "" }, { "docid": "b3280f5f106893d63070da113ad10bc6", "score": "0.6964949", "text": "public function getTestSet()\n {\n return $this->test_set;\n }", "title": "" }, { "docid": "e50f46b1db74ec8b699936cce7a620d0", "score": "0.68581647", "text": "protected function getDataSet()\n\t{\n\t\t$dataSet = new PHPUnit_Extensions_Database_DataSet_CsvDataSet(',', \"'\", '\\\\');\n\n\t\t$dataSet->addTable('jos_extensions', JPATH_TEST_DATABASE . '/jos_extensions.csv');\n\t\t$dataSet->addTable('jos_modules', JPATH_TEST_DATABASE . '/jos_modules.csv');\n\t\t$dataSet->addTable('jos_modules_menu', JPATH_TEST_DATABASE . '/jos_modules_menu.csv');\n\n\t\treturn $dataSet;\n\t}", "title": "" }, { "docid": "8ea0802baf2729164fa950acc3d750c7", "score": "0.6698074", "text": "public function getDataSet()\n {\n $seedFilePath = __DIR__ . '/databaseXml/seedApplications.xml';\n return $this->createXMLDataSet($seedFilePath);\n }", "title": "" }, { "docid": "9166b38d1b74b7c85ceeb0d3035f4fea", "score": "0.6696315", "text": "public function getDataSet()\n {\n $seedFilePath = __DIR__ . '/databaseXml/seedResume.xml';\n return $this->createXMLDataSet($seedFilePath);\n }", "title": "" }, { "docid": "56e34bdc7c8783bf7e2027854d661a5a", "score": "0.6680784", "text": "protected function getDataSet()\n\t{\n\t\t$dataSet = new PHPUnit_Extensions_Database_DataSet_CsvDataSet(',', \"'\", '\\\\');\n\n\t\t$dataSet->addTable('jos_extensions', JPATH_TEST_DATABASE . '/jos_extensions.csv');\n\n\t\treturn $dataSet;\n\t}", "title": "" }, { "docid": "f4629ad0e4d7bfea946f33a49e8736b4", "score": "0.666232", "text": "protected function getDataSet()\n {\n $path = app()->getPath().'/database/dataset/'.$this->connection;\n\n if (!file_exists($path) && !empty($this->connection)) {\n $path = dirname($path);\n }\n\n $composite = new PHPUnit_Extensions_Database_DataSet_CompositeDataSet();\n\n foreach (glob($path.'/*') as $file) {\n $dataSet = load($file);\n if (empty($dataSet)) {\n $dataSet = [];\n }\n $tableName = pathinfo($file, PATHINFO_FILENAME);\n $composite->addDataSet(\n new PHPUnit_Extensions_Database_DataSet_ArrayDataSet(\n [\n $tableName => $dataSet,\n ]\n )\n );\n }\n\n return $composite;\n }", "title": "" }, { "docid": "ad2c97f9222ccaf9beb977c6fefe03c8", "score": "0.66368777", "text": "protected function getDataSet()\n {\n return $this->createArrayDataSet([\n 'heroes' => [],\n 'teams' => [],\n ]);\n }", "title": "" }, { "docid": "930015d472951e305791b589b838bbb5", "score": "0.663571", "text": "protected function getDataSet()\n {\n }", "title": "" }, { "docid": "b6196db6303031938cd37528f100a532", "score": "0.66253334", "text": "function getDataSet() {\n\t\treturn $this->addDataSets(array(\"init.yml\", \"users_and_roles.yml\",\n\t\t\t\"page.yml\", \"page_definition.yml\", \"page_definition_hints.yml\"));\n\t}", "title": "" }, { "docid": "fe8c0268ee5a8c038220a814222804b0", "score": "0.6619884", "text": "public function getDataSet()\n {\n $originalXml = dirname(__FILE__).'/Flats/all-original-data.xml';\n return $this->createFlatXMLDataSet($originalXml);\n }", "title": "" }, { "docid": "fe8c0268ee5a8c038220a814222804b0", "score": "0.6619884", "text": "public function getDataSet()\n {\n $originalXml = dirname(__FILE__).'/Flats/all-original-data.xml';\n return $this->createFlatXMLDataSet($originalXml);\n }", "title": "" }, { "docid": "8898d63a8d3b6ba109243c0ac08a407d", "score": "0.65951055", "text": "public function provideTestData()\n {\n $data = $this->getTestData();\n $testData = array();\n\n foreach ($data as $key => $value) {\n $testData[] = array($key, $value);\n }\n\n return $testData;\n }", "title": "" }, { "docid": "748a773688215a9a20d1c54fecf1a0da", "score": "0.65609336", "text": "protected function getDataSet()\n {\n return new ArrayDataSet( array() );\n }", "title": "" }, { "docid": "fa7ef9260237a82ccf5c059cffea8dac", "score": "0.64801776", "text": "protected function getTestData()\n {\n return [\n 'foo' => ['doc_count' => 1],\n 'bar' => ['doc_count' => 2],\n ];\n }", "title": "" }, { "docid": "2286739e2615b5a8b3b32c2db131800c", "score": "0.63738966", "text": "protected function getDataSet() {\n \t$dataSet = new PHPUnit_Extensions_Database_DataSet_CsvDataSet(';','\"','\\\\');\n \t$dataSet->addTable(TB_VPS_CUSTOMER, FIXTURE_PATH.'vps_customer.csv');\n \t$dataSet->addTable(TB_VPS_CUSTOMER_LIMIT, FIXTURE_PATH.'vps_customer_limit.csv');\n \t$dataSet->addTable(TB_COMPANY, FIXTURE_PATH.'company.csv');\n \t$dataSet->addTable(TB_VPS_BILLING, FIXTURE_PATH.'vps_billing.csv'); \t\n \t\t$dataSet->addTable(TB_VPS_INVOICE, FIXTURE_PATH.'vps_invoice.csv');\n \t\t$dataSet->addTable(TB_VPS_INVOICE_ITEM, FIXTURE_PATH.'vps_invoice_item.csv');\n \t\t$dataSet->addTable(TB_VPS_MODULE2CUSTOMER, FIXTURE_PATH.'vps_module2customer.csv');\n \t\t$dataSet->addTable(TB_VPS_PAYMENT, FIXTURE_PATH.'vps_payment.csv');\n \t\t$dataSet->addTable(TB_VPS_SCHEDULE_CUSTOMER_PLAN, FIXTURE_PATH.'vps_schedule_customer_plan.csv');\n \t\t$dataSet->addTable(TB_VPS_SCHEDULE_LIMIT, FIXTURE_PATH.'vps_schedule_limit.csv');\n \t\t\n \t\t//\treplace '__NULL__' to real NULL\n \t\t$replacedDataSet = new PHPUnit_Extensions_Database_DataSet_ReplacementDataSet($dataSet, array( self::CSV_NULL => null) );\t\n \t\t \t\t\n \treturn $replacedDataSet;\n \t}", "title": "" }, { "docid": "2286739e2615b5a8b3b32c2db131800c", "score": "0.63738966", "text": "protected function getDataSet() {\n \t$dataSet = new PHPUnit_Extensions_Database_DataSet_CsvDataSet(';','\"','\\\\');\n \t$dataSet->addTable(TB_VPS_CUSTOMER, FIXTURE_PATH.'vps_customer.csv');\n \t$dataSet->addTable(TB_VPS_CUSTOMER_LIMIT, FIXTURE_PATH.'vps_customer_limit.csv');\n \t$dataSet->addTable(TB_COMPANY, FIXTURE_PATH.'company.csv');\n \t$dataSet->addTable(TB_VPS_BILLING, FIXTURE_PATH.'vps_billing.csv'); \t\n \t\t$dataSet->addTable(TB_VPS_INVOICE, FIXTURE_PATH.'vps_invoice.csv');\n \t\t$dataSet->addTable(TB_VPS_INVOICE_ITEM, FIXTURE_PATH.'vps_invoice_item.csv');\n \t\t$dataSet->addTable(TB_VPS_MODULE2CUSTOMER, FIXTURE_PATH.'vps_module2customer.csv');\n \t\t$dataSet->addTable(TB_VPS_PAYMENT, FIXTURE_PATH.'vps_payment.csv');\n \t\t$dataSet->addTable(TB_VPS_SCHEDULE_CUSTOMER_PLAN, FIXTURE_PATH.'vps_schedule_customer_plan.csv');\n \t\t$dataSet->addTable(TB_VPS_SCHEDULE_LIMIT, FIXTURE_PATH.'vps_schedule_limit.csv');\n \t\t\n \t\t//\treplace '__NULL__' to real NULL\n \t\t$replacedDataSet = new PHPUnit_Extensions_Database_DataSet_ReplacementDataSet($dataSet, array( self::CSV_NULL => null) );\t\n \t\t \t\t\n \treturn $replacedDataSet;\n \t}", "title": "" }, { "docid": "21f679c5665c80d2a929c04dbcaf1a35", "score": "0.6345435", "text": "public function getTestsData()\n {\n return $this->participations;\n }", "title": "" }, { "docid": "139eaa15002574ba490b60d0457f4e49", "score": "0.6339", "text": "public function getTestData()\n {\n $data = array(\n\t\t\t'data0' => array(),\n\t\t\t'data1' => array(\"foo\" => \"bar\", \"baz\" => array()),\n\t\t\t'data2' => array(\"foo\" => array(\"bar\", \"baz\")),\n\t\t\t'data3' => array(\"foo\" => null),\n\t\t\t'data4' => array(\"foo\" => array(\"bar\" => array(\"baz\" => null))),\n );\n\n return $data;\n }", "title": "" }, { "docid": "ad7a5f54a95000780b852e29ca8369f3", "score": "0.62965345", "text": "protected function getTestData() : array\n {\n return [\n 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10\n ];\n }", "title": "" }, { "docid": "4bc69e78dfd042b22951696d56583b4d", "score": "0.62847066", "text": "protected function getTestData()\n {\n return [\n 'key' => 'value',\n 'array' => [\n 'key1' => 'value1',\n 'key2' => 'value2',\n ],\n ];\n }", "title": "" }, { "docid": "b14fe3456eb88a04abcc02fd49cc7739", "score": "0.62716156", "text": "protected function getDataSet()\n {\n return $this->createFlatXMLDataSet(__DIR__ . '/../../../doctrine/truncateDataTables.xml');\n }", "title": "" }, { "docid": "72cfdb22231b1b1386cf5e321ccccb3d", "score": "0.62335944", "text": "public function getDataSet()\n {\n $seedFilePath = __DIR__ . '/databaseXml/seedMessages.xml';\n return $this->createXMLDataSet($seedFilePath);\n }", "title": "" }, { "docid": "a6e9dccd333f32079b6858bbd33da298", "score": "0.62293977", "text": "public function dataset() : Labeled\n {\n return $this->dataset;\n }", "title": "" }, { "docid": "3763f7a7ad6116beb5597dd3616c46eb", "score": "0.6205461", "text": "public function provideTestData()\n {\n return [\n // Variant 1\n ['9110000000', true],\n ['0269876545', true],\n\n ['9111000000', false],\n ['0269456780', false],\n\n // Variant 2\n ['487310018', true, '80053782'],\n\n ['467310018', false, '80053762'],\n ['477310018', false, '80053772'],\n ];\n }", "title": "" }, { "docid": "cfd3a100c136cf36ec717ce3e05c8f3e", "score": "0.6194248", "text": "protected function dataSet() {\n $data_set = parent::dataSet();\n $data_set[] = [\n 'name' => 'Ginger',\n 'age' => 25,\n 'job' => NULL,\n 'created' => gmmktime(0, 0, 0, 1, 2, 2000),\n 'status' => 1,\n ];\n return $data_set;\n }", "title": "" }, { "docid": "09a1ce257c58d01b90e881b84bf6ae55", "score": "0.6190906", "text": "public function getDataFixtures(): StringCollection\n {\n return $this->dataFixtures;\n }", "title": "" }, { "docid": "d6ae5184c1bf431a4ebe2f097133620e", "score": "0.61747915", "text": "protected function _loadTestData()\n {\n if ($this->_testData) {\n return $this;\n }\n foreach ($this->_configFixtures as $codePoolData) {\n if (!array_key_exists('data', $codePoolData)) {\n continue;\n }\n foreach ($codePoolData['data'] as $file) {\n $dataSets = $this->getConfig()->getHelper('file')->loadYamlFile($file);\n if (!$dataSets) {\n continue;\n }\n foreach ($dataSets as $dataSetKey => $content) {\n if ($content) {\n $this->_testData[$dataSetKey] = $content;\n }\n }\n }\n }\n\n return $this;\n }", "title": "" }, { "docid": "c8059af01885bb9798076b63e0fc1c4c", "score": "0.6158734", "text": "public function provideTestData()\n {\n return [\n ['1112048219', true],\n ['2024601814', true],\n ['3000005012', true],\n ['4143406984', true],\n ['5926485111', true],\n ['6286304975', true],\n ['7900256617', true],\n ['8102228628', true],\n ['9002364588', true],\n\n ['0359432843', false],\n ['1000062023', false],\n ['2204271250', false],\n ['3051681017', false],\n ['4000123456', false],\n ['5212744564', false],\n ['6286420010', false],\n ['7859103459', false],\n ['8003306026', false],\n ['9916524534', false],\n ];\n }", "title": "" }, { "docid": "8a73d35bf2ebcfb68aaaf8af1a459f2d", "score": "0.61542314", "text": "public static function dataSet()\n\t{\n\t\t$cases = array(\n\t\t\t'case_1' => array(\n\t\t\t\t'',\n\t\t\t\t''\n\t\t\t),\n\t\t\t'script_0' => array(\n\t\t\t\t'<script>alert(\\'hi!\\');</script>',\n\t\t\t\t''\n\t\t\t),\n\n\t\t);\n\t\t$tests = $cases;\n\n\t\treturn $tests;\n\t}", "title": "" }, { "docid": "96c522d2b2287b02852ed7cb98343aa0", "score": "0.61443955", "text": "public function getDataSource() {\n return ConnectionManager::getDataSource('test');\n }", "title": "" }, { "docid": "ac3d8dc08bf14637ee96fcd04ca52d2f", "score": "0.6142952", "text": "public function provideTestData()\n {\n return [\n // Variant 1\n ['43001500', true, '13051172'],\n ['48726458', true, '13051172'],\n\n ['29837521', false, '13051172'],\n\n // Variant 2\n ['0082335729', true, '13051172'],\n ['0734192657', true, '13051172'],\n ['6932875274', true, '13051172'],\n\n ['0132572975', false, '13051172'],\n ['3038752371', false, '13051172'],\n\n // Data from accounts.json\n ['42279904', true, '81053272'],\n ['48074470', true, '81053272'],\n ['49279640', true, '81053272'],\n ['0082335729', true, '81053272'],\n ['0734192657', true, '81053272'],\n ['6932875274', true, '81053272'],\n\n ['0132572975', false, '86055462'],\n ['3038752371', false, '86055462'],\n ];\n }", "title": "" }, { "docid": "4f7ada07b13de4ecb94a3f2e45b05254", "score": "0.61173904", "text": "function get_datasets(){\r\n\t$subdir='recommender/classes/datasets';\r\n\treturn get_classes_selection($subdir);\r\n}", "title": "" }, { "docid": "2f812effcdb73a29599664b7a79f4424", "score": "0.61105204", "text": "public function readSuiteData()\n {\n return $this->suiteData->get();\n }", "title": "" }, { "docid": "97db0c55b3a72835abd629c9823a1432", "score": "0.6102291", "text": "public function getDataset()\n {\n if (null === $this->dataset) {\n $this->dataset = new Dataset(\n $this->tableName,\n null,\n 'id',\n $this->needsCreatedAt,\n $this->needsUpdatedAt,\n (bool) Application::getConfig()->resources->multidb->slave->enabled\n );\n\n if (!empty($this->primaryKey)) {\n $this->dataset->setPrimaryKey($this->primaryKey);\n }\n }\n \n return $this->dataset;\n }", "title": "" }, { "docid": "965bfbd36fcfb2776c7c3ac6ed5a2c8b", "score": "0.6083316", "text": "protected function getDataSet($name = 'default', $module = null)\n {\n $path = BASE_PATH.'/core/tests/databaseDataset/'.$name.'.xml';\n if (isset($module) && !empty($module)) {\n $path = BASE_PATH.'/modules/'.$module.'/tests/databaseDataset/'.$name.'.xml';\n }\n\n return new PHPUnit_Extensions_Database_DataSet_FlatXmlDataSet($path);\n }", "title": "" }, { "docid": "592d4ae7a9e1a966376dd85f6dc1ce1d", "score": "0.6082023", "text": "protected function dataSet() {\n $data = parent::dataSet();\n for ($i = 0; $i < 55; $i++) {\n $data[] = [\n 'name' => 'name_' . $i,\n 'age' => $i,\n 'job' => 'job_' . $i,\n 'created' => rand(0, time()),\n 'status' => 1,\n ];\n }\n return $data;\n }", "title": "" }, { "docid": "fdc5f505263f895835091eff33da8a79", "score": "0.60528475", "text": "public function getTestDocuments()\n {\n return $this->test_documents;\n }", "title": "" }, { "docid": "46d5774d7d281870984570f51491b651", "score": "0.600772", "text": "public function getData() {\n return Datatables::of(LearningTargets::query())->make(true);\n }", "title": "" }, { "docid": "120fc8741e2fc3a37bb3accf5ddba9fe", "score": "0.5970722", "text": "protected function fixture() {\n return new \\rdbms\\sqlite\\SQLiteConnection(new \\rdbms\\DSN('sqlite://localhost/'));\n }", "title": "" }, { "docid": "4c8285ce8fd7ecf00423bd0c04e19ba6", "score": "0.59645873", "text": "public function provideTestData()\n {\n return [\n // variant one\n ['0020012357', true],\n ['0080012345', true],\n ['0926801910', true],\n ['1002345674', true],\n\n // variant one\n ['0020012399', false],\n ['0080012347', false],\n ['0080012370', false],\n ['0932100027', false],\n ['3310123454', false],\n\n // variant two\n ['8000990054', true],\n ['9000481805', true],\n\n // variant two\n ['8000990057', false],\n ['8011000126', false],\n ['9000481800', false],\n ['9980480111', false],\n ];\n }", "title": "" }, { "docid": "96fc0d56f42b7c47e818405f03628bfd", "score": "0.5929744", "text": "public function get_tests_data() \n {\n $this->db->order_by('category'); \n $query = $this->db->get(\"tests\"); \n\n return $query->result(); \n }", "title": "" }, { "docid": "af4bc7ca139b07bc1efd552f2288a329", "score": "0.5871989", "text": "public function get($filters=array()) {\n\n\t\treturn $this->_test_data();\n\n\t}", "title": "" }, { "docid": "99e92c93b6ac0762bdd165ff875a9f96", "score": "0.5861298", "text": "public function testDataRead(): void {\n $fd = $this->getQueryFixtureFromString('<sample data-foo=\"bar\"/>')->find('//sample');\n $this->assertEquals('bar', $fd->data('foo'));\n }", "title": "" }, { "docid": "26f26cea67393bf0d18509b8458772e5", "score": "0.5854677", "text": "public function get_user_custom_datasets()\n\t{\n\t\treturn $this->user_defined_datasets;\n\t}", "title": "" }, { "docid": "1da1e6d7685cb887fbb3224662614aca", "score": "0.5849801", "text": "public function dataProvider()\n {\n $expectedResults = [\n 12,\n 12.345,\n 0.12345,\n 14.0886318001429791,\n 14.0886318001429791,\n 6.79012230394269113,\n 6.79012230394269113,\n 0.690032689443043705,\n 0.690032689443043705,\n 9.8765,\n 0.98765,\n 10.7803660999986452,\n 10.7803660999986452,\n 1.07803660999986452,\n 1.07803660999986452,\n 1,\n 1,\n 0.123,\n 0.123,\n 1,\n ];\n\n return $this->formatOneArgumentTestResultArray($expectedResults);\n }", "title": "" }, { "docid": "fc097f6099de23fd905c72c16b515e31", "score": "0.58439785", "text": "public function getAll()\n {\n return $this->tests;\n }", "title": "" }, { "docid": "cc75db103c671a27c19bb892eda6afc9", "score": "0.58400524", "text": "protected function getTestConfigurationData(): array\n {\n if ($this->testConfiguration) {\n return $this->testConfiguration;\n }\n\n $testDatabaseTable = self::$testDatabaseTable;\n\n $testConfigurationJson = <<<CONFIGURATION\n{\n \"ResourceType\": {\n \"mapping\": {\n \t\"identifier\": \"uid\",\n \"tableName\": \"$testDatabaseTable\",\n\n \"properties\": {\n \"uid\": {\n \"type\": \"int\",\n \"column\": \"uid\"\n },\n \"title\": {\n \"type\": \"string\",\n \"column\": \"title\"\n },\n \"content\": {\n \"type\": \"string\",\n \"column\": \"content\"\n },\n \"contentTime\": {\n \"type\": \"int\",\n \"column\": \"content_time\"\n }\n }\n }\n }\n}\nCONFIGURATION;\n\n $this->testConfiguration = json_decode($testConfigurationJson, true);\n\n return $this->testConfiguration;\n }", "title": "" }, { "docid": "25c7f899e725fedc206acdab6f78953c", "score": "0.58349043", "text": "public function provideTestData()\n {\n return [\n // method A\n ['0001975641', true],\n ['0001988654', true],\n\n // method A\n ['0001924592', false],\n\n // method B\n ['0001863530', true],\n ['0001784451', true],\n\n // method B\n ['0000901568', false],\n\n // method C\n ['0000654321', true],\n ['0000824491', true],\n\n // method C\n ['0000820487', false],\n\n // method D\n ['0000677747', true],\n ['0000840507', true],\n\n // method D\n ['0000726393', false],\n\n // method E\n ['0000996663', true],\n ['0000666034', true],\n\n // method E\n ['0000924591', false],\n\n // method F\n ['0099100002', true],\n\n // method F\n ['0099100007', false],\n\n // method G\n ['0004923250', true],\n ['0003865960', true],\n\n // method G\n ['0003865964', false],\n ];\n }", "title": "" }, { "docid": "01da5e237ff28ba7373215b101674b9f", "score": "0.58127993", "text": "public function getTestById ($testId)\n {\n $testData = $this->_testDoctrineOb->find($testId);\n if ($testData) {\n $testData->categories = array_keys(\n $this->_testcategoryMapper->getTestCetegories($testId));\n $testData->count = $this->getQuestionAnswerByTestId($testId);\n }\n return $testData;\n }", "title": "" }, { "docid": "c9b0b190e09c215b1baf3eff42b3f3e3", "score": "0.5805406", "text": "public function data()\n {\n return $this->factory()->get('data');\n }", "title": "" }, { "docid": "baf40554bc284e41370a5bafb32bd34d", "score": "0.5802525", "text": "public function getAdditionalDatasets(): array;", "title": "" }, { "docid": "d3723b07da106cca1989a7a1f12c7f0a", "score": "0.58020693", "text": "public function getTest()\n\t{\n\t\treturn $this->test;\n\t}", "title": "" }, { "docid": "34780b1b0438b8d45964ae78573ed48d", "score": "0.5793909", "text": "public function getTest()\n {\n return $this->test;\n }", "title": "" }, { "docid": "4bf6e5bb8236e59dfebb25483f0d20b7", "score": "0.5790175", "text": "public function getDatasetId()\n {\n return $this->dataset_id;\n }", "title": "" }, { "docid": "0bbb973fb8d178cf0233e5294917a9f1", "score": "0.5759716", "text": "public function createTestData() {\n\t\tQuiz::getQuery()->delete(); // or ::truncate()\n\t\t/* Creates quiz object data */\n\t\t$ret = new Quiz();\n\t\t$ret->id = QUIZ_SERVICE_TEST_ID_1;\n\t\t$ret->name = \"Teste de desenvolvimento\";\n\t\t$ret->description = \"Teste para desenvolvedor back-end\";\n\t\t$ret->category = \"Testes\";\n\t\t$ret->base_points = 100;\n\t\t$ret->start_date = new \\DateTime(\"2018-02-15 00:00:00\");\n\t\t$ret->end_date = new \\DateTime(\"2018-02-22 00:00:00\");\n\t\t$ret->is_active = true;\n\t\t$ret->already_answered = false;\n\t\t/* Persist data to database */\n\t\t$ret->save();\n\t\t/* Creates child entities */\n\t\t$this->questionService->createTestData($ret);\n\t\treturn $ret;\n\t}", "title": "" }, { "docid": "53a618e3afe13aea1f869f72e3717cf6", "score": "0.57508504", "text": "abstract protected function initTestData() : array;", "title": "" }, { "docid": "8bbd038f48bc2a8232f75c21a293ae9e", "score": "0.57234126", "text": "public function getAutomlDataset()\n {\n return $this->readOneof(3);\n }", "title": "" }, { "docid": "27a8311a40d12102b1fd45e2b1276859", "score": "0.57158226", "text": "public function getData() {\n return $this->run('getData', array());\n }", "title": "" }, { "docid": "725a5d0a2c14e791eaff0699d28f8197", "score": "0.571113", "text": "public static function suite() {\n\t\t$suite = new vipDbTestSuite('PHPUnit Framework');\n\t\tself::traverseTests(\"../../data/test/vip_db\", $suite);\n\t\treturn $suite;\n\t}", "title": "" }, { "docid": "cec59768e4d5f19d520da1bed687bae4", "score": "0.56924635", "text": "public static function get_tests() {}", "title": "" }, { "docid": "bcc9226e5016ef433eb2e27cceb60a40", "score": "0.56846124", "text": "public function getTestingData()\n {\n $out = [];\n\n // Case #0: simple from title field.\n $out[] = [[3], new Request(['q' => 'Bar'])];\n\n // Case #1: Test if word in description is boosted more\n $out[] = [[2, 1], new Request(['q' => 'Foo'])];\n\n return $out;\n }", "title": "" }, { "docid": "e46d8dad5967e1787bbfd81a412a09c8", "score": "0.5683759", "text": "function obiba_mica_dataset_get_study_datasets_list() {\n $node_rendered = obiba_mica_commons_get_translated_node(variable_get_value('study_dataset_page'));\n drupal_set_title($node_rendered['#node']->title);\n return obiba_mica_dataset_get_datasets_page($node_rendered, DrupalMicaDatasetResource::COLLECTED_DATASET);\n}", "title": "" }, { "docid": "67306251ff707741cb2ceed22d91fca7", "score": "0.56823844", "text": "public function provideTestData()\n {\n return [\n ['0646440', true],\n ['1359100', true],\n\n ['0646441', false],\n ['1359101', false],\n\n // exceptions - calculation as exceptions in validator 51\n ['0199100002', true],\n ['0099100010', true],\n ['2599100002', true],\n ['0199100004', true],\n ['2599100003', true],\n ['3199204090', true],\n\n // exceptions - calculation as exceptions in validator 51\n ['0099345678', false],\n ['0099345678', false],\n ['0099100110', false],\n ['0199100040', false],\n ];\n }", "title": "" }, { "docid": "f3886696975e973863ff5d750670ac33", "score": "0.56789464", "text": "public function getKeyValDataTest()\n {\n return $this->keyValDataTest;\n }", "title": "" }, { "docid": "68e0722233bfa7614ed863da82b35010", "score": "0.5661731", "text": "public function getTests();", "title": "" }, { "docid": "68e0722233bfa7614ed863da82b35010", "score": "0.5661731", "text": "public function getTests();", "title": "" }, { "docid": "1302f7621ea21bfd7de082cf5f5d860b", "score": "0.5645575", "text": "public function testDataSuccess(){\n\n $response = $this->json(\"get\",'/api/v1/data-chart',['instrument' => 'USD_JPY', 'granularity' => 'M1'])\n ->assertStatus(200);\n\n $response->dump();\n }", "title": "" }, { "docid": "a706eb2438dd508159645fc1a99425ef", "score": "0.5637236", "text": "public function dataSets();", "title": "" }, { "docid": "b4665b8fec23d295508533d4569a09df", "score": "0.563318", "text": "public function getStatisticalDataSet()\n {\n return $this->hasOne(StatisticalDataSet::className(), ['id' => 'statistical_data_set_id']);\n }", "title": "" }, { "docid": "ea3960b61664ed1fbb9ec22f4ffe14c0", "score": "0.5630155", "text": "public function getDataFactory()\n {\n return $this->data_factory;\n }", "title": "" }, { "docid": "904f8946590fcc270c55d15e33bc3767", "score": "0.5629358", "text": "public function getterSetterTestDataProvider()\n {\n $testData = [];\n $testValue = null;\n\n foreach ($this->settableAttributes as $attribute => $type) {\n switch ($type) {\n case 'string':\n $testValue = uniqid('testString');\n break;\n\n case 'int':\n case 'integer':\n $testValue = rand(-10000, +10000);\n break;\n\n case 'bool':\n case 'boolean':\n $testValue = true;\n break;\n\n case 'float':\n $testValue = 0 + mt_rand() / mt_getrandmax() * 20;\n break;\n\n case 'DateTime':\n $testValue = new \\DateTime();\n break;\n\n default:\n if (class_exists($type)) {\n $testValue = new $type();\n break;\n }\n throw new \\Exception(sprintf('Type \"%s\" not recognized', $type), 1539948988);\n }\n\n $testName = 'Test setter and getter for Attribute ' . $attribute;\n $getterName = 'get' . ucfirst($attribute);\n $setterName = 'set' . ucfirst($attribute);\n\n $testData[$testName] = ['setterName' => $setterName, 'getterName' => $getterName, 'testValue' => $testValue];\n }\n\n return $testData;\n }", "title": "" }, { "docid": "cd32f3a569604c1982c29441871bab2c", "score": "0.56141347", "text": "static public function suite() {\n return Dev_Unit::load_with_prefix('Test.DB.', 'Case');\n }", "title": "" }, { "docid": "c2a273b1d34616bfc006ce1d164c99d9", "score": "0.56073695", "text": "abstract public function getFixtures();", "title": "" }, { "docid": "1e62f7d6f43e2f21f795b1f68dfcbf05", "score": "0.5579801", "text": "public function get_data()\n {\n //we replace Test Name with the class name and method name\n $old_results = $this->unit->result();\n foreach($old_results as $result){\n $test_name = strip_tags($result['Test Name']);\n $test_data = explode('->',$test_name);\n $result['classname'] = trim($test_data[0]);\n $result['method'] = trim($test_data[1]);\n\n //Set the file_data to more accurate results.\n $method_id =trim('Test_' . $result['classname'].':test_'.$result['method']);\n //If there are no asserts in the method, they won't be added to the file_data.\n if(in_array($method_id, array_keys($this->file_data))){\n $result['File Name'] = $this->file_data[$method_id]['file'];\n $result['Line Number'] = $this->file_data[$method_id]['line'];\n }\n\n unset($result['Test Name']);\n $results[] = $result;\n }\n return array('modelname' => $this->modelname,\n 'messages' => $this->messages,\n 'results' => $results\n );\n }", "title": "" }, { "docid": "440abb00d8744063987e556dcbe4472d", "score": "0.5572378", "text": "public function getDataProvider()\n {\n return $this->dataProvider;\n }", "title": "" }, { "docid": "19d1032e5da39d8b45d6fe90e7148842", "score": "0.55691665", "text": "public function getDatasetClass()\n\t{\n\t\treturn $this->datasetClass;\n\t}", "title": "" }, { "docid": "ea983033eec7c77abb4c27c9e2ec28ca", "score": "0.5566735", "text": "public function getTests(): array {}", "title": "" }, { "docid": "5ae91d39a59516e9c529c8e20517d5cb", "score": "0.5563052", "text": "public function dataProviderForTestGetDataFromURL()\n {\n $rssFixture = new RssApiFixture();\n return [\n 'get_data_succeed' => [\n 'input' => [\n 'url' => ['http://www.sample.feed.com'],\n 'api' => [\n [\n 'status_code' => 200,\n 'body' => $rssFixture->getResponseItem100ForFeedService()\n ]\n ]\n ],\n 'expected' => true\n ],\n 'get_data_failed' => [\n 'input' => [\n 'url' => ['http://www.empty.feed.com'],\n 'api' => [\n [\n 'status_code' => 200,\n 'body' => $rssFixture->getResponseEmptyForFeedService()\n ]\n ]\n ],\n 'expected' => false\n ]\n ];\n }", "title": "" }, { "docid": "b613b46fe239c9685c3d2ab5560333cc", "score": "0.55371183", "text": "private function _test_data() {\n\n return array(\n 'big_numbers' => array(\n 'all_service_events' => 115475,\n 'households_served' => 26122,\n 'people_served' => 88767,\n 'average_visits_per_family' => 4.42\n ),\n 'statistical' => array(\n 'number_of_households' => array(\n 'with_minor_children' => 7379,\n 'without_minor_children' => 10925\n ),\n 'number_of_seniors_served' => array(\n 'with_minor_children' => 2337,\n 'without_minor_children' => 7893\n ),\n 'number_of_adults_served' => array(\n 'with_minor_children' => 14936,\n 'without_minor_children' => 11553\n ),\n 'number_of_children_served' => array(\n 'with_minor_children' => 15694,\n 'without_minor_children' => 0\n )\n ),\n 'service_summaries' => array(\n 'services' => array(\n array(\n 'service' => 'Pantry - Prepack - 3 day',\n 'families_served' => 17271,\n 'people_served' => 49743,\n 'meals_provided' => 447687\n ),\n array(\n 'service' => 'Emergency - Prepack - 1 day',\n 'families_served' => 105,\n 'people_served' => 229,\n 'meals_provided' => 687\n ),\n array(\n 'service' => 'Emergency - Prepack - 3 day',\n 'families_served' => 566,\n 'people_served' => 1434,\n 'meals_provided' => 12906\n ),\n array(\n 'service' => 'Home Delivered Food',\n 'families_served' => 361,\n 'people_served' => 960,\n 'meals_provided' => 8820\n ),\n array(\n 'service' => 'Water',\n 'families_served' => 1,\n 'people_served' => 24,\n 'meals_provided' => 0\n ),\n ),\n 'total_meals_provided' => 470100,\n 'average_meals_per_person' => 8.97\n ),\n 'service_distributions' => array(\n array(\n 'number_sites_visited' => 1,\n 'number_families' => 3155\n ),\n array(\n 'number_sites_visited' => 2,\n 'number_families' => 1032\n ),\n array(\n 'number_sites_visited' => 3,\n 'number_families' => 531\n ),\n array(\n 'number_sites_visited' => 4,\n 'number_families' => 239\n ),\n array(\n 'number_sites_visited' => 5,\n 'number_families' => 347\n ),\n ),\n 'household_size_distribution' => array(\n array(\n 'number_of_patients' => 1,\n 'patient_household_size' => 1807\n ),\n array(\n 'number_of_patients' => 2,\n 'patient_household_size' => 1355\n ),\n array(\n 'number_of_patients' => 3,\n 'patient_household_size' => 1278\n ),\n array(\n 'number_of_patients' => 4,\n 'patient_household_size' => 1265\n ),\n array(\n 'number_of_patients' => 5,\n 'patient_household_size' => 1119\n ),\n array(\n 'number_of_patients' => 6,\n 'patient_household_size' => 684\n ),\n array(\n 'number_of_patients' => 7,\n 'patient_household_size' => 365\n ),\n array(\n 'number_of_patients' => 8,\n 'patient_household_size' => 197\n ),\n array(\n 'number_of_patients' => 9,\n 'patient_household_size' => 105\n ),\n array(\n 'number_of_patients' => 10,\n 'patient_household_size' => 80\n )\n ),\n 'household_composition' => array(\n 'test'\n ),\n 'families_served' => array(\n 'test'\n ),\n 'service_trends' => array(\n 'test'\n ),\n 'family_statistics' => array(\n\n ),\n 'service_frequency' => array(\n\n ),\n );\n\n }", "title": "" }, { "docid": "bd599dcd1dca5ef1499ea07c084e64d6", "score": "0.55232656", "text": "public function getData()\n {\n return (new XiboDataSetRow($this->getEntityProvider()))->get($this->dataSetId);\n }", "title": "" }, { "docid": "60be065e10286991af1df9b9214fbb11", "score": "0.55076814", "text": "public function data()\n {\n $webset = Webset::where('id', 1)->first();\n return $webset->toArray();\n }", "title": "" } ]
0eb60d71263106317cb4049337d9509f
This test will cover the error handling of the curl adapter
[ { "docid": "dadec55b9e6ac3fd1c2e060fd2e495d0", "score": "0.7166525", "text": "function testHostNotFound() {\n \n $curlAdapter = new CurlAdapter();\n \n $result = $curlAdapter->sendPost('https://abc.heidelpay.de/');\n \n \n \n $this->assertTrue(is_array($result[0]), 'First result key should be an array.');\n $this->assertTrue(is_object($result[1]), 'Secound result key should be an object.');\n $expected = array(\n 'PROCESSING_RESULT' => 'NOK',\n 'PROCESSING_RETURN_CODE' => 'CON.ERR.DEF' \n );\n $this->assertEquals($expected['PROCESSING_RESULT'], $result[0]['PROCESSING_RESULT']);\n $this->assertEquals($expected['PROCESSING_RETURN_CODE'], $result[0]['PROCESSING_RETURN_CODE']);\n \n $this->assertTrue($result[1]->isError(), 'isError should return true');\n $this->assertFALSE($result[1]->isSuccess(), 'isSuccess should return false');\n \n $error = $result[1]->getError();\n \n $this->assertEquals($expected['PROCESSING_RETURN_CODE'], $error['code']);\n }", "title": "" } ]
[ { "docid": "4990db4d36343f118d83704bc1303b72", "score": "0.7579392", "text": "public function testCurlError()\n {\n $expectedBody = $this->getExpectedBody(\n [\n ['SKU' => 'test123']\n ],\n []\n );\n\n $this->mockEndpoint();\n $this->mockCurl($expectedBody, 500, '', 'Some error');\n\n $error = '';\n try {\n $this->subject->addData(['SKU' => 'test123']);\n $this->subject->send();\n } catch (Exception $e) {\n $error = $e->getMessage();\n }\n\n $this->assertEquals(\n 'Error: HTTP 500 Response | Error Message: Some error | Body: ',\n $error\n );\n }", "title": "" }, { "docid": "75ef7e4af48f5b8957761179cfef53a5", "score": "0.67199033", "text": "public function testSoftError()\n {\n $expectedBody = $this->getExpectedBody(\n [\n ['SKU' => 'test123']\n ],\n []\n );\n\n $this->mockEndpoint();\n $this->mockCurl($expectedBody, 200, 'An error response');\n\n $error = '';\n try {\n $this->subject->addData(['SKU' => 'test123']);\n $response = $this->subject->send();\n\n $this->assertEquals(\n 'An error response',\n $response[0]['body']\n );\n } catch (Exception $e) {\n $error = $e->getMessage();\n }\n\n $this->assertEquals(\n '',\n $error\n );\n }", "title": "" }, { "docid": "8ae16d1a0d606b74e47030d92fbc9eb7", "score": "0.66241294", "text": "static function catchError($ch){\r\n if (!is_resource($ch) || !($curl_errno=curl_errno($ch))){\r\n return false;\r\n }\r\n self::$curl_errno = $curl_errno;\r\n self::$curl_error = curl_error($ch);\r\n throw new gCurlException(80,$curl_errno,self::$curl_error);\r\n return true;\r\n }", "title": "" }, { "docid": "e015161768ef9d4df1985413385ac5f9", "score": "0.643015", "text": "private static function error($ch){\n\t\t\txlog('FTPWRP: Checking connection status: '.(curl_errno($ch)==0?'no errors':' Error: ('.curl_errno($ch).') '.curl_error($ch)));\n\t\t}", "title": "" }, { "docid": "f8795ecc16f15bd7a0d08b079a7439b5", "score": "0.63746125", "text": "public function testOtherError()\n {\n $expectedBody = $this->getExpectedBody(\n [\n ['SKU' => 'test123']\n ],\n []\n );\n\n $this->mockEndpoint();\n $this->mockCurl($expectedBody, 200, 'An error response', 'An error');\n\n $error = '';\n try {\n $this->subject->addData(['SKU' => 'test123']);\n $response = $this->subject->send();\n\n $this->assertEquals(\n 'An error response',\n $response[0]['body']\n );\n } catch (Exception $e) {\n $error = $e->getMessage();\n }\n\n $this->assertEquals(\n 'Error: An error',\n $error\n );\n }", "title": "" }, { "docid": "c3eeda03d480664bc765016152f4d843", "score": "0.63332903", "text": "public function get_error()\n {\n return curl_error($this->ch); \n }", "title": "" }, { "docid": "25f858d055d91d7b3333eb0345363db8", "score": "0.6149483", "text": "public function testGetHttpStatusCode()\n {\n $this->curlAdapter->open();\n \n $this->assertEmpty($this->curlAdapter->getHttpStatusCode());\n \n $this->curlAdapter->close();\n }", "title": "" }, { "docid": "89a87f7c785310c66b9ff0f3f5e91829", "score": "0.60980356", "text": "public function testError()\n {\n $error = $this->response->error(404, 'File Not Found');\n json_decode($error);\n $checkJson = (json_last_error() == JSON_ERROR_NONE);\n\n $this->assertTrue($checkJson);\n }", "title": "" }, { "docid": "6709f424f1cb1a06b248d1def32c2259", "score": "0.60956854", "text": "function curl_get($url, array $get = NULL, array $options = array()) \n{ \n\t$defaults = array( \n CURLOPT_URL => $url. (strpos($url, '?') === FALSE ? '?' : ''). http_build_query($get), \n CURLOPT_HEADER => 0, \n CURLOPT_RETURNTRANSFER => TRUE, \n CURLOPT_TIMEOUT => 10 \n\t\t//, CURLOPT_FAILONERROR => true\n ); \n \n\t\t//print '$defaults<br/>';\n //print_r( $defaults);\n\n\t$ch = curl_init(); \n curl_setopt_array($ch, ($options + $defaults)); \n\t$result = curl_exec($ch);\n if($result === false) \n { \n\t\t//print 'curl_error<br/>';\n //print curl_error($ch);\n\t\t//trigger_error(curl_error($ch)); \n\t\tthrow new Exception(curl_error($ch)); \n\t\t\n } \n\t/*\n\tprint 'result<br/>';\n\tvar_dump( $result);\n\tprint 'curl_error<br/>';\n\tprint curl_error($ch);\n\tprint 'END========<br/>';\n\t*/\n curl_close($ch); \n return $result; \n\t\n}", "title": "" }, { "docid": "d2d946f419390586da479484cc106b14", "score": "0.6019249", "text": "public function testNoExceptionThrown()\n {\n $client = new MultiCurl(new Psr17Factory(), ['timeout' => 1]);\n\n $request = new Request('GET', $_SERVER['BUZZ_TEST_SERVER'].'?delay=3');\n\n $client->sendAsyncRequest($request, ['callback' => function ($request, $response, $exception) {\n $this->assertInstanceOf(NetworkException::class, $exception);\n }]);\n\n $client->flush();\n }", "title": "" }, { "docid": "2a5de4e0e09f999a874c4b24b33a7fe4", "score": "0.6018088", "text": "private function checkCurlResult($code)\n {\n if ($code <= 0) {\n return;\n }\n\n if (isset($this->multiErrors[$code])) {\n $message = \"cURL error: {$code} ({$this->multiErrors[$code][0]}): cURL message: {$this->multiErrors[$code][1]}\";\n } else {\n $message = 'Unexpected cURL error: ' . $code;\n }\n\n throw new CurlException($message);\n }", "title": "" }, { "docid": "ee0ebd9294a45a99c72c2a944a4982da", "score": "0.60070276", "text": "public function testSendMessageHTTPErrorResponses()\n {\n // Configure HTTP basic authorization: basicAuth\n $config = Configuration::getDefaultConfiguration()\n ->setUsername('YOUR_USERNAME')\n ->setPassword('YOUR_PASSWORD');\n\n $expected_code = 400;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n try {\n $result = $apiInstance->sendMessage($message);\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 401;\n // Create a mock response\n $expected = null;\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n try {\n $result = $apiInstance->sendMessage($message);\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 402;\n // Create a mock response\n $expected = new \\Karix\\Model\\InsufficientBalanceResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n try {\n $result = $apiInstance->sendMessage($message);\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 403;\n // Create a mock response\n $expected = new \\Karix\\Model\\UnauthorizedResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n try {\n $result = $apiInstance->sendMessage($message);\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 500;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n try {\n $result = $apiInstance->sendMessage($message);\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n }", "title": "" }, { "docid": "ffed2929501849246b0f5db38d1003e2", "score": "0.5976045", "text": "public function execute()\n {\n if( !extension_loaded('curl') || !function_exists('curl_version') ) {\n return $this->_error('noCurl');\n }\n\n // Get curl info\n $info = curl_version();\n\n // Check features\n if( $this->_ipv6 && !($info['features'] & CURL_VERSION_IPV6) ) {\n $this->_error('noIpv6');\n }\n if( $this->_kerberos4 && !($info['features'] & CURL_VERSION_KERBEROS4) ) {\n $this->_error('noKerberos4');\n }\n if( $this->_libz && !($info['features'] & CURL_VERSION_LIBZ) ) {\n $this->_error('noLibz');\n }\n if( $this->_ssl && !($info['features'] & CURL_VERSION_SSL) ) {\n $this->_error('noSsl');\n }\n\n // Check ssl version\n if( ($this->_minSslVersion || $this->_maxSslVersion) ) {\n if( empty($info['ssl_version']) ||\n !($info['features'] & CURL_VERSION_SSL) ||\n !preg_match('/[\\d.]+/', $info['ssl_version'], $matches) ||\n !($sslVersion = $matches[0]) ) {\n $this->_error('noSsl');\n } else {\n if( $this->_minSslVersion && version_compare($sslVersion, $this->_minSslVersion, '<') ) {\n $this->_error('tooLowSslVersion');\n }\n if( $this->_maxSslVersion && version_compare($sslVersion, $this->_maxSslVersion, '>') ) {\n $this->_error('tooHighSslVersion');\n }\n }\n }\n\n // Check curl lib version\n if( $this->_minVersion && version_compater($info['version'], $this->_minVersion, '<') ) {\n $this->_error('tooLowVersion');\n }\n if( $this->_maxVersion && version_compare($info['version'], $this->_maxVersion, '>') ) {\n $this->_error('tooHighVersion');\n }\n\n // Check protocols\n if( is_array($this->_protocols) && !empty($this->_protocols) ) {\n $missingProtocols = array_diff($this->_protocols, $info['protocols']);\n if( !empty($missingProtocols) ) {\n $this->_error('missingProtocols');\n }\n }\n\n return $this;\n }", "title": "" }, { "docid": "b51b628eeeb812a9d725e6480ddb07ea", "score": "0.5967447", "text": "public function test()\n {\n\n switch ($this->check()) {\n case self::ERROR_CURL:\n if ($this->check(self::PARAM_AUF) == self::ERROR_AUF) {\n print \"\\033[0;31mERROR: cURL not found and allow_url_fopen is disabled.\\033[0m\\n\";\n print \"One of this issues should be resolwed before You can use TextMagicAPI.\\n\\n\";\n print \"\\033[1;33mSolution a:\\033[0m is installing cURL from pear or from sources.\\n\";\n print \"You can use http://php.net/manual/en/book.curl.php for installing cURL.\\n\\n\";\n print \"\\033[1;33mSolution b:\\033[0m is enable 'allow_url_fopen' in Your php.ini file.\\n\";\n print \"You can check 'allow_url_fopen' settings doing 'php -i | grep allow_url_fopen' (without quotes) from terminal.\\n\";\n } else {\n print \"\\033[1;33mWARNING: cURL not found.\\033[0m\\n\";\n print \"You will be able to use only 'fopen' sending method.\\n\";\n print \"Possible solution is installing cURL from pear or from sources.\\n\";\n print \"You can use http://php.net/manual/en/book.curl.php for installing cURL.\\n\";\n }\n break;\n case self::ERROR_OPENSSL:\n print \"\\033[1;33mWARNING: OpenSSL not found or is outdated.\\033[0m\\n\";\n print \"HTTP will be used instead of HTTPS.\\n\";\n print \"For installing or updating OpenSSL You can use http://www.openssl.org and http://php.net/manual/en/openssl.installation.php\\n\";\n break;\n case self::ERROR_AUF:\n print \"\\033[0;31mERROR: allow_url_fopen is disabled.\\033[0m\\n\";\n print \"Possible solution is enable 'allow_url_fopen' in Your php.ini file.\\n\";\n print \"You can check 'allow_url_fopen' settings doing 'php -i | grep allow_url_fopen' (without quotes) from terminal.\\n\";\n break;\n case self::ERROR_NONE:\n print \"\\033[0;32mSUCCES: You system is ready to use TextMagicAPI.\\033[0m\\n\";\n break;\n }\n }", "title": "" }, { "docid": "1d8cb2d4c4ae4269e2ad0622204c6d18", "score": "0.5966902", "text": "function testErrors() {\n\t$config = getConfig();\n\t$root = getRootPath();\n\t\n\t$http = new \\AutoHttp\\Http($config);\n\n\t// Try a malformed URL.\n\t$page = $http->getPage('cheese');\n\tif (!validateResponse($page))\n\t\treturn 'We should receive a valid response object for malformed URLs.';\n\tif ($page['error'] === null)\n\t\treturn 'We should have an error message for malformed URLs.';\n\n\t// Try a URL that fails to resolve.\n\t$page = $http->getPage('http://www.test.abcdosjidfs4nt/page.html');\n\tif (!validateResponse($page))\n\t\treturn 'We should receive a valid response object for URLs that don\\'t resolve properly.';\n\n\t// Try a URL that resolves but fails to connect.\n\t$page = $http->getPage('http://localhost:1/test/omg/page.html');\n\tif (!validateResponse($page))\n\t\treturn 'We should receive a valid response object for URLs that reject our connection.';\n\tif ($page['error'] === null)\n\t\treturn 'We should have an error message for URLs that reject our connection.';\n\t\n\t// Try a page that times out before sending any data.\n\t$page = $http->getPage($root .'/test/pages/http/errortimeout.php?timeout=initial&duration=10');\n\tif (!validateResponse($page))\n\t\treturn 'We should receive a valid response object for pages that time out before sending data.';\n\tif ($page['error'] === null)\n\t\treturn 'We should have an error message for pages that time out before sending data.';\n\t\n\t// Try a page that times out midway through sending data.\n\t$page = $http->getPage($root .'/test/pages/http/errortimeout.php?timeout=during&duration=10');\n\tif (!validateResponse($page))\n\t\treturn 'We should receive a valid response object for pages that time out while sending data.';\n\tif ($page['error'] === null)\n\t\treturn 'We should have an error message for pages that time out while sending data.';\n\t\n\treturn true;\n}", "title": "" }, { "docid": "c964c09d1a14088ea773528421a21c76", "score": "0.59314835", "text": "function execCurl($url) {\n\t//echo \"<br> URL: $url <br>\";\n\t\n\t$curl = curl_init();\n\t\n\tcurl_setopt_array($curl, array(\n\t\tCURLOPT_URL => $url,\n\t\tCURLOPT_RETURNTRANSFER => true,\n\t\tCURLOPT_HEADER => false)\n\t);\n\t\n\t$curl_response = curl_exec($curl);\n\t\n\t$curl_errno = curl_errno($curl);\n $curl_error = curl_error($curl);\n\t\n\tif (curl_error($curl) || $curl_response === false || $curl_errno > 0)\n {\n $info = curl_getinfo($curl);\n echo 'error occured during curl exec - ' . var_export($info) ;\n echo '<br> error -----------> '. $curl_error; \n curl_close($curl);\n }\n \n curl_close($curl);\n\treturn $curl_response;\n}", "title": "" }, { "docid": "627b7b9b3c3007d424e83055d41dfa9a", "score": "0.5900708", "text": "public function get_error()\n\t{\n\t\treturn curl_error($this->ch);\n\t}", "title": "" }, { "docid": "06528b7707f9827c05ec8b3268fa5b13", "score": "0.589822", "text": "public function testSendError()\n {\n $this->setMockHttpResponse('JsonPurchaseResponseError.txt');\n $response = $this->request->send();\n\n $data = $this->request->getData();\n\n $code = $response->response->getStatusCode();\n $this->assertFalse($response->isSuccessful());\n $this->assertEquals(500, $data['amount']);\n $this->assertEquals(400, $code);\n $this->assertSame('BAD_REQUEST', $response->getCode());\n $this->assertSame(\"This card is not accepted for Test transactions\", $response->getMessage());\n $this->assertNull($response->getTransactionReference());\n $this->assertNull($response->getCardReference());\n }", "title": "" }, { "docid": "01206d85277a9f970f14f933eb87420f", "score": "0.589091", "text": "public function testExpandThrowsExceptionIfApiResponseHasInvalidStatusCode()\n {\n $provider = new BitlyProvider($this->getMockClientFactory($this->getMockResponseWithInvalidStatusCode()), $this->getMockAuthentication());\n $provider->expand($this->getBaseMockLink());\n }", "title": "" }, { "docid": "0b8bda2507b005e850c2e1912d049130", "score": "0.588824", "text": "public function testShortenThrowsExceptionIfApiResponseHasInvalidStatusCode()\n {\n $provider = new BitlyProvider($this->getMockClientFactory($this->getMockResponseWithInvalidStatusCode()), $this->getMockAuthentication());\n $provider->shorten($this->getBaseMockLink());\n }", "title": "" }, { "docid": "eee145a94127d0a911c44727057db9de", "score": "0.58871114", "text": "public function testCall() {\n\t\t$this->startHttpMocking();\n\t\tself::$options->set( 'domain', self::TEST_DOMAIN );\n\n\t\t// Mock for a successful API call.\n\t\t$delete_mfa = $this->getStub( true );\n\n\t\t// 1. Make sure that a transport returns the default failed response and logs an error.\n\t\t$this->http_request_type = 'wp_error';\n\t\t$this->assertFalse( $delete_mfa->call( uniqid(), uniqid() ) );\n\t\t$log = self::$error_log->get();\n\t\t$this->assertCount( 1, $log );\n\t\t$this->assertEquals( 'Caught WP_Error.', $log[0]['message'] );\n\n\t\t// 2. Make sure that an Auth0 API error returns the default failed response and logs an error.\n\t\t$this->http_request_type = 'auth0_api_error';\n\t\t$this->assertFalse( $delete_mfa->call( uniqid(), uniqid() ) );\n\t\t$log = self::$error_log->get();\n\t\t$this->assertCount( 2, $log );\n\t\t$this->assertEquals( 'caught_api_error', $log[0]['code'] );\n\n\t\t// 4. Make sure that a weak password error returns the correct message.\n\t\t$this->http_request_type = 'failed_weak_password';\n\t\t$this->assertEquals(\n\t\t\t'Password is too weak, please choose a different one.',\n\t\t\t$delete_mfa->call( uniqid(), uniqid() )\n\t\t);\n\t\t$log = self::$error_log->get();\n\t\t$this->assertCount( 3, $log );\n\t\t$this->assertEquals( '400', $log[0]['code'] );\n\n\t\t// 4. Make sure it succeeds.\n\t\t$this->http_request_type = 'success_empty_body';\n\t\t$this->assertTrue( $delete_mfa->call( uniqid(), uniqid() ) );\n\t\t$this->assertCount( 3, self::$error_log->get() );\n\t}", "title": "" }, { "docid": "6ed1b6cbc04e041199878580b9a2d2a3", "score": "0.58672184", "text": "function curlRequest( $url, $curl_handle, $fail_on_error = false ) {\n global $curl_requests;\n\n if ( $curl_handle === false ) {\n return false;\n }\n if ( $fail_on_error === true ) {\n curl_setopt( $curl_handle, CURLOPT_FAILONERROR, true );\n }\n curl_setopt( $curl_handle, CURLOPT_SSL_VERIFYPEER, false );\n curl_setopt( $curl_handle, CURLOPT_RETURNTRANSFER, true );\n curl_setopt( $curl_handle, CURLOPT_USERAGENT, 'Verus PHP EXT Tools' );\n curl_setopt( $curl_handle, CURLOPT_URL, $url );\n $curl_requests++;\n return curl_exec( $curl_handle );\n}", "title": "" }, { "docid": "ebf8a7edc6295e5c165a7c9ad828b345", "score": "0.5865474", "text": "public function testGetMessageHTTPErrorResponses()\n {\n // Configure HTTP basic authorization: basicAuth\n $config = Configuration::getDefaultConfiguration()\n ->setUsername('YOUR_USERNAME')\n ->setPassword('YOUR_PASSWORD');\n\n $expected_code = 401;\n // Create a mock response\n $expected = null;\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $direction = \"direction_example\";\n $account_uid = \"account_uid_example\";\n $state = \"state_example\";\n $offset = 0;\n $limit = 10;\n\n try {\n $result = $apiInstance->getMessage($direction, $account_uid, $state, $offset, $limit);\n $this->fail(\"No error response when calling MessageApi->getMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 403;\n // Create a mock response\n $expected = new \\Karix\\Model\\UnauthorizedResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $direction = \"direction_example\";\n $account_uid = \"account_uid_example\";\n $state = \"state_example\";\n $offset = 0;\n $limit = 10;\n\n try {\n $result = $apiInstance->getMessage($direction, $account_uid, $state, $offset, $limit);\n $this->fail(\"No error response when calling MessageApi->getMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 500;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $direction = \"direction_example\";\n $account_uid = \"account_uid_example\";\n $state = \"state_example\";\n $offset = 0;\n $limit = 10;\n\n try {\n $result = $apiInstance->getMessage($direction, $account_uid, $state, $offset, $limit);\n $this->fail(\"No error response when calling MessageApi->getMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n }", "title": "" }, { "docid": "fe39a2f207cf8a8aa795554e271cb3be", "score": "0.5856996", "text": "function get_rest_api($api_url = '')\n{\n try {\n // url\n $url = $api_url;\n\n // init\n $curl = curl_init();\n // execute rest\n curl_setopt($curl, CURLOPT_URL, $url);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);\n \n // save data \n $response = curl_exec($curl); \n\n // close connection\n curl_close($curl);\n\n return $response;\n\n } catch (\\Throwable $th) {\n //throw $th;\n }\n}", "title": "" }, { "docid": "d148b178fc22d102f5576ff36d9504f1", "score": "0.58403003", "text": "public function testErrorHandling()\n {\n $framework = $this->getFrameworkForException(new \\RuntimeException());\n\n $response = $framework->handle(new Request());\n\n $this->assertEquals(500, $response->getStatusCode());\n\n }", "title": "" }, { "docid": "4a87f180cf9ec490f77cc25cabda22fc", "score": "0.5838436", "text": "public function testRejectAutomatchUrlUsingGET()\n {\n }", "title": "" }, { "docid": "42f7f6ca43a7278c3cebd7831f7b8c97", "score": "0.5822766", "text": "private function setErrors()\n {\n $this->errors = [\n 'error_no' => curl_errno($this->curl),\n 'error' => curl_error($this->curl),\n ];\n }", "title": "" }, { "docid": "3b43915fdf9171efbd67de0237335201", "score": "0.582092", "text": "private function setUpCurl()\n {\n $this->curl = $this->get('app.curl.connector');\n $this->curl->setEndPointBaseUrl($this->getParameter('themoviedb_endpoint_url'));\n $this->curl->setExtraHeaders([\n CURLOPT_HEADER => false,\n CURLOPT_HTTPHEADER => [\"Accept: application/json\"],\n CURLOPT_SSL_VERIFYPEER => false\n ]);\n }", "title": "" }, { "docid": "b9c0142eabc2bf0080e78b1c1fd11196", "score": "0.5811308", "text": "function curl_require_code($curl, $code = 200) {\n if (curl_code($curl) !== intval($code)) {\n error(curl_url($curl) . ' responded with code ' . curl_code($curl) . ' instead of code ' . spy($code) . '.');\n }\n}", "title": "" }, { "docid": "fd6bead15ba8ed6857ed1efdb122b214", "score": "0.5803771", "text": "public function testScanCatchesBadResponseExceptions()\n {\n $mock = new \\Guzzle\\Plugin\\Mock\\MockPlugin();\n $mock->addResponse(new \\Guzzle\\Http\\Message\\Response(403));\n $this->client->addSubscriber($mock);\n\n $this->setExpectedException(\"\\Metagist\\Api\\Exception\");\n $this->client->scan('test', 'test');\n }", "title": "" }, { "docid": "7bc4970b70ba0c1811fa3379f328fb72", "score": "0.57952535", "text": "public function testCancelConnectionError()\n {\n $guzzleMock = new MockHandler();\n $handlerStack = HandlerStack::create($guzzleMock);\n $client = new Client(['handler' => $handlerStack]);\n $config = new Configuration();\n $config->setApiKey('basic', 'Totally Fake Key');\n $lettersApi = new LettersApi($config, $client);\n\n $guzzleMock->append(new ConnectException(\"Server refused connection\", new Request(\"POST\", \"test\")));\n try {\n $this->expectException(ApiException::class);\n $this->expectExceptionMessageMatches(\"/Server refused connection/\");\n $unhappyPath = $lettersApi->cancel(\"ltr_fakeIdForDel\");\n } catch (Exception $createError) {\n echo 'Caught exception: ', $createError->getMessage(), \"\\n\";\n }\n }", "title": "" }, { "docid": "569bc74d11e958e3e837162ef407f076", "score": "0.5790543", "text": "function callJsonApi($url) {\n $response = callApi($url);\n $jsonResponse = false;\n if ($response === false) {\n echo \"Failed to \".$action.\" : \" . curl_error ( $ch );\n } else {\n $jsonResponse = json_decode ( $response );\n if (! isset ( $jsonResponse->success )) {\n echo \"Failed to $url : $response\";\n } else if (! $jsonResponse->success) {\n echo \"Failed to $url : $jsonResponse->code - $jsonResponse->message\";\n }\n }\n return $jsonResponse;\n}", "title": "" }, { "docid": "39a0593150a718c0106c473444dd4d2f", "score": "0.57819664", "text": "public function testSendMessageErrorResponses()\n {\n // Configure HTTP basic authorization: basicAuth\n $config = Configuration::getDefaultConfiguration()\n ->setUsername('YOUR_USERNAME')\n ->setPassword('YOUR_PASSWORD');\n\n $expected_code = 400;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n try {\n $result = $apiInstance->sendMessage($message);\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 401;\n // Create a mock response\n $expected = null;\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n try {\n $result = $apiInstance->sendMessage($message);\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 402;\n // Create a mock response\n $expected = new \\Karix\\Model\\InsufficientBalanceResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n try {\n $result = $apiInstance->sendMessage($message);\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 403;\n // Create a mock response\n $expected = new \\Karix\\Model\\UnauthorizedResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n try {\n $result = $apiInstance->sendMessage($message);\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 500;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n try {\n $result = $apiInstance->sendMessage($message);\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n }", "title": "" }, { "docid": "0f677692810c83573bf9bad6b65c504a", "score": "0.57783806", "text": "private function curl($url, &$response, &$error)\n\t{\n\t\t$handler = curl_init();\n\t\tcurl_setopt($handler, CURLOPT_URL, $url);\n\t\tcurl_setopt($handler, CURLOPT_RETURNTRANSFER, true);\n\t\t$response = curl_exec($handler);\n\t\t$error = curl_errno($handler);\n\t\tcurl_close($handler);\n\t}", "title": "" }, { "docid": "17c8ab93d85b1cb9bdaac4e162939047", "score": "0.57759434", "text": "public function testIndexActionError() : void\n {\n $res = $this->controller->indexActionPost();\n $this->assertInternalType(\"array\", $res);\n\n list($json, $status) = $res;\n $this->assertEquals($json[\"message\"], \"Ingen IP address skickades.\");\n $this->assertEquals($status, 400);\n }", "title": "" }, { "docid": "11ebb603d9c45821824b4faef7b928d3", "score": "0.5764642", "text": "public function test_get_errors_if_category_not_exist()\n {\n $data = [\n 'category_id' => 10,\n 'name' => 'Test_item',\n 'value' => 50,\n 'quality' => -10,\n ];\n\n $response = $this->json('POST', '/api/items/', $data);\n\n $response->assertStatus(404);\n\n $response->assertSee('errors');\n }", "title": "" }, { "docid": "461605aab6d8c2e750ad26b0178dad78", "score": "0.5761435", "text": "public function testGetMessageByIdHTTPErrorResponses()\n {\n // Configure HTTP basic authorization: basicAuth\n $config = Configuration::getDefaultConfiguration()\n ->setUsername('YOUR_USERNAME')\n ->setPassword('YOUR_PASSWORD');\n\n $expected_code = 401;\n // Create a mock response\n $expected = null;\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $uid = \"uid_example\";\n\n try {\n $result = $apiInstance->getMessageById($uid);\n $this->fail(\"No error response when calling MessageApi->getMessageById when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 403;\n // Create a mock response\n $expected = new \\Karix\\Model\\UnauthorizedResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $uid = \"uid_example\";\n\n try {\n $result = $apiInstance->getMessageById($uid);\n $this->fail(\"No error response when calling MessageApi->getMessageById when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 404;\n // Create a mock response\n $expected = new \\Karix\\Model\\NotFoundResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $uid = \"uid_example\";\n\n try {\n $result = $apiInstance->getMessageById($uid);\n $this->fail(\"No error response when calling MessageApi->getMessageById when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 500;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $uid = \"uid_example\";\n\n try {\n $result = $apiInstance->getMessageById($uid);\n $this->fail(\"No error response when calling MessageApi->getMessageById when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n }", "title": "" }, { "docid": "82ac2fdaa09bce4363e06a5bcb1b762e", "score": "0.5746071", "text": "public function testRetrieveUnsuccessfulReason()\n {\n }", "title": "" }, { "docid": "5791716fe64849c209ac8e3dcdb98270", "score": "0.5737093", "text": "private function __runRequest($ch)\n {\n $data = curl_exec($ch);\n $ch_info = curl_getinfo($ch);\n if ($data === false) {\n throw new \\Exception(curl_error($ch));\n } elseif ($ch_info['http_code'] != 200) {\n throw new \\Exception('Unexpected HTTP status code ' . $ch_info['http_code'] . '.' . curl_error($ch));\n }\n curl_close($ch);\n return json_decode($data);\n }", "title": "" }, { "docid": "69116ec94811a9f082edb410a539dc47", "score": "0.5731162", "text": "public function test_receive_throwsBadResponseStatus_ifBadStatus()\n\t{\n\t\t$this->setExpectedException('Jstewmc\\\\Api\\\\Exception\\\\BadResponseStatus');\n\t\t\n\t\t$this->url->getQuery()->setParameter('code', 301);\n\t\t\n\t\t(new Client())\n\t\t\t->send(new Request\\Get((string) $this->url))\n\t\t\t->receive(new Response\\Json());\n\t\t\n\t\treturn;\n\t}", "title": "" }, { "docid": "c3ae8e90db23d3704623a96fa731def9", "score": "0.5721909", "text": "public function testGetMultiFail() : void\n {\n $fetch = new MockFetch();\n $this->expectException(\\Exception::class);\n\n $fetch->getMulti([\n \"url\" => \"\",\n ]);\n }", "title": "" }, { "docid": "fa34b4fa891fe3aec3989559f65ecaec", "score": "0.5719654", "text": "public function test_send_returnsSelf_ifFormatIsBad()\n\t{\n\t\t$this->url\n\t\t\t->getQuery()\n\t\t\t\t->setParameter('code', 200)\n\t\t\t\t->setParameter('format', 'json')\n\t\t\t\t->setParameter('output', '{foo:}');\n\t\t\n\t\t$request = new Request\\Get((string) $this->url);\n\t\t\n\t\t$client = new Client();\n\t\t\n\t\t$this->assertSame($client, $client->send($request));\n\t\t\n\t\treturn;\n\t}", "title": "" }, { "docid": "f4e5ebd64386bd16de27d878175e3790", "score": "0.5716875", "text": "public function testHandleIsNotACurlResource(): void\n {\n $request = $this->createMock(RequestInterface::class);\n $responseBuilder = $this->createMock(ResponseBuilder::class);\n\n $this->expectException(\\InvalidArgumentException::class);\n if (PHP_MAJOR_VERSION > 7) {\n $this->expectExceptionMessage('Parameter $handle expected to be a cURL resource, resource (stream) given');\n } else {\n $this->expectExceptionMessage('Parameter $handle expected to be a cURL resource, stream resource given');\n }\n\n new PromiseCore($request, fopen('php://memory', 'r+b'), $responseBuilder);\n }", "title": "" }, { "docid": "59267978036217ecab2bb34374211eee", "score": "0.571651", "text": "public function testMoviesSearchBadRequest()\n {\n $url=$this->testSystemUrl.'movies';\n $curl=$this->curl($url,true);\n $this->assertEquals(400, $curl['httpcode']);\n }", "title": "" }, { "docid": "1d70d5d3016ed7efb09bb65f2cc3d51c", "score": "0.57155395", "text": "function api_test_curl()\r\n\t{\r\n\t\techo \"true\";\r\n\t}", "title": "" }, { "docid": "d5a45076b0ae772377009a87b3ffe9f1", "score": "0.5706673", "text": "public function testIndexActionFail() : void\n {\n $this->di->request->setPost(\"ip\", \"1200:0000:AB00:1234:O000:2552:7777:1313\");\n\n $res = $this->controller->indexActionPost();\n $this->assertInternalType(\"array\", $res);\n\n list($json, $status) = $res;\n $this->assertEquals($json[\"valid\"], false);\n $this->assertEquals($status, 200);\n }", "title": "" }, { "docid": "412b0d8a670f9c60560abaeaff569eb5", "score": "0.5704056", "text": "function doCurl ($url, $options) {\n\tglobal $adminName, $adminPass, $verbose, $doe;\n\t\n\t$options = $options +\n\t\t\t array(CURLOPT_RETURNTRANSFER => true,\n\t\t\t\t\t CURLOPT_USERPWD => $adminName . \":\" . $adminPass,\n\t\t\t\t\t CURLOPT_HTTPHEADER => array('OCS-APIRequest:true', 'Accept: application/json'),\n\t\t\t );\n\n\tif ($verbose > 2) {\n\t\t$options = $options +\n\t\t\t\t array(CURLOPT_VERBOSE => TRUE,\n\t\t\t\t\t\t CURLOPT_HEADER => TRUE\n\t\t\t\t );\n\t}\n\n\t$ch = curl_init($url);\n\n \tcurl_setopt_array( $ch, $options);\n\t\n// For use with Charles proxy:\n// \tcurl_setopt($ch, CURLOPT_PROXYPORT, '8888');\n// \tcurl_setopt($ch, CURLOPT_PROXYTYPE, 'HTTP');\n// \tcurl_setopt($ch, CURLOPT_PROXY, '127.0.0.1');\n\n $response = curl_exec($ch);\n //print_r($response);\n $response = json_decode($response);\n //print_r($response);\n\n $statuscode = $response->{'ocs'}->{'meta'}->statuscode;\n\n \n if($statuscode != \"100\"){\n echo $statuscode;\n echo $response->{'ocs'}->{'meta'}->message;\n return $statuscode;\n exit(1);\n }\n\n if($response === false) {\n echo 'Curl error: ' . curl_error($ch) . \"\\n\";\n\t\texit(1);\n\t}\n\t\n\tcurl_close($ch);\n \n\t/* An error causes an exit\n\tif (preg_match(\"~<statuscode>(\\d+)</statuscode>~\", $response, $matches)) {\n $responseCode = $matches[1]; // what's the status code\n //echo $matches[3];\n //echo \"<h3>\" . $response . \"</h3>\";\n if ($responseCode == '404') {\n return \"2\";\n exit(2);\n } elseif ($responseCode != '100') {\n echo \"1Error response code; exiting\\n$response\\n\";\n\t\t\texit(1);\n\t\t}\n\t}\n\telse { // something is definitely wrong\n echo \"No statuscode response; exiting:\\n$response\\n\";\n \n\t\texit(1);\n\t}\n */\n\t// What sort of response do we want to give\n//\tif ($verbose == 1) { echo \"Response code from server: $responseCode\\n\"; }\n\t//if ($verbose == 1) { echo \"\\n\"; }\n\t//if ($verbose > 1) { echo \"Response from server:\\n$response\\n\\n\"; }\n\n\treturn $response;\n}", "title": "" }, { "docid": "8dd2d1b47cf28c83da58b62535b7f260", "score": "0.5697433", "text": "function curl_check($url) {\n\n\t$ch = curl_init($url);\n\tcurl_setopt($ch, CURLOPT_NOBODY, true);\n\n\t$response = curl_exec($ch);\n\tLOG_MSG('INFO',\"curl_get(): [$url] response=[$response]\");\n\n\treturn curl_getinfo($ch, CURLINFO_HTTP_CODE);\n}", "title": "" }, { "docid": "6e5148055ad89bfbf606cbab5ea3b6df", "score": "0.569659", "text": "public function error(): string{\n return curl_error($this->handler);\n }", "title": "" }, { "docid": "519d5bf07e0404efa78e40b8f88e3328", "score": "0.56939393", "text": "public function error()\n {\n return curl_error($this->curl);\n }", "title": "" }, { "docid": "519d5bf07e0404efa78e40b8f88e3328", "score": "0.56939393", "text": "public function error()\n {\n return curl_error($this->curl);\n }", "title": "" }, { "docid": "280bc3de2a91e7b1abaa6404afca291f", "score": "0.56887496", "text": "public function testInstantiation()\n {\n $curlAdapter = new CurlAdapter();\n }", "title": "" }, { "docid": "3a11acf794ea0e15326d2986f705a390", "score": "0.568435", "text": "function validateCurl(){\n\t// Before anything else, check if we have php-curl is installed\n\tif (!function_exists('curl_init')) {\n\t\terror_log(\"Kindly install/enable php-curl module and try again. This standard module allows the webserver to communicate with the EMS.\");\n\t\texit();\n\t}\n}", "title": "" }, { "docid": "885e95e60e5c70390bd80d4df7a96438", "score": "0.5680389", "text": "public function error()\n {\n return curl_error($this->_session);\n }", "title": "" }, { "docid": "424bec7585e3330456f6b178f546b80c", "score": "0.5661535", "text": "public function testExpandThrowsExceptionIfApiResponseHasNoStatusCode()\n {\n $provider = new BitlyProvider($this->getMockClientFactory($this->getMockResponseAsInvalidObject()), $this->getMockAuthentication());\n $provider->expand($this->getBaseMockLink());\n }", "title": "" }, { "docid": "e8a07cf0c11daea31dec80708175e4ba", "score": "0.56512904", "text": "public function testGetMessageErrorResponses()\n {\n // Configure HTTP basic authorization: basicAuth\n $config = Configuration::getDefaultConfiguration()\n ->setUsername('YOUR_USERNAME')\n ->setPassword('YOUR_PASSWORD');\n\n $expected_code = 401;\n // Create a mock response\n $expected = null;\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $direction = \"direction_example\";\n $account_uid = \"account_uid_example\";\n $state = \"state_example\";\n $offset = 0;\n $limit = 10;\n\n try {\n $result = $apiInstance->getMessage($direction, $account_uid, $state, $offset, $limit);\n $this->fail(\"No error response when calling MessageApi->getMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 403;\n // Create a mock response\n $expected = new \\Karix\\Model\\UnauthorizedResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $direction = \"direction_example\";\n $account_uid = \"account_uid_example\";\n $state = \"state_example\";\n $offset = 0;\n $limit = 10;\n\n try {\n $result = $apiInstance->getMessage($direction, $account_uid, $state, $offset, $limit);\n $this->fail(\"No error response when calling MessageApi->getMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n $expected_code = 500;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $direction = \"direction_example\";\n $account_uid = \"account_uid_example\";\n $state = \"state_example\";\n $offset = 0;\n $limit = 10;\n\n try {\n $result = $apiInstance->getMessage($direction, $account_uid, $state, $offset, $limit);\n $this->fail(\"No error response when calling MessageApi->getMessage when mocked to return error\");\n } catch (ApiException $e) {\n $this->assertEquals($expected_code, $e->getCode());\n $this->assertEquals($expected, $e->getResponseObject());\n }\n }", "title": "" }, { "docid": "9eff66537ee7ce345a9b55da30c52617", "score": "0.5646157", "text": "public function testCurlGoodUrl()\n {\n $curl = new CurlClass();\n \n $res = $curl->submit('http://feeds.nationalgeographic.com/ng/News/News_Main');\n $this->assertTrue($res, 'test url ktory zwraca kod 200');\n }", "title": "" }, { "docid": "610fe74021a01bf25a9467614f2c0837", "score": "0.5645871", "text": "public function testInvalidJsonProcessing()\n {\n $mock = new MockHandler(\n [\n new Response(200, [], '{\"malformedJSON\":[]]}'),\n ]\n );\n $handler = HandlerStack::create($mock);\n $client = new Client(['handler' => $handler]);\n\n // We want a proper exception, not a fatal error nor a silent fail.\n $this->expectException(JsonDecodingError::class);\n (new TestService(new ApiClient($client)))->getTest();\n }", "title": "" }, { "docid": "e4cc130897f23f1161d2af5e7d2cb435", "score": "0.564148", "text": "protected function _checkCurlError($item)\n {\n $curlError = $this->_client->getCurlError();\n if ($curlError) {\n $item->setMessage($curlError)\n ->setImportStatus(Dotdigitalgroup_Email_Model_Importer::FAILED)\n ->save();\n\n return true;\n }\n return false;\n }", "title": "" }, { "docid": "4ccab8d68cad9c788f1a81210080eaf9", "score": "0.5641252", "text": "function test_request_is_wp_error() {\n\t\t$this->api->token = '';\n\t\t$this->assertInstanceOf( 'WP_Error', $this->api->request( 'https://api.envato.com/v1/market/total-items.json' ) );\n\n\t\t$this->api->token = '12345';\n\t\t$this->assertInstanceOf( 'WP_Error', $this->api->request( 'https://api.envato.com/v1/market/total-items.json' ) );\n\t}", "title": "" }, { "docid": "5f53ab1b738598e28827c6010a183960", "score": "0.56275547", "text": "public function testInvalidConnect(): void\n {\n // setup\n $data = $this->getUserData();\n $data['password'] = '1234';\n $url = self::$serverPath . '/connect/';\n\n // test body\n $result = $this->postHttpRequest($data, $url);\n\n // assertions\n $this->assertTrue(isset($result->message));\n $this->assertTrue(isset($result->code));\n $this->assertTrue($result->code == - 1 || $result->code == 4);\n }", "title": "" }, { "docid": "17e2a5a3a5353823985c656029ac2524", "score": "0.56173253", "text": "function curl_query($curl) {\n $response = curl_exec($curl);\n\n if (!is_string($response)) {\n error('Failed to execute cURL query for ' . spy($curl) . '.');\n }\n\n return $response;\n}", "title": "" }, { "docid": "8ea190132538c6f67701fcf2998f9580", "score": "0.5612461", "text": "public function testShortenThrowsExceptionIfApiResponseHasNoStatusCode()\n {\n $provider = new BitlyProvider($this->getMockClientFactory($this->getMockResponseAsInvalidObject()), $this->getMockAuthentication());\n $provider->shorten($this->getBaseMockLink());\n }", "title": "" }, { "docid": "8a06910bf85e8e88a2fbc8f5a801f484", "score": "0.5607497", "text": "public static function curlGetWithErros($url)\n {\n $ch = curl_init();\n\n curl_setopt($ch,CURLOPT_URL,$url);\n curl_setopt($ch,CURLOPT_RETURNTRANSFER,true);\n\n $output=curl_exec($ch);\n\n if($output === false)\n {\n echo \"Error Number:\".curl_errno($ch).\"<br>\";\n echo \"Error String:\".curl_error($ch);\n }\n curl_close($ch);\n return $output;\n }", "title": "" }, { "docid": "0308957ab3bf04bbc3ee5080b5243525", "score": "0.5605443", "text": "function testInvalidGet() {\n $this->get('/something/def');\n $this->assertEqual(api_response::getInstance()->getCode(), 404);\n $this->assertText('/error/code', '100');\n $this->assertText('/error/msg', 'Bucket not defined: something');\n }", "title": "" }, { "docid": "d14b59a4484869c3e1a04a41c979c941", "score": "0.55893105", "text": "public function curl_post($url, array $post = NULL, array $options = array()){\n\n try{\n\n $defaults = array(\n CURLOPT_POST => 1,\n CURLOPT_HEADER => 0,\n CURLOPT_URL => $url,\n CURLOPT_FRESH_CONNECT => 1,\n CURLOPT_RETURNTRANSFER => true,\n CURLOPT_FORBID_REUSE => 1,\n CURLOPT_TIMEOUT => 25,\n CURLOPT_CONNECTTIMEOUT => 25,\n CURLOPT_POSTFIELDS => http_build_query($post)\n );\n\n /*\n If you are doing a POST, and the content length is 1,025 or greater, then curl exploits\n a feature of http 1.1: 100 (Continue) Status.\n\n See http://www.w3.org/Protocols/rfc2616/rfc2616-sec8.html#sec8.2.3\n\n * it adds a header, \"Expect: 100-continue\".\n * it then sends the request head, waits for a 100 response code, then sends the content\n\n Not all web servers support this though. Various errors are returned depending on the\n server. If this happens to you, suppress the \"Expect\" header with this command:\n\n curl_setopt($ch, CURLOPT_HTTPHEADER, array('Expect:'));\n */\n\n $ch = curl_init();\n curl_setopt_array($ch, ($options + $defaults));\n curl_setopt($ch, CURLOPT_HTTPHEADER, array('Expect:'));\n if(!$result = curl_exec($ch)) {\n\n //\n // HOOOSTON...VE HAF PROBLEM!\n throw new Exception('CRNRSTN :: CURL [POST] ERROR experienced :: '.curl_error($ch));\n\n }\n\n curl_close($ch);\n\n return $result;\n\n } catch (Exception $e) {\n\n curl_close($ch);\n\n $this->catchException($e, LOG_ERR, __METHOD__, __NAMESPACE__);\n\n return false;\n\n }\n\n }", "title": "" }, { "docid": "ecefefec73d12c625cc969d414c000f4", "score": "0.5588749", "text": "public function testOpen()\n {\n $this->curlAdapter->open();\n \n $this->assertAttributeInternalType('resource', 'curl', $this->curlAdapter);\n }", "title": "" }, { "docid": "c13884c625eb3d59f1c4ae01321f8f2b", "score": "0.5585101", "text": "public function test_send_returnsSelf_ifStatusIsBad()\n\t{\n\t\t$this->url->getQuery()->setParameter('code', 301);\n\t\t\n\t\t$request = new Request\\Get((string) $this->url);\n\t\t\n\t\t$client = new Client();\n\t\t\n\t\t$this->assertSame($client, $client->send($request));\n\t\t\n\t\treturn;\n\t}", "title": "" }, { "docid": "a9faaebe6f7b9247de99f7b8ec347513", "score": "0.55795234", "text": "protected function checkCurlResult($code)\n {\n if ($code != CURLM_OK && $code != CURLM_CALL_MULTI_PERFORM) {\n throw new CurlException(isset($this->multiErrors[$code])\n ? \"cURL error: {$code} ({$this->multiErrors[$code][0]}): cURL message: {$this->multiErrors[$code][1]}\"\n : 'Unexpected cURL error: ' . $code\n );\n }\n }", "title": "" }, { "docid": "a00f8afe028179708b3b795f3061b753", "score": "0.557568", "text": "public function testSendMessageHTTPErrorResponsesAsync()\n {\n // Configure HTTP basic authorization: basicAuth\n $config = Configuration::getDefaultConfiguration()\n ->setUsername('YOUR_USERNAME')\n ->setPassword('YOUR_PASSWORD');\n\n $expected_code = 400;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n $promise = $apiInstance->sendMessageAsync($message)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n $expected_code = 401;\n // Create a mock response\n $expected = null;\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n $promise = $apiInstance->sendMessageAsync($message)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n $expected_code = 402;\n // Create a mock response\n $expected = new \\Karix\\Model\\InsufficientBalanceResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n $promise = $apiInstance->sendMessageAsync($message)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n $expected_code = 403;\n // Create a mock response\n $expected = new \\Karix\\Model\\UnauthorizedResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n $promise = $apiInstance->sendMessageAsync($message)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n $expected_code = 500;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n $promise = $apiInstance->sendMessageAsync($message)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n }", "title": "" }, { "docid": "569303a2fe71a7d356e24e87090bc076", "score": "0.55677813", "text": "public function test_IndexError(){\n\t\t$this->validateTestException(\n\t\t\t$this->fullURL,\n\t\t\t'GET',\n\t\t\t$this->data,\n\t\t\t'NotImplementedException',\n\t\t\t'index'\n\t\t);\n\t}", "title": "" }, { "docid": "13b89a666dcfd5ce4958e3dd6d065c1e", "score": "0.55656135", "text": "public function testLinguaLeoApiExceptionThrowsInCaseOfInvalidJSONInGetResponse()\n {\n $method = $this->getReflectedMethod('getResponse');\n $stub = $this->getMockedObject(['getContentByUrl']);\n\n //Try to convert not valid JSON must throw LinguaLeoApiException\n $stub->method('getContentByUrl')\n ->willReturn('[{test1\": \"1\",\"test2\": \"2\"}]');\n\n $method->invoke($stub, 'test.cc');\n }", "title": "" }, { "docid": "9af32613eb107bdafc8b2b84283bbc6a", "score": "0.5561811", "text": "public function testRetrieveListUnsuccessfulReason()\n {\n }", "title": "" }, { "docid": "4485e50f83983cc83bd41c81ee9099de", "score": "0.55564773", "text": "public function handleFailure($response) {\n }", "title": "" }, { "docid": "e5754af93380b20a9c44223f2dcdacab", "score": "0.55513996", "text": "public function test_https_status()\n {\n }", "title": "" }, { "docid": "1450598696cdf9ab2548e39db5b1bd73", "score": "0.5548247", "text": "public function testErrorIsThrownIfURLIsInvalid()\n {\n self::$importer->get('invalid-google-url', now()->subYear(), now()->addYear());\n }", "title": "" }, { "docid": "6e9d67f187f2603a19199287243f0751", "score": "0.5544774", "text": "protected function setOptions($curl)\n {\n if(!curl_setopt($curl, CURLOPT_POST, $this->options->post))\n {\n throw new Exception('Could not set option [post]');\n }\n \n if(!curl_setopt($curl, CURLOPT_HEADER, $this->options->header))\n {\n throw new Exception('Could not set option [header]');\n }\n \n if(!curl_setopt($curl, CURLOPT_RETURNTRANSFER, $this->options->returnTransfer))\n {\n throw new Exception('Could not set option [return transfer]');\n }\n }", "title": "" }, { "docid": "917edbdea8120845ba351e5d3fde7dd3", "score": "0.5540269", "text": "public function testFailedSend()\n {\n $gateway = $this->app[CoinmarketcapGateway::class];\n $response = $gateway->send('/v1/cryptocurrency/info');\n $this->assertIsString($response);\n $response = json_decode($response, true);\n $this->assertGreaterThan(0, array_get($response, 'status.error_code'));\n }", "title": "" }, { "docid": "fa4b5521630cfb36a8667bb5d8d45181", "score": "0.5536718", "text": "function basicCurl($curlURL) {\n $url = $curlURL;\n $cURL = curl_init();\n curl_setopt($cURL, CURLOPT_URL, $url);\n curl_setopt($cURL, CURLOPT_HTTPGET, true);\n curl_setopt($cURL, CURLOPT_HTTPHEADER, array(\n 'Content-Type: application/json',\n 'Accept: application/json'\n ));\n curl_setopt($cURL, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($cURL, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($cURL, CURLOPT_USERAGENT, \"spider\");\n $result = curl_exec($cURL);\n \nif ($result === FALSE) {\n return \"cURL Error: \" . curl_error($cURL);\n} else {\n\treturn $result;\n}\n curl_close($cURL);\n \n}", "title": "" }, { "docid": "903bff5dc650b53f2bc556bdbd196fdd", "score": "0.5526509", "text": "public function test_actionAssetError()\n {\n $expected_output = \"HTTP/1.1 424 \\n\" .\n \"Content-type: application/json\\n\" .\n '{\"errors\":{\"general\":[\"Please send a valid GET. Include type, uploaded_name or is_used\"]}}';\n\n $this->assertControllerResponse('actionAsset', '/query/asset/', $expected_output);\n }", "title": "" }, { "docid": "51a3494d88d0bf8e270a1b7b16f52bc0", "score": "0.5523018", "text": "public function test_actionIndexError()\n {\n $expected_output = \"HTTP/1.1 424 \\n\" .\n \"Content-type: application/json\\n\" .\n '{\"errors\":{\"general\":[\"Not a proper http method type, please send a FILE\"]}}';\n\n $this->assertControllerResponse('actionIndex', '/create/', $expected_output);\n }", "title": "" }, { "docid": "7288a34874277416e672b78dc6654af2", "score": "0.5517061", "text": "public function testUpdateConnectionError()\n {\n $guzzleMock = new MockHandler();\n $handlerStack = HandlerStack::create($guzzleMock);\n $client = new Client(['handler' => $handlerStack]);\n $config = new Configuration();\n $config->setApiKey('basic', 'Totally Fake Key');\n $cardsApi = new CardsApi($config, $client);\n\n $guzzleMock->append(new ConnectException(\"Server refused connection\", new Request(\"POST\", \"test\")));\n try {\n $this->expectException(ApiException::class);\n $this->expectExceptionMessageMatches(\"/Server refused connection/\");\n $unhappyPath = $cardsApi->update(self::$mockCardId, self::$mockUpdatableCard);\n } catch (Exception $createError) {\n echo 'Caught exception: ', $createError->getMessage(), \"\\n\";\n }\n }", "title": "" }, { "docid": "16252bdf978e3b96c3d97e5a98114d06", "score": "0.550951", "text": "public function testDelete_Error()\r\n\t{\r\n\t\t$this->http = new Client(['base_uri' => 'http://localhost/casecheckapp/public/index.php/']);\r\n\t\t\r\n\t\t$response = $this->http->delete('/api/v1/hospital/5', [ //Change ID here to a Hospital that isn't in the datastore'\r\n\t\t\t'http_errors' => false\r\n\t\t]);\r\n\t\r\n\t\t//Test invalid requests\r\n\t\t$this->assertEquals(405, $response->getStatusCode());\r\n\r\n\t\t//Stopping the connexion with Guzzle\r\n\t\t$this->http = null;\r\n\t\t\r\n\t}", "title": "" }, { "docid": "5b783cac7446b04270dd966100a0ce47", "score": "0.55049574", "text": "public function testDispatchErrorMissingArg()\n {\n $this->expectException(ResourceNotFoundException::class);\n\n $this->uut->dispatch($this->buildRequest('/missing-arg'));\n }", "title": "" }, { "docid": "75280e4331374ff97aac3c062dd6fba7", "score": "0.5503971", "text": "public function testItThrowsException()\n {\n $location = \"00000,us\";\n $response = $this->api->send_request($location); \n }", "title": "" }, { "docid": "3bbc4bc3a1fb533b218792ba1dce12ad", "score": "0.5501449", "text": "public function error() {\n // The tests cover errors, so there will be plenty to sift through\n // $msg = func_get_arg(0);\n // $err = 'API ERROR: ' . $msg . PHP_EOL;\n\n // $objs = func_get_args();\n // array_splice($objs, 0, 1);\n\n // ob_start();\n // foreach($objs as $obj) {\n // var_dump($obj);\n // }\n // $strings = ob_get_clean();\n\n // file_put_contents('tests.log', [$err, $strings], FILE_APPEND);\n }", "title": "" }, { "docid": "eebe3b456c5e6e756a8ffacff6f635db", "score": "0.55011314", "text": "public function testSendMessageErrorResponsesAsync()\n {\n // Configure HTTP basic authorization: basicAuth\n $config = Configuration::getDefaultConfiguration()\n ->setUsername('YOUR_USERNAME')\n ->setPassword('YOUR_PASSWORD');\n\n $expected_code = 400;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n $promise = $apiInstance->sendMessageAsync($message)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n $expected_code = 401;\n // Create a mock response\n $expected = null;\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n $promise = $apiInstance->sendMessageAsync($message)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n $expected_code = 402;\n // Create a mock response\n $expected = new \\Karix\\Model\\InsufficientBalanceResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n $promise = $apiInstance->sendMessageAsync($message)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n $expected_code = 403;\n // Create a mock response\n $expected = new \\Karix\\Model\\UnauthorizedResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n $promise = $apiInstance->sendMessageAsync($message)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n $expected_code = 500;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler, 'http_errors' => false]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $message = new \\Karix\\Model\\CreateMessage();\n\n $promise = $apiInstance->sendMessageAsync($message)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->sendMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n }", "title": "" }, { "docid": "2cb5b7346fd666c454b0937bf92f50e7", "score": "0.5487436", "text": "public function test_receive_throwsBadResponseFormat_ifBadFormat()\n\t{\n\t\t$this->setExpectedException('Jstewmc\\\\Api\\\\Exception\\\\BadResponseFormat');\n\t\t\n\t\t$this->url\n\t\t\t->getQuery()\n\t\t\t\t->setParameter('code', 200)\n\t\t\t\t->setParameter('format', 'json')\n\t\t\t\t->setParameter('output', '{\"foo\":}');\n\t\t\n\t\t(new Client())\n\t\t\t->send(new Request\\Get((string) $this->url))\n\t\t\t->receive(new Response\\Json());\n\t\t\n\t\treturn;\n\t}", "title": "" }, { "docid": "71e450da7be5eee617d693f8e7931f96", "score": "0.5481066", "text": "public function testWhenEndpointsOwnErrorHandlerThrows(): void\n {\n $execute = new Exception('Execute error');\n $error = new Exception('Exception handler error');\n $endpoint = new fixtures\\ErrorHandlingEndpoint(\n function () use ($execute) {\n throw $execute;\n },\n function ($caught) use ($execute, $error) {\n $this->assertSame($execute, $caught);\n throw $error;\n },\n );\n\n $req = $this->getMockRequestWithUriPath('/cb', 'GET');\n $list = [\n HTTPMethod::GET => [\n '/cb' => 'CBClass',\n ],\n ];\n try {\n $ret = (new Dispatcher())\n ->setContainer($this->getMockContainer(['CBClass' => $endpoint]))\n ->setEndpointList($list)\n ->dispatch($req);\n $this->fail(\n \"The exception thrown from the error handler's failure should \".\n \"have made it through\"\n );\n } catch (Throwable $e) {\n $this->assertSame(\n $error,\n $e,\n \"Some exception other than the one from the exception handler \".\n \"was thrown\"\n );\n }\n }", "title": "" }, { "docid": "85f71deb45b93b3e93262dca1099f397", "score": "0.54766154", "text": "private function _executeFcCurl($remote_uri)\n {\n /**\n * Create curl resource handler\n * @var resource\n */\n\n $ch = curl_init();\n /**\n * TRUE to fail silently if the HTTP code returned is greater than or equal to 400.\n * The default behavior is to return the page normally, ignoring the code.\n */\n curl_setopt($ch, CURLOPT_FAILONERROR, 0);\n\n /**\n * set the URL to fetch.\n * This can also be set when initializing a session with curl_init().\n */\n curl_setopt($ch, CURLOPT_URL, $remote_uri);\n\n /**\n * TRUE to return the transfer as a string of the return value\n * of curl_exec() instead of outputting it out directly.\n */\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\n /**\n * Assign the curl_exec() output string to $remote_string\n * @var mixed\n */\n $remoteString = curl_exec($ch);\n\n /**\n * Handle exeptions\n */\n if(!$remoteString)\n {\n\n throw new Exception(\"HTTP code returned is greater than or equal to 400\");\n }else\n {\n $remoteString2Json = json_decode($remoteString);\n if(function_exists('json_last_error'))\n {\n switch(json_last_error()):\n case JSON_ERROR_DEPTH:\n throw new Exception(\"JSON_ERROR_DEPTH - Maximum stack depth exceeded <br>########{$remoteString }########\");\n break;\n case JSON_ERROR_CTRL_CHAR:\n throw new Exception(\"JSON_ERROR_CTRL_CHAR - Unexpected control character found <br>########{$remoteString }########\");\n break;\n case JSON_ERROR_SYNTAX:\n throw new Exception(\"JSON_ERROR_SYNTAX - Syntax error, malformed JSON <br>########{$remoteString }########\");\n break;\n /* IMPLEMENT THIS ON PHP 5.3.1 servers\n case JSON_ERROR_UTF8:\n throw new Exception(\"Malformed UTF-8 characters, possibly incorrectly encoded\");\n break;\n */\n case JSON_ERROR_NONE:\n return $this->_handleLoginErrors($remoteString2Json);\n break;\n endswitch;\n }else\n {\n return $this->_handleLoginErrors($remoteString2Json);\n }\n }\n /**\n * Close curl resource to free up system resources\n */\n curl_close($ch);\n }", "title": "" }, { "docid": "6791a52ad9343b6e4534662064b23057", "score": "0.54725385", "text": "public function testInvalidDelete() {\n\t\t$response =$this->guzzle->delete('http://bootcamp-coders.cnm.edu/~cberaun2/bread-basket/public_html/php/api/message/' . BreadBasketTest::INVALID_KEY, ['headers' => ['XRSF-TOKEN' => $this->token]]);\n\n\t\t//make sure the request returns the proper error code for the failed operation\n\t\t$body =$response->getBody();\n\t\t$retrievedMess = json_encode($body);\n\t\t$this->assertSame(404, $retrievedMess->status);\n\t}", "title": "" }, { "docid": "88be61f05fdeddac71f05c1e04caa7d9", "score": "0.54704124", "text": "public function testItWorksWithError()\n {\n // It allows us to stay in sync with T.io while being compatible with previous PHP-VCR tests\n // ---\n // If one day gettext/languages is updated, please use another more stable language than French\n // and edit the plural rules in the pre-recorded PHP-VCR YAML files so that both regular composer\n // and `--prefer-lowest` pass\n app()['config']->set('translation.target_locales', ['fr-BE']);\n app()['config']->set('translation.key', 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa');\n app()['config']->set('translation.gettext_parse_paths', ['tests/fixtures/gettext']);\n\n $this->addTranslationFixture('fr-BE', [], 'auth', [\n 'fields' => [\n 'first_name' => 'Prénom'\n ]\n ]);\n\n $this->cassette('integration/init_with_bad_api_key.yml');\n\n try {\n $this->artisan('translation:init');\n }\n catch(\\Throwable $e) {\n $this->assertEquals(\"Could not find any *active* project with this API key.\", $e->getMessage());\n }\n }", "title": "" }, { "docid": "658432102546d566176adfd409eefcc2", "score": "0.54636234", "text": "public function testGetMessageHTTPErrorResponsesAsync()\n {\n // Configure HTTP basic authorization: basicAuth\n $config = Configuration::getDefaultConfiguration()\n ->setUsername('YOUR_USERNAME')\n ->setPassword('YOUR_PASSWORD');\n\n $expected_code = 401;\n // Create a mock response\n $expected = null;\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $direction = \"direction_example\";\n $account_uid = \"account_uid_example\";\n $state = \"state_example\";\n $offset = 0;\n $limit = 10;\n\n $promise = $apiInstance->getMessageAsync($direction, $account_uid, $state, $offset, $limit)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->getMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n $expected_code = 403;\n // Create a mock response\n $expected = new \\Karix\\Model\\UnauthorizedResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $direction = \"direction_example\";\n $account_uid = \"account_uid_example\";\n $state = \"state_example\";\n $offset = 0;\n $limit = 10;\n\n $promise = $apiInstance->getMessageAsync($direction, $account_uid, $state, $offset, $limit)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->getMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n $expected_code = 500;\n // Create a mock response\n $expected = new \\Karix\\Model\\ErrorResponse();\n // Create a mock handler\n $mock = new \\GuzzleHttp\\Handler\\MockHandler([\n new \\GuzzleHttp\\Psr7\\Response($expected_code, [], $expected),\n ]);\n $handler = \\GuzzleHttp\\HandlerStack::create($mock);\n $client = new \\GuzzleHttp\\Client(['handler' => $handler]);\n\n $apiInstance = new Api\\MessageApi(\n $client,\n $config\n );\n $direction = \"direction_example\";\n $account_uid = \"account_uid_example\";\n $state = \"state_example\";\n $offset = 0;\n $limit = 10;\n\n $promise = $apiInstance->getMessageAsync($direction, $account_uid, $state, $offset, $limit)->then(function ($result) {\n $this->fail(\"No error response when calling MessageApi->getMessage when mocked to return error\");\n }, function ($exception) use(&$expected_code, &$expected) {\n $this->assertEquals($expected_code, $exception->getCode());\n $this->assertEquals($expected, $exception->getResponseObject());\n });\n $promise->wait();\n }", "title": "" }, { "docid": "89815159ee3bc5bcd7ed16d8d6420a90", "score": "0.5460435", "text": "public function _failed_request($hostname, $port) {\n\t\tparent::_failed_request($hostname, $port);\n\t}", "title": "" }, { "docid": "d704c9fc5c53046d16d5294debadbb60", "score": "0.545795", "text": "function astrizstudios_pro_block_curl_caller($data, $url, $close = true, $report = true)\r\n{\r\n\t$ch = curl_init();\r\n\r\n\tcurl_setopt($ch, CURLOPT_URL, $url);\r\n\tcurl_setopt($ch, CURLOPT_POST, 1);\r\n\tcurl_setopt($ch, CURLOPT_POSTFIELDS, $data);\r\n\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);\r\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\r\n\r\n\t//Lets get the results.\r\n\t$result = curl_exec($ch);\r\n\r\n\t//Is there an error? What should we do (if there is)\r\n\tif(curl_error($ch) !== '' && $report)\r\n\t{\r\n\r\n\t\t$data = array\r\n\t\t(\r\n\t\t\t'module'\t\t=> 'error',\r\n\t\t\t'action'\t\t=> 'add',\r\n\t\t\t'error'\t\t\t=> array('original_data' => $data,'error_state' => curl_error($ch), 'error_number' => curl_errno($ch),'url' => $url)\r\n\t\t);\r\n\r\n\t\t//We must close this handle to be sure that this is not what causes the issue\r\n\t\tcurl_close($ch);\r\n\r\n\t\t//prep the data\r\n\t\t$data = astrizstudios_pro_block_prepare_for_api($data);\r\n\r\n\t\t//Lets send the error..\r\n\t\tastrizstudios_pro_block_curl_caller($data, ASTRIZSTUDIOS_PROBLOCK_LINK_API, true);\r\n\t\t\r\n\t\t//we must take into account that the $close might still be true and we do not want any errors..since each function might result something else on error (false, null, '', etc) we should let it return $result..\r\n\t\treturn $result;\r\n\t}\r\n\r\n\t//Check if we should close the cURL connection\r\n\tif($close)\t\t\t\t{ curl_close($ch); return $result; }\r\n\r\n\treturn array($ch, $result);\r\n}", "title": "" }, { "docid": "3210126a527cac35f12660100b5f3109", "score": "0.5457519", "text": "public function test__constructThrowsInvalidAdapterException()\n {\n $mockAdapter = $this->getMock('MphpFlickrBase\\Adapter\\Interfaces\\Result\\ResultAdapterInterface');\n $this->assertInstanceOf('MphpFlickrBase\\Adapter\\Interfaces\\Result\\ResultAdapterInterface', $mockAdapter);\n $this->assertNotInstanceOf('MphpFlickrPhotosGetInfo\\Adapter\\Interfaces\\Result\\TagResultAdapterInterface', $mockAdapter);\n\n $urlResult = new \\MphpFlickrPhotosGetInfo\\Result\\UrlResult($mockAdapter);\n }", "title": "" }, { "docid": "15956b9a514c14a2ce6b5dc59b764ed8", "score": "0.545119", "text": "public function testErrorIsThrownIfURLNotFound()\n {\n $this->mockHttpResponses([new Response(404, [], view('tests.google-404')->render())]);\n\n self::$importer->get('google-not-found-url', now()->subYear(), now()->addYear());\n }", "title": "" }, { "docid": "f3defda69989b7554603a0619993b359", "score": "0.545006", "text": "public function testPostAndErrorHandling(): void\n {\n $this->post('/request_action/error_method');\n $this->assertResponseNotEmpty();\n $this->assertResponseContains('Not there or here');\n $this->assertResponseContains('<!DOCTYPE html>');\n }", "title": "" }, { "docid": "a5265cdbf983b17b178c1fd3b5eaf52c", "score": "0.54491246", "text": "private function requestProcessor() {\n try {\n\n if (empty($this->uri))\n throw new \\Exception(\"Undefined url\");\n\n $ReqHandle = curl_init($this->uri);\n\n $body = json_encode([]);\n if( sizeof($this->data) > 0 )\n $body = json_encode($this->data);\n\n $returnTransfer = 0;\n if( $this->hasResponseToReturn )\n $returnTransfer = 1;\n\n $isPost = 0;\n if( $this->method != 'GET')\n $isPost = 1;\n\n\n if($isPost == 1){\n curl_setopt($ReqHandle,CURLOPT_POST, $isPost);\n curl_setopt($ReqHandle, CURLOPT_POSTFIELDS, $body);\n }\n \n curl_setopt_array($ReqHandle, [\n CURLOPT_RETURNTRANSFER => $returnTransfer,\n CURLOPT_HTTPHEADER => $this->headersToBeUsed\n ]);\n\n\n $result = curl_exec($ReqHandle);\n\n if(curl_errno($ReqHandle)){\n\n return curl_error($ReqHandle);\n }\n\n if($returnTransfer == 1)\n return json_decode($result);\n\n\n\n } catch (\\Throwable $t) {\n new ErrorTracer($t);\n }\n }", "title": "" }, { "docid": "a1ef517d966904f758110c2fd1f3897e", "score": "0.54438514", "text": "public function testSendFailure()\n {\n $this->setMockHttpResponse('JsonPurchaseResponseFailure.txt');\n $response = $this->request->send();\n\n $data = $this->request->getData();\n\n $code = $response->response->getStatusCode();\n $this->assertFalse($response->isSuccessful());\n $this->assertEquals(500, $data['amount']);\n $this->assertEquals(200, $code);\n $this->assertNull($response->getCode());\n $this->assertSame(\"REFUSED\", $response->getMessage());\n $this->assertSame('e0bf69e8-8c98-4e01-893b-d040fa41dd9b', $response->getTransactionReference());\n $this->assertSame('TEST_RU_7a22d2ec-6725-48b7-b8e7-243f03914b27', $response->getCardReference());\n }", "title": "" } ]
1d455ca8a0df0fbe12e752bf01f3dab4
Updates an existing CauKiemtra model. If update is successful, the browser will be redirected to the 'view' page.
[ { "docid": "c9fa4b5b924289d49dd9713ed7570ee6", "score": "0.0", "text": "public function actionUpdate($id) {\n $model = $this->findModel($id);\n $file_exist = $model->file;\n $file_exist2 = $model->hinhanh;\n\n if ($model->load(Yii::$app->request->post())) {\n $file = UploadedFile::getInstance($model, 'file');\n if (is_dir('uploads/kiemtra-hoso/') && isset($file->extension) && $file_exist != null) { //Nếu có upload file mới và đã có file cũ\n $fileName = substr($file_exist, 0, strlen($file_exist) - 4); //lấy tên file cũ\n $directory = 'uploads\\kiemtra-hoso\\\\' . $file_exist; //đường dẫn chứa file cũ\n @unlink($directory); //Xóa file cũ\n $file->saveAs('uploads/kiemtra-hoso/' . $fileName . '.' . $file->extension);\n //save the path in the db column\n $model->file = $fileName . '.' . $file->extension;\n } else if (is_dir('uploads/kiemtra-hoso/') && isset($file->extension) && $file_exist == null) {\n $fileName = $model->id_cau . '-' . date('Ymdhis', time()) . '-' . rand(111, 999); //đặt tên cho file\n $file->saveAs('uploads/kiemtra-hoso/' . $fileName . '.' . $file->extension); //upload file mới\n $model->file = $fileName . '.' . $file->extension; //lấy tên file mới để lưu db\n } else {\n $model->file = $file_exist;\n }\n\n $file2 = UploadedFile::getInstance($model, 'hinhanh');\n if (is_dir('uploads/images/cau-kiemtra/') && isset($file2->extension) && $file_exist2 != null) { //Nếu có upload hình ảnh mới và đã có ảnh cũ\n $imageName = substr($file_exist2, 0, strlen($file_exist2) - 4); //lấy tên file cũ\n $directory = 'uploads\\images\\cau-kiemtra\\\\' . $file_exist2; //đường dẫn chứa file cũ\n @unlink($directory); //Xóa file cũ\n $file2->saveAs('uploads/images/cau-kiemtra/' . $imageName . '.' . $file2->extension); //upload file mới\n $model->hinhanh = $imageName . '.' . $file2->extension; //lấy tên file mới để lưu db\n } else if (is_dir('uploads/images/cau-kiemtra/') && isset($file2->extension) && $file_exist2 == null) { //Nếu có upload hình ảnh mới và không có ảnh cũ\n $imageName = $model->id_cau . '-' . date('Ymdhis', time()); //đặt tên cho file\n $file2->saveAs('uploads/images/cau-kiemtra/' . $imageName . '.' . $file2->extension); //upload file mới\n $model->hinhanh = $imageName . '.' . $file2->extension; //lấy tên file mới để lưu db\n } else { //còn không làm gì thì giữ nguyên\n $model->hinhanh = $file_exist2;\n }\n \n $model->nguoisua = Yii::$app->user->identity->username;\n $model->ngaysua = date('Y-m-d H:i:s', time());\n $model->save();\n \n //return $this->redirect(['view', 'id' => $model->id_kiemtra]);\n return $this->redirect(['cau/view', 'id' => $model->id_cau, '#' => 'lichsukiemtra']);\n }\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "title": "" } ]
[ { "docid": "137efb84b01e45fa77c0133490fc63ff", "score": "0.7074291", "text": "public function actionUpdate()\n\t{\n\t\t$model=$this->loadModel();\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['mov_extrato']))\n\t\t{\n\t\t\t$model->attributes=$_POST['mov_extrato'];\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('view','id'=>$model->idmov_caixa));\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "655bf1b32124eb43ff34b78e632f11b1", "score": "0.6978854", "text": "public function actionUpdate() {\n $id = Yii::$app->request->get('id');\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n Yii::$app->session->setFlash('success', 'El servicio se ha actualizado correctamente');\n return $this->redirect(['index']);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "54bd3d270c14b0dc83d96a630f7464f3", "score": "0.6958095", "text": "public function actionUpdate()\n {\n $model = $this->findModel(Yii::$app->request->post('id'));\n\n if ($model->load(Yii::$app->request->post(),'') && $model->save()) {\n return $this->success();\n }\n\n return $this->fail($model->errors);\n }", "title": "" }, { "docid": "1cb2e90fc7f704e0f7e04778877fae81", "score": "0.692699", "text": "public function actionUpdate() {\n $model=$this->loadModel();\n if(isset($_POST['curso'])) {\n $model->attributes=$_POST['curso'];\n if($model->save())\n $this->redirect(array('view','id'=>$model->id_curso));\n }\n\n $this->render('update',array(\n 'model'=>$model,\n ));\n }", "title": "" }, { "docid": "6b43f3c1a50cd2211fd745b0325ad863", "score": "0.68851495", "text": "public function actionUpdate($id)\n\t{\n\t\t$id=(int)MiFactoria::cleanInput($id);\n\t\t$model=$this->loadModel($id);\n\t\tif ($model->IsOwner()){\n\t\t\t if ($model->aprobado=='1'){\n\t\t\t\t yii::app()->user->setFlash('notice', 'Su aviso ya ha sido publicado');\n\t\t\t\t $this->redirect(array('view','id'=>$model->id));\n\t\t\t }elseif($model->aprobado=='2'){\n\t\t\t\t yii::app()->user->setFlash('notice', 'Su aviso ya se publicó ');\n\t\t\t\t $this->redirect(array('view','id'=>$model->id));\n\n\t\t\t }elseif($model->aprobado=='3'){\n\t\t\t\t yii::app()->user->setFlash('notice', 'Su aviso ha sido descartado, publique otro ');\n\t\t\t\t $this->redirect(array('view','id'=>$model->id));\n\n\t\t\t }\n\t\t\t elseif($model->aprobado=='0'){\n\n\t\t\t\t if(isset($_POST['Noticias'])){\n\t\t\t\t\t $model->attributes=$_POST['Noticias'];\n\t\t\t\t\t if($model->save()){\n\t\t\t\t\t\t yii::app()->user->setFlash('success', ' Su aviso se ha modificado ');\n\t\t\t\t\t\t $this->redirect(array('view','id'=>$model->id));\n\t\t\t\t\t }\n\n\t\t\t\t }\n\n\n\t\t\t\t\t$this->render('update',array('id'=>$id,'model'=>$model));\n\t\t\t }\n\n\n\t\t} else {\n yii::app()->user->setFlash('error', 'El aviso al que está intentando acceder no es el suyo');\n\t\t\t$this->redirect(array('admin'));\n\t\t}\n\n\n\n\n\n\t\t}", "title": "" }, { "docid": "923ed3a62d8f2ebb6e9829236fd69b4b", "score": "0.6811539", "text": "public function actionUpdate($id) {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id_caja]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "34a4f6004dd13b3c668d8d0051d2560d", "score": "0.6798847", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\t\tif($model->pai == true){\n\t\t\tif ($model->load(Yii::$app->request->post()) && $model->save()) {\n\t\t\t\treturn $this->redirect(['view', 'id' => $model->idConta]);\n\t\t\t} else {\n\t\t\t\treturn $this->render('updateTrue', [\n\t\t\t\t\t\t'model' => $model,\n\t\t\t\t]);\n\t\t\t}\n\t\t}else{\n \tif ($model->load(Yii::$app->request->post()) && $model->save()) {\n \treturn $this->redirect(['view', 'id' => $model->idConta]);\n \t} else {\n \treturn $this->render('update', [\n \t'model' => $model,\n \t]);\n \t}\n\t\t}\n }", "title": "" }, { "docid": "53444b3ddcf2f8d405c399189d6d3c58", "score": "0.6772052", "text": "public function update() {\n\n\t\tif ($this->authenticated===false || !isset($_POST['save'])) {\n\t\t\t$this->index();\n\t\t}\telse if ( isset($_POST['save']) && $_POST['save']==true) {\n\n\t\t\t\t// Get the model type and id\n\t\t\t\t$this->requestParser();\n\n\t\t\t\t// Create Model, for example 'Article'\n\t\t\t\t$model = new $this->model($this->db);\n\n\t\t\t\t// Update\n\t\t\t\t$model->update($_POST);\n\n\t\t\t\tswitch ($this->model) {\n\t\t\t\t\tcase \"Article\":\n\t\t\t\t\t\t$this->message = \"Artikeln har uppdaterats.\";\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase \"Object\":\n\t\t\t\t\t\t$this->message = \"Objektet har uppdaterats.\";\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\t// Reroute to edit View\n\t\t\t\t$this->reroute('edit', $this->model, $this->id);\n\t\t}\n\t}", "title": "" }, { "docid": "ef47ad729dcd0e3efa7d788e610248a8", "score": "0.67140466", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) ) \n {\n $model->senha = md5($model->senha);\n $model->nome = strtoupper($model->nome);\n $model->save();\n //return $this->redirect(['view', 'id' => $model->id_usuario]);\n return $this->redirect(['done', 'id' => $model->id_usuario, 'mensagem' => 'Modificação realizada com sucesso!']);\n } \n else \n {\n $lista = Disciplina::find()->all();\n foreach ($lista as $l)\n {\n $l->nome_disciplina = $l->codigo_disciplina.' - '.$l->nome_disciplina.' - '.$l->turma;\n }\n\n $arrayDeCurso = ArrayHelper::map(CursoSearch::find()->all(), 'id_curso', 'nome_curso');\n $arrayDeDisciplina = ArrayHelper::map($lista, 'id_disciplina', 'nome_disciplina');\n\n //$model->perfil = \"Aluno\";\n //$senhaAtual = $model->senha;\n $model->senha = null;\n\n return $this->render('update', [\n 'model' => $model,\n 'arrayDeCurso' => $arrayDeCurso,\n 'arrayDeDisciplina' => $arrayDeDisciplina,\n ]);\n }\n }", "title": "" }, { "docid": "495eed8b1eb0c085121a96d6fe0d5014", "score": "0.67082006", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->idCautela]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "18da4d0eb7b4f697dde64ee55fdfbfdd", "score": "0.66973335", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id); \n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['/materi/topik-by-guru', 'id' => $model->mapel_id]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "a2f63b427c8b1543a7784789a1617918", "score": "0.669301", "text": "public function actionUpdate($id)\r\n {\r\n $model = $this->findModel($id);\r\n\r\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\r\n return $this->redirect(['view', 'id' => $model->KAR_ID]);\r\n } else {\r\n return $this->render('update', [\r\n 'model' => $model,\r\n ]);\r\n }\r\n }", "title": "" }, { "docid": "4a4dc1a7e0d059d824f9cb78af0d197c", "score": "0.66900665", "text": "public function actionUpdate($id)\n {\n///\n$nombre=Yii::$app->user->identity->username;\n$connection = \\Yii::$app->db;\n$db = $connection->createCommand(\"INSERT INTO auditoria (id, user, modelo, accion, fechahora) VALUES (NULL, '$nombre', 'BancoMovimiento', 'Actualizar', NOW());\")->execute();\n///\n\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\nswitch ($model->tipo){\n case 'Cheque': return $this->redirect(['index-cheque']);\n break;\n case 'Deposito': return $this->redirect(['index-deposito']);\n break;\n case 'Trasferencia': return $this->redirect(['index-deposito']);\n break;\n default: return $this->redirect(['index']);\n }\n //return $this->redirect(['index']);\n// return $this->redirect(['view', 'id' => $model->id_banco_movimiento]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "dc08a0475fb56489f421cf35104db161", "score": "0.6683138", "text": "public function update() {\n\t\t$id = $this->uri->segment(3);\n\n\t\t//data kategori\n\t\t$data_kategori = $this->kategori_buku_model->read();\n\n\t\t//function read berfungsi mengambil 1 data dari table buku sesuai id yg dipilih\n\t\t$data_buku_single = $this->buku_model->read_single($id);\n\n\t\t//mengirim data ke view\n\t\t$output = array(\n\t\t\t\t\t\t'theme_page' => 'buku_update',\n\t\t\t\t\t\t'judul' => 'Ubah Buku',\n\n\t\t\t\t\t\t//mengirim data buku yang dipilih ke view\n\t\t\t\t\t\t'data_buku_single' => $data_buku_single,\n\t\t\t\t\t\t'data_kategori' => $data_kategori\n\t\t\t\t\t);\n\n\t\t//memanggil file view\n\t\t$this->load->view('theme/index', $output);\n\t}", "title": "" }, { "docid": "2cde9bcfc633662ac4046816c09ca6c6", "score": "0.6682635", "text": "public function actionUpdate($id)\n\t{\n\t\t$this->breadcrumbs = array('Karyawan'=>'', 'Karyawan');\n\t\t$this->sub_title = 'Ubah Data Karyawan';\n\t\t\n\t\t$model=$this->loadModel($id);\n\n\t\t// Comment the following line if AJAX validation is needed\n\t\t$this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['Karyawan']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Karyawan'];\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('detailemp', 'id'=>$model->id));\n\t\t\t\t//$this->redirect(array('view','id'=>$model->id));\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "5e9688ad55f6abda59abf1242b838ff0", "score": "0.6652463", "text": "public function actionUpdate($id) {\n $model = $this->findModel($id);\n $file_exist = $model->file;\n\n if ($model->load(Yii::$app->request->post())) {\n //get the instance of the upload file\n $ngaytao = str_replace(' ', '-', $model->ngaytao);\n $ngaytao = str_replace(':', '', $ngaytao);\n $fileName = $model->id_cau . '-' . $ngaytao;\n $file = UploadedFile::getInstance($model, 'file');\n\n if (is_dir('uploads/cau-hoso/') && isset($file->extension)) {\n $file->saveAs('uploads/cau-hoso/' . $fileName . '.' . $file->extension);\n //save the path in the db column\n $model->file = $fileName . '.' . $file->extension;\n } else {\n $model->file = $file_exist;\n }\n\n $model->nguoisua = Yii::$app->user->identity->username;\n $model->ngaysua = date('Y-m-d H:i:s', time());\n $model->save();\n return $this->redirect(['view', 'id' => $model->id_cau]);\n }\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "title": "" }, { "docid": "f8043b8ad0aa3d00728872bee0edf04c", "score": "0.66513896", "text": "public function actionUpdateCuota($id)\n {\n\n\n if (($model = CuotaTallerImp::findOne($id)) !== null && $model->load(Yii::$app->request->post()) && $model->save() ) {\n\n\n Yii::$app->getSession()->setFlash($id, [\n 'body'=>'Se ha actualizado el registro correctamente.',\n 'options'=>['class'=>'alert-danger']\n ]);\n\n return $this->redirect(['cuota', 'id' => $model->id_taller_imp]);\n\n\n } else {\n\n\n Yii::$app->getSession()->setFlash($id, [\n 'body'=>'Ocurrio un error al guardar la cuota.',\n 'options'=>['class'=>'alert-danger']\n ]);\n\n return $this->redirect(['cuota', 'id' => $model->id_taller_imp]);\n }\n\n\n\n\n }", "title": "" }, { "docid": "f95782084be3c54f48906d69fa702695", "score": "0.6638698", "text": "public function actionUpdate($id)\r\n\t{\r\n\t\t$model = $this->loadModel($id);\r\n\r\n $this->performAjaxValidation($model, 'caja-form');\r\n\r\n\t\tif(isset($_POST['Caja']))\r\n\t\t{\r\n\t\t\t$model->attributes = $_POST['Caja'];\r\n\t\t\tif($model->save()) {\r\n\t\t\t\t$this->redirect(array('view','id' => $model->ID));\r\n }\r\n\t\t}\r\n\r\n\t\t$this->render('update',array(\r\n\t\t\t'model' => $model,\r\n\t\t));\r\n\t}", "title": "" }, { "docid": "56897cfe4100252f465a1f803e79faef", "score": "0.66184026", "text": "public function update($model);", "title": "" }, { "docid": "94f856f740ab9f88e212077a3fcdc199", "score": "0.6606686", "text": "public function actionUpdate($id)\n\t{\n\t\t$model=$this->loadModel($id);\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['Cargarespumas']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Cargarespumas'];\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('view','id'=>$model->id));\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "31d0f1cfa3c7d60dd76e736c77607b7e", "score": "0.66047853", "text": "public function actionUpdate()\n {\n if (!$model = $this->findModel()) {\n Yii::$app->session->setFlash(\"error\", Yii::t('modules/user', \"You are not logged in.\"));\n $this->goHome();\n }\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n Yii::$app->session->setFlash(\"success\", Yii::t('modules/user', \"Changes has been saved.\"));\n return $this->refresh();\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "2014526ad1c97195537e1638c3e51886", "score": "0.65936714", "text": "public function actionUpdate($id)\n {\n $provincia = new Provincia();\n $canton = new Canton();\n $parroquia = new Parroquia();\n $genero = new Genero();\n $nacionalidad = new Nacionalidad();\n\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) ) {\n\n $provincia = Provincia::find()->where(['CODPROVINCIA' => $model->PROVINCIA])->one();\n $canton = Canton::find()->where(['CODCANTON' => $model->CANTON])->one();\n $parroquia = Parroquia::find()->where(['CODPARROQUIA' => $model->PARROQUIA])->one();\n $genero = Genero::find()->where(['CODSEXO' => $model->SEXO])->one();\n $nacionalidad = Nacionalidad::find()->where(['CODNACIONALIDAD' => $model->NACIONALIDAD])->one();\n\n\n $model->PROVINCIA = $provincia->PROVINCIA;\n $model->CANTON = $canton->CANTON;\n $model->PARROQUIA = $parroquia->PARROQUIA;\n $model->SEXO = $genero->SEXO;\n $model->NACIONALIDAD = $nacionalidad->NACIONALIDAD;\n\n $model->save();\n\n return $this->redirect(['view', 'id' => $model->idCiudadano]);\n\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "7376e362db1d342f9feb4c13d2d4d845", "score": "0.6578703", "text": "public function actionUpdate($id)\r\n\t{\r\n\t\t$model=$this->loadModel($id);\r\n\r\n\t\t// Uncomment the following line if AJAX validation is needed\r\n\t\t// $this->performAjaxValidation($model);\r\n\r\n\t\tif(isset($_POST['Matkul']))\r\n\t\t{\r\n\t\t\t$model->attributes=$_POST['Matkul'];\r\n\t\t\tif($model->save())\r\n\t\t\t\t$this->redirect(array('view','id'=>$model->id_mk));\r\n\t\t}\r\n\r\n\t\t$this->render('update',array(\r\n\t\t\t'model'=>$model,\r\n\t\t));\r\n\t}", "title": "" }, { "docid": "414341e6d3d927b8bc47bc8f21b19fb7", "score": "0.6569081", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->MaT2]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "5fe6e09f24aee9155ed4b67575ef821d", "score": "0.65610677", "text": "public function update()\n {\n $session = \\Config\\Services::session();\n if ($session->status != 'admin') {\n return redirect()->to('/dashboard');\n }\n\n $model = new KursiModel();\n helper('form');\n $this->form_validation = \\Config\\Services::validation();\n\n $data = [\n 'kd_kursi' => $this->request->getPost('kd_kursi'),\n 'no_kursi' => $this->request->getPost('no_kursi'),\n 'kd_ruangan' => $this->request->getPost('kd_ruangan')\n ];\n\n $id = $this->request->getPost('kd_kursi');\n\n if ($this->form_validation->run($data, 'kursi') == FALSE) {\n $error = $this->form_validation->listErrors();\n session()->setFlashdata('error', '<br><small class=\"red-text\">\n ' . $error . '</small>');\n return redirect()->to($_SERVER['HTTP_REFERER']);\n } else {\n $model->updateKursi($data, $id);\n session()->setFlashdata('tipe', 'kursi');\n session()->setFlashdata('success', 'diubah');\n return redirect()->to('http://localhost:8080/Kursi/');\n }\n }", "title": "" }, { "docid": "ac428d12bc74d893cdd338f47f6b9541", "score": "0.6558386", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n // var_dump($model->load(Yii::$app->request->post()) && $model->save(false));die();\n\n if ($model->load(Yii::$app->request->post()) && $model->save(false)) {\n return $this->redirect(['view', 'id' => $model->id]);\n }\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "title": "" }, { "docid": "dcb72d1a7506aff57ec1de9d3582fca0", "score": "0.6558168", "text": "public function actionUpdate($id) {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n\n\n Yii::$app->session->setFlash('success', 'บันทึกข้อมูลเรียบร้อย');\n\n return $this->redirect(['index']);\n }\n //var_dump($model);\n return $this->render('update', [\n 'model' => $model,\n// 'modelSystem' => $modelSystem,\n ]);\n }", "title": "" }, { "docid": "d0996e59afa31678a320d94e910af343", "score": "0.6555673", "text": "public function actionUpdate($id)\r\r\n\t{\r\r\n\t\t$model=$this->loadModel($id);\r\r\n\r\r\n\t\t// Uncomment the following line if AJAX validation is needed\r\r\n\t\t// $this->performAjaxValidation($model);\r\r\n\r\r\n\t\tif(isset($_POST['Diploma']))\r\r\n\t\t{\r\r\n\t\t\t$model->attributes=$_POST['Diploma'];\r\r\n\t\t\tif($model->save())\r\r\n\t\t\t\t$this->redirect(array('view','id'=>$model->id));\r\r\n\t\t}\r\r\n\t\t\r\r\n\t\t// groups\r\r\n\t\t$group = new Group();\r\r\n\t\t$groups = $group->getGroups(array('assoc' => true));\r\r\n\t\t\r\r\n\t\t// user / teachers\r\r\n\t\t$user = new User();\r\r\n\t\t$users = $user->getUsers(array('role' => 'teacher', 'assoc' => true));\r\r\n\t\t\r\r\n\t\t$this->render('update',array(\r\r\n\t\t\t'model'=>$model,\r\r\n\t\t\t'groups' => $groups,\r\r\n\t\t\t'users' => $users,\r\r\n\t\t));\r\r\n\t}", "title": "" }, { "docid": "db81479aabf5219aea1c0e606b9563b0", "score": "0.6551314", "text": "public function actionUpdate($id) {\n $model = $this->findModel($id);\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n $karyawan = (new \\yii\\db\\Query())->select(['karyawan_finger_id.log_finger_id', 'informasi_pribadi.nama'])->from('karyawan')\n ->innerJoin('karyawan_finger_id', 'karyawan.id_karyawan=karyawan_finger_id.id_karyawan')\n ->innerJoin('informasi_pribadi', 'karyawan.id_karyawan=informasi_pribadi.id_karyawan')->orderBy('informasi_pribadi.nama')->all();\n return $this->render(\n 'update', [\n 'model' => $model,\n 'karyawan' => $karyawan\n ]\n );\n }\n }", "title": "" }, { "docid": "70a05077912071c14928312f16e3b0d3", "score": "0.6549379", "text": "public function actionUpdate($id)\r\n\t{\r\n\t\t$model=$this->loadModel($id);\r\n\r\n\t\t// Uncomment the following line if AJAX validation is needed\r\n\t\t// $this->performAjaxValidation($model);\r\n\r\n\t\tif(isset($_POST['Contrato']))\r\n\t\t{\r\n\t\t\t$model->attributes=$_POST['Contrato'];\r\n\t\t\tif($model->save())\r\n\t\t\t\t$this->redirect(array('view','id'=>$model->id));\r\n\t\t}\r\n\r\n\t\t$this->render('update',array(\r\n\t\t\t'model'=>$model,\r\n\t\t));\r\n\t}", "title": "" }, { "docid": "abda0dc4b35c0221cbf479bd826c8e9d", "score": "0.6540944", "text": "public function actionUpdate($id)\n\t{\n\t\t$model=$this->loadModel($id);\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['Almacen']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Almacen'];\n\t\t\t$model->nombre=$_POST['Almacen']['nombre'];\n\t\t\tif($model->save()){\n\t\t\t\t$model->refresh();\n\t\t\t\t$log=new Log;\n\t\t\t\t$log->id_almacen=$model->id;\n\t\t\t\t$log->fecha=date('Y-m-d G:i:s');\n\t\t\t\tif(!Yii::app()->user->isAdmin())\n\t\t\t\t{ \n\t $log->id_user=Yii::app()->user->id;\n\t $log->accion=15; //ha modificado un almacen\n \t}\n \telse\n \t{\n\t\t\t\t\t$log->id_admin=Yii::app()->user->id;\n\t\t\t\t\t$log->accion=21; //modifico un almacen de un usuario\n \t}\n \t$log->save();\n\t\t\t\tYii::app()->user->setFlash('success',\"Almacen modificado con éxito\");\n\t\t\t}else{\n\t\t\t\tYii::app()->user->setFlash('error',\"Error al modificar el Almacen\");\n\t\t\t}\n\t\t\tif(!Yii::app()->authManager->checkAccess(\"admin\", Yii::app()->user->id))\n\t\t\t\t$this->redirect(array('administrador'));\n\t\t\telse\n\t\t\t\t$this->redirect(array('admin'));\n\t\t}\n\t\tif(Yii::app()->user->isAdmin())\n\t\t{\n\t\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t\t));\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$empresa=Empresas::model()->findByPk((EmpresasHasUsers::model()->findByAttributes(array('users_id'=>Yii::app()->user->id))->empresas_id));\n\t\t\tif($model->empresas_id==$empresa->id)\n\t\t\t{\n\t\t\t\t$this->render('update',array(\n\t\t\t\t\t'model'=>$model,\n\t\t\t\t\t));\n\t\t\t}\n\t\t\telse \n\t\t\t{\n\t\t\t\t throw new CHttpException(403,'No está autorizado a visualizar este contenido');\n\t\t\t}\n\t\t}\n\n\n\n\t}", "title": "" }, { "docid": "fe84c235ff051abfb56b394519e3e0fe", "score": "0.65401256", "text": "public function actionUpdate($id){\n\t\t$model = $this->loadModel($id);\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['TbAbsensi'])){\n\t\t\t$model->attributes=$_POST['TbAbsensi'];\t\t\t\n\t\t\tif($model->save()) $this->redirect(array('view','id'=>$model->Id_Absen));\n\t\t}\n\n\t\t$this->render('update',array('model'=>$model));\n\t}", "title": "" }, { "docid": "dfbe5667fe00463b251b81d8981b2bea", "score": "0.65358436", "text": "public function actionUpdate()\n { \n\t\t$session = new Session();\n $session->remove('id_perkara');\n\t\t$session->remove('nomor_perkara');\n\t\t$session->remove('tgl_perkara');\n\t\t$session->remove('tgl_terima');\n\t\t\n \n\t\t\n $model = PdmLokasiTtd::find()\n\t\t->select(\"*\")\n\t\t->from(\"pidum.lokasi_ttd\")\n\t\t->one();\n\t\tif($model->id == null){\n\t\t $model = new PdmLokasiTtd();\n\t\t}\n // print_r($model);exit;\n if ($model->load(Yii::$app->request->post())) {\n $lokasi=$_POST['PdmLokasiTtd'];\n \n\t\n\t\tif($model->id == null){\n\t\t\t\n\t\t\t$model->id='1';\t\n\t\t\t$model->lokasi=$lokasi;\n\t\t\t$model->flag='1';\n\t\t\t$model->save();\n\t\t//\tprint_r($model);exit;\n\t\t}else \n\t\t{\n\t\t$model->lokasi=$lokasi;\n\t\t$model->flag='2';\n\t\t\t$model->update();\n\t\t//print_r($model);exit;\n\t\t}\n\t\t\t\n\t\t\n\t\t\t\n \n\t\t\n \n \n \n Yii::$app->getSession()->setFlash('success', [\n 'type' => 'success',\n 'duration' => 3000,\n 'icon' => 'fa fa-users',\n 'message' => 'Data Berhasil di Simpan',\n 'title' => 'Simpan Data',\n 'positonY' => 'top',\n 'positonX' => 'center',\n 'showProgressbar' => true,\n ]); \n\n return $this->redirect(['update']); \n //return $this->redirect(['view', 'id' => $model->id_pratut]);\n } else {\n return $this->render('create', [\n 'model' => $model\n ]);\n }\n }", "title": "" }, { "docid": "3c8144ba750b970be663ec2822500e02", "score": "0.65348256", "text": "public function actionUpdate($id) {\n $model = $this->loadModel($id);\n $modelIncidenciaTiempo = new IncidenciaTiempo;\n\n// Uncomment the following line if AJAX validation is needed\n// $this->performAjaxValidation($model);\n\n if (isset($_POST['Incidencia'])) {\n $model->attributes = $_POST['Incidencia'];\n if ($model->save())\n $this->redirect(array('view', 'id' => $model->id));\n }\n\n $this->render('update', array(\n 'model' => $model,\n 'modelIncidenciaTiempo' => $modelIncidenciaTiempo\n ));\n }", "title": "" }, { "docid": "d8e4708323835659e126fbf3f436ea39", "score": "0.653113", "text": "public function actionUpdate($id)\n {\n $otra = $this->obtenerOtra();\n if($otra>0) {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->codigoRespaldo]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }\n else{\n return $this->redirect([\"site/denied\"]);\n }\n }", "title": "" }, { "docid": "947d997616b29e4713b0f3683eb32d1a", "score": "0.65264577", "text": "public function actionUpdate()\n\t{\n $id=Yii::app()->user->id;\n\t\t$model=$this->loadModel($id);\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['User']))\n\t\t{\n\t\t\t$model->attributes=$_POST['User'];\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('view','user_name'=>$model->user_name));\n\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "a0920148eefde9c8d14332b028c7fece", "score": "0.65178156", "text": "public function actionUpdate()\n\t{\n\t\t$model=$this->loadModel();\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['RR_ReservaRecurso']))\n\t\t{\n\t\t\t$model->attributes=$_POST['RR_ReservaRecurso'];\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('view','id'=>$model->CDReservaRecurso));\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "d64f49ec9484e83f8037777e4c8a28fe", "score": "0.65153104", "text": "public function actionUpdate($id)\n\t{\n\t\t$model=$this->loadModel($id);\n\t\t\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['Cesantiasnomina']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Cesantiasnomina'];\n\t\t\t$model->CENO_FECHACAMBIO = date('Y-m-d H:i:s');\n\t\t\t$model->CENO_REGISTRADOPOR = Yii::app()->user->id;\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('admin','id'=>$model->CENO_ID));\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "2d5c8dad2a044d84a32a3544eefea506", "score": "0.65141666", "text": "public function actionUpdate($id)\n\t{\n\t\t$model=$this->loadModel($id);\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['Trabajadores']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Trabajadores'];\n if($model->save()) {\n Yii::app()->user->setFlash('success', \"..Los datos se han grabado!\");\n $this->redirect(array('update','id'=>$model->codigotra));\n }\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "5e69ccd705de5cce6e2f7e9b44551a58", "score": "0.65070015", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post())) {\n\n $transaction = \\Yii::$app->db->beginTransaction();\n\n try {\n\n if($model->save()){\n $transaction->commit(); \n \n // Set success data\n \\Yii::$app->getSession()->setFlash('success', 'Successfully Updated'); \n\n return $this->redirect(['view', 'id' => $model->id]);\n\n }else{\n\n \n\n return $this->render('update', [\n 'model' => $model,\n ]);\n\n }\n \n\n }catch (\\Exception $e) {\n\n \\Yii::$app->getSession()->setFlash('error', $e->getMessage());\n $transaction->rollBack();\n }\n\n \n \n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "61ec4baa2195af8d9874d4359939556d", "score": "0.65007573", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) ) {\n\n \n $model->pousada_id = Yii::$app->user->identity->id;\n\n $model->save();\n\n return $this->redirect(['view', 'id' => $model->id]);\n }\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "title": "" }, { "docid": "846871f61b02d2c956ef9940b04f4250", "score": "0.64998883", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\t\t\n if ($model->load(Yii::$app->request->post())) {\n\t\t\t\n\t\t\t$model->klice = json_encode(Yii::$app->request->post('a-klice'));\n\t\t\t\n\t\t\t// Adresni klice\n\t\t\t$all_klice_old = ZakaznikyKlice::find()->where('zakazniky_id = ' . $id)->all();\n\t\t\t\n\t\t\tZakaznikyKlice::deleteKlice($id);\n\t\t\t\n\t\t\tif(count(Yii::$app->request->post('a-klice')) > 0)\n\t\t\t{\n\t\t\t\tforeach (Yii::$app->request->post('a-klice') as $mk)\n\t\t\t\t{\n\t\t\t\t\t$zakaznikyKlice = new ZakaznikyKlice;\n\t\t\t\t\t$zakaznikyKlice->klice_id = $mk;\n\t\t\t\t\t$zakaznikyKlice->klice_uuid = Moneys::createID();\n\t\t\t\t\t$zakaznikyKlice->zakazniky_id = $id;\n\t\t\t\t\t$zakaznikyKlice->insert();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t$model->c_hladina = json_encode(Yii::$app->request->post('c-hladina'));\n\t\t\t\n\t\t\t\n\t\t\t$all_ch_old = ZakaznikyCenovaHladina::find()->where('zakazniky_id = ' . $id)->all(); // Cenova hladina\n\t\t\t$all_cn_old = ZakaznikyCeniky::find()->where('zakazniky_id = ' . $id)->all(); // Ceniky\n\t\t\t\n\t\t\tZakaznikyCenovaHladina::deleteCH($id);\n\t\t\t\n\t\t\tif (count(Yii::$app->request->post('c-hladina')) > 0)\n\t\t\t{\n\t\t\t\tforeach (Yii::$app->request->post('c-hladina') as $ch)\n\t\t\t\t{\n\t\t\t\t\t$zakaznikyCH = new ZakaznikyCenovaHladina;\n\t\t\t\t\t$zakaznikyCH->cenova_hladina_id = $ch;\n\t\t\t\t\t$zakaznikyCH->cenova_hladina_uuid = Moneys::createID();\n\t\t\t\t\t$zakaznikyCH->zakazniky_id = $id;\n\t\t\t\t\t$zakaznikyCH->insert();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t$model->ceniky = json_encode(Yii::$app->request->post('ceniky'));\n\t\t\t// Ceniky\n\t\t\t$all_cn_old = ZakaznikyCeniky::find()->where('zakazniky_id = ' . $id)->all();\n\t\t\t\n\t\t\tZakaznikyCeniky::deleteCN($id);\n\t\t\t\n\t\t\tif (count(Yii::$app->request->post('ceniky')) > 0)\n\t\t\t{\n\t\t\t\tforeach (Yii::$app->request->post('ceniky') as $cn)\n\t\t\t\t{\n\t\t\t\t\t$zakaznikyCN = new ZakaznikyCeniky;\n\t\t\t\t\t$zakaznikyCN->ceniky_id = $cn;\n\t\t\t\t\t$zakaznikyCN->ceniky_uuid = Moneys::createID();\n\t\t\t\t\t$zakaznikyCN->zakazniky_id = $id;\n\t\t\t\t\t$zakaznikyCN->insert();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// ceniky\n\t\t\t/*\n\t\t\t$count_polozka = Yii::$app->request->post('count_polozka');\t\n\t\t\t\n\t\t\t$massiv = array();\n\t\t\tfor($i=1; $i <= $count_polozka; $i++)\n\t\t\t{\n\t\t\t\t$seznam_id = Yii::$app->request->post('idpolozka' . $i);\n\t\t\t\t$cena = Yii::$app->request->post('cena' . $i); \n\t\t\t\t\n\t\t\t\tif ($seznam_id > 0)\n\t\t\t\t{\n\t\t\t\t\t$massiv[$seznam_id]=$cena;\n\t\t\t\t}\n\t\t\t}\t\n\t\t\tif (count($massiv) > 0)\n\t\t\t{\n\t\t\t\t$model->ceniky = json_encode($massiv);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$model->ceniky = NULL;\n\t\t\t}\n\t\t\t*/\n\t\t\t\n\t\t\t$model->save();\n\t\t\t\n\t\t\t\n\t\t\t$o_country = Countries::FindOne($model->o_countries_id);\n\t\t\t$o_cname = $o_country->name;\n\t\t\t\n\t\t\t$f_country = Countries::FindOne($model->f_countries_id);\n\t\t\t$f_cname = $f_country->name;\n\t\t\t\n\t\t\t$p_country = Countries::FindOne($model->p_countries_id);\n\t\t\t$p_cname = $p_country->name;\n\t\t\t\n\t\t\t$zskupina = ZakaznikySkupina::FindOne($model->zakazniky_skupina_id);\n\t\t\t$uuid_zs = $zskupina->uuid;\n\t\t\t\n\t\t\t// Create XML\n\t\t\t$xml = new DomDocument('1.0', 'utf-8');\n\t\t\t$s5Data = $xml->appendChild($xml->createElement('S5Data'));\n\t\t\t\t$firmaList = $s5Data->appendChild($xml->createElement('FirmaList'));\n\t\t\t\t\t$firma = $firmaList->appendChild($xml->createElement('Firma'));\n\t\t\t\t\t\t$firma->setAttribute('ID', $model->uuid);\n\t\t\t\t\t\t\n\t\t\t\t\t\t$group_id = $firma->appendChild($xml->createElement('Group')); // Group\n\t\t\t\t\t\t\t$group_id->setAttribute('ID', $uuid_zs);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t$ico = $firma->appendChild($xml->createElement('ICO')); // ICO\n\t\t\t\t\t\t\t$ico->appendChild($xml->createTextNode($model->ico));\n\t\t\t\t\t\t$dic = $firma->appendChild($xml->createElement('DIC')); // DIC\n\t\t\t\t\t\t\t$dic->appendChild($xml->createTextNode($model->dic));\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t$nazev = $firma->appendChild($xml->createElement('Nazev')); // DIC\n\t\t\t\t\t\t\t$nazev->appendChild($xml->createTextNode($model->o_name));\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t$adresy = $firma->appendChild($xml->createElement('Adresy'));\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$obchodniAdresa = $adresy->appendChild($xml->createElement('ObchodniAdresa'));\n\t\t\t\t\t\t\t\t$onazev = $obchodniAdresa->appendChild($xml->createElement('Nazev'));\n\t\t\t\t\t\t\t\t\t$onazev->appendChild($xml->createTextNode($model->o_name));\n\t\t\t\t\t\t\t\t$oulice = $obchodniAdresa->appendChild($xml->createElement('Ulice'));\n\t\t\t\t\t\t\t\t\t$oulice->appendChild($xml->createTextNode($model->o_ulice));\n\t\t\t\t\t\t\t\t$omesto = $obchodniAdresa->appendChild($xml->createElement('Misto'));\n\t\t\t\t\t\t\t\t\t$omesto->appendChild($xml->createTextNode($model->o_mesto));\t\n\t\t\t\t\t\t\t\t$ocountry = $obchodniAdresa->appendChild($xml->createElement('NazevStatu'));\n\t\t\t\t\t\t\t\t\t$ocountry->appendChild($xml->createTextNode($o_cname));\t\n\t\t\t\t\t\t\t\t$opsc = $obchodniAdresa->appendChild($xml->createElement('KodPsc'));\n\t\t\t\t\t\t\t\t\t$opsc->appendChild($xml->createTextNode($model->o_psc));\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t$odlisnaFA = $adresy->appendChild($xml->createElement('OdlisnaFakturacniAdresa'));\n\t\t\t\t\t\t\t\tif($model->is_fa == '1')\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$isfa = \"True\";\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$isfa = \"False\";\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$odlisnaFA->appendChild($xml->createTextNode($isfa));\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif($model->is_fa == '1')\n\t\t\t\t\t\t\t{\t\t\n\t\t\t\t\t\t\t\t$fakturacniAdresa = $adresy->appendChild($xml->createElement('FakturacniAdresa'));\n\t\t\t\t\t\t\t\t\t$fnazev = $fakturacniAdresa->appendChild($xml->createElement('Nazev'));\n\t\t\t\t\t\t\t\t\t\t$fnazev->appendChild($xml->createTextNode($model->f_name));\n\t\t\t\t\t\t\t\t\t$fulice = $fakturacniAdresa->appendChild($xml->createElement('Ulice'));\n\t\t\t\t\t\t\t\t\t\t$fulice->appendChild($xml->createTextNode($model->f_ulice));\n\t\t\t\t\t\t\t\t\t$fmesto = $fakturacniAdresa->appendChild($xml->createElement('Misto'));\n\t\t\t\t\t\t\t\t\t\t$fmesto->appendChild($xml->createTextNode($model->f_mesto));\t\n\t\t\t\t\t\t\t\t\t$fcountry = $fakturacniAdresa->appendChild($xml->createElement('NazevStatu'));\n\t\t\t\t\t\t\t\t\t\t$fcountry->appendChild($xml->createTextNode($f_cname));\t\n\t\t\t\t\t\t\t\t\t$fpsc = $fakturacniAdresa->appendChild($xml->createElement('KodPsc'));\n\t\t\t\t\t\t\t\t\t\t$fpsc->appendChild($xml->createTextNode($model->f_psc));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$odlisnaPA = $adresy->appendChild($xml->createElement('OdlisnaAdresaProvozovny'));\n\t\t\t\t\t\t\t\tif($model->is_pa == '1')\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$ispa = \"True\";\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$ispa = \"False\";\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$odlisnaPA->appendChild($xml->createTextNode($ispa));\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif($model->is_pa == '1')\n\t\t\t\t\t\t\t{\t\t\n\t\t\t\t\t\t\t\t$provozovna = $adresy->appendChild($xml->createElement('Provozovna'));\n\t\t\t\t\t\t\t\t\t$pnazev = $provozovna->appendChild($xml->createElement('Nazev'));\n\t\t\t\t\t\t\t\t\t\t$pnazev->appendChild($xml->createTextNode($model->p_name));\n\t\t\t\t\t\t\t\t\t$pulice = $provozovna->appendChild($xml->createElement('Ulice'));\n\t\t\t\t\t\t\t\t\t\t$pulice->appendChild($xml->createTextNode($model->p_ulice));\n\t\t\t\t\t\t\t\t\t$pmesto = $provozovna->appendChild($xml->createElement('Misto'));\n\t\t\t\t\t\t\t\t\t\t$pmesto->appendChild($xml->createTextNode($model->p_mesto));\t\n\t\t\t\t\t\t\t\t\t$pcountry = $provozovna->appendChild($xml->createElement('NazevStatu'));\n\t\t\t\t\t\t\t\t\t\t$pcountry->appendChild($xml->createTextNode($p_cname));\t\n\t\t\t\t\t\t\t\t\t$ppsc = $provozovna->appendChild($xml->createElement('KodPsc'));\n\t\t\t\t\t\t\t\t\t\t$ppsc->appendChild($xml->createTextNode($model->p_psc));\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$kontakty = $firma->appendChild($xml->createElement('Kontakty'));\n\t\t\t\t\t\t\t\t$email = $kontakty->appendChild($xml->createElement('Email'));\n\t\t\t\t\t\t\t\t\t$email->appendChild($xml->createTextNode($model->email));\n\t\t\t\t\t\t\t\t$www = $kontakty->appendChild($xml->createElement('WWW'));\n\t\t\t\t\t\t\t\t\t$www->appendChild($xml->createTextNode($model->web));\t\n\t\t\t\t\t\t\t\t$telefon1 = $kontakty->appendChild($xml->createElement('Telefon1'));\n\t\t\t\t\t\t\t\t\t$cislo1 = $telefon1->appendChild($xml->createElement('Cislo'));\n\t\t\t\t\t\t\t\t\t\t$cislo1->appendChild($xml->createTextNode($model->phone));\n\t\t\t\t\t\t\t\t$telefon2 = $kontakty->appendChild($xml->createElement('Telefon2'));\n\t\t\t\t\t\t\t\t\t$cislo2 = $telefon2->appendChild($xml->createElement('Cislo'));\n\t\t\t\t\t\t\t\t\t\t$cislo2->appendChild($xml->createTextNode($model->mobil));\t\t\n\n\t\t\t\t\t\t\t\t$emailSpojeni = $kontakty->appendChild($xml->createElement('EmailSpojeni'));\n\t\t\t\t\t\t\t\t\t$emailSpojeni->setAttribute('ID', $model->uuid_email);\n\t\t\t\t\t\t\t\t$wwwSpojeni = $kontakty->appendChild($xml->createElement('WWWSpojeni'));\n\t\t\t\t\t\t\t\t\t$wwwSpojeni->setAttribute('ID', $model->uuid_web);\t\n\t\t\t\t\t\t\t\t$telefonSpojeni1 = $kontakty->appendChild($xml->createElement('TelefonSpojeni1'));\n\t\t\t\t\t\t\t\t\t$telefonSpojeni1->setAttribute('ID', $model->uuid_phone);\t\t\n\t\t\t\t\t\t\t\t$telefonSpojeni2 = $kontakty->appendChild($xml->createElement('TelefonSpojeni2'));\n\t\t\t\t\t\t\t\t\t$telefonSpojeni2->setAttribute('ID', $model->uuid_mobil);\n\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t$osoby = $firma->appendChild($xml->createElement('Osoby'));\n\t\t\t\t\t\t\t$hlavniOsoba = $osoby->appendChild($xml->createElement('HlavniOsoba'));\n\t\t\t\t\t\t\t\t$hlavniOsoba->setAttribute('ID', $model->uuid_kontaktni_osoba);\n\t\t\t\t\t\t\t$seznamOsob = $osoby->appendChild($xml->createElement('SeznamOsob'));\n\t\t\t\t\t\t\t\t$osoba = $seznamOsob->appendChild($xml->createElement('Osoba'));\n\t\t\t\t\t\t\t\t\t$osoba->setAttribute('ID', $model->uuid_kontaktni_osoba);\n\t\t\t\t\t\t\t\t\t\t$osnazev = $osoba->appendChild($xml->createElement('Nazev'));\n\t\t\t\t\t\t\t\t\t\t\t$osnazev->appendChild($xml->createTextNode($model->kontaktni_osoba));\n\t\t\t\t\t\t\t\t\t\t$cislo_osoby = $osoba->appendChild($xml->createElement('CisloOsoby'));\n\t\t\t\t\t\t\t\t\t\t\t$cislo_osoby->appendChild($xml->createTextNode(\"1\"));\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t// Poznamka\n\t\t\t\t\t\t$poznamka = $firma->appendChild($xml->createElement('Poznamka'));\n\t\t\t\t\t\t\t$poznamka->appendChild($xml->createTextNode($model->poznamka));\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Pohledavky\n\t\t\t\t\t\tif($model->splatnost > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$spl = $model->splatnost;\n\t\t\t\t\t\t\t$vsp = \"True\";\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$spl = 0;\n\t\t\t\t\t\t\t$vsp = \"False\";\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$pohledavky = $firma->appendChild($xml->createElement('Pohledavky'));\t\n\t\t\t\t\t\t\t$splatnostPohledavek = $pohledavky->appendChild($xml->createElement('SplatnostPohledavek'));\n\t\t\t\t\t\t\t\t$splatnostPohledavek->appendChild($xml->createTextNode($spl));\n\t\t\t\t\t\t\t$vlastniSplatnostPohledavek = $pohledavky->appendChild($xml->createElement('VlastniSplatnostPohledavek'));\n\t\t\t\t\t\t\t\t$vlastniSplatnostPohledavek->appendChild($xml->createTextNode($vsp));\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t// Adresni klice\t\n\t\t\t\t\t\t$aklice = $firma->appendChild($xml->createElement('AdresniKlice'));\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif(count($all_klice_old) > 0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tforeach($all_klice_old as $akl)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fak = $aklice->appendChild($xml->createElement('FirmaAdresniKlic'));\n\t\t\t\t\t\t\t\t\t\t$fak->setAttribute('ID', $akl->klice_uuid);\n\t\t\t\t\t\t\t\t\t\t$fak->setAttribute('Delete', '1');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//$all_klice = ZakaznikyKlice::find($id)->all();\n\t\t\t\t\t\t\t$all_klice = ZakaznikyKlice::find()->where('zakazniky_id = ' . $id)->all();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif(count($all_klice) > 0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tforeach($all_klice as $ak)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fak = $aklice->appendChild($xml->createElement('FirmaAdresniKlic'));\n\t\t\t\t\t\t\t\t\t\t$fak->setAttribute('ID', $ak->klice_uuid);\n\n\t\t\t\t\t\t\t\t\t\t$kuuid = Klice::findOne($ak->klice_id);\n\n\t\t\t\t\t\t\t\t\t\t$aklid = $fak->appendChild($xml->createElement('AdresniKlic_ID'));\n\t\t\t\t\t\t\t\t\t\t\t$aklid->appendChild($xml->createTextNode($kuuid->uuid));\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Cenova hladina\n\t\t\t\t\t\t$obchodni_podminky = $firma->appendChild($xml->createElement('ObchodniPodminky'));\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t$shladin = $obchodni_podminky->appendChild($xml->createElement('SeznamHladin'));\n\n\t\t\t\t\t\t\t\tforeach($all_ch_old as $chl)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fch = $shladin->appendChild($xml->createElement('FirmaCenovaHladina'));\n\t\t\t\t\t\t\t\t\t\t$fch->setAttribute('ID', $chl->cenova_hladina_uuid);\n\t\t\t\t\t\t\t\t\t\t$fch->setAttribute('Delete', '1');\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t//$all_ch = ZakaznikyCenovaHladina::find($id)->all();\n\t\t\t\t\t\t\t\t$all_ch = ZakaznikyCenovaHladina::find()->where('zakazniky_id = ' . $id)->all();\n\t\t\t\t\t\t\t\t$ii = 1;\n\t\t\t\t\t\t\t\tforeach($all_ch as $chld)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fch = $shladin->appendChild($xml->createElement('FirmaCenovaHladina'));\n\t\t\t\t\t\t\t\t\t\t$fch->setAttribute('ID', $chld->cenova_hladina_uuid);\n\n\t\t\t\t\t\t\t\t\t\t$chuuid = CenovaHladina::findOne($chld->cenova_hladina_id);\n\n\t\t\t\t\t\t\t\t\t\t$chladina = $fch->appendChild($xml->createElement('CenovaHladina_ID'));\n\t\t\t\t\t\t\t\t\t\t\t$chladina->appendChild($xml->createTextNode($chuuid->uuid));\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t$poradi = $fch->appendChild($xml->createElement('Poradi'));\t\n\t\t\t\t\t\t\t\t\t\t\t$poradi->appendChild($xml->createTextNode($ii));\n\t\t\t\t\t\t\t\t\t\t$ii++;\t\t\t\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Ceniky\n\t\t\t\t\t\t\t$sceniky = $obchodni_podminky->appendChild($xml->createElement('SeznamCeniku'));\n\n\t\t\t\t\t\t\t\tforeach($all_cn_old as $chl)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fcn = $sceniky->appendChild($xml->createElement('FirmaCenik'));\n\t\t\t\t\t\t\t\t\t\t$fcn->setAttribute('ID', $chl->ceniky_uuid);\n\t\t\t\t\t\t\t\t\t\t$fcn->setAttribute('Delete', '1');\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t//$all_ch = ZakaznikyCenovaHladina::find($id)->all();\n\t\t\t\t\t\t\t\t$all_cn = ZakaznikyCeniky::find()->where('zakazniky_id = ' . $id)->all();\n\t\t\t\t\t\t\t\t$iii = 1;\n\t\t\t\t\t\t\t\tforeach($all_cn as $cnld)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fcn = $sceniky->appendChild($xml->createElement('FirmaCenik'));\n\t\t\t\t\t\t\t\t\t\t$fcn->setAttribute('ID', $cnld->ceniky_uuid);\n\n\t\t\t\t\t\t\t\t\t\t$cnuuid = Ceniky::findOne($cnld->ceniky_id);\n\n\t\t\t\t\t\t\t\t\t\t$scenik = $fcn->appendChild($xml->createElement('Cenik_ID'));\n\t\t\t\t\t\t\t\t\t\t\t$scenik->appendChild($xml->createTextNode($cnuuid->uuid));\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t$poradiS = $fcn->appendChild($xml->createElement('Poradi'));\t\n\t\t\t\t\t\t\t\t\t\t\t$poradiS->appendChild($xml->createTextNode($iii));\n\t\t\t\t\t\t\t\t\t\t$iii++;\t\t\t\n\t\t\t\t\t\t\t\t}\t\n\t\t\t\t\t\n\t\t\t$xml_list = $xml->saveXML();\n\t\t\t//$insert = Moneys::insertXML($xml_list);\n\t\t\t\n\t\t\t$xml->formatOutput = true;\n\t\t\t$xml->save('xml/Firma-' . $model->ico . '.xml');\n\t\t\n\t\t\t//return $this->redirect(['view', 'id' => $model->id]);\n\t\t\treturn $this->redirect(['index']);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "839074ce127c7709388b020cbbdb80e9", "score": "0.6480052", "text": "public function actionUpdate($id)\n\t{\n\t\t$model=$this->loadModel($id);\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['Prestamo']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Prestamo'];\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('view','id'=>$model->id));\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "e6fe8a3c33835b8242e6c40e91108f1d", "score": "0.6461634", "text": "public function actionUpdate()\n\t{\n\t\t$model=$this->loadModel();\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['Creativeparkbaseinfo']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Creativeparkbaseinfo'];\n $this->formatAttributes($model);\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('view','id'=>$model->cp_id));\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "aa8f2c4021fa850dae31f399776483ab", "score": "0.6459462", "text": "public function actionUpdate($id)\n {\n\t\t\n\t\t$model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect('index');\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "338afb9b1861de2cfce47a3fcec67666", "score": "0.64449275", "text": "public function actionUpdate($id)\n {\n $us = Yii::$app->user->identity;\n if ($us->rol !== 'A' && $us->rol !== 'C') {\n return $this->goHome();\n }\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['index']);\n }\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "title": "" }, { "docid": "9f43cd9f8dbdd86c1471790149310bc8", "score": "0.6441471", "text": "public function actionUpdate($id)\n\t{\n\t\t$model=$this->loadModel($id);\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['Coleccion']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Coleccion'];\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('view','id'=>$model->id));\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "6e8135d94df56f4461572a5818924239", "score": "0.6431017", "text": "public function actionUpdate($id) {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->iddiaria]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "88cbe947604a0431b2b5a566b8c15f8b", "score": "0.6429312", "text": "public function actionUpdate($id)\n {\n\t\t$this->layout='main-admin';\n $model = $this->findModel($id);\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('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "10b7ed77a19281cc4169a1db556d01ad", "score": "0.64262575", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->caid]);\n }\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "title": "" }, { "docid": "80e22659ad1f04ae12889789fa2f7312", "score": "0.6414729", "text": "public function update()\n {\n if ($this->model('KepanitianModel')->editData($_POST) > 0) {\n Flasher::setFlash('Kepanitian berhasil', 'diedit', 'success');\n header('Location: ' . Url::URL . '/Kepanitian');\n exit;\n } else {\n Flasher::setFlash('Kepanitian gagal', 'diedit', 'warning');\n header('Location: ' . Url::URL . '/Kepanitian');\n exit;\n }\n }", "title": "" }, { "docid": "eb68ceeddfada85f276119b06964d6d7", "score": "0.6411493", "text": "public function actionUpdate($id)\n {\n \n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->cod]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "7221f93af1f2634ceafea8543618920a", "score": "0.64037675", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post())){ \n $model->hora = date('H:i:s');\n \n if($model->save()) {\n return $this->redirect(['index']);\n }\n } else {\n $abogados = $this->getAbogados();\n $estados = $this->getEstados();\n return $this->render('update', [\n 'model' => $model,\n 'abogados'=>$abogados,\n 'estados'=>$estados,\n 'id_usuario'=>$id,\n ]);\n }\n }", "title": "" }, { "docid": "f6d85476e144973ec86a1ff37f51ed0f", "score": "0.6398588", "text": "public function actionUpdate($id)\n {\n $model = Paises::findOne($id);\n\n// Sí ya esta cargada la info por post, guardamos los atributos\n if ($this->request->isPost) {\n $model->load($this->request->post());\n if ($model->save()) {\n Yii::$app->session->setFlash('succes', 'El pais se ha actualizado correctamente');\n $this->redirect([\"index\"]);\n }\n }\n// cargamos la vista de update, enviando el pais seleccionado.\n return $this->render(\"update\", [\"model\" => $model]);\n }", "title": "" }, { "docid": "e50c1b282ce90c925e15d388f8ef33d8", "score": "0.6396855", "text": "public function actionUpdate($id) {\n $model = $this->findModel($id);\n\n $model->klain_fisik = strtolower($model->klain_fisik);\n\n $model->klain_fisik = ($model->klain_fisik == 'ada') ? true : false ;\n\n if ($model->load(Yii::$app->request->post())) {\n \n $jk = $_POST['MasterKependudukan']['jenis'];\n if ($jk == 'P') {\n $jkn = 1;\n } else {\n $jkn = 0;\n }\n\n $sts = $_POST['MasterKependudukan']['status'];\n if ($sts == '0') {\n $stsn = \"BELUM KAWIN\";\n } else {\n $stsn = \"KAWIN\";\n }\n $tempat = $_POST['MasterKependudukan']['lhrtempat'];\n $tanggal = $_POST['MasterKependudukan']['lhrtanggal'];\n $rt=$_POST['MasterKependudukan']['rt'];\n $rw=$_POST['MasterKependudukan']['rw'];\n $desa=$_POST['MasterKependudukan']['alamat'];\n $nama_kec=$_POST['MasterKependudukan']['nama_kec'];\n $fisik = $_POST['MasterKependudukan']['klain_fisik'];\n if($fisik==0){\n $model->klain_fisik=\"Tidak Ada\";\n }\n else{\n $model->klain_fisik=\"Ada\";\n }\n $model->alamat= $desa.\" RT\".\" : \".$rt.\" RW : \".$rw.\" KELURAHAN/DESA: \".$desa. \" Kecamatan: \". $nama_kec;\n\n $model->agm = Agama::findOne($model->agama);\n $model->agm = $model->agm->Name;\n\n\n $model->ttl = $tempat . \":\" . $tanggal;\n $model->jk = $jkn;\n $model->sts = $stsn;\n if( $model->save()){\n\n Yii::$app->getSession()->setFlash('success', [\n 'type' => 'info',\n 'duration' => 500,\n 'icon' => 'fa fa-info-circle',\n 'message' => Yii::t('app', 'Success Edit'),\n 'title' => 'Info',\n 'positonY' => Yii::$app->params['flashMessagePositionY'],\n 'positonX' => Yii::$app->params['flashMessagePositionX']\n ]);\n return $this->redirect(['index']);\n }\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "59f81b14715c65771ceb29d5621c3f36", "score": "0.63933307", "text": "public function actionUpdate($id)\n {\n\t\n\t\n\t\t$modelName = $this->getModel();\n $model = $this->findModel($id);\n\t\t$model->dt_update = date('c');\n\t\t$model->id_user_create = 1;\n\t\t$model->id_user_update = 1;\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n\t\t\n \n\t\t\t\t\treturn $this->redirect(['index']);\n \n \n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "2ff4200d2dc39fdd1864e94cbc90f3f1", "score": "0.6392367", "text": "public function actionUpdate()\n {\n $models = Unit::find()\n ->addOrderBy('root, lft')\n ->all();\n\n if (isset($_POST['Unit'])) {\n /*\n * 设置先加上 $diff 的原因,以免出现保存错误的情况。\n * 如果设置的编号过大,则该 $diff 可能失效。\n */\n $diff = 10000;\n $tmp_units = $_POST['Unit'];\n $i = 0;\n $transaction = Yii::$app->db->beginTransaction();\n foreach ($tmp_units as $tmp_unit) {\n $models[$i]->id = $tmp_unit['id'] + $diff;\n $models[$i]->save();\n $i++;\n }\n $transaction->commit();\n\n $i = 0;\n $transaction = Yii::$app->db->beginTransaction();\n foreach ($tmp_units as $tmp_unit) {\n $models[$i]->id = $tmp_unit['id'];\n $models[$i]->save();\n $i++;\n }\n $transaction->commit();\n Yii::$app->session->setFlash('success', '您重新设置成功啦!');\n return $this->refresh();\n }\n\n return $this->render('update', [\n 'models' => $models,\n ]);\n }", "title": "" }, { "docid": "8efcb0bacfd6fce38722dc8d49d1a632", "score": "0.6391734", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id); \n\t\tif($model->ref_satker_id!=(int)Yii::$app->user->identity->employee->ref_satker_id){\n\t\t\treturn $this->redirect(['index']);\n\t\t}\n\t\tif($model->executor != 'GENERAL3'){\n\t\t\treturn $this->redirect(['index']);\n\t\t}\n if ($model->load(Yii::$app->request->post())) {\n \t\n if($model->save()){\n\t\t\t\tYii::$app->session->setFlash('success', 'Data saved');\n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n // error in saving model\n\t\t\t\tYii::$app->session->setFlash('error', 'There are some errors');\n } \n }\n\t\telse{\n\t\t\t//return $this->render(['update', 'id' => $model->id]);\n\t\t\treturn $this->render('update', [\n 'model' => $model,\n ]);\n\t\t}\n }", "title": "" }, { "docid": "5a19382f054a203882d13abf5fef3a6e", "score": "0.6390762", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n // $model->ringkas_dispo = $model->letterDecrypt($model->ringkas_dispo,$model->suratMasuk->tujuanDispo->password,User::findOne($model->tujuan_id)->password);\n $surat = SuratMasuk::findOne($id);\n $users = ArrayHelper::map(User::find()->asArray()->all(), 'id', 'nama_lengkap');\n $keamanan = ArrayHelper::map(Keamanan::find()->asArray()->all(), 'id', 'keamanan');\n $kecepatan = ArrayHelper::map(Kecepatan::find()->asArray()->all(), 'id', 'kecepatan');\n\n if ($model->load(Yii::$app->request->post())) {\n // $model->ringkas_dispo = $model->letterEncrypt($model->ringkas_dispo,Yii::$app->user->identity->password,User::findOne($model->tujuan_id)->password);\n if ($model->save(false)) {\n return $this->redirect(['view', 'id' => $model->id]); \n }\n }\n\n return $this->render('update', [\n 'model' => $model,\n 'surat' => $surat,\n 'users' => $users,\n 'keamanan' => $keamanan,\n 'kecepatan' => $kecepatan,\n ]);\n }", "title": "" }, { "docid": "f7034217526c0e9b100f85aca5f3e1ce", "score": "0.63898885", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->id_alumno]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "3b39bf0f0d472979474d42dfecc5535d", "score": "0.63887185", "text": "public function actionUpdate()\n\t{\n\t\t$model=$this->loadModel();\n\t\tif(isset($_POST['Transaction']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Transaction'];\n\t\t\tif($model->save())\n\t\t\t\t$this->redirect(array('view','id'=>$model->id));\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t));\n\t}", "title": "" }, { "docid": "afc42a54ccdd8e2f2a09a067f6fdc122", "score": "0.63859564", "text": "public function actionUpdate($id)\n {\n if (Yii::$app->user->isGuest) {\n return $this->goHome();\n }else{\n\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n // return $this->redirect(['view', 'id' => $model->id]);\n // return $this->redirect(['index']);\n return $this->redirect([Url::previous()]);\n }\n\n if (Yii::$app->user->isGuest) {\n return $this->goHome();\n \t}else{\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }\n }", "title": "" }, { "docid": "b933fa7adc61c95e0ccc4965b4a86885", "score": "0.6380795", "text": "public function actionUpdate($id)\n\t{\n\t\t$model=$this->loadModel($id);\n\n\t\t// Uncomment the following line if AJAX validation is needed\n\t\t// $this->performAjaxValidation($model);\n\n\t\tif(isset($_POST['Usuarios']))\n\t\t{\n\t\t\t$model->attributes=$_POST['Usuarios'];\n\t\t\t$createCommand = Yii::app()->db->createCommand();\n\t\t\t$model->contrasena = $model->hashPassword($_POST['contrasena'], $session = $model->generateSalt());\n\t\t\t$model->sesion = $session;\n\t\t\tif($model->save()){\n\t\t\t\tif ($model->fk_tipo == 1) {\n\t\t\t\t\t$createCommand->update('auth_asignacion', array(\n\t\t\t\t\t\t'itemname' => 'rol_administrador',\n\t\t\t\t\t\t), 'userid=:id', array(':id' => $model->id));\n\t\t\t\t}else if ($model->fk_tipo == 2) {\n\t\t\t\t\t$createCommand->update('auth_asignacion', array(\n\t\t\t\t\t\t'itemname' => 'rol_digitador',\n\t\t\t\t\t\t), 'userid=:id', array(':id' => $model->id));\n\t\t\t\t}else if ($model->fk_tipo == 3) {\n\t\t\t\t\t$createCommand->update('auth_asignacion', array(\n\t\t\t\t\t\t'itemname' => 'rol_consultas',\n\t\t\t\t\t\t), 'userid=:id', array(':id' => $model->id));\n\t\t\t\t}else if ($model->fk_tipo == 4) {//coordinador\n\t\t\t\t\t$createCommand->update('auth_asignacion', array(\n\t\t\t\t\t\t'itemname' => 'rol_analista_odt',\n\t\t\t\t\t\t), 'userid=:id', array(':id' => $model->id));\n\t\t\t\t}else if ($model->fk_tipo == 5) {//operario\n\t\t\t\t\t$createCommand->update('auth_asignacion', array(\n\t\t\t\t\t\t'itemname' => 'rol_brigada',\n\t\t\t\t\t\t), 'userid=:id', array(':id' => $model->id));\n\t\t\t\t}\n\t\t\t\t$this->redirect(array('view','id'=>$model->id));\n\t\t\t}\n\t\t}\n\n\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t\t));\n\t}", "title": "" }, { "docid": "62be396ac79c8b860ea32b1acb42e1c8", "score": "0.63743556", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n $modelConfort = Confort::findOne(['aviso_id'=>$id]);\n $modelSeguridad = Seguridad::findOne(['aviso_id'=>$id]);\n $modelMultimedia = Multimedia::findOne(['aviso_id'=>$id]);\n $modelExterior = Exterior::findOne(['aviso_id'=>$id]);\n\n if ($model->tipo == Aviso::AUTO){\n $model->scenario = Aviso::SCENARIO_AUTO;\n }elseif ($model->tipo == Aviso::CAMION){\n $model->scenario = Aviso::SCENARIO_CAMION;\n }elseif ($model->tipo == Aviso::CASARODANTE){\n $model->scenario = Aviso::SCENARIO_CRODANTE;\n }\n\n if (Yii::$app->user->can('updateArticle', ['model' => $model]))\n {\n if (\n $model->load(Yii::$app->request->post())\n && $modelConfort->load(Yii::$app->request->post())\n && $modelSeguridad->load(Yii::$app->request->post())\n && $modelMultimedia->load(Yii::$app->request->post())\n && $modelExterior->load(Yii::$app->request->post())\n //&& $model->validate()\n ){\n //if (Model::loadMultiple([$model,$modelConfort,$modelSeguridad,$modelMultimedia,$modelExterior],Yii::$app->request->post())){\n if ($model->validate()){\n $model->save(false);\n $modelConfort->save(false);\n $modelSeguridad->save(false);\n $modelMultimedia->save(false);\n $modelExterior->save(false);\n\n //Si es posible basica, mostrar carga exitosa y sujeto a revision\n return $this->redirect(['admin']);\n\n }\n }\n else\n {\n return $this->render('update', [\n 'model' => $model,\n 'modelConfort' => $modelConfort,\n 'modelSeguridad' => $modelSeguridad,\n 'modelMultimedia' => $modelMultimedia,\n 'modelExterior' => $modelExterior\n ]);\n }\n }\n else\n {\n throw new MethodNotAllowedHttpException(Yii::t('app', 'You are not allowed to access this page.'));\n } \n }", "title": "" }, { "docid": "02091a81c444ff261dd367fb2c68f39d", "score": "0.6361388", "text": "public function updating($model)\n {\n //\n }", "title": "" }, { "docid": "bc066b729addfb3c0152c5f788a4b632", "score": "0.63612753", "text": "public function actionUpdate( $id ) \r\n { \r\n if ( isset( $_SESSION['idContribuyente'] ) ) {\r\n \r\n $model = $this->findModel( $id );\r\n $btn = Yii::$app->request->post( 'btn' );\r\n\r\n if( $model->base_calculo == '1' || $model->base_calculo == '5' ) { \r\n\r\n $model->cantidad_propagandas='0';\r\n } \r\n\r\n if( $model->load( Yii::$app->request->post() ) && $model->save() && $btn=='crud' ) {\r\n\r\n $conexion = new ConexionController();\r\n $conn = $conexion->initConectar( 'db' );\r\n $conn->open();\r\n $id_contribuyente = $model->id_contribuyente;\r\n $ano_impositivo = $model->ano_impo;\r\n $direccion = $model->direccion;\r\n $id_cp = $model->id_cp;\r\n $clase_propaganda = $model->clase_propaganda;\r\n $tipo_propaganda = $model->tipo_propaganda;\r\n $uso_propaganda = $model->uso_propaganda;\r\n $medio_difusion = $model->medio_difusion;\r\n $medio_transporte = $model->medio_difusion;\r\n $fecha_desde = $model->fecha_desde;\r\n $cantidad_tiempo = $model->cantidad_tiempo;\r\n $id_tiempo = $model->id_tiempo;\r\n $inactivo = $model->inactivo;\r\n $id_sim = $model->id_sim;\r\n $cantidad_base = $model->cantidad_base;\r\n $base_calculo = $model->base_calculo;\r\n $cigarros = $model->cigarros;\r\n $bebidas_alcoholicas = $model->bebidas_alcoholicas;\r\n $cantidad_propagandas = $model->cantidad_propagandas;\r\n $planilla = $model->planilla;\r\n $idioma = $model->idioma;\r\n $observacion = $model->observacion;\r\n $fecha_fin = $model->fecha_fin;\r\n $fecha_guardado = $model->fecha_guardado;\r\n $cantidad_base = str_replace( '.', '', $cantidad_base );\r\n $cantidad_base = str_replace( ',', '.', $cantidad_base );\r\n\r\n $tabla = 'propagandas'; \r\n $arrayDatos = [ 'id_contribuyente' => $id_contribuyente, 'ano_impositivo' => $ano_impositivo, 'direccion' => strtoupper($direccion), 'id_cp' => $id_cp, 'clase_propaganda' => $clase_propaganda, 'tipo_propaganda' => $tipo_propaganda, 'uso_propaganda' => $uso_propaganda, 'medio_difusion' => $medio_difusion, 'medio_transporte' => $medio_transporte, 'fecha_desde' => $fecha_desde, 'cantidad_tiempo' => $cantidad_tiempo, 'id_tiempo' => $id_tiempo, 'inactivo' => $inactivo, 'id_sim' => $id_sim, 'cantidad_base' => $cantidad_base, 'base_calculo' => $base_calculo, 'cigarros' => $cigarros, 'bebidas_alcoholicas' => $bebidas_alcoholicas, 'cantidad_propagandas' => $cantidad_propagandas, 'planilla' => $planilla, 'idioma' => $idioma, 'observacion' => strtoupper($observacion), 'fecha_fin' => $fecha_fin, 'fecha_guardado' => $fecha_guardado ];\r\n $arrayCondition = [ 'id_impuesto' => $id ]; \r\n $transaccion = $conn->beginTransaction();\r\n\r\n if( $conexion->modificarRegistro( $conn, $tabla, $arrayDatos, $arrayCondition ) ) { \r\n\r\n $transaccion->commit(); \r\n $tipoError = 0;\r\n $msg = \"SUCCESSFULLY MODIFIED! .... Wait\";\r\n\t\t\t\t\t\t\t$url = \"<meta http-equiv='refresh' content='3; \".Url::toRoute(\"propaganda/propaganda/view\").\"&id=$id'>\";\r\n return $this->render( '/mensaje/mensaje', [ 'msg' => $msg, 'url' => $url, 'tipoError' => $tipoError ] );\r\n } else {\r\n $transaccion->rollBack();\r\n $tipoError = 1;\r\n $msg = \"ERROR OCCURRED!....Wait\";\r\n\t\t\t\t\t\t\t$url = \"<meta http-equiv='refresh' content='3; \".Url::toRoute(\"propaganda/propaganda/update\").\"&id=$id'>\";\r\n return $this->render( '/mensaje/mensaje', [ 'msg' => $msg, 'url' => $url, 'tipoError' => $tipoError ] );\r\n } \r\n $this->conexion->close();\r\n } else {\r\n return $this->render('update', ['model' => $model]);\r\n }\r\n } else {\r\n echo \"No hay Contribuyente!!!...\";\r\n } \r\n }", "title": "" }, { "docid": "0d3a34c712626037695e7f8ec50850b9", "score": "0.6359842", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n $customer_id = $model->customer_id;\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n //return $this->redirect(['view', 'id' => $model->id]);\n return $this->goBack();\n } else {\n return $this->render('update', [\n 'model' => $model,\n 'customer_id' => $customer_id\n ]);\n }\n }", "title": "" }, { "docid": "36deca9da90c2e1a3f1f2f46ddb1a849", "score": "0.63491094", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save())\n {\n return $this->redirect(['view', 'id' => $model->id]);\n } else\n {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "784e3ded70aef7f255fc6ef32538625f", "score": "0.63481164", "text": "public function update()\r\n {\r\n // Check if session data(id) is available\r\n if(isset($_SESSION['id'])){\r\n $id = $this->input->post('id');\r\n // new values to update\r\n $values = array(\r\n 'nama_obat' => htmlspecialchars($this->input->post('nama')),\r\n 'harga_jual' => htmlspecialchars($this->input->post('hargajual'))\r\n );\r\n // doing update user data\r\n $sql = $this->Common_model->update('m_obat', $values, ['id'=>$id]);\r\n if($sql){\r\n // set flashdata success\r\n $this->session->set_flashdata('success', \"<strong> Sukses!</strong> Berhasil mengubah data.\");\r\n redirect(base_url().'MasterObat');\r\n }else{\r\n // set flashdata error\r\n $this->session->set_flashdata('error', \"<strong> Error!</strong> Gagal mengubah data.\");\r\n redirect(base_url().'MasterObat');\r\n }\r\n }else{\r\n redirect(base_url().'Login');\r\n }\r\n }", "title": "" }, { "docid": "ed8c34e7c786cdf292c50313a65d2646", "score": "0.6346525", "text": "public function actionUpdate( $VID )\n {\n $request = Yii::$app->request;\n $model = Viecle::findOne($VID); // viecle\n $customer = $model->owner0;\n \n if($request->isPost){ \n // customer\n if( $customer->load($request->post()) && $customer->validate() ){\n $customer->type = \"GENERAL\";\n $customer->save();\n }\n else{\n var_dump($customer->errors);\n die();\n }\n // viecle\n if ($model->load($request->post()) && $model->validate()) {\n// $lastCustomer = Customer::find()->orderBy(['CID' => SORT_DESC])->one(); \n// $model->owner = $lastCustomer->CID;\n $model->save();\n } \n else {\n var_dump($model->errors);\n die();\n }\n return $this->redirect(['index']);\n }\n \n $viecleName = ViecleName::find()->all();\n $viecleModels = ViecleModel::find()->where(['viecle_name' => $model->viecle_name])->all();\n \n return $this->render('update', [\n 'model' => $model,\n 'customer' => $customer,\n 'viecleName' =>$viecleName,\n 'viecleModels' => $viecleModels,\n ]);\n }", "title": "" }, { "docid": "9edc69453744d57cb717d12a5b81818b", "score": "0.6344513", "text": "public function actionUpdate()\n {\n $model = Seo::findOne(1);\n\n if ($model->load(Yii::$app->request->post()) && $model->store()) {\n Yii::$app->session->setFlash('success', '设置成功。');\n }else{\n Yii::$app->session->setFlash('error', $model->getFirstErrors());\n }\n\n //获取快速通道 和 关注我\n $quicks = unserialize($model->fastchannel);\n $follows = unserialize($model->followme);\n\n\n return $this->render('update', [\n 'model' => $model,\n 'quicks' => $quicks,\n 'follows' => $follows,\n ]);\n }", "title": "" }, { "docid": "87b926fe445aad7f977716a04867f1fb", "score": "0.6344127", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->No_transaksi]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "fa3f91e3afbd3d801e586e0e45f8c033", "score": "0.6342881", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n //return $this->redirect(['index']);\n return $this->redirect(['view','id'=>$model->id]);\n }\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "title": "" }, { "docid": "090fcd1588d1860b01b985aeeee9a80f", "score": "0.63316566", "text": "function update() {\n $this->model->update();\n }", "title": "" }, { "docid": "ec2b577b12c6d5ba359858f5200134f1", "score": "0.63269365", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n\n\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['dashboard', 'id' => $model->id]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "76107f997402a6c5311a0c938d2abbfb", "score": "0.63240623", "text": "public function actionUpdate($id) {\n\t\t$model = $this->findModel ( $id );\n\t\t\n\t\tif ($model->load ( Yii::$app->request->post () ) && $model->save ()) {\n\t\t\treturn $this->redirect ( [ \n\t\t\t\t\t'view','id' => $model->id \n\t\t\t] );\n\t\t} else {\n\t\t\treturn $this->render ( 'update', [ \n\t\t\t\t\t'model' => $model \n\t\t\t] );\n\t\t}\n\t}", "title": "" }, { "docid": "9c5f20790a1f6d459f0324dd9e0d27a5", "score": "0.63218206", "text": "public function actionUpdate($id) {\n\t\t$model = $this->findModel ( $id );\n\t\t\n\t\tif ($model->load ( Yii::$app->request->post () ) && $model->save ()) {\n\t\t\treturn $this->redirect ( [ \n\t\t\t\t\t'view',\n\t\t\t\t\t'id' => $model->id \n\t\t\t] );\n\t\t}\n\t\t\n\t\treturn $this->render ( 'update', [ \n\t\t\t\t'model' => $model \n\t\t] );\n\t}", "title": "" }, { "docid": "a6adaf1ed36bed9a54eadfba559ecbde", "score": "0.63205475", "text": "public function actionUpdate($id)\r\n {\r\n $model = $this->findModel($id);\r\n\r\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\r\n return $this->redirect(['view', 'id' => $model->id_condom]);\r\n }\r\n\r\n return $this->render('update', [\r\n 'model' => $model,\r\n ]);\r\n }", "title": "" }, { "docid": "bec3ced0841bd71a581d27dce83cbf7a", "score": "0.6319043", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post())) {\n $cek = MataKuliahTayang::findOne([\n 'id_tahun_ajaran' => $model->id_tahun_ajaran,\n 'semester' => $model->semester,\n 'id_ref_mata_kuliah' => $model->id_ref_mata_kuliah,\n 'id_ref_kelas' => $model->id_ref_kelas,\n 'status' => '1'\n ]);\n if (!$cek || ($cek && ($cek->id==$model->id))) {\n $model->updated_user = Yii::$app->user->identity->username;\n $model->save();\n Yii::$app->session->setFlash('warning', [['Update', 'Data Berhasil Diperbarui']]);\n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n $model = $this->findModel($cek->id);\n Yii::$app->getSession()->setFlash('alert', [\n 'text' => \"Gagal Memasukkan Data\n {$model['refMataKuliah']->nama}\n Tahun {$model['tahunAjaran']->tahun}\n Semester {$model->semester} \n Kelas {$model['refKelas']->kelas}\",\n 'title' => 'Data Pernah Dimasukkan',\n 'type' => 'error',\n 'timer' => 20000,\n 'showConfirmButton' => false\n ]);\n return $this->redirect(['update', 'id'=>$model->id]);\n }\n\n return $this->redirect(['view', 'id' => $model->id]);\n }\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "title": "" }, { "docid": "c8eb0125749e23dd2ba9d7e8aac89e63", "score": "0.6315733", "text": "public function actionUpdate($Tahun, $Kd_Prov, $Kd_Kab, $Kd_Kec, $Kd_Kel, $Kd_Urut_Kel, $Kd_Lingkungan, $Kd_Media)\n {\n $model = $this->findModel($Tahun, $Kd_Prov, $Kd_Kab, $Kd_Kec, $Kd_Kel, $Kd_Urut_Kel, $Kd_Lingkungan, $Kd_Media);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'Tahun' => $model->Tahun, 'Kd_Prov' => $model->Kd_Prov, 'Kd_Kab' => $model->Kd_Kab, 'Kd_Kec' => $model->Kd_Kec, 'Kd_Kel' => $model->Kd_Kel, 'Kd_Urut_Kel' => $model->Kd_Urut_Kel, 'Kd_Lingkungan' => $model->Kd_Lingkungan, 'Kd_Media' => $model->Kd_Media]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "d902504c97cece5daf6f77e8a3740c76", "score": "0.6315272", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n $model->aliyeingiza = Yii::$app->user->identity->username;\n $model->muda = date('Y-m-d H:i:s');\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('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "63059edffea5c57a8b5302b3f36b2b02", "score": "0.6314067", "text": "public function actionUpdate($id)\n {\t$this->changeDBPuid();\n $model = $this->findModel($id);\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('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "941b01f57c9ee3622d1ba94e386c9ee8", "score": "0.6310545", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->idServicio]);\n }\n $modCli= new Clientes();\n $cli = $modCli->find()->all();\n $modEqui = new Equiposervicios();\n $equi = $modEqui->find()->all();\n\n\n return $this->render('update', [\n 'model' => $model,'cli'=>$cli,'equi'=>$equi,\n ]);\n }", "title": "" }, { "docid": "d027b4e605301db81f7974cf100d3b21", "score": "0.6308224", "text": "public function actionUpdate($id) {\n $model = $this->loadModel($id);\n\n // Uncomment the following line if AJAX validation is needed\n // $this->performAjaxValidation($model);\n\n if (isset($_POST['Cargos'])) {\n $model->attributes = $_POST['Cargos'];\n if ($model->save()) {\n\n Auditoria::model()->registrarAccion('', $model->ID_CARGO, $model->NOMBRE_CARGO);\n $this->redirect(array('view', 'id' => $model->ID_CARGO));\n }\n }\n\n $this->render('update', array(\n 'model' => $model,\n ));\n }", "title": "" }, { "docid": "21f4cb059acd225347149b532265cbee", "score": "0.63064855", "text": "public function actionUpdate() {\n $model = $this->loadModel();\n if (isset($_POST['Account'])) {\n $model->attributes = $_POST['Account'];\n if ($model->save())\n $this->redirect(array('view', 'id' => $model->id));\n }\n\n $this->render('update', array('model' => $model));\n }", "title": "" }, { "docid": "8acc9abda36ca7aedc0fdb2098cdce81", "score": "0.6299582", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->cane_id]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "e9f5aa4044fef01d32fc5637fc9c212d", "score": "0.62944657", "text": "public function updateCafe()\n {\n // // $data['jurusan'] = ['Teknik Informatika', 'Teknik Mesin', 'Teknik Planologi', 'Teknik Pangan', 'Teknik Lingkungan'];\n\n // $this->form_validation->set_rules('id_user', 'ID User', 'required');\n // $this->form_validation->set_rules('email', 'Email', 'required|valid_email');\n // if ($this->form_validation->run() == false) {\n // $this->load->view('templates/header', $data);\n // $this->load->view('admin/admin-user/update', $data);\n // $this->load->view('templates/footer');\n // echo \"Gagal\";\n // } else {\n $status = $this->Admin_cafe_model->updateCafe();\n if ($status['status'] === true) {\n $this->session->set_flashdata('flash', 'Diubah');\n redirect('admin/adminCafe');\n } else {\n $this->session->set_flashdata('error', 'Diubah');\n redirect('admin/adminCafe');\n }\n // }\n }", "title": "" }, { "docid": "53c74515efefc789b3c29a00129ef134", "score": "0.6293456", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->validate()) {\n\n\n $model->save(false);\n return $this->redirect(['view', 'id' => $model->id]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "0d3c18788b2e35e166a2ee6fd66452e4", "score": "0.6288254", "text": "public function update($usua_id)\n {\n $usuario=new UsuarioModel;\n $usuario->update_usuar($usua_id);\n redirect(base_url('usuario'));\n }", "title": "" }, { "docid": "1dd8058ceec8ba486041f8f34e993119", "score": "0.628801", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['index',\n// 'id' => $model->id\n \n ]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "704369e4db4eec1398e0314e7d8ac66c", "score": "0.6284434", "text": "public function actionUpdate($id)\n {\n $us = Usuarios::find()->where(['id' => Yii::$app->user->id])->one();\n if ($us->rol !== 'A' && $us->rol !== 'C') {\n return $this->goHome();\n }\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['index']);\n }\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "title": "" }, { "docid": "7013912e8d28c6ce7d886cf9c30cd030", "score": "0.6283465", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n Yii::$app->getSession()->setFlash('success', Yii::t('app', 'Kategorija je izmijenjena.'));\n return $this->redirect(['update', 'id' => $model->katID]);\n } elseif (!\\Yii::$app->request->isPost) {\n $model->load(Yii::$app->request->get());\n $model->atributiIDs = ArrayHelper::map($model->atributi, 'nazivAtr', 'nazivAtr');\n }\n\n return $this->render('update', ['model' => $model]);\n }", "title": "" }, { "docid": "8d7d4fea159f953ee9e52e07c95bdce7", "score": "0.62805176", "text": "public function update(){\n\t\t\t// lay bien id truyen tu url\n\t\t\t$id = isset($_GET[\"id\"]) ? $_GET[\"id\"] : 0;\n\t\t\t// goi ham tu model de lay du lieu\n\t\t\t$record = $this->modelGetRecord($id);\n\t\t\t// tao bien $action de dua vao thuoc tinh action cua form\n\t\t\t$action = \"index.php?controller=Customers&action=updatePost&id=$id\";\n\t\t\t//goi view, truyen du lieu ra view\n\t\t\t$this->loadView(\"CustomersFormView.php\",[\"record\"=>$record,\"action\"=>$action]);\n\t\t}", "title": "" }, { "docid": "6be641333beb5d68ea8179e88522c970", "score": "0.62756366", "text": "public function actionUpdate($id)\n {\n $this->view->params['no_wrapp'] = true;\n \n $model = $this->findModel($id);\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('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "7349cdcebc6286e2bacd0dc61304c83b", "score": "0.62700903", "text": "public function actionUpdate($id) {\n $model = $this->loadModel($id);\n\n// Uncomment the following line if AJAX validation is needed\n// $this->performAjaxValidation($model);\n\n if (isset($_POST['Plantel'])) {\n $model->attributes = $_POST['Plantel'];\n if ($model->save())\n $this->redirect(array('view', 'id' => $model->id));\n }\n\n $this->render('update', array(\n 'model' => $model,\n ));\n }", "title": "" }, { "docid": "572f129c061d598687f86064a4a8e01c", "score": "0.62699175", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) \n\t\t{\n\t\t\tswitch ($model->education) \n\t\t\t{\n\t\t\t\tcase \"0\":\n\t\t\t\t\t$model->education = \"SD\";\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"1\":\n\t\t\t\t\t$model->education = \"SMP\";\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"2\":\n\t\t\t\t\t$model->education = \"SMA\";\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"3\":\n\t\t\t\t\t$model->education = \"D3\";\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"4\":\n\t\t\t\t\t$model->education = \"S1\";\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"5\":\n\t\t\t\t\t$model->education = \"S2\";\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"6\":\n\t\t\t\t\t$model->education = \"S3\";\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif ($model->gender == 0)\n\t\t\t\t$model->gender = 'Pria';\n\t\t\telse $model->gender = 'Wanita';\n\t\t\t\n\t\t\t$model->save();\n $activitylog = new ActivityLog();\n $activitylog->User_ID = Yii::$app->user->id;\n $activitylog->Timestamp = date('Y-m-d H:i:s');\n $activitylog->Activity = 'Mengubah profil';\n $activitylog->save();\n return $this->redirect(['view', 'User_ID' => $model->id]);\n } \n\t\telse \n\t\t{\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "934d61d3675f2310a7b29e57d04a55f1", "score": "0.62688065", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n \n $users = $this->getUsers();\n $contragents = $this->getContragents();\n $cat_title = $this->categoryName($model->direction, $model->level);\n $contragent_pol = '';\n $direction = $model->direction;\n $level = $model->level;\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n $this->setUserLetters($model->id, $model->users, true);\n $contragent_pol = $this->setContragentsLetters($model->id, $model->contragent, true);\n $this->setEvent(Yii::$app->user->identity->id, $model->id, 'Изменено');\n $model->contragent_id = $contragent_pol;\n $model->update();\n Yii::$app->session->setFlash('success', \"Корреспонденция изменена\");\n return $this->redirect(['view', 'id' => $model->id]);\n }\n\n return $this->render('update', compact(['model', 'users', 'contragents', 'level', 'direction', 'cat_title']));\n }", "title": "" }, { "docid": "9ebeb5dd6add9352dad9c40eff168453", "score": "0.6266027", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n Yii::$app->session->setFlash('success','\"Вопрос/ответ\" успешно обновлен');\n return $this->redirect(['index', 'id' => $model->id]);\n }\n\n if ($model->hasErrors()){\n Yii::$app->session->setFlash('error',Html::errorSummary($model,['header' => 'Исправьте следующие ошибки:']));\n }\n\n return $this->render('update', [\n 'model' => $model,\n ]);\n }", "title": "" }, { "docid": "9dea69e5ba68dd973503773a4c55e5d7", "score": "0.62660086", "text": "public function actionUpdate($id)\n {\n $id_boda = Yii::$app->user->id;\n if (Yii::$app->request->post('_asnew') == '1') {\n $model = new Mesa();\n } else {\n $model = $this->findModel($id);\n }\n\n if ($model->loadAll(Yii::$app->request->post()) && $model->saveAll()) {\n return $this->redirect(['index']);\n } else {\n if (Yii::$app->request->isAjax) {\n return $this->renderAjax('update', [\n 'model' => $model,\n ]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }\n }", "title": "" }, { "docid": "ba652f220240f69ac06172699234dae9", "score": "0.6264822", "text": "public function actionUpdate($id)\n {\n $model = $this->findModel($id);\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view', 'id' => $model->factuur_id]);\n } else {\n return $this->render('update', [\n 'model' => $model,\n ]);\n }\n }", "title": "" }, { "docid": "78f0cb7a9bb4fe4eb10fe4a9f97e7132", "score": "0.62598187", "text": "public function actionUpdate($id)\n\t\t{\n\t\t\t$model=$this->loadModel($id);\n\t\t\tif(isset($_POST['SolicitudesServicio']))\n\t\t\t{\n\t\t\t$model->attributes=$_POST['SolicitudesServicio'];\n\t\t\tif($model->save())\n\t\t\t$this->redirect(array('index','id'=>$model->id));\n\t\t\t}\n\n\t\t\t$this->render('update',array(\n\t\t\t'model'=>$model,\n\t\t\t));\n\t\t}", "title": "" } ]
7e509423c6eaf766e934040a6dda25a7
Uvecavanje polja za 1 jedinicu
[ { "docid": "ccf0e89d32a2042e9a86226363d074af", "score": "0.0", "text": "public function incrementField($table,$field,$kveri)\r\n {\r\n $sql = \"UPDATE `{$table}` SET `{$field}`= {$field} + 1 WHERE 1 {$kveri}\";\r\n $all = $this->conn->executeQuery($sql);\r\n if ($all){\r\n echo \"1\";\r\n } else {\r\n echo \"-1\";\r\n }\r\n }", "title": "" } ]
[ { "docid": "d0ae5cb960b257efe4545a096b679849", "score": "0.6060701", "text": "public function izracunajPlatu(){\n if($this->brsati<40){\n return $this->zarada*0.8;\n }\n if($this->brsati>40){\n return $this->zarada*1.3;\n }\n return $this->zarada;\n }", "title": "" }, { "docid": "6905bbf8517637c2def2f8dd9a7384b2", "score": "0.60038877", "text": "protected function _potegowanie(){\n $this->_wynik = $this->_liczbaA ** $this->_liczbaB;\n }", "title": "" }, { "docid": "fbf71a0fbb64f20e34532957da3c150d", "score": "0.58465517", "text": "function oppervlakte()\n\t\t\t\t{\n\t\t\t\t\t\n\t\t\t\t}", "title": "" }, { "docid": "ef69898496077e961f4c3c5e19e83db7", "score": "0.5809163", "text": "function brakuje()\n\t{\n\t\t$suma=0;\n\t\tfor($i=0; $i< $this->liczba_stanow_c ; $i++)\n\t\t\t{\n\t\t\t\t$suma= $suma + $this->tablica_stan[$i];\n\t\t\t}\n\t\t\t$brakuje = $this->rozmiar_parlamentu_c - $suma;\n\t\t\t\n\t\treturn $brakuje;\n\t}", "title": "" }, { "docid": "fe331ae32c16f74a106bf3079c9d7551", "score": "0.5751206", "text": "function cariPosisi($batas){\nif(empty($_GET[lap_pembelian])){\n\t$posisi=0;\n\t$_GET[lap_pembelian]=1;\n}\nelse{\n\t$posisi = ($_GET[lap_pembelian]-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "771e83ff978e6259d450d4ae47d7cd43", "score": "0.5737766", "text": "public function udomiPretrazi() {\n $od=$_GET['starostOd'];\n $do=$_GET['starostDo'];\n $v=$_GET['vrsta'];\n $r=$_GET['rasa'];\n $p=$_GET['pol'];\n \n if($od=='') $od=0;\n if($do=='') $do=20;\n if($v=='vrsta') $v='%';\n if($p=='pol') $p='%';\n if($r=='') $r='%';\n \n \n $oglasiModel=new Oglasi();\n $udomiModel=new UdomiModel();\n \n $array = ['pol' => $p, 'vrsta' => $v, 'rasa' => $r];\n $celiOglasi=$oglasiModel->like($array)->findAll();\n \n $niz=array();\n \n foreach ($celiOglasi as $oglasC) {\n $og=$udomiModel->find($oglasC->oglasId);\n \n if($og!=null && $og->starost!='' && ((int)$og->starost >= (int)$od && (int)$og->starost <= (int)$do)){\n array_push($niz, $oglasC->oglasId);\n }\n } \n \n \n $slikaModel=new SlikeModel();\n $slike=$slikaModel->findAll();\n \n if(empty($niz)){\n \n $this->prikaz('Views/stranice/Udomi.php', ['slike'=>$slike], ['oglasi'=>[]]);\n }\n else{\n $oglasi=$udomiModel->find($niz);\n $this->prikaz('Views/stranice/Udomi.php', ['slike'=>$slike], ['oglasi'=>$oglasi]);\n }\n }", "title": "" }, { "docid": "70e726386215646568113b7d0fb9a8c1", "score": "0.5700318", "text": "function os_patio($id_ot){\n\t$queryos_patio=\"SELECT distinct OS.id_os,OS.origen\n FROM os_detalle OD\n join os OS on (OD.id_os=OS.id_os)\n where OD.ot_id=$id_ot\";\n $rq_1 = tep_db_query($queryos_patio);\n $res_1 = tep_db_fetch_array( $rq_1 );\n if($res_1['origen']=='P'){\n return $res_1['origen'];\n }\n}", "title": "" }, { "docid": "72bdfdd7901f33f83c11103768b0f95b", "score": "0.56988734", "text": "function prosecanBrojZadataka($zbirka)\n{\n return $prosecanBrojZadataka = $zbirka->getBrojZadataka()/$zbirka->getBrojStrana();\n}", "title": "" }, { "docid": "1514dfe15e3c36f1bc742e5737208c61", "score": "0.5639415", "text": "public function pujaMaxima($p){\r\n\t\treturn 0;\r\n\t}", "title": "" }, { "docid": "e887a7eda7db4869f43a0954cec8a35f", "score": "0.55925876", "text": "public function save1(){\n\t\tfor($year=1;$year<= $this->n;$year++){\n\t\t\t$this->pv*=(1+$this->int);\n\t\t}\n\t\treturn $this->pv;\n\t}", "title": "" }, { "docid": "6473c29bf2250e2b78b3701a9f7a1cdf", "score": "0.5572103", "text": "public function getPrava(){ return $this->prava; }", "title": "" }, { "docid": "51d38cabe42e88a0b49c5def7f79a201", "score": "0.55649537", "text": "function pekerjaan($pejabat, $profesional, $assisten_pro, $tu, $tu_jual, $tu_tani, $kerajinan, $operator ,$kasar, $army, $max){\r\n\tif($army == 'TNI'){\r\n\t\treturn 10/$max;\r\n\t}elseif ($army == 'Polisi') {\r\n\t\treturn 10/$max;\r\n\t}elseif ($army >= $max) {\r\n\t\treturn 1;\r\n\t}\r\n\tif($pejabat == 'Hakim'){\r\n\t\treturn 9/$max;\r\n\t}elseif ($pejabat == 'Mentri') {\r\n\t\treturn 9/$max;\r\n\t}elseif ($pejabat == 'Jaksa') {\r\n\t\treturn 9/$max;\r\n\t}elseif ($pejabat >= $max) {\r\n\t\treturn 1;\r\n\t}\r\n\tif ($profesional == 'Dokter') {\r\n\t\treturn 8/$max;\r\n\t}elseif ($profesional == 'Pengacara') {\r\n\t\treturn 8/$max;\r\n\t}elseif ($profesional == 'Dosen') {\r\n\t\treturn 8/$max;\r\n\t}elseif ($profesional == 'Guru') {\r\n\t\treturn 8/$max;\r\n\t}elseif ($profesional == 'Bidan') {\r\n\t\treturn 8/$max;\r\n\t}elseif ($profesional >= $max) {\r\n\t\treturn 1;\r\n\t}\r\n\tif ($assisten_pro == 'Perawat') {\r\n\t\treturn 7/$max;\r\n\t}elseif ($assisten_pro == 'Apoteker') {\r\n\t\treturn 7/$max;\r\n\t}elseif ($assisten_pro >= $max) {\r\n\t\treturn 1;\r\n\t}\r\n\tif($tu == 'Pegawai'){\r\n\t\treturn 6/$max;\r\n\t}elseif ($tu == 'Buruh') {\r\n\t\treturn 6/$max;\r\n\t}elseif ($tu == 'PNS') {\r\n\t \treturn 6/$max;\r\n\t}elseif ($tu >= $max ) {\r\n\t\treturn 1;\r\n\t}\r\n\tif ($tu_jual == 'Pedagang') {\r\n\t\treturn 5/$max;\r\n\t}elseif ($tu_jual == 'Wiraswasta') {\r\n\t\treturn 5/$max;\r\n\t}elseif ($tu_jual == 'Wirausaha') {\r\n\t\treturn 5/$max;\r\n\t}elseif($tu_jual >= $max){\r\n\t\treturn 1;\r\n\t}\r\n\tif($tu_tani == 'Petani'){\r\n\t\treturn 4/$max;\r\n\t}elseif ($tu_tani == 'Nelayan') {\r\n\t\treturn 4/$max;\r\n\t}elseif ($tu_tani >= $max) {\r\n\t\treturn 1;\r\n\t}\r\n\tif($kerajinan == 'Entertainer'){\r\n\t\treturn 3/$max;\r\n\t}elseif ($kerajinan == 'Aktor') {\r\n\t\treturn 3/$max;\r\n\t}elseif ($kerajinan >= $max) {\r\n\t\treturn 1;\r\n\t}\r\n\tif($operator == 'Ojek'){\r\n\t\treturn 2/$max;\r\n\t}elseif ($operator == 'Astronot') {\r\n\t\treturn 2/$max;\r\n\t}elseif ($operator == 'Pilot') {\r\n\t\treturn 2/$max;\r\n\t}elseif ($operator == 'Nahkoda') {\r\n\t\treturn 2/$max;\r\n\t}elseif ($operator == 'Masinis') {\r\n\t\treturn 2/$max;\r\n\t}elseif ($operator == 'Supir') {\r\n\t\treturn 2/$max;\r\n\t}elseif ($operator >= $max) {\r\n\t\treturn 1;\r\n\t}\r\n\tif($kasar == 'Ibu Rumah Tangga'){\r\n\t\treturn 1/$max;\r\n\t}elseif ($kasar == 'Assisten Rumah Tangga') {\r\n\t\treturn 1/$max;\r\n\t}elseif($kasar == 'Tunakarya'){\r\n\t\treturn 1/$max;\r\n\t}elseif ($kasar == 'Lain-lain') {\r\n\t\treturn 1/$max;\r\n\t}elseif ($kasar >= $max) {\r\n\t\treturn 1;\r\n\t}\r\n\r\n}", "title": "" }, { "docid": "b702dbe516befd4dc9e815d65678474e", "score": "0.55619204", "text": "public function renderPoupanca(){\n $this->valor = $this->valor*1.006;\n }", "title": "" }, { "docid": "8bb1d4959ea4d761fa2acc2f95272b18", "score": "0.5560936", "text": "function renvoyerMin ($tabNombre)\r\n{\r\n // QUEL SERAIT LE CODE POUR OBTENIR CE RESULTAT ?\r\n // SI JE VEUX PRENDRE CHAQUE ELEMENT D'UN TABLEAU\r\n // => BOUCLE\r\n // IL FAUT DONNER UNE VALEUR A $plusPetit\r\n $plusPetit = $tabNombre[0]; // ON PREND LA PREMIERE VALEUR\r\n foreach($tabNombre as $nombre)\r\n {\r\n // SI JE COMPARE DES VALEURS => CONDITION\r\n if ($nombre < $plusPetit)\r\n {\r\n // $nombre EST PLUS PLUS PETIT QUE $plusPetit\r\n // DONC LE PLUS PETIT EST LE NOMBRE\r\n $plusPetit = $nombre;\r\n }\r\n } \r\n\r\n return $plusPetit;\r\n}", "title": "" }, { "docid": "304ba6fd73b13dabe44e8ca320cdfaa4", "score": "0.55200106", "text": "function berechne_initiative($obj){\n\tif ($obj == null or $obj->initiative == null or $obj->initiative < 0) $wert = 0;\n\tif ($obj->initiative == 0) $wert = 9999999;\n\t\telse $wert = floor_x((10000/$obj->initiative),3);\n\treturn $wert;\n}", "title": "" }, { "docid": "494e2d7bd38765b821f218b4403c00a4", "score": "0.54336977", "text": "function isPogodena($i,$j,$pronadenaRijec){\n\n\t // ... Prvo provjeri je li unesena rijec zaista na popisu\n\t\t$flag = 0;\n\n\t\tfor($m = 0; $m < Osmosmjerka::M; $m++)\n\t\t\tif($this->popisRijeci[$m] === $pronadenaRijec)\n\t\t\t\t$flag = 1;\n\n\t\tif($flag === 0) return 0;\n\n\n\n\t // ... Zatim provjeri je li unesena rijec na navedenom mjestu (za svaki slucaj je drugaciji return da bi nam kasnije pomogao u obradiFormu() )\n\n\t\t// Trazi rijec VODORAVNO DESNO\n\n\t\t$string = '';\n\t\t// Spremi ponudenu rijec u string\n\t\tfor($l = $j; $l < Osmosmjerka::N; $l++){\n\t\t\t$string .= $this->poljeSlova[$i][$l];\n\t\t\tif( strlen($string) === strlen($pronadenaRijec) ) break;\n\t\t}\n\n\t\t// Je li pronadenaRijec na tocnom mjestu? (poklapa li se sa stringom)\n\t\tif( $string === $pronadenaRijec ) return 1;\n\n\n\n\t\t// Trazi rijec VODORAVNO LIJEVO\n\n\t\t$string = '';\n\t\t// Spremi ponudenu rijec u string\n\t\tfor($l = $j; $l >= 0; $l--){\n\t\t\t$string .= $this->poljeSlova[$i][$l];\n\t\t\tif( strlen($string) === strlen($pronadenaRijec) ) break;\n\t\t}\n\t\t// Je li pronadenaRijec na tocnom mjestu? (poklapa li se sa stringom)\n\t\tif( $string === $pronadenaRijec ) return 2;\n\n\n\n\t\t// Trazi rijec OKOMITO GORE\n\n\t\t$string = '';\n\t\t// Spremi ponudenu rijec u string\n\t\tfor($k = $i; $k >= 0; $k--){\n\t\t\t$string .= $this->poljeSlova[$k][$j];\n\t\t\tif( strlen($string) === strlen($pronadenaRijec) ) break;\n\t\t}\n\t\t// Je li pronadenaRijec na tocnom mjestu? (poklapa li se sa stringom)\n\t\tif( $string === $pronadenaRijec ) return 3;\n\n\n\n\t\t// Trazi rijec OKOMITO DOLJE\n\n\t\t$string = '';\n\t\t// Spremi ponudenu rijec u string\n\t\tfor($k = $i; $k < Osmosmjerka::N; $k++){\n\t\t\t$string .= $this->poljeSlova[$k][$j];\n\t\t\tif( strlen($string) === strlen($pronadenaRijec) ) break;\n\t\t}\n\t\t// Je li pronadenaRijec na tocnom mjestu? (poklapa li se sa stringom)\n\t\tif( $string === $pronadenaRijec ) return 4;\n\n\n\n\t\t// Trazi rijec DIJAGONALNO GORE DESNO\n\n\t\t$string = '';\n\t\t// Spremi ponudenu rijec u string\n\t\t$k = $i; $l = $j;\n\t\twhile($k >= 0 && $l < Osmosmjerka::N){\n\t\t\t$string .= $this->poljeSlova[$k][$l];\n\t\t\tif( strlen($string) === strlen($pronadenaRijec) ) break;\n\t\t\t$k--; $l++;\n\t\t}\n\t\t// Je li pronadenaRijec na tocnom mjestu? (poklapa li se sa stringom)\n\t\tif( $string === $pronadenaRijec ) return 5;\n\n\n\n\t\t// Trazi rijec DIJAGONALNO DOLJE DESNO\n\n\t\t$string = '';\n\t\t// Spremi ponudenu rijec u string\n\t\t$k = $i; $l = $j;\n\t\twhile($k < Osmosmjerka::N && $l < Osmosmjerka::N){\n\t\t\t$string .= $this->poljeSlova[$k][$l];\n\t\t\tif( strlen($string) === strlen($pronadenaRijec) ) break;\n\t\t\t$k++; $l++;\n\t\t}\n\t\t// Je li pronadenaRijec na tocnom mjestu? (poklapa li se sa stringom)\n\t\tif( $string === $pronadenaRijec ) return 6;\n\n\n\n\t\t// Trazi rijec DIJAGONALNO DOLJE LIJEVO\n\n\t\t$string = '';\n\t\t// Spremi ponudenu rijec u string\n\t\t$k = $i; $l = $j;\n\t\twhile($k < Osmosmjerka::N && $l >= 0){\n\t\t\t$string .= $this->poljeSlova[$k][$l];\n\t\t\tif( strlen($string) === strlen($pronadenaRijec) ) break;\n\t\t\t$k++; $l--;\n\t\t}\n\t\t// Je li pronadenaRijec na tocnom mjestu? (poklapa li se sa stringom)\n\t\tif( $string === $pronadenaRijec ) return 7;\n\n\n\n\t\t// Trazi rijec DIJAGONALNO GORE LIJEVO\n\n\t\t$string = '';\n\t\t// Spremi ponudenu rijec u string\n\t\t$k = $i; $l = $j;\n\t\twhile($k >= 0 && $l >= 0){\n\t\t\t$string .= $this->poljeSlova[$k][$l];\n\t\t\tif( strlen($string) === strlen($pronadenaRijec) ) break;\n\t\t\t$k--; $l--;\n\t\t}\n\t\t// Je li pronadenaRijec na tocnom mjestu? (poklapa li se sa stringom)\n\t\tif( $string === $pronadenaRijec ) return 8;\n\n\n\t\treturn 0;\n\t}", "title": "" }, { "docid": "2107a9cf7b3413ee250153078a34cd5e", "score": "0.53831726", "text": "public function jml_permohonan_selesaiKasubag()\n {\n $this->db->select('id_permohonan_ptsp, COUNT(id_permohonan_ptsp) as permohonan_selesaiKasubag');\n $this->db->from('permohonan_ptsp');\n $this->db->where(\"(id_kasubag != 'null')\");\n $this->db->where(\"(status = 'Selesai')\");\n $this->db->where('status_delete', 0);\n\n $hasil = $this->db->get();\n return $hasil;\n }", "title": "" }, { "docid": "c8595a25b81df30df8e49643cc9ecb59", "score": "0.5369806", "text": "public function ganador($p){\r\n\t\treturn 0;\r\n\t}", "title": "" }, { "docid": "35d027e95a1ce28a85e134ae66b337f4", "score": "0.5369674", "text": "public function poslednji_vestackiId() \n {\n $voljenja=$this->findAll();\n $maxId=-1;\n foreach ($voljenja as $voli)\n {\n if ($voli->VestackiId>$maxId)\n {\n $maxId=$voli->VestackiId; \n }\n }\n return $maxId;\n }", "title": "" }, { "docid": "a6b5c475348ae4f4f96afb3ca36f9a6c", "score": "0.53552103", "text": "function vandens_pupeliu_santykis($masyvas) {\n echo \"</br></br>Ar pupelėms užteks vandens?\";\n $raktai = array_keys($masyvas);\n $Pupeles = 0;\n $Vanduo = 0;\n for ($i=0; $i < count($raktai) ; $i++) { //tikrina ar masyve yra pupelių\n if ($raktai[$i] == \"Pupelės\") {\n $Pupeles++;\n } else {\n $Pupeles = $Pupeles;\n }\n }\n for ($i=0; $i < count($raktai) ; $i++) { // tikrina ar masyve yra vandens \n if ($raktai[$i] == \"Vanduo\") {\n $Vanduo++;\n } else {\n $Vanduo = $Vanduo;\n }\n }\n if ($Pupeles !== 0 && $Vanduo !== 0) {\n if ($masyvas[\"Vanduo\"] >= $masyvas[\"Pupelės\"]) {\n echo \"</br>Kadangi pilame pakankamai vandens, pupelės neprisvils.\";\n } elseif ($masyvas[\"Vanduo\"] < $masyvas[\"Pupelės\"]) {\n echo \"</br> Pilkite daugiau vandens, nes pupelės prisvils.\";\n } \n } else {\n echo \"</br>Recepte nėra pupelių ar vandens.\";\n }\n}", "title": "" }, { "docid": "e8d06b0414ffed87a10e7768a7686dc4", "score": "0.53332716", "text": "public function reculer(){\r\n if($this->jauge>0){\r\n $this->kmParcouru += 3;\r\n $this->jauge -= 2;\r\n return true;\r\n }else{\r\n $this->erreur .= 'Panne d\\'essence!';\r\n return false;\r\n }\r\n }", "title": "" }, { "docid": "063f098ea17074d8afd5891e1d380755", "score": "0.5329876", "text": "function cariPosisi($batas){\nif(empty($_GET[aksi])){\n\t$posisi=0;\n\t$_GET[aksi]=1;\n}\nelse{\n\t$posisi = ($_GET[aksi]-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "05e57b0a37ac101d2a4ecf3d134ab5dd", "score": "0.53272045", "text": "public function lfPretrazi(){\n $ip=$_GET['izgpro'];\n $v=$_GET['vrsta'];\n $r=$_GET['rasa'];\n $p=$_GET['pol'];\n \n if($ip=='izgubljen') $ip=0;\n else if($ip=='pronadjen') $ip=1;\n \n if($v=='vrsta') $v='%';\n if($p=='pol') $p='%';\n if($r=='') $r='%';\n \n \n $oglasiModel=new Oglasi();\n \n $array = ['pol' => $p, 'vrsta' => $v, 'rasa' => $r];\n $celiOglasi=$oglasiModel->like($array)->findAll();\n \n $niz=array();\n foreach ($celiOglasi as $oglasC) {\n array_push($niz, $oglasC->oglasId);\n } \n \n \n $slikaModel=new SlikeModel();\n $slike=$slikaModel->findAll();\n \n if(empty($niz)){\n \n $this->prikaz('Views/stranice/Lost&Found.php', ['slike'=>$slike], ['oglasi'=>[]]);\n }\n else{\n $lfModel=new LFModel();\n $oglasi=$lfModel->like('izgpro',$ip)->find($niz);\n $this->prikaz('Views/stranice/Lost&Found.php', ['slike'=>$slike], ['oglasi'=>$oglasi]);\n }\n }", "title": "" }, { "docid": "6451084f89ff12bcbc8ece846028fc2a", "score": "0.5324937", "text": "function moguciPoteziSvi($json2, $cetvrtina){\n global $poteza;\n if($cetvrtina == 1){\n $niz = $json2->FirstQuarter;\n $m = count($niz);\n for($i=0; $i<$m ; $i++){\n $poteza[$niz[$i]->NTTIPO] = $niz[$i]->CSDESCWEB;\n }\n }\n if($cetvrtina == 2){\n $niz = $json2->SecondQuarter;\n $m = count($niz);\n for($i=0; $i<$m ; $i++){\n $poteza[$niz[$i]->NTTIPO] = $niz[$i]->CSDESCWEB;\n }\n }\n if($cetvrtina == 3){\n $niz = $json2->ThirdQuarter;\n $m = count($niz);\n for($i=0; $i<$m ; $i++){\n $poteza[$niz[$i]->NTTIPO] = $niz[$i]->CSDESCWEB;\n }\n }\n if($cetvrtina == 4){\n $niz= $json2->ForthQuarter;\n $m = count($niz);\n for($i=0; $i<$m ; $i++){\n $poteza[$niz[$i]->NTTIPO] = $niz[$i]->CSDESCWEB;\n }\n }\n if($cetvrtina == 5){\n $niz = $json2->ExtraTime;\n $m = count($niz);\n if($m==0)\n echo \"Nema produzetaka\\n\";\n else{\n echo \"Obradjeni i produzeci \\n\";\n for($i=0; $i<$m ; $i++){\n $poteza[$niz[$i]->NTTIPO] = $niz[$i]->CSDESCWEB;\n }\n }\n\n }\n}", "title": "" }, { "docid": "73171be068865ff25283a5d47af6a83c", "score": "0.5320925", "text": "private function mapRekapitulasiKomoditi()\n {\n $volume = [\n\n 'dokel' => $this->repository->totalRekapitulasi()->dokelTotalVolume,\n 'domas' => $this->repository->totalRekapitulasi()->domasTotalVolume,\n 'ekspor' => $this->repository->totalRekapitulasi()->eksporTotalVolume,\n 'impor' => $this->repository->totalRekapitulasi()->imporTotalVolume,\n 'serahterima' => $this->repository->totalRekapitulasi()->serahTerimaTotalVolume,\n 'reekspor' => $this->repository->totalRekapitulasi()->reeksporTotalVolume,\n\n ];\n\n return $volume[strtolower($this->permohonan)];\n }", "title": "" }, { "docid": "283c00c4a80da11052825806d7ba2b02", "score": "0.5303456", "text": "function cariPosisi($batas){\nif(empty($_GET[halaman])){\n\t$posisi=0;\n\t$_GET[halaman]=1;\n}\nelse{\n\t$posisi = ($_GET[halaman]-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "283c00c4a80da11052825806d7ba2b02", "score": "0.5303456", "text": "function cariPosisi($batas){\nif(empty($_GET[halaman])){\n\t$posisi=0;\n\t$_GET[halaman]=1;\n}\nelse{\n\t$posisi = ($_GET[halaman]-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "283c00c4a80da11052825806d7ba2b02", "score": "0.5303456", "text": "function cariPosisi($batas){\nif(empty($_GET[halaman])){\n\t$posisi=0;\n\t$_GET[halaman]=1;\n}\nelse{\n\t$posisi = ($_GET[halaman]-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "0c2f7a3836ad3fe3aaa7dedf04418c14", "score": "0.53004843", "text": "function salarioMinimo($vector) {\n $min=1250;\n foreach ($vector as $nombre => $salario) {\n #Si el salario es menor que la cantidad en min, se guardara este como el nuevo minimo\n if($salario<$min) {\n $min = $salario;\n }\n }\n #Devuelvo el valor del salario minimo\n return $min;\n }", "title": "" }, { "docid": "8b06df0f46ef5e7cc9282c3649383b02", "score": "0.52988887", "text": "public function perimetro()\n {\n // TODO: Implement perimetro() method.\n }", "title": "" }, { "docid": "b3929ac14f03ee8fe5bfb45579b214f2", "score": "0.5295293", "text": "public static function scaleno($lato1, $lato2, $lato3){\n $scaleno = new static();\n $p = ($lato1 + $lato2 + $lato3);\n $semiP = ($lato1 + $lato2 + $lato3)/2;\n $area = sqrt($semiP * ($semiP - $lato1) * ($semiP - $lato2) * ($semiP - $lato3));\n echo \"\\n\";\n echo \"Triangolo scaleno: \\nIl suo perimetro è di: \".$p.\"\\n\".\"La sua area è di: \".$area;\n return $scaleno;\n }", "title": "" }, { "docid": "a217f276ba3b43641de24060c90583bd", "score": "0.52940106", "text": "public function getPregled(){\n\t\t$predmeti=Predmeti::join('skole','skole.id','=','predmeti.skole_id')\n\t\t->where('predmeti.skole_id','=',Session::get('skola_id'))\n\t\t->get(['predmeti.naziv','predmeti.id'])->toArray();\n\n\t\t$izostanci['neopravdano']=DB::table('izostanci')\n\t\t\t\t->join('djaci','djaci.id','=','izostanci.djaci_id')\n\t\t\t\t\t->join('roditelji','roditelji.id','=','djaci.id_roditelji')\n\t\t\t\t\t->where('roditelji.id','=',Session::get('id'))\n\t\t\t\t\t->where('izostanci.opravdano','=',0)\n\t\t\t\t\t->sum('broj_casova');\n\t\t$izostanci['ukupno']=Izostanci::\n\t\t\t\tjoin('djaci','djaci.id','=','izostanci.djaci_id')\n\t\t\t\t\t->join('roditelji','roditelji.id','=','djaci.id_roditelji')\n\t\t\t\t\t->where('roditelji.id','=',Session::get('id'))\n\t\t\t\t\t->sum('broj_casova');//2 je neravdano. 1 je pravdano , 0 je neopravdano\n\t\t$prosek=Zakljucneocene::join('djaci','djaci.id','=','zakljucne_ocene.djaci_id')\n\t\t\t\t\t\t->join('predmeti','predmeti.id','=','zakljucne_ocene.predmeti_id')\n\t\t\t\t\t\t->join('semestar','semestar.id','=','zakljucne_ocene.semestar_id')\n\t\t\t\t\t\t->join('roditelji','roditelji.id','=','djaci.id_roditelji')\n\t\t\t\t\t\t->where('djaci.id_roditelji','=',Session::get('id'))\n\t\t\t\t\t\t->where('zakljucne_ocene.semestar_id','=',1)\n\t\t\t\t\t\t->avg('zakljucna',2);\n\n\t\treturn Security::autentifikacija('roditelj.pregled',compact('predmeti','izostanci','prosek'),2);\n\t}", "title": "" }, { "docid": "9f13b9f2f5585de685541295a8594722", "score": "0.52900875", "text": "function juegoConMasPuntaje ($coleccionJuegos){\n //$n ,$j $ptos , $indiceJuego INT\n //$puntosArreglo ARRAY\n $n = count($coleccionJuegos);\n $ptos = 0;\n $indiceJuego = 0;\n for($j=0; $j<$n; $j++){//Recorrido exhaustivo para encontrar el puntaje mas alto dentro del arreglo\n $puntosArreglo= $coleccionJuegos[$j][\"puntos\"];\n echo $puntosArreglo.\"\\n\";\n if ( $ptos < $puntosArreglo){\n $ptos=$coleccionJuegos[$j][\"puntos\"];\n echo $ptos.\"\\n\";\n $indiceJuego = $j;\n }\n }\n return $indiceJuego;\n}", "title": "" }, { "docid": "e753bf72b3900bb5cfa30bf68220321a", "score": "0.52789176", "text": "function udelejDotaz($od, $do, $typ)\n{\n$dotaz ='';\n\n$id = '';\n\nif($typ=='sumstroje' || $typ=='vsechno')\n {\n $id = '';\n }\nelseif($typ=='stroje') {\n $id = 'id, nazev, c_vykresu, prum_cena,';\n }\nelseif($typ=='sestavy' || $typ=='rozprac') {\n $id = 'zac_c_vykresu, ';\n}\n \nif($typ=='sestavy' || $typ=='sumsestavy' || $typ=='rozprac' || $typ=='sumrozprac')\n{\n $not = 'not';\n}\nelse\n{\n $not = '';\n}\n\n// pri rozpracovane vyrobe se prida omezeni pouze na karty ktere maji cenu prace \nif($typ=='rozprac' || $typ=='sumrozprac' )\n{\n $rozprac = 'AND Z.cena_prace > 0';\n}\nelse if($typ=='stroje' || $typ=='sumstroje')\n{\n $rozprac = '';\n}\nelse\n{\n $rozprac = 'AND Z.cena_prace < 1';\n}\n\n//rozliseni jestli se omezuju jenom na stroje,nebo sestavy\nif($typ!='vsechno')\n$omezeni_zbozi = \"WHERE Z.id $not in (SELECT id_zbozi\n FROM stroje) $rozprac\";\nelse {$omezeni_zbozi = '';}\n\n\n\n$datum_dotaz = '';\nif(!empty($_GET['od']))\n{\n $timestamp_dateod = strtotime($od);\n $datum_dotaz .= \"AND D.datum >= '$timestamp_dateod' \";\n}\n\nif(!empty($_GET['do']))\n{\n $timestamp_datedo = strtotime($do); \n $datum_dotaz .= \"AND D.datum <= '$timestamp_datedo' \";\n}\n\n$dotaz .= \"select $id sum(mnozstvi) as mnozstvi, sum(mnozstvi*cena_MJ) as cena_celkem from\n ((SELECT Z.id, Z.zac_c_vykresu, nazev, c_vykresu, prum_cena, sum(TD.mnozstvi) as mnozstvi, (Z.prum_cena) as cena_MJ\n FROM zbozi as Z \n JOIN (SELECT T.id_zbozi, T.mnozstvi, T.cena_MJ, D.skupina \n FROM transakce as T\n JOIN doklady as D ON D.id=T.id_dokladu\n WHERE D.skupina in('Nákup','Inventura') $datum_dotaz ) \n as TD on Z.id = TD.id_zbozi\n $omezeni_zbozi\n GROUP BY Z.id) \n UNION ALL\n (SELECT Z.id, Z.zac_c_vykresu, nazev, c_vykresu, prum_cena, sum(TD.mnozstvi) as mnozstvi, (Z.prum_cena) as cena_MJ\n FROM zbozi as Z \n JOIN (SELECT T.id_zbozi, -(T.mnozstvi) as mnozstvi, T.cena_MJ, D.skupina \n FROM transakce as T\n JOIN doklady as D ON D.id=T.id_dokladu\n WHERE D.skupina in('Prodej','Zmetkování') $datum_dotaz ) \n as TD on Z.id = TD.id_zbozi\n $omezeni_zbozi\n GROUP BY Z.id)\n UNION ALL\n (SELECT Z.id, Z.zac_c_vykresu, nazev, c_vykresu, prum_cena, sum(TD.mnozstvi) as mnozstvi, (Z.prum_cena) as cena_MJ\n FROM zbozi as Z \n JOIN (SELECT T.id_zbozi, T.mnozstvi, T.cena_KOO, D.skupina \n FROM transakce as T\n JOIN doklady as D ON D.id=T.id_dokladu\n WHERE D.skupina in('Výroba','Kooperace') $datum_dotaz ) \n as TD on Z.id = TD.id_zbozi\n $omezeni_zbozi\n GROUP BY Z.id) \n UNION ALL\n (SELECT Z.id, Z.zac_c_vykresu, nazev, c_vykresu, prum_cena, sum(TD.mnozstvi) as mnozstvi, (Z.prum_cena) as cena_MJ\n FROM zbozi as Z\n JOIN (SELECT VOT.id_zbozi, -(VOT.mnozstvi) as mnozstvi, VOT.d_id, D.datum\n FROM doklady as D \n JOIN (SELECT VO.id_zbozi, VO.mnozstvi, T.id_dokladu as d_id\n FROM vyroba_odpisy as VO \n JOIN transakce as T ON T.id = VO.id_vyroby\n ) as VOT ON D.id = VOT.d_id $datum_dotaz)\n AS TD on Z.id = TD.id_zbozi\n $omezeni_zbozi\n GROUP BY Z.id)\n ) as TSUMY\n\";\n\n\n// (SELECT Z.id, Z.zac_c_vykresu, nazev, c_vykresu, prum_cena, sum(TD2.mnozstvi) as mnozstvi, (Z.prum_cena) as cena_MJ\n// FROM zbozi as Z\n// JOIN (SELECT S.soucastka as id_zbozi, -(S.mnozstvi*TD.mnozstvi) as mnozstvi, TD.id_dokladu\n// FROM ((SELECT T.id_zbozi, T.id_dokladu, T.mnozstvi FROM transakce as T\n// JOIN doklady as D ON D.id=T.id_dokladu\n// WHERE D.skupina in('Výroba','Kooperace') $datum_dotaz ) as TD\n// JOIN (SELECT soucastka,celek, mnozstvi\n// FROM sestavy\n// ) as S ON S.celek=TD.id_zbozi)) \n// as TD2 on Z.id = TD2.id_zbozi\n// $omezeni_zbozi\n// GROUP BY Z.id)\n// \n\n\nif($typ=='stroje')\n $dotaz.=' GROUP BY id ';\nelseif($typ=='sestavy' || $typ=='rozprac')\n $dotaz.=' GROUP BY zac_c_vykresu ';\n\n\nreturn $dotaz;\n}", "title": "" }, { "docid": "37177c2d6ef2ded45e25095d1d2d0b43", "score": "0.52646065", "text": "function cariPosisi($batas){\nif(empty($_GET['halgaleri'])){\n\t$posisi=0;\n\t$_GET['halgaleri']=1;\n}\nelse{\n\t$posisi = ($_GET['halgaleri']-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "de8c9fc905966068676265aedc84cf4c", "score": "0.52601933", "text": "function obliczSQ($populacja,$key)\n\t{\n\t\t$this->tablica_SQ[$key] = round(($populacja/$this->SD_c),2,PHP_ROUND_HALF_UP);\n\t\t\n\t}", "title": "" }, { "docid": "686b288222d57a3865b4acfbe9ed1b86", "score": "0.52566075", "text": "function verlieren()\n {\n $summeSpielzug = 0;\n $wuerfe = $wuerfe + 1;\n }", "title": "" }, { "docid": "57492e5aff737c618e5f1c56c208ec64", "score": "0.5247246", "text": "public function perimetrocirculo($radio){\n $perimetro=$this->radio*3.14*2;\n return $perimetro;\n\n}", "title": "" }, { "docid": "b8e5b06f53cb48b79f95fe5f29486590", "score": "0.5245274", "text": "function pausiereSpiel($spielID) {\n\n\t\t//holt den aktuellen SpielStatus\n\t\t$spielStatus = holeSpielStatus($spielID);\n\n\t\t//Spiel pausieren\n\t\tif($spielStatus == 1) {\n\t\t\t//Setze Status auf 2 in der Datenbank\n\t\t\tabfrageDB(\"UPDATE spiel SET Status = '2' WHERE SpielID = '\" . $spielID . \"'\");\n\t\t\t//Damit JS den richtigen Button laden kann\n\t\t\techo \"2\";\n\t\t}\n\t\t//Spiel forsetzten\n\t\telse if($spielStatus == 2) {\n\t\t\t//Setze Status auf 1 in der Datenbank\n\t\t\tabfrageDB(\"UPDATE spiel SET Status = '1' WHERE SpielID = '\" . $spielID . \"'\");\n\t\t\t//Damit JS den richtigen Button laden kann\n\t\t\techo \"1\";\n\t\t}\n\n\t}", "title": "" }, { "docid": "9259f449a8e989b42be9791e7f42018a", "score": "0.5244505", "text": "function print_polin($polin, $pp_al_mode = true)\n{\n\t$n = max(array_keys($polin));\n\tfor($i = $n ; $i > 0; $i--)\n\t{\n\t\tif (isset($polin[$i]))\n\t\t{\n\t\t\tif($polin[$i] != 0)\n\t\t\t{\n\t\t\t\tif($pp_al_mode)\n\t\t\t\t{\n\t\t\t\t\tprintf(\"a<sup>%d</sup>x<sup>%d</sup>\", $polin[$i], $i);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\techo \"{$polin[$i]}x<sup>{$i}</sup>\";\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t\tprintf(\"x<sup>%d</sup>\", $i);\n\t\t\tif($i > 0 && isset($polin[$i-1]))\n\t\t\t{\n\t\t\t\techo \" + \";\n\t\t\t}\n\t\t}\n\t}\n\n\t//afiseaza ultimul termen\n\tif(isset($polin[0]))\n\t{\n\t\tif($pp_al_mode)\n\t\t{\n\t\t\tprintf(\"a<sup>%d</sup>\", $polin[$i]);\n\t\t}\n\t\telse\n\t\t{\n\t\t\techo $polin[$i];\n\t\t}\n\t}\n\techo \"<br>\";\n}", "title": "" }, { "docid": "ac5f72c401ff43565faf2d90b155c2f0", "score": "0.52430904", "text": "private function mapTotalVolumeKomoditi()\n {\n return $this->repository->totalVolumePerSatuan()[strtolower($this->permohonan)];\n }", "title": "" }, { "docid": "bf1fb1810c31dff5b87aee230b675e30", "score": "0.5242932", "text": "public function ObtenerUltBol();", "title": "" }, { "docid": "dc4dab7f6c2722fba404dd072c425b83", "score": "0.52385193", "text": "function cariPosisi($batas){\nif(empty($_GET['halaman'])){\n\t$posisi=0;\n\t$_GET['halaman']=1;\n}\nelse{\n\t$posisi = ($_GET['halaman']-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "dc4dab7f6c2722fba404dd072c425b83", "score": "0.52385193", "text": "function cariPosisi($batas){\nif(empty($_GET['halaman'])){\n\t$posisi=0;\n\t$_GET['halaman']=1;\n}\nelse{\n\t$posisi = ($_GET['halaman']-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "3200b414c9d824cb8589182390415e9c", "score": "0.5238493", "text": "function cariPosisi($batas){\nif(empty($_GET[hutang])){\n\t$posisi=0;\n\t$_GET[hutang]=1;\n}\nelse{\n\t$posisi = ($_GET[hutang]-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "2c72904eab4bf4c9268df0dec3442a26", "score": "0.52378726", "text": "public function lleno() \n {\n foreach($this->stock as $k => $v)\n {\n if($v['capacidadMaxima'] = $this->capacidadMaxima)\n {\n echo \"Esta lleno\";\n }\n }\n }", "title": "" }, { "docid": "2b2b41b7c2bbc9004a435a3477318f62", "score": "0.52364004", "text": "function bulan_pesan($eoq) {\n $incremental=12/$eoq;\n // array penampung bulan pesanan\n $arr_bulan_pesan=array();\n $arr_bulan=array();\n\n //perulangan yg mengisi bulan pesan\n for ($i=$incremental; $i <=12; $i+=$incremental) {\n $arr_bulan_pesan[]=round($i);\n }\n\n //mengembalikan nilai bulan pesan.\n return $arr_bulan_pesan;\n // return $data;\n}", "title": "" }, { "docid": "c1458647e22ee5a1a537de468be03fa1", "score": "0.5235088", "text": "function ambil_pelanggan($id)\r\r\n\t{\r\r\n\t\t//select*from pelanggan where id_pelanggan='$id'\r\r\n\t\t$hasil=$this->db->get_where('pelanggan',array('id_pelanggan'=>$id));\r\r\n\t\t//=> artinya mempunyai nilai\r\r\n\t\t//mecah ke array 1 data pelanggan\r\r\n\t\t$pecah = $hasil->row_array();\r\r\n\t\t//mengembalikan nilai karena mau menampilkan di tempat lain\r\r\n\t\treturn $pecah;\r\r\n\t}", "title": "" }, { "docid": "859960dc928dda6623f0a5b6def57f7a", "score": "0.52350026", "text": "function cariPosisi($batas){\nif(empty($_GET[adjs])){\n\t$posisi=0;\n\t$_GET[adjs]=1;\n}\nelse{\n\t$posisi = ($_GET[adjs]-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "0854e6a569742cbfcd2f36161823a781", "score": "0.52336437", "text": "public function proveri_proizvod($id){\n if(isset($_SESSION['stavke'])) {\n $this->stavke = $_SESSION['stavke'];\n foreach ($this->stavke as $st) {\n if($st->proizvod->id == $id){\n return $st->kolicina; \n }\n }\n return false;\n } \n return false; \n \n \n }", "title": "" }, { "docid": "fffb09f61453885c54cf0d929b667ad2", "score": "0.5228276", "text": "function cariPosisi($batas){\nif(empty($_GET['halberita'])){\n$posisi=0;\n$_GET['halberita']=1;\n}\nelse{\n$posisi = ($_GET['halberita']-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "fffb09f61453885c54cf0d929b667ad2", "score": "0.5228276", "text": "function cariPosisi($batas){\nif(empty($_GET['halberita'])){\n$posisi=0;\n$_GET['halberita']=1;\n}\nelse{\n$posisi = ($_GET['halberita']-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "d42c1eb224c7c021054b2e522b12182e", "score": "0.5208164", "text": "function cariPosisi($batas){\nif(empty($_GET['halagenda'])){\n\t$posisi=0;\n\t$_GET['halagenda']=1;\n}\nelse{\n\t$posisi = ($_GET['halagenda']-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "37a10da144cdeee50c63958d3cdee926", "score": "0.52032584", "text": "public function ulubione(){\n return $this->ulubione;\n }", "title": "" }, { "docid": "655a67b2db67683dbe6bda8f9705241b", "score": "0.5192353", "text": "function przepisy_ID_KategoriaCzasNazwa($y)\n{\n $tab=[];\n $xy=0;\n if (isset($_COOKIE['kategoria'])) {\n foreach ($_COOKIE['kategoria'] as $name => $value) {\n $name = htmlspecialchars($name);\n $value = htmlspecialchars($value);\n $tab[$xy] = $value;\n $xy++;\n }\n }\n\n $ileKat = count($tab);\n\n\n\n if($ileKat == 1){\n if($tab[0]=='Dowolne')\n {\n $kat = PrzepisQuery::create()\n ->where('Przepis.Nazwa LIKE ?', '%'.$_COOKIE['przepis'].'%')\n ->where('Przepis.CzasPrzygotowania = ?', $_COOKIE[\"czas\"])\n ->select(array('Przepis.IdPrzepis'))\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n else{\n $kat = NalezyQuery::create()\n ->join('Przepis')\n ->join('Kategoria')\n ->where('Przepis.Nazwa LIKE ?', '%'.$_COOKIE['przepis'].'%')\n ->where('Przepis.CzasPrzygotowania = ?', $_COOKIE[\"czas\"])\n ->where('Kategoria.Nazwa = ?', $tab[0])\n ->select(array('Przepis.IdPrzepis'))\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n }\n else\n {\n $kat = NalezyQuery::create()\n ->join('Przepis')\n ->join('Kategoria')\n ->select(array('Przepis.IdPrzepis'))\n ->where('Przepis.Nazwa LIKE ?', '%'.$_COOKIE['przepis'].'%')\n ->where('Przepis.CzasPrzygotowania = ?', $_COOKIE[\"czas\"])\n ->where('Kategoria.Nazwa IN ?', $tab)\n ->groupBy(array('Przepis.IdPrzepis'))\n ->having(\"count(Przepis.IdPrzepis) = ?\", $ileKat)\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n\n}", "title": "" }, { "docid": "4417f231ab5d72c180fe0537f39497ee", "score": "0.5189883", "text": "function upit($tabela,$id){\n\t\t\t\t$upit_kolicina = \"0\";\n\t\t\t\t$id_korisnika = $_SESSION['id_korisnika'];\n\t\t\t\t$id_member = $_SESSION['memberID'];\n\t\t\t\t$database = new Database;\n\t\t\t\t\n\t\t\t\tif($tabela == \"radnici\"){\n\t\t\t\t\t\n\t\t\t\t\t$database->query(\"SELECT * FROM $tabela WHERE id_korisnika='$id_korisnika' AND status='1' AND zaduzenje LIKE '%,$id/%'\");\n\t\t\t\t\t$upit = $database->resultset();\n\t\t\t\t\tforeach($upit as $row){\n\t\t\t\t\t\t$upit_array = explode(\",\",$row['zaduzenje']); //pretvaranje stringa u niz, podela na \",\" (clan niza je \"artikal/komada/datum\")\n\t\t\t\t\t\t\n\t\t\t\t\t\tforeach($upit_array as $upit_part){\n\t\t\t\t\t\t\tif($upit_part != \"\"){\n\t\t\t\t\t\t\t\t$upit_part_array = explode(\"/\", $upit_part); //pretvaranje stringa u niz, podela na \"/\" (clanovi niza su \",artikal\" , \"kolicina\" , \"datum\")\n\t\t\t\t\t\t\t\t$upit_id = $upit_part_array[0];\n\t\t\t\t\t\t\t\tif($upit_id == $id){\n\t\t\t\t\t\t\t\t\t$upit_kolicina += (int)$upit_part_array[1];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\treturn $upit_kolicina;\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\t$database->query(\"SELECT * FROM $tabela WHERE id_korisnika='$id_korisnika' AND status='1' AND artikli_kolicina_cena LIKE '%,$id/%'\");\n\t\t\t\t\t$upit = $database->resultset();\n\t\t\t\t\tforeach($upit as $row){\n\t\t\t\t\t\t$upit_array = explode(\" \",$row['artikli_kolicina_cena']); //pretvaranje stringa u niz, podela na \" \" (clan niza je \",artikal/komada/cena\")\n\t\t\t\t\t\tforeach($upit_array as $upit_part){\n\t\t\t\t\t\t\t$upit_part_array = explode(\"/\", $upit_part); //pretvaranje stringa u niz, podela na \"/\" (clanovi niza su \",artikal\" , \"kolicina\" , \"cena\")\n\t\t\t\t\t\t\t$upit_id = substr($upit_part_array[0], 1);\n\t\t\t\t\t\t\tif($upit_id == $id){\n\t\t\t\t\t\t\t\t$upit_kolicina += (int)$upit_part_array[1];\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\treturn $upit_kolicina;\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "5a699ef7157e2437b0405bfa555844d6", "score": "0.5189772", "text": "function kuadrat($angka)\r\n{\r\n\t$hasil = $angka * $angka;\r\n\treturn $hasil;\r\n}", "title": "" }, { "docid": "34ea7af053965a86014da03120872602", "score": "0.5185745", "text": "function cariPosisi($batas){\r\r\n if(empty($_GET['halaman'])){\r\r\n $posisi=0;\r\r\n $_GET['halaman']=1;}\r\r\n else{\r\r\n $posisi = ($_GET['halaman']-1) * $batas;}\r\r\n return $posisi;}", "title": "" }, { "docid": "eb70f8cef9ef3d18de300011a4fdfdf2", "score": "0.5180352", "text": "function primerJuegoConMasPuntaje ($coleccionJuegos,$maximoPuntaje){ \n //$indiceJuego, $i, $n INT\n //$maximo BOOLEAN\n\n $indiceJuego=-1;\n $maximo = false;\n $i=0;\n $n=count($coleccionJuegos);\n while ($i< $n && !$maximo ){//Recorrido parcial para encontrar el primer juego con mas puntaje\n $ptos = $coleccionJuegos[$i][\"puntos\"];\n if ($ptos > $maximoPuntaje) {\n $maximoPuntaje = $ptos;\n $maximo = true;\n $indiceJuego = $i;\n }\n $i++;\n } \n return $indiceJuego; \n}", "title": "" }, { "docid": "49d24583bf5e07ae2169703ad1abb3c7", "score": "0.517998", "text": "function kuva_puurid(){\n\tif(isset($_SESSION['user'])){ //Kontrollib, kas kasutaja on sisse logitud. Kui pole, suunab sisselogimise vaatesse\n\n\t\tglobal $connection;\n\t\t$puurid = array();\n\t\t$query =\"SELECT DISTINCT(puur) FROM `<taivol/dk11>_loomaaed`\";\n\t\t$result = mysqli_query($connection, $query) or die(\"$query - \".mysqli_error($connection));\n\t\t// hangime tulemusest esimese rea\n\n\t\twhile($row = $result->fetch_assoc()) {\n\t\t\t\t$query1 =\"SELECT * FROM `<taivol/dk11>_loomaaed` WHERE puur=\".mysqli_real_escape_string($connection, $row['puur']).\";\";\n\t\t\t\t$result1 = mysqli_query($connection, $query1) or die(\"$query - \".mysqli_error($connection));\n\t\t\t\t\n\t\t\t\twhile($row1 = $result1->fetch_assoc()) {\n\t\t\t\t\t$puurid[$row[\"puur\"]][]= $row1;\n\n\t\t\t\t}\n\t\t}\n\t\t\n\t\tinclude_once('views/puurid.html');\n\t}\n\telse header(\"Location: ?page=login\");\n}", "title": "" }, { "docid": "6dead66458ae3c395e73586aa8248fc4", "score": "0.5179813", "text": "function balise_ID_RUBRIQUE_GENEA_dist($p) {\r\n /* explorer la pile memoire pour atteindre le 'vrai' champ */\r\n $id_genea = champ_sql('id_genea', $p);\r\n /* le code php qui sera execute */\r\n $p->code = \"intval(titre_genea(\".$id_genea.\", 'id_rubrique'))\";\r\n return $p;\r\n}", "title": "" }, { "docid": "9dd698b60a2d8943c787d7dec693e0b5", "score": "0.5178806", "text": "public function ultimoPlusUsado() {\n $this->viajesPlusAbonados = -2;\n }", "title": "" }, { "docid": "e468b14e7ed715784b90839a8f6087b5", "score": "0.5176466", "text": "function calcularVolumen(){\n $this->volumen=($this->ancho) * ($this->largo)*($this->alto);\n }", "title": "" }, { "docid": "15873437809f306a1e9222020b728e07", "score": "0.51706356", "text": "function cariPosisi($batas){\nif(empty($_GET['halberita'])){\n\t$posisi=0;\n\t$_GET['halberita']=1;\n}\nelse{\n\t$posisi = ($_GET['halberita']-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "486926ee5130b50ce18e73c530e1a400", "score": "0.5170413", "text": "public function pregled_pitanja_po_kategoriji() {\n $pitanjeModel = new PitanjeModel();\n $kategorijaPitanjaModel = new KategorijaPitanjaModel();\n if ($this->request->getVar('pretraga')==null) $pitanjaK=$pitanjeModel->findAll();\n else // ako nije uneta nijedna kategorija onda prikazi sva pitanja\n {\n $kategorijaId = $kategorijaPitanjaModel->findQuestionCategoryId($this->request->getVar('pretraga'));\n $pitanjaK = $pitanjeModel->pregled_pitanja_po_kategoriji($kategorijaId);\n }\n echo view(\"pregled_pitanja\", ['pitanja' => $pitanjaK]);\n }", "title": "" }, { "docid": "cfd5a423907b37602c14f6d28d46b4d8", "score": "0.51654714", "text": "public function promedio( $info_grades_aux )\n\t\t\t\t{\n\t\t\t\t\t $counter= 0;\n $union = [];\n $sumatoria = 0;\n $aux = 0;\n $weights_aux = 0;\n\n \n\n\n //print_r( $info_grades_aux );\n //echo \"<br />\";\n\n foreach ($info_grades_aux as $key ) \n { \n if( $counter == 0 )\n {\n $counter++;\n $aux = $key['weight']; \n $sumatoria = $key['value']; \n // print_r($key) ;\n\n continue;\n }\n\n\n $weights_aux = $key['weight']; \n\n\n if( $aux == $weights_aux )\n {\n $sumatoria += $key[ 'value' ];\n $counter++;\n }\n\n if( ($aux != $weights_aux) || (next( $info_grades_aux ) != false) )\n //if( ($aux != $weights_aux) )\n {\n $union[$aux] = [ $counter => (($sumatoria/$counter)*($aux/100)) ]; \n $aux= $weights_aux; \n $counter = 1;\n $sumatoria = $key['value']; \n // echo \"Entreadasasdads<br />\";\n }\n\n //echo \"<br />\".$key; \n// print_r($key);\n\n //echo \"<br />\";\n //echo \"<br />\".$sumatoria; \n\n\n }\n\n // print_r($union);\n $promedio = 0;\n foreach ($union as $weight => $total_Elements) {\n foreach ($total_Elements as $a => $sumatoriaElements) {\n $promedio += $sumatoriaElements; \n } \n }\n $promedio = round( $promedio, 4 );\n \n\n\n //print_r( $info_grades_aux );\n\n return $promedio;\n\t\t\t\t}", "title": "" }, { "docid": "b9c522e2f2c68d649a122853dd21bfcf", "score": "0.5161417", "text": "function kd_peminjaman()\n {\n $this->db->select_max('kd_peminjaman');\n $hasil = $this->db->get('tbl_peminjaman_aset');\n foreach ($hasil->result_array() as $j) {\n $kode = 1 + $j['kd_peminjaman'];\n }\n return $kode;\n }", "title": "" }, { "docid": "7965d45a2dfec85f8342245cc4b9253e", "score": "0.5159766", "text": "public function kupi($id_proizvod) {\n $proizvodModel = new ProizvodModel();\n $korpaModel = new KorpaModel();\n $proizvod = $proizvodModel->vratiProizvod($id_proizvod);\n $korpa = array(\n 'id_korisnik' => $this->session->get('korisnik')->id_korisnik,\n 'id_proizvod' => $proizvod->id_proizvod,\n 'ime_proizvoda' => $proizvod->naziv,\n 'cena' => $proizvod->cena,\n 'is_active' => true\n );\n if($proizvod->kolicina > 0){\n $proizvodModel->updateKolicina($proizvod->id_proizvod, ($proizvod->kolicina - 1));\n $korpaModel->dodaj($korpa);\n }\n return redirect()->to(site_url('Korisnik/katalog'));\n }", "title": "" }, { "docid": "daa6cc64287757951fcc339a25482663", "score": "0.5157197", "text": "function napada( $targetVojska )\n {\n // takodjer, ne moze napasti ako je mrtav\n if( ( $this->brMetaka > 0 ) && ( $this->ziv ) )\n {\n // smanjuje broj metaka\n $this->brMetaka -= 1;\n\n // napada vojnika iz protivnicke vojske koji je prvi po indeksu\n // oduzima mu 1 zivot (ranjava ga, tj ubija ako mu uzima treci zivot)\n\n //trazi prvog zivog\n $i = 0;\n\n while( 1 )\n {\n $odabraniVojnik = $targetVojska->vojska[ $i ];\n\n if( $odabraniVojnik->ziv )\n {\n // oduzima mu 1 zivot\n for( $j = 0; $j < 3; ++$j )\n {\n // ako jos posjeduje i-ti zivot, oduzmi mu ga, tj. postavi na false i zavrsi\n // ako mu je to zadnji zivot, ubij ga (tj. dekrementiraj broj vojnika u njegovoj vojsci)\n if( $odabraniVojnik->zivoti[ $j ] )\n {\n $odabraniVojnik->zivoti[ $j ] = false;\n if( $j === 2 )\n {\n $targetVojska->brojVojnika -= 1;\n $odabraniVojnik->ziv = false;\n }\n\n break;\n }\n }\n break;\n }\n ++$i;\n }\n }\n }", "title": "" }, { "docid": "cbdff40ee4ebd6c7ef1fab78fd0d9185", "score": "0.51558703", "text": "function cariPosisi($batas){\nif(empty($_GET['halplaylist'])){\n\t$posisi=0;\n\t$_GET['halplaylist']=1;\n}\nelse{\n\t$posisi = ($_GET['halplaylist']-1) * $batas;\n}\nreturn $posisi;\n}", "title": "" }, { "docid": "7f302186a4a868ef40cc4d239bc3ad9b", "score": "0.5155278", "text": "function getPeliculas(){\n return $this->peliculas;\n }", "title": "" }, { "docid": "ff0932e18e52d819946a44efd2881140", "score": "0.51542145", "text": "function get0ne() {\n\t\t$query = \"SELECT P.product_id,\n\t\t\tP.product_name,\n\t\t\tP.product_description,\n\t\t\tDATE_FORMAT(P.product_creation, '%d %M %Y %T') AS DateCrea,\n\t\t\tP.user_id_product,\n\t\t\tP.product_status,\n\t\t\tP.product_img_url,\n\t\t\tP.product_nblike,\n\t\t\tS.nom,\n\t\t\tS.statut\n\t\t\tFROM \" . _TABLE__PRODUCTS . \" as P,\" . _TABLE__STATUTS . \" as S\n\t\t\tWHERE P.product_id = :id AND S.type = 'product' AND S.statut = P.product_status\";\n\t\t\n\t\n\t\t$champs = ':id';\n\t\t$values = $this->product_id; \n\t\n\t\t$item = $this->select_one_with_one_param($query, $values, $champs);\n\t\n\t\treturn $item;\n\t}", "title": "" }, { "docid": "bec98ebf5b944da74d6de2b16a6299a4", "score": "0.51512104", "text": "function formaIgra(){\n\t\t?>\n\n\t\t<!DOCTYPE html>\n\t\t<html>\n\t\t<head>\n\t\t\t<meta charset=\"utf-8\" />\n\t\t\t<title>Osmosmjerka</title>\n\t\t\t<style>\n\t\t\t\ttable,td { border: 1px solid; }\n\t\t\t\ttd { padding: 5px 10px; }\n\t\t\t</style>\n\t\t</head>\n\t\t<body>\n\t\t\t<h1> Osmosmjerka! </h1>\n\n\t\t\t<p> Igrač: <?php echo htmlentities( $this->imeIgraca ); ?> </p>\n\t\t\t<p> Broj pokušaja: <?php echo htmlentities( $this->brojPokusaja ); ?> </p>\n\n\n\t\t\t<table>\n\t\t\t\t<?php\n\t\t\t\t//idi po recima\n\t\t\t\tfor($i = 0; $i < Osmosmjerka::N; $i++){\n\t\t\t\t\techo '<tr>';\n\t\t\t\t\t\t//idi po stupcima\n\t\t\t\t\t\tfor($j = 0; $j < Osmosmjerka::N; $j++){\n\n\t\t\t\t\t\t\t// Ako ovo polje nije nikad pogođeno, ostavi bijelo\n\t\t\t\t\t\t\tif( $this->stanjeSlova[$i][$j] === -1 )\n\t\t\t\t\t\t\t\techo '<td>' . $this->poljeSlova[$i][$j] . '</td>';\n\n\t\t\t\t\t\t\t// Ako je ovo polje pogođeno nekad prije (ne zadnji put), obojaj ga žuto\n\t\t\t\t\t\t\telse if( $this->stanjeSlova[$i][$j] === 0 )\n\t\t\t\t\t\t\t\techo '<td style=\"background-color: yellow\">' . $this->poljeSlova[$i][$j] . '</td>';\n\n\t\t\t\t\t\t\t// Ako je ovo polje pogođeno zadnji put, obojaj ga zeleno\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\techo '<td style=\"background-color: green\">' . $this->poljeSlova[$i][$j] . '</td>';\n\t\t\t\t\t\t}\n\n\t\t\t\t\techo '</tr>';\n\t\t\t\t}\n\t\t\t\t?>\n\t\t\t</table>\n\n\n\t\t\t<br>\n\n\t\t\t<?php\n\t\t\t\techo \"Pronađi riječ s popisa:\";\n\t\t\t\tfor($i = 0; $i < Osmosmjerka::M; $i++){\n\t\t\t\t\techo \" \";\n\n\t\t\t\t\t// Ako rijec nije pogodena dosad, ostavi je normalno\n\t\t\t\t\tif( $this->stanjeRijeci[$i] === -1 )\n\t\t\t\t\t\techo '<a>' . $this->popisRijeci[$i] . '</a>';\n\n\t\t\t\t\t// Ako je rijec pogodena nekad prije (ne u zadnjem pokusaju), obojaj žuto i precrtaj\n\t\t\t\t\telse if( $this->stanjeRijeci[$i] === 0 )\n\t\t\t\t\t\techo '<a style=\"background-color: yellow\"><strike>' . $this->popisRijeci[$i] . '</strike></a>';\n\n\t\t\t\t\t// Ako je rijec pogodena u zadnjem pokusaju, obojaj zeleno i precrtaj\n\t\t\t\t\telse\n\t\t\t\t\t\techo '<a style=\"background-color: green\"><strike>' . $this->popisRijeci[$i] . '</strike></a>';\n\t\t\t\t}\n\t\t\t?>\n\n\t\t\t<br><br>\n\n\t\t\t<form action=\"<?php echo htmlentities( $_SERVER['PHP_SELF']); ?>\" method=\"post\">\n\t\t\t\t<label for=\"rijec\">Našao sam riječ:</label>\n\t\t\t\t<input type=\"text\" name=\"rijec\" id=\"rijec\" value=\"\" />\n\n\t\t\t\t<br>\n\n\t\t\t\t<label for=\"redak\">Prvo slovo je u redu </label>\n\t\t\t\t\t<select name=\"redak\" id=\"redak\">\n\t\t\t\t\t\t<option selected=\"selected\" value=\"1\">1</option>\n\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\tfor($i = 2; $i <= Osmosmjerka::N; $i++){\n\t\t\t\t\t\t\t\t?>\n\t\t\t\t\t\t\t\t<option value=\" <?php echo $i ?> \"> <?php echo $i ?> </option>\n\t\t\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t?>\n\t\t\t\t\t</select>\n\n\t\t\t\t<label for=\"stupac\">i u stupcu </label>\n\t\t\t\t\t<select name=\"stupac\" id=\"stupac\">\n\t\t\t\t\t\t<option selected=\"selected\" value=\"1\">1</option>\n\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\tfor($i = 2; $i <= Osmosmjerka::N; $i++){\n\t\t\t\t\t\t\t\t?>\n\t\t\t\t\t\t\t\t<option value=\" <?php echo $i ?> \"> <?php echo $i ?> </option>\n\t\t\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t?>\n\t\t\t\t\t</select>\n\n\t\t\t\t<br><br>\n\n\t\t\t\t<button type=\"submit\" name=\"submit\">Označi pronađenu riječ!</button>\n\t\t\t\t<br>\n\t\t\t\t<button type=\"submit\" name=\"reset\">Hoću sve ispočetka!</button>\n\n\t\t\t</form>\n\n\t\t</body>\n\t\t</html>\n\t\t<?php\n\t}", "title": "" }, { "docid": "d5cb349107b2246c30208f3dde63ce5e", "score": "0.514637", "text": "function get_pgrande($tienda,$filtro_caja,$codloc) {\n $sql = \"\n SELECT COALESCE(SUM(IF(prosic_categoria.id_categoria=6,detalle_mesa_pedido.cantidad,detalle_mesa_pedido.cantidad*0.5)),0) AS cantidad\n FROM detalle_mesa_pedido\n INNER JOIN prosic_producto ON (detalle_mesa_pedido.id_producto = prosic_producto.id_producto)\n INNER JOIN prosic_mesa_pedido ON (detalle_mesa_pedido.id_mesa_pedido = prosic_mesa_pedido.id_mesa_pedido)\n INNER JOIN prosic_categoria ON (prosic_producto.id_categoria = prosic_categoria.id_categoria)\n INNER JOIN prosic_caja ON (prosic_mesa_pedido.id_caja = prosic_caja.id_caja) \n WHERE prosic_caja.fecha_caja='\".$filtro_caja.\"'\n\t\t\t AND prosic_categoria.id_categoria IN(6,7) AND detalle_mesa_pedido.status_detalle NOT IN ('AN','EL')\";\n mysql_select_db($tienda);\n $res = $this->Consulta_Mysql($sql);\n $row = @mysql_fetch_assoc($res);\n return $row;\n }", "title": "" }, { "docid": "8712a4cd1469431eaa6a7d2e7885cd43", "score": "0.5141336", "text": "public function newGetWloknaStart($id_kabel,$id_mufa){\n\t\t$qb = $this->getEntityManager()\n\t\t->createQuery(\n\t\t\t\t'SELECT\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t(SELECT kl.id FROM SpsBundle:Wlokno wl \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel kl with wl.id_kabel=kl.id\n\t\t\t\t\tWHERE wl.id=w.id) as id_kabel_lewa,\n\t\t\t\t\n\t\t\t\t\t(SELECT m1.id FROM SpsBundle:Wlokno w1 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel k1 with w1.id_kabel=k1.id\n\t\t\t\t\tLEFT JOIN SpsBundle:Mufa m1 with k1.id_mufa_end=m1.id\n\t\t\t\t\tWHERE w1.id=w.id) as id_end_lewa,\n\t\t\t\t\n\t\t\t\t\t(SELECT m2.kod FROM SpsBundle:Wlokno w2 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel k2 with w2.id_kabel=k2.id\n\t\t\t\t\tLEFT JOIN SpsBundle:Mufa m2 with k2.id_mufa_end=m2.id\n\t\t\t\t\tWHERE w2.id=w.id) as kod_end_lewa,\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t(SELECT kk2.j FROM SpsBundle:Wlokno ww2 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel kk2 with ww2.id_kabel=kk2.id\n\t\t\t\t\tWHERE ww2.id=w.id) as j_end_lewa,\n\t\t\t\t\n\t\t\t\t\t(SELECT kk3.producent FROM SpsBundle:Wlokno ww3 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel kk3 with ww3.id_kabel=kk3.id\n\t\t\t\t\tWHERE ww3.id=w.id) as producent_end_lewa,\n\t\t\t\t\n\t\t\t\t\t(SELECT kk4.tubs FROM SpsBundle:Wlokno ww4 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel kk4 with ww4.id_kabel=kk4.id\n\t\t\t\t\tWHERE ww4.id=w.id) as tubs_end_lewa,\n\t\t\t\t\t\n\t\t\t\t\t(SELECT m4.id FROM SpsBundle:Wlokno w4 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel k4 with w4.id_kabel=k4.id\n\t\t\t\t\tLEFT JOIN SpsBundle:Mufa m4 with k4.id_mufa_start=m4.id\n\t\t\t\t\tWHERE w4.id=w.id) as id_start_lewa,\n\t\t\t\t\n\t\t\t\t\t(SELECT m3.kod FROM SpsBundle:Wlokno w3 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel k3 with w3.id_kabel=k3.id\n\t\t\t\t\tLEFT JOIN SpsBundle:Mufa m3 with k3.id_mufa_start=m3.id\n\t\t\t\t\tWHERE w3.id=w.id) as kod_start_lewa,\n\t\t\t\t\t\n\t\t\t\t\tw.id as id_w_lewa,\n\t\t\t\t \n\t\t\t\t\t(SELECT w5.id FROM SpsBundle:Wlokno w5\n\t\t\t\t\tWHERE w5.id =w.id_spaw_start) as id_w_prawa,\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t(SELECT m6.id FROM SpsBundle:Wlokno w6 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel k6 with w6.id_kabel=k6.id\n\t\t\t\t\tLEFT JOIN SpsBundle:Mufa m6 with k6.id_mufa_end=m6.id\n\t\t\t\t\tWHERE w6.id=w.id_spaw_start) as id_start_prawa,\n\t\t\t\t\n\t\t\t\t\t(SELECT m7.kod FROM SpsBundle:Wlokno w7 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel k7 with w7.id_kabel=k7.id\n\t\t\t\t\tLEFT JOIN SpsBundle:Mufa m7 with k7.id_mufa_end=m7.id\n\t\t\t\t\tWHERE w7.id=w.id_spaw_start) as kod_start_prawa,\n\t\t\t\t\n\t\t\t\t\t(SELECT kk7.producent FROM SpsBundle:Wlokno ww7 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel kk7 with ww7.id_kabel=kk7.id\n\t\t\t\t\tWHERE ww7.id=w.id_spaw_start) as producent_start_prawa,\n\t\t\t\t\n\t\t\t\t\t(SELECT kk8.j FROM SpsBundle:Wlokno ww8 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel kk8 with ww8.id_kabel=kk8.id\n\t\t\t\t\tWHERE ww8.id=w.id_spaw_start) as j_start_prawa,\n\t\t\t\t\n\t\t\t\t\t(SELECT kk9.tubs FROM SpsBundle:Wlokno ww9 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel kk9 with ww9.id_kabel=kk9.id\n\t\t\t\t\tWHERE ww9.id=w.id_spaw_start) as tubs_start_prawa,\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t(SELECT m8.id FROM SpsBundle:Wlokno w8 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel k8 with w8.id_kabel=k8.id\n\t\t\t\t\tLEFT JOIN SpsBundle:Mufa m8 with k8.id_mufa_end=m8.id\n\t\t\t\t\tWHERE w8.id_spaw_end=w.id_spaw_start) as id_end_prawa,\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t(SELECT m9.kod FROM SpsBundle:Wlokno w9 \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel k9 with w9.id_kabel=k9.id\n\t\t\t\t\tLEFT JOIN SpsBundle:Mufa m9 with k9.id_mufa_end=m9.id\n\t\t\t\t\tWHERE w9.id_spaw_end=w.id_spaw_start) as kod_end_prawa,\n\t\t\t\t\n\t\t\t\t\t(SELECT kr.id FROM SpsBundle:Wlokno wr \n\t\t\t\t\tLEFT JOIN SpsBundle:Kabel kr with wr.id_kabel=kr.id\n\t\t\t\t\tWHERE wr.id_spaw_end=w.id_spaw_start) as id_kabel_prawa\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\tFROM SpsBundle:Wlokno w\n\t\t\t\tLEFT JOIN SpsBundle:Kabel k with k.id = w.id_kabel\n \t WHERE k.id =:id_kabel\n\t\t\t\tAND k.id_mufa_start=:id_mufa\n\t\t\t\t\n\t\n\t\t\t\t'\n\t\t)->setParameter('id_kabel', $id_kabel)\n\t\t->setParameter('id_mufa', $id_mufa)\n\t\t;\n\n\t\treturn $qb->getResult();\n\t}", "title": "" }, { "docid": "3be867a32963d9a56ad508f26d1c4e99", "score": "0.51386374", "text": "function obliczSD($populacja_kraju,$rozmiar_parlamentu)\n\t{\n\t\t$this->SD_c = round( ($populacja_kraju/$rozmiar_parlamentu),2);\t\t\n\t}", "title": "" }, { "docid": "35402d4519d85f4f794109746d103d55", "score": "0.5138007", "text": "function kdautogejala($tabel, $inisial){\r\n\t$struktur\t= mysql_query(\"SELECT * FROM $tabel\");\r\n\t$field\t\t= mysql_field_name($struktur, 0);\r\n\t$panjang\t= mysql_field_len($struktur, 0);\r\n\t\r\n\t$qry\t= mysql_query(\"SELECT max(\".$field.\") FROM \".$tabel);\r\n\t$row\t= mysql_fetch_array($qry);\r\n\tif ($row[0]==\"\"){\r\n\t\t$angka = 0;\r\n\t}\r\n\telse {\r\n\t\t$angka = substr($row[0], strlen($inisial));\r\n\t}\r\n\t\r\n\t$angka++;\r\n\t$angka = strval($angka);\r\n\t$tmp = \"\";\r\n\tfor($i=1; $i <= ($panjang-strlen($inisial)-strlen($angka)); $i++){\r\n\t\t$tmp = $tmp.\"0\";\r\n\t}\r\n\treturn $inisial.$tmp.$angka;\r\n}", "title": "" }, { "docid": "55a445afe3ca1898f455ce093282a923", "score": "0.51319414", "text": "public function getriset(){\n $data = $this->db->get('penelitian');\n return $data;\n }", "title": "" }, { "docid": "111605464715545fdea30e0a1835f0c3", "score": "0.5129453", "text": "function transporteur($ressources,$transporteur,$user_building,$Hyp=0)\r\n{\r\n global $user_data;\r\n\t$start = 101;\r\n\t$nb_planete = find_nb_planete_user($user_data[\"user_id\"]);\r\n\t$result = array();//force l'interpretation de $result comme un array : retire des erreurs (silencieuses) dns le journal des PHP 5\r\n\t// Calcul de la capacité des transporteurs\r\n\t$Capac_GT = 25000 * 0.05 * $Hyp + 25000;\r\n\t$Capac_PT = 5000 * 0.05 * $Hyp + 5000;\r\n\r\n\t\r\n\tfor ($i=$start ; $i<=$start+$nb_planete -1 ; $i++) \r\n\t\t{\r\n\t\t\t$result[$i]=1;\r\n\t\t\t// test planète existante\r\n\t\t\tif($user_building[$i][0] === TRUE)\r\n\t\t\t\t{\r\n\t\t\t\t\tif($transporteur==\"GT\")\r\n\t\t\t\t\t$result[$i]=ceil($ressources[$i]/$Capac_GT);\r\n\r\n\t\t\t\t\tif($transporteur==\"PT\")\r\n\t\t\t\t\t$result[$i]=ceil($ressources[$i]/$Capac_PT);\r\n\t\t\t\t}\r\n\t\t}\r\n\treturn $result;\r\n}", "title": "" }, { "docid": "882fdff73f0394fb943288019a2cbf68", "score": "0.51256377", "text": "public function codigopq(){\n $stmt=$this->objPDO->prepare(\"SELECT ltrim(to_char((CASE WHEN max(codigo)is null THEN 1 ELSE max(codigo)+1 END),'00000')) as nuevo from sisanatom.biopsia b\n inner join sisanatom.topografia_area ta on ta.id_top=b.id_top\n WHERE EXTRACT(YEAR FROM fecha_ingreso)=(SELECT EXTRACT(YEAR FROM current_date)) and ta.id_area=1\");\n $stmt->execute();\n $codpq=$stmt->fetchAll(PDO::FETCH_OBJ);\n return $codpq[0]->nuevo;\n }", "title": "" }, { "docid": "bad57c008321bb38b6d07848b0e2bef0", "score": "0.5124801", "text": "public function min($parametro)\n {\n }", "title": "" }, { "docid": "11c337b21b3bbe8528fc49ec361b215c", "score": "0.5106279", "text": "function getmenu_star_pengajuan($level){\n\t\tswitch($level){\n\t\t\tcase'KTU':$sts='0';break;\n\t\t\tcase'KKR':$sts='1';break;\n\t\t\tcase'STB':$sts='2';break;\n\t\t}\n\t\t$sql=mysql_query(\"select count(id) as num from $this->table_pengajuan where status='$sts'\");\n\t\twhile($row=mysql_fetch_assoc($sql))\n\t\tif($row['num']>0){\n\t\t\treturn $row['num'];\n\t\t}\n\t\treturn '0';\n\t}", "title": "" }, { "docid": "3038365dbf9e03413159968e109bb513", "score": "0.51055676", "text": "public function getPerifericos()\r\n {\r\n }", "title": "" }, { "docid": "27e94bdb0320fd836e5042b39f4067b0", "score": "0.50962186", "text": "function vrati_minimum_maksimum_srednavrednost_na_nizata($abrakadabra){\n\n\t$min = $abrakadabra[0];\n\t$max = $abrakadabra[0];\n\t$zbir = 0;\n\n\tforeach ($abrakadabra as $value) {\n\t\t\n\t\tif( $min > $value){\n\t\t\t$min = $value;\n\t\t}\n\n\t\tif( $max < $value){\n\t\t\t$max = $value;\n\t\t}\n\n\t\t$zbir += $value;\n\t}\n\n\treturn [ $min , $max , $zbir/count($abrakadabra) ];\n\t\n\t// return [ \n\t// \t\t\t'min' => $min , \n\t// \t\t\t'max' => $max , \n\t// \t\t\t'avg' => $zbir/count($abrakadabra) \n\t// \t\t];\n}", "title": "" }, { "docid": "fba2a11ef1aec5e9d49a0a9db36069a0", "score": "0.50958276", "text": "function luasPersegi($sisi){ //membuat luasPersegi untuk dipanggil\n return $luas = pow($sisi, 2);\n }", "title": "" }, { "docid": "68793e84e69666d59ec1597ff1a95ebc", "score": "0.5095006", "text": "function przepisy_ID_Kategoria($y)\n{\n $tab=[];\n $xy=0;\n if (isset($_COOKIE['kategoria'])) {\n foreach ($_COOKIE['kategoria'] as $name => $value) {\n $name = htmlspecialchars($name);\n $value = htmlspecialchars($value);\n $tab[$xy] = $value;\n $xy++;\n }\n }\n\n $ileKat = count($tab);\n\n\n if($ileKat == 1){\n if($tab[0]=='Dowolne')\n {\n $kat = PrzepisQuery::create()\n ->select(array('Przepis.IdPrzepis'))\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n else{\n $kat = NalezyQuery::create()\n ->join('Przepis')\n ->join('Kategoria')\n ->where('Kategoria.Nazwa IN ?', $tab)\n ->select(array('Przepis.IdPrzepis'))\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n }\n else\n {\n $kat = NalezyQuery::create()\n ->join('Przepis')\n ->join('Kategoria')\n ->select(array('Przepis.IdPrzepis'))\n ->where('Kategoria.Nazwa IN ?', $tab)\n ->groupBy(array('Przepis.IdPrzepis'))\n ->having(\"count(Przepis.IdPrzepis) = ?\", $ileKat)\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n\n}", "title": "" }, { "docid": "a35fa0d02221640357d3c55d2f733c3d", "score": "0.50928116", "text": "function getPrijsByConfGebruiker($id,$confId)\n { \n $geld = 0;\n \n $this->db->where('gebruikerId', $id);\n $query = $this->db->get('gebruikerActiviteit');\n $activiteitenGeb = $query->result();\n \n $this->load->model('activiteit_model'); \n foreach ($activiteitenGeb as $a){\n $a->activiteit = $this->activiteit_model->get($a->activiteitId); \n // Controleren of de activiteit wel bij de juiste conferentie hoort\n if ($a->activiteit->conferentieId == $confId)\n {\n $g->activiteit = $this->activiteit_model->get($a->activiteitId);\n $geld += ($a->activiteit->prijs * $a->aantalPersonen);\n }\n } \n return $geld;\n }", "title": "" }, { "docid": "4682d5f21b9810030eabc5e00047db9e", "score": "0.5092683", "text": "function setFidiOC(){\n\t\t$db=$this->db;\n\t\t$sql=\"UPDATE oneri.oneri_concessori SET fideiussione=coalesce((SELECT sum(totale-coalesce(versato,0)) FROM oneri.rate WHERE rata in (2,3) and pratica=$this->pratica),0) WHERE pratica=$this->pratica;\";\n $db->sql_query($sql);\n\t}", "title": "" }, { "docid": "062b7cc176ff46f037de2dc87454832f", "score": "0.5087539", "text": "function tampil_pelanggan()\n\t{\n\t\t$ambildata = $this->koneksi->query(\"SELECT * FROM pelanggan\");\n\t\t//2.pecah ke array dan diperulangkan\n\t\twhile($pecahdata = $ambildata->fetch_assoc())\n\t\t{\n\t\t\t//3.gabungan array ke semuadata (array multidemensi)\n\t\t\t$semuadata[] = $pecahdata;\n\t\t}\n\t\t//4.outputkan semua sebagai hasil akhir\n\t\treturn $semuadata;\n\t}", "title": "" }, { "docid": "20e6afa1ffcfca190a054bc1eca7c5e1", "score": "0.5087229", "text": "private function lps()\n {\n if(!empty($this->fechafac))\n {\n $lpeleg = Lp::join('lpclies', 'lpclies.lp', '=', 'lps.id')\n ->where('lpclies.cliente', $this->nit)\n ->where('lps.estado', 2)\n ->whereDate('lps.inicio', '<=', $this->fechafac)\n ->whereDate('lps.fin', '>=', $this->fechafac)\n ->select('lps.lista', 'lps.id')\n ->first();\n\n if($lpeleg){\n $this->lp = $lpeleg->id;\n $this->lpsel = 1;\n return $lpeleg;\n } else {\n $this->lpsel='';\n }\n\n\n }\n }", "title": "" }, { "docid": "ad0bf413bb5fd99ebe083ba193e8620f", "score": "0.5084844", "text": "function calculaPontos(){\n\t\t$this->pontos = $this->vitorias * 3 + $this->empates;\n\t}", "title": "" }, { "docid": "fc587c605b216fea36df5a250c029f3f", "score": "0.5080598", "text": "function przepisy_ID_KategoriaCzas($y)\n{\n $tab=[];\n $xy=0;\n if (isset($_COOKIE['kategoria'])) {\n foreach ($_COOKIE['kategoria'] as $name => $value) {\n $name = htmlspecialchars($name);\n $value = htmlspecialchars($value);\n $tab[$xy] = $value;\n $xy++;\n }\n }\n\n $ileKat = count($tab);\n\n if($ileKat == 1){\n if($tab[0]=='Dowolne')\n {\n $kat = PrzepisQuery::create()\n ->where('Przepis.CzasPrzygotowania = ?', $_COOKIE[\"czas\"])\n ->select(array('Przepis.IdPrzepis'))\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n else{\n $kat = NalezyQuery::create()\n ->join('Przepis')\n ->join('Kategoria')\n ->where('Przepis.CzasPrzygotowania = ?', $_COOKIE[\"czas\"])\n ->where('Kategoria.Nazwa = ?', $tab[0])\n ->select(array('Przepis.IdPrzepis'))\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n }\n else\n {\n $kat = NalezyQuery::create()\n ->join('Przepis')\n ->join('Kategoria')\n ->select(array('Przepis.IdPrzepis'))\n ->where('Przepis.CzasPrzygotowania = ?', $_COOKIE[\"czas\"])\n ->where('Kategoria.Nazwa IN ?', $tab)\n ->groupBy(array('Przepis.IdPrzepis'))\n ->having(\"count(Przepis.IdPrzepis) = ?\", $ileKat)\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n\n}", "title": "" }, { "docid": "70e1c8d62c577c09ae3fbe415fa9ea9d", "score": "0.50778306", "text": "public function koniecobrony() {\n if ($this->aktywnaObrona == true) {\n $odejmij = ($this->param->getZrecznosc() / 3);\n\n $this->param->setZrecznosc($this->param->getZrecznosc() - $odejmij);\n\n $this->aktywnaObrona = false;\n }\n\n return $this->aktywnaObrona;\n }", "title": "" }, { "docid": "5f22ab745dccdf2bcab853715b7918d0", "score": "0.50770015", "text": "function przepisy_ID_KategoriaNazwa($y)\n{\n $tab=[];\n $xy=0;\n if (isset($_COOKIE['kategoria'])) {\n foreach ($_COOKIE['kategoria'] as $name => $value) {\n $name = htmlspecialchars($name);\n $value = htmlspecialchars($value);\n $tab[$xy] = $value;\n $xy++;\n }\n }\n\n $ileKat = count($tab);\n\n if($ileKat == 1){\n if($tab[0]=='Dowolne')\n {\n $kat = PrzepisQuery::create()\n ->where('Przepis.Nazwa LIKE ?', '%'.$_COOKIE['przepis'].'%')\n ->select(array('Przepis.IdPrzepis'))\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n else{\n $kat = NalezyQuery::create()\n ->join('Przepis')\n ->join('Kategoria')\n ->where('Przepis.Nazwa LIKE ?', '%'.$_COOKIE['przepis'].'%')\n ->where('Kategoria.Nazwa = ?', $tab[0])\n ->select(array('Przepis.IdPrzepis'))\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n }\n else\n {\n $kat = NalezyQuery::create()\n ->join('Przepis')\n ->join('Kategoria')\n ->select(array('Przepis.IdPrzepis'))\n ->where('Przepis.Nazwa LIKE ?', '%'.$_COOKIE['przepis'].'%')\n ->where('Kategoria.Nazwa IN ?', $tab)\n ->groupBy(array('Przepis.IdPrzepis'))\n ->having(\"count(Przepis.IdPrzepis) = ?\", $ileKat)\n ->paginate($page = $y, $rowsPerPage = 10);\n\n return $kat;\n }\n\n}", "title": "" }, { "docid": "dced1c50077b628d919e0b1fc1f5ca43", "score": "0.5073", "text": "abstract function niveauEtude();", "title": "" }, { "docid": "b1c087066cbace37fd9cfd220605db61", "score": "0.5069127", "text": "function calcularBolsasDisp($idBolsa){\r\n $database = JFactory::getDBO();\r\n\t\r\n $sql1 = \"SELECT quantidade FROM #__bolsas WHERE id = '$idBolsa'\";\r\n $database->setQuery($sql1);\r\n $bolsa = $database->loadObjectList();\r\n\t\r\n\t$sql2 = \"SELECT COUNT(*) as bolsistas FROM #__bolsas_aloc WHERE idBolsa = '$idBolsa' AND status='Ativa'\";\r\n $database->setQuery($sql2);\r\n $bolsa_aloc = $database->loadObjectList();\r\n\t\r\n\t$total = $bolsa[0]->quantidade;\r\n\t$bolsitas = $bolsa_aloc[0]->bolsistas;\r\n\t\r\n\t$disponiveis = $total - $bolsitas;\r\n\t$alocadas = $bolsitas;\r\n\t\r\n\treturn $alocadas;\r\n}", "title": "" }, { "docid": "497692d072c566bfab85d8c603d5ce26", "score": "0.5068158", "text": "function napada( $targetVojska )\n {\n // takodjer, ne moze napasti ako je mrtav\n if( ( $this->brMetaka > 0 ) && ( $this->ziv ) )\n {\n //smanji mu broj metaka\n $this->brMetaka -= 1;\n\n // napada vojnika iz protivnicke vojske koji je prvi po indeksu\n // oduzima mu 3 zivota, tj. ubija ga\n\n //trazi prvog zivog\n $i = 0;\n\n while( 1 )\n {\n $odabraniVojnik = $targetVojska->vojska[ $i ];\n\n if( $odabraniVojnik->ziv )\n {\n // oduzima mu sve preostale zivote (neovisno o tome koliko ih je izgubio do sad)\n for( $j = 0; $j < 3; ++$j )\n {\n $odabraniVojnik->zivoti[ $j ] = false;\n }\n $targetVojska->brojVojnika -= 1;\n $odabraniVojnik->ziv = false;\n break;\n }\n ++$i;\n }\n }\n }", "title": "" }, { "docid": "5ad7c893fccf48ceb87b25398d6050fb", "score": "0.5067555", "text": "function panierCompte( &$Panier )\n//- 10b -----------------------------------------------------------------------------------------\n// FUNCTION : panierCompte\n// version : 2.0\n// date : 2007-12-09\n// derniere modif : Denis Léveillé\n// info : Compte le nombre d'articles dans le panier\n{\n if( !isset($Panier) || !is_array($Panier) || !count($Panier) )\n return 0;\n\n $nbArticles = 0;\n\n foreach( $Panier as $id => $item){\n $nbArticles += @$item['Qte'];\n }\n\n return $nbArticles;\n}", "title": "" }, { "docid": "f7d4f3c2f47525d73eb2ac1a5eecc72c", "score": "0.50648713", "text": "public function kupi()\n {\n if (isset($_SESSION['korpa']) && count($_SESSION['korpa']) > 0 && $this->validate(['brkartice'=>'required' , 'mesec'=>'required' , 'god'=>'required' , 'cvc'=>'required']))\n {\n $newsDB = new News();\n $usersDB = new User();\n /*$korime = $this->session->get('user')->KorIme;\n $korisnik = $usersDB->where('KorIme', $korime)->find();*/\n\n $iddog = [];\n foreach ($_SESSION['korpa'] as $key => $value)\n array_push($iddog, $key);\n\n $news = $newsDB->findid($iddog);\n\n $suma = 0;\n\n $maxid = 0;\n $transakcijaDB = new Transakcija();\n $row = $transakcijaDB->selectMax(\"IdT\");\n if(isset($row)) $maxid = $row->IdT;\n $maxid++;\n\n $stavka = new Stavka();\n foreach ($news as $dog)\n {\n $id = $dog->IdD;\n\n $s_data['IdD'] = $id;\n $s_data['Cena'] = $dog->Cena;\n $s_data['Kolicina'] = $_SESSION['korpa'][$id];\n $s_data['IdT'] = $maxid;\n $stavka->insert($s_data);\n //array_push($stavke, $s_data);\n\n $suma += $dog->Cena * $_SESSION['korpa'][$id];\n }\n $brkartice = $_POST['brkartice'];\n\n\n\n\n $transakcijaDB->insert(\n [\n 'Cena' => $suma,\n 'BrojKartice' => $brkartice,\n 'KorIme' => $this->session->get('user')->KorIme\n ]\n\n );\n unset($_SESSION['korpa']);\n\n $this->index();\n //$this->prikaz(\"index\", []);\n }\n else\n return $this->korpa();\n }", "title": "" }, { "docid": "4b11d685b2f0f725f0291c1c36713017", "score": "0.50644255", "text": "function getPrestito()\n\t{\n\t\treturn f_persistance::getInstance()->carica(e_libro::class, $this->id, f_target::CARICA_PRESTITO);\n\t}", "title": "" }, { "docid": "0121155110ad964fb52b1fb07e4c2580", "score": "0.50576097", "text": "function ressourcespetithangar($autonomieM,$autonomieC,$autonomieD,$user_building)\r\n{\r\n global $user_data;\r\n\t$start = 101;\r\n\t$nb_planete = find_nb_planete_user($user_data[\"user_id\"]);\r\n\t$result = array();//force l'interpretation de $result comme un array : retire des erreurs (silencieuses) dns le journal des PHP 5\r\n\t\r\n\tfor ($i=$start ; $i<=$start+$nb_planete -1 ; $i++) \r\n\t\t{\r\n\t\t\t// test planete existante\r\n\t\t\tif($user_building[$i][0] === TRUE)\r\n\t\t\t\t{\r\n\t\t\t\t\t// lorsque pas d'autonomie, il faut quand meme des valeurs pour comparer\r\n\t\t\t\t\tif (empty($autonomieM[$i])) $autonomieM[$i] = 9999999;\r\n\t\t\t\t\tif (empty($autonomieC[$i])) $autonomieC[$i] = 9999999;\r\n\t\t\t\t\tif (empty($autonomieD[$i])) $autonomieD[$i] = 9999999;\r\n\r\n\t\t\t\t\tif($autonomieM[$i]<=$autonomieC[$i] and $autonomieM[$i]<=$autonomieD[$i])\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t$temps= $autonomieM[$i];\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\telseif($autonomieC[$i]<=$autonomieM[$i] and $autonomieC[$i]<=$autonomieD[$i])\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t$temps= $autonomieC[$i];\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\telseif($autonomieD[$i]<=$autonomieM[$i] and $autonomieD[$i]<=$autonomieC[$i])\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t$temps= $autonomieD[$i];\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t$result[$i]=($user_building[$i]['M_hour']+$user_building[$i]['C_hour']+$user_building[$i]['D_hour'])*$temps;\r\n\t\t\t\t}\r\n\t\t}\r\n\treturn $result;\r\n}", "title": "" } ]
20aedf6de8b8cf069ca87070fd6e4ee4
Adds a JOIN clause to the query using the PageRelatedByid relation
[ { "docid": "11a1724e8e38955a6b4f8a76fc6e2d43", "score": "0.6038807", "text": "public function joinPageRelatedByid($relationAlias = null, $joinType = Criteria::LEFT_JOIN)\n {\n $tableMap = $this->getTableMap();\n $relationMap = $tableMap->getRelation('PageRelatedByid');\n\n // create a ModelJoin object for this join\n $join = new ModelJoin();\n $join->setJoinType($joinType);\n $join->setRelationMap($relationMap, $this->useAliasInSQL ? $this->getModelAlias() : null, $relationAlias);\n if ($previousJoin = $this->getPreviousJoin()) {\n $join->setPreviousJoin($previousJoin);\n }\n\n // add the ModelJoin to the current object\n if ($relationAlias) {\n $this->addAlias($relationAlias, $relationMap->getRightTable()->getName());\n $this->addJoinObject($join, $relationAlias);\n } else {\n $this->addJoinObject($join, 'PageRelatedByid');\n }\n\n return $this;\n }", "title": "" } ]
[ { "docid": "a8a835d90f8b8bddbc6a5d95b31eb490", "score": "0.60950625", "text": "public function usePageRelatedByidQuery($relationAlias = null, $joinType = Criteria::LEFT_JOIN)\n {\n return $this\n ->joinPageRelatedByid($relationAlias, $joinType)\n ->useQuery($relationAlias ? $relationAlias : 'PageRelatedByid', '\\m038\\KunstkamerBundle\\Model\\PageQuery');\n }", "title": "" }, { "docid": "f586255645255232ad0a6613a96f0d07", "score": "0.5606996", "text": "function location_search_join( $join ) {\n global $wpdb;\n return $join .=' LEFT JOIN '.$wpdb->postmeta. ' ON '. $wpdb->posts . '.ID = ' . $wpdb->postmeta . '.post_id ';\n}", "title": "" }, { "docid": "792abfaf53d7389f859c089abb429a1a", "score": "0.55683225", "text": "function cf_search_join( $join ) {\n global $wpdb;\n\n if ( is_search() ) {\n $join .=' LEFT JOIN '.$wpdb->postmeta. ' ON '. $wpdb->posts . '.ID = ' . $wpdb->postmeta . '.post_id ';\n }\n\n return $join;\n}", "title": "" }, { "docid": "792abfaf53d7389f859c089abb429a1a", "score": "0.55683225", "text": "function cf_search_join( $join ) {\n global $wpdb;\n\n if ( is_search() ) {\n $join .=' LEFT JOIN '.$wpdb->postmeta. ' ON '. $wpdb->posts . '.ID = ' . $wpdb->postmeta . '.post_id ';\n }\n\n return $join;\n}", "title": "" }, { "docid": "792abfaf53d7389f859c089abb429a1a", "score": "0.55683225", "text": "function cf_search_join( $join ) {\n global $wpdb;\n\n if ( is_search() ) {\n $join .=' LEFT JOIN '.$wpdb->postmeta. ' ON '. $wpdb->posts . '.ID = ' . $wpdb->postmeta . '.post_id ';\n }\n\n return $join;\n}", "title": "" }, { "docid": "27ce255aecc8933d64e714d96a802cc8", "score": "0.5537664", "text": "private function add_relationship_query_join( $join, $wp_query ) {\n\t\t// of the posts_where filter (it comes before posts_join)\n\t\treturn $join . ' ' . $this->get_table_join_manager( $wp_query )->get_join_clauses() . ' ';\n\t}", "title": "" }, { "docid": "84c8fe242ef7437dfdfe7fdd5e1a8aa9", "score": "0.55354077", "text": "protected function _innerJoin()\n\t{\n\t\t\n\t}", "title": "" }, { "docid": "8c6b55524fb0f697546b24b470ff2846", "score": "0.5459296", "text": "public function get_sql_join();", "title": "" }, { "docid": "a336b04b5b18365d443435dbc5ce2de8", "score": "0.5456108", "text": "public function getJoin()\n {\n $jta = false;\n if(!isset($this->def['source']) || $this->def['source'] == 'db') {\n return false;\n }\n $related = false;\n $bean = $this->query->getFromBean();\n if (isset($this->def['type'])) {\n if ($bean instanceof SugarBean) {\n $related = in_array($this->def['type'], $bean::$relateFieldTypes);\n } else {\n $related = ($this->def['type'] == 'related');\n }\n }\n if ($related\n || (isset($this->def['source']) && $this->def['source'] == 'non-db'\n // For some reason the full_name field has 'link' => true\n && isset($this->def['link']) && $this->def['link'] !== true)\n ) {\n $params = array(\n 'joinType' => 'LEFT',\n );\n if (!isset($this->def['link'])) {\n if (!isset($this->def['id_name']) || !isset($this->def['module'])) {\n throw new SugarQueryException(\"No ID field Name or Module Name\");\n }\n // we may need to put on our detective hat and see if we can\n // hunt down a relationship\n $farBean = BeanFactory::getDefinition($this->def['module']);\n\n // check if relate field refers some other field as id_name, otherwise we may get infinite recursion\n if ($this->def['id_name'] != $this->def['name']\n // check and see if we need to do the join, it may already be done.\n && (!$this->query->getJoinAlias($farBean->table_name)\n || !$this->query->getJoinAlias($this->def['name']))) {\n //Custom relate fields may have the id field on the custom table, need to check for that.\n $idField = new SugarQuery_Builder_Field($this->def['id_name'], $this->query);\n $idField->setupField($this->query);\n $idField->checkCustomField();\n if ($idField->custom) {\n $this->custom = true;\n }\n //Now actually join the related table\n $jta = $this->query->getJoinTableAlias($this->def['name']);\n $this->query->joinTable($farBean->table_name, array(\n 'joinType' => 'LEFT',\n 'bean' => $farBean,\n 'alias' => $jta,\n ))\n ->addLinkName($this->def['id_name'])\n ->on()->equalsField(\"{$idField->table}.{$this->def['id_name']}\", \"{$jta}.id\")\n ->equals(\"{$jta}.deleted\", 0);\n }\n }\n if (!empty($this->def['link']) && !$this->query->getJoinAlias($this->def['link'])) {\n if ($this instanceof SugarQuery_Builder_Field_Select) {\n $params['team_security'] = false;\n }\n if (isset($this->def['id_name']) && $this->def['id_name'] != $this->def['name']) {\n //Custom relate fields may have the id field on the custom table, need to check for that.\n $idField = new SugarQuery_Builder_Field_Select($this->def['id_name'], $this->query);\n $idField->setupField($this->query);\n $idField->checkCustomField();\n if ($idField->custom) {\n $this->custom = true;\n }\n }\n $join = $this->query->join($this->def['link'], $params);\n $jta = $join->joinName();\n } elseif(!empty($this->def['link']) && $this->query->getJoinAlias($this->def['link'])) {\n $jta = $this->query->getJoinAlias($this->def['link']);\n }\n\n if (!empty($this->def['rname_link'])) {\n $jta = $this->query->getJoinAlias($this->def['link']);\n $this->query->rname_link = $jta;\n $this->table = !empty($this->query->join[$jta]->relationshipTableAlias) ? $this->query->join[$jta]->relationshipTableAlias : $jta;\n }\n }\n return $jta;\n }", "title": "" }, { "docid": "b9f254ef841e66471d8fdfe9be172ac2", "score": "0.5455505", "text": "function join($relation)\n {\n return $this->from()->join($relation);\n }", "title": "" }, { "docid": "b4b6e9ccf28f012a78c4469bdad7d82f", "score": "0.5426545", "text": "public function filter_posts_join( $join ) {\n\t\tglobal $wpdb;\n\n\t\tif ( $this->is_search() ) {\n\t\t\t$join = \"LEFT JOIN {$wpdb->postmeta} ON {$wpdb->posts}.ID = {$wpdb->postmeta}.post_id \";\n\t\t}\n\n\t\treturn $join;\n\t}", "title": "" }, { "docid": "1f01b593a845f672d474399dc75900f6", "score": "0.5317975", "text": "function buildQueryJoin( $join = '', $current_query ) {\r\n\t\tglobal $wpdb;\r\n\t\t\r\n\t\t$join .= ' INNER JOIN '.$wpdb->simple_post_gmaps.' ON ( '.$wpdb->simple_post_gmaps.'.post_id = '.$wpdb->prefix.'posts.ID )';\r\n\t\treturn $join;\r\n\t}", "title": "" }, { "docid": "2484f79402293c8ce05b6d8fdbc9b04e", "score": "0.5303331", "text": "private function oneToManyQuery(Association $association, string $id): QueryInterface\n {\n // pagination hack to modify alias\n $association->setTarget($association->getTarget());\n $association->getTarget()->setAlias($this->_controller()->getName());\n\n /** @var string $foreignKey */\n $foreignKey = $association->getForeignKey();\n\n $query = $association->find('all')->where([\n $association->getTarget()->aliasField($foreignKey) => $id,\n ]);\n\n return $query;\n }", "title": "" }, { "docid": "3608dda16bdb572efcc8f87d41ea5560", "score": "0.5280131", "text": "function join_postmeta( $join, &$query )\n {\n if ( $query->is_search() && ! $query->get('suppress_filters') && $this->search_postmeta ) {\n global $wpdb;\n\n $meta = \" INNER JOIN $wpdb->postmeta ON ( $wpdb->posts.ID = $wpdb->postmeta.post_id ) \";\n\n if ( false === strpos( $join, $meta ) ) {\n $join .= $meta;\n }\n }\n\n return $join;\n }", "title": "" }, { "docid": "033e47c9749d25aef1e533dffe9e211b", "score": "0.5271881", "text": "function tmpl_wpml_posts_joins($join){\r\n\tglobal $wpdb, $pagenow, $wp_taxonomies,$ljoin;\r\n\t$language_where='';\t\r\n\tif(is_plugin_active('sitepress-multilingual-cms/sitepress.php')){\r\n\t\t$language = ICL_LANGUAGE_CODE;\r\n\t\t$join .= \" {$ljoin} JOIN {$wpdb->prefix}icl_translations t1 ON {$wpdb->posts}.ID = t1.element_id AND t1.element_type IN ('post_post') JOIN {$wpdb->prefix}icl_languages l1 ON t1.language_code=l1.code AND l1.active=1 AND t1.language_code='{$language}'\";\r\n\t}\r\n\treturn $join;\r\n}", "title": "" }, { "docid": "9d24867be272de7b485a913a3f96012c", "score": "0.5195353", "text": "private function get_single_join_clause_for_wpml(\n\t\t$relationship_id,\n\t\t$associations_table_alias,\n\t\t$role_to_return_column,\n\t\t$role_to_query_by_column,\n\t\t$element_to_query_by\n\t) {\n\n\t\t$alias_translation = 'toolset_t_' . $this->uniqe_table_alias->generate(\n\t\t\t$this->wpml_service->icl_translations_table_name(),\n\t\t\ttrue\n\t\t);\n\n\t\t$alias_default_lang = 'toolset_dl_' . $this->uniqe_table_alias->generate(\n\t\t\t\t$this->wpml_service->icl_translations_table_name(),\n\t\t\t\ttrue\n\t\t\t);\n\n\t\t$clause = $this->wpdb->prepare(\n\t\t\t\"\n\t\t\t# join the icl_translations table independently from WPML's 't'\n\t\t\t# because that one may not be joined at all time, but we \n\t\t\t# need it always - this is safer than trying to reuse the 't' one\n\t\t\tLEFT JOIN {$this->wpml_service->icl_translations_table_name()} AS {$alias_translation} ON (\n\t\t\t\twp_posts.ID = {$alias_translation}.element_id\n\t\t\t\tAND {$alias_translation}.element_type = CONCAT('post_', wp_posts.post_type)\n\t\t\t) LEFT JOIN {$this->wpml_service->icl_translations_table_name()} AS {$alias_default_lang} ON (\n\t\t\t {$alias_translation}.trid = {$alias_default_lang}.trid\n\t\t\t AND {$alias_default_lang}.language_code = %s\n\t\t\t) JOIN {$this->table_name->association_table()} AS {$associations_table_alias} ON (\n\t\t\t\t(\n\t\t\t\t\t# join the association row if either the post ID matches the\n\t\t\t\t\t# proper column in the associations table or if the ID of the default\n\t\t\t\t\t# language version of the post matches it\n\t\t\t\t\twp_posts.ID = {$associations_table_alias}.{$role_to_return_column}\n\t\t\t\t\tOR {$alias_default_lang}.element_id = {$associations_table_alias}.{$role_to_return_column}\n\t\t\t\t)\n\t\t\t\tAND {$associations_table_alias}.relationship_id = %d\n\t\t\t\tAND {$associations_table_alias}.{$role_to_query_by_column} = %d\n\t\t\t)\",\n\t\t\t$this->wpml_service->get_default_language(),\n\t\t\t$relationship_id,\n\t\t\t$element_to_query_by\n\t\t);\n\n\t\treturn $clause;\n\t}", "title": "" }, { "docid": "9a9e4f54be392c3189eafed73f094cc4", "score": "0.51487875", "text": "public function get_sql_join($context_level = '', $join_field = '') {\n $this->init_customfield_data();\n\n $joins = array();\n if (!empty($context_level) && !empty($this->sql_joins)) {\n $joins[] = 'LEFT JOIN {context} '.static::FIELDSET_NAME.'_ctx\n ON '.static::FIELDSET_NAME.'_ctx.contextlevel = '.$context_level.'\n AND '.static::FIELDSET_NAME.'_ctx.instanceid = '.$join_field;\n }\n return array_merge($joins, $this->sql_joins);\n }", "title": "" }, { "docid": "56d90952d186876da25172aa795fcca0", "score": "0.5127731", "text": "public function join_records($fields, $table1, $table2, $joinon, $where = '', $orderby = '', $limit = '', $start = '') {\n $this->db->select($fields);\n $this->db->from($table1);\n $this->db->join($table2, $joinon);\n\n if ($where != '')\n $this->db->where($where);\n\n if ($orderby != '')\n $this->db->order_by($orderby);\n\n if ($limit != '') {\n //if($start != '')\n $this->db->limit($limit, $start);\n //else\n //$this->db->limit($limit);\n }\n $query = $this->db->get();\n\n if ($query->num_rows() > 0) {\n return $query->result_array();\n } else {\n return false;\n }\n }", "title": "" }, { "docid": "6f52304caf3708f1dad6012d77a69474", "score": "0.511674", "text": "public function join($extra)\n { \n $join = array();\n\n if( !isset($this->config->{$this->active}->join ) ) return $this; \n\n\n if(is_array($this->config->{$this->active}->join))\n foreach ($this->config->{$this->active}->join as $field => $relation) \n {\n if(isset($relation->fields))\n {\n foreach ($relation->fields as $join_with) \n {\n $this->_select[]=$this->config->{$relation->table}->alias.\".\".$join_with.\" AS '{$relation->table}_{$join_with}'\";\n }\n }\n\n \n $join[]= replace($this->ql_join, array\n (\n 'table_a'=> $relation->table,\n 'alias_a'=> $this->config->{$relation->table}->alias,\n 'alias_b'=> $this->config->{$this->active}->alias,\n 'id_b' => $field,\n 'id_a' => \"id\"\n )); \n }\n\n if(is_array($extra))\n foreach ($extra as $item) \n {\n $pieces = explode(\".\", $item->union);\n $relation_table = $pieces[0];\n $relation_key = $pieces[1]; \n \n $tpl = ( $item->type == \"left\" ? $this->ll_join : $this->ql_join );\n \n //INNER JOIN {table_a} {alias_a} ON( {alias_a}.{id_a} = {alias_b}.{id_b} )\n\n $join[]= replace( $tpl, array\n (\n 'table_a'=> $item->with,\n 'alias_a'=> $this->alias($item->with),\n 'alias_b'=> $this->alias($relation_table),\n 'id_b' => $relation_key,\n 'id_a' => isset($item->key) ? $item->key : \"id\"\n ));\n }\n\n\n $this->current .= \"\\n\".implode(\"\\n\", $join); \n\n return $this;\n }", "title": "" }, { "docid": "a45fff5dc2a3921fad5c432715e290a9", "score": "0.50868464", "text": "public function handle_single_relationship_join( &$clauses, $id_column, $pass_thru_order ) {\n\t\tglobal $wpdb;\n\n\t\t$join = $this->build_single_relationship_join( $this->args, $clauses, $id_column, $pass_thru_order );\n\t\t$clauses['join'] .= \" INNER JOIN $wpdb->mb_relationships AS mbr ON $join\";\n\t}", "title": "" }, { "docid": "c758e86d0a4f0b610543f2a6f0c1b8d0", "score": "0.500625", "text": "public function filterByPageRelatedByid($page, $comparison = null)\n {\n if ($page instanceof Page) {\n return $this\n ->addUsingAlias(PagePeer::INTID, $page->getparentpage(), $comparison);\n } elseif ($page instanceof PropelCollection) {\n return $this\n ->usePageRelatedByidQuery()\n ->filterByPrimaryKeys($page->getPrimaryKeys())\n ->endUse();\n } else {\n throw new PropelException('filterByPageRelatedByid() only accepts arguments of type Page or PropelCollection');\n }\n }", "title": "" }, { "docid": "7bb05cc6add963dbb393d1481332ec35", "score": "0.4987307", "text": "protected function get_from_join_snippet() {\n\n\t\treturn \" FROM {$this->wpdb->posts} p\n\t JOIN {$this->wpdb->prefix}icl_translations wpml_translations\n\t\t\t\t\tON p.ID = wpml_translations.element_id\n\t\t\t\t\t\tAND wpml_translations.element_type = CONCAT('post_', p.post_type ) \";\n\t}", "title": "" }, { "docid": "f8e26646c29abb12af24a5fcb1b27150", "score": "0.4979315", "text": "public static function posts_join( $join )\r\n\t\t{\r\n\t\t\tglobal $wpdb;\r\n\t\t\tif ( strpos( $join, $wpdb->postmeta ) === false ) {\r\n\t\t\t\t$join .= ' INNER JOIN ' . $wpdb->postmeta . ' ON ( ' . $wpdb->posts . '.ID = ' . $wpdb->postmeta . '.post_id ) ';\r\n\t\t\t}\r\n\r\n\t\t\treturn $join;\r\n\t\t}", "title": "" }, { "docid": "688c01f50fcdfa3243642230caffdff7", "score": "0.49782658", "text": "public function joinAll()\n {\n $keys = $this->getPublicMembers();\n // ignore primary key.. lol!\n array_splice($keys, 0, 1);\n foreach ($keys as $key) {\n if (substr($key, -2) === \"ID\")\n $this->joinOn($key);\n }\n }", "title": "" }, { "docid": "b55648ad4c881afcdb699f4f39e2a0d4", "score": "0.49665028", "text": "public function join($sql, $condition = '') {\n if ($this->from == '') {\n return $this->from($sql);\n }\n if ($condition != '') {\n $sql = \"$sql on $condition\";\n }\n $this->from .= ($sql) ? \" inner join $sql \" : '';\n return $this;\n }", "title": "" }, { "docid": "b9d4e593909ae6faa0e38ec9246a2035", "score": "0.49524602", "text": "public function join($table, $params) {\n\t\t\tif($in_array($table, $this->has_one, true)) {\n\t\t\t\t$join_query = \"JOIN \" . $table . \" ON \" . $table . \".\" . $table .\"_id = \" . $this->table . \".\" . $table \"_id\";\n\t\t\t}\n\t\t\treturn $this;\n\t\t}", "title": "" }, { "docid": "29e9485e1c917984521a711bfad6e3c6", "score": "0.49488774", "text": "public function paginate($perPage = 15, $related = []);", "title": "" }, { "docid": "86a628269ebc8d30b60b60a1142cc65a", "score": "0.49335206", "text": "public function join($model, $condition = null, $alias = null, $type = null);", "title": "" }, { "docid": "469abe2d73a553920b58d8ca1a012ca8", "score": "0.49184564", "text": "private function getManyToManyRelatedData(ResultQueryInterface $parentEntityQuery, RelationMap $relation, array &$relatedData, RelatedData $relatedDataObject): SelectQueryInterface\n\t{\n\t\t$table = $relation->getRelationType()->getTable();\n\t\t$relatedTableName = $relation->getTableName();\n\n\t\t$parentIds = array_map(function($item) use ($relation) {\n\t\t\treturn $item[$relation->getParentIdentifier()];\n\t\t}, $parentEntityQuery->getResult());\n\n\t\t//find relation table rows\n\t\t/**\n\t\t * @var SelectQueryInterface $query\n\t\t */\n\t\t$query = $this->orm->createQuery();\n\n\t\t$relatedTableIdentifier = $relation->getRelationType()->getRelatedEntity()->getIdentifier();\n\n\t\t$on = sprintf(\n\t\t\t'ON %s.%s = %s.%s',\n\t\t\t$relatedTableName,\n\t\t\t$relatedTableIdentifier,\n\t\t\t$table,\n\t\t\t$relation->getRelationType()->getReferencedColumnName()\n\t\t);\n\t\t$where = sprintf(\n\t\t\t\"%s.%s IN (%s)\",\n\t\t\t$table,\n\t\t\t$relation->getRelationType()->getColumnName(),\n\t\t\timplode(',', $parentIds)\n\t\t);\n\n\t\t$select = sprintf($query->getConcatQuery('%s.%s', ',', 'ids') . ', %s.*',\n\t\t\t$table,\n\t\t\t$relation->getRelationType()->getColumnName(),\n\t\t\t$relatedTableName\n\t\t);\n\n\t\t$query\n\t\t\t->select($select)\n\t\t\t->from($table)\n\t\t\t->join(new Join('INNER', $relatedTableName, $on))\n\t\t\t->whereExpr($where)\n\t\t\t->groupBy($relation->getTableName() . '.' . $relatedTableIdentifier);\n\n\t\t$params = [];\n foreach ($relatedDataObject->getConditions() as $condition) {\n $field = $relatedTableName . '.' . $condition->getField();\n $generatedKey = AbstractQuery::generateParamName($field);\n $params[$generatedKey] = $condition->getValue();\n $query->whereExpr($field . $condition->getOperator() . ':' . $generatedKey);\n }\n\n\t\tif ($order = $relatedDataObject->getOrder()) {\n\t\t $query->orderBy($relation->getTableName() . '.' . $order->getField(), $order->getDirection());\n }\n if ($pagination = $relatedDataObject->getPagination()) {\n list($limit, $offset) = $pagination->getLimitOffset();\n\t\t $query->limit($limit, $offset);\n }\n\t\tif (!empty($parentIds)) {\n\t\t\t$query->execute($params);\n\t\t} else {\n\t\t\t$query->setResult([]);\n\t\t}\n\n\t\tforeach ($parentEntityQuery->getResult() as $parentResult) {\n\t\t\tforeach ($query->getResult() as $childResult) {\n\t\t\t\tif (in_array($parentResult[$relation->getParentIdentifier()], explode(',', $childResult['ids']))) {\n\t\t\t\t\t$relatedData[$relation->getEntityField()]['data'][$parentResult[$relation->getParentIdentifier()]][] = $childResult;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $query;\n\t}", "title": "" }, { "docid": "9743746b0742384de441876d17130aa5", "score": "0.48955527", "text": "public static function buildRelations(int $pageId, array &$relatedPages)\n {\n if(!isset($relatedPages[$pageId])) {\n $relatedPages[$pageId] = $pageId;\n\n /** @var QueryBuilder $queryBuilder */\n $queryBuilder = GeneralUtility::makeInstance(ConnectionPool::class)\n ->getQueryBuilderForTable('pages');\n $queryBuilder->getRestrictions()->removeAll()\n ->add(GeneralUtility::makeInstance(DeletedRestriction::class));\n $directRelations = $queryBuilder\n ->select('mm.*')\n ->from('tx_bgmhreflang_page_page_mm', 'mm')\n ->leftJoin('mm', 'pages', 'p', 'mm.uid_foreign = p.uid')\n ->where($queryBuilder->expr()->eq('mm.uid_local', (int)$pageId))\n ->execute()\n ->fetchAll();\n foreach ($directRelations as $directRelation) {\n if (!isset($relatedPages[$directRelation['uid_foreign']])) {\n self::buildRelations($directRelation['uid_foreign'], $relatedPages);\n }\n }\n\n /** @var QueryBuilder $queryBuilder2 */\n $queryBuilder2 = GeneralUtility::makeInstance(ConnectionPool::class)\n ->getQueryBuilderForTable('pages');\n $queryBuilder2->getRestrictions()->removeAll()\n ->add(GeneralUtility::makeInstance(DeletedRestriction::class));\n $indirectRelations = $queryBuilder2\n ->select('mm.*')\n ->from('tx_bgmhreflang_page_page_mm', 'mm')\n ->leftJoin('mm', 'pages', 'p', 'mm.uid_local = p.uid')\n ->where($queryBuilder2->expr()->eq('mm.uid_foreign', (int)$pageId))\n ->execute()\n ->fetchAll();\n foreach ($indirectRelations as $indirectRelation) {\n if (!isset($relatedPages[$indirectRelation['uid_local']])) {\n self::buildRelations($indirectRelation['uid_local'], $relatedPages);\n }\n }\n }\n }", "title": "" }, { "docid": "77718ade79146af8ae7107d384c2394a", "score": "0.48938224", "text": "private function applyRelationJoinToQuery($relationJoins): void\n {\n $filteredJoins = array_diff($relationJoins, $this->query->getAllAliases());\n\n // Add a left join to query which does not exist in the query\n if (!empty($filteredJoins)) {\n foreach ($filteredJoins as $property => $column) {\n $this->query->addSelect($column);\n $this->query->leftJoin($property, $column);\n }\n }\n }", "title": "" }, { "docid": "53b6c99d934ac0809b0c2ea4ebfadce8", "score": "0.48668593", "text": "protected function joinOn($column) {\n $join_clause = '';\n $column_alias = $this->getName().'.'.$column->getName();\n if ($column->is_foreign_key()) {\n $fk1_table = $column->get_referenced_table();\n $fk1_title_column = $fk1_table->get_title_column();\n $join_clause .= ' LEFT OUTER JOIN `' . $fk1_table->getName() . '` AS f' . $this->alias_count\n . ' ON (`'.$this->getName().'`.`'.$column->getName() . '` '\n . ' = `f'.$this->alias_count.'`.`'.$fk1_table->get_pk_column()->getName() . '`)';\n $column_alias = \"f$this->alias_count.\" . $fk1_title_column->getName();\n $this->joined_tables[] = $column_alias;\n // FK is also an FK?\n if ($fk1_title_column->is_foreign_key()) {\n $fk2_table = $fk1_title_column->get_referenced_table();\n $fk2_title_column = $fk2_table->get_title_column();\n $join_clause .= ' LEFT OUTER JOIN `' . $fk2_table->getName() . '` AS ff' . $this->alias_count\n . ' ON (f'.$this->alias_count.'.`'.$fk1_title_column->getName() . '` '\n . ' = ff'.$this->alias_count.'.`'.$fk1_table->get_pk_column()->getName() . '`)';\n $column_alias = \"ff$this->alias_count.\" . $fk2_title_column->getName();\n $this->joined_tables[] = $column_alias;\n }\n $this->alias_count++;\n }\n return array('join_clause'=>$join_clause, 'column_alias'=>$column_alias);\n }", "title": "" }, { "docid": "8e7cf839870deb8d62119dde7b8a2669", "score": "0.48510075", "text": "public function getRelated(One_Relation_Adapter $link, One_Model $model, array $options = array());", "title": "" }, { "docid": "28a9d0bd4b0e59a87ffdf81501e12549", "score": "0.48484322", "text": "public function joinPageTypeCustom($relationAlias = null, $joinType = Criteria::INNER_JOIN)\n {\n $tableMap = $this->getTableMap();\n $relationMap = $tableMap->getRelation('PageTypeCustom');\n\n // create a ModelJoin object for this join\n $join = new ModelJoin();\n $join->setJoinType($joinType);\n $join->setRelationMap($relationMap, $this->useAliasInSQL ? $this->getModelAlias() : null, $relationAlias);\n if ($previousJoin = $this->getPreviousJoin()) {\n $join->setPreviousJoin($previousJoin);\n }\n\n // add the ModelJoin to the current object\n if ($relationAlias) {\n $this->addAlias($relationAlias, $relationMap->getRightTable()->getName());\n $this->addJoinObject($join, $relationAlias);\n } else {\n $this->addJoinObject($join, 'PageTypeCustom');\n }\n\n return $this;\n }", "title": "" }, { "docid": "7bb5632ca255ef2b3c64e2847235076d", "score": "0.48334402", "text": "public function join($condition) {\n\t\tlist($key, $value) = each($condition);\n\t\t$this->sql .= \" INNER JOIN \".$this->joinTable.\" ON \".$this->tableAliases[$this->selectTable].\".\".$key.\" = \".$this->tableAliases[$this->joinTable].\".\".$value;\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "0a33f78a889ff745a17a6b1de81515c7", "score": "0.48300695", "text": "public function joinAcademicClass(&$q, $from_table, $from_table_foreign_key, $filter_period_id = null) {\n\t\t$q->join($from_table, \"AcademicClass\", array($from_table_foreign_key=>\"id\"));\n\t\tif ($filter_period_id <> null)\n\t\t\t$q->whereValue(\"AcademicClass\", \"period\", $filter_period_id);\n\t}", "title": "" }, { "docid": "09d08ec322b10fc7e2051b0636a482cd", "score": "0.48169768", "text": "protected function performJoin($query = null)\n {\n $query = $query ?: $this->query;\n\n // We need to join to the intermediate table on the related model's primary\n // key column with the intermediate table's foreign key for the related\n // model instance. Then we can set the \"where\" for the parent models.\n $baseTable = $this->related->getTable();\n\n $key = $baseTable.'.'.$this->relatedKey;\n\n $query->join($this->table, $key, '=', $this->getQualifiedRelatedPivotKeyName());\n\n return $this;\n }", "title": "" }, { "docid": "c303007a12e3acb3b7c2b67d54a315d4", "score": "0.48029354", "text": "protected function _hasJoin_sql($key, $table, $cond, &$filter, &$options) {\n $relConf = $this->fieldConf[$key]['belongs-to-one'];\n $relModel = is_array($relConf)?$relConf[0]:$relConf;\n $rel = $this->getRelInstance($relModel,null,$key);\n $fkey = is_array($this->fieldConf[$key]['belongs-to-one']) ?\n $this->fieldConf[$key]['belongs-to-one'][1] : $rel->primary;\n $alias = $table.'__'.$key;\n $query = $this->_sql_left_join($key,$this->table,$fkey,[$table,$alias]);\n $this->_sql_mergeRelCondition($cond,$alias,$filter,$options);\n return $query;\n }", "title": "" }, { "docid": "efd37a2587b17a6f52d86dedbf78ae7d", "score": "0.47869194", "text": "protected function _buildJoinQuery() {\r\n\t\treturn $this->_meta['join'] ? implode(' ', $this->_meta['join']) . ' ' : '';\r\n\t}", "title": "" }, { "docid": "3fad231f4cf30f53f267075a3a0aa533", "score": "0.47825995", "text": "public static function join($otherTable,$mainTableField, $otherTableField){\n\n self::$_table = self::$_table . \" JOIN $otherTable ON \" . self::$_table . \".$mainTableField = $otherTable.$otherTableField\";\n\n return new static;\n\n }", "title": "" }, { "docid": "c7987623fb3837429e613940a2e37347", "score": "0.47811857", "text": "public function setJoin($value)\n\t{\n\t\t$this->_query['join']=$value;\n\t}", "title": "" }, { "docid": "74302603845536872861fdd0573e458f", "score": "0.4772052", "text": "public function filter_act_join($join)\n {\n global $wpdb;\n\n $join .= \" LEFT JOIN `{$wpdb->prefix}\" . self::TABLE_NAME . \"` `act` ON `act`.`act_external_id`=`{$wpdb->posts}`.`id` \";\n\n return ($join);\n }", "title": "" }, { "docid": "350e6e4dec9e39b57a28ff2370a413fa", "score": "0.47666353", "text": "function get_tagsByCategory($category_id){\n $query = selectJoin(TAB_TAG_CAT, TAB_TAGS, \"tag = id\", \"category = $category_id\");\n return $query;\n}", "title": "" }, { "docid": "3773058d44594108d3d1d4f8dda6d100", "score": "0.4758315", "text": "public function joinAll($table);", "title": "" }, { "docid": "964e5490fc578edfcec366ed0bef5d2a", "score": "0.47514018", "text": "private function applyJoins()\n {\n if (isset($this->joins[0])) {\n $this->applyJoin($this->queryBuilder, $this, $this->joins[0]);\n }\n }", "title": "" }, { "docid": "0748578e1224b7e147c85f532d449f6e", "score": "0.47502637", "text": "public function join($join, $wp_query)\r\n {\r\n if(is_string($wp_query->query_vars['post_type']) and $wp_query->query_vars['post_type'] == $this->main->get_main_post_type() and $wp_query->get('mec-init', false))\r\n {\r\n $join .= $this->db->_prefix(\" LEFT JOIN `#__mec_events` AS mece ON #__posts.ID = mece.post_id LEFT JOIN `#__mec_dates` AS mecd ON #__posts.ID = mecd.post_id\");\r\n }\r\n\r\n return $join;\r\n }", "title": "" }, { "docid": "9afb1da59bbd4df2046be57ead90e4ba", "score": "0.47488004", "text": "public function joinForTableProxy( Doctrine_Query $q, array $options = array() )\r\n {\r\n\r\n $options = Doctrine_Lib::arrayDeepMerge( $this->_options, $options );\r\n $q->getRootAlias(); // fix for initialize root\r\n\r\n if( empty( $options['parentTable'] ) )\r\n {\r\n $parentTable = $q->getRoot();\r\n $parentTableAlias = $q->getRootAlias();\r\n }\r\n else\r\n {\r\n $parentTable = Doctrine::getTable( $options['parentTable'] );\r\n $parentTableAlias = empty( $options['parentTableAlias'] ) ? $q->getSqlTableAlias( sfInflector::tableize( $options['parentTable'] ) ) : $options['parentTableAlias'] ;\r\n }\r\n\r\n if( !empty( $options['componentAlias'] ) )\r\n {\r\n $componentAlias = $options['componentAlias'];\r\n }\r\n elseif( $parentTable->hasRelation( $this->_table->getComponentName() ) )\r\n {\r\n $componentAlias = $this->_table->getComponentName();\r\n }\r\n else\r\n {\r\n $componentName = $this->_table->getComponentName();\r\n $relations = $parentTable->getRelations();\r\n\r\n foreach( $relations as $relation )\r\n {\r\n if( $relation['class'] == $componentName )\r\n {\r\n $componentAlias = $relation['alias'];\r\n break;\r\n }\r\n }\r\n }\r\n\r\n $tableAlias = empty( $options['tableAlias'] ) ? $this->_table->getAlias() : $options['tableAlias'];\r\n $q->addSqlTableAlias( $tableAlias, sfInflector::tableize( $this->_table->getComponentName() ) );\r\n\r\n $q->leftJoin( $parentTableAlias . '.' . $componentAlias . ' ' . $tableAlias );\r\n if($options['withI18n'] == true && $this->_table->hasTemplate( 'Doctrine_Template_I18nMod' )) // no need to join non exist translations\r\n {\r\n $cultures = empty( $options['cultures'] ) ? sfContext::getInstance()->getUser()->getCulture() : $options['cultures'];\r\n $chunkWith = implode( ' AND ', array_fill( 0, count( $cultures ), ' ' . $tableAlias . '_trans.lang = ? ' ) );\r\n $q->leftJoin($tableAlias . '.Translation ' . $tableAlias . '_trans WITH ' . $chunkWith, $cultures );\r\n }\r\n\r\n return $q;\r\n\r\n }", "title": "" }, { "docid": "a7091b39bc4af5f2528c5773989bbe9a", "score": "0.47453266", "text": "public function relate($linkName,$related_id){\n return $this->link($linkName,$related_id);\n }", "title": "" }, { "docid": "6f2ad9dcdd35bab6743bcfee4ee4284e", "score": "0.4735918", "text": "protected function performJoin($query = null)\n {\n $query = $query ?: $this->query;\n\n parent::performJoin($query);\n\n // We need to join to the intermediate table on the related model's primary\n // key column with the intermediate table's foreign key for the related\n // model instance. Then we can set the \"where\" for the parent models.\n $intermediateTable = $this->intermediateRelation->getTable();\n\n $key = $this->intermediateRelation->getQualifiedRelatedKeyName();\n\n $query->join($intermediateTable, $key, '=', $this->getQualifiedForeignKeyName());\n\n return $this;\n }", "title": "" }, { "docid": "d70d13d2cd5ad7891e1dae010a7df0b4", "score": "0.47228384", "text": "public function getDisplayAllInnerJoin($main_table_name, $fields, $join , $limit_from, $total_row_display, $sort, $order, $where = null) {\n\n\n\n if(is_array($fields )) {\n\n\n\n $select_fields = implode($fields,', ');\n\n }\n\n\n\n $join_str = \"\";\n\n\n\n foreach($join as $inner_array) {\n\n //$join_str .= ' INNER JOIN '.implode($inner_array, ' ON ');\n\n $join_str .= ' INNER JOIN '.$inner_array[0].' ON '.$inner_array[1];\n\n if(count($inner_array) > 2) {\n\n for($i=2;$i<count($inner_array);$i++) {\n\n $join_str .= ' AND '.$inner_array[$i];\n\n }\n\n }\n\n }\n\n\n\n $sql = \"SELECT \".$select_fields.\" FROM \".$main_table_name.\" \".$join_str.\" \".$where.\" ORDER BY \".$sort.\" \". $order.\" LIMIT \".$limit_from.\", \".$total_row_display;\n\n $sql_run = mysql_query($sql);\n\n\n\n $i=0;\n\n $arrayData = array ();\n\n\n\n while($row=mysql_fetch_array($sql_run)) {\n\n\n\n $arrayData[$i] = $row;\n\n\n\n $i++;\n\n }\n\n return $arrayData;\n\n }", "title": "" }, { "docid": "c8874965b0e6ea55f2572b6af71fd945", "score": "0.47187153", "text": "private function getOneToManyRelatedData(ResultQueryInterface $parentEntityQuery, RelationMap $relation, array &$relatedData, RelatedData $relatedDataObject): SelectQueryInterface\n\t{\n\t\t$table = $relation->getRelationType()->getRelatedEntity()->getTable();\n\n\t\t/**\n\t\t * @var SelectQuery $query\n\t\t */\n\t\t$query = $this->orm->createQuery();\n\n\t\t$parentIds = $this->makeInArgument($parentEntityQuery->getResult(), $relation->getParentIdentifier());\n\n\t\t$query\n\t\t\t->from($table)\n\t\t\t->whereExpr(sprintf(\n\t\t\t\t\"%s IN (%s)\",\n\t\t\t\t\t$relation->getRelationType()->getRelatedTableField(),\n\t\t\t\t$parentIds\n\t\t\t))\n\t\t;\n\n\t\t$params = [];\n\n\t\tforeach ($relatedDataObject->getConditions() as $condition) {\n\t\t $generatedKey = AbstractQuery::generateParamName($condition->getField());\n\t\t $params[$generatedKey] = $condition->getValue();\n\t\t $query->whereExpr($condition->getField() . $condition->getOperator() . ':' . $generatedKey);\n }\n\n if ($order = $relatedDataObject->getOrder()) {\n\t\t $query->orderBy($order->getField(), $order->getDirection());\n }\n\n if ($pagination = $relatedDataObject->getPagination()) {\n\t\t list($limit, $offset) = $relatedDataObject->getPagination()->getLimitOffset();\n\t\t $query->limit($limit, $offset);\n }\n\n\t\tif (!empty($parentIds)) {\n\t\t\t$query->execute($params);\n\t\t} else {\n\t\t\t$query->setResult([]);\n\t\t}\n\n\t\tforeach($query->getResult() as $relationData) {\n\t\t\t$relatedData[$relation->getEntityField()]['data'][$relationData[$relation->getRelationType()->getRelatedTableField()]][] =\n\t\t\t\t$relationData;\n\t\t}\n\n\t\treturn $query;\n\t}", "title": "" }, { "docid": "f2811821489a33875d6beba1e2de0966", "score": "0.47142777", "text": "protected function GetFilterQueryCustomJoins()\n {\n $sJoin = parent::GetFilterQueryCustomJoins();\n if ($this->IsCustomSort()) {\n $databaseConnection = $this->getDatabaseConnection();\n $quotedMltTableName = $databaseConnection->quoteIdentifier($this->GetMLTTableName());\n $quotedTableName = $databaseConnection->quoteIdentifier($this->oTableConf->sqlData['name']);\n\n $sJoin .= \" INNER JOIN $quotedMltTableName ON $quotedMltTableName.`target_id` = $quotedTableName.`id` \";\n }\n\n return $sJoin;\n }", "title": "" }, { "docid": "38466cedf52da7caff2f9171a0fdb2e5", "score": "0.47134072", "text": "public static function join(string $relationTable, string $baseId, string $sign = \"=\", string $relationId): self\n {\n $resolve = self::innerJoinResolver($relationTable, $baseId, $sign, $relationId);\n\n self::$join .= $resolve;\n\n return new self;\n }", "title": "" }, { "docid": "5decfa7d26cb2038312eefd1a8b788da", "score": "0.47108382", "text": "private function manyToManyQuery(Association $association, string $id): QueryInterface\n {\n /**\n * @var string $tableName\n */\n $tableName = $association->getTarget()->getTable();\n $table = TableRegistry::getTableLocator()->get(Inflector::camelize($tableName));\n\n // pagination hack to modify alias\n $association->setTarget($association->getTarget());\n $association->getTarget()->setAlias($this->_controller()->getName());\n\n $related = $this->getManyToManyAssociation($association->getTarget(), $association->getName());\n if (is_null($related)) {\n throw new InvalidArgumentException(sprintf(\n '%s is not associated with %s',\n App::shortName(get_class($association->getTarget()), 'Model/Table', 'Table'),\n $this->_table()->getAlias()\n ));\n }\n\n $query = $association->find('all')->innerJoinWith($related->getName(), function ($q) use ($related, $id) {\n /** @var string $primaryKey */\n $primaryKey = $this->_table()->getPrimaryKey();\n\n return $q->where([$related->getTarget()->aliasField($primaryKey) => $id]);\n });\n\n return $query;\n }", "title": "" }, { "docid": "35ebcc3ca86b14d0f5c6e203b4237e9c", "score": "0.47010532", "text": "function SelectDataInnerJoinObjectFormat($table1, $table2, $table1_id_field, $table2_id_field, $short_table1, $short_field1, $short_term, $start, $howmanyrow)\n\n {\n $query_string = \"SELECT * FROM \" ;\n if(isset($table1))\n {\n $query_string .= $table1 ; \n }\n $query_string .= \" JOIN \" ;\n if(isset($table2))\n {\n $query_string .= $table2 ; \n }\n $query_string .= \" ON \" ;\n if(isset($table1_id_field) && isset($table1))\n {\n $query_string .= $table1 . \".\" . $table1_id_field ;\n }\n $query_string .= \" = \" ;\n if(isset($table2_id_field) && isset($table2))\n {\n $query_string .= $table2 . \".\" . $table2_id_field ;\n }\n if($short_table1 != \"\" && $short_field1 != \"\") \n {\n $query_string .= \" ORDER BY \" . $short_table1 . \".\" . $short_field1 ;\n }\n if($short_term != \"\")\n {\n $query_string .= \" \" . $short_term ;\n }\n if($start != \"\" && $howmanyrow != \"\")\n {\n $query_string .= \" LIMIT \" . $start . \",\" . $howmanyrow ;\n }\n\n $query = $this->db->query($query_string) ;\n return $query->result() ;\n }", "title": "" }, { "docid": "5694902305740d035a0745ad2f937b23", "score": "0.46984205", "text": "protected function _joinFields()\n {\n $commentTable = Mage::getSingleton('core/resource')\n ->getTableName('xcentia_vendors/vendor_comment');\n $this->getSelect()->join(\n array('ct' => $commentTable),\n 'ct.vendor_id = main_table.entity_id',\n array(\n 'ct_title' => 'title',\n 'ct_comment_id' => 'comment_id',\n 'ct_name' => 'name',\n 'ct_status' => 'status',\n 'ct_email' => 'email',\n 'ct_created_at' => 'created_at',\n 'ct_updated_at' => 'updated_at'\n )\n );\n return $this;\n }", "title": "" }, { "docid": "73a98928b3f4967284e8f1f44fe8e05b", "score": "0.46954894", "text": "protected function _setJoins() {\n\t\tif(!empty($this->filter['CoursesTadirahObject.tadirah_object_id'])) {\n\t\t\t$subquery = $this->Course->find('all', array(\n\t\t\t\t'joins' => array(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'alias' => 'CoursesTadirahObject',\n\t\t\t\t\t\t'table' => 'courses_tadirah_objects',\n\t\t\t\t\t\t'type' => 'INNER',\n\t\t\t\t\t\t'conditions' => 'CoursesTadirahObject.course_id = Course.id'\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'conditions' => array(\n\t\t\t\t\t'CoursesTadirahObject.tadirah_object_id' => $this->filter['CoursesTadirahObject.tadirah_object_id']\n\t\t\t\t),\n\t\t\t\t'fields' => array('DISTINCT (CoursesTadirahObject.course_id) AS ids_filtered'),\n\t\t\t\t'contain' => array('CoursesTadirahObject')\n\t\t\t));\n\t\t\t$this->filter['Course.id'] = Set::extract('/CoursesTadirahObject/ids_filtered', $subquery);\n\t\t\tunset($this->filter['CoursesTadirahObject.tadirah_object_id']);\n\t\t}\n\t\tif(!empty($this->filter['CoursesTadirahTechnique.tadirah_technique_id'])) {\n\t\t\t$subquery = $this->Course->find('all', array(\n\t\t\t\t'joins' => array(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'alias' => 'CoursesTadirahTechnique',\n\t\t\t\t\t\t'table' => 'courses_tadirah_techniques',\n\t\t\t\t\t\t'type' => 'INNER',\n\t\t\t\t\t\t'conditions' => 'CoursesTadirahTechnique.course_id = Course.id'\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'conditions' => array(\n\t\t\t\t\t'CoursesTadirahTechnique.tadirah_technique_id' => $this->filter['CoursesTadirahTechnique.tadirah_technique_id']\n\t\t\t\t),\n\t\t\t\t'fields' => array('DISTINCT (CoursesTadirahTechnique.course_id) AS ids_filtered'),\n\t\t\t\t'contain' => array('CoursesTadirahTechnique')\n\t\t\t));\n\t\t\t$this->filter['Course.id'] = Set::extract('/CoursesTadirahTechnique/ids_filtered', $subquery);\n\t\t\tunset($this->filter['CoursesTadirahTechnique.tadirah_technique_id']);\n\t\t}\n\t\tif(!empty($this->filter['CoursesTadirahActivity.tadirah_activity_id'])) {\n\t\t\t$subquery = $this->Course->find('all', array(\n\t\t\t\t'joins' => array(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'alias' => 'CoursesTadirahActivity',\n\t\t\t\t\t\t'table' => 'courses_tadirah_activities',\n\t\t\t\t\t\t'type' => 'INNER',\n\t\t\t\t\t\t'conditions' => 'CoursesTadirahActivity.course_id = Course.id'\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'conditions' => array(\n\t\t\t\t\t'CoursesTadirahActivity.tadirah_activity_id' => $this->filter['CoursesTadirahActivity.tadirah_activity_id']\n\t\t\t\t),\n\t\t\t\t'fields' => array('DISTINCT (CoursesTadirahActivity.course_id) AS ids_filtered'),\n\t\t\t\t'contain' => array('CoursesTadirahActivity')\n\t\t\t));\n\t\t\t$this->filter['Course.id'] = Set::extract('/CoursesTadirahActivity/ids_filtered', $subquery);\n\t\t\tunset($this->filter['CoursesTadirahActivity.tadirah_activity_id']);\n\t\t}\n\t\tif(!empty($this->filter['CoursesNwoDiscipline.nwo_discipline_id'])) {\n\t\t\t$subquery = $this->Course->find('all', array(\n\t\t\t\t'joins' => array(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'alias' => 'CoursesNwoDiscipline',\n\t\t\t\t\t\t'table' => 'courses_nwo_disciplines',\n\t\t\t\t\t\t'type' => 'INNER',\n\t\t\t\t\t\t'conditions' => 'CoursesNwoDiscipline.course_id = Course.id'\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'conditions' => array(\n\t\t\t\t\t'CoursesNwoDiscipline.nwo_discipline_id' => $this->filter['CoursesNwoDiscipline.nwo_discipline_id']\n\t\t\t\t),\n\t\t\t\t'fields' => array('DISTINCT (CoursesNwoDiscipline.course_id) AS ids_filtered'),\n\t\t\t\t'contain' => array('CoursesNwoDiscipline')\n\t\t\t));\n\t\t\t$this->filter['Course.id'] = Set::extract('/CoursesNwoDiscipline/ids_filtered', $subquery);\n\t\t\tunset($this->filter['CoursesNwoDiscipline.nwo_discipline_id']);\n\t\t}\n\t}", "title": "" }, { "docid": "4b00a107eedcd204551024834cdd58c3", "score": "0.46911404", "text": "protected function joinSellerRelationTable($tableName, $columnName)\n {\n $this->getSelect()->join(\n [$tableName => $this->getTable($tableName)],\n 'main_table.' . $columnName . ' = '.$tableName.'.' . $columnName,\n []\n )->group(\n 'main_table.' . $columnName\n );\n }", "title": "" }, { "docid": "5e34e5df3ead9cfe3333ea8142520527", "score": "0.46842572", "text": "public function qbRelationAction()\n {\n $qb = $this->get('doctrine')->getRepository('espendDoctrineRelationBundle:Relation')->createQueryBuilder('relation');\n\n $qb->join('relation.many_to_one_ns', 'manyToOneNs');\n $qb->addSelect('manyToOneNs.field_1', 'relation');\n\n $qb->addSelect('relation', 'manyToOneNs', '');\n $qb->addGroupBy('relation', 'relation');\n $qb->andWhere($qb->expr()->eq('relation.foo', '1'));\n $qb->andWhere($qb->expr()->eq('relation.many_to_many', '1'));\n\n $qb->andWhere('relation.id => ');\n\n\n $qb1 = $this->get('doctrine')->getRepository('espendDoctrineRelationBundle:Relation')->createQueryBuilder('relation');\n $qb1->from('espendDoctrineMongoDbBundle:MongoYaml', 'mongoYaml', 'relation.id');\n }", "title": "" }, { "docid": "4b8e97ef54012bb47b747b4f52dc5b80", "score": "0.46819404", "text": "public function get_sql_join() {\n return array();\n }", "title": "" }, { "docid": "2e52e4fc40ccc387890ab4b7fdefe2ec", "score": "0.46819142", "text": "private function addJoinedResources(xPDOQuery $c) {\r\n\t\tif (!empty($this->queryHook['joined'])) {\r\n $pattern = '{core_path}';\r\n $replacement = $this->modx->getOption('core_path',null,MODX_CORE_PATH);\r\n\t\t\t$joineds = $this->queryHook['joined'];\r\n\t\t\tforeach($joineds as $joined) {\r\n\t\t\t\tif (!empty($joined['joinCriteria'])) {\r\n\t\t\t\t\t$joinedClass = $joined['class'];\r\n\t\t\t\t\t// add package\r\n\t\t\t\t\t$joined['packagePath'] = str_replace($pattern, $replacement, $joined['packagePath']);\r\n\t\t\t\t\t$this->modx->addPackage($joined['package'],$joined['packagePath']);\r\n\t\t\t\t\t// initialize and add joined displayed fields\r\n\t\t\t\t\tif (!empty($joined['withFields'])) {\r\n\t\t\t\t\t\t$joinedWhereFields = array_map('trim',explode(',',$joined['withFields'])); \t\t\t// fields of joined table where to do the search\r\n\t\t\t\t\t\tif (!empty($joined['fields'])) $joinedFields = array_map('trim',explode(',',$joined['fields'])); \t\t\t// fields of joined table to display\r\n\t\t\t\t\t\telse $joinedFields = $joinedWhereFields;\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse {\r\n\t\t\t\t\t\tif (!empty($joined['fields'])) {\r\n\t\t\t\t\t\t\t$joinedFields = array_map('trim',explode(',',$joined['fields']));\r\n\t\t\t\t\t\t\t$joinedWhereFields = $joinedFields;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tforeach($joinedWhereFields as & $joinedWhereField) $joinedWhereField = $this->modx->escape($joinedClass) . '.' . $this->modx->escape($joinedWhereField);\r\n\t\t\t\t\t$this->joinedWhereFields = array_merge($this->joinedWhereFields, $joinedWhereFields);\r\n\t\t\t\t\t// add joined fields\r\n\t\t\t\t\t$c->select($this->modx->getSelectColumns($joinedClass,$joinedClass,\"{$joinedClass}_\",$joinedFields));\r\n\t\t\t\t\tforeach($joinedFields as & $joinedField) $joinedField = \"{$joinedClass}_{$joinedField}\"; // all the fields of joined class are prefixed by classname_\r\n\t\t\t\t\t$this->joinedFields = array_merge($this->joinedFields, $joinedFields);\r\n\t\t\t\t\t// add left join\r\n\t\t\t\t\tlist($leftCriteria,$rightCriteria) = array_map('trim',explode('=',$joined['joinCriteria']));\r\n\t\t\t\t\t$leftCriteriaElts = array_map('trim',explode('.',$leftCriteria));\r\n\t\t\t\t\t$leftCriteria = (count($leftCriteriaElts) == 1) ? \"`{$joinedClass}`.`{$leftCriteriaElts[0]}`\" : \"`{$leftCriteriaElts[0]}`.`{$leftCriteriaElts[1]}`\";\r\n\t\t\t\t\t$rightCriteriaElts = array_map('trim',explode('.',$rightCriteria));\r\n\t\t\t\t\t$rightCriteria = (count($rightCriteriaElts) == 1) ? \"`{$joinedClass}`.`{$rightCriteriaElts[0]}`\" : \"`{$rightCriteriaElts[0]}`.`{$rightCriteriaElts[1]}`\";\r\n\t\t\t\t\t$joined['joinCriteria'] = \"{$leftCriteria} = {$rightCriteria}\";\r\n\t\t\t\t\t$c->leftJoin($joinedClass,$joinedClass,$joined['joinCriteria']);\r\n\t\t\t\t\t// restrict search with a where condition on joined resource\r\n\t\t\t\t\tif (!empty($joined['where'])) {\r\n\t\t\t\t\t\tif (!is_array($joined['where'])) $c->andCondition(array($joined['where']));\r\n\t\t\t\t\t\telse $c->andCondition($joined['where']);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n return $c;\r\n }", "title": "" }, { "docid": "c896da9770062f044313712174c22cd8", "score": "0.4680142", "text": "function join(&$q_obj, $name, $parent, $columns = false, $type = 'left')\n\t{\n\t\t// fetch the columns if they are not already specified\n\t\tempty($columns) AND $columns = IR_base::list_fields($this->get_table());\n\t\t\n\t\t// get the id column for the related object\n\t\tif($model =& IR_base::get_model($this->get_table()))\n\t\t{\n\t\t\t$col = $model->id_col;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$col = 'id';\n\t\t}\n\t\t\n\t\t// alias the columns\n\t\t$select = array();\n\t\tforeach((Array)$columns as $field)\n\t\t{\n\t\t\t$select[] = $this->name.'.'.$field.' AS '.$name.'_'.$field;\n\t\t}\n\t\t\n\t\t// add the data to the query\n\t\t$q_obj->select($select);\n\t\t$q_obj->join($this->_get_aliased_table(), $parent->table.'.'.$this->get_fk().\n\t\t\t\t\t ' = '.$this->name.'.'.$col, $type);\n\t}", "title": "" }, { "docid": "47e018cef72e9d6090eb484ed2a8bd75", "score": "0.4672141", "text": "public function join($table, $condition)\n\t{\n\t\t\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "6c0b1255759d0292f0841d3f31fd2eef", "score": "0.4660107", "text": "public function newPivotStatementForId($id)\n {\n return $this->newPivotQuery()->whereIn($this->relatedPivotKey, $this->parseIds($id));\n }", "title": "" }, { "docid": "ac1a9905b7dfa86432f3a0b2cb298ea9", "score": "0.4653761", "text": "public function with($relation, &$alias = null) {\n\n $from_class = $this->unaliasClass($this->from_alias);\n $relation_data = $from_class::_getRelation($relation);\n\n\n //if it's many to many, load the related class and flag the first join to be attached as relation data\n if($relation_data['relation_type'] === Wave\\DB\\Relation::MANY_TO_MANY) {\n\n $this->leftJoin($relation_data['related_class'], $related_alias, $target_alias);\n\n //more iteration for multi-column relations\n foreach($relation_data['related_columns'] as $index => $related_column) {\n $func = $index === 0 ? 'on' : 'and';\n $this->$func(\n sprintf(\n '%s.%s = %s.%s', $related_alias, $this->escape($related_column),\n $this->from_alias, $this->escape($relation_data['local_columns'][$index])\n )\n );\n }\n\n $this->leftJoin($relation_data['target_relation']['related_class'], $alias);\n\n foreach($relation_data['target_relation']['related_columns'] as $index => $related_column) {\n $func = $index === 0 ? 'on' : 'and';\n $this->$func(\n sprintf(\n '%s.%s = %s.%s', $alias, $this->escape($related_column),\n $related_alias, $this->escape($relation_data['target_relation']['local_columns'][$index])\n )\n );\n }\n\n //go back and set the target alias to the joined row\n $target_alias = $alias;\n\n } else {\n //any other type of join is a simple table-table join\n $this->leftJoin($relation_data['related_class'], $alias);\n\n //more iteration for multi-column relations\n foreach($relation_data['related_columns'] as $index => $related_column) {\n $func = $index === 0 ? 'on' : 'and';\n $this->$func(\n sprintf(\n '%s.%s = %s.%s', $alias, $this->escape($related_column),\n $this->from_alias, $this->escape($relation_data['local_columns'][$index])\n )\n );\n }\n\n }\n\n //this needs recording so the object can be added as a relation, not a join\n $this->with[$alias] = array(\n 'relation_type' => $relation_data['relation_type'],\n 'relation_name' => Wave\\Inflector::singularize($relation)\n );\n\n return $this;\n\n }", "title": "" }, { "docid": "d8001e95130ce8d5ecd3599178291592", "score": "0.4652235", "text": "public function joinModel($params){\t\n\t\t\t\n\t\t$joinModel = GO::getModel($params['model']);\n\n\t\tif(!isset($params['foreignField']))\n\t\t\t$params['foreignField']=$joinModel->primaryKey();\n\n\t\tif(!isset($params['localField']))\n\t\t\t$params['localField']=\"id\";\n\t\t\n\t\tif(!isset($params['localTableAlias']))\n\t\t\t$params['localTableAlias']=\"t\";\n\n\t\tif(!isset($params['type']))\n\t\t\t$params['type']='INNER';\n\n\t\tif(!isset($params['tableAlias']))\n\t\t\t$params['tableAlias']=false;\n\n\t\tif(!isset($params['criteria'])){\n\t\t\t$params['criteria'] = new FindCriteria();\n\t\t}\t\t\t\t\n\t\t\n\t\t$table = $params['tableAlias'] ? $params['tableAlias'] : $joinModel->tableName();\n\n\t\t$params['criteria']->addRawCondition(\"`\".$table.\"`.`\".$params['foreignField'].\"`\", \"`\".$params['localTableAlias'].\"`.`\".$params['localField'].\"`\");\n\n\t\treturn $this->join($joinModel->tableName(), $params['criteria'], $params['tableAlias'],$params['type']);\n\t}", "title": "" }, { "docid": "9cefa1b85acaaae3a40c4d2e5b6d7381", "score": "0.46402934", "text": "public function joinBatch(&$q, $from_table, $from_table_foreign_key) {\n\t\t$q->join($from_table, \"StudentBatch\", array($from_table_foreign_key=>\"id\"));\n\t}", "title": "" }, { "docid": "31b28749c7fc348964ee0bdc20444e27", "score": "0.46318582", "text": "protected function setJoin(Builder $query = null)\n {\n $query = $query ?: $this->query;\n\n $foreignKey = $this->related->getTable() . '.' . $this->related->getKeyName();\n $localKey = $this->parent->getTable() . '.' . $this->secondKey;\n\n $query->join($this->parent->getTable(), $foreignKey, '=', $localKey);\n\n if ($this->parentSoftDeletes()) {\n\n $query->whereNull($this->parent->getQualifiedDeletedAtColumn());\n }\n }", "title": "" }, { "docid": "39fba555588dde007da9dcdbcceab178", "score": "0.46280658", "text": "public function join($table, $cond, $type = '')\n {\n \t// prevents conflicts when joining tables\n \t$this->select(\"{$this->table}.*\");\n \t$this->db->join($table,$cond,$type);\n }", "title": "" }, { "docid": "d339d543f0836715f227c098d335b4be", "score": "0.4621337", "text": "private function _get_join() {\n return self::_get_inner_join() . self::_get_left_join();\n }", "title": "" }, { "docid": "86176bcfd5159f062afc8546ebcc1ba5", "score": "0.46209866", "text": "function _relatedAll() {\n\t\t$o=new FPDB_Query(array('start'=>0, 'count'=>-1, 'fullparse'=>false), null);\n\t\twhile($o->hasMore()) {\n\t\t\tlist($id, $entry)=$o->getEntry();\n\t\t\t$this->getRelation($id);\n\t\t}\n\t}", "title": "" }, { "docid": "d3aeef9614383d0bbed1c7159b4222e7", "score": "0.4620457", "text": "public function joinWhere($table, $first, $operator, $second, $type = 'inner');", "title": "" }, { "docid": "0756c8320f1983a5d5d56ffcca187554", "score": "0.46141583", "text": "public function useAlquilerQuery($relationAlias = null, $joinType = Criteria::INNER_JOIN)\n\t{\n\t\treturn $this\n\t\t\t->joinAlquiler($relationAlias, $joinType)\n\t\t\t->useQuery($relationAlias ? $relationAlias : 'Alquiler', 'AlquilerQuery');\n\t}", "title": "" }, { "docid": "75e4b69b127f47f5ff4ee9d261dd0684", "score": "0.4614056", "text": "public function get_extra_joins() {\n return array();\n }", "title": "" }, { "docid": "5f3caacf42210faf1a5f5fd2153f83ff", "score": "0.46123058", "text": "public function newPivotStatementForId($id)\n {\n return $this->newPivotQuery()->where($this->relatedPivotKey, $id);\n }", "title": "" }, { "docid": "36e30f17902947ee301019e4f4642ffb", "score": "0.45975718", "text": "public function joinRelationships($option)\n {\n $query = $this->model\n ->leftJoin('relationships', 'users.id', '=', $option);\n\n $this->model = $query;\n return $this;\n }", "title": "" }, { "docid": "d13dcf77ed3666d54dde72c3cb28b715", "score": "0.4595727", "text": "public function testJoins()\n {\n $dq = new DataQuery(Member::class);\n $dq->innerJoin(\"Group_Members\", \"\\\"Group_Members\\\".\\\"MemberID\\\" = \\\"Member\\\".\\\"ID\\\"\");\n $this->assertSQLContains(\n \"INNER JOIN \\\"Group_Members\\\" ON \\\"Group_Members\\\".\\\"MemberID\\\" = \\\"Member\\\".\\\"ID\\\"\",\n $dq->sql($parameters)\n );\n\n $dq = new DataQuery(Member::class);\n $dq->leftJoin(\"Group_Members\", \"\\\"Group_Members\\\".\\\"MemberID\\\" = \\\"Member\\\".\\\"ID\\\"\");\n $this->assertSQLContains(\n \"LEFT JOIN \\\"Group_Members\\\" ON \\\"Group_Members\\\".\\\"MemberID\\\" = \\\"Member\\\".\\\"ID\\\"\",\n $dq->sql($parameters)\n );\n }", "title": "" }, { "docid": "c51816e949b110c3a04bcd8f3e238cec", "score": "0.4595602", "text": "protected function _buildQueryJoins(&$query)\n {\n\n\t\n }", "title": "" }, { "docid": "0f0c2f3f733f7fffcf530d58a4be4dde", "score": "0.45890206", "text": "public /* void */ function join($table, $on, $direction = \"\") {\n\t\t$this->join .= strtoupper($direction).' JOIN '.$table.' ON ('.$on.')';\n\t}", "title": "" }, { "docid": "15bab5311ea5c0c6fc39793505939d82", "score": "0.4583156", "text": "public function manyRelation()\n {\n Builder::macro('manyRelation', function (string $related, string $fieldId) {\n $instance = new $related;\n $model = $this->getModel();\n\n return $model->belongsToMany($related, 'form_relations', 'from_model_id', 'to_model_id', $model->getKeyName(), $instance->getKeyName())\n ->where('form_relations.from_model_type', get_class($model))\n ->where('form_relations.to_model_type', $related)\n ->where('field_id', $fieldId)\n ->orderBy('form_relations.order_column');\n });\n }", "title": "" }, { "docid": "fc6197c8e244f0a9b9f13b9e26c9c231", "score": "0.45826676", "text": "public function test_Simple_Join()\n {\n // table relation simple =>Relation_Table\n $sql = ' SELECT * FROM bl '\n . 'INNER JOIN r_bl_commande '\n . ' ON bl.id =r_bl_commande.id_bl'\n . ' INNER JOIN commande'\n . ' ON commande.id =r_bl_commande.id_commande'\n . ' WHERE 1';\n $sqlquery = (new QuerySQL())->select()\n ->from(\"bl\")\n ->join(\"commande\", \"INNER\", true)\n ->query();\n $this->assertEquals($sql, $sqlquery);\n }", "title": "" }, { "docid": "c45ff2553a71b29edc3f00f4a3e44818", "score": "0.458249", "text": "public function add_order_itemmeta_join( $join ) {\n\t\tglobal $typenow, $wpdb;\n\n\t\tif ( 'shop_order' !== $typenow ) {\n\t\t\treturn $join;\n\t\t}\n\n\t\tforeach ( wc_checkout_add_ons()->get_add_ons() as $add_on ) {\n\n\t\t\t$filtering = $add_on->is_filterable() && isset( $_GET[ $add_on->get_key() ] ) && $_GET[ $add_on->get_key() ];\n\n\t\t\t// if the join has not been altered yet, and the add-on is filterable\n\t\t\tif ( $filtering ) {\n\n\t\t\t\t$join .= \"\n\t\t\t\t\tLEFT JOIN {$wpdb->prefix}woocommerce_order_items woi ON {$wpdb->posts}.ID = woi.order_id\n\t\t\t\t\tLEFT JOIN {$wpdb->prefix}woocommerce_order_itemmeta woim_id ON woi.order_item_id = woim_id.order_item_id\n\t\t\t\t\tJOIN {$wpdb->prefix}woocommerce_order_itemmeta woim_value ON woi.order_item_id = woim_value.order_item_id\";\n\n\t\t\t\t// Break the foreach loop - we only need to alter the join clause once\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t}\n\n\t\treturn $join;\n\t}", "title": "" }, { "docid": "19bbc41132da91cbb5aae4ac2aedac1a", "score": "0.4573001", "text": "function get_related_data_items($table_info, $ids)\n {\n global $lang;\n \n $ids_query = implode(', ', $ids);\n \n if(isset($table_info['columns']))\n {\n $i=0;\n foreach($table_info['columns'] as $column)\n {\n if($column['type']>0) $query_parts[] = 'table'.$table_info['table']['id'].'.'.$column['name'];\n if($column['relation_table'])\n {\n $joins[$i]['table'] = $table_info['table']['id'];\n $joins[$i]['alias'] = 'table'.$table_info['table']['id'].'_'.$i; // unique table alias\n $joins[$i]['relation_table'] = $column['relation_table'];\n $joins[$i]['relation_table_name'] = $column['relation_table_name'];\n $joins[$i]['relation_column_name'] = $column['name'];\n $joins[$i]['fk'] = $column['name'];\n $query_parts[] = $joins[$i]['alias'].'.'.$column['relation_column_name'].' AS '.$column['name'];\n }\n ++$i;\n }\n }\n\n\n if(isset($query_parts)) $custom_query_part = ', ' . implode(', ', $query_parts);\n else $custom_query_part = '';\n \n $query = \"SELECT table\".$table_info['table']['id'].\".id,\n table\".$table_info['table']['id'].\".fk,\n extract(epoch FROM table\".$table_info['table']['id'].\".created) as created_timestamp,\n userdata_table_1.name as creator,\n extract(epoch FROM table\".$table_info['table']['id'].\".last_edited) as last_edited_timestamp,\n table\".$table_info['table']['id'].\".last_editor as last_editor,\n userdata_table_2.name as last_editor_name\";\n if($table_info['table']['type']==1) $query .= \", ST_AsText(table\".$table_info['table']['id'].\".geom) AS wkt, ST_Area(ST_GeogFromWKB(table\".$table_info['table']['id'].\".geom)) as area, ST_Perimeter(ST_GeogFromWKB(table\".$table_info['table']['id'].\".geom)) as perimeter\";\n $query .= $custom_query_part;\n $query .= \"\\nFROM \".$table_info['table']['table_name'].\" AS table\".$table_info['table']['id'];\n if(isset($joins))\n {\n foreach($joins as $join)\n {\n $query .= \"\\nLEFT JOIN \".$join['relation_table_name'].\" AS \".$join['alias'].\" ON table\".$table_info['table']['id'].\".\".$join['fk'].\"=\".$join['alias'].\".id\";\n }\n } \n \n $query .= \"\\nLEFT JOIN \".Database::$db_settings['userdata_table'].\" AS userdata_table_1 ON userdata_table_1.id=table\".$table_info['table']['id'].\".creator\";\n $query .= \"\\nLEFT JOIN \".Database::$db_settings['userdata_table'].\" AS userdata_table_2 ON userdata_table_2.id=table\".$table_info['table']['id'].\".last_editor\";\n \n $query .= \"\\nWHERE table\".$table_info['table']['id'].\".id IN (\".$ids_query.\") ORDER BY id ASC\";\n \n $dbr = Database::$connection->prepare($query);\n $dbr->execute();\n \n \n \n $i=0;\n foreach($dbr as $row) \n {\n // default columns:\n $data_items[$i]['id'] = intval($row['id']);\n $data_items[$i]['creator'] = htmlspecialchars($row['creator']);\n $data_items[$i]['created'] = htmlspecialchars(strftime($lang['time_format'], $row['created_timestamp']));\n if(!is_null($row['last_editor'])) \n {\n $data_items[$i]['last_editor'] = htmlspecialchars($row['last_editor_name']);\n $data_items[$i]['last_edited'] = htmlspecialchars(strftime($lang['time_format'], $row['last_edited_timestamp']));\n }\n // spatial data columns:\n if($table_info['table']['type']==1)\n {\n $data_items[$i]['wkt'] = $row['wkt'];\n $data_items[$i]['area_sqm'] = number_format($row['area'], 1, $lang['dec_point'], $lang['thousands_sep']);\n $data_items[$i]['area_ha'] = number_format($row['area']/10000, 1, $lang['dec_point'], $lang['thousands_sep']);\n $data_items[$i]['perimeter'] = number_format($row['perimeter'], 1, $lang['dec_point'], $lang['thousands_sep']);\n } \n // custom columns:\n if(isset($table_info['columns']))\n {\n foreach($table_info['columns'] as $column)\n {\n // first custom column as feature label: \n if($table_info['table']['type']==1 && empty($data_items[$i]['_featurelabel_'])) $data_items[$i]['_featurelabel_'] = htmlspecialchars($row[$column['name']]);\n $data_items[$i][$column['name']] = htmlspecialchars($row[$column['name']]);\n }\n }\n ++$i;\n }\n if(isset($data_items)) return $data_items;\n else return false;\n \n }", "title": "" }, { "docid": "f80ebb2b8e931ba5c877ed2e1d11a143", "score": "0.45658305", "text": "public function get_sql_join() {\n return parent::get_sql_join(CONTEXT_ELIS_CLASS, 'cls.id');\n }", "title": "" }, { "docid": "cd5933b07cf988b68d9024579062ad56", "score": "0.45655608", "text": "public function joinPageRelatedByparentpage($relationAlias = null, $joinType = Criteria::LEFT_JOIN)\n {\n $tableMap = $this->getTableMap();\n $relationMap = $tableMap->getRelation('PageRelatedByparentpage');\n\n // create a ModelJoin object for this join\n $join = new ModelJoin();\n $join->setJoinType($joinType);\n $join->setRelationMap($relationMap, $this->useAliasInSQL ? $this->getModelAlias() : null, $relationAlias);\n if ($previousJoin = $this->getPreviousJoin()) {\n $join->setPreviousJoin($previousJoin);\n }\n\n // add the ModelJoin to the current object\n if ($relationAlias) {\n $this->addAlias($relationAlias, $relationMap->getRightTable()->getName());\n $this->addJoinObject($join, $relationAlias);\n } else {\n $this->addJoinObject($join, 'PageRelatedByparentpage');\n }\n\n return $this;\n }", "title": "" }, { "docid": "39ef7c5c6e6af46c936d1880b8d759dc", "score": "0.4565183", "text": "public function useUserRelatedByIdQuery($relationAlias = null, $joinType = Criteria::LEFT_JOIN)\n {\n return $this\n ->joinUserRelatedById($relationAlias, $joinType)\n ->useQuery($relationAlias ? $relationAlias : 'UserRelatedById', '\\Rdy4Racing\\Models\\UserQuery');\n }", "title": "" }, { "docid": "5a688f1198c5f128b8dbe0e8939a3114", "score": "0.45638815", "text": "function join($table, $cond, $type = '')\n\t{\n\t\t$this->db->join($table, $cond, $type);\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "9d9ac1b87fa53f0b308ee2821bedf13b", "score": "0.45611626", "text": "private function getManyOrOneToOneRelatedData(ResultQueryInterface $parentEntityQuery, RelationMap $relation, array &$relatedData, RelatedData $relatedDataObject): SelectQueryInterface\n\t{\n\t\t$table = $relation->getTableName();\n\n\t\t$parentIds = $this->makeInArgument($parentEntityQuery->getResult(), $relation->getRelationType()->getFieldName());\n\n\t\t/**\n\t\t * @var SelectQuery $query\n\t\t */\n\t\t$query = $this->orm->createQuery();\n\t\t$query\n\t\t\t->from($table)\n\t\t\t->whereExpr(sprintf(\n\t\t\t\t\"%s IN (%s)\",\n\t\t\t\t$relation->getRelationType()->getRelatedEntity()->getIdentifier(),\n\t\t\t\t$parentIds\n\t\t\t));\n\n\t\t$params = [];\n foreach ($relatedDataObject->getConditions() as $condition) {\n $generatedKey = AbstractQuery::generateParamName($condition->getField());\n $params[$generatedKey] = $condition->getValue();\n $query->whereExpr($condition->getField() . $condition->getOperator() . ':' . $generatedKey);\n }\n\n\t\tif (!empty($parentIds)) {\n\t\t\t$query->execute($params);\n\t\t} else {\n\t\t\t$query->setResult([]);\n\t\t}\n\n\t\tforeach($parentEntityQuery->getResult() as $parentResult) {\n\t\t\tif ($query->getResult()) {\n\t\t\t\tforeach ($query->getResult() as $childResult) {\n\t\t\t\t\tif ($parentResult[$relation->getRelationType()->getFieldName()] ==\n\t\t\t\t\t\t$childResult[$relation->getRelationType()->getRelatedEntity()->getIdentifier()]) {\n\t\t\t\t\t\t$relatedData[$relation->getEntityField()]['data'][$childResult[$relation->getRelationType()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t->getRelatedEntity()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t->getIdentifier()\n\t\t\t\t\t\t]] = $childResult;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $query;\n\t}", "title": "" }, { "docid": "01a8292100a9fde4e86b91725233a2f9", "score": "0.4557006", "text": "public function jsonGlobalJoinWhere($select, $tbl, $id, $value, $join)\n {\n $this->datatables->select($select);\n $this->datatables->from($tbl);\n $this->datatables->where($id, $value);\n foreach ($join as $row) {\n $this->datatables->join($row[0], $row[1], $row[2]);\n }\n\n return $this->datatables->generate();\n }", "title": "" }, { "docid": "bfb95d7817f8706b461fc3709f9f4496", "score": "0.45505753", "text": "public function fetchByIdWithRelation($id, array $foreignKeys)\n {\n $tableName = static::tableName();\n $rel_tables = static::relationTables();\n $primaryKey = static::primaryKey();\n\n /*For Example\n * SELECT *, projects.id FROM projects JOIN\n * departments ON dep_id = departments.id JOIN sub_counties ON sub_id = sub_counties.id\n * JOIN financial_years ON year_id = financial_years.id WHERE projects.id = $id\n *\n * departments ON :departments = departments.id JOIN sub_counties ON :sub_counties = sub_counties.id\n * JOIN financial_years ON :financial_years = financial_years.id WHERE projects.id = $id\n */\n $partSql = implode(\" JOIN \", array_map(fn($attr) => \"$attr ON :$attr = $attr.$primaryKey\", $rel_tables));\n //var_dump($partSql);\n /*\n * We want to replace eg :department with the respective foreign keys passed above, we can think\n * of it as binding values\n */\n $attr_replace = array_map(fn($attr) => \":$attr\", $rel_tables);\n $sql = str_replace($attr_replace, $foreignKeys, $partSql);\n\n $statement = self::prepare(\"SELECT *, $tableName.$primaryKey FROM $tableName JOIN $sql WHERE $tableName.$primaryKey = $id\");\n\n $statement->execute();\n\n return $statement->fetchObject(static::class);\n\n }", "title": "" }, { "docid": "a6b97344740d0ada7225aebdd2f06703", "score": "0.45407087", "text": "public function joinUserRelatedById($relationAlias = null, $joinType = Criteria::LEFT_JOIN)\n {\n $tableMap = $this->getTableMap();\n $relationMap = $tableMap->getRelation('UserRelatedById');\n\n // create a ModelJoin object for this join\n $join = new ModelJoin();\n $join->setJoinType($joinType);\n $join->setRelationMap($relationMap, $this->useAliasInSQL ? $this->getModelAlias() : null, $relationAlias);\n if ($previousJoin = $this->getPreviousJoin()) {\n $join->setPreviousJoin($previousJoin);\n }\n\n // add the ModelJoin to the current object\n if ($relationAlias) {\n $this->addAlias($relationAlias, $relationMap->getRightTable()->getName());\n $this->addJoinObject($join, $relationAlias);\n } else {\n $this->addJoinObject($join, 'UserRelatedById');\n }\n\n return $this;\n }", "title": "" }, { "docid": "d8a4c398e57c101bcde72589a2ab59d8", "score": "0.4528827", "text": "public function getRelatedProducts($id) {\n \n $related_products = RelatedProduct::model()->findAll(\"product_id = \" . $id);\n $related_products = CHtml::listData($related_products, \"related_product_id\", \"related_product_id\");\n \n $criteria = new CDbCriteria;\n $criteria->addInCondition('product_id', $related_products);\n\n $dataProvider = new DTActiveDataProvider($this, array(\n 'pagination' => array(\n 'pageSize' => 50,\n ),\n 'criteria' => $criteria,\n ));\n\n return $dataProvider;\n }", "title": "" }, { "docid": "71df8dcc871682f1b28b9d9b7dc2763f", "score": "0.4528181", "text": "public function innerJoin($model, $condition = null, $alias = null);", "title": "" }, { "docid": "98f779d84a1a025dc982e8ab32bf9963", "score": "0.45271412", "text": "public function joinRelation($name, $type='INNER'){\n\t\t\n\t\tif(!isset($this->_params['joinRelations']))\n\t\t\t$this->_params['joinRelations']=array();\n\t\t\n\t\t$this->_params['joinRelations'][$name]=array('name'=>$name, 'type'=>$type);\n\t\t\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "a0394b406b65ee6c6fad670f8dc468e0", "score": "0.45239705", "text": "protected function _joinTables()\n {\n $adapter = $this->getConnection();\n $entityType = Mage::getSingleton('eav/config')->getEntityType(Mage_Catalog_Model_Product::ENTITY);\n $attribute = Mage::getModel('eav/config')->getAttribute($entityType->getEntityTypeId(), 'name');\n\n $joinConditionDefault = $adapter->quoteInto('p_d.attribute_id=?', $attribute->getAttributeId()) .\n $adapter->quoteInto(' AND p_d.store_id=?', 0) . ' AND main_table.product_id=p_d.entity_id';\n\n $joinCondition = $adapter->quoteInto('p.attribute_id=?', $attribute->getAttributeId()) .\n ' AND p.store_id=main_table.store_id AND main_table.product_id=p.entity_id';\n\n $this->getSelect()\n ->joinLeft(\n array('p_d' => $attribute->getBackend()->getTable()),\n $joinConditionDefault,\n array()\n );\n\n $codeExpr = $adapter->getCheckSql('p.value IS NOT NULL', 'p.value', 'p_d.value');\n $this->getSelect()\n ->joinLeft(\n array('p' => $attribute->getBackend()->getTable()),\n $joinCondition,\n array('name' => $codeExpr)\n );\n\n $codeExpr = $adapter->getCheckSql(\n 'types.gbase_itemtype IS NOT NULL',\n 'types.gbase_itemtype',\n $adapter->quote(Mage_GoogleBase_Model_Service_Item::DEFAULT_ITEM_TYPE)\n );\n\n $this->getSelect()\n ->joinLeft(\n array('types' => $this->getTable('googlebase/types')),\n 'main_table.type_id=types.type_id',\n array('gbase_itemtype' => $codeExpr)\n );\n\n return $this;\n }", "title": "" }, { "docid": "a99fea2e84ecc90d0c430ba97896f2b5", "score": "0.45195374", "text": "public function doSelectJoinTranslation(Doctrine_Query $q)\n {\n //--- Get Alias ---//\n $rootAlias = $q->getRootAlias();\n\n //--- Get Default Culture ---//\n $culture = sfContext::getInstance()->getUser()->getCulture();\n\n $q->leftJoin($rootAlias . '.Translation ct')->addwhere('ct.lang = ?', $culture);\n\n return $q;\n }", "title": "" }, { "docid": "bdf86e2c56a3846bdbfee163671cafbe", "score": "0.45167163", "text": "private function buildJoin()\n {\n if (empty($this->join)) {\n return;\n }\n\n foreach ($this->join as $data) {\n list ($joinType, $joinTable, $joinCondition) = $data;\n\n if (is_object($joinTable)) {\n $joinStr = $this->buildPair(\"\", $joinTable);\n } else {\n $joinStr = $joinTable;\n }\n\n $this->query .= \" \".$joinType.\" JOIN \".$joinStr.\n (false !== stripos($joinCondition, 'using') ? \" \" : \" ON \")\n .$joinCondition;\n }\n }", "title": "" }, { "docid": "b588da2ab79969e4aec09e98a8d00ca3", "score": "0.45101497", "text": "protected function links($id)\n\t{\n\t\tif ($id instanceof $this)\n\t\t{\n\t\t\t$id = $id->pk();\n\t\t}\n\n\t\treturn DB::select('id', 'title')\n\t\t\t->from($this->_table_name)\n\t\t\t->where('id', 'IN', DB::expr(DB::select('remote_id')\n\t\t\t\t->from('wiki_links')\n\t\t\t\t->where('wiki_id', '=', DB::expr($this->_table_name.'.'.'id'))\n\t\t\t\t))\n\t\t\t->execute($this->_db)\n\t\t\t->as_array('id', 'title');\n\t}", "title": "" }, { "docid": "87bf37871be120f6767d0d68b2a7e263", "score": "0.45100018", "text": "public function find($id, $related = []);", "title": "" }, { "docid": "fc3d561be0c87423b06158bcb52ebdf2", "score": "0.4509998", "text": "public function getPaged($id,$pagesize){\r\n\t\t$query = $this->getQuery($id);\r\n\t\t$query->setPageSize($pagesize);\r\n\t\t$query->usePaging();\r\n\t\treturn $query->find('LinkedTable',$this->linkedclass);\r\n\t}", "title": "" } ]
516ab75d500d17c5419e3a1a8251b4bc
This is the main function that execute the parsing.
[ { "docid": "30d7997a27a4b47ded5653e7a9cfabd8", "score": "0.0", "text": "public function doImport(){\n // initialize zend parser\n try{\n $oZendFeed = Zend_Feed::import($this->requestUrl);\n }catch(Exception $oException){\n throw new AMI_DataImportException(\n 'exception_unable_to_import_rss',\n AMI_DataImportException::ERROR_IMPORTING,\n array('driverMsg' => $oException->getMessage())\n );\n }\n\n $root = '';\n foreach($oZendFeed->getDOM()->getElementsByTagName('link') as $oLink){\n $aURL = parse_url($oLink->nodeValue);\n if(isset($aURL['host'])){\n $root =\n (isset($aURL['scheme']) ? $aURL['scheme'] : 'http') . '://' .\n $aURL['host'] .\n (isset($aURL['port']) ? ':' . $aURL['port'] : '') . '/';\n }\n break;\n }\n\n // read data from the feed\n $aImportedData = array();\n\n // put all records into array\n foreach($oZendFeed as $oEntry){\n\n $aData = array();\n foreach($this->aFields as $fieldData){\n $fieldName = trim($fieldData['name']);\n\n // field is method?\n if(substr($fieldName, -2, 2) == '()'){\n $methodName = 'field' . ucfirst(substr($fieldName, 0, strlen($fieldName) - 2));\n if(method_exists($this, $methodName)){\n // call driver method to parse the field\n call_user_func_array(array($this, $methodName), array($oEntry));\n }else{\n $fieldValue = '';\n }\n }else{\n $fieldValue = call_user_func(array($oEntry, $fieldName));\n }\n\n // if field is pubdate we must convert it to our format\n // $aData[$fieldName] = $fieldName == 'pubDate'\n\n if($root){\n AMI_Registry::push('disable_error_mail', true);\n foreach(\n array(\n \"/href=(\\\"|')?([^\\\"'\\s]+)/si\",\n \"/src=(\\\"|')?([^\\\"'\\s]+)/si\",\n \"/data-ami-mbpopup=(\\\"|')?([^\\\"'\\s]+)/si\"\n ) as $pattern\n ){\n if(preg_match_all($pattern, $fieldValue, $aMatches)){\n foreach($aMatches[2] as $url){\n $aURL = parse_url($url);\n if(!isset($aURL['host']) || '' == $aURL['host']){\n $fieldValue = str_replace($url, $root . $url, $fieldValue);\n }\n }\n\n }\n }\n AMI_Registry::pop('disable_error_mail');\n }\n\n $aData[] = $fieldName == 'pubDate'\n ? gmdate('Y-m-d H:i:s', strtotime($fieldValue, time()))\n : $fieldValue;\n }\n\n $aImportedData[] = $aData;\n }\n\n // add event before initializing connection\n $aEvent = array('aImportedData' => $aImportedData);\n AMI_Event::fire('ami_data_import_after_import', $aEvent, $this->modId);\n $aImportedData = $aEvent['aImportedData'];\n\n $this->bIsImported = true;\n $this->rawData = null;\n $this->aImportedData = $aImportedData;\n\n return true;\n }", "title": "" } ]
[ { "docid": "41be9f83a2e16eea96a3666c9611cd0d", "score": "0.72434634", "text": "function run()\r\n {\r\n if (isset($this->error)) {\r\n $this->_printUsage($this->error);\r\n } else {\r\n if (isset($this->dir)) {\r\n $this->_parseDir();\r\n } elseif (isset($this->file)) {\r\n $this->_parseFile();\r\n }\r\n }\r\n }", "title": "" }, { "docid": "9eacacbd290e55648a6ae7eed142826c", "score": "0.69374996", "text": "function parse() {}", "title": "" }, { "docid": "4f11aad988b41418c4395268fe65959f", "score": "0.67337954", "text": "public function parser()\n\t{\n\t\t// wraps parser method\n\t}", "title": "" }, { "docid": "176c4555a560799549f0884625f48d56", "score": "0.6667129", "text": "public function parse();", "title": "" }, { "docid": "176c4555a560799549f0884625f48d56", "score": "0.6667129", "text": "public function parse();", "title": "" }, { "docid": "176c4555a560799549f0884625f48d56", "score": "0.6667129", "text": "public function parse();", "title": "" }, { "docid": "176c4555a560799549f0884625f48d56", "score": "0.6667129", "text": "public function parse();", "title": "" }, { "docid": "b4c0eee4b5a7d1c9a52565d91a07e68c", "score": "0.65050524", "text": "public static function main() {\n // open the URL into a buffered reader,\n // print the header,\n // parse each section, printing a formatted version\n // followed by the result of the execution\n // print the footer.\n\n $inputSource = 'http://localhost/secure1/fall20Testing.txt';\n // $inputSource = 'http://cs5339.cs.utep.edu/longpre/fall20Testing.txt'; // debugging\n\n $header = \"<html>\" . self::$EOL .\n \" <head>\" . self::$EOL .\n \" <title>CS 4339/5339 PHP assignment</title>\" . self::$EOL .\n \" </head>\" . self::$EOL .\n \" <body>\" . self::$EOL .\n \" <pre>\";\n\n $footer = \" </pre>\" . self::$EOL .\n \" </body>\" . self::$EOL .\n \"</html>\";\n\n $in = fopen($inputSource, 'r') or die(\"File does not exist.\");\n $inputLine;\n $inputFile = \"\";\n\n // from php.net\n while (($inputLine = fgets($in)) !== FALSE) {\n $inputFile = $inputFile . $inputLine;\n }\n \n if (!feof($in)) {\n die(\"Error reading file.\");\n } else {\n fclose($in);\n }\n\n self::$t = new Tokenizer($inputFile);\n self::$currentToken = self::$t->nextToken();\n $section = 0;\n echo $header . self::$EOL;\n\n // loop through all sections, for each section printing result\n // if a section causes exception, catch and jump to next section\n while (self::$currentToken->getType() !== TokenType::EOF) {\n echo \"section \" . ++$section . self::$EOL;\n\n try {\n self::evalSection();\n echo \"Section result:\" . self::$EOL;\n echo self::$result . self::$EOL;\n\n } catch (EvalSectionException $ex) {\n // skip to the end of the section \n echo $ex . self::$EOL;\n\n while (self::$currentToken->getType() !== TokenType::RSQUAREBRACKET && self::$currentToken->getType() !== TokenType::EOF) {\n self::$currentToken = self::$t->nextToken();\n }\n self::$currentToken = self::$t->nextToken();\n }\n }\n echo $footer . self::$EOL;\n }", "title": "" }, { "docid": "508094b2946054fb5bd8c38504d5525b", "score": "0.6412609", "text": "abstract public function parse();", "title": "" }, { "docid": "a9cc2b0afbe84a0641fffbe129c4be83", "score": "0.6382542", "text": "abstract function parse();", "title": "" }, { "docid": "fdae7fbed8970046adec2c9d4074b3d5", "score": "0.6332726", "text": "public function main()\n\t{\n $this->commonfunction = new CommonFunctions();\n $this->_registerAutoloaders();\n\t\t\t\t$this->_registerServices();\n /*\n * Initiate for error handling via php inbuilt function\n * general syntax as below\n * handler(class name, function of that class);\n */\n\t\t\t\t\n \n\t\techo $this->handle()->getContent();\n\t}", "title": "" }, { "docid": "bfce27be2dbdc04ea524f16a6c38a9f9", "score": "0.63180363", "text": "function parseMainPage()\n{\n \n}", "title": "" }, { "docid": "1b609c54488d462c5d38c4a8b12581c4", "score": "0.6317338", "text": "public function initParsing() {\n\t\t$fName = __METHOD__;\n\t\t$this->profileIn($fName);\n\t\tglobal $w2lTags;\n\t\tglobal $w2lParserFunctions;\n\t\tglobal $w2lConfig;\n\n\t\tif ($this->initiated == true ) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\twfRunHooks('w2lInitParser', array(&$this));\n\t\t\n\t\t$this->unique = $this->uniqueString();\n\t\t\n\t\tforeach($w2lTags as $key => $value) {\n\t\t\t$this->addTagCallback($key, $value);\n\t\t}\n\n\t\tforeach($w2lParserFunctions as $key => $value) {\n\t\t\t$this->addParserFunction($key, $value);\n\t\t}\n\n\t\tforeach($w2lConfig as $key => $value) {\n\t\t\t$this->setVal($key, $value);\n\t\t}\n\n\t\t//$this->addCoreParserFunction();\n\t\t$this->addCoreParserFunction( 'int', array( 'CoreParserFunctions', 'intFunction' ) );\n\t\t$this->addCoreParserFunction( 'ns', array( 'CoreParserFunctions', 'ns' ) );\n\t\t$this->addCoreParserFunction( 'urlencode', array( 'CoreParserFunctions', 'urlencode' ) );\n\t\t$this->addCoreParserFunction( 'lcfirst', array( 'CoreParserFunctions', 'lcfirst' ) );\n\t\t$this->addCoreParserFunction( 'ucfirst', array( 'CoreParserFunctions', 'ucfirst' ) );\n\t\t$this->addCoreParserFunction( 'lc', array( 'CoreParserFunctions', 'lc' ) );\n\t\t$this->addCoreParserFunction( 'uc', array( 'CoreParserFunctions', 'uc' ) );\n\t\t$this->addCoreParserFunction( 'localurl', array( 'CoreParserFunctions', 'localurl' ) );\n\t\t$this->addCoreParserFunction( 'localurle', array( 'CoreParserFunctions', 'localurle' ) );\n\t\t$this->addCoreParserFunction( 'fullurl', array( 'CoreParserFunctions', 'fullurl' ) );\n\t\t$this->addCoreParserFunction( 'fullurle', array( 'CoreParserFunctions', 'fullurle' ) );\n\t\t//$this->addCoreParserFunction( 'formatnum', array( 'CoreParserFunctions', 'formatnum' ) );\n\t\t//$this->addCoreParserFunction( 'grammar', array( 'CoreParserFunctions', 'grammar' ) );\n\t\t//$this->addCoreParserFunction( 'plural', array( 'CoreParserFunctions', 'plural' ) );\n\t\t$this->addCoreParserFunction( 'numberofpages', array( 'CoreParserFunctions', 'numberofpages' ) );\n\t\t$this->addCoreParserFunction( 'numberofusers', array( 'CoreParserFunctions', 'numberofusers' ) );\n\t\t$this->addCoreParserFunction( 'numberofarticles', array( 'CoreParserFunctions', 'numberofarticles' ) );\n\t\t$this->addCoreParserFunction( 'numberoffiles', array( 'CoreParserFunctions', 'numberoffiles' ) );\n\t\t$this->addCoreParserFunction( 'numberofadmins', array( 'CoreParserFunctions', 'numberofadmins' ) );\n\t\t$this->addCoreParserFunction( 'language', array( 'CoreParserFunctions', 'language' ) );\n\t\t$this->addCoreParserFunction( 'padleft', array( 'CoreParserFunctions', 'padleft' ) );\n\t\t$this->addCoreParserFunction( 'padright', array( 'CoreParserFunctions', 'padright' ) );\n\t\t$this->addCoreParserFunction( 'anchorencode', array( 'CoreParserFunctions', 'anchorencode' ) );\n\t\t$this->addCoreParserFunction( 'special', array( 'CoreParserFunctions', 'special' ) );\n\t\t//$this->addCoreParserFunction( 'defaultsort', array( 'CoreParserFunctions', 'defaultsort' ) );\n\t\t$this->addCoreParserFunction( 'pagesinnamespace', array( 'CoreParserFunctions', 'pagesinnamespace' ) );\n\n\t\t// And here we add some replace-rules\n\t\t$this->addSimpleReplace(\" - \",\" -- \");\n\t\t$this->addSimpleReplace(\" -\\n\",\" --\\n\");\n\t\t$this->addSimpleReplace(\"\\n- \", \"\\n-- \");\n\n\t\t$this->addSimpleReplace(\"...\",\"{\\dots}\");\n\n\t\t\n\t\tinclude('w2lChars.php');\n\t\tinclude('w2lQuotes.php');\n\t\t\n\t\twfRunHooks('w2lInitParserFinish', array(&$this));\n\n\t\t$this->initiated = true;\n\t\t$this->profileOut($fName);\n\t\treturn;\n\t}", "title": "" }, { "docid": "7db79e81a95fbd4404c7968a2e881e8e", "score": "0.6310199", "text": "function startDoc()\r\n {\r\n $this->output.=\"Parsing started\\n\";\r\n }", "title": "" }, { "docid": "60659d55f89314ae93ed3999dbf62644", "score": "0.62963146", "text": "function parse()\n {\n $lines = explode(\"\\n\", $this->wiki->source);\n\n $this->wiki->source = '';\n\n foreach ($lines as $line) {\n $this->wiki->source .= $this->process($line) . \"\\n\";\n }\n $this->wiki->source = substr($this->wiki->source, 0, -1);\n }", "title": "" }, { "docid": "a75f0d99baad5c1d1f145b7c622523fc", "score": "0.6243465", "text": "function parse($toparse) {\n\t$action = \"parse\";\n\t$output = \"\";\n\t$code = \"\";\n\t$text = \"\";\n\t$url = \"\";\n\t$type = \"\";\n\t$col = \"\";\n\t$subaction = \"\";\n\t$subcode = \"\";\n\tfor($i = 0; $i < strlen($toparse); $i++) {\n\t\tif($action == \"parse\") {\n\t\t\t//echo(\"DEBUG: Action: parse<br />\");\n\t\t\tif($toparse[$i] == \"\\n\") {\n\t\t\t//echo(\"DEBUG: Parsed endl, inserting br<br />\");\t\n\t\t\t$output .= \"<br />\";\t\n\t\t\t} else if($toparse[$i] == '[') {\n\t\t\t//echo(\"DEBUG: Code detected, reading...<br />\");\n\t\t\t$code = \"\";\n\t\t\t$action = \"getcode\";\t\n\t\t\t} else {\n\t\t\t//echo(\"DEBUG: Adding normal char to output...<br />\");\n\t\t\t$output .= $toparse[$i];\t\n\t\t\t}\n\t\t} else if($action == \"getcode\") {\n\t\t\t//echo(\"DEBUG: Action: getcode<br />\");\n\t\t\tif($toparse[$i] != \"]\") {\n\t\t\t//echo(\"DEBUG: Adding normal char to code...<br />\");\n\t\t\t$code .= $toparse[$i];\t\n\t\t\t} else {\n\t\t\t//echo(\"DEBUG: End of code detected, parsing...<br />\");\n\t\t\t$action = \"codeparse\";\t\n\t\t\t}\n\t\t} else if($action == \"codeparse\") {\n\t\t\t//echo(\"DEBUG: Action: codeparse<br />\");\n\t\t\tif($code == \"b\") {\n\t\t\t//echo(\"DEBUG: b code detected, switching to b...<br />\");\n\t\t\t$action = \"b\";\n\t\t\t$subaction = \"text\";\n\t\t\t} else if($code == \"i\") {\n\t\t\t//echo(\"DEBUG: i code detected, switching to i...<br />\");\n\t\t\t$action = \"i\";\n\t\t\t$subaction = \"text\";\n\t\t\t} else if($code == \"u\") {\n\t\t\t//echo(\"DEBUG: u code detected, switching to u...<br />\");\t\n\t\t\t\t$action = \"u\";\n\t\t\t\t$subaction = \"text\";\n\t\t\t} else if($code == \"img\") {\n\t\t\t//echo(\"DEBUG: img code detected, switching to img...<br />\");\t\n\t\t\t\t$action = \"img\";\n\t\t\t\t$subaction = \"text\";\n\t\t\t} else if($code[0] == 'a') {\n\t\t\t\t//echo(\"DEBUG: a code detected...<br />\");\n\t\t\t\tif($code[1] == \"=\") {\n\t\t\t\t//echo(\"DEBUG: Custom a code detected, switching to ac...<br />\");\t\n\t\t\t\t\t$action = \"ac\";\n\t\t\t\t\t$subaction = \"url\";\n\t\t\t\t} else {\n\t\t\t\t//echo(\"DEBUG: Simple a code detected, switching to a...<br />\");\t\n\t\t\t\t\t$action = \"a\";\n\t\t\t\t\t$subaction = \"text\";\n\t\t\t\t}\n\t\t\t} else if($code[0] == 'o' AND $code[1] == 'b' AND $code[2] == 'j' AND $code[3] == 'e' AND $code[4] == 'c' AND $code[5] == 't') {\n\t\t\t//echo(\"DEBUG: object code detected, switching to object...<br />\");\t\n\t\t\t\t$action = \"object\";\n\t\t\t\t$subaction = \"type\";\n\t\t\t} else if($code[0] == 'c' AND $code[1] == 'o' AND $code[2] == 'l' AND $code[3] == 'o' AND $code[4] == 'r') {\n\t\t\t//echo(\"DEBUG: color code detected, switching to color...<br />\");\t\n\t\t\t\t$action = \"color\";\n\t\t\t\t$subaction = \"col\";\n\t\t\t}\n\t\t} \n\t\tif($action == \"b\") {\n\t\t\t//echo(\"DEBUG: Action: b<br />\");\t\n\t\t\tif($subaction == \"code\") {\n\t\t\t\t//echo(\"DEBUG: b: Subaction: code<br />\");\n\t\t\t\tif($toparse[$i] == \"]\") {\n\t\t\t\t\tif($subcode == \"/b\") {\n\t\t\t\t\t\t//echo(\"DEBUG: b: Parsed end of b, executing function...<br />\");\n\t\t\t\t\t\t$output .= b(parse($text));\n\t\t\t\t\t\t//echo(\"DEBUG: b: Clearing vars and switching back to parse...<br />\");\n\t\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t\t$subaction = \"\";\n\t\t\t\t\t\t$text = \"\";\n\t\t\t\t\t\t$action = \"parse\";\n\t\t\t\t\t} else {\n\t\t\t\t\t//echo(\"DEBUG: b: This code is not the end of b, adding to text and switching mode...<br />\");\n\t\t\t\t\t$text .= '[';\n\t\t\t\t\t$text .= $subcode;\n\t\t\t\t\t$text .= $toparse[$i];\n\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t$subaction = \"text\";\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t//echo(\"DEBUG: b: Getting char to subcode...<br />\");\n\t\t\t\t$subcode .= $toparse[$i];\t\n\t\t\t\t}\n\t\t\t} else if($subaction == \"text\") {\n\t\t\t\t//echo(\"DEBUG: b: Subaction: text<br />\");\n\t\t\t\tif($toparse[$i] == \"[\") {\n\t\t\t\t//echo(\"DEBUG: b: Code detected, switching mode...<br />\");\n\t\t\t\t$subaction = \"code\";\n\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//echo(\"DEBUG: b: Getting char to text...<br />\");\n\t\t\t$text .= $toparse[$i];\t\n\t\t\t}\n\t\t} else if($action == \"i\") {\n\t\t\t//echo(\"DEBUG: Action: i<br />\");\n\t\t\tif($subaction == \"code\") {\n\t\t\t\t//echo(\"DEBUG: i: Subaction: code<br />\");\n\t\t\t\tif($toparse[$i] == \"]\") {\n\t\t\t\t\tif($subcode == \"/i\") {\n\t\t\t\t\t\t//echo(\"DEBUG: i: Parsed end of i, executing function...<br />\");\n\t\t\t\t\t\t$output .= i(parse($text));\n\t\t\t\t\t\t//echo(\"DEBUG: i: Clearing vars and switching back to parse...<br />\");\n\t\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t\t$subaction = \"\";\n\t\t\t\t\t\t$text = \"\";\n\t\t\t\t\t\t$action = \"parse\";\n\t\t\t\t\t} else {\n\t\t\t\t\t//echo(\"DEBUG: i: This code is not the end of i, adding to text and switching mode...<br />\");\n\t\t\t\t\t$text .= '[';\n\t\t\t\t\t$text .= $subcode;\n\t\t\t\t\t$text .= $toparse[$i];\n\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t$subaction = \"text\";\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t//echo(\"DEBUG: i: Getting char to subcode...<br />\");\n\t\t\t\t$subcode .= $toparse[$i];\t\n\t\t\t\t}\n\t\t\t} else if($subaction == \"text\") {\n\t\t\t\t//echo(\"DEBUG: i: Subaction: text<br />\");\n\t\t\t\tif($toparse[$i] == \"[\") {\n\t\t\t\t//echo(\"DEBUG: i: Code detected, switching mode...<br />\");\t\n\t\t\t\t$subaction = \"code\";\n\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//echo(\"DEBUG: i: Getting char to text...<br />\");\n\t\t\t$text .= $toparse[$i];\t\n\t\t\t}\n\t\t} else if($action == \"u\") {\n\t\t\t//echo(\"DEBUG: Action: u<br />\");\n\t\t\tif($subaction == \"code\") {\n\t\t\t\t//echo(\"DEBUG: u: Subaction: code<br />\");\n\t\t\t\tif($toparse[$i] == \"]\") {\n\t\t\t\t\tif($subcode == \"/u\") {\n\t\t\t\t\t\t//echo(\"DEBUG: u: Parsed end of u, executing function...<br />\");\n\t\t\t\t\t\t$output .= u(parse($text));\n\t\t\t\t\t\t//echo(\"DEBUG: u: Clearing vars and switching back to parse...<br />\");\n\t\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t\t$subaction = \"\";\n\t\t\t\t\t\t$action = \"parse\";\n\t\t\t\t\t} else {\n\t\t\t\t\t//echo(\"DEBUG: u: This code is not the end of u, adding to text and switching mode...<br />\");\n\t\t\t\t\t$text .= '[';\n\t\t\t\t\t$text .= $subcode;\n\t\t\t\t\t$text .= $toparse[$i];\n\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t$subaction = \"text\";\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t//echo(\"DEBUG: u: Getting char to subcode...<br />\");\n\t\t\t\t$subcode .= $toparse[$i];\t\n\t\t\t\t}\n\t\t\t} else if($subaction == \"text\") {\n\t\t\t\t//echo(\"DEBUG: u: Subaction: text<br />\");\n\t\t\t\tif($toparse[$i] == \"[\") {\n\t\t\t\t//echo(\"DEBUG: u: Code detected, switching mode...<br />\");\t\n\t\t\t\t$subaction = \"code\";\n\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//echo(\"DEBUG: u: Getting char to text...<br />\");\n\t\t\t$text .= $toparse[$i];\t\n\t\t\t}\n\t\t} else if($action == \"img\") {\n\t\t\t//echo(\"DEBUG: Action: img<br />\");\n\t\t\tif($subaction == \"code\") {\n\t\t\t\t//echo(\"DEBUG: img: Subaction: code<br />\");\n\t\t\t\tif($toparse[$i] == \"]\") {\n\t\t\t\t\tif($subcode == \"/img\") {\n\t\t\t\t\t\t//echo(\"DEBUG: img: Parsed end of img, executing function...<br />\");\n\t\t\t\t\t\t$output .= img(parse($text));\n\t\t\t\t\t\t//echo(\"DEBUG: img: Clearing vars and switching back to parse...<br />\");\n\t\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t\t$subaction = \"\";\n\t\t\t\t\t\t$text = \"\";\n\t\t\t\t\t\t$action = \"parse\";\n\t\t\t\t\t} else {\n\t\t\t\t\t\t//echo(\"DEBUG: img: This code is not the end of img, adding to text and switching mode...<br />\");\n\t\t\t\t\t$text .= '[';\n\t\t\t\t\t$text .= $subcode;\n\t\t\t\t\t$text .= $toparse[$i];\n\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t$subaction = \"text\";\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t//\techo(\"DEBUG: img: Getting char to subcode...<br />\");\n\t\t\t\t$subcode .= $toparse[$i];\t\n\t\t\t\t}\n\t\t\t} else if($subaction == \"text\") {\n\t\t\t\t//echo(\"DEBUG: img: Subaction: text<br />\");\n\t\t\t\tif($toparse[$i] == \"[\") {\n\t\t\t\t//echo(\"DEBUG: img: Code detected, switching mode...<br />\");\n\t\t\t\t$subaction = \"code\";\n\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//echo(\"DEBUG: img: Getting char to text...<br />\");\n\t\t\t$text .= $toparse[$i];\t\n\t\t\t}\n\t\t} else if($action == \"a\") {\n\t\t\t//echo(\"DEBUG: Action: a<br />\");\n\t\t\tif($subaction == \"code\") {\n\t\t\t\t//echo(\"DEBUG: a: Subaction: code<br />\");\n\t\t\t\tif($toparse[$i] == \"]\") {\n\t\t\t\t\tif($subcode == \"/a\") {\n\t\t\t\t\t//\techo(\"DEBUG: a: Parsed end of a, executing function...<br />\");\n\t\t\t\t\t\t$output .= a($text, parse($text));\n\t\t\t\t\t\t//echo(\"DEBUG: a: Clearing vars and switching back to parse...<br />\");\n\t\t\t\t\t\t$text = \"\";\n\t\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t\t$subaction = \"\";\n\t\t\t\t\t\t$action = \"parse\";\n\t\t\t\t\t} else {\n\t\t\t\t\t//echo(\"DEBUG: a: This code is not the end of a, adding to text and switching mode...<br />\");\n\t\t\t\t\t$text .= '[';\n\t\t\t\t\t$text .= $subcode;\n\t\t\t\t\t$text .= $toparse[$i];\n\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t$subaction = \"text\";\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t//echo(\"DEBUG: a: Getting char to subcode...<br />\");\n\t\t\t\t$subcode .= $toparse[$i];\t\n\t\t\t\t}\n\t\t\t} else if($subaction == \"text\") {\n\t\t\t\t//echo(\"DEBUG: a: Subaction: text<br />\");\n\t\t\t\tif($toparse[$i] == \"[\") {\n\t\t\t\t//echo(\"DEBUG: a: Code detected, switching mode...<br />\");\n\t\t\t\t$subaction = \"code\";\n\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//echo(\"DEBUG: a: Getting char to text...<br />\");\n\t\t\t$text .= $toparse[$i];\t\n\t\t\t}\n\t\t} else if($action == \"ac\") {\n\t\t\t//echo(\"DEBUG: Action: ac<br />\");\n\t\t\tif($subaction == \"code\") {\n\t\t\t\t//echo(\"DEBUG: ac: Subaction: code<br />\");\n\t\t\t\tif($toparse[$i] == \"]\") {\n\t\t\t\t\tif($subcode == \"/a\") {\n\t\t\t\t\t\t//echo(\"DEBUG: ac: Parsed end of a, executing function...<br />\");\n\t\t\t\t\t\t$output .= a($url, parse($text));\n\t\t\t\t\t\t//echo(\"DEBUG: ac: Clearing vars and switching back to parse...<br />\");\n\t\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t\t$subaction = \"\";\n\t\t\t\t\t\t$url = \"\";\n\t\t\t\t\t\t$text = \"\";\n\t\t\t\t\t\t$action = \"parse\";\n\t\t\t\t\t} else {\n\t\t\t\t\t//echo(\"DEBUG: ac: This code is not the end of a, adding to text and switching mode...<br />\");\n\t\t\t\t\t$text .= '[';\n\t\t\t\t\t$text .= $subcode;\n\t\t\t\t\t$text .= $toparse[$i];\n\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t$subaction = \"text\";\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t//echo(\"DEBUG: ac: Getting char to subcode...<br />\");\n\t\t\t\t$subcode .= $toparse[$i];\t\n\t\t\t\t}\n\t\t\t} else if($subaction == \"text\") {\n\t\t\t\t//echo(\"DEBUG: ac: Subaction: text<br />\");\n\t\t\t\tif($toparse[$i] == \"[\") {\n\t\t\t\t\t//echo(\"DEBUG: ac: Code detected, switching mode...<br />\");\n\t\t\t\t$subaction = \"code\";\n\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//echo(\"DEBUG: ac: Getting char to text...<br />\");\n\t\t\t$text .= $toparse[$i];\t\n\t\t\t} else if($subaction = \"url\") {\n\t\t\t\t//echo(\"DEBUG: ac: Subaction: url<br />\");\n\t\t\t\t//echo(\"CODE: \".$code.\"<br />\");\n\t\t\t\tfor($k = 2; $k < strlen($code); $k++) {\n\t\t\t\t\t//echo(\"DEBUG: ac: Reading url from code... (\".$k.\")<br />\");\n\t\t\t\t\t$url .= $code[$k];\n\t\t\t\t}\n\t\t\t\t//echo(\"DEBUG: ac: url reading finished, switching mode...<br />\");\n\t\t\t\t$subaction = \"text\";\n\t\t\t\t//echo(\"DEBUG: ac: Getting char to text...<br />\");\n\t\t\t\t$text .= $toparse[$i];\n\t\t\t}\n\t\t} else if($action == \"object\") {\n\t\t\t//echo(\"DEBUG: Action: object<br />\");\n\t\t\tif($subaction == \"code\") {\n\t\t\t\t//echo(\"DEBUG: object: Subaction: code<br />\");\n\t\t\t\tif($toparse[$i] == \"]\") {\n\t\t\t\t\tif($subcode == \"/object\") {\n\t\t\t\t\t\t//echo(\"DEBUG: object: Parsed end of object, executing function...<br />\");\n\t\t\t\t\t\t$output .= ob($type, parse($text));\n\t\t\t\t\t//\techo(\"DEBUG: object: Clearing vars and switching back to parse...<br />\");\n\t\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t\t$subaction = \"\";\n\t\t\t\t\t\t$type = \"\";\n\t\t\t\t\t\t$text = \"\";\n\t\t\t\t\t\t$action = \"parse\";\n\t\t\t\t\t} else {\n\t\t\t\t\t//echo(\"DEBUG: object: This code is not the end of object, adding to text and switching mode...<br />\");\t\n\t\t\t\t\t$text .= '[';\n\t\t\t\t\t$text .= $subcode;\n\t\t\t\t\t$text .= $toparse[$i];\n\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t$subaction = \"text\";\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t//echo(\"DEBUG: object: Getting char to subcode...<br />\");\n\t\t\t\t$subcode .= $toparse[$i];\t\n\t\t\t\t}\n\t\t\t} else if($subaction == \"text\") {\n\t\t\t\t//echo(\"DEBUG: object: Subaction: text<br />\");\n\t\t\t\tif($toparse[$i] == \"[\") {\n\t\t\t\t\t\t//echo(\"DEBUG: object: Code detected, switching mode...<br />\");\n\t\t\t\t$subaction = \"code\";\n\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//echo(\"DEBUG: object: Getting char to text...<br />\");\n\t\t\t$text .= $toparse[$i];\t\n\t\t\t} else if($subaction = \"type\") {\n\t\t\t\t//echo(\"DEBUG: object: Subaction: type<br />\");\n\t\t\t\tfor($k = 6; $k < strlen($code); $k++) {\n\t\t\t\t\t//echo(\"DEBUG: object: Reading type from code... (\".$k.\")<br />\");\n\t\t\t\t\t$type .= $code[$k];\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//echo(\"DEBUG: object: type reading finished, switching mode...<br />\");\n\t\t\t\t$subaction = \"text\";\n\t\t\t\t//echo(\"DEBUG: object: Getting char to text...<br />\");\n\t\t\t$text .= $toparse[$i];\n\t\t\t}\n\t\t} else if($action == \"color\") {\n\t\t\t//echo(\"DEBUG: Action: color<br />\");\n\t\t\tif($subaction == \"code\") {\n\t\t\t\t//echo(\"DEBUG: color: Subaction: code<br />\");\n\t\t\t\tif($toparse[$i] == \"]\") {\n\t\t\t\t\tif($subcode == \"/color\") {\n\t\t\t\t\t\t//echo(\"DEBUG: color: Parsed end of color, executing function...<br />\");\n\t\t\t\t\t\t$output .= col($col, parse($text));\n\t\t\t\t\t\t//echo(\"DEBUG: color: Clearing vars and switching back to parse...<br />\");\n\t\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t\t$subaction = \"\";\n\t\t\t\t\t\t$col = \"\";\n\t\t\t\t\t\t$text = \"\";\n\t\t\t\t\t\t$action = \"parse\";\n\t\t\t\t\t} else {\n\t\t\t\t\t//echo(\"DEBUG: color: This code is not the end of color, adding to text and switching mode...<br />\");\t\n\t\t\t\t\t$text .= '[';\n\t\t\t\t\t$text .= $subcode;\n\t\t\t\t\t$text .= $toparse[$i];\n\t\t\t\t\t$subcode = \"\";\n\t\t\t\t\t$subaction = \"text\";\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t//echo(\"DEBUG: color: Getting char to subcode...<br />\");\n\t\t\t\t$subcode .= $toparse[$i];\t\n\t\t\t\t}\n\t\t\t} else if($subaction == \"text\") {\n\t\t\t\t//echo(\"DEBUG: color: Subaction: text<br />\");\n\t\t\t\tif($toparse[$i] == \"[\") {\n\t\t\t\t\t\t//echo(\"DEBUG: color: Code detected, switching mode...<br />\");\n\t\t\t\t$subaction = \"code\";\n\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//echo(\"DEBUG: color: Getting char to text...<br />\");\n\t\t\t$text .= $toparse[$i];\t\n\t\t\t} else if($subaction = \"col\") {\n\t\t\t\t//echo(\"DEBUG: color: Subaction: col<br />\");\n\t\t\t\tfor($k = 6; $k < strlen($code); $k++) {\n\t\t\t\t\t//echo(\"DEBUG: color: Reading color from code... (\".$k.\")<br />\");\n\t\t\t\t\t$col .= $code[$k];\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//echo(\"DEBUG: color: color reading finished, switching mode...<br />\");\n\t\t\t\t$subaction = \"text\";\n\t\t\t\t//echo(\"DEBUG: color: Getting char to text...<br />\");\n\t\t\t$text .= $toparse[$i];\n\t\t\t}\n\t\t}\n\t}\n\t//echo(\"DEBUG: Function parse END <br /> OUTPUT: \".htmlspecialchars($output).\"<br />\");\n\treturn $output;\n}", "title": "" }, { "docid": "4c52ba0f83f91fd3d0caa8b229ce3921", "score": "0.6222238", "text": "public function parse() {\n\t\t\n\t\tHandler::set_parser($this);\n\t\t\n\t\t$node_namespace = Library::namespace_from_class(get_called_class()) . '\\\\' . 'nodes';\n\t\t$root_class = $node_namespace . '\\\\Node';\n\t\t$this->root = new $root_class;\n\t\t$this->root->set_from_parser($this);\n\t\t\n\t\t$this->context = $this->root;\n\t\t\n\t\t$this->line_number = 0;\n\t\t$this->indent_level = 0;\n\t\t\n\t\t$this->force_handler = false;\n\t\t$this->context_locked = false;\n\t\t\n\t\twhile(($this->content = $this->get_line()) !== false) {\n\t\t\t$this->line_number ++;\n\t\t\t\n\t\t\t$this->update_context();\n\t\t\t\n\t\t\tif($this->content = trim($this->content))\n\t\t\t\t$this->handle();\n\t\t}\n\t\t\n\t\tforeach(static::$handlers as $handler)\n\t\t\t$handler::reset();\n\t\t\n\t}", "title": "" }, { "docid": "f6a71fd2ef5a66df5a41018f94d6399e", "score": "0.61920846", "text": "public function getParser();", "title": "" }, { "docid": "302202f7b3b93543963d246ec2c26692", "score": "0.61886066", "text": "public function parse()\n {\n parent::parse();\n }", "title": "" }, { "docid": "dc0758f7c67c46b21afcc74b1dc03be1", "score": "0.6184776", "text": "function execParser($type,$data = array())\n\t{\n\t\tinclude_once(FCC_PATH.'parse_form.php');\n\t\t\n\t\t// add the parser function\n\t\tif ((is_object($this->execute)) and (method_exists($this->executeClass,\"preParser\")))\n\t\t\t$this->execute->preParser(); \n\t\t\n\t\tif (!is_object($this->parser))\n\t\t\t$this->parser = new fcc_parseForm;\n\t\t\n\t\tif (method_exists(\"fcc_parseForm\",$type))\n\t\t{\n\t\t\t$this->parser->$type($data);\t\t\t\n\t\t\t\n\t\t\t$this->error = $this->parser->error;\n\t\t\t$this->error_msg = $this->parser->error_msg;\n\t\t\t$this->error_input = $this->parser->error_input;\n\t\t}\n\t\telse\n\t\t{\t\t\t\n\t\t\tdie(\"cannot load fcc_parseForm::$type method\");\n\t\t}\n\t\t\n\t\tif ((is_object($this->execute)) and (method_exists($this->executeClass,\"postParser\")))\n\t\t\t$this->execute->postParser(); \n\n\t}", "title": "" }, { "docid": "25d8d98df7d59b66d9389c67ed0a6662", "score": "0.6179675", "text": "function parse($reload = false) {\n if ($this->parsed && !$reload) return;\n $str = $this->main;\n //check includes\n $str = $this->_includes($str, $this->data);\n //check blocks\n $str = $this->_blocks($str, $this->data);\n //check recursions\n $str = $this->_recursions($str, $this->data);\n //check standard achors\n $str = $this->_standards($str, $this->data);\n $this->parsed = true;\n $this->output = $str;\n }", "title": "" }, { "docid": "ea706cc407add23a9ed3bd6b692ed780", "score": "0.6082027", "text": "public function run() : void\n {\n // Parser options bind\n $options = $this->parser->options;\n\n // Create file for converted output\n $this->outputFile = Filesystem::createResource(\n basename($this->outputFilePath)\n );\n\n // Write header to converted output file based on standard\n Filesystem::writeLine(\n $this->outputFile,\n implode($this->delimiter, $this->getFieldsToImplode())\n );\n\n // Execute exporter\n $this->exporter->run();\n\n // Get the raw csv lines\n $lines = Filesystem::getLines($this->exporter->getTempFilePath());\n\n //Execute default steps\n $lines = self::cutTop($lines, $options->get('discard_top'));\n $lines = self::cutBottom($lines, $options->get('discard_bottom'));\n $lines = self::cutContains($lines, $options->get('discard_contains'));\n\n //Execute line sumarization rule\n $lines = $this->parser->summarizeLines($lines);\n\n //Run the parser logic implemented by the child\n $parsedLines = [];\n\n foreach ($lines as $lineSet) {\n // Detects the enf of file if set and exit\n if ($options->get('end_file_string') != '') {\n foreach ($lineSet as $line) {\n // Finalize file processing when string found\n if (Str::create($line)->contains($options->get('end_file_string'))) {\n // Exit run function\n return;\n }\n }\n }\n\n // if ($this->parser->options->get('mode') == 'dinamic') {\n // dd($lineSet);\n // }\n \n $parsedLines = $this->parser->parseLines($lineSet);\n\n // Detect if the line has contents parsed\n if ($parsedLines != []) {\n Filesystem::writeLine($this->outputFile, \"\\n\".$parsedLines);\n }\n }\n }", "title": "" }, { "docid": "0a7e9879992995131338d76b01197e44", "score": "0.60633075", "text": "function parse ()\n\t{\n\t\t$this->_tokenize();\n\t\treturn $this->_build();\n\t}", "title": "" }, { "docid": "a88f72b5a8981f2833d1ed17a263d177", "score": "0.6046691", "text": "public function main() {\n\t}", "title": "" }, { "docid": "c307c8b382784e650c031d6a95f5ea96", "score": "0.6046543", "text": "function parse($file)\n {\n }", "title": "" }, { "docid": "62d8f301d0d3b6355bae40264840f9fe", "score": "0.60122424", "text": "function parse (&$parse_data, $path, $base = 0, $packages = false)\n {\n global $_phpDocumentor_options;\n static $endrecur = 0;\n\n $this->setupStates();\n if (strlen($parse_data) == 0) {\n return false;\n }\n\n $this->configWordParser($parse_data);\n // initialize variables so E_ALL error_reporting doesn't complain\n $pevent = 0;\n $word = 0;\n\n $page = new ParserPage;\n $page->setSource($this->_wp->getFileSource());\n $page->setPath($path);\n $this->_path = $path;\n $page->setPackageOutput($packages);\n $page->setFile(basename($path));\n $this->publishEvent(PHPDOCUMENTOR_EVENT_NEWFILE, basename($path));\n //$name = str_replace(\"/\",\"_\",dirname($path)) . \"_\" \n // . array_shift(explode(\".\",$page->getFile()));\n // fc@fc.clever-soft.com 11/29/2001\n $name = str_replace(':', '', dirname($path)\n . PATH_DELIMITER . $page->getFile());\n $tmp = explode(PATH_DELIMITER, $name);\n $name = implode(\"---\", array_slice($tmp, $base));\n // if base is '', drive letter is present in windows\n\n $page->setName($name);\n $temploc = $_phpDocumentor_options['Program_Root'] \n . PATH_DELIMITER . implode(PATH_DELIMITER,\n array_slice(explode(PATH_DELIMITER, $path), $base));\n \n if ($temploc == $_phpDocumentor_options['Program_Root'] . PATH_DELIMITER) {\n $temploc .= $path;\n }\n \n $this->source_location = $source_location = $temploc;\n $page->setSourceLocation($source_location);\n\n $this->publishEvent(PHPDOCUMENTOR_EVENT_PAGE, $page);\n unset($page);\n do {\n $lpevent = $pevent;\n $pevent = $this->_event_stack->getEvent();\n if ($lpevent != $pevent) {\n $this->_last_pevent = $lpevent;\n }\n\n $this->publishEvent(PHPDOCUMENTOR_EVENT_NEWSTATE, ($pevent + 100));\n\n $this->_pv_last_word = $word;\n\n $word = $this->_wp->getWord();\n if (isset($this->_pv_findglobal) && $word == $this->_pv_findglobal) {\n $this->_last_pevent = $pevent;\n\n $this->_event_stack->pushEvent($pevent = PARSER_EVENT_DEFINE_GLOBAL);\n }\n // in wordparser, have to keep track of lines\n $this->publishEvent(PHPDOCUMENTOR_EVENT_NEWLINENUM, $this->_wp->linenum);\n if ($this->_pf_get_source) {\n if ($word[0] == T_FUNCTION) {\n $this->_wp->retrievesource($word);\n $this->_pf_get_source = false;\n $this->_pf_getting_source = true;\n }\n }\n\n if (PHPDOCUMENTOR_DEBUG == true) {\n echo \"LAST: \";\n if (is_array($this->_pv_last_word)) {\n echo token_name($this->_pv_last_word[0]) . ' => |' \n . htmlspecialchars($this->_pv_last_word[1]);\n } else {\n echo \"|\" . $this->_pv_last_word;\n }\n echo \"|\\n\";\n echo \"PEVENT: \" . $this->getParserEventName($pevent) . \"\\n\";\n echo \"LASTPEVENT: \"\n . $this->getParserEventName($this->_last_pevent) . \"\\n\";\n echo $this->_wp->getPos() . \": \";\n if (is_array($word)) {\n echo token_name($word[0]) . ' => |'\n . htmlspecialchars($word[1]);\n } else {\n echo '|' . htmlspecialchars($word);\n }\n echo \"|\\n-------------------\\n\\n\\n\";\n }\n\n // $this->_pf_getting_source && \n // ($pevent == PARSER_EVENT_DOCBLOCK) || \n // ($pevent == PARSER_EVENT_NOEVENTS))\n if (0) {\n addError(PDERROR_SOURCE_TAG_FUNCTION_NOT_FOUND);\n // throw away source\n $this->_wp->getSource();\n }\n if (isset($this->eventHandlers[$pevent])) {\n $handle = $this->eventHandlers[$pevent];\n $this->$handle($word, $pevent);\n } else {\n debug('WARNING: possible error, no handler for event number '\n . $pevent);\n if ($endrecur++ == 25) {\n die(\"FATAL ERROR, recursion limit reached\");\n }\n }\n } while (!($word === false));\n $this->publishEvent(PHPDOCUMENTOR_EVENT_NEWSTATE,\n PHPDOCUMENTOR_EVENT_END_PAGE);\n }", "title": "" }, { "docid": "9cd0401ea5f9e836844681a082367797", "score": "0.60024416", "text": "protected function executeMain() {}", "title": "" }, { "docid": "acfd4e6b9f79ccbbebcd916f8199dda4", "score": "0.59846467", "text": "public function parse()\n { \n $fileObject = $this->getFileObject();\n \n $childNodes = array();\n \n $tokens = array_reverse($this->getTokens($this->getFileContent()));\n foreach ($tokens as $token) {\n switch ($token->identify()) {\n case PhpScanner::T_NAMESPACE:\n \n break;\n case PhpScanner::T_USE_STATEMENT:\n\n break;\n case PhpScanner::T_AS_STATEMENT:\n \n break;\n case PhpScanner::T_INCLUDE_STATEMENT:\n \n break;\n case PhpScanner::T_CLASS_NAME:\n \n break;\n }\n }\n }", "title": "" }, { "docid": "498efa5b8792967cbe9d11d9aebaae9f", "score": "0.5982491", "text": "public function parse() {\n\t\t$this->run();\n\t\treturn $this->endOfStream();\n\t}", "title": "" }, { "docid": "41e18443cb02a77c8e40346ae15e4f8f", "score": "0.59805894", "text": "function Run()\n {\n $this->article =& new wikiArticle($this->GetTitle(), &$this->config);\n $this->article->Load();\n $this->article->Parse();\n }", "title": "" }, { "docid": "9e6096a8ef29e1fc172bedee239337f8", "score": "0.5976592", "text": "public static function main()\n {\n\n }", "title": "" }, { "docid": "15ce642e7f774fa9a7f5032d7b657e3d", "score": "0.59726673", "text": "public function program()\n\t{\n\t}", "title": "" }, { "docid": "f3f6a25f0cefc2778ed5074c07784ff5", "score": "0.5950031", "text": "function run() {\n $this->readinput();\n $this->process();\n }", "title": "" }, { "docid": "f3f6a25f0cefc2778ed5074c07784ff5", "score": "0.5950031", "text": "function run() {\n $this->readinput();\n $this->process();\n }", "title": "" }, { "docid": "e9e88d9c277b9f97d03043a907ba0c53", "score": "0.592152", "text": "public abstract function main();", "title": "" }, { "docid": "a0072caa27f16484e2710d76f551f0a8", "score": "0.5895306", "text": "function main() {\n\t\t$this->help();\n\t}", "title": "" }, { "docid": "a0072caa27f16484e2710d76f551f0a8", "score": "0.5895306", "text": "function main() {\n\t\t$this->help();\n\t}", "title": "" }, { "docid": "a8f48823df66066fbd906e9f7c2f3402", "score": "0.5872758", "text": "function main(array $argv, $argc) {\n\n\tglobal $flag_i, $flag_o, $flag_p, $flag_ni, $flag_m, $flag_nd, $flag_r;\n\tglobal $input_FoD, $output_F, $px_K, $mp_N;\n\tglobal $output;\n\tglobal $xmlWriter;\n\n\tcheck_parameters($argv, $argc);\n\n\t// open output file =====================================\n\tif ($flag_o == true) {\n\n\n\t\tif ($output_F == \"\") { // filename is not entered\n\t\t\terror(\"Output file name is not specified!\", 3);\n\t\t}\n\n\n\t\tif (file_exists($output_F)) { // filename is entered and it exists\n\t\t\tif (is_dir($output_F)==true) { // it is dir\n\t\t\t\terror(\"Output file cannot be a directory!\",3);\n\t\t\t}\n\t\t\telse { // it is file\n\t\t\t\t$fl=fopen($output_F, \"w\"); // can we open it for write ?\n\t\t\t\tif ($fl==NULL) { // no\n\t\t\t\t\terror(\"No access to output file\",3);\n\t\t\t\t}\n\t\t\t\telse { // yes\n\t\t\t\t\tfclose($fl);\n\t\t\t\t\t$bool=$xmlWriter->openURI($output_F);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\n\t\telse { // filename does not exists so we create the file\n\t\t\t$bool=$xmlWriter->openURI($output_F);\n\t\t}\n\n\n\t\tif ($bool==false) {\n\t\t\terror(\"Unable to create an output file!\", 3);\n\t\t}\n\n\n\t}\n\telse {\n\t\t$xmlWriter->openURI(\"php://stdout\");\n\t}\n\n\t// input examination ====================================\n\t$flag_dir=false;\n\tif ($flag_i == true) {\n\t\tif ($input_FoD == \"\") { // --input=(nothing)\n\t\t\terror(\"Input file or directory name (path) is not specified!\", 2);\n\t\t}\n\t\tif (is_dir($input_FoD)) {\n\t\t\t$flag_dir=true;\n\t\t\t$input=$input_FoD;\n\t\t\tstart_document();\n\t\t\tfinder($input, $flag_dir);\n\t\t}\n\t\telse {\n\t\t\tif (is_file($input_FoD)) {\n\t\t\t\tif (is_readable($input_FoD)==false) {\n\t\t\t\t\terror(\"Input file is not readable!\",2);\n\t\t\t\t}\n\t\t\t\t$input=$input_FoD;\n\t\t\t\tstart_document();\n\t\t\t\tfinder($input, $flag_dir);\n\t\t\t}\n\t\t\telse {\n\t\t\t\terror(\"File or directory does not exist!\", 2);\n\t\t\t}\n\t\t}\n\t}\n\telse {\n\t\t$flag_dir=true;\n\t\t$input=__DIR__;\n\t\tstart_document();\n\t\tfinder($input, $flag_dir);\n\t}\n\n\n\n\t// end for <function dir\"\">\n\t// </functions>\n\t$xmlWriter->writeRaw(\"\");\n\t$xmlWriter->endElement();\n\n\n\n\t// write to output ========================================\n\t$xmlWriter->flush();\n\n\n\n\texit(0);\n}", "title": "" }, { "docid": "c1d911e7c26f9c7e2225a7d7f19680d5", "score": "0.58405834", "text": "private function parse() {\n\t\tif (!empty(self::$config)) {\n\t\t\treturn;\n\t\t}\n\n\t\t$callback = array(\n\t\t\t$this,\n\t\t\t'parseFiles'\n\t\t);\n\t\tarray_walk($this->configPath, $callback);\n\t\tarray_walk($this->overwritePath, $callback);\n\n\t\t$this->parser->setUsedStaging($this->staging);\n\t\t$this->parser->setUseFileNameAsKey($this->useFileNameAsKey);\n\n\t\t$this->parser->directory($this->defaultFiles);\n\t\t$this->parser->directory($this->overwriteFiles);\n\t}", "title": "" }, { "docid": "8bfb73dbe48c2d2a311760f86e1d7480", "score": "0.5817659", "text": "final private function parse($parse)\n\t{\n\t\t$this->debug(\"Parsing Start<br /> <hr /><hr /><hr />\");\n\t\t\n\t\t$parse = $this->stripPrecedingWhitespace($parse);\n\t\t\n\t\twhile($parse = $this->parseString($parse))\n\t\t{\n\t\t\t$parse = $this->parseTag($parse);\n\t\t}\n\t\t$this->debug(\"Parsing Complete<br /> <hr /><hr /><hr />\");\n\t}", "title": "" }, { "docid": "d5d50360a9b6fe95729688df759a28f1", "score": "0.58148015", "text": "function parse() {\n\n do {\n $oldText = ($this->wiki->source);\n if ($this->regex) {\n $this->wiki->source = preg_replace_callback($this->regex, array(\n &$this,\n 'process'), $this->wiki->source);\n }\n } while ($oldText !== $this->wiki->source);\n }", "title": "" }, { "docid": "d1675d8830c1542b1dd910f7a864ea40", "score": "0.5810876", "text": "public function parse() {\n $this->checkMessage();\n $this->preParseAll();\n $this->checkRequiredFields();\n $this->checkValidateFunctions();\n }", "title": "" }, { "docid": "e031e8667f20b1f0ca37bbf9d7d73e1c", "score": "0.58080214", "text": "public function main() {\n\t\t$this->help();\n\t}", "title": "" }, { "docid": "f2f4e75dd3b26980814e75b74a647b8f", "score": "0.5798032", "text": "public function run()\n {\n $config = new LexerConfig();\n $config->setDelimiter(',');\n $lexer = new Lexer($config);\n $interpreter = new Interpreter();\n $interpreter->addObserver(function(array $row) {\n $record = [\n 'name' => array_shift($row),\n 'is_custom' => array_shift($row),\n ];\n\n $skillset = Skillset::create($record);\n $skillset->save();\n $skillset->skills()->sync(array_filter($row));\n });\n\n $lexer->parse(base_path().self::PATH, $interpreter);\n }", "title": "" }, { "docid": "8a4030c6d0af2ea798a3beaa59cf48ef", "score": "0.5789027", "text": "public function run()\n {\n $multiline = '';\n $is_multiline = 0;\n\n while (true) {\n $line = readline('magento > ');\n $linereverse = strrev( $line );\n if($linereverse[0] != ';') {\n $is_multiline = 1;\n }\n if(!$is_multiline){\n if ($line == 'exit') {\n $this->quit();\n }\n if ($line == 'help') {\n\n $this->usageHelp();\n }\n if (!empty($line)) {\n $this->addToHistory($line);\n eval($line);\n echo \"\\n\";\n }\n }else {\n if($linereverse[0] == '}'){\n $multiline .= ' '. $line;\n\n $this->addToHistory($multiline);\n eval($multiline);\n $multiline ='';\n $is_multiline = 0;\n\n echo \"\\n\";\n }else{\n $multiline .= ' '. $line;\n }\n }\n\n }\n }", "title": "" }, { "docid": "626839d0363b5ee6e1e14c378a11afac", "score": "0.5787887", "text": "function SAXY_Parser() {\r\n\t\t$this->SAXY_Parser_Base();\r\n\t\t$this->state = SAXY_STATE_PROLOG_NONE;\r\n\t}", "title": "" }, { "docid": "33dc48794a69e08ad2dc24dc3c884ee0", "score": "0.5769914", "text": "public function parse() {\n if(empty($this->return))\n return null;\n\n preg_match_all('|File stem \\<(.*)\\>|',$this->return,$this->fonctions);\n\n // Extract tree\n $start = strpos($this->return, 'Decision Tree:')+15;\n $end = strpos($this->return, 'Simplified Decision Tree:');\n $tree = trim(substr($this->return, $start, ($end-$start)));\n $tree = preg_replace('|(\\(.*\\))|','',$tree);\n\n // Generate functions\n $lines = explode(\"\\n\",$tree);\n $levelCurrent = -1;\n\n $this->php .= 'function ' . $this->functions[1][0] . '() { ' . \"\\n\";\n\n foreach($lines as $line) {\n $level = substr_count($line, '|');\n $purge = trim(str_replace('|','',$line));\n $words = explode(' ',$purge);\n $last = count($words)-1;\n\n // New level of the tree\n if($level != $levelCurrent) {\n if($level < $levelCurrent) {\n for($t = 1; $t < $level; $t++)\n $this->php .= \"\\t\";\n $dif = $levelCurrent-$level;\n for($t = 0; $t < $dif; $t++) {\n for($c = 1; $c < $level-$t; $c++)\n $this->php .= \"\\t\";\n $this->php .= ' } ';\n }\n }\n $levelCurrent = $level;\n }\n\n // Detecting the type of condition\n if((string) intval($words[$last]) != $words[$last]) {\n foreach($words as $i => $word) {\n if(strpos($word, '>') !== false || strpos($word, '=') !== false || strpos($word, '<') !== false) {\n $var = $words[($i-1)];\n $condition = $word;\n $verif = str_replace(':','',$words[($i+1)]);\n for($t = 1; $t < $levelCurrent; $t++)\n $this->php .= \"\\t\";\n $this->php .= 'if($' . $var . ' ' . $condition . ' ' . $verif . ') { ' . \"\\n\";\n\n }\n }\n }\n else {\n foreach($words as $i => $word) {\n if(strpos($word, '>') !== false || strpos($word, '=') !== false || strpos($word, '<') !== false) {\n $var = $words[($i-1)];\n $condition = $word;\n $verif = str_replace(':','',$words[($i+1)]);\n if(!isset($words[($i+3)])) {\n $val = str_replace(':','',$words[($i+2)]);\n } else {\n $val = str_replace(':','',$words[($i+3)]);\n }\n\n for($t = 1; $t < $levelCurrent; $t++)\n $this->php .= \"\\t\";\n $this->php .= 'if($' . $var . ' ' . $condition . ' ' . $verif . ') { return ' . $val . '; }' . \"\\n\";\n\n }\n }\n }\n }\n\n // Close conditions\n for($t = 0; $t < $levelCurrent; $t++) {\n for($c = 1; $c < $level-$t; $c++)\n $this->php .= \"\\t\";\n $this->php .= ' } ';\n }\n $this->php .= '}';\n\n return $this;\n }", "title": "" }, { "docid": "6778e46589ade0a5a210387b46aaafd2", "score": "0.5739816", "text": "function parserHook( $input, $args, &$parser ) \n\t\t{\n $output = $parser->parse( $input, $parser->mTitle, $parser->mOptions, false, false );\n return $output->getText();\n }", "title": "" }, { "docid": "35c64e4a4a1b928b7757d8f5b98a1489", "score": "0.57343185", "text": "public function main() {\n\t\t$this->processField();\n\t}", "title": "" }, { "docid": "1054409b796e7b5267547dbd8d715a5c", "score": "0.5718537", "text": "abstract public function parse($arg);", "title": "" }, { "docid": "f355bb30af397aa98694970e528cf341", "score": "0.570766", "text": "public function execute() {\n\n\t\tif (!$this->isOn()) {\n\t\t\t$this->getController()->addOutput(ucfirst($this->getRequest()->action) . \" is off\");\n\t\t\treturn;\n\t\t}\n\n\t\t$possibleOptions = array(\n\t\t\t'type' => false,\n\t\t\t'parser' => false,\n\t\t\t'path' => true,\n\t\t\t'backup' => true, // backup path\n\t\t);\n\n\t\tif (($options = $this->getController()->getInstanceOptions($possibleOptions)) === FALSE) {\n\t\t\treturn;\n\t\t}\n\n\t\t$this->_controller->addOutput(\"Parser selected: \" . $options['parser']);\n\t\t//$options['parser'] = Billrun_Parser::getInstance(array('type' => $options['parser']));\n\n\t\t$this->_controller->addOutput(\"Loading processor\");\n\t\t$processor = Billrun_Processor::getInstance($options);\n\t\t$this->_controller->addOutput(\"Processor loaded\");\n\n\t\tif ($processor) {\n\t\t\t$this->_controller->addOutput(\"Starting to process. This action can take a while...\");\n\t\t\t// buffer all action output\n\t\t\tob_start();\n\t\t\tif (isset($options['path']) && $options['path']) {\n\t\t\t\t$linesProcessedCount = $processor->process();\n\t\t\t} else {\n\t\t\t\t$linesProcessedCount = $processor->process_files();\n\t\t\t}\n\t\t\t// write the buffer into log and output\n\t\t\t$this->_controller->addOutput(\"processed \" . $linesProcessedCount . \" lines\");\n\t\t\t$this->_controller->addOutput(ob_get_contents());\n\t\t\tob_end_clean();\n\t\t} else {\n\t\t\t$this->_controller->addOutput(\"Processor cannot be loaded\");\n\t\t}\n\t}", "title": "" }, { "docid": "b38cbeee4ed8b4de0544394aa4e6a53d", "score": "0.5702804", "text": "public function action_parse() {\n $command = isset($_GET['command']) ? trim($_GET['command']) : null;\n $defaultCommand = isset($_GET['default']) ? trim($_GET['default']) : null;\n if (strlen($command) == 0) {\n $this->redirectTo('/');\n }\n // According to the access log, Yahoo Pipes seems to be bringing the site down. [Jon Aquino 2009-07-03]\n if (strpos($_SERVER['HTTP_USER_AGENT'], 'Yahoo Pipes') > -1) {\n header('HTTP/1.0 403 Forbidden');\n echo 'YubNub is currently blocking Yahoo Pipes. Contact jonathan.aquino@gmail.com for more info.';\n exit;\n }\n $parser = new Parser();\n $this->redirectTo($parser->parse($command, $defaultCommand));\n }", "title": "" }, { "docid": "443cd49da9db83887103a544d85a918f", "score": "0.57000184", "text": "function parse(){\n\t\tif (is_null($this->template)){\n\t\t\treturn \"ERROR\";\n\t\t}\n\t\t$this->loginout();\n\t\t$this->incfiles();\n\t\t$this->loginout();\n\t\t//$this->conditions();\n\t\t$this->loop();\n\t\t\n\t\t$this->tags($this->template);\n\t\t\n\t\t$this->template = $this->template->replace('{#', '{$');\n\t\treturn $this->template->toString();\n\t}", "title": "" }, { "docid": "914cb189d4ef591008a53db5a6e1d0c4", "score": "0.57000107", "text": "function exec() {\n\t\t$purl = $this->parsed();\n\t\t\n\t\t// ****** Handling variables\n\t\t$handler = array($this, 'page');\n\t\t$matchindex = 0;\n\t\t\n\t\t// ****** Match\n\t\t$file = '';\n\t\t\n\t\tif (is_array($purl) && isset($purl[0]) && $purl[0] != '') {\n\t\t\t// *** Check for matches\n\t\t\tfor ($i = sizeof($purl); $i > 0; $i--) {\n\t\t\t\t$name = join('.', array_slice($purl, 0, $i));\n\t\t\t\t$path = $this->path . $name . '.php';\n\t\t\t\t\n\t\t\t\tif (file_exists($path)) {\n\t\t\t\t\t// *** Use the file handler\n\t\t\t\t\t$matchindex = $i;\n\t\t\t\t\t$i = false;\n\t\t\t\t} else {\n\t\t\t\t\t// ****** Check for an entry in the bind array\n\t\t\t\t\t$name = join('/', array_slice($purl, 0, $i));\n\t\t\t\t\tif (isset($this->binds[$name])) {\n\t\t\t\t\t\t// *** Use the bound handler\n\t\t\t\t\t\t$handler = $this->binds[$name];\n\t\t\t\t\t\t$matchindex = $i;\n\t\t\t\t\t\t$i = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// *** No handler specified, at any level\n\t\t\tif ($matchindex == 0) {\n\t\t\t\t$purl = array_merge(array('404'), $purl);\n\t\t\t\t$matchindex = 1;\n\t\t\t}\n\t\t} else {\n\t\t\t// *** Open the index\n\t\t\t$purl = array('index');\n\t\t\t$matchindex = 1;\n\t\t}\n\t\t\n\t\t// ****** Handle!\n\t\t$this->handle($handler, $purl, $matchindex);\n\t}", "title": "" }, { "docid": "481f3ee20b2f03db9c295b7e1e51c558", "score": "0.5681472", "text": "public function main() {\n\t\t// Check post data\n\t\t$this->post_data_check();\n\n\t\t// Check virtual page\n\t\t$this->virtual_page();\n\n\t\t// Adds new fields to profile page\n\t\t$this->profile_additions();\n\n\t\t// Pull in rest calls\n\t\t$this->rest_api();\n }", "title": "" }, { "docid": "38f42a954277304ed6552bb796e0bfe2", "score": "0.5674095", "text": "public function parse() {\n return $this->parser->parse(); \n }", "title": "" }, { "docid": "771b1741039348f09c4f4429908a2320", "score": "0.56639624", "text": "abstract public function parse($input);", "title": "" }, { "docid": "793f828f035c0af5342b6eea4c4d4830", "score": "0.5663958", "text": "public function parse()\n {\n\n // passed arguments are available in the $GLOBALS array\n $params = implode(\" \", $GLOBALS['argv']);\n\n\n// replace by a single value, not to replace but to match corresponding parameters to corresponding values\n//$params = preg_replace('/\\-{1,2}[a-zA-z]+ *= */','|', $params);\n\n $params = preg_match_all(\n '/'.\n // parameter is any item having beginning with 1-2 dashes, but not having a 3rd one before\n // followed by alpha characters (perhaps add numerical) followed by arbitrary number of spaces\n // or having an equal sign after\n '( (?<!-)\\-{1,2}[a-zA-z]+ *=? *)'.\n\n // do not accept even the first dash, value cannot accept dash and ends up when a new dash begins\n // so cant contain and cannot be followed by a one, maybe should except space too\n '([^-]*(?!\\-)+'.\n // value, not followed by -\n //'(?!\\-)'.\n ')/',\n $params,\n $matches\n );\n\n\n // matches[1] = params, left side , matches[2] = params right side\n // trims every element by a character in another array passed as a 3rd parameter with pregenerated ' ' values\n $params = array_map('trim', $matches[1], array_fill(0,count($matches[1]),' '));\n\n\n// params , left side , paramL=valueR\n foreach ($params as &$param) {\n // workaround the above regexp allowed params like --p, whereas it should allow only -p, or full size --param\n // remove single letter params with double dash prefix , the regexp should be remade to this not complicately\n if (strpos($param, \"--\") !== false && strlen($param)<=5){\n echo $param.\" \\n\\n\\n\\n\";\n //unset($el);\n $param = \"\";\n }\n }\n\n\n\n // trim any dashes from all the array elements, to have params in array ['-p','--directory'] => ['p', 'directory']\n $params = array_map('trim', $params, array_fill(0, count($params),'-'));\n // make param names indexes of an array\n // [0=>'p', 1=>'directory'] => ['p'=>'0', 'directory'=>'1']\n $params = array_flip($params);\n\n\n // map params (params' indexes) to their values ['p'=>'0', 'directory'=>'1'] = > ['p'=>'pParam', 'directory'=>'directoryParam']\n foreach ($params as $paramName => $paramIndex) {\n\n // if a param was removed (became empty) as incorrect double dash -- usage for shortened parameters\n if (empty($paramName)) {\n continue;\n }\n\n $params[$paramName] = $matches[2][$paramIndex];\n\n }\n $params = $this->mapParamsWithShortFlags($params);\n\n\n return $params;\n }", "title": "" }, { "docid": "1a5b9432087d0e25456d9fa9fb8d76fb", "score": "0.5662805", "text": "public function main()\n {\n $projectFile = '../project.yml';\n\n $projectConfig = App::loadYmlFileEx($projectFile);\n $apps = array_try_get($projectConfig, 'app', []);\n $dbServers = array_try_get($projectConfig, 'db_server', []);\n\n foreach ($dbServers as &$server)\n {\n $this->_setDbServerDefaultSettings($server);\n }\n $this->_dbServers = $dbServers;\n\n foreach ($apps as $appName => $appconfig)\n {\n $this->_processApp($appName, $appconfig);\n }\n }", "title": "" }, { "docid": "b23277a62b6925a89ef5b085027d297c", "score": "0.5640534", "text": "public function run()\n {\n\t\t\n require_once(dirname(__FILE__) . '/php/elFinder.class.php');\n $fm = new elFinder($this->settings);\n $fm->run();\n\n }", "title": "" }, { "docid": "a6decbbf30797665cf885c537febe507", "score": "0.5640446", "text": "public function parse() {\n ## remove empty lines\n if (trim($this->code) == '') return 1;\n\n $t = token_get_all('<?php '.$this->code.' ?>');\n \n $need_semicolon = 1; /* do we need a semicolon to complete the statement ? */\n $need_return = 1; /* can we prepend a return to the eval-string ? */\n $open_comment = 0; /* a open multi-line comment */\n $eval = ''; /* code to be eval()'ed later */\n $braces = array(); /* to track if we need more closing braces */\n\n $methods = array(); /* to track duplicate methods in a class declaration */\n $ts = array(); /* tokens without whitespaces */\n\n foreach ($t as $ndx => $token) {\n if (is_array($token)) {\n $ignore = 0;\n \n switch($token[0]) {\n case T_WHITESPACE:\n case T_OPEN_TAG:\n case T_CLOSE_TAG:\n $ignore = 1;\n break;\n case T_FOREACH:\n case T_DO:\n case T_WHILE:\n case T_FOR:\n\n case T_IF:\n case T_RETURN:\n \n case T_CLASS:\n case T_FUNCTION:\n case T_INTERFACE:\n\n case T_PRINT:\n case T_ECHO:\n\n case T_COMMENT:\n case T_UNSET:\n\n case T_INCLUDE:\n case T_REQUIRE:\n case T_INCLUDE_ONCE:\n case T_REQUIRE_ONCE:\n case T_TRY:\n case T_SWITCH:\n case T_DEFAULT:\n case T_CASE:\n case T_BREAK:\n case T_DOC_COMMENT:\n $need_return = 0;\n break;\n case T_EMPTY:\n case T_ISSET:\n case T_EVAL:\n case T_EXIT:\n\n case T_VARIABLE:\n case T_STRING:\n case T_NEW:\n case T_EXTENDS:\n case T_IMPLEMENTS:\n case T_OBJECT_OPERATOR:\n case T_DOUBLE_COLON:\n case T_INSTANCEOF:\n\n case T_CATCH:\n case T_THROW:\n\n case T_ELSE:\n case T_AS:\n case T_LNUMBER:\n case T_DNUMBER:\n case T_CONSTANT_ENCAPSED_STRING:\n case T_ENCAPSED_AND_WHITESPACE:\n case T_CHARACTER:\n case T_ARRAY:\n case T_DOUBLE_ARROW:\n\n case T_CONST:\n case T_PUBLIC:\n case T_PROTECTED:\n case T_PRIVATE:\n case T_ABSTRACT:\n case T_STATIC:\n case T_VAR:\n\n case T_INC:\n case T_DEC:\n case T_SL:\n case T_SL_EQUAL:\n case T_SR:\n case T_SR_EQUAL:\n\n case T_IS_EQUAL:\n case T_IS_IDENTICAL:\n case T_IS_GREATER_OR_EQUAL:\n case T_IS_SMALLER_OR_EQUAL:\n \n case T_BOOLEAN_OR:\n case T_LOGICAL_OR:\n case T_BOOLEAN_AND:\n case T_LOGICAL_AND:\n case T_LOGICAL_XOR:\n case T_MINUS_EQUAL:\n case T_PLUS_EQUAL:\n case T_MUL_EQUAL:\n case T_DIV_EQUAL:\n case T_MOD_EQUAL:\n case T_XOR_EQUAL:\n case T_AND_EQUAL:\n case T_OR_EQUAL:\n\n case T_FUNC_C:\n case T_CLASS_C:\n case T_LINE:\n case T_FILE:\n\n case T_BOOL_CAST:\n case T_INT_CAST:\n case T_STRING_CAST:\n\n /* just go on */\n break;\n default:\n /* debug unknown tags*/\n error_log(sprintf(\"unknown tag: %d (%s): %s\".PHP_EOL, $token[0], token_name($token[0]), $token[1]));\n \n break;\n }\n if (!$ignore) {\n $eval .= $token[1].\" \";\n $ts[] = array(\"token\" => $token[0], \"value\" => $token[1]);\n }\n } else {\n $ts[] = array(\"token\" => $token, \"value\" => '');\n\n $last = count($ts) - 1;\n\n switch ($token) {\n case '(':\n /* walk backwards through the tokens */\n\n if ($last >= 4 &&\n $ts[$last - 1]['token'] == T_STRING &&\n $ts[$last - 2]['token'] == T_OBJECT_OPERATOR &&\n $ts[$last - 3]['token'] == ')' ) {\n /* func()->method()\n * \n * we can't know what func() is return, so we can't \n * say if the method() exists or not\n * \n */\n } else if ($last >= 3 &&\n $ts[0]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[0]['token'] != T_ABSTRACT && /* if we are not in a class definition */\n $ts[1]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[$last - 1]['token'] == T_STRING &&\n $ts[$last - 2]['token'] == T_OBJECT_OPERATOR &&\n $ts[$last - 3]['token'] == T_VARIABLE ) {\n\n /* $object->method( */\n\n /* catch (Exception $e) does not set $e in $GLOBALS[] */\n $in_catch = 0;\n\n foreach ($ts as $v) {\n if ($v['token'] == T_CATCH) {\n $in_catch = 1;\n }\n }\n\n if (!$in_catch) {\n /* $object has to exist and has to be a object */\n $objname = $ts[$last - 3]['value'];\n \n if (!isset($GLOBALS[ltrim($objname, '$')])) {\n throw new Exception(sprintf('Variable \\'%s\\' is not set', $objname));\n }\n $object = $GLOBALS[ltrim($objname, '$')];\n \n if (!is_object($object)) {\n throw new Exception(sprintf('Variable \\'%s\\' is not a class', $objname));\n }\n \n $method = $ts[$last - 1]['value'];\n\n /* obj */\n \n if (!method_exists($object, $method)) {\n throw new Exception(sprintf(\"Variable %s (Class '%s') doesn't have a method named '%s'\", \n $objname, get_class($object), $method));\n }\n }\n } else if ($last >= 3 &&\n $ts[0]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[$last - 1]['token'] == T_VARIABLE &&\n $ts[$last - 2]['token'] == T_OBJECT_OPERATOR &&\n $ts[$last - 3]['token'] == T_VARIABLE ) {\n\n /* $object->$method( */\n\n /* $object has to exist and has to be a object */\n $objname = $ts[$last - 3]['value'];\n \n if (!isset($GLOBALS[ltrim($objname, '$')])) {\n throw new Exception(sprintf('Variable \\'%s\\' is not set', $objname));\n }\n $object = $GLOBALS[ltrim($objname, '$')];\n\n if (!is_object($object)) {\n throw new Exception(sprintf('Variable \\'%s\\' is not a class', $objname));\n }\n \n $methodname = $ts[$last - 1]['value'];\n\n if (!isset($GLOBALS[ltrim($methodname, '$')])) {\n throw new Exception(sprintf('Variable \\'%s\\' is not set', $methodname));\n }\n $method = $GLOBALS[ltrim($methodname, '$')];\n\n /* obj */\n \n if (!method_exists($object, $method)) {\n throw new Exception(sprintf(\"Variable %s (Class '%s') doesn't have a method named '%s'\", \n $objname, get_class($object), $method));\n }\n\n } else if ($last >= 6 &&\n $ts[0]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[$last - 1]['token'] == T_STRING &&\n $ts[$last - 2]['token'] == T_OBJECT_OPERATOR &&\n $ts[$last - 3]['token'] == ']' &&\n /* might be anything as index */\n $ts[$last - 5]['token'] == '[' &&\n $ts[$last - 6]['token'] == T_VARIABLE ) {\n\n /* $object[...]->method( */\n\n /* $object has to exist and has to be a object */\n $objname = $ts[$last - 6]['value'];\n \n if (!isset($GLOBALS[ltrim($objname, '$')])) {\n throw new Exception(sprintf('Variable \\'%s\\' is not set', $objname));\n }\n $array = $GLOBALS[ltrim($objname, '$')];\n\n if (!is_array($array)) {\n throw new Exception(sprintf('Variable \\'%s\\' is not a array', $objname));\n }\n\n $andx = $ts[$last - 4]['value'];\n\n if (!isset($array[$andx])) {\n throw new Exception(sprintf('%s[\\'%s\\'] is not set', $objname, $andx));\n }\n\n $object = $array[$andx];\n\n if (!is_object($object)) {\n throw new Exception(sprintf('Variable \\'%s\\' is not a class', $objname));\n }\n \n $method = $ts[$last - 1]['value'];\n\n /* obj */\n \n if (!method_exists($object, $method)) {\n throw new Exception(sprintf(\"Variable %s (Class '%s') doesn't have a method named '%s'\", \n $objname, get_class($object), $method));\n }\n\n } else if ($last >= 3 &&\n $ts[0]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[$last - 1]['token'] == T_STRING &&\n $ts[$last - 2]['token'] == T_DOUBLE_COLON &&\n $ts[$last - 3]['token'] == T_STRING ) {\n\n /* Class::method() */\n\n /* $object has to exist and has to be a object */\n $classname = $ts[$last - 3]['value'];\n \n if (!class_exists($classname)) {\n throw new Exception(sprintf('Class \\'%s\\' doesn\\'t exist', $classname));\n }\n \n $method = $ts[$last - 1]['value'];\n\n if (!in_array($method, get_class_methods($classname))) {\n throw new Exception(sprintf(\"Class '%s' doesn't have a method named '%s'\", \n $classname, $method));\n }\n } else if ($last >= 3 &&\n $ts[0]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[$last - 1]['token'] == T_VARIABLE &&\n $ts[$last - 2]['token'] == T_DOUBLE_COLON &&\n $ts[$last - 3]['token'] == T_STRING ) {\n\n /* $var::method() */\n\n /* $object has to exist and has to be a object */\n $classname = $ts[$last - 3]['value'];\n \n if (!class_exists($classname)) {\n throw new Exception(sprintf('Class \\'%s\\' doesn\\'t exist', $classname));\n }\n \n $methodname = $ts[$last - 1]['value'];\n\n if (!isset($GLOBALS[ltrim($methodname, '$')])) {\n throw new Exception(sprintf('Variable \\'%s\\' is not set', $methodname));\n }\n $method = $GLOBALS[ltrim($methodname, '$')];\n\n if (!in_array($method, get_class_methods($classname))) {\n throw new Exception(sprintf(\"Class '%s' doesn't have a method named '%s'\", \n $classname, $method));\n }\n\n } else if ($last >= 2 &&\n $ts[0]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[$last - 1]['token'] == T_STRING &&\n $ts[$last - 2]['token'] == T_NEW ) {\n\n /* new Class() */\n\n /* don't care about this in a class ... { ... } */\n\n $classname = $ts[$last - 1]['value'];\n\n if (!class_exists($classname)) {\n throw new Exception(sprintf('Class \\'%s\\' doesn\\'t exist', $classname));\n }\n\n $r = new ReflectionClass($classname);\n\n if ($r->isAbstract()) {\n throw new Exception(sprintf(\"Can't instantiate abstract Class '%s'\", $classname));\n }\n\n if (!$r->isInstantiable()) {\n throw new Exception(sprintf('Class \\'%s\\' can\\'t be instantiated. Is the class abstract ?', $classname));\n }\n\n } else if ($last >= 2 &&\n $ts[0]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[$last - 1]['token'] == T_STRING &&\n $ts[$last - 2]['token'] == T_FUNCTION ) {\n\n /* make sure we are not a in class definition */\n\n /* function a() */\n\n $func = $ts[$last - 1]['value'];\n\n if (function_exists($func)) {\n throw new Exception(sprintf('Function \\'%s\\' is already defined', $func));\n }\n } else if ($last >= 4 &&\n $ts[0]['token'] == T_CLASS &&\n $ts[1]['token'] == T_STRING &&\n $ts[$last - 1]['token'] == T_STRING &&\n $ts[$last - 2]['token'] == T_FUNCTION ) {\n\n /* make sure we are not a in class definition */\n\n /* class a { .. function a() ... } */\n\n $func = $ts[$last - 1]['value'];\n $classname = $ts[1]['value'];\n\n if (isset($methods[$func])) {\n throw new Exception(sprintf(\"Can't redeclare method '%s' in Class '%s'\", $func, $classname));\n }\n\n $methods[$func] = 1;\n\n } else if ($last >= 1 &&\n $ts[0]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[0]['token'] != T_ABSTRACT && /* if we are not in a class definition */\n $ts[1]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[$last - 1]['token'] == T_STRING ) {\n /* func() */\n $funcname = $ts[$last - 1]['value'];\n \n if (!function_exists($funcname)) {\n throw new Exception(sprintf(\"Function %s() doesn't exist\", $funcname));\n }\n } else if ($last >= 1 &&\n $ts[0]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[$last - 1]['token'] == T_VARIABLE ) {\n \n /* $object has to exist and has to be a object */\n $funcname = $ts[$last - 1]['value'];\n \n if (!isset($GLOBALS[ltrim($funcname, '$')])) {\n throw new Exception(sprintf('Variable \\'%s\\' is not set', $funcname));\n }\n $func = $GLOBALS[ltrim($funcname, '$')];\n\n if (!function_exists($func)) {\n throw new Exception(sprintf(\"Function %s() doesn't exist\", $func));\n }\n\n }\n \n array_push($braces, $token);\n break;\n case '{':\n $need_return = 0;\n\n if ($last >= 2 &&\n $ts[$last - 1]['token'] == T_STRING &&\n $ts[$last - 2]['token'] == T_CLASS ) {\n\n /* class name { */\n\n $classname = $ts[$last - 1]['value'];\n\n if (class_exists($classname, false)) {\n throw new Exception(sprintf(\"Class '%s' can't be redeclared\", $classname));\n }\n } else if ($last >= 4 &&\n $ts[$last - 1]['token'] == T_STRING &&\n $ts[$last - 2]['token'] == T_EXTENDS &&\n $ts[$last - 3]['token'] == T_STRING &&\n $ts[$last - 4]['token'] == T_CLASS ) {\n\n /* class classname extends classname { */\n\n $classname = $ts[$last - 3]['value'];\n $extendsname = $ts[$last - 1]['value'];\n\n if (class_exists($classname, false)) {\n throw new Exception(sprintf(\"Class '%s' can't be redeclared\", \n $classname));\n }\n if (!class_exists($extendsname, true)) {\n throw new Exception(sprintf(\"Can't extend '%s' ... from not existing Class '%s'\", \n $classname, $extendsname));\n }\n } else if ($last >= 4 &&\n $ts[$last - 1]['token'] == T_STRING &&\n $ts[$last - 2]['token'] == T_IMPLEMENTS &&\n $ts[$last - 3]['token'] == T_STRING &&\n $ts[$last - 4]['token'] == T_CLASS ) {\n\n /* class name implements interface { */\n\n $classname = $ts[$last - 3]['value'];\n $implements = $ts[$last - 1]['value'];\n\n if (class_exists($classname, false)) {\n throw new Exception(sprintf(\"Class '%s' can't be redeclared\", \n $classname));\n }\n if (!interface_exists($implements, false)) {\n throw new Exception(sprintf(\"Can't implement not existing Interface '%s' for Class '%s'\", \n $implements, $classname));\n }\n }\n\n array_push($braces, $token);\n break;\n case '}':\n $need_return = 0;\n case ')':\n array_pop($braces);\n break;\n case '[':\n if ($ts[0]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[0]['token'] != T_ABSTRACT && /* if we are not in a class definition */\n $ts[1]['token'] != T_CLASS && /* if we are not in a class definition */\n $ts[$last - 1]['token'] == T_VARIABLE) {\n /* $a[] only works on array and string */\n\n /* $object has to exist and has to be a object */\n $objname = $ts[$last - 1]['value'];\n \n if (!isset($GLOBALS[ltrim($objname, '$')])) {\n throw new Exception(sprintf('Variable \\'%s\\' is not set', $objname));\n }\n $obj = $GLOBALS[ltrim($objname, '$')];\n\n if (is_object($obj)) {\n throw new Exception(sprintf('Objects (%s) don\\'t support array access operators', $objname));\n }\n }\n break;\n }\n \n $eval .= $token;\n } \n }\n\n $last = count($ts) - 1;\n if ($last >= 2 &&\n $ts[$last - 0]['token'] == T_STRING &&\n $ts[$last - 1]['token'] == T_DOUBLE_COLON &&\n $ts[$last - 2]['token'] == T_STRING ) {\n\n /* Class::constant */\n\n /* $object has to exist and has to be a object */\n $classname = $ts[$last - 2]['value'];\n \n if (!class_exists($classname)) {\n throw new Exception(sprintf('Class \\'%s\\' doesn\\'t exist', $classname));\n }\n \n $constname = $ts[$last - 0]['value'];\n\n $c = new ReflectionClass($classname);\n if (!$c->hasConstant($constname)) {\n throw new Exception(sprintf(\"Class '%s' doesn't have a constant named '%s'\", \n $classname, $constname));\n }\n } else if ($last == 0 &&\n $ts[$last - 0]['token'] == T_VARIABLE ) {\n\n /* $var */\n\n $varname = $ts[$last - 0]['value'];\n \n if (!isset($GLOBALS[ltrim($varname, '$')])) {\n throw new Exception(sprintf('Variable \\'%s\\' is not set', $varname));\n }\n }\n\n\n $need_more = (count($braces) > 0) || $open_comment;\n\n if ($need_more || ';' === $token) {\n $need_semicolon = 0;\n } \n \n if ($need_return) {\n $eval = \"return \".$eval;\n }\n \n /* add a traling ; if necessary */ \n if ($need_semicolon) $eval .= ';';\n \n if (!$need_more) {\n $this->code = $eval;\n }\n \n return $need_more;\n }", "title": "" }, { "docid": "02453b7895d082bf41d1c580f73e7add", "score": "0.56247926", "text": "public static function Initialize()\n {\n self::$cli_parser = new CommandLine\\Parser;\n\n // Set Application details\n self::$cli_parser->application_name = \"peg-custom\";\n self::$cli_parser->application_version = \"1.0\";\n self::$cli_parser->application_description = t(\"PHP Extension Generator (http://github.com/peg-org/peg-custom)\");\n\n // Create commands\n self::$help_command = new Command\\Help;\n self::$init_command = new Command\\Init;\n self::$parse_command = new Command\\Parse;\n self::$generate_command = new Command\\Generate;\n\n // Register command operations\n self::$cli_parser->RegisterCommand(self::$help_command);\n self::$cli_parser->RegisterCommand(self::$init_command);\n self::$cli_parser->RegisterCommand(self::$parse_command);\n self::$cli_parser->RegisterCommand(self::$generate_command);\n\n // Initialize the plugin loader and try to load any plugins.\n self::$plugin_loader = new \\Peg\\Lib\\Plugins\\Loader();\n\n if(self::ValidExtension())\n {\n self::$plugin_loader->Start(self::GetCwd() . \"/plugins\");\n\n if(file_exists(self::GetCwd() . \"/peg.conf\"))\n {\n Settings::SetBackEnd(new \\Peg\\Lib\\Config\\INI);\n Settings::Load(self::GetCwd(), \"peg.conf\");\n }\n else\n {\n Settings::SetBackEnd(new \\Peg\\Lib\\Config\\JSON);\n Settings::Load(self::GetCwd(), \"peg.json\");\n }\n }\n }", "title": "" }, { "docid": "12cde66cbaefd80266bb67320d1dd16d", "score": "0.5623597", "text": "function pre_parse()\r\n\t{\r\n\t\treturn PARSER_REQUIRE_PARSING;\r\n\t}", "title": "" }, { "docid": "8f6ce8d46ee795e830d7771eaf8fe292", "score": "0.56138253", "text": "public function main() {\n\t\t$this->execute();\n\t}", "title": "" }, { "docid": "31d26e347a440b4a018c4c4553aec9ac", "score": "0.56078917", "text": "public function exec()\n {\n if( empty($this->formatter) )\n $this->loadFormatter();\n\n $result = $this->run();\n echo $this->formatter->format($result);\n }", "title": "" }, { "docid": "59577580570e9cf050f91e024cef4799", "score": "0.5588366", "text": "public function run()\n {\n $parser = new Parser;\n $feature = $parser->parse(file_get_contents($this->file));\n $this->printer->logFeature($feature, $this->file);\n\n return $this->runFeature($feature);\n }", "title": "" }, { "docid": "d52128b2df1421e8d05931fef1f835d0", "score": "0.5579455", "text": "public function run()\n {\n $this->_scanner->scan();\n }", "title": "" }, { "docid": "a6392110854122fa8ca61c43d0121ca5", "score": "0.5573855", "text": "public function run()\n {\n CommonFunctions::checkForExtensions(array('xsl'));\n $xmlfile = $this->getXMLString();\n $xslfile = \"phpsysinfo.xslt\";\n $domxml = new DOMDocument();\n $domxml->loadXML($xmlfile);\n $domxsl = new DOMDocument();\n $domxsl->load($xslfile);\n $xsltproc = new XSLTProcessor;\n $xsltproc->importStyleSheet($domxsl);\n echo $xsltproc->transformToXML($domxml);\n }", "title": "" }, { "docid": "b9c36fbd455c112a1d0a237e177ab3f1", "score": "0.55733305", "text": "protected function main(): void {\n }", "title": "" }, { "docid": "5d64eb5b5f7732fcf5ff24ce05f502bb", "score": "0.5559808", "text": "public function execute() {\n\t\t$pattern = array();\n\t\t$replace = array();\n\n\t\t/* Remove single-line HTML comments in my personal\n\t\t * style, preserving <!-- --> because it counters\n\t\t * an internet explorer deficiency\n\t\t */\n\t\t$pattern[] = '/<!-- (.*) -->/m';\n\t\t$replace[] = '';\n\n\t\t/* C-style commentary removal\n\t\t */\n\t\t$pattern[] = '#/\\*(?:[^*]*(?:\\*(?!/))*)*\\*/#';\n\t\t$replace[] = '';\n\n\t\t/* Remove whitespace characters that occur at the\n\t\t * beginning of each line\n\t\t */\n\t\t$pattern[] = '/^\\s+/m';\n\t\t$replace[] = '';\n\n\t\t/* Remove whitespace characters that occur at the\n\t\t * end of each line\n\t\t */\n\t\t$pattern[] = '/\\s+$/m';\n\t\t$replace[] = '';\n\n\t\t/* Remove tabs and newlines characters that\n\t\t * occur elsewhere\n\t\t */\n\t\t$pattern[] = '/[\\r\\n\\t]*/';\n\t\t$replace[] = '';\n\n\t\t/* Push tags together\n\t\t */\n\t\t$pattern[] = '/>\\ +</';\n\t\t$replace[] = '><';\n\n\t\t$data = trim($this->getInput());\n\t\t$data = preg_replace($pattern, $replace, $data);\n\t\t$data = htmlentities($data);\n\n\t\t$this->setOutput($data);\n }", "title": "" }, { "docid": "7d3bfce0f03b66b5b0f60958edcef22f", "score": "0.5552332", "text": "public function run() : void\n {\n // Get the input extension\n $inputExtension = $this->inputFileInfo['extension'];\n\n // In this case use csv\n if ($inputExtension == 'txt') {\n $inputExtension = 'csv';\n }\n\n // Get the input delimiter if set\n $delimiter = $this->parser->options->get('delimiter');\n\n // Create the reader\n $reader = ReaderFactory::create($inputExtension, $delimiter);\n\n // Encoding configuration is only for input type csv\n if ($inputExtension == 'csv') {\n $reader->setInputEncoding('ISO-8859-1');\n }\n\n // Load imput file to reader\n $spreadsheet = $reader->load($this->inputFilePath);\n\n // Create the writer factory instance\n $writer = WriterFactory::create($spreadsheet);\n\n // Ensure the folder output exists\n Filesystem::makeFolder(dirname($this->tempFilePath));\n\n // Save temp conversion output\n $writer->save($this->tempFilePath);\n }", "title": "" }, { "docid": "811b6ab5bf9d1384041557a9660e8433", "score": "0.5538423", "text": "function _parse_exec_tags()\n\t{\n\t\tpreg_match_all( \"#<\\!--exec\\.(file|url)=(?:[\\\"'])?(.+?)(?:[\\\"'])?-->#is\", $this->ipsclass->skin['_wrapper'], $match );\n\t\t\n\t\tfor ($i=0; $i < count($match[0]); $i++)\n\t\t{\n\t\t\t$method = strtolower(trim( $match[1][$i] ));\n\t\t\t$uri = trim( $match[2][$i] );\n\t\t\t\n\t\t\t//-----------------------------------------\n\t\t\t// PARSE: URL\n\t\t\t//-----------------------------------------\n\t\t\t\n\t\t\tif ( $method == 'url' AND IPB_ACP_ALLOW_EXEC_URL )\n\t\t\t{\n\t\t\t\t//-----------------------------------------\n\t\t\t\t// Buffer...\n\t\t\t\t//-----------------------------------------\n\t\t\t\t\n\t\t\t\t@ob_start();\n\t\t\t\tinclude( $uri );\n\t\t\t\t$data = @ob_get_contents();\n\t\t\t\t@ob_end_clean();\n\t\t\t}\n\t\t\t//-----------------------------------------\n\t\t\t// PARSE: LOCAL FILE\n\t\t\t//-----------------------------------------\n\t\t\telse\n\t\t\t{\n\t\t\t\tif ( file_exists( $uri ) AND ! preg_match( \"#http(s)?://#si\", $uri ) )\n\t\t\t\t{\n\t\t\t\t\t//-----------------------------------------\n\t\t\t\t\t// Buffer...\n\t\t\t\t\t//-----------------------------------------\n\t\t\t\t\t\n\t\t\t\t\t@ob_start();\n\t\t\t\t\tinclude( $uri );\n\t\t\t\t\t$data = @ob_get_contents();\n\t\t\t\t\t@ob_end_clean();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t$this->ipsclass->skin['_wrapper'] = str_replace( $match[0][$i], \"<!--included content-->\\n\".$data.\"\\n<!--/ included content-->\", $this->ipsclass->skin['_wrapper'] );\n\t\t\tunset( $data );\n\t\t}\n\t}", "title": "" }, { "docid": "c0cf6dc25c61c083793963fc0a65ac7b", "score": "0.55235314", "text": "public function handle()\n {\n $this->runParse();\n }", "title": "" }, { "docid": "399c8f3967695811ce1c2e48655eabd8", "score": "0.552326", "text": "function parseFile() {\n $this->title = $this->val(\"title\");\n $this->showTitle = $this->val(\"showtitle\");\n $this->rating = $this->val(\"rating\");\n $this->votes = $this->val(\"votes\");\n $this->epBookmark = $this->val(\"epbookmark\");\n $this->year = $this->val(\"year\");\n $this->top250 = $this->val(\"top250\");\n $this->season = $this->val(\"season\");\n $this->episode = $this->val(\"episode\");\n $this->uniqueId = $this->val(\"uniqueid\");\n $this->displaySeason = $this->val(\"displayseason\");\n $this->displayEpisode = $this->val(\"displayepisode\");\n $this->outline = $this->val(\"outline\");\n $this->plot = $this->val(\"plot\");\n $this->tagline = $this->val(\"tagline\");\n $this->runtime = $this->val(\"runtime\");\n $this->mpaa = $this->val(\"mpaa\");\n $this->playCount = $this->val(\"playcount\");\n $this->lastPlayed = $this->val(\"lastplayed\");\n $this->episodeGuide = $this->val(\"url\", $this->val(\"episodeGuide\"));\n $this->id = $this->val(\"id\");\n $this->genres = [];\n $genreNodeList = $this->doc->getElementsByTagName(\"genre\");\n foreach ($genreNodeList as $genre) {\n $this->genres[] = $genre->nodeValue;\n }\n $this->set = $this->val(\"set\");\n $this->premiered = $this->val(\"premiered\");\n $this->status = $this->val(\"status\");\n $this->code = $this->val(\"code\");\n $this->aired = $this->val(\"aired\");\n $this->studio = $this->val(\"studio\");\n $this->trailer = $this->val(\"trailer\");\n $this->actors = [];\n $actorNodeList = $this->doc->getElementsByTagName(\"actor\");\n foreach ($actorNodeList as $actorNode) {\n $actor = (object) [];\n $nameItem = $actorNode->getElementsByTagName(\"name\")->item(0);\n $actor->name = $nameItem != null ? $nameItem->nodeValue : \"\";\n $roleItem = $actorNode->getElementsByTagName(\"role\")->item(0);\n $actor->role = $roleItem != null ? $roleItem->nodeValue : \"\";\n $thumbItem = $actorNode->getElementsByTagName(\"thumb\")->item(0);\n $actor->thumb = $thumbItem != null ? $thumbItem->nodeValue : \"\";\n //if we have either an actor name or role, add this actor\n if ($actor->name != \"\" || $actor->role != \"\" || $actor->thumb != \"\") {\n $this->actors[] = $actor;\n }\n }\n\n $this->resume = (object) [];\n $this->resume->position = $this->val(\"position\", $this->doc->getElementsByTagName(\"resume\")->item(0));\n $this->resume->total = $this->val(\"total\", $this->doc->getElementsByTagName(\"resume\")->item(0));\n $this->dateAdded = $this->val(\"dateadded\");\n\n //if made it to here, all is good. return true\n return true;\n }", "title": "" }, { "docid": "551cc468058a5513886368e5448e46e2", "score": "0.5509111", "text": "public static function parseCommand(){\n // 检查运行命令的参数\n global $argv;\n $command = $argv[1];\n\n switch($command) {\n // 启动 phpspider\n case 'start':\n // TODO\n break;\n// case 'stop':\n// exec(\"ps aux | grep $start_file | grep -v grep | awk '{print $2}'\", $info);\n// if (count($info) <= 1) {\n// echo \"PHPSpider[$start_file] not run\\n\";\n// } else {\n// //echo \"PHPSpider[$start_file] is stoping ...\\n\";\n// echo \"PHPSpider[$start_file] stop success\";\n// exec(\"ps aux | grep $start_file | grep -v grep | awk '{print $2}' |xargs kill -SIGINT\", $info);\n// }\n// exit;\n// break;\n// case 'kill':\n// exec(\"ps aux | grep $start_file | grep -v grep | awk '{print $2}' |xargs kill -SIGKILL\");\n// break;\n// // 显示 phpspider 运行状态\n// case 'status':\n// exit(0);\n// // 未知命令\n// default :\n// exit(\"Usage: php yourfile.php {start|stop|status|kill}\\n\");\n }\n\n }", "title": "" }, { "docid": "5be2cd12d31b9766f4c56f7135f044a6", "score": "0.5505811", "text": "function main($argv) {\n\n\t$params = parse_args($argv);\n\n\t$fp = file_open($params[\"filename\"]);\n\n\twhile ($line = fgets($fp)) {\n\n\t\t$lines = process_line($line);\n\t\tprint $lines;\n\t}\n\n\tfile_close($fp);\n\n}", "title": "" }, { "docid": "8089fd6b3207b39cbb7746b974cd0b49", "score": "0.5504389", "text": "public function run(){\n\n $smaClient = new SMAClient($this->what, $this->key);\n $result = $smaClient->analyze($smaClient->createDocument($this->txt, 'en', 'myID', 'TWITTER', '', 'txt'));\n if($result)\n $result->printElements();\n\n }", "title": "" }, { "docid": "8cb606b8cbff16ee8152a0003ee450f5", "score": "0.5492399", "text": "function pparse () {\r\n\t\t\tif (!$this->_parsed) $this->_parse();\r\n\t\t\tprint($this->_tmploutput);\r\n\t\t\treturn true;\r\n\t\t}", "title": "" }, { "docid": "cc646ab6292694bac0e964d0737485d3", "score": "0.54846513", "text": "public function parse()\n {\n if ($this->isParsed()) {\n return;\n }\n\n $this->parsed = true;\n\n // skip parsing for empty useragents or those not containing any letter\n if (empty($this->userAgent) || !preg_match('/([a-z])/i', $this->userAgent)) {\n return;\n }\n\n $this->parseBot();\n if ($this->isBot()) {\n return;\n }\n\n }", "title": "" }, { "docid": "8695a3042ea4fe3d256630f355ac4baa", "score": "0.54831314", "text": "public function actionSetparsing()\n {\n ParsingRss::parsing();\n }", "title": "" }, { "docid": "7f8987fb179f9456394bebceddab1f19", "score": "0.5481357", "text": "public function main()\n {\n // Setting GPvars:\n $displayFile = GeneralUtility::_GP('file');\n $show = GeneralUtility::_GP('show');\n $preview = GeneralUtility::_GP('preview');\n $limitTags = GeneralUtility::_GP('limitTags');\n $path = GeneralUtility::_GP('path');\n\n switch (GeneralUtility::_GP('mode')) {\n case 'explode':\n case 'source':\n $mode = GeneralUtility::_GP('mode');\n break;\n default:\n $mode = '';\n }\n\n // Checking if the displayFile parameter is set:\n if (@is_file($displayFile) && GeneralUtility::getFileAbsFileName($displayFile)) {\n $fileData = GeneralUtility::getUrl($displayFile);\n if ($fileData) {\n $relPathFix = $GLOBALS['BACK_PATH'] . '../' . dirname(substr($displayFile, strlen(PATH_site))) . '/';\n\n if ($this->preview) { // In preview mode, merge preview data into the template:\n // Add preview data to file:\n $this->content = $this->displayFileContentWithPreview($fileData, $relPathFix);\n } else {\n // Markup file:\n $this->content = $this->displayFileContentWithMarkup($fileData, $path, $relPathFix, $limitTags, $show, $mode);\n }\n } else {\n $this->displayFrameError(TemplaVoilaUtility::getLanguageService()->getLL('errorNoContentInFile') . ': <em>' . htmlspecialchars($displayFile) . '</em>');\n }\n } else {\n $this->displayFrameError(TemplaVoilaUtility::getLanguageService()->getLL('errorNoFileToDisplay'));\n }\n }", "title": "" }, { "docid": "792decce80b4166f51ddb49616405329", "score": "0.54621303", "text": "static public function process()\n {\n \tprint self::getReturnXML();\n \texit;\n }", "title": "" }, { "docid": "01586378bcded23f16f420d155642636", "score": "0.54590654", "text": "public function run()\n {\n $tags = [\n 'C',\n 'C++',\n 'C#',\n 'Clojure',\n 'CSS',\n 'D',\n 'Diff',\n 'Erlang',\n 'Go',\n 'Graphviz',\n 'Groovy',\n 'Haskell',\n 'HTML',\n 'Java',\n 'JavaScript',\n 'Laravel',\n 'LaTel',\n 'Lisp',\n 'Lua',\n 'Makelife',\n 'Markdown',\n 'MATLAB',\n 'Objective-C',\n 'OCaml',\n 'Pascal',\n 'Perl',\n 'PHP',\n 'Python',\n 'R',\n 'Rails',\n 'Regular Expression',\n 'reStructuredText',\n 'Ruby',\n 'Rust',\n 'Scala',\n 'Seti_UI',\n 'Shell Script',\n 'SQL',\n 'Vue',\n 'XML'\n ];\n foreach ($tags as $tag){\n \\App\\Tag::create([\n 'tag' => $tag\n ]);\n }\n }", "title": "" }, { "docid": "e8f575f91c2fd286ee2e0d8f32417048", "score": "0.5453947", "text": "public function testParse() {\n $file = dirname(dirname(dirname(dirname(dirname(dirname(__FILE__)))))) . '/tests/resources/rss/googlenewstz.rss2';\n $fetcher_result = new RawFetcherResult(file_get_contents($file));\n\n $result = $this->parser->parse($this->feed, $fetcher_result, $this->state);\n $this->assertSame(count($result), 6);\n $this->assertSame($result[0]->get('author_name'), 'Person Name');\n $this->assertSame($result[3]->get('title'), 'NEWSMAKER-New Japan finance minister a fiery battler - Reuters');\n }", "title": "" }, { "docid": "62b2aa521d54e7356f89c004c00b3aa3", "score": "0.54513043", "text": "public static function main()\n {\n\t\t$suite = new PHPUnit_Framework_TestSuite('Tine 2.0 Projects Json Tests');\n PHPUnit_TextUI_TestRunner::run($suite);\n\t}", "title": "" }, { "docid": "837ae749d06c3b052a4d396cfab57cdf", "score": "0.54282916", "text": "public function main()\n {\n $console = $this->getConsole($_SERVER['argv']);\n $logger = $this->getLogger();\n $writer = $this->getWriter();\n $runner = $this->getCommandRunner($writer);\n $configFile = $console->getOptionValue('config', null);\n $useColor = $console->getOptionValue('color', false);\n\n if ($useColor) {\n $writer->setColor($this->getWriterColor());\n }\n\n // Load the right config file\n try {\n $config = $this->getConfig($configFile);\n } catch (Exception $e) {\n $writer->error($e->getMessage())->line();\n $runner->showHelp();\n exit;\n }\n \n $db = $this->getDb($config);\n\n if ($console->issetOption('version')) {\n $writer->version();\n return;\n }\n\n // Finally execute the right command\n try {\n $command = $console->getCommand();\n $runner->getCommand($command, $console)\n ->setConfig($config)\n ->setDb($db)\n ->setLogger($logger)\n ->init()\n ->execute();\n \n } catch (Exception $e) {\n $writer->error($e->getMessage())->line();\n $runner->showHelp();\n exit;\n }\n return;\n }", "title": "" }, { "docid": "44a4119e7d6fdf1daeb8adae5aebef19", "score": "0.54123294", "text": "function parse( $text, $linestart = true ) {\n\t\tglobal $wgParser, $wgTitle;\n\t\t$parserOutput = $wgParser->parse( $text, $wgTitle, $this->mParserOptions, $linestart );\n\t\treturn $parserOutput->getText();\n\t}", "title": "" }, { "docid": "3ecb05753cd1882b40b42d8aacfcb453", "score": "0.53996503", "text": "protected function _run()\n {\n echo $this->_xslt->transformToXML($this->_dom);\n }", "title": "" }, { "docid": "58f34d621176f0047dfe20e927f4b7d0", "score": "0.5398741", "text": "function main()\n\t{\n\t\t$group = new GroupTest();\n\t\t\n\t\t$filenames = $this->getFilenames();\n\t\t\n\t\tforeach ($filenames as $testfile)\n\t\t{\n\t\t\t$group->addTestFile($testfile);\n\t\t}\n\t\t\n\t\tif ($this->printsummary)\n\t\t{\n\t\t\t$fe = new SimpleTestFormatterElement();\n\t\t\t$fe->setType('summary');\n\t\t\t$fe->setUseFile(false);\n\t\t\t$this->formatters[] = $fe;\n\t\t}\n\t\t\n\t\tforeach ($this->formatters as $fe)\n\t\t{\n\t\t\t$formatter = $fe->getFormatter();\n\t\t\t$formatter->setProject($this->getProject());\n\n\t\t\tif ($fe->getUseFile())\n\t\t\t{\n\t\t\t\t$destFile = new PhingFile($fe->getToDir(), $fe->getOutfile());\n\t\t\t\t\n\t\t\t\t$writer = new FileWriter($destFile->getAbsolutePath());\n\n\t\t\t\t$formatter->setOutput($writer);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$formatter->setOutput($this->getDefaultOutput());\n\t\t\t}\n\t\t}\n\t\t\n\t\t$this->execute($group);\n\t\t\n\t\tif ($this->testfailed)\n\t\t{\n\t\t\tthrow new BuildException(\"One or more tests failed\");\n\t\t}\n\t}", "title": "" }, { "docid": "78619517fb9bd702eef1763891fccb64", "score": "0.5397353", "text": "protected function parse()\n {\n $this->parseNote(['usage_period_note', 'usage_area_note', 'note']);\n }", "title": "" }, { "docid": "971dea346ed098a87705d3f5e9c2fdfb", "score": "0.53933203", "text": "public static function main_text() {\n }", "title": "" }, { "docid": "91aec9b31a073ae1c7d920032604dba4", "score": "0.53864765", "text": "public function __construct()\r\n {\r\n// $db->deleteTable('message_base');\r\n// die;\r\n// $this->setCurrentPage(self::$initial_path); // if we want to parse content from \"bash.im\";\r\n $this->setCurrentPage(self::INITIAL_PAGE); // if we wanna parse just for testing from file: Parsing/data/input_data.txt;\r\n $this->parseData(self::$initial_path);\r\n $this->showContent();\r\n }", "title": "" }, { "docid": "4e70d499c97a1c7711ec4ec6b9a3a481", "score": "0.5386028", "text": "public function main() {\n\t\t\n\t\t$this->validateAttributes();\n\n\t\t$fields = $this->buildFields();\n\n\n\t\t$url = rtrim($this->host,\"/\").$this->urlPath;\n\t\t$query = http_build_query($fields);\n\t\t\n\t\t$this->log($url.'?'.$query);\n\t\t//open connection\n\t\t$ch = curl_init();\n\n\t\t//set the url, number of POST vars, POST data\n\t\tcurl_setopt($ch, CURLOPT_URL, \t\t\t $url);\n\t\tcurl_setopt($ch, CURLOPT_POST, \t\t\t TRUE);\n\t\tcurl_setopt($ch, CURLOPT_POSTFIELDS,\t $query);\n\t\tcurl_setopt($ch, CURLOPT_HEADER,\t\t 0); // add or remove header from OUTPUT\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\t\n\t\tcurl_setopt($ch, CURLOPT_CONNECTTIMEOUT, $this->timeoutConnection);\n\t\tcurl_setopt($ch, CURLOPT_TIMEOUT,\t\t $this->timeoutExecution);\n\n\t\t//execute post\n\t\t$result = curl_exec($ch);\n\t\t\n\t\t$error = null;\n\t\t$error_code = curl_errno($ch);\n\t\tif ($error_code == CURLE_OK) {\n\t\t\t$this->log($result);\n\t\t} else {\n\t\t\t$error = curl_error($ch);\n\t\t}\n\t\t\n\t\t//close connection\n\t\tcurl_close($ch);\n\t\t\n\t\tif ($error) {\n\t\t\tthrow new BuildException(\"Task exited with error:($error_code) $error\");\n\t\t}\n\t}", "title": "" }, { "docid": "5ede74df9c8dcb27b244cb5bc2cf41f1", "score": "0.5385384", "text": "public function exec() {\n \n }", "title": "" }, { "docid": "980038ed52ac345681ea888287ff1691", "score": "0.5384507", "text": "public function run()\n {\n // 将字符串 str 从 in_charset 转换编码到 out_charset\n\n // 取到的网页内容编码为GBK,很多PHP函数在这种编码下无法正常工作\n $html = iconv(\"GBK\", \"UTF-8\", MyCurl::request($this->url));\n $this->parsePage($this->url, $html);\n }", "title": "" }, { "docid": "3beac62f6c812fa2dcd5933da092d7fc", "score": "0.5374624", "text": "public function processFile() {\n\n $ext = Utils::getFileExtension($this->inputFile); \n\n # composition: load the appropriate parser\n # get the tuple of dictionaries for all the users in the data file\n switch($ext){\n\n case \"csv\":\n echo(\"parsing the csv file\\n\");\n require_once(\"./modules/csv_parser.php\");\n $parser = new CsvParser($this->inputFile);\n break;\n\n case \"yml\":\n echo(\"parsing the yml file\\n\");\n require_once(\"./modules/yml_parser.php\");\n $parser = new YmlParser($this->inputFile);\n break;\n\n case \"xml\":\n echo(\"parsing the xml file\\n\");\n require_once(\"./modules/xml_parser.php\");\n $parser = new XmlParser($this->inputFile);\n break;\n\n default:\n echo(\"file type not supported\\n\");\n return null;\n }\n\n # read file contents \n $parser->parseFile();\n # process file contents based on certain criteria \n $parser->processFile();\n # return parsed value\n $this->data = $parser->getValue(); \n \n }", "title": "" }, { "docid": "7692a95966d9f91159740e619f2e6e7c", "score": "0.5358313", "text": "private function parse()\r\n {\r\n // add current action to js data\r\n $this->addJSData('Settings', array('Action' => $this->getAction()));\r\n\r\n // add js\r\n $this->addJS('marked-0.3.3/marked.min.js', false);\r\n $this->addJS('highlight-8.4/highlight.pack.js', false);\r\n $this->addJS('taboverride-4.0.2/taboverride.js', false);\r\n $this->addJS('Purify.js', false);\r\n\r\n // highlight theme\r\n $this->addCSS('highlight-8.4/styles/github.css', false);\r\n\r\n // parse form\r\n $this->frm->parse($this->tpl);\r\n }", "title": "" }, { "docid": "781118eb4e2b75d92959d170eb09bbfb", "score": "0.5357622", "text": "function LLSDParser()\n\t{\n\t\t$this->parser = xml_parser_create();\n\t\t$this->result = null;\n\t\t$this->inLLSDElement = false;\n\n\t\t$this->stack \t= array();\n\t\t$this->keyStack\t= array();\n\n\t\t$this->depth = 0;\n\t\t$this->skipping = false;\n\t\t$this->skipThrough;\n\n\t\t$this->currentContent = '';\n\n\t\txml_parser_set_option($this->parser, XML_OPTION_CASE_FOLDING, False);\n\t\txml_set_object($this->parser, $this);\n\t\txml_set_element_handler($this->parser, 'tag_open', 'tag_close');\n\t\txml_set_character_data_handler($this->parser, 'cdata');\n\t}", "title": "" }, { "docid": "f67ac445e115b45cbaa478f90a3daf22", "score": "0.53572077", "text": "function getTokenParsers();", "title": "" }, { "docid": "bc3d3d9d725c628acbe5b3d72e25f8d2", "score": "0.53567755", "text": "function main()\n {\n // filename, give them contents of latest, or give them\n // contents of a specific version of Andromeda\n if (gp('gp0')=='latest_filename.php') {\n echo LatestAndro();\n } else {\n $file=gp('gp0');\n if (strpos($file, 'andro') ===false) {\n echo \"File not found\";\n } else {\n $this->GiveEmFile($file);\n }\n }\n // Exit prevents any further extraneous output.\n exit;\n }", "title": "" }, { "docid": "bf28b707efd8a225e3e22e0e84d59fff", "score": "0.53551704", "text": "abstract public function parse($input = null, $options = 0);", "title": "" } ]
108976c3cc1b38b10688e8c4f827fccf
Creates an instance of Comparison, with the given arguments. First argument is considered the left expression and the second is the right expression. When converted to string, it will generated a . Example: [php] // u.id where($q>expr()>lessEqual('u.id', '?1'));
[ { "docid": "60f2aff29e3a5c97a245ecb908c3e98b", "score": "0.62106293", "text": "public function lessEqual($x, $y)\n {\n return new Comparison($x, Comparison::LTE, $y);\n }", "title": "" } ]
[ { "docid": "d84aea8b6b8ec22e4b8ec69a6fd4bab4", "score": "0.6583625", "text": "public function lessThanEquals($expression);", "title": "" }, { "docid": "2836b5300509a245f9b4262a3546d415", "score": "0.6146516", "text": "public function lessThanOrEqual()\n {\n return $this->buildExpression(RelationalOperator::lessThanOrEqual());\n }", "title": "" }, { "docid": "5e8560479e10c72777e6dd9397070836", "score": "0.6043449", "text": "public function compare( $operator, $name, $value )\n\t{\n\t\treturn new \\Aimeos\\MW\\Criteria\\Expression\\Compare\\PgSQL( $this->getConnection(), $operator, $name, $value );\n\t}", "title": "" }, { "docid": "f9001c966475e8c66c6126e8f2614353", "score": "0.6028613", "text": "public function less($x, $y)\n {\n return new Comparison($x, Comparison::LT, $y);\n }", "title": "" }, { "docid": "010957a1e559d4aaa40db63fa970fce5", "score": "0.60046124", "text": "public function lessThan($expression);", "title": "" }, { "docid": "b9152f28971a112fc1468a24ac31c5ec", "score": "0.59384906", "text": "public function greaterThanEquals($expression);", "title": "" }, { "docid": "37e93869304578e20e64da9693f0024b", "score": "0.5928061", "text": "public function comparison()\n {\n if (null === static::$comparison_builder) {\n static::$comparison_builder = new ComparisonExpressionBuilder();\n }\n\n return static::$comparison_builder;\n }", "title": "" }, { "docid": "6ee31bd0c2dd29cd89a7ffe0aceb800e", "score": "0.5906148", "text": "private function make_comparer()\n {\n $criteriaNames = func_get_args();\n $comparer = function ($first, $second) use ($criteriaNames) {\n // Do we have anything to compare?\n while (!empty($criteriaNames)) {\n // What will we compare now?\n $criterion = array_shift($criteriaNames);\n\n // Used to reverse the sort order by multiplying\n // 1 = ascending, -1 = descending\n $sortOrder = 1;\n if (is_array($criterion)) {\n $sortOrder = $criterion[1] == SORT_DESC ? -1 : 1;\n $criterion = $criterion[0];\n }\n\n // Do the actual comparison\n if ($first[$criterion] < $second[$criterion]) {\n return -1 * $sortOrder;\n } else if ($first[$criterion] > $second[$criterion]) {\n return 1 * $sortOrder;\n }\n\n }\n // Nothing more to compare with, so $first == $second\n return 0;\n };\n return $comparer;\n }", "title": "" }, { "docid": "129a60394f6128a53bf7194099e4cbc0", "score": "0.5854954", "text": "private function exprCOMPARISON() {\r\n $leftval = $this->exprPLUSMINUS();\r\n if ($leftval === null) return null;\r\n\r\n $cmps = [ '==','!=','<','<=','>','>=', '===', '!=='];\r\n $cmps = array_merge($cmps, $this->assign_ops);\r\n\r\n while (true) {\r\n $backtrace = $this->index;\r\n \r\n $res = false;\r\n $rightval = '';\r\n // look for 1-char, 2-chars or 3-chars comparison operator\r\n $one = substr($this->input, $this->index++, 1);\r\n $two = $one.substr($this->input, $this->index++, 1);\r\n $three = $two.substr($this->input, $this->index++, 1);\r\n $op = $three;\r\n if (!in_array($op, $cmps)) {\r\n $op = $two; $this->index--;\r\n if (!in_array($op, $cmps)) { $op = $one; $this->index--; }\r\n }\r\n if ($op && in_array($op, $cmps) && ($rightval = $this->exprPLUSMINUS()) !== null) {\r\n $leftval = $this->binOp($leftval, $op, $rightval);\r\n if ($leftval === null) return null;\r\n $res = true;\r\n }\r\n \r\n if (!$res) {\r\n $this->index = $backtrace;\r\n return $leftval;\r\n }\r\n }\r\n return null;\r\n }", "title": "" }, { "docid": "bb602b14aae9c6f0da1fd5ff7fd6f434", "score": "0.5845314", "text": "private function _get_where_less_than_or_equal_to() {\n if (!isset($this->where_less_than_or_equal_to) || !is_array($this->where_less_than_or_equal_to) || empty($this->where_less_than_or_equal_to)) {\n return '';\n } else {\n $where_less_than_or_equal_to = array();\n foreach ($this->where_less_than_or_equal_to as $k => $v) {\n $k = $this->replaceReservedWords($k);\n $v = $this->replaceReservedWords($v);\n if (is_null($v)) {\n $where_less_than_or_equal_to[] = $k . ' IS NULL';\n } elseif (is_int($k)) {\n $where_less_than_or_equal_to[] = $v;\n } elseif (is_int($v)) {\n $where_less_than_or_equal_to[] = sprintf($k . ' <= %s', $this->_check_link_mysqli($v));\n } else {\n $where_less_than_or_equal_to[] = sprintf($k . ' <= \"%s\"', $this->_check_link_mysqli($v));\n }\n }\n return implode(' AND' . \"\\n\\t\", $where_less_than_or_equal_to) . ' ';\n }\n }", "title": "" }, { "docid": "13c29419df7e9a3d5f7126cf54c48424", "score": "0.58013517", "text": "function operator_less_than($a, $b)\n{\n return $a < $b;\n}", "title": "" }, { "docid": "c31a067f7bcffde6a0e363067a7139be", "score": "0.5784939", "text": "function math_isLess($arguments) {\n $number1 = intval($arguments[0]);\n $number2 = intval($arguments[1]);\n $allowEqual = false;\n if(isset($arguments[2])) {\n $allowEqual = $arguments[2];\n }\n if($allowEqual) {\n return strval($number1 <= $number2);\n } else {\n return strval($number1 < $number2);\n }\n}", "title": "" }, { "docid": "5450e64b6e8d5a5c6a9927bf68a86a90", "score": "0.57708985", "text": "function operator_less_than_or_equal_to($a, $b)\n{\n return $a <= $b;\n}", "title": "" }, { "docid": "137433c68d7adb998dfe989fdb3c9f06", "score": "0.5711156", "text": "public function greaterEqual($x, $y)\n {\n return new Comparison($x, Comparison::GTE, $y);\n }", "title": "" }, { "docid": "fe412be5fb385e31f18337cf59e51016", "score": "0.5677855", "text": "public static function gen_eq($lhs, $rhs, $operator=\"=\", $backticks=false) {\n $eq = Lib_DQ::gen_expr($lhs) . \" $operator \" . Lib_DQ::gen_expr($rhs);\n if ($backticks) $eq = \"`\" . $eq . \"`\";\n return $eq;\n }", "title": "" }, { "docid": "81939949ea27e9fe527b8888095ed9ac", "score": "0.56445754", "text": "function operator_greater_than_or_equal_to($a, $b)\n{\n return $a >= $b;\n}", "title": "" }, { "docid": "83fae78fbefbafdcc650032b5612e09c", "score": "0.5591698", "text": "function operator_greater_than($a, $b)\n{\n return $a > $b;\n}", "title": "" }, { "docid": "a209cd43e1da10a94d125977c8e1fee5", "score": "0.55529696", "text": "public function equal($x, $y)\n {\n return new Comparison($x, Comparison::EQ, $y);\n }", "title": "" }, { "docid": "45de6fb879218e56f106b7ae7a027200", "score": "0.5521401", "text": "public function greater($x, $y)\n {\n return new Comparison($x, Comparison::GT, $y);\n }", "title": "" }, { "docid": "334f4867f2a35c8929fda7cfd53e00a0", "score": "0.5487858", "text": "function make_comparer() {\n\t// Normalize criteria up front so that the comparer finds everything tidy\n\t$criteria = func_get_args();\n\tforeach ($criteria as $index => $criterion) {\n\t\t$criteria[$index] = is_array($criterion)\n\t\t\t? array_pad($criterion, 3, null)\n\t\t\t: array($criterion, SORT_ASC, null);\n\t}\n\treturn function($first, $second) use (&$criteria) {\n\tforeach ($criteria as $criterion) {\n\t\t// How will we compare this round?\n\t\tlist($column, $sortOrder, $projection) = $criterion;\n\t\t$sortOrder = $sortOrder === SORT_DESC ? -1 : 1;\n\t\t// If a projection was defined project the values now\n\t\tif ($projection) {\n\t\t\t$lhs = call_user_func($projection, $first[$column]);\n\t\t\t$rhs = call_user_func($projection, $second[$column]);\n\t\t}\n\t\telse {\n\t\t\t$lhs = $first[$column];\n\t\t\t$rhs = $second[$column];\n\t\t}\n\t\t// Do the actual comparison; do not return if equal\n\t\tif ($lhs < $rhs) {\n\t\t\treturn -1 * $sortOrder;\n\t\t}\n\t\telse if ($lhs > $rhs) {\n\t\t\treturn 1 * $sortOrder;\n\t\t}\n\t}\n\treturn 0; // tiebreakers exhausted, so $first == $second\n\t};\n}", "title": "" }, { "docid": "9c9eca8ef240b887c5da1fcafc385718", "score": "0.54462975", "text": "public function parseLt($expr1, $expr2)\n\t{\n\t\treturn $this->convertComparison($expr1, '<', $expr2);\n\t}", "title": "" }, { "docid": "17d96622571af0be8196cd89c13133fe", "score": "0.54295146", "text": "public function greaterThanOrEqual()\n {\n return $this->buildExpression(RelationalOperator::greaterThanOrEqual());\n }", "title": "" }, { "docid": "71d05a172945ce4cb9ac1b2f0e5485ed", "score": "0.5402403", "text": "private function _get_where_less_than() {\n if (!isset($this->where_less_than) || !is_array($this->where_less_than) || empty($this->where_less_than)) {\n return '';\n } else {\n $where_less_than = array();\n foreach ($this->where_less_than as $k => $v) {\n $k = $this->replaceReservedWords($k);\n $v = $this->replaceReservedWords($v);\n if (is_null($v)) {\n $where_less_than[] = $k . ' IS NULL';\n } elseif (is_int($k)) {\n $where_less_than[] = $v;\n } elseif (is_int($v)) {\n $where_less_than[] = sprintf($k . ' < %s', $this->_check_link_mysqli($v));\n } else {\n $where_less_than[] = sprintf($k . ' < \"%s\"', $this->_check_link_mysqli($v));\n }\n }\n return implode(' AND' . \"\\n\\t\", $where_less_than) . ' ';\n }\n }", "title": "" }, { "docid": "191253217cff45eebce669934fa170cd", "score": "0.5390712", "text": "function lt($lhs = null, $rhs = null)\n{\n return call_user_func_array(__PRIVATE__::$instance[lt], func_get_args());\n}", "title": "" }, { "docid": "6b5521da241bb9fd783e356be119b06a", "score": "0.53799754", "text": "protected static function buildComparison(string $field, string $operator, string $value) : string\n {\n if ('~' == $value) {\n $operator = self::getOperatorFromScope($operator, self::NULL);\n\n return \"{$field} {$operator}\";\n }\n\n $operator = self::getOperatorFromScope($operator, self::containsWildcards($value) ? self::LIKE : self::EQUALS);\n\n $value = mb_strtolower($value);\n $value = ctype_digit($value) ? $value : \"'{$value}'\";\n\n return \"{$field} {$operator} {$value}\";\n }", "title": "" }, { "docid": "794cd53842a85cc1773763d3a6509f9e", "score": "0.5360141", "text": "private function _get_where_greater_than_or_equal_to() {\n if (!isset($this->where_greater_than_or_equal_to) || !is_array($this->where_greater_than_or_equal_to) || empty($this->where_greater_than_or_equal_to)) {\n return '';\n } else {\n $where_greater_than_or_equal_to = array();\n foreach ($this->where_greater_than_or_equal_to as $k => $v) {\n $k = $this->replaceReservedWords($k);\n $v = $this->replaceReservedWords($v);\n if (is_null($v)) {\n $where_greater_than_or_equal_to[] = $k . ' IS NULL';\n } elseif (is_int($k)) {\n $where_greater_than_or_equal_to[] = $v;\n } elseif (is_int($v)) {\n $where_greater_than_or_equal_to[] = sprintf($k . ' >= %s', $this->_check_link_mysqli($v));\n } else {\n $where_greater_than_or_equal_to[] = sprintf($k . ' >= \"%s\"', $this->_check_link_mysqli($v));\n }\n }\n return implode(' AND' . \"\\n\\t\", $where_greater_than_or_equal_to) . ' ';\n }\n }", "title": "" }, { "docid": "a1a097210e4ef4ef85ca3b3fc62909ee", "score": "0.534937", "text": "protected function parseComparison(\\TYPO3\\CMS\\Extbase\\Persistence\\Generic\\Qom\\ComparisonInterface $comparison, \\TYPO3\\CMS\\Extbase\\Persistence\\Generic\\Qom\\SourceInterface $source, array &$sql, array &$parameters) {\n\t\t$operand1 = $comparison->getOperand1();\n\t\t$operator = $comparison->getOperator();\n\t\t$operand2 = $comparison->getOperand2();\n\t\tif ($operator === \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_IN) {\n\t\t\t$items = array();\n\t\t\t$hasValue = FALSE;\n\t\t\tforeach ($operand2 as $value) {\n\t\t\t\t$value = $this->getPlainValue($value);\n\t\t\t\tif ($value !== NULL) {\n\t\t\t\t\t$items[] = $value;\n\t\t\t\t\t$hasValue = TRUE;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ($hasValue === FALSE) {\n\t\t\t\t$sql['where'][] = '1<>1';\n\t\t\t} else {\n\t\t\t\t$this->parseDynamicOperand($operand1, $operator, $source, $sql, $parameters, NULL, $operand2);\n\t\t\t\t$parameters[] = $items;\n\t\t\t}\n\t\t} elseif ($operator === \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_CONTAINS) {\n\t\t\tif ($operand2 === NULL) {\n\t\t\t\t$sql['where'][] = '1<>1';\n\t\t\t} else {\n\t\t\t\t$className = $source->getNodeTypeName();\n\t\t\t\t$tableName = $this->dataMapper->convertClassNameToTableName($className);\n\t\t\t\t$propertyName = $operand1->getPropertyName();\n\t\t\t\twhile (strpos($propertyName, '.') !== FALSE) {\n\t\t\t\t\t$this->addUnionStatement($className, $tableName, $propertyName, $sql);\n\t\t\t\t}\n\t\t\t\t$columnName = $this->dataMapper->convertPropertyNameToColumnName($propertyName, $className);\n\t\t\t\t$dataMap = $this->dataMapper->getDataMap($className);\n\t\t\t\t$columnMap = $dataMap->getColumnMap($propertyName);\n\t\t\t\t$typeOfRelation = $columnMap instanceof \\TYPO3\\CMS\\Extbase\\Persistence\\Generic\\Mapper\\ColumnMap ? $columnMap->getTypeOfRelation() : NULL;\n\t\t\t\tif ($typeOfRelation === \\TYPO3\\CMS\\Extbase\\Persistence\\Generic\\Mapper\\ColumnMap::RELATION_HAS_AND_BELONGS_TO_MANY) {\n\t\t\t\t\t$relationTableName = $columnMap->getRelationTableName();\n\t\t\t\t\t$sql['where'][] = $tableName . '.uid IN (SELECT ' . $columnMap->getParentKeyFieldName() . ' FROM ' . $relationTableName . ' WHERE ' . $columnMap->getChildKeyFieldName() . '=?)';\n\t\t\t\t\t$parameters[] = intval($this->getPlainValue($operand2));\n\t\t\t\t} elseif ($typeOfRelation === \\TYPO3\\CMS\\Extbase\\Persistence\\Generic\\Mapper\\ColumnMap::RELATION_HAS_MANY) {\n\t\t\t\t\t$parentKeyFieldName = $columnMap->getParentKeyFieldName();\n\t\t\t\t\tif (isset($parentKeyFieldName)) {\n\t\t\t\t\t\t$childTableName = $columnMap->getChildTableName();\n\t\t\t\t\t\t$sql['where'][] = $tableName . '.uid=(SELECT ' . $childTableName . '.' . $parentKeyFieldName . ' FROM ' . $childTableName . ' WHERE ' . $childTableName . '.uid=?)';\n\t\t\t\t\t\t$parameters[] = intval($this->getPlainValue($operand2));\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$sql['where'][] = 'FIND_IN_SET(?,' . $tableName . '.' . $columnName . ')';\n\t\t\t\t\t\t$parameters[] = intval($this->getPlainValue($operand2));\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tthrow new \\TYPO3\\CMS\\Extbase\\Persistence\\Generic\\Exception\\RepositoryException('Unsupported or non-existing property name \"' . $propertyName . '\" used in relation matching.', 1327065745);\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\tif ($operand2 === NULL) {\n\t\t\t\tif ($operator === \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_EQUAL_TO) {\n\t\t\t\t\t$operator = self::OPERATOR_EQUAL_TO_NULL;\n\t\t\t\t} elseif ($operator === \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_NOT_EQUAL_TO) {\n\t\t\t\t\t$operator = self::OPERATOR_NOT_EQUAL_TO_NULL;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$this->parseDynamicOperand($operand1, $operator, $source, $sql, $parameters);\n\t\t\t$parameters[] = $this->getPlainValue($operand2);\n\t\t}\n\t}", "title": "" }, { "docid": "71f06809e325256ea112fb6860db51ff", "score": "0.5346937", "text": "public function greaterThan($expression);", "title": "" }, { "docid": "049cf0faa13206e27afa799bb59aa95d", "score": "0.5328326", "text": "public function compare($a, $b);", "title": "" }, { "docid": "8127646de6d40d2555792c876bacdaae", "score": "0.52726656", "text": "public function parseGte($expr1, $expr2)\n\t{\n\t\treturn $this->convertComparison($expr1, '>=', $expr2);\n\t}", "title": "" }, { "docid": "196856849305d02610475a5c391aadc4", "score": "0.52576804", "text": "public static function prepareOperator($conditions) {\n global $wpdb;\n\n $queryArgs = [];\n $values = [];\n $operator = '=';\n $logicalOperator = 'AND';\n\n foreach($conditions as $idx => $v) {\n\n // Set the \"name = %s\" in queryArgs and value to array values if not be an AND or OR condition\n if ( !is_array( $conditions[$idx] ) && $conditions[$idx] != 'AND' && $conditions[$idx] != 'OR') {\n array_push( $queryArgs, $idx . \" = %s\" );\n array_push( $values, $v );\n }\n\n // If array contains AND or OR operation condition, receive them and continue to next loop\n if ($conditions[$idx] == 'AND' || $conditions[$idx] == 'OR') {\n $logicalOperator = $conditions[$idx];\n continue;\n }\n\n // If the index is array, and your first value is 'AND' or 'OR'\n if ( is_array($v) && ($v[0] == 'AND' || $v[0] == 'OR') ) {\n $result = static::prepareOperator($v);\n array_push($queryArgs, $result['logicalQuery']);\n foreach ($result['values'] as $value) {\n array_push($values, $value);\n }\n }\n \n if ( is_array ($conditions[$idx]) ) {\n // Break the array into operator, attribute and value\n $operator = strtolower($v[0]);\n $attribute = $v[1];\n $value = $v[2];\n\n // Check and apply operator\n switch ( $operator ) {\n // ['=', 'attribute', 'value']\n case '=':\n // ['>=', 'attribute', 'value']\n case '>=':\n // ['<=', 'attribute', 'value']\n case '<=':\n // ['>', 'attribute', 'value']\n case '>':\n // ['<', 'attribute', 'value']\n case '<':\n // ['<>', 'attribute', 'value']\n case '<>':\n array_push( $queryArgs, \"$attribute $operator %s\");\n array_push( $values, $value );\n break;\n \n // ['not', 'name', NULL]\n case 'not':\n // Differ operator string if the item is NULL\n if ( $value == NULL) {\n array_push( $queryArgs, $attribute . ' IS NOT NULL');\n \n } else {\n array_push( $queryArgs, $attribute . ' IS NOT %s');\n array_push( $values, $value );\n }\n break;\n\n // ['in', 'name', ['test', 'ok']]\n case 'in':\n // Only insert this validation if there is at least one item in the values array\n if ( count( $value ) > 0 ) {\n // Parse the values array to string\n $values_placeholders = implode( ', ', array_fill( 0, count( $value ), '%s' ) );\n array_push( $queryArgs, $attribute . \" IN ($values_placeholders)\" );\n $values = array_merge( $values, $value );\n }\n break;\n\n // ['not in', 'name', ['test', 'ok']]\n case 'not in':\n // Only insert this validation if there is at least one item in the values array\n if ( count( $value ) > 0 ) {\n // Parse the values array to string\n $values_placeholders = implode( ', ', array_fill( 0, count( $value ), '%s' ) );\n array_push( $queryArgs, $attribute . \" NOT IN ($values_placeholders)\" );\n $values = array_merge( $values, $value );\n }\n break;\n\n // ['like', 'name', 'search_text']\n case 'like':\n array_push( $queryArgs, $attribute . \" LIKE %s\" );\n // Properly scape esc like attribute\n array_push( $values, \"%\" . $wpdb->esc_like($value) . \"%\");\n break;\n\n // ['regexp', 'name', '[a-zA-Z ]*']\n case 'regexp':\n // This operation should be used with caution and the value validation should be run by the caller\n array_push( $queryArgs, $attribute .\" REGEXP '\". $value .\"'\" );\n break;\n }\n }\n }\n\n // Parse the array with the logical operator. default = 'AND'\n $logicalQuery = '(' . implode (\" $logicalOperator \", $queryArgs) . ')';\n\n return [\n 'logicalQuery' => $logicalQuery, \n 'values' => $values,\n ];\n }", "title": "" }, { "docid": "2553ffe1eb9b0cdf3d757641d6e1c752", "score": "0.52110404", "text": "function math_isGreater($arguments) {\n $number1 = intval($arguments[0]);\n $number2 = intval($arguments[1]);\n $allowEqual = false;\n if(isset($arguments[2])) {\n $allowEqual = $arguments[2];\n }\n if($allowEqual) {\n return strval($number1 >= $number2);\n } else {\n return strval($number1 > $number2);\n }\n}", "title": "" }, { "docid": "60787c98f4e2c0b1326aaca9c3dc508a", "score": "0.52007943", "text": "function condition_operator2str($operator) {\n\t$operators = [\n\t\tCONDITION_OPERATOR_EQUAL => '=',\n\t\tCONDITION_OPERATOR_NOT_EQUAL => '<>',\n\t\tCONDITION_OPERATOR_LIKE => _('like'),\n\t\tCONDITION_OPERATOR_NOT_LIKE => _('not like'),\n\t\tCONDITION_OPERATOR_IN => _('in'),\n\t\tCONDITION_OPERATOR_MORE_EQUAL => '>=',\n\t\tCONDITION_OPERATOR_LESS_EQUAL => '<=',\n\t\tCONDITION_OPERATOR_NOT_IN => _('not in')\n\t];\n\n\treturn $operators[$operator];\n}", "title": "" }, { "docid": "581a3d849f4421fc1680e43f97ee9bdc", "score": "0.5198061", "text": "public function parseLte($expr1, $expr2)\n\t{\n\t\treturn $this->convertComparison($expr1, '<=', $expr2);\n\t}", "title": "" }, { "docid": "cf54978dd5a94b242110518e66ca3fc4", "score": "0.5157733", "text": "static public function get( $condition_operator )\n {\n\tswitch( $condition_operator )\n\t{\n\t case self::FULL_TEXT: return array(\n '%%%s%%' => '%LIKE%',\n '%s' => '=',\n 'x%s' => '<>',\n '%s%%' => 'LIKE%',\n '%%%s' => '%LIKE',\n\t\t'x%%%s%%' => 'NOT %LIKE%',\n 'x%s%%' => 'NOT LIKE%',\n 'x%%%s' => 'NOT %LIKE',\n 'IS NULL' => 'IS EMPTY',\n 'IS NOT NULL' => 'IS NOT EMPTY',\n\t );\n\t case self::LIGHT_TEXT: return array(\n '%%%s%%' => '%LIKE%',\n '%s' => '=',\n 'x%s' => '<>',\n '%s%%' => 'LIKE%',\n '%%%s' => '%LIKE',\n\t\t'x%%%s%%' => 'NOT %LIKE%',\n 'x%s%%' => 'NOT LIKE%',\n 'x%%%s' => 'NOT %LIKE',\n\t );\n\t case self::SMAL_TEXT: return array(\n '%%%s%%' => '%LIKE%',\n '%s' => '=',\n 'x%s' => '<>',\n 'IS NULL' => 'IS EMPTY',\n 'IS NOT NULL' => 'IS NOT EMPTY',\n\t );\n\t case self::MIN_INT: return array(\n '%s' => '=',\n 'x%s' => '<>',\n\t );\n\t case self::FULL_INT: return array(\n '%s' => '=',\n 'x%s' => '<>',\n\t\t'xx%s' => '>',\n\t\t'xxx%s' => '<',\n\t\t'xxxx%s' => '>=',\n\t\t'xxxxx%s' => '<=',\n 'IS NULL' => 'IS EMPTY',\n 'IS NOT NULL' => 'IS NOT EMPTY',\n\t );\n\t case self::MEDIUM_INT: return array(\n '%s' => '=',\n 'x%s' => '<>',\n\t\t'xxxx%s' => '>=',\n\t\t'xx%s' => '>',\n\t\t'xxxxx%s' => '<=',\n\t\t'xxx%s' => '<',\n\t );\n\t case self::SMAL_INT: return array(\n '%s' => '=',\n 'x%s' => '<>',\n 'IS NULL' => 'IS EMPTY',\n 'IS NOT NULL' => 'IS NOT EMPTY',\n\t );\n\t case self::LIKE: return array(\n '%%%s%%' => '%LIKE%',\n\t );\n\t case self::EQ: return array(\n '%s' => '=',\n\t );\n\t case self::YES_NO: return array(\n 'TRUE_FALSE' => '=',\n\t );\n\t case self::DATE_FROM: return array(\n\t\t'xxxx%s' => '>=',\n\t\t'xx%s' => '>',\n\t\t'xxxxx%s' => '<=',\n\t\t'xxx%s' => '<',\n '%s' => '=',\n 'x%s' => '<>',\n\t );\n\t case self::DATE_TO: return array(\n\t\t'xxxxx%s' => '<=',\n\t\t'xxx%s' => '<',\n\t\t'xxxx%s' => '>=',\n\t\t'xx%s' => '>',\n '%s' => '=',\n 'x%s' => '<>',\n\t );\n\t case self::MIN_MAX: return array(\n\t\t'xx%s' => '>',\n\t\t'xxxxx%s' => '<=',\n\t );\n\t}\n return array();\n }", "title": "" }, { "docid": "ad0eebc6899e5ff784450977ab3d4a47", "score": "0.515228", "text": "private function buildComparison($propertyName, $propertyValue)\n {\n $originalPropertyName = $propertyName;\n $propertyName = Inflector::camelize($propertyName);\n\n if ( ! $this->checkValidProperty($propertyName)) {\n return null;\n }\n\n $leftExpression = 'e.' . $propertyName;\n $rightExpression = ':' . $originalPropertyName;\n\n switch (true) {\n case (is_array($propertyValue)):\n return new Expr\\Func($leftExpression . ' IN', $rightExpression);\n case (strtolower($propertyValue) === 'null'):\n return sprintf('%s IS NULL', $leftExpression);\n case (strpos($propertyValue, self::WILDCARD_CHAR) !== false):\n return new Expr\\Comparison($leftExpression, 'LIKE', $rightExpression);\n default:\n return new Expr\\Comparison($leftExpression, Expr\\Comparison::EQ, $rightExpression);\n }\n }", "title": "" }, { "docid": "4939cc98923d3bd6b7da679a929a5d73", "score": "0.51495904", "text": "function LessThan($greater) {\n if ( is_object($greater) ) {\n// eZDebug::writeDebug( \"RRule\", \" Comparing %s with %s\", $this->_text, $greater->_text );\n return ( $this->_text < $greater->_text );\n }\n// eZDebug::writeDebug( \"RRule\", \" Comparing %s with %s\", $this->_text, $greater );\n return ( $this->_text < $greater ); // These sorts of dates are designed that way...\n }", "title": "" }, { "docid": "ad2260d113f82062358adf65343eba5a", "score": "0.50948304", "text": "static public function get2( $condition_operator )\n {\n\tswitch( $condition_operator )\n\t{\n\t case \"%s\" : return \"='|||'\";\n\t case \"x%s\" : return \"<>'|||'\";\n\t case \"xx%s\" : return \">'|||'\";\n\t case \"xxx%s\" : return \"<'|||'\";\n\t case \"xxxx%s\" : return \">='|||'\";\n\t case \"xxxxx%s\": return \"<='|||'\";\n\t case \"%%%s%%\" : return \"LIKE '%|||%'\";\n\t case \"%s%%\" : return \"LIKE '|||%'\";\n\t case \"%%%s\" : return \"LIKE '%|||'\";\n\t case \"x%%%s%%\": return \"NOT LIKE '%|||%'\";\n\t case \"x%s%%\" : return \"NOT LIKE '|||%'\";\n\t case \"x%%%s\" : return \"NOT LIKE '%|||'\";\n\t}\n\treturn null;\n }", "title": "" }, { "docid": "7352a3f7909f1b5098ea3bc281ff40ee", "score": "0.5082143", "text": "private function _get_where_greater_than() {\n if (!isset($this->where_greater_than) || !is_array($this->where_greater_than) || empty($this->where_greater_than)) {\n return '';\n } else {\n $where_greater_than = array();\n foreach ($this->where_greater_than as $k => $v) {\n $k = $this->replaceReservedWords($k);\n $v = $this->replaceReservedWords($v);\n if (is_null($v)) {\n $where_greater_than[] = $k . ' IS NULL';\n } elseif (is_int($k)) {\n $where_greater_than[] = $v;\n } elseif (is_int($v)) {\n $where_greater_than[] = sprintf($k . ' > %s', $this->_check_link_mysqli($v));\n } else {\n $where_greater_than[] = sprintf($k . ' > \"%s\"', $this->_check_link_mysqli($v));\n }\n }\n return implode(' AND' . \"\\n\\t\", $where_greater_than) . ' ';\n }\n }", "title": "" }, { "docid": "6a99ffa7f10a405367e2ddb655c705d0", "score": "0.50736016", "text": "public function comparison($check1, $operator = null, $check2 = null) {\n\n $operator = str_replace(array(' ', \"\\t\", \"\\n\", \"\\r\", \"\\0\", \"\\x0B\"), '', strtolower($operator));\n\n switch ($operator) {\n case 'isgreater':\n case '>':\n if ($check1 > $check2) {\n return true;\n }\n break;\n case 'isless':\n case '<':\n if ($check1 < $check2) {\n return true;\n }\n break;\n case 'greaterorequal':\n case '>=':\n if ($check1 >= $check2) {\n return true;\n }\n break;\n case 'lessorequal':\n case '<=':\n if ($check1 <= $check2) {\n return true;\n }\n break;\n case 'equalto':\n case '==':\n if ($check1 == $check2) {\n return true;\n }\n break;\n case 'notequal':\n case '!=':\n if ($check1 != $check2) {\n return true;\n }\n break;\n }\n return false;\n }", "title": "" }, { "docid": "4d33f817c5711b48c0b4927ebcab013e", "score": "0.50721496", "text": "public function expr($properties = [], $arguments = null)\n {\n $e = new self($properties, $arguments);\n $e->connection = $this->connection;\n\n return $e;\n }", "title": "" }, { "docid": "5db5143fece94963eb4597b9f5f84f83", "score": "0.5050048", "text": "public static function getComparisonOperators()\n {\n return array(\n static::COMPARE_EQUAL,\n static::COMPARE_NOT_EQUAL,\n static::COMPARE_CONTAINS,\n static::COMPARE_NOT_CONTAINS,\n static::COMPARE_REGEX,\n static::COMPARE_NOT_REGEX,\n static::COMPARE_GT,\n static::COMPARE_LT,\n static::COMPARE_GTE,\n static::COMPARE_LTE\n );\n }", "title": "" }, { "docid": "03c8d24134d780619ad8dba3b3a8e586", "score": "0.5013464", "text": "public function parseGt($expr1, $expr2)\n\t{\n\t\treturn $this->convertComparison($expr1, '>', $expr2);\n\t}", "title": "" }, { "docid": "69a8d4de6a1e477005a1ce4fcc391cb2", "score": "0.4994728", "text": "private function __buildquery($values, $filter = \" AND \", $compare = \"=\") {\n\t\t\t// check values\n\t\t\tif(!is_array($values)) return \"\";\n\t\t\t// initialize result\n\t\t\t$result = Array();\n\t\t\t// cycle values\n\t\t\tforeach($values as $n=>$v) {\n\t\t\t\t// pre format\n\t\t\t\t$p = true;\n\t\t\t\tswitch($n) {\n\t\t\t\t\tcase DB_FIELD_HISTORY: \n\t\t\t\t\t\t// process correct\n\t\t\t\t\t\tif(is_array($v)) $v = serialize($v);\n\t\t\t\t\t\t$p = !is_string($v)||strlen($v)==0?false:true; \n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\t// format data\n\t\t\t\tif($p===true) {\n\t\t\t\t\t$result[] = sprintf(\"%s%s'%s'\", $n, $compare, @mysql_real_escape_string($v));\n\t\t\t\t}\n\t\t\t}\n\t\t\t// return result\n\t\t\treturn implode($filter, $result);\n\t\t}", "title": "" }, { "docid": "b59e1ffa8fcaed23923f45460c5975bd", "score": "0.4993309", "text": "public function isComparisonOperator()\n {\n return\n $this->Id == ExpressionTokenId::IDENTIFIER &&\n (strcmp($this->Text, ODataConstants::KEYWORD_EQUAL) == 0 ||\n strcmp($this->Text, ODataConstants::KEYWORD_NOT_EQUAL) == 0 ||\n strcmp($this->Text, ODataConstants::KEYWORD_LESSTHAN) == 0 ||\n strcmp($this->Text, ODataConstants::KEYWORD_GREATERTHAN) == 0 ||\n strcmp($this->Text, ODataConstants::KEYWORD_LESSTHAN_OR_EQUAL) == 0 ||\n strcmp($this->Text, ODataConstants::KEYWORD_GREATERTHAN_OR_EQUAL) == 0) ||\n strcmp($this->Text, ODataConstants::KEYWORD_IN) == 0;\n }", "title": "" }, { "docid": "1f918a32b471dbe466f5c1e05a920f96", "score": "0.4986394", "text": "public function getExpression()\n {\n $expression = '';\n\n foreach ($this->_conditions as $condition) {\n // turn array key/value pairs into named variables\n extract($condition);\n\n // skip empty sub-filters.\n $isSubFilter = array_key_exists('filter', $condition);\n $subExpression = $isSubFilter ? $filter->getExpression() : null;\n if ($isSubFilter && empty($subExpression)) {\n continue;\n }\n\n // add in the connective if this isn't the first condition\n // if it is the first condition, and the connective is negated\n // start the expression with a logical not.\n if ($expression !== '') {\n $expression .= ' ' . $connective . ' ';\n } else if (static::isNegatedOperator($connective)) {\n $expression = static::LOGICAL_NOT;\n }\n\n // if this condition is a sub-filter, wrap sub-expression in group operators\n if ($isSubFilter) {\n $expression .= static::GROUP_OPEN . $subExpression . static::GROUP_CLOSE;\n continue;\n }\n\n // escape the provided value so it is safe to use in a filter clause.\n $value = ($comparison === static::COMPARE_REGEX || $comparison === static::COMPARE_NOT_REGEX)\n ? $this->escapeForRegex($condition['value'])\n : $this->escapeForEquals($condition['value']);\n\n // produce a null value so we can match empty/null attributes,\n // but only when we have a comparison.\n if ($value === '' and $comparison !== '') {\n $comparison = static::COMPARE_REGEX;\n $value = $this->escapeForRegex('^$');\n }\n\n // Perforce doesn't support '!=' style operators, so we must\n // switch the operator over to positive and prepend a logical not.\n if ($comparison === static::COMPARE_NOT_EQUAL\n || $comparison === static::COMPARE_NOT_REGEX\n || $comparison === static::COMPARE_NOT_CONTAINS\n ) {\n $expression .= static::LOGICAL_NOT;\n if ($comparison === static::COMPARE_NOT_EQUAL) {\n $comparison = static::COMPARE_EQUAL;\n } else if ($comparison === static::COMPARE_NOT_REGEX) {\n $comparison = static::COMPARE_REGEX;\n } else if ($comparison === static::COMPARE_NOT_CONTAINS) {\n $comparison = static::COMPARE_CONTAINS;\n }\n }\n\n // convert equals and contains operators to regex because it is\n // more accurate (not all characters can be escaped for the equals\n // operator and it doesn't support case insensitive comparisons).\n // to convert equals, we must bind to the start/end of the value\n // to ensure a literal match.\n if ($comparison === static::COMPARE_EQUAL) {\n $comparison = static::COMPARE_REGEX;\n $value = $this->escapeForRegex('^')\n . $value\n . $this->escapeForRegex('$');\n } else if ($comparison === static::COMPARE_CONTAINS) {\n $comparison = static::COMPARE_REGEX;\n }\n\n // when we are matching and ignoring case, we need to compose a\n // suitable regex. since we may have character classes in the\n // provided regex, we track bracketing and try to behave sensibly\n // while adding [Aa] atoms to the regex where appropriate.\n if ($caseInsensitive && $comparison === static::COMPARE_REGEX) {\n $newValue = '';\n $bracketLevel = 0;\n $escape = false;\n foreach (str_split($value) as $char) {\n if ($char === '[' and !$escape) {\n $bracketLevel++;\n }\n if ($char === ']' and !$escape) {\n if ($bracketLevel-- < 0) {\n $bracketLevel = 0;\n }\n }\n if (preg_match('/[a-zA-Z]/', $char)) {\n $startBracket = $bracketLevel > 0 ? '' : '[';\n $endBracket = $bracketLevel > 0 ? '' : ']';\n $char = $startBracket . strtoupper($char) . strtolower($char) . $endBracket;\n }\n\n // check for escape characters, set escape state accordingly.\n $escape = $char === '\\\\'\n ? ($escape ? false : true)\n : false;\n $newValue .= $char;\n }\n $value = $newValue;\n }\n\n // glue on the field/comparison/value to our running expression\n $expression .= $field . $comparison . $value;\n }\n\n return $expression;\n }", "title": "" }, { "docid": "e2f68bd6e53db59a98e6d9b6f6d92323", "score": "0.4985102", "text": "public function buildLikeCondition($operator, $operands, &$params)\n {\n if (!isset($operands[0], $operands[1])) {\n throw new InvalidParamException(\"Operator '$operator' requires two operands.\");\n }\n\n $escape = isset($operands[2]) ? $operands[2] : ['%' => '\\%', '_' => '\\_', '\\\\' => '\\\\\\\\'];\n unset($operands[2]);\n\n if (!preg_match('/^(AND |OR |)(((NOT |))I?LIKE)/', $operator, $matches)) {\n throw new InvalidParamException(\"Invalid operator '$operator'.\");\n }\n $andor = ' ' . (!empty($matches[1]) ? $matches[1] : 'AND ');\n $not = !empty($matches[3]);\n $operator = $matches[2];\n\n list($column, $values) = $operands;\n\n if (!is_array($values)) {\n $values = [$values];\n }\n\n if (empty($values)) {\n return $not ? '' : '0=1';\n }\n\n if (strpos($column, '(') === false) {\n $column = $this->db->quoteColumnName($column);\n }\n\n $parts = [];\n foreach ($values as $value) {\n if ($value instanceof Expression) {\n foreach ($value->params as $n => $v) {\n $params[$n] = $v;\n }\n $phName = $value->expression;\n } else {\n $phName = self::PARAM_PREFIX . count($params);\n $params[$phName] = empty($escape) ? $value : ('%' . strtr($value, $escape) . '%');\n }\n $parts[] = \"$column $operator $phName\";\n }\n\n return implode($andor, $parts);\n }", "title": "" }, { "docid": "7b2d43f0fa224463fe61e7d3c9a14ec6", "score": "0.4984795", "text": "public function pcLt(string $separator = \"AND\", array $columns): LibPdo {\n try {\n if(!empty($columns)) {\n $this -> conditionFiller[key($columns)] = current($columns);\n if(!empty($columnNames = array_keys($columns))) {\n if($this ->conditionString) {\n $this -> conditionString.=\" $separator \".$columnNames[0].\" < :\".$columnNames[0];\n } else {\n $this -> conditionString = $columnNames[0].\" < :\".$columnNames[0];\n }\n }\n }\n } catch(\\Throwable $t) {\n echo $t -> getMessage();\n }\n return $this;\n }", "title": "" }, { "docid": "9e39270afce135958942a1c58d1b7924", "score": "0.49698842", "text": "private function formCondition($specOperator, $field, $comparison) {\r\n\t\t$condition = \"$specOperator {$field} {$comparison} ?\";\r\n\t\treturn $condition;\r\n\t}", "title": "" }, { "docid": "a2fdffb1f834b5a1166527e3274b43e6", "score": "0.496718", "text": "public function buildSimpleCondition($operator, $operands, &$params)\n {\n if (count($operands) !== 2) {\n throw new InvalidParamException(\"Operator '$operator' requires two operands.\");\n }\n\n list($column, $value) = $operands;\n\n if (strpos($column, '(') === false) {\n $column = $this->db->quoteColumnName($column);\n }\n\n if ($value === null) {\n return \"$column $operator NULL\";\n } elseif ($value instanceof Expression) {\n foreach ($value->params as $n => $v) {\n $params[$n] = $v;\n }\n return \"$column $operator {$value->expression}\";\n } elseif ($value instanceof Query) {\n list($sql, $params) = $this->build($value, $params);\n return \"$column $operator ($sql)\";\n } else {\n $phName = self::PARAM_PREFIX . count($params);\n $params[$phName] = $value;\n return \"$column $operator $phName\";\n }\n }", "title": "" }, { "docid": "a59780b3edd8193aaf1b835455fcf537", "score": "0.49622598", "text": "protected function getSqlOperator(){\n\t\tif(is_null($this->value)){\n\t\t\treturn \"IS\";\n\t\t}\n\t\tif($this->operator == \"contains\"){\n\t\t\treturn \"LIKE\";\n\t\t}\n\t\tif($this->operator == \"notcontains\"){\n\t\t\treturn \"NOT LIKE\";\n\t\t}\n\t\tif($this->operator == \"startswith\"){\n\t\t\treturn \"LIKE\";\n\t\t}\n\t\tif($this->operator == \"endswith\"){\n\t\t\treturn \"LIKE\";\n\t\t}\n\t\tif($this->operator == \"in\"){\n\t\t\treturn \"IN\";\n\t\t}\n\t\tif($this->operator == \"range\"){\n\t\t\treturn \"BETWEEN\";\n\t\t}\n\t\tif($this->operator == \"eq\" or $this->operator == \"=\"){\n\t\t\treturn \"=\";\n\t\t}\n\t\tif($this->operator == \"noteq\"){\n\t\t\treturn \"<>\";\n\t\t}\n\t\tif($this->operator == \"lt\"){\n\t\t\treturn \"<\";\n\t\t}\n\t\tif($this->operator == \"lte\"){\n\t\t\treturn \"<=\";\n\t\t}\n\t\tif($this->operator == \"gt\"){\n\t\t\treturn \">\";\n\t\t}\n\t\tif($this->operator == \"gte\"){\n\t\t\treturn \">=\";\n\t\t}\n\t\tthrow new \\UnexpectedValueException(\"Operator {$this->operator} is not recognized\");\n\t}", "title": "" }, { "docid": "b6797f107679418eaae575dd81d946da", "score": "0.49567208", "text": "function query($args, $operator = 'AND')\n {\n }", "title": "" }, { "docid": "01af9dc50061ff8b009a1a26a1d14e7f", "score": "0.4953519", "text": "function operator_spaceship($a, $b)\n{\n return $a <=> $b;\n}", "title": "" }, { "docid": "dcbae845136c7b1659e3b89fc4fafa5c", "score": "0.49484727", "text": "public function testWhere1() {\n \t$condition = array(\"AND\"=>array(\"=\"=>array(\"field1\"=>\"value1\", \"field2\"=>\"value2\"), \">\"=>array(\"field3\"=>\"value3\")));\n\t\t$result = $this->object->where($condition)->getWherePart();\n\t\t$compare = \" WHERE [field1] = 'value1' AND [field2] = 'value2' AND [field3] > 'value3' \";\n\t\t$this->assertEquals($compare, $result);\n }", "title": "" }, { "docid": "3ab47b59528acdc5d28c79993fea8679", "score": "0.4946744", "text": "public function like($x, $y)\n {\n return new Comparison($x, 'LIKE', $y);\n }", "title": "" }, { "docid": "15d8b80eeb9a3c021a647213643717a8", "score": "0.49450716", "text": "public function where($expr = null, array $args = array())\n {\n if (!$this->where) {\n $this->where = new Conditions();\n }\n if ($expr) {\n if (is_string($expr)) {\n $this->where->raw($expr, $args);\n } elseif (is_array($expr)) {\n foreach ($expr as $key => $val) {\n $this->where->equal($key, $val);\n }\n } else {\n throw new InvalidArgumentException(\"Unsupported argument type of 'where' method.\");\n }\n }\n\n return $this->where;\n }", "title": "" }, { "docid": "25e74256ac0eb5977bd974865a829d4b", "score": "0.49379128", "text": "public function parseEq($expr1, $operator, $expr2)\n\t{\n\t\t$parsedExpr1 = $this->parser->parse($expr1);\n\t\t$parsedExpr2 = $this->parser->parse($expr2);\n\n\t\t$operator = $operator[0] . '=';\n\t\tif (in_array('String', $parsedExpr1['groups'], true) && in_array('String', $parsedExpr2['groups'], true))\n\t\t{\n\t\t\t$operator .= '=';\n\t\t}\n\n\t\treturn $parsedExpr1['value'] . $operator . $parsedExpr2['value'];\n\t}", "title": "" }, { "docid": "41649037eb67c6a5c328c824fa4a26ba", "score": "0.49252224", "text": "public function __construct($comparison, MQB_Field $left, $right = null)\n {\n $comparison = strtolower($comparison);\n if (!in_array($comparison, $this->validConditions))\n throw new RangeException('invalid comparator-function');\n if ($comparison == 'in') {\n if (is_array($right)) {\n // IN (1,2,3,4)\n foreach ($right as $value) {\n if (!is_numeric($value)) {\n throw new InvalidArgumentException('Right-op has to be array consisting of NUMERIC VALUES, if comparison is \"in\"');\n }\n }\n } else {\n // IN (SELECT …)\n if (!is_object($right) or !($right instanceof SelectQuery)) {\n throw new InvalidArgumentException('Right-op has to be object of class SelectQuery, if comparison is \"in\"');\n }\n if ($right->countSelects() != 1) {\n throw new InvalidArgumentException('Right-op has to be query with one field, if comparison is \"in\"');\n }\n }\n } elseif (!in_array($comparison, $this->validSingulars)) {\n if (is_scalar($right)) {\n $right = new Parameter($right);\n } elseif (null !== $right and !($right instanceof Parameter) and !($right instanceof MQB_Field)) {\n throw new InvalidArgumentException('Right-op has to be Parameter or MQB_Field. Got '.get_class($right).' instead');\n }\n }\n $this->content = array($comparison, $left, $right);\n }", "title": "" }, { "docid": "95b466efd7b7ce4852e235f9c8ee2287", "score": "0.48838645", "text": "private function buildCondition($operator, $conditions)\n {\n if (empty($conditions)) {\n return;\n }\n\n //Prepare the where portion of the query\n $this->query .= ' '.$operator;\n\n foreach ($conditions as $cond) {\n list ($concat, $varName, $operator, $val) = $cond;\n $this->query .= \" \".$concat.\" \".$varName;\n\n switch (strtolower($operator)) {\n case 'not in':\n case 'in':\n $comparison = ' '.$operator.' (';\n if (is_object($val)) {\n $comparison .= $this->buildPair(\"\", $val);\n } else {\n foreach ($val as $v) {\n $comparison .= ' ?,';\n $this->params[] = $v;\n }\n }\n $this->query .= rtrim($comparison, ',').' ) ';\n break;\n case 'not between':\n case 'between':\n $this->query .= \" $operator ? AND ? \";\n $this->params = array_merge($this->params, $val);\n break;\n case 'not exists':\n case 'exists':\n $this->query.= $operator.$this->buildPair(\"\", $val);\n break;\n default:\n if (is_array($val)) {\n $this->params = array_merge($this->params, $val);\n } elseif ($val === null) {\n $this->query .= ' '.$operator.\" NULL\";\n } elseif ($val != 'DBNULL' || $val == '0') {\n $this->query .= $this->buildPair($operator, $val);\n }\n }\n }\n }", "title": "" }, { "docid": "51c346962ac119efca4f312170362626", "score": "0.48569465", "text": "public function compare($column, $operator, $value, $filter = false)\n {\n return $this->constraint(__FUNCTION__, $column, $operator, $value, $filter);\n }", "title": "" }, { "docid": "99552bab578f31ccad598a27edc10bf5", "score": "0.48537356", "text": "protected function resolveOperator($operator) {\n\t\tswitch ($operator) {\n\t\t\tcase self::OPERATOR_EQUAL_TO_NULL:\n\t\t\t\t$operator = 'IS';\n\t\t\t\tbreak;\n\t\t\tcase self::OPERATOR_NOT_EQUAL_TO_NULL:\n\t\t\t\t$operator = 'IS NOT';\n\t\t\t\tbreak;\n\t\t\tcase \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_IN:\n\t\t\t\t$operator = 'IN';\n\t\t\t\tbreak;\n\t\t\tcase \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_EQUAL_TO:\n\t\t\t\t$operator = '=';\n\t\t\t\tbreak;\n\t\t\tcase \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_NOT_EQUAL_TO:\n\t\t\t\t$operator = '!=';\n\t\t\t\tbreak;\n\t\t\tcase \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_LESS_THAN:\n\t\t\t\t$operator = '<';\n\t\t\t\tbreak;\n\t\t\tcase \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_LESS_THAN_OR_EQUAL_TO:\n\t\t\t\t$operator = '<=';\n\t\t\t\tbreak;\n\t\t\tcase \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_GREATER_THAN:\n\t\t\t\t$operator = '>';\n\t\t\t\tbreak;\n\t\t\tcase \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_GREATER_THAN_OR_EQUAL_TO:\n\t\t\t\t$operator = '>=';\n\t\t\t\tbreak;\n\t\t\tcase \\TYPO3\\CMS\\Extbase\\Persistence\\QueryInterface::OPERATOR_LIKE:\n\t\t\t\t$operator = 'LIKE';\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tthrow new \\TYPO3\\CMS\\Extbase\\Persistence\\Generic\\Exception('Unsupported operator encountered.', 1242816073);\n\t\t}\n\t\treturn $operator;\n\t}", "title": "" }, { "docid": "edb6ec0540681b8e306470781bc2b377", "score": "0.4843214", "text": "public static function lessThanOrEqual($value): self\n {\n return new self('<=', $value);\n }", "title": "" }, { "docid": "f50ba7240a3b32c1b34eeb7b5b27462c", "score": "0.4817982", "text": "private function compare($value1, $value2, $operator = '==')\n {\n switch ($operator) {\n case '==':\n return $value1 == $value2;\n case '===':\n return $value1 === $value2;\n case '!=':\n return $value1 != $value2;\n case '!==':\n return $value1 !== $value2;\n case '<':\n return $value1 < $value2;\n case '>':\n return $value1 > $value2;\n case '<=':\n return $value1 <= $value2;\n case '>=':\n return $value1 >= $value2;\n default:\n return $value1 == $value2;\n }\n }", "title": "" }, { "docid": "cf7de439d06332771f72011b4f486231", "score": "0.4814075", "text": "public function pcGt(string $separator = \"AND\", array $columns): LibPdo {\n try {\n if(!empty($columns)) {\n $this -> conditionFiller[key($columns)] = current($columns);\n if(!empty($columnNames = array_keys($columns))) {\n if($this ->conditionString) {\n $this -> conditionString.=\" $separator \".$columnNames[0].\" > :\".$columnNames[0];\n } else {\n $this -> conditionString = $columnNames[0].\" > :\".$columnNames[0];\n }\n }\n }\n } catch(\\Throwable $t) {\n echo $t -> getMessage();\n }\n return $this;\n }", "title": "" }, { "docid": "92b984adea7df0acbfb96ba64dc9ab29", "score": "0.48085296", "text": "public function compare($object1, $object2);", "title": "" }, { "docid": "07cba90368c6365a1aa2d9a65fa8cf87", "score": "0.47949445", "text": "function Operator($valueFirst, $valueSecond)\n{\n /*Operator ==*/\n echo \"Operator ==:<br/>\";\n\n if ($valueFirst == $valueSecond) {\n echo \"True\";\n } else {\n echo \"False\";\n }\n\n /*Operator ===*/\n echo \"<br/>Operator ===:<br/>\";\n\n if ($valueFirst === $valueSecond) {\n echo \"True\";\n } else {\n echo \"False\";\n }\n}", "title": "" }, { "docid": "0a28d4d4b16de01a2071b6451b57b441", "score": "0.47898975", "text": "private function makeComparerCB() { \n // Normalize criteria up front so that the comparer finds everything tidy\n $criteria = func_get_args();\n foreach ($criteria as $index => $criterion) {\n $criteria[$index] = is_array($criterion)\n ? array_pad($criterion, 3, null)\n : array($criterion, SORT_ASC, null);\n }\n\n return function($first, $second) use (&$criteria) {\n foreach ($criteria as $criterion) {\n // How will we compare this round?\n list($column, $sortOrder, $projection) = $criterion;\n $sortOrder = $sortOrder === SORT_DESC ? -1 : 1;\n\n // If a projection was defined project the values now\n if ($projection) {\n $lhs = call_user_func($projection, $first[$column]);\n $rhs = call_user_func($projection, $second[$column]);\n }\n else {\n $lhs = $first[$column];\n $rhs = $second[$column];\n }\n\n // Do the actual comparison; do not return if equal\n if ($lhs < $rhs) {\n return -1 * $sortOrder;\n }\n else if ($lhs > $rhs) {\n return 1 * $sortOrder;\n }\n }\n return 0; // tiebreakers exhausted, so $first == $second\n };\n }", "title": "" }, { "docid": "1e439dda343ec76c1a15dc968148458a", "score": "0.47856334", "text": "public function buildAndCondition($operator, $operands, &$params)\n {\n $parts = [];\n foreach ($operands as $operand) {\n if (is_array($operand)) {\n $operand = $this->buildCondition($operand, $params);\n }\n if ($operand !== '') {\n $parts[] = $operand;\n }\n }\n if (!empty($parts)) {\n return implode(\" $operator \", $parts);\n } else {\n return '';\n }\n }", "title": "" }, { "docid": "ae4aae13629cf18aaaa146643f575e3c", "score": "0.47834176", "text": "private function convertComparator($comparator)\n {\n switch ($comparator) {\n case '':\n $comparator = '==';\n break;\n case 'lt':\n $comparator = '<';\n break;\n case 'lte':\n $comparator = '<=';\n break;\n case 'ne':\n $comparator = '<>';\n break;\n case 'gte':\n $comparator = '>=';\n break;\n case 'gt':\n $comparator = '>';\n break;\n\n default:\n throw new \\InvalidArgumentException(\n sprintf(\n 'The comparator \"%s\" is invalid',\n $comparator\n )\n );\n }\n\n return $comparator;\n }", "title": "" }, { "docid": "9fd60c34c04255ac14d7f5979fc06df3", "score": "0.47815412", "text": "public function where(array $conditions, $operator='AND', $comparison='=')\n {\n $array_keys = array_keys($conditions);\n if (reset($array_keys) === 0 &&\n end($array_keys) === count($conditions) - 1 &&\n !is_array(end($conditions))\n ) {\n $condition = array_shift($conditions);\n\n $this->where[] = array(\n 'query' => $condition,\n 'binds' => $conditions,\n 'operator' => $operator\n );\n } else {\n\n foreach ($conditions as $key => $value) {\n\n if (is_array($value)) {\n\n $this->whereIn($key, $value, $operator);\n } elseif (is_null($value)) {\n\n $this->whereIsNull($key, $operator);\n } else {\n\n $field = $this->get_field_with_table($key);\n\n $this->where[] = array(\n 'query' => \"$field $comparison ?\",\n 'binds' => array($value),\n 'operator' => $operator\n );\n }\n }\n }\n\n return $this;\n }", "title": "" }, { "docid": "5ec3e747df3fc3c07c7be94b8de90c18", "score": "0.4779499", "text": "public function other($column, $condition, $operator = null);", "title": "" }, { "docid": "1981cb8a581bc5197aa799ef4ddcf598", "score": "0.47720617", "text": "function glue_condition($condition) {\r\n\t$key = \"`{$condition['key']}`\";\r\n\t$operator = $condition['operator'];\r\n\tif (in_array($condition['operator'], ['=', '!=', '>', '<'])) {\r\n\t\t$value = process_value($condition['value']);\r\n\t} else if (in_array($condition['operator'], ['in', 'not in'])) {\r\n\t\t$value = \"(\".glue_values($condition['value']).\")\";\r\n\t}\r\n\t\r\n\treturn $key.\" \".$operator.\" \".$value;\r\n}", "title": "" }, { "docid": "f733fa2cc0f73bbd82e3aabd2b635016", "score": "0.4767937", "text": "public function comp($leftOperand, $rightOperand)\n {\n throw new Exception\\RuntimeException(\n \"Method \\\"\".__FUNCTION__.\"\\\" not supported in adapter\"\n );\n }", "title": "" }, { "docid": "a41b8d2940f81c3058a782fe3414109c", "score": "0.47678447", "text": "protected function _processLesser(&$first, &$second) {\n\n if (!isset($first['$lt'])) {\n return;\n }\n\n if (isset($second['$gt']) && $this->_isLesser($first['$lt'], $second['$gt'], false)) {\n throw new QueryRewriteException('Invalid condition');\n }\n\n if (isset($second['$gte']) && $this->_isLesser($first['$lt'], $second['$gte'], false)) {\n throw new QueryRewriteException('Invalid condition');\n }\n\n if (isset($second['$lt'])) {\n\n if ($this->_isGreater($first['$lt'], $second['$lt'])) {\n unset($first['$lt']);\n return;\n } else {\n unset($second['$lt']);\n }\n\n }\n\n if (isset($second['$lte'])) {\n\n if ($this->_isGreater($first['$lt'], $second['$lte'])) {\n unset($first['$lt']);\n return;\n } else {\n unset($second['$lte']);\n }\n\n }\n\n }", "title": "" }, { "docid": "aa0b32c34a12afe8e2796542548d32cc", "score": "0.4760559", "text": "function db_string_equal_to($attribute, $compare)\n{\n return $GLOBALS['DB_STATIC_OBJECT']->db_string_equal_to($attribute, $compare);\n}", "title": "" }, { "docid": "63bdf259d2f749fad4bfbf7b2a29d061", "score": "0.475927", "text": "abstract protected function doCompare($left, $right);", "title": "" }, { "docid": "4e5f8d78f56744dc61e607c19982ce68", "score": "0.4751065", "text": "private function processEqualOrGreaterOrLesser($startPosition, $operator) {\n \n /*\n * <equal>, <greater> or <lesser>\n */\n $valuedUnitQuantity = $this->getValuedUnitQuantity($startPosition);\n if (isset($valuedUnitQuantity)) {\n if (isset($valuedUnitQuantity['valuedUnit'])) {\n if (isset($valuedUnitQuantity['valuedUnit']['unit'])) {\n $value = (floatval($valuedUnitQuantity['valuedUnit']['value']) * $valuedUnitQuantity['valuedUnit']['unit']['factor']);\n }\n else {\n $value = (floatval($valuedUnitQuantity['valuedUnit']['value']));\n }\n switch ($operator) {\n case WhatProcessor::EQUAL:\n $this->addToResult(array($valuedUnitQuantity['quantity']['key'] => $value));\n break;\n case WhatProcessor::GREATER:\n $this->addToResult(array($valuedUnitQuantity['quantity']['key'] => ']' .$value));\n break;\n case WhatProcessor::LESSER:\n $this->addToResult(array($valuedUnitQuantity['quantity']['key'] => $value . '['));\n break;\n }\n }\n $this->queryManager->discardPositionInterval(__METHOD__, $valuedUnitQuantity['startPosition'], $valuedUnitQuantity['endPosition'], isset($valuedUnitQuantity['error']) ? $valuedUnitQuantity['error'] : null);\n \n return true;\n \n }\n return false;\n }", "title": "" }, { "docid": "de04ce0efe6381ba6973b2e1b75388ac", "score": "0.47481236", "text": "protected function buildCompositeInCondition($operator, $columns, $values, &$params)\n {\n $vss = [];\n foreach ($values as $value) {\n $vs = [];\n foreach ($columns as $column) {\n if (isset($value[$column])) {\n $phName = self::PARAM_PREFIX . count($params);\n $params[$phName] = $value[$column];\n $vs[] = $phName;\n } else {\n $vs[] = 'NULL';\n }\n }\n $vss[] = '(' . implode(', ', $vs) . ')';\n }\n foreach ($columns as $i => $column) {\n if (strpos($column, '(') === false) {\n $columns[$i] = $this->db->quoteColumnName($column);\n }\n }\n\n return '(' . implode(', ', $columns) . \") $operator (\" . implode(', ', $vss) . ')';\n }", "title": "" }, { "docid": "893e5f97a49b5ddbbf9c77a7b4bfc8d2", "score": "0.47426873", "text": "function GreaterThan($lesser) {\n if ( is_object($lesser) ) {\n// eZDebug::writeDebug( \"RRule\", \" Comparing %s with %s\", $this->_text, $lesser->_text );\n return ( $this->_text > $lesser->_text );\n }\n// eZDebug::writeDebug( \"RRule\", \" Comparing %s with %s\", $this->_text, $lesser );\n return ( $this->_text > $lesser ); // These sorts of dates are designed that way...\n }", "title": "" }, { "docid": "56e8e4bc91f369193e3cc87cb4b0bc12", "score": "0.4736415", "text": "public function notEqual($x, $y)\n {\n return new Comparison($x, Comparison::NEQ, $y);\n }", "title": "" }, { "docid": "54cbfab99802195cf36df7d7f0076023", "score": "0.47359148", "text": "protected function comparisionTypeGrammar()\n {\n if ($this->type !== 'date') {\n switch ($this->criteria['comparision_type']) {\n case 'equals_to':\n $query = function ($query) {\n $query->where($this->field, '=', $this->criteria['value']);\n };\n break;\n\n case 'start_with':\n $query = function ($query) {\n $query->where($this->field, 'like', $this->criteria['value'] . '%');\n };\n break;\n\n case 'end_with':\n $query = function ($query) {\n $query->where($this->field, 'like', '%' . $this->criteria['value']);\n };\n break;\n\n case 'like':\n $query = function ($query) {\n $query->where($this->field, 'like', '%' . $this->criteria['value'] . '%');\n };\n break;\n\n default:\n throw new CriteriaException(\n 'Unrecognized ' . $this->criteria['comparision_type'] . ' comparision type.'\n );\n }\n } else {\n $query = function ($query) {\n $query->whereBetween($this->field, [$this->criteria['start_date'], $this->criteria['end_date']]);\n };\n }\n\n\n return $query;\n }", "title": "" }, { "docid": "8c19be3ec7af3bfd3e4f33f7e7fff932", "score": "0.47265524", "text": "protected function _processLesserOrEqual(&$first, &$second) {\n\n if (!isset($first['$lte'])) {\n return;\n }\n\n if (isset($second['$gt']) && $this->_isLesser($first['$lte'], $second['$gt'], false)) {\n throw new QueryRewriteException('Invalid condition');\n }\n\n if (isset($second['$gte']) && $this->_isLesser($first['$lte'], $second['$gte'])) {\n throw new QueryRewriteException('Invalid condition');\n }\n\n if (isset($second['$lt'])) {\n\n if ($this->_isGreater($first['$lte'], $second['$lt'], false)) {\n unset($first['$lte']);\n return;\n } else {\n unset($second['$lt']);\n }\n\n }\n\n if (isset($second['$lte'])) {\n\n if ($this->_isGreater($first['$lte'], $second['$lte'])) {\n unset($first['$lte']);\n return;\n } else {\n unset($second['$lte']);\n }\n\n }\n\n if (isset($second['$nin']) && in_array($first['$lte'], $second['$nin'])) {\n $first['$lt'] = $first['$lte'];\n unset($first['$lte']);\n }\n\n }", "title": "" }, { "docid": "608bbe2ad1d4122580e5c2fab8f5655c", "score": "0.47238353", "text": "function wpc_condition_operators() {\n\n\t\t$condition_operators = array(\n\t\t\t// Add default for when a custom condition doesn't properly add the available operators\n\t\t\t'default' => array(\n\t\t\t\t'==' => __( 'Equal to', 'wpc-conditions' ),\n\t\t\t\t'!=' => __( 'Not equal to', 'wpc-conditions' ),\n\t\t\t\t'>=' => __( 'Greater or equal to', 'wpc-conditions' ),\n\t\t\t\t'<=' => __( 'Less or equal to ', 'wpc-conditions' ),\n\t\t\t),\n\t\t);\n\n\t\tforeach ( wpc_get_registered_conditions() as $condition ) {\n\t\t\t$condition_operators[ $condition->get_slug() ] = $condition->get_available_operators();\n\t\t}\n\n\t\treturn apply_filters( 'wp-conditions\\condition_operators', $condition_operators );\n\n\t}", "title": "" }, { "docid": "59bd75468324a786230a0bbd899f20eb", "score": "0.47102633", "text": "protected function parseComparisonField(string $field) : string\n {\n if (!$this->isAQueryableField($field)) {\n throw new NotQueryableFieldException($field);\n }\n\n //return mb_strpos($field, '.') ? \"{$field}\" : $field;\n return $field;\n }", "title": "" }, { "docid": "ad6ee01c63b1f1150027815e39b132f7", "score": "0.47078028", "text": "public function min(string $leftOperand, string $rightOperand): string;", "title": "" }, { "docid": "de5cd38ed2f1167a045dd6148de05757", "score": "0.47054762", "text": "public function testCompare($leftVersion, $rightVersion, $operator, $expectedReturn)\n {\n $leftVersion = new Version($leftVersion);\n\n static::assertSame($expectedReturn, $leftVersion->compare($rightVersion, $operator));\n static::assertSame($expectedReturn, $leftVersion->compare(new Version($rightVersion), $operator));\n }", "title": "" }, { "docid": "909a0ca783c90ed5dfb9129d52ce066d", "score": "0.47053683", "text": "function compareFloatNumbers($float1, $float2, $operator = '=') {\n // Check numbers to 5 digits of precision \n $epsilon = 0.00001;\n\n $float1 = (float) $float1;\n $float2 = (float) $float2;\n\n switch ($operator) {\n // equal \n case \"=\":\n case \"eq\": {\n if (abs($float1 - $float2) < $epsilon) {\n return true;\n }\n break;\n }\n // less than \n case \"<\":\n case \"lt\": {\n if (abs($float1 - $float2) < $epsilon) {\n return false;\n } else {\n if ($float1 < $float2) {\n return true;\n }\n }\n break;\n }\n // less than or equal \n case \"<=\":\n case \"lte\": {\n if (compareFloatNumbers($float1, $float2, '<') || compareFloatNumbers($float1, $float2, '=')) {\n return true;\n }\n break;\n }\n // greater than \n case \">\":\n case \"gt\": {\n if (abs($float1 - $float2) < $epsilon) {\n return false;\n } else {\n if ($float1 > $float2) {\n return true;\n }\n }\n break;\n }\n // greater than or equal \n case \">=\":\n case \"gte\": {\n if (compareFloatNumbers($float1, $float2, '>') || compareFloatNumbers($float1, $float2, '=')) {\n return true;\n }\n break;\n }\n case \"<>\":\n case \"!=\":\n case \"ne\": {\n if (abs($float1 - $float2) > $epsilon) {\n return true;\n }\n break;\n }\n default: {\n die(\"Unknown operator '\" . $operator . \"' in compareFloatNumbers()\");\n }\n }\n\n return false;\n}", "title": "" }, { "docid": "46ea2974e54d2110dfbf255e38b59436", "score": "0.47046706", "text": "function where($column_name, $comparison_operator = null, $value = null, $type = \"AND\")\n {\n if ($comparison_operator !== null and is_string($comparison_operator) == false) {\n throw new \\InvalidArgumentException(\"The second parameter in where method in \" . get_class($this) . \" MUST be of type String: \" . gettype($comparison_operator) . \" given\");\n }\n if ($value !== null and (is_string($value) == false and is_numeric($value) == false)) {\n throw new \\InvalidArgumentException(\"The third parameter in where method in \" . get_class($this) . \" MUST be of type String: \" . gettype($value) . \" given\");\n }\n if (isset($this->sql[\"where\"]) == false) {\n $this->sql[\"where\"] = array();\n }\n if (is_string($column_name)) {\n $this->sql[\"where\"][] = array(\"COLUMN\" => $column_name, \"OPERATOR\" => $comparison_operator, \"VALUE\" => $value, \"TYPE\" => $type);\n }\n if (is_array($column_name)) {\n $array = [];\n foreach ($column_name as $entry) {\n $entryColumnName = isset($entry[0]) ? $entry[0] : '';\n $entryComparisonOperator = isset($entry[1]) ? $entry[1] : null;\n $entryValue = isset($entry[2]) ? $entry[2] : null;\n $entryType = isset($entry[3]) ? $entry[3] : 'AND';\n $array[] = array(\"COLUMN\" => $entryColumnName, \"OPERATOR\" => $entryComparisonOperator, \"VALUE\" => $entryValue, \"TYPE\" => $entryType);\n }\n $this->sql[\"where\"][] = array(\"WHERE\" => $array, \"TYPE\" => $type);\n }\n return $this;\n }", "title": "" }, { "docid": "71f461063e0f6ad3158899773cef5cf2", "score": "0.46994808", "text": "public function __toString(): string\n {\n return 'is less than ' . export($this->expected);\n }", "title": "" }, { "docid": "fca016d130a3db44724908fad53dc612", "score": "0.46893114", "text": "public static function buildWhere($column, $value, $compare=\"=\")\n\t{\n\t\t// Prepare\n\t\t$compare = empty($compare) ? '=' : trim(strtoupper($compare));\n\t\t\n\t\t// Handle some simple and common cases, just to improve performance\n\t\tif (is_string($column)) {\n\t\t\tif (self::countPlaceholders($column) != 0) {\n\t\t\t\treturn array('where'=>self::parse($column, $value));\n\t\t\t} else if (isset($value) && !is_array($value) && ($compare === '=' || $compare === '!=' || $compare === '>' || $compare === '<' || $compare === '>=' || $compare === '<=')) {\n\t\t\t\treturn array('where'=>\"$column $compare \" . self::quote($value));\n\t\t\t} elseif ($compare === 'IS NULL' || $compare === 'IS NOT NULL') {\n\t\t\t if (isset($value) && $value !== '' && (int)$value == 0) $compare = $compare === 'IS NULL' ? 'IS NOT NULL' : 'IS NULL';\n\t\t\t\treturn array('where'=>\"$column $compare\");\n\t\t\t}\n\t\t}\n\t\t\n\t\t// Prepare\n\t\t$column = (array)$column;\n\t\t$value = (array)$value;\n\n\t\tif ($compare === 'ANY' || ($compare === '=' && sizeof($value)>1)) $compare = 'IN';\n\t\t \n\t\t// Only use the non-null values with between, autoconvert to >= or <=\n\t\tif (($compare===\"BETWEEN\" || $compare===\"NOT BETWEEN\") && (isset($value[0]) xor isset($value[1]))) {\n\t\t\t$compare = ($compare===\"BETWEEN\" xor isset($value[0])) ? '<=' : '>=';\n\t\t\t$value = isset($value[0]) ? array($value[0]) : array($value[1]);\n\t\t}\n\t\t\n\t\t// Quote value. (For LIKE: Apply % for %LIKE% to value)\n\t\t$matches = null;\n\t\tif (preg_match('/^(\\%?)(?:REVERSE\\s+)?LIKE(\\%?)$/', $compare, $matches)) {\n\t\t\tif (isset($value)) {\n\t\t\t\tforeach ($value as &$val) $val = DB_MySQL_SQLSplitter::quote((isset($matches[1]) ? $matches[1] : \"\") . addcslashes($val, '%_') . (isset($matches[2]) ? $matches[2] : \"\"));\n\t\t\t}\n\t\t\t$compare = trim($compare, \"%\");\n\t\t} elseif (isset($value)) {\n\t\t\tforeach ($value as &$val) $val = DB_MySQL_SQLSplitter::quote($val);\n\t\t}\n\t\tunset($val);\n\n\t\t// Apply reverse -> value LIKE column, instead of column LIKE value\n\t\tif (substr($compare, 0, 8) === 'REVERSE ') {\n\t\t\t$tmp = $column;\n\t\t\t$column = $value;\n\t\t\t$value = $tmp;\n\t\t\t$compare = trim(substr($compare, 8));\n\t\t}\n\n\t\t// Compare as in any\n\t\tif ($compare === \"IN\" || $compare === \"NOT IN\" || $compare === \"ALL\") $value = array_unique($value);\n\t\t\n\t\t// Create where expression for each column (using if, instead of switch for performance)\n\t\t$where = null;\n\t\t$having = null;\n\t\t\n\t\tif ($compare === \"ALL\") {\n\t\t\tif (!isset($value)) throw new Exception(\"Unable to add '$compare' criteria: \\$value is not set\");\n\t\t\tif (!empty($value)) {\n\t\t\t foreach ($column as $col) {\n \t\t\t\t$having[] = \"COUNT(DISTINCT $col) = \" . sizeof($value);\n\t \t\t\t$where[] = \"$col IN (\" . join(\", \", $value) . \")\";\n\t\t \t}\n\t\t\t}\n\t\t\n\t\t} elseif ($compare === \"IN\" || $compare === \"NOT IN\") {\n\t\t\tif (!isset($value)) throw new Exception(\"Unable to add '$compare' criteria: \\$value is not set\");\n\t\t\tif (!empty($value)) {\n\t\t\t foreach ($column as $col) $where[] = \"$col $compare (\" . join(\", \", $value) . \")\";\n\t\t\t}\n\t\t\n\t\t} elseif ($compare === \"BETWEEN\" || $compare === \"NOT BETWEEN\") {\n\t\t\tif (sizeof($value) != 2) throw new Exception(\"Unable to add '$compare' criteria: \\$value should have exactly 2 items, but has \" . sizeof($value) . \" items\");\n\t\t\tforeach ($column as $col) $where[] = \"$col $compare \" . $value[0] . \" AND \" . $value[1];\n\n\t\t} elseif ($compare === \"IS NULL\" || $compare === \"IS NOT NULL\") {\n\t\t if (isset($value) && $value !== '' && (int)$value == 0) $compare = $compare === 'IS NULL' ? 'IS NOT NULL' : 'IS NULL';\n\t\t if (!empty($value)) {\n\t\t foreach ($column as $col) $where[] = \"$col $compare\";\n\t\t }\n\t\t\t\n\t\t} else {\n\t\t\tif (!isset($value)) throw new Exception(\"Unable to add '$compare' criteria: \\$value is not set\");\n\t\t\tif (!empty($value)) {\n\t\t\t foreach ($column as $col) {\n\t\t\t \tforeach ($value as $val) $where[] = \"$col $compare $val\";\n\t\t\t }\n\t\t\t}\n\t\t}\n\n\t\t// Return where expression\n\t\treturn array('where'=>isset($where) ? join(\" OR \", $where) : null, 'having'=>isset($having) ? join(\" OR \", $having) : null);\n\t}", "title": "" }, { "docid": "339d0e46cec6b9e129c0577759d2917d", "score": "0.46871254", "text": "public function addColumnsComparation(\n string $column1,\n string $column2,\n string $operator = self::OP_EQUAL,\n string $expression = self::COND_AND\n ) {\n $this->conditions[] = new Condition($column1, $column2, $operator, $expression, true);\n }", "title": "" }, { "docid": "98408d4c0aacdbd9ac942080e4ffdf15", "score": "0.4686206", "text": "public function renderExtendedCondition($extCond )\n {\n\n $sql = '';\n\n $isCS = (isset($extCond[self::CASE_SENSITIVE]) && $extCond[self::CASE_SENSITIVE]);\n\n $sql .= isset($extCond[self::NOT]) && $extCond[self::NOT]\n ? ' NOT '\n : '';\n\n if ($isCS) {\n $sql .= 'UPPER('.$extCond[self::SOURCE_KEY].'.'.$extCond[self::FIELD].')';\n } else {\n $sql .= $extCond[self::SOURCE_KEY].'.'.$extCond[self::FIELD];\n }\n\n if ('in' != $extCond[self::OPERATOR]) {\n $value = $this->db->escape($extCond[self::VALUE]);\n } else {\n $value = $extCond[self::VALUE];\n }\n\n switch ($extCond[self::OPERATOR]) {\n case 'equals': {\n if ($isCS)\n $sql .= \" = UPPER('{$value}') \";\n else\n $sql .= \" = '{$value}' \";\n\n break;\n }\n case 'null': {\n $sql .= \" IS NULL \";\n break;\n }\n case 'like': {\n if ($isCS)\n $sql .= \" like UPPER('%{$value}%') \";\n else\n $sql .= \" like '%{$value}%' \";\n\n break;\n }\n case 'start_with': {\n if ($isCS)\n $sql .= \" like UPPER('{$value}%') \";\n else\n $sql .= \" like '{$value}%' \";\n\n break;\n }\n case 'end_with': {\n if ($isCS)\n $sql .= \" like UPPER('%{$value}') \";\n else\n $sql .= \" like '%{$value}' \";\n\n break;\n }\n case 'before': {\n\n $sql .= \" < '{$value}' \";\n\n break;\n }\n case 'after': {\n\n $sql .= \" > '{$value}' \";\n\n break;\n }\n case 'in': {\n\n if (is_array($value)) {\n\n $tmp = [];\n\n if ($isCS) {\n\n foreach ($value as $vNode) {\n $tmp[] = \"UPPER('\".$this->db->escape($vNode).\"')\";\n }\n\n $sql .= \" IN(\".implode(', ', $tmp).\") \";\n } else {\n $sql .= \" IN('\".implode(\"', '\", $value).\"') \";\n }\n } else {\n $sql .= \" IN({$value}) \";\n }\n\n break;\n }\n default: {\n throw new LibDb_Exception(\"Got nonsupported extended condition operator: \".$extCond[self::OPERATOR]);\n }\n\n }\n\n return $sql;\n\n }", "title": "" }, { "docid": "12b82e927abc309631d777bd486df342", "score": "0.4677509", "text": "public function __call($name, $args) {\r\n\t\tif (is_callable ( $callback = array (\r\n\t\t\t\t$this->_pdo,\r\n\t\t\t\t$name \r\n\t\t) ))\r\n\t\t\treturn call_user_func_array ( $callback, $args );\r\n\t\tif (in_array ( $name = strtolower ( $name ), array_keys ( self::$operators ) ))\r\n\t\t\t$this->addCondition ( $args [0], self::$operators [$name], isset ( $args [1] ) ? $args [1] : null, (is_string ( end ( $args ) ) && 'or' === strtolower ( end ( $args ) )) ? 'OR' : 'AND' );\r\n\t\telse if (in_array ( $name = str_replace ( 'by', '', $name ), array_keys ( self::$sqlParts ) ))\r\n\t\t\t$this->$name = new Expressions ( array (\r\n\t\t\t\t\t'operator' => self::$sqlParts [$name],\r\n\t\t\t\t\t'target' => implode ( ', ', $args ) \r\n\t\t\t) );\r\n\t\telse\r\n\t\t\tthrow new Exception ( \"Method $name not exist.\" );\r\n\t\treturn $this;\r\n\t}", "title": "" }, { "docid": "982a147c2dd53ea0421b3e2f5d99d195", "score": "0.46752006", "text": "public function compare($test, $operator, $expected, $testName='undefined') {\n $php = sprintf(\"\\$result = \\$test $operator \\$expected;\");\n eval($php);\n $this->saveTest($test, $expected, $result, $testName);\n }", "title": "" }, { "docid": "ce061211c2f54f377665d704dfa93de0", "score": "0.46717963", "text": "function opTest($op, $val1, $val2){\n\t\tswitch($op){\n\t\t\tcase \"eq\":\n\t\t\treturn $val1 == $val2;\n\t\t\tcase \"ne\":\n\t\t\treturn $val1 != $val2;\n\t\t\tcase \"gt\":\n\t\t\treturn $val1 > $val2;\n\t\t\tcase \"gte\":\n\t\t\treturn $val1 >= $val2;\n\t\t\tcase \"lt\":\n\t\t\treturn $val1 < $val2;\n\t\t\tcase \"lte\":\n\t\t\treturn $val1 <= $val2;\n\t\t}\n\t}", "title": "" }, { "docid": "2b4d417a530277c9da12b3899b8220da", "score": "0.46621782", "text": "public function comparision(){\n $result = null;\n\n $lhs=null;\n $rhs = null;\n\n\n try {\n {\n $lhs=$this->match($this->input,$this->getToken('SYMBOL'),self::$FOLLOW_SYMBOL_in_comparision78); if ($this->state->failed) return $result;\n $this->match($this->input,$this->getToken('13'),self::$FOLLOW_13_in_comparision80); if ($this->state->failed) return $result;\n $this->pushFollow(self::$FOLLOW_value_in_comparision84);\n $rhs=$this->value();\n\n $this->state->_fsp--;\n if ($this->state->failed) return $result;\n if ( $this->state->backtracking==0 ) {\n $result=array('==', new VTEventConditionSymbol(($lhs!=null?$lhs->getText():null)), $rhs); echo $value;\n }\n\n }\n\n }\n \n \tcatch (RecognitionException $e) { \n \t\tthrow $e; \n \t} \n catch(Exception $e) {\n throw $e;\n }\n \n return $result;\n }", "title": "" }, { "docid": "187c6d15490d47919462b245a687cffe", "score": "0.46611387", "text": "private function constructSqlDateTimeWhereSubclause($operator,$dateColumn,$dateValue,$timeColumn,$timeValue){\n\t\tswitch($operator){\n\t\t\tcase '<':\n\t\t\tcase '<=':\n\t\t\tcase '>':\n\t\t\tcase '>=':\n\t\t\t\treturn \"($dateColumn $operator $dateValue || ($dateColumn=$dateValue && $timeColumn $operator $timeValue))\";\t\t\t\t\t\n\t\t\tdefault:\n\t\t\t\treturn \"$dateColumn $operator $dateValue && $timeColumn $operator $timeValue\";\n\t\t}\n\t}", "title": "" }, { "docid": "808bff7afb6011029d03db07d3ee83ef", "score": "0.46573395", "text": "public function createExpression()\n {\n return new ezcQueryExpression( $this );\n }", "title": "" }, { "docid": "9d5cfd2d68888401e4c4c18bad19ec09", "score": "0.46573114", "text": "private function _get_where_equal_to_and_or() {\n if (!isset($this->where_equal_to_and_or) || !is_array($this->where_equal_to_and_or) || empty($this->where_equal_to_and_or)) {\n return '';\n } else {\n return \"(\" . self::_get_where_equal_to_or($this->where_equal_to_and_or[0]) . \" OR \\n\\t\" . self::_get_where_equal_to_or($this->where_equal_to_and_or[1]) . \")\";\n }\n }", "title": "" }, { "docid": "f7033d90b8ed2bace5202fb91b971b7a", "score": "0.46477917", "text": "function ObeysExpr ($expr, $variables) {\r\n if (strlen($expr) == 0)\r\n return true;\r\n\r\n if (preg_match('/[^a-zA-Z0-9&|<>= ]/', $expr) > 0) {\r\n IERR('Invalid expression.', $expr);\r\n return false;\r\n }\r\n\r\n preg_match_all('/[a-zA-Z]+/', $expr, $matches);\r\n foreach ($matches[0] as $var) {\r\n if (!isset($variables[$var])) {\r\n IERR('Unknown variable in expression.', array('expr' => $expr, 'var' => $var));\r\n return false;\r\n }\r\n }\r\n\r\n $expr = preg_replace('/([a-zA-Z]+)/', '$\\1', $expr);\r\n\r\n extract($variables, EXTR_SKIP);\r\n\r\n $result = eval('return ' . $expr . ';');\r\n if ($result == NULL)\r\n return false;\r\n\r\n if ($result)\r\n return true;\r\n else\r\n return false;\r\n}", "title": "" } ]
ad282ad0cb8e499e668ebd1430ed62d0
Turn this item object into a generic array
[ { "docid": "e7fb0d8ed1b5a93535295b7cef3825af", "score": "0.0", "text": "public function transform($customer)\n {\n $lastName = issetRetrun($customer, 'last_name') ?: '';\n $jobAddress = $this->getJobAddress($customer);\n $customerAddress = $this->getCustomerAddress($customer);\n\n $data = [\n 'id' => $customer['customer_id'],\n 'company_id' => $customer['company_id'],\n 'first_name' => $customer['first_name'],\n 'last_name' => $lastName,\n 'is_commercial' => (int)$customer['is_commercial'],\n 'company_name' => issetRetrun($customer, 'company_name') ?: '',\n 'job_id' => issetRetrun($customer, 'job_id') ?: '',\n 'job_name' => issetRetrun($customer, 'job_name') ?: '',\n 'number' => issetRetrun($customer, 'number') ?: '',\n 'alt_id' => issetRetrun($customer, 'alt_id') ?: '',\n 'division_code' => issetRetrun($customer, 'division_code') ?: '',\n 'phones' => $this->getPhones($customer),\n 'parent_id' => issetRetrun($customer, 'parent_id') ?: '',\n 'multi_job' => (int)issetRetrun($customer, 'multi_job'),\n 'customer_contact' => $this->getCustomerContact($customer),\n 'trades' => issetRetrun($customer, 'trades') ?: [],\n 'job_resource_id' => issetRetrun($customer, 'job_resource_id') ?: '',\n 'current_stage' => [],\n 'full_name' => $customer['first_name'] . ' ' . $lastName,\n 'full_name_mobile' => $customer['first_name'] . ' ' . $lastName,\n 'job_address' => $jobAddress,\n 'customer_address' => $customerAddress,\n 'full_customer_address' => implode(', ', array_filter($customerAddress)),\n 'full_job_address' => implode(', ', array_filter($jobAddress)),\n 'other_trade_type_description' => issetRetrun($customer, 'other_trade_type_description') ?: '',\n 'score' => $customer['score'],\n 'division' => issetRetrun($customer, 'division') ?: '',\n 'division_id' => (int)issetRetrun($customer, 'division_id') ?: 0,\n 'lost_job' => ine($customer, 'lost_date'),\n 'archived' => ine($customer, 'archived'),\n ];\n\n if (ine($customer, 'job_id')) {\n $data['current_stage'] = $this->getCurrentStage($customer);\n }\n\n return $data;\n }", "title": "" } ]
[ { "docid": "c35dd66e567a5aec7f9be59c6799ebe2", "score": "0.733577", "text": "public function toArray()\n {\n return $this->item;\n }", "title": "" }, { "docid": "ed24bc77dfb4c354ef2fabc75a6dc13f", "score": "0.72740287", "text": "public function toArray()\n\t{\n\t\t$items = array();\n\t\tforeach ($this->items as $key => $item) {\n\t\t\tif (is_object($item) && method_exists($item, \"toArray\")) {\n\t\t\t\t$items[$key] = $item->toArray();\n\t\t\t} else {\n\t\t\t\t$items[$key] = $item;\n\t\t\t}\n\t\t}\n\n\t\treturn $items;\n\t}", "title": "" }, { "docid": "b0b5b0a6e4c24f45e35cabe08d24c890", "score": "0.72460127", "text": "public function toArray(): array\r\n {\r\n $items = [];\r\n\r\n foreach ($this->items as $item) {\r\n $items[] = Factory::make($item)->toArray();\r\n }\r\n\r\n return $items;\r\n }", "title": "" }, { "docid": "2d986a3ef78fbe2395bb190bf90a703d", "score": "0.72156876", "text": "public function toArray()\n {\n $items = [];\n foreach ($this->items as $key => $item) {\n if (is_numeric($item)) {\n $item = DataObject::get_by_id($this->dataClass, $item);\n }\n if (!empty($this->extraFields[$key])) {\n $item->update($this->extraFields[$key]);\n }\n $items[] = $item;\n }\n return $items;\n }", "title": "" }, { "docid": "f0a56b9a81f05eac93d6b1dd965d81df", "score": "0.717355", "text": "public function toArray(){\n\t\treturn $this->items;\n\t}", "title": "" }, { "docid": "eb24fa55bfe93e6feee648ddc4b08c25", "score": "0.71438384", "text": "public function toArray(): array\n {\n return $this->items;\n }", "title": "" }, { "docid": "8879241154c61089d45871a83b1a118f", "score": "0.70713985", "text": "public function asArray() {\n $arr = array();\n foreach ( $this->getFields() as $field ) {\n $key = $field->getName();\n $value = $field->getValueOrTargetObject();\n if ( is_string( $value ) ) {\n self::addItemToObjectArray( $arr, $key, $value );\n } else if ( $value instanceof ActivityPubObject ) {\n self::addItemToObjectArray( $arr, $key, $value->asArray() );\n }\n }\n return $arr;\n }", "title": "" }, { "docid": "77a970fb730dddea81ec0d842a8ef6d0", "score": "0.70647454", "text": "final public function toArray() : array\n {\n return $this->items;\n }", "title": "" }, { "docid": "49d953cb668ade691f05013fead1b2e3", "score": "0.7002954", "text": "abstract public function toArray();", "title": "" }, { "docid": "49d953cb668ade691f05013fead1b2e3", "score": "0.7002954", "text": "abstract public function toArray();", "title": "" }, { "docid": "49d953cb668ade691f05013fead1b2e3", "score": "0.7002954", "text": "abstract public function toArray();", "title": "" }, { "docid": "49d953cb668ade691f05013fead1b2e3", "score": "0.7002954", "text": "abstract public function toArray();", "title": "" }, { "docid": "49d953cb668ade691f05013fead1b2e3", "score": "0.7002954", "text": "abstract public function toArray();", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969472", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "6f3533916530c8ff0c0698336c546bbd", "score": "0.6969207", "text": "public function toArray(){}", "title": "" }, { "docid": "a49866bcbe53b98390c76db3f84ba7ba", "score": "0.6940172", "text": "function asArray(){\n\t\t\t$array = $this->toArray( $this );\n\t\t\treturn $array;\n\t\t}", "title": "" }, { "docid": "a49866bcbe53b98390c76db3f84ba7ba", "score": "0.6940172", "text": "function asArray(){\n\t\t\t$array = $this->toArray( $this );\n\t\t\treturn $array;\n\t\t}", "title": "" }, { "docid": "6fd93fb018fe8966766e54ac56183e8a", "score": "0.69355255", "text": "public function toArray()\n {\n return $this->items;\n }", "title": "" }, { "docid": "6fd93fb018fe8966766e54ac56183e8a", "score": "0.69355255", "text": "public function toArray()\n {\n return $this->items;\n }", "title": "" }, { "docid": "2fa445364a8d3cba723fe712de0b763f", "score": "0.69253373", "text": "public function getItemArray()\n {\n if (!$this->_item) {\n return false;\n }\n\n return $this->_item->toArray();\n }", "title": "" }, { "docid": "64a78431134efb7a6b68a428bcb142da", "score": "0.69173294", "text": "public function toArray()\n {\n return toArray($this->getItems());\n }", "title": "" }, { "docid": "d97cb52ed62600531d2da9ef803fdcdc", "score": "0.691141", "text": "public function toArray()\n\t{\n\t\treturn $this->items;\n\t}", "title": "" }, { "docid": "d97cb52ed62600531d2da9ef803fdcdc", "score": "0.691141", "text": "public function toArray()\n\t{\n\t\treturn $this->items;\n\t}", "title": "" }, { "docid": "01296aed74c73cb9c91e4f1f6798de90", "score": "0.69071484", "text": "public function toArray() : array\n {\n $identifier = $this->getIdentifierClass();\n\n $array = [];\n\n foreach ($identifier->getIdentifyKeys() as $key => $data) {\n $array[$key] = $identifier->getIdentifier($key);\n }\n\n $item = [\n 'identifier' => $this->identifier,\n 'parentIdentifier' => $this->parentIdentifier,\n 'quantity' => $this->quantity,\n ];\n\n //CartItem additional data\n if ( is_null($this->data) === false ){\n $item['data'] = $this->data;\n }\n\n return array_merge($array, $item);\n }", "title": "" }, { "docid": "54dd6e699c430b0096ad32bde32dea7e", "score": "0.6903563", "text": "public function _as_array()\n\t{\n\t\t$return = $this->values;\n\t\t$return['__itemoptions'] = $this->options;\n\t\treturn $return;\n\t}", "title": "" }, { "docid": "0ec7b353455bd6927979108a312c2e74", "score": "0.6872191", "text": "#[@generic(return= 'T[]')]\n public function toArray() { \n return array_values($this->_elements);\n }", "title": "" }, { "docid": "8fa9c2e69c8be0bbe58795328b350798", "score": "0.6860447", "text": "public function __toArray() {\n $_basketItems = $this->_items;\n $_counter = 1;\n\n $this->_basket[self::BASKET_AMOUNT] = $this->getAmount();\n $this->_basket[self::BASKET_CURRENCY] = $this->_currency;\n $this->_basket[self::BASKET_ITEMS] = count($_basketItems);\n\n foreach($_basketItems as $oItem) {\n $mArticleNumber = $oItem['instance']->getArticleNumber();\n $oItem = $oItem['instance'];\n\n $this->_basket[self::BASKET_ITEM_PREFIX . $_counter . WirecardCEE_Stdlib_Basket_Item::ITEM_ARTICLE_NUMBER] = $mArticleNumber;\n $this->_basket[self::BASKET_ITEM_PREFIX . $_counter . self::QUANTITY] = $this->_getItemQuantity($mArticleNumber);\n $this->_basket[self::BASKET_ITEM_PREFIX . $_counter . WirecardCEE_Stdlib_Basket_Item::ITEM_UNIT_PRICE] = $oItem->getUnitPrice();\n $this->_basket[self::BASKET_ITEM_PREFIX . $_counter . WirecardCEE_Stdlib_Basket_Item::ITEM_TAX] = $oItem->getTax();\n $this->_basket[self::BASKET_ITEM_PREFIX . $_counter . WirecardCEE_Stdlib_Basket_Item::ITEM_DESCRIPTION] = $oItem->getDescription();\n\n $_counter++;\n }\n\n return $this->_basket;\n }", "title": "" }, { "docid": "38d9a093e430e6f0520c4be52c4f8840", "score": "0.68438476", "text": "public function toInternalArray() {\n return parent::toArray();\n }", "title": "" }, { "docid": "967247e834d7e8229725f042dd51cf29", "score": "0.68247086", "text": "public function toArray()\n\t\t{\n\t\t\treturn $this->items;\n\t\t}", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.6801505", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "58e92c5cfdabe669dbe8f6326213f9a6", "score": "0.68013495", "text": "public function toArray();", "title": "" }, { "docid": "a9ef81250547b41c7407adc8aceab00b", "score": "0.6797569", "text": "public function toArray()\n {\n $newItem = [];\n\n foreach ($this->items as $key => $val) {\n if ($val instanceof ArrayInterface) {\n $newItem[$key] = $val->items;\n } else {\n $newItem[$key] = $val;\n }\n }\n\n return $newItem;\n }", "title": "" }, { "docid": "d21a8ed6ac7860195ebacc8c32ad69cf", "score": "0.6795853", "text": "public function getItemArray()\n {\n return $this->itemArray;\n }", "title": "" }, { "docid": "3f3bf8ac6544166f67f408f0fa9c1211", "score": "0.6775837", "text": "public function asArray();", "title": "" }, { "docid": "4e2513b598b37df6caeb96836cc2494b", "score": "0.6767955", "text": "public function asArray(): array {\n return [\n \"data\" => $this->data,\n \"type\" => $this->type,\n ];\n }", "title": "" }, { "docid": "833a0c4292cf678055f9f4231022071a", "score": "0.6764786", "text": "abstract protected function toArray(): array;", "title": "" }, { "docid": "98e4623b5603d87856e0500dd312fb00", "score": "0.6763832", "text": "public function toArray() {\n $data = $this->data;\n foreach ($data as $key => $value) {\n if ($value instanceof self) {\n $data[$key] = $value->toArray();\n }\n }\n return $data;\n }", "title": "" }, { "docid": "9850dc46c3798c9461af322c4e95b167", "score": "0.67486906", "text": "public function toArray()\n {\n return self::arrayize($this);\n }", "title": "" }, { "docid": "bd443e08462036e25235ff38d25a7647", "score": "0.67132694", "text": "public function toArray()\n {\n $a = parent::toArray();\n if ($this->type) {\n $a[\"type\"] = $this->type;\n }\n if ($this->values) {\n $ab = array();\n foreach ($this->values as $i => $x) {\n $ab[$i] = $x->toArray();\n }\n $a['values'] = $ab;\n }\n return $a;\n }", "title": "" }, { "docid": "43eab2368848b991fd352c6623288a64", "score": "0.6711524", "text": "public function to_array() {\n $array = array();\n\n foreach ( $this->items as $tag => $data ) {\n // Set element as allowed on the elements\n // that are listed in the «allow_in» option.\n foreach ( $data['allow_in'] as $allow_in ) {\n array_push( $this->items[$allow_in]['allow'], $tag );\n }\n }\n\n foreach ( $this->items as $tag => $data ) {\n $instance = new $data['class']( $data['tag'], $data );\n $array[$tag] = $instance->to_array();\n }\n\n return $array;\n }", "title": "" }, { "docid": "497c9aa7d154a7921dc03a888cc7235b", "score": "0.6704713", "text": "public function toArray(): array\n {\n return array_map(function (PostAggregatorInterface $item) {\n return $item->toArray();\n }, $this->items);\n }", "title": "" }, { "docid": "22a6a4cc4665cc11c48ccfb22a2f5ffa", "score": "0.66993946", "text": "public function toArray()\n {\n return parent::toArray();\n }", "title": "" }, { "docid": "340cb59a3674b832e774882d5f5b2a21", "score": "0.66830087", "text": "public function to_array() {\r\n\t\treturn get_object_vars( $this );\r\n\t}", "title": "" }, { "docid": "06f9a1a20fa5eb29b30488d4390ac536", "score": "0.66796476", "text": "public function toArray()\n {\n return array_map(function($value)\n {\n return $value instanceof Arrayable ? $value->toArray() : $value;\n }, $this->items);\n }", "title": "" }, { "docid": "7871e0e8a0249509d107aa1c645c4f00", "score": "0.66704357", "text": "function to_array(mixed $items)\n {\n return json_decode( json_encode($items), true);\n }", "title": "" }, { "docid": "f8c61349d76b5d4ff4cc6579bea77bf9", "score": "0.6659771", "text": "public function itemToNestedArray(Item $item): array;", "title": "" }, { "docid": "755e47af5935aa11435f4b5c64c71ea6", "score": "0.6649261", "text": "public function toArray()\n {\n return [\n 'items' => $this->items(),\n 'coupons' => $this->coupons()\n ];\n }", "title": "" }, { "docid": "5cfad52061d1fb1b35e508d7ec45a27c", "score": "0.66463035", "text": "public function toArray()\r\n {\r\n $a = parent::toArray();\r\n return $a;\r\n }", "title": "" }, { "docid": "23659845e5d66ae13ad72fa0f2b8672d", "score": "0.6637417", "text": "protected abstract function convertObjectToArray($entity);", "title": "" }, { "docid": "6ae961005240fb13ea20fa958e9e8e44", "score": "0.6636845", "text": "public function toArray() {\n\n // it is wrapper class only, get its child\n if(get_class($this) == \"treeNode\") {\n\n $children = array();\n foreach($this->_children as $k => $child) {\n $children[] = $child->toArray();\n }\n\n return $children;\n\n } else {\n\n $item = array(\n 'id' => $this->getItem()->getId(),\n 'name' => $this->getItem()->getTitle(),\n 'enabled' => $this->getEnabled(),\n 'deleted' => $this->getDeleted(),\n 'hasChild' => $this->hasChild()\n );\n\n $children = array();\n foreach($this->_children as $k => $child) {\n $children[] = $child->toArray();\n }\n\n $item['children'] = $children;\n\n return $item;\n }\n }", "title": "" }, { "docid": "793b324b77932c672e6f2780750c26e4", "score": "0.66282976", "text": "public function toArray()\n {\n return array_map(function ($value) {\n return $value instanceof Arrayable ? $value->toArray() : $value;\n\n }, $this->items);\n }", "title": "" }, { "docid": "a5131d21e508c064ab0cd4ac9b5100b5", "score": "0.6624837", "text": "abstract protected function toArrayFromProxy(): array;", "title": "" }, { "docid": "5f4187096d8f7f9025847a3e7fb5d76a", "score": "0.6619673", "text": "public function toArray()\n\t{\n\t\t$this->data = $this->transformer->transformBack($this->data);\n\n\t\treturn $this->data;\n\t}", "title": "" }, { "docid": "23340658f4bbb1025aabdd072962e116", "score": "0.6618105", "text": "public function toArray()\n\t{\n\t\t$this->supplement();\n\t\treturn parent::toArray();\n\t}", "title": "" }, { "docid": "daa89dd2587615727e7d2cf4672003ff", "score": "0.6615969", "text": "function toArray()\n {\n return parent::toArray();\n }", "title": "" }, { "docid": "4610008ceb8da2256fdea406d7d685db", "score": "0.6608637", "text": "public function toArray()\n \t{\n \t\t$result = array();\n \t\tforeach ( get_object_vars( $this ) as $key => $noUse ){\n \t\t\t\n \t\t\t$result[ $key ] = $this->__get( $key );\n \t\t}\n \t\n \t\treturn $result;\n \t}", "title": "" }, { "docid": "32262a5ebcf3d9a3fd7ebbd33b6d16d8", "score": "0.65981525", "text": "public function toArray()\n {\n return json_decode(json_encode($this), true);\n }", "title": "" }, { "docid": "32262a5ebcf3d9a3fd7ebbd33b6d16d8", "score": "0.65981525", "text": "public function toArray()\n {\n return json_decode(json_encode($this), true);\n }", "title": "" }, { "docid": "32262a5ebcf3d9a3fd7ebbd33b6d16d8", "score": "0.65981525", "text": "public function toArray()\n {\n return json_decode(json_encode($this), true);\n }", "title": "" }, { "docid": "32262a5ebcf3d9a3fd7ebbd33b6d16d8", "score": "0.65981525", "text": "public function toArray()\n {\n return json_decode(json_encode($this), true);\n }", "title": "" }, { "docid": "5e69ffc093f07ed81c1470d1e45fc45f", "score": "0.6597232", "text": "public function toArray()\n {\n $a = parent::toArray();\n if ($this->type) {\n $a[\"type\"] = $this->type;\n }\n if ($this->person) {\n $a[\"person\"] = $this->person->toArray();\n }\n if ($this->details) {\n $a[\"details\"] = $this->details;\n }\n\n return $a;\n }", "title": "" }, { "docid": "15ebef48bcb222ae3f2c34135dff6816", "score": "0.65964544", "text": "function toArray()\n {\n \treturn array('meta' => $this->meta, 'strings' => $this->strings);\n }", "title": "" }, { "docid": "861eeddcc30f0041ff79794a5cf48448", "score": "0.6595025", "text": "public function __toArray()\n {\n return array(\n 'status' => $this->status,\n 'meta' => $this->meta,\n 'data' => $this->data,\n );\n }", "title": "" }, { "docid": "c8c484502926e5f578cfd46ec9d4b4b1", "score": "0.65724576", "text": "public function toArray()\n {\n return (array) $this->data;\n }", "title": "" }, { "docid": "180896c65401f44aa753d54ce5baeb06", "score": "0.6569081", "text": "public function toArray():array{\n return json_decode(json_encode($this),true);\n }", "title": "" }, { "docid": "45e14afafd6e7305d325ce4a0d639802", "score": "0.6568812", "text": "public function toArray()\n {\n return $this->createDataArray();\n\n }", "title": "" } ]
0e09942d6c346a9b4d43f882202025fb
this down() migration is autogenerated, please modify it to your needs
[ { "docid": "74d26eb9849600aee43803ac20ac56a2", "score": "0.0", "text": "public function down(Schema $schema): void\n {\n $this->addSql('DROP TABLE fichiers');\n $this->addSql('ALTER TABLE produits CHANGE photo photo VARCHAR(255) CHARACTER SET utf8mb4 DEFAULT NULL COLLATE `utf8mb4_unicode_ci`');\n }", "title": "" } ]
[ { "docid": "e54dad8abc5dfd9ee11ad5cb884d70c8", "score": "0.75539154", "text": "public function down(){\n\t\t/*Drop the Users table in the down function*/\n\t\t$this->dbforge->drop_column('pages', 'parent_id');\n\t}", "title": "" }, { "docid": "3844974f29f564ea9d9b35fba20733a0", "score": "0.7471724", "text": "public function down()\n {\n //return false;\n $this->dropTable('apples');\n }", "title": "" }, { "docid": "7fb3894f5faf0357b362f9c74b26eb23", "score": "0.74182886", "text": "public function down(){\n\t//\t$this->query($sql);\n\t\t\n\t}", "title": "" }, { "docid": "fdf9a924004c6bec5945a2d2b9c15129", "score": "0.7268329", "text": "public function down()\n\t{\n\t\t//return false;\n\t\t$this->dropColumn('dcc_history', 'calc_date');\n\t}", "title": "" }, { "docid": "51df944845bc3ed5c975ff6af33b908b", "score": "0.7160172", "text": "public function down()\n\t{\n\t\t//Schema::drop('purchase_item_details');\n\t}", "title": "" }, { "docid": "eaca5190425caef57536621816f30aaf", "score": "0.7135585", "text": "public function down(): void {\n\t\t$this->schema->changeTable('task', static function (TableBuilder $t): void {\n\t\t\t$t->changeColumn('name')->size(40);\n\t\t});\n\t}", "title": "" }, { "docid": "e13a8a83dc66700356540f77277eda68", "score": "0.7134332", "text": "public function down(){\n $this->dbforge->drop_table('focus'); //eliminacion de la tabla focus\n }", "title": "" }, { "docid": "ae707aa371f883099aa74cf7f495f62a", "score": "0.7133434", "text": "public function down()\n {\n// return false;\n\n $this->dropTable('note');\n $this->dropTable('user');\n }", "title": "" }, { "docid": "c6ec53d234b78d7048830f70e6d6b5fa", "score": "0.7097788", "text": "public function down()\n {\n $this->dbforge->drop_table('activities'); //eliminacion de la tabla activities\n }", "title": "" }, { "docid": "534c38fcd853b5f0fd992d42799580f5", "score": "0.70935166", "text": "public function down(){\n $this->dbforge->drop_table('users'); //eliminacion de la tabla users\n }", "title": "" }, { "docid": "631d8120526e23f7d0b9217ca5d38131", "score": "0.7090587", "text": "public function down()\n\t{\n\t\t//return false;\n\n\t\t$this->dropTable('users');\n\t}", "title": "" }, { "docid": "b5c0b0b39c799741b5b35d8390bee1d9", "score": "0.70874643", "text": "public function down()\n {\n //\n }", "title": "" }, { "docid": "05272e7796f0d0f9b5481933c783a363", "score": "0.70798796", "text": "public function down()\n {\n DBManager::get()->execute(\"DROP TABLE IF EXISTS `phonebook_entries`\");\n }", "title": "" }, { "docid": "bc7e2b80accf6350d5f3559fad63a495", "score": "0.7077547", "text": "public function down()\n {\n\n $this->table('commande_lignes')->drop()->save();\n $this->table('commandes')->drop()->save();\n }", "title": "" }, { "docid": "3e2aa3eefa50e366833c22692f2b8f68", "score": "0.7053364", "text": "public function down()\n\t{\n\t}", "title": "" }, { "docid": "c62778c7c9626d550931c7ea62aa262c", "score": "0.7052239", "text": "public function down(): void\n {\n }", "title": "" }, { "docid": "c62778c7c9626d550931c7ea62aa262c", "score": "0.7052239", "text": "public function down(): void\n {\n }", "title": "" }, { "docid": "37348a1daf8cf02674f9373a5c5d5f61", "score": "0.70503587", "text": "public function down()\n\t{\n\t\tSchema::drop('followers');\n\t}", "title": "" }, { "docid": "b8d04c4d241d7a2ff5d9a369d7d3e1e4", "score": "0.7042174", "text": "public function down()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "c840d59bcb737f493565a84405fbea84", "score": "0.69999653", "text": "public function down()\n\t{\n\t\t$this->forge->dropTable('users');\n\t}", "title": "" }, { "docid": "a307688b69fcebf64ef77d47ace4b59a", "score": "0.69978255", "text": "public function down()\n\t{\n\t\tSchema::drop('teamfile');\n\t\t//\n\t}", "title": "" }, { "docid": "87ee01e730cd6e1673504d916fad25c8", "score": "0.6997816", "text": "public function safeDown()\n {\n $this->dropForeignKey('fromsdf', 'notify');\n $this->dropForeignKey('tosdf', 'notify');\n $this->dropForeignKey('fdkfng', 'notify');\n\t\t$this->dropTable('notify');\n //return false;\n }", "title": "" }, { "docid": "43e5c660199db2ceac95afdb2cd4863e", "score": "0.6986877", "text": "public function down()\n {\n $this->output->writeln('Down migration is not available.');\n }", "title": "" }, { "docid": "b787c7d4b8349cee5f538b100b17a66a", "score": "0.6979313", "text": "public function down()\n {\n \n $this->dropForeignKey('fk-user_powers-user_id', 'user_powers');\n $this->dropForeignKey('fk-user_powers-power_id', 'user_powers');\n \n $this->dropForeignKey('fk-user_qualities-user_id', 'user_qualities');\n $this->dropForeignKey('fk-user_qualities-quality_id', 'user_qualities');\n \n $this->dropForeignKey('fk-quality_powers-power_id', 'quality_powers');\n $this->dropForeignKey('fk-quality_powers-quality_id', 'quality_powers');\n \n $this->dropTable('user_powers');\n $this->dropTable('user_qualities');\n $this->dropTable('quality_powers');\n $this->dropTable('powers');\n\n return true;\n }", "title": "" }, { "docid": "ee4cdf04362f4da77778254c35ded348", "score": "0.69753027", "text": "public function up()\n\t{ // eliminamos el campo active.\n /* Schema::table('users',function(Blueprint $table){\n $table->dropColumn('active');\n });*/\n\t\t//\n\t}", "title": "" }, { "docid": "8794051f1b215c825586249ca7d40383", "score": "0.6975", "text": "public function down()\r\n {\r\n $this->executeSQL('SET FOREIGN_KEY_CHECKS=0');\n \n $this->executeSQL('DROP TABLE esq_customers');\n $this->executeSQL('DROP TABLE esq_websites');\n $this->executeSQL('DROP TABLE esq_domain_names');\n $this->executeSQL('DROP TABLE esq_domain_checks');\n $this->executeSQL('DROP TABLE esq_website_attributes');\n $this->executeSQL('DROP TABLE esq_templates');\n $this->executeSQL('DROP TABLE esq_template_categories');\n $this->executeSQL('DROP TABLE esq_hosts');\n $this->executeSQL('DROP TABLE esq_coupons');\n $this->executeSQL('DROP TABLE esq_coupons_to_websites');\n $this->executeSQL('DROP TABLE esq_email_accounts');\n $this->executeSQL('DROP TABLE esq_member_feedbacks');\n $this->executeSQL('DROP TABLE esq_page_entries');\n $this->executeSQL('DROP TABLE esq_page_groups');\n $this->executeSQL('DROP TABLE esq_pages');\n $this->executeSQL('DROP TABLE esq_page_content_display_types');\n $this->executeSQL('DROP TABLE esq_client_messages');\n $this->executeSQL('DROP TABLE esq_bar_associations');\n $this->executeSQL('DROP TABLE esq_template_types');\n $this->executeSQL('DROP TABLE esq_resource_categories');\n $this->executeSQL('DROP TABLE esq_resources');\n $this->executeSQL('DROP TABLE sf_guard_group');\n $this->executeSQL('DROP TABLE sf_guard_permission');\n $this->executeSQL('DROP TABLE sf_guard_group_permission');\n $this->executeSQL('DROP TABLE sf_guard_user');\n $this->executeSQL('DROP TABLE sf_guard_user_permission');\n $this->executeSQL('DROP TABLE sf_guard_user_group');\n $this->executeSQL('DROP TABLE sf_guard_remember_key');\n $this->executeSQL('DROP TABLE sf_moderated_content');\n $this->executeSQL('DROP TABLE sf_comment');\n $this->executeSQL('DROP TABLE sf_tag');\n $this->executeSQL('DROP TABLE sf_tagging');\n $this->executeSQL('DROP TABLE te_blog_post');\n $this->executeSQL('DROP TABLE te_blog_post_category');\n $this->executeSQL('DROP TABLE te_blog_posts_to_categories');\n $this->executeSQL('DROP TABLE te_faq');\n $this->executeSQL('DROP TABLE te_testimonials');\n \n $this->executeSQL('SET FOREIGN_KEY_CHECKS=1');\r\n }", "title": "" }, { "docid": "588767bbe7b500ebdeff25d4d1796b62", "score": "0.69689393", "text": "public function up()\n\t{\n\t\t$this->execute(\"\n ALTER TABLE `vfue_fuel` \n DROP COLUMN `vfue_ccnt_id`, \n DROP COLUMN `vfue_company`, \n DROP COLUMN `vfue_comapny_reg_number`, \n DROP COLUMN `vfue_series`, \n DROP COLUMN `vfue_fvat_id`, \n DROP COLUMN `vfue_vat`, \n DROP COLUMN `vfue_total`, \n DROP COLUMN `vfue_vase_vat`, \n DROP COLUMN `vfue_base_total`, \n CHANGE `vfue_amt` `vfue_amt` DECIMAL(10,2) UNSIGNED NULL AFTER `vfue_qnt`, \n DROP INDEX `vfue_ccnt_id`,\n DROP FOREIGN KEY `vfue_fuel_ibfk_2`;\n\n\n \");\n\t}", "title": "" }, { "docid": "834da7d0d8c430bd0d07a94083bc2f74", "score": "0.6962166", "text": "public function getDownSQL()\n {\n return array (\n 'default' => '\n# This is a fix for InnoDB in MySQL >= 4.1.x\n# It \"suspends judgement\" for fkey relationships until are tables are set.\nSET FOREIGN_KEY_CHECKS = 0;\n\nALTER TABLE `user_level` DROP `ul_role`;\n\n# This restores the fkey checks, after having unset them earlier\nSET FOREIGN_KEY_CHECKS = 1;\n',\n);\n }", "title": "" }, { "docid": "c66264fdcb65faea3d7e74a05266a81e", "score": "0.69474334", "text": "public function safeDown()\n {\n //return false;\n\n $this->dropForeignKey($this->fkName, $this->tableNameI18n);\n $this->dropTable($this->tableNameI18n);\n }", "title": "" }, { "docid": "7652b377f649b7cc69a10d51ab8f5ce4", "score": "0.6942397", "text": "public function down()\n\t{\n\t\tSchema::drop('tif_details');\n\t}", "title": "" }, { "docid": "1875b9b5cfc2430a8fc7576839f4f8ff", "score": "0.6936244", "text": "public function down()\n\t{\n\t\t// return false;\n\t\t$this->dropTable('AuthItem');\n\t}", "title": "" }, { "docid": "2a65400cdf45b0f90fcdb72f0d88e345", "score": "0.6935437", "text": "public function down()\n\t{\n\t\tSchema::drop('l_doors_table');\n\t}", "title": "" }, { "docid": "3c48d4bcd8a99bd7b1c5a2a3db5562cb", "score": "0.6932594", "text": "public function down()\n {\n $this->dbforge->drop_column('menu', 'max_supply_num');\n $this->dbforge->drop_column('menu', 'actual_supply_num');\n }", "title": "" }, { "docid": "b0b766b32fcab8bfefe9d497a8ec9633", "score": "0.69208026", "text": "public function down()\n {\n $this->executeSQL('SET FOREIGN_KEY_CHECKS=0');\n \n $this->executeSQL('DROP TABLE ask_question');\n $this->executeSQL('DROP TABLE ask_answer');\n $this->executeSQL('DROP TABLE ask_user');\n $this->executeSQL('DROP TABLE ask_interest');\n $this->executeSQL('DROP TABLE ask_relevancy');\n \n $this->executeSQL('SET FOREIGN_KEY_CHECKS=1');\n }", "title": "" }, { "docid": "6f9437719eb8c0e4e036057075d92aa9", "score": "0.6903113", "text": "public function down() {}", "title": "" }, { "docid": "badd8e714ae2f75f5e9f63c47675c552", "score": "0.6897824", "text": "public function down()\n {\n }", "title": "" }, { "docid": "badd8e714ae2f75f5e9f63c47675c552", "score": "0.6897824", "text": "public function down()\n {\n }", "title": "" }, { "docid": "badd8e714ae2f75f5e9f63c47675c552", "score": "0.6897824", "text": "public function down()\n {\n }", "title": "" }, { "docid": "badd8e714ae2f75f5e9f63c47675c552", "score": "0.6897824", "text": "public function down()\n {\n }", "title": "" }, { "docid": "badd8e714ae2f75f5e9f63c47675c552", "score": "0.6897824", "text": "public function down()\n {\n }", "title": "" }, { "docid": "7c09979fa3dd56e844b7f97a7bbb7627", "score": "0.6888725", "text": "public function down()\n\t{\n\t\tSchema::drop('data_status');\n\t}", "title": "" }, { "docid": "011ce3b9aa08fc417caa1ff31003aca6", "score": "0.6884365", "text": "public function down()\n {\n $this->execute(\"drop view IF EXISTS `lpd_page_v`;\n drop table IF EXISTS `lpd_log`;\n drop table IF EXISTS `lpd_file`;\n drop table IF EXISTS `lpd_page`;\n drop table IF EXISTS `pg_category`;\n drop table IF EXISTS `lpd_user`;\n \n\");\n }", "title": "" }, { "docid": "e26021430cdb140a3c9637783421cbe5", "score": "0.68757993", "text": "public function getDownSQL()\n {\n return array (\n 'curry' => '\n# This is a fix for InnoDB in MySQL >= 4.1.x\n# It \"suspends judgement\" for fkey relationships until are tables are set.\nSET FOREIGN_KEY_CHECKS = 0;\n\nDROP TABLE IF EXISTS `termcondition`;\n\nALTER TABLE `customer` CHANGE `company_name` `company_name` TEXT;\n\n# This restores the fkey checks, after having unset them earlier\nSET FOREIGN_KEY_CHECKS = 1;\n',\n);\n }", "title": "" }, { "docid": "9edc266a6c5f03cb2db6aead8c433b8d", "score": "0.6871628", "text": "public function down(): void {\n\t\t$this->schema->dropTable('group');\n\t}", "title": "" }, { "docid": "6b908b47ac5020229be6b5d07e861a86", "score": "0.6864267", "text": "public static function down(){\n\n DBW::drop('Article');\n\n }", "title": "" }, { "docid": "19c59a17f61594fd4055a20f3623e7f7", "score": "0.68635535", "text": "public function down(): void\n {\n $this->abortIf($this->connection->getDatabasePlatform()->getName() !== 'mysql', 'Migration can only be executed safely on \\'mysql\\'.');\n }", "title": "" }, { "docid": "19c59a17f61594fd4055a20f3623e7f7", "score": "0.68635535", "text": "public function down(): void\n {\n $this->abortIf($this->connection->getDatabasePlatform()->getName() !== 'mysql', 'Migration can only be executed safely on \\'mysql\\'.');\n }", "title": "" }, { "docid": "19c59a17f61594fd4055a20f3623e7f7", "score": "0.68635535", "text": "public function down(): void\n {\n $this->abortIf($this->connection->getDatabasePlatform()->getName() !== 'mysql', 'Migration can only be executed safely on \\'mysql\\'.');\n }", "title": "" }, { "docid": "6a0759904b6878794884420acfb74ba5", "score": "0.68610376", "text": "public function down()\n\t{\n\t\t//\n\t\t Schema::table(Config::get('sentry::sentry.table.users_groups'), function($table)\n {\n $table->on(Config::get('sentry::sentry.db_instance'));\n $table->drop_column('is_default');\n });\n\n\t}", "title": "" }, { "docid": "82606fb34d2a0114238e9a60eed05953", "score": "0.685915", "text": "public function down() {\n\t\t$this->dbforge->drop_table('mileage', TRUE);\n\n\t\t$this->dbforge->drop_table('timesheets_mileage', TRUE);\n\n\t\t$this->dbforge->drop_table('timesheets_fuel_card', TRUE);\n\n\t\t$this->dbforge->drop_column('staff', 'mileage_activate_fuel_cards');\n\n\t\t$this->dbforge->drop_column('staff', 'default_start_location');\n\n\t\t$this->dbforge->drop_column('staff', 'mileage_default_mode_of_transport');\n\n\t\t$this->dbforge->drop_column('accounts', 'addon_mileage');\n\n\t\t$this->db->from('settings_fields')->where('section', \"staff_recruitment\")->where('field', \"mileage_default_start_location\")->delete();\n\n\t\t$this->db->from('settings_fields')->where('section', \"staff_recruitment\")->where('field', \"mileage_activate_fuel_cards\")->delete();\n\n\t\t$this->db->from('settings_fields')->where('section', \"staff_recruitment\")->where('field', \"mileage_default_mode_of_transport\")->delete();\n\n\t\t$where_in = array(\n\t\t\t'excluded_mileage',\n\t\t\t'mileage_default_start_location',\n\t\t\t'mileage_default_mode_of_transport',\n\t\t\t'mileage_activate_fuel_cards',\n\t\t\t'mileage_default_address1',\n\t\t\t'mileage_default_address2',\n\t\t\t'mileage_default_county',\n\t\t\t'mileage_default_town',\n\t\t\t'mileage_default_postcode',\n\t\t);\n\n\t\t$this->db->from('settings')->where_in('key', $where_in)->delete();\n\n\t}", "title": "" }, { "docid": "2bf47ddf4fdc83eac8ffce0fcadfde63", "score": "0.68447775", "text": "public function getDownSQL()\n {\n return array (\n 'default' => '\n# This is a fix for InnoDB in MySQL >= 4.1.x\n# It \"suspends judgement\" for fkey relationships until are tables are set.\nSET FOREIGN_KEY_CHECKS = 0;\n\nDROP TABLE IF EXISTS `categoria`;\n\nDROP TABLE IF EXISTS `trabajos`;\n\nDROP TABLE IF EXISTS `afiliados`;\n\nDROP TABLE IF EXISTS `categoria_afiliado`;\n\n# This restores the fkey checks, after having unset them earlier\nSET FOREIGN_KEY_CHECKS = 1;\n',\n);\n }", "title": "" }, { "docid": "4344f1ab5ccf52156d3d0fcd7315654f", "score": "0.6842522", "text": "public function down() {\n\n }", "title": "" }, { "docid": "73738f81d4f5072e46bfe72ee860debe", "score": "0.6840553", "text": "public function down()\n\t{\n\t\t//\n Schema::drop('packs');\n\t}", "title": "" }, { "docid": "44f26c252dcf313f8f28f0eb8039469c", "score": "0.683866", "text": "public function down()\n {\n if ($this->getDb()->schema()->hasTable('deliverer_translation')) {\n $this->getDb()->schema()->drop('deliverer_translation');\n }\n\n /*\n * Drop deliverer table\n */\n if ($this->getDb()->schema()->hasTable('deliverer')) {\n $this->getDb()->schema()->drop('deliverer');\n }\n }", "title": "" }, { "docid": "84fe37227d701e21adddea9356c36533", "score": "0.68374884", "text": "public static function down() {\n\t\tSchema::dropTable(\"card\");\n\t}", "title": "" }, { "docid": "7ab33f2bc282cd135868e42d062afa8e", "score": "0.68355477", "text": "public function down()\n\t{\n\t\tSchema::drop('tucs');\n\t}", "title": "" }, { "docid": "5a0feaafe49ead0d6a159e40b711e2a7", "score": "0.68262744", "text": "public function safeDown()\n {\n Yii::$app->db->createCommand('set foreign_key_checks=0')->execute();\n\n $this->addColumn('{{%language}}', 'url_code', Schema::TYPE_STRING.'(5) NOT NULL AFTER `code`');\n\n $this->dropIndex('key_unique_locale', '{{%language}}');\n\n return true;\n }", "title": "" }, { "docid": "1bee422ba25d4bfa979880ecebf8c497", "score": "0.6811746", "text": "public function down()\n {\n $this->getSchema()->dropIfExists('user_providers');\n parent::down();\n }", "title": "" }, { "docid": "b46e920a7342b8df74811f91844b07a7", "score": "0.6811237", "text": "public function\n\tDown() {\n\n\t\t$this->Execute(\"DROP TABLE IF EXISTS `BlogPostTags`;\");\n\t\t$this->Execute(\"DROP TABLE IF EXISTS `BlogTags`;\");\n\n\t\treturn;\n\t}", "title": "" }, { "docid": "ece4599cdcc587d9c58a0553a3e0c4f4", "score": "0.68092495", "text": "public function getDownSQL()\n {\n return array(\n 'default' => '\n# This is a fix for InnoDB in MySQL >= 4.1.x\n# It \"suspends judgement\" for fkey relationships until are tables are set.\nSET FOREIGN_KEY_CHECKS = 0;\n\nDROP TABLE IF EXISTS `admin`;\n\n# This restores the fkey checks, after having unset them earlier\nSET FOREIGN_KEY_CHECKS = 1;\n',\n );\n }", "title": "" }, { "docid": "411b780350f73424fc46e3da3096597d", "score": "0.68092316", "text": "public function down()\n {\n Schema::dropIfExists('group_user'); \n }", "title": "" }, { "docid": "e1fe0685de6c43601cb63e26c0e9494b", "score": "0.68081725", "text": "public function safeDown()\n\t{\n $this->execute('SET foreign_key_checks = 0');\n $this->execute(\n \"DELETE FROM lkp_audio_job_statuses_rules\n WHERE `from_status_id` = (SELECT id FROM `lkp_audio_job_statuses` WHERE `sort_order` = '1')\n OR `to_status_id` = (SELECT id FROM `lkp_audio_job_statuses` WHERE `sort_order` = '1')\n \"\n );\n $this->delete('lkp_audio_job_statuses', \"`sort_order` = '1'\");\n $this->execute('UPDATE `lkp_audio_job_statuses` SET `sort_order` = (`sort_order`-1) WHERE 1');\n $this->execute('SET foreign_key_checks = 1');\n\t}", "title": "" }, { "docid": "965f81b58a3c66df4716fcdfd0cf701f", "score": "0.68044", "text": "public function down()\n\t{\n\t\tif(Yii::app()->db->getSchema()->getTable(\"{{shortcut}}\")){\n\t\t\t$this->dropTable(\"{{shortcut}}\");\n\t\t}\n\t}", "title": "" }, { "docid": "1f1cb172053c18998fd228363914ad76", "score": "0.68014073", "text": "public function down()\n {\n $this->dropForeignKey(\n 'fk-bought_products-user_id',\n 'bought_products'\n );\n\n // drop index for column `user_id`\n $this->dropIndex(\n 'idx-bought_products-user_id',\n 'bought_products'\n );\n\n // drop foreign key for table `products`\n $this->dropForeignKey(\n 'fk-bought_products-product_id',\n 'bought_products'\n );\n\n // drop index for column `product_id`\n $this->dropIndex(\n 'idx-bought_products-product_id',\n 'bought_products'\n );\n\n $this->dropTable('bought_products');\n\n return false;\n }", "title": "" }, { "docid": "1e27e358a4fe93bf09a1dd5674c0e34f", "score": "0.68010896", "text": "public function up(){\n // instead the parameter checksum will be used\n $this->dbforge->drop_column('snapshots', 'snapshot');\n\n }", "title": "" }, { "docid": "5ebe0f662825e5fdf63b73e8f0bac792", "score": "0.67983884", "text": "public function down()\n {\n\n $this->dropForeignKey('fk-tag_translations-language_id', 'tag_translations');\n $this->dropForeignKey('fk-tag_translations-tag_id', 'tag_translations');\n \n $this->dropTable('tag_translations');\n\n return false;\n }", "title": "" }, { "docid": "0fe24088aa001106d6fd2692cc5cd0b3", "score": "0.6797273", "text": "public function down(Schema $schema) : void\n {\n $this->addSql('CREATE TABLE product_detail (id INT AUTO_INCREMENT NOT NULL, name_id INT NOT NULL, height NUMERIC(5, 2) NOT NULL, colour VARCHAR(255) CHARACTER SET utf8mb4 NOT NULL COLLATE `utf8mb4_unicode_ci`, price NUMERIC(5, 2) NOT NULL, image_source VARCHAR(255) CHARACTER SET utf8mb4 NOT NULL COLLATE `utf8mb4_unicode_ci`, INDEX IDX_4C7A3E3771179CD6 (name_id), PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8 COLLATE `utf8_unicode_ci` ENGINE = InnoDB COMMENT = \\'\\' ');\n $this->addSql('ALTER TABLE product_detail ADD CONSTRAINT FK_4C7A3E3771179CD6 FOREIGN KEY (name_id) REFERENCES product (id) ON UPDATE NO ACTION ON DELETE NO ACTION');\n $this->addSql('DROP TABLE order_item_product_colour');\n $this->addSql('ALTER TABLE colour DROP FOREIGN KEY FK_FAF865CE383C2DC1');\n $this->addSql('DROP INDEX IDX_FAF865CE383C2DC1 ON colour');\n $this->addSql('ALTER TABLE order_item DROP FOREIGN KEY FK_52EA1F094584665A');\n $this->addSql('ALTER TABLE order_item DROP FOREIGN KEY FK_52EA1F094679B87C');\n $this->addSql('ALTER TABLE order_item DROP FOREIGN KEY FK_52EA1F09D614C7E7');\n $this->addSql('DROP INDEX IDX_52EA1F094584665A ON order_item');\n $this->addSql('DROP INDEX IDX_52EA1F094679B87C ON order_item');\n $this->addSql('DROP INDEX IDX_52EA1F09D614C7E7 ON order_item');\n $this->addSql('ALTER TABLE product DROP FOREIGN KEY FK_D34A04AD383C2DC1');\n $this->addSql('DROP INDEX IDX_D34A04AD383C2DC1 ON product');\n $this->addSql('ALTER TABLE product_colour MODIFY id INT NOT NULL');\n $this->addSql('ALTER TABLE product_colour DROP PRIMARY KEY');\n $this->addSql('ALTER TABLE product_colour ADD product_id INT NOT NULL, ADD colour_id INT NOT NULL');\n $this->addSql('ALTER TABLE product_colour ADD CONSTRAINT FK_9884246A569C9B4C FOREIGN KEY (colour_id) REFERENCES colour (id) ON UPDATE NO ACTION ON DELETE CASCADE');\n $this->addSql('CREATE INDEX IDX_9884246A4584665A ON product_colour (product_id)');\n $this->addSql('CREATE INDEX IDX_9884246A569C9B4C ON product_colour (colour_id)');\n $this->addSql('ALTER TABLE product_colour ADD PRIMARY KEY (id, product_id, colour_id)');\n }", "title": "" }, { "docid": "c6ad0d96f38937b932daf5459c23a699", "score": "0.6796732", "text": "public function down()\r\n\t{\r\n\t\tSchema::drop('gebruikers');\r\n\t}", "title": "" }, { "docid": "82b29dbc692ac7ffde57f78617a2f230", "score": "0.678316", "text": "public function down()\n\t{\n\t\tSchema::drop('empresas');\n\t}", "title": "" }, { "docid": "41dc9719469bfcb0f1b5225fec96c1f9", "score": "0.67764324", "text": "public function down()\n {\n $this->table('patients')->drop()->save();\n $this->table('rendezvous')->drop()->save();\n $this->table('users')->drop()->save();\n }", "title": "" }, { "docid": "64b85ae811a61870432f509f7c671909", "score": "0.6766251", "text": "public function down()\n {\n Schema::dropIfExists(\"prestart\");\n }", "title": "" }, { "docid": "e8af1459bd97eae72e5a883d7032f110", "score": "0.6765163", "text": "public function down()\n {\n Schema::table('apartments', function (Blueprint $table) {\n $table->dropForeign('apartment_user');\n $table->dropColumn('user_id');\n });\n\n\n Schema::table('messages', function (Blueprint $table) {\n $table->dropForeign('messages_apartment');\n $table->dropColumn('apartment_id');\n });\n Schema::table('stats', function (Blueprint $table) {\n $table->dropForeign('stats_apartment');\n $table->dropColumn('apartment_id');\n });\n\n //mtom appartments -> configs\n Schema::table('apartment_config', function (Blueprint $table) {\n $table->dropForeign('apartment_config_configs');\n $table->dropColumn('config_id');\n\n $table->dropForeign('apartment_config_apartments');\n $table->dropColumn('apartment_id');\n });\n\n //mtom appartments -> configs\n Schema::table('ad_apartment', function (Blueprint $table) {\n $table->dropForeign('ad_apartment_ads');\n $table->dropColumn('ad_id');\n\n $table->dropForeign('ad_apartment_apartments');\n $table->dropColumn('apartment_id');\n });\n\n }", "title": "" }, { "docid": "6c3b3fc383c05d0d1867fe135c460d6a", "score": "0.6759028", "text": "public function down()\n {\n $this->dbforge->drop_table('pxmenu', true);\n }", "title": "" }, { "docid": "3f4ab9f9759cada519cf14d25397d76e", "score": "0.6757603", "text": "public static function down(){\n\n DBW::drop('Tag_article');\n\n }", "title": "" }, { "docid": "3ee15fbdd6dbcaa18262ad62decc598c", "score": "0.6753351", "text": "public function down() {\n\t}", "title": "" }, { "docid": "11d758cc1b139ee03d2b5e0c6b7add0e", "score": "0.67478234", "text": "public function down()\n\t{\n\t\t//\n\t\tSchema::drop('users');\n\t}", "title": "" }, { "docid": "fda9e87b128bd46e9a9b554d9bfd0167", "score": "0.67459893", "text": "public function getDownSQL()\n {\n return array (\n 'default' => '\nBEGIN;\n\nALTER TABLE \"player_equipment\" DROP CONSTRAINT \"player_equipment_fk_weapon1_player_item\";\n\nALTER TABLE \"player_equipment\" DROP CONSTRAINT \"player_equipment_fk_weapon2_player_item\";\n\nALTER TABLE \"player_equipment\"\n\n DROP COLUMN \"weapon1_player_item_id\",\n\n DROP COLUMN \"weapon2_player_item_id\";\n\nALTER TABLE \"player_equipment\" ADD CONSTRAINT \"player_equipment_fk_head_player_item\"\n FOREIGN KEY (\"head_player_item_id\")\n REFERENCES \"player_item\" (\"id\");\n\nCOMMIT;\n',\n);\n }", "title": "" }, { "docid": "46daeab275585d463d90032b811a345d", "score": "0.67441", "text": "public function down()\n\t{\n\t\t// Drop all three tables in reverse order (so that relationships don't explode)\n\t\tSchema::drop('votes');\n\t\tSchema::drop('candidates');\n\t\tSchema::drop('parties');\n\t}", "title": "" }, { "docid": "28ac3d97bca965969da2b3fc97bee274", "score": "0.6743731", "text": "public function down()\n\t{\n\t\tSchema::drop('palettes');\n\t}", "title": "" }, { "docid": "eecf6f809b2fc91746237e2882eae339", "score": "0.67408603", "text": "public function down()\n {\n $this->dropForeignKey(\n 'fk-authors-user-id',\n 'authors'\n );\n\n // drops foreign key for table `user`\n $this->dropForeignKey(\n 'fk-authors-created-by',\n 'authors'\n );\n\n // drops foreign key for table `user`\n $this->dropForeignKey(\n 'fk-authors-modified-by',\n 'authors'\n );\n }", "title": "" }, { "docid": "717aa77a225d334ace52b71b996c6035", "score": "0.67372274", "text": "public function down()\n {\n /** @var \\yii\\db\\Transaction $transaction */\n $transaction = $this->db->beginTransaction();\n\n try {\n /** Drop foreign keys */\n $this->dropForeignKey('fk-pstcat-post-id-post-id', '{{%post_category}}');\n $this->dropForeignKey('fk-pstcat-category-id-categories-id', '{{%post_category}}');\n\n /** Drop indexes */\n $this->dropIndex('ix-post-categories-post-id', '{{%post_category}}');\n $this->dropIndex('ix-post-categories-category-id', '{{%post_category}}');\n\n /** Drop table */\n $this->dropTable('{{%post_category}}');\n\n $transaction->commit();\n } catch (\\yii\\db\\Exception $e) {\n echo $e->getMessage();\n $transaction->rollBack();\n }\n }", "title": "" }, { "docid": "4c5601a883c0c80ccd9fba49cc2500ab", "score": "0.67355233", "text": "public function down()\n {\n $results = '';\n foreach ($this->toArray() as $column => $attributes) {\n $results .= $this->createField($column, $attributes, 'remove');\n }\n\n return $results;\n }", "title": "" }, { "docid": "ab8ac2a81f9c948bb5707eeaee31b06c", "score": "0.6729607", "text": "public function down(){\n\t\tSchema::dropIfExists('user');\n\t}", "title": "" }, { "docid": "3d7cd898469dd09d7efe1c7207ff6997", "score": "0.67256546", "text": "public function down(): void\n {\n $this->exec('DROP TABLE IF EXISTS animals');\n }", "title": "" }, { "docid": "1be334111cd8ccc2f72317bcf93d3549", "score": "0.671978", "text": "public function down()\n\t{\n\t\tif(Yii::app()->db->getSchema()->getTable(\"{{auth_item}}\")){\n\t\t\t$this->dropTable(\"{{auth_item}}\");\n\t\t}\n\n\t\t//delete table if exists\n\t\tif(Yii::app()->db->getSchema()->getTable(\"{{auth_item_child}}\")){\n\t\t\t$this->dropTable(\"{{auth_item_child}}\");\n\t\t}\n\n\t\t//delete table if exists\n\t\tif(Yii::app()->db->getSchema()->getTable(\"{{auth_assignment}}\")){\n\t\t\t$this->dropTable(\"{{auth_assignment}}\");\n\t\t}\n\t}", "title": "" }, { "docid": "eafe2042624e15c52a7eb58b4406e19a", "score": "0.67153484", "text": "public function down()\n {\n Schema::table('companies', function (Blueprint $table) {\n //\n $table->id();\n $table->dropColumn('companyName');\n $table->dropColumn('country');\n $table->dropColumn('province');\n $table->dropColumn('city');\n $table->dropColumn('adress');\n $table->dropColumn('companyTel');\n $table->dropColumn('domaine');\n $table->dropColumn('position');\n $table->dropColumn('currency');\n $table->dropColumn('salary');\n $table->dropColumn('description');\n $table->dropColumn('dateFinal');\n $table->dropColumn('cvemail');\n $table->dropColumn();\n });\n }", "title": "" }, { "docid": "a7899cd9752aae2f96c6fca86829dc3d", "score": "0.67094964", "text": "public function down(Schema $schema) : void\n {\n $this->addSql('CREATE TABLE habits (id INT AUTO_INCREMENT NOT NULL, reference_habit VARCHAR(10) CHARACTER SET utf8mb4 NOT NULL COLLATE `utf8mb4_unicode_ci`, tarif INT NOT NULL, PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8 COLLATE `utf8_unicode_ci` ENGINE = InnoDB COMMENT = \\'\\' ');\n $this->addSql('CREATE TABLE lot_habit_habits (lot_habit_id INT NOT NULL, habits_id INT NOT NULL, INDEX IDX_CA857B6F45644286 (lot_habit_id), INDEX IDX_CA857B6FC2F9C136 (habits_id), PRIMARY KEY(lot_habit_id, habits_id)) DEFAULT CHARACTER SET utf8 COLLATE `utf8_unicode_ci` ENGINE = InnoDB COMMENT = \\'\\' ');\n $this->addSql('ALTER TABLE lot_habit_habits ADD CONSTRAINT FK_CA857B6F45644286 FOREIGN KEY (lot_habit_id) REFERENCES lot_habit (id) ON DELETE CASCADE');\n $this->addSql('ALTER TABLE lot_habit_habits ADD CONSTRAINT FK_CA857B6FC2F9C136 FOREIGN KEY (habits_id) REFERENCES habits (id) ON DELETE CASCADE');\n $this->addSql('DROP TABLE type_habit');\n $this->addSql('ALTER TABLE client DROP FOREIGN KEY FK_C7440455A8CBA5F7');\n $this->addSql('DROP INDEX IDX_C7440455A8CBA5F7 ON client');\n $this->addSql('ALTER TABLE client CHANGE nom nom VARCHAR(40) CHARACTER SET utf8mb4 NOT NULL COLLATE `utf8mb4_unicode_ci`, CHANGE prenom prenom VARCHAR(50) CHARACTER SET utf8mb4 NOT NULL COLLATE `utf8mb4_unicode_ci`, CHANGE numero numero INT NOT NULL, CHANGE lot_id lot_habit_id INT DEFAULT NULL');\n $this->addSql('ALTER TABLE client ADD CONSTRAINT FK_C744045545644286 FOREIGN KEY (lot_habit_id) REFERENCES lot_habit (id)');\n $this->addSql('CREATE INDEX IDX_C744045545644286 ON client (lot_habit_id)');\n $this->addSql('ALTER TABLE lot_habit CHANGE reference_lot reference_lot VARCHAR(10) CHARACTER SET utf8mb4 NOT NULL COLLATE `utf8mb4_unicode_ci`, CHANGE etat etat VARCHAR(25) CHARACTER SET utf8mb4 NOT NULL COLLATE `utf8mb4_unicode_ci`');\n }", "title": "" }, { "docid": "df4e8f3dfc2ec6e44521b88922380cf5", "score": "0.67084193", "text": "public function down()\n {\n $this->dropForeignKey(\n 'idx-gallery_image-ownerId',\n 'gallery_image'\n );\n\n $this->dropTable($this->tableName);\n }", "title": "" }, { "docid": "6ee27829873cddccbea03b0c56159593", "score": "0.6704606", "text": "public static function down() {\n\t\tSchema::dropTable(\"player\");\n\t}", "title": "" }, { "docid": "45394fb27f2729ce9a8360fb64ab2035", "score": "0.67031324", "text": "public function down()\n {\n $table = $this->table('article');\n\n $table->addColumn('published', 'datetime')\n ->addColumn('approvedby', 'string', array('limit' => 16))\n ->addForeignKey('approvedby', 'user', 'id', array('delete'=> 'RESTRICT', 'update'=> 'CASCADE'))\n ->save();\n\n // Now migrate over publication status\n foreach($this->fetchAll('SELECT * FROM article_publication WHERE republished = 0') as $article) {\n $this->execute('UPDATE article SET published = \"'.$article['publication_date'].'\" AND approvedby = \"'.$article['published_by'].'\" WHERE id = '.$article['article']); \n }\n\n // Finally, delete the old table\n $this->dropTable('article_publication');\n }", "title": "" }, { "docid": "ee331fdcf0fda0f4d75ff7084bfa00ef", "score": "0.6700049", "text": "public function safeDown()\r\n\t{\r\n\t\t$this->down();\r\n\t}", "title": "" }, { "docid": "ee331fdcf0fda0f4d75ff7084bfa00ef", "score": "0.6700049", "text": "public function safeDown()\r\n\t{\r\n\t\t$this->down();\r\n\t}", "title": "" }, { "docid": "ee331fdcf0fda0f4d75ff7084bfa00ef", "score": "0.6700049", "text": "public function safeDown()\r\n\t{\r\n\t\t$this->down();\r\n\t}", "title": "" }, { "docid": "040e75918b2be97fb25d583098a0ebe3", "score": "0.66969883", "text": "public function down()\n\t{\n\t\tSchema::drop('jpositions');\n\t\tSchema::drop('ppositions');\n\t\tSchema::drop('spositions');\n\t}", "title": "" }, { "docid": "4057b09a8511e65aa4fc8cc4c2bcc9dd", "score": "0.66930026", "text": "public function down(Schema $schema): void\n {\n $this->addSql('CREATE TABLE alerte_bon_plan (alerte_id INT NOT NULL, bon_plan_id INT NOT NULL, INDEX IDX_1EDEBCB72E81A751 (bon_plan_id), INDEX IDX_1EDEBCB72C9BA629 (alerte_id), PRIMARY KEY(alerte_id, bon_plan_id)) DEFAULT CHARACTER SET utf8 COLLATE `utf8_unicode_ci` ENGINE = InnoDB COMMENT = \\'\\' ');\n $this->addSql('CREATE TABLE alerte_code_promo (alerte_id INT NOT NULL, code_promo_id INT NOT NULL, INDEX IDX_47417016294102D4 (code_promo_id), INDEX IDX_474170162C9BA629 (alerte_id), PRIMARY KEY(alerte_id, code_promo_id)) DEFAULT CHARACTER SET utf8 COLLATE `utf8_unicode_ci` ENGINE = InnoDB COMMENT = \\'\\' ');\n $this->addSql('ALTER TABLE alerte_bon_plan ADD CONSTRAINT FK_1EDEBCB72C9BA629 FOREIGN KEY (alerte_id) REFERENCES alerte (id) ON DELETE CASCADE');\n $this->addSql('ALTER TABLE alerte_bon_plan ADD CONSTRAINT FK_1EDEBCB72E81A751 FOREIGN KEY (bon_plan_id) REFERENCES bon_plan (id) ON DELETE CASCADE');\n $this->addSql('ALTER TABLE alerte_code_promo ADD CONSTRAINT FK_47417016294102D4 FOREIGN KEY (code_promo_id) REFERENCES code_promo (id) ON DELETE CASCADE');\n $this->addSql('ALTER TABLE alerte_code_promo ADD CONSTRAINT FK_474170162C9BA629 FOREIGN KEY (alerte_id) REFERENCES alerte (id) ON DELETE CASCADE');\n $this->addSql('ALTER TABLE saved_bonplan DROP FOREIGN KEY FK_28FABDE7F52E2F80');\n $this->addSql('DROP INDEX IDX_28FABDE7F52E2F80 ON saved_bonplan');\n $this->addSql('ALTER TABLE saved_bonplan DROP PRIMARY KEY');\n $this->addSql('ALTER TABLE saved_bonplan CHANGE bon_plan_id bon_plan_id INT NOT NULL');\n $this->addSql('ALTER TABLE saved_bonplan ADD CONSTRAINT FK_28FABDE7F52E2F80 FOREIGN KEY (bon_plan_id) REFERENCES bon_plan (id)');\n $this->addSql('CREATE INDEX IDX_28FABDE7F52E2F80 ON saved_bonplan (bon_plan_id)');\n $this->addSql('ALTER TABLE saved_bonplan ADD PRIMARY KEY (user_id, bon_plan_id)');\n $this->addSql('ALTER TABLE saved_codepromo DROP FOREIGN KEY FK_EE06C9DC68FB988A');\n $this->addSql('DROP INDEX IDX_EE06C9DC68FB988A ON saved_codepromo');\n $this->addSql('ALTER TABLE saved_codepromo DROP PRIMARY KEY');\n $this->addSql('ALTER TABLE saved_codepromo CHANGE code_promo_id code_promo_id INT NOT NULL');\n $this->addSql('ALTER TABLE saved_codepromo ADD CONSTRAINT FK_EE06C9DC68FB988A FOREIGN KEY (code_promo_id) REFERENCES code_promo (id)');\n $this->addSql('CREATE INDEX IDX_EE06C9DC68FB988A ON saved_codepromo (code_promo_id)');\n $this->addSql('ALTER TABLE saved_codepromo ADD PRIMARY KEY (user_id, code_promo_id)');\n }", "title": "" }, { "docid": "1e9ceef806b0e211dd83bc9b079bf46e", "score": "0.6690192", "text": "public function down(Schema $schema) : void\r {\r $this->abortIf($this->connection->getDatabasePlatform()->getName() !== 'mysql', 'Migration can only be executed safely on \\'mysql\\'.');\r\r $this->addSql('ALTER TABLE answer DROP FOREIGN KEY FK_DADD4A251E27F6BF');\r $this->addSql('ALTER TABLE answer DROP FOREIGN KEY FK_DADD4A251CF5F25E');\r $this->addSql('ALTER TABLE game_context DROP FOREIGN KEY FK_779FFA51A76ED395');\r $this->addSql('ALTER TABLE game_constraint DROP FOREIGN KEY FK_D796491FDEE9D12B');\r $this->addSql('ALTER TABLE question DROP FOREIGN KEY FK_B6F7494EE48FD905');\r $this->addSql('ALTER TABLE characteristic DROP FOREIGN KEY FK_522FA950E48FD905');\r $this->addSql('ALTER TABLE game_constraint DROP FOREIGN KEY FK_D796491FE48FD905');\r $this->addSql('ALTER TABLE game_context DROP FOREIGN KEY FK_779FFA51E48FD905');\r $this->addSql('DROP TABLE answer');\r $this->addSql('DROP TABLE question');\r $this->addSql('DROP TABLE update_log');\r $this->addSql('DROP TABLE user');\r $this->addSql('DROP TABLE characteristic');\r $this->addSql('DROP TABLE game');\r $this->addSql('DROP TABLE game_constraint');\r $this->addSql('DROP TABLE game_context');\r }", "title": "" }, { "docid": "c8db2a4c05bc67fa58a183df1636704b", "score": "0.668846", "text": "public function safeDown()\n\t{\n\t\t$this->down();\n\t}", "title": "" }, { "docid": "c8db2a4c05bc67fa58a183df1636704b", "score": "0.668846", "text": "public function safeDown()\n\t{\n\t\t$this->down();\n\t}", "title": "" }, { "docid": "c8db2a4c05bc67fa58a183df1636704b", "score": "0.668846", "text": "public function safeDown()\n\t{\n\t\t$this->down();\n\t}", "title": "" }, { "docid": "fa916ec1712f1c1460f9769a505bec20", "score": "0.6687894", "text": "public function getDownSQL()\n {\n return array (\n 'default' => '\n# This is a fix for InnoDB in MySQL >= 4.1.x\n# It \"suspends judgement\" for fkey relationships until are tables are set.\nSET FOREIGN_KEY_CHECKS = 0;\n\nDROP TABLE IF EXISTS `user_level`;\n\nALTER TABLE `company` DROP PRIMARY KEY;\n\nALTER TABLE `company` CHANGE `company_id` `id` INTEGER NOT NULL AUTO_INCREMENT;\n\nALTER TABLE `company` DROP `company_added_by`;\n\nALTER TABLE `company` ADD PRIMARY KEY (`id`);\n\nALTER TABLE `user` DROP PRIMARY KEY;\n\nDROP INDEX `user_FI_2` ON `user`;\n\nALTER TABLE `user` CHANGE `user_id` `id` INTEGER NOT NULL AUTO_INCREMENT;\n\nALTER TABLE `user` CHANGE `user_fname` `first_name` VARCHAR(50);\n\nALTER TABLE `user` CHANGE `user_fname` `last_name` VARCHAR(50);\n\nALTER TABLE `user` CHANGE `user_email` `email` VARCHAR(200);\n\nALTER TABLE `user` CHANGE `user_gender` `gender` CHAR;\n\nALTER TABLE `user` CHANGE `user_birth_date` `birth_date` DATE;\n\nALTER TABLE `user` CHANGE `user_phone` `phone` VARCHAR(100);\n\nALTER TABLE `user` CHANGE `user_status` `status` VARCHAR(10);\n\nALTER TABLE `user` CHANGE `user_date_added` `date_added` DATETIME;\n\nALTER TABLE `user` DROP `user_lname`;\n\nALTER TABLE `user` DROP `user_user_role`;\n\nALTER TABLE `user` ADD PRIMARY KEY (`id`);\n\n# This restores the fkey checks, after having unset them earlier\nSET FOREIGN_KEY_CHECKS = 1;\n',\n);\n }", "title": "" }, { "docid": "711b8b9ec133238120a703268a7f4a8d", "score": "0.668357", "text": "public function down(Schema $schema) : void\n {\n $this->addSql('ALTER TABLE biblio_book DROP FOREIGN KEY FK_C723DF756407ABA');\n $this->addSql('ALTER TABLE biblio_book DROP FOREIGN KEY FK_C723DF716A2B381');\n $this->addSql('ALTER TABLE comments DROP FOREIGN KEY FK_5F9E962A16A2B381');\n $this->addSql('ALTER TABLE cover DROP FOREIGN KEY FK_8D0886C516A2B381');\n $this->addSql('ALTER TABLE type_book DROP FOREIGN KEY FK_1CEA663916A2B381');\n $this->addSql('ALTER TABLE writer_book DROP FOREIGN KEY FK_597EE01316A2B381');\n $this->addSql('ALTER TABLE comments DROP FOREIGN KEY FK_5F9E962AB706B6D3');\n $this->addSql('ALTER TABLE book DROP FOREIGN KEY FK_CBE5A331922726E9');\n $this->addSql('ALTER TABLE book DROP FOREIGN KEY FK_CBE5A33167402924');\n $this->addSql('ALTER TABLE type_book DROP FOREIGN KEY FK_1CEA6639C54C8C93');\n $this->addSql('ALTER TABLE biblio DROP FOREIGN KEY FK_D90CBB259EB185F9');\n $this->addSql('ALTER TABLE book DROP FOREIGN KEY FK_CBE5A3316995AC4C');\n $this->addSql('ALTER TABLE comments DROP FOREIGN KEY FK_5F9E962AF675F31B');\n $this->addSql('ALTER TABLE writer_book DROP FOREIGN KEY FK_597EE0131BC7E6B6');\n $this->addSql('DROP TABLE biblio');\n $this->addSql('DROP TABLE biblio_book');\n $this->addSql('DROP TABLE book');\n $this->addSql('DROP TABLE comments');\n $this->addSql('DROP TABLE cover');\n $this->addSql('DROP TABLE publishing_house');\n $this->addSql('DROP TABLE type');\n $this->addSql('DROP TABLE type_book');\n $this->addSql('DROP TABLE `user`');\n $this->addSql('DROP TABLE writer');\n $this->addSql('DROP TABLE writer_book');\n }", "title": "" } ]
b38e3de0cf130cfe3f0d5978497e658c
Permanently delete Education from storage.
[ { "docid": "f5fce75db7b7a2a99bcff509b99f5ca2", "score": "0.6196927", "text": "public function perma_del($id)\n {\n if (! Gate::allows('education_delete')) {\n return abort(401);\n }\n $education = Education::onlyTrashed()->findOrFail($id);\n $education->forceDelete();\n\n return redirect()->route('admin.education.index');\n }", "title": "" } ]
[ { "docid": "c8759f588d6de4815aad217280a39aa7", "score": "0.69943315", "text": "public function deleteAll(){\n DwEducation::query()->delete();\n }", "title": "" }, { "docid": "add51c26adec924e7fb72a855abb4ca0", "score": "0.6798883", "text": "public function destroy(Education $education)\n {\n $this->authorize('education.manage');\n\n $education->delete();\n\n alert()->success(trans('message.ctrl.education.destroy'))->persistent(\"Close\");\n\n return redirect(route('settings.index'));\n }", "title": "" }, { "docid": "178ecb293615d3cd3c581ac63720dab6", "score": "0.6658461", "text": "public function deleteEducation($educationId)\n {\n $this->createQueryBuilder('a')\n ->delete()\n ->where('a.Application =:educationId')\n ->setParameter('educationId',$educationId)\n ->getQuery()\n ->execute();\n }", "title": "" }, { "docid": "1035c41c821b744279f6a21456a103c0", "score": "0.6591219", "text": "public function DeleteEducation($id)\n {\n Education::where('id', $id)->delete();\n\n $redirectLink = '/seeker/profile/' . Auth::user()->id;\n return redirect($redirectLink);\n }", "title": "" }, { "docid": "9144e12a298c0eab3f8f6df1fbf89138", "score": "0.65828013", "text": "public function destroy(Education $education)\n {\n $education->bulletPoints()->delete();\n $education->delete();\n return back();\n }", "title": "" }, { "docid": "2a16eec4649872586b53cd9c5d322b4e", "score": "0.6528949", "text": "final public function delete()\n {\n $this->data->unlink();\n }", "title": "" }, { "docid": "2e049688183cadb17c81bef05f3de9fc", "score": "0.6517799", "text": "function del_education($id)\n {\n $this->db->where('id', $id);\n $this->db->delete('education');\n }", "title": "" }, { "docid": "6edd1b8b0f31b1185714a7d271dfcb26", "score": "0.6491019", "text": "public function destroy($id)\n {\n $education = Education::findOrFail($id);\n $education->delete();\n return redirect('/resume');\n }", "title": "" }, { "docid": "81dc227dc6729978b8e70fa719a5e4a9", "score": "0.64578235", "text": "public function destroy($id)\n {\n $model = new Model(\"education\");\n $conditions = array(\"id = \" . $id);\n $model->delete($conditions);\n }", "title": "" }, { "docid": "020a519fc19547f121e19326c01a6356", "score": "0.6442205", "text": "public function destroy(Education $education)\n {\n $education->delete();\n\n return redirect()->route('education.index')\n ->with('success', 'Education deleted successfully');\n }", "title": "" }, { "docid": "d0200b5511e373dc382f72a63508d06c", "score": "0.63948727", "text": "public function remove()\n {\n\n // delete it phsically\n Storage::delete($this->getAttribute('file_path'));\n\n // delete the db record\n $this->delete();\n\n }", "title": "" }, { "docid": "f57a1543be50c05c9d9e836022b5df10", "score": "0.63343394", "text": "public function deleteInStorage()\n {\n $driver = Storage::disk($this->storage);\n $driver->delete($this->source);\n\n $styles = $this->imagestyles()->filter(function ($item) {\n return $item['path'];\n });\n foreach ($styles as $style) {\n $driver->delete($style['path']);\n }\n }", "title": "" }, { "docid": "ac8ac612ba5ed7d51c40432a0df40461", "score": "0.6314677", "text": "public function cleanEntityStorage(): void;", "title": "" }, { "docid": "6135bcff168c3ab2e042cd2a00a4650c", "score": "0.6304457", "text": "protected function removeStorage()\n {\n $this->session->remove($this->formid);\n }", "title": "" }, { "docid": "8bc393920ebad94801cc00a9901b86e8", "score": "0.6295273", "text": "public function destroy($id)\n {\n $education = Education::findOrFail($id);\n $education->delete();\n toastr()->success('Success To Delete Education..');\n return back();\n\n }", "title": "" }, { "docid": "2931d9b75e0e409683172c9703f69836", "score": "0.6233597", "text": "public function delete(){\n Storage::cloud()->delete($this->url);\n parent::delete();\n }", "title": "" }, { "docid": "47cb71e12c5dd09f715be84a3c1cb22b", "score": "0.62295836", "text": "public function delete()\n {\n $this->mode = 'delete';\n \n $this->performDelete();\n }", "title": "" }, { "docid": "7b78ad6985f210ee1cf44e286b83e95a", "score": "0.6216181", "text": "public function delete(): void\n {\n if ($this->getSchoolClassId() >= 0) {\n $db = new DB();\n\n $db->startTransaction();\n\n $db->query(\"DELETE FROM templates WHERE FK_Class = ?\", $this->getSchoolClassId());\n $db->query(\"DELETE FROM `student` WHERE `student`.`FK_Class` = ?\", $this->getSchoolClassId());\n $db->query(\"DELETE FROM `templates` WHERE `templates`.`FK_Class` = ?\", $this->getSchoolClassId());\n $db->query(\"DELETE FROM `class` WHERE `class`.`PK_Class` = ?\", $this->getSchoolClassId());\n\n $db->commitTransaction();\n }\n }", "title": "" }, { "docid": "828b563bd8da42b2a743a067ebacaa1e", "score": "0.62003666", "text": "public function destroy($id)\n {\n if (! Gate::allows('education_delete')) {\n return abort(401);\n }\n $education = Education::findOrFail($id);\n $education->delete();\n\n return redirect()->route('admin.education.index');\n }", "title": "" }, { "docid": "1ff0354ec98125684a2a7f79c1a86828", "score": "0.61489296", "text": "function delete() {\n\n unlink($this->path);\n\n }", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.6146138", "text": "public function delete();", "title": "" }, { "docid": "d859b349ca89a71f71c6b7e9f118caef", "score": "0.6114861", "text": "public function delete()\n {\n $this->removeAllNodes();\n $this->storage->deleteLink($this->id);\n }", "title": "" }, { "docid": "8b0b4548ad7abade4ca3bca024dc64fc", "score": "0.6104409", "text": "public function destroy($id)\n {\n $experience= Experience::find($id)->delete();\n }", "title": "" }, { "docid": "f9520978afbaf3da90dc31b6415b2157", "score": "0.6100619", "text": "public function wipeStorage(): void\n {\n }", "title": "" }, { "docid": "bbd4fbeb169cce49dbdee4fcf4da3308", "score": "0.60794586", "text": "public function destroy(Storage $storage)\n {\n //\n }", "title": "" }, { "docid": "26aa2043ba9e2e4f16560ac76b7b21d0", "score": "0.6039272", "text": "public function delete()\n {\n $this->parseObject->destroy($this->useMasterKey);\n }", "title": "" }, { "docid": "450ebc775e61a9030c8bca5819d675c5", "score": "0.6022249", "text": "public function forceDelete();", "title": "" }, { "docid": "22132d56c3db86b2bc86da974688671e", "score": "0.5996945", "text": "public function delete()\n {\n $this->archive();\n }", "title": "" }, { "docid": "398fe98c4c3cfe0491a8e72e80249550", "score": "0.59822214", "text": "public function delete()\n {\n $this->deleteInStorage();\n\n return parent::delete();\n }", "title": "" }, { "docid": "1191f8b1401637303bd4807657f0ff14", "score": "0.5982163", "text": "public function destroy(Experience $experience)\n {\n //\n }", "title": "" }, { "docid": "3cc7d162a9399a6df3f87a5427370e3e", "score": "0.5979069", "text": "function delete()\n {\n // Delete from the database\n $this->dbInit();\n\n if ( isset( $this->ID ) )\n {\n $variationArray =& $this->variations();\n\n foreach( $variationArray as $variation )\n {\n $variation->delete();\n }\n\n $this->Database->query( \"DELETE FROM eZImageCatalogue_Image WHERE ID='$this->ID'\" );\n $this->Database->query( \"DELETE FROM eZImageCatalogue_ImagePermission WHERE ObjectID='$this->ID'\" );\n\n // Delete from the filesystem\n if ( file_exists ( $this->filePath( true ) ) )\n {\n unlink( $this->filePath( true ) );\n }\n }\n }", "title": "" }, { "docid": "af0643a44ddd78a45d8160d1456861e0", "score": "0.5946017", "text": "public function delete() {}", "title": "" }, { "docid": "af0643a44ddd78a45d8160d1456861e0", "score": "0.5946017", "text": "public function delete() {}", "title": "" }, { "docid": "cee7f3bd9d693669c37cc4e1ef97424b", "score": "0.59452", "text": "public function revokeIdentity()\n {\n if (!$this->storage->isEmpty()) {\n $this->storage->unsetIdentity();\n }\n }", "title": "" }, { "docid": "07e45bd0ec2446be664410fee5985aee", "score": "0.5939856", "text": "public function destroy()\n {\n if ($this->activeLock)\n $this->unlockFile();\n $this->datastoreObject = array();\n if ($this->currentDatastore == null)\n return;\n if (is_file($this->getDataFile()))\n unlink($this->getDataFile());\n if (is_file($this->getLockFile()))\n unlink($this->getLockFile());\n }", "title": "" }, { "docid": "00a92b43ed089e0a7e16cc76191c680d", "score": "0.5937324", "text": "public function delete()\n {\n $this->deleted = true;\n }", "title": "" }, { "docid": "00a92b43ed089e0a7e16cc76191c680d", "score": "0.5937324", "text": "public function delete()\n {\n $this->deleted = true;\n }", "title": "" }, { "docid": "9ebd94a50a2e958b6710ddc0436ae1ea", "score": "0.59351003", "text": "public function destroy(StorageRental $storageRental)\n {\n //\n }", "title": "" }, { "docid": "069b8305dbf7a52f30a2bac6943a8d27", "score": "0.5923391", "text": "public function delete()\n\t{\n\t\t$tbl_grade_evaluations = Database :: get_main_table(TABLE_MAIN_GRADEBOOK_EVALUATION);\n\t\t$sql = 'DELETE FROM '.$tbl_grade_evaluations.' WHERE id = '.intval($this->id);\n\t\tDatabase::query($sql);\n\t}", "title": "" }, { "docid": "b18729ba7267d2215a25c145726c3961", "score": "0.5922663", "text": "public function DeleteLemon50Assessment() {\n\t\t\t$this->objLemon50Assessment->Delete();\n\t\t}", "title": "" }, { "docid": "26beba6aab83ce493ecdc3c403b93140", "score": "0.59135795", "text": "public function delete()\n {\n\n $id = $this->uri->segment(4);\n $this->kvitancy_model->delete_kvitancy($id);\n redirect('admin/kvitancy');\n }", "title": "" }, { "docid": "c08dd55becb0a6161f478536f13fbf96", "score": "0.5913575", "text": "public function flush()\n {\n File::delete($this->storagePath);\n }", "title": "" }, { "docid": "77a73de0f7aaeca4dad6524d2d1a628a", "score": "0.5902642", "text": "public function delete()\n {\n $this->deleteOnProvider();\n\n $this->address()->delete();\n $this->daemonGenerations()->delete();\n $this->tasks()->delete();\n\n parent::delete();\n }", "title": "" }, { "docid": "4dbf284e94c74b19f2be577b0f361bb3", "score": "0.5898633", "text": "public function delete() {\n\t\t\tdosql(\"DELETE FROM students WHERE id = :id\", array(\":id\" => $this->id));\n\t\t}", "title": "" }, { "docid": "901346032d849135a1cc9b1c8ea4554a", "score": "0.5891326", "text": "public function remove()\n {\n $this->store->remove($this->identifier);\n }", "title": "" }, { "docid": "a7854e07536d87f85b58e1ab309b3b22", "score": "0.58879596", "text": "public function forceDeleted(Attendance $attendance)\n {\n //\n }", "title": "" }, { "docid": "1dc1a8a2087ca14979451f6309e2b1ec", "score": "0.5877694", "text": "public function delete() {\n // TODO: Delete recipe if record has been marked deleted and deleted linked data in other tables\n $sql = \"UPDATE Recipe SET Deleted=1\";\n runQuery($sql);\n }", "title": "" }, { "docid": "8423f8ec30148fe2246b328de86debc8", "score": "0.58736336", "text": "public function delete() {\n $id = $this->get_id();\n $this->persistent->delete();\n // Delete files.\n $fs = get_file_storage();\n $contextid = $this->get_template()->get_context()->id;\n $fs->delete_area_files($contextid, 'tool_certificate', 'element', $id);\n $fs->delete_area_files($contextid, 'tool_certificate', 'elementaux', $id);\n return true;\n }", "title": "" }, { "docid": "980487ed345f33342e7a244aa24704c7", "score": "0.5862547", "text": "public function deleteExperience(Experience $experience)\n {\n return Auth::user()->id == $experience->user_id ? $experience->delete() : exit('oops something went wrong !'); \n }", "title": "" }, { "docid": "daee036f6f1144bfd39ae9fb16a628e5", "score": "0.5860337", "text": "public function clear()\n {\n $this->storage->clear();\n }", "title": "" }, { "docid": "bf9a645b87f9454a0db80dbce51b3512", "score": "0.58461833", "text": "public function massDestroy(Request $request)\n {\n if (! Gate::allows('education_delete')) {\n return abort(401);\n }\n if ($request->input('ids')) {\n $entries = Education::whereIn('id', $request->input('ids'))->get();\n\n foreach ($entries as $entry) {\n $entry->delete();\n }\n }\n }", "title": "" }, { "docid": "4592eced28d09834d996940335900939", "score": "0.58403647", "text": "public function delete()\n\t{\n\t\tforeach ($this->collectable as $entity)\n\t\t{\n\t\t\t$entity->delete();\n\t\t}\n\t}", "title": "" }, { "docid": "c6a42846f59d058a9dec0b145180c1f0", "score": "0.5838755", "text": "public static function deleteUserEducation($id)\n {\n $userEducation = self::findOne(['id' => $id]);\n\n return ($userEducation->delete()) ? true : false;\n }", "title": "" }, { "docid": "de59a861d20794933f3fd4ca6d5a9323", "score": "0.5830113", "text": "public function delete()\n {\n $this->facilityOrm->delete();\n }", "title": "" }, { "docid": "9db8c0f345d1fcdfb9347172f787ddc3", "score": "0.58189136", "text": "public function delete_edition_mode() {\n\n\t\t$this->pikachu->multi_delete(\n\n\t\t\tarray('canEdit', 'edit_string', 'edit_url', 'edit_id')\n\n\t\t);\n\n\t}", "title": "" }, { "docid": "3ca7cef4e8c6a002055834009cea3101", "score": "0.58082944", "text": "public function delete() {\n\t\tif (array_key_exists($this->attributes['deleted_at'])) {\n\t\t\t$this->deleted_at = new \\DateTime;\n\t\t\t$this->save();\n\t\t}\n\t\telse {\n\t\t\tparent::delete();\n\t\t}\n\t}", "title": "" }, { "docid": "143f14c0ee71fc98a5cbd06040cd9309", "score": "0.58063835", "text": "public function delete() {\n \n parent::delete();\n }", "title": "" }, { "docid": "341eee7f4c6f9816490c439344c6ab6f", "score": "0.57913405", "text": "public function destroy(EducationCertificate $educationcertificate)\n {\n $educationcertificate->delete(); \n \n return Redirect::route('educationcertificates.index')->with(['success' => 'Education Certificate Deleted Successful']);\n }", "title": "" }, { "docid": "5c365415501875824094ddd44948a6e9", "score": "0.57821816", "text": "public function destroy(Assistant $assistant)\n {\n//delete user of assisant\n$assistant->users()->delete();\n\n//delete assistant\n$assistant->delete();\n\nreturn redirect('/assistant');\n }", "title": "" }, { "docid": "ac50b64c96a32340c85fb69572cd46ca", "score": "0.5779669", "text": "public function delete()\n\t{\n\t\t// cascad ?\n\t}", "title": "" }, { "docid": "d82f700b22a7cf979b91acc1a30e6590", "score": "0.5779536", "text": "public function delete(){\n\t\t$this->announcements_model->delete();\n\t}", "title": "" }, { "docid": "20b936cd00fe32951f5dfd1985ad720f", "score": "0.57786775", "text": "public function delete()\n {\n }", "title": "" }, { "docid": "5859a7840cdda12a4e6f97df0a0b00c4", "score": "0.57785183", "text": "public function destroy($id)\n {\n $doctorEducation = DoctorEducation::findOrFail($id);\n $doctorEducation->delete();\n return redirect()->back();\n }", "title": "" }, { "docid": "8f09754fe5bf5bad297292043787676f", "score": "0.5778044", "text": "public function delete()\n {\n //réservée à l'admin\n new SessionVerify();\n $educator = Becomeeducator::getOne($_GET['id']);\n if ($educator instanceof Becomeeducator) {\n $image = $educator->getImage();\n $educator->delete();\n unlink('uploads/' . $image);\n }\n $this->redirectToRoute(\"becomeeducator\", \"list\");\n }", "title": "" }, { "docid": "65d9262aaa2d8511e09375a64eebcea3", "score": "0.57739776", "text": "protected function deleteFromStorage(string $path): void\n {\n unlink($this->storagePath($path));\n }", "title": "" }, { "docid": "12164ebea653a31ba4bfb39695b4e71e", "score": "0.5765393", "text": "public function forceDelete()\n {\n $softDelete = static::$softDelete;\n static::$softDelete = false;\n $this->delete();\n static::$softDelete = $softDelete;\n }", "title": "" }, { "docid": "b4dfadc6661c9ed476901def6ca0d755", "score": "0.5760717", "text": "function deleteStudent($id) {\n $serializedData = file_get_contents(DB_NAME);\n $students = unserialize($serializedData);\n\n unset($students[$id-1]);\n $serializedData = serialize($students);\n file_put_contents(DB_NAME, $serializedData, LOCK_EX);\n}", "title": "" }, { "docid": "ac1331b3034356b3b51b06f362a6bc9a", "score": "0.575087", "text": "public function destroy($id)\n {\n $education = $this->educationRepository->find($id);\n\n if (empty($education)) {\n Flash::error('Education not found');\n\n return redirect(route('education.index'));\n }\n\n $this->educationRepository->delete($id);\n\n Flash::success('Education deleted successfully.');\n\n return redirect(route('education.index'));\n }", "title": "" }, { "docid": "9a335d422e2dc77084a2daee7d8a3c41", "score": "0.57507724", "text": "public function delete()\n {\n $this->value = null;\n $this->hit = false;\n $this->loaded = false;\n\n $entity = $this->createEntity();\n $this->pool->getEntityManager()->delete($entity)->flush();\n }", "title": "" }, { "docid": "e89debb0e311188d3990cbda6f1aae7d", "score": "0.5739916", "text": "public function delete() {\n\t\n\t}", "title": "" }, { "docid": "321f5a4cd8f16c801d95d71586c1c5ca", "score": "0.5737345", "text": "public function delete()\n {\n foreach ($this->students()->get() as $student) {\n //iterate all requirements of this course\n foreach ($this->baseClass->course->requirements()->get() as $requirement) {\n //iterate all student evaluations related to the requirement\n foreach ($student->SOEvaluations()->where('Requirement_Id', $requirement->Requirement_Id)->get() as $SOEvals) {\n $SOEvals->delete();\n }\n }\n }\n\n $this->students()->detach();\n\n return parent::delete(); // TODO: Change the autogenerated stub\n }", "title": "" }, { "docid": "290d1f995eadf964fd2e1de963a7d154", "score": "0.57287896", "text": "public function removeEducationDetails()\n\t{\n\t\t\n\t\t$educationid = Input::get('educationid');\n\t\t\n\t\tif($educationid)\n\t\t\t$del = EducationDetails::find($educationid)->delete();\n/*\t\t$countryid = Country::where(['country_name' => $input['countryId']])->value('country_id');\t\t\n\t\t$statequeries = State::where(['country_id' => $countryid])->get();\t\t\n\t\t$states = array('<option value=\"\">State</option>');\n\t\tforeach($statequeries as $query){\t\t\t\n\t\t\t$states[] = '<option value=\"'.$query->state_name.'\">'.$query->state_name.'</option>';\n\t\t}\t\t\n\t\techo implode('',$states);*/\n\t}", "title": "" }, { "docid": "381573c5a290ed7c540b8f0a2bdbfba6", "score": "0.5720161", "text": "public function destroy($id)\n {\n $estudiante = Estudiantes::find($id);\n $estudiante->delete();\n }", "title": "" }, { "docid": "eafae81d5f958603bc98de95e3dd70cb", "score": "0.5711282", "text": "public function destroy(Request $request) {\n $areaGuide = Testimonial::find($request->id);\n \n if(($areaGuide->image != null) && file_exists($areaGuide->image)){\n unlink($areaGuide->image);\n }\n \n $areaGuide->delete();\n return response()->json();\n }", "title": "" }, { "docid": "3d144a7c8f769d19013addf7ded826b9", "score": "0.57104707", "text": "public function deleteDacl()\n\t{\n\t\t$this->remove();\n\t}", "title": "" }, { "docid": "de2cc5bf7a8f4fde8b78e2e762f626e4", "score": "0.57055926", "text": "public function cleanUpStorage()\n {\n return null;\n }", "title": "" }, { "docid": "9f12cc29df65b91c72dbeb77e16cabbe", "score": "0.57054645", "text": "public function delete_how_to_learn_delete()\r\n\t{\r\n\t\t$details=array('how_to_learn_id'=>$this->uri->segment(2));\r\n\t\t$response = $this->how_to_learn_api->_delete_how_to_learn($details);\r\n\t\t$this->response($response, REST_Controller::HTTP_OK);\r\n\t}", "title": "" }, { "docid": "0bf43a7ec91685ba7a017b9f84526eb2", "score": "0.57037115", "text": "public function delete(){\n \treturn $this->persistency->delete($this->to_array());\n }", "title": "" }, { "docid": "9e1d042bf9beb73bf0bd909737159dcd", "score": "0.56956106", "text": "public function destroy($id)\n {\n $ad=Ad::find($id);\n //delete related file from storage\n $ad->delete();\n return redirect()->route('ads.index');\n }", "title": "" }, { "docid": "374c6e8620ddecdf651c640f4387a409", "score": "0.5690423", "text": "public function delete(): void\n {\n $this->close();\n }", "title": "" }, { "docid": "4bf620992e4c8914bc040375f1b5de14", "score": "0.5690027", "text": "public function delete() {\n try {\n $del = \"id=\".$this->developer->id;\n $deletion = $this->removeData($del);\n if ($deletion) {\n echo \"i have deleted the record\";\n }\n }\n catch (Exception $e) {\n echo \"An Error there was.<br>\".\n \"error code:\".$e->getCode().\"<br>\".\n $e->getMessage();\n }\n }", "title": "" }, { "docid": "ef42fa8a73733a3b047cf17cee76b9d5", "score": "0.568901", "text": "public function delete()\r\n\t{\r\n\t\t//\r\n\t}", "title": "" }, { "docid": "05eb03cdd2b8927a1585e7de3586a762", "score": "0.56881857", "text": "public function clear()\n\t{\n\t\t$this->storage()->clear();\n\t}", "title": "" }, { "docid": "093a9de0a6e83ac02476648ab0f0cc63", "score": "0.5661508", "text": "public function forceDelete()\n {\n }", "title": "" }, { "docid": "093a9de0a6e83ac02476648ab0f0cc63", "score": "0.5661508", "text": "public function forceDelete()\n {\n }", "title": "" } ]
f2aff5dcab36ee1123e34ae4b39442ab
/ Function: Get [String] user has a webmaster role
[ { "docid": "d31ad3b28be2184701b2f0297b11639a", "score": "0.0", "text": "function custom_list_user_administrator() {\n $list_user = custom_array_list_user_administrator();\n if (!empty($list_user[0])) {\n // dsm(join('+', $list_user));\n return join('+', $list_user);\n }\n else {\n return '1';\n }\n}", "title": "" } ]
[ { "docid": "9262ca00ff2dc61fabe1fe3b8adb8573", "score": "0.6908812", "text": "public function is_admin()\n {\n \t$user_data = $this->user_model->get_user_data_by_id();\n \t$user_role = $this->db->get_where('user_roles', array('id' => $user_data['role']))->row();\n \treturn $user_role->manage_other_users;\n }", "title": "" }, { "docid": "7f4c3b68860de72418cf70e4047289e2", "score": "0.6899105", "text": "private function getUserRole()\n {\n $user = $this->user;\n\n $admin = Sentinel::findRoleBySlug('super-admin');\n $dpeo = Sentinel::findRoleBySlug('dpeo');\n $adpeo = Sentinel::findRoleBySlug('adpeo');\n $teo = Sentinel::findRoleBySlug('teo');\n $ateo = Sentinel::findRoleBySlug('ateo');\n $teacher = Sentinel::findRoleBySlug('teacher');\n\n if ($user->inRole($admin)) {\n return 'admin';\n } elseif ($user->inRole($dpeo)) {\n return 'dpeo';\n } elseif ($user->inRole($adpeo)) {\n return 'adpeo';\n } elseif ($user->inRole($teo)) {\n return 'teo';\n } elseif ($user->inRole($ateo)) {\n return 'ateo';\n } elseif ($user->inRole($teacher)) {\n return 'teacher';\n }\n \n return false;\n }", "title": "" }, { "docid": "b4d8e9ec5db62b80181daabc987bc88a", "score": "0.66726184", "text": "function check_user_access() {\n\tif ( property_exists($this, 'allowed_roles') ) $allowed_roles = $this->allowed_roles;\n\telse $allowed_roles = array('administrator');\n\tglobal $user_ID;\n\tif ( !empty($user_ID) ) {\n\t\t$user = new WP_User($user_ID);\n\t\tif (!is_array($user->roles)) $user->roles = array($user->roles);\n\t\t\tforeach ($user->roles as $role) {\n\t \t\t\tif (in_array($role, $allowed_rows)) {\n\t\t\t\treturn $role;\n\t\t\t}\n\t\t}\n\t}\n\treturn false;\n}", "title": "" }, { "docid": "66638c2cfebadf5985264367ee9ce026", "score": "0.6593378", "text": "public function getIsUserSiteAdmin()\n {\n return $this->getProperty(\"IsUserSiteAdmin\");\n }", "title": "" }, { "docid": "e8a58ce47ea2a86d657050d8a1f6c60a", "score": "0.6554984", "text": "public function getUserRole()\r\n {\r\n $admin_user_session = Mage::getSingleton('admin/session');\r\n $adminUserId = $admin_user_session->getUser()->getUserId();\r\n return Mage::getModel('admin/user')->load($adminUserId)->getRole()->role_name;\r\n }", "title": "" }, { "docid": "91de5300eba7f61ce1faa1f32f960314", "score": "0.6544271", "text": "public static function getRole()\n {\n\t\tif(isset(Yii::$app->user->identity->hak_akses)){\n\t\t\treturn Yii::$app->user->identity->hak_akses;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n }", "title": "" }, { "docid": "8065e672fb719e21e7f86f165e416868", "score": "0.64175004", "text": "function get_current_user_role() {\n\n\tglobal $wp_roles;\n\n\t$current_user = wp_get_current_user();\n\n\t$roles = $current_user->roles;\n\n\t$role = array_shift($roles);\n\n\treturn isset($wp_roles->role_names[$role]) ? translate_user_role($wp_roles->role_names[$role] ) : false;\n\n}", "title": "" }, { "docid": "3c41f5286e8d4f70a50e401de9a56bff", "score": "0.6397396", "text": "public static function getUserRole()\n {\n return self::getInstance()->_getUserRole();\n }", "title": "" }, { "docid": "4101eb2f6a4c95dfc4c0534e6f8bfc90", "score": "0.6395185", "text": "function isAdmin(){\n $user = $this->loadUser(Yii::app()->user->id);\n return intval($user->role) == 1;\n }", "title": "" }, { "docid": "4c57ba7a7e5bcd62d375d0bdad711c8e", "score": "0.63836324", "text": "public function getRoleByUserUid()\r\n {\r\n \t$asRoles = self::getRoles();\r\n \t\r\n \tif (is_array($asRoles))\r\n\t \treturn $asRoles[0];\r\n\t \t\r\n\t\treturn false;\r\n }", "title": "" }, { "docid": "4630eb64dfb657076e00149b635ca640", "score": "0.63814056", "text": "function isAdmin(){\n$user = $this->loadUser(Yii::app()->user->user_id);\nreturn intval($user->user_role_id) == 1;\n}", "title": "" }, { "docid": "42bff7b3006763c761b8d64810289a32", "score": "0.637902", "text": "function getUserRole($userId) {\n\tglobal $db,$app;\n\t$sql = \"SELECT type FROM `users` WHERE id=\".$userId.\"\";\n\t$result = $db->getOne($db->query($sql));\n\tif($result->type == 1) {\n\t\treturn 'admin';\n\t} else {\n\t\treturn 'deliveryboy';\n\t}\n}", "title": "" }, { "docid": "2e3a77227942cac77a167b6535523e50", "score": "0.63506573", "text": "function isViewer($wpUser){\n for($i = 0; $i < count($wpUser->roles); $i++){\n if(strpos($wpUser->roles[$i], SARON_ROLE_PREFIX . SARON_ROLE_VIEWER) !== FALSE){ // CHECK IF THE USER IS A MEMBER OF THE GROUP (test)saron_edit\n return true;\n }\n } \n return false; \n }", "title": "" }, { "docid": "cf5982a3f184d7324219972739e6d383", "score": "0.6327104", "text": "public function _getUserRole()\n {\n $this->selftest();\n return $this->objectUserRole;\n }", "title": "" }, { "docid": "9086c89ae3bc493019e631e74c408bff", "score": "0.6325245", "text": "public function getUserRole()\n {\n return $this->userRole;\n }", "title": "" }, { "docid": "8e0f4442aa0508d3acaeba64f4967439", "score": "0.6322769", "text": "public static function requireAdmin() {\n\t$status = (Yii::$app->user->identity->roles == 'admin') ? true : false;\n return $status\n }", "title": "" }, { "docid": "290e02b68a865dbe9d2849be5fcc4745", "score": "0.6319009", "text": "public function getRole();", "title": "" }, { "docid": "290e02b68a865dbe9d2849be5fcc4745", "score": "0.6319009", "text": "public function getRole();", "title": "" }, { "docid": "290e02b68a865dbe9d2849be5fcc4745", "score": "0.6319009", "text": "public function getRole();", "title": "" }, { "docid": "c01eb2c8faf9549493d9b88f027196da", "score": "0.6316638", "text": "static function access () {\n onapp_debug(__CLASS__.' :: '.__FUNCTION__);\n $return = onapp_has_permission( array( 'roles' ) );\n onapp_debug( 'return => '.$return );\n return $return;\n }", "title": "" }, { "docid": "1c6a26316a22971ac8021b80b9bda763", "score": "0.63112384", "text": "protected function userIsAdmin ()\n {\n $tokenHeader = apache_request_headers();\n $token = $tokenHeader['token'];\n $datosUsers = JWT::decode($token, $this->key, $this->algorithm);\n\n if($datosUsers->nombre==\"admin\")\n {\n return true;\n }\n else\n {\n return false;\n } \n }", "title": "" }, { "docid": "ba63bb8be28a1a236e545c4f29988739", "score": "0.6306235", "text": "function shibboleth_get_user_role() {\n\t// wp_roles() requires WordPress version 4.3 or higher.\n\tif ( function_exists( 'wp_roles' ) ) {\n\t\t$roles = wp_roles();\n\t} else {\n\t\tglobal $wp_roles;\n\n\t\tif ( isset( $wp_roles ) ) {\n\t\t\t$roles = $wp_roles;\n\t\t} else {\n\t\t\t$roles = new WP_Roles();\n\t\t}\n\t}\n\n\t$shib_roles = apply_filters( 'shibboleth_roles', shibboleth_getoption( 'shibboleth_roles', array(), true ) );\n\t$user_role = shibboleth_getoption( 'shibboleth_default_role' );\n\n\tforeach ( $roles->role_names as $key => $name ) {\n\t\tif ( isset( $shib_roles[ $key ]['header'] ) ) {\n\t\t\t$role_header = $shib_roles[ $key ]['header'];\n\t\t}\n\t\tif ( isset( $shib_roles[ $key ]['value'] ) ) {\n\t\t\t$role_value = $shib_roles[ $key ]['value'];\n\t\t}\n\t\tif ( empty( $role_header ) || empty( $role_value ) ) {\n\t\t\tcontinue;\n\t\t}\n\t\t$values = explode( ';', shibboleth_getenv( $role_header ) );\n\t\tif ( in_array( $role_value, $values, true ) ) {\n\t\t\t$user_role = $key;\n\t\t\tbreak;\n\t\t}\n\t}\n\n\t$user_role = apply_filters( 'shibboleth_user_role', $user_role );\n\n\treturn $user_role;\n}", "title": "" }, { "docid": "9287aa6d92e61c012137d3473cd4de8e", "score": "0.6304042", "text": "protected function userRole() : string\n {\n return 'user';\n }", "title": "" }, { "docid": "12cf0c15e6a309f65379953ae32a100d", "score": "0.628241", "text": "public function getRole() : string;", "title": "" }, { "docid": "b8997d8d49507dde9c2c84e8f22d2aca", "score": "0.62814176", "text": "public function role(): mixed;", "title": "" }, { "docid": "edbbfa783a5a07a0b83fbec6526b3bbe", "score": "0.6263902", "text": "public function getRole() {}", "title": "" }, { "docid": "e9220e771e09cb3e033ac96f2f380e46", "score": "0.6259246", "text": "public function getUserRole() {\n\t\treturn $this->getSessionuserRole();\n\t}", "title": "" }, { "docid": "ee262c6be33099628274f7a52e5a1bea", "score": "0.6256488", "text": "function is_admin()\n{\n\n global $connection;\n\n if (IsLoggedIn()) {\n\n $result = query(\"SELECT user_role FROM users WHERE user_id = \" . $_SESSION['user_id'] . \"\");\n $row = fetchRecords($result);\n\n if ($row['user_role'] == 'Admin') {\n\n return true;\n } else {\n\n return false;\n }\n }\n}", "title": "" }, { "docid": "18ed6e1e3322a159ef556f64071ddca2", "score": "0.6252447", "text": "function is_admin()\r\n{\r\n global $sqlconnection;\r\n $currentuserid ='';\r\n if(IsLoggedIn())\r\n {\r\n $currentuserid = $_SESSION['userid'];\r\n }\r\n $userrolequery = \"SELECT User_Role FROM USER WHERE User_Id = $currentuserid \";\r\n $userroleresult = mysqli_query($sqlconnection,$userrolequery);\r\n if($userroleresult){\r\n $row = mysqli_fetch_assoc($userroleresult);\r\n if(strtolower($row['User_Role']) ==='admin'){\r\n return true;\r\n }\r\n else{\r\n return false;\r\n }\r\n }\r\n else{\r\n return false;\r\n }\r\n \r\n}", "title": "" }, { "docid": "259e3b19720a16c997adf48f360ec700", "score": "0.62509537", "text": "public function UserIsAdmin()\n {\n \t$user = $this->Auth->user();\n // debug($user);\n \n if($user != null)\n {\n if($user['role'] == 'admin')\n {\n return true;\n }\n }\n \n \treturn false;\n }", "title": "" }, { "docid": "6ee7f356eb4fdc42ebb3f5a498c118ee", "score": "0.6246966", "text": "public function isAdmin(){\n\n $isAdmin = false;\n\n foreach (Auth::user()->roles as $key => $value) {\n if ( $value['full-access'] == 'yes' || $value->id == 2) {\n $isAdmin = true;\n }\n }\n\n return $isAdmin;\n }", "title": "" }, { "docid": "50f03453455d0c68a11875fe61c5b536", "score": "0.62330675", "text": "function leadin_get_user_role ()\n{\n global $current_user;\n\n $user_roles = $current_user->roles;\n $user_role = array_shift($user_roles);\n\n return $user_role;\n}", "title": "" }, { "docid": "87bbbbb53ba27ca941a9dc6521c8e9de", "score": "0.6222976", "text": "function checkSingleRole($roleToCheck) {\n //Ensure user is logged in\n if(Auth::guest()) {\n return false;\n }\n $roleToCheck = strtolower($roleToCheck);\n //Ensure that the user is an admin or an owner\n $roles = Auth::user()->roles;\n //Loop through roles and check for permission\n foreach($roles as $role) {\n if($role->name == $roleToCheck) {\n return true;\n }\n }\n //User is not an admin\n return false;\n}", "title": "" }, { "docid": "9c5e0ca290c51825b88a44a579658fcd", "score": "0.62132937", "text": "function cs_get_user_role() {\n\tglobal $current_user;\n\t$user_roles = $current_user->roles;\n\t$user_role = array_shift($user_roles);\n\treturn $user_role;\n}", "title": "" }, { "docid": "67edb2392dd63dca08d57f71f8fbca30", "score": "0.62079763", "text": "public function authorize()\n {\n return Auth::user()->userRole->name === 'Super Admin' || Auth::user()->userRole->name === 'Admin';\n }", "title": "" }, { "docid": "0bd5699046ab6417f9bdd0bc97b37a45", "score": "0.6207082", "text": "function is_admin($username){\n global $connection;\n\n $query = \"SELECT user_role FROM users WHERE user_name = '{$username}'\";\n $result = mysqli_query($connection, $query);\n\n $row = mysqli_fetch_array($result);\n\n if(($row['user_role'] == 'Admin') || ($row['user_role' == 'admin'])){\n return true;\n }else{\n return false;\n }\n}", "title": "" }, { "docid": "6bd49a098c7012160a804334c7aecbf6", "score": "0.6200481", "text": "function wv_get_loggedin_user_role() {\n global $current_user;\n\n $user_roles = $current_user->roles;\n $user_role = array_shift($user_roles);\n\n return $user_role;\n }", "title": "" }, { "docid": "895481186dcc6733fa9abf5ef8cefeb4", "score": "0.6199561", "text": "public function isRole(){\n $r=Cache::get('role');\n if ((int)$r ==2)\n {\n return true;\n }\n else\n return false;\n }", "title": "" }, { "docid": "dc9de9539cf4ca249bada192c150132a", "score": "0.6175956", "text": "public function es_admin(){\n\t\t$user = $this->getUser();\n\t\tif ($user != null) {\n\t\t\t$roles = $user->getRoles();\n\t\t\treturn in_array('ROLE_ADMIN', $roles);\n\t\t}\n\t\treturn false;\n\t}", "title": "" }, { "docid": "561eee85a66ee497751825b952736693", "score": "0.61721295", "text": "public function rolesForUser();", "title": "" }, { "docid": "66e57d58cace4e721d40f0a2a8751441", "score": "0.61662096", "text": "public function authorize()\n {\n /* @var User $user */\n $user = \\Auth::user();\n $authorize = $user->hasRole(['admin', 'superadmin']);\n return $authorize;\n }", "title": "" }, { "docid": "5dccfcffd08f486850db033e9d628549", "score": "0.6162901", "text": "public function getUser_status_role()\n {\n return $this->user_status_role;\n }", "title": "" }, { "docid": "6fa025923714ba2dc30140bcc74ef601", "score": "0.6157588", "text": "public function isUser() {\n return $this->role === 'user';\n }", "title": "" }, { "docid": "f199b280fbc71b30989282c45b251dcf", "score": "0.6154236", "text": "static function getIsAdmin() {\n\t\t$user = ctrl_users::GetUserDetail();\n\t\tif($user['usergroupid'] == 1) {\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "title": "" }, { "docid": "3970d029c6dc58f60f2dcaf6b1717698", "score": "0.613351", "text": "private function wf_user_permission(){\n\t\t$current_user = wp_get_current_user();\n\t\t$user_ok = false;\n\t\tif ($current_user instanceof WP_User) {\n\t\t\tif (in_array('administrator', $current_user->roles) || in_array('shop_manager', $current_user->roles)) {\n\t\t\t\t$user_ok = true;\n\t\t\t}\n\t\t}\n\t\treturn $user_ok;\n\t}", "title": "" }, { "docid": "c9a123b0a18b9e1e1d0e5ecbb238d59c", "score": "0.6123685", "text": "public function isUserAssignable()\r\n {\r\n return strpos($this->assignRole,'ROLE_USER') !== false ? true : false;\r\n }", "title": "" }, { "docid": "7deaf9e957ca0ce9246f96a45eddaae5", "score": "0.61204237", "text": "function isManager(){\n\n $t = &get_instance();\n\n $user = $t->session->userdata(\"user\");\n\n return true;\n\n if($user->role == \"Manager\")\n return true;\n else\n return false;\n// $user = get_active_user();\n// $user_roles = get_user_roles();\n\n}", "title": "" }, { "docid": "0a0d7672ffa324d84049faf6f20d97b9", "score": "0.61114997", "text": "function is_Admin($username=''){\n\n global $connect;\n $sql=\"SELECT user_role FROM users WHERE username='$username'\";\n $result=mysqli_query($connect,$sql);\n if(!$result){\n die('QUERY FAILED'. mysqli_error($connect));\n }\n $row=mysqli_fetch_assoc($result);\n if($row['user_role'] == 'admin'){\n return true;\n }else{\n return false;\n }\n}", "title": "" }, { "docid": "a01d6fe959d4874086f74b27821e299e", "score": "0.6090406", "text": "public function role() {\n\t\ttry {\n\t\t\t\n\t\t\t$stmt = $this->_db->prepare('SELECT role FROM user WHERE username = :username');\n\t\t\t$stmt->execute(array('username' => $_SESSION['userName']));\n\t\t\t\t\t\n\t\t\t$row = $stmt->fetch();\n\n\t\t\treturn $row['role'];\n\t\t\t\n\t\t} catch(PDOException $e) {\n\t\t\techo '<p class=\"error\">'.$e->getMessage().'</p>';\n\t\t}\n\t}", "title": "" }, { "docid": "b04d318c318553e2c982cc7a81aec5d2", "score": "0.6087833", "text": "public function getUserRole() {\n return view('backend.acl.user_role');\n }", "title": "" }, { "docid": "82687115c0f23150e8fcb28ddcb93fc0", "score": "0.6087172", "text": "function is_admin() {\n\tglobal $connection;\n\n\tif(isLoggedIn()) {\n\t\t$query = \"SELECT user_role FROM users WHERE user_id =\" . $_SESSION['user_id']. \"\";\n\t\t$result = mysqli_query($connection, $query);\n\t\tconfirm($result);\n\n\t\t$row = mysqli_fetch_array($result);\n\n\t\treturn $row['user_role'] === 'admin' ? true : false;\n\t}\n}", "title": "" }, { "docid": "0c5acd04242b11ada42962c187851765", "score": "0.60826766", "text": "public function authorize()\n {\n $user = request()->user('api');\n return $user->isSenior();\n }", "title": "" }, { "docid": "10a0d42ca37c28467dd5b9579543f200", "score": "0.6075142", "text": "public function hasRole($name);", "title": "" }, { "docid": "2b76c490dd02b07e68bbfab6d03576b8", "score": "0.6074188", "text": "public function authorize()\n {\n return $this->user()->rol == 'admin' ? true : false;\n }", "title": "" }, { "docid": "39b21538ba00476cc1b2683b6f96d674", "score": "0.6072331", "text": "function is_admin(){\n if(isLoggedIn()){\n $result = query(\"SELECT user_role FROM users WHERE user_id=\" . $_SESSION['user_id'] );\n\n $row = fetchRecords($result);\n if($row['user_role'] == 'admin'){\n return true;\n }else{\n return false;\n }\n }\n\n return false;\n}", "title": "" }, { "docid": "4d662b97958fed14d6412a50ef38920b", "score": "0.6061167", "text": "function hasRights($roleid, $fullAccessAdmin = true){\r\n\r\n\t$hasRights = false;\r\n\r\n\tif($_SESSION[\"userinfo\"][\"admin\"] == 1 && ($fullAccessAdmin || $roleid == \"Admin\"))\r\n\t\t$hasRights = true;\r\n\telseif($roleid == \"\")\r\n\t\t$hasRights = true;\r\n\telse\r\n\t\tforeach($_SESSION[\"userinfo\"][\"roles\"] as $role){\r\n\r\n if($role == $roleid){\r\n\r\n\t\t\t\t$hasRights = true;\r\n break;\r\n\r\n }//endif\r\n\r\n }//endif\r\n\r\n\treturn $hasRights;\r\n\r\n}", "title": "" }, { "docid": "96a5e832e07fe7c7fcdcb189ff16d607", "score": "0.60608596", "text": "public function getHasReadRole()\n {\n return $this->getProperty(\"HasReadRole\");\n }", "title": "" }, { "docid": "db340c1e11921586c9287928f9f2167c", "score": "0.6046554", "text": "public static function get_user_role() {\n $user = \\Singular\\Authentication::get_user_data();\n\n $role = \"user_role\";\n\n if (isset($user[\"role\"])) {\n $role = $user[\"role\"];\n }\n\n return $role;\n }", "title": "" }, { "docid": "da8008c7e308b22c4c0aed72433a5d43", "score": "0.6038324", "text": "function isAdmin() {\n $user = $this->loadUser(Yii::app()->user->id);\n return intval($user->role) == 1;\n }", "title": "" }, { "docid": "7736ba18a7abcaffd1f951dc0da98152", "score": "0.60328764", "text": "public function getRole()\n {\n $userIdentity = $this->getIdentity();\n if ($userIdentity === false) {\n return false;\n }\n return $userIdentity->role;\n }", "title": "" }, { "docid": "0ce91678eb7fca30229fbb7e6390fd9b", "score": "0.60263306", "text": "public function hasAdminRole()\n {\n return \\in_array($this->getHighestRole(), [\n User::ROLE_SUPER_ADMIN,\n User::ROLE_ADMIN,\n ]);\n }", "title": "" }, { "docid": "3936b763adb872194a7812e4066c2254", "score": "0.6024198", "text": "function checkUserRole($userId, $roleToCheck) {\n //Ensure user is logged in\n\n $user = User::find($userId);\n if (is_null($user)) {\n return false; //User dose not exist\n }\n $roleToCheck = strtolower($roleToCheck);\n //Ensure that the user is an admin or an owner\n $roles = $user->roles;\n //Loop through roles and check for permission\n foreach($roles as $role) {\n if($role->name == $roleToCheck) {\n return true;\n }\n }\n //User is not an admin\n return false;\n}", "title": "" }, { "docid": "5257a92d8bfa734e384d87adc3ee74a8", "score": "0.60167307", "text": "function is_admin($username) {\n\n global $connection; \n\n $query = \"SELECT user_role FROM users WHERE username = '$username'\";\n $result = mysqli_query($connection, $query);\n confirmQuery($result);\n\n $row = mysqli_fetch_array($result);\n\n\n if($row['user_role'] == 'admin'){\n\n return true;\n\n }else {\n\n\n return false;\n }\n\n}", "title": "" }, { "docid": "067bd87b0d756557c85471ba189f19f8", "score": "0.60164225", "text": "function jpen_get_user_roles() {\n global $wp_roles;\n\n $roles = $wp_roles->get_names();\n\n return $roles;\n}", "title": "" }, { "docid": "85d552dae16ce0e267411ee6bc2ab976", "score": "0.6012476", "text": "public function authorize()\n {\n $user = Auth::user();\n return $user && $user->rol == 'admin';\n }", "title": "" }, { "docid": "1455461206b5e5eb2e27ab454828bfa7", "score": "0.6010366", "text": "public function authorize()\n {\n $user = $this->user();\n return in_array($user->role->name, ['superadmin','admin','company']);\n }", "title": "" }, { "docid": "ed2983120593fb699ce83135ffde460f", "score": "0.6003991", "text": "public function role();", "title": "" }, { "docid": "9f8690ec2b20e5f7d946aad7051b385f", "score": "0.60035604", "text": "public function isAdmin() {\r\n\r\n return $this->hasRole('Administrator') || $this->hasRole('urn:lti:sysrole:ims/lis/SysAdmin') ||\r\n $this->hasRole('urn:lti:sysrole:ims/lis/Administrator') || $this->hasRole('urn:lti:instrole:ims/lis/Administrator');\r\n\r\n }", "title": "" }, { "docid": "14544fe11b443d7427cb21014d229505", "score": "0.6001913", "text": "public function getIncludeAdministratorSystemUserRole() : bool\n {\n return $this->includeAdministratorSystemUserRole;\n }", "title": "" }, { "docid": "ff61e7eb5e6a1a80a0c1f5902c9ac238", "score": "0.5999982", "text": "public function getIsAdministrator() {}", "title": "" }, { "docid": "378597d7c21ff806cb6d8fd72da6afff", "score": "0.599985", "text": "function is_admin($userId){\n $query = selectRecord(TAB_USR_ROLE, \"userId = $userId\");\n if($query['groupId'] == 1)\n return 1;\n else\n return 0;\n}", "title": "" }, { "docid": "63cbd639b0a79ea3dad447262b84d58a", "score": "0.5992779", "text": "function wp_ff_get_user_role($user_ID) {\r\n\r\n\tglobal $wpdb;\r\n\t\r\n\t$meta_key = $wpdb->get_row($wpdb->prepare(\"SELECT umeta_id, user_id, meta_key FROM $wpdb->usermeta WHERE user_id = %d AND meta_key = 'wp_capabilities'\",$user_ID));\r\n\r\n\t$usermeta = $wpdb->get_row($wpdb->prepare(\"SELECT * FROM $wpdb->usermeta WHERE umeta_id = %d\",$meta_key->umeta_id));\r\n\t\r\n\treturn unserialize($usermeta->meta_value);\r\n\t\r\n}", "title": "" }, { "docid": "3524110bd6b4caf84a1703d7acb407f7", "score": "0.59832394", "text": "public function isRole(){\n $r=Cache::get('role');\n if ((int)$r ==1 || (int)$r ==3)\n {\n return true;\n }\n else\n return false;\n }", "title": "" }, { "docid": "a6fe1ca71e45328b9820c3e6e28b2b90", "score": "0.5958506", "text": "function getIsAdmin(){\n\t\treturn ( $this->user && $this->user->access_level >= User::LEVEL_ADMIN );\n\t}", "title": "" }, { "docid": "da3d90ddb2eee49175e3702c7d42a375", "score": "0.5957007", "text": "public function authorize()\n {\n if (Auth::user()->role == 'admin') return true;\n }", "title": "" }, { "docid": "d54b38d48501e5728c2ce303585d51cb", "score": "0.59559584", "text": "protected function _getUserRoleId()\n {\n $cuser = $this->_getUser();\n $role_id = (empty($cuser)) ? ROLE_GUEST : $cuser['role_id'];\n\n return $role_id;\n }", "title": "" }, { "docid": "c11886e45ede4894f6ee0358f4d78524", "score": "0.5955375", "text": "public function getIsAdminAttribute()\n\t{\n\t\tif($this->roles->isEmpty())\n\t\t\treturn 0;\n\t\treturn $this->roles[0]->name == 'admin';\n\t}", "title": "" }, { "docid": "2914d4d38eb4591da353038ead6a2fc9", "score": "0.5952936", "text": "public function getAssignable() {\n\t\treturn (($this->role != self::ROLE_ADMINISTRATOR) && Controller::isAdmin());\n\t}", "title": "" }, { "docid": "3c5831e76055be347dce73cccd8722bf", "score": "0.5950332", "text": "function get_user_role() {\n global $current_user;\n $user_roles = $current_user->roles;\n $user_role = array_shift($user_roles);\n return $user_role; // return translate_user_role( $user_role );\n}", "title": "" }, { "docid": "600e38ce61e36464863f408d60c9ff05", "score": "0.59446245", "text": "public function isAdmin()\n {\n // Look for value only if not already set\n if(!isset($this->isAdmin)) {\n $us = SemanticScuttle_Service_Factory::get('User');\n $this->isAdmin = $us->isAdmin($this->username);\n }\n return $this->isAdmin;\n }", "title": "" }, { "docid": "5e48db35ceddc72708193b0ca1522ea5", "score": "0.59435487", "text": "public function check_role($username) \n {\n $this->db->select('role');\n $this->db->from('user');\n $this->db->where('adminNumber', $username);\n $query = $this->db->get(); \n $row = $query->row();\n return $row->role;\n }", "title": "" }, { "docid": "fb21a11e75b778582229d45ece5af129", "score": "0.5940094", "text": "public function getRole()\n {\n return $this->access_level;\n }", "title": "" }, { "docid": "1f3f4535dfe8443d2fe9572ae23f76e3", "score": "0.5925655", "text": "function user_role()\n\t{\n\t\t$CI =& get_instance();\n\t\treturn $CI->session->userdata('user_role');\n\t}", "title": "" }, { "docid": "4ba04982c15fc31c0e7c5cc83f18eba1", "score": "0.59245443", "text": "public function getRole()\n\t\t{\n\t\t\tif(isset($_COOKIE['info']))\n\t\t\t{\n\t\t\t\t$info = explode(':',$_COOKIE['info']);\n\t\t\t\treturn $info[0];\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "6617fbe1143da7cb2f81b2293bba81d1", "score": "0.59239376", "text": "function requires_webauth() {\n return $this->auth->requires_webauth();\n }", "title": "" }, { "docid": "0fb67ddf08041c637a279af722351eec", "score": "0.59200174", "text": "function is_admin(){\n global $connection; \n\n if(isLoggedIn()){\n $query = \"SELECT user_role from users where user_id=\".$_SESSION['user_id'].\"\"; \n $result = query($query); \n // confirm_query($result); // because it is embeded in query function \n $row = fetchRecord($result); \n if ($row['user_role'] == 'admin') {\n return true; \n }else {\n return false; \n }\n }\n return false; \n}", "title": "" }, { "docid": "5d7a75161df5304a1f79c9958e728a77", "score": "0.5917901", "text": "public static function getRole()\n\t{\n\t\treturn self::getUser()->getRole();\n\t}", "title": "" }, { "docid": "3fb0c1040c5307b92730d54b8cd17611", "score": "0.5917432", "text": "public function hasRole($role): bool;", "title": "" }, { "docid": "40af44d64e6a18f2271728620b8bdf62", "score": "0.591663", "text": "public function get_role()\n {\n }", "title": "" }, { "docid": "9891fd763a09919751200988367035c2", "score": "0.59136295", "text": "public function isAdmin()\n {\n return ($this->role == 1) ? true : false;\n }", "title": "" }, { "docid": "907d02e1fcde7577f858e111c663f4bf", "score": "0.5908333", "text": "public function getIsAdmin()\r\n {\r\n return $this->role === self::ROLE_ADMIN;\r\n }", "title": "" }, { "docid": "ab3ee43e4ef5fe8f905d863309cfdeca", "score": "0.5900659", "text": "function hasRole($request, $roleName)\n {\n //dd($request->auth->username === \"admin\");\n if ($request->auth->username === \"admin\") {\n return true;\n } else {\n $has_role = false;\n foreach ($request->auth->roles as $role) {\n if ($role->name == $roleName) {\n $has_role = true;\n }\n }\n return $has_role;\n }\n }", "title": "" }, { "docid": "b778c059d6c8d2d4894a72b47357b072", "score": "0.5898772", "text": "function isOrgEditor($wpUser){\n for($i = 0; $i < count($wpUser->roles); $i++){\n if(strpos($wpUser->roles[$i], SARON_ROLE_PREFIX . SARON_ROLE_ORG) !== FALSE){ // CHECK IF THE USER IS A MEMBER OF THE GROUP (test)saron_edit\n return true;\n }\n } \n return false; \n }", "title": "" }, { "docid": "b9cd57c366a6a09396cefe03ad466a17", "score": "0.589172", "text": "public function authorize() {\n\t\treturn $this->user()->is_admin;\n\t}", "title": "" }, { "docid": "86bf6d581c6840ee3b030b9d58e4de7b", "score": "0.5891365", "text": "public function authorize()\n {\n return Auth::user()->user_role === config('settings.roles.user');\n }", "title": "" }, { "docid": "447221515c0a0f3b908e82ab4bab1f82", "score": "0.58873105", "text": "public function getRoleOfUser() {\n $role = Authassignment::model()->find(array(\n 'select' => '*',\n 'condition' => 'userid =:userId',\n 'params' => array(':userId' => $this->user_id),\n ));\n return $role->itemname;\n }", "title": "" }, { "docid": "eb14687f4a751412e8a02b2aac9d9a39", "score": "0.58843017", "text": "function hasRole($user, $role){\n\n if(ucfirst($user->role) == 'Root'){\n return true;\n }\n else {\n if($user->role == ucwords($role)){\n return true;\n }\n else {\n return false;\n }\n }\n }", "title": "" }, { "docid": "5c495db5b8c6c8cc6b33c354057d0f72", "score": "0.58841825", "text": "public function hasAccess() {\n // This is the TokenAuthUser.\n // The Publisher role is not assigned to the user,\n // it is only used to scope the consumer.\n /** @var \\Drupal\\Core\\Session\\AccountProxyInterface $user */\n $userAccount = $this->currentUser();\n // Verify permission against User entity.\n $userEntity = User::load($userAccount->id());\n if ($userEntity->hasPermission('access publisher')) {\n return new JsonResponse([\n 'access' => TRUE,\n ], 200);\n }\n else {\n return new JsonResponse([\n 'access' => FALSE,\n ], 403);\n }\n }", "title": "" }, { "docid": "c2f8229304ac6918b03ed9250a351576", "score": "0.5878281", "text": "public function isAdmin(){\n if($this->role==\"admin\"){\n return true;\n }\n return false;\n }", "title": "" }, { "docid": "0382652bbeb179e571caa0776c941213", "score": "0.58738756", "text": "function checkrole($rolename, $check_superset = true)\n{\n global $G_SYMFONY, $apiFromInternal;\n if (isset($apiFromInternal) && $apiFromInternal === true) {\n return true;\n }\n return $G_SYMFONY->checkrole($rolename, $check_superset);\n}", "title": "" }, { "docid": "a8cb0f55b2ea4033a97fdadf228ea1c2", "score": "0.58722275", "text": "public function authorize()\n {\n return $this->user() && $this->user()->role === Constants::USER_ROLE_ADMIN;\n }", "title": "" } ]
b635910a26740ef5d8e689b61d3b1a0b
Retrieves a list of models based on the current search/filter conditions.
[ { "docid": "9e0a7420707a6308d25c6a031af880a7", "score": "0.0", "text": "public function search() {\n // Warning: Please modify the following code to remove attributes that\n // should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('host_id', $this->host_id);\n $criteria->compare('surf_id', $this->surf_id);\n $criteria->compare('type', $this->type);\n $criteria->compare('title', $this->title, true);\n $criteria->compare('content', $this->content, true);\n $criteria->compare('couch_number', $this->couch_number);\n $criteria->compare('status', $this->status);\n $criteria->compare('arrive_date', $this->arrive_date, true);\n $criteria->compare('leave_date', $this->leave_date, true);\n $criteria->compare('create_time', $this->create_time, true);\n $criteria->compare('deal_time', $this->create_time, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "title": "" } ]
[ { "docid": "6c1a920efd4686b6996345830e2c6903", "score": "0.6890721", "text": "public function getModels()\r\n {\r\n $query = $this->getQuery();\r\n $models = $query->all();\r\n return $models;\r\n }", "title": "" }, { "docid": "5c5084da01a3d18e3878dff9220c3a43", "score": "0.6745192", "text": "public function getModels();", "title": "" }, { "docid": "ff10c2f7c2cd2a28de8c1eedaf03c453", "score": "0.6554302", "text": "public function models(): Enumerable\n {\n return ModelsFinder::find(...$this->discoverModelsUsing);\n }", "title": "" }, { "docid": "c6c2fbb78bb06b62fded410bb62a3d58", "score": "0.6509238", "text": "public function modelSearch($sType, $hWhere = null, $xOrder = null)\n {\n $oList = Model::search($this->defaultModelType($sType), $hWhere, $xOrder, $this->getDB());\n $oList->setApp($this);\n return $oList;\n }", "title": "" }, { "docid": "e80dce7ca35733405fa16daa34818f83", "score": "0.63156456", "text": "public function all()\n {\n $builder = $this->getModel()->newQuery();\n\n foreach($this->activeFilters as $filter)\n {\n $argsToPass = $filter->args;\n array_unshift($argsToPass, $filter->name);\n call_user_func_array([$builder, 'where'], $argsToPass);\n }\n\n $this->activeFilters = [];\n\n return $builder->get();\n }", "title": "" }, { "docid": "c086807117d6a6ab325d7832637b6962", "score": "0.629408", "text": "public function getModels(){\t\t\n\t\n\t\t$models=array();\n\t\t$classes=$this->findClasses('model');\n\t\tforeach($classes as $class){\n\t\t\t\tif(!$class->isAbstract()){\t\t\t\t\t\n\t\t\t\t\t$models[] = $class;\n\t\t\t\t}\n\t\t}\t\t\n\t\treturn $models;\n\t}", "title": "" }, { "docid": "c1a5e127020d07ac98d3ad8996720508", "score": "0.6168778", "text": "public function listAll($model = null, $disable_search = false)\n {\n try {\n if (! is_null($model)) {\n $this->model = $model;\n }\n\n if (! empty($this->with)) {\n $this->model = $this->model->with($this->with);\n }\n\n $search = null;\n $search_field = null;\n $search_mode = null;\n $search_exact = false;\n if (request()->has('search') && !$disable_search) {\n $search = request('search');\n $search_field = request()->has('search_field') ? request('search_field') : '';\n $search_mode = request()->has('search_mode') ? request('search_mode') : 'or';\n $search_exact = false;\n } elseif (request()->has('search_exact') && !$disable_search) {\n $search = request('search_exact');\n $search_field = request()->has('search_field') ? request('search_field') : '';\n $search_mode = request()->has('search_mode') ? request('search_mode') : 'or';\n $search_exact = true;\n }\n\n if (! is_null($search)) {\n // support multiple search\n if (! is_array($search)) {\n $search = [$search];\n }\n if (! is_array($search_field)) {\n $search_field = [$search_field];\n }\n\n if ($search_exact) {\n $this->model = $this->model->searchExactMultiple($search, $search_field, $search_mode);\n } else {\n $this->model = $this->model->searchMultiple($search, $search_field, $search_mode);\n }\n }\n\n $order = request()->has('order') ? request('order') : $this->modelPrimaryKeyName;\n $atoz = request()->has('atoz') ? request('atoz') : 'asc';\n\n // support multiple order by\n if (! is_array($order)) {\n $order = [$order];\n }\n if (! is_array($atoz)) {\n $atoz = [$atoz];\n }\n foreach ($order as $i => $order_item) {\n $atoz_item = isset($atoz[$i]) ? $atoz[$i] : 'asc';\n $this->model = $this->model->order($order_item, $atoz_item);\n }\n\n if (request()->has('page_len') && request('page_len') == 'all') {\n return $this->model->paginate(999);\n }\n return $this->model->paginate(\n request()->has('page_len')\n ? request('page_len')\n : 30\n );\n } catch (\\Exception $e) {\n throw $e;\n }\n }", "title": "" }, { "docid": "a222f875b800d7c431c44c431b2bd255", "score": "0.6137669", "text": "public function getList() {\n $list = parent::getList();\n\n // Always limit by model class, in case you're managing multiple\n if($this->modelClass == 'ResearchResource') {\n $list = $list\n \t->innerJoin('ResearchResource_ArticleTypes', \"ResearchResource.ID = ResearchResource_ArticleTypes.ResearchResourceID\")\n \t->innerJoin('ResourceArticleType', \"ResearchResource_ArticleTypes.ResourceArticleTypeID = ResourceArticleType.ID\")\n \t->filter(array('ResourceArticleType.Name:PartialMatch' => 'e-Bulletin'))\n \t->sort('Created DESC');\n }\n\n return $list;\n }", "title": "" }, { "docid": "3bf0aae3ea6622e88db6d4fabc712dff", "score": "0.6130853", "text": "public function getSearchList()\n {\n return $this->search->getList();\n }", "title": "" }, { "docid": "f60dfde510ade227665b0ea2c9a23247", "score": "0.61300707", "text": "public function getSearch()\n {\n if($this->model_params['query'] != '')\n {\n\t\t\t$streams_manager = new MediasManager;\n\t\t\t$games_manager = new MediasManager;\n\t\t\t\n\t\t\t$twitch = new Twitch;\n $twitch->getSearchFromPlatform($this->model_params['query']);\n\t\t\t$streams_manager->setMediasArray($twitch->getStreams());\n\t\t\t$games_manager->addGames($twitch->getGames());\n\t\t\t\n\t\t\t$smashcast = new Smashcast;\n $smashcast->getSearchFromPlatform($this->model_params['query']);\n\t\t\t$streams_manager->setMediasArray($smashcast->getStreams());\n\t\t\t$games_manager->addGames($smashcast->getGames());\n\n\t\t\t$this->model_data['streams_array'] = $streams_manager->getMediasToDisplay(100, 0, [\"All\",\"Twitch\",\"Smashcast\"]);\n\t\t\t$this->model_data['games_array'] = $games_manager->getMediasArray();\n\t\t\t$this->model_data['offline_streamers'] = array_merge($twitch->getOfflineStreamers(), $smashcast->getOfflineStreamers());\n }\n }", "title": "" }, { "docid": "509d173cabb08089d8cced2d3a438c25", "score": "0.6123331", "text": "public function getModels($model= null) {\n \tif(!$model){\n \t\treturn response()->json('Debes ingresar el modelo a consultar', 500);\n \t}\n\t\t$models = $this->odoo\n\t\t\t\t// ->where('customer', true)\n // ->limit(1)\n ->get($model);\n return response()->json($models, 200);\n }", "title": "" }, { "docid": "b45927db8d5cd59ab0560bb5e432c401", "score": "0.6109287", "text": "public function search()\n {\n if ($this->hasOption('like')) {\n $this->query->where($this->option('where'), 'like', \"%{$this->option('like')}%\");\n }\n\n if ($this->hasOption('equals')) {\n $this->query->where($this->option('where'), $this->option('equals'));\n }\n\n return $this->query->get();\n }", "title": "" }, { "docid": "7b771ccec8c4d825b1eaa38df66bff02", "score": "0.6094454", "text": "public function all()\n {\n $this->newQuery()->eagerLoad();\n $models = $this->query->get();\n $this->unsetClauses();\n return $models;\n }", "title": "" }, { "docid": "134c00531494e3e432856ee99508a7dd", "score": "0.60764295", "text": "public function get()\n {\n $this->newQuery()->eagerLoad()->setClauses()->setScopes();\n $models = $this->query->get();\n $this->unsetClauses();\n return $models;\n }", "title": "" }, { "docid": "da4ba66df31035f15c22ca6247be1e6e", "score": "0.60690886", "text": "public function getModels()\n {\n return empty($this->_models) ? array() : $this->_models;\n }", "title": "" }, { "docid": "1d10efc7b08b1c7aa946f7fdd964f573", "score": "0.6004011", "text": "public function index()\n {\n $model = $this->name;\n\n // Check GET request\n if (!$this->request->is('get')) {\n $this->Flash->error(__('Invalid request'));\n return;\n }\n\n // Check normal pagination\n if (!$this->request->getQuery('column', 0) && !$this->request->getQuery('value', 0)) {\n return;\n }\n\n // Check filter column supplied\n if (!$this->request->getQuery('column', 0)) {\n $this->Flash->error(__('Filter column not specified'));\n return;\n }\n\n // Check filter value supplied\n if (!$this->request->getQuery('value', 0)) {\n $this->Flash->error(__('Filter vallue not specified'));\n return;\n }\n\n $column = $this->request->getQuery('column');\n $value = $this->request->getQuery('value');\n return $column == 'id'\n ? [\"$model.id\" => [$value]]\n : [\"$model.$column LIKE\" => \"%$value%\"];\n }", "title": "" }, { "docid": "867d950db038c768bb32b8090a697467", "score": "0.59965914", "text": "public function searchByFieldsAndAnyModel() {\n $this -> viewClass = 'Json';\n $res = array();\n $data = $this -> request -> data;\n if (isset($data['fields_in'], $data['value'], $data['model'], $data['fields_out'])) {\n\n if ($this -> Check -> isset_model($data['model'])) {\n try {\n $this -> loadModel($data['model']);\n $fields = explode(GLUE, $data['fields_out']);\n $fields_condtions = explode(GLUE, $data['fields_in']);\n $conditions = $this -> Common -> mapTwoArray($data['value'], $fields_condtions);\n if (array_key_exists('del_flag', $this -> $data['model'] -> getColumnTypes())) {\n $conditions[$data['model'] . '.del_flag'] = FALSE;\n }\n $data_find[] = $this -> $data['model'] -> find('first', array('conditions' => $conditions, 'fields' => $fields, 'recursive' => -1));\n if ($this -> Check -> is_multiArrayEmpty($data_find)) {\n $res['status'] = STS_EMPTY;\n } else {\n $res['status'] = STS_SUCCESS;\n $res['data_res'] = $data_find;\n }\n } catch(Exception $e) {\n echo 'Exception: ', $e -> getMessage(), \"\\n\";\n $this -> log('Exception: ' . $e -> getMessage(), LOG_ERROR);\n }\n } else {\n $res['status'] = STS_ERROR_AUTH;\n }\n } else {\n $res['status'] = STS_ERROR_MISSINGDATA;\n }\n $this -> set(compact('res'));\n $this -> set('_serialize', array('res'));\n }", "title": "" }, { "docid": "5ca1f015d31b82dfadc4587d6024823a", "score": "0.59892213", "text": "public function filterByAll()\n {\n\n return $this->query\n ->allowedIncludes(\n $this->getAllowedIncludes()\n )\n ->allowedFilters(\n $this->buildFilter('partial')\n )\n ->get();\n\n }", "title": "" }, { "docid": "184718187540fa269a2f4e4238eb97f1", "score": "0.59875655", "text": "public static function search(string $keyword)\n {\n if (self::isTesting()) {\n $files = File::allFiles(__DIR__ . '/../tests/Models');\n } else {\n $files = File::allFiles(app()->basePath() . '/app/' . config('fullsite-search.model_path'));\n }\n\n // to get all the model classes\n return collect($files)\n ->map([self::class, 'parseModelNameFromFile'])\n ->filter([self::class, 'filterSearchableModel'])\n ->map(function ($classname) use ($keyword) {\n // for each class, call the search function\n /** @var $model Model */\n $model = app(self::modelNamespacePrefix() . $classname);\n\n /**\n * Our goal here: to add these 3 attributes to each of our search result:\n * a. `match` -- the match found in our model records\n * b. `model` -- the related model name\n * c. `view_link` -- the URL for the user to navigate in the frontend to view the resource\n */\n\n // to create the `match` attribute, we need to join the value of all the searchable fields in\n // our model, ie all the fields defined in our 'toSearchableArray' model method\n\n // We make use of the SEARCHABLE_FIELDS constant in our model\n // we dont want id in the match, so we filter it out.\n $fields = array_filter($model::SEARCHABLE_FIELDS, fn ($field) => $field !== 'id');\n\n return $model::search($keyword)\n ->take(config('fullsite-search.search_limit_per_model'))\n ->get()\n ->map(function (Model $modelRecord) use ($keyword, $fields, $classname) {\n\n // use $slice as the match, otherwise if undefined we use the first 20 character of serialisedValues\n $modelRecord->setAttribute('match', self::createMatchAttribute($modelRecord, $fields, $keyword));\n // setting the model name\n $modelRecord->setAttribute('model', $classname);\n // setting the resource link\n $modelRecord->setAttribute('view_link', self::resolveModelViewLink($modelRecord));\n\n return $modelRecord;\n });\n })->flatten(1);\n }", "title": "" }, { "docid": "9495beed5d6b59fdef9a59dbfda663b3", "score": "0.5963531", "text": "public function loadModels( $criteria )\n {\n $select = $this->select();\n \n // Get parameters from criteria array\n $order = $criteria['_order']; unset( $criteria['_order'] );\n $count = $criteria['_count']; unset( $criteria['_count'] );\n $offset = $criteria['_offset']; unset( $criteria['_offset'] );\n \n // Build WHERE clause\n $where = $this->buildWhere($criteria);\n \n // Set the Zend_Select structure's various properties\n $select->where($where);\n $select->order($order);\n $select->limit($count, $offset);\n \n // Query the database\n $rows = $this->fetchAll($select);\n if( count($rows) == 0 )\n return array();\n \n // Try to create models from the result\n $result = array();\n foreach( $rows as $row )\n {\n try\n {\n $model = $this->build($row);\n $result[] = $model;\n }\n catch( ModelTableException $e )\n {\n continue;\n }\n }\n \n // Return the result\n return $result;\n }", "title": "" }, { "docid": "037ab0b69688acef72102d0f552147d7", "score": "0.5961151", "text": "public function getModels(){\n\t\t$models = array();\n\t\tforeach($this->request->params['models'] as $modelName => $model){\n\t\t\t$plugin = $model['plugin'];\n\t\t\t$plugin .= ($plugin) ? '.' : null;\n\n\t\t\t$models[] = array(\n\t\t\t\t'class' => $plugin . $model['className'],\n\t\t\t\t'alias' => $modelName\n\t\t\t);\n\t\t}\n\n\t\treturn $models;\n\t}", "title": "" }, { "docid": "e65ab4b81a48a3e261892660887b9dd4", "score": "0.59592026", "text": "public function getModels()\n {\n // Count unfiltered total\n $count = $this->count($this->query);\n\n // Clone the Query\\Builder, Eloquent\\Builder, or Relation\n $filteredQuery = clone $this->query;\n\n // Apply filters\n $this->applyFilters($filteredQuery);\n\n // Count filtered total\n $countFiltered = $this->countFiltered($filteredQuery);\n\n // Apply sorts\n $this->applySorts($filteredQuery);\n\n // Paginate\n $this->applyPagination($filteredQuery);\n\n $collection = collect($filteredQuery->get());\n\n // Perform any additional transformations on the dataset\n $collection = $this->applyTransformations($collection);\n\n return [$count, $countFiltered, $collection];\n }", "title": "" }, { "docid": "7d253c98592db2d4320871f2b8db6194", "score": "0.595302", "text": "public function getWhere($conditions)\n {\n }", "title": "" }, { "docid": "a1c2765c3d2f3cbfbad3c2d2a29d382e", "score": "0.594539", "text": "public static function getModels($type)\n {\n return self::find()->where(['status' => self::STATUS_ACTIVE, 'type' => $type])->orderBy(['position' => SORT_ASC])->all();\n }", "title": "" }, { "docid": "fc94ed3aa2e3861b518d86030b84ce29", "score": "0.5943518", "text": "public function getList() {\n $context=$this->getSearchContext();\n $params=$this->getRequest()->requestVar('q');\n \n if(is_array($params)) {\n if(array_key_exists('Created', $params) && is_array($params['Created'])) {\n $params['Created']=implode(' ', $params['Created']);\n }\n \n $params=array_map('trim', $params);\n }\n \n $list=$context->getResults($params);\n \n $this->extend('updateList', $list);\n \n return $list;\n }", "title": "" }, { "docid": "51d628060466502972b26dffff4fc60a", "score": "0.5924311", "text": "public function searchByFieldsAndModel() {\n $this -> viewClass = 'Json';\n $res = array();\n $data = $this -> request -> data;\n if (isset($data['fields_in'], $data['value'], $data['model'], $data['fields_out'])) {\n\n if ($this -> Check -> isset_model($data['model'])) {\n try {\n $this -> loadModel($data['model']);\n $fields = $this -> Common -> addModeltoFileds($data['model'], $data['fields_out']);\n $fields_condtions = $this -> Common -> addModeltoFileds($data['model'], $data['fields_in']);\n $conditions = $this -> Common -> mapTwoArray($data['value'], $fields_condtions);\n if (array_key_exists('del_flag', $this -> $data['model'] -> getColumnTypes())) {\n $conditions[$data['model'] . '.del_flag'] = FALSE;\n }\n $data_find[] = $this -> $data['model'] -> find('first', array('conditions' => $conditions, 'fields' => $fields, 'recursive' => -1));\n if ($this -> Check -> is_multiArrayEmpty($data_find)) {\n $res['status'] = STS_EMPTY;\n } else {\n $res['status'] = STS_SUCCESS;\n $res['data_res'] = $data_find;\n }\n } catch(Exception $e) {\n echo 'Exception: ', $e -> getMessage(), \"\\n\";\n $this -> log('Exception: ' . $e -> getMessage(), LOG_ERROR);\n }\n } else {\n $res['status'] = STS_ERROR_AUTH;\n }\n } else {\n $res['status'] = STS_ERROR_MISSINGDATA;\n }\n $this -> set(compact('res'));\n $this -> set('_serialize', array('res'));\n }", "title": "" }, { "docid": "64f0d1c2e0781b9dc192521f30453e4e", "score": "0.5922892", "text": "public function get_model(){\n\t\t// setting default query\n\t\t$query = $this->get_base_query();\n\t\t// setting default query along with its where \n\t\t$where_val = array();\n\t\tforeach ($this->wheres as $where ) {\n\t\t\tif( isset( $where ['text'] )){\n\t\t\t\t $query .= \" \". $where ['text'] . \" \" ; // Space is to keep safe \n\t\t\t\t$where_val [] = $where ['val'] ;\n\t\t\t}\n\t\t}\n\t\t//! raw query\n\t\t$query .= $this->get_where_raw ();\n\t\tforeach( $this->get_where_raw_vals() as $val){\n\t\t\t$where_val [] = $val;\n\t\t}\n\t\t//! setting group\n\t\t$query .= \" \" . $this->get_group() . \" \"; \n\t\t// setting order\n\t\t$query .= \" \" . $this->get_order() . \" \"; \n\t\t//! setting page nation\n\t\tif( $this->get_jump() > 0 )\n\t\t\t$this->set_pagenation( $query , $where_val);\n\t\t// setting limit\n\t\t$query .= $this->get_limit();\t\n\t\t$this->set_final_query( $query );\n\t\t$name_db = $this->get_database_name();\n\t\t$posts = DB::connection( $name_db )->select( DB::raw( $query ) \t , $where_val );\n\t\t//$posts = DB::select(DB::raw( $query ) \t , $where_val ) ;\n\t\treturn $posts;\n\t}", "title": "" }, { "docid": "715a200eefda4d479fb2d48aa9435786", "score": "0.5912202", "text": "public function actionGetModels(){\n\n\t}", "title": "" }, { "docid": "934b3c2bd5ccde854c608598b9932872", "score": "0.59005016", "text": "public function filtered_list() {\n\t\t$orgs = new Omelette_OrganisationCollection();\n\t\t$sh = new SearchHandler($orgs,false);\n\t\t$sh->extract();\n\t\t\n\t\t$cc = new ConstraintChain();\n\t\tif(!empty($this->_data['name'])) {\n\t\t\t$cc->add(new Constraint('org.name','ILIKE',$this->_data['name'].'%'));\n\t\t}\n\t\t$sh->addConstraintChain($cc);\n\t\t$sh->perpage = 10;\n\t\t$orgs->load($sh);\n\t\t\n\t\t$model = $orgs->getModel();\t\n\t\t//then get the query, same one as used for the index\n\t\t$query = $model->getQueryForRecentlyViewedSearch();\n\t\t\n\t\t//recent things have their own collection that knows what to do with the query\n\t\t$recent = new ViewedItemCollection($model);\n\t\t$sh = new SearchHandler($recent,false);\n\t\t$sh->extract();\n\t\t$sh->perpage = 3;\n\t\t$db = DB::Instance();\n\t\t\n\t\t//things in the ViewedItem query are 'x', need to unambiguise 'name'\n\t\t$query->where('x.name ILIKE ' . $db->qstr($this->_data['name'].'%'));\n\t\t$recent->load($sh, $query);\n\t\t\n\t\t// Search by exact Account Number match\n\t\t$by_accountno = new Omelette_OrganisationCollection();\n\t\t$sh = new SearchHandler($by_accountno, false);\n\t\t$sh->extract();\n\t\t$sh->addConstraint(new Constraint('accountnumber','=',$this->_data['name']));\n\t\t$by_accountno->load($sh);\n\t\t\n\t\t// Remove duplicates from the other lists\n\t\tforeach ($by_accountno as $org) {\n\t\t\tif (false !== ($index = $recent->contains('id', $org->id))) {\n\t\t\t\t$recent->remove($index);\n\t\t\t}\n\t\t\tif (false !== ($index = $orgs->contains('id', $org->id))) {\n\t\t\t\t$orgs->remove($index);\n\t\t\t}\n\t\t}\n\t\tforeach($recent as $org) {\n\t\t\tif(false !== ($index = $orgs->contains('id', $org->id))) {\n\t\t\t\t$orgs->remove($index);\n\t\t\t}\n\t\t}\n\t\t\n\t\t$this->view->set('items',$orgs);\n\t\t$this->view->set('recent', $recent);\n\t\t$this->view->set('by_accountno', $by_accountno);\n\t}", "title": "" }, { "docid": "01215e70d1f6c415e001a274d162e551", "score": "0.5900252", "text": "public function getListRegistry()\n {\n $query = $this->getRequest()->getParams();\n $result = null;\n if (@$query['filter-selected'] == self::FILTER_BY_TITLE) {\n $title = $query['title'];\n $result = $this->searchByTitle($title, $query['type-selected']);\n } else {\n $firstName = $this->getFirstNameByRequestParams($query);\n $lastName = $this->getLastNameByRequestParams($query);\n $result = $this->searchByName($firstName, $lastName, @$query['type-selected']?@$query['type-selected']:@$query['type']);\n }\n return $result;\n }", "title": "" }, { "docid": "42958312e9e2c56c01fc6d31bcff147b", "score": "0.5891794", "text": "public function getAll()\n\t{\n\t\treturn $this->model->get();\n\t}", "title": "" }, { "docid": "d93bb3ddc43b1eae1f5b3b13e2c8728b", "score": "0.58894473", "text": "function getList() {\r\n $result = $this->Right->search();\r\n return $result;\r\n }", "title": "" }, { "docid": "7b88ea46701e8d82e03ed7ea3e8b318b", "score": "0.5886752", "text": "public function filters()\n {\n return [\n 'from' => new FromDateSearch ,\n 'to' => new ToDateSearch ,\n 'active' => new StatusFilter ,\n 'category_id' => new CategoryFilter ,\n 'admin_global_search' => new AdminGlobalSearch(['name','description'])\n ];\n }", "title": "" }, { "docid": "93d34e26b4fbad6343edeb99d0ca4b24", "score": "0.5874978", "text": "public function search($searchTerm = '')\n {\n $this->searchTerm = $searchTerm;\n\n return collect($this->models)->filter(Closure::fromCallable([$this, 'authorizedToSearch']))\n ->map(Closure::fromCallable([$this, 'getResultsFor']))\n ->filter(function ($results) {\n return count($results) > 0 || $this->includeEmpty;\n })\n ->unless($this->useGroups, function ($collection) {\n return $collection->flatten(1);\n });\n }", "title": "" }, { "docid": "9ee8f2dffea3adabfb6a7e6ee2a05cda", "score": "0.586117", "text": "private function filterEloquent() {\n $globalSearch = [];\n $columnSearch = [];\n $dtColumns = $this->_pluck($this->_columns, 'dt');\n\n if (isset($this->_request['search']) && $this->_request['search']['value'] != '') {\n $str = $this->_request['search']['value'];\n\n for ($i = 0, $ien = count($this->_request['columns']); $i < $ien; $i++) {\n $requestColumn = $this->_request['columns'][$i];\n $columnIdx = array_search($requestColumn['data'], $dtColumns);\n $column = $this->_columns[$columnIdx];\n\n if ($requestColumn['searchable'] == 'true') {\n $array = [];\n\n if (isset($column['relation'])) {\n $array['relation'] = $column['relation'];\n }\n\n if (isset($column['filter'])) {\n $array['filter'] = $column['filter']($column['db'], $str);\n }else{\n $array['filter'] = $array['filter'] = [\n 'column' => $column['db'],\n 'where' => 'LIKE',\n 'value' => '%' . $str . '%',\n ];\n }\n\n array_push($globalSearch, $array);\n }\n }\n }\n\n // Individual column filtering\n for ($i = 0, $ien = count($this->_request['columns']); $i < $ien; $i++) {\n $requestColumn = $this->_request['columns'][$i];\n $columnIdx = array_search($requestColumn['data'], $dtColumns);\n\n $column = $this->_columns[$columnIdx];\n\n $str = $requestColumn['search']['value'];\n\n if ($requestColumn['searchable'] == 'true' && $str != '') {\n $array = [];\n\n if (isset($column['relation'])) {\n $array['relation'] = $column['relation'];\n }\n\n if (isset($column['filter'])) {\n $array['filter'] = $column['filer']($column['db'], $str);\n }else{\n $array['filter'] = [\n 'column' => $column['db'],\n 'where' => 'LIKE',\n 'value' => '%' . $str . '%',\n ];\n }\n\n array_push($globalSearch, $array);\n }\n }\n\n $wheres = array_merge($globalSearch, $columnSearch);\n\n\n if (count($wheres) < 1) {\n return;\n }\n\n $this->_eloquent = $this->_eloquent->where(function ($query) use ($wheres) {\n foreach ($wheres as $where) {\n if (isset($where['relation'])){\n $query->orWhereHas($where['relation'], function($subQuery) use ($where) {\n $subQuery->where($where['filter']['column'], $where['filter']['where'], $where['filter']['value']);\n });\n }else{\n $query->orwhere($where['filter']['column'], $where['filter']['where'], $where['filter']['value']);\n }\n }\n });\n }", "title": "" }, { "docid": "06cd15700b8a9ee9d972247a3b3f0e6d", "score": "0.58529407", "text": "public function getItemsBy($params = false)\n {\n $query = $this->model->query();\n\n /*== RELATIONSHIPS ==*/\n if (in_array('*', $params->include)) {//If Request all relationships\n $query->with([]);\n } else {//Especific relationships\n $includeDefault = [];//Default relationships\n if (isset($params->include))//merge relations with default relationships\n $includeDefault = array_merge($includeDefault, $params->include);\n $query->with($includeDefault);//Add Relationships to query\n }\n\n\n /*== FILTERS ==*/\n if (isset($params->filter)) {\n $filter = $params->filter;//Short filter\n\n\n /* if (isset($filter->status)) {\n $query->whereStatus($filter->status);\n }*/\n\n\n //Filter by date\n if (isset($filter->date)) {\n $date = $filter->date;//Short filter date\n $date->field = $date->field ?? 'created_at';\n if (isset($date->from))//From a date\n $query->whereDate($date->field, '>=', $date->from);\n if (isset($date->to))//to a date\n $query->whereDate($date->field, '<=', $date->to);\n }\n if (isset($filter->accounts)) {\n $accounts = is_array($filter->accounts) ? $filter->accounts : [$filter->accounts];\n $query->whereHas('accounts', function ($q) use ($accounts) {\n $q->whereIn('account_id', $accounts);\n });\n } elseif (!isset($params->permissions['vehicle.vehicles.all'])||!$params->permissions['vehicle.vehicles.all']) {\n $query->whereHas('accounts', function ($q) use ($params) {\n\n $q->where('account_id', $params->user->accounts[0]->id??0);\n });\n }\n\n //Order by\n if (isset($filter->order)) {\n $orderByField = $filter->order->field ?? 'created_at';//Default field\n $orderWay = $filter->order->way ?? 'desc';//Default way\n $query->orderBy($orderByField, $orderWay);//Add order to query\n }\n\n //add filter by search\n if (isset($filter->search) && $filter->search) {\n //find search in columns\n $term = $filter->search;\n $query->where('board', 'LIKE', \"%{$term}%\")->orWhere('id', $term);\n }\n }\n\n /*== FIELDS ==*/\n if (isset($params->fields) && count($params->fields))\n $query->select($params->fields);\n\n /*== REQUEST ==*/\n if (isset($params->page) && $params->page) {\n return $query->paginate($params->take);\n } else {\n $params->take ? $query->take($params->take) : false;//Take\n return $query->get();\n }\n }", "title": "" }, { "docid": "7366cbe1f227997c770d64a7840f2554", "score": "0.5850142", "text": "function gets(Maker_model $model)\n {\n\n $display = isset($model->display)? $model->display:10;\n $page = isset($model->page)?$model->page:1;\n $offset = ($page-1) * $display;\n\n $search = isset($model->search)? $model->search:'';\n $field = isset($model->search_by)? $model->search_by: 'maker_name';\n\n $this->db->select(\"maker.*, \".\n \"(select count(*) from maker where $field like '%$search%') 'records' \"\n );\n $this->db->like(\"$field\", \"$search\");\n $this->db->limit($display, $offset);\n $query = $this->db->get('maker');\n\n //echo $this->db->last_query();\n\n if(!$query || $query->num_rows()== 0)\n {\n return Message_result::error_message('Search not found');\n }\n else\n {\n return Message_result::success_message('', null, $query->result('Maker_model'));\n }\n }", "title": "" }, { "docid": "f2b9d006d42909aef10632f8807c0173", "score": "0.5836924", "text": "public function getWhere();", "title": "" }, { "docid": "f2b9d006d42909aef10632f8807c0173", "score": "0.5836924", "text": "public function getWhere();", "title": "" }, { "docid": "3b86e02219c101087ef4a9d42ae8a53e", "score": "0.58304375", "text": "public function performSearch() {\n\t\t\t$searchCriteria = $this->getSearchComponents();\n\t\t\t$sql = \"SELECT \".$searchCriteria['select'].\" FROM \".implode(\" \", $searchCriteria['tables']).\" \".(!empty($searchCriteria['where']) ? \"WHERE \".implode(\" \", $searchCriteria['where']).\" \" : \"\").(!empty($searchCriteria['order']) ? \"ORDER BY \".implode(\", \", $searchCriteria['order']).\" \" : \"\").\"LIMIT \".$searchCriteria['start'].\", \".$searchCriteria['show'];\n\t\t\t$result = $this->dbh->query($sql);\n\t\t\treturn $result->fetchAll();\n\t\t}", "title": "" }, { "docid": "fc5836801524376f03865a4d47b06394", "score": "0.5826346", "text": "public function actionIndex()\n\t{\n\t\tif (!Yii::app()->user->checkAccess('root'))\n\t\t\t$this->accessError();\n\n\t\t$model = new $this->modelName('search');\n\t\t$model->unsetAttributes(); // clear any default values\n\n\t\tif (isset($_GET[$this->modelName]))\n\t\t\t$model->attributes=$_GET[$this->modelName];\n\n\t\t$this->render('list', array('model'=>$model));\n\t}", "title": "" }, { "docid": "5014a29852fb4dea939c261c0f67bc11", "score": "0.5819272", "text": "public function getProvides($model= null) {\n \tif(!$model){\n \t\treturn response()->json('Debes ingresar el modelo a consultar', 500);\n \t}\n $ids = $this->odoo\n \t// ->where('is_company', false)\n // ->where('customer', '=', true)\n // ->limit(3)\n ->search($model);\n return response()->json($ids, 200);\n }", "title": "" }, { "docid": "e770df3232675e87861f6338743f6a54", "score": "0.5818011", "text": "public function getAllFilters();", "title": "" }, { "docid": "d8b884c4e7d262a7955bb77f85f17f49", "score": "0.58118397", "text": "public function getList()\n {\n $list = parent::getList();\n $params = $this->request->requestVar('q');\n\n if (isset($params['RemoveEmptyMetaDescriptions']) && $params['RemoveEmptyMetaDescriptions']) {\n $list = $this->removeEmptyAttributes($list, 'MetaDescription');\n }\n\n if (isset($params['DuplicatesOnly']) && $params['DuplicatesOnly']) {\n $list = $this->filterDuplicates($list);\n }\n\n if (!empty($params['SearchTitle'])) {\n $list = $list->filterAny([\n 'MenuTitle:PartialMatch' => $params['SearchTitle'],\n 'Title:PartialMatch' => $params['SearchTitle'],\n ]);\n }\n\n $list = $list->exclude('ClassName', $this->config()->ignore_page_types); // remove error pages etc\n\n $list = $list->sort('ID');\n\n return $list;\n }", "title": "" }, { "docid": "8d2b8d304b1dff7e813b1faa127cfe77", "score": "0.5811764", "text": "private function responsableSearch()\n {\n return [\n 'id',\n 'name'\n ];\n }", "title": "" }, { "docid": "2598b5152e1f8239d33175cb55113159", "score": "0.58057594", "text": "protected function list($model): Collection\n {\n return Service::all();\n }", "title": "" }, { "docid": "1a02d4a8f7430074880bae30acc4a9a7", "score": "0.5801088", "text": "function queryAll() {\n\t\t$model = $this->getModel();\n\t\tif (is_object($model)) {\n\t\t\t$resultset = $model->performQueryAll($this);\n\t\t\treturn $resultset;\n\t\t}\n\t\treturn array(); \n\t}", "title": "" }, { "docid": "eccc93ab1df1a3671ee2c2a9f3f2e85e", "score": "0.57914186", "text": "function get_search_set() {\n\t\treturn $this->filter;\n\t}", "title": "" }, { "docid": "003700dd9127b84bb07b93bd0c9403fc", "score": "0.57906586", "text": "public static function loadModels() {\n $_items = array();\n $models = self::model()->findAll(array(\n 'order' => 'id ASC',\n ));\n foreach ($models as $model) {\n $_items[$model->id] = $model;\n }\n return $_items;\n }", "title": "" }, { "docid": "87c7a20c7d8066c137bd9b25ee942676", "score": "0.576147", "text": "public function getModels()\n {\n return $this->models;\n }", "title": "" }, { "docid": "87c7a20c7d8066c137bd9b25ee942676", "score": "0.576147", "text": "public function getModels()\n {\n return $this->models;\n }", "title": "" }, { "docid": "87c7a20c7d8066c137bd9b25ee942676", "score": "0.576147", "text": "public function getModels()\n {\n return $this->models;\n }", "title": "" }, { "docid": "20875966f53aa706023efa850c6c8603", "score": "0.57516944", "text": "public function list($model)\n {\n return app($this->getEntity($model))\n ->list();\n }", "title": "" }, { "docid": "dd453512a908f49227011da322384fd0", "score": "0.5751159", "text": "private static function get_model_files() {\n $base_dir = $GLOBALS['wpatomic_base_dir:'.__DIR__];\n $models = glob( $base_dir.'/models/*.php' );\n return $models;\n }", "title": "" }, { "docid": "aa9db39904451d28932879491a752fe1", "score": "0.57491165", "text": "private function getModelsFromIds() {\n $ids = $this->owner->{$this->idListAttr};\n $relationClass = $this->owner->getRelation($this->relation)->modelClass;\n // Return RelationClass::findAll($ids);\n return call_user_func([$relationClass, 'findAll'], ['id' => $ids]);\n }", "title": "" }, { "docid": "d3bfdc155a55f6a80199f4941b9a5bf3", "score": "0.5748127", "text": "protected function filterModels($modelArray)\n\t{\n\t\t$user = ActiveUser::getUser();\n\t\t$filteredModels = array();\n\t\tforeach($modelArray as $modelInfo)\n\t\t{\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif(!isset($modelInfo['type']))\n\t\t\t\t\t$modelInfo['type'] = $this->type;\n\t\t\t\t$model = ModelRegistry::loadModel($modelInfo['type'], $modelInfo['id']);\n\n\t\t\t\tif($model->checkAuth('Read', $user))\n\t\t\t\t\t$filteredModels[] = $modelInfo;\n\n\t\t\t}catch(Exception $e){\n\n\t\t\t}\n\t\t}\n\t\treturn $filteredModels;\n\t}", "title": "" }, { "docid": "b2b7ecc27cd528de27350ab309001ab0", "score": "0.5742676", "text": "function get_search_set() {\n return $this->filter;\n }", "title": "" }, { "docid": "5de049a930e7bdb89243874d51fcd8dd", "score": "0.5733481", "text": "public function getModels() {\n return $this->models;\n }", "title": "" }, { "docid": "638644da5ed4640fbb545e23b0240cde", "score": "0.5727243", "text": "public function searchCriteria(){\n\t\t$conditions = array();\n\t\t/*\n\t\t * db_status:\n\t\t * 0 active\n\t\t * 1 deleted\n\t\t */\n\t\t$conditions[] = 'Listing.db_status = 0';\n\t\t//single office\n\t\t$conditions[] = 'Listing.office_id IN (1)';\n\t\t\n\t\t$conditions[] = \"unix_timestamp(LtInsp.insp_start) >= '\".time().\"'\";\n\t\treturn $conditions;\n\t}", "title": "" }, { "docid": "888d67774758960cdc66137b3014fc5a", "score": "0.5724188", "text": "public function filter(array $criteria, Model $model)\n {\n extract($this->filterBindings($criteria));\n\n $sql = \"SELECT * FROM {$model->table} WHERE {$where};\";\n\n $query = $this->pdo->prepare($sql);\n $query->execute($values);\n\n $results = $this->fetchObjects($query, $model);\n\n $this->publish('read-filter', $model, $results);\n\n return $results;\n }", "title": "" }, { "docid": "aa14aa3bc16471568b72806323931f6b", "score": "0.5724031", "text": "public function actionModels($partialSupport=1) {\n // To obtain all models: iterate through modules\n $modelNames = X2Model::getModelNames();\n // Partially-supported models\n $partial = array(\n 'Actions'=>Yii::t('app','Actions'),\n 'Docs'=>Yii::t('app','Docs'),\n 'Groups'=>Yii::t('app','Groups'),\n 'Media'=>Yii::t('app','Media'),\n 'Quote'=>Yii::t('app','Quotes'),\n 'X2List'=>Yii::t('app','Contact Lists')\n );\n if((boolean) (integer) $partialSupport) {\n $modelNames = array_unique(array_merge($modelNames,$partial));\n } else {\n $modelNames = array_diff($modelNames,$partial);\n }\n asort($modelNames);\n\n $models = array();\n foreach($modelNames as $modelName => $title) {\n $attributes = X2Model::model($modelName)->attributeNames();\n $models[] = compact('modelName','title','attributes');\n }\n\n $this->responseBody = $models;\n }", "title": "" }, { "docid": "b1ee43b27c23bc31f07bdfdb5960b40f", "score": "0.5698383", "text": "public function filterByAll();", "title": "" }, { "docid": "f9932ae7ec9ca073ffedc8cb8bc5fbec", "score": "0.5697622", "text": "public function getList(\\Magento\\Framework\\Api\\SearchCriteria $searchCriteria);", "title": "" }, { "docid": "f9932ae7ec9ca073ffedc8cb8bc5fbec", "score": "0.5697622", "text": "public function getList(\\Magento\\Framework\\Api\\SearchCriteria $searchCriteria);", "title": "" }, { "docid": "796d8f9b0ffddecfdd44f295f87d39c0", "score": "0.5690304", "text": "public function getFindAllQuery() {\n\t\t$query = $this->getModel()->find();\t\t\n\t\treturn $query;\n\t}", "title": "" }, { "docid": "fd10f6eda4b6bc288af4386bb02bd006", "score": "0.56703836", "text": "public function getModels(): array\n {\n return $this->models;\n }", "title": "" }, { "docid": "2a2b81b4cac71e45ef4bdb46d3f3c7b9", "score": "0.56703377", "text": "public function getAll()\n {\n return $this->model->all();\n }", "title": "" }, { "docid": "5d23eca13c4b5e3eee3a8f979f308312", "score": "0.56633735", "text": "public function getDataByList($model = null, $conditions = [], $fields = ['id'],\n $order = [], $limit = false, $contain = [], $offset = false, $distinct = false\n ) {\n if ($model != null) {\n //Model->TableName\n $items = TableRegistry::get($model);\n }\n\n $query = $items->find();\n if ($limit !== false) {\n $query->limit($limit);\n }\n if ($offset !== false) {\n $query->offset($offset);\n }\n if ($distinct !== false) {\n $query->distinct($distinct);\n }\n $tmp = $query->where($conditions)\n ->select($fields)\n ->order($order)\n ->contain($contain)\n ->toList();\n // pr($tmp);die();\n return $tmp;\n }", "title": "" }, { "docid": "63e3cd73781379d62074a8111725db0e", "score": "0.56444174", "text": "public function search(Request $request)\n {\n extract($this->getResourceNames());\n\n $results = $modelPath::search($request->input('q'), 20, true)\n ->groupBy('id')->get();\n\n return $this->compileView($resourceMultiple . '.search', [$resourceMultiple => $results]);\n }", "title": "" }, { "docid": "eb46fa8472d4983c285b4e338bfbea4f", "score": "0.5643912", "text": "public function index()\n\t{\n\t\t$Model = App::make($this->Model);\n\t\t$objects = $Model::withTrashed();\n\n\t\t// If a search term has been entered...\n\t\t$this->data['search'] = $search = (Input::get('search')) ? urldecode(Input::get('search')) : null;\n\t\tif ($search) {\n\t\t\t$terms = explode(' ', $search);\n\t\t\tforeach ($terms as &$term) {\n\t\t\t\t$term = '%' . $term . '%';\n\t\t\t}\n\n\t\t\t// Call the search method on the Model\n\t\t\t$resultIDs = array();\n\t\t\t$Model->search($terms)->each(function($object) use (&$resultIDs) {\n\t\t\t\t$resultIDs[] = $object->id;\n\t\t\t});\n\t\t\t// Limit the $objects query based on the results, make sure that no objects\n\t\t\t// are returned if there are no results. (where id = 0, it's cheap but it works!)\n\t\t\t$objects = (count($resultIDs)) ? $objects->whereIn('id', $resultIDs) : $objects->where('id', 0);\n\t\t}\n\n\t\t// Return all objects in order if this is a reorderable index\n\t\tif ($Model->reorderable) {\n\t\t\t$this->data[$this->plural] = $objects->orderBy('order')->get();\n\t\t} else {\n\t\t\t// Otherwise, paginate the objects\n\t\t\t$paginator = $objects->paginate();\n\t\t\t$this->data[$this->plural] = $paginator->getCollection();\n\t\t\t$appends = $_GET;\n\t\t\tunset($appends['page']);\n\t\t\t$this->data['links'] = $paginator->appends($appends)->links();\n\t\t}\n\n\t\treturn View::make($this->view('index'), $this->data);\n\t}", "title": "" }, { "docid": "79d326ca36f9dd3f98de05a4b70f09af", "score": "0.564325", "text": "public function getFilters();", "title": "" }, { "docid": "79d326ca36f9dd3f98de05a4b70f09af", "score": "0.564325", "text": "public function getFilters();", "title": "" }, { "docid": "79d326ca36f9dd3f98de05a4b70f09af", "score": "0.564325", "text": "public function getFilters();", "title": "" }, { "docid": "66667d3d8768d88eb63f0689e0af9e54", "score": "0.5639765", "text": "protected function getListQuery() {\n\t\t$where='';\n\t\t$db\t\t= $this->getDbo();\n\t\t\n\t\tif ($this->getState('filter.search') !== '' && $this->getState('filter.search') !== null)\n\t\t{\n\t\t\t// Escape the search token.\n\t\t\t$token = $db->quote('%' . $db->escape($this->getState('filter.search')) . '%');\n\n\t\t\t// Compile the different search clauses.\n\t\t\t$searches = array();\n\t\t\t$searches[] = ' CONCAT(c.firstname,\" \",IF(c.middlename,CONCAT(c.middlename,\" \"),\"\"),c.lastname) LIKE ' . $token;\n\t\t\t$searches[] = ' u.email LIKE ' . $token;\n\n\t\t\t// Add the clauses to the query.\n\t\t\t$where= implode(' OR ', $searches);\n\t\t}\n\n\t\t$query = $db->getQuery(true);\n\t\t\t\t\n\t\t$query->select('`j`.`id`, `j`.`photo`, `j`.`international`, `j`.`other`, `j`.`judgestatus`, `j`.`judgelevel`');\n\t\t$query->select('`j`.`distinguished_judge`, `j`.`licensed`, `j`.`judge_of_merit`, `j`.`judge_emeritus`');//, `j`.`airport`\n\t\t$query->select('`j`.`school_instructor`, `j`.`ring_instructor`, `j`.`genetics_instructor`, `j`.`licensed_until`');\n\t\t$query->select('`s`.`judge_status`, `l`.`judge_level`');\n\t\t$query->select('`c`.`firstname`, `c`.`middlename`, `c`.`lastname`, `u`.`email`');\n\t\t$query->select('`c`.`cb_address1`, `c`.`cb_address2`, `c`.`cb_address3`, `c`.`cb_city`, `c`.`cb_state`, `c`.`cb_country`');\n\t\t$query->select('`c`.`cb_zip`, `r`.`competitive_region_name`, `r`.`competitive_region_abbreviation`');\n\t\t\n\t\t$query->from('`#__jdg_judges` AS `j`');\n $query->join('LEFT','`#__comprofiler` AS `c` ON `j`.`user_id` = `c`.`user_id`');\n $query->join('LEFT','`#__users` AS `u` ON `j`.`user_id` = `u`.`id`');\n\t\t$query->join('LEFT','`#__jdg_judge_level` AS `l` ON `l`.`judge_level_id` = `j`.`judgelevel`');\n\t\t$query->join('LEFT','`#__jdg_judge_status` AS `s` ON `s`.`judge_status_id` = `j`.`judgestatus`');\n\t\t$query->join('LEFT','`#__toes_competitive_region` AS `r` ON `r`.`competitive_region_abbreviation` = `c`.`cb_tica_region`');\n\t\t\n\t\tif($where) {\n\t\t\t$query->where($where);\n\t\t}\n\t\t\n\t\t// Add the list ordering clause.\n\t\t$orderCol = $this->state->get('list.ordering', 'c.firstname');\n\t\t$orderDirn = $this->state->get('list.direction', 'asc');\n\n\t\t$query->order($db->escape($orderCol . ' ' . $orderDirn));\n\n\t\treturn $query;\n\t}", "title": "" }, { "docid": "e63c0a171273854542fd41f99c026caa", "score": "0.56383264", "text": "public static function getSearchableFields() {\n }", "title": "" }, { "docid": "375cc1fae11e52bf21e216d0824384fe", "score": "0.5636992", "text": "public function getFrom()\n {\n return $this->_models;\n }", "title": "" }, { "docid": "1da3909ea020f4c7f12bd1851523557c", "score": "0.5634673", "text": "public function all(Model $model)\n {\n $sql = \"SELECT * FROM {$model->table};\";\n\n $query = $this->pdo->prepare($sql);\n $query->execute();\n\n $results = $this->fetchObjects($query, $model);\n\n $this->publish('read-all', $model, $results);\n\n return $results;\n }", "title": "" }, { "docid": "bec9fc65b5fc294bc432e40203265f4a", "score": "0.56282246", "text": "public function getAll()\n\t{\n\t\treturn $this->model->all();\n\t}", "title": "" }, { "docid": "6bbb95d9eb2c991c286f0083559484d3", "score": "0.5627521", "text": "public function getSearchComponents() {\n\t\t\t$search = array();\n\t\t\tlist($start, $show, $page) = $this->getTableLocation();\n\t\t\t$search['select'] = '*';\n\t\t\t$search['start'] = $start;\n\t\t\t$search['show'] = $show;\n\t\t\t$search['tables'] = array(\n\t\t\t\t0 => '`'.$this->table.'`'\n\t\t\t);\n\t\t\t$search['where'] = array();\n\t\t\t$search['order'] = array();\n\t\t\t$defaultSearch = false;\n\t\t\t$performSearch = getRequest('search');\n\t\t\t// impose default search criteria when search action is not explicitly called\n\t\t\tif (!$performSearch && !empty($this->searchValues)) {\n\t\t\t\t$performSearch = true;\n\t\t\t\t$defaultSearch = true;\n\t\t\t}\n\t\t\tif ($performSearch) {\n\t\t\t\tforeach ($this->searchFields as $field => $val) {\n\t\t\t\t\tif (!$val['range']) {\n\t\t\t\t\t\tif ($defaultSearch) {\n\t\t\t\t\t\t\tif (isset($this->searchValues[$field])) {\n\t\t\t\t\t\t\t\t$value = $this->searchValues[$field][0];\n\t\t\t\t\t\t\t\t$operator = $this->searchValues[$field][1];\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$value = false;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif (isset($this->searchValues[$field]) && $this->searchValues[$field][2]) {\n\t\t\t\t\t\t\t\t$value = $this->searchValues[$field][0];\n\t\t\t\t\t\t\t\t$operator = $this->searchValues[$field][1];\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$value = clean(urldecode(getRequest($field)), $val['type']);\n\t\t\t\t\t\t\t\t$operator = getRequest($field.'_operator');\n\t\t\t\t\t\t\t\t$operator = isset($this->searchOperators[$operator]) ? $this->searchOperators[$operator] : false;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($value) {\n\t\t\t\t\t\t\tif ($operator) {\n\t\t\t\t\t\t\t\tif ($operator == 'LIKE') {\n\t\t\t\t\t\t\t\t\t$value = preg_replace('/\\*/', '%', prep($value));\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t$value = prep($value);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$operator = '=';\n\t\t\t\t\t\t\t\t$value = prep($value);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$search['where'][$field] = \"AND `\".$field.\"` \".$operator.\" '\".$value.\"'\";\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif ($defaultSearch) {\n\t\t\t\t\t\t\tif (isset($this->searchValues[$field])) {\n\t\t\t\t\t\t\t\t$valueFrom = isset($this->searchValues[$field][0][0]) ? $this->searchValues[$field][0][0] : '';\n\t\t\t\t\t\t\t\t$valueTo = isset($this->searchValues[$field][0][1]) ? $this->searchValues[$field][0][1] : '';\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$valueFrom = '';\n\t\t\t\t\t\t\t\t$valueTo = '';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif (isset($this->searchValues[$field]) && $this->searchValues[$field][2]) {\n\t\t\t\t\t\t\t\t$valueFrom = isset($this->searchValues[$field][0][0]) ? $this->searchValues[$field][0][0] : '';\n\t\t\t\t\t\t\t\t$valueTo = isset($this->searchValues[$field][0][1]) ? $this->searchValues[$field][0][1] : '';\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$valueFrom = clean(getRequest($field.'From'), $val['type']);\n\t\t\t\t\t\t\t\t$valueTo = clean(getRequest($field.'To'), $val['type']);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($valueFrom != '' || $valueTo != '') {\n\t\t\t\t\t\t\tif ($val['type'] == 'date') {\n\t\t\t\t\t\t\t\t$valueFrom = $valueFrom ? dateToSql($valueFrom) : $valueFrom;\n\t\t\t\t\t\t\t\t$valueTo = $valueTo ? dateToSql($valueTo) : $valueTo;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif ($valueFrom != '' && $valueTo != '') {\n\t\t\t\t\t\t\t\t$search['where'][$field] = \"AND `\".$field.\"` BETWEEN '\".$valueFrom.\"' AND '\".$valueTo.\"'\";\n\t\t\t\t\t\t\t} elseif ($valueFrom != '') {\n\t\t\t\t\t\t\t\t$search['where'][$field] = \"AND `\".$field.\"` >= '\".$valueFrom.\"'\";\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$search['where'][$field] = \"AND `\".$field.\"` <= '\".$valueTo.\"'\";\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!empty($search['where'])) {\n\t\t\t\t$key = key($search['where']);\n\t\t\t\t$search['where'][$key] = preg_replace('/^(AND|OR) /', '', $search['where'][$key]);\n\t\t\t}\n\t\t\treturn $search;\n\t\t}", "title": "" }, { "docid": "66fac23a8d583a2f4cf6f15b73d80d1c", "score": "0.5620318", "text": "public function getSearchOperations();", "title": "" }, { "docid": "4b0b8f4e883e2a81a7ff008241ce4cef", "score": "0.56196934", "text": "public function getVehicles(Collection $filters): Collection;", "title": "" }, { "docid": "1bee9c2dd61ab367f5fa0fbf8d8df7a7", "score": "0.56125915", "text": "public function actionFiltr()\r\n {\r\n $model = new Orders('search');\r\n $ordersModel = new Orders();\r\n\r\n $model->unsetAttributes();\r\n if (isset($_GET['Orders']))\r\n $model->attributes = $_GET['Orders'];\r\n\r\n $users = Users::model()->findAll(array('order' => 't.organisation'));\r\n $users = CHtml::listData($users, 'id', 'fullname');\r\n\r\n $this->render('filtr', array(\r\n 'model' => $model,\r\n 'users' => $users,\r\n 'notMatchLogistic' => $ordersModel->getNotMatchLogistic()\r\n ));\r\n\r\n\r\n }", "title": "" }, { "docid": "7d58c804a76d2ee27172443a5c27e3bd", "score": "0.5606516", "text": "public function regularSearch()\n {\n $ids = [];\n $this->chooseModalOnly();\n $this->normalize();\n $this->selectIndexService();\n if ($this->notExactSearch) {\n $this->control->fuzziness = true;\n if (isset($this->fuzzy_distance))\n $this->control->fuzzy_distance = $this->fuzzy_distance;\n\n if (isset($this->fuzzy_prefix_length))\n $this->control->fuzzy_prefix_length = $this->fuzzy_prefix_length;\n\n if (isset($this->max_expansions))\n $this->control->fuzzy_max_expansions = $this->max_expansions;\n\n }\n\n if (isset($this->search)) {\n $this->result = $this->control->search($this->search, $this->maxNum);\n\n foreach ($this->result['ids'] as $id)\n $ids[] = $id;\n\n\n \n return $ids;\n\n } else {\n return $ids;\n }\n }", "title": "" }, { "docid": "c3c6e518aa89a9e4b9f1f7b68515cecd", "score": "0.5603044", "text": "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('makes_id',$this->makes_id);\n\t\t$criteria->compare('models_id',$this->models_id);\n\t\t$criteria->compare('year',$this->year);\n\t\t$criteria->compare('logo_img',$this->logo_img,true);\n\t\t$criteria->compare('car_img',$this->car_img,true);\n\t\t$criteria->compare('logo_data',$this->logo_data,true);\n\t\t$criteria->compare('car_data',$this->car_data,true);\n\t\t$criteria->compare('maker_model_name',$this->maker_model_name,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "title": "" }, { "docid": "d256fcdb089febe54102a89926cd6944", "score": "0.5595641", "text": "public function getModelsByBrand($brand){\r\n $sql = \"SELECT `ID`,`modelName`,`modelImage`,`modelDesc` FROM `Models` WHERE `BrandID`=:brandId\";\r\n $this->modelList = $this->query($sql,'select',array('brandId'=>$brand));\r\n return ($this->modelList) ? $this->modelList : [];\r\n }", "title": "" }, { "docid": "84edee55ce736680d1b16e81a34f32da", "score": "0.55917627", "text": "public function getListData()\n { \n $result = new \\stdClass();\n\n if(isset($this->listFilter['search']) && $this->listFilter['search'] != '')\n {\n\n /* Put listing query with search here.. */\n\n $searchby = $this->listTableHead[ $this->listFilter['searchby'] ]['tableName'].'.'.$this->listTableHead[ $this->listFilter['searchby'] ]['tableField'];\n\n $result->dataQuery = DB::table($this->DBTableName)\n ->where($searchby, 'like', '%'.$this->listFilter['search'].'%')\n ->paginate($this->listFilter['perpage']);\n }else{\n\n /* Put listing query without search word here.. */\n\n $result->dataQuery = DB::table($this->DBTableName)\n ->paginate($this->listFilter['perpage']);\n }\n\n return $result;\n \n }", "title": "" }, { "docid": "4e15b6565ff48becb45821dabcde1bc7", "score": "0.55895466", "text": "public function list_models ( /* void */ )\n {\n return array_keys($this->aModels);\n }", "title": "" }, { "docid": "db2142c11faf0a30b119c4f99b24c8c9", "score": "0.55841225", "text": "public function find($model, array $conditions = [], array $orders = [], $limit = null, $offset = null)\n {\n $result = [];\n foreach ($this->driver->find($this->buildTableName($model), true, $conditions, $orders, $limit, $offset) as $item) {\n $result[] = $this->initializer($item, $model);\n }\n\n return $result;\n }", "title": "" }, { "docid": "8a2feb7720d608a5b34b580d7b52127d", "score": "0.55839735", "text": "public function getWithConditions($conditions) {\n\t\t$count = 10;\n\t\t$offset = 0;\n\t\tif(isset($conditions['page'])) $page = $conditions['page'];\n\t\tif(isset($conditions['linesforpage'])) {\n\t\t\t$count = $conditions['linesforpage'];\n\t\t\t$offset = ($page - 1) * $count;\n\t\t}\n\t\tif(isset($conditions['category'])) $this->setQualifier('category','equals',$conditions['category'],true);\n\t\tif(isset($conditions['root'])) $this->setQualifier('root','equals',$conditions['root'],true);\n\t\tif(isset($conditions['permalink'])) $this->setQualifier('permalink','equals',$conditions['permalink'],true);\n\t\tif(isset($conditions['blogid'])) $this->setQualifier('blogid','equals',$conditions['blogid']);\n\t\telse $this->setQualifier('blogid','equals',getBlogId());\n\t\tif(isset($conditions['keyword'])) {\n\t\t\t$this->setQualifier('content','like',$conditions['keyword'],true);\n\t\t}\n\t\t$this->setLimit($count, $offset);\n\t\t$this->setOrder('created','desc');\n\t\treturn $this->getAll();\n\t}", "title": "" }, { "docid": "32d53a7d6df629353f04cf01844df241", "score": "0.55798733", "text": "public function search()\n {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $this->reportConditions($criteria);\n $criteria->order='t.id DESC';\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n 'pagination' => array('pageSize' => isset($_GET['pageSize'])?$_GET['pageSize']:20)\n ));\n }", "title": "" }, { "docid": "07baf939e5e83e00e269f4edbf3db935", "score": "0.5579656", "text": "public function getAll()\n {\n return $this->model->all();\n }", "title": "" }, { "docid": "2d45734633611df7f65cc05ac0beaf13", "score": "0.5573656", "text": "public function index() {\n $records = $this->modelInstance->all();\n\n return $records;\n }", "title": "" }, { "docid": "e37a754b6d01882e31b93eb26479d051", "score": "0.5568888", "text": "public function searches()\n {\n $items = Auth::user()->searches()\n ->whereNotNull('keyword')\n ->whereNotNull('saved_at')\n ->orderBy('created_at', 'DESC')\n ->paginate($this->pageSize);\n \n return view('backend.search.all')\n ->with('title', __('app.searches'))\n ->with('items', $items);\n }", "title": "" }, { "docid": "cc17a5c43b81d0078e762eeb0d91da7b", "score": "0.55664635", "text": "public function getSearchComponents() {\n\t\t\t$search = parent::getSearchComponents();\n\t\t\t$search['select'] = \"a.*, `b`.`company`, `b`.`fax`, `b`.`website`, `b`.`taxid`, `b`.`industry`, `b`.`description`, `b`.`payTo`, `b`.`im`, `b`.`dateCreated` AS `businessDateCreated`, `b`.`lastModified` AS `businessLastModified`, `c`.`memberGroupID`\";\n\t\t\t$search['tables'][0] = '`'.$this->table.'` `a`';\n\t\t\t$search['tables'][] = 'LEFT JOIN `memberBusinessInfo` `b` ON (`a`.`memberID` = `b`.`memberID`)';\n\t\t\t$search['tables'][] = 'LEFT JOIN `memberGroupMap` `c` ON (`a`.`memberID` = `c`.`memberID` AND `memberGroupID` = 2)';\n\t\t\tforeach ($search['where'] as $field => &$val) {\n\t\t\t\tswitch ($field) {\n\t\t\t\t\tcase 'company':\n\t\t\t\t\t\t$val = preg_replace('/^(AND |OR )?/', '$1`b`.', $val);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\t$val = preg_replace('/^(AND |OR )?/', '$1`a`.', $val);\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!empty($search['where'])) {\n\t\t\t\treset($search['where']);\n\t\t\t\t$key = key($search['where']);\n\t\t\t\t$search['where'][$key] = preg_replace('/^(AND|OR) /', '', $search['where'][$key]);\n\t\t\t}\n\t\t\t$search['order'][] = '`a`.`memberID` ASC';\n\t\t\treturn $search;\n\t\t}", "title": "" }, { "docid": "aec682fed9f519efa758f7124fb03366", "score": "0.55628", "text": "public function getFilterList()\n\t{\n\t\tglobal $UserProfile;\n\n\t\t// Initialize\n\t\t$filterList = \"\";\n\t\t$savedFilterList = \"\";\n\n\t\t// Load server side filters\n\t\tif (Config(\"SEARCH_FILTER_OPTION\") == \"Server\" && isset($UserProfile))\n\t\t\t$savedFilterList = $UserProfile->getSearchFilters(CurrentUserName(), \"femploymentlistsrch\");\n\t\t$filterList = Concat($filterList, $this->EmployeeID->AdvancedSearch->toJson(), \",\"); // Field EmployeeID\n\t\t$filterList = Concat($filterList, $this->ProvinceCode->AdvancedSearch->toJson(), \",\"); // Field ProvinceCode\n\t\t$filterList = Concat($filterList, $this->LACode->AdvancedSearch->toJson(), \",\"); // Field LACode\n\t\t$filterList = Concat($filterList, $this->DepartmentCode->AdvancedSearch->toJson(), \",\"); // Field DepartmentCode\n\t\t$filterList = Concat($filterList, $this->SectionCode->AdvancedSearch->toJson(), \",\"); // Field SectionCode\n\t\t$filterList = Concat($filterList, $this->SubstantivePosition->AdvancedSearch->toJson(), \",\"); // Field SubstantivePosition\n\t\t$filterList = Concat($filterList, $this->DateOfCurrentAppointment->AdvancedSearch->toJson(), \",\"); // Field DateOfCurrentAppointment\n\t\t$filterList = Concat($filterList, $this->LastAppraisalDate->AdvancedSearch->toJson(), \",\"); // Field LastAppraisalDate\n\t\t$filterList = Concat($filterList, $this->AppraisalStatus->AdvancedSearch->toJson(), \",\"); // Field AppraisalStatus\n\t\t$filterList = Concat($filterList, $this->DateOfExit->AdvancedSearch->toJson(), \",\"); // Field DateOfExit\n\t\t$filterList = Concat($filterList, $this->SalaryScale->AdvancedSearch->toJson(), \",\"); // Field SalaryScale\n\t\t$filterList = Concat($filterList, $this->EmploymentType->AdvancedSearch->toJson(), \",\"); // Field EmploymentType\n\t\t$filterList = Concat($filterList, $this->EmploymentStatus->AdvancedSearch->toJson(), \",\"); // Field EmploymentStatus\n\t\t$filterList = Concat($filterList, $this->ExitReason->AdvancedSearch->toJson(), \",\"); // Field ExitReason\n\t\t$filterList = Concat($filterList, $this->RetirementType->AdvancedSearch->toJson(), \",\"); // Field RetirementType\n\t\t$filterList = Concat($filterList, $this->EmployeeNumber->AdvancedSearch->toJson(), \",\"); // Field EmployeeNumber\n\t\t$filterList = Concat($filterList, $this->SalaryNotch->AdvancedSearch->toJson(), \",\"); // Field SalaryNotch\n\t\t$filterList = Concat($filterList, $this->BasicMonthlySalary->AdvancedSearch->toJson(), \",\"); // Field BasicMonthlySalary\n\t\t$filterList = Concat($filterList, $this->ThirdParties->AdvancedSearch->toJson(), \",\"); // Field ThirdParties\n\t\t$filterList = Concat($filterList, $this->PayrollCode->AdvancedSearch->toJson(), \",\"); // Field PayrollCode\n\t\t$filterList = Concat($filterList, $this->DateOfConfirmation->AdvancedSearch->toJson(), \",\"); // Field DateOfConfirmation\n\t\tif ($this->BasicSearch->Keyword != \"\") {\n\t\t\t$wrk = \"\\\"\" . Config(\"TABLE_BASIC_SEARCH\") . \"\\\":\\\"\" . JsEncode($this->BasicSearch->Keyword) . \"\\\",\\\"\" . Config(\"TABLE_BASIC_SEARCH_TYPE\") . \"\\\":\\\"\" . JsEncode($this->BasicSearch->Type) . \"\\\"\";\n\t\t\t$filterList = Concat($filterList, $wrk, \",\");\n\t\t}\n\n\t\t// Return filter list in JSON\n\t\tif ($filterList != \"\")\n\t\t\t$filterList = \"\\\"data\\\":{\" . $filterList . \"}\";\n\t\tif ($savedFilterList != \"\")\n\t\t\t$filterList = Concat($filterList, \"\\\"filters\\\":\" . $savedFilterList, \",\");\n\t\treturn ($filterList != \"\") ? \"{\" . $filterList . \"}\" : \"null\";\n\t}", "title": "" }, { "docid": "3b906adf79f87ac751232b680d02fccb", "score": "0.5560518", "text": "public function provideGridListFilters() {\n\t\tif ($page = Application::get_current_page()) {\n\t\t\tif ($filter = $page->config()->get('filter_all')) {\n\t\t\t\t// set ModelTag so GridList.Filter method can find it... yech\n\t\t\t\t$filter['ModelTag'] = $filter['Filter'];\n\t\t\t\treturn [\n\t\t\t\t\tnew GridListFilter($filter)\n\t\t\t ];\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "e0cf149c1f3a543322a5ac55d746420d", "score": "0.5556209", "text": "abstract public function getFieldsSearchable();", "title": "" }, { "docid": "e0cf149c1f3a543322a5ac55d746420d", "score": "0.5556209", "text": "abstract public function getFieldsSearchable();", "title": "" }, { "docid": "e0cf149c1f3a543322a5ac55d746420d", "score": "0.5556209", "text": "abstract public function getFieldsSearchable();", "title": "" }, { "docid": "26abac55768be4552e4897f8f46bdf28", "score": "0.55477417", "text": "public function search() {\r\n\r\n\t\ttry {\r\n\t\t\tglobal $ks_db;\r\n\t\t\tglobal $ks_log;\r\n\r\n\t\t\t//store found objects as an array collection of objects\r\n\t\t\t//in this case, array of KS_Acl_Inheritance\r\n\t\t\t$arrSearchResults = array ();\r\n\t\t\t\r\n\t\t\t//store found records as an array collection of objects, in this case, array of QS_Application\r\n\t\t\t$arrSearchResults = array ();\r\n\t\t\t\r\n\t\t\t//if sqlWhere clause is specified, use it\r\n\t\t\tif (trim ( $this->searchSqlWhere ) != '') {\r\n\t\t\t\t\r\n\t\t\t\t//remove the word WHERE, just in case specified\r\n\t\t\t\t$this->searchSqlWhere = preg_replace ( '/WHERE/', '', trim ( $this->searchSqlWhere ) );\r\n\t\t\t\t\r\n\t\t\t\t$sql = 'SELECT * FROM ' . $this->sqlTable;\r\n\t\t\t\t$sql .= ' WHERE ' . $this->searchSqlWhere;\r\n\t\t\t\r\n\t\t\t} else {\r\n\t\t\t\t//we use $this->arraySearchFields property\r\n\t\t\t\tif (! is_array ( $this->arraySearchFields )) {\r\n\t\t\t\t\treturn $arrSearchResults;\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$searchClause .= \"1 \";\r\n\t\t\t\t\r\n\t\t\t\t//this array holds ignored values. maybe field is specified as SearchField but matches all \r\n\t\t\t\t//(won't be included in where clause)\r\n\t\t\t\t$arrIgnoreValues = array ();\r\n\t\t\t\t$arrIgnoreValues [] = '';\r\n\t\t\t\t$arrIgnoreValues [] = '%';\r\n\t\t\t\t$arrIgnoreValues [] = '%%';\r\n\t\t\t\t$arrIgnoreValues [] = '0000-00-00';\r\n\t\t\t\t$arrIgnoreValues [] = '0000-00-00 00:00:00';\r\n\t\t\t\t$arrIgnoreValues [] = NULL;\r\n\t\t\t\t\r\n\t\t\t\tforeach ( $this->arraySearchFields as $curSearchFieldObject ) {\r\n\t\t\t\t\t$searchField = $curSearchFieldObject->getField ();\r\n\t\t\t\t\t$searchValue = $curSearchFieldObject->getValue ();\r\n\t\t\t\t\t$searchOperator = $curSearchFieldObject->getOperator ();\r\n\t\t\t\t\t\r\n\t\t\t\t\tif (in_array ( $searchValue, $arrIgnoreValues )) {\r\n\t\t\t\t\t\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\t$searchClause .= \" AND $searchField $searchOperator ? \";\r\n\t\t\t\t\t\t$searchBinding [] = $searchValue;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t$sql = \"SELECT * FROM \" . $this->sqlTable;\r\n\t\t\t\t$sql .= \" WHERE $searchClause\";\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//we need to know in total, how many (before we limit the return by LIMIT )??\r\n\t\t\t$sqlTotal = $sql;\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tif (trim ( $this->searchSortField )) {\r\n\t\t\t\t$sql .= \" ORDER BY {$this->searchSortField} {$this->searchSortOrder} \";\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$pageStart = $this->searchPageStart * $this->searchRecordsPerPage;\r\n\t\t\t\r\n\t\t\t$sql .= \" LIMIT $pageStart, {$this->searchRecordsPerPage}\";\r\n\t\t\t\r\n\t\t\t$stmt = $ks_db->query ( $sql, $searchBinding );\r\n\t\t\t\r\n\t\t\t$stmtTotal = $ks_db->query ( $sqlTotal, $searchBinding );\r\n\t\t\t\r\n\t\t\t//count how many rows found\r\n\t\t\t$this->searchRowCount = $stmtTotal->rowCount ();\r\n\t\t\t\r\n\t\t\t//record is found, associate columns to the object properties\r\n\t\t\twhile ( true == ($row = $stmt->fetch ()) ) {\r\n\t\t\t\t\r\n\t\t\t\t$objResult = new KS_Acl_Inheritance ( );\r\n\t\t\t\t\r\n\t\t\t\t$objResult->childid = $row ['inh_childid'];\r\n\t\t\t\t$objResult->parentid = $row ['inh_parentid'];\r\n\t\t\t\t$objResult->order = $row ['inh_order'];\r\n\t\t\t\t\r\n\t\t\t\t$arrSearchResults [] = $objResult;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\treturn $arrSearchResults;\r\n\r\n\t\t} catch(Exception $e) {\r\n\t\t\t$ks_log->info ( 'Fatal Error: ' . __CLASS__ . '::' . __METHOD__ . '. ' . $e->getMessage () );\r\n\t\t\t$ks_log->info ( '<br>SQL Statement: ' . $sql );\r\n\t\t\techo \"Fatal Error: \" . __CLASS__ . '::' . __METHOD__ . '. ' . $e->getMessage ();\r\n\t\t\techo \"SQL Statement: \" . $sql;\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "1e9f20a0643568412c8b0381b37ba744", "score": "0.5539157", "text": "public function getModels(Request $request)\n {\n if (request('make') != 'alle') {\n $models = vehicle::select('model')->distinct()->where('make', request('make'))->get();\n return response()->json($models);\n }\n }", "title": "" } ]
fca8d4dca22723615c4142bbc217b0d5
/ Takes in an integervalue recommendation level for a TA applicant and returns the corresponding text for that recommendation level
[ { "docid": "5c488378601058c5204b057a354027eb", "score": "0.6203402", "text": "function get_recommendation( $value )\n{\n if ($value == 1)\n {\n return \"Possible\";\n }\n else if ($value == 2)\n {\n return \"Recommended\";\n }\n else if ($value == 3)\n {\n return \"Desired\";\n }\n else if ($value == 4)\n {\n return \"Confirmed\";\n }\n\n return \"Not Interested\";\n}", "title": "" } ]
[ { "docid": "cfb5c2bac99a77774101b911fed54bd5", "score": "0.6423506", "text": "function hitchability2textual($rating=false) {\n\n\tif($rating == 1) return _(\"Very good\");\n\telseif($rating == 2) return _(\"Good\");\n\telseif($rating == 3) return _(\"Average\");\n\telseif($rating == 4) return _(\"Bad\");\n\telseif($rating == 5) return _(\"Senseless\");\n\telse return _(\"Unknown\");\n}", "title": "" }, { "docid": "564b1d9157414f9f5ef98d2860d3fed9", "score": "0.5668159", "text": "function setTextRating($a_text_rating)\n\t{\n\t\tswitch ($a_text_rating)\n\t\t{\n\t\t\tcase TEXTGAP_RATING_CASEINSENSITIVE:\n\t\t\tcase TEXTGAP_RATING_CASESENSITIVE:\n\t\t\tcase TEXTGAP_RATING_LEVENSHTEIN1:\n\t\t\tcase TEXTGAP_RATING_LEVENSHTEIN2:\n\t\t\tcase TEXTGAP_RATING_LEVENSHTEIN3:\n\t\t\tcase TEXTGAP_RATING_LEVENSHTEIN4:\n\t\t\tcase TEXTGAP_RATING_LEVENSHTEIN5:\n\t\t\t\t$this->text_rating = $a_text_rating;\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t$this->text_rating = TEXTGAP_RATING_CASEINSENSITIVE;\n\t\t\t\tbreak;\n\t\t}\n\t}", "title": "" }, { "docid": "0312c943e61835b771bb924d15a95d63", "score": "0.5565711", "text": "public abstract function get_accessibility_text();", "title": "" }, { "docid": "ff3611a9f1c767eab7fa0d54ff69602a", "score": "0.54768056", "text": "function getExperience($value) {\n\n switch ($value) {\n case 'N':\n $text = \"ยังไม่เคยตกปลามาก่อน\";\n Return $text;\n break;\n default:\n $text = \"มีประสบการณ์ตกปลามาบ้างแล้ว\"; Return $text; }\n}", "title": "" }, { "docid": "ec577bacef27b6ce28918d98a4ada5cc", "score": "0.54729474", "text": "function getTextRating()\n\t{\n\t\treturn $this->text_rating;\n\t}", "title": "" }, { "docid": "c42e8ca2da9ffc058e02dc92fc04ea2e", "score": "0.51807153", "text": "function do_valtostr_rate_ticket($avalue) {\n\t# Dim some Vars:\n\t\tglobal $_LANG;\n\n\t\tswitch($avalue) {\n\t\t\tcase \"1\":\n\t\t\t\t$_result = '*';\n\t\t\t\tbreak;\n\t\t\tcase \"2\":\n\t\t\t\t$_result = '**';\n\t\t\t\tbreak;\n\t\t\tcase \"3\":\n\t\t\t\t$_result = '***';\n\t\t\t\tbreak;\n\t\t\tcase \"4\":\n\t\t\t\t$_result = '****';\n\t\t\t\tbreak;\n\t\t\tcase \"5\":\n\t\t\t\t$_result = '*****';\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t$_result = $_LANG['_HDESK']['unrated'];\n\t\t\t\tbreak;\n\t\t}\n\n\t\treturn $_result;\n}", "title": "" }, { "docid": "48f4c172256a924c541877562422715c", "score": "0.5169925", "text": "#[Pure]\n #[TentativeType]\n public static function reasonText(\n #[ElementAvailable(from: '5.3', to: '7.4')] $reason = 0,\n #[ElementAvailable(from: '8.0')] int $reason\n ): string {}", "title": "" }, { "docid": "455c6f23dd74962ea6851ae0fc728e5a", "score": "0.5149375", "text": "function wpars_rating_text($post_id = null,$template = null) {\n\tglobal $wpdb,$post;\n\tglobal $template_rate_only_text;\n\t$out_put = '';\n\tif (is_null($post_id) || $post_id == 0) { $post_id = get_the_ID(); }\n\tif (is_null($template) || $template == 0) { $template = $template_rate_only_text; }\n\t$out_put .= '<span id=\"rate_text_'.$post_id.'\" class=\"wpars_rating_text\">';\n\t$out_put .= wpars_rating_text_out($post_id, $template_rate_only_text );\n\t$out_put .= '</span>';\n\treturn $out_put;\n}", "title": "" }, { "docid": "75b8371387dc332333aaba107560987e", "score": "0.51294214", "text": "public function get_qual_award()\r\n {\r\n $type = get_string('predicted','block_bcgt');\r\n $award = \"N/S\";\r\n if ($this->studentAward){\r\n $award = $this->studentAward->get_award();\r\n } \r\n \r\n return \"<span id='qualAwardType_{$this->studentID}'>$type</span><br><span id='qualAward_{$this->studentID}'>\".$award.\"</span>\";\t\r\n \r\n }", "title": "" }, { "docid": "0f257030deb7efaf2fc06e10e33cb446", "score": "0.50748634", "text": "private function achievementIndexToDescription($ind)\r\n {\r\n switch($ind)\r\n {\r\n case 0: return \"XS: max score of 20% reached.\";\r\n case 1: return \"S : max score of 20% reached.\";\r\n case 2: return \"M : max score of 20% reached.\";\r\n case 3: return \"L : max score of 20% reached.\";\r\n case 4: return \"XL: max score of 20% reached.\";\r\n case 5: return \"All max scores of 20% reached.\";\r\n\r\n case 6: return \"XS: max score of 30% reached.\";\r\n case 7: return \"S : max score of 30% reached.\";\r\n case 8: return \"M : max score of 30% reached.\";\r\n case 9: return \"L : max score of 30% reached.\";\r\n case 10: return \"XL: max score of 30% reached.\";\r\n case 11: return \"All max scores of 30% reached.\";\r\n\r\n //TODO: Fill in names\r\n case 12: return \"Unlocked preset 12\";\r\n case 13: return \"Unlocked preset 13\";\r\n case 14: return \"Unlocked preset 14\";\r\n case 15: return \"Unlocked preset 15\";\r\n case 16: return \"Unlocked preset 16\";\r\n case 17: return \"Unlocked preset 17\";\r\n case 18: return \"Unlocked preset 18\";\r\n case 19: return \"Unlocked preset 19\";\r\n case 20: return \"Unlocked preset 20\";\r\n case 21: return \"Unlocked preset 21\";\r\n case 22: return \"Unlocked preset 22\";\r\n case 23: return \"Unlocked preset 23\";\r\n case 24: return \"Unlocked preset 24\";\r\n case 25: return \"Unlocked preset 25\";\r\n case 26: return \"Unlocked preset 26\";\r\n case 27: return \"Unlocked preset 27\";\r\n case 28: return \"Unlocked preset 28\";\r\n case 29: return \"Unlocked preset 29\";\r\n case 30: return \"Unlocked preset 30\";\r\n case 31: return \"Unlocked preset 31\";\r\n case 32: return \"Unlocked preset 32\";\r\n case 33: return \"Unlocked preset 33\";\r\n case 34: return \"Unlocked preset 34\";\r\n case 35: return \"Unlocked preset 35\";\r\n case 36: return \"Unlocked preset 36\";\r\n case 37: return \"Unlocked preset 37\";\r\n case 38: return \"Unlocked preset 38\";\r\n case 39: return \"Unlocked preset 39\";\r\n case 40: return \"Unlocked preset 40\";\r\n case 41: return \"Unlocked preset 41\";\r\n case 42: return \"Unlocked preset 42\";\r\n case 43: return \"Unlocked preset 43\";\r\n case 44: return \"Unlocked preset 44\";\r\n case 45: return \"Unlocked preset 45\";\r\n case 46: return \"Unlocked preset 46\";\r\n case 47: return \"Unlocked preset 47\";\r\n case 48: return \"Unlocked preset 48\";\r\n case 49: return \"Unlocked preset 49\";\r\n case 50: return \"Unlocked preset 50\";\r\n case 51: return \"Unlocked preset 51\";\r\n case 52: return \"Unlocked preset 52\";\r\n case 53: return \"Unlocked preset 53\";\r\n case 54: return \"Unlocked preset 54\";\r\n case 55: return \"Unlocked preset 55\";\r\n case 56: return \"Unlocked preset 56\";\r\n case 57: return \"Unlocked preset 57\";\r\n case 58: return \"Unlocked preset 58\";\r\n case 59: return \"Unlocked preset 59\";\r\n case 60: return \"Unlocked preset 60\";\r\n case 61: return \"Unlocked preset 61\";\r\n case 62: return \"Unlocked preset 62\";\r\n case 63: return \"Unlocked preset 63\";\r\n case 64: return \"Unlocked preset 64\";\r\n case 65: return \"Unlocked preset 65\";\r\n case 66: return \"Unlocked preset 66\";\r\n case 67: return \"Unlocked preset 67\";\r\n case 68: return \"Unlocked preset 68\";\r\n case 69: return \"Unlocked preset 69\";\r\n case 70: return \"Unlocked preset 70\";\r\n case 71: return \"Unlocked preset 71\";\r\n case 72: return \"Unlocked preset 72\";\r\n case 73: return \"Unlocked preset 73\";\r\n case 74: return \"Unlocked preset 74\";\r\n case 75: return \"Unlocked preset 75\";\r\n case 76: return \"Unlocked preset 76\";\r\n case 77: return \"Unlocked preset 77\";\r\n case 78: return \"Unlocked preset 78\";\r\n case 79: return \"Unlocked preset 79\";\r\n case 80: return \"Unlocked preset 80\";\r\n case 81: return \"Unlocked preset 81\";\r\n case 82: return \"Unlocked preset 82\";\r\n case 83: return \"Unlocked preset 83\";\r\n case 84: return \"Unlocked preset 84\";\r\n case 85: return \"Unlocked preset 85\";\r\n case 86: return \"Unlocked preset 86\";\r\n case 87: return \"Unlocked preset 87\";\r\n case 88: return \"Unlocked preset 88\";\r\n case 89: return \"Unlocked preset 89\";\r\n case 90: return \"Unlocked preset 90\";\r\n case 91: return \"Unlocked preset 91\";\r\n case 92: return \"Unlocked preset 92\";\r\n case 93: return \"Unlocked preset 93\";\r\n case 94: return \"Unlocked preset 94\";\r\n case 95: return \"Unlocked preset 95\";\r\n case 96: return \"Unlocked preset 96\";\r\n case 97: return \"Unlocked preset 97\";\r\n case 98: return \"Unlocked preset 98\";\r\n case 99: return \"Unlocked preset 99\";\r\n case 100: return \"Unlocked preset 100\";\r\n case 101: return \"Unlocked preset 101\";\r\n case 102: return \"Unlocked preset 102\";\r\n case 103: return \"Unlocked preset 103\";\r\n case 104: return \"Unlocked preset 104\";\r\n case 105: return \"Unlocked preset 105\";\r\n case 106: return \"Unlocked preset 106\";\r\n case 107: return \"Unlocked preset 107\";\r\n case 108: return \"Unlocked preset 108\";\r\n case 109: return \"Unlocked preset 109\";\r\n case 110: return \"Unlocked preset 110\";\r\n case 120: return \"Unlocked preset 120\";\r\n case 121: return \"Unlocked preset 121\";\r\n case 122: return \"Unlocked preset 122\";\r\n case 123: return \"Unlocked preset 123\";\r\n case 124: return \"Unlocked preset 124\";\r\n case 125: return \"Unlocked preset 125\";\r\n case 126: return \"Unlocked preset 126\";\r\n case 127: return \"Unlocked preset 127\";\r\n case 128: return \"Unlocked preset 128\";\r\n case 129: return \"Unlocked preset 129\";\r\n case 130: return \"Unlocked preset 130\";\r\n case 131: return \"Unlocked preset 131\";\r\n case 132: return \"Unlocked preset 132\";\r\n case 133: return \"Unlocked preset 133\";\r\n case 134: return \"Unlocked preset 134\";\r\n case 135: return \"Unlocked preset 135\";\r\n case 136: return \"Unlocked preset 136\";\r\n case 137: return \"Unlocked preset 137\";\r\n case 138: return \"Unlocked preset 138\";\r\n case 139: return \"Unlocked preset 139\";\r\n case 140: return \"Unlocked preset 140\";\r\n case 141: return \"Unlocked preset 141\";\r\n case 142: return \"Unlocked preset 142\";\r\n case 143: return \"Unlocked preset 143\";\r\n case 144: return \"Unlocked preset 144\";\r\n case 145: return \"Unlocked preset 145\";\r\n case 146: return \"Unlocked preset 146\";\r\n case 147: return \"Unlocked preset 147\";\r\n case 148: return \"Unlocked preset 148\";\r\n case 149: return \"Unlocked preset 149\";\r\n case 150: return \"Unlocked preset 150\";\r\n case 151: return \"Unlocked preset 151\";\r\n case 152: return \"Unlocked preset 152\";\r\n case 153: return \"Unlocked preset 153\";\r\n case 154: return \"Unlocked preset 154\";\r\n case 155: return \"Unlocked preset 155\";\r\n case 156: return \"Unlocked preset 156\";\r\n case 157: return \"Unlocked preset 157\";\r\n case 158: return \"Unlocked preset 158\";\r\n case 159: return \"Unlocked preset 159\";\r\n case 160: return \"Unlocked preset 160\";\r\n case 161: return \"Unlocked preset 161\";\r\n case 162: return \"Unlocked preset 162\";\r\n case 163: return \"Unlocked preset 163\";\r\n case 164: return \"Unlocked preset 164\";\r\n case 165: return \"Unlocked preset 165\";\r\n case 166: return \"Unlocked preset 166\";\r\n case 167: return \"Unlocked preset 167\";\r\n case 168: return \"Unlocked preset 168\";\r\n case 169: return \"Unlocked preset 169\";\r\n case 170: return \"Unlocked preset 170\";\r\n case 171: return \"Unlocked preset 171\";\r\n case 172: return \"Unlocked preset 172\";\r\n case 173: return \"Unlocked preset 173\";\r\n case 174: return \"Unlocked preset 174\";\r\n case 175: return \"Unlocked preset 175\";\r\n case 176: return \"Unlocked preset 176\";\r\n case 177: return \"Unlocked preset 177\";\r\n case 178: return \"Unlocked preset 178\";\r\n case 179: return \"Unlocked preset 179\";\r\n case 180: return \"Unlocked preset 180\";\r\n case 181: return \"Unlocked preset 181\";\r\n case 182: return \"Unlocked preset 182\";\r\n case 183: return \"Unlocked preset 183\";\r\n case 184: return \"Unlocked preset 184\";\r\n case 185: return \"Unlocked preset 185\";\r\n case 186: return \"Unlocked preset 186\";\r\n case 187: return \"Unlocked preset 187\";\r\n case 188: return \"Unlocked preset 188\";\r\n default: return \"Unknown Achievement\";\r\n }\r\n }", "title": "" }, { "docid": "dc6df530df3022e9082be462f4956cde", "score": "0.5072577", "text": "function tkdItm_getString_jobRate( $taskItem ) {\n switch($taskItem->tskItem_job_rateCode) {\n case PAY_RATEMETHOD_ADMIN: $desc = 'Admin'; break;\n case PAY_RATEMETHOD_FIELD: $desc = 'Field'; break;\n case PAY_RATEMETHOD_SALARY: $desc = 'Salary'; break;\n case PAY_RATEMETHOD_OVERRIDE_RATE: $desc = 'Rate='.draff_dollarsAsString($taskItem->tskItem_override_rateAmount); break;\n case PAY_RATEMETHOD_OVERRIDE_AMOUNT: $desc = 'Pay='.draff_dollarsAsString($taskItem->tskItem_override_rateAmount); break;\n case 0: $desc = 'n/a'; break;\n default: $desc = '???'; break;\n }\n}", "title": "" }, { "docid": "00e5443a37798a8c53634bb67e078974", "score": "0.5068804", "text": "public static function getDescription($value): string\n {\n /**\n if ($value === self::Postive) {\n return 'Malaria Postive';\n }\n */\n\n switch ($value) {\n case self::Male:\n return 'Male';\n break;\n\n case self::Female:\n return 'Female';\n break;\n\n case self::Unknown:\n return 'N/A';\n break;\n\n default:\n return self::getKey($value);\n }\n\n return parent::getDescription($value);\n }", "title": "" }, { "docid": "3a15c24a1b603149f8f3954a9a07a184", "score": "0.50376016", "text": "private function processRatingSystem($gameRating)\n {\n if(substr($gameRating,0,3)=='SRB'){\n $gameRating = \"ESRB:\" . substr($gameRating,3);\n }\n\n switch($gameRating){\n case \"ESRB:AlcRef\":\n $cleanedRating = \"Alcohol Reference\";\n break;\n case \"ESRB:AlcAndTobRef\":\n $cleanedRating = \"Alcohol and Tobacco Reference\";\n break;\n case \"ESRB:AniBlo\":\n $cleanedRating = \"Animated Blood\";\n break;\n case \"ESRB:Blo\":\n $cleanedRating = \"Blood\";\n break;\n case \"ESRB:BloGor\":\n $cleanedRating = \"Blood and Gore\";\n break;\n case \"ESRB:CarVio\":\n $cleanedRating = \"Cartoon Violence\";\n break;\n case \"ESRB:ComMis\":\n $cleanedRating = \"Comic Mischief\";\n break;\n case \"ESRB:CruHum\":\n $cleanedRating = \"Crude Humor\";\n break;\n case \"ESRB:DruRef\":\n $cleanedRating = \"Drug Reference\";\n break;\n case \"ESRB:E\":\n $cleanedRating = \"Everyone\";\n break;\n case \"ESRB:E10\":\n $cleanedRating = \"Everyone\";\n break;\n case \"ESRB:FanVio\":\n $cleanedRating = \"Fantasy Violence\";\n break;\n case \"ESRB:IntVio\":\n $cleanedRating = \"Intense Violence\";\n break;\n case \"ESRB:Lan\":\n $cleanedRating = \"Language\";\n break;\n case \"ESRB:Lyr\":\n $cleanedRating = \"Lyrics\";\n break;\n case \"ESRB:MatHum\":\n $cleanedRating =\"Mature Humor\";\n break;\n case \"ESRB:MilBlo\":\n $cleanedRating =\"Mild Blood\";\n break;\n case \"ESRB:MilCarVio\":\n $cleanedRating =\"Mild Cartoon Violence\";\n break;\n case \"ESRB:MilFanVio\":\n $cleanedRating =\"Mild Fantasy Violence\";\n break;\n case \"ESRB:MilLan\":\n $cleanedRating =\"Mild Language\";\n break;\n case \"ESRB:MilLyr\":\n $cleanedRating =\"Mild Lyrics\";\n break;\n case \"ESRB:MilSexThe\":\n $cleanedRating =\"Mild Sexual Themes\";\n break;\n case \"ESRB:MilSugThe\":\n $cleanedRating =\"Mild Suggestive Themes\";\n break;\n case \"ESRB:MilVio\":\n $cleanedRating =\"Mild Violence\";\n break;\n case \"ESRB:MilVio1\":\n $cleanedRating =\"Mild Violence\";\n break;\n case \"ESRB:MilVio3\":\n $cleanedRating =\"Mild Violence\";\n break;\n case \"ESRB:MilVio5\":\n $cleanedRating =\"Mild Violence\";\n break;\n case \"ESRB:MilVio7\":\n $cleanedRating =\"Mild Violence\";\n break;\n case \"ESRB:MilVio9\":\n $cleanedRating =\"Mild Violence\";\n break;\n case \"ESRB:Nud\":\n $cleanedRating =\"Nudity\";\n break;\n case \"ESRB:ParNud\":\n $cleanedRating =\"Partial Nudity\";\n break;\n case \"ESRB:ReaGam\":\n $cleanedRating =\"Real Gambling\";\n break;\n case \"ESRB:RPEveryone\":\n $cleanedRating = \"Everyone\";\n break;\n case \"ESRB:RPTeen\":\n $cleanedRating = \"Everyone\";\n break;\n case \"ESRB:SexCon\":\n $cleanedRating =\"Sexual Content\";\n break;\n case \"ESRB:SexThe\":\n $cleanedRating =\"Sexual Themes\";\n break;\n case \"ESRB:SexVio\":\n $cleanedRating =\"Sexual Violence\";\n break;\n case \"ESRB:SimGam\":\n $cleanedRating =\"Simulated Gambling\";\n break;\n case \"ESRB:StrLan\":\n $cleanedRating =\"Strong Language\";\n break;\n case \"ESRB:StrLyr\":\n $cleanedRating =\"Strong Lyrics\";\n break;\n case \"ESRB:StrSexCon\":\n $cleanedRating =\"Strong Sexual Content\";\n break;\n case \"ESRB:SugThe\":\n $cleanedRating =\"Suggestive Themes\";\n break;\n case \"ESRB:T\":\n $cleanedRating = \"Everyone\";\n break;\n case \"ESRB:TobRef\":\n $cleanedRating =\"Tobacco Reference\";\n break;\n case \"ESRB:UseOfAlcAndTob\":\n $cleanedRating =\"Use of Alcohol and Tobacco\";\n break;\n case \"ESRB:UseAlc\":\n $cleanedRating =\"Use of Alcohol\";\n break;\n case \"ESRB:UseDru\":\n $cleanedRating =\"Use of Drugs\";\n break;\n case \"ESRB:UseTob\":\n $cleanedRating =\"Use of Tobacco\";\n break;\n case \"ESRB:Vio\":\n $cleanedRating =\"Violence\";\n break;\n case \"ESRB:VioRef\":\n $cleanedRating =\"Violent References\";\n break;\n default:\n $cleanedRating = $gameRating;\n break;\n }\n\n return $cleanedRating;\n }", "title": "" }, { "docid": "6e388cf950122d119dd1567df11a0697", "score": "0.50004935", "text": "function raceText( $num, $gen ) {\r\n\t$racename = '';\r\n\t$gendername = '';\r\n\r\n\tswitch ( $num ) {\r\n\t\tcase 1:\r\n\t\t\t$racename = 'Human';\r\n\t\t\tbreak;\r\n\t\tcase 2:\r\n\t\t\t$racename = 'Orc';\r\n\t\t\tbreak;\r\n\t\tcase 3:\r\n\t\t\t$racename = 'Dwarf';\r\n\t\t\tbreak;\r\n\t\tcase 4:\r\n\t\t\t$racename = 'NightElf';\r\n\t\t\tbreak;\r\n\t\tcase 5:\r\n\t\t\t$racename = 'Undead';\r\n\t\t\tbreak;\r\n\t\tcase 6:\r\n\t\t\t$racename = 'Tauren';\r\n\t\t\tbreak;\r\n\t\tcase 7:\r\n\t\t\t$racename = 'Gnome';\r\n\t\t\tbreak;\r\n\t\tcase 8:\r\n\t\t\t$racename = 'Troll';\r\n\t\t\tbreak;\r\n\t\tcase 9:\r\n\t\t\t$racename = 'Goblin';\r\n\t\t\tbreak;\r\n\t\tcase 10:\r\n\t\t\t$racename = 'BloodElf';\r\n\t\t\tbreak;\r\n\t\tcase 11:\r\n\t\t\t$racename = 'Draenei';\r\n\t\t\tbreak;\r\n\t\tcase 22:\r\n\t\t\t$racename = 'Worgen';\r\n\t\t\tbreak;\r\n\t\tcase 26:\r\n\t\t\t$racename = 'Pandaren';\r\n\t\t\tbreak;\r\n\t}\r\n\r\n\tswitch ( $gen ) {\r\n\t\tcase '0':\r\n\t\t\t$gendername = 'Male';\r\n\t\t\tbreak;\r\n\t\tcase '1':\r\n\t\t\t$gendername = 'Female';\r\n\t\t\tbreak;\r\n\t}\r\n\r\n\t$fullrace = $racename . ' ' . $gendername;\r\n\treturn $fullrace;\r\n}", "title": "" }, { "docid": "01993573fc1028e680511fa594a633f8", "score": "0.49956048", "text": "public function reasonPhrase();", "title": "" }, { "docid": "c60344aaf24973e2b903d1692f47bc6b", "score": "0.49940145", "text": "public function getText()\n {\n return sprintf(static::$text, $this->TrainValues['trainNr'], $this->TrainValues['from'], $this->TrainValues['to'], $this->TrainValues['seatNumber']);\n }", "title": "" }, { "docid": "f24c1cb9d94d3e569fa6b3e81ed7e15a", "score": "0.49936318", "text": "public function getRecommendation()\n {\n return $this->recommendation;\n }", "title": "" }, { "docid": "7892e6baa0daac073c084291bf6d6c5d", "score": "0.49922043", "text": "function exhibit_builder_page_text($entryIndex = 1, $exhibitPage = null)\n{\n if (!$exhibitPage) {\n $exhibitPage = get_current_record('exhibit_page');\n }\n\n if (count($exhibitPage->ExhibitPageEntry) < $entryIndex) {\n $text = '';\n } else {\n $text = $exhibitPage->ExhibitPageEntry[(int) $entryIndex]->text;\n }\n\n return $text;\n}", "title": "" }, { "docid": "ec29af533e5feb22a25895ad2c86f1aa", "score": "0.49900785", "text": "public function get_onlinetext($itemid) {\n global $DB;\n\n $moodletextsubmission = $DB->get_record('question_attempts', array('id' => $itemid), 'responsesummary');\n\n if (isset($moodletextsubmission->responsesummary)) {\n return $moodletextsubmission->responsesummary;\n }\n }", "title": "" }, { "docid": "6181e9c122f0f07048117ff214fbcd4c", "score": "0.49884295", "text": "public function test_display_of_penalty_regime() {\n $q = test_question_maker::make_question('coderunner', 'sqr');\n $q->penaltyregime = '';\n $q->penalty = 0.18555555;\n $this->start_attempt_at_question($q, 'adaptive', 1, 1);\n $this->check_output_contains('penalty regime: 18.6, 37.1, ... %');\n $q = test_question_maker::make_question('coderunner', 'sqr');\n $q->penaltyregime = '0,11,33, ...';\n $q->penalty = 0.18555555;\n $this->start_attempt_at_question($q, 'adaptive', 1, 1);\n $this->check_output_contains('penalty regime: 0,11,33, ... %');\n }", "title": "" }, { "docid": "4fb53255ee36983f5cf2eeaa9c0da183", "score": "0.4963246", "text": "function spamLevelToText($level)\n{\n if (is_float($level)) {\n $percentage = round($level * 100);\n if ($level <= 0.25) return '<span style=\"color:#00cc00;\">unwahrscheinlich (' . $percentage . '%)</span>';\n if ($level <= 0.5) return '<span style=\"color:#cccc00;\">gering (' . $percentage . '%)</span>';\n if ($level <= 0.75) return '<span style=\"color:#ff8000;\">mittel (' . $percentage . '%)</span>';\n //higher than 75%\n return '<span style=\"color:#ff0000;\"><b>hoch (' . $percentage . '%)</b></span>';\n }\n //usual integer-based stuff\n if ($level <= 0) return '<span style=\"color:#00cc00;\">unwahrscheinlich</span>';\n if ($level == 1) return '<span style=\"color:#cccc00;\">gering</span>';\n if ($level == 2) return '<span style=\"color:#ff8000;\">mittel</span>';\n //3 or higher\n return '<span style=\"color:#ff0000;\"><b>hoch</b></span>';\n}", "title": "" }, { "docid": "3259d804106ceea7ad0252a113b4a020", "score": "0.49572715", "text": "function maipr_get_post_reviewer_text() {\n\t$reviewers = maipr_get_post_reviewer_terms();\n\tif ( ! $reviewers ) {\n\t\treturn '';\n\t}\n\t// Filter to change the default 'Reviewed by:' text.\n\t$text = apply_filters( 'maipr_post_reviewer_text', __( 'Reviewed by:', 'mai-post-reviewers' ) );\n\treturn sprintf( '<span class=\"reviewer-text\">%s&nbsp;</span>', $text );\n}", "title": "" }, { "docid": "6f89ccb45848dafe3185001791187106", "score": "0.4938815", "text": "public function getOpinion() {\n\t\treturn $this->getAsString('opinion');\n\t}", "title": "" }, { "docid": "23211e0505e9c9d6e04b6a6c6045f840", "score": "0.4918664", "text": "public function getFormattedScoreGradeAttribute(): string\n {\n if ($this->score <= 5) {\n return 'Poor';\n }\n\n if ($this->score <= 7) {\n return 'Variable';\n }\n\n if ($this->score <= 9) {\n return 'Good';\n }\n\n return 'Excellent';\n }", "title": "" }, { "docid": "c359655d9486235ec739b27c5b88ca5d", "score": "0.4913437", "text": "function get_text($expr){\n\n if (!empty($expr)) {\n //Lets Explode the share to get the REc_id\n @$ex1= explode('-', $expr);\n @$postid= $ex1[0];\n $p=$postid.\"-\";\n $tit2= str_replace($p, ' ', $expr);\n $tit2=ucwords(str_replace('-', ' ', $tit2));\n\n return $tit2;//the extracted post id from the statemnet\n } \n\n\n}", "title": "" }, { "docid": "c32ce1c839981ff03123a6d2a60f34b4", "score": "0.48848853", "text": "function getMStatTxt( $qKey )\n {\n global $link;\n global $mp_script;\n #\n # read mp_stat_type on key and get descriptive text\n #\n $Qquery = \"SELECT * FROM mp_stat_type WHERE m_stat_id = '$qKey'\";\n $Qresult=mysqli_query($link, $Qquery)\n or die( \"$mp_script - cannot read status codes for text\" );\n #\n # read results of query and return\n #\n while ($Qrow = mysqli_fetch_array( $Qresult ) )\n {\n $qualstr = $Qrow[ \"m_stat_txt\" ];\n }\n #\n # return\n #\n mysqli_free_result( $Qresult );\n return $qualstr;\n }", "title": "" }, { "docid": "9aacea6d099de0d94e826c68bc37f9a8", "score": "0.48811942", "text": "function RequestType($type){\n\n\t\tswitch($type){\n\n\t\t\tcase 1:$text=\"Casual Leaves\";\n\n\t\t\tbreak;\n\n\t\t\tcase 2:$text=\"Medical Leaves\"; \n\n\t\t\tbreak;\n\n\t\t\tcase 3:$text=\"Work From Home\";\n\n\t\t\tbreak;\n\n\t\t\tcase 4:$text=\"LOP\";\n\n\t\t\tbreak;\t\t\t\n\n\t\t\tcase 5:$text=\"Swap\"; \n\n\t\t\tbreak;\n\n\t\t}\n\n\t\treturn $text;\n\n\t}", "title": "" }, { "docid": "06493b1ed86434cd2e14b7d3f81a53fc", "score": "0.48773852", "text": "public function specific_feedback(question_attempt $qa) {\n global $DB;\n\n $output = '';\n\n // Decide if we should show grade explanation.\n // This will skip \"gaveup\" and possibly others\n if ($step = $qa->get_last_step()) {\n $show = preg_match('/(right|partial|wrong)$/', $step->get_state());\n } else {\n $show = false;\n }\n\n // If required, show explanation of grade calculation.\n if ($show) {\n\n $plugin = $this->plugin_name();\n $question = $qa->get_question();\n\n $currentresponse = $question->get_current_response();\n $displayoptions = $currentresponse->displayoptions;\n if ($displayoptions && isset($displayoptions->markdp)) {\n $precision = $displayoptions->markdp;\n } else {\n $precision = 0;\n }\n\n $gradeband = array_values($currentresponse->bands); // percents\n $gradeband = array_search($currentresponse->completepercent, $gradeband);\n $gradeband++;\n\n $itemtype = '';\n switch ($question->itemtype) {\n case $question->plugin_constant('ITEM_TYPE_CHARS'): $itemtype = get_string('chars', $plugin); break;\n case $question->plugin_constant('ITEM_TYPE_WORDS'): $itemtype = get_string('words', $plugin); break;\n case $question->plugin_constant('ITEM_TYPE_SENTENCES'): $itemtype = get_string('sentences', $plugin); break;\n case $question->plugin_constant('ITEM_TYPE_PARAGRAPHS'): $itemtype = get_string('paragraphs', $plugin); break;\n }\n $itemtype = core_text::strtolower($itemtype);\n\n $show = has_capability('mod/quiz:grade', $displayoptions->context);\n $show = array(\n $this->plugin_constant('SHOW_NONE') => false,\n $this->plugin_constant('SHOW_TEACHERS_ONLY') => $show,\n $this->plugin_constant('SHOW_TEACHERS_AND_STUDENTS') => true,\n );\n\n $showgradebands = ($show[$question->showgradebands] && count($currentresponse->bands));\n\n if ($show[$question->showtextstats] && $question->textstatitems) {\n $strman = get_string_manager();\n\n $table = new html_table();\n $table->attributes['class'] = 'generaltable essayautograde_stats';\n\n $names = explode(',', $question->textstatitems);\n $names = array_filter($names);\n foreach ($names as $name) {\n $label = get_string($name, $plugin);\n if ($strman->string_exists($name.'_help', $plugin)) {\n $label .= $this->help_icon($name, $plugin);\n }\n if (isset($currentresponse->stats->$name)) {\n $value = $currentresponse->stats->$name;\n } else {\n $value = '';\n }\n if (is_int($value)) {\n $value = number_format($value);\n }\n $cells = array(new html_table_cell($label),\n new html_table_cell($value));\n $table->data[] = new html_table_row($cells);\n }\n $output .= html_writer::tag('h5', get_string('textstatistics', $plugin));\n $output .= html_writer::table($table);\n }\n\n // show explanation of calculation, if required\n if ($show[$question->showcalculation]) {\n\n $details = array();\n if ($currentresponse->completecount) {\n $a = (object)array('percent' => $currentresponse->completepercent,\n 'count' => $currentresponse->completecount,\n 'gradeband' => $gradeband,\n 'itemtype' => $itemtype);\n if ($showgradebands) {\n $details[] = get_string('explanationcompleteband', $plugin, $a);\n } else {\n $details[] = get_string('explanationfirstitems', $plugin, $a);\n }\n }\n if ($currentresponse->partialcount) {\n $a = (object)array('percent' => $currentresponse->partialpercent,\n 'count' => $currentresponse->partialcount,\n 'gradeband' => ($gradeband + 1),\n 'itemtype' => $itemtype);\n if ($showgradebands) {\n $details[] = get_string('explanationpartialband', $plugin, $a);\n } else if (count($details)) {\n $details[] = get_string('explanationremainingitems', $plugin, $a);\n } else if ($currentresponse->partialpercent) {\n $details[] = get_string('explanationitems', $plugin, $a);\n }\n }\n\n foreach ($currentresponse->myphrases as $phrase => $percent) {\n $a = (object)array('percent' => $percent,\n 'phrase' => $phrase);\n $details[] = get_string('explanationtargetphrase', $plugin, $a);\n }\n\n if (empty($details) && $currentresponse->count) {\n $a = (object)array('count' => $currentresponse->count,\n 'itemtype' => $itemtype);\n $details[] = get_string('explanationnotenough', $plugin, $a);\n }\n\n if ($details = implode(')<br /> + (', $details)) {\n\n $maxgrade = $qa->format_max_mark($precision);\n\n $step = $qa->get_last_step_with_behaviour_var('finish');\n if ($step->get_id()) {\n $rawgrade = format_float($step->get_fraction() * $maxgrade, $precision);\n } else {\n $rawgrade = $qa->format_mark($precision);\n }\n $rawpercent = $currentresponse->rawpercent;\n\n $autopercent = $currentresponse->autopercent;\n $autograde = format_float($currentresponse->autofraction * $maxgrade, $precision);\n\n if ($trypenalty = $question->penalty) {\n // A \"try\" is actually a click of the \"Check\" button\n // in \"interactive\" mode with a less-than-perfect response.\n // A \"Check\" of a correct response does not count as a \"try\".\n $trycount = $qa->get_step(0)->get_behaviour_var('_triesleft');\n $trycount -= $qa->get_last_behaviour_var('_triesleft');\n $penalty = max(0, $trypenalty * $trycount);\n } else {\n $trypenalty = 0;\n $trycount = 0;\n $penalty = 0;\n }\n\n if ($penalty) {\n $penaltygrade = format_float($penalty * $maxgrade, $precision);\n $penaltypercent = ($penalty * 100);\n if (fmod($penaltypercent, 1)==0) {\n $penaltypercent = intval($penaltypercent);\n } else {\n $penaltypercent = format_float($penaltypercent, $precision);\n }\n $penaltytext = $penaltypercent.'%';\n if ($trycount > 1) {\n $trypenaltypercent = ($trypenalty * 100);\n if (fmod($trypenaltypercent, 1)==0) {\n $trypenaltypercent = intval($trypenaltypercent);\n } else {\n $trypenaltypercent = format_float($trypenaltypercent, $precision);\n }\n $penaltytext .= ' = ('.$trycount.' x '.$trypenaltypercent.'%)';\n }\n } else {\n $penaltytext = '';\n $penaltygrade = 0;\n $penaltypercent = 0;\n }\n\n $finalgrade = max(0.0, $autograde - $penaltygrade);\n $finalpercent = max(0, $autopercent - $penaltypercent);\n\n // numeric values used by explanation strings\n $a = (object)array('maxgrade' => $maxgrade,\n 'rawpercent' => $rawpercent,\n 'autopercent' => $autopercent,\n 'penaltytext' => $penaltytext,\n 'finalgrade' => $finalgrade,\n 'finalpercent' => $finalpercent,\n 'details' => $details);\n\n $output .= html_writer::tag('h5', get_string('gradecalculation', $plugin));\n $output .= html_writer::tag('p', get_string('explanationmaxgrade', $plugin, $a));\n $output .= html_writer::tag('p', get_string('explanationrawpercent', $plugin, $a));\n if ($rawpercent != $autopercent) {\n $output .= html_writer::tag('p', get_string('explanationautopercent', $plugin, $a));\n }\n if ($penalty) {\n $output .= html_writer::tag('p', get_string('explanationpenalty', $plugin, $a));\n }\n $output .= html_writer::tag('p', get_string('explanationgrade', $plugin, $a));\n\n // add details of most recent manual override, if any\n $step = $qa->get_last_step_with_behaviour_var('mark');\n if ($step->get_id()) {\n $a = (object)array(\n 'datetime' => userdate($step->get_timecreated(), get_string('explanationdatetime', $plugin)),\n 'manualgrade' => format_float($step->get_behaviour_var('mark'), $precision),\n );\n $output .= html_writer::tag('p', get_string('explanationoverride', $plugin, $a));\n\n // add manual override details\n $details = array();\n\n // add manual comment, if any\n $comment = $step->get_behaviour_var('comment');\n $commentformat = $step->get_behaviour_var('commentformat');\n $commentoptions = (object)array('noclean' => true, 'para' => false);\n if (is_null($comment)) {\n list($comment, $commentformat) = $qa->get_manual_comment();\n }\n if ($comment = format_text($comment, $commentformat, $commentoptions)) {\n $comment = shorten_text(html_to_text($comment), 80);\n $comment = html_writer::tag('i', $comment);\n $header = get_string('comment', 'quiz');\n $details[] = html_writer::tag('b', $header.': ').$comment;\n }\n\n // add manual grader (user who manually graded the essay) info, if available\n //if ($grader = $step->get_user_id()) {\n // if ($grader = $DB->get_record('user', array('id' => $grader))) {\n // $grader = fullname($grader);\n // $header = get_string('grader', 'gradereport_history');\n // $details[] = html_writer::tag('b', $header.': ').$grader;\n // }\n //}\n\n if (count($details)) {\n $output .= html_writer::alist($details);\n }\n }\n }\n }\n\n // show grade bands, if required\n if ($showgradebands) {\n $details = array();\n $i = 1; // grade band index\n foreach ($currentresponse->bands as $count => $percent) {\n $detail = get_string('gradeband', $plugin);\n $detail = str_replace('{no}', $i++, $detail);\n $details[] = html_writer::tag('dt', $detail);\n $detail = get_string('bandcount', $plugin).' '.$count.' '.\n get_string('bandpercent', $plugin).' '.\n get_string('percentofquestiongrade', $plugin, $percent);\n $details[] = html_writer::tag('dd', $detail);\n }\n $output .= html_writer::tag('h5', get_string('gradebands', $plugin));\n $output .= html_writer::tag('dl', implode('', $details), array('class' => 'gradebands'));\n }\n\n // show target phrases, if required\n if ($show[$question->showtargetphrases] && count($currentresponse->phrases)) {\n $details = array();\n foreach ($currentresponse->phrases as $match => $percent) {\n $details[] = get_string('phrasematch', $plugin).' \"'.$match.'\" '.\n get_string('phrasepercent', $plugin).' '.\n get_string('percentofquestiongrade', $plugin, $percent);\n }\n $output .= html_writer::tag('h5', get_string('targetphrases', $plugin));\n $output .= html_writer::alist($details);\n }\n }\n\n if ($feedback = $this->combined_feedback($qa)) {\n $output .= html_writer::tag('h5', get_string('generalfeedback', 'question'));\n $output .= html_writer::tag('p', $feedback);\n }\n\n return $output;\n }", "title": "" }, { "docid": "bb33b8bb69bc454dbadfbe6158de7ab4", "score": "0.4869267", "text": "function get_ratings()\n{\n\treturn 'G|PG|PG13|NC17|NR|R|TV14|E|T|M|KA';\n}", "title": "" }, { "docid": "484921f49dd24ea06989dc9f7740562c", "score": "0.48414528", "text": "public function getFeedbackLevel() {\n\t\t$vigorous_met = $this->calculateVigorousMET();\n\t\t$moderate_met = $this->calculateModerateMET();\n\t\t$walking_met = $this->calculateWalkingMET();\n\t\t$total_days = $this->data['ExerciseScreener']['vigorous_days'] + $this->data['ExerciseScreener']['moderate_days'] + $this->data['ExerciseScreener']['walking_days'];\n\t\t$total_met = $vigorous_met + $moderate_met + $walking_met;\n\t\t\n\t\tif(($this->data['ExerciseScreener']['vigorous_days'] >= 3) && ($vigorous_met >= 1500)) {\n\t\t\treturn \"HIGH\";\n\t\t} elseif (($total_days > 7) && ($total_met >= 3000)) {\n\t\t\treturn \"HIGH\";\n\t\t} elseif (($this->data['ExerciseScreener']['vigorous_days'] >= 3) && ($this->data['ExerciseScreener']['vigorous_mins'] >= 20)) {\n\t\t\treturn \"MODERATE\";\n\t\t} elseif ((($this->data['ExerciseScreener']['moderate_days'] + $this->data['ExerciseScreener']['walking_days']) >= 5)\n\t\t\t\t&& (($this->data['ExerciseScreener']['moderate_mins'] + $this->data['ExerciseScreener']['walking_mins']) >= 30)) {\n\t\t\treturn \"MODERATE\";\n\t\t} elseif (($total_days >= 5) && ($total_met >= 600)) {\n\t\t\treturn \"MODERATE\";\n\t\t}\n\t\t\n\t\treturn \"LOW\";\n\t\t\n\t}", "title": "" }, { "docid": "801bedc8b9b9c26196afab1e544d8581", "score": "0.48215774", "text": "function wpars_rating_text_replace($post_id, $rate_text){\n\tglobal $template_no_rate;\n\t$out_put = '';\n\t$get_rating_info = wpars_get_rating_info($post_id);\n\t//$rate_text = stripslashes($rate_text);\n\tif ($get_rating_info['raters'] == 0 ){\n\t\t$out_put .= $template_no_rate;\n\t} else {\n\t\t$rate_text = str_replace(\"{total_raters}\", $get_rating_info['raters'], $rate_text);\n\t\t$rate_text = str_replace(\"{rate_average}\", $get_rating_info['average'], $rate_text);\n\t\t$rate_text = str_replace(\"{max_rates}\", $get_rating_info['max_rates'], $rate_text);\n\t\t$rate_text = str_replace(\"{rate_percent}\", $get_rating_info['percent'], $rate_text);\n\t\t$rate_text = str_replace(\"{total_scores}\", $get_rating_info['scores'], $rate_text);\n\t\t$out_put .= $rate_text;\n\t}\n\treturn $out_put;\n}", "title": "" }, { "docid": "ac757b0c8020e14d3e58e464307a30ea", "score": "0.48130167", "text": "public function getTextRise()\n {\n }", "title": "" }, { "docid": "6f817efb0275664b771b2ec29d57a4a6", "score": "0.4788358", "text": "function showTransductiveSuggestion($mysqli){\n\t$labels = $_SESSION['fDoc'][$_SESSION['curDocID']];\n\tarsort($labels);\n\t$rankedLabels = array_keys ($labels);\n\t$_SESSION['lblOptionRank'] = $rankedLabels;\n\tshowSuggestedLabel(array_shift($rankedLabels)); //Removes first option(best rank) from array and show it\n\tshowOtherLabels($rankedLabels); \n}", "title": "" }, { "docid": "14742ad30bd5b0594ddc222c206a9fe9", "score": "0.47771496", "text": "function include_vote_text()\n{\n $objSrcUser = &$GLOBALS[\"objSrcUser\"];\n $iSrcVote = $objSrcUser->get_stat(VOTE);\n $objSrcAlli = $objSrcUser->get_alliance();\n $arrUserIds = $objSrcAlli->get_userids();\n\n // M: Show advisor text\n $strAdvisorText =\n '<div id=\"textMedium\" style=\"margin-top: 0;\">' .\n '<p>' .\n \"Please vote for whom you think should be the elder and control your alliance.\" .\n '</p>' .\n '</div><br />';\n echo $strAdvisorText;\n\n // M: Populate arrVotes - this array contains information about all voters\n $objTmpUser = new clsUser(1);\n foreach ($arrUserIds as $iUserId)\n {\n $objTmpUser->set_userid($iUserId);\n\n $arrVotes[$iUserId][\"tribename\"] = $objTmpUser->get_stat(TRIBE);\n $arrVotes[$iUserId][\"playertype\"] = $objTmpUser->get_stat(TYPE);\n $arrVotes[$iUserId][\"votes\"] = 0;\n $arrVotes[$iUserId][\"votefor\"] = '';\n }\n\n // M: Count their votes (also verify that they voted for an alliance member)\n $iValidVotes = 0;\n foreach ($arrUserIds as $iUserId)\n {\n $objTmpUser->set_userid($iUserId);\n $iTmpVote = $objTmpUser->get_stat(VOTE);\n if ($iTmpVote > 0 && in_array($iTmpVote, $arrUserIds))\n {\n $iValidVotes++;\n $arrVotes[$iTmpVote][\"votes\"]++;\n $arrVotes[$iUserId][\"votefor\"] = stripslashes($arrVotes[$iTmpVote][\"tribename\"]);\n }\n }\n\n // M: Create table rows for each tribe\n $strTableRows = '';\n foreach ($arrUserIds as $iUserId)\n {\n $objTmpUser->set_userid($iUserId);\n $arrTmpStats = $objTmpUser->get_stats();\n $strTmpTribe = stripslashes($arrTmpStats[TRIBE]);\n\n // M: Fetch information about this tribe's votes\n $strVoted = stripslashes($arrVotes[$iUserId][\"votefor\"]);\n $strType = $arrVotes[$iUserId][\"playertype\"];\n $iVotes = $arrVotes[$iUserId][\"votes\"];\n\n if ($iSrcVote == $iUserId) $strChecked = \" checked\";\n else $strChecked = \"\";\n\n // M: Column for elder to elect co-elder\n $strCoelderTD = '';\n if ($objSrcUser->get_stat(TYPE) == 'elder')\n {\n if ($strType == \"coelder\") $strChecked2 = \" checked\";\n else $strChecked2 = \"\";\n\n $strCoelderTD =\n '<td>' .\n '<input type=\"checkbox\" name=\"voteforcoelder[]\" value=\"' .\n $iUserId . '\"' . $strChecked2 . \" />\" .\n \"</td>\";\n }\n\n $strTableRows .=\n '<tr class=\"data\">' .\n\n '<th>' .\n '<label>' .\n '<input type=\"radio\" name=\"votefor\" value=\"' . $iUserId . '\"' .\n $strChecked . ' /> <span class=\"' . $strType . '\">' .\n $strTmpTribe . '</span></label>' .\n '</th>' .\n\n '<td class=\"left\">' .\n floor($iVotes / max(1, $iValidVotes) * 100) . '%' .\n '</td>' .\n\n '<td class=\"left\">' . $strVoted . '</td>' .\n\n $strCoelderTD .\n\n \"</tr>\";\n }\n\n // M: Vote for donkey (default)\n if ($iSrcVote == '' || $iSrcVote == 0) $strChecked = \" checked\";\n else $strChecked = '';\n\n // M: Extra column for elder to elect co-elders\n if ($objSrcUser->get_stat(TYPE) == 'elder')\n {\n $iColumns = '4';\n $strThCoelder = \"<th class=\\\"center\\\">\" . \"Co-elder\" . \"</td>\";\n }\n else\n {\n $iColumns = '3';\n $strThCoelder = '';\n }\n\n // M: \"Elect your elder\"-table\n $strElderTable =\n \"<form method=\\\"post\\\" action=\\\"main.php?cat=game&amp;page=vote2\\\" id=\\\"center\\\">\" .\n \"<table cellspacing=\\\"0\\\" cellpadding=\\\"0\\\" class=\\\"medium\\\">\" .\n\n \"<tr class=\\\"header\\\">\" .\n \"<th colspan=\\\"\" . $iColumns . \"\\\">\" . \"Elect Your Elder\" . \"</th>\" .\n \"</tr>\" .\n\n \"<tr class=\\\"subheader\\\">\" .\n \"<th>\" . \"Tribe\" . \"</th>\" .\n \"<th>\" . \"Votes\" . \"</th>\" .\n \"<th>\" . \"Voted For\" . \"</th>\" .\n $strThCoelder .\n \"</tr>\" .\n\n $strTableRows .\n\n \"<tr class=\\\"data\\\">\" .\n '<th class=\"bsup\" colspan=\"' . $iColumns . '\">' .\n \"<input type=\\\"radio\\\" name=\\\"votefor\\\" value=\\\"0\\\" id=\\\"0\\\"\" . $strChecked . \" /> \" .\n \"<label for=\\\"0\\\">\" . \"No Vote\" . \"</label>\" .\n \"</th>\" .\n \"</tr>\" .\n\n \"</table><br />\" .\n\n \"<input type=\\\"submit\\\" value=\\\"Vote\\\" />\" .\n \"</form>\";\n echo $strElderTable;\n}", "title": "" }, { "docid": "26f0be8909248a8d3d0bb8d11b90faa0", "score": "0.47571555", "text": "public function detectRickLevel($risk_level){\n $strResult = \"\";\n \tswitch ($risk_level) {\n \t case 3:\n \t $strResult = \"High\"; \n \t break;\n \t case 2:\n \t \t$strResult = \"Medium\";\n \t \tbreak;\n \t case 1:\n \t \t$strResult = \"Low\";\n \t \tbreak;\n \t default:\n \t $strResult = \"Issue\";\n \t break;\n \t}\n \treturn $strResult;\n }", "title": "" }, { "docid": "20872c825ff34240b7a81958756ea4c8", "score": "0.47406974", "text": "function showTechRatingInput($n)\n {\n echo '<option value=\"\">Rate Technical Skill &num;' . $n . '</option>';\n echo '<option value=\"5: Expert\">5: Expert </option>';\n echo '<option value=\"4: Advanced\">4: Advanced </option>';\n echo '<option value=\"3: Intermediate\">3: Intermediate </option>';\n echo '<option value=\"2: Basic\">2: Basic </option>';\n echo '<option value=\"1: Beginner\">1: Beginner </option>';\n }", "title": "" }, { "docid": "3bcc591b43b6d566ba113ecec5744fed", "score": "0.47354737", "text": "function givelinktoo_vs_Otext($text)\n{\n $x = explode('-',$text);\n\t$x = array_map('trim',$x);\n\t$dicts = explode(':',$x[1]);\n\t$words = explode(':',$x[0]);\n\t\n\tfor ($j=0;$j<count($dicts);$j++)\n\t{\n\t\t$culpritdict=explode(',',$dicts[$j]);\n\t\tfor ($i=0;$i<count($culpritdict);$i++){\n\t\t$d[$i]=$culpritdict[$i];\n\t\t$y[$i] = Cologne_hrefyear($d[$i]); \n\t\t$rep[$i] = '<a href=\"'.\"http://www.sanskrit-lexicon.uni-koeln.de/scans/\".$d[$i].\"Scan/\".$y[$i].\"/web/webtc/indexcaller.php\".'?key='.$words[$j].'&input=slp1&output=SktDevaUnicode\" target=\"_blank\">'.$d[$i].\"</a>\"; // Keeping direct href because buttons fail to open in multiple tabs. They refresh the page.\n\t\t$culpritdict[$i] = str_replace($d[$i],$rep[$i],$culpritdict[$i]);\n\t\t}\n\t\t$dicts[$j]=implode(',',$culpritdict);\n\t}\n//\techo convert($words[0]).\" : \".convert($words[1]).\" - \".$words[0].\" : \".$words[1].\" - \".$dicts[0].\" : \".$dicts[1].\"<br/>\";\n\treturn convert($words[0]).\" : \".convert($words[1]).\" - \".$words[0].\" : \".$words[1].\" - \".$dicts[0].\" : \".$dicts[1];\n//\techo $words[0].\":\".$words[1].\"-\".$dicts[0].\":\".$dicts[1].\"<br/>\";\n}", "title": "" }, { "docid": "0bbb39e92213eafd81de70eba38e0725", "score": "0.47298446", "text": "public static function levelToText(int $level) {\r\n return (isset(self::LEVELS[$level])?self::LEVELS[$level]:\"Inconnu\");\r\n }", "title": "" }, { "docid": "d54ae90d95b99ea48b4471f628b2b466", "score": "0.4728628", "text": "public function score(): string\n {\n if ($this->hasWinner()) {\n return 'Winner: ' . $this->leader();\n }\n\n if ($this->hasAdvantage()) {\n return 'Advantage: ' . $this->leader();\n }\n\n if ($this->isDeuce()) {\n return 'deuce';\n }\n\n return sprintf(\n '%s-%s',\n $this->pointsToTerm($this->playerOne->getPoints()),\n $this->pointsToTerm($this->playerTwo->getPoints()),\n );\n }", "title": "" }, { "docid": "55fc73d34b60457b0ab8552b7d31eb53", "score": "0.47171113", "text": "function level2string(int $level) {\n\t\tswitch($level){\n\t\t\tcase 0: return \"Easy\";\n\t\t\tcase 1: return \"Hard\";\n\t\t\tcase 2: return \"Medium\";\n\t\t\tdefault: return \"Unknown\";\n\t\t}\n\t\treturn \"Unknown\";\n\t}", "title": "" }, { "docid": "4ba13a5c50ed565bb586dd4da080b3e5", "score": "0.47073868", "text": "public function specific_grade_detail_feedback(question_attempt $qa): string {\n $gradingtype = '';\n $gradedetails = '';\n $scoredetails = '';\n\n // Decide if we should show grade explanation for \"partial\" or \"wrong\" states.\n // This should detect \"^graded(partial|wrong)$\" and possibly others.\n if ($step = $qa->get_last_step()) {\n $show = preg_match('/(partial|wrong)$/', $step->get_state());\n } else {\n $show = false;\n }\n\n // If required, add explanation of grade calculation.\n if ($show) {\n\n $plugin = 'qtype_ordering';\n $question = $qa->get_question();\n\n // Show grading details if they are required.\n if ($question->options->showgrading) {\n\n // Fetch grading type.\n $gradingtype = $question->options->gradingtype;\n $gradingtype = qtype_ordering_question::get_grading_types($gradingtype);\n\n // Format grading type, e.g. Grading type: Relative to next item, excluding last item.\n if ($gradingtype) {\n $gradingtype = get_string('gradingtype', $plugin).': '.$gradingtype;\n $gradingtype = html_writer::tag('p', $gradingtype, array('class' => 'gradingtype'));\n }\n\n // Fetch grade details and score details.\n if ($currentresponse = $question->currentresponse) {\n\n $totalscore = 0;\n $totalmaxscore = 0;\n\n $sortableitem = $question->get_ordering_layoutclass();\n $params = array('class' => $sortableitem);\n\n $scoredetails .= html_writer::tag('p', get_string('scoredetails', $plugin));\n $scoredetails .= html_writer::start_tag('ol', array('class' => 'scoredetails'));\n\n // Format scoredetails, e.g. 1 /2 = 50%, for each item.\n foreach ($currentresponse as $position => $answerid) {\n if (array_key_exists($answerid, $question->answers)) {\n $answer = $question->answers[$answerid];\n $score = $this->get_ordering_item_score($question, $position, $answerid);\n list($score, $maxscore, $fraction, $percent, $class, $img) = $score;\n if ($maxscore === null) {\n $score = get_string('noscore', $plugin);\n } else {\n $totalscore += $score;\n $totalmaxscore += $maxscore;\n $score = \"$score / $maxscore = $percent%\";\n }\n $scoredetails .= html_writer::tag('li', $score, $params);\n }\n }\n\n $scoredetails .= html_writer::end_tag('ol');\n\n if ($totalmaxscore == 0) {\n $scoredetails = ''; // ALL_OR_NOTHING.\n } else {\n // Format gradedetails, e.g. 4 /6 = 67%.\n if ($totalscore == 0) {\n $gradedetails = 0;\n } else {\n $gradedetails = round(100 * $totalscore / $totalmaxscore, 0);\n }\n $gradedetails = \"$totalscore / $totalmaxscore = $gradedetails%\";\n $gradedetails = get_string('gradedetails', $plugin).': '.$gradedetails;\n $gradedetails = html_writer::tag('p', $gradedetails, array('class' => 'gradedetails'));\n }\n }\n }\n }\n\n return $gradingtype.$gradedetails.$scoredetails;\n }", "title": "" }, { "docid": "ce8ceeafdad2e1945f0859adaff48b00", "score": "0.4702988", "text": "public function get_accessibility_text() {\n return ['sr-only' => get_string('course_sr-only', 'block_featured_links', !empty($this->course->fullname) ? $this->course->fullname : '')];\n }", "title": "" }, { "docid": "9b1ee084982aeb0adfcebc9f4528de25", "score": "0.46817333", "text": "function recommendationEngine($con,$keywords){\n $probability=[];\n foreach ($keywords as $key => $value) {\n $query=\"select specialization from recommendation where keywords like '%$value%'\";\n $result= mysqli_query($con, $query);\n if($result){\n $data = $result->fetch_array();\n\n if($data['specialization']!=''){\n if(!isset($probability[$data['specialization']])) \n $probability[$data['specialization']]=1;\n else\n $probability[$data['specialization']]++;\n }\n }\n }\n //return doctor type with greatest probability \n if($probability){\n return array_keys($probability, max($probability));\n }else return \"false\";\n}", "title": "" }, { "docid": "807baccc2589720e96b9b9de1eb2f267", "score": "0.46817246", "text": "function _text_to_summarize (&$obj)\n {\n return $obj->description . ' ' . $obj->ingredients . ' ' . $obj->instructions;\n }", "title": "" }, { "docid": "13b1d87006e8fce92578f13e1869a5c0", "score": "0.46771196", "text": "function getQuestionTypeInText(){\r\n\t\t$this->type = $this->getQuestionType();\r\n\t\tswitch($this->type){\r\n\t\t\tcase \"1\": $typeInTxt = \"Open text\"; break;\r\n\t\t\tcase \"2\": $typeInTxt = \"Open number\"; break;\r\n\t\t\tcase \"3\": $typeInTxt = \"Sound\"; break;\r\n\t\t\tcase \"4\": $typeInTxt = \"Multiple choice\"; break;\r\n\t\t\tcase \"5\": $typeInTxt = \"Super\"; break;\r\n\t\t\tcase \"6\": $typeInTxt = \"Comment\"; break;\r\n\t\t\tcase \"7\": $typeInTxt = \"Photo\"; break;\r\n\t\t\tcase \"8\": $typeInTxt = \"Video\"; break;\r\n\t\t\tcase \"9\": $typeInTxt = \"Slider\"; break;\r\n\t\t\tcase \"10\": $typeInTxt = \"Multiple answer\"; break;\r\n\t\t}\r\n\t\tif(isset($typeInTxt)){\r\n\t\t\treturn $typeInTxt;\r\n\t\t}else{\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "165996637fb33bfc4e8f829b4dcecafc", "score": "0.4675686", "text": "function getRecommendation($explorationid, $uid, $cid, $tid) {\n\t$db = new DB_Sql;\n\t$db->connect();\n\n$sql2 = '\nselect c.general_title cname,ld.idconcept cid,ld.idtopic tid,ld.idunit uid\nfrom compass_mt.LOGDATA ld\nleft join compass_mt.CONCEPT c\non c.idconcept=ld.idconcept\nwhere ld.idexploration=\"' . $explorationid . '\" order by ld.time;\n';\n\n$result = $db->query($sql2);\nif (!$result) {\n\treturn '';\n}\n\nwhile ($row = mysql_fetch_assoc($result)) {\n\t$c = $row['cid'];\n\tif ($c != null) {\n\t\t$input_array[] = $c;\n\t}\n}\n\n$input_array[] = $cid; # the current concept might not be updated in database yet.\n\nif (count($input_array) <= 1) {\n\treturn '';\n}\n\n#\t$concepts = mysql_real_escape_string($_GET['concepts']);\n\n#\tif ($concepts == null) {\n#\t\theader(\"location:/compass/error_code.php?code=006\"); \n#\t}\n#\t$input_array = split(',', $concepts);\n\t# remove consecutive duplicates\n\t$last_a = '';\n\tforeach ($input_array as $a) {\n\t\tif ($a != $last_a && $a != '') {\n\t\t\t$array[] = $a;\n\t\t\t$last_a = $a;\t\t\t\n\t\t}\n\t}\n\n\n\t$array_size = count($array);\n\n\t# if there are more than 4 concepts, use the first few to prune the clusters\n\t# that is, form a table with only those clusters that could have generated the concepts\n\tif ($array_size <= 4) {\n\t\t$table_name = 'compass_mt.cluster_probabilities c';\n\t} else {\n\t\t$table_name = \n\t\t\t'(\n\t\t\tselect t1.* from compass_mt.cluster_probabilities t1 \n\t\t\tinner join\n\t\t\t(\n\t\t\t\tselect cluster_num, sum(c.probability) as prob\n\t\t\t\tFROM compass_mt.cluster_probabilities c\n\t\t\t\twhere c.concept2=' . $array[$array_size - 3];\n\t\tif ($array_size >= 4) {\n\t\t\t$table_name = $table_name . ' or c.concept2= ' . $array[$array_size - 4];\n\t\t}\n\t\tif ($array_size >= 5) {\n\t\t\t$table_name = $table_name . ' or c.concept2= ' . $array[$array_size - 5];\n\t\t}\n\n\t\t$table_name = $table_name . ' group by c.cluster_num\n\t\t\torder by prob desc\n\t\t\t\tlimit 25\n\t\t\t) t2\n\t\t\twhere t1.cluster_num = t2.cluster_num\n\t\t) c';\n\t}\n\n\t$full_query = ' select q.concept, p.name, q.prob from \n\t\t(select co.idconcept, co.general_title as name from compass_mt.concept co) p\n\t\tinner join (';\n\t$get_concepts_query = '\n\t\tselect c.concept, c.prob from\n\t\t(\t\t\n\t\tselect c.concept2 as concept, sum(c.probability) as prob\tfrom '\n\t\t. $table_name . \n\t\t' where (c.concept1 = ' . $array[$array_size - 1] . ' or c.concept1=' . $array[$array_size - 2] . ')';\n\n\t# exclude already clicked concepts from results\n\tfor ($i=0; $i<$array_size; $i++) {\n\t\t$get_concepts_query = $get_concepts_query . ' and (c.concept2 != ' . $array[$i] . ') ';\n\t}\n\n\t$get_concepts_query = $get_concepts_query . ' group by c.concept2 ) c \n\t\tinner join \n\t(SELECT c3.idconcept as idconcept FROM compass_mt.conceptintopic c3 where idtopic = ' . $tid . ') z\n\twhere z.idconcept = c.concept\n\torder by c.prob desc limit 3 ';\t\n\n\t$full_query = $full_query . $get_concepts_query . ') q where p.idconcept=q.concept;';\n\t\n\t$sql = $full_query;\n\t$result = $db->query($sql);\n\n\tif (!$result) {\n\t\treturn '';\n\t\texit;\n\t}\n\n#\techo '<br/>';\n#\techo $full_query;\n#\techo '<br/>';\n\n\t$num_rows = mysql_num_rows($result);\n\n\tif ($num_rows == 0) {\n\t\treturn '';\n\t\texit;\n\t}\n\t\n\t$output = '<div style=\"font-size:small;float:right;border:1px solid darkgreen;\n\tbackground-color: lightgreen;width:100px; padding-left:2px;\">\n\t\t<b>You may find these interesting:</b>\n\t\t';\n\twhile ($row = mysql_fetch_assoc($result)) {\n\t\t$output = $output .\n\t\t\t'<a style=\"text-transform:capitalize\" \n\t\t\tonClick=\"window.parent.document.mapApplet.shareddata.setMap(' . $uid . ', ' . $tid . ', ' . $row['concept'] . ',2);\"\n\t\t\t href=\"#\">' . $row['name'] . '</a><br/>';\n\t} \n\t$output = $output . '</div>';\n\n\tmysql_free_result($result);\n\n\treturn $output;\n}", "title": "" }, { "docid": "658f132bb2d7483f1549e84c9efb9fd8", "score": "0.467127", "text": "public function getText()\n {\n return $this->random(static::$values['texts']);\n }", "title": "" }, { "docid": "7fae0308d11ef81906ed96f59c03e77d", "score": "0.46712175", "text": "function show_score($score, $weight, $show_percentage = true, $use_platform_settings = true) {\n if (is_null($score) && is_null($weight)) {\n return '-';\n }\n $html = '';\n $score_rounded = $score; \n $max_note = api_get_setting('exercise_max_score');\n $min_note = api_get_setting('exercise_min_score');\n \n if ($use_platform_settings) {\n if ($max_note != '' && $min_note != '') { \n if (!empty($weight) && intval($weight) != 0) {\n \t $score = $min_note + ($max_note - $min_note) * $score /$weight;\n } else {\n $score = $min_note;\n } \n $weight = $max_note;\n }\n } \n $score_rounded = float_format($score, 1); \n $weight = float_format($weight, 1); \n if ($show_percentage) { \n $parent = '(' . $score_rounded . ' / ' . $weight . ')';\n $html = float_format(($score / ($weight != 0 ? $weight : 1)) * 100, 1) . \"% $parent\";\t\n } else { \n \t$html = $score_rounded . ' / ' . $weight;\n } \n return $html;\t\n}", "title": "" }, { "docid": "f909e5a4a6353deca65713be8d06a2ad", "score": "0.46598393", "text": "protected function getText($code)\r\n {\r\n $code = (int)$code;\r\n $rand = mt_rand(min(1, $code - 1), max(1, $code - 1));\r\n $operation = mt_rand(0, count($this->operations) - 1);\r\n\r\n switch($this->operations[$operation]) {\r\n case '+': return ($code - $rand).' + '.$rand;\r\n case '-': return ($code + $rand).' - '.$rand;\r\n case '*':\r\n $sign = mt_rand(0, 1); // operation sign for subexpression\r\n $whole = (int)($code / $rand);\r\n switch ($sign) {\r\n case 0: // plus\r\n $reminder = $code % $rand;\r\n break;\r\n case 1: // minus\r\n $whole++;\r\n $reminder = $whole * $rand - $code;\r\n }\r\n $str = $whole.' * '.$rand;\r\n if ($reminder) $str .= ($sign == 1 ? ' - ' : ' + ').$reminder;\r\n return $str;\r\n }\r\n }", "title": "" }, { "docid": "c60ddd25101d6e946ed26911010e6503", "score": "0.46568885", "text": "private function getIncreaseDecreaseText(ApplicationOperatingCentre $aoc)\n {\n $loc = $this->getLicenceOperatingCentre($aoc);\n if ($loc === null) {\n return null;\n }\n\n if ($aoc->getNoOfVehiclesRequired() > $loc->getNoOfVehiclesRequired()) {\n return self::INCREASE;\n }\n if ($aoc->getNoOfVehiclesRequired() < $loc->getNoOfVehiclesRequired()) {\n return self::DECREASE;\n }\n if ($aoc->getNoOfTrailersRequired() > $loc->getNoOfTrailersRequired()) {\n return self::INCREASE;\n }\n if ($aoc->getNoOfTrailersRequired() < $loc->getNoOfTrailersRequired()) {\n return self::DECREASE;\n }\n\n return null;\n }", "title": "" }, { "docid": "83f54c29adb5bde4bab1b0e8537443ed", "score": "0.46431598", "text": "public function getExhibition(): string\n {\n return $this->exhibition;\n }", "title": "" }, { "docid": "afb6530401e59743d52551c075c5b7b2", "score": "0.46213087", "text": "public function getAudioText()\n {\n $content = $this->getAudioFileContent();\n\n # set string as audio content\n $audio = (new RecognitionAudio())->setContent($content);\n\n # The audio file's encoding, sample rate and language\n $config = new RecognitionConfig([\n 'encoding' => AudioEncoding::LINEAR16,\n 'sample_rate_hertz' => 48000,\n 'language_code' => 'en-US',\n 'alternative_language_codes' => ['es','fr','zh']\n ]);\n\n # Instantiates a client\n $client = new SpeechClient();\n\n # Detects speech in the audio file\n $response = $client->recognize($config, $audio);\n \n # Print most likely transcription\n foreach ($response->getResults() as $result) {\n $alternatives = $result->getAlternatives();\n $mostLikely = $alternatives[0];\n $text = $mostLikely->getTranscript();\n $client->close();\n $this->deleteAudio();\n return $text;\n }\n\n $client->close();\n $this->deleteAudio();\n\n return '-';\n }", "title": "" }, { "docid": "4263d0ea7603b7c297b5a36e2a03cb1d", "score": "0.46003017", "text": "public static function getYesNoText($int = null) {\n if ($int === null)\n return \"N/A\";\n if ($int == 0)\n return \"No\";\n if ($int == 1)\n return \"Yes\";\n return '?';\n }", "title": "" }, { "docid": "767d88c7ff1282725a82964c70f8ce2a", "score": "0.4599392", "text": "public function getQuestion(int $index): string\n {\n $data = $this->getQuestionList();\n\n return $data[$index][self::QUESTION];\n }", "title": "" }, { "docid": "605bd37f80519d828f7bebd52adaef21", "score": "0.45750868", "text": "function pro_experts_title_text( $title ){\n $screen = get_current_screen();\n \n if ( 'pro-expert-review' == $screen->post_type ) {\n $title = 'Client Name';\n }\n\n if ( 'pro-experts' == $screen->post_type ) {\n $title = 'Professional Expert Name';\n }\n \n return $title;\n}", "title": "" }, { "docid": "b1a1c161b41197316ff28f27a0deb6ec", "score": "0.45704222", "text": "private function getInterestFreeText($interestFree)\n {\n return ($interestFree === true) ? 'sem' : 'com';\n }", "title": "" }, { "docid": "2a60e4ceed44b2c956a00f435cb640d8", "score": "0.45694172", "text": "public function getProvidedReviewText()\n {\n return $this->review->getText();\n }", "title": "" }, { "docid": "9e1a62aeb945551712bcb97a674fdb10", "score": "0.45693907", "text": "function getAgency($code) {\r\n $agencyCodeArray = explode(\"+\", $code);\r\n $agencyTextArray = array();\r\n foreach($agencyCodeArray as $agencyCode) {\r\n $aText = $this->getAgencySingle($agencyCode);\r\n array_push($agencyTextArray, $aText);\r\n }\r\n \r\n $agencyText = \"\";\r\n foreach($agencyTextArray as $i => $agency) {\r\n $agencyText = $agencyText . $agency;\r\n if($i < count($agencyTextArray)-1) $agencyText = $agencyText . \", \";\r\n }\r\n\r\n return $agencyText;\r\n\t}", "title": "" }, { "docid": "828c9b0d0c032ca682c7b77eaaab9e69", "score": "0.45586982", "text": "public function getRebatesText()\n {\n $value = $this->get(self::rebates_text);\n return $value === null ? (string)$value : $value;\n }", "title": "" }, { "docid": "27a9c41c0977ea1dfee6bd26f2d51b36", "score": "0.4558603", "text": "protected function getAction(Approval $model)\n {\n # no change\n if(is_null($model->is_approved)) return 'NoChange';\n\n # Approved\n if($model->is_approved == 1) return 'Approved';\n\n # NotApproved\n return 'NotApproved';\n }", "title": "" }, { "docid": "580e6a927bdd4fa6a07419451e0aed62", "score": "0.45436403", "text": "function getTypeText(){\n\t\t$text = '--';\n\t\tif(!isEmptyString($this->getInputID())){\n\t\t\tif(!isEmptyString($this->getType())){\n\t\t\t\t$alltypes = getAllInputTypes();\n\t\t\t\t$text = $alltypes[$this->getType()];\n\t\t\t}\n\t\t} else {\n\t\t\tif(!isEmptyString($this->getType())){\n\t\t\t\t$alltypes = getAllExpenseTypes();\n\t\t\t\t$text = $alltypes[$this->getType()];\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $text;\n\t}", "title": "" }, { "docid": "8e331740f890b90d9e4996de838ef66f", "score": "0.45398903", "text": "public function getAvancement()\n {\n return $this->avancement;\n }", "title": "" }, { "docid": "f22e72f83c6b368654fb88bc9faa4080", "score": "0.45370734", "text": "public function getImportanceString() {\n switch($this->importance) {\n case self::IMPORTANCE_BLOCKER:\treturn \"blocker\";\n case self::IMPORTANCE_CRITICAL:\treturn \"critical\";\n case self::IMPORTANCE_MAJOR:\treturn \"major\";\n case self::IMPORTANCE_NORMAL:\treturn \"normal\";\n case self::IMPORTANCE_MINOR:\treturn \"minor\";\n\t\t\tcase self::IMPORTANCE_TRIVIAL:\treturn \"trivial\";\n }\n }", "title": "" }, { "docid": "cc598933e53cf06025575eba295772a9", "score": "0.4520932", "text": "function getHand($value) {\n\n switch ($value) {\n case 'LH':\n $text = \"มือซ้าย\";\n Return $text;\n break;\n case 'RH':\n $text = \"มือขวา\";\n Return $text;\n break;\n default:\n $text = \"ทั้งสองข้าง\"; Return $text; }\n}", "title": "" }, { "docid": "5b2ae40b94cff3ec04d66cb7f7e48472", "score": "0.4520852", "text": "private function _getClassVoteItemText($category, $star)\n {\n \t$result = '';\n\n $aryContent = array(1 => 'もの足りない', 2 => '少し物足りない', 3 => '普通', 4 => '充実している', 5 => 'かなり充実');\n $aryDifficult = array(1 => 'かなり難しい', 2 => '難しい', 3 => '普通', 4 => '余裕', 5 => 'かなり余裕');\n $aryWork = array(1 => 'ほぼ無し', 2 => '少なめ', 3 => '普通', 4 => 'ちょっと多め', 5 => '宿題多すぎ');\n $aryTest = array(1 => '超難関', 2 => '厳しい', 3 => '普通', 4 => '優しい', 5 => '超簡単');\n $aryAttend = array(1 => 'かなり厳しい', 2 => '厳しい', 3 => '普通', 4 => '優しい', 5 => 'ほぼ出欠なし');\n\n if ('vote_content' == $category) {\n $result = $aryContent[$star];\n }\n else if ('vote_difficult' == $category) {\n $result = $aryDifficult[$star];\n }\n else if ('vote_work' == $category) {\n $result = $aryWork[$star];\n }\n else if ('vote_test' == $category) {\n $result = $aryTest[$star];\n }\n else if ('vote_attend' == $category) {\n $result = $aryAttend[$star];\n }\n\n return $result;\n }", "title": "" }, { "docid": "79a9f2967ef45b28ab42d2fa309b1e41", "score": "0.45157498", "text": "function explain()\r\n {\r\n global $sampleTable;\r\n \r\n $base = new SRUFromMysqlBase();\r\n \r\n $db = $base->db_connect();\r\n if ($db instanceof SRUDiagnostics) {\r\n \\ACDH\\FCSSRU\\diagnostics($db);\r\n return;\r\n }\r\n \r\n $maps = array();\r\n \r\n if (stripos($sampleTable, \"sampletext\") !== false) {\r\n array_push($maps, array(\r\n 'title' => 'VICAV Profile Sample Text',\r\n 'name' => 'sampleText',\r\n 'search' => 'true',\r\n 'scan' => 'true',\r\n 'sort' => 'false',\r\n ));\r\n } else if (stripos($sampleTable, \"lingfeatures\") !== false) {\r\n array_push($maps, array(\r\n 'title' => 'VICAV Linguistic Features Samples',\r\n 'name' => 'lingfeature',\r\n 'search' => 'true',\r\n 'scan' => 'true',\r\n 'sort' => 'false',\r\n ));\r\n }\r\n \r\n array_push($maps, array(\r\n 'title' => 'Resource Fragement PID',\r\n 'name' => 'rfpid',\r\n 'search' => 'true',\r\n 'scan' => 'true',\r\n 'sort' => 'false',\r\n ));\r\n \r\n $base->populateExplainResult($db, \"$sampleTable\", \"$sampleTable\", $maps);\r\n }", "title": "" }, { "docid": "b3ecb5222d086ed902d471b1a034fd84", "score": "0.45114303", "text": "function fit_score($fitLevel){\r\n\t\tswitch($fitLevel){\r\n\t\tcase ($fitLevel==\"לא מתאמן\"):\r\n\t\treturn 0.2;\r\n\t\tbreak;\r\n\t\tcase ($fitLevel==\"מתאמן פעם בשבוע\"):\r\n\t\treturn 0.4;\r\n\t\tbreak;\r\n\t\tcase ($fitLevel==\"מתאמן פעמיים בשבוע\"):\r\n\t\treturn 0.6;\r\n\t\tbreak;\r\n\t\tcase ($fitLevel==\"מתאמן 3-4 פעמים בשבוע\"):\r\n\t\treturn 0.8;\r\n\t\tbreak;\r\n\t\tcase ($fitLevel==\"מתאמן מעל 4 פעמים בשבוע\"):\r\n\t\treturn 1;\r\n\t\tbreak;\r\n}\r\n\t\t}", "title": "" }, { "docid": "b87edcae6b9500639c6bbde78ae86abf", "score": "0.45053986", "text": "function pmprovat_pmpro_level_cost_text($r, $level, $tags, $short)\r\n{\t\r\n\tif(isset($_REQUEST['self_identify']))\r\n\t\t$self_identify = $_REQUEST['self_identify'];\r\n\telse\r\n\t\t$self_identify = 0;\r\n\t\r\n\tif(isset($_REQUEST['bcountry']))\r\n\t\t$bcountry = $_REQUEST['bcountry'];\r\n\telse\r\n\t\t$bcountry = 0;\r\n\t\r\n\tglobal $already_run, $country_from_ip, $pmpro_vat_by_country, $pmpro_european_union, $pmpro_pages, $post;\r\n\tif(!is_array($already_run))\r\n\t\t$already_run = array();\r\n\t\r\n\tif(!isset($already_run[$level->id]) && !is_admin())\r\n\t{\r\n\t\t$already_run = array();\r\n\t\r\n\t\t$country_from_ip = pmprovat_determine_country_from_ip();\r\n\t\r\n\t\t//we are in the EU\r\n\t\tif($country_from_ip && array_key_exists($country_from_ip, $pmpro_european_union))\r\n\t\t{\t\r\n\t\t\t$vat_rate = $pmpro_vat_by_country[$country_from_ip];\r\n\t\t\t\r\n\t\t\tif($self_identify == 1)\r\n\t\t\t\t$vat_rate = $pmpro_vat_by_country[$bcountry];\r\n\t\t\r\n\t\t\tif(!empty($vat_rate))\r\n\t\t\t{\r\n\t\t\t\t$level = pmprovat_pmpro_apply_vat_to_level($level, $vat_rate);\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t$already_run[$level->id] = true;\r\n\t\t\r\n\t\tif($pmpro_pages['checkout'] == $post->ID)\r\n\t\t\treturn '<span id = \"reg_price\">'.$r.'</span><span id = \"vat_price\">'.pmpro_getLevelCost($level, $tags, $short).'</span>';\r\n\t\telse return pmpro_getLevelCost($level, $tags, $short);\r\n\t}\r\n\t\r\n\telse\r\n\t{\r\n\t\treturn $r;\r\n\t}\r\n}", "title": "" }, { "docid": "661b58226a98fe5a5ca9cec4d3fb00a5", "score": "0.44987246", "text": "public function header_bookrating() {\n return get_string('bookrating', 'mod_reader');\n }", "title": "" }, { "docid": "84e4d1d0cde316e6310f3792790d2c79", "score": "0.4494004", "text": "public function getStudentIsLivingWith($data) {\n if($data === 3){\n return 'Guardian';\n } elseif ($data === 2) {\n return 'Mother';\n } elseif ($data === 1) {\n return 'Father';\n } else {\n return 'Both';\n }\n }", "title": "" }, { "docid": "4dc55211200be3e9951ff16a9ed9930d", "score": "0.44877452", "text": "function performance($value){\n\t\t$smallest = min($value);\n\n\t\tif($smallest<5){\n\t\t\treturn \"poor\";\n\t\t}\n\t\telseif($smallest==5){\n\t\t\treturn \"average\";\n\t\t}\n\t\telseif ($smallest>=6 and $smallest<8) {\n\t\t\treturn \"good\";\n\t\t}\n\t\telseif ($smallest>=8) {\n\t\t\treturn \"excellent\";\n\t\t}\n\t}", "title": "" }, { "docid": "4399f8de20387655281900d481dac11e", "score": "0.44827273", "text": "function access_level_get_string( $p_access_level ) {\n\tif( $p_access_level > ANYBODY ) {\n\t\t$t_access_level_string = get_enum_element( 'access_levels', $p_access_level );\n\t} else {\n\t\t$t_access_level_string = lang_get( 'no_access' );\n\t}\n\treturn $t_access_level_string;\n}", "title": "" }, { "docid": "cda307e76d1ed003284e51d064a643ad", "score": "0.44797677", "text": "public function resultRangeText() {\r\n\t\t\tif($this->total_records == 0) {\r\n\t\t\t\treturn 'No results found';\r\n\t\t\t}\r\n\t\t\tif($this->total_records == 1) {\r\n\t\t\t\treturn 'Displaying the only result';\r\n\t\t\t}\r\n\t\t\treturn sprintf('Currently displaying <strong>%d - %d</strong> of <strong>%d</strong> results',\r\n\t\t\t\t$this->start_record,\r\n\t\t\t\t$this->end_record,\r\n\t\t\t\t$this->total_records);\r\n\t\t}", "title": "" }, { "docid": "4d4e2199aea0f8d8dd2f03893471fd02", "score": "0.44788152", "text": "public function getText(): string\n {\n return trans('activities.' . $this->type);\n }", "title": "" }, { "docid": "bd83f850db5b521e3466b92a909116a1", "score": "0.44751117", "text": "public function vocative()\n {\n switch ($this->lastTwo) {\n case 'da':\n case 'sa':\n return $this->changeLast('o', 1);\n case 'ca':\n return $this->changeLast('e', 1);\n case 'ar':\n return $this->changeLast('re', 2);\n }\n\n switch ($this->lastOne) {\n case 'n':\n case 't':\n case 'v':\n case 'r':\n case 's':\n return $this->changeLast('e');\n case 'g':\n return $this->changeLast('že', 1);\n case 'k':\n return $this->changeLast('če', 1);\n default:\n return $this->word;\n }\n }", "title": "" }, { "docid": "67e013e80328fd9093940bf691d77a06", "score": "0.44667765", "text": "public function getRarityWord()\n {\n\n return $this->rarity_word;\n }", "title": "" }, { "docid": "8f0e57ed195f12f1c5a3316edf287f55", "score": "0.44599074", "text": "function get_treatment() {\n $treatment = null;\n \n switch(rand(0,3)) {\n case 0:\n $treatment = 'control';\n break;\n case 1:\n $treatment = 'staticText';\n break;\n case 2:\n $treatment = 'dynamicText';\n break;\n case 3:\n $treatment = 'strengthMeter';\n break;\n }\n \n return $treatment;\n}", "title": "" }, { "docid": "4ec432e376583b541e2f9756feab183b", "score": "0.44598547", "text": "public function suggestion(): string\n {\n return $this->suggestion;\n }", "title": "" }, { "docid": "d8b72fbaaba20a5ed348357552af1e2d", "score": "0.44506058", "text": "private function _prettyTempAdj($temp)\n\t{\n\t\t# Just like we do with the templates, we'll probabily have a dictionary of terms available for each range\n\n\t\tif ($temp >= 90)\n\t\t\treturn \"bloody hot\";\n\t\telseif ($temp >= 80)\n\t\t\treturn \"warm\";\n\t\telseif ($temp >= 70)\n\t\t\treturn \"nice and cozy\";\n\t\telseif ($temp >= 60)\n\t\t\treturn \"cool\";\n\t\telseif ($temp >= 50)\n\t\t\treturn \"chilly\";\n\t\telseif ($temp >= 40)\n\t\t\treturn \"cold\";\n\t\telseif ($temp >= 30)\n\t\t\treturn \"freezing\";\n\t\telse\n\t\t\treturn \"freakin' cold\";\n\t}", "title": "" }, { "docid": "a87c75511942dbed4a3efd1829ea90dc", "score": "0.4447393", "text": "function excel_format_reproducibility( \\Core\\BugData $p_bug ) {\n\t\treturn excel_prepare_string( \\Core\\Helper::get_enum_element( 'reproducibility', $p_bug->reproducibility, \\Core\\Auth::get_current_user_id(), $p_bug->project_id ) );\n\t}", "title": "" }, { "docid": "c767d04edbf06d47c707aee6b9b165f5", "score": "0.44435945", "text": "private function getAtkModifier($att_total,$def_total) {\n \t\t$pct_str=($att_total*100/$def_total)-100;\n\t\t\t\t\n\t\t\t\t//defense and offense bonus capped at 50% and -50%\n\t\t\t\tif ($pct_str > 50)\n\t\t\t\t\t$pct_str=50;\n\t\t\t\telse if ($pct_str < -50)\n\t\t\t\t\t$pct_str = -50;\n\t\t\t\t\t\n\t\t\t\treturn $pct_str;\n }", "title": "" }, { "docid": "95cc183426db2a9e17928eed9e3c85b5", "score": "0.44423327", "text": "private function getAlertRuleDescriptionString($rule)\n {\n if ($rule == Alert::$EQUAL_TO) {\n return \"equal to\";\n }\n if ($rule == Alert::$GREATER_THAN) {\n return \"greater than\";\n }\n if ($rule == ALert::$LESS_THAN) {\n return \"less than\";\n }\n return $rule;\n }", "title": "" }, { "docid": "347e3e223a20b15d1f7017091e43502f", "score": "0.44398057", "text": "function fulltext($arg) {\r\n\t\t$x = $arg;\r\n\t\tswitch ($arg) {\r\n\t\t\tcase 'HEA':\r\n\t\t\t\t $x = \" HEALTH\";\r\n\t\t\t\tbreak;\r\n\t\t\tcase 'SOC':\r\n\t\t\t\t $x = \" SOCIAL\";\r\n\t\t\t\tbreak;\r\n\t\t\tcase 'POL':\r\n\t\t\t\t $x = \" POLITICAL\";\r\n\t\t\t\tbreak;\r\n\t\t\tcase 'BUS':\r\n\t\t\t\t $x = \" BUSINESS\";\r\n\t\t\t\tbreak;\r\n\t\t\tcase 'YOU':\r\n\t\t\t\t $x = \" YOUTH\";\r\n\t\t\t\tbreak;\r\n\t\t\tcase 'LEG':\r\n\t\t\t\t $x = \" LEGAL\";\r\n\t\t\t\tbreak;\r\n\t\t\tcase 'EDU':\r\n\t\t\t\t $x = \" EDUCATIONAL\";\r\n\t\t\t\tbreak;\r\n\t\t\tcase 'PAS':\r\n\t\t\t\t $x = \" PASTORAL\";\r\n\t\t\t\tbreak;\t\t\t\r\n\t\t\tcase 'EVE':\r\n\t\t\t\t $x = \" SOCIAL & COMMUNITY EVENTS\";\r\n\t\t\t\tbreak;\t\t\t\r\n\t\t\tdefault:\r\n\t\t\t\techo \"No specific segment was chosen\";\r\n\t\t}\r\n\r\n\t\treturn ($x);\r\n\t\t}", "title": "" }, { "docid": "b2e45993b8d447dc48789111d9e9b6f0", "score": "0.44299024", "text": "public function step5CustomTitle()\n\t{\n\t\t$limit = isset( \\IPS\\Request::i()->extra ) ? \\IPS\\Request::i()->extra : 0;\n\n\t\tif( !isset( $_SESSION['_step5Count'] ) )\n\t\t{\n\t\t\t$_SESSION['_step5Count'] = \\IPS\\Db::i()->select( 'COUNT(*)', 'nexus_reviews', 'review_votes>0' )->first();\n\t\t}\n\n\t\treturn \"Upgrading commerce review ratings (Upgraded so far: \" . ( ( $limit > $_SESSION['_step5Count'] ) ? $_SESSION['_step5Count'] : $limit ) . ' out of ' . $_SESSION['_step5Count'] . ')';\n\t}", "title": "" }, { "docid": "dfc72bc8e21203b01e5351387eafab19", "score": "0.44293678", "text": "private function __normalisePrefer()\n {\n\n $prefer = strtolower($this->input->get_post(\"prefer\"));\n\n //value to get\n switch ($prefer) {\n case \"max\":\n case \"min\";\n case \"mean\":\n break;\n default:\n $prefer = \"\";\n }\n\n return $prefer;\n }", "title": "" }, { "docid": "3215b26063227ea1bd0abab8287e8ab5", "score": "0.442567", "text": "function save_impr_text_data($textid, $line, $val): string\n{\n global $tbpref;\n $success = \"NOTOK\";\n $ann = get_first_value(\n \"SELECT TxAnnotatedText AS value \n FROM \" . $tbpref . \"texts \n WHERE TxID = \" . $textid\n );\n $items = preg_split('/[\\n]/u', $ann);\n if (count($items) >= $line) {\n $vals = preg_split('/[\\t]/u', $items[$line-1]);\n if ($vals[0] > -1 && count($vals) == 4) {\n $vals[3] = $val;\n $items[$line-1] = implode(\"\\t\", $vals);\n runsql(\n 'UPDATE ' . $tbpref . 'texts \n SET TxAnnotatedText = ' . convert_string_to_sqlsyntax(implode(\"\\n\", $items)) . ' \n WHERE TxID = ' . $textid, \"\"\n );\n $success = \"OK\";\n }\n }\n return $success;\n}", "title": "" }, { "docid": "592c8a79af2b2e8e27b94fd28cce055b", "score": "0.4423778", "text": "public function getQualification($staffID, $levelID ){\r\n\t\t\treturn $this->tifb_module->getEmpQuaificaton( $staffID, $levelID );\t\r\n\t\t}", "title": "" }, { "docid": "9bd7056aa0bcf2144e16c1157246205d", "score": "0.44232047", "text": "function String_Evaluation($lettr) {\r\n\t\t//check input letter and return its roman value, or if not in alphabet, \r\n\t\t//return -1 to signify invalidity.\r\n\t\tif ($lettr == 'I') {\r\n\t\t\treturn 1;\r\n\t\t}\r\n\t\tif ($lettr == 'V') {\r\n\t\t\treturn 5;\r\n\t\t}\r\n\t\tif ($lettr == 'X') {\r\n\t\t\treturn 10;\r\n\t\t}\r\n\t\tif ($lettr == 'L') {\r\n\t\t\treturn 50;\r\n\t\t}\r\n\t\tif ($lettr == 'C') {\r\n\t\t\treturn 100;\r\n\t\t}\r\n\t\tif ($lettr == 'D') {\r\n\t\t\treturn 500;\r\n\t\t}\r\n\t\tif ($lettr == 'M') {\r\n\t\t\treturn 1000;\r\n\t\t}\r\n\t\treturn -1; //invalid input: not in Roman Numeral form\r\n\t}", "title": "" }, { "docid": "dde8ca1fd8e73c19abbada59907f80d1", "score": "0.44228396", "text": "public function religion()\n {\n if($this->religionName)\n {\n return $this->religionName->name;\n }\n else\n {\n return \"Religion Unspecified\";\n }\n }", "title": "" }, { "docid": "79c559571942715c5a82dbbb9d18cf7b", "score": "0.44185933", "text": "public function getText() {\n $text = '<p>' . $this->t('You are accessing a U.S. Government information system, which includes: (1) this computer, (2) this computer network, (3) all computers connected to this network, and (4) all devices and storage media attached to this network or to a computer on this network. This information system is provided for U.S. Government-authorized use only. Unauthorized or improper use of this system may result in disciplinary action, and civil and criminal penalties.') . '</p>';\n $text .= '<p>' . $this->t('By logging in to this information system you are acknowledging that you understand and consent to the following:') . '<br>';\n $text .= t('- You have no reasonable expectation of privacy regarding any communications transmitted through or data stored on this information system. At any time, the government may monitor, intercept, search and/or seize data transiting or stored on this information system.') . '<br>';\n $text .= t('- Any communications transmitted through or data stored on this information system may be disclosed or used for any U.S. Government-authorized purpose.') . '</p>';\n $text .= '<p>' . $this->t('For further information see the Department order on Use and Monitoring of Department Computers and Computer Systems.') . '</p>';\n\n return $text;\n }", "title": "" }, { "docid": "8b6f5403f05476edea64ede05fff93b0", "score": "0.44146875", "text": "public function getReviewedTitle(): string {\n // TODO:\n return \"\";\n }", "title": "" }, { "docid": "b48dc2ab6c08c45977d808c55349d8e4", "score": "0.44094396", "text": "public function getStatus()\n {\n if ($this->githubApi->getRepos() >= 5 && $this->githubApi->getRepos() <= 10) {\n return \"Yeah, I crown you Senior Evangelist. Thanks for making the world a better place\";\n } elseif ($this->githubApi->getRepos() >=11 && $this->githubApi->getRepos() <= 20) {\n return \"Keep Up The Good Work, I crown you Associate Evangelist\";\n } elseif ($this->githubApi->getRepos() >= 21) {\n return \"Damn It!!! Please make the world better, Oh Ye Prodigal Junior Evangelist\";\n } else {\n return \"You don't qualify to be called an evangelist....whatsoever\";\n }\n }", "title": "" }, { "docid": "efd500aeed8a2bcbfd91dce944a48eb3", "score": "0.44008195", "text": "function exp_type_score($Exp_type){\r\n\t\tswitch($Exp_type){\r\n\t\tcase ($Exp_type==\"מתחיל\"):\r\n\t\treturn 0.2;\r\n\t\tbreak;\r\n\t\tcase ($Exp_type==\"חובבןŸ\"):\r\n\t\treturn 0.4;\r\n\t\tbreak;\r\n\t\tcase ($Exp_type==\"נערים-נוער\"):\r\n\t\treturn 0.6;\r\n\t\tbreak;\r\n\t\tcase ($Exp_type==\"בוגרים - עד ליגה א'\"):\r\n\t\treturn 0.8;\r\n\t\tbreak;\r\n\t\tcase ($Exp_type==\"בוגרים - ליגות גבוהות\"):\r\n\t\treturn 1;\r\n\t\tbreak;\r\n\r\n\t\t\r\n}\r\n\t\t}", "title": "" }, { "docid": "07e85a7486fcb801aa9fca4640d73f86", "score": "0.4398862", "text": "function convert_score($score, $weight) {\n $max_note = api_get_setting('exercise_max_score');\n $min_note = api_get_setting('exercise_min_score'); \n \n if ($score != '' && $weight != '') { \n if ($max_note != '' && $min_note != '') { \n if (!empty($weight)) { \n $score = $min_note + ($max_note - $min_note) * $score / $weight;\n } else {\n $score = $min_note;\n } \n } \n } \n $score_rounded = float_format($score, 1); \n return $score_rounded;\n}", "title": "" }, { "docid": "349b31d2a0a5e90c8a2ba913d06ccb34", "score": "0.43942258", "text": "public static function getAvailabilityText($availability)\r\n {\r\n switch ($availability) {\r\n case '1':\r\n return 'В наличии';\r\n break;\r\n case '0':\r\n return 'Под заказ';\r\n break;\r\n }\r\n }", "title": "" }, { "docid": "272b05ab572ce8f4b4ee0f646a38cddb", "score": "0.43894532", "text": "public function getRecruitment(): string\n {\n return $this->recruitment;\n }", "title": "" }, { "docid": "2364cef13a25b1a3ed3d6ef65f01a240", "score": "0.43881717", "text": "public function getBenefit();", "title": "" }, { "docid": "f4c3e376e5aa1e180603c7459f097309", "score": "0.4383263", "text": "public function getStatusTextAttribute()\n {\n switch ($this->status) {\n case 0:\n return 'Canceled';\n break;\n case 1:\n return 'Unmatched';\n break;\n case 2:\n return 'Partially Matched';\n break;\n case 3:\n return 'Fully Matched';\n break;\n case 4:\n return 'Fully Paid';\n break;\n case 5:\n return 'Unfrozen';\n break;\n \n default:\n return 'Unknown';\n break;\n }\n }", "title": "" }, { "docid": "35c993f2deb68def65e2f84605289ec4", "score": "0.4380209", "text": "public function getAnno() {\n\t\treturn $this->anno;\n\t}", "title": "" }, { "docid": "75168c551d6b6f327cf939d42eea8282", "score": "0.43781817", "text": "function getLoydesc( $qKey )\n {\n global $link;\n global $mp_script;\n #\n # read mp_loyalty_codes on passed desc and return key\n #\n $Qquery = \"SELECT * FROM mp_loyalty_code WHERE mpLdesc = '$qKey'\";\n $Qresult=mysqli_query($link, $Qquery)\n or die( \"$mp_script getLoydesc - cannot read loyalty codes on description\" );\n #\n # read results of query and return\n #\n while ($Qrow = mysqli_fetch_array($Qresult) )\n {\n $qualstr = $Qrow[ \"mpLid\" ];\n }\n #\n # return\n #\n mysqli_free_result($Qresult);\n return $qualstr;\n }", "title": "" } ]
5f1fce81e74cefb856d872a3003f3519
/ acf_delete_metadata This function will delete a value from the DB
[ { "docid": "7f1d256bf0314bcb4666f9932b7dec51", "score": "0.69084793", "text": "function acf_delete_metadata( $post_id = 0, $name = '', $hidden = false ) {\n\t\n\t// vars\n\t$return = false;\n\t$prefix = $hidden ? '_' : '';\n\t\n\t\n\t// get post_id info\n\t$info = acf_get_post_id_info($post_id);\n\t\n\t\n\t// bail early if no $post_id (acf_form - new_post)\n\tif( !$info['id'] ) return $return;\n\t\n\t\n\t// option\n\tif( $info['type'] === 'option' ) {\n\t\t\n\t\t$name = $prefix . $post_id . '_' . $name;\n\t\t$return = delete_option( $name );\n\t\t\n\t// meta\n\t} else {\n\t\t\n\t\t$name = $prefix . $name;\n\t\t$return = delete_metadata( $info['type'], $info['id'], $name );\n\t\t\n\t}\n\t\n\t\n\t// return\n\treturn $return;\n\t\n}", "title": "" } ]
[ { "docid": "a12ad8faebe157c9a07bb5968530cb93", "score": "0.7497628", "text": "function delete_value($post_id, $meta_key, $field)\n {\n }", "title": "" }, { "docid": "2f7e43ace96d133565648cadfa17c1cb", "score": "0.7409799", "text": "function acf_delete_metadata($post_id = 0, $name = '', $hidden = \\false)\n{\n}", "title": "" }, { "docid": "4943a213d51a903f6c7e59120b0696ca", "score": "0.73502535", "text": "function acf_delete_value($post_id, $field)\n{\n}", "title": "" }, { "docid": "8d6484750efc129dcd1c4761fae553f0", "score": "0.7039541", "text": "function delete_value($post_id, $key, $field)\n {\n }", "title": "" }, { "docid": "770d6b001e462ce430b088320ffb811d", "score": "0.7001041", "text": "function acf_delete_value( $post_id = 0, $field ) {\n\t\n\t/**\n\t* Fires before a value is deleted.\n\t*\n\t* @date\t28/09/13\n\t* @since\t5.0.0\n\t*\n\t* @param\tstring $post_id The post ID for this value.\n\t* @param\tmixed $name The meta name.\n\t* @param\tarray $field The field array.\n\t*/\n\tdo_action( \"acf/delete_value/type={$field['type']}\",\t$post_id, $field['name'], $field );\n\tdo_action( \"acf/delete_value/name={$field['_name']}\",\t$post_id, $field['name'], $field );\n\tdo_action( \"acf/delete_value/key={$field['key']}\",\t\t$post_id, $field['name'], $field );\n\tdo_action( \"acf/delete_value\",\t\t\t\t\t\t\t$post_id, $field['name'], $field );\n\t\n\t\n\t// delete value\n\t$return = acf_delete_metadata( $post_id, $field['name'] );\n\t\n\t\n\t// delete reference\n\tacf_delete_metadata( $post_id, $field['name'], true );\n\t\n\t\n\t// clear cache\n\tacf_delete_cache(\"get_value/post_id={$post_id}/name={$field['name']}\");\n\tacf_delete_cache(\"format_value/post_id={$post_id}/name={$field['name']}\");\n\t\n\t\n\t// return\n\treturn $return;\n\t\n}", "title": "" }, { "docid": "eb48756eee9e26abafcad216a56bf2a8", "score": "0.68631375", "text": "public function delete_meta( $key, $value = '' ) {\n\t\treturn delete_user_meta( $this->get_id(), $key, $value );\n\t}", "title": "" }, { "docid": "7e9f80273fad43307d689ab45050c946", "score": "0.67978734", "text": "function delete_value($name)\n{\n\t$GLOBALS['SITE_DB']->query_delete('values',array('the_name'=>$name),'',1);\n\tif (function_exists('persistant_cache_delete')) persistant_cache_delete('VALUES');\n}", "title": "" }, { "docid": "cddcc9853c9005e6da418aaf7f587891", "score": "0.6737087", "text": "public function deleteValue()\n {\n // this is not a common attribute.\n // Every form with a particular formtype uses the same value.\n // Therefore the value is only stored in the atPlainText table, the avID-entris in the AtttributeValues are just dummies\n }", "title": "" }, { "docid": "593dd0e95ea0ef003476d87b3a98ee2a", "score": "0.67023206", "text": "function delete_meta($args){\n\t\textract($args);\n\t\tif(isset($id)){\n\t\t\t$this->db->where('id', $id)->delete('sc_boat_meta');\n\t\t}elseif(isset($field) && isset($boat_id)){\n\t\t\t$this->db->where('boat_id', $boat_id)->where('field', $field)->delete('sc_boat_meta');\n\t\t}else{\n\t\t\treturn false;\n\t\t}\n\t}", "title": "" }, { "docid": "591938189643ae659ea5db283fd010cf", "score": "0.66032493", "text": "public function deletePostMetaData($data) {\n\t\t$this->db->query(\"DELETE FROM \" . DB_PREFIX . \"d_meta_data WHERE route = 'bm_post_id=\" . (int)$data['post_id'] . \"'\");\n\t}", "title": "" }, { "docid": "c6df6faa5ac4254c97193df31c857382", "score": "0.64810807", "text": "function wpsc_delete_visitor_meta( $visitor_id, $meta_key, $meta_value = '' ) {\n\n\tif ( ! _wpsc_visitor_database_ready() ) {\n\t\treturn false;\n\t}\n\n\t// Allow central validation (and possibly transformation) of visitor meta prior to it being saved\n\t$meta_key = _wpsc_validate_visitor_meta_key( $meta_key );\n\n\t$success = delete_metadata( 'wpsc_visitor', $visitor_id , $meta_key , $meta_value );\n\n\t// notification after any meta item has been deleted\n\tif ( $success && has_action( $action = 'wpsc_deleted_visitor_meta' ) ) {\n\t\tdo_action( $action, $meta_key, $visitor_id );\n\t}\n\n\t// notification after a specific meta item has been deleted\n\tif ( $success && has_action( $action = 'wpsc_deleted_visitor_meta_' . $meta_key ) ) {\n\t\tdo_action( $action, $meta_key, $visitor_id );\n\t}\n\n\treturn $success;\n}", "title": "" }, { "docid": "6d7c90e318a6589e2ea31b49fa911ef7", "score": "0.64796984", "text": "public function delete( $value ) {\n\n\t\t$sql = sprintf( 'DELETE FROM %s WHERE %s = %%s', $this->get_table(), static::$primary_key );\n\n\t\treturn self::$wp_db->query( self::$wp_db->prepare( $sql, $value ) );\n\t}", "title": "" }, { "docid": "fd9c24deac1854f6733d982f22fdd7df", "score": "0.6471445", "text": "public function delete_meta($id){\r\n\t\treturn $this->db->delete('meta', array('id' => $id)); \r\n\t}", "title": "" }, { "docid": "192c1b2fa00b17f376fda949adc8380d", "score": "0.64208174", "text": "function custom_field_destroy( $p_field_id ) {\n # delete all values\n $query = \"DELETE FROM `mantis_custom_field_string_table` WHERE field_id= $p_field_id;\";\n SqlWrapper::getInstance()->sql_query($query) or die(\"<span style='color:red'>Query FAILED: $query <br/>\".SqlWrapper::getInstance()->sql_error().\"</span>\");\n\n # delete all project associations\n $query = \"DELETE FROM `mantis_custom_field_project_table` WHERE field_id= $p_field_id;\";\n SqlWrapper::getInstance()->sql_query($query) or die(\"<span style='color:red'>Query FAILED: $query <br/>\".SqlWrapper::getInstance()->sql_error().\"</span>\");\n\n # delete the definition\n $query = \"DELETE FROM `mantis_custom_field_table` WHERE id= $p_field_id;\";\n SqlWrapper::getInstance()->sql_query($query) or die(\"<span style='color:red'>Query FAILED: $query <br/>\".SqlWrapper::getInstance()->sql_error().\"</span>\");\n\n #custom_field_clear_cache( $p_field_id );\n \n #echo \"DEBUG: customField $p_field_id removed</br>\";\n return true;\n}", "title": "" }, { "docid": "87068259c2de6d8c86565eb0897b2b87", "score": "0.6406385", "text": "function unsetMetadataValue($name);", "title": "" }, { "docid": "e3b0280c4ffe6bce655d98b394a76270", "score": "0.63154256", "text": "function hook_taxonomy_vocabulary_delete($vocabulary) {\n db_delete('mytable')\n ->condition('vid', $vocabulary->vid)\n ->execute();\n}", "title": "" }, { "docid": "d29a0ba00aed1692e282a554e4bc0383", "score": "0.6251556", "text": "function hrb_opened_dispute_delete_meta( $dispute, $workspace ) {\n\tdelete_post_meta( $workspace->ID, 'opened_dispute', $dispute->post_author );\n}", "title": "" }, { "docid": "7e53d243464dd7af6ac71c2c01c50f10", "score": "0.6234157", "text": "function delValue($value)\n {\n rex_valid_type($value, 'string', __FILE__, __LINE__);\n \n if ($this->hasValue($value))\n {\n unset ($this->values[$value]);\n }\n }", "title": "" }, { "docid": "867e274feea08762bfbeb31270316bc2", "score": "0.6124508", "text": "static function deleteFieldValue($a_field_id, $a_value)\n\t{\n\t\tglobal $ilDB;\n\n\t\t$ilDB->manipulate(\"UPDATE udf_text SET value = \".$ilDB->quote(\"\", \"text\").\" WHERE \"\n\t\t\t.\" field_id = \".$ilDB->quote($a_field_id, \"integer\")\n\t\t\t.\" AND value = \".$ilDB->quote($a_value, \"text\")\n\t\t\t);\n\t}", "title": "" }, { "docid": "4716d41c847c8d217ddedadc91c90495", "score": "0.61194384", "text": "function acf_delete_field($id = 0)\n{\n}", "title": "" }, { "docid": "c0ffda87c67f7333d9db030ba8668404", "score": "0.6118919", "text": "function wpse_83587_delete_image( $value, $post_id, $field ) {\n $old_value = get_field( $field['name'], $post_id, false );\n\n if ( $old_value && ( int ) $old_value !== ( int ) $value )\n wp_delete_attachment( $old_value, true );\n\n return $value;\n}", "title": "" }, { "docid": "9fb1523e7df9efa8d60a348bf08640fc", "score": "0.6090516", "text": "function deleteStoredObjectAttribute( $contentObjectAttribute, $version = null )\r\n {\r\n\t\t// contentObjectIDを取得\r\n $contentobject_id = intval( $contentObjectAttribute->attribute( \"contentobject_id\" ) );\r\n\t\t// contentObjectAttributeIDを取得\r\n\t\t$contentobject_attribute_id = intval( $contentObjectAttribute->attribute( \"id\" ) );\r\n // インスタンス作成\r\n $ez_kaltura_comm = new eZKalturaComm($contentobject_id, $contentobject_attribute_id);\r\n if ($ez_kaltura_comm->client) {\r\n // 削除を実行\r\n $ez_kaltura_comm->doDelete_DB_KalturaServer($contentobject_attribute_id, $version, true);\r\n }\r\n }", "title": "" }, { "docid": "d4da877b42b845c32c47b10d48970576", "score": "0.6084762", "text": "public function delete($value)\n {\n $id = $this->client->hget($this->idKey, $value);\n $this->clearPair($id, $value);\n }", "title": "" }, { "docid": "80beb0398e95b0cd3697521ac436a440", "score": "0.607358", "text": "public function unsetMetadataValue($name);", "title": "" }, { "docid": "471a2e51ea8c3d19339c935e1212b383", "score": "0.6042372", "text": "public function deleteCategoryMetaData($data) {\n\t\t$this->db->query(\"DELETE FROM \" . DB_PREFIX . \"d_meta_data WHERE route = 'bm_category_id=\" . (int)$data['category_id'] . \"'\");\n\t}", "title": "" }, { "docid": "05174fe5d7c5482f39f604e6e90b7af5", "score": "0.59860957", "text": "protected function afterDelete()\n {\n FilterValueStore::instance()->property->clear($this->obElement->slug);\n }", "title": "" }, { "docid": "cafd35dfde1dc3b0deb4c9a5c7c93475", "score": "0.59852475", "text": "public function delete(){\n\t\t\t$this->deleted = 1;\n\t\t\t$this->save();\n\t\t}", "title": "" }, { "docid": "da3060257d4b30e8c85a7f97fa2bb8f5", "score": "0.5940657", "text": "public function delete()\n {\n $this->deleteById($this->field['id']);\n }", "title": "" }, { "docid": "8ae53d40eff41464eeea9ddf24e972e9", "score": "0.59359515", "text": "public function execute()\n {\n global $wpdb;\n\n $wpdb->query(\n \"DELETE FROM $wpdb->postmeta\n\t\t WHERE meta_key LIKE '_quick_links%' \n\t\t OR meta_key LIKE '_content_tabs%' \n\t\t \"\n );\n }", "title": "" }, { "docid": "a0ddaa1fbce3348691b35b9b8b3fbb61", "score": "0.5930806", "text": "function custom_field_destroy( $p_field_id ) {\n\t\t$c_field_id = db_prepare_int( $p_field_id );\n\n\t\t# delete all values\n\t\t$t_custom_field_string_table = config_get( 'mantis_custom_field_string_table' );\n\t\t$query = \"DELETE FROM\n\t\t\t\t $t_custom_field_string_table\n\t\t\t\t WHERE field_id='$c_field_id'\";\n\t\tdb_query( $query );\n\n\t\t# delete all project associations\n\t\t$t_custom_field_project_table = config_get( 'mantis_custom_field_project_table' );\n\t\t$query = \"DELETE FROM\n\t\t\t\t $t_custom_field_project_table\n\t\t\t\t WHERE field_id='$c_field_id'\";\n\t\tdb_query( $query );\n\n\t\t$t_custom_field_table = config_get( 'mantis_custom_field_table' );\n\t\t# delete the definition\n\t\t$query = \"DELETE FROM\n\t\t\t\t $t_custom_field_table\n\t\t\t\t WHERE id='$c_field_id'\";\n\t\tdb_query( $query );\n\n\t\tcustom_field_clear_cache( $p_field_id );\n\n\t\t# db_query() errors on failure so:\n\t\treturn true;\n\t}", "title": "" }, { "docid": "8a1dd79c136da970715b1cedbd1305f5", "score": "0.5928916", "text": "function delete($key, $value){\n $this->db->where($key, $value);\n $this->db->delete($this->table);\n }", "title": "" }, { "docid": "cb761977bbf4787e1f0e4182bdaeeee1", "score": "0.5902812", "text": "function deleteAttributeValues()\n\t{\n\t\tforeach ($_POST['attributevalueCheck'] as $key => $value) {\n\n\t\t\t$sql = \"DELETE FROM attribute_value_table WHERE attrib_value_id='$value'\";\n\t\t\t$query = new Bin_Query();\n\t\t\t$query->updateQuery($sql);\n\n\t\t\t\n\t\t}\n\t\treturn '<div class=\"alert alert-success\">\n <button type=\"button\" class=\"close\" data-dismiss=\"alert\">×</button> Deleted Successfully</div>';\n\t}", "title": "" }, { "docid": "e9f4cf2335a807926c9e5d39607fc516", "score": "0.5901854", "text": "function deleteSetting($objectId, $metadataId) {\n\t\t$params = array((int) $objectId, (int) $metadataId);\n\t\t$sql = 'DELETE FROM object_for_review_settings WHERE object_id = ? AND review_object_metadata_id = ?';\n\t\treturn $this->update($sql, $params);\n\t}", "title": "" }, { "docid": "9b10ab094085d1d7a67e8e5fb8453731", "score": "0.58631706", "text": "public function delete() {\r\n $this->db->delete(\"object_query_\" . $this->model->getClassId(), $this->db->quoteInto(\"oo_id = ?\", $this->model->getId()));\r\n $this->db->delete(\"object_store_\" . $this->model->getClassId(), $this->db->quoteInto(\"oo_id = ?\", $this->model->getId()));\r\n $this->db->delete(\"object_relations_\" . $this->model->getClassId(), $this->db->quoteInto(\"src_id = ?\", $this->model->getId()));\r\n\r\n // delete fields wich have their own delete algorithm\r\n foreach ($this->model->getClass()->getFieldDefinitions() as $fd) {\r\n if (method_exists($fd, \"delete\")) {\r\n $fd->delete($this->model);\r\n }\r\n }\r\n\r\n parent::delete();\r\n }", "title": "" }, { "docid": "75780d24498694e8a0d63ce1c31ff621", "score": "0.5857443", "text": "function uvasom_term_meta_delete( $term_id, $tt_id ) {\n\t$term_meta = (array) get_option('uvasom-term-meta');\n\tunset( $term_meta[$term_id] );\n\tupdate_option('uvasom-term-meta', (array) $term_meta);\n}", "title": "" }, { "docid": "c3489c313dbe5e91b0ec99986ee0f7d2", "score": "0.5855051", "text": "public function deleteField ($fieldName) {}", "title": "" }, { "docid": "c3489c313dbe5e91b0ec99986ee0f7d2", "score": "0.5855051", "text": "public function deleteField ($fieldName) {}", "title": "" }, { "docid": "780378b613453b0cbd01d3f504f44254", "score": "0.5847691", "text": "public function delete($value)\n {\n $node = $this->search($value);\n if ($node) {\n $this->deleteByReference($node);\n }\n }", "title": "" }, { "docid": "a9288922a7ebf366d324eacd6e56b495", "score": "0.58353376", "text": "function delete() {\r\n\r\n\r\n // if the value is a root node throw an error\r\n /*if($this->parent_id == null) {\r\n $this->setError(JText::_('NO PARENT VALUE'));\r\n return false;\r\n }*/\r\n\r\n $dbo =& JFactory::getDBO();\r\n\r\n //if the value contains childrens throw an error\r\n $query = 'SELECT * FROM #__custom_properties_values\r\n WHERE parent_id = '.$this->id;\r\n\t$this->_db->setQuery($query);\r\n $results = $this->_db->loadObjectList();\r\n if (count($results) != 0) {\r\n $this->setError(JText::_('NODE NO LEAF'));\r\n return false;\r\n }\r\n\r\n\r\n // set the value's parent as the childs one\r\n /*$query = 'UPDATE '. $dbo->nameQuote('#__custom_properties_values') . ' v'\r\n .' SET '. $dbo->nameQuote('v.parent_id') .' = '. $this->parent_id\r\n .' WHERE '. $dbo->nameQuote('v.parent_id') .' = '. $this->id;\r\n\t$this->_db->setQuery($query);\r\n if($this->_db->query() === false) return false ;\r\n */\r\n\r\n // delete value AND records from customProperties\r\n $query = \"DELETE FROM #__custom_properties_values\r\n\t\t\tWHERE id = '\" . $this->id . \"'\" ;\r\n $this->_db->setQuery($query);\r\n if($this->_db->query() === false) return false ;\r\n\r\n // exterminate orphans\r\n $query = \"DELETE FROM #__custom_properties\r\n\t\t\tWHERE value_id = '\" . $this->id . \"'\";\r\n $this->_db->setQuery($query);\r\n if($this->_db->query() === false) return false ;\r\n\r\n return true;\r\n }", "title": "" }, { "docid": "ad5e70de2e59357addf0bab2d33abc9e", "score": "0.58321416", "text": "public function hookActionFeatureValueDelete($params)\n {\n $this->deletePicto($params['id_feature_value']);\n }", "title": "" }, { "docid": "90906c964c394082892dbd388e99cf57", "score": "0.5831357", "text": "public function delete( Field $field );", "title": "" }, { "docid": "2170096483e8aa37a92febfe25585db6", "score": "0.5829182", "text": "function cp_delete_ad_meta( $post_id ) {\n\tglobal $wpdb;\n\n\tif ( APP_POST_TYPE != get_post_type( $post_id ) ) {\n\t\treturn;\n\t}\n\n\t$attachments_query = $wpdb->prepare( \"SELECT ID FROM $wpdb->posts WHERE post_parent = %d AND post_type='attachment'\", $post_id );\n\t$attachments = $wpdb->get_results( $attachments_query );\n\n\t// delete all associated attachments\n\tif ( $attachments ) {\n\t\tforeach ( $attachments as $attachment ) {\n\t\t\twp_delete_attachment( $attachment->ID, true );\n\t\t}\n\t}\n\n}", "title": "" }, { "docid": "143b5ef78b6e47b5c397c94f77e52dcb", "score": "0.5828014", "text": "public function deleteSystemValue($key);", "title": "" }, { "docid": "51da3d759239517f8f234c256b00d481", "score": "0.58255553", "text": "public function removeMeta($key, $value = null)\n {\n return delete_comment_meta($this->getID(), $key, $value);\n }", "title": "" }, { "docid": "57fb01f21c25625f18b7b5c813837269", "score": "0.5797402", "text": "function Xsy_Sql_Delete($SQL_DATABASE, $SQL_TABLE, $field, $value){\n\n return Xsy_Sql_Query(\"DELETE FROM `\".$SQL_DATABASE.\"`.`\".$SQL_TABLE.\"` WHERE `\".$field.\"`='\".$value.\"'\");\n \n}", "title": "" }, { "docid": "ccc3561fd45c66e5331c85e06aa2c3d6", "score": "0.5796246", "text": "public function deleteMeta($key)\n {\n if (is_array($key)) {\n return $this->metas()->whereIn('key', $key)->delete();\n }\n\n return $this->metas()->where('key', $key)->delete();\n }", "title": "" }, { "docid": "99aacc9f08cdd2efa8b41447bcc77e32", "score": "0.5791904", "text": "public function deleteAuthorMetaData($data) {\n\t\t$this->db->query(\"DELETE FROM \" . DB_PREFIX . \"d_meta_data WHERE route = 'bm_author_id=\" . (int)$data['author_id'] . \"'\");\n\t}", "title": "" }, { "docid": "47bcef852f4609298b4d85e357733ea9", "score": "0.57835865", "text": "public function deleteField($fieldName) {}", "title": "" }, { "docid": "27eb5a2f61e4eab3ec0637a268813329", "score": "0.57713926", "text": "function delete_field($field)\n {\n }", "title": "" }, { "docid": "27eb5a2f61e4eab3ec0637a268813329", "score": "0.57713926", "text": "function delete_field($field)\n {\n }", "title": "" }, { "docid": "c75335893e38cbf441607fdb7f696e26", "score": "0.5763509", "text": "function hook_taxonomy_term_delete($term) {\n db_delete('mytable')\n ->condition('tid', $term->tid)\n ->execute();\n}", "title": "" }, { "docid": "9b63c966913c1401daf0b81c4b862c08", "score": "0.57529896", "text": "public function delete(){\n $db = Loader::db();\n $db->Execute(\"DELETE FROM MissGreekContestantAttributeValues WHERE contestantID = ?\", array($this->id));\n $db->Execute(\"DELETE FROM MissGreekContestantSearchIndexAttributes WHERE contestantID = ?\", array($this->id));\n $db->Execute(\"DELETE FROM {$this->tableName} WHERE id = ?\", array($this->id));\n }", "title": "" }, { "docid": "b046c3e4408efe179f3c8cbbede1357f", "score": "0.57477134", "text": "public function deleteValue(){\n\n $id = decoding($this->input->post('id'));\n $where = array('valueId'=>$id);\n $res = $this->common_model->deleteData(VALUE,$where);\n if($res){\n $response = 200; \n }else{\n $response = 400;\n }\n echo $response;\n\n }", "title": "" }, { "docid": "a33eadb171ac30365556e7587d48ffbe", "score": "0.5735984", "text": "public function delete(){\n\t\tif ($this->wf_name != NULL) {\n\t\t\tglobal $cDeleteWorkflow;\n\t\t\t$queryStr = $cDeleteWorkflow.\"('{$this->wf_name}')\";\n\t\t\trunScalarDbQuery($queryStr);\n\t\t}\n\t}", "title": "" }, { "docid": "0e909021123d7b6d52abb97a68f6c34d", "score": "0.5717832", "text": "public function delete(){\n if ($this->id()!='') {\n $this->deleteFiles();\n $query = 'DELETE FROM '.$this->tableName.'\n WHERE '.$this->primary.'=\"'.$this->id().'\"';\n Db::execute($query);\n $onDelete = (string)$this->info->info->sql->onDelete;\n if ($onDelete!='') {\n $onDeleteFields = explode(',', $onDelete);\n foreach ($onDeleteFields as $onDeleteField) {\n $onDeleteObject = new $onDeleteField;\n $listObjects = $onDeleteObject->readListObject(array('where'=>$this->primary.'=\"'.$this->id().'\"'));\n foreach ($listObjects as $listObject) {\n $listObject->delete();\n }\n }\n }\n }\n }", "title": "" }, { "docid": "1925f8bbe00ca44150f373db202446cf", "score": "0.5702038", "text": "public function delGalleryImgMeta($id, $key, $val) {\n\t\t$id \t= $this->DB->sanitize($id);\n\t\t$key \t= $this->DB->sanitize($key);\n\t\t$val\t= $this->DB->sanitize($val);\n\t\t$this->DB->query(\"DELETE FROM `gallery_meta` WHERE `gallery_id` = '$id' AND `meta_key` = '$key' and `meta_val` = '$val';\", false);\n\t}", "title": "" }, { "docid": "c4128c1a8997c05301dd30335a86be17", "score": "0.56965244", "text": "public function deleteCustomMetadataField($id=null)\n {\n if(!isset($id) || empty($id)){\n return Response::respond(true, ((object)ErrorMessages::$DELETE_CUSTOM_METADATA_ID_MISSING));\n }\n \n $this->httpClient->setUri(Endpoints::deleteCustomMetadataField($id));\n return Manage\\CustomMetadataFields::deleteCustomMetadataField($this->httpClient);\n }", "title": "" }, { "docid": "40661fdf049288dd20366616aad3d5ca", "score": "0.5695382", "text": "function acf_delete_json_field_group($key)\n{\n}", "title": "" }, { "docid": "07a03a54725b39fc82f1cb5c26f971b2", "score": "0.56900203", "text": "function delRow($table, $field_name, $field_value) {\n\t\t$sql = 'DELETE FROM ' . $table . ' WHERE ' . $field_name . '=' . $field_value;\n\t\treturn $this->execute($sql);\n\t}", "title": "" }, { "docid": "92ab6b03bf004824ea3bad97188fe100", "score": "0.56866544", "text": "public function DeleteFieldValue($row, $field, $name = false, $publish=false){\n\t\t\treturn $this->__processfieldvalue(3, $row, $field, $name, $publish);\t\t\t\n\t\t}", "title": "" }, { "docid": "6c7ee498a04047fc296adbf03f03bd54", "score": "0.5685341", "text": "function deleteByReviewObjectMetadataId($reviewObjectMetadataId) {\n\t\treturn $this->update(\n\t\t\t'DELETE FROM object_for_review_settings WHERE review_object_metadata_id = ?', (int) $reviewObjectMetadataId\n\t\t);\n\t}", "title": "" }, { "docid": "60d10828a3b39baa7351ed7e607e1d8b", "score": "0.5677034", "text": "function delete_actualisation($id)\n\t{\n\t\tdelete_gallery($id);\n\t}", "title": "" }, { "docid": "c541d4f89d3ce9c2e2c0f80f9fb1e16f", "score": "0.5675033", "text": "public function delete() {\n $this->db->delete(static::getTableName() , $this->db->quoteInto(\"`key`= ?\", $this->model->getKey()));\n\n $this->model->clearDependentCache();\n }", "title": "" }, { "docid": "2099bbcbf1aab4c1c746791c36d3848c", "score": "0.5654183", "text": "public function deleteBy( $field, $value ) {\n $query = $this -> db -> query(\n \"DELETE FROM $this->table WHERE $field = '$value'; \"\n );\n\n return $query;\n }", "title": "" }, { "docid": "03e3223b678ae757277ec68526ac4354", "score": "0.56506246", "text": "function delete_field_from_db( $id ) {\r\n\t\t\t$fields = UM()->builtin()->saved_fields;\r\n\t\t\tif (isset( $fields[$id] )) {\r\n\t\t\t\tunset( $fields[$id] );\r\n\t\t\t\tupdate_option( 'um_fields', $fields );\r\n\t\t\t}\r\n\t\t}", "title": "" }, { "docid": "fe37b8b8c929f52a1bd1d0a61e4cd0e1", "score": "0.5648636", "text": "function delete() {\n db_delete('flags')->condition('fid', $this->fid)->execute();\n db_delete('flag_content')->condition('fid', $this->fid)->execute();\n db_delete('flag_types')->condition('fid', $this->fid)->execute();\n db_delete('flag_counts')->condition('fid', $this->fid)->execute();\n module_invoke_all('flag_delete', $this);\n }", "title": "" }, { "docid": "78fbd09ae02e9cbe1969c4d2c32dd4e6", "score": "0.5640429", "text": "public function deleteMeta($key)\n {\n return (bool) $this->meta()->whereKey($key)->delete();\n }", "title": "" }, { "docid": "7d09d9ffed7ea22216a0fd4646e973a7", "score": "0.5634513", "text": "public function delete( $args, $assoc_args ) {\n\t\t$this->perform_meta_action( 'delete', $args, $assoc_args );\n\t}", "title": "" }, { "docid": "fd95f759095698a08811c17024e7c1a4", "score": "0.5633077", "text": "function delete_image($id_value,$table,$field_name,$field_id,$path)\n\t{\n\t\t\t\n\t\t\t$data = array();\n \t$this->db->select($field_name);\n \t$this->db->where($field_id,$id_value);\n\t $Q = $this->db->get($table);\n $image_name =\"default_image.jpg\";\n \tif ($Q->num_rows() > 0)\n\t\t{\n\t \tforeach ($Q->result_array() as $row)\n\t\t {\n \t\t$image_name = $row[$field_name];\n\t \t}\n \t}\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\tif($image_name!=\"default_image.jpg\")\n\t\t{\n\t\t\t$image_default = \"./../images/\".$path.\"/\".$image_name;\n\t\t\t$image_large = \"./../images/\".$path.\"/large/\".$image_name;\n\t\t\t$image_medium = \"./../images/\".$path.\"/medium/\".$image_name;\n\t\t\t$image_small = \"./../images/\".$path.\"/small/\".$image_name;\n\t\t\t$return = @unlink($image_default);\n\t\t\t$return = @unlink($image_large);\n\t\t\t$return = @unlink($image_medium);\n\t\t\t$return = @unlink($image_small);\n\t\t}\n\t}", "title": "" }, { "docid": "52b680440a60c8263c0d08a960692b24", "score": "0.5630856", "text": "public function delete() {\n if (\n array_key_exists('id', $this->rawData) && \n $this->rawData['id'] != '' &&\n array_key_exists('parent_taxa_id', $this->rawData) && \n $this->rawData['parent_taxa_id'] != ''\n ) {\n $this->db->query('DELETE FROM `'.$this->table->getTable().'` \n WHERE `id`=\"'.addslashes($this->rawData['id']).'\"\n AND `parent_taxa_id`='.intval($this->rawData['parent_taxa_id']),\n \\Zend\\Db\\Adapter\\Adapter::QUERY_MODE_EXECUTE);\n }\n }", "title": "" }, { "docid": "465f379da689ae542b17030f73676a09", "score": "0.5628555", "text": "public function deleteWhere($column, $value, $force = false);", "title": "" }, { "docid": "0447525a0291ad61aeaea65539c01317", "score": "0.5623922", "text": "public function delete(string $value, string $column = \"id\")\n {\n $query = DB::getPDO()->prepare(\"DELETE FROM $this->table WHERE $column = :placeholder\");\n $query->execute([':placeholder' => $value]);\n }", "title": "" }, { "docid": "99bc9271c72b1f6883c604821d302bd8", "score": "0.5622447", "text": "public function afterDelete();", "title": "" }, { "docid": "bbff4911e28fb11369e71bd506e4862b", "score": "0.5622299", "text": "function delete_data($data_delete_item) {\n\t}", "title": "" }, { "docid": "079de7f205e866582a9089e0a1541683", "score": "0.5621249", "text": "function delete_airstory_data() {\n\tglobal $wpdb;\n\n\t$wpdb->query( \"DELETE FROM $wpdb->usermeta WHERE meta_key = '_airstory_data';\" ); // WPCS: unprepared SQL ok.\n\n\t// Remove the _airstory_encryption_algorithm site option.\n\tdelete_site_option( '_airstory_cipher_algorithm' );\n}", "title": "" }, { "docid": "12558c90c5d11e9c652b7de17c9d8174", "score": "0.56179315", "text": "public function delete() {\r\n\r\n $this->db->delete(\"custom_layouts\", $this->db->quoteInto(\"id = ?\", $this->model->getId()));\r\n\r\n @unlink(PIMCORE_CUSTOMLAYOUT_DIRECTORY.\"/custom_definition_\". $this->model->getId() .\".psf\");\r\n }", "title": "" }, { "docid": "4bcf1f49e4ef93d004072d633196b0fd", "score": "0.561102", "text": "function _delete_preset(){\n global $wpdb;\n $table = $wpdb->ww_extras_table;\n \n // can't delete defaults\n if(isset($_POST['preset-id']) && isset($_POST['preset-variety']) && $_POST['preset-variety'] != 'core'){\n $preset_id = $_POST['preset-id'];\n $preset_variety = $_POST['preset-variety'];\n \n $sql = \"DELETE FROM \".$table.\" WHERE `type` = 'preset' AND `variety` = '%s' AND `id` = '%s' LIMIT 1\";\n $prepared = $wpdb->prepare($sql,$preset_variety, $preset_id);\n \n $wpdb->query($prepared);\n }\n }", "title": "" }, { "docid": "459382e34fd3900fda9ee6e5ee90f947", "score": "0.5609819", "text": "public function deleteMeta(string $key) {\n $this->meta->delete($key);\n }", "title": "" }, { "docid": "13e067f8defa4d9a42af8d886efb3841", "score": "0.5608405", "text": "protected function afterDelete() {}", "title": "" }, { "docid": "e163fee51a0de65fa7dc9df74776f321", "score": "0.5596225", "text": "final public function delete($pk,$value){\n if(\\Input::has('_forcedelete')){\n $id = \\Input::get('_forcedelete');\n if( \\Crypt::decrypt($id) == $value ){\n return $this->forceDelete($pk,$value);\n }\n else{\n $this->errors = trans('lacrud::notifications.invalid_key_forcedelete');\n return false;\n }\n }\n\n $register = $this->entity->where($pk,'=',$value)->first();\n try{\n $register->table = $this->entity->table;\n $register->delete();\n return true;\n }\n catch(\\PDOException $e){\n if($e->getCode() == '23000'){\n $this->errors = trans('lacrud::notifications.error_dependency');\n \\Session::flash('error_code', 23000);\n }\n else{\n $this->errors = $e->getMessage();\n }\n return false;\n }\n }", "title": "" }, { "docid": "7a6292d1588e9d56c408363ceb6e99e0", "score": "0.5595572", "text": "public function delBlogMeta($id, $key, $val) {\n\t\t$id \t= $this->DB->sanitize($id);\n\t\t$key \t= $this->DB->sanitize($key);\n\t\t$val\t= $this->DB->sanitize($val);\n\t\t$this->DB->query(\"DELETE FROM `blog_meta` WHERE `blog_id` = '$id' AND `meta_key` = '$key' and `meta_val` = '$val';\", false);\n\t\t//deccrement the tag's count\n\t\tif($key == \"tag\") {\n\t\t\t$count = $this->DB->query(\"SELECT `tag_count` FROM `blog_tags` WHERE `tag_id` = $val LIMIT 1;\");\n\t\t\tif(isset($count[0])) {\n\t\t\t\t$count = intval($count[0][\"tag_count\"]);\n\t\t\t\t$count--;\n\t\t\t\t$this->DB->query(\"UPDATE `blog_tags` SET `tag_count` = '$count' WHERE `tag_id` = $val;\", false);\n\t\t\t}\n\t\t}\t\t\n\t}", "title": "" }, { "docid": "fd0d3284adb3a97b266df4373bdedcc9", "score": "0.5585859", "text": "public function delete($value) {\n if(isset($value)){\n // Pregatesc query DELETE\n if (($value > 0) and (filter_var($value, FILTER_VALIDATE_INT))){\n $query = \"DELETE FROM \" . static::$table . \" WHERE \" . $this->id_field . \" = ?\"; \n //prepared stmt\n if($stmt = $this->link->prepare($query)){\n /* Adauga parametrii s - string, b - blob, i - int */\n $stmt -> bind_param(\"i\", $value);\n \n /* Executa */\n $stmt -> execute();\n\n $affected = $stmt->affected_rows;\n /* Inchide statement */\n $stmt -> close(); \n if (($affected == 1) and (LOG))\n {\n //$this->log(); \n\n $user = new User();\n try{\n $logged_in = $user->loggedIn();\n $user = $user->name .' '. $user->last_name; \n }\n catch (Exception $e){\n echo $e->getMessage();\n $logged_in = false;\n }\n $output = date(\"d.m.Y H:i:s\") . \" - Deleted id \" . $value . \" from \" . static::$table . \" by \" . $user . \"\\n\";\n foreach ($this as $field=>$value){\n $output .= \"\\t{$field}: {$value}\\n\";\n }\n $output .= \"\\n\";\n $output .= \"----------------------------------------------------------------\";\n $output .= \"\\n\\n\";\n file_put_contents(LOG_FOLDER . \"/data.log\",$output, FILE_APPEND); \n }\n return $affected; \n }else{\n throw new Exception(\"Eroare query!\");\n }\n }\n else{\n throw new Exception(\"Bad ID\");\n }\n }else{\n throw new Exception(\"ID inexistent\");\n }\n }", "title": "" }, { "docid": "3a2fa374d4fa144b0fe47c3f8a00641d", "score": "0.5584563", "text": "public function delete()\n {\n $this->deleted_at = date('Y-m-d H:i:s');\n $this->save();\n }", "title": "" }, { "docid": "605ffb5cc0bb951d279eb6d37096a3d2", "score": "0.55787826", "text": "public function onFieldStorageDefinitionDelete(FieldStorageDefinitionInterface $storage_definition);", "title": "" }, { "docid": "82ba0b177680cb1b49d1acab1b18b034", "score": "0.5576546", "text": "function glz_delete_custom_field($name, $table) {\n if ( glz_custom_digit($name) > 10 ) {\n if ( in_array($table, array(PFX.\"txp_prefs\", PFX.\"txp_lang\", PFX.\"custom_fields\")) ) {\n $query = \"\n DELETE FROM\n `{$table}`\n WHERE\n `name`='{$name}'\n \";\n }\n else if ( $table == PFX.\"textpattern\" ) {\n $query = \"\n ALTER TABLE\n `\".PFX.\"textpattern`\n DROP\n `{$name}`\n \";\n }\n safe_query($query);\n }\n else {\n if ( $table == PFX.\"txp_prefs\" )\n glz_custom_fields_MySQL(\"reset\", $name, $table);\n else if ( ($table == PFX.\"custom_fields\") ) {\n safe_query(\"\n DELETE FROM\n `{$table}`\n WHERE\n `name`='{$name}'\n \");\n }\n }\n}", "title": "" }, { "docid": "a31d22ef15986d3cfe1b07b14021c679", "score": "0.5572362", "text": "public function delete() {\r\n $this->db->delete(\"objects\", $this->db->quoteInto(\"o_id = ?\", $this->model->getO_id() ));\r\n }", "title": "" }, { "docid": "d102bac1dfa8a751b875e1e79ca57f32", "score": "0.5569616", "text": "private function del_meta( $act ) {\n \n $this->db->select('*');\n $this->db->from('activity_meta');\n $this->db->where(['activity_id' => $act]);\n $query = $this->db->get();\n \n if ( $query->num_rows() > 0 ) {\n $result = $query->result();\n \n foreach ( $result as $res ) {\n $this->db->select('*');\n $this->db->from('comments');\n $this->db->where(['comment' => $res->net_id]);\n $query = $this->db->get();\n \n if ( $query->num_rows() > 0 ) {\n \n $this->db->delete('comments', ['comment' => $res->net_id]);\n \n }\n }\n $this->db->delete('activity_meta', ['activity_id' => $act]);\n \n return true;\n \n } else {\n \n return false;\n \n }\n \n }", "title": "" }, { "docid": "e0cfae1678e48a585bd1e2255eb340d5", "score": "0.5566058", "text": "public function deleteData()\n {\n\t}", "title": "" }, { "docid": "e0cfae1678e48a585bd1e2255eb340d5", "score": "0.5566058", "text": "public function deleteData()\n {\n\t}", "title": "" }, { "docid": "b927101dd1f5f5f7baa59c6108d10b9c", "score": "0.55614847", "text": "public function actionDelete()\n\t{\n\t\t\n\t\tif($_GET['val_id'])\n\t\t{\n\t\t\t$model = ConfScopeOfValue::model()->findByPk($_GET['val_id']);\n\t\t\t$model->delete();\n\t\t}\n\t}", "title": "" }, { "docid": "08f8ade392bdfc55a341cbc014e380ac", "score": "0.5550268", "text": "function deleteData()\n{\n global $myDataGrid;\n $arrKeys = [];\n foreach ($myDataGrid->checkboxes as $strValue) {\n $arrKeys['code'][] = $strValue;\n }\n $dataHrdAbsenceType = new cHrdAbsenceType();\n $dataHrdAbsenceType->deleteMultiple($arrKeys);\n $myDataGrid->message = $dataHrdAbsenceType->strMessage;\n}", "title": "" }, { "docid": "8f7ec7bee30c2890f8865ecc698c01e0", "score": "0.55470383", "text": "public function post_delete(){\n\n\t\t$income_data \t= \tFiledb::_rawurldecode(json_decode(stripcslashes(Input::get('data')), true));\n\n\t\tif($income_data[\"delete\"] == 'delete'){\n\n\t\t\t$income_data[\"table\"]::delete($income_data[\"id\"]);\n\n\t\t\treturn Utilites::alert(__('forms.deleted_notification', array(\"item\" => $income_data[\"id\"])), 'success');\n\n\t\t}else{\n\n\t\t\treturn Utilites::alert(__('forms_errors.undefined'), 'error');\n\t\t}\n\t}", "title": "" }, { "docid": "20103c8e97a5790989431e5f0b9d69e9", "score": "0.5546157", "text": "function delete()\n {\n $path = $this->filePath;\n eZDebugSetting::writeDebug( 'kernel-clustering', \"dfs::delete( '$path' )\" );\n\n self::$dbbackend->_delete( $path );\n\n $this->metaData = null;\n }", "title": "" }, { "docid": "2c83677ff9757c94ae7f8592daffa9b6", "score": "0.5545277", "text": "protected function delete_data() {\n\t\t$this->delete_option( 'issues' );\n\t\t$this->delete_option( 'stats' );\n\t}", "title": "" }, { "docid": "5a1aff9910f0c8d75e287c2c15842444", "score": "0.55338573", "text": "public function deletePersonalData()\n\t{\n\t\t$this->confirmed = false;\n\t\t$this->save();\n\t\t\n\t\tif ($this->resource) {\n $this->resource->removeFromStorage();\n\t\t\t$this->resource->delete();\n }\n\t}", "title": "" }, { "docid": "fa28e450cee1c40bd7db70f8d5411781", "score": "0.55336326", "text": "final public function delete($value=null):self\n {\n $value = Base\\Obj::cast($value,2);\n $this->setType('delete');\n\n if(is_string($value))\n $this->from($value);\n\n return $this;\n }", "title": "" }, { "docid": "78bee795ecf72dc44c582ec495fadb6f", "score": "0.5516329", "text": "public function Delete($rootValue, array $args, GraphQLContext $context, ResolveInfo $resolveInfo)\n {\n // Bloque donde escoge el nombre de la tabla segun el tipo de producto\n $db_name=\"\";\n switch ($args['tipo']) {\n case 1:\n $db_name=\"civil_articulos_juridicos\";\n break;\n case 2:\n $db_name=\"penal_articulos_juridicos\";\n break;\n case 3:\n $db_name=\"constitucional_articulos_juridicos\";\n break;\n case 4:\n $db_name=\"juridica_articulos_juridicos\";\n break;\n case 5:\n $db_name=\"jurisprudencia_articulos_juridicos\";\n break;\n case 6:\n $db_name=\"solucion_articulos_juridicos\";\n break;\n }\n //Eliminar elemnto\n DB::table($db_name)->where('id',$args['id'])->delete();\n return \"Exito\";\n }", "title": "" }, { "docid": "115f0a8f303d4e38f53fc32fa27fb59e", "score": "0.5515327", "text": "public function delete()\n\t{\n\t\t$this->deleted = true;\n\t}", "title": "" }, { "docid": "63532aa6318a96ccc7831c74336e77b3", "score": "0.5514481", "text": "public function p_preferences_delete() {\n $condition = \"WHERE preference_id = \".$_POST['preference_id'];\n $result = DB::instance(DB_NAME)->delete('preferences', $condition);\n\n # If something was deleted, return preference_id of row deleted\n if ($result == 1) {\n echo $_POST['preference_id'];\n } else {\n echo \"failed to delete\";\n }\n }", "title": "" }, { "docid": "573f58d57c5b1333e4a2ddf6048545ec", "score": "0.55122375", "text": "public function delete();", "title": "" } ]
783d73c8674c5e71e7ead9fa78c55845
Makes a copy of this object that will be inserted as a new row in table when saved. It creates a new object filling in the simple attributes, but skipping any primary keys that are defined for the table. If desired, this method can also make copies of all associated (fkey referrers) objects.
[ { "docid": "b8eea0c4b0da73e1595c57bc6fcf723d", "score": "0.0", "text": "public function copy($deepCopy = false)\n {\n // we use get_class(), because this might be a subclass\n $clazz = get_class($this);\n $copyObj = new $clazz();\n $this->copyInto($copyObj, $deepCopy);\n\n return $copyObj;\n }", "title": "" } ]
[ { "docid": "b3b4f3eed79b0445e06a99238301a4f8", "score": "0.6941202", "text": "public function copy()\n {\n\t\t$objCopy = clone $this;\n\t\t$objCopy->__blnRestored = false;\n\n\t\t// Make sure all valid data is dirty so it will be saved\n\t\tforeach ($this->__blnValid as $key=>$val) {\n\t\t\t$objCopy->__blnDirty[$key] = $val;\n\t\t}\n\n \t\t// Nullify primary keys so they will be saved as a different object\n\t\t$objCopy->intId = null;\n\n\n\n\t\treturn $objCopy;\n\t}", "title": "" }, { "docid": "05833de99252efa168957237a1b5620c", "score": "0.6826438", "text": "private function prepareObjectForSave()\n {\n $columns = ShopgateWrapper::db_get_columns($this->getMainTable());\n $object = clone $this;\n foreach ($columns as $row) {\n if (!array_key_exists($row['Field'], $object->getData())) {\n $object->unsetData($row['Field']);\n }\n }\n\n return $this->setSavedObject($object);\n }", "title": "" }, { "docid": "3b90296603701b63f7da321a5cf91052", "score": "0.6739122", "text": "public function copy()\n {\n\t\t$objCopy = clone $this;\n\t\t$objCopy->__blnRestored = false;\n\n\t\t// Make sure all valid data is dirty so it will be saved\n\t\tforeach ($this->__blnValid as $key=>$val) {\n\t\t\t$objCopy->__blnDirty[$key] = $val;\n\t\t}\n\n \t\t// Nullify primary keys so they will be saved as a different object\n\t\t$objCopy->intId = null;\n\n\n\n \t\t// Reverse references\n\t\t$objCopy->_objTourist = null;\n\t\t$objCopy->_objTouristArray = null;\n\n\t\treturn $objCopy;\n\t}", "title": "" }, { "docid": "798df84ef9bca772ec2391a3edd0a8c0", "score": "0.6539761", "text": "public function __clone(){\r\n $this->{$this->pk()} = null;\r\n }", "title": "" }, { "docid": "faeaf8452978daa474c6490ad38b6db7", "score": "0.6141917", "text": "public function duplicate() {\n\t\t/**\n\t\t * PHP4 is no longer supported or allowed.\n\t\t * The\n\t\t * installer/upgrader/converter simply stops executing.\n\t\t * This method also appears (modified) in the apm_Utilities_Date and apm_Database_Query class.\n\t\t */\n\t\t$_key = $this->_tbl_key;\n\t\t\n\t\t$newObj = clone ($this);\n\t\t$newObj->$_key = '';\n\t\t\n\t\treturn $newObj;\n\t}", "title": "" }, { "docid": "db56ffb9118a66b145444ed3104721ea", "score": "0.6043473", "text": "public function DuplicateRecord() {\r\n\r\n //Create the INSERT query using all the parameter names and values of this object.\r\n $qCopy = \"INSERT INTO $this->tableName (\";\r\n\r\n foreach ($this->columnNames as $column) {\r\n if (($column != $this->keyIdName) && ($column != \"TS\")) {\r\n $qCopy .= $column . \",\";\r\n }\r\n }\r\n $qCopy = rtrim($qCopy, \",\") . \") VALUES (\";\r\n foreach ($this->columnNames as $column) {\r\n if (($column != $this->keyIdName) && ($column != \"TS\")) {\r\n $qCopy .= \"'{$this->{$column}}',\";\r\n }\r\n }\r\n $qCopy = rtrim($qCopy, \",\") . \");\";\r\n mysqli_query($this->dbConnection, $qCopy);\r\n\r\n //After the new duplicate record is created, get the primary key value and reinitialize\r\n //this object to the newly created record.\r\n $qMax = \"SELECT MAX($this->keyIdName) FROM $this->tableName;\";\r\n $rMax = mysqli_query($this->dbConnection, $qMax);\r\n $newId = ADAPT_mysqli_result($rMax, 0, 0);\r\n $this->__construct($this->tableName, $newId, $this->keyIdName, $this->GetValue($this->fcKeyName), $this->fcKeyName);\r\n }", "title": "" }, { "docid": "e59b5bd2750b3edfb519a147fa7bfb04", "score": "0.6040378", "text": "public function __clone() {\r\n $this->properties[$this->pkName] = 0;\r\n //deep clone\r\n $this->dataService = clone $this->dataService;\r\n }", "title": "" }, { "docid": "80ab93ca89a4b16076f6c3efbc0b6d15", "score": "0.59960157", "text": "public function copy($deep = false)\n {\n $data = $this->_data;\n $idtype = $this->_table->getIdentifierType();\n if ($idtype === Doctrine_Core::IDENTIFIER_AUTOINC || $idtype === Doctrine_Core::IDENTIFIER_SEQUENCE) {\n $id = $this->_table->getIdentifier();\n\n unset($data[$id]);\n }\n\n $ret = $this->_table->create($data);\n $modified = array();\n\n foreach ($data as $key => $val) {\n if ( ! ($val instanceof Doctrine_Null)) {\n $ret->_modified[] = $key;\n }\n }\n\n if ($deep) {\n foreach ($this->_references as $key => $value) {\n if ($value instanceof Doctrine_Collection) {\n foreach ($value as $valueKey => $record) {\n $ret->{$key}[$valueKey] = $record->copy($deep);\n }\n } else if ($value instanceof Doctrine_Record) {\n $ret->set($key, $value->copy($deep));\n }\n }\n }\n\n return $ret;\n }", "title": "" }, { "docid": "5c1fda32f335d20767b04884f52279d7", "score": "0.5922194", "text": "public function save_entry() {\n\t\t$table = $this->get_ar_table_name();\n\t\t$key = $this->_primary;\n\n\t\t$tmp = new stdClass;\n\t\tforeach( $this->get_public_properties() as $p ) {\n\t\t\t$tmp->$p = $this->$p;\n\t\t}\n\n\t\tif( !$this->$key ) {\n\t\t\t$this->db->insert($table, $tmp);\n\n\t\t\t$this->$key = $this->db->insert_id();\n\t\t} else {\n\t\t\t$this->db->update(\n\t\t\t\t$table, $tmp, array($key => $this->$key)\n\t\t\t);\n\t\t}\n\n\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "5214c0887c86ec3c33368340b16e844e", "score": "0.5867561", "text": "public function create()\n {\n $this->delete_properties();\n self::$id_autoincrement++;\n $this->id = self::$id_autoincrement;\n $this->is_new = true;\n return $this;\n }", "title": "" }, { "docid": "ed5f0fc29f42bc11c99aaf0372ed814b", "score": "0.5859088", "text": "public function __clone()\r\n {\r\n $this->createdAt = null;\r\n $this->dateModified = null;\r\n $this->checkedOut = null;\r\n $this->active = false;\r\n $this->deleted = false;\r\n }", "title": "" }, { "docid": "cf0fcb6df1e846373721c06c7036a9ff", "score": "0.5849746", "text": "public function duplicate($newPrimaryKey = null)\n {\n if ($this->exists) {\n $response = $this->client->cloneObject($this->type, $this->original, $this->getDirty(), $newPrimaryKey);\n\n $model = $this->newInstance($response);\n $model->exists = true;\n\n $this->restore();\n\n return $model;\n }\n }", "title": "" }, { "docid": "e742fb48dcc1a15ec832729771843c2c", "score": "0.58478916", "text": "public function cloneObject(){\n return new Object($this->objectClass,$this->resetAttributes($this->attributes()));\n }", "title": "" }, { "docid": "95d9cd32923792c0a6795468e4366357", "score": "0.5815848", "text": "public function __wakeup()\n {\n $this->_table = new Table($this->_tableName, $this->_schema);\n }", "title": "" }, { "docid": "dd98791e0ac18fccdd07b0c3c930dce3", "score": "0.578582", "text": "public function save() {\n if (isset($this->id)) {\n \\field_update_instance($this->export());\n }\n else {\n foreach (\\field_create_instance($this->export()) as $k => $v) {\n $this->$k = $v;\n }\n }\n return $this;\n }", "title": "" }, { "docid": "8d30cc109bde8edf27f1d00cee4c4188", "score": "0.574725", "text": "public function __clone() {\n $this->name = $name;\n $this->lastname = $lastname;\n $this->nationality = $nationality;\n $this->id = $id;\n }", "title": "" }, { "docid": "a7ccfa34f627ace1ba9ad67c443f3021", "score": "0.566805", "text": "public function create()\n\t{\n\t\t$into = $values = '';\n\t\t$bindings = array();\n\n\t\tforeach ($this->data as $key => $val) {\n\t\t\tif ($key != $this->pkname) {\n\t\t\t\t$into .= ',`'.$key.'`';\n\t\t\t\t$values .= ',:'.$key;\n\t\t\t\t$bindings[':'.$key] = $val;\n\t\t\t}\n\t\t}\n\n\t\t$sql = 'INSERT INTO `'.$this->tablename.'` ('.substr($into,1).') VALUES ('.substr($values,1).')';\n\t\t$this->execute($sql,$bindings);\n\n\t\tif ($this->count > 0) {\n\t\t\t$this->data[$this->pkname] = $this->dbh->lastInsertId();\n\t\t}\n\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "52e968846a28ef0c9cf257b512083e68", "score": "0.5663004", "text": "function __clone() {\n\t\tforeach ((array)get_object_vars($this) as $k => $v) {\n\t\t\t$this->$k = null;\n\t\t}\n\t}", "title": "" }, { "docid": "81f596649e8ef6963b338e523235d6d3", "score": "0.56446177", "text": "function create() {\n\t\t$this->new_row = true;\n\t\t$this->save();\n\t}", "title": "" }, { "docid": "394b2371f2036e732ec03c9394bc157a", "score": "0.5637593", "text": "public function __clone() {\n\t\t$this->id = NULL;\n\t\t$this->changes = [];\n\t}", "title": "" }, { "docid": "08708e7e602b77c78df7433356999d25", "score": "0.5620391", "text": "public function make()\n {\n $this->_record->name = $this->name;\n $this->_record->latin_name = $this->latin_name;\n $this->_record->country = $this->country;\n $this->_record->save();\n }", "title": "" }, { "docid": "8add43b6e8013dc31f569740c7bc300c", "score": "0.5618957", "text": "function create() {\n $this->beforeCreate();\n \n if ($this->isValid()) {\n $this->inDatabase = !!($this->dbh->insert($this->tableName, $this->values()));\n $this->{$this->idField} = mysql_insert_id();\n $this->_data[$this->idField] = mysql_insert_id();\n \n $class = get_class($this);\n $relations =& self::$relations[$class];\n foreach ($relations as $key => $relation) {\n $cache = \"_$key\";\n if ($relation['arity'] == 'hasOne' && $this->$cache) {\n $this->$key = $this->$cache; // update the IDs on the relations\n $this->$cache->save();\n } elseif ($relation['arity'] == 'hasMany' && $this->$cache) {\n foreach ($this->$cache as $val) {\n $val->{$this->idField} = $this->__id();\n $val->save();\n }\n }\n }\n }\n $this->afterCreate();\n \n return $this->inDatabase;\n }", "title": "" }, { "docid": "9d93e4916283c4ee100b0518fba5ef4c", "score": "0.5607502", "text": "public function create()\r\n {\r\n $this->db->insert(\"objects\", array(\r\n \"o_key\" => $this->model->getKey(),\r\n \"o_path\" => $this->model->getPath()\r\n ));\r\n $this->model->setId($this->db->lastInsertId());\r\n\r\n if (!$this->model->getKey()) {\r\n $this->model->setKey($this->db->lastInsertId());\r\n }\r\n }", "title": "" }, { "docid": "c34cd65e1c04b592974d52454bd65409", "score": "0.55913335", "text": "function __clone() {\n foreach ($this as $key => $val) {\n if (is_object($val) || (is_array($val))) {\n $this->{$key} = unserialize(serialize($val));\n }\n }\n }", "title": "" }, { "docid": "13d54860669ad44052109cc531633d0d", "score": "0.55851454", "text": "public function __clone()\n {\n $vars = get_object_vars($this);\n foreach ($vars as $key => $value) {\n if ($key == 'worksheet') {\n $this->worksheet = null;\n } elseif (is_object($value)) {\n $this->$key = clone $value;\n } else {\n $this->$key = $value;\n }\n }\n }", "title": "" }, { "docid": "7aa04389c8ad8f4f5cb846174391620c", "score": "0.55504805", "text": "public function Create()\r\n {\r\n $dbh = $this->getDatabaseHandle();\r\n $s1 = $s2 = '';\r\n $params = array();\r\n\r\n foreach ($this->_recordSet as $key => $value)\r\n {\r\n if (!$this->isFakeField($key))\r\n {\r\n $dbKey = $this->convertClassKeyToDBKey($key);\r\n if ($value)\r\n {\r\n $s1 .= (strlen($s1) > 0 ? ',' : ''). $this->quoteDbObject($dbKey);\r\n $s2 .= (strlen($s2) > 0 ? ',' : '').'?';\r\n $params[] = $value;\r\n }\r\n }\r\n }\r\n\r\n\r\n $stmt = $dbh->prepare('INSERT INTO ' . $this->quoteDbObject($this->_tableName) . ' (' . $s1 . ') VALUES (' . $s2 . ')');\r\n $stmt->execute($params);\r\n\r\n $this->ValidateStatement($stmt);\r\n\r\n if (!$stmt->rowCount())\r\n {\r\n return false;\r\n }\r\n\r\n $this->Set($this->_primaryKeyName, $dbh->lastInsertId());\r\n return $this;\r\n }", "title": "" }, { "docid": "fd436be3782a1c85e9bd4f80aa0e671a", "score": "0.55441236", "text": "function create(stdClass $data){\n\t\t// $data is a PHP object\n global $ORIONDB_DB;\n // run through the data to filter out any fields not in $this->_fieldnames\n $filtereddata = $this->filterfieldnames($data, true);\n\t\t$newid = $ORIONDB_DB->createrecord($this->_tablename,$filtereddata, $this);\n\t\tlogmessage(\"New record created with id $newid\");\n\t\tif($newid) $this->init($newid);\n\t}", "title": "" }, { "docid": "ef9c5a3d1c02ba0ab40414b3f10a1a87", "score": "0.55280036", "text": "public function __clone()\n {\n $this->id = null;\n }", "title": "" }, { "docid": "e343cd98ccd7b2db0edb19cd366e5b45", "score": "0.55250144", "text": "public function copy($dest = false){\n if($dest){\n $ret = clone $this;\n $ret->{$ret->primary_key} = $dest->primval();\n if($assocs = $this->associations()){\n if(!$ret->primval()) $ret->save();\n foreach($assocs as $assoc => $data){\n $ret->$assoc->unlink();\n $ret->$assoc = $this->$assoc;\n }\n }\n return $ret;\n }else{\n $ret = clone $this;\n $ret->{$ret->primary_key} = null;\n return $this->copy($ret);\n }\n }", "title": "" }, { "docid": "799ecc841a4b0f669014cffca235614b", "score": "0.54996604", "text": "public function copy() : Schema\n {\n return deep_copy($this);\n }", "title": "" }, { "docid": "572202048b35da9b7b42758c8d8795d3", "score": "0.5466283", "text": "public function __clone()\n\t{\n\t\t$this->values['id'] = NULL;\n\t\t$this->valid = [];\n\t\t$this->changed[NULL] = true;\n\t\tforeach ($this->values as $property => $value)\n\t\t{\n\t\t\tif ($value instanceof IRelationship)\n\t\t\t{\n\t\t\t\tunset($this->values[$property]);\n\t\t\t\t$this->{$property} = iterator_to_array($value);\n\t\t\t}\n\t\t\telse if ($value instanceof IEntityInjection)\n\t\t\t{\n\t\t\t\t$this->values[$property] = $value->getInjectedValue();\n\t\t\t}\n\t\t\telse if (!($value instanceof IEntity) AND is_object($value))\n\t\t\t{\n\t\t\t\t$this->values[$property] = clone $value;\n\t\t\t}\n\t\t}\n\t\tparent::__clone();\n\t}", "title": "" }, { "docid": "ffb5034509e621fc1f10c77b050dd419", "score": "0.5447732", "text": "public function duplicate($id = false){\n\t\t// Get my class name\n\t\t\t/* @var zajModel $class_name */\n\t\t\t$class_name = $this->class_name;\n\t\t// create the same object type\n\t\t\t$new = $class_name::create($id);\n\t\t// load up data object if not already done\n\t\t\tif(!$this->data) $this->data = new zajData($this);\n\t\t// run through all of my fields\n\t\t\t$model = $class_name::__model();\n\t\t\tforeach($model as $name=>$fielddata){\n\t\t\t\t/* @var zajDb $fielddata */\n\t\t\t\tif($fielddata->use_duplicate){\n\t\t\t\t\t$fobj = $class_name::__field($name);\n\t\t\t\t\t$data = $fobj->duplicate($this->data->$name, $this);\n\t\t\t\t\t$new->set($name, $data);\n\t\t\t\t}\n\t\t\t}\n\t\treturn $new;\n\t}", "title": "" }, { "docid": "b04188a94ace915707254a1b2cf7f349", "score": "0.5423722", "text": "public function createNewRecord(){\n\n\t\t$modelName = get_class( $this );\n\n\t\t$modelFields = [];\n\n\t\t//Loop through the model's validation (if such validation exists)\n\t\t//Make sure we get the lil kid all set up to pass \n\t\tif( isset( $this->validate ) ){\n\t\t\tforeach( $this->validate as $fieldName => $fieldCriteria ){\n\t\t\t\n\t\t\t\t//If we have a default we can set then we do\n\t\t\t\tif( isset( $fieldCriteria['default'] ) ){\n\t\t\t\t\t$modelFields[ $fieldName ] = $fieldCriteria['default'];\n\t\t\t \t}\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t\t\n\t\t//Finalize the model data\n\t\t$modelData = [\n\t\t\t$modelName => $modelFields\n\t\t];\n\n\t\t//Create the record\n\t\t$this->create();\n\t\t$this->save( $modelData );\n \n\t\t\n\t\t//Even though what we're actually returning the \"uid\" element\n\t\t//we need to use $this->id as it seems to be where Cake stores\n\t\t//the primary key value after a save. \n\t\treturn $this->id;\n\t\t\n\t}", "title": "" }, { "docid": "aac73c87e90c78a15d926b1e53f357ce", "score": "0.5403761", "text": "public function __clone()\r\n {\r\n $this->queryable = clone $this->newElegantQuery();\r\n $this->queryable->setModel($this);\r\n }", "title": "" }, { "docid": "3a924cef9e164ae7384281c3a956d23b", "score": "0.5382958", "text": "protected function new_model(){\n $model = new $this->model_class;\n //find the required fields and give them default values\n foreach($model->columns as $name=>$values){\n if($name == $model->primary_key || $values[0] == \"HasManyField\" || $values[0] == \"ManyToManyField\") continue;\n if($values[1]['unique']) $model->$name = time();\n elseif($values[0] == \"FloatField\" || $values[0] == \"IntegerField\" || $values[0] == \"BooleanField\" || $values[0] == \"ForeignKey\") $model->$name = 0;\n elseif($values[0] == \"EmailField\") $model->$name = \"fill.me@in.com\";\n else $model->$name = $name;\n }\n if($saved = $model->save()) return $saved;\n else return false;\n }", "title": "" }, { "docid": "a42c2f0777711860098edbef0299413d", "score": "0.5376797", "text": "public function save()\n\t{\n\t\t$this->preSave();\n\n\t\tif(!$this->hasObject()){\n\t\t\t$this->object = new $this->modelClass();\n\t\t}\n\n\n\t\tforeach($this->getFields() as $field){\n\t\t\t$key = $field->getId();\n\n\t\t\tif(isset($this->object->$key) && $key != 'id' && $key != 'Id' && $field->getType() != 'file' && !$field->hasAttribute('DoctrineRelation')){\n\t\t\t\t$this->object->$key = $field->getValue();\n\t\t\t}\n\t\t}\n\n\t\tforeach($this->getFields() as $field){\n\t\t\tif($field->hasAttribute('DoctrineRelation')){\n\n\t\t\t\t$relation = $field->getAttribute('DoctrineRelation');\n\t\t\t\tif($relation->getType() == Doctrine_Relation::MANY){\n\n\t\t\t\t\t/**\n\t\t\t\t\t * fetch many to many association table definition\n\t\t\t\t\t */\n\t\t\t\t\t$assocTable = $relation->getAssociationFactory();\n\t\t\t\t\t$assocClass = $assocTable->getClassNameToReturn();\n\t\t\t\t\t$relationAlias = $relation->getAlias();\n\t\t\t\t\t$relatedClass = $relation->getClass();\n\n\t\t\t\t\t/**\n\t\t\t\t\t * the association table column for $this->object\n\t\t\t\t\t */\n\t\t\t\t\t$foreignLocalColumn = $relation->getLocalColumnName();\n\n\t\t\t\t\t/**\n\t\t\t\t\t * the association table column for the related object\n\t\t\t\t\t */\n\t\t\t\t\t$foreignForeignColumn = $relation->getForeignFieldName();\n\n\t\t\t\t\t/**\n\t\t\t\t\t * dirty hack TODO: get column from model instead to specify it at Form class or by a default value\n\t\t\t\t\t */\n\t\t\t\t\tif($field->hasAttribute('DoctrineRelationHack')){\n\t\t\t\t\t\t$attr = $field->getAttribute('DoctrineRelationHack');\n\t\t\t\t\t\t$columnWhereToPutValue = $attr['localKeyColumn'];\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$columnWhereToPutValue = 'id';\n\t\t\t\t\t}\n\n\t\t\t\t\t/**\n\t\t\t\t\t * erase old associated records from database\n\t\t\t\t\t */\n\t\t\t\t\t$this->object->unlink($relationAlias);\n\n\t\t\t\t\t/**\n\t\t\t\t\t * if value is not an array, make it an array\n\t\t\t\t\t */\n\t\t\t\t\tif(!is_array($field->getValue())){\n\t\t\t\t\t\t$values = array();\n\t\t\t\t\t\t$values[] = $field->getValue();\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$values = $field->getValue();\n\t\t\t\t\t}\n\n\t\t\t\t\t$this->object->link($relationAlias,$values);\n\n\t\t\t\t}elseIf($relation->getType() == Doctrine_Relation::ONE){\n\t\t\t\t\t/**\n\t\t\t\t\t * TODO: implement ONE-TO-ONE relationship feature\n\t\t\t\t\t */\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t/**\n\t\t * now if there's any field of type FILE, save images to specified field upload path\n\t\t */\n\t\t$isMultipart = false;\n\t\tforeach($this->fields as $field){\n\t\t\tif($field->getType() == 'file'){\n\t\t\t\t$isMultipart = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\tif($isMultipart){\n\t\t\tif(!$this->object->exists()){\n\t\t\t\t$this->object->trySave();\n\t\t\t}\n\t\t\tforeach($this->fields as $field){\n\t\t\t\tif($field->getType() == 'file' and isset($this->object)){\n\t\t\t\t\t$this->preUpload();\n\t\t\t\t\t$this->uploadFile($field);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\ttry{\n\t\t\t$this->object->save();\n\t\t}catch(Exception $e){\n\t\t\tlog_message('error',get_class($this).' error: '.$e->getMessage());\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "title": "" }, { "docid": "cfd630e1416de2b15e6d51c10436d1a0", "score": "0.5351388", "text": "public function create()\n {\n $fields = $this->primary_key . \", \";\n $fields .= join(\", \", array_keys($this->fields));\n\n $inspoints = array(\"0\");\n foreach(array_keys($this->fields) as $field)\n $inspoints []= \"?\";\n\n $inspt = join( \", \", $inspoints );\n\n $sql = \"INSERT INTO \".$this->table_name() .\n \" ($fields) VALUES ($inspt )\";\n\n $values = array();\n foreach(array_keys($this->fields) as $field )\n $values []= $this->fields[$field];\n\n $insert_result = Par::mysql_prepare($sql,$values);\n\n $this->catch_and_throw_any_mysql_errors('Could not create new row');\n\n $id_sql = \"SELECT last_insert_id()\" ;\n\n\n //$result = mysql_query( \"SELECT last_insert_id()\" );\n global $db;\n $result = $db->execute($id_sql);\n\n $row = mysql_fetch_row( $result);\n \t$this->catch_and_throw_any_mysql_errors('Could not create new row');\n $this->id_value = $row[0];\n $this->persisted = true;\n //return $row[0];\n return $this;\n }", "title": "" }, { "docid": "0678019e369c3efaf30af0f9a9d29776", "score": "0.5348151", "text": "public function save()\n {\n $data = get_object_vars($this);\n $data = array_intersect_key($data, array_flip($this->field_names)); // filter out non DB field data\n $data = array_filter($data, array($this, \"filter_null\"));\n\n if (isset($this->id) && $this->is_new === false) {\n return $this->update(array('id' => $this->id), $data);\n } else {\n $this->is_new = false;\n return $this->insert($data);\n }\n }", "title": "" }, { "docid": "9954e09075ee4c4a927d1c7c44a19424", "score": "0.5326315", "text": "public function __clone()\n\t{\n\t\tforeach ($this as $key => $value)\n\t\t{\n\t\t\tif (is_object($value))\n\t\t\t{\n\t\t\t\t$this->offsetSet($key, clone $value);\n\t\t\t}\n\t\t}\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "7b317ddaaf9ed9be1613fb4e51093623", "score": "0.5324218", "text": "private function persist(): QModel\r\n {\r\n $indexedCompleteAttributes = [];\r\n $completeAttributes = [];\r\n\r\n $i = 0;\r\n array_walk_recursive($this->columns, function ($key) use (&$indexedCompleteAttributes, &$completeAttributes, &$i) {\r\n if ($i % 2 === 0) {\r\n try {\r\n // Attribute has been given.\r\n $indexedCompleteAttributes[] = $this->attributes[$key];\r\n $completeAttributes[$key] = $this->attributes[$key];\r\n } catch (Exception $e) {\r\n // Attribute needs to be generated.\r\n if ($key === 'id') {\r\n $lastId = $this->last(['id'])->id;\r\n $indexedCompleteAttributes[] = $lastId + 1;\r\n $completeAttributes[$key] = $lastId + 1;\r\n } elseif ($key === 'created_at' || $key === 'updated_at') {\r\n $indexedCompleteAttributes[] = Carbon::now()->unix();\r\n $completeAttributes[$key] = Carbon::now()->unix();\r\n } else {\r\n $indexedCompleteAttributes[] = null;\r\n $completeAttributes[$key] = null;\r\n }\r\n }\r\n }\r\n $i++;\r\n });\r\n\r\n $this->attributes = $completeAttributes;\r\n\r\n if ($this->persistAttributes($indexedCompleteAttributes)) {\r\n return $this;\r\n }\r\n\r\n throw new RuntimeException('Could not create new record.');\r\n }", "title": "" }, { "docid": "4b47a5b49e906594d9ebfa0f8b745631", "score": "0.5320163", "text": "public function copy()\n {\n return new static($this->db);\n }", "title": "" }, { "docid": "978767371369aa4c2417aae5bceb09cc", "score": "0.5289669", "text": "public function create(){ \n\t\t$obj_attributes = $this->attributes();\n\t\t$sql = \"INSERT INTO \".static::$table_name.\" (\";\n\t\t$sql.= join(',',array_keys($obj_attributes)).\")\";\n\t\t$sql.= \" VALUES ('\".join(\"','\",$obj_attributes).\"')\";\n\t\t// echo($sql); --->for debugging purposes only\n\t\treturn ($this->connection->query($sql)) ? true : false;\n\t}", "title": "" }, { "docid": "2a9f8a2b6d18fc070b33d41f255f51a2", "score": "0.52888817", "text": "function preparedCreate(){\n $obj_attributes_array = $this->attributes();\n\t\t\t$obj_attributes_array_keys = array_keys($obj_attributes_array);\n\t\t\t$sql = \"INSERT INTO \".static::$table_name;\n\t\t\t$sql .= \" (\".join(',',$obj_attributes_array_keys).\") \";\n\t\t\t$sql .= \"VALUES (:\".join(\",:\",$obj_attributes_array_keys).\")\";\n\t\t\t// echo $sql;\n $statement = $this->connection->prepare($sql);\n $statement->execute($obj_attributes_array);\n }", "title": "" }, { "docid": "14f391ea5481991c7e3efd07a3265909", "score": "0.52860904", "text": "public function fresh(){\n // Update table and column info, in case it has changed\n $this->_table = static::$tables['user'];\n $user = new User(parent::fresh(), $this->_id);\n $user->_groups = $this->fetchGroups();\n $user->_primary_group = $this->fetchPrimaryGroup();\n return $user;\n }", "title": "" }, { "docid": "12afd923c1b03fcebd93121317448ac8", "score": "0.52728426", "text": "public function save()\n {\n\n $attributes = $this->get_attributes();\n\n if ($this->id !== null) :\n $attributes[self::get_primary_key()] = $this->id;\n self::update($attributes);\n else :\n $id = self::create($attributes);\n $this->id = $id;\n endif;\n }", "title": "" }, { "docid": "ac816c0d19f5f8d8876ce1de106261bd", "score": "0.5261938", "text": "public function create() {\n\t\n\t\t// create query to excecute on object.\n\t\t$values = array();\n\t\t$query = \"INSERT INTO $this->tableName (\";\n\t\tforeach (array_slice($this->fields, 1) as $field){\n\t\t\t$query .= $field->getName().',';\n\t\t\t$values[] = $field->getValue($this->entity);\n\t\t}\n\t\t\n\t\t// get right amount of parameters for the query\n\t\t$query = rtrim($query,',');\n\t\t$query .= \") VALUES(\";\n\t\tforeach($values as $value){\n\t\t\t$query.= '?,'; \n\t\t}\n\t\t$query = rtrim($query,',');\n\t\t$query .= ')';\n\t\t\n\t\t\n\t\t// excecute query.\n\t\ttry {\n\t\t\t$stmt = $this->dataBase->prepare ($query);\n\t\t\t$stmt->execute ($values);\n\t\t\t$stmt->closeCursor ();\n\t\t} catch ( PDOException $e ) {\n\t\t\tthrow $e;\n\t\t}\n\t}", "title": "" }, { "docid": "1f0eb4c85be1cb7b57d37ae5c9d4ea2d", "score": "0.5259428", "text": "public function __clone(){\r\n $this->QUERY_ID = null;\r\n $this->sLastQuery = null;\r\n $this->bInTransaction = false;\r\n $this->ROW = null;\r\n $this->ERRNO = null;\r\n $this->ERROR = null;\r\n $this->RECORD = null;\r\n $this->FIELDS = null;\r\n }", "title": "" }, { "docid": "acbba3c47247243c4e6f5eb2d99aac31", "score": "0.5247651", "text": "public function __clone() {\n $this->id = uniqid(); // Preserve uniqueness.\n }", "title": "" }, { "docid": "26b7c77dd7a9832d1de4a213d0ffc92f", "score": "0.5238202", "text": "public function create(){\n \n $attributes = $this->sanitized_attributes();\n $table_name = static::$table_name;\n $sql = \"INSERT INTO \" . $table_name . \" (\";\n $sql .= join(\", \", array_keys($attributes));\n $sql .= \") VALUES ('\";\n $sql .= join(\"', '\", array_values($attributes));\n $sql .= \"')\";\n \n if (self::$database->query($sql)) {\n \n return $this->{$table_name . \"_id\"} = self::$database->insert_id;\n \n // return true;\n } else {\n return false;\n }\n }", "title": "" }, { "docid": "18904715b79e59c3ced668b156abb4cf", "score": "0.5230001", "text": "public function create () {\n\t\tglobal $database;\n\t\t$attributes = $this->attributes();\n\t\t$sql = \"INSERT INTO \".self::$table_name.\" (\";\n\t\t$sql .= join(\", \", array_keys($attributes));\n\t\t$sql .= \") VALUES ('\";\n\t\t$sql .= join(\"', '\", array_values($attributes));\n\t\t$sql .= \"')\";\n\t\tif($database->query($sql)) {\n\t\t\t$this->id = $database->insert_id();\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "title": "" }, { "docid": "744ae1db81fc69faa33b8ce00a15ed51", "score": "0.52289915", "text": "public function create(){\r\n global $database;\r\n $attributes = $this->sanitized_attributes();\r\n\r\n // don't forget sql syntax and good habits:\r\n // INSERT INTO table (key, key) VALUES ('value', 'value')\r\n // single-quotes aroound all values\r\n // escape all values to prevent SQL injection\r\n\r\n $sql = \"INSERT INTO \". self::$table_name .\" (\";\r\n $sql .= join(\", \", array_keys($attributes));\r\n $sql .= \") VALUES ('\";\r\n $sql .= join(\"', '\", array_values($attributes));\r\n $sql .= \"')\";\r\n if($database->query($sql)){\r\n // we just inserted a record into DB, but we don't hava the id for this,\r\n // so we get the id using insert_id() and we have everything about this object\r\n $this->id = $database->insert_id();\r\n return true;\r\n }else{\r\n return false;\r\n }\r\n }", "title": "" }, { "docid": "918eedf4eb63baf2e4b1547653bb74cd", "score": "0.5219516", "text": "public function cloneMeta ($table = null) ;", "title": "" }, { "docid": "9c46bc32741cd51f5befd5099f4a0503", "score": "0.5210613", "text": "public function syncAttributes()\r\n {\r\n $this->original = $this->attributes;\r\n return $this;\r\n }", "title": "" }, { "docid": "f7ed33ce9e90857476a4b2631b091295", "score": "0.5209927", "text": "protected function _beforeSave()\n {\n parent::_beforeSave();\n $now = Mage::getSingleton('core/date')->gmtDate();\n if ($this->isObjectNew()) {\n $this->setCreatedAt($now);\n }\n $this->setUpdatedAt($now);\n return $this;\n }", "title": "" }, { "docid": "2e8411189feb103ac542650baba16468", "score": "0.51989055", "text": "public function __clone()\r\n\t{\r\n\t\t$this->_loaded = FALSE;\r\n\t}", "title": "" }, { "docid": "43e3bea25e547b0da00f9fb89767f11a", "score": "0.5193468", "text": "public function __clone()\n {\n if ($this->fromEntity) {\n $this->fromEntity = clone $this->fromEntity;\n }\n if ($this->toEntity) {\n $this->toEntity = clone $this->toEntity;\n }\n }", "title": "" }, { "docid": "d6f1deecac45d0fd5e50f3d6c120e87d", "score": "0.5193263", "text": "public function __clone()\n {\n $this->getMetas();\n // Now clone the wpPost reference\n $this->wpPost = clone $this->wpPost;\n // Set ID to null\n $this->setId(null);\n // Since the new post is unsaved, we'll have to add all meta values\n $this->refreshMetaInput(false);\n }", "title": "" }, { "docid": "edab1209b9f5b11c36640716f99a7bd4", "score": "0.5189814", "text": "public function save()\n {\n $columns = $this->getTableColumns();\n $attributes = [];\n\n foreach ($columns as $column)\n {\n // if(empty($this->{$column})) { continue; }\n if(! empty($this->fillable))\n {\n if(\\in_array($column, $this->fillable))\n {\n $attributes[$column] = $this->{$column};\n }\n\n } else {\n\n $attributes[$column] = $this->{$column};\n }\n }\n\n if(! empty($this->guarded))\n {\n foreach ($this->guarded as $guarded)\n {\n if(isset($attributes[$guarded]))\n {\n unset($attributes[$guarded]);\n }\n }\n }\n\n //dump($attributes);\n //dd($this);\n\n # Process\n $id = (int) $this->getAttribute('id');\n\n $manager = self::manager()->setTable($this->getTable());\n\n if($id)\n {\n $manager->update($attributes, $id);\n } else{\n $manager->insert($attributes);\n $this->setAttribute('id', self::query()->lastId());\n }\n }", "title": "" }, { "docid": "a4444a32cf86081fac7fdd92ea1f1edf", "score": "0.51887125", "text": "protected function _create() {\n\t\tif ($this->loaded() OR $this->_pkv)\n\t\t\tthrow new Exception('Can\\'t recreate existing row');\n\t\t\n\t\t$filtered = array_filter($this->_data);\n\t\tif ( ! count($filtered))\n\t\t\tthrow new Exception('Nothing to insert');\n\t\t\n\t\t$valuePrep = array_map(function($item) {\n\t\t\treturn '?';\n\t\t}, $filtered);\n\n\t\t$query = str_replace(\n\t\t\t[':columns', ':values'],\n\t\t\t[implode(', ', array_keys($filtered)), implode(', ', $valuePrep)],\n\t\t\t\"INSERT INTO {$this->_table} (:columns) VALUES (:values)\"\n\t\t);\n\n\t\t$q = Database::get_pdo()->prepare($query);\n\t\t$q->execute(array_values($filtered));\n\t\t$id = Database::get_pdo()->lastInsertId();\n\n\t\t// To insure data integrity, load the model anew\n\t\t$this->_load_data($id);\n\n\t\treturn TRUE;\n\t}", "title": "" }, { "docid": "fd9c449cee65bb2164a258c32e372172", "score": "0.51885664", "text": "public function __clone() {\n\t\t\tparent::__clone();\n\t\t\t$this->blnSaveHelpers = false;\n\t\t}", "title": "" }, { "docid": "c8a49a332d7d40282f85f80558ead473", "score": "0.5184813", "text": "public function __wakeup() {\n // Restore ReflectionClass and properties\n $this->reflClass = new ActiveEntityReflectionClass($this->name);\n\n foreach($this->fieldMappings as $field => $mapping) {\n if(isset($mapping['declared'])) {\n $reflField = new ActiveEntityReflectionProperty($mapping['declared'], $field);\n } else {\n $reflField = $this->reflClass->getProperty($field);\n }\n $reflField->setAccessible(true);\n $this->reflFields[$field] = $reflField;\n }\n \n foreach($this->associationMappings as $field => $mapping) {\n if(isset($mapping['declared'])) {\n $reflField = new ActiveEntityReflectionProperty($mapping['declared'], $field);\n } else {\n $reflField = $this->reflClass->getProperty($field);\n }\n $reflField->setAccessible(true);\n $this->reflFields[$field] = $reflField;\n }\n }", "title": "" }, { "docid": "32bce1270d2789356370e3b61140af6b", "score": "0.51762027", "text": "public function __clone()\n\t{\n\t\t$this->_frozen = FALSE;\n\t}", "title": "" }, { "docid": "cb2fb2054273a91876cc71c18e6102df", "score": "0.5170942", "text": "public function __clone()\n {\n parent::__clone();\n\n $this->state = self::STATE_DIRTY;\n }", "title": "" }, { "docid": "3def409823614f2eb4d953481d8d6d42", "score": "0.51581556", "text": "public function save() {\n\n $this->get(\"id\") ? $this->_update() : $this->_create();\n return $this;\n\n }", "title": "" }, { "docid": "d8dc75deed797e6062f2a1c96675dabf", "score": "0.51578784", "text": "public function __clone(){\n if (is_object($this->_field)) {\n $this->_field = clone $this->_field;\n }\n }", "title": "" }, { "docid": "1c28b11e441fd89dd31d49b7a1906b97", "score": "0.5145673", "text": "public function __clone()\n {\n // Iterate over all properties on the current object.\n foreach (get_object_vars($this) as $property => $value) {\n $this->$property = \\garethp\\ews\\Utilities\\cloneValue($value);\n }\n }", "title": "" }, { "docid": "1c7316889cb91e95ad45df15ba097b8c", "score": "0.51455307", "text": "public function reload()\n {\n $record = $this->getDBTable()->fetch($record->getId());\n \n foreach ($new as $key=>$value) {\n $this->$key = $value;\n }\n \n return $this;\n }", "title": "" }, { "docid": "f55ac1adf1d12d69f10df5c4cb34ea59", "score": "0.51437885", "text": "public function __clone()\n {\n $this->type = clone $this->type;\n $this->manufacturer = clone $this->manufacturer;\n $this->brand = clone $this->brand;\n $this->display = clone $this->display;\n }", "title": "" }, { "docid": "d8d59e0aac1606abc9eafdd774540a18", "score": "0.51366603", "text": "public function refresh()\r\n {\r\n if (! $this->exists) {\r\n return $this;\r\n }\r\n\r\n $this->setRawAttributes(\r\n $this->newManager()->load($this->getKey())\r\n );\r\n\r\n return $this;\r\n }", "title": "" }, { "docid": "365785c4c05782680d439d11a68bc6cc", "score": "0.5136541", "text": "public static function instantation($the_record){ //Its the same as $row\n \n $the_object = new self;\n \n// $the_object->id =$found_user['id'];\n// $the_object->username =$found_user['username'];\n// $the_object->password =$found_user['password'];\n// $the_object->First_Name =$found_user['first_name'];\n// $the_object->Last_Name =$found_user['last_name'];\n// \n foreach ($the_record as $the_attribute =>$value){\n if ($the_object->has_the_attribute($the_attribute)){\n \n $the_object->$the_attribute=$value; // Value is attribute in database\n } \n }\n return $the_object; \n \n }", "title": "" }, { "docid": "c2a35358340e4534438e88e3f1670f4a", "score": "0.5135963", "text": "public function __construct($data, ORM $parent, $is_new = false)\n\t{\n\t\t$this->_data = $data;\n\t\t$this->_parent = $parent;\n\n\t\t$this->_newEntry = $is_new;\n\t\t$this->_idField = $parent->getIDColumn();\n\n\t\t//for new entry every field is dirty\n\t\tif($is_new)\n\t\t{\n\t\t\t$this->forceAllDirty();\n\t\t}\n\t}", "title": "" }, { "docid": "6f16ea74a64b0e791d10832a376669fb", "score": "0.51199126", "text": "public static function NewRecord($tableName, $inKeyIdName = 'keyId', $inFc = '40', $inFcKeyName = 'none') {\r\n $dbConnection = site_getDbConnection();\r\n\r\n // If no facility code is provided, a default value is obtained in config_main.php.\r\n // Facility code is optional, so one of two INSERT statements will be used for the new record.\r\n if ($inFcKeyName != \"none\") {\r\n $qNew = \"INSERT INTO $tableName($inFcKeyName) VALUES($inFc);\";\r\n } else {\r\n $qNew = \"INSERT INTO $tableName() VALUES();\";\r\n }\r\n\r\n $rNew = mysqli_query($dbConnection, $qNew);\r\n\r\n // After the record has been created, get the new primary key value\r\n $qNew = \"SELECT MAX($inKeyIdName) FROM $tableName;\";\r\n $rNew = mysqli_query($dbConnection, $qNew);\r\n $keyId = ADAPT_mysqli_result($rNew, 0);\r\n\r\n // Call the Initialize function again, so that this object represents what is in the new record.\r\n return new self($tableName, $keyId, $inKeyIdName, $inFc, $inFcKeyName);\r\n }", "title": "" }, { "docid": "5163cb3c86e5bc178165a3234b1ba1b0", "score": "0.51123846", "text": "public function __clone()\n {\n $this->data = array_map(function ($data) {\n return is_object($data) ? clone $data : $data;\n }, $this->data);\n }", "title": "" }, { "docid": "05c2d962eb10330084053a82e2bad006", "score": "0.51122886", "text": "public function createTable()\n\t{\n\t\t$table = $this->getTableName();\n\t\t$indexes = $this->defineIndexes();\n\t\t$attributes = $this->getAttributeConfigs();\n\t\t$columns = array();\n\n\t\t// Add any Foreign Key columns\n\t\tforeach ($this->getBelongsToRelations() as $name => $config)\n\t\t{\n\t\t\t$columnName = $config[2];\n\n\t\t\t// Is the record already defining this column?\n\t\t\tif (isset($attributes[$columnName]))\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$required = !empty($config['required']);\n\t\t\t$columns[$columnName] = array('column' => ColumnType::Int, 'required' => $required);\n\n\t\t\t// Add unique index for this column?\n\t\t\t// (foreign keys already get indexed, so we're only concerned with whether it should be unique)\n\t\t\tif (!empty($config['unique']))\n\t\t\t{\n\t\t\t\t$indexes[] = array('columns' => array($columnName), 'unique' => true);\n\t\t\t}\n\t\t}\n\n\t\t// Add all other columns\n\t\tforeach ($attributes as $name => $config)\n\t\t{\n\t\t\t// Add (unique) index for this column?\n\t\t\t$indexed = !empty($config['indexed']);\n\t\t\t$unique = !empty($config['unique']);\n\n\t\t\tif ($unique || $indexed)\n\t\t\t{\n\t\t\t\t$indexes[] = array('columns' => array($name), 'unique' => $unique);\n\t\t\t}\n\n\t\t\t$columns[$name] = $config;\n\t\t}\n\n\t\t$addIdColumn = true;\n\t\t$pks = $this->primaryKey();\n\n\t\tif (!is_array($pks))\n\t\t{\n\t\t\t$pks = array($pks);\n\t\t}\n\n\t\tforeach ($pks as $pk)\n\t\t{\n\t\t\tif (isset($columns[$pk]))\n\t\t\t{\n\t\t\t\t$columns[$pk]['primaryKey'] = true;\n\t\t\t\t$addIdColumn = false;\n\t\t\t}\n\t\t}\n\n\t\t// Create the table\n\t\tcraft()->db->createCommand()->createTable($table, $columns, null, $addIdColumn);\n\n\t\t// Create the indexes\n\t\tforeach ($indexes as $index)\n\t\t{\n\t\t\t$columns = ArrayHelper::stringToArray($index['columns']);\n\t\t\t$unique = !empty($index['unique']);\n\t\t\tcraft()->db->createCommand()->createIndex($table, implode(',', $columns), $unique);\n\t\t}\n\t}", "title": "" }, { "docid": "ae2e0aa2258cf2f5db5b20f4137bc661", "score": "0.5112074", "text": "public function fill(array $attributes)\r\n {\r\n foreach ($this->fillableFromArray($attributes) as $key => $value) {\r\n $key = $this->removeTableFromKey($key);\r\n\r\n if ($this->isFillable($key)) {\r\n $this->setAttribute($key, $value);\r\n }\r\n }\r\n\r\n return $this;\r\n }", "title": "" }, { "docid": "98f1fbcd868aec7d8c7609f0ada1eab7", "score": "0.51118046", "text": "public function save()\n {\n if ($this->definition->getTable()->updated() && $this->valid()) {\n\n if (!ActiveRecordDB::getDatabase()->pdo->inTransaction()) {\n $createdTransaction = ActiveRecordDB::getDatabase()->pdo->beginTransaction();\n }\n\n $row = $this->compileTable($this->definition->getTable());\n\n if ($this->definition->getTable()->getIdentifier()->getValue() != null) {\n\n ActiveRecordDB::getDatabase()->update(\n $this->definition->getTable()->getName(),\n $row,\n self::createIdentifier($this->definition->getTable()->getIdentifier())\n );\n\n $this->definition->getTable()->refresh();\n ActiveRecordDB::getInstance()->debug();\n } else {\n ActiveRecordDB::getDatabase()->insert($this->definition->getTable()->getName(), $row);\n $this->definition->getTable()->getIdentifier()->setValue(ActiveRecordDB::getDatabase()->id());\n $this->definition->getTable()->refresh();\n ActiveRecordDB::getInstance()->debug();\n }\n\n foreach ($this->definition->getRelationships() as $relationship) {\n $relationship->save();\n }\n\n if (isset($createdTransaction)) {\n ActiveRecordDB::getDatabase()->pdo->commit();\n }\n }\n }", "title": "" }, { "docid": "7fe1152a6817b9e5e0828a256efd8b0d", "score": "0.51079583", "text": "public function __clone()\n {\n $vertices = $this->verticesStorage;\n $this->verticesStorage = array();\n $this->vertices = VerticesMap::factoryArrayReference($this->verticesStorage);\n\n $edges = $this->edgesStorage;\n $this->edgesStorage = array();\n $this->edges = Edges::factoryArrayReference($this->edgesStorage);\n\n $map = array();\n foreach ($vertices as $originalVertex) {\n assert($originalVertex instanceof Vertex);\n\n $vertex = new Vertex($this, $originalVertex->getId());\n $vertex->getAttributeBag()->setAttributes($originalVertex->getAttributeBag()->getAttributes());\n\n // create map with old vertex hash to new vertex object\n $map[spl_object_hash($originalVertex)] = $vertex;\n }\n\n foreach ($edges as $originalEdge) {\n assert($originalEdge instanceof Edge);\n\n // use map to match old vertex hashes to new vertex objects\n $vertices = $originalEdge->getVertices()->getVector();\n $v1 = $map[spl_object_hash($vertices[0])];\n $v2 = $map[spl_object_hash($vertices[1])];\n\n // recreate edge and assign attributes\n if ($originalEdge instanceof EdgeUndirected) {\n $edge = $this->createEdgeUndirected($v1, $v2);\n } else {\n $edge = $this->createEdgeDirected($v1, $v2);\n }\n $edge->getAttributeBag()->setAttributes($originalEdge->getAttributeBag()->getAttributes());\n }\n }", "title": "" }, { "docid": "b67b476e72b1a8fd5f169cb0c4c115c6", "score": "0.5106143", "text": "public function createModelObject($data = null)\n {\n return clone $this->getModelObjectPrototype();\n }", "title": "" }, { "docid": "15ac76024aa1171b6ef1affb0963e6de", "score": "0.51045305", "text": "public function __clone() {\n $this->name = null;\n $this->value = null;\n }", "title": "" }, { "docid": "90f888536d6f26b486e22ccab15e0cbb", "score": "0.5104371", "text": "function __clone(){\n foreach($this as $name => $value){\n if(gettype($value)=='object'){\n $this->$name= clone($this->$name);\n }\n }\n }", "title": "" }, { "docid": "cc13865cf1ae979274c1e5230341a6a5", "score": "0.5103789", "text": "public function __clone(){}", "title": "" }, { "docid": "cc13865cf1ae979274c1e5230341a6a5", "score": "0.5103789", "text": "public function __clone(){}", "title": "" }, { "docid": "cc13865cf1ae979274c1e5230341a6a5", "score": "0.51035595", "text": "public function __clone(){}", "title": "" }, { "docid": "c004efd4b7c6de0b34942b4fc0a86301", "score": "0.5095811", "text": "public function Create() {\n $this->IsNew = TRUE;\n $this->ID = 0;\n }", "title": "" }, { "docid": "c91fcdb4c4e1e2f57b59d0373bd641e5", "score": "0.50877005", "text": "public function newRecord()\n\t{\n\t\treturn $this->executeEmpty()->newRecord();\n\t}", "title": "" }, { "docid": "aea2bf707cb5fe803c2923c69f71e4a8", "score": "0.50828", "text": "function reset()\n\t{\n\t\t$k = $this->_tbl_key;\n\t\tforeach ($this->getProperties() as $name => $value)\n\t\t{\n\t\t\tif($name != $k)\n\t\t\t{\n\t\t\t\t$this->$name\t= $value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "82493984b24b8fe0db228be4297612fa", "score": "0.50798774", "text": "public function create() {\n\t\t\tglobal $db;\n\t\t\n\t\t\t$attributes = $this->sanitized_attributes();\n\t\t\t\t\t\n\t\t\t$sql = \"INSERT INTO \" . self::$table . \" (\";\n\t\t\t$sql .= join(\", \", array_keys($attributes)); \n\t\t\t$sql .= \") VALUES ('\";\n\t\t\t$sql .= join(\"', '\", array_values($attributes));\n\t\t\t$sql .= \"')\";\n\t\t\tif ($db->query($sql)) {\n\t\t\t\t$this->id = $db->insert_id();\n\t\t\t\treturn true;\n\t\t\t} else {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "346a5ea58be078ae52c139627cd901c9", "score": "0.50755906", "text": "public function copy()\n\t\t{\n\t\t\t$copy = new static();\n\t\t\t\n\t\t\ttrace('copy of %s results in %s', typeid($this), typeid($copy));\n\t\t\t\n\t\t\tforeach($this->attributes as $attribute)\n\t\t\t{\n\t\t\t\t$copy->setAttribute($attribute->getName(), $attribute->getValue());\n\t\t\t}\n\n\t\t\t// if the constructor causes elements to be created, they'd be \n\t\t\t// duplicated by the next loop.\n\t\t\treturn $copy;\n\t\t}", "title": "" }, { "docid": "22ecb1cbf47407b43792ea9482a1746a", "score": "0.50714666", "text": "protected function insertRecord(): void\n {\n $fetchKey = false;\n $primaryKeys = $this->getDBTable()->getPrimaryKeys();\n $fields = $this->getDBTable()->getFields();\n\n $insert = $this->getSqlDriver()->insert();\n $insert->table($this->getDBTable()->getFQN());\n\n foreach ( $fields as $field )\n {\n $fieldName = $field->getName();\n\n // Do not include a primary key field that doesn't have a value\n // assigned. At this point, going to assume an auto incrementing\n // field.\n if ( in_array($fieldName, $primaryKeys) )\n {\n if ( empty($this->get($fieldName)) )\n {\n continue;\n }\n }\n\n $tblFv = $field->getSqlBoundValue($this->get($fieldName));\n $marker = $tblFv->getValueMarker();\n $binding = $tblFv->getBoundValues();\n\n if ( $marker === null )\n {\n continue;\n }\n\n $sqlFv = new DBSql\\Field\\Value($fieldName);\n $sqlFv->setBoundValues( $binding )\n ->setValueMarker( $marker );\n\n $insert->addFieldValue($sqlFv);\n }\n\n // PostgreSQL needs to have a RETURNING statement added with the\n // primary keys for the table assigned to it.\n if ( $this->getDBTable() instanceof DBTable\\PostgreSQL )\n {\n if ( !empty($primaryKeys) )\n {\n foreach ( $primaryKeys as $primaryKey )\n {\n $insert->returning($primaryKey);\n $fetchKey = true;\n }\n }\n }\n\n $statement = $this->getDb()->prepare($insert->output());\n $statement->execute($insert->getBindings());\n\n if ( $fetchKey )\n {\n $result = $statement->fetch(PDO::FETCH_ASSOC);\n\n foreach ( $primaryKeys as $primaryKey )\n {\n $this->set($primaryKey, $result[$primaryKey]);\n }\n }\n\n $this->_sqlStatement = $insert;\n }", "title": "" }, { "docid": "adf96d6601a76b43c507420d0131ae07", "score": "0.5066551", "text": "public function newModel()\n {\n return static::getSchema()->newModel();\n }", "title": "" }, { "docid": "5f6e65ac9de9c57a695659fdcd1f7e6a", "score": "0.50618315", "text": "public function duplicate($parent = null, $clid = null)\n\t{\n\t\t//\tLAZY: Might not be the fastest and most elegant way of checking if given class is crm_offer_obj::CLID or a subclass.\n\t\tif (is_class_id($clid) and !obj(null, array(), $clid)->is_a(crm_offer_obj::CLID))\n\t\t{\n\t\t\tthrow new awex_crm_offer_duplication(\"Cannot duplicate object! Given class is not crm_offer_obj::CLID nor a subclass!\");\n\t\t}\n\t\t$clid = is_class_id($clid) ? $clid : crm_offer_obj::CLID;\n\t\t$parent = is_oid($parent) ? $parent : $this->parent();\n\n\t\t$new_object = obj(null, array(), $clid);\n\t\t$new_object->set_parent($parent);\n\t\tforeach($this->get_property_list() as $pn => $pd)\n\t\t{\n\t\t\tif($new_object->is_property($pn) and !in_array($pn, array(\"state\", \"result\", \"result_object\", \"price_object\")))\n\t\t\t{\n\t\t\t\t$new_object->set_prop($pn, $this->prop($pn));\n\t\t\t}\n\t\t}\n\t\t$new_object->set_prop(\"state\", self::STATE_NEW);\n\t\t$new_object->save();\n\n\t\t$this->duplicate_applied_price_components($new_object);\n\n\t\tforeach ($this->get_rows() as $row)\n\t\t{\n\t\t\t$new_row = new object($row->save_new(), array(), crm_offer_row_obj::CLID);\n\t\t\t$new_row->set_prop(\"offer\", $new_object->id());\n\t\t\t$new_row->save();\n\n\t\t\t$row->duplicate_applied_price_components($new_row);\n\t\t}\n\n\t\t$new_object->save();\n\n\t\treturn $new_object;\n\t}", "title": "" }, { "docid": "08c45c2a4d1e5e729ac6da993385ef50", "score": "0.50604457", "text": "public function testCreateOrUpdateWithExistingRecord()\n {\n\n // Create item and servers.\n $item = $this->_item();\n $server1 = $this->_server();\n $server2 = $this->_server();\n\n // Create object.\n $object = $this->_object($item, $server1, 'pid:test', 'DC,content');\n\n // Capture starting count.\n $count = $this->objectsTable->count();\n\n // Update record.\n $object = $this->objectsTable->createOrUpdate(\n $item, $server2->id, 'pid:new', array('DC', 'new'));\n\n // Check for count.\n $this->assertEquals($this->objectsTable->count(), $count);\n\n // Check attributes.\n $this->assertEquals($object->item_id, $item->id);\n $this->assertEquals($object->server_id, $server2->id);\n $this->assertEquals($object->pid, 'pid:new');\n $this->assertEquals($object->dsids, 'DC,new');\n\n }", "title": "" }, { "docid": "55b5b55d71b90372f2f44552294ae8c6", "score": "0.50526094", "text": "public function modifyTable()\n {\n $table = $this->getTable();\n if (!$table->hasPrimaryKey() && !$table->hasBehavior('concrete_inheritance')) {\n $columnAttributes = array_merge(array('primaryKey' => 'true'), $this->getParameters());\n $this->getTable()->addColumn($columnAttributes);\n }\n }", "title": "" }, { "docid": "18837584b7c0a962f692a948fb647082", "score": "0.50259125", "text": "public function __clone() {\n $this->a = clone $this->a;\n $this->b = clone $this->b;\n parent::__clone();\n }", "title": "" }, { "docid": "dc20776772a67e4f803741b905248390", "score": "0.5025683", "text": "function cloneObject() {\n $cloned = new Producto();\n\n $cloned->setIdproducto($this->idproducto); \n $cloned->setNombproducto($this->nombproducto); \n $cloned->setDescripcion($this->descripcion); \n $cloned->setLink($this->link); \n $cloned->setIdartesano($this->idartesano); \n $cloned->setAceptado($this->aceptado); \n $cloned->setEmpresa($this->empresa); \n $cloned->setNroenvio($this->nroenvio); \n $cloned->setNotificado($this->notificado); \n $cloned->setStock($this->stock); \n $cloned->setVentas($this->ventas); \n $cloned->setFormatofoto($this->formatofoto); \n $cloned->setPrecio($this->precio); \n $cloned->setMostrar($this->mostrar); \n $cloned->setFecha($this->fecha); \n $cloned->setComision($this->comision);\n\n return $cloned;\n }", "title": "" }, { "docid": "afb43a58fd2796dbcf282bf29f058fbc", "score": "0.50230145", "text": "protected function initNewRecord(): self\n {\n /** @var RecordFactory $recordFactory */\n $recordFactory = $this->recordFactory;\n\n $this->record = $recordFactory->build();\n\n return $this;\n }", "title": "" }, { "docid": "4e717b221a48cfd79650df2ccab3318e", "score": "0.5021785", "text": "public function createIfNotExists() : self\n {\n\n // Try to read.\n $this->read();\n\n // This is call to Entity own method. If PK is defined in this record after reading\n // than yeah - this record exists.\n if ($this->hasPrimaryKey() === false) {\n $this->create();\n }\n\n return $this;\n }", "title": "" }, { "docid": "eae87a00ccec0e193c41ec9b022e5a52", "score": "0.5016586", "text": "function createNewEntry( $doAllowPrimaryKeyUpdate=false ) \n { \n\t parent::createNewEntry( $doAllowPrimaryKeyUpdate );\n\t \n\t //$ccTransID = $this->getID(); \n\t $values = $this->getArrayOfValues();\n// \t echo \"<pre>\".print_r($values,true).\"</pre>\";\n\t \n\t if (isset($values['reg_id']))\n\t {\n\t \n\t\t // update balance owing column in cim_reg_registration table\n\t\t $singleReg = new RowManager_RegistrationManager($values['reg_id']);\n// \t\t $singleReg_list = $singleReg->getListIterator();\n// \t\t $singleReg_array = $singleReg_list->getDataList();\n// \t\t \n// \t\t reset($singleReg_array);\n// \t\t $record = current($singleReg_array);\n// \t\t $oldBalance = $record['registration_balance'];\n\t\t \n\t\t\t $balanceGetter = new FinancialTools();\n\t\t\t $balance = array();\n// \t\t\t $balance['registration_balance'] = $oldBalance - $record['cctransaction_amount'];\n\t\t\t $balance['registration_balance'] = $balanceGetter->simpleCalcBalanceOwing($values['reg_id']);\t\n\t\t\t $singleReg->loadFromArray( $balance );\n\t\t\t $singleReg->updateDBTable();\t\t\t\n\t\t }\t \n }", "title": "" }, { "docid": "290af5dd4c46861bab0deb20c5e0b462", "score": "0.5016476", "text": "public function create(array $attributes = []) \n {\n return parent::create($this->model->sanitizeToModelFillable($attributes));\n }", "title": "" }, { "docid": "2c182724ace0609b48c5739d9c14fc5e", "score": "0.5003125", "text": "function save() {\n\t\tglobal $database;\n\n\t\t// Get the MySQL columns to update\n\t\t$cols = implode(\",\", get_object_vars($this));\n\n\t\t// Get the values to update\n\t\t$vals = array();\n\t\tforeach(get_object_vars($this) as $key => $val) {\n\t\t\tif(!in_array($key, array_keys(get_class_vars('DatabaseObject')))) {\n\t\t\t\tif(!$this->new_row) {\n\t\t\t\t\tif(!strcmp($key, $this->_getPrimaryKey()))\n\t\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t$val = mysqli_real_escape_string($database->mysqli, $val);\n\t\t\t\t$vals[$key] = \"'$val'\";\n\t\t\t}\n\t\t}\n\n\t\t$values = implode(',', $vals);\n\n\t\t// Make those values usable for our MySQL class\n\t\t$keys = array_keys($vals);\n\t\tfor($i = 0; $i < sizeof($keys); $i++)\n\t\t\t$keys[$i] = \"`{$keys[$i]}`\";\n\n\t\t$cols = implode(\",\", $keys);\n\n\t\t// Get the table name from the class\n\t\t$table = strtolower(get_class($this));\n\n\t\tif($this->new_row) {\n\t\t\t$database->query(\"INSERT INTO $table ($cols) VALUES($values)\");\n\t\t\t$this->{$this->primary_key} = mysql_insert_id();\n\t\t\treturn(mysql_insert_id());\n\t\t}\n\t\telse {\n\t\t\t$updates = array();\n\t\t\tforeach($vals as $key => $value) {\n\t\t\t\tif((!in_array($key, array_keys(get_class_vars('DatabaseObject')))) && strcmp($key, $this->primary_key)) {\n\t\t\t\t\tarray_push($updates, \"`$key` = $value\");\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$values = implode(\",\", $updates);\n\t\t\t$key = $this->primary_key;\n\t\t\t$database->query(\"UPDATE $table SET $values WHERE `$key` = '{$this->primary_key_value}'\");\n\t\t}\n\t}", "title": "" }, { "docid": "02cb6eed3364f8e21818d1902c68181f", "score": "0.49988532", "text": "public function set_all_fields($row)\n {\n // This allows creating new rows without id values\n if ($row[$this->primary_key] != \"\")\n {\n $this->id_value = $row[$this->primary_key];\n $this->persisted = true;\n } else{\n $this->persisted = false;\n }\n\n foreach( array_keys( $row ) as $key )\n if ($key != $this->primary_key)\n\t$this->fields[ $key ] = $row[ $key ];\n $this->persisted = true;\n }", "title": "" } ]
13723369ee210991fbaeff150e6325a0
Display the specified resource.
[ { "docid": "f09c1dfb4964fd701730c9027e33cefa", "score": "0.0", "text": "public function show(Clothe $clothe)\n {\n return response()->json($clothe,200);\n }", "title": "" } ]
[ { "docid": "f379d94fc578937200b5c52c49012541", "score": "0.8565385", "text": "public function display($resource)\t\r\r\n\t{\r\r\n\t\t$this->sm->display($resource);\r\r\n\t}", "title": "" }, { "docid": "ac91646235dc2026e2b2e54b03ba6edb", "score": "0.8190437", "text": "public function show(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "56c1b3fa26b6d9cabf2dd64200068151", "score": "0.7232847", "text": "public function viewAction()\n\t{\n\t\t$id = $this->getRequest()->getParam('id');\n\t\t// Check to see if they specified id in the url and its a valid id\n\t\tif($id == null || !intval($id)) {\n\t\t\t// Redirect because to view a Resource, they have to specify one in the url\n\t\t\t$this->_redirect($this->view->baseUrl('/resources/'));\n\t\t\texit();\n\t\t}\n\n\t\t// Get the resource from the database\n\t\t$this->view->resource = Application_Model_Document_Resource::find($id);\n\t}", "title": "" }, { "docid": "f7b7d1b1441808ba8a10baf202dd812d", "score": "0.7231613", "text": "function viewResource() {\n if ( !isset($_GET[\"resourceId\"]) || !$_GET[\"resourceId\"] ) {\n homepage();\n return;\n }\n \n $results = array();\n $results['resource'] = Resource::getById( (int)$_GET[\"resourceId\"] );\n $results['pageTitle'] = $results['resource']->title . \" | Couch To Code\";\n require( $TEMPLATE_PATH . \"/viewResource.php\" );\n}", "title": "" }, { "docid": "2469246bfacb305518866aabf78fdf25", "score": "0.711776", "text": "public function show(Resource $resource)\n {\n return view('frontend.resources.show', compact('resource'));\n }", "title": "" }, { "docid": "ecd32fc705283cc0e1ddec209c43aec8", "score": "0.69488674", "text": "public function displayResourceForm($resource)\n {\n $childServices = new Setting('child_services');\n\n ob_start();\n include(VIEW_PATH . '/child-resources-edit.phtml');\n $resource_content = ob_get_contents();\n ob_end_clean();\n\n print $resource_content;\n }", "title": "" }, { "docid": "fd732d21f7abd3682ae6c91a53d78e2a", "score": "0.6865356", "text": "function display($resource_name, $cache_id = null, $compile_id = null)\r\n {\r\n header(\"content-type:text/html; charset=UTF-8\");\r\n $this->fetch($resource_name, $cache_id, $compile_id, true);\r\n }", "title": "" }, { "docid": "c20bab39c09603f7d64ce51657305feb", "score": "0.6764596", "text": "public function show($resource, $id)\n {\n $fields = $this->getModelAttributes();\n $model = $this->model->findOrFail($id);\n return view('admin::resource.show', [\n 'id' => $id,\n 'fields' => $fields,\n 'model' => $model,\n 'model_name' => $this->modelName,\n ]);\n }", "title": "" }, { "docid": "cdbc9ca49f6e1cb18dac8bcf70572df8", "score": "0.654542", "text": "public function show($resourceId)\n {\n $resource = $this->resource->with('fields')->where('slug', $this->slug)->first();\n $model = $this->getModel($resource);\n $entity = $model::with('objects')->where('id', $resourceId)->first();\n $objects = Object::all();\n\n return view('laramanager::resource.show', compact('resource', 'entity', 'objects'));\n }", "title": "" }, { "docid": "754481a7bcbe790bd36063183e1ce547", "score": "0.65097207", "text": "public function show($id)\n {\n // GET /resources/{id}\n echo 'This is ResourceController-'.\"<span style=\\\"color: red\\\">show-{$id}</span>\".' function for GET request';\n }", "title": "" }, { "docid": "f5f88a360f9e8bba14d5cdf454b19db2", "score": "0.63916266", "text": "public function getAction()\n {\n $id = $this->_getParam('id', 0);\n\n $this->view->id = $id;\n $this->view->message = sprintf('Resource #%s', $id);\n $this->_response->ok();\n }", "title": "" }, { "docid": "44d76948504b6adb4e16305ebd5913b0", "score": "0.628938", "text": "function view($id = null) {\r\n\t $this->__requireLogin();\r\n\t\tif (!$id) {\r\n\t\t\t$this->flash(__('Invalid Resource', true), array('action'=>'index'));\r\n\t\t}\r\n\t\t$file = $this->Resource->findById($id);\r\n \r\n header('Content-type: ' . $file['Resource']['type']);\r\n header('Content-length: ' . $file['Resource']['size']);\r\n header('Content-Disposition: attachment; filename=\"'.$file['Resource']['name'].'\"');\r\n echo $file['Resource']['data'];\r\n exit;\r\n\t}", "title": "" }, { "docid": "48b73977d6fc027cde6cd073ae8022ea", "score": "0.6241571", "text": "public function show($id)\n {\n $resource = Resource::find($id);\n return view('resources.show')->with('resource', $resource);\n }", "title": "" }, { "docid": "40f975ff71d90c3f5edf0cf754386eab", "score": "0.6150558", "text": "public function displayPlain($resource_name, $cache_id = null, $compile_id = null) {\n\t\t\tparent::display($resource_name, $cache_id, $compile_id);\n\t\t}", "title": "" }, { "docid": "ad3f5bc00574f3d97b19728b6e3e0bbf", "score": "0.61076814", "text": "public function show(ResourceBuilder $resource)\n {\n return $resource\n ->setId($this->route->parameter('id'))\n ->setOption('map', $this->route->parameter('map'))\n ->setOption('read', true)\n ->response(\n $this->route->parameter('namespace'),\n $this->route->parameter('stream')\n );\n }", "title": "" }, { "docid": "73f64795d6bc2b94d2d47da1cfe131e9", "score": "0.60787934", "text": "public function show($id)\n\t{\n\t\t$this->layout->nest('content', $this->view, array('route' => $this->resource));\n\t}", "title": "" }, { "docid": "6bd053b923b63a1f9a1cfc5ee94f9a92", "score": "0.6056226", "text": "public static function display () {\n\t\t$r = self::get();\n\t\techo $r;\n\t}", "title": "" }, { "docid": "f1919612984d797496fb91a1df6bfc28", "score": "0.60360175", "text": "public function show(Resident $resident)\n {\n //\n }", "title": "" }, { "docid": "a0bc85eba3bf9a7248de034fbbb25784", "score": "0.6007803", "text": "public function display()\n {\n echo $this->getResponse();\n }", "title": "" }, { "docid": "3b3cd10f692f83d4dc9bbb65b5a42273", "score": "0.5948826", "text": "public function index(Resource $resource)\n {\n session(['resourceId' => $resource->id]);\n\n $credits = $this->getCredits();\n\n $noSideBar = true;\n\n // Show the page\n return view('admin.credit.index', compact('resource', 'credits', 'noSideBar'));\n }", "title": "" }, { "docid": "924979ab90976d4cf30edfc605f8b0a4", "score": "0.5944731", "text": "public function resolveForDisplay($resource, $attribute = null)\n {\n parent::resolveForDisplay($resource, $attribute);\n\n $attribute = $attribute ?? $this->attribute;\n\n $properties = $this->getPropertiesWithMetaForDisplay($resource, $attribute);\n\n $this->resolveResourceFields($resource, $attribute, $properties);\n }", "title": "" }, { "docid": "5d8393b27071ea3dea23f88f54ed88d2", "score": "0.5931804", "text": "protected function showResourceView($id)\n\t{\n\n\t\t$element = $this->getElements($id);\n\t\treturn Response::view('adm/Obs/element', array('data' => $element));\n\n\t}", "title": "" }, { "docid": "e7087dc02ae8702a512361ac22fc4c1b", "score": "0.59251773", "text": "public function showAction()\n\t{\n\t\t$file = $this->_fileModel->getFileById($this->getRequest()->getParam('id'));\n\n\t\t$filename = $file->filename;\n\n\t\tif ($file->getThumb()) {\n\t\t\t$filename = $file->getThumb();\n\t\t}\n\t\t$this->_helper->SendFile(Zend_Registry::get('config')->directories->uploads.$filename, $file->mimetype, array('disposition' => 'inline'));\n\t\texit();\n\t}", "title": "" }, { "docid": "edcfd48bc84396ce018d75bad0445dd1", "score": "0.59243864", "text": "function presenting_resource($resource)\n { \n return event(new \\Core\\Crud\\Events\\PresentingResource($resource)); \n }", "title": "" }, { "docid": "aade75262be1495917e772f7186d1ef6", "score": "0.5920925", "text": "public function displayURI()\n\t\t{\n\n\t\t\t//Look up template from url (processed by FileDispatcher)\n\t\t\t$buffer = parent::fetch('file:'.FileDispatcher::getFilePath());\n\n\t\t\tparent::assignGlobal('buffer', $buffer);\n\n\t\t\t//Select Container and look up from FileDispatcher\n\t\t\t$container = parent::getTemplateVars('container');\n\n\t\t\tif(!isset($container))\n\t\t\t\t$container = 'default.tpl';\n\t\t\t//Display container\n\n\t\t\tparent::display('ember_container:'.$container);\n\t\t}", "title": "" }, { "docid": "926f5a0c2f718fd012ee6af0eb82bb93", "score": "0.5911495", "text": "public function show(Retiro $retiro)\n {\n //\n }", "title": "" }, { "docid": "b0c30b37c914212f6751d7af803d3c9c", "score": "0.5878103", "text": "public function show(Fetch $fetch)\n {\n //\n }", "title": "" }, { "docid": "fd728130e464c7ca0e936873b067ad9b", "score": "0.5873589", "text": "public function index()\n {\n $resource = $this->resource->with('fields')->where('slug', $this->slug)->first();\n\n $select = ['id'];\n $eagerLoad = [];\n foreach($resource->fields as $field)\n {\n if($field->list) $select[] = $field->slug;\n\n if($field->type == 'relational')\n {\n $eagerLoad[] = $field->data('method');\n }\n }\n\n $model = $this->getModel($resource);\n $entities = $model::with($eagerLoad)->select($select)->get();\n\n $hasObjects = false;\n if(method_exists($model, 'objects')) $hasObjects = true;\n\n return view('laramanager::resource.index', compact('resource', 'entities', 'hasObjects'));\n }", "title": "" }, { "docid": "8f6a1062ec77ffb509e4d3ffaf7b3ff0", "score": "0.5872246", "text": "public\tfunction\tshow($id)\n\t\t\t\t{\n\t\t\t\t\t//\n\t\t\t\t}", "title": "" }, { "docid": "d7ce48ce019e0bea04d049b9105b5e4d", "score": "0.58685344", "text": "public function edit(Resource $resource)\n {\n return view('dashboard.resources.edit', compact('resource'));\n }", "title": "" }, { "docid": "c37bc8432dc699eb4868713404eb44df", "score": "0.5867447", "text": "public function displayAction() {\n // set filters and validators for GET input\n $filters = array(\n 'id' => array('HtmlEntities', 'StripTags', 'StringTrim')\n );\n $validators = array(\n 'id' => array('NotEmpty', 'Int')\n );\n $input = new Zend_Filter_Input($filters, $validators);\n $input->setData($this->getRequest()->getParams());\n\n // test if input is valid\n // retrieve requested record\n // attach to view\n if ($input->isValid()) {\n $q = Doctrine_Query::create()\n ->from('Tripjacks_Model_News n')\n ->where('n.newsid = ?', $input->id);\n $result = $q->fetchArray();\n if (count($result) == 1) {\n $this->view->news = $result[0];\n } else {\n throw new Zend_Controller_Action_Exception('Page not found', 404);\n }\n } else {\n throw new Zend_Controller_Action_Exception('Invalid input');\n }\n }", "title": "" }, { "docid": "47e747f99077c377d962c44054ba1f49", "score": "0.586655", "text": "public function action_show() {\n $this->render('show');\n }", "title": "" }, { "docid": "7c25d9175a0b8f2be9a3f3b0c4a64c29", "score": "0.5860501", "text": "public function showAction()\r\n\t{\r\n\t\t$this->loadLayout()->renderLayout();\r\n\t}", "title": "" }, { "docid": "afdef03db60b66fcaac5256155065eef", "score": "0.58447284", "text": "public function show()\n {\n $parameters = func_get_args();\n $id = end($parameters);\n\n $this->getPermissionClass()->canShowOrFail();\n $entry = $this->getEntry($id);\n\n $title = $this->getSingularModelName();\n SEO::setTitle($title);\n\n return view($this->getViewShow(), [\n 'title' => $title,\n 'entry' => $entry,\n ]);\n }", "title": "" }, { "docid": "699876e556a945a17b98cfd3fd402c79", "score": "0.5843976", "text": "public function show(RespondentResponse $respondentResponse)\n {\n //\n }", "title": "" }, { "docid": "173a672fb3fc108352b0a12fdf43c627", "score": "0.58403057", "text": "public function display($name, $context = array());", "title": "" }, { "docid": "fa8588667a1d890c9dfa26a352341bfd", "score": "0.58148795", "text": "public function showResourceForm(array $data);", "title": "" }, { "docid": "70aa9bc46f07e7c2bb6237a1a809da50", "score": "0.58115053", "text": "public function display(): void{\n\t\tif($this->checkPermissions())\n\t\t\t$this->render();\n\t}", "title": "" }, { "docid": "656fe493779bf91e119cf4af807d6ffc", "score": "0.5810919", "text": "public function show( )\n {\n //\n }", "title": "" }, { "docid": "89ba560285c74712b8199c0fc1766637", "score": "0.5805252", "text": "public function show($id)\n {\n // Nothing TODO ... yet\n }", "title": "" }, { "docid": "41e5ee3783ca0e67337c6b41b7d0ca62", "score": "0.57929444", "text": "public function display()\n {\n echo $this->fetch();\n }", "title": "" }, { "docid": "dffabbd39fa01d27e5385af66489771e", "score": "0.5784531", "text": "public function show()\n\t{\n\n\n\n\t}", "title": "" }, { "docid": "8479d09c5ed3e908dc1de9eefe3c1948", "score": "0.57744014", "text": "public function show($name)\n\t{\n\t\t\n\t}", "title": "" }, { "docid": "86c1cdcea2e8f7d9622836d391eb01a0", "score": "0.57640016", "text": "public function resources()\n {\n if($this->input->post('resource_id', false)) {\n $this->auth->restrict('Capacity_Building.Content.Create');\n $this->addOrEditResourceLink();\n $id = $this->input->post('resource_id');\n\n Template::redirect($this->resourceResourcesUrl.'/'.$id);\n } else {\n $this->auth->restrict('Capacity_Building.Content.View');\n $id = $this->uri->segment(5);\n $listView = $this->showResourceResourcesList($id);\n\n Template::set('backUrl', $this->homeScreenUrl);\n Template::set('listView', $listView);\n Template::render();\n }\n }", "title": "" }, { "docid": "f9398d1b2a35351b84b6f10fff87197f", "score": "0.57630813", "text": "public function showAction() {\n $id = $this->route_params['id'];\n $company = Company::getById($id);\n View::renderTemplate('Companies/show.html', [\n 'company' => $company\n ]);\n }", "title": "" }, { "docid": "1c17a048467bdd4665dff5a0b022922b", "score": "0.5749995", "text": "function ShowAction()\n\t\t{\n\t\t\t//retrieve post details\n\t\t\t//display post details\n\t\t}", "title": "" }, { "docid": "e3b51ebfe04703c114ab39fc729ba43b", "score": "0.5749091", "text": "public function show(Entry $entry)\n {\n //\n }", "title": "" }, { "docid": "8c6c92dca7be1af09c99f8f3d0192fb4", "score": "0.57394016", "text": "function display() {\n echo $this->get();\n }", "title": "" }, { "docid": "b805cdaee398222732d4781465289810", "score": "0.5737449", "text": "public function show($id)\n\t{\n \t//\n\t}", "title": "" }, { "docid": "63e8b96d2643a39f6b58a94ab06cc3e5", "score": "0.5724377", "text": "public function show() {\n if (!isset($_GET['id']))\n return call('application', 'error');\n\n // we use the given id to get the right course\n $course = Course::find($_GET['id']);\n require_once('views/courses/show.php');\n }", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "b5e7179ea7c94add1c1af50e9f9b7fdd", "score": "0.57208323", "text": "public function show($id)\n\t{\n\t\n\t}", "title": "" }, { "docid": "47171b843665ac85f7c5da2618a7ae0e", "score": "0.5718969", "text": "public function show($id) {}", "title": "" }, { "docid": "47171b843665ac85f7c5da2618a7ae0e", "score": "0.5718969", "text": "public function show($id) {}", "title": "" }, { "docid": "47171b843665ac85f7c5da2618a7ae0e", "score": "0.5718969", "text": "public function show($id) {}", "title": "" }, { "docid": "231df042c1c22328d0bccca36d00d4b3", "score": "0.5717272", "text": "public function showAction($id)\n {\n $bookRepository = new BookRepository();\n $book = $bookRepository->getOneById($id);\n\n if(null == $book){\n $errorMessage = 'no book found with id = ' . $id;\n $this->app->abort(404, $errorMessage);\n }\n\n $argsArray = [\n 'book' => $book\n ];\n $templateName = 'show';\n return $this->app['twig']->render($templateName . '.html.twig', $argsArray);\n }", "title": "" }, { "docid": "8beddd76b0dfd4ee8fbc7e77c7941f9d", "score": "0.57165015", "text": "public function display()\n \t{\n \t\tparent::display();\n \t}", "title": "" }, { "docid": "05ca915e5f597f0a1925a6b1a1e6afb0", "score": "0.57057405", "text": "public abstract function display();", "title": "" }, { "docid": "51bb50cf0d2068c55898b438773d4e90", "score": "0.5704464", "text": "public function show(Entry $entry) {\n //\n }", "title": "" }, { "docid": "12bf7179b06b190879842d1f1945365c", "score": "0.57026845", "text": "public function show( $id ) {\n\t\t//\n\t}", "title": "" }, { "docid": "12bf7179b06b190879842d1f1945365c", "score": "0.57026845", "text": "public function show( $id ) {\n\t\t//\n\t}", "title": "" }, { "docid": "12bf7179b06b190879842d1f1945365c", "score": "0.57026845", "text": "public function show( $id ) {\n\t\t//\n\t}", "title": "" }, { "docid": "12bf7179b06b190879842d1f1945365c", "score": "0.57026845", "text": "public function show( $id ) {\n\t\t//\n\t}", "title": "" }, { "docid": "7b283ba1c0546a155efc95a44dd0f9cf", "score": "0.56981397", "text": "public function show(Response $response)\n {\n //\n }", "title": "" }, { "docid": "7b283ba1c0546a155efc95a44dd0f9cf", "score": "0.56981397", "text": "public function show(Response $response)\n {\n //\n }", "title": "" }, { "docid": "7b283ba1c0546a155efc95a44dd0f9cf", "score": "0.56981397", "text": "public function show(Response $response)\n {\n //\n }", "title": "" }, { "docid": "2204f8d554d9525d60e0aba235700bfd", "score": "0.56858474", "text": "public function locate($resource);", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" } ]
aa7e39565cb56b307d4bfa6573de1807
/ / Function for Find Highest saleing Product /
[ { "docid": "67d15bf696bd6117ac83a7f4fd7312c0", "score": "0.7550604", "text": "function find_higest_saleing_product($limit){\n global $db;\n $sql = \"SELECT p.name, COUNT(s.product_id) AS totalSold, SUM(s.qty) AS totalQty\";\n $sql .= \" FROM sales s\";\n $sql .= \" LEFT JOIN products p ON p.id = s.product_id \";\n $sql .= \" GROUP BY s.product_id\";\n $sql .= \" ORDER BY SUM(s.qty) DESC LIMIT \".$db->escape((int)$limit);\n return $db->query($sql);\n }", "title": "" } ]
[ { "docid": "680797b39676f53d228f612c5e9deb9d", "score": "0.7552066", "text": "function find_higest_saleing_product($limit){\n global $db;\n $sql = \"SELECT p.name, COUNT(s.product_id) AS totalSold, SUM(s.qty) AS totalQty\";\n $sql .= \" FROM sales s\";\n $sql .= \" LEFT JOIN producto p ON p.id = s.product_id \";\n $sql .= \" GROUP BY s.product_id\";\n $sql .= \" ORDER BY SUM(s.qty) DESC LIMIT \".$db->escape((int)$limit);\n return $db->query($sql);\n }", "title": "" }, { "docid": "7b75cc9f5110c18b5904ebe90e397585", "score": "0.73537266", "text": "public static function highest_price($product_array){\n usort($product_array, function($a, $b) {\n if($a->pris && $b->pris > 0){\n return ($a->pris - $b->pris) ;\n }\n });\n\n //Grab the last value, since it's already sorted by value the last price in the array will be the most expensive!\n $most_expensive = end($product_array);\n echo '<p>Högsta priset på en artikel är ' . round($most_expensive->pris * 1.25) . ':- </p>';\n }", "title": "" }, { "docid": "3b964c0b1d8ee7b82b1387b0a35a35b5", "score": "0.7134767", "text": "public function best()\n {\n $best = BuyItem::all()->max('price');\n\n \n\n return($best);\n\n }", "title": "" }, { "docid": "f1715e911d16855e46382b951ba50654", "score": "0.67991894", "text": "function ol_get_full_max_price() {\n\tglobal $ol_dbh;\n\n\t$stmt = $ol_dbh->query( 'SELECT MAX(price) from mstore' );\n\t$stmt->execute();\n\n\treturn $stmt->fetchColumn();\n}", "title": "" }, { "docid": "d7a14adb1b714e5007bed17a2d8fe6c1", "score": "0.6693008", "text": "public function maxPrice() {\r\n\t\t$query = \"SELECT MAX(cost) AS maxPrice FROM inventory\";\r\n\t\t\r\n\t\t$db = Database::getInstance ();\r\n\t\t$stmt = $db->prepare ( $query );\r\n\t\t$stmt->execute ();\r\n\t\t$row = $stmt->fetch ( PDO::FETCH_ASSOC );\r\n\t\t\r\n\t\treturn $row ['maxPrice'];\r\n\t}", "title": "" }, { "docid": "cc1067b921b89280fd1295a83cf80bcb", "score": "0.66169864", "text": "public function fetchBestSales($qty, $limit);", "title": "" }, { "docid": "916b860b82554208180fd5cf365b9199", "score": "0.64630353", "text": "public function highestPrice() : int\n {\n return array_reduce($this->_orders, function($highestPrice, $order) {\n return $order['total_price'] > $highestPrice\n ? $order['total_price']\n : $highestPrice;\n }, PHP_INT_MIN);\n }", "title": "" }, { "docid": "3830af7fc7b5106e53419675a6ba3b1f", "score": "0.6296183", "text": "public function getHighestRating();", "title": "" }, { "docid": "df1f7c38826fd125dd0f308c321ee93c", "score": "0.62831724", "text": "public function getBestPromotion()\n {\n $promotions = $this->getRtShopProduct()->getrtShopPromotionsAvailableOnly();\n\n if(count($promotions) > 0)\n {\n $sorted_array = array();\n $i=0;\n foreach($promotions as $promotion)\n {\n // Product promotion rule 1:\n // If promotion is stackable and price_promotion available use price_promotion, otherwise use price_retail\n $price = ($promotion->getStackable() && $this->getPricePromotion() != 0) ? $this->getPricePromotion() : $this->getPriceRetail();\n \n switch ($promotion->getReductionType())\n {\n case 'percentageOff':\n $percentage = $promotion->getReductionValue()/100;\n $reduced_price = $price - ($price * $percentage);\n break;\n case 'dollarOff':\n $reduced_price = $price - $promotion->getReductionValue();\n break;\n }\n\n $sorted_array[$i]['id'] = $promotion->getId();\n $sorted_array[$i]['reduced_price'] = $reduced_price;\n\n if($reduced_price < $sorted_array[0]['reduced_price'])\n {\n $best = array();\n $best['id'] = $promotion->getId();\n $best['reduced_price'] = $reduced_price;\n array_unshift($sorted_array, $best);\n }\n $i++;\n }\n return Doctrine::getTable('rtShopPromotionProduct')->find($sorted_array[0]['id']);\n }\n return false;\n }", "title": "" }, { "docid": "09415198101855ddec0ad89b72b73afe", "score": "0.62606466", "text": "function obtenerCostoProducto($idProducto){\n\t\t$db = obtenerBaseDeDatosSecundaria();\n\t\t$sentencia = $db->prepare(\"SELECT max_price FROM wp_wc_product_meta_lookup WHERE product_id = ?\");\n\t\t$sentencia->execute([$idProducto]);\n\t\treturn $sentencia->fetchAll();\n\t}", "title": "" }, { "docid": "6f03f90ab35d62a9e377d3490b41dc3b", "score": "0.6233052", "text": "public function getTopProduct()\n {\n return $this->topProduct;\n }", "title": "" }, { "docid": "7089291c66590ef89ad14b1e2d30ca7e", "score": "0.6217616", "text": "public static function get_most_popular_products()\n {\n global $database;\n\n $query = \"SELECT * FROM producten \n ORDER BY aantalVerkocht DESC LIMIT 4\";\n\n $result = $database->fire_query($query);\n\n return $result;\n }", "title": "" }, { "docid": "49900b6877056a75cb0875426fe524f0", "score": "0.6047086", "text": "public static function lowest_price($product_array){\n usort($product_array, function($a, $b) {\n if($a->pris && $b->pris > 0){\n return ($a->pris - $b->pris) ;\n }\n });\n\n //Grab the first value, since it's already sorted by value the first price in the array will be the cheapest!\n echo '<p>Lägsta priset på en artikel är ' . round($product_array[0]->pris * 1.25) . ':- </p>';\n }", "title": "" }, { "docid": "cbc6cde61126f27652042f1d2083cebc", "score": "0.6032184", "text": "public function getHighPrice()\n {\n if(is_array($this->prices))\n {\n return $this->prices['high'];\n }\n else\n {\n return false;\n }\n }", "title": "" }, { "docid": "f18b7a95dafc59e08082b8ae133bc715", "score": "0.59992987", "text": "public function getHighPrice()\n {\n return (int) $this->info[4];\n\n }", "title": "" }, { "docid": "cf1c064be389f82f7e65ed5b2391eea2", "score": "0.5996848", "text": "public function getMaxPrice()\n {\n return $this->maxPrice;\n }", "title": "" }, { "docid": "ce5213d4b9e46b4bef1c043ab8daf0c5", "score": "0.59680045", "text": "function getTopSellingProducts($todayOfferProduct)\n {\n global $objCore;\n\n// $updateProduct=\"select pkProductID,FinalPrice,DiscountFinalPrice from \" . TABLE_PRODUCT . \"\";\n// $updateProductQuery = $this->getArrayResult($updateProduct);\n// foreach($updateProductQuery as $updateProductQueryVal){\n// $productDiscountPercent=$objCore->getProductDiscount(trim($updateProductQueryVal['FinalPrice']),trim($updateProductQueryVal['DiscountFinalPrice']));\n// mysql_query(\"update \" . TABLE_PRODUCT . \" set discountPercent=\".$productDiscountPercent.\" where pkProductID=\".$updateProductQueryVal['pkProductID'].\"\");\n// }\n\n $dateAfter = $objCore->serverDateTime(date(DATE_TIME_FORMAT_DB), DATE_TIME_FORMAT_DB);\n $varQuery = \"SELECT p.Sold,p.pkProductID,sum(oi.Quantity) as pnum,p.ProductRefNo,p.ProductName,(select OfferPrice from tbl_product_today_offer where fkProductId=pkProductID) as offerPrice,p.FinalPrice,FinalSpecialPrice,p.DiscountFinalPrice,discountPercent,p.Quantity,p.ProductDescription,p.ProductDateAdded,p.ProductImage\n FROM \" . TABLE_PRODUCT . \" as p LEFT JOIN \" . TABLE_SPECIAL_PRODUCT . \" sProduct ON pkProductID=sProduct.fkProductID\n INNER JOIN \" . TABLE_ORDER_ITEMS . \" as oi ON (pkProductID = fkItemID AND ItemDateAdded<= '\" . $dateAfter . \"' AND ItemType='product')\n INNER JOIN \" . TABLE_CATEGORY . \" ON (pkCategoryId = p.fkCategoryID AND ProductStatus='1' AND CategoryIsDeleted = '0' AND CategoryStatus = '1' AND pkProductID !='$todayOfferProduct')\n INNER JOIN \" . TABLE_WHOLESALER . \" ON (p.fkWholesalerID = pkWholesalerID AND WholesalerStatus = 'active')\n LEFT JOIN \" . TABLE_PRODUCT_TO_OPTION . \" as pto ON p.pkProductID = pto.fkProductId\n \n Group By pkProductID HAVING p.Sold>1 ORDER BY p.Sold DESC\n limit 0,\" . $this->topSellingProductDisplayLimit;\n\n $arrRes = $this->getArrayResult($varQuery);\n\n\n// $arrRows = array();\n// $i = 0;\n// foreach ($arrRes as $key => $val) {\n// $arrRows[$i][] = $val;\n// if ($key % 2 == 1) {\n// $i++;\n// }\n// }\n //pre($arrRows);\n return $arrRes;\n }", "title": "" }, { "docid": "6d99d461f9fec2df0d6f3ff67886fc8b", "score": "0.59550065", "text": "public function get_highest_priced_plan() {\n\n\t\t$plan = new Plan();\n\n\t\t$table = $plan->table;\n\n\t\t$stmt = $this->db->prepare( \"SELECT id, amount FROM $table WHERE product_id = %d AND status = 'published' ORDER BY amount DESC LIMIT 1\", $this->get_id() );\n\n\t\t$result = $this->db->get_row( $stmt, object );\n\n\t\tif ( ! empty( $result ) ) {\n\t\t\treturn $plan->get_plan( $result->id );\n\t\t}\n\n\t\treturn false;\n\n\t}", "title": "" }, { "docid": "9ecb7cb8f3ac521deb5bbd02e09e6bcd", "score": "0.5944926", "text": "public function GetMaxItem()\n {\n /** @var null|TdbShopVat $oMaxItem */\n $oMaxItem = null;\n $iPt = $this->getItemPointer();\n $this->GoToStart();\n while ($oItem = $this->Next()) {\n if ($oItem->getTotalValue() > 0 && (is_null($oMaxItem) || $oItem->getTotalValue() > $oMaxItem->getTotalValue())) {\n $oMaxItem = $oItem;\n }\n }\n $this->setItemPointer($iPt);\n\n return $oMaxItem;\n }", "title": "" }, { "docid": "cd01f972f9f51bbe78cae08a128195bb", "score": "0.5941345", "text": "function getTenHighestRatedPoems()\n{\n\n\n\n}", "title": "" }, { "docid": "ac7000e231426fc546dd0a5e6e66a681", "score": "0.59354556", "text": "function getHighest($a)\r\n\t{\r\n\t\t$h=0;\r\n\t\tfor ($i=0; $i<count($a); $i++)\r\n\t\t{\r\n\t\t\tif ($a[$i][\"id\"]>$h) $h=$a[$i][\"id\"];\r\n\t\t}\r\n\t\treturn $h;\r\n\t}", "title": "" }, { "docid": "ae51ea8cda2a6688c4bc5b87a7dc89c0", "score": "0.5922034", "text": "public static function cheapest()\n {\n return floor((float)Course::min('price'));\n }", "title": "" }, { "docid": "4ea2902265a258faae39513282588ca7", "score": "0.5882399", "text": "private function getPopular()\n {\n $prod = $this->model(\"Product\");\n\n return $prod->getPopular();\n }", "title": "" }, { "docid": "60d2bd57b63b3d04ca03e50492f56361", "score": "0.58610344", "text": "public function getMaxPeso(){\n $this -> Conexion -> abrir();\n $this -> Conexion -> ejecutar($this -> PrecioDAO -> getMaxPeso());\n $res = $this -> Conexion -> extraer();\n $this -> Conexion -> cerrar();\n return $res[0];\n }", "title": "" }, { "docid": "734e66c13919d9e5ba29856e405214e9", "score": "0.5856248", "text": "public function getMaxExpenseTransaction() {\n\t\t$select = $this->remoteDb->select()\n\t\t\t\t\t ->from(array('t1' => 'expense_transaction_list'),array('t1.fkexpense_id','t1.fkexpense_type','t1.product_description',\"maxi\"=>\"MAX(t1.unit_price * t1.quantity)\"))\n\t\t\t\t\t ->joinLeft(array('t2' => 'account'),'t1.fkexpense_type = t2.id',array('t2.id as aid',\n\t\t\t\t\t \t\t't2.account_name'))\n\t\t\t\t\t ->group('t1.id')\n\t\t\t\t\t ->order('maxi DESC');\n\t\t$sql = $this->remoteDb->fetchAll($select);\n\t return $sql;\n\t}", "title": "" }, { "docid": "c61a2524f3289cd940a7de3534500fcd", "score": "0.5854402", "text": "public function getTopSellingProducts()\n {\n $databaseResults = $this -> databaseInstance -> queryTopSellingProducts(\"products\" , \"order\");\n $resultsDecoded= Utility::jsonEncodeThenDecode($databaseResults);\n\n return $this -> productMapper($resultsDecoded);\n }", "title": "" }, { "docid": "c395ebabee0e70f4ceabd077a4093ed6", "score": "0.585409", "text": "public function getHighestRating(): int;", "title": "" }, { "docid": "d3ecf309c0c282ab1fbb6ca9bae805fb", "score": "0.58521146", "text": "public function getMax() {\n\t\treturn Temboo_Results::getSubItemByKey($this->base, \"max\");\n\t}", "title": "" }, { "docid": "b24b9e478138c7ef4d4a89eff9b1a0d8", "score": "0.58457184", "text": "public function findBestSells($n = 3, $active = true) {\n $first_query = $this->getEntityManager()\n ->createQuery('select p, sum(ol.quantity) as qte from sil16VitrineBundle:Product p, sil16VitrineBundle:OrderLine ol where ol.product = p and p.active = :value group by ol.product order by qte DESC')\n ->setParameter('value', $active)\n ->setMaxResults($n)\n ->getResult();\n foreach($first_query as $element){\n $products[] = $element[0];\n }\n return $products;\n }", "title": "" }, { "docid": "04d49b26519be96ccf9fd1f4a88d20b6", "score": "0.57942593", "text": "public function get_maximum_appraised_amount($product_name = false, $brand_name = false, $category_name = false)\n {\n $this->db->select_max('appraised_amount');\n $this->db->join('ph_category_brand', 'ph_category_brand.category_brand_id = ph_product.category_brand_id', 'LEFT');\n $this->db->join('ph_category', 'ph_category.category_id = ph_category_brand.category_id', 'LEFT');\n $this->db->join('ph_brand', 'ph_brand.brand_id = ph_category_brand.brand_id', 'LEFT');\n $this->db->order_by('category_name, brand_name, product_name');\n $this->db->group_by('product_name, brand_name', 'category_name');\n return $this->db->get_where('ph_product', array('product_name' => $product_name, 'brand_name' => $brand_name));\n }", "title": "" }, { "docid": "56d2005fa030093a9a3a320d716d1016", "score": "0.57927275", "text": "function maximumToys($prices, $k) {\n sort($prices);\n $basket = [];\n foreach( $prices as $value ) {\n if( array_sum($basket)+$value <= $k ) {\n array_push($basket, $value);\n }\n }\n return count($basket);\n}", "title": "" }, { "docid": "2d168a31f3995d151eba68dcd3f9abfa", "score": "0.57836366", "text": "public static function expensive()\n {\n return floor((float)Course::max('price'));\n }", "title": "" }, { "docid": "f592e1004b236512d36d190f52d459e8", "score": "0.57696366", "text": "public function getMaxPriceInt() {\n $maxPrice = $this->getData('max_price_int');\n if (is_null($maxPrice)) {\n // echo \"sdfsdf\";\n $_collection = $this->getLayer()->getProductCollection();\n //->getMaxPrice();\n\n\n\n $select = clone $_collection->getSelect();\n $priceExpression = $_collection->getPriceExpression($select) . ' ' . $_collection->getAdditionalPriceExpression($select);\n $sqlEndPart = ') * ' . $_collection->getCurrencyRate() . ', 2)';\n\n\n $select->reset(Zend_Db_Select::ORDER);\n $select->reset(Zend_Db_Select::WHERE);\n $select->reset(Zend_Db_Select::LIMIT_COUNT);\n $select->reset(Zend_Db_Select::LIMIT_OFFSET);\n $select->reset(Zend_Db_Select::COLUMNS);\n\n\n //$select = $_collection->_getSelectCountSql($select, false);\n $select->columns('ROUND(MAX(' . $priceExpression . $sqlEndPart);\n // $select->columns('ROUND(MIN(' . $priceExpression . $sqlEndPart);\n // $select->columns($_collection->getConnection()->getStandardDeviationSql('ROUND((' . $priceExpression . $sqlEndPart));\n // $select->where($_collection->getPriceExpression($select) . ' IS NOT NULL');\n // echo $select;\n\n $row = $_collection->getConnection()->fetchRow($select, array(), Zend_Db::FETCH_NUM);\n //$this->_pricesCount = (int)$row[0];\n //$this->_maxPrice = ;\n //$this->_minPrice = (float)$row[2];\n //$this->_priceStandardDeviation = (float)$row[3];\n // return $this;\n\n\n /* echo \"---\";\n print_r($row);\n echo \"----\"; */\n\n\n\n\n $maxPrice = ceil((float) $row[0]);\n $this->setData('max_price_int', $maxPrice);\n }\n\n\n return $maxPrice;\n }", "title": "" }, { "docid": "7c591751c44313872a67e66c928cd447", "score": "0.5737392", "text": "public function getHighestBidderNickName($product_id) {\n\n $connection = Yii::app()->db;\n $command = $connection->createCommand('select product_winners, product_reserve_price, product_temp_current_price from tbl_product WHERE product_status=1 AND product_id=' . $product_id);\n $model = $command->queryRow();\n\n $no_of_winners = $model['product_winners'];\n $reserve_price = $model['product_reserve_price'];\n $temp_price = $model['product_temp_current_price'];\n\n $sql = 'SELECT b.bid_productID, b.bid_buyersID, max( b.bid_value ) maxval, max(b.bid_created) maxdate, p.product_bid_diff_price ';\n $sql .= ' FROM `tbl_bid` b';\n $sql .= ' INNER JOIN tbl_product p ON b.bid_productID = p.product_id';\n $sql .= ' WHERE `bid_productID` = ' . $product_id;\n //$sql .= ' AND b.bid_value >= p.product_reserve_price';\n $sql .= ' GROUP BY b.bid_buyersID';\n $sql .= ' ORDER BY maxval DESC, maxdate ASC';\n $sql .= ' LIMIT ' . $no_of_winners;\n\n //echo $sql;\n\n $command = $connection->createCommand($sql);\n $rows = $command->queryAll();\n $result = array();\n\n $num_rows = count($rows);\n if ($num_rows > 0) {\n $i = 1;\n $status = 1;\n $highestBidValue = $rows[0]['maxval'];\n\n if ($num_rows == 1) {\n\n $price = $temp_price;\n if ($reserve_price >= $temp_price) {\n $price = $reserve_price;\n }\n\n $result[] = array(\n 'winner_number' => $i,\n 'winner_price' => $price,\n 'winner_userid' => $rows[0]['bid_buyersID'],\n 'winner_created' => $rows[0]['bid_created']\n );\n } else {\n foreach ($rows as $r) {\n\n if ($r['maxval'] <= $temp_price) {\n $price = $r['maxval'];\n } else if ($r['maxval'] > $temp_price) {\n if ($r['maxval'] < $highestBidValue) {\n $price = $r['maxval'];\n } else if ($r['maxval'] == $highestBidValue) {\n $price = $temp_price;\n }\n }\n\n $result[] = array(\n 'winner_number' => $i,\n 'winner_price' => $price,\n 'winner_userid' => $r['bid_buyersID'],\n 'winner_created' => $r['bid_created']\n );\n $i++;\n }\n }\n } else {\n $status = 0;\n }\n\n $nickname = '';\n $user_id = $result[0]['winner_userid'];\n $nickname = Buyers::model()->getUsername($user_id);\n return $nickname;\n }", "title": "" }, { "docid": "50ef4d554c9cab84f6b0fecbae4fabea", "score": "0.5736846", "text": "public static function get_most_popular_products_extra_page()\n {\n global $database;\n\n $query = \"SELECT * FROM producten \n ORDER BY aantalVerkocht DESC LIMIT 10\";\n\n $result = $database->fire_query($query);\n\n return $result;\n }", "title": "" }, { "docid": "ac6bf62121e643bdc4170037b91268ce", "score": "0.56909174", "text": "function LatestNineProducts(){\n return $this->database->DbLatestNineProducts();\n }", "title": "" }, { "docid": "ffb2c1914541a0bdcc054bf106caf388", "score": "0.5673637", "text": "public static function getProductMaxQuantity($desc) {\n \t$db = new Database();\n \t$q = \"select quantity from (select p.p_id, p.description, p.price, i.quantity from products p, inventory i where p.p_id = i.p_id order by p.p_id) where description='{$desc}'\";\n \t$result = $db->createQuery($q);\n \tif (count($result) > 0) {\n \t\treturn $result[0]['QUANTITY'];\n \t} else {\n \t\treturn FALSE;\n \t}\n }", "title": "" }, { "docid": "bc81265c3500551440107b02449b8654", "score": "0.562264", "text": "public function GetLargestVATObject()\n {\n $oActiveVatList = $this->GetActiveVATList();\n\n $oMaxItem = null;\n if (is_object($oActiveVatList)) {\n $oMaxItem = $oActiveVatList->GetMaxItem();\n }\n\n return $oMaxItem;\n }", "title": "" }, { "docid": "1f345b0ded010226797b193d63132f86", "score": "0.5616765", "text": "function ol_get_full_min_price() {\n\tglobal $ol_dbh;\n\n\t$stmt = $ol_dbh->query( 'SELECT MIN(price) from mstore' );\n\t$stmt->execute();\n\n\treturn $stmt->fetchColumn();\n}", "title": "" }, { "docid": "75513bcadf1abf3868b04680b4b0b269", "score": "0.56066984", "text": "public function getMaximumUses();", "title": "" }, { "docid": "5c35903567037336006fc80faac3741d", "score": "0.55920887", "text": "function getHighestKeyRow($railsMaxs){\n\t$tempkey = array();\n\tforeach($railsMaxs as $key => $val){\n\t \t $tempkey = $key;\t\n\t}\n\t//print_r(\" row - \" .$tempkey);\n}", "title": "" }, { "docid": "188f28d18926df646ed1f916c066c50a", "score": "0.5584083", "text": "public function Top_Product($limit)\n\t{\n\t\t$sql = $this->pdo->prepare(\"select * from product_tbl limit $limit\");\n\t\t$sql->execute();\n\t\t$row = $sql->fetchAll(PDO::FETCH_OBJ);\n\t\treturn $row;\n\t}", "title": "" }, { "docid": "4f374094875fabe93ec2d59bb53cc08f", "score": "0.55782557", "text": "function largestProduct(string $series, int $adjacents = 4)\n{\n $maxProduct = 0;\n $seriesArray = toArraySeries($series);\n\n for ($i = 0; $i < (count($seriesArray) - $adjacents); $i++) {\n $product = 1;\n for ($j = 0; $j < $adjacents; $j++) {\n $product *= $seriesArray[$i + $j];\n }\n\n $maxProduct = max($maxProduct, $product);\n }\n\n echo $maxProduct;\n}", "title": "" }, { "docid": "08c6d6204ae5d8d8fef220902a6d3e82", "score": "0.5575399", "text": "public function getPairWithHighestRating()\n {\n return collect($this->pairs)\n ->sortByDesc(function ($pair) {\n return $this->getPairRating($pair);\n })->first();\n }", "title": "" }, { "docid": "ce5241d3f81faa11152f15d2539bbb7a", "score": "0.5569523", "text": "function get_second_max_bid($product_id){\n\t\tglobal $wpdb;\n\n\t\t$bids = array();\n\t\t$first_bid = $this->get_max_bid($product_id);\n\t\tif($first_bid){\n\t\t\tif ( isset($first_bid->user_id) ) {\n\t\t\t\t$query = $wpdb->prepare( \"SELECT * FROM {$this->yithTable} WHERE auction_id = %d AND user_id <> %d ORDER by CAST(bid AS decimal(50,5)) DESC, date ASC LIMIT 1\",$product_id,$first_bid->user_id);\n\t\t\t\t$second_bid = $wpdb->get_row( $query );\n\t\t\t\tif($second_bid){\n\t\t\t\t\treturn $second_bid;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn false;\n\t}", "title": "" }, { "docid": "10e5f7b6f43c5aa7aa75871fdb568e80", "score": "0.55474496", "text": "protected function resolveBestSellers()\n {\n if (Configuration::get('PS_CATALOG_MODE')) {\n return false;\n }\n\n if (!($result = $this->getBestSalesLight(\n (int) $this->context->language->id,\n 0,\n (int) Configuration::get(static::BESTSELLERS_TO_DISPLAY),\n Configuration::get(static::BESTSELLERS_PRICE_ABOVE)))\n ) {\n return (Configuration::get(static::BESTSELLERS_DISPLAY) ? [] : false);\n }\n\n $currency = new Currency($this->context->currency->id);\n $usetax = (Product::getTaxCalculationMethod((int) $this->context->customer->id) != PS_TAX_EXC);\n foreach ($result as &$row) {\n $row['price_raw'] = round(Product::getPriceStatic((int) $row['id_product'], $usetax), _TB_PRICE_DATABASE_PRECISION_);\n $row['price'] = Tools::displayPrice($row['price_raw'], $currency);\n }\n\n return $result;\n }", "title": "" }, { "docid": "78e15cc6a6820b47a84662b3ccf74712", "score": "0.55398965", "text": "function storepage_best_selling_products( $args ) {\n\t\tif ( is_woocommerce_activated() ) {\n\t\t\t\n\t\t\t$args = apply_filters( 'storepage_best_selling_products_args', array(\n\t\t\t\t'limit' => 4,\n\t\t\t\t'columns' => 4,\n\t\t\t\t'title'\t => esc_attr__( 'Best Sellers', 'storepage' ),\n\t\t\t) );\n\t\t\t\n\t\t\techo '<section class=\"storepage-product-section storepage-best-selling-products\">';\n\t\t\t\n\t\t\tdo_action( 'storepage_before_best_selling_products' );\n\t\t\t\n\t\t\techo '<h2 class=\"section-title\">' . wp_kses_post( $args['title'] ) . '</h2>';\n\t\t\t\n\t\t\tdo_action( 'storepage_after_best_selling_products_title' );\n\t\t\t\n\t\t\techo storepage_do_shortcode( 'best_selling_products', array(\n\t\t\t\t'per_page' => intval( $args['limit'] ),\n\t\t\t\t'columns' => intval( $args['columns'] ),\n\t\t\t) );\n\t\t\t\n\t\t\tdo_action( 'storepage_after_best_selling_products' );\n\t\t\t\n\t\t\techo '</section>';\n\t\t}\n\t}", "title": "" }, { "docid": "2e5641945a52b97da81fee73f478c247", "score": "0.5536576", "text": "function calculate_product_price($product){\n return (int)$product[\"amount\"] * reduce_by_20($product[\"price\"]) * sales_price();\n}", "title": "" }, { "docid": "ad92c989370d666158f8c067d143ad16", "score": "0.5533402", "text": "public static function get_maximum_price( $product ) {\r\n\r\n\t\t$product = self::maybe_get_product_instance( $product );\r\n\r\n\t\tif ( ! $product ) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\r\n\t\t$maximum = $product->get_meta( '_maximum_price', true, 'edit' );\r\n\r\n\t\tif ( ! is_numeric( $maximum ) ) {\r\n\t\t\t$maximum = false;\r\n\t\t}\r\n\r\n\t\t// Filter the raw maximum price @since 2.8.0.\r\n\t\treturn apply_filters( 'wc_nyp_raw_maximum_price', $maximum, $product->get_id(), $product );\r\n\r\n\t}", "title": "" }, { "docid": "0a4671e272f8ffc86d75c8e54ebb37d1", "score": "0.552722", "text": "function max_scorer()\n {\n global $player;//using array of objects of player class\n $total=0;//for calculating total run scored by a player\n $max=0;//for keeping maximum run scored\n foreach ($player as $key=>$value)\n {\n foreach($value as $key1=>$value1)\n {\n $total = $total + $value1->run_scored;\n if($total > $max)\n {\n $max=$total;\n $p_name=$key;\n }\n }\n $total=0;\n }\n echo \"Highest Scorer: \" . $p_name . \"<br>\" . \"Score: \" . $max . \"<br><br>\";\n }", "title": "" }, { "docid": "49732b5073f1ee7b1f0658b5335797a0", "score": "0.5511892", "text": "function getBestSeller($argRequest)\n {\n $arrTodayOffer = $this->getTodayOffer();\n\n $todayOfferProduct = $arrTodayOffer['offer_details']['0']['fkProductId'];\n\n $objCore = new Core();\n //$dateAfter = $objCore->serverDateTime(date(DATE_TIME_FORMAT_DB, strtotime(\"-1 month\")), DATE_TIME_FORMAT_DB);\n $dateAfter = $objCore->serverDateTime(date(DATE_TIME_FORMAT_DB), DATE_TIME_FORMAT_DB);\n $varQuery = \"SELECT p.Sold,p.pkProductID,sum(oi.Quantity) as pnum,p.ProductRefNo,p.ProductName,p.FinalPrice,p.DiscountFinalPrice,FinalSpecialPrice,discountPercent,p.Quantity,p.ProductDescription,p.ProductDateAdded,p.ProductImage,count(fkAttributeId) as Attribute,\n (select IFNULL(CAST(avg(Rating) as decimal(10,2)),0) from \" . TABLE_PRODUCT_RATING . \" where fkProductID=pkProductID AND RatingApprovedStatus='Allow') as avgRating,\n (select OfferPrice from tbl_product_today_offer where fkProductId=pkProductID) as offerPrice\n FROM \" . TABLE_PRODUCT . \" as p\n LEFT JOIN \" . TABLE_SPECIAL_PRODUCT . \" sProduct ON pkProductID=sProduct.fkProductID INNER JOIN \" . TABLE_ORDER_ITEMS . \" as oi ON (pkProductID = fkItemID AND ItemDateAdded<= '\" . $dateAfter . \"' AND ItemType='product')\n INNER JOIN \" . TABLE_CATEGORY . \" ON (pkCategoryId = p.fkCategoryID AND ProductStatus='1' AND CategoryIsDeleted = '0' AND CategoryStatus = '1' AND pkProductID !='$todayOfferProduct')\n INNER JOIN \" . TABLE_WHOLESALER . \" ON (p.fkWholesalerID = pkWholesalerID AND WholesalerStatus = 'active')\n LEFT JOIN \" . TABLE_PRODUCT_TO_OPTION . \" as pto ON p.pkProductID = pto.fkProductId\n\n Group By pkProductID HAVING p.Sold>1 ORDER BY p.Sold DESC\n limit 0,\" . $argRequest['limit'];\n\n $arrRes = $this->getArrayResult($varQuery);\n //pre($arrRes);\n return $arrRes;\n }", "title": "" }, { "docid": "16f80664b3629f7614df77f13f3cb1ac", "score": "0.5493169", "text": "public function is_sale(){\n if($this->present_price < $this->price){\n return 1;\n }\n return 0;\n }", "title": "" }, { "docid": "7f8c69dcc6bb3750f87c9a824a4d671d", "score": "0.54795885", "text": "public function getHighestItemId()\n{\n $stmt = $this->conn->prepare(\"SELECT id from food_items order by id DESC limit 1\");\n $stmt->execute();\n $results = $stmt->get_result()->fetch_assoc();\n $stmt->close();\n return $results;\n }", "title": "" }, { "docid": "d6b66faa150dffccc4c11159e61d07b5", "score": "0.54773706", "text": "function getMakeModelMaxPrice($make, $model, $maxPrice){\n $getCars = \"SELECT * FROM CarSales.UsedCars where manufacturer='$make' and model='$model' and price<='$maxPrice'\";\n displayListOfCars($getCars);\n}", "title": "" }, { "docid": "3776343086204e770f496aaa3206c1a7", "score": "0.5472358", "text": "public function arrangeableGetHighestOrderNumber()\n {\n $orderColumnName = static::arrangeableGetConfig('order_key');\n\n return static::arrangeableModelQuery($this->arrangeableGetForeignKeyValue())\n ->max($orderColumnName);\n\n }", "title": "" }, { "docid": "935e338f7d7da61c52418d11933e8ab8", "score": "0.5469263", "text": "function get_product_last_purchase_price($productId, $toDate = null, $fromDate = null)\n {\n $last_purchase_price = 0;\n $CI =& get_instance();\n $CI->load->database();\n $last_purchase = $CI->db->where('product_id', $productId)\n ->order_by('purchase_details_id', \"desc\")\n ->limit(1)\n ->get('purchase_details')\n ->row();\n if (empty($last_purchase)) {\n $product_purchase_price = $CI->db->where('product_id', $productId)\n ->limit(1)\n ->get('product')\n ->row();\n $last_purchase_price = $product_purchase_price->purchases_price;\n } else {\n $last_purchase_price = $last_purchase->unit_price;\n }\n return $last_purchase_price;\n }", "title": "" }, { "docid": "1820a5ee8c37a0db6e21fe14234a6d2b", "score": "0.5462011", "text": "public function mostRecentUpload() {\n\t\n\t\t$cpModel = Base::getModel('Client_Products');\n\t\t$select = $cpModel->select()\n\t\t ->where('common_user_id = ?', $this->id)\n\t\t ->where('date_deleted IS NULL')\n\t\t\t\t ->order('id DESC')\n\t\t\t\t ->limit(1);\n\t\t\n\t\t$product = $cpModel->fetchRow($select);\n\t\t\n\t\treturn $product;\n\t}", "title": "" }, { "docid": "8704f89c5ad3e63ba655124120fafdf7", "score": "0.5461054", "text": "public function latestFromSamsung(){\n$query=\"SELECT*FROM table_product WHERE brandId='21' ORDER BY productId DESC LIMIT 1\";\n$result=$this->db->select($query);\nreturn $result;\n }", "title": "" }, { "docid": "8b652fd2f7c64949cccab459b0c18560", "score": "0.5456935", "text": "public function usesMax();", "title": "" }, { "docid": "06d8c226067d4fb177297429e8afcaf1", "score": "0.5453522", "text": "function maxSedista($autobusi){\n $max = $autobusi[0]->getBrojSedista();\n foreach($autobusi as $bus){\n if($bus->getBrojSedista() >= $max){\n $max = $bus->getBrojSedista();\n }\n }\n foreach($autobusi as $bus){\n if($bus->getBrojSedista() == $max){\n $bus->stampaj();\n }\n }\n}", "title": "" }, { "docid": "7daefac04ebacc83e20f5c395fde8a06", "score": "0.5444569", "text": "function nzshpcrt_latest_product( $args = null, $instance ) {\n\t_wpsc_deprecated_function( __FUNCTION__, '3.8', 'wpsc_latest_product');\n\techo wpsc_latest_product( $args, $instance );\n}", "title": "" }, { "docid": "1b0d5a0a267f71636072df878ab5691b", "score": "0.54386014", "text": "public function getHighestDeliveryId()\n {\n $stmt = $this->conn->prepare(\"SELECT id from deliveries order by id DESC limit 1\");\n $stmt->execute();\n $results = $stmt->get_result()->fetch_assoc();\n $stmt->close();\n return $results;\n }", "title": "" }, { "docid": "39c6ec639c59e3848f9eed4934c7d4d3", "score": "0.5434359", "text": "function getSizeofMarket($marketData) {\r\n$MaxArray = max(array_map(\"count\", $marketData));\r\nreturn $MaxArray;\t\t\r\n}", "title": "" }, { "docid": "39c6ec639c59e3848f9eed4934c7d4d3", "score": "0.5434359", "text": "function getSizeofMarket($marketData) {\r\n$MaxArray = max(array_map(\"count\", $marketData));\r\nreturn $MaxArray;\t\t\r\n}", "title": "" }, { "docid": "6326e1306e824f73ebb72d58d681110c", "score": "0.54327905", "text": "function getLatestProductByCatId($argProductId)\n {\n //$arrRow = array();\n \n //$categoryIds= is_array($val['pkCategoryId'])?$val['pkCategoryId']:$val;\n /*$limitCon =\"\";\n $limit = $argProductId['limit'];\n if($limit!=\"\")\n {\n $limitCon =\"limit 0,\".$limit; \n }*/\n $limit = ($arrPost['limit']) ? $arrPost['limit'] : 9;\n $varQuery = \"SELECT pkProductID,ProductRefNo,ProductName,FinalPrice,FinalSpecialPrice,DiscountFinalPrice,IF(sum(atInv.OptionQuantity)>0,sum(atInv.OptionQuantity),Quantity) as Quantity,discountPercent,ProductDescription,ProductDateAdded,ProductImage,count(fkAttributeId) as Attribute,(select OfferPrice from tbl_product_today_offer where fkProductId=pkProductID) as offerPrice,(select IFNULL(CAST(avg(Rating) as decimal(10,2)),0) from \" . TABLE_PRODUCT_RATING . \" where fkProductID=pkProductID AND RatingApprovedStatus='Allow') as avgRating FROM \".TABLE_PRODUCT.\" product LEFT JOIN \".TABLE_SPECIAL_PRODUCT.\" sProduct ON pkProductID=sProduct.fkProductID INNER JOIN \".TABLE_CATEGORY.\" ON (pkCategoryId = product.fkCategoryID AND (CategoryHierarchy like'\".$argProductId['catId'].\":%' OR CategoryHierarchy ='\".$argProductId['catId'].\"') AND ProductStatus='1' AND CategoryIsDeleted = '0' AND CategoryStatus = '1' OR pkProductID ='\".$argProductId['catId'].\"') INNER JOIN \".TABLE_WHOLESALER.\" ON (product.fkWholesalerID = pkWholesalerID AND WholesalerStatus = 'active') LEFT JOIN \".TABLE_PRODUCT_TO_OPTION.\" as pto ON pkProductID = pto.fkProductId LEFT JOIN \".TABLE_PRODUCT_OPTION_INVENTORY.\" as atInv ON pkProductID = atInv.fkProductID Group By pkProductID ORDER BY pkProductID DESC LIMIT \" . $limit . \"\";\n\n $arrRes = $this->getArrayResult($varQuery);\n\n /*mail('anuj.singh@mail.vinove.com','request',print_r($argProductId,1));\n mail('anuj.singh@mail.vinove.com','response',print_r($arrRes,1));\n mail('deepak.sindhu@mail.vinove.com','request',print_r($argProductId,1));\n mail('deepak.sindhu@mail.vinove.com','response',print_r($arrRes,1));*/\n return $arrRes;\n }", "title": "" }, { "docid": "00a888557a5471a110a1e27263c576af", "score": "0.54314387", "text": "public function getHighestOrderNumber()\n {\n return ((int) self::max($this->determineOrderColumnName())) + 1;\n }", "title": "" }, { "docid": "0ff1635731a7e6c7b302d3bfdfae7fdd", "score": "0.5428047", "text": "function nIdprov(){\r\n\t$salida='PRV0000001';\r\n\t$query =\"SELECT MAX(IDPROVEEDOR) FROM PROVEEDOR\";\r\n\r\n\t$result=mysql_query($query) or die(\"Error en: \" . mysql_error());\r\n\t\r\n\t//Mientras exista resultados\r\n\t\tif( $fila=mysql_fetch_array($result) ){\r\n\t\t\t$salida= 'PRV'.formatoNum($fila['MAX(IDPROVEEDOR)']);\r\n\t\t}\r\n\treturn $salida;\r\n}", "title": "" }, { "docid": "ee3dcbeb2dc63d6952672e3529cd55fc", "score": "0.54260623", "text": "function getLatestProducts($todayOfferProduct)\n {\n $varQuery = \"SELECT pkProductID,ProductRefNo,ProductName,FinalPrice,DiscountFinalPrice,ProductDescription,ProductImage,ProductSliderImage\n FROM \" . TABLE_PRODUCT . \" INNER JOIN \" . TABLE_CATEGORY . \" ON (pkCategoryId = fkCategoryID AND ProductStatus='1' AND CategoryIsDeleted = '0' AND CategoryStatus = '1' AND pkProductID !='$todayOfferProduct')\n INNER JOIN \" . TABLE_WHOLESALER . \" ON (fkWholesalerID = pkWholesalerID AND WholesalerStatus = 'active')\n ORDER BY pkProductID DESC\n limit 0,\" . $this->latestProductDisplayLimit;\n\n\n $arrRes = $this->getArrayResult($varQuery);\n //pre($arrRes);\n return $arrRes;\n }", "title": "" }, { "docid": "c8ddc9a2897fabfc86c42e90fe71aa11", "score": "0.5424667", "text": "public function maxSodaPrice()\n {\n return $this->rules->getMaxSodaPrice();\n }", "title": "" }, { "docid": "c5f9bfa47cde1d476a7e4d903bc018e4", "score": "0.54230976", "text": "function findingTheLastAdvetisementIdFromeDb() {\n\t \t$query = \"SELECT MAX(adv_Id) FROM advertisement\"; /// product_Id query\n\n\t \t$result = executeQuery($query);\n\t \t$productId = null;\n\n\t \tif($result) {\n\t \t\t$productId = mysqli_fetch_array($result);\n\t \t}\n\n\t \treturn $productId;\n\t }", "title": "" }, { "docid": "3c4357829fa89ca34e42bfeea5516998", "score": "0.5419731", "text": "public function ComputeProductStock($ProductId)\n\t{\n\t\t$sql = '\n\t\t\t\tselect sum(sm_coef * sm_qty) stock\n\t\t\t\tfrom '.mage::getModel('Purchase/Constant')->getTablePrefix().'stock_movement \n\t\t\t\twhere sm_product_id = '.$ProductId.'\n\t\t\t\t';\n\t\t$data = mage::getResourceModel('sales/order_item_collection')->getConnection()->fetchAll($sql);\t\n\t\tif (count($data) > 0)\n\t\t{\n\t\t\tif ($data[0]['stock'] == '')\n\t\t\t\treturn 0;\n\t\t\telse\n\t\t\t\treturn $data[0]['stock'];\n\t\t}\n\t\t\n\t\treturn 0;\n\t}", "title": "" }, { "docid": "f935551954454d387a69003160857b4f", "score": "0.54119635", "text": "public function firstHighestBid(): int\n {\n $maxBid = $this->bids()->max('bid_amount');\n $firstHighest = $this->bids()->where('bid_amount', $maxBid)->orderBy('created_at')->first();\n if($firstHighest ===null) {\n return 0;\n }\n return $firstHighest->id;\n }", "title": "" }, { "docid": "7723c5067884fffb0ad93536ff1898a8", "score": "0.54068077", "text": "public function show_last_product()\n {\n $last_product = Product::latest()->first();\n\n // dd($last_offer);\n return $this->show($last_product->id);\n }", "title": "" }, { "docid": "072b20e543bf469eea37f636cc708fbf", "score": "0.54008055", "text": "function findItemToGoSale(){\n //find total number of products that are on in the table\n $servername = \"localhost\";\n $username = \"jchen127\";\n $password = \"KbZFqBcZCy29b3Lx\";\n $dbname = \"mydb\";\n $conn = new mysqli($servername, $username, $password, $dbname);\n // Check connection\n if ($conn->connect_error) {\n die(\"Connection failed: \" . $conn->connect_error);\n }\n \n /*\n $sql = \"select count(*) as total from product where categoryid = '$categoryidBest'\";\n $result = $conn->query($sql);\n if($result->num_rows >0){\n while($newRow = $result->fetch_assoc()){\n // echo \"<br>################## productid: \" . $newRow['productid'] . \" categoryid \" . $newRow['categoryid'] . \" name \" . $newRow['productname'];\n // echo \"<br> count: \". $newRow['total'];\n $total = intval($newRow['total']); //where to stop\n }\n }\n */\n //finding upper bound\n $sql = \"select count(*) as total from product\";\n $result = $conn->query($sql);\n if($result->num_rows >0){\n while($newRow = $result->fetch_assoc()){\n \n $total = intval($newRow['total']); //where to stop\n }\n }else{\n echo \"Fatal Error, the product table is not populated, Application crashing...\";\n }\n //$total is the upper bound\n $randProductId = rand(1, $total);\n \n $conn->close();\n return $randProductId;\n }", "title": "" }, { "docid": "203929750d2158d4e0212b6b0b07a354", "score": "0.5399552", "text": "public function getTopRateProducts() {\n $ratedAr = [];\n $this->ratingList = [];\n\n $products = $this->_collectionFactory->create()\n ->addAttributeToSelect('*')\n ->addFieldToFilter(\"status\", \"1\")\n ->setOrder('created_at', 'DESC')\n ->load();\n\n foreach($products as $p ) {\n $score = $this->getRateScore($p);\n if ($score > 0) {\n $ratedAr[$p->getId()] = $score;\n\n $this->ratingList[$p->getId()] = array(\n 'score' => $score,\n 'star' => intval($score / 20),\n 'title' => $p->getName(),\n 'url' => $p->getProductUrl()\n );\n }\n }\n arsort($ratedAr);\n return array_slice($ratedAr, 0, 5, true);\n }", "title": "" }, { "docid": "c60b7b0cb0cccbfc69260ef9937956a1", "score": "0.537863", "text": "function getHighestScore($db) {\n\t$sql = \"SELECT score\n\t\t\tFROM highscores\n\t\t\tORDER BY score DESC\n\t\t\tLIMIT 1;\";\n\tif ($db->query($sql)) {\n\t\treturn $db->getOne();\n\t}\n\t\n\t$msg = $db->ErrorMsg() . \"\\n\" . $sql;\n\tlog_msg($msg);\n\n\treturn false;\n}", "title": "" }, { "docid": "7798f8acf0c3468fba5a6bd8fbb140e5", "score": "0.5359087", "text": "public static function getMaxRatingAboutShopStore($shopStoreId){\n $retResult = false;\n try{\n $connection = Yii::app()->db;\n $sqlFetchQuery = \"SELECT \n COUNT(DISTINCT urd.group_no) countUser,\n COALESCE(qrd.id, '') questionId,\n COALESCE(qrd.question_title, '') questionTitle,\n COALESCE(qrd.max_points, '') maxPoints,\n COALESCE(urd.given_answerpoints, 0) givenMaxAnswerPoints\n FROM DK_USER_REVIEWANSWERDETAILS urd\n JOIN DK_REVIEWQESTIONSDETAILS qrd ON qrd.id=urd.question_id\n JOIN DK_USERS u ON u.id=urd.user_id\n WHERE \n urd.status='A' AND qrd.status='A' AND urd.group_no IS NOT NULL \n AND urd.shopstore_id ='$shopStoreId'\n AND qrd.question_answerpattern='SELECT'\n GROUP BY qrd.id, COALESCE(urd.given_answerpoints, 0)\n ORDER BY qrd.sort_order ASC, COALESCE(urd.given_answerpoints, 0) DESC\";\n $command = $connection->createCommand($sqlFetchQuery);\n $retMaxRatingProductDetailsArr = $command->queryAll();\n if(count($retMaxRatingProductDetailsArr)>0 \n && $retMaxRatingProductDetailsArr!=false){\n $retResult = $retMaxRatingProductDetailsArr;\n }\n }catch(Exception $ex){} \n return $retResult;\n }", "title": "" }, { "docid": "04174eadc98aa22e17b2ed3fb3928ba9", "score": "0.5351064", "text": "function get_stok_max($variasi_id)\n {\n $stok = VariasiDetail::where('variasi_id', $variasi_id)->first();\n if($stok)\n {\n return $stok->qty_tersedia;\n }\n }", "title": "" }, { "docid": "eeaf17ff6e72f12c4fcf9c1f9f628c42", "score": "0.5350752", "text": "function LatestTwoProducts(){\n return $this->database->DbLatestTwoProducts();\n }", "title": "" }, { "docid": "d010e48745f1f7b325a2aad51a8c12bb", "score": "0.5349854", "text": "public function getHighestBid()\n {\n return $this->highestBid;\n }", "title": "" }, { "docid": "ba9a0f44044efddac3b789a64cdff8d8", "score": "0.534755", "text": "protected function getMostExpensiveItems($items)\n {\n $mostExpensiveItem = false;\n foreach ($items as $item) {\n /** @var $item Mage_Sales_Model_Quote_Item */\n if ($mostExpensiveItem == false) {\n $mostExpensiveItem = $item;\n } elseif ($item->getPrice() > $mostExpensiveItem->getPrice()) {\n $mostExpensiveItem = $item;\n }\n }\n\n return $mostExpensiveItem;\n }", "title": "" }, { "docid": "f2cd33f1b97cd715fb1aff40534256bd", "score": "0.5340799", "text": "public function productsPriceHighestBrand($id, Product $product)\n {\n\n // Get the Brand ID\n $brands = Brand::where('id', '=', $id)->get();\n\n // From Traits/CategoryTrait.php\n // ( Show Categories in side-nav )\n $categoryAll = $this->categoryAll();\n\n // From Traits/BrandAll.php\n // Get all the Brands\n $brand = $this->brandsAll();\n\n // From Traits/SearchTrait.php\n // ( Enables capabilities search to be preformed on this view )\n $search = $this->search();\n\n $products = Product::orderBy('price', 'desc')->where('active', '=', '1')->where('brand_id', '=', $id)->paginate(18);\n\n // Count the products\n $count = $products->count();\n\n // From Traits/CartTrait.php\n // ( Count how many items in Cart for signed in user )\n $cart_count = $this->countProductsInCart();\n\n $brandId = $id;\n // Get all the Brands in NavBar template\n $brandsAll = $this->brandsAll();\n\n return view('brand.show', ['products' => $products], compact('brands', 'brand', 'categoryAll', 'search', 'count', 'cart_count', 'brandId', 'brandsAll'));\n }", "title": "" }, { "docid": "4b724082dd65f4d87ef52e7fcb6a9fcc", "score": "0.5325976", "text": "protected function getBestSellers()\n {\n static $cache = null;\n if (is_null($cache)) {\n $cache = $this->resolveBestSellers();\n }\n return $cache;\n }", "title": "" }, { "docid": "5c7f8603a8211b7d0994d006389d6c03", "score": "0.5324246", "text": "public function productsPriceHighest($id, Product $product)\n {\n\n// // Get the Category ID\n// $categories = Category::where('id', '=', $id)->get();\n//\n//\n// // From Traits/SearchTrait.php\n// // ( Enables capabilities search to be preformed on this view )\n// $search = $this->search();\n//\n// // Order Products by price highest, where the category id = the URl route ID\n// $products = Product::orderBy('price', 'desc')->where('cat_id', '=', $id)->where('active', '=', '1')->paginate(18);\n//\n// // Count the Products\n// $count = $products->count();\n//\n// // From Traits/CartTrait.php\n// // ( Count how many items in Cart for signed in user )\n// $cart_count = $this->countProductsInCart();\n//\n// //get discount from DB table shop_settings\n// $discount = DB::table('shop_settings')->first();\n//\n// $categoryId = $id;\n//\n// // From Traits/CategoryTrait.php\n// // ( Show Categories in side-nav )\n// $categoryAll = $this->categoryAll();\n//\n// // From Traits/BrandAll.php\n// // Get all the Brands\n// $brandsAll = $this->brandsAll();\n// //Get all sizes unique from bd product_information\n// $sizes = DB::table('product_information')->select('size')->distinct()->get();\n// //Get all colors unique from bd table_colors\n// $colors = DB::table('colors_table')->select('color')->distinct()->get();\n// return view('category.show', ['products' => $products], compact('categories', 'categoryAll', 'brandsAll', 'search', 'count', 'cart_count', 'categoryId', 'discount', 'colors','sizes'));\n $categories = Category::where('id', $id)->get();\n\n $categories_find = Category::find($id);\n\n\n // If no category exists with that particular ID, then redirect back to Home page.\n if (!$categories_find) {\n return redirect('/');\n }\n\n //if current category is parent , we get all child categories\n if($categories_find->parent_id == null){\n $cat_id = Category::where('parent_id', $categories_find->id)->pluck('id');\n }else{\n $cat_id = [$id];\n }\n\n $shop_settings = DB::table('shop_settings')->get();\n if(count($shop_settings)>0){$shop_settings = $shop_settings[0];}\n\n // From Traits/CategoryTrait.php\n // ( Show Categories in side-nav )\n $categoryAll = $this->categoryAll();\n\n // From Traits/BrandAll.php\n // Get all the Brands\n $brands = $this->brandsAll();\n //Need to main navbar(need fix)\n $brandsAll = $this->brandsAll();\n\n // From Traits/SearchTrait.php\n // ( Enables capabilities search to be preformed on this view )\n $search = $this->search();\n\n\n $showAll = Input::get('showAll');\n if($showAll != null) {\n $products = Product::with(['category'])\n ->select(DB ::raw('*','DISTINCT(id)'))\n ->whereHas('category',function ($query) use ($cat_id){\n $query->whereIn('id',$cat_id);\n })\n ->where('created_at' ,'>', Carbon::now()->subSeconds($shop_settings->time_new))\n ->where('active', '1')\n ->orderBy('price', 'desc')\n ->get();\n $productCount = count($products);\n $products = Product::with(['category'])\n ->select(DB ::raw('*','DISTINCT(id)'))\n ->whereHas('category',function ($query) use ($cat_id){\n $query->whereIn('id',$cat_id);\n })\n ->where('created_at' ,'>', Carbon::now()->subSeconds($shop_settings->time_new))\n ->where('active', '1')\n ->orderBy('price', 'desc')\n ->paginate($productCount);\n }else{\n\n $products = Product::with(['category'])\n ->select(DB ::raw('*','DISTINCT(id)'))\n ->whereHas('category',function ($query) use ($cat_id){\n $query->whereIn('id',$cat_id);\n })\n ->where('active', '1')\n ->orderBy('price', 'desc')\n ->paginate(18);\n }\n\n\n $breadcrumbs = [\n (object) ['page' => trans('messages.mainPage'), \"link\" => url('/')]\n ];\n\n $locale = App::getLocale();\n\n if ($locale != \"ua\") {\n $category = \"category_\".$locale;\n }else{\n $category = \"category\";\n }\n\n if (!is_null($categories_find->parent)){\n array_push($breadcrumbs,(object) ['page' => $categories_find->parent->$category, \"link\" => route('category.showAll',[$categories_find->parent->id,$categories_find->parent->slug])]);\n array_push($breadcrumbs,(object) ['page' => $categories_find->$category, \"link\" => route('category.showAll',[$categories_find->id,$categories_find->slug])]);\n }else {\n array_push($breadcrumbs,(object) ['page' => $categories_find->$category, \"link\" => route('category.showAll',[$categories_find->id,$categories_find->slug])]);\n }\n\n\n // Count the products under a certain category\n $count = $products->count();\n\n // From Traits/CartTrait.php\n // ( Count how many items in Cart for signed in user )\n $cart_count = $this->countProductsInCart();\n\n //get discount from DB table shop_settings\n $discount = DB::table('shop_settings')->first();\n\n $products_id = $products->pluck('id');\n //Get all sizes unique from bd product_information\n $sizes = DB::table('product_information')->select('size')->whereIn('product_id' , $products_id)->distinct()->orderBy('size', 'asc')->get();\n //Get all colors unique from bd table_colors\n $colors = DB::table('product_information')->select('color')->whereIn('product_id' , $products_id)->whereNotNull('color')->distinct()->get();\n\n $metaTags = $this->metaTags($categories_find);\n return view('category.show', compact('shop_settings','products','categories','brands', 'categoryAll', 'search', 'cart_count','discount','brandsAll','sizes','colors','breadcrumbs','metaTags'))->with('count', $count)->with('categoryId',$id);\n\n }", "title": "" }, { "docid": "4ccae6e7e34dbd0cd0b747ec8055ce6c", "score": "0.53224367", "text": "public function _getHigh(){ return floatval($this->_getDataKey('high')); }", "title": "" }, { "docid": "78479542898658f9e50555b4f4b25325", "score": "0.53205305", "text": "function get_second_max_autobid($product_id){\n\t\tglobal $wpdb;\n\n\t\t$bids = array();\n\t\t$first_bid = $this->get_max_autobid($product_id);\n\t\tif($first_bid){\n\t\t\tif ( isset($first_bid->user_id) ) {\n\t\t\t\t$query = $wpdb->prepare( \"SELECT * FROM {$this->yithTable} WHERE auction_id = %d AND user_id <> %d AND autobid !=0 ORDER by CAST(autobid AS decimal(50,5)) DESC, date ASC LIMIT 1\",$product_id,$first_bid->user_id);\n\t\t\t\t$second_bid = $wpdb->get_row( $query );\n\t\t\t\tif($second_bid){\n\t\t\t\t\treturn $second_bid;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn false;\n\t}", "title": "" }, { "docid": "bd356b25281432e19f8bb1f0aea1ffff", "score": "0.5316637", "text": "public function max($itemKey,$comparisonType='std'){\r\n\t\tif( $this->count() < 1)\r\n\t\t\treturn 0;\r\n\t\t$lastItem = smvcCollection::init($this)->sort($itemKey,$comparisonType)->pop();\r\n\t\treturn $lastItem[$itemKey];\r\n\t}", "title": "" }, { "docid": "cb466e06daa11ef3e5c80767dff0fdfd", "score": "0.5315763", "text": "public function max();", "title": "" }, { "docid": "a128d9ef5b20f2af4d692dd497e8fa9a", "score": "0.5315467", "text": "function discount_maxKg($kg){\n\t\t$x = $kg * 0.6;\n\t\t$result = $x / 2;\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "fe99f54092bf514acf82579c9d375847", "score": "0.5297711", "text": "function getMostSoldProducts($start = 0, $limit = 0, $product_cid = 0, $withQuantity=false)\n\t{\n\t\t$ret = array();\n\t\tif(is_array($product_cid)) {\n\t\t\t$sql = 'SELECT c.caddy_product_id, sum( c.caddy_qte ) AS mv FROM '.$this->table.' c, '.$this->db->prefix('myshop_products').' b WHERE (c.caddy_product_id = b.product_id) AND b.product_cid IN ('.implode(',', $product_cid).') GROUP BY c.caddy_product_id ORDER BY mv DESC';\n\t\t} elseif($product_cid > 0) {\n\t\t\t$sql = 'SELECT c.caddy_product_id, sum( c.caddy_qte ) AS mv FROM '.$this->table.' c, '.$this->db->prefix('myshop_products').' b WHERE (c.caddy_product_id = b.product_id) AND b.product_cid = '.intval($product_cid).' GROUP BY c.caddy_product_id ORDER BY mv DESC';\n\t\t} else {\n\t\t\t$sql = 'SELECT caddy_product_id, sum( caddy_qte ) as mv FROM '.$this->table.' GROUP BY caddy_product_id ORDER BY mv DESC';\n\t\t}\n $result = $this->db->query($sql, $limit, $start);\n if ($result) {\n\t\t\twhile ($myrow = $this->db->fetchArray($result)) {\n\t\t\t\tif(!$withQuantity) {\n\t\t\t\t\t$ret[$myrow['caddy_product_id']] = $myrow['caddy_product_id'];\n\t\t\t\t} else {\n\t\t\t\t\t$ret[$myrow['caddy_product_id']] = $myrow['mv'];\n\t\t\t\t}\n\t\t\t}\n }\n return $ret;\n\t}", "title": "" }, { "docid": "d2ecf4ae06b0fede75a88f8f24ec4d3f", "score": "0.5296271", "text": "public function latestFromAcer(){\n$query=\"SELECT*FROM table_product WHERE brandId='18' ORDER BY productId DESC LIMIT 1\";\n$result=$this->db->select($query);\nreturn $result;\n }", "title": "" }, { "docid": "46689e9b23738530810d4c05515af91a", "score": "0.5288837", "text": "public function getTopProducts(){\r\n $this->products = array();\r\n try {\r\n include_once __DIR__.'\\..\\cruds\\productCrud.php';\r\n $productCrud = new ProductCrud($this->crud);\r\n $dbProducts = $productCrud->readTopProducts();\r\n $rankingCounter = 1;\r\n foreach($dbProducts as $product){\r\n include_once __DIR__.'\\..\\objects\\productWithExtra.php';\r\n $product = new ProductWithExtra($product);\r\n $product->setRanking($rankingCounter);\r\n $rankingCounter += 1;\r\n $this->products[$product->product_id] = $product;\r\n }\r\n }\r\n catch (PDOException $e){\r\n $this->exception = DATABASE_ERROR;\r\n $this->debugLog('Getting all the top products failed with the following error: '. $e->getMessage());\r\n $this->debugLog = 'Getting all the top products failed with the following error: '. $e->getMessage();\r\n }\r\n }", "title": "" }, { "docid": "4e80a0a12299b1ae6475c9bc17540ab2", "score": "0.52885914", "text": "public function get_last_erp_id(){\n\t\tglobal $wpdb;\n\t\t$results = $wpdb->get_results( \"SELECT meta_value FROM $wpdb->postmeta WHERE meta_key = 'erp_product_id' ORDER BY CAST(meta_value AS UNSIGNED) DESC LIMIT 1;\", ARRAY_A );\n\t\tif(count($results)==0){\n\t\t\treturn NULL;\n\t\t}\n\t\telseif(count($results==1)){\n\t\t\treturn $results[0][\"meta_value\"];\n\t\t}\n\t}", "title": "" }, { "docid": "13db5d96820916394e869d53a5091a49", "score": "0.5288039", "text": "public function latestFromCanon(){\n$query=\"SELECT*FROM table_product WHERE brandId='19' ORDER BY productId DESC LIMIT 1\";\n$result=$this->db->select($query);\nreturn $result;\n }", "title": "" }, { "docid": "37cefb2500d57110c3c3bb4fdbc44f9d", "score": "0.52876055", "text": "function get_max($table, $column, $where = [])\n {\n $ci =& get_instance();\n\n //get data from databasea\n if (!empty($where) && $ci->db->field_exists($column, $table)) {\n //get data from databasea\n $ci->db->select_max($column);\n $ci->db->where($where);\n $query = $ci->db->get($table);\n\n if ($query->num_rows() > 0) {\n $result = $query->row();\n return $result->$column;\n } else {\n return 0.00;\n }\n } else {\n return false;\n }\n }", "title": "" }, { "docid": "37cefb2500d57110c3c3bb4fdbc44f9d", "score": "0.52876055", "text": "function get_max($table, $column, $where = [])\n {\n $ci =& get_instance();\n\n //get data from databasea\n if (!empty($where) && $ci->db->field_exists($column, $table)) {\n //get data from databasea\n $ci->db->select_max($column);\n $ci->db->where($where);\n $query = $ci->db->get($table);\n\n if ($query->num_rows() > 0) {\n $result = $query->row();\n return $result->$column;\n } else {\n return 0.00;\n }\n } else {\n return false;\n }\n }", "title": "" }, { "docid": "3ffedd3c1dc4b647de22e0a1b740a816", "score": "0.52835137", "text": "public function getTopGiver() {\n $mongo = new MongoClient();\n $db = $mongo->highscores;\n $collection = $db->ledger;\n \n\n $userStats = $collection->aggregate(array(\n array('$match' => array('value' => array('$gte' => 0))), \n array('$group' => array('_id' => '$from', 'value' => array('$sum' => '$value'))),\n array('$match' => array('value' => array('$ne' => 0))),\n array('$sort' => array('value' => -1))\n ));\n if(empty($userStats['result'])) {\n return '';\n }\n\n $result = \"the most giving-est users is:\\n\";\n\n foreach($userStats['result'] as $stat) {\n $result .= $stat['_id'] . ' with ' . $stat['value'] . \" gives\\n\";\n }\n\n return $result;\n }", "title": "" }, { "docid": "c46edc5a9a092d70c86e5bd21c776460", "score": "0.52798116", "text": "function helpful_get_most_helpful( $limit = null, $post_type = null ) {\n\t\t$items = Helpers\\Stats::get_most_helpful( $limit, $post_type );\n\n\t\tif ( isset( $items[0]['pro'] ) ) {\n\t\t\tusort( $items, function ( $a, $b ) {\n\t\t\t\treturn $b['pro'] - $a['pro'];\n\t\t\t} );\n\t\t}\n\n\t\treturn $items;\n\t}", "title": "" }, { "docid": "3a6b59aa89aaf653c64c300fa35b45a9", "score": "0.5274578", "text": "public function getAfterSale()\n {\n $before_sale = $this->getProduct()->getPrice();\n return $before_sale-(($this->getValue()/100)*$before_sale);\n }", "title": "" }, { "docid": "0c22a3bfa0ab54b540c0d75d2dd45325", "score": "0.5271268", "text": "function getSaldoMax($idmuda,$idtua)\n {\n\n $sql = pg_query($this->conn,\"select saldo from db_schema.rekening WHERE id_nasabah IN (\". implode(',',$idmuda) .\")\");\n $listmuda = [];\n while ($data = pg_fetch_array($sql))\n {\n array_push($listmuda,$data['saldo']);\n }\n $max_value_m = 0;\n for($i=0;$i<count($listmuda) ;$i++){\n if($listmuda[$i] > $max_value_m){\n $max_value_m=$listmuda[$i];\n }\n }\n echo \"Saldo Terbesar ID Muda => \".$this->rupiah($max_value_m).' <br/>';\n\n /* --------------------------------------- Saldo Maksimum ID Tua --------------------------------------- */\n\n $sql1 = pg_query($this->conn,\"select saldo from db_schema.rekening WHERE id_nasabah IN (\". implode(',',$idtua) .\")\");\n $listtua = [];\n while ($data = pg_fetch_array($sql1))\n {\n array_push($listtua,$data['saldo']);\n }\n $max_value_t = 0;\n for($i=0;$i<count($listtua) ;$i++){\n if($listtua[$i] > $max_value_t){\n $max_value_t=$listtua[$i];\n }\n }\n echo \"Saldo Terbesar ID Tua => \".$this->rupiah($max_value_t).' <br/>';\n\n /* --------------------------------------- Total Saldo Maksimum ID Muda dan Tua --------------------------------------- */\n\n $total_max = $max_value_m + $max_value_t;\n echo \"Total Saldo Maksimum ID Muda dan Tua => \".$this->rupiah($total_max);\n }", "title": "" } ]
6774fd6ca855ea4975ecbf7bbd284e06
introduce the FAQ part
[ { "docid": "cd5c6c429387831bc11cf79263a04714", "score": "0.6319906", "text": "public function intro(){\n\t\t$html = \"\";\n\t\t$html.= '\n\t\t<div class=\"row description\">\n\t\t\t<div class=\"row\">\n\t\t\t\t<div class=\"small-12 large-12 columns\">\n\t\t\t\t\t<h1>FAQ</h1>\n\t\t\t\t\t<hr/>\n\t\t\t\t\t<p class=\"center\">La FAQ contient toutes les questions et précisions sur le monde d\\'Altraya. N\\'hésitez pas à souvent la consulter !</p>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t';\n\t\techo($html);\n\t}", "title": "" } ]
[ { "docid": "7a4bb81b5b4274a3e001283192e3d33b", "score": "0.73806113", "text": "public function faq()\n {\n $blogs = $this->common_model->getRecords(TABLES::$MST_BLOG_POSTS,'',array('status'=>'1'),'post_id desc','3');\n $this->template->set('blogs', $blogs);\n $this->template->set('global', $this->global_setting);\n $this->template->set('global_setting', $this->global_setting);\n $this->template->set('page', 'faq');\n $this->template->set_theme('default_theme');\n $this->template->set_layout('frontend')\n ->title($this->global_setting['site_title'] . ' | FAQ')\n ->set_partial('header', 'partials/header')\n ->set_partial('footer', 'partials/footer');\n $this->template->build('frontpages/faq');\n }", "title": "" }, { "docid": "d53200ea0f42e3d26ca0318b5859f5e6", "score": "0.70777035", "text": "public static function ToFAQ()\r\n\t\t{\r\n\t\t\treturn self::Build('faq/');\r\n\t\t}", "title": "" }, { "docid": "2165db9cdbb3e21a97cf571a07366c72", "score": "0.7006275", "text": "public function faqAction()\n {\n\t\t//GET NAVIGATION\n \t$this->view->navigation = Engine_Api::_()->getApi('menus', 'core')\n \t ->getNavigation('document_admin_main', array(), 'document_admin_main_faq');\n\n\t\t$this->view->show = $this->_getParam('show');\n }", "title": "" }, { "docid": "bb59d9595e9e3c0c81915407c583988d", "score": "0.6974466", "text": "public function executeFaq()\n {\n $this->headline = HeadlinePeer::getHeadlineFromType('faq');\n $this->setTemplate('about');\n }", "title": "" }, { "docid": "1a0133589d563a1cb69bf16c1204c8da", "score": "0.6890736", "text": "public function faqAction()\n {\n $this->view->headTitle($this->_headPrefix . 'Frequently Asked Questions');\n $this->view->messages = $this->_flashMessenger->getMessages();\n\n $inst = Zend_Registry::get('config')->institution;\n $this->view->inst = $inst;\n if (is_file(Bootstrap::$rootDirectory . '/../institution/' . $inst . '/FAQ.php'))\n {\n \t$faqClass = $inst . '_FAQ';\n \t$faq = new $faqClass;\n }\n else\n {\n \t$faq = new Sahara_DefaultInfo;\n }\n\n $this->view->faq = $faq->getFAQ();\n }", "title": "" }, { "docid": "4ba1e7710da6ba147294ff9f1b92e216", "score": "0.68751365", "text": "function _h_add_faq_schema_v1() {\n if (is_home()) { return; } // abort if blog page\n\n global $post;\n $content = isset($post) ? $post->post_content : null;\n\n // Find FAQ with --noindex class\n preg_match_all('/wp-block-h-faq(?!.*--noindex).*>(.+)<\\/details/Ui', $content, $faqs);\n\n // if FAQ found\n if (empty($faqs[1])) { return; }\n\n $data = [\n '@context' => 'https://schema.org',\n '@type' => 'FAQPage',\n 'mainEntity' => [],\n ];\n\n foreach ($faqs[1] as $f) {\n // parse the Question and Answer\n preg_match('/<summary.+>(.+)<\\/summary>/Ui', $f, $question);\n preg_match('/h-faq-answer.+>(.+)<\\/div>$/Ui', $f, $answer);\n\n // abort if question or answer is empty\n if (!isset($question[1]) || !isset($answer[1])) { continue; }\n\n // Add to question lists\n $data['mainEntity'][] = [\n '@type' => 'Question',\n 'name' => $question[1],\n 'acceptedAnswer' => [\n '@type' => 'Answer',\n 'text' => $answer[1]\n ]\n ];\n }\n \n $json_ld = json_encode($data);\n echo \"<!-- Edje FAQ --><script type='application/ld+json'>$json_ld</script>\";\n}", "title": "" }, { "docid": "a57f8030a0f3816513c3575980d12ff5", "score": "0.6844102", "text": "function faq(){\n\t\t$sql=\"select * from gas_faq\";\n\n\t\t$sentencia=mysql_query($sql,$this->id_con);\n\n\t\twhile($rs=mysql_fetch_array($sentencia,MYSQL_BOTH)){\n\n\t\t\techo '<div class=\"row\">\n\t\t\t<ul class=\"list-group\">';\n\t\t\t\techo '<li class=\"list-group-item\"><p>'.$rs['pregunta'].'</p></li>\n\t\t\t\t<li class=\"list-group-item\"><p>'.$rs['respuesta'].'</p></li>';\n\t\t\t\tif ($rs['link']!=\"\") {\t\t\t\t\t\n\t\t\t\t\techo '<li class=\"list-group-item\"><a href=\"'.$rs['link'].'\">LINK</a></li>\t';\n\t\t\t\t}\n\t\t\t\techo '</ul> </div>';\t\t\t\n\t\t\t}\n\n\t\t}", "title": "" }, { "docid": "4b7273367459e4ff6687faa7e06e5f07", "score": "0.6769591", "text": "public function get_name() {\n\t\treturn 'faq';\n\t}", "title": "" }, { "docid": "bd86ed7c6d431167964c827a769b2373", "score": "0.6682795", "text": "public function faq()\n\t{\n\t\treturn view('pages.faq');\n\t}", "title": "" }, { "docid": "ca586700d45754a488db44ffde88b1a5", "score": "0.66550136", "text": "public function faq()\n {\n ?>\n <b>Frequently Asked Questions</b> <a href=\"web-settings.php?id=Faq&&moduleID=AddFaq\">\n <button>Add New</button>\n </a>\n <br><br><br>\n <table width=\"100%\" cellpadding=\"10\" cellspacing=\"0\" border=\"0\">\n <tbody>\n <tr>\n <td class=\"tableTop\">Question</td>\n </tr>\n <?php\n $stmt = $this->objDB->prepare(\"SELECT faqID, faqQuestion, faqAnswer FROM faq ORDER BY faqOrder\");\n $stmt->execute();\n $stmt->bind_result($faqID, $faqQuestion, $faqAnswer);\n while ($checkRow = $stmt->fetch()) {\n ?>\n <tr class=\"rowRef\" style=\"\"\n onclick=\"location.href = 'web-settings.php?id=Faq&&moduleID=EditFaq&&faqID=<?= $faqID; ?>'\">\n <td width=\"40%\">\n <?= $faqQuestion; ?>\n </td>\n </tr>\n <?php\n }\n ?>\n </tbody>\n </table>\n <?php\n }", "title": "" }, { "docid": "f570324fb42e80c0a6282a4a79882deb", "score": "0.6611795", "text": "public function faq()\n {\n $data['site_info'] = $this->config->item('site_info');\n $data['base_url'] = $this->config->item('base_url');\n $data['site_page'] = 'help';\n\n // Title\n $data['title_addition'] = 'Faq';\n\n // Load stuff\n $data['stylesheet'] = 'help';\n $data['javascript'] = 'help';\n\n // Load header library\n //$this->load->library('ForgotPasswordSystem.php');\n\n // load the view\n $this->load->view('templates/header.php', $data);\n $this->load->view('home/help/faq');\n $this->load->view('templates/footer.php');\n }", "title": "" }, { "docid": "a5291e7a3317913d1f0e9c874d538bc1", "score": "0.65509564", "text": "public function faqs_screen() {\n\t\t?>\n\t\t<div class=\"wrap about-wrap\">\n\n\t\t<?php $this->intro(); ?>\n\n\t\t<h3><?php echo __(\"FAQ / Common Problems\", SA_Smart_Offers::$text_domain); ?></h3>\n\n\t\t<?php\n \t$faqs = array(\n \t\t\t\tarray(\n \t\t\t\t\t\t'que' => __( 'Is it possible to change the text & look of “Yes, Add to Cart” and “No, I want to skip” ?', SA_Smart_Offers::$text_domain ),\n \t\t\t\t\t\t'ans' => sprintf(__( 'Yes, it is possible to change the text and look of the “Yes, Add to Cart” and “No, I want to skip”. The text can be changed in the Offer Description and style can be changed by going to %s', SA_Smart_Offers::$text_domain ), '<a href=\"' . admin_url( 'admin.php?page=wc-settings&tab=smart_offers' ) . '\" target=\"_blank\">' . __( 'Settings', SA_Smart_Offers::$text_domain ) . '</a>' )\n \t\t\t\t\t),\n \t\t\t\tarray(\n \t\t\t\t\t\t'que' => __( 'Are there any pre-defined button styles for Add to Cart links?', SA_Smart_Offers::$text_domain ),\n \t\t\t\t\t\t'ans' => sprintf(__( 'Yes, Smart Offers gives you 3 pre-defined styles for Add to Cart links. You can find it in Smart Offers global %s', SA_Smart_Offers::$text_domain ), '<a href=\"' . admin_url( 'admin.php?page=wc-settings&tab=smart_offers' ) . '\" target=\"_blank\">' . __( 'Settings', SA_Smart_Offers::$text_domain ) . '</a>' )\n \t\t\t\t\t),\n \t\t\t\tarray(\n \t\t\t\t\t\t'que' => __( 'Is Smart Offers WPML (Multilingual usage) compatible ?', SA_Smart_Offers::$text_domain ),\n \t\t\t\t\t\t'ans' => __( 'Yes, Smart Offers is WPML compatible.', SA_Smart_Offers::$text_domain )\n \t\t\t\t\t),\n \t\t\t\tarray(\n \t\t\t\t\t\t'que' => __( 'I have setup offer to display as Popup but it shows as an Inline Offer.', SA_Smart_Offers::$text_domain ),\n \t\t\t\t\t\t'ans' => __( 'Have you selected multiple offers to display on that same one page? If yes, then it is behaving correctly i.e. when you wish to show multiple offers all offers will be shown “Inline”', SA_Smart_Offers::$text_domain )\n \t\t\t\t\t),\n \t\t\t\tarray(\n \t\t\t\t\t\t'que' => __( 'How can I check Conversion rate of my offers?', SA_Smart_Offers::$text_domain ),\n \t\t\t\t\t\t'ans' => __( 'You can know how much money you are making from your Offers from Smart Offers Dashboard widget on dashboard page. Smart Offers Dashboard shows you the statistics of how many times an offer was shown, accepted, skipped and paid through. It also tells you the conversion rate for offers', SA_Smart_Offers::$text_domain )\n \t\t\t\t\t),\n \t\t\t\tarray(\n \t\t\t\t\t\t'que' => __( 'I have added shortcode <code>[so_quantity]</code> but quantity box doesn\\'t appear in offer.', SA_Smart_Offers::$text_domain ),\n \t\t\t\t\t\t'ans' => __( 'That is because you haven\\'t added any parameter to the shortcode. To show quantity in the offer, add <code>[so_quantity allow_change=true]</code>, this will show quantity box in the offer.', SA_Smart_Offers::$text_domain )\n \t\t\t\t\t),\n \t\t\t\tarray(\n \t\t\t\t\t\t'que' => __( 'I can\\'t find a way to do X...', SA_Smart_Offers::$text_domain ),\n \t\t\t\t\t\t'ans' => __( 'Smart Offers is actively developed. If you can\\'t find your favorite feature (or have a suggestion) contact us. We\\'d love to hear from you.', SA_Smart_Offers::$text_domain )\n \t\t\t\t\t)\n \t\t\t);\n\n\t\t\t\t$faqs = array_chunk( $faqs, 2 );\n\n\t\t\t\techo '<div>';\n\t\t\t\tforeach ( $faqs as $fqs ) {\n\t\t\t\t\techo '<div class=\"two-col\">';\n\t\t\t\t\tforeach ( $fqs as $index => $faq ) {\n\t\t\t\t\t\techo '<div' . ( ( $index == 1 ) ? ' class=\"col last-feature\"' : ' class=\"col\"' ) . '>';\n\t\t\t\t\t\techo '<h4>' . $faq['que'] . '</h4>';\n\t\t\t\t\t\techo '<p>' . $faq['ans'] . '</p>';\n\t\t\t\t\t\techo '</div>';\n\t\t\t\t\t}\n\t\t\t\t\techo '</div>';\n\t\t\t\t}\n\t\t\t\techo '</div>';\n\t \t?>\n\n\t\t\t</div>\n\t\t\n\t\t<?php\n\t}", "title": "" }, { "docid": "d2a7d735f246cb8882b743b98d10b617", "score": "0.65420425", "text": "public function faqs()\n\t{\n\t\t$data['data_faqs'] = [\n\t\t\t[\n\t\t\t\t'question' => 'Apa itu Codeigniter?',\n\t\t\t\t'answer' => 'Codeigniter adalah framework untuk membuat web'\n\t\t\t],\n\t\t\t[\n\t\t\t\t'question' => 'Siapa yang membuat Codeiginter?',\n\t\t\t\t'answer' => 'CI awalnya dibuat oleh Ellislab'\n\t\t\t],\n\t\t\t[\n\t\t\t\t'question' => 'Codeigniter versi berapakah yang digunakan pada tutoril ini?',\n\t\t\t\t'answer' => 'Codeigniter versi 4.0.4'\n\t\t\t]\n\t\t];\n\n\t\t// load view dengan data\n\t\techo view(\"faqs\", $data);\n\t}", "title": "" }, { "docid": "be8951487a44ef9b99833bc3903b151d", "score": "0.6541988", "text": "public function actionfaq()\n\t{\n\t\t// using the default layout 'protected/views/layouts/main.php'\n\t\t$test = Testtype::model()->findall(array('order' => 'ApplicationStartDate ASC'));\n\t\t$this->render('pages/faq', array('tests' => $test));\n\t}", "title": "" }, { "docid": "62a92f9e1883a7574db6f901849dbdd6", "score": "0.64805937", "text": "function main()\t{\r\n\t\tglobal $LANG;\r\n\r\n\t\tif ($this->P['table'] && $this->P['field'] && $this->P['uid'])\t{\r\n\t\t\t$this->content.=$this->doc->section($LANG->getLL('quest_title'),$this->questionnaireWizard(),0,1);\t\t\t\r\n\t\t} else {\r\n\t\t\t$this->content.=$this->doc->section($LANG->getLL('quest_title'),'<span class=\"typo3-red\">'.$LANG->getLL('table_noData',1).'</span>',0,1);\t\t\t\r\n\t\t}\r\n\t\t$this->content.=$this->doc->endPage();\r\n\t}", "title": "" }, { "docid": "7d01a0829537665534b01f31c032f838", "score": "0.6450687", "text": "public function run()\n {\n Model::unguard();\n\n $faq = [\n \t\t\t[\n \t\t\t\t'title' \t\t\t\t=> 'Wanneer en waar kan er ingeschreven worden?',\n \t\t\t\t'slug' \t\t\t\t\t=> str_slug('Wanneer en waar kan er ingeschreven worden?', '-'),\n \t\t\t\t'content' \t\t\t=>\n\t\t\t\t\t\t'<p>\n\t\t\t\t\t\t\n\t\t\t\t\t\tWe houden als organisatie 3 inschrijf momenten en deze vinden plaats op een woensdag en zaterdag in de aanloop naar de avondvierdaagse. \n\t\t\t\t\t\tDaarnaast kunt u ook nog uw inschrijving regelen op de startdag van de avondvierdaagse en dit is op dinsdag. \n\t\t\t\t\t\t<br><br>\n\t\t\t\t\t\tOp woensdag 12-06-2019 tussen 12.00 en 13.00 kunt u zich inschrijven op de volgende 2 lokaties:\n\t\t\t\t\t\t<br>\n\t\t\t\t\t\t<ul>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\tOBS De Tweesprong\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\tKBS De Weilust\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t</ul>\n\t\t\t\t\t\tOp zaterdag 15-06-2019 tussen 10.00 en 13.00 kunt u zich inschrijven op de volgende 2 lokaties:\n\t\t\t\t\t\t<br>\n\t\t\t\t\t\t<ul>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\tAlbert Heijn Bischopshoeve\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\tAlbert Heijn Brabantplein\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t</ul>\n\t\t\t\t\t\t<br>\n\t\t\t\t\t\tOp deze lokaties vindt u vrijwilligers van de a4d Breda Oost. \n\t\t\t\t\t\t<br><br>\n\t\t\t\t\t\tOp dinsdag 18-06-2019 is er nog een mogelijkheid om in te schrijven op de start locatie. De tijden hiervoor zijn van 17.30 tot 18.30.\n\t\t\t\t\t\t\n\t\t\t\t\t\t</p>',\n \t\t\t\t'description'\t \t\t\t=> 'Informatie over wanneer en waar de inschrijvingen plaats vinden.',\n \t\t\t\t'web_order' \t\t\t=> 1,\n \t\t\t\t'faq_categorie_id' \t\t=> 1,\n \t\t\t\t'draft' \t\t\t\t=> 1,\n \t\t\t\t'author' \t\t\t\t=> 6,\n \t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'author_approve' \t\t=> 1,\n \t\t\t\t'editor' \t\t\t\t=> 6,\n \t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'editor_approve' \t\t=> 1,\n \t\t\t\t'publisher' \t\t\t=> 6,\n \t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n \t\t\t\t'publisher_approve' \t=> 1,\n \t\t\t\t'publish_date_start' \t=> Carbon::now(),\n \t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n \t\t\t[\n \t\t\t\t'title' \t\t\t\t=> 'Is legitimatie verplicht bij de inschrijving?',\n \t\t\t\t'slug' \t\t\t\t\t=> str_slug('Is legitimatie verplicht bij de inschrijving?', '-'),\n \t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tNee, dit is niet nodig. We gaan er vanuit dat alles op een eerlijke manier zal gebeuren. \n \t\t\t\tHier mogen we toch wel vertrouwen in hebben. \n \t\t\t\tMocht er toch nog twijfel bestaan over de leeftijden van de jongere deelnemers \n \t\t\t\tdan wordt er alsnog om legitimatie verzocht. Dit is puur om veiligheids redenen.\n \t\t\t\t</p>',\n \t\t\t\t'description'\t \t\t\t=> 'Legitimatie i.v.m. de leeftijd van de deelnemers',\n \t\t\t\t'web_order' \t\t\t=> 2,\n \t\t\t\t'faq_categorie_id' \t\t=> 1,\n \t\t\t\t'draft' \t\t\t\t=> 1,\n \t\t\t\t'author' \t\t\t\t=> 6,\n \t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'author_approve' \t\t=> 1,\n \t\t\t\t'editor' \t\t\t\t=> 6,\n \t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'editor_approve' \t\t=> 1,\n \t\t\t\t'publisher' \t\t\t=> 6,\n \t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n \t\t\t\t'publisher_approve' \t=> 1,\n \t\t\t\t'publish_date_start' \t=> Carbon::now(),\n \t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n \t\t\t[\n \t\t\t\t'title' \t\t\t\t=> 'Ik wil met mijn zoon / dochter meelopen. Moet ik me nu verplicht inschrijven ?',\n \t\t\t\t'slug' \t\t\t\t\t=> str_slug('Ik wil met mijn zoon / dochter meelopen. Moet ik me nu verplicht inschrijven ?', '-'),\n \t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tU bent niet verplicht tot inschrijving wanneer u mee loopt maar met uw inschrijving \n \t\t\t\tsteunt u ook de avondvierdaagse voor uw zoon / dochter. \n \t\t\t\tUiteraard kunt u dan ook gebruik maken van de versnaperingen onderweg en \n \t\t\t\taan het eind een medaille in ontvangst nemen.\n \t\t\t\t</p>',\n \t\t\t\t'description'\t \t\t\t=> 'Is de inschrijving verplicht?',\n \t\t\t\t'web_order' \t\t\t=> 3,\n \t\t\t\t'faq_categorie_id' \t\t=> 1,\n \t\t\t\t'draft' \t\t\t\t=> 1,\n \t\t\t\t'author' \t\t\t\t=> 6,\n \t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'author_approve' \t\t=> 1,\n \t\t\t\t'editor' \t\t\t\t=> 6,\n \t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'editor_approve' \t\t=> 1,\n \t\t\t\t'publisher' \t\t\t=> 6,\n \t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n \t\t\t\t'publisher_approve' \t=> 1,\n \t\t\t\t'publish_date_start' \t=> Carbon::now(),\n \t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n \t\t\t[\n \t\t\t\t'title' \t\t\t\t=> 'Mag ik ook mijn kleinkinderen inschrijven ?',\n \t\t\t\t'slug' \t\t\t\t\t=> str_slug('Mag ik ook mijn kleinkinderen inschrijven ?', '-'),\n \t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tZeer zeker dat dit mag. \n \t\t\t\tDe avondvierdaagse is altijd al een soort van familiefeest geweest en dit willen we graag zo houden. \n \t\t\t\tHet zou helemaal geweldig zijn wanneer u zelf ook meeloopt.\n \t\t\t\t</p>',\n \t\t\t\t'description'\t \t\t\t=> 'Kunnen mijn kleinkinderen ingeschreven worden?',\n \t\t\t\t'web_order' \t\t\t=> 4,\n \t\t\t\t'faq_categorie_id' \t\t=> 1,\n \t\t\t\t'draft' \t\t\t\t=> 1,\n \t\t\t\t'author' \t\t\t\t=> 6,\n \t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'author_approve' \t\t=> 1,\n \t\t\t\t'editor' \t\t\t\t=> 6,\n \t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'editor_approve' \t\t=> 1,\n \t\t\t\t'publisher' \t\t\t=> 6,\n \t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n \t\t\t\t'publisher_approve' \t=> 1,\n \t\t\t\t'publish_date_start' \t=> Carbon::now(),\n \t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n \t\t\t[\n \t\t\t\t'title' \t\t\t\t=> 'Wat zijn de inschrijvingskosten ?',\n \t\t\t\t'slug' \t\t\t\t\t=> str_slug('Wat zijn de inschrijvingskosten ?', '-'),\n \t\t\t\t'content' \t\t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tTijdens de voorinschrijving op de scholen en bij de supermarkten zijn de kosten € 3,50. \n \t\t\t\t<br>\n\t\t\t\t\t\tInschrijven op de startdag bij PCP kost € 4,50 \n\t\t\t\t\t\t<br>\n\t\t\t\t\t\tDe kosten dienen contant voldaan te worden.\n \t\t\t\t</p>',\n \t\t\t\t'description'\t \t\t=> 'Wat zijn de kosten bij inschrijving?',\n \t\t\t\t'web_order' \t\t\t=> 5,\n \t\t\t\t'faq_categorie_id' \t\t=> 1,\n \t\t\t\t'draft' \t\t\t\t=> 1,\n \t\t\t\t'author' \t\t\t\t=> 6,\n \t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'author_approve' \t\t=> 1,\n \t\t\t\t'editor' \t\t\t\t=> 6,\n \t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'editor_approve' \t\t=> 1,\n \t\t\t\t'publisher' \t\t\t=> 6,\n \t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n \t\t\t\t'publisher_approve' \t=> 1,\n \t\t\t\t'publish_date_start' \t=> Carbon::now(),\n \t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n \t\t\t[\n \t\t\t\t'title' \t\t\t\t=> 'Welke afstanden kunnen er worden gelopen?',\n \t\t\t\t'slug' \t\t\t\t\t=> str_slug('Welke afstanden kunnen er worden gelopen?', '-'),\n \t\t\t\t'content' \t\t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tWij hebben 4 afstanden:\n \t\t\t\t<ul>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t2,5 km\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t5 km\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t7,5 km\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t10 km\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t</ul>\n \t\t\t\t</p>',\n \t\t\t\t'description'\t \t\t\t=> 'Wat zijn de afstanden?',\n \t\t\t\t'web_order' \t\t\t=> 6,\n \t\t\t\t'faq_categorie_id' \t\t=> 1,\n \t\t\t\t'draft' \t\t\t\t=> 1,\n \t\t\t\t'author' \t\t\t\t=> 6,\n \t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'author_approve' \t\t=> 1,\n \t\t\t\t'editor' \t\t\t\t=> 6,\n \t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'editor_approve' \t\t=> 1,\n \t\t\t\t'publisher' \t\t\t=> 6,\n \t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n \t\t\t\t'publisher_approve' \t=> 1,\n \t\t\t\t'publish_date_start' \t=> Carbon::now(),\n \t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n \t\t\t[\n \t\t\t\t'title' \t\t\t\t=> 'Hoe oud moet je zijn?',\n \t\t\t\t'slug' \t\t\t\t\t=> str_slug('Hoe oud moet je zijn?', '-'),\n \t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tVoor onze afstanden hebben we wel regels voor wat betreft de afstanden. \n \t\t\t\tHieronder de regels per afstand.\n \t\t\t\t<ul>\n \t\t\t\t\t<li>\n \t\t\t\t\t\t<b>2,5 km :</b> Voor deze afstand geldt geen leeftijd. \n \t\t\t\t\t\tVan jong tot oud mag je jezelf op deze afstand inschrijven.\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t<b>5 km :</b> Voor deze afstand geldt geen leeftijd. \n\t\t\t\t\t\t\t\tVan jong tot oud mag je jezelf op deze afstand inschrijven.\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t<b>7,5 km :</b> De minimum leeftijd voor deze afstand is 12 jaar. \n\t\t\t\t\t\t\t\tEchter zit hier dan wel de voorwaarde aan dat dit onder begeleiding van een volwassene is. \n\t\t\t\t\t\t\t\tVanaf de leeftijd van 16 jaar mag deze afstand zelfstandig gelopen worden.\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t<b>10 km :</b> De minimum leeftijd voor deze afstand is 12 jaar. \n\t\t\t\t\t\t\t\tEchter zit hier dan wel de voorwaarde aan dat dit onder begeleiding van een volwassene is. \n\t\t\t\t\t\t\t\tVanaf de leeftijd van 16 jaar mag deze afstand zelfstandig gelopen worden.\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t</ul>\n\t\t\t\t\t\tI.v.m. de minimum leeftijd en de begeleiding op de \"lange\" afstanden kan er bij twijfel gevraagd worden om te legitimeren op leeftijd.\n\n \t\t\t\t</p>',\n \t\t\t\t'description'\t \t\t\t=> 'De leeftijden per afstand uitgewerkt',\n \t\t\t\t'web_order' \t\t\t=> 7,\n \t\t\t\t'faq_categorie_id' \t\t=> 1,\n \t\t\t\t'draft' \t\t\t\t=> 1,\n \t\t\t\t'author' \t\t\t\t=> 6,\n \t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'author_approve' \t\t=> 1,\n \t\t\t\t'editor' \t\t\t\t=> 6,\n \t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n \t\t\t\t'editor_approve' \t\t=> 1,\n \t\t\t\t'publisher' \t\t\t=> 6,\n \t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n \t\t\t\t'publisher_approve' \t=> 1,\n \t\t\t\t'publish_date_start' \t=> Carbon::now(),\n \t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\n\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Zoeken jullie nog extra mensen voor ondersteuning ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Zoeken jullie nog extra mensen voor ondersteuning ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tWe zijn altijd op zoek naar vrijwilligers. Hoe meer hoe liever want het is niet zo dat alle vrijwilligers ook elke dag kunnen. \n\t\t\t\t\t\tOok voor het bestuur en de werkgroepen zijn we op zoek naar ondersteuning. \n\t\t\t\t\t\tStuur ons een berichtje via de <a href=\"/contact\" class=\"text-success\">contactpagina</a> en we laten u de mogelijkheden weten.\n\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Vrijwilligers gevraagd',\n\t\t\t\t\t\t'web_order' \t\t\t=> 1,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 2,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Hoeveel uur steken jullie in de organisatie ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Hoeveel uur steken jullie in de organisatie ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tDit is een vraag die bijna niet te beantwoorden is. \n\t\t\t\t\t\tGedurende het jaar zitten er al redelijk wat uren in maar in de week van de avondvierdaagse zijn we bijna fulltime bezig.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Hoeveel uur zijn we bezig met de organisatie.',\n\t\t\t\t\t\t'web_order' \t\t\t=> 2,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 2,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\n\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Wat is de start lokatie ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Wat is de start lokatie ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\t\tAl heel wat jaren is de start van het evenement op het PCP terrein Sportpark De lage Kant Noord. \n \t\t\t\t\t<br>\n\t\t\t\t\t\t\tWij starten dagelijks van deze lokatie.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'De start lokatie',\n\t\t\t\t\t\t'web_order' \t\t\t=> 1,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> ' Wat zijn de starttijden ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug(' Wat zijn de starttijden ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tIn de starttijden zitten een aantal wisselingen, vandaar dat we hieronder even een opsomming maken:\n \t\t\t\t<ul>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t<b>Dinsdag : </b>\n\t\t\t\t\t\t\t\tDeze dag is de openingsdag en dan zouden wij het waarderen dat iedereen om 18.30 aanwezig is. \n\t\t\t\t\t\t\t\tWij starten dan nadat het welkomstwoord is gesproken.\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t<b>Woensdag :</b>\n\t\t\t\t\t\t\t\tStarten tussen 18.30 en 19.00\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t<b>Donderdag :</b>\n\t\t\t\t\t\t\t\tStarten tussen 18.30 en 19.00\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t<b>Vrijdag :</b>\n\t\t\t\t\t\t\t\tOp deze dag is de huldiging van de gelopen avondvierdaagse. \n\t\t\t\t\t\t\t\tOm ervoor te zorgen dat alle afstanden op een gelijk moment bij de finish aankomen hebben we op deze dag verschillende starttijden.\n\t\t\t\t\t\t\t\t<ul>\n\t\t\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t\t\t<b>2,5 km :</b>\n\t\t\t\t\t\t\t\t\t\tDeze afstand start om 19.30\n\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t\t\t<b>5 km :</b>\n\t\t\t\t\t\t\t\t\t\tDeze afstand start om 18.30\n\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t\t\t<b>7,5 km :</b>\n\t\t\t\t\t\t\t\t\t\tDeze afstand start om 18.15\n\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t\t\t<b>10 km :</b>\n\t\t\t\t\t\t\t\t\t\tDeze afstand start om 18.00\n\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t</ul>\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t</ul>\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'De starttijden voor de verschillende afstanden',\n\t\t\t\t\t\t'web_order' \t\t\t=> 2,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Wanneer en waar is de huldiging ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Wanneer en waar is de huldiging ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tDe huldiging vindt jaarlijks plaats bij PCP. De lokatie van waar we ook de start hebben. \n\t\t\t\t\t\tWe plannen het zo, dat de officiële binnenkomst`op vrijdag om 20.00 uur is.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'De huldiging',\n\t\t\t\t\t\t'web_order' \t\t\t=> 3,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Waar is het verzamelpunt ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Waar is het verzamelpunt ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tHet verzamelpunt, op de slotavond, wisselt jaarlijks. \n \t\t\t\tAls organisatie kunnen we wel met zekerheid zeggen dat de huldiging plaats vindt bij het PCP terrein. \n \t\t\t\tVoor onze deelnemers zou het geweldig zijn wanneer hier een grote haag van mensen gevormd wordt\n \t\t\t\t voor de ontvangst en huldiging van onze deelnemers. \n \t\t\t\t Vanuit het verzamelpunt lopen wij hier altijd naar toe\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Verzamelpunt op de laatste dag',\n\t\t\t\t\t\t'web_order' \t\t\t=> 4,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Moet ik me melden voor de start ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Moet ik me melden voor de start ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tU moet zich te allen tijde melden voor de start. \n \t\t\t\tBij het melden ontvangt u een knipkaart. \n \t\t\t\tOp deze manier is het voor ons zichtbaar of alle deelnemers vertrokken zijn.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Melden bij start',\n\t\t\t\t\t\t'web_order' \t\t\t=> 5,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Moet ik me dan ook afmelden en waarom dan ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Moet ik me dan ook afmelden en waarom dan ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tBij het afmelden levert u, uw knipkaart in. \n \t\t\t\tOp het moment dat einde binnenkomst is kunnen we zien wie de knipkaart niet ingeleverd hebben. \n \t\t\t\tDeze deelnemers kunnen we in eerste instantie telefonisch benaderen om te kijken of ze al binnen zijn geweest. \n \t\t\t\tHet kan natuurlijk altijd zo zijn dat ze vergeten zijn hun knipkaart in te leveren. \n \t\t\t\tMocht het zo zijn dat de deelnemer door omstandigheden niet binnen is gekomen dan kunnen we altijd kijken hoe we tot een oplossing kunnen komen.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Afmelden bij binnenkomst',\n\t\t\t\t\t\t'web_order' \t\t\t=> 6,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Bij wie ligt de verantwoordelijkheid tijdens het evenement ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Bij wie ligt de verantwoordelijkheid tijdens het evenement ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tDeelname aan het evenement is altij op eigen risico. \n\t\t\t\t\t\tAls organisatie proberen wij de situaties zo veilig mogelijk te maken. \n\t\t\t\t\t\tHet is ook van groot belang om de aanwijzingen van de organisatie op te lopen. \n\t\t\t\t\t\tOnze verkeersregelaars zijn er om te zorgen voor een veilige oversteek.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Evenement is voor eigen risico',\n\t\t\t\t\t\t'web_order' \t\t\t=> 7,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Is het toegestaan om een baby mee te nemen in een kinderwagen ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Is het toegestaan om een baby mee te nemen in een kinderwagen ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tEr zijn voor de korte afstanden geen restricties op de leeftijden. \n\t\t\t\t\t\tHet is dus toegestaan om kleine en zeer kleine kinderen mee te nemen met ondersteuning van een kinderwagen of buggy.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Kinderen in buggy\\'s of kinderwagens.',\n\t\t\t\t\t\t'web_order' \t\t\t=> 8,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Hoe kom ik aan mijn route ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Hoe kom ik aan mijn route ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tWanneer de starttijd is aangebroken staan er vrijwilligers klaar met de routes. \n \t\t\t\tIedere vrijwilliger zal een eigen afstand hebben.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Route informatie',\n\t\t\t\t\t\t'web_order' \t\t\t=> 9,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Kan ik de route ook digitaal lopen ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Kan ik de route ook digitaal lopen ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\t Ja dit is mogelijk. De routes worden beschikbaar gesteld via de website <a href=\"afstandmeten.nl\" class=\"text-success\">afstandmeten.nl</a>. \n \t\t\t\t De inlog gegevens worden per dag bij de start verstrekt.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Digitale route',\n\t\t\t\t\t\t'web_order' \t\t\t=> 10,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Wie moet er in noodgevallen benaderd worden ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Wie moet er in noodgevallen benaderd worden ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tOp het routeformulier staat altijd het nummer vermeld van de calamiteiten persoon.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Nood nummer',\n\t\t\t\t\t\t'web_order' \t\t\t=> 11,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Het lukt me niet om alle dagen mee te doen. Krijg ik nu wel een medaille ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Het lukt me niet om alle dagen mee te doen. Krijg ik nu wel een medaille ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tEr zijn altijd momenten dat het niet lukt om alle dagen aanwezig te zijn. \n \t\t\t\tWij houden hier altijd rekening mee en u kunt op de laatste dag gewoon een medaille in ontvangst nemen.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Niet alle dagen dan wel een medaille?',\n\t\t\t\t\t\t'web_order' \t\t\t=> 12,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Wat gebeurt er bij slecht weer ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('t gebeurt er bij slecht weer ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tAls organisatie houden wij alle kanalen in de gaten. \n \t\t\t\tWeer radar, nieuwsberichten maar de belangrijkste is nog wel de informatie vanuit de politie en gemeente. \n \t\t\t\tWij proberen zo lang mogelijk te wachten met een beslissing te nemen bij slecht weer om er maar voor te \n \t\t\t\tzorgen dat we met plezier dit gezellige evenement af kunnen maken. \n \t\t\t\tHoudt tijdens de avondvierdaagse week onze website en onze social media kanalen in de gaten.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Slecht weer, en nu?',\n\t\t\t\t\t\t'web_order' \t\t\t=> 13,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'De afstand die we gekozen hebben blijkt te lang voor mijn zoon / dochter. Kunnen wij van afstand wisselen ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('De afstand die we gekozen hebben blijkt te lang voor mijn zoon / dochter. Kunnen wij van afstand wisselen ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tWanneer u zich voor de start meldt bij het secretariaat kunnen we uw inschrijving zo omzetten. \n\t\t\t\t\t\tHet zou jammer zijn wanneer uw zoon / dochter het plezier verliest in de avondvierdaagse doordat \n\t\t\t\t\t\tbij de inschrijving voor een verkeerde afstand gekozen is.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Gekozen afstand blijkt te lang',\n\t\t\t\t\t\t'web_order' \t\t\t=> 14,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 3,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\n\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Wat gebeurd er met de persoonlijke gegevens, van de deelnemers, die bij de inschrijving worden gebruikt ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Wat gebeurd er met de persoonlijke gegevens, van de deelnemers, die bij de inschrijving worden gebruikt ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\tDe informatie wordt tijdens het evenment gebruikt om te achterhalen wie de betreffende deelnemer is mochten er problemen zijn. \n \t\t\t\tHet zou zomaar kunnen gebeuren dat er iemand verdwaald of te laat binnen is. \n \t\t\t\tAan de hand van de informatie welke is gegeven bij de inschrijving kunnen wij direct contact zoeken. \n \t\t\t\t<br>\n \t\t\t\t<br>\n \t\t\t\tDe gegevens worden zo spoedig mogelijk, tot uiterlijk 1 week, na het evenement vernietigd.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> '',\n\t\t\t\t\t\t'web_order' \t\t\t=> 1,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 4,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'title' \t\t\t\t=> 'Wat gebeurd er met de foto\\'s gemaakt tijdens het evenement ?',\n\t\t\t\t\t\t'slug' \t\t\t\t\t=> str_slug('Wat gebeurd er met de foto\\'s gemaakt tijdens het evenement ?', '-'),\n\t\t\t\t\t\t'content' \t\t\t=> '\n \t\t\t\t<p>\n \t\t\t\t\n Bij de inschrijving heef u een akkoord gegeven voor gebruik op social media en website.\n Mocht er echter onverhoopt een foto geplaatst zijn waarvoor geen toestemming is gegeven,\n laat ons dit dan weten via het <a href=\"/contact\" class=\"text-success\">contactformulier</a>.\n Wij zullen er dan voor zorgen dat de betreffende foto zo spoedig mogelijk wordt verwijderd.\n \t\t\t\t</p>',\n\t\t\t\t\t\t'description'\t \t\t\t=> 'Wat er met de foto\\'s en videos gebeurd.',\n\t\t\t\t\t\t'web_order' \t\t\t=> 2,\n\t\t\t\t\t\t'faq_categorie_id' \t\t=> 4,\n\t\t\t\t\t\t'draft' \t\t\t\t=> 1,\n\t\t\t\t\t\t'author' \t\t\t\t=> 6,\n\t\t\t\t\t\t'author_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'author_approve' \t\t=> 1,\n\t\t\t\t\t\t'editor' \t\t\t\t=> 6,\n\t\t\t\t\t\t'editor_group' \t\t\t=> 'Boardmember',\n\t\t\t\t\t\t'editor_approve' \t\t=> 1,\n\t\t\t\t\t\t'publisher' \t\t\t=> 6,\n\t\t\t\t\t\t'publisher_group' \t\t=> 'Boardmember',\n\t\t\t\t\t\t'publisher_approve' \t=> 1,\n\t\t\t\t\t\t'publish_date_start' \t=> Carbon::now(),\n\t\t\t\t\t\t'publish_date_end' \t\t=> Carbon::yesterday(),\n\n\t\t\t\t\t],\n\n\t\t\t\t];\n\n\t\tforeach ($faq as $key => $value) {\n\t\t\tFaq::create($value);\n\t\t}\n }", "title": "" }, { "docid": "89b99d60e3deb36084aab1704d2b5c2f", "score": "0.64279586", "text": "function add_table_faq($question)\n {\n global $db, $function;\n $language = LANG_AUGE;\n $sql = \"INSERT INTO coupons_faq(question,language) VALUES('$question','$language')\";\n $res = $db->db_query($sql);\n\n return 1;\n }", "title": "" }, { "docid": "c1e919d48ae71def75eca3edb8dab401", "score": "0.6408963", "text": "public function show(Faq $faq)\n {\n //\n }", "title": "" }, { "docid": "99e53fb27b6fbb92febc9aae7d1f691f", "score": "0.640095", "text": "public function faq()\n {\n return view('site.faq');\n }", "title": "" }, { "docid": "82f25395533d55e724a1570ffe4a0c3c", "score": "0.63223004", "text": "public function run()\n {\n $faq = new faq;\n $faq->create([\n 'question' => 'What are the requirements to be a member of the 1st RRF',\n 'answer' => '<h5>Membership Criteria</h5>\n <ul>\n <li>\n Members must own a legal copy of ARMA 3 and expansions.\n </li>\n <li>\n Members must have a clean Steam VAC and BattlEye Record\n </li>\n <li>Members must be over the age of 18.</li>\n <li>Members will be required to be citizens of a NATO member country to partake.</li>\n <li>Members will need to be able to commit to a weekly operations and training schedule.</li>\n <li>Members will need speak english in order to properly communicate with the unit.</li>\n </ul>',\n 'order'=>1,\n 'published'=> true\n ]);\n $faq->create([\n 'question' => 'Why am I required to login with Steam?',\n 'answer' => '1st Rapid Response Force systems use Steam Open ID authentication for login. For more information <a href=\"http://steamcommunity.com/dev\">click here.</a>',\n 'order'=>2,\n 'published'=> true\n ]);\n $faq->create([\n 'question' => 'How do I download the modpack?',\n 'answer' => '<p>You can download the mods using our official launcher Infil, <a href=\"/modpack\">Modpack Instructions</a></p>',\n 'order'=>34,\n 'published'=> true\n ]);\n }", "title": "" }, { "docid": "5baf86e02c1137c704302d4cbe5e8e7e", "score": "0.631697", "text": "function printFaqs ($faqs) {\r\n\r\n foreach ($faqs as $faq) {\r\n echo $faq[\"question\"]\r\n . $faq[\"answer\"];\r\n }\r\n\r\n }", "title": "" }, { "docid": "1604162f2a413791f028b35132f54f18", "score": "0.62741864", "text": "public function index() {\n\t\t$contents = FAQModel::getFAQ();\n\t\t$modified = FAQModel::getLastUpdated();\n\n\t\t$this->addCSSFiles('faq.css');\n\t\treturn $this->renderPage(\n\t\t\tarray(\n\t\t\t\t'title' => 'F.A.Q.',\n\t\t\t\t'content_title' => 'FAQ :: Frequently Asked Questions',\n\t\t\t\t'contents' => $contents,\n\t\t\t\t'modified' => $modified,\n\t\t\t),\n\t\t\t$this->_template\n\t\t);\n\t}", "title": "" }, { "docid": "5c485e39fae4bcec490e5039e8b16bb6", "score": "0.61691386", "text": "public function get_faq($atts)\n {\n $args = shortcode_atts(array(\n 'id' => '',\n 'excerpt' => 'true',\n 'content' => 'false',\n 'link' => 'true',\n ), $atts);\n\n $content = $args['content'];\n $excerpt = $args['excerpt'];\n $link = $args['link'];\n $id = $args['id'];\n\n if (empty($id)) {\n return __('No FAQ ID set.', 'kong-helpdesk');\n }\n\n $faq = get_post($id);\n\n if(!isset($faq->post_content)) {\n return __('No FAQ found.', 'kong-helpdesk');\n }\n\n $content = $content == 'true' ? $content = $faq->post_content : $content = '';\n $excerpt = $excerpt == 'true' ? $excerpt = $this->get_excerpt($faq->post_content) : $excerpt = '';\n $link = $link == 'true' ? $link = get_permalink($faq->ID) : $link = '';\n\n $loggedInOnlyFAQs = $this->get_option('FAQLoggedInOnly');\n $loggedInHideInKnowledgeBase = $this->get_option('FAQLoggedInHideInKnowledgeBase');\n if($loggedInHideInKnowledgeBase == \"1\" && !is_user_logged_in()){\n return;\n }\n\n if(is_array($loggedInOnlyFAQs) && in_array($faq->ID, $loggedInOnlyFAQs) && !is_user_logged_in()) {\n return;\n }\n\n ob_start();\n echo '\n <div class=\"kong-helpdesk-faq\">\n <div class=\"kong-helpdesk-row\">\n <div class=\"kong-helpdesk-col-sm-12\">\n <h3 class=\"kong-helpdesk-faq-title\">' . $faq->post_title . '</h3>\n <hr class=\"kong-helpdesk-faq-divider\">';\n if(!empty($excerpt)) {\n echo '<div class=\"kong-helpdesk-faq-excerpt\">' . $excerpt . '</div>';\n }\n if(!empty($content)) {\n echo '<div class=\"kong-helpdesk-faq-content\">' . $content . '</div>';\n }\n echo '<div class=\"kong-helpdesk-faq-link\"><a href=\"' . $link . '\">>' . __('View Article', 'kong-helpdesk') . '</a></div>\n </div>\n </div>\n </div>';\n $output_string = ob_get_contents();\n ob_end_clean();\n return $output_string;\n }", "title": "" }, { "docid": "76ba8097a966f2150b016223e110f994", "score": "0.6160506", "text": "public function faq()\n\t{\n\t\t//$str .= \" </div>\";\n\n\t\t$str .= '<div><strong>What does this extension do?</strong></dev>';\n\t\t$str .= \"<div>This extension gives your customers the option to pick up their FedEx packages at a FedEx retail location. There are 2,400 FedEx locations across the \n\t\tU.S. to choose from, and the plug-in is only available for FedEx Express&reg; and FedEx Ground&reg; services and Magento Community edition.</div></br>\";\n\t\t\n\t\t$str .= '<div><strong>What do I do after I install the extension?</strong></dev>';\n\t\t$str .= \"<div>From the Webgility tab in your Magento Admin Panel, select Hold at FedEx Location. If you don't have \n\t\ta Webgility Account or FedEx Account, you can register within the extension. Sign in to your FedEx and Webgility Accounts, and enable the plug-in.</div></br>\";\n\t\t\n\t\t$str .= '<div><strong>What FedEx services are supported with Hold at FedEx Location?</strong></dev>';\n\t\t$str .= \"<div>FedEx Express&reg; and FedEx Ground&reg;.</div></br>\";\n\t\t\n\t\t$str .= '<div><strong>Are there any costs for me or my customer?</strong></dev>';\n\t\t$str .= \"<div>The extension is free! There are no costs above your regular FedEx rates, and no surcharges for the customer.</div></br>\";\n\t\t\n\t\t$str .= '<div><strong>How do customers select Hold at FedEx Location?</strong></dev>';\n\t\t$str .= \"<div>Upon checkout, the customer selects \\\"Ship to different address,\\\" and then chooses \\\"Hold at FedEx Location.\\\" The customer enters their zip code and selects from the list of FedEx retail locations. They proceed with checkout as usual.\n\t\t.</div></br>\";\n\t\t\n\t\t$str .= '<div><strong>What happens if a customer chooses Hold at FedEx location incorrectly?</strong></dev>';\n\t\t$str .= \"<div>If the order is not processed yet, the customer needs to contact the online store to request a manual change in shipping address.</div></br>\";\n\t\t\n\t\t$str .= '<div><strong>Does this extension work for international orders?</strong></dev>';\n\t\t$str .= \"<div>No. Hold as FedEx Location is only available within the U.S.</div></br>\";\n\t\t\n\t\t$str .= '<div><strong>What will happen if I upgrade Magento?</strong></dev>';\n\t\t$str .= \"<div>The extension is compatible with Magento Community editions, v1.7 and up.</div></br>\";\n\t\t\n\t\t$str .= '<div><strong>I run several Magento stores. Do I need several copies of the extension?</strong></dev>';\n\t\t$str .= \"<div>You only need one extension. You can toggle the extension \\\"on\\\" or \\\"off\\\" for individual stores within your Admin panel.</div></br>\";\n\t\t\n\t\t$str .= '<div><strong>Do your extensions work with custom themes?</strong></dev>';\n\t\t$str .= \"<div>Generally, our extensions are compatible with most custom themes if they were installed according to the instructions from the installation guide. However, some problems may occur for a number of third-party themes.\n\t\t</div></br>\";\n\t\t\n\t\t$str .= '<div><strong>Who do I contact if I have questions or feedback?</strong></dev>';\n\t\t$str .= \"<div>Email holdatfedex@webgility.com</br>\n\t\t</br>Thank you for installing the Hold at FedEx Location extension by Webgility! Learn more about our other Magento-compatible products at\n\t\t <a target=\\\"_blank\\\" href=\\\"http://www.webgility.com/carts/magento.php\\\">webgility.com/magento</a></div>\";\n\t\t\n\t\t\n\t\treturn $str;\t\t\n\t\n\t}", "title": "" }, { "docid": "3a7a410064686749b27edb7407d05d0f", "score": "0.6148302", "text": "public function faq()\n {\n return view('search.faq');\n }", "title": "" }, { "docid": "6dae5e9b1477d7a13a407c8d5dd6ea93", "score": "0.6137481", "text": "function askquestion(){\n\t\t$data['heading']='Ask Question';\n\t\t$this->maHeader();\n\t\t$this->maLeft();\n\t\t$this-> load-> view('askquestion',$data);\n\t\t $this->maFooter();\n\t}", "title": "" }, { "docid": "62e57a27f9251032d72d2796c3d10b89", "score": "0.6127668", "text": "function setTitleAndDescription()\n\t{\n\t\tparent::setTitleAndDescription();\n\t\tif ($_GET[\"q_id\"] > 0)\n\t\t{\n\t\t\tinclude_once \"./Modules/TestQuestionPool/classes/class.assQuestionGUI.php\";\n\t\t\t$q_gui = assQuestionGUI::_getQuestionGUI(\"\", $_GET[\"q_id\"]);\n\t\t\tif($q_gui->object instanceof assQuestion)\n\t\t\t{\n\t\t\t\t$q_gui->object->setObjId($this->object->getId());\n\t\t\t\t$title = $q_gui->object->getTitle();\n\t\t\t\tif (strcmp($this->ctrl->getCmd(), \"assessment\") == 0)\n\t\t\t\t{\n\t\t\t\t\t$title .= \" - \" . $this->lng->txt(\"statistics\");\n\t\t\t\t}\n\t\t\t\tif(!$title)\n\t\t\t\t{\n\t\t\t\t\t$title = $this->lng->txt('new').': '.assQuestion::_getQuestionTypeName($q_gui->object->getQuestionType());\n\t\t\t\t}\n\t\t\t\t$this->tpl->setTitle($title);\n\t\t\t\t$this->tpl->setDescription($q_gui->object->getComment());\n\t\t\t\t$this->tpl->setTitleIcon(ilUtil::getImagePath(\"icon_\".$this->object->getType().\"_b.png\"), $this->lng->txt(\"obj_qpl\"));\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// Workaround for context issues: If no object was found, redirect without q_id parameter\n\t\t\t\t$this->ctrl->setParameter($this, 'q_id', '');\n\t\t\t\t$this->ctrl->redirect($this);\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->tpl->setTitle($this->object->getTitle());\n\t\t\t$this->tpl->setDescription($this->object->getLongDescription());\n\t\t\t$this->tpl->setTitleIcon(ilUtil::getImagePath(\"icon_\".$this->object->getType().\"_b.png\"), $this->lng->txt(\"obj_qpl\"));\n\t\t}\n\t}", "title": "" }, { "docid": "4dd0696e75101050126a386d3306ea50", "score": "0.6098452", "text": "public function update($FAQ) {\n\t\t\n\t}", "title": "" }, { "docid": "15ddbbf9df0ada2c1bddafe11021e147", "score": "0.609537", "text": "function printFaqGet ($faqs, $faqGet) {\r\n\r\n $faqGet = $_GET[\"faq\"];\r\n\r\n echo $faqs[$_GET[\"faq\"]][\"question\"]\r\n . $faqs[$_GET[\"faq\"]][\"answer\"];\r\n\r\n\r\n echo \"Hai selezionato \";\r\n // funzione che stampa quante faqs ci sono\r\n printFaqsCount ($faqGet);\r\n echo \" domanda, con relativa risposta. <br>\";\r\n\r\n }", "title": "" }, { "docid": "87669794a8514636eb5937cb04a8922c", "score": "0.6082414", "text": "function getQuestion();", "title": "" }, { "docid": "a1175040f8e074f25adf11cf3d369ca5", "score": "0.60814214", "text": "public function getConvertFAQUrl() {\r\n\t\treturn \"index.php?module=\".$this->getModuleName().\"&action=ConvertFAQ&record=\".$this->getId();\r\n\t}", "title": "" }, { "docid": "abbe525e85510ed1ab97ed95e977c8dc", "score": "0.60291165", "text": "public function verFAQ(){\n return view('frontend.paginas.faq');\n }", "title": "" }, { "docid": "348ad9065112e99b7d1c924b1dd2ebab", "score": "0.6019947", "text": "function ct_faq(){\r\n\treturn FelisFaq::getInstance();\r\n}", "title": "" }, { "docid": "4670ac5fda449f99bc698a2b758a6caa", "score": "0.5991579", "text": "public function modificarFaq(Faq $faq){\n }", "title": "" }, { "docid": "40ff155a949604298de81bf3e211f39f", "score": "0.59741086", "text": "public function run()\n {\n $FAQ = new FAQ;\n\n $FAQ->question = \"How to bid?\";\n $FAQ->answer = \"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin ac neque ex. Nunc lobortis id diam eu vulputate. Pellentesque aliquet, massa sit amet laoreet egestas, orci metus suscipit nisi, eu ultricies odio dui et massa. Phasellus sed viverra eros. Phasellus quis euismod eros. Praesent risus ante, pellentesque eget nulla sit amet, volutpat imperdiet magna. Phasellus efficitur suscipit tincidunt. Vestibulum mollis egestas libero ut efficitur. Nulla sodales pretium massa. Donec pretium sem vitae lectus pretium fermentum. Nullam ut ante ex. Interdum et malesuada fames ac ante ipsum primis in faucibus.\";\n\n $FAQ->save();\n\n $FAQ = new FAQ;\n\n $FAQ->question = \"How to sell?\";\n $FAQ->answer = \"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin ac neque ex. Nunc lobortis id diam eu vulputate. Pellentesque aliquet, massa sit amet laoreet egestas, orci metus suscipit nisi, eu ultricies odio dui et massa. Phasellus sed viverra eros. Phasellus quis euismod eros. Praesent risus ante, pellentesque eget nulla sit amet, volutpat imperdiet magna. Phasellus efficitur suscipit tincidunt. Vestibulum mollis egestas libero ut efficitur. Nulla sodales pretium massa. Donec pretium sem vitae lectus pretium fermentum. Nullam ut ante ex. Interdum et malesuada fames ac ante ipsum primis in faucibus.\";\n\n $FAQ->save();\n\n $FAQ = new FAQ;\n\n $FAQ->question = \"How to buy?\";\n $FAQ->answer = \"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin ac neque ex. Nunc lobortis id diam eu vulputate. Pellentesque aliquet, massa sit amet laoreet egestas, orci metus suscipit nisi, eu ultricies odio dui et massa. Phasellus sed viverra eros. Phasellus quis euismod eros. Praesent risus ante, pellentesque eget nulla sit amet, volutpat imperdiet magna. Phasellus efficitur suscipit tincidunt. Vestibulum mollis egestas libero ut efficitur. Nulla sodales pretium massa. Donec pretium sem vitae lectus pretium fermentum. Nullam ut ante ex. Interdum et malesuada fames ac ante ipsum primis in faucibus.\";\n\n $FAQ->save();\n\n $FAQ = new FAQ;\n\n $FAQ->question = \"How to Register?\";\n $FAQ->answer = \"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin ac neque ex. Nunc lobortis id diam eu vulputate. Pellentesque aliquet, massa sit amet laoreet egestas, orci metus suscipit nisi, eu ultricies odio dui et massa. Phasellus sed viverra eros. Phasellus quis euismod eros. Praesent risus ante, pellentesque eget nulla sit amet, volutpat imperdiet magna. Phasellus efficitur suscipit tincidunt. Vestibulum mollis egestas libero ut efficitur. Nulla sodales pretium massa. Donec pretium sem vitae lectus pretium fermentum. Nullam ut ante ex. Interdum et malesuada fames ac ante ipsum primis in faucibus.\";\n\n $FAQ->save();\n\n $FAQ = new FAQ;\n\n $FAQ->question = \"How to ask a question?\";\n $FAQ->answer = \"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin ac neque ex. Nunc lobortis id diam eu vulputate. Pellentesque aliquet, massa sit amet laoreet egestas, orci metus suscipit nisi, eu ultricies odio dui et massa. Phasellus sed viverra eros. Phasellus quis euismod eros. Praesent risus ante, pellentesque eget nulla sit amet, volutpat imperdiet magna. Phasellus efficitur suscipit tincidunt. Vestibulum mollis egestas libero ut efficitur. Nulla sodales pretium massa. Donec pretium sem vitae lectus pretium fermentum. Nullam ut ante ex. Interdum et malesuada fames ac ante ipsum primis in faucibus.\";\n\n $FAQ->save();\n\n $FAQ = new FAQ;\n\n $FAQ->question = \"What is a watchlist?\";\n $FAQ->answer = \"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin ac neque ex. Nunc lobortis id diam eu vulputate. Pellentesque aliquet, massa sit amet laoreet egestas, orci metus suscipit nisi, eu ultricies odio dui et massa. Phasellus sed viverra eros. Phasellus quis euismod eros. Praesent risus ante, pellentesque eget nulla sit amet, volutpat imperdiet magna. Phasellus efficitur suscipit tincidunt. Vestibulum mollis egestas libero ut efficitur. Nulla sodales pretium massa. Donec pretium sem vitae lectus pretium fermentum. Nullam ut ante ex. Interdum et malesuada fames ac ante ipsum primis in faucibus.\";\n\n $FAQ->save();\n\n $FAQ = new FAQ;\n\n $FAQ->question = \"How to use a watchlist?\";\n $FAQ->answer = \"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin ac neque ex. Nunc lobortis id diam eu vulputate. Pellentesque aliquet, massa sit amet laoreet egestas, orci metus suscipit nisi, eu ultricies odio dui et massa. Phasellus sed viverra eros. Phasellus quis euismod eros. Praesent risus ante, pellentesque eget nulla sit amet, volutpat imperdiet magna. Phasellus efficitur suscipit tincidunt. Vestibulum mollis egestas libero ut efficitur. Nulla sodales pretium massa. Donec pretium sem vitae lectus pretium fermentum. Nullam ut ante ex. Interdum et malesuada fames ac ante ipsum primis in faucibus.\";\n\n $FAQ->save();\n }", "title": "" }, { "docid": "e9d8c32d71f00da1ce64b256753c1ec4", "score": "0.5956417", "text": "function event_faq_new()\n\t{\n\t\tglobal $question, $name, $email;\n\n\t\tif (!empty($question))\n\t\t{\n\t\t\tempty($name) && $name = '';\n\t\t\tempty($email) && $email = '';\n\n\t\t\t$this->db->query(\"INSERT INTO $this->table (question, name, email, posted, visible) VALUES ('$question', '$name', '$email', NOW(), 0)\");\n\n\t\t\t$this->tpl->set_file('mail', 'faq/tpl/mail_new_faq.txt');\n\t\t\t$this->tpl->set_var('name', $name);\n\t\t\t$this->tpl->set_var('email', $email);\n\t\t\t$this->tpl->set_var('question', $question);\n\n mail(\"artscene-admin-talk@googlegroups.com\", 'naujas klausimas svetainėje', $this->tpl->process('temp', 'mail'), \"MIME-Version: 1.0\\nContent-Type: text/plain; charset=Windows-1257\\nContent-Transfer-Encoding: 8bit\\nFrom: art.scene automatas <pukomuko@gmail.com>\\n\");\n\t\t}\n\n\t\treturn true;\n\t}", "title": "" }, { "docid": "1c532d45fd6cec5dbe07baded14dc22a", "score": "0.59491307", "text": "function questionpage_builder ( $qpObject ) {\n\t// first display label text and any help text\n\techo <<<EOT\n\t\n\t\t<p class=\"questiontext\">$qpObject->labelText<span class=\"help\">?</span><br />\n\t\t<span class=\"helptext\">$qpObject->helpText</span></p>\n\t\t\nEOT;\n\n\t// for each group of questions, call fieldset_builder\n\tforeach ( $qpObject->childElements as $fsObject ) {\n\t\tfieldset_builder ( $fsObject, $qpObject->idName );\n\t\t\n\t}\n}", "title": "" }, { "docid": "0b100890af8d95bc06a444958148713b", "score": "0.5948409", "text": "public function init()\n {\n global $kong_helpdesk_options;\n $this->options = $kong_helpdesk_options;\n\n if (!$this->get_option('enableFAQ')) {\n return false;\n }\n\n $this->register_faq_post_type();\n $this->register_faq_taxonomy();\n $this->add_custom_meta_fields();\n\n add_action('post_submitbox_start', array( $this, 'show_copy_button' ));\n add_action('admin_action_copy_ticket_to_faq', array( $this, 'copy_ticket_to_faq' ));\n\n add_shortcode('knowledge_base', array( $this, 'get_knowledge_base' ));\n add_shortcode('faq', array( $this, 'get_faq' ));\n add_shortcode('faqs', array( $this, 'get_faqs' ));\n add_shortcode('faq_search', array( $this, 'get_shortcode_search' ));\n add_filter( 'get_user_option_screen_layout_faq',array($this,'make_faq_one_column'),10, 3 );\n \n }", "title": "" }, { "docid": "9dbbb58b176585d075e0d7ffb795a598", "score": "0.59415686", "text": "function question_url($question) {\n\t$title = $question->title;\n\t$title = elgg_get_friendly_title($title);\n\treturn elgg_get_site_url() . \"answers/view/\" . $question->getGUID() . \"/\" . $title;\n}", "title": "" }, { "docid": "d12706987c8e188c2ed7026d78907f9b", "score": "0.5914955", "text": "function parse_faq() {\n $faq = array();\n $file = W3TC_INC_DIR . '/options/faq.xml';\n\n $xml = @file_get_contents($file);\n\n if ($xml) {\n if (function_exists('xml_parser_create')) {\n $parser = @xml_parser_create('UTF-8');\n\n xml_parser_set_option($parser, XML_OPTION_TARGET_ENCODING, 'UTF-8');\n xml_parser_set_option($parser, XML_OPTION_CASE_FOLDING, 0);\n xml_parser_set_option($parser, XML_OPTION_SKIP_WHITE, 1);\n $values = null;\n\n $result = xml_parse_into_struct($parser, $xml, $values);\n xml_parser_free($parser);\n\n if ($result) {\n $index = 0;\n $current_section = '';\n $current_entry = array();\n\n foreach ($values as $value) {\n switch ($value['type']) {\n case 'open':\n if ($value['tag'] === 'section') {\n $current_section = $value['attributes']['name'];\n }\n break;\n\n case 'complete':\n switch ($value['tag']) {\n case 'question':\n $current_entry['question'] = $value['value'];\n break;\n\n case 'answer':\n $current_entry['answer'] = $value['value'];\n break;\n }\n break;\n\n case 'close':\n if ($value['tag'] == 'entry') {\n $current_entry['index'] = ++$index;\n $faq[$current_section][] = $current_entry;\n }\n break;\n }\n }\n }\n }\n }\n\n return $faq;\n }", "title": "" }, { "docid": "40a34b0e094a7d8dd70164b1a50a0d3c", "score": "0.5893887", "text": "public function getFAQ()\n {\n $user = null;\n\t\t$cart = [];\n\t\tif(Auth::check())\n\t\t{\n\t\t\t$user = Auth::user();\n\t\t}\n\t $signals = $this->helpers->signals;\n\t\t\n \treturn view('faq',compact(['user','signals']));\n }", "title": "" }, { "docid": "16420fdc1e7ee9064501187af2113dd2", "score": "0.5888699", "text": "public function faqs() {\n\t\t\t$faqs=Faq::all();\n\t\t\t\treturn view('faq', compact('faqs'));\n\t\t}", "title": "" }, { "docid": "d9d308fc77abd8778a1bb3542730946c", "score": "0.587173", "text": "function faq_therapist_head_erehab(){\n\t\t$this->output = $this->build_template($this->get_template(\"faq_therapist_head_erehab\"));\n\t}", "title": "" }, { "docid": "4d14b747ba2ab7341d47f4eb7ce11db0", "score": "0.58683854", "text": "public function get_knowledge_base($atts)\n {\n $args = shortcode_atts(array(\n 'columns' => $this->get_option('FAQColumns'),\n 'max_faqs' => 5,\n 'orderby' => 'order',\n 'order' => 'ASC',\n ), $atts);\n\n $columns = $args['columns'];\n $max_faqs = $args['max_faqs'];\n $orderby = $args['orderby'];\n $order = $args['order'];\n $topicsLoggedInOnly = is_array($this->get_option('FAQTopicsLoggedInOnly')) ? $this->get_option('FAQTopicsLoggedInOnly') : array();\n\n $topics = get_terms(array(\n 'taxonomy' => 'faq_topics',\n 'hide_empty' => false,\n 'parent' => 0,\n 'orderby' => $orderby,\n 'order' => $order,\n ));\n\n if (empty($topics)) {\n return __('<h2>No Topics created so far!</h2>', 'kong-helpdesk');\n }\n\n foreach ($topics as $key => $topic) {\n if(in_array($topic->term_id, $topicsLoggedInOnly) && !is_user_logged_in()) {\n unset($topics[$key]);\n }\n }\n\n $masonry = $this->get_option('FAQMasonry');\n if(!$masonry) {\n $topics = array_chunk($topics, $columns);\n }\n\n $columns = floor( 12 / intval($columns) );\n $max_faqs = intval($max_faqs);\n\n $sidebarClass = '';\n $contentClass = '';\n if($this->get_option('supportSidebarPosition') == \"left\") {\n $sidebarClass = 'kong-helpdesk-pull-left';\n $contentClass = 'kong-helpdesk-pull-right';\n } elseif($this->get_option('supportSidebarPosition') == \"right\") {\n $sidebarClass = 'kong-helpdesk-pull-right';\n $contentClass = 'kong-helpdesk-pull-left';\n }\n \n ob_start();\n ?>\n <div class=\"kong-helpdesk kong-helpdesk-faq\">\n <div class=\"kong-helpdesk-row\">\n <?php\n $checks = array('none', 'only_ticket');\n if(in_array($this->get_option('supportSidebarDisplay'), $checks)) {\n echo '<div class=\"kong-helpdesk-col-sm-12\">';\n } else {\n echo '<div class=\"kong-helpdesk-col-sm-8 ' . $contentClass . '\">';\n }\n\n if ($this->get_option('FAQShowSearch')) {\n $this->get_search();\n }\n foreach ($topics as $topic) {\n\n if(is_array($topic)) {\n echo '<div class=\"kong-helpdesk-row\">';\n foreach ($topic as $_topic) {\n $this->get_faq_column($_topic, $columns, $max_faqs);\n }\n echo '</div>';\n } else {\n $this->get_faq_column($topic, $columns, $max_faqs);\n }\n }\n ?>\n \n </div>\n <?php\n $checks = array('both', 'only_faq');\n if(in_array($this->get_option('supportSidebarDisplay'), $checks)) {\n ?>\n <div class=\"kong-helpdesk-col-sm-4 kong-helpdesk-sidebar <?php echo $sidebarClass ?>\">\n <?php dynamic_sidebar('helpdesk-sidebar'); ?>\n </div>\n <?php\n }\n ?>\n </div>\n </div>\n <?php\n $output_string = ob_get_contents();\n ob_end_clean();\n return $output_string;\n }", "title": "" }, { "docid": "d15169855c45c82da53207b59fc1dcd3", "score": "0.5835773", "text": "abstract public function getFunctionTermsQuestions();", "title": "" }, { "docid": "cfc4ef57f6b6c41e9f1e5e7057acbf13", "score": "0.5821232", "text": "function faq_add_query( $p_project_id, $p_poster_id, $p_question, $p_answere ,$p_view_level= 10) {\n\t\tglobal $g_mantis_faq_table;\n\n\t\t# \" character poses problem when editting so let's just convert them\n\t\t$p_question\t= db_prepare_string( $p_question );\n\t\t$p_answere\t= db_prepare_string( $p_answere );\n\n\t\t# Add item\n\t\t$query = \"INSERT\n\t\t\t\tINTO $g_mantis_faq_table\n\t \t\t( id, project_id, poster_id, date_posted, last_modified, question, answere, view_access )\n\t\t\t\tVALUES\n\t\t\t\t( null, '$p_project_id', '$p_poster_id', NOW(), NOW(), '$p_question', '$p_answere', '$p_view_level' )\";\n\t return db_query_bound( $query );\n\t}", "title": "" }, { "docid": "068dd0ec9ac836b0c39fcc4d2603e2d1", "score": "0.58196276", "text": "protected function landing_ask_question(){\r\n\t\t\r\n\t\t/* Load template */\r\n\t\tinclude(BLUPATH_TEMPLATES . '/questions/landing/ask_question.php');\r\n\t\t\r\n\t}", "title": "" }, { "docid": "5057c2b806b6de81efea5cb66d7912a1", "score": "0.57988316", "text": "public function questionView($qq_id) {\n $quiz = new Quiz();\n $question = $quiz->get_question($qq_id);\n $this->layout->content = View::make('quiz::question-add')->with('question',$question);\n }", "title": "" }, { "docid": "3899e844c5314dfc9b6806f021b2f98b", "score": "0.5792441", "text": "public function action_quickhelp()\n\t{\n\t\tglobal $txt, $helptxt, $context;\n\n\t\tif (!isset($this->_req->query->help) || !is_string($this->_req->query->help))\n\t\t{\n\t\t\tthrow new Exception('no_access', false);\n\t\t}\n\n\t\tif (!isset($helptxt))\n\t\t{\n\t\t\t$helptxt = array();\n\t\t}\n\n\t\t$help_str = Util::htmlspecialchars($this->_req->query->help);\n\n\t\t// Load the admin help language file and template.\n\t\tTxt::load('Help');\n\n\t\t// Load permission specific help\n\t\tif (substr($help_str, 0, 14) === 'permissionhelp')\n\t\t{\n\t\t\tTxt::load('ManagePermissions');\n\t\t}\n\n\t\t// Load our template\n\t\ttheme()->getTemplates()->load('Help');\n\n\t\t// Allow addons to load their own language file here.\n\t\tcall_integration_hook('integrate_quickhelp');\n\n\t\t// Set the page title to something relevant.\n\t\t$context['page_title'] = $context['forum_name'] . ' - ' . $txt['help'];\n\n\t\t// Only show the 'popup' sub-template, no layers.\n\t\ttheme()->getLayers()->removeAll();\n\t\t$context['sub_template'] = 'popup';\n\n\t\t$helps = explode('+', $help_str);\n\t\t$context['help_text'] = '';\n\n\t\t// Find what to display: the string will be in $helptxt['help'] or in $txt['help]\n\t\tforeach ($helps as $help)\n\t\t{\n\t\t\tif (isset($helptxt[$help]))\n\t\t\t{\n\t\t\t\t$context['help_text'] .= $helptxt[$help];\n\t\t\t}\n\t\t\telseif (isset($txt[$help]))\n\t\t\t{\n\t\t\t\t$context['help_text'] .= $txt[$help];\n\t\t\t}\n\t\t\telse\n\t\t\t\t// nothing :(\n\t\t\t{\n\t\t\t\t$context['help_text'] .= $help;\n\t\t\t}\n\t\t}\n\n\t\t// Link to the forum URL, and include session id.\n\t\tif (preg_match('~%(\\d+\\$)?s\\?~', $context['help_text'], $match))\n\t\t{\n\t\t\t$context['help_text'] = sprintf($context['help_text'], getUrl('boardindex', []), $context['session_id'], $context['session_var']);\n\t\t}\n\t}", "title": "" }, { "docid": "5d80720bd8bb09a4ddb893271e9d6258", "score": "0.57706785", "text": "public function qaAction()\n {\n\t\t//GET NAVIGATION\n \t$this->view->navigation = Engine_Api::_()->getApi('menus', 'core')\n \t ->getNavigation('siteqa_admin_main', array(), 'siteqa_admin_main_qa');\n }", "title": "" }, { "docid": "c6f418a02a1fc39eee0633124f41ee0d", "score": "0.576817", "text": "public function faqsView () {\n $page = Page::where('slug', 'preguntas-frecuentes')->first();\n $questions = Question::where(['is_faq' => true])->get();\n $socialLinks = LinkController::getVisibleLinks();\n $links = $this->getMenuLinks();\n\n return view('frontend.faqs', compact('page', 'questions', 'links', 'socialLinks'));\n }", "title": "" }, { "docid": "687e10ffad1e35112ca77e897f30c4bf", "score": "0.5767405", "text": "public function getFAQ()\n {\n\t\t $user = null;\n\t\t\n\t\t$cart = [];\n\t\tif(Auth::check())\n\t\t{\n\t\t\t$user = Auth::user();\n\t\t\t$cart = $this->helpers->getCart($user);\n\t\t}\n\t\t$layoutAd = $this->helpers->getAds();\n return view('faq',compact(['layoutAd','user','cart']));\n }", "title": "" }, { "docid": "fd92e9d935d3f964622f93b3ec52ea73", "score": "0.57604367", "text": "function ipal_print_singlequestion($question, $returnurl, $quiz) {\r\n echo '<div class=\"singlequestion\">';\r\n echo ipal_question_edit_button($quiz->cmid, $question, $returnurl,\r\n ipal_question_tostring($question) . ' ');\r\n echo '<span class=\"questiontype\">';\r\n print_question_icon($question);\r\n echo ' ' . question_bank::get_qtype_name($question->qtype) . '</span>';\r\n echo '<span class=\"questionpreview\">' .\r\n ipal_question_preview_button($quiz, $question, true) . '</span>';\r\n echo \"</div>\\n\";\r\n}", "title": "" }, { "docid": "d52ed570dca359f6a973cf1741d311bc", "score": "0.57533115", "text": "function faq_function( $atts = array(), $content = null ) {\n extract(shortcode_atts(array(\n 'question' => 'Why am I here?'\n ), $atts));\n \n $slug = slugify($question);\n\n return '\n <div class=\"card faq--question\">\n <div class=\"card-header\" id=\"heading'. $slug .'\">\n <h2 class=\"mb-0\">\n <h5 class=\"collapsed\" data-toggle=\"collapse\" data-target=\"#' . $slug . '\" aria-expanded=\"true\" aria-controls=\"' . $slug . '\">\n <ion-icon class=\"minus\" name=\"remove\"></ion-icon><ion-icon class=\"plus\" name=\"add\"></ion-icon>\n ' . $question . '\n </h5>\n </h2>\n </div>\n\n <div id=\"' . $slug . '\" class=\"collapse\" aria-labelledby=\"heading'. $slug .'\" data-parent=\"#accordionExample\">\n <div class=\"card-body\">\n ' . $content . '\n </div>\n </div>\n </div>';\n \n \n \n //return '<a href=\"'. $link .'\" target=\"blank\" class=\"doti-button\">' . $content . '</a>';\n}", "title": "" }, { "docid": "f31528d2a282c921d8db20d1f6792779", "score": "0.5750873", "text": "function getLinks($withname = false) {\n global $CFG_GLPI;\n\n $ret = '';\n\n if ($withname) {\n $ret .= $this->fields[\"name\"];\n $ret .= \"&nbsp;&nbsp;\";\n }\n\n if ($this->isField('knowbaseitemcategories_id')\n && $this->fields['knowbaseitemcategories_id']) {\n $title = __s('FAQ');\n\n if (Session::getCurrentInterface() == 'central') {\n $title = __s('Knowledge base');\n }\n\n $rand = mt_rand();\n $kbitem = new KnowbaseItem;\n $found_kbitem = $kbitem->find([\n KnowbaseItem::getTable() . '.id' => KnowbaseItem::getForCategory($this->fields['knowbaseitemcategories_id'])\n ]);\n\n $kbitem->getFromDB(reset($found_kbitem)['id']);\n if (count($found_kbitem)) {\n $ret.= \"<div class='faqadd_block'>\";\n $ret.= \"<label for='display_faq_chkbox$rand'>\";\n $ret.= \"<img src='\".$CFG_GLPI[\"root_doc\"].\"/pics/faqadd.png' class='middle pointer'\n alt=\\\"$title\\\" title=\\\"$title\\\">\";\n $ret.= \"</label>\";\n $ret.= \"<input type='checkbox' class='display_faq_chkbox' id='display_faq_chkbox$rand'>\";\n $ret.= \"<div class='faqadd_entries'>\";\n if (count($found_kbitem) == 1) {\n $ret.= \"<div class='faqadd_block_content' id='faqadd_block_content$rand'>\";\n $ret.= $kbitem->showFull(['display' => false]);\n $ret.= \"</div>\"; // .faqadd_block_content\n } else {\n $ret.= Html::scriptBlock(\"\n var getKnowbaseItemAnswer$rand = function() {\n var knowbaseitems_id = $('#dropdown_knowbaseitems_id$rand').val();\n $('#faqadd_block_content$rand').load(\n '\".$CFG_GLPI['root_doc'].\"/ajax/getKnowbaseItemAnswer.php',\n {\n 'knowbaseitems_id': knowbaseitems_id\n }\n );\n };\n \");\n $ret.= \"<label for='dropdown_knowbaseitems_id$rand'>\".\n KnowbaseItem::getTypeName().\"</label>&nbsp;\";\n $ret.= KnowbaseItem::dropdown([\n 'value' => reset($found_kbitem)['id'],\n 'display' => false,\n 'rand' => $rand,\n 'condition' => [\n KnowbaseItem::getTable() . '.id' => KnowbaseItem::getForCategory($this->fields['knowbaseitemcategories_id'])\n ],\n 'on_change' => \"getKnowbaseItemAnswer$rand()\"\n ]);\n $ret.= \"<div class='faqadd_block_content' id='faqadd_block_content$rand'>\";\n $ret.= $kbitem->showFull(['display' => false]);\n $ret.= \"</div>\"; // .faqadd_block_content\n }\n $ret.= \"</div>\"; // .faqadd_entries\n $ret.= \"</div>\"; // .faqadd_block\n }\n }\n return $ret;\n }", "title": "" }, { "docid": "4a5070f0da7dc53d70dd2745e5ac814c", "score": "0.5744596", "text": "public function render() {\n \n\t\t$fields = $this->get_fields();\n \n if ( ! isset( $fields['faq'] ) || empty( $fields['faq'] ) ) {\n return;\n }\n \n $field = $this->get_fields( 'faq' );\n \n $heading = isset( $field['heading'] ) ? _s_format_string( $field['heading'], 'h2' ) : '';\n $faq = $field['faq'];\n \n if( empty( $faq ) ) {\n return false;\n }\n \n $rows = get_field( 'faq', $faq->ID );\n \n \n $fa = new Foundation_Accordion;\n \n foreach( $rows as $key => $row ) {\n $fa->add_item( $row['question'], $row['answer'] );\n }\n \n $accordion = $fa->get_accordion();\n \n $this->add_render_attribute( 'wrapper', 'class', 'element-faq' );\n \n return sprintf( '<div %s>%s%s</div>', $this->get_render_attribute_string( 'wrapper' ), $heading, $accordion );\n\t}", "title": "" }, { "docid": "50dde017626fad8ea6dedfe841ebe7bf", "score": "0.57428336", "text": "public function actionFaq()\r\n\t{\r\n $model =Page::model()->findByPk(9);\r\n\t\t$this->render('privacy',array('model'=>$model));\r\n\t}", "title": "" }, { "docid": "387255d7abbdeeed6f96440729dea37c", "score": "0.57421184", "text": "public function getFaqName()\n {\n return $this->scopeConfig->getValue(\n self::XML_PATH_FAQ_NAME,\n ScopeInterface::SCOPE_STORE\n );\n }", "title": "" }, { "docid": "da6453ad90f4348a1ee317ef3e714872", "score": "0.5718038", "text": "public function get_faqs($atts)\n {\n $args = shortcode_atts(array(\n 'topic' => '',\n 'content' => 'false',\n 'excerpt' => 'true',\n 'link' => 'true',\n 'max_faqs' => '-1',\n 'show_children' => 'false',\n 'show_child_categories' => 'true',\n 'columns' => $this->get_option('FAQColumns'),\n 'order' => 'ASC',\n 'orderby' => 'menu_order',\n ), $atts);\n\n $content = $args['content'];\n $excerpt = $args['excerpt'];\n $link = $args['link'];\n $topic = $args['topic'];\n $order = $args['order'];\n $orderby = $args['orderby'];\n $max_faqs = $args['max_faqs'];\n $show_children = $args['show_children'] === 'true' ? true: false;\n $show_child_categories = $args['show_child_categories'] === 'true' ? true: false;\n $columns = $args['columns'];\n $topicsLoggedInOnly = is_array($this->get_option('FAQTopicsLoggedInOnly')) ? $this->get_option('FAQTopicsLoggedInOnly') : array();\n\n $columns = floor( 12 / intval($columns) );\n $max_faqs = intval($max_faqs);\n\n $args = array(\n 'post_type' => 'faq',\n 'orderby' => $orderby,\n 'order' => $order,\n 'hierarchical' => false,\n 'posts_per_page' => $max_faqs,\n );\n\n if (!empty($topic)) {\n if (!is_numeric($topic)) {\n return __('Topic ID not an ID', 'kong-helpdesk');\n }\n $args['tax_query'] = array(\n array(\n 'taxonomy' => 'faq_topics',\n 'field' => 'id',\n 'terms' => $topic,\n 'include_children' => $show_children\n )\n );\n\n $topic_icon = get_term_meta($topic, 'kong_helpdesk_icon');\n if (isset($topic_icon) && !empty($topic_icon)) {\n $topic_icon = $topic_icon[0];\n } else {\n $topic_icon = 'fa fa-file-text-o';\n }\n }\n\n ob_start();\n\n if(in_array($topic, $topicsLoggedInOnly) && !is_user_logged_in()) {\n echo sprintf(__('Please <a href=\"%s\" title=\"Login\">login to view this topic.</a>', 'kong-helpdesk'), wp_login_url(get_permalink()));\n return;\n }\n \n\n\n echo '<div class=\"kong-helpdesk kong-helpdesk-faq\">';\n\n if ($this->get_option('FAQShowSearch')) {\n $this->get_search();\n }\n \n if($show_child_categories) {\n $children = get_term_children( $topic, 'faq_topics');\n if(!empty($children)) {\n echo '<div class=\"kong-helpdesk-row\" style=\"margin-bottom: 20px;\">';\n foreach ($children as $child) {\n if(in_array($child, $topicsLoggedInOnly) && !is_user_logged_in()) {\n continue;\n }\n $topic_child = get_term($child);\n $this->get_faq_column($topic_child, $columns, $max_faqs);\n }\n echo '</div>';\n }\n }\n\n $faqs = get_posts($args);\n\n if(empty($faqs)) {\n return '<b>' . __('No Articles found.', 'kong-helpdesk') . '</b></div>';\n }\n\n\n $FAQItemLayout = $this->get_option('FAQItemLayout');\n $FAQItemColumns = $this->get_option('FAQItemColumns');\n\n $masonry = $this->get_option('FAQItemMasonry');\n if(!$masonry) {\n $faqs = array_chunk((array) $faqs, $FAQItemColumns);\n }\n\n $FAQItemColumns = floor( 12 / intval($FAQItemColumns) );\n\n foreach ($faqs as $faq) {\n\n if(is_array($faq)) {\n echo '<div class=\"kong-helpdesk-row\">';\n\n foreach ($faq as $faq_row) {\n $this->get_single_faq_column($faq_row, $FAQItemColumns, $topic_icon, $content, $excerpt, $link);\n }\n\n echo '</div>';\n continue;\n } else {\n $this->get_single_faq_column($faq, $FAQItemColumns, $topic_icon, $content, $excerpt, $link);\n }\n }\n echo '</div>';\n\n $output_string = ob_get_contents();\n ob_end_clean();\n return $output_string;\n }", "title": "" }, { "docid": "98f9bf772ba0e2874371194fce169ff7", "score": "0.57080054", "text": "function dealership_questionaire($q_no = false)\r\n\t{\r\n\t\t$questions = array(\r\n\t\t\t\"1\" => array('ques' => 'IS THIS DEALER FRANCHISED?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"2\" => array('ques' => 'HOW LONG HAS THE DEALERSHIP OWNER BEEN IN BUSINESS?', 'boolean'=> false, 'detail' => true, 'radios' => false, \r\n\t\t\t'checkboxes' => false, 'msg' => '(must be a franchised auto dealer)'),\r\n\t\t\t\"3\" => array('ques' => 'DOES THE DEALER DO ANY MANUFACTURING OR UPFITTING OF VEHICLES?', 'boolean'=> true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"4\" => array('ques' => 'ARE CUSTOMERS ALLOWED TO TEST DRIVE VEHICLES OVERNIGHT?', 'boolean'=> true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"5\" => array('ques' => 'DOES THE SALES STAFF ACCOMPANY PROSPECTIVE CUSTOMERS ON TEST DRIVES? PERCENTAGE OF TIME?', 'boolean'=> true, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"6\" => array('ques' => 'ARE CUSTOMERS DRIVERS LICENSE VERIFIED FOR VALIDITY AND COPIED PRIOR TO TEST DRIVES?', 'boolean'=> true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"7\" => array('ques' => 'ARE THE WORKING SET OF KEYS MAINTAINED IN THE CONTROL OF THE SALESMAN DURING ALL SALES TRANSACTIONS AND TEST DRIVES?', 'boolean'=>true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"8\" => array('ques' => 'ARE MOTOR VEHICLE RECORDS AND OR DRIVERS LICENSES OBTAINED ON EMPLOYEES AND REVIEWED ON A YEARLY BASIS?', 'boolean'=> true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"9\" => array('ques' => 'DOES THE DEALER FURNISH AUTOMOBILES TO NON-EMPOYEES SUCH AS DEMOS OR CUSTOMER LOANERS?', 'boolean'=> true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"10\" => array('ques' => 'DOES THE DEALER PROVIDE DEMONSTRATORS TO EMPLOYEES? HOW MANY?', 'boolean' => true, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"11\" => array('ques' => 'IS THE DEALERSHIP EQUIPPED WITH AN ALARM SYSTEM? ', 'boolean' => true, 'detail' => false, 'radios' => array('a' => 'LOCAL', 'b' => 'CENTRAL', 'c' => 'STATION'), 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"12\" => array('ques' => 'SECURITY SYSTEM ON PREMISES?', 'boolean' => true, 'detail' => false, 'radios' => array('a'=>'24 HOURS', 'b'=>'AFTER HOURS', 'c'=>'DRIVE BY SERVICE'), 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"13\" => array('ques' => 'PERIMETER LIGHTING?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"14\" => array('ques' => 'WORKING SURVEILLANCE CAMERAS?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"15\" => array('ques' => 'MOTION SENSERS ON THE EXTERIOR OF THE DEALERSHIP?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"16\" => array('ques' => 'IS LOT FULLY ENCLOSED AFTER BUSINESS HOURS?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"17\" => array('ques' => 'ARE GATES LOCKED WHEN BUSINESS IS CLOSED?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"18\" => array('ques' => 'IS ON PREMISES SECURITY SERVICE USED? <br> a. IF SO, WHAT ARE THE HOURS?', 'boolean' => true, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"19\" => array('ques' => 'LOJACK OR BOOMERANG ANTI THEFT SYSTEMS USED? <br> OTHER:', 'boolean' => true, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"20\" => array('ques' => 'ARE LOCK BOXES USED? <br>a. IF SO ARE KEYS REMOVED FROM BOXES AT NIGHT?', 'boolean' => true, 'detail' => false, 'radios' => array('a' => 'Yes', 'b' => 'NO'), 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"21\" => array('ques' => 'WINDOW ETCHING?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"22\" => array('ques' => 'CAN THE PUBLIC ACCESS KEYS TO INVENTORIED VEHICLES?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"23\" => array('ques' => 'ARE DESIGNATED INDIVIDUALS GIVEN THE RESPONSIBILITY TO DISPENSE KEYS?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"24\" => array('ques' => 'ARE ELECTRONIC KEY MACHINE REPORTS / LOGS REVIEWED AND RECONCILED AT THE END OF EACH BUSINESS DAY?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"25\" => array('ques' => 'DESCRIBE KEY SECURITY, KEY MACHINE MODLE ETC... HOW ARE KEYS RETURNED TO CABINET? WHO IS RESPONSIBLE?', 'boolean' => false, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"26\" => array('ques' => 'HAS ANY PART OF YOUR DEALERSHIP OR STORAGE LOTS EVER BEEN FLOODED?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"27\" => array('ques' => 'IS YOUR DEALERSHIP LOCATED IN A 100 YEAR FLOOD PLAIN?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"28\" => array('ques' => 'IS THERE A FLOOD PROTECTION PLAN IN PLACE? (ATTACH)', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"29\" => array('ques' => 'ARE HAIL NETS USED? IF SO, AGE OF CONSTRUCTION OR LAST UPDATED? ', 'boolean' => true, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"30\" => array('ques' => 'IS THERE A HAIL PROTECTION PLAN IN PLACE?(ATTACH)', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"31\" => array('ques' => 'ARE ANY OF YOUR NEW / USED INVENTORY VEHICLES PARKED UNDER PROTECTIVE COVER? PERCENTAGE?', 'boolean' => true, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"32\" => array('ques' => 'PERCENTAGE OF UNITS IN PARKING GARAGE ON AVERAGE?', 'boolean' => false, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"33\" => array('ques' => 'PERCENTAGE OF UNITS IN PARKING GARAGE MAX?', 'boolean' => false, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"34\" => array('ques' => 'IS THERE A FORMALIZED LOSS PREVENTION PROGRAM THAT HAS BEEN INSTITUTED AT THE DEALERSHIP?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"35\" => array('ques' => 'ARE VEHICLE HISTORY REPORTS OBTAINED FOR ALL USED AUTOS PURCHASED OR TAKEN IN TRADE? PERCENTAGE OF TIME:', 'boolean' => true, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"36\" => array('ques' => 'ARE ALL CHECKS, DRAFTS AND FINANCIAL INSTRUMENTS VERIFIED PRIOR TO VEHICLE DELIVERY?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"37\" => array('ques' => 'IS THERE AN IDENTITY THEFT PROCEDURE IN PLACE?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"38\" => array('ques' => 'WHAT IS THE MAXIMUM VALUE OF ANY ONE VEHICLE?', 'boolean' => false, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"39\" => array('ques' => 'DOES DEALER PROVIDE SHOP LOANERS OR SHOP RENTALS? <br>a. IF SO HOW MANY VEHICLES ARE DESIGNATED FOR SHOP LOANER OR SHOP RENTAL?\r\n', 'boolean' => true, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"40\" => array('ques' => 'FOR EACH LOCATION: DESCRIBE EXTENT OF FENCE, POSTS, CHAINS, BARRICADES AND GATES AROUND PREMISES:', 'boolean' => false, 'detail' => true, 'radios' => false, 'checkboxes' => false, 'msg' => false),\r\n\t\t\t\"41\" => array('ques' => 'DOES DEALER OWN A BODY SHOP?', 'boolean' => true, 'detail' => false, 'radios' => false, 'checkboxes' => false, 'msg' => false)\r\n\t\t);\r\n\t\t\r\n\t\tif($q_no) {\r\n\t\t\treturn $questions[$q_no];\r\n\t\t}\r\n\t\treturn $questions;\r\n\t}", "title": "" }, { "docid": "bfb22301d478fccbfdac11517d6238ba", "score": "0.57023245", "text": "function asQuestion($data)\n {\n return \"<question>$data</question>\";\n }", "title": "" }, { "docid": "7c02bf88023f11abebcd3b6efffb98bc", "score": "0.5691397", "text": "public function show(Faq $faq)\n {\n return 0;\n }", "title": "" }, { "docid": "7f82b9fed5e677aef95d698416f59f00", "score": "0.56878346", "text": "function get_question_title() {\n\t\t\t\tglobal $questionDetails;\n\t\t\t\techo $questionDetails['questionName'];\t\n\t\t\t}", "title": "" }, { "docid": "946293c23a65d3cabd9dbff1bbf4ac77", "score": "0.5685892", "text": "function qnaQ()\n{\n\tglobal $themedir, $theme, $l;\n\tglobal $globals, $mysql, $theme, $done, $errors;\n\tglobal $user;\n\tglobal $qu;\n\t\n\t\n\t$theme['name'] = 'qna';\n\t$theme['call_theme_func'] = 'qnaQ';\n\t\n\t// DANGER! DANGER! DANGER! \n\t// Before using it in an SQL query, \n\t// Purify this $_GET variable\n\t$qid = $_GET['qid'];\n\t$qid = mysql_real_escape_string( $qid );\n\t\n\t$qna_post_tablename = 'qna_post';\n\t\n\t$qq = \"SELECT `title` FROM `$qna_post_tablename` WHERE `id`= $qid\";\n\t$qqu = mysql_query($qq);\n\t$r = mysql_fetch_assoc($qqu);\n\t\n\tmysql_free_result($qqu);\n\t\n\t$theme['page_title'] = \"$r[title]\";\n\t\n\t\n\t// $q = \"SELECT * FROM `qna_post` `q` JOIN `qna_post` `a` WHERE `q`.`id` = `a`.`parent_id` AND `q`.`id`= $qid\";\n\t\n\t\n\t$q = \"\n\tSELECT * FROM `$qna_post_tablename` WHERE `id` = $qid AND `parent_id` IS NULL \n\tUNION ALL \n\tSELECT * FROM `$qna_post_tablename` WHERE `parent_id` = $qid\";\n\t/*\n\t// For the replies\n\tSELECT child.*\n\t\tFROM comments AS parent\n\t\t\t LEFT JOIN comments AS child \n\t\t\t ON child.parent_id = parent.id\n\tWHERE parent.parent_id = 0 \n\tAND child.parent_id = 1\n\t\n\t*/\n\t\n\t$qu = mysql_query($q);\n\t\n}", "title": "" }, { "docid": "91d5738a01277e8687ca0cad5f21bcd0", "score": "0.56855613", "text": "function setQuestionTabs()\n\t{\n\t\tglobal $rbacsystem, $ilTabs;\n\n\t\t$ilTabs->clearTargets();\n\n\t\t$this->ctrl->setParameterByClass(\"ilAssQuestionPageGUI\", \"q_id\", $_GET[\"q_id\"]);\n\t\tinclude_once \"./Modules/TestQuestionPool/classes/class.assQuestion.php\";\n\t\t$q_type = $this->object->getQuestionType();\n\n\t\tif (strlen($q_type))\n\t\t{\n\t\t\t$classname = $q_type . \"GUI\";\n\t\t\t$this->ctrl->setParameterByClass(strtolower($classname), \"sel_question_types\", $q_type);\n\t\t\t$this->ctrl->setParameterByClass(strtolower($classname), \"q_id\", $_GET[\"q_id\"]);\n\t\t}\n\n\t\tif ($_GET[\"q_id\"])\n\t\t{\n\t\t\tif ($rbacsystem->checkAccess('write', $_GET[\"ref_id\"]))\n\t\t\t{\n\t\t\t\t// edit page\n\t\t\t\t$ilTabs->addTarget(\"edit_page\",\n\t\t\t\t\t$this->ctrl->getLinkTargetByClass(\"ilAssQuestionPageGUI\", \"edit\"),\n\t\t\t\t\tarray(\"edit\", \"insert\", \"exec_pg\"),\n\t\t\t\t\t\"\", \"\", $force_active);\n\t\t\t}\n\n\t\t\t$this->addTab_QuestionPreview($ilTabs);\n\t\t}\n\n\t\t$force_active = false;\n\t\tif ($rbacsystem->checkAccess('write', $_GET[\"ref_id\"]))\n\t\t{\n\t\t\t$url = \"\";\n\t\t\tif ($classname) $url = $this->ctrl->getLinkTargetByClass($classname, \"editQuestion\");\n\t\t\t// edit question properties\n\t\t\t$ilTabs->addTarget(\"edit_question\",\n\t\t\t\t$url,\n\t\t\t\tarray(\"editQuestion\", \"save\", \"saveEdit\", \"analyze\", \"originalSyncForm\"),\n\t\t\t\t$classname, \"\", $force_active);\n\t\t}\n\n\t\t// add tab for question feedback within common class assQuestionGUI\n\t\t$this->addTab_QuestionFeedback($ilTabs);\n\n\t\t// add tab for question hint within common class assQuestionGUI\n\t\t$this->addTab_QuestionHints($ilTabs);\n\n\t\t// add tab for question's suggested solution within common class assQuestionGUI\n\t\t$this->addTab_SuggestedSolution($ilTabs, $classname);\n\n\t\t// Assessment of questions sub menu entry\n\t\tif ($_GET[\"q_id\"])\n\t\t{\n\t\t\t$ilTabs->addTarget(\"statistics\",\n\t\t\t\t$this->ctrl->getLinkTargetByClass($classname, \"assessment\"),\n\t\t\t\tarray(\"assessment\"),\n\t\t\t\t$classname, \"\");\n\t\t}\n\n\t\t$this->addBackTab($ilTabs);\n\t}", "title": "" }, { "docid": "30d218edb9bd425ca6b9630dd41f3404", "score": "0.5683245", "text": "public function index()\n {\n return view('pages.faq.show', ['questions' => FrequentlyAsked::getQuestions(null), 'recent' => FrequentlyAsked::getQuestions(4)]);\n }", "title": "" }, { "docid": "bfc0ec5902dd13e3b7abb120f1d7e446", "score": "0.56745136", "text": "public function run()\n {\n Faq::create([\n 'unique_code' => uniqid().date('').time(),\n 'question' => 'What is pexeer ?',\n 'answer' => 'Aenean condimentum nibh vel enim sodales scelerisque. Mauris quisn pellentesque odio, in vulputate turpis. Integer condimentum eni lorem pellentesque euismod. Nam rutrum accumsan nisl vulputate.',\n 'author' => 1\n ]\n );\n Faq::create([\n 'unique_code' => uniqid().date('').time(),\n 'question' => 'How it works ?',\n 'answer' => 'Aenean condimentum nibh vel enim sodales scelerisque. Mauris quisn pellentesque odio, in vulputate turpis. Integer condimentum eni lorem pellentesque euismod. Nam rutrum accumsan nisl vulputate.',\n 'author' => 1\n ]\n );\n Faq::create([\n 'unique_code' => uniqid().date('').time(),\n 'question' => 'What is the workflow ?',\n 'answer' => 'Aenean condimentum nibh vel enim sodales scelerisque. Mauris quisn pellentesque odio, in vulputate turpis. Integer condimentum eni lorem pellentesque euismod. Nam rutrum accumsan nisl vulputate.',\n 'author' => 1\n ]\n );\n Faq::create([\n 'unique_code' => uniqid().date('').time(),\n 'question' => 'How i place a order ?',\n 'answer' => 'Aenean condimentum nibh vel enim sodales scelerisque. Mauris quisn pellentesque odio, in vulputate turpis. Integer condimentum eni lorem pellentesque euismod. Nam rutrum accumsan nisl vulputate.',\n 'author' => 1\n ]\n );\n Faq::create([\n 'unique_code' => uniqid().date('').time(),\n 'question' => 'How i make a withdrawal ?',\n 'answer' => 'Aenean condimentum nibh vel enim sodales scelerisque. Mauris quisn pellentesque odio, in vulputate turpis. Integer condimentum eni lorem pellentesque euismod. Nam rutrum accumsan nisl vulputate.',\n 'author' => 1\n ]\n );\n Faq::create([\n 'unique_code' => uniqid().date('').time(),\n 'question' => 'What about the deposit process ?',\n 'answer' => 'Aenean condimentum nibh vel enim sodales scelerisque. Mauris quisn pellentesque odio, in vulputate turpis. Integer condimentum eni lorem pellentesque euismod. Nam rutrum accumsan nisl vulputate.',\n 'author' => 1\n ]\n );\n }", "title": "" }, { "docid": "21694a6c05bc6c36135fbc1252a55c56", "score": "0.56701064", "text": "function get_faq_by_url_title($url_title){\r\n\r\n $this->db->select('q.id, q.question, q.answer, q.url_title');\r\n\r\n $this->db->from('faq_questions q');\r\n\r\n $this->db->where('url_title', $url_title);\r\n\r\n $query = $this->db->get();\r\n\r\n $result = $query->result_array();\r\n\r\n $table_cnf[] = array('col_id_name'=>'id', 'table_name'=>'faq_categories');\r\n $question = update_i18n_data($result[0], I18N_MULTIPLE_MODE, $table_cnf);\r\n\r\n\t\treturn $question;\r\n\t}", "title": "" }, { "docid": "e20ca571391f5f607f8b39c1ef9cbbc0", "score": "0.56693465", "text": "public function faqs_screen() {\n\t\t\t?>\n\n\t\t\t<script type=\"text/javascript\">\n\t\t\t\tjQuery(document).on('ready', function(){\n\t\t\t\t\tjQuery('#toplevel_page_woocommerce').find('a[href$=shop_coupon]').addClass('current');\n\t\t\t\t\tjQuery('#toplevel_page_woocommerce').find('a[href$=shop_coupon]').parent().addClass('current');\n\t\t\t\t});\n\t\t\t</script>\n\n\t\t\t<div class=\"wrap about-wrap\">\n\n\t\t\t\t<?php $this->intro(); ?>\n\n\t\t\t\t<h3 class=\"aligncenter\"><?php echo esc_html__( 'FAQ / Common Problems', 'woocommerce-smart-coupons' ); ?></h3>\n\n\t\t\t\t<?php\n\t\t\t\t\t$faqs = array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'When trying to add coupon/Smart Coupon, I get \"Invalid post type\" message.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Make sure use of coupon is enabled in your store. You can find this setting', 'woocommerce-smart-coupons' ) . ' <a href=\"' . add_query_arg(\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t'page' => 'wc-settings',\n\t\t\t\t\t\t\t\t\t'tab' => 'general',\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tadmin_url( 'admin.php' )\n\t\t\t\t\t\t\t) . '\" target=\"_blank\">' . __( 'here', 'woocommerce-smart-coupons' ) . '</a>.',\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Smart Coupon\\'s fields are broken?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Make sure you are using the ', 'woocommerce-smart-coupons' ) . '<a target=\"_blank\" href=\"http://dzv365zjfbd8v.cloudfront.net/changelogs/woocommerce-smart-coupons/changelog.txt\">' . __( 'latest version of Smart Coupons', 'woocommerce-smart-coupons' ) . '</a>' . esc_html__( '. If still the issue persist, temporarily de-activate all plugins except WooCommerce & Smart Coupons. Re-check the issue, if the issue still persists, contact us (from the link at the end of this page). If the issue goes away, re-activate other plugins one-by-one & re-checking the fields, to find out which plugin is conflicting.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'How to translate texts from Smart Coupons?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Simplest method is by installing', 'woocommerce-smart-coupons' ) . ' <a href=\"https://wordpress.org/plugins/loco-translate/\" target=\"_blank\">' . esc_html__( 'Loco Translate', 'woocommerce-smart-coupons' ) . '</a> ' . esc_html__( 'plugin and then following steps listed ', 'woocommerce-smart-coupons' ) . ' <a href=\"https://docs.woocommerce.com/document/smart-coupons/#section-29\" target=\"_blank\">' . __( 'here', 'woocommerce-smart-coupons' ) . '</a>.',\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'How to change texts of the emails sent from Smart Coupons?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'You can do this by overriding the email template.', 'woocommerce-smart-coupons' ) . ' <a href=\"https://docs.woocommerce.com/document/smart-coupons/#section-28\" target=\"_blank\">' . esc_html__( 'How to override email template', 'woocommerce-smart-coupons' ) . '</a>.',\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Can coupon code have any spaces in the name? / My Store Credit/Gift Certificate is not working (not generating new coupon code).', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'No. Coupon code should not have any spaces in the name, Eg, Coupon code should be “gift-certificate” & not “gift certificate”.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'What’s the URL to a coupon, so it’s automatically inserted when visiting?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'URL of coupon should be like this:', 'woocommerce-smart-coupons' ) . ' <code>https://www.mysite.com/?coupon-code=discount5</code> ' . esc_html__( '. Replace www.mysite.com with your own site URL and replace discount5 with the your coupon code.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Do not want to tie store credit to be used by only one customer? / Can a customer send a gift certificate to themselves to pass on to someone else?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Edit the main coupon which is entered in \"Coupons\" field of the product edit page, then go to \"Usage Restrictions\" > \"Disable Email Restriction\" and disable this setting and save the coupon.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Getting \\'Page Not Found Error\\' when accessing Coupons tab from My Account Page?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Go to WordPress -> Settings -> Permalinks and click on Save Settings once.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Is there any reference file for creating an import file for coupons?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'There is one file which is located inside the plugin. The file name is', 'woocommerce-smart-coupons' ) . ' <code>sample.csv</code> ' . esc_html__( 'If you want to import coupon through file, the file should be like', 'woocommerce-smart-coupons' ) . ' <code>sample.csv</code>',\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Available coupons are not visible on Cart, Checkout & My Account page?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Smart Coupons uses hooks of Cart, Checkout & My Account page to display available coupons. If your theme is not using those hooks in cart, checkout & my-account template, coupons will not be displayed.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'How can I resend gift card coupon bought by customers?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'You can resend them from order admin edit page.', 'woocommerce-smart-coupons' ) . ' <a href=\"https://docs.woocommerce.com/document/smart-coupons/#section-25\" target=\"_blank\">' . __( 'See how', 'woocommerce-smart-coupons' ) . '</a>.',\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Uncheck \"Auto-generate\" option in Store Credit is not saving? Is it always checked?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Store Credit\\'s default behavior is auto-generate because, when using a store credit, it\\'s balance keeps reducing. Therefore it should be uniquely created for every user automatically.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Smart Coupons is not sending emails.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Smart Coupons sends email only after order completion. So make sure that order complete email is enabled and sending. If enabled, then make sure all settings of coupons, products are in place. Also check by switching your theme.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( '\"Store Credit Receiver detail\" form not appearing on checkout page?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'This form is displayed using a hook which is available in My Account template. Make sure your theme\\'s my-account template contains all hooks required for that template. Update your theme if it is not updated.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Does Smart Coupons allow printing of coupon as Gift Card?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'No, it doesn\\'t provide any feature which enables you to take a printout of the generated coupon, but if you can take printout from your email, you can use it as an alternative.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Is it possible to have a coupon for each variation of the variable product?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'No, currently, you cannot set a coupon for each variation.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Is Smart Coupons compatible with WooCommerce Subscriptions?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Yes, Smart Coupons does work with WooCommerce Subscriptions.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Which features of Smart Coupons work with Subscriptions?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Give away a discount or credit on signing up a subscription, give away recurring discount or credits, apply credit during sign up, automatic payment for renewals from credit (Note: When using PayPal Standard Gateway, store credit can be applied only during sign up. Automatic payment for renewals by credit will not work for PayPal Standard Gateway).', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'How does automatic payment by store credit work with Subscriptions?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Customers can apply store credit on a subscription during purchase of subscription. If the same store credit has sufficient balance, it’ll keep applying it to renewals till the remainder in store credit is higher than renewal price. Customers will be able to apply store credit only during signup. They will not get an option to apply store credit in renewals. But if the store credit will not have sufficient balance to pay for the renewals, then the order will go into pending mode. Now when the customer will go to pay for this renewal order, they’ll get an option to apply store credit again. To activate the subscription again, the customer will have to pay for the renewals. When the customer is paying for the renewals from their account, then in that process they can use the same store credit which didn’t have the sufficient balance, again & pay for the remaining amount.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Is it possible to partially pay for a subscription with store credit and the remainder by another method?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'No, this is possible only in those cases where subscription amount is more than store credit’s balance. If store credit’s balance is more than subscription’s total then your bank account or credit card will not be charged.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'Is Smart Coupons WPML compatible?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Not yet, but this is being worked on. You will find this in later versions.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'que' => esc_html__( 'I\\'m using WPML & WPML provides support for multi-currency, but Smart Coupons only changes currency symbol & the price value remains same. Can Smart Coupons change the currency symbol and the price value associated with it?', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t\t'ans' => esc_html__( 'Currently, It can only change the currency symbol the price value remains the same. Smart Coupon is not compatible with multi-currency plugin. You may find this in some future version.', 'woocommerce-smart-coupons' ),\n\t\t\t\t\t\t),\n\t\t\t\t\t);\n\n\t\t\t\t\t$faqs = array_chunk( $faqs, 2 );\n\t\t\t\t\t$right_faq_numbering = 1;\n\t\t\t\t\t$left_faq_numbering = 0;\n\t\t\t\t\techo '<div>';\n\t\t\t\t\tforeach ( $faqs as $fqs ) {\n\t\t\t\t\t\techo '<div class=\"has-2-columns two-col\">';\n\t\t\t\t\t\tforeach ( $fqs as $index => $faq ) {\n\t\t\t\t\t\t\techo '<div' . ( ( 1 === absint( $index ) ) ? ' class=\"column col last-feature\"' : ' class=\"column col\"' ) . '>';\n\t\t\t\t\t\t\techo '<h4>' . ( ( 1 === absint( $index ) ) ? $right_faq_numbering : ( $left_faq_numbering + 1 ) ) . '. ' . $faq['que'] . '</h4>'; // phpcs:ignore\n\t\t\t\t\t\t\techo '<p>' . $faq['ans'] . '</p>'; // phpcs:ignore\n\t\t\t\t\t\t\techo '</div>';\n\t\t\t\t\t\t\t$right_faq_numbering++;\n\t\t\t\t\t\t\t$left_faq_numbering++;\n\t\t\t\t\t\t}\n\t\t\t\t\t\techo '</div>';\n\t\t\t\t\t}\n\t\t\t\t\techo '</div>';\n\t\t\t\t\t?>\n\n\t\t\t\t<div class=\"aligncenter\">\n\t\t\t\t\t<h3>\n\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\t/* translators: WooCommerce My Account support link */\n\t\t\t\t\t\t\techo sprintf( __( 'If you are facing any issues, please %s from your WooCommerce account.', 'woocommerce-smart-coupons' ), '<a target=\"_blank\" href=\"https://woocommerce.com/my-account/create-a-ticket/\">' . esc_html__( 'submit a ticket', 'woocommerce-smart-coupons' ) . '</a>' ); // phpcs:ignore\n\t\t\t\t\t\t?>\n\t\t\t\t\t</h3>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<?php\n\t\t}", "title": "" }, { "docid": "7b7ff053796a3374c7d56bd077644814", "score": "0.56514555", "text": "function addFaq()\r\r\n\t{\t\r\r\n\t if(isset($_REQUEST['question'],$_REQUEST['faq_type'],$_REQUEST['answer'],$_SESSION['admin']['user_id']) and !empty($_REQUEST['question']) and !empty($_REQUEST['faq_type']) and !empty($_SESSION['admin']['user_id']))\r\r\n\t\t{\r\r\n\t\t\t$admin=$_SESSION['admin']['user_id'];\r\r\n $question = mysql_real_escape_string($_REQUEST['question']); \r\r\n $faq_type =$_REQUEST['faq_type']; \r\r\n $answer = mysql_real_escape_string($_REQUEST['answer']); \r\r\n\t\t\t$status = $_REQUEST['status']; \r\r\n\t\t\t$sql = \"insert into sr_faq set question='\".$question.\"',answer='\".$answer.\"',faq_type_id='\".$faq_type.\"',status='\".$status.\"', created_on='\".date('Y-m-d::H:i:s').\"',updated_on='\".date('Y-m-d::H:i:s').\"',created_by='\".$admin.\"',updated_by='\".$admin.\"'\"; \r\r\n\t\t\t$resp = mysql_query($sql);\r\r\n if($resp==true)\r\r\n\t\t\t{\r\r\n return 5; //##### ADDED SUCCESS\r\r\n }\r\r\n\t\t\telse\r\r\n\t\t\t{\r\r\n return 1; //##### FAILED SQL ERROR\r\r\n }\r\r\n\t }\r\r\n\t\telse\r\r\n\t\t{\r\r\n return 0; //##### REQUIRED PARAMETER MISSING\r\r\n }\r\r\n \r\r\n\r\r\n\t}", "title": "" }, { "docid": "3c4f800f40388a1cd8b4fe6ce5842492", "score": "0.5644535", "text": "public function __construct() {\n\t\t\t// variables:\n\t\t\t$date \t= date('Y-m-d', time());\n\t\t\t$tar \t= \"2017/05/24\";\n\t\t\t$year \t= array(\"2012\", \"396\", \"300\",\"2000\", \"1100\", \"1089\");\n\t\t\t$serial \t= array(\n\t\t\t\t'date' => $date,\n\t\t\t\t'tar' => $tar,\n\t\t\t\t'year' => $year);\n\t\t\t\n\t\t\t// begin building output \n\t\t\t\n\t\t\t// header\n\t\t\t$this->html .= textFormat::lineBreak() . 'Week 4 homework: ' . textFormat::lineBreak() . textFormat::lineBreak();\n\t\t\t\n\t\t\t// homework output (list format to handle numbering)\n\t\t\t$this->html .= '<ol>';\n\t\t\t$this->html .= textFormat::makeListItem(answers::quesOne($serial));\n\t\t\t$this->html .= textFormat::makeListItem(answers::quesTwo($date));\n\t\t\t$this->html .= textFormat::makeListItem(answers::quesThree($serial));\n\t\t\t$this->html .= textFormat::makeListItem(answers::quesFour($date));\n\t\t\t$this->html .= textFormat::makeListItem(answers::quesFive($date));\n\t\t\t$this->html .= textFormat::makeListItem(answers::quesSix($tar));\n\t\t\t$this->html .= textFormat::makeListItem(answers::quesSeven($tar));\n\t\t\t$this->html .= textFormat::makeListItem(answers::quesEight($date));\n\t\t\t$this->html .= textFormat::makeListItem(answers::quesNine($date));\n\t\t\t$this->html .= textFormat::makeListItem(answers::quesTen($year));\n\t\t\t$this->html .= '</ol>' . textFormat::lineBreak();\n\t\t\t// echo $this->html;\n\t\t}", "title": "" }, { "docid": "f2bea13a616a365aa20c0c6e573a7ee0", "score": "0.56376755", "text": "public function run()\n {\n $rows = [\n [\n 'language_id' => 1,\n 'faq_id' => 1,\n 'question' => 'Maket Bıçağı Nedir?',\n 'answer' => \"Maket bıçağı veya halk arasında bilinen adıyla falçata,metal veya plastik bir koruma sürgüsü içerisinde ileri geri hareket eden ve kilitleme mekanizması ile sabitlenebilen tek tarafı keskin bıçaktır.\",\n ],\n [\n 'language_id' => 2,\n 'faq_id' => 1,\n 'question' => 'What is Utility Knife?',\n 'answer' => \"The Utility Knife also known as a Cutter/Snap off Blade is one of the tools that can be fixed and moved back by locking mechanism and can be used in daily life as well as for professional works.\",\n ],\n [\n 'language_id' => 1,\n 'faq_id' => 2,\n 'question' => 'Maket Bıçağı Kullanım Alanları Nelerdir?',\n 'answer' => \"Maket bıçağının başlıca kullanım alanları fabrikalar, inşaat projeleri, okullar ve ofislerdir. Maket bıçağı sayesinde kesimi zor olan yüzeylerde kolayca ve güvenle istediğiniz şekilde kesim yapabilirsiniz.\",\n ],\n [\n 'language_id' => 2,\n 'faq_id' => 2,\n 'question' => 'What Are the Usage Areas of Utility Knife?',\n 'answer' => \"The main uses of utility knife are factories, construction projects, warehouses, schools and offices. Thanks to utility knife you can easly cut different materials which you may have difficulty with other tools.\",\n ],\n\n ];\n\n FAQTranslation::insert($rows);\n }", "title": "" }, { "docid": "483043e56df1b0e84a26512584a2ef4f", "score": "0.5636253", "text": "public function create()\n {\n /*\n * این تابع به منظور نمابش صفحه ی ساخت faq مورد استفاده قرار می گیرد\n */\n return view('adminDashboard.FAQ.create');\n }", "title": "" }, { "docid": "8faf8072d658245e5493912973e2f5a2", "score": "0.5612325", "text": "public function show(Faq $faq)\n {\n //\n\t\t\t\treturn view('faqs.show', compact('faq'));\n }", "title": "" }, { "docid": "6b7c38044192c5cc4b369af2b6901fe7", "score": "0.56086147", "text": "function setQuestionTabs()\n\t{\n\t\tglobal $rbacsystem, $ilTabs;\n\n\t\t$ilTabs->clearTargets();\n\t\t\n\t\t$this->ctrl->setParameterByClass(\"ilAssQuestionPageGUI\", \"q_id\", $_GET[\"q_id\"]);\n\t\tinclude_once \"./Modules/TestQuestionPool/classes/class.assQuestion.php\";\n\t\t$q_type = $this->object->getQuestionType();\n\n\t\tif (strlen($q_type))\n\t\t{\n\t\t\t$classname = $q_type . \"GUI\";\n\t\t\t$this->ctrl->setParameterByClass(strtolower($classname), \"sel_question_types\", $q_type);\n\t\t\t$this->ctrl->setParameterByClass(strtolower($classname), \"q_id\", $_GET[\"q_id\"]);\n\t\t}\n\n\t\tif ($_GET[\"q_id\"])\n\t\t{\n\t\t\tif ($rbacsystem->checkAccess('write', $_GET[\"ref_id\"]))\n\t\t\t{\n\t\t\t\t// edit page\n\t\t\t\t$ilTabs->addTarget(\"edit_page\",\n\t\t\t\t\t$this->ctrl->getLinkTargetByClass(\"ilAssQuestionPageGUI\", \"edit\"),\n\t\t\t\t\tarray(\"edit\", \"insert\", \"exec_pg\"),\n\t\t\t\t\t\"\", \"\", $force_active);\n\t\t\t}\n\n\t\t\t$this->addTab_QuestionPreview($ilTabs);\n\t\t}\n\n\t\t$force_active = false;\n\t\tif ($rbacsystem->checkAccess('write', $_GET[\"ref_id\"]))\n\t\t{\n\t\t\t$url = \"\";\n\t\t\tif ($classname) $url = $this->ctrl->getLinkTargetByClass($classname, \"editQuestion\");\n\t\t\t$commands = $_POST[\"cmd\"];\n\t\t\tif (is_array($commands))\n\t\t\t{\n\t\t\t\tforeach ($commands as $key => $value)\n\t\t\t\t{\n\t\t\t\t\tif (preg_match(\"/^delete_.*/\", $key, $matches))\n\t\t\t\t\t{\n\t\t\t\t\t\t$force_active = true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t// edit question properties\n\t\t\t$ilTabs->addTarget(\"edit_question\",\n\t\t\t\t$url,\n\t\t\t\tarray(\"orderNestedTerms\",\"orderNestedPictures\",\"editQuestion\", \"save\", \"saveEdit\", \"addanswers\", \"removeanswers\", \"changeToPictures\", \"uploadanswers\", \"changeToText\", \"upanswers\", \"downanswers\", \"originalSyncForm\"),\n\t\t\t\t$classname, \"\", $force_active);\n\t\t}\n\n\t\t// add tab for question feedback within common class assQuestionGUI\n\t\t$this->addTab_QuestionFeedback($ilTabs);\n\n\t\t// add tab for question hint within common class assQuestionGUI\n\t\t$this->addTab_QuestionHints($ilTabs);\n\n\t\t// add tab for question's suggested solution within common class assQuestionGUI\n\t\t$this->addTab_SuggestedSolution($ilTabs, $classname);\n\n\t\t// Assessment of questions sub menu entry\n\t\tif ($_GET[\"q_id\"])\n\t\t{\n\t\t\t$ilTabs->addTarget(\"statistics\",\n\t\t\t\t$this->ctrl->getLinkTargetByClass($classname, \"assessment\"),\n\t\t\t\tarray(\"assessment\"),\n\t\t\t\t$classname, \"\");\n\t\t}\n\n\t\t$this->addBackTab($ilTabs);\n\t}", "title": "" }, { "docid": "0d9433df6a8461174a1e27d6e2b1f7b5", "score": "0.5605666", "text": "public function testMoreInterestingQuestions()\n\t{\n\t\t$this->\n\t\t\tvisit($this->getTestDomain())->\n\t\t\tclick_link('more-questions')->\n\t\t\t// This seems needed to help the browser settle before we get the current path\n\t\t\tassertHasCss(\"h3:contains(\\\"What's the current focus?\\\")\")\n\t\t;\n\t\t$this->assertEquals('/about', $this->current_path());\n\t}", "title": "" }, { "docid": "d68ade8e15b6a1b039344e49264b2df9", "score": "0.56039906", "text": "function ipal_question_tostring($question, $showicon = false,\r\n $showquestiontext = true, $return = true) {\r\n global $COURSE;\r\n $result = '';\r\n $result .= '<span class=\"questionname\">';\r\n if ($showicon) {\r\n $result .= print_question_icon($question, true);\r\n echo ' ';\r\n }\r\n $result .= shorten_text(format_string($question->name), 200) . '</span>';\r\n if ($showquestiontext) {\r\n $formatoptions = new stdClass();\r\n $formatoptions->noclean = true;\r\n $formatoptions->para = false;\r\n $questiontext = strip_tags(format_text($question->questiontext,\r\n $question->questiontextformat,\r\n $formatoptions, $COURSE->id));\r\n $questiontext = shorten_text($questiontext, 200);\r\n $result .= '<span class=\"questiontext\">';\r\n if (!empty($questiontext)) {\r\n $result .= $questiontext;\r\n } else {\r\n $result .= '<span class=\"error\">';\r\n $result .= get_string('questiontextisempty', 'quiz');\r\n $result .= '</span>';\r\n }\r\n $result .= '</span>';\r\n }\r\n if ($return) {\r\n return $result;\r\n } else {\r\n echo $result;\r\n }\r\n}", "title": "" }, { "docid": "af797bef35b9610914292ecf61a72df2", "score": "0.5577397", "text": "function print_question(&$question, &$state, $number, $cmoptions, $options) {\n /* The default implementation should work for most question types\n provided the member functions it calls are overridden where required.\n The layout is determined by the template question.html */\n\n global $CFG;\n $isgraded = question_state_is_graded($state->last_graded);\n\n // If this question is being shown in the context of a quiz\n // get the context so we can determine whether some extra links\n // should be shown. (Don't show these links during question preview.)\n $cm = get_coursemodule_from_instance('quiz', $cmoptions->id);\n if (!empty($cm->id)) {\n $context = get_context_instance(CONTEXT_MODULE, $cm->id);\n } else if (!empty($cm->course)) {\n $context = get_context_instance(CONTEXT_COURSE, $cm->course);\n } else {\n $context = get_context_instance(CONTEXT_SYSTEM, SITEID);\n }\n\n // For editing teachers print a link to an editing popup window\n $editlink = '';\n if ($context && has_capability('moodle/question:manage', $context)) {\n $stredit = get_string('edit');\n $linktext = '<img src=\"'.$CFG->pixpath.'/t/edit.gif\" alt=\"'.$stredit.'\" />';\n $editlink = link_to_popup_window('/question/question.php?inpopup=1&amp;id=' .\n $question->id, 'editquestion', $linktext, false, false, $stredit, '', true);\n }\n\n $generalfeedback = '';\n if ($options->generalfeedback) {\n $generalfeedback = $this->format_text($question->generalfeedback,\n $question->questiontextformat, $cmoptions);\n }\n\n $grade = '';\n if ($question->maxgrade and $options->scores) {\n if ($cmoptions->optionflags & QUESTION_ADAPTIVE) {\n $grade = !$isgraded ? '--/' : round($state->last_graded->grade, $cmoptions->decimalpoints).'/';\n }\n $grade .= $question->maxgrade;\n }\n\n $comment = stripslashes($state->manualcomment);\n $commentlink = '';\n\n if (isset($options->questioncommentlink) && $context && has_capability('mod/quiz:grade', $context)) {\n $strcomment = get_string('commentorgrade', 'quiz');\n $question_to_comment = isset($question->randomquestionid) ? $question->randomquestionid : $question->id;\n $commentlink = '<div class=\"commentlink\">'.link_to_popup_window ($options->questioncommentlink.'?attempt='.$state->attempt.'&amp;question='.$question_to_comment,\n 'commentquestion', $strcomment, 450, 650, $strcomment, 'none', true).'</div>';\n }\n\n $history = $this->history($question, $state, $number, $cmoptions, $options);\n\n include \"$CFG->dirroot/question/type/question.html\";\n }", "title": "" }, { "docid": "953007f2a673a27572dbcfaf191088cd", "score": "0.55772865", "text": "public function insert($FAQ) {\n\t\t$query = 'INSERT INTO pd_faq SET page_id=?, asking_text=?, asking_response=?';\n\t\t$waiting = $FAQ->getWaiting();\n\t\t$DB = DBFactory::getInstance();\n\t\tfor ($i = 0; $i < count($waiting); $i++) {\n\t\t\t$data[0] = Validation::antiInjection($waiting[$i]['page']);\n\t\t\t$data[1] = Validation::antiInjection($waiting[$i]['question']);\n\t\t\t$data[2] = Validation::antiInjection($waiting[$i]['response']);\n\t\t\t\n\t\t\tif ( !$DB->query($query, $data)) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "title": "" }, { "docid": "cedcd631c236bdcdd013bf7c09aff2e3", "score": "0.55768216", "text": "protected function _displayQuestion()\n {\n $question = trim(\"{$this->_displayPreamble()}\\n<question>{$this->_question}</question>\");\n\n if ($this->_default !== null) {\n $question .= \" <info>(default: {$this->_displayDefault()})</info>\";\n }\n\n $question .= ': ';\n\n return $question;\n }", "title": "" }, { "docid": "789fab1d8006bb843ca7aad2885aed80", "score": "0.5575911", "text": "public function setupFaq($builderCode, $question, $answer)\n {\n $site = Factory::createNewQueryObject(SiteQuery::class)->findOneByCode($builderCode);\n\n $faq = Factory::createNewObject(Faq::class);\n $faq->setSiteId($site->getSiteId());\n $faq->setQuestion($question);\n $faq->setAnswer($answer);\n $faq->setSortOrder($this->faqPosition);\n $faq->save();\n\n ++$this->faqPosition;\n }", "title": "" }, { "docid": "fb55f1d71f6afa19baf7b32f8a4a4478", "score": "0.55679226", "text": "private function askQuestion()\n {\n switch ($this->currentCategory()) {\n case Categories::POP:\n echoln(array_shift($this->popQuestions));\n break;\n case Categories::SCIENCE:\n echoln(array_shift($this->scienceQuestions));\n break;\n case Categories::SPORTS:\n echoln(array_shift($this->sportsQuestions));\n break;\n case Categories::ROCK:\n echoln(array_shift($this->rockQuestions));\n break;\n }\n }", "title": "" }, { "docid": "40e307fdf92ad4bc1403202cef9439a9", "score": "0.556633", "text": "public function show(Question $question)\n {\n //\n }", "title": "" }, { "docid": "40e307fdf92ad4bc1403202cef9439a9", "score": "0.556633", "text": "public function show(Question $question)\n {\n //\n }", "title": "" }, { "docid": "40e307fdf92ad4bc1403202cef9439a9", "score": "0.556633", "text": "public function show(Question $question)\n {\n //\n }", "title": "" }, { "docid": "40e307fdf92ad4bc1403202cef9439a9", "score": "0.556633", "text": "public function show(Question $question)\n {\n //\n }", "title": "" }, { "docid": "a9817482ff604dc064f2eb91101687fc", "score": "0.55649775", "text": "public function run()\n {\n $questions = [\n [\n \"category\" => \"医药\",\n \"question\" => \"下列哪种情况下可以采用热敷的疗法?\",\n \"answer\" => \"肠胃痉挛\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"我国第一部药典书是?\",\n \"answer\" => \"新修本草\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"毒蛇的头部多为三角形,有毒腺,能分泌毒液,如果不幸被毒蛇咬伤,怎么处理比较妥当?\",\n \"answer\" => \"近心端包扎,并尽快救医\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"下列哪种蔬菜对缺铁性贫血有明显的改善作用?\",\n \"answer\" => \"菠菜\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"霉变的花生因为存在哪种毒素而不宜食用?\",\n \"answer\" => \"黄曲霉素\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"夜盲症是因为缺少什么维生素引起的?\",\n \"answer\" => \"维生素A\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"吃多了皮蛋会造成哪种重金属元素中毒?\",\n \"answer\" => \"铅\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"听诊器最初是由什么材质制成的?\",\n \"answer\" => \"木头\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"《献血法》规定,献血者两次献血间隔时间不得少于多长时间?\",\n \"answer\" => \"六个月\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"人体血液循环的动力泵是什么?\",\n \"answer\" => \"心脏\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"洁厕精和84消毒液混用会产生哪种气体导致人体中毒?\",\n \"answer\" => \"氯气\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"接种卡介苗是为了预防哪一类传染病?\",\n \"answer\" => \"结核病\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"贫血主要原因是人体缺少哪一种元素\",\n \"answer\" => \"铁\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"为什么不宜在强光下看书?\",\n \"answer\" => \"强光容易让眼疲劳\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"生活中如果不慎发生关节扭伤,应该采用的应急救治方法是?\",\n \"answer\" => \"冷敷\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"我国婚姻法规定禁止近亲结婚,是因为近亲结婚有什么危害?\",\n \"answer\" => \"后代患遗传病的机会增加\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"医生一般在病人臀部外上部进行肌肉注射,这是因为该处有什么特点?\",\n \"answer\" => \"没有大的神经和血管\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"小孩不适宜睡在沙发上,这是因为?\",\n \"answer\" => \"发育期,容易使骨骼变形\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"在世界上首创用汤药治病的是谁?\",\n \"answer\" => \"伊尹\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"阿司匹林最初提取于什么?\",\n \"answer\" => \"杨柳树皮\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"人体最大的解毒器官是以下哪个?\",\n \"answer\" => \"肝脏\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"古代医学著作《伤寒杂病论》奠定了中医治疗学的基础,是历代学医者的必修之书,它的作者是?\",\n \"answer\" => \"张仲景\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"神医扁鹊是哪个朝代人\",\n \"answer\" => \"春秋战国\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"后代医家奉之为“脉学之宗”的人是谁?\",\n \"answer\" => \"扁鹊\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"我国古代第一个采用“望闻问切”诊断疾病的名医是谁?\",\n \"answer\" => \"扁鹊\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"名医扁鹊总结出“望,闻,问,切”的诊断疾病的方法,其中“切”是指什么?\",\n \"answer\" => \"按脉搏\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"“扁鹊见蔡桓公,立有间,扁鹊曰:“君有疾在腠理”摘自《韩非子》,据此判断扁鹊当时采用的诊断方法是?\",\n \"answer\" => \"望\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"众所周知,糖尿病人在生活中是不能摄入太多的糖份的,但有一种“糖”可作为糖尿病人代谢时一场时注射输液实用,也适合于糖尿病人患者服用。请问这种“糖”是什么?\",\n \"answer\" => \"木糖醇\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"百会穴在人体的哪个部位?\",\n \"answer\" => \"头顶\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"下列哪种中药对眼睛有好处?\",\n \"answer\" => \"决明子\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"在我国古代针灸用具是?\",\n \"answer\" => \"九针\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"以下不属于中药薄荷的功效的是?\",\n \"answer\" => \"止血\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药里的“牛黄”指的是?\",\n \"answer\" => \"牛的胆囊结石\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"以下中药里,除了治病外还有驱蚊功效的是\",\n \"answer\" => \"艾蒿\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药川贝母取材于什么?\",\n \"answer\" => \"一种草本植物\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药的“狗宝”通常指的是?\",\n \"answer\" => \"犬科动物犬的胃结石\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药里的“玳瑁”具有很好的清热解毒功效,它取材于?\",\n \"answer\" => \"一种海洋植物\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"熬制中药一般常用的器具是?\",\n \"answer\" => \"砂锅砂壶\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"茶酒中药。中药所说的“饮片”是指?\",\n \"answer\" => \"加工后炮制的中药\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药里所说的“陈皮”是指?\",\n \"answer\" => \"晒干的橘皮\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药“胖大海”的主要功效是?\",\n \"answer\" => \"润喉止咳\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"按照一般市场行情,同样重量的以下中药(例如同为一两)最为贵重的是?\",\n \"answer\" => \"鹿茸\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药里的“雄黄”属于?\",\n \"answer\" => \"矿物\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药里的“大黄”指的是?\",\n \"answer\" => \"一种植物类中药\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"龙眼的主要功效?\",\n \"answer\" => \"补血安神\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药“羊蹄”按取材分类应该属于?\",\n \"answer\" => \"植物药\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药很早就有“忌口”的说法,以下不是常见的忌口食物是?\",\n \"answer\" => \"清淡食物\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药配药有“十八反十九畏”的基本禁忌,以下一般不可同时入药的是?\",\n \"answer\" => \"甘草和甘遂\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"健胃类的中药一般怎样服用有利于药效的发挥?\",\n \"answer\" => \"饭前服用\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"古代中药里俗称“当门子”指的是什么?\",\n \"answer\" => \"麝香\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"有一味中药名为“全虫”,这里的虫是指?\",\n \"answer\" => \"蝎子\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药人言即信是指?\",\n \"answer\" => \"砒霜\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药“阿胶”有补血止血,滋阴润燥之效,被列为药品之中的“上品”。请问它是用哪种动物的皮加工制成?\",\n \"answer\" => \"驴\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"有补脾益气、清热解毒、祛痰止咳、缓急止痛,调和褚药的功效,被尊为“灵草”、“国老”、“众药之王”的是以下哪种中药?\",\n \"answer\" => \"甘草\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中医的“针灸”对人体穴位有很深的研究,以下位于人体手部的穴位为?\",\n \"answer\" => \"劳宫穴\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中医的“针灸”对人体穴位有很深的研究,人体有一处“曲池穴”位于?\",\n \"answer\" => \"肘部\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中国历史上第一部中医学典籍?\",\n \"answer\" => \"《黄帝内经》\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"借问酒家何处有。(打中医术语)\",\n \"answer\" => \"童便作引\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中医的“针灸”对人体空位有很深的研究,人体有一处“四白穴”位于?\",\n \"answer\" => \"头部\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中医所说的“白虎历节”指的是哪种症状\",\n \"answer\" => \"关节肿痛\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"以下“不是”古代药酒常用原料的是?\",\n \"answer\" => \"鸡尾\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"下列不属于治疗砒霜中毒的急救药物的是?\",\n \"answer\" => \"草木灰\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"涌泉穴在哪?\",\n \"answer\" => \"足底\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"下列具有疏散风热、清目醒脑作用的一味中草药是?\",\n \"answer\" => \"薄荷\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"川贝母属于?\",\n \"answer\" => \"野生药用植物\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中药中的麝香是什么?\",\n \"answer\" => \"雄性鹿的腹部\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"药用兽皮的统称?\",\n \"answer\" => \"晒干的蝉蜕\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"中草药里“三七”的入药部分实际是植物的?\",\n \"answer\" => \"根\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"不属于中草药的是什么?\",\n \"answer\" => \"巴乌\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"适量合理地饮用葡萄酒,对人体有什么好处?\",\n \"answer\" => \"防治心血管病\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"适量合理地饮用葡萄酒,对人体有什么好处?\",\n \"answer\" => \"防治心血管病\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"古代将中草药按药性分为“四气”指的是什么?\",\n \"answer\" => \"寒热温凉\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"以下不属于中草药的是?\",\n \"answer\" => \"砌末\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"下列具有清热解毒作用的一味中草药是?\",\n \"answer\" => \"金银花\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"下列哪种草药能够治疗呕吐泻痢?\",\n \"answer\" => \"黄连\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"胰岛素能治疗\",\n \"answer\" => \"糖尿病\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"在缺医的情况下,对于中风、中暑、中毒、过敏以及手术麻醉过程中出现昏迷、呼吸停止、血压下降、休克的病人可用拇指反复按压其“人中”以使其苏醒。请问“人中”具体在人体哪个部位?\",\n \"answer\" => \"鼻子之下、嘴唇之上的凹沟中\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"细菌是生物的主要类群之一,它是所有生物中数量最多的一类。以下关于细菌的说法正确的是?\",\n \"answer\" => \"有很多细菌对人体有益\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"人体如果运动过度或热身不足,很容易造成肌肉拉伤。出现肌肉拉伤的情况后,应立即停止运动并采取以下哪个措施?\",\n \"answer\" => \"敷上冰块或冷毛巾\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"看病时选对就诊科室,不但能使自己及时、顺利就诊,也可节约医疗资源。请问感冒头疼的患者挂号时应选哪个科室?\",\n \"answer\" => \"内科\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"婴儿出生时的哭啼声意味着婴儿开始有一什么生理功能?\",\n \"answer\" => \"呼吸\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"哪种病人不宜饮茶?\",\n \"answer\" => \"溃疡病\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"具有止血功能的维生素是?\",\n \"answer\" => \"维生素K\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"亚硝胺是食品中致癌的因素,多吃以下哪种蔬菜可以抵制人体对亚硝胺的吸收和合成?\",\n \"answer\" => \"大白菜\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"用以下哪种方法预防颈椎病是错误的?\",\n \"answer\" => \"睡软床\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"我们大家的血型或相同或不相同,请问ABO系统血型有几种?\",\n \"answer\" => \"4\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"冻疮是由于皮肤哪一部分受损而引起的?\",\n \"answer\" => \"毛细血管\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"人体全身有多少块肌肉?\",\n \"answer\" => \"639块\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"缺少哪种维生素后,儿童易患佝偻病,成人易得软骨病?\",\n \"answer\" => \"维生素D\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"皮肤轻微划伤后血能自行止住,这主要是什么起作用?\",\n \"answer\" => \"血小板\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"人体分解和代谢酒精的是什么器官?\",\n \"answer\" => \"肝\"\n ],\n [\n \"category\" => \"医药\",\n \"question\" => \"不论是儿童、成年或老年缺钙都会影响健康,患各种疾病。钙的吸收与哪种维生素有关?\",\n \"answer\" => \"维生素D\"\n ],\n ];\n\n $questions = collect($questions)->map(function ($item) {\n return array_merge($item, [\n \"created_at\" => Carbon::now(),\n \"updated_at\" => Carbon::now(),\n ]);\n })\n ->toArray();\n\n Question::insert($questions);\n }", "title": "" }, { "docid": "d40dcbbd03f9a81c777cf7fd60a8b995", "score": "0.5563022", "text": "function How()\r\n\t\t{\r\n\t\t\t$this->page_title = Language::Get('How it works');\r\n\t\t\t$this->menuItem = 'how';\r\n//\t\t\t$this->hasLeftColumn = false;\r\n\t\t}", "title": "" }, { "docid": "c4f10970315aba1a9145b3788efdc217", "score": "0.55510217", "text": "function display_question_editing_page(&$mform, $question, $wizardnow){\n list($heading, $langmodule) = $this->get_heading();\n print_heading_with_help($heading, $this->name(), $langmodule);\n $mform->display();\n }", "title": "" }, { "docid": "21b4e35e022dc9ef7bb39c8af5a6a855", "score": "0.5548374", "text": "function question_xhtml($descr, $questionID, $results = '') {\n $html = file_get_contents(dirname(__FILE__) . '/question.thtml');\n $html = str_replace('%%DESCRIPTION%%', $descr, $html);\n $html = str_replace('%%RESULTS%%', $results, $html);\n $html = str_replace('%%QF%%', $questionID . \".zip\", $html);\n\n\t/* Utter a warning message when displaying results */\n\tif($results) {\n $html .= '<div style=\"background-color: red;\">';\n $html .= 'The score is <strong>not</strong> saved. ' .\n 'You MUST click on \"Grade\" to make your answer final.';\n $html .= '</div>';\n\t}\n\n return $html;\n }", "title": "" }, { "docid": "48db22fd9886f87a72bd2c938d183598", "score": "0.5535803", "text": "public function index(){\n $this->data['rows'] = DB::table('faqs')\n ->where([\n 'status'=>1\n ])\n ->get();\n\n return view('backend.pages.faq.all')->with($this->data);\n }", "title": "" }, { "docid": "7395b6b5014b67753a1d8aaf152b86a1", "score": "0.552105", "text": "protected function process_quiz_questions( $questions = array() ) {\n\t\t\tglobal $learndash_question_types;\n\n\t\t\t$questions_section_html = '';\n\n\t\t\t$steps_type = 'sfwd-question';\n\n\t\t\tif ( ! empty( $questions ) ) {\n\t\t\t\tforeach ( $questions as $question_id => $q_pro_id ) {\n\t\t\t\t\t$edit_post_link = get_edit_post_link( $question_id );\n\t\t\t\t\t$edit_post_link = add_query_arg( 'quiz_id', $this->builder_post_id, $edit_post_link );\n\n\t\t\t\t\t$view_post_link = learndash_get_step_permalink( $question_id, $this->builder_post_id );\n\n\t\t\t\t\t//$question_pro_id = get_post_meta( $question_id, 'question_pro_id', true );\n\t\t\t\t\t//if ( ! empty( $question_pro_id ) ) {\n\t\t\t\t\t//\t$question_pro_fields = leandash_get_question_pro_fields( $question_pro_id, array( 'quiz_id', 'points', 'answer_type' ) );\n\t\t\t\t\t//}\n\n\t\t\t\t\t$question_pro_fields = leandash_get_question_pro_fields( $q_pro_id, array( 'quiz_id', 'points', 'answer_type' ) );\n\n\t\t\t\t\t$question_type_string = '';\n\t\t\t\t\tif ( ( ! isset( $question_pro_fields['answer_type'] ) ) || ( empty( $question_pro_fields['answer_type'] ) ) || ( ! isset( $learndash_question_types[ $question_pro_fields['answer_type'] ] ) ) ) {\n\t\t\t\t\t\t$question_pro_fields['answer_type'] = 'single';\n\t\t\t\t\t}\n\n\t\t\t\t\t// translators: placeholder: Question Type.\n\t\t\t\t\t$question_type_string = sprintf( _x('%s', 'placeholder: Question Type', 'learndash' ), $learndash_question_types[ $question_pro_fields['answer_type'] ] );\n\n\t\t\t\t\t$question_points_string = '';\n\t\t\t\t\tif ( ( isset( $question_pro_fields['points'] ) ) && ( ! empty( $question_pro_fields['points'] ) ) ) {\n\t\t\t\t\t\t$question_points = absint( $question_pro_fields['points'] );\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$question_points = 1;\n\t\t\t\t\t}\n\n\t\t\t\t\t// translators: placeholder: Question Points.\n\t\t\t\t\t$question_points_string = sprintf( _nx( '(%dpt)', '(%dpts)', $question_points, 'placeholder: Question Points', 'learndash' ), number_format_i18n( $question_points ) );\n\n\t\t\t\t\t$questions_section_item_html = '<div id=\"ld-post-' . $question_id . '\" class=\"ld-course-builder-item ld-course-builder-question-item\" data-ld-type=\"' . $steps_type . '\" data-ld-id=\"' . $question_id . '\">\n\t\t\t\t\t\t\t\t\t<div class=\"ld-course-builder-quiz-header ld-course-builder-header\">\n\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-actions\">\n\t\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-action ld-course-builder-action-move ld-course-builder-action-question-move dashicons\" title=\"' . esc_html__( 'Move', 'learndash' ) . '\"></span>\n\t\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-sub-actions\">\n\t\t\t\t\t\t\t\t\t\t\t\t<a target=\"_blank\" class=\"ld-course-builder-action ld-course-builder-action-edit ld-course-builder-action-quiz-edit dashicons\" href=\"' . $edit_post_link . '\"><span class=\"screen-reader-text\">' .\n\t\t\t\t\t\t\t\t\t\t\t\t// translators: placeholder: placeholder: Topic.\n\t\t\t\t\t\t\t\t\t\t\t\tsprintf( esc_html_x( 'Edit %s Settings (new window)', 'placeholder: Topic', 'learndash' ), LearnDash_Custom_Label::get_label( 'Quiz' ) ) . '\" ></span></a>\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-action ld-course-builder-action-remove ld-course-builder-action-quiz-remove dashicons\" title=\"' .\n\t\t\t\t\t\t\t\t\t\t\t\t// translators: placeholders: Question, Quiz.\n\t\t\t\t\t\t\t\t\t\t\t\tsprintf( esc_html_x( 'Remove %1$s from %2$s', 'placeholders: Question, Quiz', 'learndash' ), LearnDash_Custom_Label::get_label( 'question' ), LearnDash_Custom_Label::get_label( 'quiz' ) ) . '\"></span>\n\t\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-title\">\n\t\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-title-text\">' . get_the_title( $question_id ) . '</span>\n\t\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-action ld-course-builder-edit-title-pencil dashicons\" title=\"' . esc_html__( 'Edit Title', 'learndash' ) . '\" ></span>\n\t\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-action ld-course-builder-edit-title-ok dashicons\" title=\"' . esc_html__( 'Ok', 'learndash' ) . '\" ></span>\n\t\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-action ld-course-builder-edit-title-cancel dashicons\" title=\"' . esc_html__( 'Cancel', 'learndash' ) . '\" ></span>\n\t\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-title-right\" style=\"float: right;\" >\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-type\">'. $question_type_string .'</span>\n\t\t\t\t\t\t\t\t\t\t\t\t<span class=\"ld-course-builder-points\" data-ld-points=\"' . absint( $question_points ) . '\">'. $question_points_string .'</span>\n\t\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t</div>';\n\t\t\t\t\t$questions_section_html .= $questions_section_item_html;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$questions_section_html = '<div class=\"ld-course-builder-' . $this->get_label_for_post_type( $steps_type ) . '-items\">'. $questions_section_html .'</div>';\n\n\t\t\treturn $questions_section_html;\n\t\t}", "title": "" }, { "docid": "db0247eae59abc3f31f9d9763b0b19fb", "score": "0.55139303", "text": "function array_to_faq($blocks, $quests)\n{\n\t$lines = array();\n\n\tfor($i = 0; $i < count($blocks); $i++)\n\t{\n\t\t$lines[] = '$faq[] = array(\"--\", \"'.str_replace('\"', '\\\"', $blocks[$i]).'\");'.\"\\n\";\n\n\t\tfor($j = 0; $j < count($quests[$i]); $j++)\n\t\t{\n\t\t\tif( !empty($quests[$i][$j][Q]) && !empty($quests[$i][$j][A]) )\n\t\t\t{\n\t\t\t\t$lines[] = '$faq[] = array(\"'.str_replace('\"', '\\\"', $quests[$i][$j][Q]).'\", \"'.str_replace('\"', '\\\"', $quests[$i][$j][A]).'\");'.\"\\n\";\n\t\t\t}\n\t\t}\n\n\t\t$lines[] = \"\\n\";\n\t}\n\n\treturn $lines;\n}", "title": "" }, { "docid": "e56a2e8a89a2b7e1635f5a3367de47bc", "score": "0.5509271", "text": "public function explain(){}", "title": "" }, { "docid": "d465832bd5557d202892a2efc321bb03", "score": "0.55077016", "text": "public function getFaqMetaDescription()\n {\n return $this->scopeConfig->getValue(\n self::XML_PATH_FAQ_META_DESCRIPTION,\n ScopeInterface::SCOPE_STORE\n );\n }", "title": "" }, { "docid": "3ba89cd3c70da7b041470e1cedba835b", "score": "0.5504987", "text": "function AnswerInfo($qid,$slug, $title,$counts, $position, $properties, $status, $id = 0)\n\t{\n\t\t$this->id = $id;\n\t\t$this->qid = $qid;\n\t\t$this->slug = $slug;\n\t\t$this->title = stripslashes($title);\n\t\t$this->counts=$counts;\n\t\t$this->position = $position;\n\t\t$this->properties = unserialize($properties);\n\t\t$this->status = $status;\n\t}", "title": "" }, { "docid": "6378c70273f6630b6a164a1090f50576", "score": "0.5501989", "text": "public function testGetRelatedFAQs()\n {\n $faq = $this->objFromFixture('FAQ', 'faq1');\n $result = $faq->getRelatedFAQs();\n\n $this->assertEquals(1, $result->count());\n $this->assertEquals(\n [],\n array_diff(\n $result->column('Question'),\n ['Question 3']\n )\n );\n\n $faq = $this->objFromFixture('FAQ', 'faq2');\n $result = $faq->getRelatedFAQs();\n\n $this->assertEquals(1, $result->count());\n $this->assertEquals(\n [],\n array_diff(\n $result->column('Question'),\n ['Question 3']\n )\n );\n\n $faq = $this->objFromFixture('FAQ', 'faq3');\n $result = $faq->getRelatedFAQs();\n\n $this->assertEquals(2, $result->count());\n $this->assertEquals(\n [],\n array_diff(\n $result->column('Question'),\n ['Question 1', 'Question 2']\n )\n );\n\n $faq = $this->objFromFixture('FAQ', 'faq4');\n $result = $faq->getRelatedFAQs();\n\n $this->assertNull($result);\n }", "title": "" }, { "docid": "e64e06fcfb157b38131c4ecb190c3d5d", "score": "0.5501108", "text": "public function getAboutYouQuestionsAction() {\n $sql = Mage::getSingleton('core/resource')->getConnection('core_read');\n $questions = $sql->fetchAll(\"SELECT * FROM `nordstrom_quiz_questions` WHERE 1 ORDER BY sort_order ASC LIMIT 0, 4\");\n foreach ($questions as $key => $q) {\n // Generate questions\n $result[$q['id']]['text'] = $q['text'];\n $result[$q['id']]['id'] = $q['id'];\n $result[$q['id']]['single'] = $q['single_answer'];\n if (strlen($q['hint_title']) > 1) {\n $result[$q['id']]['hint_title'] = $q['hint_title'];\n $result[$q['id']]['hint_text'] = $q['hint_text'];\n }\n $id = $q['id'];\n $answers = $sql->fetchAll(\"SELECT * FROM `nordstrom_quiz_answers` WHERE question_id = $id\");\n foreach($answers as $key => $a) {\n // Add some answers\n // Bugfix: Has to provide id in array instead of a key\n $result[$q['id']]['answers'][$key]['id'] = $a['id'];\n $result[$q['id']]['answers'][$key]['text'] = $a['answer_text'];\n }\n }\n echo json_encode($result); // And send it back!\n }", "title": "" }, { "docid": "77a28f2c0b1023845e90ccec60e9d160", "score": "0.5488969", "text": "function question_body ( $which ) {\n\tif ( $which == 'start' ) {\n\t\techo <<<EOT\n\t\t\n\t<div class=\"questionblock\">\n\t\nEOT;\n\t}\n\telse if ( $which == 'end' ) {\n\t\techo <<<EOT\n\t\t\n\t</div><!-- close questionblock div -->\n\t\nEOT;\n\t}\n}", "title": "" }, { "docid": "2988fdf8c49c75b8adb89ecb70576d9b", "score": "0.5487229", "text": "public function register_faq_post_type()\n {\n $redirect_base = \"\";\n $FAQKnowledgeBasePage = $this->get_option('FAQKnowledgeBasePage');\n if (!empty($FAQKnowledgeBasePage)) {\n $redirect_base = get_post_field('post_name', $FAQKnowledgeBasePage) . '/';\n }\n\n $singular = __('FAQ', 'kong-helpdesk');\n $plural = __('FAQs', 'kong-helpdesk');\n\n $labels = array(\n 'name' => __('FAQs', 'kong-helpdesk'),\n 'all_items' => sprintf(__('All %s', 'kong-helpdesk'), $plural),\n 'singular_name' => $singular,\n 'add_new' => sprintf(__('New %s', 'kong-helpdesk'), $singular),\n 'add_new_item' => sprintf(__('Add New %s', 'kong-helpdesk'), $singular),\n 'edit_item' => sprintf(__('Edit %s', 'kong-helpdesk'), $singular),\n 'new_item' => sprintf(__('New %s', 'kong-helpdesk'), $singular),\n 'view_item' => sprintf(__('View %s', 'kong-helpdesk'), $singular),\n 'search_items' => sprintf(__('Search %s', 'kong-helpdesk'), $plural),\n 'not_found' => sprintf(__('No %s found', 'kong-helpdesk'), $plural),\n 'not_found_in_trash' => sprintf(__('No %s found in trash', 'kong-helpdesk'), $plural),\n );\n\n $args = array(\n 'labels' => $labels,\n 'public' => true,\n 'exclude_from_search' => false,\n 'show_ui' => true,\n 'menu_position' => 70,\n 'rewrite' => array(\n 'slug' => $redirect_base . 'faq',\n 'with_front' => false\n ),\n 'query_var' => 'faqs',\n 'supports' => array('title', 'editor', 'author', 'revisions', 'thumbnail', 'comments', 'page-attributes'),\n 'menu_icon' => 'dashicons-welcome-learn-more',\n 'capability_type' => array('faq','faqs'),\n 'capabilities' => array(\n 'publish_posts' => 'publish_faqs',\n 'edit_posts' => 'edit_faqs',\n 'edit_others_posts' => 'edit_others_faqs',\n 'delete_posts' => 'delete_faqs',\n 'delete_others_posts' => 'delete_others_faqs',\n 'delete_published_posts' => 'delete_published_faqs',\n 'read_private_posts' => 'read_private_faqs',\n 'edit_post' => 'edit_faq',\n 'delete_post' => 'delete_faq',\n 'read_post' => 'read_faq',\n 'edit_published_posts' => 'edit_published_faqs'\n ),\n 'map_meta_cap' => true,\n 'taxonomies' => array('product_cat'),\n );\n\n register_post_type('faq', $args);\n }", "title": "" } ]
092501551a087a03be3941ddc24d98ed
Get the BluePay post response
[ { "docid": "33c989a96892ee9141b151fddebbc0cd", "score": "0.0", "text": "public function getResponse($raw = false)\n\t{\n\t\tif ($raw)\n\t\t{\n\t\t\treturn $this->response;\n\t\t}\n\n\t\tparse_str($this->response, $array);\n\t\treturn $array;\n\t}", "title": "" } ]
[ { "docid": "e63ea1aefd236f6b7d980da1b6671aab", "score": "0.7482258", "text": "public function post()\n {\n curl_setopt($this->curl, CURLOPT_CUSTOMREQUEST, \"POST\");\n $this->response_body = curl_exec($this->curl);\n return $this->response_body;\n }", "title": "" }, { "docid": "1355c99afb809075d035c679a0f90e4e", "score": "0.6968534", "text": "protected function getPOST(){\n\t\t$data = array();\n\t\tif($this->description != null){\n\t\t\t$data['description'] = $this->description;\n\t\t}\n\n\t\t$payment_method = $this->getPaymentMethod();\n\t\tif($payment_method != null){\n\t\t\t$data['payment_method'] = $payment_method;\n\t\t}else{\n\t\t\t$this->exceptions[] = new InvalidPaymentException();\n\t\t}\n\t\t$this->addAddressPOST($data);\n\t\treturn json_encode($data,JSON_UNESCAPED_SLASHES);\n\n\t}", "title": "" }, { "docid": "21278ab7e4c1cfbb48aad3ed454f5dea", "score": "0.66291493", "text": "public function responseAction() {\n\n try {\n $request = $this->_checkReturnedPost();\n if ($request['err_code'] == '00' || $request['err_code'] == '000') {\n $this->_processSale($request);\n } elseif ($request['err_code'] == '529') {\n $this->_processCancel($request);\n\n $this->getResponse()->setBody(\n $this->getLayout()\n ->createBlock($this->_cancelBlockType)\n ->setOrder($this->_order)\n ->toHtml()\n );\n } else {\n $this->_processCancel($request);\n\n $this->getResponse()->setBody(\n $this->getLayout()\n ->createBlock($this->_cancelBlockType)\n ->setOrder($this->_order)\n ->toHtml()\n );\n }\n } catch (Mage_Core_Exception $e) {\n $this->_debug('Payfast response error: ' . $e->getMessage());\n $this->getResponse()->setBody(\n $this->getLayout()\n ->createBlock($this->_failureBlockType)\n ->setOrder($this->_order)\n ->toHtml()\n );\n }\n }", "title": "" }, { "docid": "f399f5dc42e73071d428e25cc645f468", "score": "0.6522146", "text": "public function getdatatoken_post()\n {\n $data = $this->verify_request();\n // Send the return data as reponse\n $status = parent::HTTP_OK;\n $response = ['status' => $status, 'data' => $data];\n $this->response($response, $status);\n\n // // Call the verification method and store the return value in the variable\n // $token = $this->post('token');\n\n // if(!empty($token)){\n // $data = $this->verify_request($token);\n // // Send the return data as reponse\n // $status = parent::HTTP_OK;\n // $response = ['status' => $status, 'data' => $data];\n // $this->response($response, $status);\n // }else{\n // $status = parent::HTTP_BAD_REQUEST;\n // $response = ['status' => $status, 'msg' => 'Bad Request! '];\n // $this->response($response, $status);\n // }\n\n }", "title": "" }, { "docid": "60f25f1536e28428361e8b54bf2ef233", "score": "0.64937514", "text": "public function post(): Response\n {\n return $this->setMethod(static::POST)->send();\n }", "title": "" }, { "docid": "cfe0238caa93a4b900ef3fa867f94ad9", "score": "0.64599603", "text": "public function responseAction() {\r\n\t\tif($this->getRequest()->isPost()) {\r\n\t\t\t\r\n\t\t\t/*\r\n\t\t\t/* Your gateway's code to make sure the reponse you\r\n\t\t\t/* just got is from the gatway and not from some weirdo.\r\n\t\t\t/* This generally has some checksum or other checks,\r\n\t\t\t/* and is provided by the gateway.\r\n\t\t\t/* For now, we assume that the gateway's response is valid\r\n\t\t\t*/\r\n\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t$order_id = $_POST['order_id']; // Generally sent by gateway\r\n $signature = ($_POST[\"sig\"]);\r\n $reference_code = ($_POST[\"reference\"]);\r\n $tracker = ($_POST[\"tracker\"]);\r\n \r\n $success = false;\r\n $error = \"\";\r\n\r\n if (!isset($order_id) || !isset($signature))\r\n {\r\n $error = 'Payment to Safepay Failed. No data received';\r\n }\r\n else if (Mage::helper('safepay')->validate_signature($tracker, $signature) === false)\r\n {\r\n $error = 'Payment is invalid. Failed security check.';\r\n }\r\n else\r\n {\r\n $success = true;\r\n }\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tif($success) {\r\n\t\t\t\t// Payment was successful, so update the order's state, send order email and move to the success page\r\n\t\t\t\t$order = Mage::getModel('sales/order');\r\n\t\t\t\t$order->load($order_id);\r\n\t\t\t\t$order->setState(Mage_Sales_Model_Order::STATE_PROCESSING, true, 'Gateway has authorized the payment.');\r\n\t\t\t\t$order->addStatusHistoryComment(Mage::helper('safepay')->__('Payment Gateway Reference %s and tracker id %s',$reference_code,$tracker));\r\n\r\n\t\t\t\t$order->sendNewOrderEmail();\r\n\t\t\t\t$order->setEmailSent(true);\r\n\t\t\t\t\r\n\t\t\t\t$order->save();\r\n\t\t\t\t\r\n\t\t\t\t$payment = $order->getPayment();\r\n\t\t\t\t$payment->setAdditionalInformation($_POST);\r\n\t\t\t\t$payment->save();\r\n\t \r\n\t\t\t\tMage::getSingleton('checkout/session')->unsQuoteId();\r\n\t\t\t\t\r\n\t\t\t\tMage_Core_Controller_Varien_Action::_redirect('checkout/onepage/success', array('_secure'=>true));\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t// There is a problem in the response we got\r\n\t\t\t\t$this->cancelAction( $error);\r\n\t\t\t\tMage_Core_Controller_Varien_Action::_redirect('checkout/onepage/failure', array('_secure'=>true));\r\n\t\t\t}\r\n\t\t}\r\n\t\telse\r\n\t\t\tMage_Core_Controller_Varien_Action::_redirect('');\r\n\t}", "title": "" }, { "docid": "aa0f8b06bd4d32645243f664da2f2e5a", "score": "0.6455032", "text": "function PPHttpPost($methodName_, $nvpStr_) {\n\t\t\tglobal $gateway_environment;\n\t\t\t$environment = $gateway_environment;\n\n\t\t\t$PARTNER = pmpro_getOption(\"payflow_partner\");\n\t\t\t$VENDOR = pmpro_getOption(\"payflow_vendor\");\n\t\t\t$USER = pmpro_getOption(\"payflow_user\");\n\t\t\t$PWD = pmpro_getOption(\"payflow_pwd\");\n\t\t\t$API_Endpoint = \"https://payflowpro.paypal.com\";\n\t\t\tif(\"sandbox\" === $environment || \"beta-sandbox\" === $environment) {\n\t\t\t\t$API_Endpoint = \"https://pilot-payflowpro.paypal.com\";\n\t\t\t}\n\n\t\t\t$version = urlencode('4');\n\n\t\t\t// NVPRequest for submitting to server\n\t\t\t$nvpreq = \"TRXTYPE=\" . $methodName_ . \"&TENDER=C&PARTNER=\" . $PARTNER . \"&VENDOR=\" . $VENDOR . \"&USER=\" . $USER . \"&PWD=\" . $PWD . \"&VERBOSITY=medium\" . \"&BUTTONSOURCE=\" . urlencode(PAYPAL_BN_CODE) . $nvpStr_;\n\n\t\t\t//post to PayPal\n\t\t\t$response = wp_remote_post( $API_Endpoint, array(\n\t\t\t\t\t'timeout' => 60,\n\t\t\t\t\t'sslverify' => FALSE,\n\t\t\t\t\t'httpversion' => '1.1',\n\t\t\t\t\t'body' => $nvpreq\n\t\t\t )\n\t\t\t);\n\n\t\t\t$httpParsedResponseAr = array();\n\n\t\t\tif ( is_wp_error( $response ) ) {\n\t\t\t $error_message = $response->get_error_message();\n\t\t\t wp_die( \"{$methodName_} failed: $error_message\" );\n\t\t\t} else {\n\t\t\t\t//extract the response details\n\t\t\t\tparse_str(wp_remote_retrieve_body($response), $httpParsedResponseAr);\n\n\t\t\t\t//check for valid response\n\t\t\t\tif((0 == sizeof($httpParsedResponseAr)) || !array_key_exists('RESULT', $httpParsedResponseAr)) {\n\t\t\t\t\texit(\"Invalid HTTP Response for POST request($nvpreq) to $API_Endpoint.\");\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn $httpParsedResponseAr;\n\t\t}", "title": "" }, { "docid": "21e5d578cc5729eaee3f8854759f3c10", "score": "0.64246696", "text": "public function checkPostAnswer() {\n if ($_SERVER['HTTP_USER_AGENT'] === \"SMS Gateway Client (\" . $this->getProjectHolder() . \";\" . $this->getProjectName() . \"')\") {\n $return = new \\stdClass();\n $return->status = $_POST['status'];\n $return->id = $_POST['id'];\n return $return;\n } else {\n\n throw new myGatewayClientException(\"Post Answer Auth(Passiv) wasn't successfully\");\n }\n }", "title": "" }, { "docid": "d559a6290f513859effa5c35a7c2d95f", "score": "0.6384311", "text": "public function post_pass()\n {\n return $this->response->withStringBody(json_encode($this->request->getData()));\n }", "title": "" }, { "docid": "f68325b6cc5c84625f4f56beef144709", "score": "0.6369446", "text": "public function ppcBill(){\r\n\t\t\t$return = array('error'=>false,'message'=>'','data'=>array());\r\n\t\t\t$dir = dirname(__FILE__).'/../lib/svc/ppc_api.php';\r\n require_once $dir;\r\n\t\t\t$ppc = new PpcAPI();\r\n\t\t\tif($_SERVER['REQUEST_METHOD'] == 'POST') {\r\n\t\t\t\t$balanceCheck = array();\r\n\t\t\t\t$balanceDeduction = array();\t\r\n\t\t\t\t$balanceDeduction = $ppc->ppcOperation($_POST, PPC_REDEEM);\r\n\t\t\t\t$this->log->trace(\"PPC REDEEMING METHOD RESPONSE \\r\\n\".json_encode($balanceDeduction));\r\n\t\t\t\t$res = json_encode($balanceDeduction,true);\r\n\t\t\t\treturn $res;\r\n\t\t\t}\r\n\t\t}", "title": "" }, { "docid": "6f0d12c892c67ddd9ee93e1a62365325", "score": "0.63509893", "text": "public function getTransactionResponse();", "title": "" }, { "docid": "dcb8baf094eba236a170817c399bc399", "score": "0.6284368", "text": "function PP_HttpPost($methodName_, $nvpStr_,$API_UserName,$API_Password,$API_Signature,$API_Endpoint) {\n\t$API_UserName = urlencode($API_UserName);\n\t$API_Password = urlencode($API_Password);\n\t$API_Signature = urlencode($API_Signature);\n\t$version = urlencode(VERSION);\t\n\t// Set the API operation, version, and API signature in the request.\n\t$nvpreq = \"METHOD=$methodName_&VERSION=$version&PWD=$API_Password&USER=$API_UserName&SIGNATURE=$API_Signature$nvpStr_\";\n\n\t$ret = HP_SendPost($API_Endpoint, $nvpreq);\n\tif ($ret['error']) return $ret;\n\t// Get response from the server.\n\t$httpResponse = $ret['response'];\t\n\t// Extract the response details.\n\t$httpResponseAr = explode(\"&\", $httpResponse);\n\n\t$httpParsedResponseAr = array();\n\tforeach ($httpResponseAr as $i => $value) {\n\t\t$tmpAr = explode(\"=\", $value);\n\t\tif(sizeof($tmpAr) > 1) {\n\t\t\t$httpParsedResponseAr[$tmpAr[0]] = $tmpAr[1];\n\t\t}\n\t}\n\n\tif((0 == sizeof($httpParsedResponseAr)) || !array_key_exists('ACK', $httpParsedResponseAr)) {\n\t\t$ret['error'][] = \"Invalid HTTP Response for request to Paypal\";//exit(\"$methodName_ failed: \".curl_error($ch).'('.curl_errno($ch).')');\n\t\treturn $ret;\n\t\t//exit(\"Invalid HTTP Response for POST request($nvpreq) to $API_Endpoint.\");\n\t}\n\t$ret['paypal'] = $httpParsedResponseAr;\n\treturn $ret;\n}", "title": "" }, { "docid": "ce2da3c2eb6f79779d04cc5584eddce8", "score": "0.62783897", "text": "public function handleResponse(){\n // General defines\n define( 'PAYFAST_SERVER', 'LIVE' );\n // Whether to use \"sandbox\" test server or live server\n define( 'USER_AGENT', 'Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)' );\n // User Agent for cURL\n\n // Messages\n // Error\n define( 'PF_ERR_AMOUNT_MISMATCH', 'Amount mismatch' );\n define( 'PF_ERR_BAD_SOURCE_IP', 'Bad source IP address' );\n define( 'PF_ERR_CONNECT_FAILED', 'Failed to connect to PayFast' );\n define( 'PF_ERR_BAD_ACCESS', 'Bad access of page' );\n define( 'PF_ERR_INVALID_SIGNATURE', 'Security signature mismatch' );\n define( 'PF_ERR_CURL_ERROR', 'An error occurred executing cURL' );\n define( 'PF_ERR_INVALID_DATA', 'The data received is invalid' );\n define( 'PF_ERR_UKNOWN', 'Unkown error occurred' );\n\n // General\n define( 'PF_MSG_OK', 'Payment was successful' );\n define( 'PF_MSG_FAILED', 'Payment has failed' );\n\n\n // Notify PayFast that information has been received\n header( 'HTTP/1.0 200 OK' );\n flush();\n\n // Variable initialization\n $pfError = false;\n $pfErrMsg = '';\n $filename = 'notify.txt'; // DEBUG\n $output = ''; // DEBUG\n $pfParamString = '';\n $pfHost = ( PAYFAST_SERVER == 'LIVE' ) ?\n 'www.payfast.co.za' : 'sandbox.payfast.co.za';\n\n //// Dump the submitted variables and calculate security signature\n if( !$pfError )\n {\n $output = \"Posted Variables:\\n\\n\"; // DEBUG\n\n // Strip any slashes in data\n foreach( $_POST as $key => $val )\n $pfData[$key] = stripslashes( $val );\n $output .= $key.'='.stripslashes( $val ).'\\n\\n';\n\n // Dump the submitted variables and calculate security signature\n foreach( $pfData as $key => $val )\n {\n if( $key != 'signature' )\n $pfParamString .= $key .'='. urlencode( $val ) .'&';\n }\n\n // Remove the last '&' from the parameter string\n $pfParamString = substr( $pfParamString, 0, -1 );\n $signature = md5( $pfParamString );\n\n $result = ( $_POST['signature'] == $signature );\n\n $output .= \"Security Signature:\\n\\n\"; // DEBUG\n $output .= \"- posted = \". $_POST['signature'] .\"\\n\"; // DEBUG\n $output .= \"- calculated = \". $signature .\"\\n\"; // DEBUG\n $output .= \"- result = \". ( $result ? 'SUCCESS' : 'FAILURE' ) .\"\\n\"; // DEBUG\n }\n\n //// Verify source IP\n if( !$pfError )\n {\n $validHosts = array(\n 'www.payfast.co.za',\n 'sandbox.payfast.co.za',\n 'w1w.payfast.co.za',\n 'w2w.payfast.co.za',\n );\n\n $validIps = array();\n\n foreach( $validHosts as $pfHostname )\n {\n $ips = gethostbynamel( $pfHostname );\n\n if( $ips !== false )\n $validIps = array_merge( $validIps, $ips );\n }\n\n // Remove duplicates\n $validIps = array_unique( $validIps );\n\n if( !in_array( $_SERVER['REMOTE_ADDR'], $validIps ) )\n {\n $pfError = true;\n $pfErrMsg = PF_ERR_BAD_SOURCE_IP;\n }\n }\n\n //// Connect to server to validate data received\n if( !$pfError )\n {\n // Use cURL (If it's available)\n if( function_exists( 'curl_init' ) )\n {\n $output .= \"\\n\\nUsing cURL\\n\\n\"; // DEBUG\n\n // Create default cURL object\n $ch = curl_init();\n\n // Base settings\n $curlOpts = array(\n // Base options\n CURLOPT_USERAGENT => USER_AGENT, // Set user agent\n CURLOPT_RETURNTRANSFER => true, // Return output as string rather than outputting it\n CURLOPT_HEADER => false, // Don't include header in output\n CURLOPT_SSL_VERIFYHOST => true,\n CURLOPT_SSL_VERIFYPEER => false,\n\n // Standard settings\n CURLOPT_URL => 'https://'. $pfHost . '/eng/query/validate',\n CURLOPT_POST => true,\n CURLOPT_POSTFIELDS => $pfParamString,\n );\n curl_setopt_array( $ch, $curlOpts );\n\n // Execute CURL\n $res = curl_exec( $ch );\n curl_close( $ch );\n\n if( $res === false )\n {\n $pfError = true;\n $pfErrMsg = PF_ERR_CURL_ERROR;\n }\n }\n // Use fsockopen\n else\n {\n $output .= \"\\n\\nUsing fsockopen\\n\\n\"; // DEBUG\n\n // Construct Header\n $header = \"POST /eng/query/validate HTTP/1.0\\r\\n\";\n $header .= \"Host: \". $pfHost .\"\\r\\n\";\n $header .= \"Content-Type: application/x-www-form-urlencoded\\r\\n\";\n $header .= \"Content-Length: \" . strlen( $pfParamString ) . \"\\r\\n\\r\\n\";\n\n // Connect to server\n $socket = fsockopen( 'ssl://'. $pfHost, 443, $errno, $errstr, 10 );\n\n // Send command to server\n fputs( $socket, $header . $pfParamString );\n\n // Read the response from the server\n $res = '';\n $headerDone = false;\n\n while( !feof( $socket ) )\n {\n $line = fgets( $socket, 1024 );\n\n // Check if we are finished reading the header yet\n if( strcmp( $line, \"\\r\\n\" ) == 0 )\n {\n // read the header\n $headerDone = true;\n }\n // If header has been processed\n else if( $headerDone )\n {\n // Read the main response\n $res .= $line;\n }\n }\n }\n }\n\n //// Get data from server\n if( !$pfError )\n {\n // Parse the returned data\n $lines = explode( \"\\n\", $res );\n\n $output .= \"\\n\\nValidate response from server:\\n\\n\"; // DEBUG\n\n foreach( $lines as $line ) // DEBUG\n $output .= $line .\"\\n\"; // DEBUG\n }\n\n //// Interpret the response from server\n if( !$pfError )\n {\n // Get the response from PayFast (VALID or INVALID)\n $result = trim( $lines[0] );\n\n $output .= \"\\nResult = \". $result; // DEBUG\n\n // If the transaction was valid\n if( strcmp( $result, 'VALID' ) == 0 )\n {\n $sStatus = 'PAID';\n $id= $_REQUEST['m_payment_id'];\n $oDb = oxDb::getDb();\n $sQ = 'update oxorder set oxtransstatus='.$oDb->quote( $sStatus ).', OXPAID = \"'.date('Y-m-d h:i:s').'\" where oxid='.$oDb->quote( $id);\n $oDb->execute( $sQ );\n }\n // If the transaction was NOT valid\n else\n {\n // Log for investigation\n $pfError = true;\n $pfErrMsg = PF_ERR_INVALID_DATA;\n }\n }\n\n // If an error occurred\n if( $pfError )\n {\n $output .= \"\\n\\nAn error occurred!\";\n $output .= \"\\nError = \". $pfErrMsg;\n }\n\n //// Write output to file // DEBUG\n file_put_contents( $filename, $pfParamString.'test'.$output ); \n }", "title": "" }, { "docid": "705f92d755fb213977c02f44d73c692e", "score": "0.62756103", "text": "function post(){\n\t\t$database = new Database();\n\t\t$db = $database->getConnection();\n\t\t \n\t\t$order = new Order($db);\n\n\t\t$response_data = $order->create();\n\n\n\t\techo $response_data;\n\n\n\n\t}", "title": "" }, { "docid": "05283aef51fb321d7912d10d92cf5b6e", "score": "0.626039", "text": "public function responseAction()\n {\n $parameters = $this->getRequest()->getParams();\n $coHelper = Mage::helper('paybyfinance/checkout');\n $helper = Mage::helper('paybyfinance');\n $helper->log(\"Response: \\n\" . $helper->arrayDump($parameters), 'post');\n $order = null;\n\n if (array_key_exists('ro', $parameters)) {\n $order = Mage::getModel('sales/order')->load($parameters['ro'], 'increment_id');\n }\n\n // Unexpected error, PBF didn't send a correct order id (authentication error?)\n if (!$order) {\n $session = Mage::getSingleton('paybyfinance/session');\n $order = Mage::getModel('sales/order')->load($session->getData('order_id'));\n $coHelper->setUnexpectedError($order, $parameters);\n $redirectUrl = 'paybyfinance/status/error';\n } else {\n $redirectUrl = $coHelper->processReturnStatus($order, $parameters);\n }\n\n $this->_redirect($redirectUrl, array('order_id'=>$order->getId()));\n }", "title": "" }, { "docid": "258aca3deda4a57dba827e97c19e72a0", "score": "0.62144065", "text": "public function submitPayment()\n {\n return ['error' => 0, 'transactionReference' => ''];\n }", "title": "" }, { "docid": "49604f2545bbc4c909ac3f5d5120aca8", "score": "0.6185914", "text": "public function send() {\r\r\n\t\tLoader::load(dirname(__FILE__) . DS . \"post_api.php\");\r\r\n\t\t$util = new PostApi();\r\r\n\t\treturn $util->send($this->getEDP_Url(), $this->getToken());\r\r\n }", "title": "" }, { "docid": "e664bfedc52193faba4fe613284aabc6", "score": "0.6177445", "text": "public function payReceived() {\n\n // Data was passed in a Post\n $request = $this->request->getCurrentRequest();\n $results = $request->request->all();\n \n $this->getLogger('rusa_perm_reg')->notice('Perm program payment post received');\n \n // This is the data we should receive\n $regid = $results['regid'];\n // $mid = $results['mid']; We don't actually need this\n \n if (empty($regid)) {\n // Log an error message\n $this->getLogger('rusa_perm_reg')->error('Perm program payment missing parameter regid %regid',['%regid' => $regid]);\n } \n else {\n // Load the registration entity which was passed back to us in $regid\n $storage = $this->entityTypeManager->getStorage('rusa_perm_registration');\n $reg = $storage->load($regid); \n\n // Set the payment received boolean and the date\n $reg->set('field_payment_received', TRUE);\n $reg->set('field_date_payment_received', date('Y-m-d', time()));\n $reg->save();\n }\n return ['#markup' => 'Payment posted to perm program registration # ' . $regid];\n //return $this->redirect('rusa_perm.reg',['user' => $this->currentUser->id()]); \n\t}", "title": "" }, { "docid": "fd14281b537023e71122db79dbc58d91", "score": "0.61618185", "text": "public function GetResponse()\n {\n //Initialize a curl session \n $ch = curl_init();\n\n //Prepare for an HTTP REQUEST \n curl_setopt($ch, CURLOPT_POST, 1);\n\n //Prepare the request to be POSTed \n curl_setopt($ch, CURLOPT_POSTFIELDS, rtrim($this->$_mRequest, '& '));\n\n //Set the url where we want to POST our data \n curl_setopt($ch, CURLOPT_URL, $this->$_mUrl);\n\n //Do not verify the common name of the peer certificate in the SSL handshake;\n curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);\n\n //We wnat curl to directly return the transfer instead of print it \n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\n //Perform a cURL session \n $result = curl_exec($ch);\n\n //Close the cURL session \n curl_close($ch);\n\n //Return the response \n return $result;\n\n }", "title": "" }, { "docid": "21e6a2ef3f0d038038647d75f1623c43", "score": "0.61577976", "text": "function user_post()\n {\n //$this->response($data);\n var_dump($this->post());\n }", "title": "" }, { "docid": "891dfb41726d108fc1bd0f610c594448", "score": "0.6141261", "text": "public function getResponse();", "title": "" }, { "docid": "891dfb41726d108fc1bd0f610c594448", "score": "0.6141261", "text": "public function getResponse();", "title": "" }, { "docid": "891dfb41726d108fc1bd0f610c594448", "score": "0.6141261", "text": "public function getResponse();", "title": "" }, { "docid": "891dfb41726d108fc1bd0f610c594448", "score": "0.6141261", "text": "public function getResponse();", "title": "" }, { "docid": "891dfb41726d108fc1bd0f610c594448", "score": "0.6141261", "text": "public function getResponse();", "title": "" }, { "docid": "891dfb41726d108fc1bd0f610c594448", "score": "0.6141261", "text": "public function getResponse();", "title": "" }, { "docid": "891dfb41726d108fc1bd0f610c594448", "score": "0.6141261", "text": "public function getResponse();", "title": "" }, { "docid": "891dfb41726d108fc1bd0f610c594448", "score": "0.6141261", "text": "public function getResponse();", "title": "" }, { "docid": "891dfb41726d108fc1bd0f610c594448", "score": "0.6141261", "text": "public function getResponse();", "title": "" }, { "docid": "c2fb4f775122de9b45d11d11ed4775e6", "score": "0.61081594", "text": "public function response()\n {\n\t\t$obj = new \\AWLMEAPI();\n\t\t\n\t\t/* This is the response Object */\n\t\t$resMsgDTO = new \\ResMsgDTO();\n\n\t\t/* This is the request Object */\n\t\t$reqMsgDTO = new \\ReqMsgDTO();\n\t\t\n\t\t//This is the Merchant Key that is used for decryption also\n\t\t$enc_key = '6375b97b954b37f956966977e5753ee6';\n\t\t\n\t\t/* Get the Response from the WorldLine */\n\t\t$responseMerchant = $_REQUEST['merchantResponse'];\n\t\t\n\t\t$response = $obj->parseTrnResMsg( $responseMerchant , $enc_key );\n\t\t$jsonData = json_encode($response);\n\t\t$status = $response->getStatusCode();\n\t\tif($status == 'S')\n\t\t{\n\t\t\t$order_id = $response->getOrderId();\n\t\t\t$transaction_id = $response->getPgMeTrnRefNo();\n\t\t\t$amount = $response->getTrnAmt();\n\t\t\t$transaction_date = $response->getTrnReqDate();\n\t\t}\n\t\treturn view('client/payments/errors');\n }", "title": "" }, { "docid": "4aa454aeb1a82e526c345ba4b19128a4", "score": "0.6100437", "text": "public function post() {\n\t\treturn $this->post;\n\t}", "title": "" }, { "docid": "3f587a341e3f70c4e6c0aa49a30d84c7", "score": "0.6097843", "text": "private function handlePostRequest()\n {\n // first fetch the csrf-token\n $this->fetchCsrfToken();\n \n // read the POST data sent by the form\n $requestBody = @file_get_contents(\"php://input\");\n $requestData = json_decode($requestBody);\n \n // optional: enhance the request data with the IP address for tracking purposes\n $requestData->IpAddress = $_SERVER[\"REMOTE_ADDR\"];\n \n // optional: add the campaign id to connect all form interactions to your campaign\n // $requestData->CampaignId = \"your-campaign-id\";\n \n // send the prepared request data to the system\n $requestString = json_encode($requestData);\n $response = $this->sendHttpRequest(\"POST\", $this::BASE_PATH . $this::RESULT_HEADERS_PATH, $requestString);\n \n // print the response\n echo $response;\n }", "title": "" }, { "docid": "866ac060ef3abd0019265a663d36aaf4", "score": "0.6085681", "text": "public function post();", "title": "" }, { "docid": "b15d611fca2b2e41528c2530c43b2d9e", "score": "0.6076414", "text": "public function sendpost(){\n\t$url = 'http://wcsc02.ad.ydesigngroup.com/login';\n\t$data = array('username' => 'sudarsan', 'password' => '5e884898da28047151d0e56f8dc6292773603d0d6aabbdd62a11ef721d1542d8');\n\t// use key 'http' even if you send the request to https://...\n\t$options = array(\n\t 'http' => array(\n\t 'header' => \"Content-type: application/json\\n\",\n\t 'method' => 'POST',\n\t 'content' => json_encode($data),\n\t ),\n\t);\n \t$context = stream_context_create($options);\n\t$result = file_get_contents($url, false, $context);\n\tif ($result === FALSE) { /* Handle error */ }\n\n\tvar_dump($result);\n\treturn new JsonResponse (null);\n }", "title": "" }, { "docid": "87b73f0bcd496f145ab8833d52135ff4", "score": "0.60583663", "text": "public function generate_post()\n {\n // Invalid request, set the response and exit.\n $this->response([\n 'status' => FALSE,\n 'message' => 'Bad Request'\n ], REST_Controller::HTTP_BAD_REQUEST); // BAD_REQUEST (400) being the HTTP response code\n return ;\n }", "title": "" }, { "docid": "3635bb8686d3a97da994dbb0b864939e", "score": "0.60515994", "text": "public function responseMsg() {\n $postStr = $GLOBALS[\"HTTP_RAW_POST_DATA\"];\n\n //extract post data\n if (!empty($postStr)){\n $postObj = simplexml_load_string($postStr, 'SimpleXMLElement', LIBXML_NOCDATA);\n return $postObj;\n } else {\n return FALSE;\n }\n }", "title": "" }, { "docid": "290c829f790b3518bfd6cd68f5085751", "score": "0.6007445", "text": "public function signup_post()\n\t{\n\t\t$data = array();\n\t\t$data[ getSysConfig( \"rest_response_field_name\" ) ] = cmn_vw_signup();\n\t\n\t\t$data[ getSysConfig( \"rest_status_field_name\" ) ] = \"success\";\n\t\t$data[ getSysConfig( \"rest_message_field_name\" ) ] = \"\";\n\t\t$this->response( $data, 200 );\n\t}", "title": "" }, { "docid": "9a340f06f374d46888e57cacca776bed", "score": "0.5962447", "text": "function PayUser($recieve_address,$amount,$currency)\r\n{\r\n global $kswallet_api;\r\n\r\n $url = \"https://www.kswallet.net/api/send?\";\r\n\r\n //The data you want to send via POST\r\n $fields = [\r\n 'api_key' => $kswallet_api,\r\n 'to' => $recieve_address,\r\n 'amount' => $amount,\r\n 'c' => $currency,\r\n ];\r\n //url-ify the data for the POST\r\n $fields_string = http_build_query($fields);\r\n\r\n //open connection\r\n $ch = curl_init();\r\n //set the url, number of POST vars, POST data\r\n curl_setopt($ch,CURLOPT_URL, $url);\r\n curl_setopt($ch,CURLOPT_POST, true);\r\n curl_setopt($ch,CURLOPT_POSTFIELDS, $fields_string);\r\n //So that curl_exec returns the contents of the cURL; rather than echoing it\r\n curl_setopt($ch,CURLOPT_RETURNTRANSFER, true); \r\n //execute post\r\n $result = curl_exec($ch);\r\n $result = json_decode($result, true);\r\n if ($result[\"status\"] == 200) {\r\n return $result[\"status\"];\r\n }\r\n return $result[\"message2\"];\r\n}", "title": "" }, { "docid": "297f3bc1b74277b16dc3763665464167", "score": "0.59584033", "text": "function check_unionpay_response() {\n\n if (empty($_POST)) {\n wp_die(\"Invalid Requirements\");\n }\n\n if (!$this->verify_response($_POST)){\n $this->log('Unionpay response verify faild! post:'.json_encode($_POST));\n wp_die(\"Invalid Requirements\");\n }\n\n $orderId = substr($_POST['orderId'], 14, strlen($_POST['orderId']));\n $order = new WC_Order($orderId);\n if( $order->status != 'completed'){\n $order->payment_complete();\n $order->add_order_note ('支付成功');\n update_post_meta( $orderId, 'Unionpay Trade No.', wc_clean( $_POST['queryId'] ) );\n $this->log('Payment Completed! Order ID: ' . $orderId . 'date:' . json_encode($_POST), 'Info');\n header( 'HTTP/1.1 200 OK' );\n echo \"Success\";\n exit;\n }\n\n }", "title": "" }, { "docid": "cd54564a4e2b30c9bf2cb2f19cf16336", "score": "0.5955784", "text": "function dumpResponse() {\n // names and the values returned for the payment submission. This should\n // be called AFTER the process() function has been called to view details\n // about eway's response.\n \n echo \"<h3>eway_class->dump_response() Output:</h3>\";\n echo \"<table width=\\\"95%\\\" border=\\\"1\\\" cellpadding=\\\"2\\\" cellspacing=\\\"0\\\">\n <tr>\n <td bgcolor=\\\"black\\\"><b><font color=\\\"white\\\">Index&nbsp;</font></b></td>\n <td bgcolor=\\\"black\\\"><b><font color=\\\"white\\\">Field Name</font></b></td>\n <td bgcolor=\\\"black\\\"><b><font color=\\\"white\\\">Value</font></b></td>\n </tr>\";\n \n $i = 0;\n foreach ($this->response as $key => $value) {\n echo \"<tr>\n <td valign=\\\"top\\\" align=\\\"center\\\">$i</td>\n <td valign=\\\"top\\\">$key</td>\n <td valign=\\\"top\\\">$value&nbsp;</td>\n </tr>\";\n $i++;\n } \n echo \"</table><br>\";\n }", "title": "" }, { "docid": "6979fecdbe13eba8f4243816ec7b06fb", "score": "0.59539425", "text": "public function getResponse(){\n \n return $this->response;\n \n }", "title": "" }, { "docid": "7f5756c8b63110d6bf3934b89b120846", "score": "0.5951952", "text": "public function getResponse()\n {\n $response = new stdClass();\n $params = $this->getPaymentReturnFields();\n\n //TODO: SOLOPMT_RETURN_PAID\n\n if($this->checkSignature($params)){\n $response->result = 'success';\n $response->amount = $params['SOLOPMT_AMOUNT'];\n } else {\n\n $response->result = 'canceled';\n $response->amount = 0;\n\n }\n\n $response->stamp = $params['SOLOPMT_STAMP'];\n $response->referenceNr = $params['SOLOPMT_RETURN_REF'];\n $response->message = $params['SOLOPMT_MSG'];\n $response->isAutomaticResponse= false;\n\n return $response;\n }", "title": "" }, { "docid": "96eaef1eb424f27ede5b83f2f306f72b", "score": "0.59459794", "text": "public function getBackendResult()\n {\n if (count($_POST) == 0 or ! isset($_POST['payment_id']))\n {\n return false;\n }\n\n $paymentId = $_POST['payment_id'];\n\n $requestUrl = $this->_gatewayEnquiryUrl.'/'.$paymentId;\n\n $options = array(\n CURLOPT_HTTPHEADER => array(\n 'Content-Type: application/json',\n 'Content-Length: 0',\n 'Authorization:Bearer ' . $this->_bearer\n )\n );\n\n $data = $this->makeRequest($requestUrl, null, $options, 'GET');\n\n $response = json_decode($data['response'], true);\n\n $paymentInfo = $response['payment_info'];\n $paymentResult = $response['payment_result'];\n\n $amount = $paymentResult['paid_amount'];\n $invoice = $paymentResult['request_id'];\n $currency = $paymentInfo['currency'];\n\n $result = array(\n 'status' => true,\n 'data' => array(\n 'gateway' => self::GATEWAY,\n 'status' => $this->mapStatusReturned($paymentResult['payment_result_status']),\n 'invoice' => $invoice,\n 'currency' => $currency,\n 'amount' => $amount,\n 'dump' => json_encode($data)\n ),\n 'custom' => array(\n 'recheck' => \"yes\"\n )\n );\n\n return $result;\n }", "title": "" }, { "docid": "13e2ac6272bfb0e63f9dd92f2992bd3f", "score": "0.5943706", "text": "function PPHttpPost($methodName_, $nvpStr_) {\r\n global $__SITE;\r\n $siteObj = $__SITE;\r\n\r\n\t$version = '60.0';\r\n\t$live = $_SESSION['live'] || $_SESSION['live_payments_test'];\r\n\t//$live = 1;\r\n $API_UserName = get_config(($live ? \"ppu\" : \"pput\"), $siteObj->id);\r\n $API_Password = get_config(($live ? \"ppp\" : \"pppt\"), $siteObj->id);\r\n $API_Signature = get_config(($live ? \"pps\" : \"ppst\"), $siteObj->id);\r\n $API_Endpoint = get_config(($live ? \"ppe\" : \"ppet\"), $siteObj->id);\r\n\r\n //echo(\"sl=\".$_SESSION['live'].html_break());\r\n //echo(\"tp=\".$_SESSION['live_payments_test'].html_break());\r\n //die(\"live=$live user=$API_UserName Endpoint=$API_Endpoint\");\r\n \r\n\t// Set the API operation, version, and API signature in the request.\r\n\t$nvpreq = \"METHOD=$methodName_&VERSION=\".urlencode($version).\"&PWD=\".\r\n\t urlencode($API_Password).\"&USER=\".urlencode($API_UserName).\"&SIGNATURE=\".urlencode($API_Signature).\"$nvpStr_\";\r\n //echo($nvpreq);\r\n\r\n $httpResponse = http_post($API_Endpoint, $nvpreq);\r\n $now = now();\r\n print_log(\"http_post: $now: $API_Endpoint\", \"paypal\", LOG_LEVEL_ALWAYS);\r\n //print_log($nvpreq, \"paypal\", LOG_LEVEL_ALWAYS);\r\n print_log($httpResponse, \"paypal\", LOG_LEVEL_ALWAYS);\r\n \r\n\t// Extract the response details.\r\n\t$httpResponseAr = explode(\"&\", $httpResponse);\r\n\r\n\t$httpParsedResponseAr = array();\r\n\tforeach ($httpResponseAr as $i => $value) {\r\n\t\t$tmpAr = explode(\"=\", $value);\r\n\t\tif(sizeof($tmpAr) > 1) {\r\n\t\t\t$httpParsedResponseAr[$tmpAr[0]] = urldecode($tmpAr[1]);\r\n\t\t}\r\n\t}\r\n\r\n\tif((0 == sizeof($httpParsedResponseAr)) || !array_key_exists('ACK', $httpParsedResponseAr)) {\r\n\t\texit(\"Invalid HTTP Response for POST request($nvpreq) to $API_Endpoint.\");\r\n\t}\r\n\r\n if($dev && $methodName_ != 'SetExpressCheckout') {\r\n //echo(\"Sent method $methodName_ to $API_Endpoint:<br />$nvpreq<br />Result = $httpParsedResponseAr[ACK] <hr />\");\r\n //dump($httpParsedResponseAr);\r\n }\r\n\treturn $httpParsedResponseAr;\r\n}", "title": "" }, { "docid": "bba8c8540751463fbd97ca661f48900b", "score": "0.594252", "text": "public function getPostData() {\n\t\treturn $this->getBody();\n\t}", "title": "" }, { "docid": "420e6eb0f6a2a5781d3e2386b7a8f558", "score": "0.59301287", "text": "public function response() {\r\r\n $this->debugPrint(print_r($this->response, true), 3);\r\r\n return $this->response;\r\r\n }", "title": "" }, { "docid": "df9bf15ba346c8f040e000167049e67b", "score": "0.59234506", "text": "function getResponse() { return $this->response; }", "title": "" }, { "docid": "a560ac5ec769eff15c29e95e6c86b331", "score": "0.5920885", "text": "public function getResponse() {\n\t\treturn $this->json_unescaped_encode(array('result' => $this->status, 'response'=> $this->response));\n\t}", "title": "" }, { "docid": "acda45a1b2e9293edff11a6b4eef709e", "score": "0.59086716", "text": "public function responseAction()\n {\n echo Mage::helper('ecpaypayment')->getPaymentResult();\n exit;\n }", "title": "" }, { "docid": "744e8981bd034abd136ca6b4b4e84286", "score": "0.5907609", "text": "public function getResponse()\n {\n return $this->body;\n }", "title": "" }, { "docid": "7d912a52201225638330cc19c684eca4", "score": "0.58995825", "text": "public function forgot_post()\n\t{\n\t\t$data = array();\n\t\t$data[ getSysConfig( \"rest_response_field_name\" ) ] = cmn_vw_forgot();\n\t\n\t\t$data[ getSysConfig( \"rest_status_field_name\" ) ] = \"success\";\n\t\t$data[ getSysConfig( \"rest_message_field_name\" ) ] = \"\";\n\t\t$this->response( $data, 200 );\n\t}", "title": "" }, { "docid": "12ff377cfa79ea5a3c3373e4c5543869", "score": "0.5898124", "text": "function PPHttpPost($methodName_, $nvpStr_)\r\n{\r\n\t$API_UserName = urlencode(PAYPAL_APIID);\r\n\t$API_Password = urlencode(PAYPAL_PASS);\r\n\t$API_Signature = urlencode(PAYPAL_SIG);\r\n\t$API_Endpoint = \"https://api-3t.paypal.com/nvp\";\r\n\tif(\"sandbox\" === $this->environment || \"beta-sandbox\" === $this->environment) {\r\n\t\t$API_Endpoint = \"https://api-3t.$this->environment.paypal.com/nvp\";\r\n\t}\r\n\t$version = urlencode('74.0');\r\n \r\n\t// Set the curl parameters.\r\n\t$ch = curl_init();\r\n\tcurl_setopt($ch, CURLOPT_URL, $API_Endpoint);\r\n\tcurl_setopt($ch, CURLOPT_VERBOSE, 1);\r\n \r\n\t// Turn off the server and peer verification (TrustManager Concept).\r\n\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);\r\n\tcurl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE);\r\n \r\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\r\n\tcurl_setopt($ch, CURLOPT_POST, 1);\r\n \r\n\t// Set the API operation, version, and API signature in the request.\r\n\t$nvpreq = \"METHOD=$methodName_&VERSION=$version&PWD=$API_Password&USER=$API_UserName&SIGNATURE=$API_Signature$nvpStr_\";\r\n \r\n\t// Set the request as a POST FIELD for curl.\r\n\tcurl_setopt($ch, CURLOPT_POSTFIELDS, $nvpreq);\r\n \r\n\t// Get response from the server.\r\n\t$httpResponse = curl_exec($ch);\r\n \r\n\tif(!$httpResponse) {\r\n\t\texit(\"$methodName_ failed: \".curl_error($ch).'('.curl_errno($ch).')');\r\n\t}\r\n \r\n\t// Extract the response details.\r\n\t$httpResponseAr = explode(\"&\", $httpResponse);\r\n \r\n\t$httpParsedResponseAr = array();\r\n\tforeach ($httpResponseAr as $i => $value) {\r\n\t\t$tmpAr = explode(\"=\", $value);\r\n\t\tif(sizeof($tmpAr) > 1) {\r\n\t\t\t$httpParsedResponseAr[$tmpAr[0]] = $tmpAr[1];\r\n\t\t}\r\n\t}\r\n \r\n\tif((0 == sizeof($httpParsedResponseAr)) || !array_key_exists('ACK', $httpParsedResponseAr)) {\r\n\t\texit(\"Invalid HTTP Response for POST request($nvpreq) to $API_Endpoint.\");\r\n\t}\r\n \r\n\treturn $httpParsedResponseAr;\r\n}", "title": "" }, { "docid": "9649791f4e6cf3fb8e1eeb41b6d2a5fa", "score": "0.5891237", "text": "public function getResponseMessage () {}", "title": "" }, { "docid": "e10f7105dc3f0577e5b3cbc7b0bd2ddb", "score": "0.58900094", "text": "public function postTest(){\n $response = new Response();\n $response->contentType = \"application/json\";\n $response->body = json_encode(array(\"Id\"=>\"1\", \"Nombre\"=>\"Sheldon\"));\n $response->code = Response::CREATED;\n return $response;\n }", "title": "" }, { "docid": "e67cde2654a9e76bd7b04f11412fd9d9", "score": "0.588686", "text": "public function getResponse()\n { \n return \\Utm\\Core::instance()->getResponse();\n }", "title": "" }, { "docid": "15cc2edb8303259eb2da180d38032378", "score": "0.5883681", "text": "public function send()\n {\n //Store in database\n $payment = new Payment();\n $payment->value = 30;\n $payment->status = 'pending';\n $payment->insert();\n\n //Send to gateway\n $url = 'http://localhost/webhook/gateway/public/receive';\n $content = json_encode([\n 'value' => $payment->value,\n 'refid' => $payment->id,\n ]);\n\n $curl = curl_init($url);\n curl_setopt($curl, CURLOPT_HEADER, false);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($curl, CURLOPT_HTTPHEADER,\n array(\"Content-type: application/json\"));\n curl_setopt($curl, CURLOPT_POST, true);\n curl_setopt($curl, CURLOPT_POSTFIELDS, $content);\n\n $json_response = curl_exec($curl);\n\n $status = curl_getinfo($curl, CURLINFO_HTTP_CODE);\n curl_close($curl);\n\n //region redirect\n $response = new Response();\n $response->addHeader('location', 'http://localhost/webhook/store/public/checkout/sent');\n\n return $response;\n //endregion\n }", "title": "" }, { "docid": "7194842a9df13d8771b5845703e9e9c2", "score": "0.58791596", "text": "public function getResponse()\n {\n return $this->_body;\n }", "title": "" }, { "docid": "27de47c81997128a934b60bae27b459d", "score": "0.5854798", "text": "function PPHttpPost($methodName_, $nvpStr_) {\n\tglobal $environment;\n \n\t// Set up API credentials, PayPal end point, and API version.\n\t$API_UserName = urlencode('CREDENTIALS REMOVED');\n\t$API_Password = urlencode('CREDENTIALS REMOVED');\n\t$API_Signature = urlencode('CREDENTIALS REMOVED');\n\t$API_Endpoint = \"https://api-3t.paypal.com/nvp\";\n\tif(\"sandbox\" === $environment || \"beta-sandbox\" === $environment) {\n\t\t$API_Endpoint = \"https://api-3t.$environment.paypal.com/nvp\";\n\t}\n\t$version = urlencode('51.0');\n \n\t// Set the curl parameters.\n\t$ch = curl_init();\n\tcurl_setopt($ch, CURLOPT_URL, $API_Endpoint);\n\tcurl_setopt($ch, CURLOPT_VERBOSE, 1);\n \n\t// Turn off the server and peer verification (TrustManager Concept).\n\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);\n\tcurl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE);\n \n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\tcurl_setopt($ch, CURLOPT_POST, 1);\n \n\t// Set the API operation, version, and API signature in the request.\n\t$nvpreq = \"METHOD=$methodName_&VERSION=$version&PWD=$API_Password&USER=$API_UserName&SIGNATURE=$API_Signature$nvpStr_\";\n \n\t// Set the request as a POST FIELD for curl.\n\tcurl_setopt($ch, CURLOPT_POSTFIELDS, $nvpreq);\n \n\t// Get response from the server.\n\t$httpResponse = curl_exec($ch);\n \n\tif(!$httpResponse) {\n\t\texit(\"$methodName_ failed: \".curl_error($ch).'('.curl_errno($ch).')');\n\t}\n \n\t// Extract the response details.\n\t$httpResponseAr = explode(\"&\", $httpResponse);\n \n\t$httpParsedResponseAr = array();\n\tforeach ($httpResponseAr as $i => $value) {\n\t\t$tmpAr = explode(\"=\", $value);\n\t\tif(sizeof($tmpAr) > 1) {\n\t\t\t$httpParsedResponseAr[$tmpAr[0]] = urldecode($tmpAr[1]);\n\t\t}\n\t}\n \n\tif((0 == sizeof($httpParsedResponseAr)) || !array_key_exists('ACK', $httpParsedResponseAr)) {\n\t\texit(\"Invalid HTTP Response for POST request($nvpreq) to $API_Endpoint.\");\n\t}\n \n\treturn $httpParsedResponseAr;\n}", "title": "" }, { "docid": "317b986567e80d5697f7c11da37d04fa", "score": "0.58535635", "text": "public function callResponseAction()\n {\n $mandataireManager = $this->get('apr_mandataire.mandataire_manager');\n $paymentsManager = $this->get('apr_mandataire.payments_manager');\n\n $keyfile = $this->container->getParameter('paybox.keyfile');\n\n $request = $this->getRequest();\n\n $amount = $request->get('Amount')/100;\n $reference = $request->get('Ref');\n // Récupération du timestamp ...\n $arr = explode(\"-\", $reference, 2);\n $idMandataire = $arr[0];\n $timestamp = $arr[1];\n\n $auto = $request->get('Auto');\n $error = $request->get('Error');\n if($error == \"00000\") {\n $first = strpos($_SERVER['REQUEST_URI'],'?');\t\t\t// recherche le ?\n $qrystr = substr($_SERVER['REQUEST_URI'], $first+1);\n\n $CheckSig = $this->PbxVerSign($qrystr, $keyfile);\n\n if( $CheckSig == 1 ) {\n $emails = array();\n $mandataire = $mandataireManager->loadMandataireById($idMandataire);\n $payment = $paymentsManager->createPayment($mandataire, 'CB', $amount, $timestamp.\"#\".$auto);\n if(!is_null($payment)) {\n $paymentsManager->validatePayment($mandataire, $payment, $emails);\n\n if (!empty($emails)) {\n $mailsManager = $this->get('apr_user.mailer');\n $mailsManager->sendMails($emails);\n }\n }\n }\n else if( $CheckSig == 0 ) {\n // Signature invalide : donnees alterees ou signature falsifiee\n }\n else {\n // Erreur lors de la vérification de la signature\n }\n\n }\n\n return new JsonResponse(true);\n }", "title": "" }, { "docid": "a660335d8d7ca8e9700e25fe3945b026", "score": "0.58516407", "text": "public function getResponse() {\n return $this->response;\n }", "title": "" }, { "docid": "aa8d7504d38c4a97e5bb06752e812823", "score": "0.5840918", "text": "public function response(){\n if($this->validate($request, $response)){\n return $response;\n } else{\n $error = array(\n 'Error' => 'Transacción ' . $this->status[1],\n 'Detail' => 'Error de validación de firma'\n );\n return $error;\n }\n }", "title": "" }, { "docid": "9c9d0a3c615c6aa6fe0f2b109ebb7644", "score": "0.5838584", "text": "public function getResponse()\n {\n }", "title": "" }, { "docid": "9c9d0a3c615c6aa6fe0f2b109ebb7644", "score": "0.5838584", "text": "public function getResponse()\n {\n }", "title": "" }, { "docid": "04d5b14edefde228765d11aad29bc966", "score": "0.58193547", "text": "public function getPostData();", "title": "" }, { "docid": "c1c86cb596691a40a10027b581e58bb5", "score": "0.58179307", "text": "abstract public function getResponse();", "title": "" }, { "docid": "448ba401817498e580fb8baee6c8bb86", "score": "0.5815763", "text": "public function post() {}", "title": "" }, { "docid": "9bc8c3b9305c55c89b3c131583e7d74b", "score": "0.58136386", "text": "public function getResponse ()\n {\n $this->connect($this->getMethod());\n if ($this->_response == null) {\n $this->_response = '{\"status\":\"error\",\n \"results\":[],\n \"error\":{\"message\":\n \"Pro6PP validation service is unavailable at this time\"}}';\n }\n return $this->_response;\n }", "title": "" }, { "docid": "e2aeb096119f572c8c688bb0d2ab19e2", "score": "0.5808482", "text": "function empleados_post()\n {\n // return data = echo format_response($data);\n }", "title": "" }, { "docid": "73819e917fb0d3af07eb48fdde6b68f9", "score": "0.58040106", "text": "public function sendPost()\r\n {\r\n $this->setCurlOption(CURLOPT_URL, $this->url);\r\n $this->setCurlOption(CURLOPT_POST, 1);\r\n $this->setCurlOption(CURLOPT_POSTFIELDS, http_build_query($this->data));\r\n return $this->exec();\r\n }", "title": "" }, { "docid": "43160a4555a409db58e0b02309f7aaed", "score": "0.5788846", "text": "public function getPostUrl()\n\t{\n\t\treturn $this->getUrl(self::RESPONSE_URL_PATH_POST, array('_secure' => true));\n\t}", "title": "" }, { "docid": "3c66d4fefbd7931c35ee757787a72af3", "score": "0.5787624", "text": "public function actionPost()\r\n\t{\r\n\t\t$params = $_POST;\r\n\t\tif (empty($params['username'])){\r\n\t\t\tCommonFn::formatReturn(201,\"登录账户不能为空\");\r\n\t\t}\r\n\t\t$params['contract_date'] = $params['contract_date'] ? strtotime($params['contract_date']) : 0;\r\n\t\t$params['contract_deadline'] = $params['contract_deadline'] ? strtotime($params['contract_deadline']) : 0;\r\n\t\t$_id = MerchantService::insertUpdateFromPost($params);\r\n\t\t$rt_info = array(\r\n\t\t\t\"id\" => $_id,\r\n\t\t\t\"reload_url\"\t=>\t\"\"\r\n\t\t);\r\n\t\t$rt_info['info'] = $info;\r\n\t\tCommonFn::formatReturn(0, '', $rt_info);\r\n\t}", "title": "" }, { "docid": "0cb3b4f4da86b83c63c47f2c84f67def", "score": "0.5770347", "text": "public abstract function getResponse();", "title": "" }, { "docid": "cbe7bb5739a26bf82c2665c339c99171", "score": "0.57609797", "text": "public function getResponseMessage();", "title": "" }, { "docid": "321b879dd2e9435e999ae9099b4cf293", "score": "0.5747653", "text": "function applyCoupon_post()\n\t{\n\t\t$data = array();\n\t\t$data[ getSysConfig( \"rest_response_field_name\" ) ] = cmn_vw_applyCoupon();\n\t\t\t\n\t\t$data[ getSysConfig( \"rest_status_field_name\" ) ] = \"success\";\n\t\t$data[ getSysConfig( \"rest_message_field_name\" ) ] = \"\";\n\t\t$this->response( $data, 200 );\n\t}", "title": "" }, { "docid": "76540d764718666ecf7ece4ee7f6a244", "score": "0.57373244", "text": "public function pdt_return_handler() {\r\n $posted = stripslashes_deep( $_REQUEST );\r\n // echo \"<pre>\";print_r($posted);echo \"</pre>\";\r\n /*\r\n [key] => wc_order_59f00fac7fa77\r\n [error_message] =>\r\n [processor-tx-id] => PNTEST-12023\r\n [merchant_order] => 25991\r\n [orderid] => 12023\r\n [client_orderid] => 25991\r\n [bin] => 444455\r\n [control] => ace0a3e586a98be9907a1f4bc62d3701d7725e35\r\n [gate-partial-reversal] => enabled\r\n [descriptor] => test-evro-eur 3D\r\n [gate-partial-capture] => enabled\r\n [type] => sale\r\n [card-type] => VISA\r\n [phone] => 79265766710\r\n [last-four-digits] => 1111\r\n [card-holder-name] => VLADIMIR BUSHUEV\r\n [status] => approved\r\n */\r\n $order = new WC_Order( $posted['client_orderid']);\r\n switch($posted['status']){\r\n case 'approved':{\r\n\r\n update_post_meta( $order->id, 'Transaction ID', wc_clean( $posted['orderid'] ) );\r\n $order->add_order_note( __( 'PaynetEasy payment completed', 'woocommerce' ) );\r\n $order->update_status( 'processing', sprintf( __( 'Payment success', 'woocommerce' ) ) );\r\n $order->payment_complete();\r\n\r\n return true;\r\n }break;\r\n }\r\n\t\treturn false;\r\n\t}", "title": "" }, { "docid": "23997e04f3e01234701fb0c0f92a7249", "score": "0.5736077", "text": "function getResponse()\n {\n return $this->message->params[0];\n }", "title": "" }, { "docid": "0ad5b8fc56849fea278ba6dc14012439", "score": "0.5732569", "text": "public function createSuccess() {\n // var_dump($response);\n }", "title": "" }, { "docid": "c3e704a97f4bd03eeb9f2960c99181c3", "score": "0.57325536", "text": "public function sendMoney()\n {\n $curl = curl_init();\n curl_setopt_array($curl, array(\n 'CURLOPT_URL', \"http://pay.npontu.com/api/pay\",\n 'CURLOPT_RETURNTRANSFER', 1,\n 'CURLOPT_POST', 1,\n 'CURLOPT_POSTFIELDS', array(\n \"amt\", \"2\",\n \"number\",\"0547787834\",\n \"uid\",\"ashesi\",\n \"pass\",\"ashesi\",\n \"tp\",\"001\",\n \"trans_type\",\"debit\",\n \"msg\",\"test1\",\n \"vendor\",\"MTN\",\n \"cbk\",\"http://gmpay.npontu.com/api/tigo\"\n )\n ));\n\n $response = curl_exec($curl);\n return $response;\n var_dump($response);\n\n curl_close($curl);\n\n }", "title": "" }, { "docid": "ddd769c4e5468c9c6fb8c988cdefb33a", "score": "0.57069254", "text": "public function getResponse() {\n return $this->response;\n }", "title": "" }, { "docid": "3103f5c9074a8a513c9b23aca485d5b7", "score": "0.57029927", "text": "public function responseMsg()\n {\n $postStr = $GLOBALS[\"HTTP_RAW_POST_DATA\"];\n //extract post data\n if (!empty($postStr)){\n \n $postObj = simplexml_load_string($postStr, 'SimpleXMLElement', LIBXML_NOCDATA);\n $RX_TYPE = trim($postObj->MsgType);\n //echo json_encode($postObj);\n //echo var_dump($postObj);\n switch($RX_TYPE)\n {\n case \"text\":\n $resultStr = $this->handleText($postObj);\n break;\n case \"event\":\n $resultStr = $this->handleEvent($postObj);\n break;\n case \"voice\":\n $resultStr = $this->handleVoice($postObj);\n break;\n default:\n $resultStr = \"Unknow msg type: \".$RX_TYPE;\n break;\n }\n echo $resultStr;\n }else {\n echo \"\";\n exit;\n }\n }", "title": "" }, { "docid": "b87680a2563bc96bfb725bc92a3432c9", "score": "0.5691793", "text": "public function executePayment(){\r\n // gets the paymentId and payerId\r\n $PaymentID = $_POST['paymentID'];\r\n $PayerID = $_POST['payerID'];\r\n\r\n $url = \"https://api.sandbox.paypal.com/v1/payments/payment/\".$PaymentID.\"/execute\";\r\n $paymentHeaders = array(\"Content-Type: application/json\", \"Authorization: Bearer \".$_SESSION[\"access_token\"]);\r\n $postfields = \"{\\\"payer_id\\\":\\\"$PayerID\\\"}\"; \r\n\r\n $ch = curl_init();\r\n\r\n curl_setopt($ch, CURLOPT_URL, $url);\r\n curl_setopt($ch, CURLOPT_HTTPHEADER, $paymentHeaders);\r\n curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields);\r\n\r\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\r\n curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);\r\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\r\n\r\n curl_setopt($ch, CURLOPT_VERBOSE, 1);\r\n curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);\r\n curl_setopt($ch, CURLOPT_POST, true);\r\n\r\n $run = curl_exec($ch);\r\n\r\n curl_close($ch);\r\n\r\n $runArray = json_decode($run, 1);\r\n \r\n // writes the execute payment response for checking purposes\r\n file_put_contents(\"executePaymentResponse.txt\", $run);\r\n\r\n \r\n\r\n // return the response from the paypal site trought the curl post execute \r\n echo $run;\r\n }", "title": "" }, { "docid": "cdca7d33f2f9acccfd9dc7713e95f55b", "score": "0.56915414", "text": "protected function parseRequestPost(){\n $data = $this->_request->post();\n if(!$data){\n $data = $this->_request->raw_post();\n if($this->_response->format === 'json'){\n $data = (array)json_decode($data);\n }\n }\n return $data;\n }", "title": "" }, { "docid": "9a80dc47f3e827b8b1c530913a3d583e", "score": "0.56905174", "text": "public function getResponse()\n {\n return $this->response;\n }", "title": "" }, { "docid": "c140ac6ebab618b70663e36d22e9efa6", "score": "0.56901145", "text": "public function getGatewayResponse(){\n return $this->gateway_response;\n }", "title": "" }, { "docid": "ff6ef94905be764fa0ea49e793e50ddd", "score": "0.5688384", "text": "public function testPostCurlRequest()\n {\n $body = [\n 'merchant_id' => 'TTM-00000001',\n 'transaction_id' => time().'11',\n 'desc' => 'testing from the other side',\n 'amount' => '000000000010',\n 'r-switch' => 'MAS',\n 'pan' => '5454410007344162',\n 'processing_code' => '000000',\n 'exp_month' => '10',\n 'exp_year' => '19',\n 'cvv' => '959',\n '3d_url_response' => 'https://webhook.site/52b5e75e-cab4-4339-b0c1-9cea380e4ba6'\n ];\n\n $merchant_id = factory(Merchant::class)->create();\n\n $payment = factory(Payment::class)->create([\n \"merchant_id\" => $merchant_id->merchant_id,\n \"provider\" => \"MAS\",\n \"account_number\" => $body['pan']\n ]);\n\n $transaction = new Transaction($body['cvv'], $body['exp_month'], $body['exp_year']);\n\n $this->assertTrue(true);\n\n// $this->assertEquals([\"status\" => \"approved\", \"code\" => 2000, \"reason\" => \"payment approved\"], $transaction->debit($payment));\n }", "title": "" }, { "docid": "73c2e5f29796d624447525ac166581a6", "score": "0.5687378", "text": "public function razorpayWebResponse_post() {\n\n $Input = file_get_contents(\"php://input\");\n $PayResponse = json_decode($Input, 1);\n\n\n $InsertData = array_filter(array(\n \"PageGUID\" => \"RazorPay\",\n \"Title\" => \"Test\",\n \"Content\" => json_encode($Input)\n ));\n $this->db->insert('set_pages', $InsertData);\n\n\n\n $payResponse = $PayResponse['payload']['payment']['entity'];\n if ($payResponse['status'] === \"authorized\") {\n\n $this->db->trans_start();\n\n $payment_id = $payResponse['id'];\n /* update profile table */\n $UpdataData = array_filter(\n array(\n 'PaymentGatewayResponse' => @$Input,\n 'ModifiedDate' => date(\"Y-m-d H:i:s\"),\n 'StatusID' => 5\n ));\n $this->db->where('WalletID', $payResponse['notes']['OrderID']);\n $this->db->where('UserID', $payResponse['notes']['UserID']);\n $this->db->where('StatusID', 1);\n $this->db->limit(1);\n $this->db->update('tbl_users_wallet', $UpdataData);\n if ($this->db->affected_rows() <= 0) return FALSE;\n\n $Amount = $payResponse['amount'] / 100;\n $this->db->set('WalletAmount', 'WalletAmount+' . $Amount, FALSE);\n $this->db->where('UserID', $payResponse['notes']['UserID']);\n $this->db->limit(1);\n $this->db->update('tbl_users');\n\n $UserID = $payResponse['notes']['UserID'];\n $this->Notification_model->addNotification('AddCash', 'Cash Added', $UserID, $UserID, '', 'Deposit of ' . DEFAULT_CURRENCY . @$Amount . ' is Successful.');\n\n $CouponDetails = $this->Users_model->getWallet('CouponDetails', array(\"WalletID\" => $payResponse['notes']['OrderID']));\n\n /* Check Coupon Details */\n if (!empty($CouponDetails['CouponDetails'])) {\n $WalletData = array(\n \"Amount\" => $CouponDetails['CouponDetails']['DiscountedAmount'],\n \"CashBonus\" => $CouponDetails['CouponDetails']['DiscountedAmount'],\n \"TransactionType\" => 'Cr',\n \"Narration\" => 'Coupon Discount',\n \"EntryDate\" => date(\"Y-m-d H:i:s\")\n );\n $this->Users_model->addToWallet($WalletData, $UserID, 5);\n }\n\n $TotalDeposits = $this->db->query('SELECT COUNT(*) TotalDeposits FROM `tbl_users_wallet` WHERE `UserID` = ' . $UserID . ' AND Narration = \"Deposit Money\" AND StatusID = 5')->row()->TotalDeposits;\n\n if ($TotalDeposits == 1) { // On First Successful Transaction\n\n /* Get Deposit Bonus Data */\n $DepositBonusData = $this->db->query('SELECT ConfigTypeValue,StatusID FROM set_site_config WHERE ConfigTypeGUID = \"FirstDepositBonus\" LIMIT 1');\n if ($DepositBonusData->row()->StatusID == 2) {\n\n $MinimumFirstTimeDepositLimit = $this->db->query('SELECT ConfigTypeValue FROM set_site_config WHERE ConfigTypeGUID = \"MinimumFirstTimeDepositLimit\" LIMIT 1');\n $MaximumFirstTimeDepositLimit = $this->db->query('SELECT ConfigTypeValue FROM set_site_config WHERE ConfigTypeGUID = \"MaximumFirstTimeDepositLimit\" LIMIT 1');\n\n if ($MinimumFirstTimeDepositLimit->row()->ConfigTypeValue <= @$Amount && $MaximumFirstTimeDepositLimit->row()->ConfigTypeValue >= @$Amount) {\n /* Update Wallet */\n $FirstTimeAmount = (@$Amount * $DepositBonusData->row()->ConfigTypeValue) / 100;\n $WalletData = array(\n \"Amount\" => $FirstTimeAmount,\n \"CashBonus\" => $FirstTimeAmount,\n \"TransactionType\" => 'Cr',\n \"Narration\" => 'First Deposit Bonus',\n \"EntryDate\" => date(\"Y-m-d H:i:s\")\n );\n $this->Users_model->addToWallet($WalletData, $UserID, 5);\n }\n }\n\n /* Get User Data */\n $UserData = $this->Users_model->getUsers('ReferredByUserID', array(\"UserID\" => $UserID));\n if (!empty($UserData['ReferredByUserID'])) {\n\n /* Get Referral To Bonus Data */\n $ReferralToBonus = $this->db->query('SELECT ConfigTypeValue,StatusID FROM set_site_config WHERE ConfigTypeGUID = \"ReferToDepositBonus\" LIMIT 1');\n if ($ReferralToBonus->row()->StatusID == 2) {\n\n /* Update Wallet */\n $WalletData = array(\n \"Amount\" => $ReferralToBonus->row()->ConfigTypeValue,\n \"CashBonus\" => $ReferralToBonus->row()->ConfigTypeValue,\n \"TransactionType\" => 'Cr',\n \"Narration\" => 'Referral Bonus',\n \"EntryDate\" => date(\"Y-m-d H:i:s\")\n );\n $this->Users_model->addToWallet($WalletData, $UserID, 5);\n $this->Notification_model->addNotification('ReferralBonus', 'Referred Bonus Added', $UserID, $UserID, '', 'You have received ' . DEFAULT_CURRENCY . @$ReferralToBonus->row()->ConfigTypeValue . ' Cash Bonus for Referred.');\n }\n\n /* Get Referral By Bonus Data */\n $ReferralByBonus = $this->db->query('SELECT ConfigTypeValue,StatusID FROM set_site_config WHERE ConfigTypeGUID = \"ReferByDepositBonus\" LIMIT 1');\n if ($ReferralByBonus->row()->StatusID == 2) {\n\n /* Update Wallet */\n $WalletData = array(\n \"Amount\" => $ReferralByBonus->row()->ConfigTypeValue,\n \"CashBonus\" => $ReferralByBonus->row()->ConfigTypeValue,\n \"TransactionType\" => 'Cr',\n \"Narration\" => 'Referral Bonus',\n \"EntryDate\" => date(\"Y-m-d H:i:s\")\n );\n $this->Users_model->addToWallet($WalletData, $UserData['ReferredByUserID'], 5);\n $this->Notification_model->addNotification('ReferralBonus', 'Referral Bonus Added', $UserData['ReferredByUserID'], $UserData['ReferredByUserID'], '', 'You have received ' . DEFAULT_CURRENCY . @$ReferralByBonus->row()->ConfigTypeValue . ' Cash Bonus for Successful Referral.');\n }\n }\n }\n\n /* MLM Referrals Wallet */\n $MLMISActive = FALSE;\n $FirstLevel = 0;\n $SecondLevel = 0;\n $ThirdLevel = 0;\n $MLMConfigType = $this->db->query('SELECT ConfigTypeGUID,ConfigTypeValue,StatusID FROM set_site_config '\n . 'WHERE (ConfigTypeGUID = \"MlmIsActive\" OR ConfigTypeGUID = \"MlmFirstLevel\" OR ConfigTypeGUID = '\n . '\"MlmSecondLevel\" OR ConfigTypeGUID = \"MlmThirdLevel\")')->result_array();\n\n if (!empty($MLMConfigType)) {\n foreach ($MLMConfigType as $ConfigValue) {\n if ($ConfigValue['ConfigTypeGUID'] == \"MlmIsActive\") {\n if ($ConfigValue['ConfigTypeValue'] == \"Yes\" && $ConfigValue['StatusID'] == 2) {\n $MLMISActive = TRUE;\n }\n }\n if ($ConfigValue['ConfigTypeGUID'] == \"MlmFirstLevel\" && $ConfigValue['StatusID'] == 2) {\n $FirstLevel = $ConfigValue['ConfigTypeValue'];\n }\n if ($ConfigValue['ConfigTypeGUID'] == \"MlmSecondLevel\" && $ConfigValue['StatusID'] == 2) {\n $SecondLevel = $ConfigValue['ConfigTypeValue'];\n }\n if ($ConfigValue['ConfigTypeGUID'] == \"MlmThirdLevel\" && $ConfigValue['StatusID'] == 2) {\n $ThirdLevel = $ConfigValue['ConfigTypeValue'];\n }\n }\n }\n if ($MLMISActive) {\n $WalletAmount = $Amount;\n\n if ($WalletAmount > 0) {\n /** get first level * */\n $LevelFirst = $this->Users_model->getUserReferralBy($UserID);\n\n if (!empty($LevelFirst['Records'])) {\n\n /** get 2.5% on first level * */\n $LevelFirstRffferID = $LevelFirst['Records']['ReferredByUserID'];\n if (!empty($LevelFirstRffferID) && $FirstLevel != 0) {\n $FirstLevelDeposit = ($WalletAmount * $FirstLevel) / 100;\n /** add to wallet amount * */\n $WalletData = array(\n \"Amount\" => $FirstLevelDeposit,\n \"WalletAmount\" => $FirstLevelDeposit,\n \"TransactionType\" => 'Cr',\n \"Narration\" => 'Referral Deposit',\n \"AmountType\" => \"Referral\",\n \"ReferralGetAmountUserID\" => $UserID,\n \"EntryDate\" => date(\"Y-m-d H:i:s\")\n );\n $this->Users_model->addToWallet($WalletData, $LevelFirstRffferID, 5);\n\n\n /** get second level * */\n $LevelSecond = $this->Users_model->getUserReferralBy($LevelFirstRffferID);\n\n if (!empty($LevelSecond['Records'])) {\n $LevelSecondRffferID = $LevelSecond['Records']['ReferredByUserID'];\n\n if (!empty($LevelSecondRffferID) && $SecondLevel != 0) {\n /** get 1.5% on first level * */\n $SecondLevelDeposit = ($WalletAmount * $SecondLevel) / 100;\n /** add to wallet amount * */\n $WalletData = array(\n \"Amount\" => $SecondLevelDeposit,\n \"WalletAmount\" => $SecondLevelDeposit,\n \"TransactionType\" => 'Cr',\n \"Narration\" => 'Referral Deposit',\n \"AmountType\" => \"Referral\",\n \"ReferralGetAmountUserID\" => $UserID,\n \"EntryDate\" => date(\"Y-m-d H:i:s\")\n );\n $this->Users_model->addToWallet($WalletData, $LevelSecondRffferID, 5);\n\n /** get third level * */\n $LevelThird = $this->Users_model->getUserReferralBy($LevelSecondRffferID);\n if (!empty($LevelThird['Records'])) {\n $LevelThirdRffferID = $LevelThird['Records']['ReferredByUserID'];\n if (!empty($LevelThirdRffferID) && $ThirdLevel != 0) {\n /** get 1% on first level * */\n $ThirdLevelDeposit = ($WalletAmount * $ThirdLevel) / 100;\n /** add to wallet amount * */\n $WalletData = array(\n \"Amount\" => $ThirdLevelDeposit,\n \"WalletAmount\" => $ThirdLevelDeposit,\n \"TransactionType\" => 'Cr',\n \"Narration\" => 'Referral Deposit',\n \"AmountType\" => \"Referral\",\n \"ReferralGetAmountUserID\" => $UserID,\n \"EntryDate\" => date(\"Y-m-d H:i:s\")\n );\n $this->Users_model->addToWallet($WalletData, $LevelThirdRffferID, 5);\n }\n }\n }\n }\n }\n }\n }\n }\n $this->db->trans_complete();\n if ($this->db->trans_status() === FALSE) {\n return FALSE;\n }\n } else {\n /* if ($payResponse['status'] === \"failed\") {\n $UpdataData = array_filter(\n array(\n 'PaymentGatewayResponse' => @$Input,\n 'ModifiedDate' => date(\"Y-m-d H:i:s\"),\n 'StatusID' => 3\n ));\n $this->db->where('WalletID', $payResponse['notes']['OrderID']);\n $this->db->where('UserID', $payResponse['notes']['UserID']);\n $this->db->where('StatusID', 1);\n $this->db->limit(1);\n $this->db->update('tbl_users_wallet', $UpdataData);\n if ($this->db->affected_rows() <= 0)\n return FALSE;\n } */\n }\n }", "title": "" }, { "docid": "30761415e20a686a4068ba4b84b4ab31", "score": "0.56839013", "text": "public function getResponse()\n {\n return $this->responseBody;\n }", "title": "" }, { "docid": "3911256151bec97e7707f3e20fb6bdd8", "score": "0.56815195", "text": "public function post()\n {\n $resource = curl_init();\n $xml = $this->getXMLBody();\n\n curl_setopt($resource, CURLOPT_URL, $this->apiPath);\n curl_setopt($resource, CURLOPT_POST, true);\n foreach ($this->headers as $header => $value) {\n curl_setopt($resource, CURLOPT_HTTPHEADER, [$header, $value]);\n }\n curl_setopt($resource, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($resource, CURLOPT_POSTFIELDS, $xml);\n $result = curl_exec($resource);\n\n if ($this->logger) {\n $this->logger->info('AdobeConnect request using POST method', [\n 'url' => $this->apiPath,\n 'headers' => $this->headers,\n 'post_body' => $xml\n ]);\n }\n\n return new Response($resource, $result);\n }", "title": "" }, { "docid": "9eae285ed860cc2884fb950922da7a7b", "score": "0.56793576", "text": "function response(){\n\t\treturn $this->_response;\n\t}", "title": "" }, { "docid": "3d51bca29d2a1b2a8b51c6d04400a90b", "score": "0.56729937", "text": "public function post() {return \"\";}", "title": "" }, { "docid": "38b3bef30931ed17e4fac6c0972e3f93", "score": "0.5668987", "text": "public function getResponse() : Response{\n return $this->response;\n }", "title": "" }, { "docid": "b656a5ba1d70688adb562c3dfa03627f", "score": "0.56687325", "text": "public function post()\n\t{\n\t\t\n\t}", "title": "" }, { "docid": "56da3e39836302ad7ca277fe18885f26", "score": "0.56651634", "text": "function getResponse();", "title": "" }, { "docid": "a0630ed5c81db0e0a591794daba83992", "score": "0.5660273", "text": "public function getResponse(): string;", "title": "" }, { "docid": "a0630ed5c81db0e0a591794daba83992", "score": "0.5660273", "text": "public function getResponse(): string;", "title": "" }, { "docid": "8b213fff41c67854085c056982f78235", "score": "0.56573915", "text": "function get_post_response($url,$fields) {\n $fields_string = '';\n foreach($fields as $key=>$value) { $fields_string .= $key.'='.$value.'&'; }\n $fields_string = rtrim($fields_string, '&');\n\n\n //open connection\n $ch = curl_init();\n\n //set the url, number of POST vars, POST data\n curl_setopt($ch,CURLOPT_URL, $url);\n curl_setopt($ch,CURLOPT_RETURNTRANSFER, true); \n curl_setopt($ch,CURLOPT_POST, count($fields));\n curl_setopt($ch,CURLOPT_POSTFIELDS, $fields_string);\n\n //execute post\n $result = curl_exec($ch);\n\n //close connection\n curl_close($ch);\n \n return $result;\n \n}", "title": "" }, { "docid": "15987d7c9c8d5f594d4c716c44d076bd", "score": "0.5651625", "text": "public function getResponse() {\n return $this->response;\n }", "title": "" }, { "docid": "0baae64d9ba1e645bf684922a7cafbe3", "score": "0.5645729", "text": "private function handlePostRequest() {\n if ($requestbody = $this->api->getBodyParams()) {\n $client = new apiClient();\n $out = $client->store($requestbody);\n if (is_array($out)) {\n $this->body = ['errorcode' => 100, 'messages' => $out];\n $this->status = 400;\n } else {\n $this->body = ['errorcode' => 0, 'id' => $out];\n $this->status = 200;\n }\n } else {\n $this->status = 400;\n $this->body = ['errorcode' => 1, 'messages' => ['invalid input']];\n }\n }", "title": "" }, { "docid": "38f50fc526cea2536764da9f4642dcb3", "score": "0.56329066", "text": "public function index_post()\n\t{\n $this->response([\n 'metadata' => [\n 'code' => \"200\",\n 'message' => \"this ajax with post method\"\n ],\n 'status' => 'success'\n ], 200);\n }", "title": "" }, { "docid": "7c2f69c97b2a85f4918917de4efb8918", "score": "0.5632531", "text": "public function getResponse()\r\n {\r\n return $this->response;\r\n }", "title": "" }, { "docid": "7c2f69c97b2a85f4918917de4efb8918", "score": "0.5632531", "text": "public function getResponse()\r\n {\r\n return $this->response;\r\n }", "title": "" } ]
f2cd5d22d6bff14eb20109bf881633cc
\\ endregion region ARRAY JSON ARRAY JSON\\ Guarda los alumnos en un solo array de elementos JSON. Recibe el array de Alummnos (Clase alumno) y lo fusiona con el array ya existente en el archivo para reguardarlo como un solo array con los elementos entrantes y los ya existentes
[ { "docid": "76372fc41988b92e89bcdeb2d61dd897", "score": "0.5759892", "text": "public static function GuardarArrayJSON($dirFile, $array)\n {\n if(file_exists($dirFile))\n {\n $arrayYaExistente = alumno::LeerArchivoArrayJSON($dirFile); //Tomo los alumnos ya existentes\n $arrayAcumulativo = array();\n if($arrayYaExistente !=NULL)\n {\n foreach($arrayYaExistente as $alumnos)\n {\n array_push($arrayAcumulativo,$alumnos); //Los meto en el nuevo array\n }\n }\n foreach($array as $alumno) //Tomo los elementos entrantes y los meto en el nuevo array\n {\n array_push($arrayAcumulativo,$alumno);\n }\n $resource = fopen($dirFile, \"w\");\n fwrite($resource, json_encode($arrayAcumulativo)); //Escribo el array fusionado\n fclose($resource);\n }\n else\n {\n $resource = fopen($dirFile, \"w\");\n fwrite($resource, json_encode($array));\n fclose($resource);\n }\n }", "title": "" } ]
[ { "docid": "60c882d96aa3f13902b8e8952c178e74", "score": "0.6545386", "text": "public static function leerFromJSON($path)\n {\n $retorno = array();\n $json = file_get_contents($path);\n $json_data = json_decode($json,true);\n //var_dump($json_data);\n foreach ($json_data as $key => $value) \n {\n array_push($retorno,new Alumno($json_data[$key]['nombre'],$json_data[$key]['apellido'],$json_data[$key]['email'],$json_data[$key]['nomFoto'])); \n }\n return $retorno;\n }", "title": "" }, { "docid": "447ff92565bd98377cc5d84f362d7db5", "score": "0.5941058", "text": "function lerArquivo($nomeArquivo){\r\n //le o arquivo como string\r\n $arquivo = file_get_contents($nomeArquivo);\r\n \r\n //transforma string em array\r\n $jsonArray = json_decode($arquivo);\r\n\r\n //deolve o array\r\n return $jsonArray;\r\n}", "title": "" }, { "docid": "d3b0b18e531aa487681142e4743fc1c8", "score": "0.58791643", "text": "function cargarJson(){\n\t\t$archivo = file_get_contents(\"../json/usuarios_personal.json\");\n\n\t\t// esto me arma un array con todos los usuarios\n $usuariosJSON = explode(PHP_EOL, $archivo);\n\n\t\t// Saco el último elemento que es una línea vacia\n\t\tarray_pop($usuariosJSON);\n\n\t\t// Creo un array vacio, para guardar los usuarios\n\t\t$usuariosFinal = [];\n\n\t\t// Recorremos el array y generamos por cada usuario un array del usuario\n\t\tforeach ($usuariosJSON as $usuario) {\n\t\t\t$usuariosFinal[] = json_decode($usuario, true);\n\t\t}\n\n\t\treturn $usuariosFinal;\n\t}", "title": "" }, { "docid": "b86b8c93ad8df192ec033c838b000384", "score": "0.5816675", "text": "function traerTodos(){\n\t $allUsers = file_get_contents('usuarios.json');\n\t $arrayDeJSON = explode(PHP_EOL, $allUsers);\n\t array_pop($arrayDeJSON);\n\t $arrayPHP = [];\n\t foreach ($arrayDeJSON as $usuario) {\n\t $arrayPHP[] = json_decode($usuario, true);\n\t }\n\t return $arrayPHP;\n\t}", "title": "" }, { "docid": "2e0f35108454965b1eb547429f8d5f65", "score": "0.5658782", "text": "function scriviArray ($arContenuto, $file){\r\n $arContenuto = str_replace(['Array','(',')'], '', print_r($arContenuto, true));\r\n \r\n if(!is_file($file)){\r\n file_put_contents($file, print_r($arContenuto, true));\r\n };\r\n }", "title": "" }, { "docid": "fbbe354cd04a989c7a476135ff7163f7", "score": "0.5618321", "text": "public static function BorrarAlumnoArrayJSON($dirFile,$_DELETE)\n {\n $arrayAlumnos = alumno::LeerArchivoArrayJSON($dirFile);\n $arrayEscribir = alumno::BorrarRegistro($arrayAlumnos,$_DELETE[\"Legajo\"]);\n if($arrayEscribir != -1)\n {\n alumno::VaciarArchivo($dirFile);\n if(!(empty($arrayEscribir)))\n {\n alumno::GuardarArrayJSON($dirFile,$arrayEscribir);\n }\n }\n }", "title": "" }, { "docid": "1e48cc594be866e14061f792019526f9", "score": "0.5617921", "text": "public static function LeerArchivoArrayJSON($dirFile)\n {\n if(file_exists($dirFile))\n {\n $arrayJSON = json_decode(file_get_contents($dirFile));\n $arrayAlumnos = array();\n if($arrayJSON != NULL)\n {\n foreach($arrayJSON as $alumno)\n {\n array_push($arrayAlumnos,alumno::objectToObject($alumno));\n }\n return $arrayAlumnos;\n }\n }\n return false;\n }", "title": "" }, { "docid": "4949c7fb4b28978539d58920352b5827", "score": "0.5612657", "text": "function get_json() {\n $arr = array();\n\n foreach($this->table->data as $row) {\n\n $i = 0;\n $arr_row = array();\n\n foreach(array_keys($this->columns) as $key) {\n $arr_row[$key] = $row[$i];\n $i += 1;\n }\n\n $arr[] = $arr_row;\n }\n\n return json_encode($arr);\n }", "title": "" }, { "docid": "70eb59c7ee38644cbe48208fc3f87a11", "score": "0.5563181", "text": "public static function json2array($filename) {\r\n if (isset($filename) && file_exists($filename)) {\r\n $contenuto_stringa = file_get_contents($filename);\r\n\r\n \r\n $json = json_decode($contenuto_stringa, true);\r\n //se il formato del json non e corretto\r\n if (!is_null($json)) {\r\n return $json;\r\n } else {\r\n \r\n throw new Exception(\"il file $filename non é un JSON\");\r\n }\r\n \r\n } else {\r\n throw new Exception(\"il file $filename, non esiste\");\r\n }\r\n }", "title": "" }, { "docid": "e44dcad1489aba5c75e977ae302db5b0", "score": "0.5562745", "text": "function Insertar(){\n $jsondata = file_get_contents('empdetails.json');\n \n //convert json object to php associative array\n $data = json_decode($jsondata, true);\n foreach ($data->usuario as $user) \n\t{\n $nombre = $user->nombre; \n $apellido1 = $user->apellido1; \n $apellido2 = $user->apellido2; \n $correo = $user->correo; \n $telefono = $user->telefono; \n $usuario = $user->usuario; \n $rol = $user->rol; \n $sql = \"INSERT INTO usuarios(nombre, apellido1, apellido2, correo, telefono, usuario, rol)\n VALUES('$nombre', '$apellido1', '$apellido2', '$correo', $telefono, '$usuario', '$rol')\";\n AccesoDatos.Insert($sql);\n\t}\n }", "title": "" }, { "docid": "b5c60d40f1662dd85424591b96b0eb24", "score": "0.5530887", "text": "public function saveJsonArray() {\n\t\t\t//$this->load->helper('url');\n\t\t\t\n\t\t\t/* DIT ZIJN ALLE VELDEN ZOALS ZE IN DE DB MOETEN KOMEN TE STAAN:\n\t\t\t * artikel_id\t\n\t\t\t\tartikel_titel\tGeen index gedefinieerd! Maak hieronder er een aan\n\t\t\t\tartikel_slug\tGeen index gedefinieerd! Maak hieronder er een aan\n\t\t\t\tartikel_auteur\tGeen index gedefinieerd! Maak hieronder er een aan\n\t\t\t\tartikel_tekst\tGeen index gedefinieerd! Maak hieronder er een aan\n\t\t\t\tartikel_datum_gewijzigd\tGeen index gedefinieerd! Maak hieronder er een aan\n\t\t\t\tartikel_categorie\tGeen index gedefinieerd! Maak hieronder er een aan\n\t\t\t\tartikel_actief\tGeen index gedefinieerd! Maak hieronder er een aan */\n\t\t\t\n\t\t\t//ALLES OPHALEN UIT JSON BESTAND EN DECODEREN\n\t\t\t//$jsonArray = json_decode(file_get_contents(base_url('assets/json/my_array.json')));\n\t\t\t\n\t\t\t//PER ARTIKEL IN DB WEGSCHRIJVEN\n\t\t\t/*foreach($jsonArray as $key => $artikel) {\n\t\t\t\t$data = array(\n\t\t\t\t\t'artikel_categorie' => $artikel[1],\n\t\t\t\t\t'artikel_auteur' => $artikel[2],\n\t\t\t\t\t'artikel_titel' => $artikel[3],\n\t\t\t\t\t'artikel_slug' => $artikel[3],\n\t\t\t\t\t'artikel_tekst' => $artikel[4],\n\t\t\t\t\t'artikel_actief' => $artikel[5]\n\t\t\t\t\t);\n\t\t\t\t$this->db->insert('artikelen', $data);\t\n\t\t\t\t}*/\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t//return; \n\t\t}", "title": "" }, { "docid": "6a7655b112e10ca3714d6a33524db56a", "score": "0.54956347", "text": "private function getAllFieldsFile($file){\n\n\t\t$return = new \\stdClass();\n\t\t$return->pk = null;\n\t\t$return->fks = array();\n\t\t$return->filters = array();\n\t\t$return->fields = array();\n\n\t\t//Todos os comentários dá classe\n\t\tpreg_match_all('/(\\/\\*(.|\\s)+?(\\*\\/))/', file_get_contents($file), $matches);\n\n\t\tif(isset($matches[0])){\n\n\t\t\t$fields = array();\n\t\t\t$pk = null;\n\t\t\tforeach($matches[0] as $key => $comment){\n\t\t\t\tpreg_match('/\\@field\\(.*\\)/', $comment, $field);\n\n\t\t\t\tif(isset($field[0])){\n\t\t\t\t\t$field = $field[0];\n\n\t\t\t\t\t$col = $this->retValues('@field', $field);\n\n\t\t\t\t\tpreg_match('/\\@list\\([^\\r\\n]*/m', $comment, $list);\n\t\t\t\t\tif(isset($list[0])){\n\t\t\t\t\t\t$col['list'] = PQDUtil::json_decode(substr($list[0], strlen('@list')+1, -1));\n\n\t\t\t\t\t\tif( is_string($col['list']) && substr($col['list'], -5) == '.json'){\n\n\t\t\t\t\t\t\t$jsonFile = dirname($this->class) . '/' . $col['list'];\n\n\t\t\t\t\t\t\tif (is_file($jsonFile))\n\t\t\t\t\t\t\t\t$col['list'] = PQDUtil::json_decode(file_get_contents($jsonFile));\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\tPQDApp::getApp()->getExceptions()->setException(new \\Exception(\"Arquivo JSON não encontrado!\", 13) );\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (is_null($col['list']))\n\t\t\t\t\t\t\tthrow new \\Exception(\"Erro no JSON da entidade! Arquivo(\" . $this->class . \"), coluna: (\" . $col['name'] . \").\");\n\t\t\t\t\t}\n\n\t\t\t\t\tpreg_match('/\\@help\\(.*$/m', $comment, $help);\n\t\t\t\t\tif(isset($help[0]))\n\t\t\t\t\t\t$col['help'] = substr($help[0], strlen('@help')+1, -2);\n\n\t\t\t\t\tif(isset($col['name']))\n\t\t\t\t\t\t$fields[$col['name']] = $col;\n\t\t\t\t\telse\n\t\t\t\t\t\t$fields[] = $col;\n\n\t\t\t\t\tif(isset($col['isPk']) && $col['isPk'] == 'true')\n\t\t\t\t\t\t$pk = $col['name'];\n\n\t\t\t\t\tif(isset($col['isFilter']) && $col['isFilter'] == 'true')\n\t\t\t\t\t\t$return->filters[] = $col;\n\n\t\t\t\t\tif(isset($col['fk']))\n\t\t\t\t\t\t$return->fks[] = array($col['name'] => $col['fk']);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$return->fields = $fields;\n\t\t\t$return->pk = $pk;\n\t\t}\n\n\t\treturn $return;\n\t}", "title": "" }, { "docid": "1fbc49f3257b95a024bc5f2d44dd943f", "score": "0.5445717", "text": "private function estrutura_vazia(){ \n $dados[0]['id_usuario']=NULL;\n $dados[0]['nome']=NULL;\n $dados[0]['email']=NULL;\n $dados[0]['sistema']=NULL;\n $dados[0]['status']=NULL;\n $dados[0]['senha']=NULL;\n \n return $dados;\n }", "title": "" }, { "docid": "ef8c26d716b75cfe151bab78bb255f6b", "score": "0.5440292", "text": "public function GenerarArrayDatosJson($noticiacod,$carpetaFecha,&$array)\n\t{\n\t\t$array = array();\n\t\t$datosbuscar['noticiacod'] = $noticiacod;\t\n\t\tif (!$this->EsNoticiaPublicada($datosbuscar,$resultado,$numfilas))\n\t\t\treturn false;\n\t\t$array = $this->conexion->ObtenerSiguienteRegistro($resultado);\n\t\t\n\t\t//BUSCO E INSERTO LOS DATOS DE GALERIAS DE LA NOTICIA EN LA TABLA NOT_NOTICIAS_TAGS\n\t\t$array['noticiaurl'] = $array['catdominio'].\"/\".$array['noticiadominio'];\n\t\t$array['noticiaurlcompartir'] = \"cn\".$noticiacod;\n\t\t\n\t\t //BUSCO E INSERTO LOS DATOS DE LA TABLA NOT_NOTICIAS_TAGS\n\t\t$oNoticiasTags = new cNoticiasTags($this->conexion,$this->formato);\t\t\n\t\tif (!$oNoticiasTags->BuscarTagsxNoticia($datosbuscar,$resultadotags,$numfilastags))\n\t\t\treturn false;\t\n\t\t$array['tags'] = array();\n\t\tif($numfilastags>0){\n\t\t\t$i =0;\n\t\t\twhile ($arraytagsinsertar = $this->conexion->ObtenerSiguienteRegistro($resultadotags))\n\t\t\t{\n\t\t\t\t$array['tags'][$i]=$arraytagsinsertar['noticiatag'];\n\t\t\t\t$i++;\n\t\t\t}\n \t\t }\t\n\t\t //BUSCO E INSERTO LOS DATOS DE LA TABLA NOT_NOTICIAS_TEMAS\n\t\t$oNoticiasNoticiasTemas = new cNoticiasNoticiasTemas($this->conexion,$this->formato);\n\t\t$DatosBuscarTemasNoticia['noticiacod'] = $noticiacod;\n\t\t$DatosBuscarTemasNoticia['temaestado'] = ACTIVO;\t\t\n\t\tif (!$oNoticiasNoticiasTemas->BuscarxNoticia($DatosBuscarTemasNoticia,$resultadotemas,$numfilastemas))\n\t\t\treturn false;\t\n\t\t$array['temas'] = array();\n\t\tif($numfilastemas>0){\n\t\t\twhile ($arraytemasinsertar = $this->conexion->ObtenerSiguienteRegistro($resultadotemas))\n\t\t\t\t$array['temas'][$arraytemasinsertar['temacod']]=$arraytemasinsertar;\n \t\t }\t\n\t\t \n\t\t //BUSCO E INSERTO LOS DATOS DE LA TABLA NOT_NOTICIAS_MUL_MULTIMEDIAS\n\t\t $oNoticiasMultimedia = new cNoticiasMultimedia($this->conexion,$this->formato);\t\t\t\n\t\t// FOTOS DE LA NOTICIA\n\t\t$array['multimedias']['fotos'] = array();\n\t\t$datosmultimedia['multimediaconjuntocod'] = FOTOS;\n\t\t$datosmultimedia['noticiacod'] = $noticiacod;\n\t\tif(!$oNoticiasMultimedia->BuscarMultimediaxCodigoxMultimediaConjunto($datosmultimedia,$resultadoFotos,$numfilasFotos))\n\t\t\treturn false;\n\t\tif($numfilasFotos>0)\n\t\t{\n\t\t\twhile($filaFotos= $this->conexion->ObtenerSiguienteRegistro($resultadoFotos))\n\t\t\t{\n\t\t\t\t\n\t\t\t\tif(!$this->GenerarDatosMultimedia($filaFotos,$array['multimedias'],'multimediacod','not'))\n\t\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// AUDIOS DE LA NOTICIA\t\n\t\t$array['multimedias']['audios'] = array();\n\t\t$datosmultimedia['multimediaconjuntocod'] = AUDIOS;\n\t\t$datosmultimedia['noticiacod'] = $noticiacod;\n\t\tif(!$oNoticiasMultimedia->BuscarMultimediaxCodigoxMultimediaConjunto($datosmultimedia,$resultadoAudios,$numfilasAudios))\n\t\t\treturn false;\n\t\tif($numfilasAudios>0)\n\t\t{\n\t\t\twhile($filaAudios= $this->conexion->ObtenerSiguienteRegistro($resultadoAudios))\n\t\t\t{\n\t\t\t\tif(!$this->GenerarDatosMultimedia($filaAudios,$array['multimedias'],'multimediacod','not'))\n\t\t\t\t\treturn false;\t\t\t\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\t// VIDEOS DE LA NOTICIA\t\n\t\t$array['multimedias']['videos'] = array();\n\t\t$datosmultimedia['multimediaconjuntocod'] = VIDEOS;\n\t\tif(!$oNoticiasMultimedia->BuscarMultimediaxCodigoxMultimediaConjunto($datosmultimedia,$resultadoVideos,$numfilasVideos))\n\t\t\treturn false;\n\t\tif($numfilasVideos>0)\n\t\t{\n\t\t\twhile($filaVideos= $this->conexion->ObtenerSiguienteRegistro($resultadoVideos))\n\t\t\t{\n\t\t\t\tif(!$this->GenerarDatosMultimedia($filaVideos,$array['multimedias'],'multimediacod','not'))\n\t\t\t\t\treturn false;\t\t\t\n\t\t\t}\n\t\t}\n\t\t// FILES DE LA NOTICIA\t\n\t\t$array['multimedias']['archivos'] = array();\n\t\t$datosmultimedia['multimediaconjuntocod'] = FILES;\n\t\tif(!$oNoticiasMultimedia->BuscarMultimediaxCodigoxMultimediaConjunto($datosmultimedia,$resultadoFiles,$numfilasFiles))\n\t\t\treturn false;\n\t\tif($numfilasFiles>0)\n\t\t{\n\t\t\twhile($filaFiles= $this->conexion->ObtenerSiguienteRegistro($resultadoFiles))\n\t\t\t{\n\t\t\t\tif(!$this->GenerarDatosMultimedia($filaFiles,$array['multimedias'],'multimediacod','not'))\n\t\t\t\t\treturn false;\t\t\t\n\t\t\t}\n\t\t}\n\t\t\n\t\t//BUSCO E INSERTO LOS DATOS DE LA TABLA NOT_NOTICIAS_GAL_GALERIAS\t\t\t\n\t\t$arraygalerias = array();\n\t\t$oNoticiasGalerias = new cNoticiasGalerias($this->conexion,$this->formato);\t\t\n\t\tif (!$oNoticiasGalerias->BuscarGaleriasRelacionadasxNoticia($datosbuscar,$resultadogaleriasrel,$numfilasgaleriasrel))\n\t\t\treturn false;\t\t\t\t\n\t\t\n\t\tif($numfilasgaleriasrel>0)\n\t\t{\n\t\t\twhile ($datosgaleriarelacionada = $this->conexion->ObtenerSiguienteRegistro($resultadogaleriasrel))\n\t\t\t{\n\t\t\t\t$arraygalerias[$datosgaleriarelacionada['galeriacod']]['galeriacodigo'] = $datosgaleriarelacionada['galeriacod'];\n\t\t\t\t$arraygalerias[$datosgaleriarelacionada['galeriacod']]['galeriatitulo'] = $datosgaleriarelacionada['galeriatitulo'];\n\t\t\t\t$arraygalerias[$datosgaleriarelacionada['galeriacod']]['galeriadesc'] = $datosgaleriarelacionada['galeriadesc'];\n\t\t\t\t$arraygalerias[$datosgaleriarelacionada['galeriacod']]['galeriaimportante'] = $datosgaleriarelacionada['galeriaimportante'];\n\t\t\t\t$arraytemp = array();\n\t\t\t\tswitch ($datosgaleriarelacionada['multimediaconjuntocod'])\n\t\t\t\t{\n\t\t\t\t\tcase FOTOS:\n\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$arraytemp['codigo'] = $datosgaleriarelacionada['multimediacod'];\n\t\t\t\t\t\t\t$arraytemp['conjunto'] = $datosgaleriarelacionada['multimediaconjuntocod'];\n\t\t\t\t\t\t\t$arraytemp['titulo'] = $datosgaleriarelacionada['multimediatitulo'];\n\t\t\t\t\t\t\t$arraytemp['descripcion'] = $datosgaleriarelacionada['multimedianombre'];\n\t\t\t\t\t\t\t$arraytemp['idexterno'] = $datosgaleriarelacionada['multimediaidexterno'];\n\t\t\t\t\t\t\t$arraytemp['url'] = CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ORIGINALES.$datosgaleriarelacionada['multimediaubic'];\n\t\t\t\t\t\t\tif(isset($datosgaleriarelacionada['previewubic']) && $datosgaleriarelacionada['previewubic']!=\"\")\n\t\t\t\t\t\t\t$arraytemp['multimedias']['url_preview'] = CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ORIGINALES.$datosgaleriarelacionada['previewubic'];\n\t\t\t\t\t\t\t$arraygalerias[$datosgaleriarelacionada['galeriacod']]['multimedias']['fotos'][$datosgaleriarelacionada['multimediacod']] = FuncionesPHPLocal::DecodificarUtf8($arraytemp);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase VIDEOS:\n\t\t\t\t\t\t\t$arraytemp['codigo'] = $datosgaleriarelacionada['multimediacod'];\n\t\t\t\t\t\t\t$arraytemp['conjunto'] = $datosgaleriarelacionada['multimediaconjuntocod'];\n\t\t\t\t\t\t\t$arraytemp['titulo'] = $datosgaleriarelacionada['multimediatitulo'];\n\t\t\t\t\t\t\t$arraytemp['descripcion'] = $datosgaleriarelacionada['multimedianombre'];\n\t\t\t\t\t\t\t$arraytemp['idexterno'] = $datosgaleriarelacionada['multimediaidexterno'];\n\t\t\t\t\t\t\tif(isset($datosgaleriarelacionada['multimediaidexterno']) && $datosgaleriarelacionada['multimediaidexterno']!=\"\")\n\t\t\t\t\t\t\t\t$arraytemp['url'] = \"\";\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t$arraytemp['url'] = CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.\"videos/\".$datosgaleriarelacionada['multimediaubic'];\n\t\t\t\t\t\t\tif(isset($datosgaleriarelacionada['previewubic']) && $datosgaleriarelacionada['previewubic']!=\"\")\n\t\t\t\t\t\t\t$arraytemp['multimedias']['url_preview'] = CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ORIGINALES.$datosgaleriarelacionada['previewubic'];\n\t\t\t\t\t\t\t$arraygalerias[$datosgaleriarelacionada['galeriacod']]['multimedias']['video'][$datosgaleriarelacionada['multimediacod']] = FuncionesPHPLocal::DecodificarUtf8($arraytemp);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase AUDIOS:\n\t\t\t\t\t\t\t$arraytemp['codigo'] = $datosgaleriarelacionada['multimediacod'];\n\t\t\t\t\t\t\t$arraytemp['conjunto'] = $datosgaleriarelacionada['multimediaconjuntocod'];\n\t\t\t\t\t\t\t$arraytemp['titulo'] = $datosgaleriarelacionada['multimediatitulo'];\n\t\t\t\t\t\t\t$arraytemp['descripcion'] = $datosgaleriarelacionada['multimedianombre'];\n\t\t\t\t\t\t\t$arraytemp['idexterno'] = $datosgaleriarelacionada['multimediaidexterno'];\n\t\t\t\t\t\t\tif(isset($datosgaleriarelacionada['multimediaidexterno']) && $datosgaleriarelacionada['multimediaidexterno']!=\"\")\n\t\t\t\t\t\t\t\t$arraytemp['url'] = \"\";\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t$arraytemp['url'] = CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.\"audios/\".$datosgaleriarelacionada['multimediaubic'];\n\t\t\t\t\t\t\tif(isset($datosgaleriarelacionada['previewubic']) && $datosgaleriarelacionada['previewubic']!=\"\")\n\t\t\t\t\t\t\t$arraytemp['multimedias']['url_preview'] = CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ORIGINALES.$datosgaleriarelacionada['previewubic'];\n\t\t\t\t\t\t\t$arraygalerias[$datosgaleriarelacionada['galeriacod']]['multimedias']['audio'][$datosgaleriarelacionada['multimediacod']] = FuncionesPHPLocal::DecodificarUtf8($arraytemp);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase FILES:\n\t\t\t\t\t\t\t$arraytemp['codigo'] = $datosgaleriarelacionada['multimediacod'];\n\t\t\t\t\t\t\t$arraytemp['conjunto'] = $datosgaleriarelacionada['multimediaconjuntocod'];\n\t\t\t\t\t\t\t$arraytemp['titulo'] = $datosgaleriarelacionada['multimediatitulo'];\n\t\t\t\t\t\t\t$arraytemp['descripcion'] = $datosgaleriarelacionada['multimedianombre'];\n\t\t\t\t\t\t\t$arraytemp['idexterno'] = $datosgaleriarelacionada['multimediaidexterno'];\n\t\t\t\t\t\t\tif(isset($datosgaleriarelacionada['multimediaidexterno']) && $datosgaleriarelacionada['multimediaidexterno']!=\"\")\n\t\t\t\t\t\t\t\t$arraytemp['url'] = \"\";\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t$arraytemp['url'] = CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ARCHIVOS.$datosgaleriarelacionada['multimediaubic'];\n\t\t\t\t\t\t\tif(isset($datosgaleriarelacionada['previewubic']) && $datosgaleriarelacionada['previewubic']!=\"\")\n\t\t\t\t\t\t\t$arraytemp['multimedias']['url_preview'] = CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ORIGINALES.$datosgaleriarelacionada['previewubic'];\n\t\t\t\t\t\t\t$arraygalerias[$datosgaleriarelacionada['galeriacod']]['multimedias']['archivo'][$datosgaleriarelacionada['multimediacod']] = FuncionesPHPLocal::DecodificarUtf8($arraytemp);\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t$array['galerias'] = $arraygalerias;\n\t\t\n\t\t\n\t\t//BUSCO E INSERTO LOS DATOS DE LA TABLA NOT_NOTICIAS_NOT_NOTICIAS\t\n\t\t$arrayrelacionadas = array();\t\n\t\t$oNoticiasNoticias = new cNoticiasNoticias($this->conexion,$this->formato);\t\t\n\t\tif (!$oNoticiasNoticias->BuscarNoticiasRelacionadasxCodigoNoticia($datosbuscar,$resultadonoticiasrel,$numfilasnoticiasrel))\n\t\t\treturn false;\t\t\t\t\n\t\t\n\t\tif($numfilasnoticiasrel>0){\n\t\t\twhile ($arrayrelacionada = $this->conexion->ObtenerSiguienteRegistro($resultadonoticiasrel)){\n\t\t\t\t\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['noticiacod']=$arrayrelacionada['noticiacodrel'];\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['noticiatitulo']=$arrayrelacionada['noticiatitulo'];\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['noticiatitulocorto']=$arrayrelacionada['noticiatitulocorto'];\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['noticiacopete']=$arrayrelacionada['noticiacopete'];\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['noticiafecha']=$arrayrelacionada['noticiafecha'];\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['noticiadominio']=$arrayrelacionada['noticiadominio'];\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['noticiaurl']=$arrayrelacionada['catdominio'].\"/\".$arrayrelacionada['noticiadominio'];;\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['noticiaorden']=$arrayrelacionada['noticiaorden'];\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['noticiaimportante']=$arrayrelacionada['noticiaimportante'];\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['multimedias']['fotos']= array();\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['multimedias']['videos']= array();\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['multimedias']['audios']= array();\n\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['multimedias']['archivos']= array();\n\t\t\t\n\t\t\t\t$datosbuscarmultimedia['noticiacod'] = $arrayrelacionada['noticiacodrel'];\n\t\t\t\tif (!$oNoticiasMultimedia->BuscarMultimediaxCodigoNoticiaxMinimoOrden($datosbuscarmultimedia,$resultadomultimediarel,$numfilasmultimrdiarel))\n\t\t\t\t\treturn false;\t\t\t\t\n\t\t\t\twhile ($datosmultimediarel = $this->conexion->ObtenerSiguienteRegistro($resultadomultimediarel)){\n\t\t\t\t\t\t\n\t\t\t\t\t\tif(!$this->GenerarDatosMultimedia($datosmultimediarel,$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['multimedias'],'multimediacod','not'))\n\t\t\t\t\t\t\treturn false;\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t/*switch ($datosmultimediarel['multimediaconjuntocod'])\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcase FOTOS:\n\t\t\t\t\t\t\t\t\t$datosmultimediarel['multimediaubic'] = CARPETA_SERVIDOR_MULTIMEDIA.CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ORIGINALES.$datosmultimediarel['multimediaubic'];\n\t\t\t\t\t\t\t\t\tif(isset($datosmultimediarel['previewubic']) && $datosmultimediarel['previewubic']!=\"\")\n\t\t\t\t\t\t\t\t\t\t$datosmultimediarel['previewubic'] = CARPETA_SERVIDOR_MULTIMEDIA.CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ORIGINALES.$datosmultimediarel['previewubic'];\n\t\t\t\t\t\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['multimedias']['foto'][$datosmultimediarel['multimediacod']]= FuncionesPHPLocal::DecodificarUtf8($datosmultimediarel);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase VIDEOS:\n\t\t\t\t\t\t\t\t\tif($datosmultimediarel['multimediaubic']!=\"\")\n\t\t\t\t\t\t\t\t\t\t$datosmultimediarel['multimediaubic'] = CARPETA_SERVIDOR_MULTIMEDIA.CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.\"videos/\".$datosmultimediarel['multimediaubic'];\n\t\t\t\t\t\t\t\t\tif(isset($datosmultimediarel['previewubic']) && $datosmultimediarel['previewubic']!=\"\")\n\t\t\t\t\t\t\t\t\t\t$datosmultimediarel['previewubic'] = CARPETA_SERVIDOR_MULTIMEDIA.CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ORIGINALES.$datosmultimediarel['previewubic'];\n\t\t\t\t\t\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['multimedias']['video'][$datosmultimediarel['multimediacod']]= FuncionesPHPLocal::DecodificarUtf8($datosmultimediarel);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase AUDIOS:\n\t\t\t\t\t\t\t\t\t$datosmultimediarel['multimediaubic'] = CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.\"audios/\".$datosmultimediarel['multimediaubic'];\n\t\t\t\t\t\t\t\t\tif(isset($datosmultimediarel['previewubic']) && $datosmultimediarel['previewubic']!=\"\")\n\t\t\t\t\t\t\t\t\t\t$datosmultimediarel['previewubic'] = CARPETA_SERVIDOR_MULTIMEDIA.CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ORIGINALES.$datosmultimediarel['previewubic'];\n\t\t\t\t\t\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['multimedias']['audio'][$datosmultimediarel['multimediacod']]= FuncionesPHPLocal::DecodificarUtf8($datosmultimediarel);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase FILES:\n\t\t\t\t\t\t\t\t\t$datosmultimediarel['multimediaubic'] = CARPETA_SERVIDOR_MULTIMEDIA.CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ARCHIVOS.$datosmultimediarel['multimediaubic'];\n\t\t\t\t\t\t\t\t\tif(isset($datosmultimediarel['previewubic']) && $datosmultimediarel['previewubic']!=\"\")\n\t\t\t\t\t\t\t\t\t\t$datosmultimediarel['previewubic'] = CARPETA_SERVIDOR_MULTIMEDIA.CARPETA_SERVIDOR_MULTIMEDIA_NOTICIAS.CARPETA_SERVIDOR_MULTIMEDIA_ORIGINALES.$datosmultimediarel['previewubic'];\n\t\t\t\t\t\t\t\t\t$arrayrelacionadas[$arrayrelacionada['noticiacodrel']]['multimedias']['archivo'][$datosmultimediarel['multimediacod']]= FuncionesPHPLocal::DecodificarUtf8($datosmultimediarel);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}*/\n\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t}\t\n\t\t$array['relacionadas'] = $arrayrelacionadas;\n\t\treturn true;\n\t}", "title": "" }, { "docid": "3129fa6b12b8dfa5e62fec0b85023d13", "score": "0.5400773", "text": "public static function GetAll()\n {\n $retornoArray = array();\n $path = \"./archivos/materias-profesores.json\";\n\n if(file_exists($path)) { //si existe\n $ar = fopen($path, \"r\"); //abro archivo\n if($ar != false) {\n while(!feof($ar)) {\n $linea = trim(fgets($ar)); //obtiene la linea sin espacios\n if($linea != \"\") //si llegamos a la linea vacia\n { \n $auxJWT = json_decode($linea); //convierte la linea en un json para que lo lea y sea guardable en Objeto\n $auxObj = new Asignacion($auxJWT->legajoProfesor, $auxJWT->idMateria, $auxJWT->turno);\n array_push($retornoArray, $auxObj); //agrega el objeto leido al array\n }\n }\n fclose($ar); //cierro el archivo\n }\n }\n return $retornoArray;\n }", "title": "" }, { "docid": "88bf95384bc7f5a82fb6cf10bceefaf6", "score": "0.53622913", "text": "function store_array($file, $arr) {\n file_put_contents($file, json_encode($arr));\n}", "title": "" }, { "docid": "5c13c9eccdc3976690c468a710c8e1da", "score": "0.53605086", "text": "public function grab_array_from_file()\n {\n $array = json_decode(file_get_contents(\"array.json\"), true);\n return $array;\n }", "title": "" }, { "docid": "ef7adaa7f4063e97b1ee73dd34ede35c", "score": "0.53518844", "text": "private function createJSON() {\n require ( 'sqlTableRowsArray.php' );\n $rawData = [];\n $json_elem = [];\n $json = [];\n for ( $i = 0; $i < $this->rows_num; $i++ ) {\n array_push( $rawData, $this->result->fetch_assoc());\n }\n foreach ( $rawData as $data ) {\n foreach ( $data as $key => $value ) {\n $json_elem[ $SQLTabRowsArray[ $key ]] = $value;\n }\n array_push( $json, $json_elem );\n }\n return $json;\n }", "title": "" }, { "docid": "36304fc357c79dfbcbc2b6c0ba5560a8", "score": "0.5334858", "text": "function ecrireJSON($tache, $terminer)\n{\n /*appel de la fonction \"tableauJSON\", $tabjson reçoit un tableau d'objet JSON*/\n $tabjson = tableauJSON();\n\n /*CREATION JSON*/\n /*Création d'une table ($tab) qui deviendra un objet JSON*/\n $tab = array(\"Nom\" => $tache, \"Terminer\" => $terminer );\n /*ajout de l'objet JSON dans la table qui reçois les objets JSON*/\n $tabjson[] = $tab;\n\n /*utilise la fonction \"sauvegardeJSON\" en lui envoyant un tablreau d'objets JSON ($tabjson)*/\n sauvegardeJSON($tabjson);\n}", "title": "" }, { "docid": "163b5922950aed1d716f03e7301df8a6", "score": "0.52962536", "text": "private function vdfToArray()\n\t{\n\t\t// load VDF data either from API call or fetching from file/url\n\t\t// no matter your method, $json must contain the VDF data to be parsed\n\t\t$json = $this->file_contents;\n\t\n\t\t// encapsulate in braces\n\t\t$json = \"{\\n$json\\n}\";\n\t\n\t\n\t\t// remove comments\n\t\t$pattern = '~([^/]*)//.*~';\n\t\t$replace = '$1';\n\t\t$json = preg_replace($pattern, $replace, $json);\n\t\n\t\t// replace open braces\n\t\t$pattern = '/\"([^\"]*)\"(\\s*){/';\n\t\t$replace = '\"${1}\": {';\n\t\t$json = preg_replace($pattern, $replace, $json);\n\t\n\t\t// replace values\n\t\t$pattern = '~\"([^\"]*)\"\\s*\"([^\"]*)\"(.*)~';\n\t\t$replace = '\"${1}\": \"${2}\",';\n\t\t$json = preg_replace($pattern, $replace, $json);\n\t\n\t\t// remove trailing commas\n\t\t$pattern = '/,(\\s*[}\\]])/';\n\t\t$replace = '${1}';\n\t\t$json = preg_replace($pattern, $replace, $json);\n\t\n\t\t// add commas\n\t\t$pattern = '/([}\\]])(\\s*)(\"[^\"]*\":\\s*)?([{\\[])/';\n\t\t$replace = '${1},${2}${3}${4}';\n\t\t$json = preg_replace($pattern, $replace, $json);\n\t\n\t\t// object as value\n\t\t$pattern = '/}(\\s*\"[^\"]*\":)/';\n\t\t$replace = '},${1}';\n\t\t$json = preg_replace($pattern, $replace, $json);\n\t\n\t\t$array = json_decode($json, true);\n\t\n\t\tif (!is_array($array)) {\n\t\t\tthrow new \\Exception('we don\\'t have an array');\n\t\t}\n\t\n\t\treturn $array;\n\t}", "title": "" }, { "docid": "b0a212e7a3fcdbbe90163c2e129edcd3", "score": "0.5255195", "text": "function get_array(){\r\n $datos= file_get_contents(\"https://data.cityofchicago.org/resource/u77m-8jgp.json\");\r\n $array = json_decode($datos, true);\r\n return $array;\r\n }", "title": "" }, { "docid": "9b66873d6e4848b9d8f8654682837801", "score": "0.5245093", "text": "public function baca(){\n if ( Storage::disk('local')->has(DATA) ) {\n $data = Storage::get(DATA);\n }else{\n $data = Storage::disk('local')->put(DATA, json_encode([]));\n }\n $array = json_decode($data);\n return $array;\n }", "title": "" }, { "docid": "c09008643d646c1ac97a4ebf945297ed", "score": "0.52365965", "text": "public function JSON_listCuentaEmpresaEditar($codigo){\n $lista_detalles = array();\n $dataCuenta= $this->empresa_model->listCuentaEmpresaCodigo($codigo);\n if(count($dataCuenta)>0){\n foreach ($dataCuenta as $key => $value) {\n $objeto = new stdClass();\n $objeto->CUENT_Codigo =$value->CUENT_Codigo;\n $objeto->CUENT_NumeroEmpresa =$value->CUENT_NumeroEmpresa;\n $objeto->CUENT_Titular =$value->CUENT_Titular;\n $objeto->CUENT_TipoPersona =$value->CUENT_TipoPersona;\n $objeto->CUENT_FechaRegistro =$value->CUENT_FechaRegistro;\n $objeto->BANC_Nombre =$value->BANC_Nombre;\n $objeto->MONED_Descripcion =$value->MONED_Descripcion;\n $objeto->CUENT_TipoCuenta =$value->CUENT_TipoCuenta;\n $objeto->BANC_Selec=$this->seleccionar_banco($value->BANP_Codigo);\n $lista_detalles[] = ($objeto); \n \n } \n \n }\n\n $resultado[] = array();\n $resultado = json_encode($lista_detalles,JSON_NUMERIC_CHECK);\n echo $resultado;\n\n}", "title": "" }, { "docid": "101561fc168c45ea62c1f94488efaec2", "score": "0.523608", "text": "function readTxt(){\r\r\n\r\r\n $miArrayDeObjetos = [];\r\r\n $myfile = fopen(\"fichero.txt\", \"r\") or die(\"No se pudo abrir el fichero!\");\r\r\n while(!feof($myfile)) {\r\r\n $lineaTxt = fgets($myfile);\r\r\n $datosLinea = explode(\"-\", $lineaTxt);\r\r\n //$datosJson = json_encode($datosLinea);\r\r\n array_push($miArrayDeObjetos, $datosLinea);\r\r\n }\r\r\n fclose($myfile);\r\r\n\r\r\n return $miArrayDeObjetos;\r\r\n}", "title": "" }, { "docid": "3bf38f14b61abcef9def772890307af1", "score": "0.52171797", "text": "function guardarUsuario($datos)\n{\n $usuarios = obtenerContenido(USUARIOS_KEY);\n\n //agregamos un ID a los datos del usuario\n $datos['id'] = count($usuarios) + 1;\n\n //agregamos los datos final del array.\n $usuarios[] = $datos;\n\n //guardamos el array en el archivo json\n guardarContenido(USUARIOS_KEY, $usuarios);\n}", "title": "" }, { "docid": "45433e80fe1e0de239ebd1de23549234", "score": "0.52027375", "text": "public function getDataJSON(){\r\n$aux = array(//cria array para receber os valore dos atributos\r\n'motor'=>$this->motor,\r\n'cavalos'=>$this->cavalos);\r\n\r\nreturn($aux);//retorno da funcao, array de string com os valores dos atributos\r\n}", "title": "" }, { "docid": "b0fe69c167ce7a27b4447f71e7cc9ed7", "score": "0.51988083", "text": "public function deleteAlumnotemporal()\n {\n try {\n $dbm = new DbmBecas($this->get(\"db_manager\")->getEntityManager());\n $content = trim(file_get_contents(\"php://input\"));\n $decoded = json_decode($content, true);\n $arraypadres = [];\n\n\n $dbm->getConnection()->beginTransaction();\n foreach ($decoded as $alumno) {\n\n $alumnoclavefamiliar = $dbm->getRepositorioById('CeAlumnoporclavefamiliar', 'alumnoid', $alumno);\n\n if($alumnoclavefamiliar) { \n $clavefamiliarid = $alumnoclavefamiliar->getClavefamiliarid()->getClavefamiliarid();\n $becas = $dbm->getRepositoriosById('BcSolicitudbeca', 'clavefamiliarid', $clavefamiliarid);\n foreach($becas as $beca) {\n $alumnossolicitud = $dbm->getRepositoriosById('BcSolicitudporalumno', 'solicitudid', $beca->getSolicitudid());\n if(count($alumnossolicitud) <= 1) {\n if($alumnossolicitud) {\n $dbm->removeManyRepositorio('BcBecarecomendadaporalumno', 'alumnosolicitudid', $alumnossolicitud[0]->getAlumnosolicitudid()); \n }\n $dbm->removeManyRepositorio('BcCuentabanco', 'solicitudbecaid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcDependienteseconomicoshijos', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcDeudascreditos', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcDomicilioestudiosocioeconomico', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcEgresomensuales', 'solicitudbecaid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcIngresosfamiliares', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcObservacionesestudiose', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcOtrosdependienteseconomicos', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcPadresotutoressolicitud', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcPersonareferencia', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcPropiedadesfamiliares', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcRecibirdocumentos', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcSituacionfamiliar', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcSolicitudbecadictamen', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcSolicitudfamilia', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcSolicitudingresos', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcVehiculos', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcVisitaestudiosocioeconomico', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeManyRepositorio('BcRecibirdocumentos', 'solicitudid', $beca->getSolicitudid());\n $dbm->removeManyRepositorio('BcPadresotutores', 'solicitudid', $beca->getSolicitudid());\n $solicitudalumno = $dbm->getOneByParametersRepositorio('BcSolicitudporalumno', \n ['solicitudid' => $beca->getSolicitudid()]);\n if($solicitudalumno) { $dbm->removeRepositorio($solicitudalumno); } \n\n $becasalumno = $dbm->getRepositoriosById('BcBecasporsolicitud', 'solicitudid', $beca->getSolicitudid());\n foreach($becasalumno as $becaalumno) {\n $becaid = $becaalumno->getBecaid()->getBecaid();\n $dbm->removeManyRepositorio('BcSolicitudbecadictamen', 'alumnoid', $alumno);\n $dbm->removeManyRepositorio('BcReconsideracionbeca', 'becaid', $becaid);\n $dbm->removeRepositorio($becaalumno);\n $dbm->removeRepositorio($dbm->getRepositorioById('BcBecas', 'becaid', $becaid));\n }\n $dbm->removeManyRepositorio('BcProvisionalbecas', 'solicitudid', $beca->getSolicitudid()); \n $dbm->removeRepositorio($beca);\n } else {\n $solicitudalumno = $dbm->getOneByParametersRepositorio('BcSolicitudporalumno', \n ['solicitudid' => $beca->getSolicitudid(), 'alumnoid' => $alumno]);\n if($solicitudalumno) {\n $becasalumno = $dbm->BuscarSolicitudes(['solicitudid' => $solicitudalumno->getSolicitudid()->getSolicitudid(), 'alumnoid' => $alumno]);\n if($becasalumno) {\n foreach($becasalumno as $becaalumno) {\n $becaid = $becaalumno->getBecaid()->getBecaid();\n $solicitudalumno = $dbm->getOneByParametersRepositorio('BcSolicitudporalumno', \n ['solicitudid' => $beca->getSolicitudid(), 'alumnoid' => $alumno]);\n if($solicitudalumno) { $dbm->removeRepositorio($solicitudalumno); }\n \n $dbm->removeManyRepositorio('BcSolicitudbecadictamen', 'alumnoid', $alumno);\n $dbm->removeManyRepositorio('BcReconsideracionbeca', 'becaid', $becaid);\n $dbm->removeRepositorio($becaalumno);\n $dbm->removeRepositorio($dbm->getRepositorioById('BcBecas', 'becaid', $becaid));\n }\n } else {\n $solicitudalumno = $dbm->getOneByParametersRepositorio('BcSolicitudporalumno', \n ['solicitudid' => $beca->getSolicitudid(), 'alumnoid' => $alumno]);\n if($solicitudalumno) { $dbm->removeRepositorio($solicitudalumno); }\n }\n\n $provisionbecas = $dbm->getByParametersRepositorios('BcProvisionalbecas', \n ['solicitudid' => $beca->getSolicitudid(), 'alumnoid' => $alumno]);\n foreach($provisionbecas as $provision) {\n $dbm->removeRepositorio($provision);\n }\n } \n }\n }\n\n $alumnos = $dbm->getRepositoriosById('CeAlumnoporclavefamiliar', 'clavefamiliarid', $clavefamiliarid);\n if(count($alumnos) == 1) {\n \n $padresporclavefamiliar = $dbm->getRepositoriosById('CePadresotutoresclavefamiliar', 'clavefamiliarid', $clavefamiliarid);\n\n foreach($padresporclavefamiliar as $padreporclave) {\n $dbm->removeRepositorio($padreporclave);\n $padreclavefamiliar = $dbm->getRepositoriosModelo(\"CePadresotutoresclavefamiliar\", [\"IDENTITY(d.padresotutoresid) AS padresotutoresid\"], \n [[\"padresotutoresid\", ['=', $padreporclave->getPadresotutoresid()],[\"clavefamiliarid\", ['!=', $clavefamiliarid]]]], false,true);\n if(count($padreclavefamiliar) == 0) {\n\n $usuario = $dbm->getRepositorioById('Usuario', 'padreotutorid', $padreporclave->getPadresotutoresid()->getPadresotutoresid());\n if($usuario) {\n $dbm->removeManyRepositorio('Cicloporusuario', 'usuarioid', $usuario->getUsuarioid());\n $dbm->removeManyRepositorio('Sesion', 'usuarioid', $usuario->getUsuarioid());\n if($usuario->getTipousuarioid()->getTipousuarioid() == 4) {\n $dbm->removeRepositorio($usuario);\n $dbm->removeRepositorio($padreporclave->getPadresotutoresid());\n } \n } else {\n $dbm->removeRepositorio($padreporclave->getPadresotutoresid());\n }\n }\n }\n \n $dbm->removeRepositorio($alumnoclavefamiliar);\n $dbm->removeRepositorio($alumnoclavefamiliar->getClavefamiliarid());\n \n } else if (count($alumnos)> 1) {\n $dbm->removeRepositorio($alumnoclavefamiliar);\n }\n };\n \n $planpago = $dbm->getRepositorioById('CjPlanpagoporalumno', 'alumnoid', $alumno);\n if($planpago) {\n $planpago->setAlumnoid(null);\n $dbm->saveRepositorio($planpago);\n };\n\n $dbm->removeManyRepositorio('CeAlumnoporpersonal', 'alumnoid', $alumno);\n $dbm->removeManyRepositorio('CeAlumnotelefono', 'alumnoid', $alumno);\n $dbm->removeManyRepositorio('CeAlumnolugarnacimiento', 'alumnoid', $alumno);\n $dbm->removeManyRepositorio('CeAlumnodomicilio', 'alumnoid', $alumno);\n $dbm->removeManyRepositorio('CeAlumnodinamicafamiliar', 'alumnoid', $alumno);\n $dbm->removeManyRepositorio('CeContactoemergencia', 'alumnoid', $alumno);\n $dbm->removeManyRepositorio('CeAlumnocorreo', 'alumnoid', $alumno);\n $dbm->removeManyRepositorio('CeAlumnodatomedico', 'alumnoid', $alumno);\n $dbm->removeManyRepositorio('CmNotificacionesleidas', 'alumnoid', $alumno);\n $alumnociclo = $dbm->getRepositoriosById('CeAlumnoporciclo', 'alumnoid', $alumno);\n if($alumnociclo) { \n foreach($alumnociclo as $ac) {\n $alumnofoto = $dbm->getRepositorioById('CeAlumnociclofoto', 'alumnoporcicloid', $ac);\n $dbm->removeRepositorio($alumnofoto);\n $dbm->removeRepositorio($ac);\n }\n }\n\n $solicitud = $dbm->getRepositorioById('Solicitudadmision', 'alumnoid', $alumno);\n $solicitud->setAlumnoid(null);\n $dbm->saveRepositorio($solicitud);\n\n $dbm->removeManyRepositorio('CeAlumno', 'alumnoid', $alumno);\n\n\n \n \n }\n $dbm->getConnection()->commit();\n return new View(\"Se han eliminado los alumno(s)\", Response::HTTP_OK);\n } catch (\\Exception $e) {\n if ($e->getPrevious()->getCode() == \"23000\") {\n return new View(\"No se puede eliminar el registro debido a que ya se encuentra relacionado.\", Response::HTTP_PARTIAL_CONTENT);\n } else {\n return new View($e->getMessage(), Response::HTTP_BAD_REQUEST);\n }\n }\n }", "title": "" }, { "docid": "bb4e1cb5b70a15fb8139c5c891a410b5", "score": "0.51873136", "text": "function getData($array) {\n $pars = json_decode($array);\n $conn=mysqli_connect('localhost','root','','alodokter');\n $query = \"select * from \".$pars->table;\n $result = mysqli_query($conn,$query);\n $data = array();\n while ($row = mysqli_fetch_assoc($result)) {\n $data[] = $row;\n }\n\n return json_encode($data);\n }", "title": "" }, { "docid": "eadbc6899c59e6fd7ba0bda4cd2888a5", "score": "0.5184084", "text": "function AppendToJSON($array, $filename){\n\t\t$str = @file_get_contents($filename);\n\n\t\tif($str !== \"\" && $str !== false){\n\t\t\t$contents = json_decode($str, true);\n\t\t\t$contents[] = $array;\n\t\t\tfile_put_contents($filename, json_encode($contents));\n\t\t}\n\t\telse {\n\t\t\tfile_put_contents($filename, json_encode([$array]));\n\t\t}\n\t}", "title": "" }, { "docid": "78931d8e6280e7c541976ad0504a6cde", "score": "0.51809907", "text": "function selectall($idminuta, $tipo){\n require_once \"libcon.php\";\n \n $con = Conectarfb();\n $sql = \"SELECT * FROM MINUTAREGION;\";\n\n $result = ibase_query($con, $sql);\n if (!$result){\n die('Error ' . ibase_errmsg());\n exit;\n }\n\n $dataminuta = array();\n $i = 0; \n while ($datosdetalle = ibase_fetch_object($result)){\n $dataminuta[$i] = $datosdetalle;\n $i++;\n }\n \n \n echo json_encode($dataminuta);\n \n \n ibase_free_result($result);\n ibase_close($con);\n\n\n\n //echo \"[]\";\n //ibase_close($con);\n}", "title": "" }, { "docid": "be5b0651e135e88b52ccab36d29f7375", "score": "0.5180742", "text": "public function insertOB(){\n $json = file_get_contents('data.json');\n $dataJson = json_decode($json, true);\n if($this->conexionBD()){\n // disminuye el riesgo de inyeccion sql\n $pQuery = $this->conBD->prepare($this->strInsert);\n foreach ($dataJson as $id => $value) {\n $pQuery ->bind_param(\n \"ssdiis\",\n $value['nombre'],\n $value['categoria'],\n $value['precio'],\n $value['cantidad_vendidos'],\n $value['en_almacen'],\n $value['fecha_alta']\n );\n $pQuery->execute();\n // comprobamos insert del ultimo id insertado\n $ultimoid = $this->conBD->insert_id;\n echo 'nombre: ',$value['nombre'],'ultimo id insertado: ', $ultimoid,'\\n';\n }\n $pQuery->close();\n $this->conBD->close();\n }\n }", "title": "" }, { "docid": "1a3bf082f0b5870e515d58c6a5e6bc03", "score": "0.5180663", "text": "public function guardarEmpresa($diaReg,$mes){\n $contenido_archivo= file_get_contents(\"../data/empresas.json\");\n $empresas=json_decode($contenido_archivo,true);\n $empresas[]= array(\n \"nombre_empresa\"=>$this->nombre_empresa,\n \"correoElectronico\"=>$this->correoElectronico,\n \"eslogan\"=> $this->eslogan,\n \"descripcion\"=> $this->descripcion,\n \"direccion\"=> $this->direccion,\n \"pais\"=> $this->pais,\n \"latitud\"=> $this->latitud,\n \"longitud\"=>$this->longitud,\n \"facebook\"=> $this->facebook,\n \"instagram\"=>$this->instagram,\n \"twitter\"=> $this->twitter,\n \"numeroTelefono\"=> $this->numeroTelefono,\n \"administradores\"=>[],\n \"estado\"=>array(\n \"diaReg\"=>$diaReg,\n \"entrada\"=>0,\n \"total_ventas\"=>0,\n \"total_ventas_mes\"=>0,\n \"mes\"=>$mes, //actualizar este mes cuando la empresa se registre o cuando haya un cambio de mes\n \"total_seguidoresPasado\"=>0,\n \"total_seguidores\"=>0,\n \"visitas\"=>0,\n \"pago\"=>0,\n \"visitaspasado\"=>0,\n \"estado_promociones\"=>array(\n \"vendidas\"=>0,\n \"carrito\"=>0 ),\n \"ventas_semana\"=>array(\n \"info\"=>array(\n \"num_semana\"=>date(\"W\"),\n \"dia_semana\"=>date(\"w\")-1,\n \"total_semana\"=>0\n ),\n \"domingo\"=>0,\n \"lunes\"=>0,\n \"martes\"=>0,\n \"miercoles\"=>0,\n \"jueves\"=>0,\n \"viernes\"=>0,\n \"sabado\"=>0\n ),\n \"inventario\"=>array(\n \"registrados\"=>0,\n \"promocion\"=>0,\n \"exis_baja\"=>0,\n )\n ),\n \"comentarios\"=>[],\n \"logotipo\"=> \"img/logoPerfil.png\",\n \"Banner\"=>0,\n \"sucursales\"=>[],\n \"productos\"=>[],\n \"promociones\"=> [],\n \"pedidos\"=>[],\n \"plan\"=>0\n );\n $indexEmp=sizeof($empresas)-1;\n $archivo=fopen(\"../data/empresas.json\",\"w\");\n fwrite($archivo,json_encode($empresas)); \n fclose($archivo);\n\n $contenido_archivol=file_get_contents(\"../data/plataforma.json\");\n $plataforma=json_decode($contenido_archivol,true);\n $plataforma[0][\"empresaActual\"]=$indexEmp;\n $archivo=fopen(\"../data/plataforma.json\",\"w\");\n fwrite($archivo,json_encode($plataforma)); \n fclose($archivo);\n mkdir(\"../archivos-subidos/empresas/empresa\".$indexEmp, 0700);\n \n\n \n }", "title": "" }, { "docid": "2ed3cc3b9e0d8bc7e61290a610631855", "score": "0.51804304", "text": "public function jsonSerialize()\r\n {\r\n $this->valueType = \"array\";\r\n $this->props('type',$this->uploadType);\r\n $this->props('uploadProps',$this->uploadProps);\r\n return array_merge(parent::jsonSerialize(), []);\r\n }", "title": "" }, { "docid": "3b59ccf0e02936a99ffbd33dd9cf4ebf", "score": "0.5176981", "text": "private function getFileData() : array\n {\n if ($this->fileNotSet())\n {\n throw new Exception(\"file not set\");\n }\n\n $jsonString = file_get_contents($this->fileName);\n\n if ($jsonString === false)\n {\n throw new Exception(\"can't get a file content from current fileName: \" . $this->fileName);\n }\n\n $jsonArray = json_decode($jsonString, true);\n\n $personsFromFile = [];\n\n if ($jsonArray === null)\n {\n // if $jsonString == \"\" then file is empty and it may be correct\n if ($jsonString != \"\")\n {\n throw new Exception(\"can't convert a json string from file: \" . $this->fileName);\n }\n }\n else\n {\n foreach ($jsonArray as $key => $value)\n {\n $person = new Person($value[\"name\"], $value[\"surname\"], $value[\"patronymic\"],\n $value[\"age\"], $value[\"profession\"]);\n\n array_push($personsFromFile, $person);\n }\n }\n\n return $personsFromFile;\n }", "title": "" }, { "docid": "457bb832a84a570b006f2545945a26b2", "score": "0.5154224", "text": "function getDatos(){\n $res = $this->Consulta('SELECT * FROM '.$this->Table .' WHERE '.$this->PrimaryKey.' = '.$this->_datos);\n print_r( json_encode( $res[0] ) );\n }", "title": "" }, { "docid": "457bb832a84a570b006f2545945a26b2", "score": "0.5154224", "text": "function getDatos(){\n $res = $this->Consulta('SELECT * FROM '.$this->Table .' WHERE '.$this->PrimaryKey.' = '.$this->_datos);\n print_r( json_encode( $res[0] ) );\n }", "title": "" }, { "docid": "c6e64fbff7f38a07dac44fcbaa90e7e2", "score": "0.51485556", "text": "public static function GuardarTodosJSON($dirFile, $alumnos)\n {\n if($alumnos != -1)\n {\n alumno::VaciarArchivo($dirFile);\n if(!(empty($alumnos)))\n {\n foreach($alumnos as $alumno)\n {\n $alumno->GuardarJSONIndividual($dirFile);\n }\n }\n }\n }", "title": "" }, { "docid": "22022260511959d792f9fa5eead051b2", "score": "0.5143286", "text": "public function GetArrayFromJson()\n {\n $objects = MTJson::Decode($this->ConfigJson);\n if ($objects == null) return null;\n $result = array();\n //---\n foreach ($objects as $obj)\n {\n $info = MTTickStatJson::GetFromJson($obj);\n //---\n $result[] = $info;\n }\n //---\n $objects = null;\n //---\n return $result;\n }", "title": "" }, { "docid": "eae80dca64fbbffd91c72dc2d4f2989f", "score": "0.5130047", "text": "public function GetArrayFromJson()\n {\n $objects = MTJson::Decode($this->ConfigJson);\n if ($objects == null) return null;\n $result = array();\n //---\n foreach ($objects as $obj)\n {\n $info = MTTickJson::GetFromJson($obj);\n //---\n $result[] = $info;\n }\n //---\n $objects = null;\n //---\n return $result;\n }", "title": "" }, { "docid": "f24aff0e62988c5771eb453346ed1272", "score": "0.51111984", "text": "public static function readAll(){\n $filePath = 'files/users.json'; \n\n $file = fopen($filePath, 'r');\n\n $data = fread($file, filesize($filePath));\n \n fclose($file);\n\n if(strlen($data)>1){\n\n $arrayJSON = json_decode($data);\n\n return $arrayJSON;\n }\n \n return $emptyArray = array();\n}", "title": "" }, { "docid": "017d8d51e5fea9d6470983786e9449d3", "score": "0.51070726", "text": "public function getjson() {\n $arrkey = $this->json[0];\n // remove first array from collection\n array_shift($this->json);\n // Loop through the arrays in json array\n foreach ($this->json as $key => $value) {\n // use array_combine and assign key and value\n $this->json[$key] = array_combine($arrkey, $value);\n }\n // JSON encode the resulting array and return\n return json_encode($this->json);\n }", "title": "" }, { "docid": "12ce2c561c8ef95cb07bb3fbfaa5c4ea", "score": "0.5102749", "text": "private static function CargarDesdeArchivo(){\n $usuarios = [];\n if( file_exists(TXT_PRODUCTOS) ){\n if(strlen(file_get_contents(TXT_PRODUCTOS)) > 0){\n $usuarios = json_decode(file_get_contents(TXT_PRODUCTOS),true);\n }\n }\n return $usuarios;\n }", "title": "" }, { "docid": "b3d8060eca65e39eab0cecedb26650a2", "score": "0.50775546", "text": "public function getArrayFieldJson( $fields, $childrenArr = null ) {\n $fieldJson = array();\n\n foreach( $fields as $field ) {\n\n //echo \"field=\".$field.\" \";\n\n if( $field == null ) {\n $fieldJson[] = null;\n continue;\n }\n\n $provider = $field->getProvider();\n $providerStr = $provider->getUserNameStr();\n\n //echo \"providerStr=\".$providerStr.\", \";\n\n $transformer = new DateTimeToStringTransformer(null,null,'m/d/Y');\n $dateStr = $transformer->transform($field->getCreationdate());\n\n $hist = array();\n $hist['id'] = $field->getId();\n $hist['text'] = $field.\"\";\n $hist['provider'] = $providerStr;\n $hist['date'] = $dateStr;\n $hist['validity'] = $field->getStatus();\n\n if( $childrenArr ) {\n foreach( $childrenArr as $child ) {\n $getMethod = \"get\".$child;\n //echo \"getMethod=\".$getMethod.\"<br>\";\n\n if( $child == \"keytype\" ) {\n $childValue = $field->$getMethod()->getId();\n //echo \"childValue=\".$childValue.\"<br>\";\n $hist[$child] = $childValue;\n $hist['keytypename'] = $field->$getMethod().\"\";\n } else\n if( $child == \"staintype\" ) {\n $childValue = $field->$getMethod()->getId();\n $hist[$child] = $childValue;\n } else\n if( $child == \"documents\" ) {\n $childs = $field->$getMethod();\n $children = array();\n foreach( $childs as $onechild ) {\n $childArr = array();\n $childArr[\"id\"] = $onechild->getId();\n $childArr[\"uniquename\"] = $onechild->getUniquename();\n $childArr[\"originalname\"] = $onechild->getOriginalnameClean();\n $childArr[\"size\"] = $onechild->getSize();\n $childArr[\"url\"] = $onechild->getAbsoluteUploadFullPath();\n $children[] = $childArr;\n }\n $hist[$child] = $children;\n } else\n if( $child == \"diseaseorigins\" || $child == \"diseasetypes\" ) {\n $childs = $field->$getMethod();\n $children = array();\n foreach( $childs as $onechild ) {\n $childArr = array();\n $childArr[\"id\"] = $onechild->getId();\n $childArr[\"name\"] = $onechild->getName().\"\";\n $children[] = $childArr;\n }\n $hist[$child] = $children;\n } else\n {\n $childValue = $field->$getMethod().\"\";\n //echo \"childValue=\".$childValue.\"<br>\";\n $hist[$child] = $childValue;\n }\n\n\n }\n }\n\n $fieldJson[] = $hist;\n\n }\n\n return $fieldJson;\n }", "title": "" }, { "docid": "f8901c86ba2329b14c935307ad014be5", "score": "0.5075426", "text": "function escreverArquivoArray($arr) {\n\t\t$fp = fopen('pessoas.txt', 'a+');\n\n //verifica se arquivo existe\n\t\tif ($fp) {\n //vai verificar os indices do vetor\n\t\t\tforeach($arr as $cpf => $dados) {\n\t\t\t\tif(!empty($dados)) {\n\t\t\t\t\t$linha = $cpf.\" - \".$dados['nome'].\" - \".$dados['endereco'].\" - \".$dados['telefone'];\n\t\t\t\t\t//escreve no arquivo efaz uma quebra de linha\n fputs($fp, \"$linha\\n\");\n\t\t\t\t}\n\t\t\t}\n//fecha depois de percorrer\n\t\t\tfclose($fp);\n\t\t}\n//mostra essa mensagem de ok\n\t\techo \"[OK] Dados escritos com Sucesso!\";\n\t}", "title": "" }, { "docid": "242239df986396e9f93a6ce79dfaf487", "score": "0.50669736", "text": "function upload_file_and_json_array_update($json_array,$element_id,$field) {\n $new_file = 'data/' . updload('webgis_file', '../data');\n return json_array_edit_element_field($json_array, $element_id, $field, $new_file);\n}", "title": "" }, { "docid": "1b0a22bc3894c760cb89c4faf464f6e6", "score": "0.50611997", "text": "public function getArray() {\r\n $json = [];\r\n foreach($this->_mapa as $key => $atribute){\r\n $json[$key] = $this->{\"_\".$key};\r\n }\r\n return $json;\r\n }", "title": "" }, { "docid": "c7719046faf18966233129d8331b928d", "score": "0.50517416", "text": "public function jsonSerialize(): array;", "title": "" }, { "docid": "c7719046faf18966233129d8331b928d", "score": "0.50517416", "text": "public function jsonSerialize(): array;", "title": "" }, { "docid": "9549676ca8a34dc045414be4aab8bb1b", "score": "0.5048626", "text": "private function readToArray() : bool\n {\n if (!$handle = fopen($this->filePath, 'r')) {\n return false;\n }\n\n $result = null;\n $headers = null;\n\n while ($row = fgetcsv($handle)) {\n if ($headers === null) {\n $headers = $row;\n continue;\n }\n\n $newRow = [];\n for ($col = 0; $col < count($row); $col++) {\n $newRow[$headers[$col]] = $row[$col];\n }\n\n $result[] = $newRow;\n }\n\n fclose($handle);\n\n $this->headers = $headers;\n $this->data = $result;\n\n return true;\n }", "title": "" }, { "docid": "0054e1fe82d6ec20d0c01f446e33dfd9", "score": "0.50423026", "text": "public static function getFiltroEsami(): array\n {\n return json_decode(\n file_get_contents(self::$path . DIRECTORY_SEPARATOR . \"filtro_esami.json\", true),\n true\n );\n }", "title": "" }, { "docid": "69653e6d30ce01982a885aec819952f9", "score": "0.5039767", "text": "function saveToJson($file = 'cities-br.json')\n {\n $parsed_cities = array();\n foreach ($this->cities as $state => $cities) {\n $parsed_cities[$state] = array();\n $cities_table = $cities->getElementById('municipios');\n foreach ($cities_table->getElementsByTagName('tr') as $city) {\n if ($city->hasAttribute('class')) {\n foreach ($city->getElementsByTagName('td') as $data) {\n if ($data->getAttribute('class') == 'codigo') {\n $cod = $data->nodeValue;\n }\n if ($data->getAttribute('class') == 'nome') {\n $name = $data->nodeValue;\n }\n }\n $parsed_cities[$state][$cod] = $name;\n }\n }\n }\n $json = json_encode($parsed_cities);\n file_put_contents($file, $json);\n }", "title": "" }, { "docid": "a14d6b1f2c9f8c2fa9de5feb94720692", "score": "0.5038362", "text": "abstract public function toDbArray();", "title": "" }, { "docid": "369f4b081e8aa1d52f8d852888064cc3", "score": "0.5033221", "text": "function refactoreArray(&$file_post) {\n\n $file_ary = array();\n $file_count = count($file_post['name']);\n $file_keys = array_keys($file_post);\n\n for ($i=0; $i<$file_count; $i++) {\n foreach ($file_keys as $key) {\n $file_ary[$i][$key] = $file_post[$key][$i];\n }\n }\n\n return $file_ary;\n}", "title": "" }, { "docid": "3b0f65d39cb4a138bc1fc3982a4c8254", "score": "0.50330687", "text": "function get_full_table_as_json($db_name,$table_name,$query,$obj){\r\n $con = mysqli_connect(\"localhost\",\"root\",\"\",$db_name);\r\n $output=\"\";\r\n $col_name[] =\"\";\r\n $col_type[] = \"\";\r\n $sel_col_name_query =\r\n \"SELECT COLUMN_NAME FROM INFORMATION_SCHEMA.COLUMNS \r\n WHERE table_name = '\".$table_name.\"'\r\n AND table_schema = '\".$db_name.\"';\";\r\n $i = 0;\r\n \r\n $result= mysqli_query($con, $sel_col_name_query);\r\n if($result->num_rows == 0){ // Co reqult\r\n echo \"something wrong with database connection! OR wrong Table name\";\r\n }\r\n else\r\n { //Result got!\r\n //Step 1:\r\n // Filling in the array for col name and type so can be used as needed\r\n $result1= mysqli_query($con, $query);\r\n $row1 = $result1->fetch_assoc();\r\n $output.= '{ '.$obj.' : [ {';\r\n \r\n echo $output;\r\n while($row = $result->fetch_assoc())\r\n {\r\n $output.= '\"'.$row[\"COLUMN_NAME\"].'\":\"'.$row1[$row[\"COLUMN_NAME\"]].'\"';\r\n $i++;\r\n if($i+1 <= count($row))\r\n $output .= ',';\r\n } \r\n $output .='}]}';\r\n }\r\n return $output;\r\n}", "title": "" }, { "docid": "1e7606ef2d945a5bc74892e7cf0787ec", "score": "0.50301856", "text": "public function agregarAlCarrito($idUsuario){\n $contenido_archivo= file_get_contents(\"../data/usuarios.json\");\n $usuarios=json_decode($contenido_archivo,true);\n //verificar que el elemento no se agregue dos veces al carrito\n $existe=false;\n if(sizeof($usuarios[$idUsuario][\"carrito\"])>0){\n for($i=0; $i<sizeof($usuarios[$idUsuario][\"carrito\"]);$i++){\n if($usuarios[$idUsuario][\"carrito\"][$i][\"idCat\"]==$this->idCat && $usuarios[$idUsuario][\"carrito\"][$i][\"idPromo\"]==$this->idPromo){\n $existe=true;\n }\n }\n }\n \n if($existe==false){\n $usuarios[$idUsuario][\"carrito\"][]=array(\n \"idCat\"=>$this->idCat,\n \"idPromo\"=>$this->idPromo,\n \"idCantidad\"=>$this->cantidad\n );\n $archivo=fopen(\"../data/usuarios.json\",\"w\");\n fwrite($archivo,json_encode($usuarios)); \n fclose($archivo);\n \n }\n $estado=Array(\"estado\"=>$existe);\n echo json_encode($estado);\n }", "title": "" }, { "docid": "60c96c44b35a4554a4078957d80a88ba", "score": "0.5026133", "text": "function load_input_file_into_php_array(){\n $data_string = file_get_contents('input.json');\n $data_array = json_decode($data_string, true);\n return $data_array;\n}", "title": "" }, { "docid": "5f7b7b5149028ff2ea90bbd0905364f4", "score": "0.50251275", "text": "function generarTabla() {\n $tabla = \n [\n [\n \"id\" => 1,\n \"Titulo\" => \"Los señores del tiempo\",\n \"Autor\" => \"García Sénz de Urturi\",\n \"Editorial\" => \"Tranfe\",\n \"Genero\" => \"Novela\",\n \"Precio\" => 19.50\n ],\n [\n \"id\" => 2,\n \"Titulo\" => \"El Rey recibe\",\n \"Autor\" => \"Eduardo Mendoza\",\n \"Editorial\" => \"Alfaguara\",\n \"Genero\" => \"Novela\",\n \"Precio\" => 20.50\n ],\n [\n \"id\" => 3,\n \"Titulo\" => \"Diario de una mujer\",\n \"Autor\" => \"Eduardo Mendoza\",\n \"Editorial\" => \"Novelda\",\n \"Genero\" => \"Novela\",\n \"Precio\" => 12.95\n ],\n [\n \"id\" => 4,\n \"Titulo\" => \"El quijote de la Mancha\",\n \"Autor\" => \"Miguel de Cervantes\",\n \"Editorial\" => \"Santillana\",\n \"Genero\" => \"Juvenil\",\n \"Precio\" => 15.95\n ],\n ];\n\n return $tabla;\n}", "title": "" }, { "docid": "cd5f2201c15a9b411ec18b12d0f59392", "score": "0.50235164", "text": "public static function getCorsiDiLaurea(): array\n {\n return json_decode(\n file_get_contents(self::$path . DIRECTORY_SEPARATOR . \"corsi_di_laurea.json\", true),\n true\n );\n }", "title": "" }, { "docid": "f77347d17a88509c8cd58062f9aeccfb", "score": "0.502162", "text": "public function plataformas(){\n\t\t$plataformas = new Plataforma();\n\t\t$plataformas->search_clause = '1';\n\t\t$this->plataformas = $plataformas->read('id,nombre,empresa');\n\t\t$plataformasjson = [];\n\t\tforeach ($this->plataformas as $plataforma) {\n\t\t\t$plataforma_tmp = null;\n\t\t\t$plataforma_tmp->id = $plataforma->id; \n\t\t\t$plataforma_tmp->nombre = $plataforma->nombre; \n\t\t\t$plataforma_tmp->empresa = $plataforma->empresa; \n\t\t\tarray_push($plataformasjson, $plataforma_tmp);\n\n\t\t}\n\t\techo json_encode($plataformasjson);\n\t\tif($this->get('id') == 'archivo'){\n\t\t\tfile_put_contents($this->config->document_root.'datos.json',json_encode($plataformasjson));\n\t\t}\n\t}", "title": "" }, { "docid": "215a2743e65887118126eb4e80dd36b8", "score": "0.5012966", "text": "public static function consultarAlumno($nombreParametro, $parametro)\n {\n $archivo = \"alumnos.json\";\n $arrayObj = Alumno::LeerArchivo($archivo);\n $arrayResultante = array(); \n if(file_exists($archivo) == true)\n {\n $flag = false;\n for ($i=0; $i < count($arrayObj); $i++) \n { \n //strcasecmp es case INsensitive\n if (strcasecmp($arrayObj[$i][$nombreParametro], $parametro) == 0) {\n $obj = $arrayObj[$i];\n array_push($arrayResultante, $obj);\n $flag = true;\n if($nombreParametro == \"email\")\n break;\n }\n }\n if ($flag) {\n return $arrayResultante;\n }\n else\n {\n echo \"No existe alumno con \" . $nombreParametro . \" \" . $parametro;\n }\n }\n else\n {\n echo \"No hay alumnos cargados\";\n }\n }", "title": "" }, { "docid": "3c408c223f44dd2878befd4336b9ddcf", "score": "0.5010622", "text": "public function array_fromdb($params = array()) \n {\n $field_key = $params['field']->name;\n if (isset($params['result'][$field_key]))\n {\n $params['result'][$field_key] = json_decode($params['result'][$field_key],TRUE);\n }\n \n }", "title": "" }, { "docid": "665ba3a679ef020994b2031429d955d7", "score": "0.5009897", "text": "function estructuraDatos()\n {\n $dato['estructura'] = array();\n //0\n $dato['estructura'][] = array(\n 'campo' => 'id',\n 'texto' => 'Identificador',\n 'tipo' => 'text',\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => 'disabled',\n 'nuevo' => 0,\n // 'mostrar'=>false,\n 'ancho' => '40'\n );\n //1\n $dato['estructura'][] = array(\n 'campo' => 'codigo_producto',\n 'texto' => 'Código 13',\n 'tipo' => 'text',\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => 'disabled',\n 'nuevo' => \"\",\n // 'mostrar'=>false,\n 'ancho' => '40'\n );\n //2\n $dato['estructura'][] = array(\n 'campo' => 'id_producto',\n 'texto' => 'Código Boka',\n 'tipo' => 'text',\n 'color' => 'black',\n 'editar' => \"\",\n 'nuevo' => \"\",\n 'requerido' => true,\n 'ancho' => '30'\n );\n //3\n $dato['estructura'][] = array(\n 'campo' => 'nombre',\n 'texto' => 'Nombre producto',\n 'tipo' => 'text',\n 'color' => 'black',\n 'editar' => \"\",\n 'nuevo' => \"\",\n 'requerido' => true,\n 'ancho' => '30'\n );\n //4\n $dato['estructura'][] = array(\n 'campo' => 'nombre_generico',\n 'texto' => 'Nombre genérico',\n 'tipo' => 'text',\n 'color' => 'black',\n 'editar' => \"\",\n 'nuevo' => \"\",\n 'requerido' => true,\n 'ancho' => '30'\n );\n //5\n $dato['estructura'][] = array(\n 'campo' => 'codigo_ean',\n 'texto' => 'Código EAN',\n 'tipo' => 'text',\n 'editar' => \"\",\n 'nuevo' => \"\",\n 'color' => 'black',\n 'requerido' => false,\n 'ancho' => '30'\n );\n //6\n $dato['estructura'][] = array(\n 'campo' => 'id_grupo',\n 'texto' => 'Grupo',\n 'tipo' => 'seleccion',\n 'color' => 'black',\n 'editar' => \"\",\n 'ver' => \"disabled\",\n 'nuevo' => 0,\n 'seleccion' => array('tabla' => 'pe_grupos', 'indice' => 'id_grupo', 'valor' => 'nombre_grupo'),\n 'requerido' => true,\n 'ancho' => '30'\n );\n //7\n $dato['estructura'][] = array(\n 'campo' => 'id_familia',\n 'texto' => 'Familia',\n 'tipo' => 'seleccion',\n 'color' => 'black',\n 'editar' => \"\",\n 'ver' => \"disabled\",\n 'nuevo' => 0,\n 'seleccion' => array('tabla' => 'pe_familias', 'indice' => 'id_familia', 'valor' => 'nombre_familia'),\n 'requerido' => true,\n 'ancho' => '30'\n );\n //8\n $dato['estructura'][] = array(\n 'campo' => 'peso_real',\n 'texto' => 'Peso real (Kg)',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'editar' => \"\",\n 'nuevo' => 0,\n 'decimales' => 3,\n 'color' => 'black',\n 'requerido' => false,\n 'ancho' => '30'\n );\n //9\n $dato['estructura'][] = array(\n 'campo' => 'anada',\n 'texto' => 'Añada',\n 'tipo' => 'text',\n 'color' => 'black',\n 'editar' => \"\",\n 'nuevo' => \"\",\n 'requerido' => false,\n 'ancho' => '30'\n );\n //10\n $dato['estructura'][] = array(\n 'campo' => 'stock_minimo',\n 'texto' => 'Stock mínimo',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 0,\n 'editar' => \"\",\n 'nuevo' => 0,\n 'color' => 'black',\n 'requerido' => true,\n 'ancho' => '30'\n );\n //11\n $dato['estructura'][] = array(\n 'campo' => 'control_stock',\n 'texto' => 'Control stock',\n 'tipo' => 'seleccion',\n 'color' => 'black',\n 'editar' => \"\",\n 'ver' => \"disabled\",\n 'nuevo' => \"0\",\n 'requerido' => true,\n 'seleccion' => array('tabla' => 'pe_si_no', 'indice' => 'indice', 'valor' => 'valor'),\n 'ancho' => '30'\n );\n //12\n $dato['estructura'][] = array(\n 'campo' => 'fecha_alta',\n 'texto' => 'Fecha alta',\n 'tipo' => 'date',\n 'color' => 'black',\n 'editar' => \"disabled\",\n 'nuevo' => date(\"Y-m-d\"),\n 'requerido' => true,\n 'ancho' => '30'\n );\n //13\n $dato['estructura'][] = array(\n 'campo' => 'fecha_modificacion',\n 'texto' => 'Fecha modificacion',\n 'tipo' => 'date',\n 'editar' => \"disabled\",\n 'nuevo' => date(\"Y-m-d\"),\n 'color' => 'black',\n 'requerido' => true,\n 'ancho' => '30'\n );\n //14\n $dato['estructura'][] = array(\n 'campo' => 'modificado_por',\n 'texto' => 'Modificado por',\n 'tipo' => 'seleccion',\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"disabled\",\n 'ver' => \"disabled\",\n 'nuevo' => $this->session->id,\n 'seleccion' => array('tabla' => 'pe_users', 'indice' => 'id', 'valor' => 'nombre'),\n 'ancho' => '30'\n );\n //15\n $dato['estructura'][] = array(\n 'campo' => 'unidades_caja',\n 'texto' => 'Unidades caja/compra',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 0,\n 'editar' => \"\",\n 'nuevo' => 1000,\n 'color' => 'black',\n 'requerido' => true,\n 'ancho' => '30'\n );\n //16\n $dato['estructura'][] = array(\n 'campo' => 'id_proveedor_web',\n 'texto' => 'Proveedor',\n 'tipo' => 'seleccion',\n 'columnas' => '4',\n 'editar' => \"\",\n 'ver' => \"disabled\",\n 'nuevo' => 0,\n 'color' => 'black',\n 'seleccion' => array('tabla' => 'pe_proveedores', 'indice' => 'id_proveedor', 'valor' => 'nombre_proveedor'),\n 'requerido' => true,\n 'ancho' => '30'\n );\n //17\n $dato['estructura'][] = array(\n 'campo' => 'tipo_unidad',\n 'texto' => 'Tipo unidad',\n 'tipo' => 'seleccion',\n 'editar' => \"\",\n 'ver' => \"disabled\",\n 'color' => 'black',\n 'nuevo' => 0,\n 'seleccion' => array('tabla' => 'pe_tipo_unidades', 'indice' => 'indice', 'valor' => 'valor'),\n 'requerido' => true,\n // 'mostrar'=>false,\n 'ancho' => '30'\n );\n //18\n $dato['estructura'][] = array(\n 'campo' => 'precio_ultimo_unidad',\n 'texto' => 'Precio Compra (€/unidad compra)',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 3,\n 'color' => 'black',\n 'nuevo' => 0,\n 'requerido' => true,\n 'editar' => \"\",\n 'ancho' => '30'\n );\n //19\n $dato['estructura'][] = array(\n 'campo' => 'precio_ultimo_peso',\n 'texto' => 'Precio Compra (€/Kg compra)',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 3,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"\",\n 'nuevo' => 0,\n 'ancho' => '30'\n );\n //20\n $dato['estructura'][] = array(\n 'campo' => 'descuento_1_compra',\n 'texto' => 'Descuento compra (%)',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 3,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"\",\n 'nuevo' => 0,\n 'ancho' => '30'\n );\n //21\n $dato['estructura'][] = array(\n 'campo' => 'precio_transformacion_unidad',\n 'texto' => 'Precio transformación (€/unidad)',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 3,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"\",\n 'nuevo' => 0,\n\n // 'editar'=>false,\n // 'mostrar'=>false,\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'precio_transformacion_peso',\n 'texto' => 'Precio transformación (€/Kg)',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 3,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"\",\n 'nuevo' => 0,\n\n // 'editar'=>false,\n // 'mostrar'=>false,\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'precio_compra',\n 'texto' => 'Precio Compra Final en Tienda',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 3,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"disabled\",\n 'nuevo' => 0,\n\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'unidades_precio',\n 'texto' => 'Unidades Precio',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 0,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"\",\n 'nuevo' => 1000,\n\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'tarifa_venta',\n 'texto' => 'Tarifa PVP',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 2,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"\",\n 'nuevo' => 0,\n\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'beneficio_recomendado',\n 'texto' => 'Beneficio recomendado (%)',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 2,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"\",\n 'nuevo' => 35000,\n\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'margen_real_producto',\n 'texto' => 'Margen (%)',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 2,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"disabled\",\n 'nuevo' => 0,\n\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'stock_total',\n 'texto' => 'Total unidades stock',\n 'tipo' => 'number',\n 'factor' => 1,\n 'decimales' => 0,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"disabled\",\n 'nuevo' => 0,\n\n // 'mostrar'=>false,\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'valoracion',\n 'texto' => 'Valor stock precio compra actual',\n 'tipo' => 'number',\n 'factor' => 1,\n 'decimales' => 2,\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"disabled\",\n 'nuevo' => 0,\n\n // 'mostrar'=>false,\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'iva',\n 'texto' => 'IVA',\n 'tipo' => 'number',\n 'factor' => 1000,\n 'decimales' => 2,\n 'color' => 'black',\n 'requerido' => false,\n 'editar' => 'disabled',\n 'nuevo' => 0,\n\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'url_producto',\n 'texto' => 'Url producto',\n 'tipo' => 'text',\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"\",\n 'nuevo' => \"\",\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'url_imagen_portada',\n 'texto' => 'Imagen Producto',\n 'tipo' => 'text',\n 'color' => 'black',\n 'requerido' => true,\n 'editar' => \"\",\n 'nuevo' => \"\",\n 'ancho' => '30'\n );\n $dato['estructura'][] = array(\n 'campo' => 'notas',\n 'texto' => 'Notas',\n 'tipo' => 'text',\n 'color' => 'black',\n 'editar' => \"\",\n 'nuevo' => \"\",\n 'requerido' => false,\n 'ancho' => '30'\n );\n\n // $dato['estructura'][] = array(\n // 'campo' => 'espack',\n // 'texto' => 'Es Pack?',\n // 'tipo' => 'checkbox',\n // 'color' => 'black',\n // 'editar' => \"\",\n // 'nuevo' => \"\",\n // 'requerido' => false,\n // 'ancho' => '30'\n // );\n\n\n return $dato['estructura'];\n }", "title": "" }, { "docid": "d2fc72ddaf5bb1d4f9ed9532267f27ee", "score": "0.50097907", "text": "function arrayToJson($name, $array, $destination = \"../cache/\") {\n $fp = fopen($destination . $name . \".json\", 'w');\n fwrite($fp, json_encode($array));\n fclose($fp);\n }", "title": "" }, { "docid": "16b5e3d6161dfab165dd94c74c716eae", "score": "0.49867725", "text": "public function readArray()\n {\n return $this->getFile()->readArray();\n }", "title": "" }, { "docid": "2aa75926e21ef07a22b4c8143cf834f3", "score": "0.49833313", "text": "public function parseArray(): void\n {\n $this->type = self::TYPE_ARRAY;\n }", "title": "" }, { "docid": "f323372f45640ba527fd90aa29e4e451", "score": "0.4980035", "text": "function readArray()\n {\n $ret = array(); // init the array object\n $this->amf0storedObjects[] = & $ret;\n $length = $this->readLong(); // get the length of the array\n for ($i = 0; $i < $length; $i++) { // loop over all of the elements in the data\n $type = $this->readByte(); // grab the type for each element\n $ret[] = $this->readData($type); // grab each element\n }\n return $ret; // return the data\n\n }", "title": "" }, { "docid": "5cc49e16267ed345ea57f5fea7f8a77d", "score": "0.49792787", "text": "public function toArray() : array\n {\n $header = explode(' ', $this->output['result'][1]);\n $initial_header_length = 0;\n\n // $columns armazena o nome da coluna, seu inicio e fim\n foreach($header as $h) {\n $key = trim(substr($this->output['result'][0], $initial_header_length, strlen($h)));\n\n $columns[] = ['name' => $key, 'start' => $initial_header_length, 'end' => strlen($h)];\n\n $initial_header_length += strlen($h) + 2;\n }\n\n $components = array_slice($this->output['result'], 2);\n\n $item_counter = 0;\n foreach ($components as $comp) { // retorna a linha do componente\n foreach($columns as $column) { // retorna o item da coluna\n $item[$column['name']] = utf8_encode(trim(substr($comp, $column['start'], $column['end'])));\n }\n\n $result[$item_counter++] = $item;\n }\n\n return $result;\n }", "title": "" }, { "docid": "43632631901ff935c5a0147d6033e5ca", "score": "0.49792388", "text": "function dump_json_row($cols, $values, $is_first) {\n $row = array();\n foreach ($cols as $col) {\n $v = null;\n foreach ($values as $i => $value) {\n if ($col->col == $value->col) {\n $v = $value->content;\n unset($values[$i]);\n break;\n }\n }\n array_push($row, $v);\n }\n if (!$is_first) {\n print(',');\n }\n print(\"\\n \" . json_encode($row));\n \n}", "title": "" }, { "docid": "9175c9adb1e2a25e652554b974e24ef1", "score": "0.49721086", "text": "function guardarUsuario($post) {\n\n if (count($errors) ==0) {\n $usuario = [\n 'name' => $post['name'],\n 'lastname' => $post['lastname'],\n 'email' => $post['email'],\n 'password' => password_hash ($post['password'] , PASSWORD_DEFAULT),\n ];\n\n $usuarios = file_get_contents('user_data.json');\n\n $array_data = json_decode($usuarios, true);\n\n $array_data['usuarios'][] = $usuario;\n\n $json = json_encode($array_data, JSON_PRETTY_PRINT);\n\n file_put_contents('user_data.json', $json);\n }\n\n}", "title": "" }, { "docid": "ae5e029a6f4612795ac2328c47df8b48", "score": "0.49666125", "text": "public function getDataAsArrayE() {\n\t\t$res = [];\n\t\tforeach($this->getFieldObjects() as $field) {\n\t\t\t$name = $field->getName(); //['name'];\n\t\t\tif($name == null) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t$res[$name] = $this->getE($name);\n\t\t}\n\t\treturn $res;\n\t}", "title": "" }, { "docid": "f5ab2880e60642bc4fa449741700d374", "score": "0.49642926", "text": "public function export_csv_array(){\n\t\theader(\"Content-type: application/csv\");\n header(\"Content-Disposition: attachment; filename=\\\"cassava_data\".\".csv\\\"\");\n header(\"Pragma: no-cache\");\n header(\"Expires: 0\");\n\n\t \t// Open the write output stream\n $handle = fopen('php://output', 'w');\n\n // Get the cleaned cassava data\n $result = $this->cassava_model->getdata();\n\n $flag = false;\n foreach ($result as $row) {\n\t\t // Convert stdClass $row object returned from query to normal array\n\t\t $array = json_decode(json_encode($row), True);\n\n\t\t // Write normalized row to CSV\n \tfputcsv($handle, $array);\n }\n fclose($handle);\n exit; \n\t}", "title": "" }, { "docid": "2a999ba37e4ae37d734a5914f862d3ef", "score": "0.49641547", "text": "function readArray() {\n\t\t$ret = array(); // init the array object\n\t\t$this->amf0storedObjects[] = & $ret;\n\t\t$length = $this->readLong(); // get the length of the array\n\t\tfor ($i = 0; $i < $length; $i++) { // loop over all of the elements in the data\n\t\t\t$type = $this->readByte(); // grab the type for each element\n\t\t\t$ret[] = $this->readData($type); // grab each element\n\t\t} \n\t\treturn $ret; // return the data\n\t\t\n\t}", "title": "" }, { "docid": "b0264c78228bd910976e4b6c1915191d", "score": "0.49629143", "text": "protected function dataMapping()\n {\n $objectsDB = [];\n $resultDB = $this->getTableObject();\n foreach ($resultDB as $row) {\n if (!isset($objectsDB[$row->selected_table])) {\n $objectsDB[$row->selected_table] = [];\n }\n if (!isset($objectsDB[$row->selected_table][\"columns\"])) {\n $objectsDB[$row->selected_table][\"columns\"] = [];\n }\n if (!isset($objectsDB[$row->selected_table][\"columns\"][$row->selected_column])) {\n $objectsDB[$row->selected_table][\"columns\"][$row->selected_column] = [];\n }\n if (!isset($objectsDB[$row->selected_table][\"columns\"][$row->selected_column][\"name\"])) {\n $objectsDB[$row->selected_table][\"columns\"][$row->selected_column][\"name\"] = $row->selected_column;\n }\n if (!isset($objectsDB[$row->selected_table][\"columns\"][$row->selected_column][\"selected_data_type\"])) {\n $objectsDB[$row->selected_table][\"columns\"][$row->selected_column][\"selected_data_type\"] = $row->selected_data_type;\n }\n if (!isset($objectsDB[$row->selected_table][\"columns\"][$row->selected_column][\"selected_length\"])) {\n $objectsDB[$row->selected_table][\"columns\"][$row->selected_column][\"selected_length\"] = $row->selected_length;\n }\n if (!isset($objectsDB[$row->selected_table][\"columns\"][$row->selected_column][\"is_nullable\"])) {\n $objectsDB[$row->selected_table][\"columns\"][$row->selected_column][\"is_nullable\"] = $row->is_nullable;\n }\n if (!isset($objectsDB[$row->selected_table][\"columns\"][$row->selected_column][\"extra_information\"])) {\n $objectsDB[$row->selected_table][\"columns\"][$row->selected_column][\"extra_information\"] = $row->extra_information;\n }\n }\n\n return $objectsDB;\n }", "title": "" }, { "docid": "4701a98828a6bdf6d4dfa3eb73d53704", "score": "0.49627653", "text": "protected function getRecordFromArray($ar)\n\t{\n\t\t$row = [];\n\t\tif (is_array($ar)) {\n\t\t\tforeach ($ar as $fldname => $val) {\n\t\t\t\tif (array_key_exists($fldname, $this->fields) && ($this->fields[$fldname]->Visible || $this->fields[$fldname]->IsPrimaryKey)) { // Primary key or Visible\n\t\t\t\t\t$fld = &$this->fields[$fldname];\n\t\t\t\t\tif ($fld->HtmlTag == \"FILE\") { // Upload field\n\t\t\t\t\t\tif (EmptyValue($val)) {\n\t\t\t\t\t\t\t$row[$fldname] = NULL;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif ($fld->DataType == DATATYPE_BLOB) {\n\t\t\t\t\t\t\t\t$url = FullUrl(GetApiUrl(Config(\"API_FILE_ACTION\"),\n\t\t\t\t\t\t\t\t\tConfig(\"API_OBJECT_NAME\") . \"=\" . $fld->TableVar . \"&\" .\n\t\t\t\t\t\t\t\t\tConfig(\"API_FIELD_NAME\") . \"=\" . $fld->Param . \"&\" .\n\t\t\t\t\t\t\t\t\tConfig(\"API_KEY_NAME\") . \"=\" . rawurlencode($this->getRecordKeyValue($ar)))); //*** need to add this? API may not be in the same folder\n\t\t\t\t\t\t\t\t$row[$fldname] = [\"type\" => ContentType($val), \"url\" => $url, \"name\" => $fld->Param . ContentExtension($val)];\n\t\t\t\t\t\t\t} elseif (!$fld->UploadMultiple || !ContainsString($val, Config(\"MULTIPLE_UPLOAD_SEPARATOR\"))) { // Single file\n\t\t\t\t\t\t\t\t$url = FullUrl(GetApiUrl(Config(\"API_FILE_ACTION\"),\n\t\t\t\t\t\t\t\t\tConfig(\"API_OBJECT_NAME\") . \"=\" . $fld->TableVar . \"&\" .\n\t\t\t\t\t\t\t\t\t\"fn=\" . Encrypt($fld->physicalUploadPath() . $val)));\n\t\t\t\t\t\t\t\t$row[$fldname] = [\"type\" => MimeContentType($val), \"url\" => $url, \"name\" => $val];\n\t\t\t\t\t\t\t} else { // Multiple files\n\t\t\t\t\t\t\t\t$files = explode(Config(\"MULTIPLE_UPLOAD_SEPARATOR\"), $val);\n\t\t\t\t\t\t\t\t$ar = [];\n\t\t\t\t\t\t\t\tforeach ($files as $file) {\n\t\t\t\t\t\t\t\t\t$url = FullUrl(GetApiUrl(Config(\"API_FILE_ACTION\"),\n\t\t\t\t\t\t\t\t\t\tConfig(\"API_OBJECT_NAME\") . \"=\" . $fld->TableVar . \"&\" .\n\t\t\t\t\t\t\t\t\t\t\"fn=\" . Encrypt($fld->physicalUploadPath() . $file)));\n\t\t\t\t\t\t\t\t\tif (!EmptyValue($file))\n\t\t\t\t\t\t\t\t\t\t$ar[] = [\"type\" => MimeContentType($file), \"url\" => $url, \"name\" => $file];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$row[$fldname] = $ar;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$row[$fldname] = $val;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $row;\n\t}", "title": "" }, { "docid": "108233c6dd4cbd8187023606e135b89a", "score": "0.49579725", "text": "public function getArray() {\r\n if ($this->isFileActual() === false) {\r\n $data = $this->parse();\r\n $this->store($data);\r\n } else {\r\n $data = $this->load();\r\n }\r\n return $data;\r\n }", "title": "" }, { "docid": "d53ee921f94999b8fbc8cbb554508cde", "score": "0.4957274", "text": "public function update_json_file_list()\n\t{\n $this->db->select('*');\n $this->db->from('begoo_file');\n\t\t$query = $this->db->get();\n\t\t\n\t\t$verdict = $query->num_rows(); \n\n\t\tif($verdict > 0)\n\t\t{\n\t\t\twrite_file('./assets/json/all_file_uploaded.json',json_encode(array_reverse($query->result_array())));\n\n\t\t\t$this->db->select('file_cat');\n $this->db->from('begoo_file');\n $this->db->distinct();\n\t\t $query2 = $this->db->get();\n\n\t\t write_file('./assets/json/all_file_uploaded_cat.json',json_encode(array_reverse($query2->result_array())));\n\t\t\treturn $query2->result_array();\n\t\t}\n\t}", "title": "" }, { "docid": "16f5aa37ebf91525e781219460adfbba", "score": "0.49564013", "text": "public function getAsArray(){\n $this->utente=serialize($this->utente);\n \t$result=array();\n \tforeach($this as $key => $value) {\n \t\tif (!is_array($value) && !is_object($value)) \n \t\t\t$result[$key]= $value;\n \t}\n \treturn $result;\n\n }", "title": "" }, { "docid": "4f1fd16d7e1a6461399f52986f78de72", "score": "0.49484056", "text": "function getFichierOrder($filename) {\n // The nested array to hold all the arrays\n $the_big_array = [];\n $h = fopen($filename, \"r\");\n if($h) {\n while (($data = fgetcsv($h, 50, \";\")) !== FALSE)\n {\n $the_big_array[] = $data;\n }\n fclose($h);\n foreach($the_big_array as $champs) {\n $chp1 = $champs[0];\n $chp2 = intval($champs[1]);\n $champ3 = intval($champs[2]);\n $chp4 = floatval($champs[3]);\n $ordre = new Ordre($chp1, $chp2, $champ3, $chp4);\n array_push($this->ListOrdre, $ordre);\n }\n }\n else{\n print(\"FICHIER ORDRES.CSV NON TROUVE.CREATION FICHIER.\"); \n $this->writeOrdres($filename);\n }\n\n }", "title": "" }, { "docid": "5759d7e3492c050e62892a34d81e2fb0", "score": "0.49392208", "text": "function array_creating(){\r\n $xlsx=file_reading();\r\n //Se crea el arreglo asociativo\r\n $data= array(\r\n 'B1' => $xlsx->getCell(0,'B1'),\r\n 'B2' => $xlsx->getCell(0,'B2'),\r\n 'B3' => $xlsx->getCell(0,'B3'),\r\n 'B4' => $xlsx->getCell(0,'B4'),\r\n 'B5' => $xlsx->getCell(0,'B5'),\r\n 'B11' => $xlsx->getCell(0,'B11'),\r\n 'B12' => $xlsx->getCell(0,'B12'),\r\n 'B13' => $xlsx->getCell(0,'B13'),\r\n 'B14' => $xlsx->getCell(0,'B14'),\r\n 'B15' => $xlsx->getCell(0,'B15'),\r\n 'B16' => $xlsx->getCell(0,'B16'),\r\n 'B18' => $xlsx->getCell(0,'B18'),\r\n 'B19' => $xlsx->getCell(0,'B19'),\r\n 'B20' => $xlsx->getCell(0,'B20'),\r\n 'B30' => $xlsx->getCell(0,'B30'),\r\n 'C7' => $xlsx->getCell(0,'C7'),\r\n 'C25' => $xlsx->getCell(0,'C25'),\r\n 'D3' => $xlsx->getCell(0,'D3'),\r\n 'D7' => $xlsx->getCell(0,'D7'),\r\n 'D21' => $xlsx->getCell(0,'D21'),\r\n 'D23' => $xlsx->getCell(0,'D23'),\r\n 'D25' => $xlsx->getCell(0,'D25'),\r\n 'D28' => $xlsx->getCell(0,'D28'),\r\n 'E3' => $xlsx->getCell(0,'E3')\r\n );\r\n echo\"<pre>\";\r\n var_dump($data);\r\n echo\"</pre>\";\r\n //Se retorna lo obtenido \r\n return $data;\r\n}", "title": "" }, { "docid": "8498ecbc5a8b56e5d4f5eb056d9c3eea", "score": "0.4934244", "text": "protected function fixarray() {\n\t\t$filename = $_POST['xmlfile'] ? $_POST['xmlfile'].'.xlx' : 'temp.xlx'; \n\t\t$f = @file($this->prpath . $filename);\n\t\t\n\t\tif (is_array($f)) {\n\t\t\tforeach ($f as $a=>$line) {\n\t\t\t if ($line) {\n\t\t\t\t$x = explode(',',$line);\n\t\t\t\t$fa[trim($x[0])] = trim($x[1]);\n\t\t\t }\n\t\t\t} \n\t\t}\n\t\telse\n\t\t\t$fa = array(); //empty\n\t\t//print_r($fa);\n\t\treturn $fa;\n\t}", "title": "" }, { "docid": "a1e2fead680098f56e8301d3a59aed80", "score": "0.49339306", "text": "private static function CargarDesdeArchivo(){\n $listaProveedores = [];\n if( file_exists(TXT_PROVEEDORES) ){\n if(strlen(file_get_contents(TXT_PROVEEDORES)) > 0){\n $listaProveedores = json_decode(file_get_contents(TXT_PROVEEDORES),true);\n }\n }\n return $listaProveedores;\n }", "title": "" }, { "docid": "e22a3043b5e948b8f0311a2fb7f3491e", "score": "0.49238774", "text": "private function toArray()\n {\n $this->header = $this->getRow();\n while (($row = $this->getRow()) !== false) {\n $this->data[] = array_combine($this->header, $row);\n }\n }", "title": "" }, { "docid": "d40e9a8ad47b5da7b11a891079d5deee", "score": "0.4919864", "text": "public function createArray(){\n\t\t$dataArray = array(\n\t\t array('name' =>'Kim','account'=>'0901','age'=>'43' ),\n\t\t array('name' =>'King','account'=>'0902','age'=>'23' ),\n\t\t array('name' =>'Cam','account'=>'0903','age'=>'53' ),\n\t\t array('name' =>'Cannon','account'=>'0904','age'=>'43' ),\n\t\t array('name' =>'Bob','account'=>'0905','age'=>'30' ),\n\t\t array('name' =>'Cashy','account'=>'0906','age'=>'28' ),\n\t\t);\n\t\t$list = $data['$dataArray'];\n\n\t}", "title": "" }, { "docid": "3b70e5676bf28b87534588ada2afaee1", "score": "0.4915897", "text": "public function listarChikera($codigo){\n $lista_detalles = array();\n $listDetalle= $this->empresa_model->listChikera($codigo);\n if(count($listDetalle)>0){ \n foreach ($listDetalle as $key => $value) {\n $objeto = new stdClass();\n $objeto->CHEK_Codigo =$value->CHEK_Codigo;\n $objeto->CUENT_NumeroEmpresa =$value->CUENT_NumeroEmpresa;\n $objeto->CHEK_FechaRegistro =mysql_to_human($value->CHEK_FechaRegistro);\n $objeto->SERIP_Codigo =$value->SERIP_Codigo;\n $objeto->CHEK_Numero=$value->CHEK_Numero;\n $lista_detalles[] = ($objeto);\n }\n $resultado[] = array();\n $resultado = json_encode($lista_detalles,JSON_NUMERIC_CHECK);\n echo $resultado; \n} \n}", "title": "" }, { "docid": "13cdac9d711a6d7605ed42e21d2fe29d", "score": "0.49122384", "text": "function json_array_save($json_array) {\n $json_file = fopen(\"../data/config.json\", \"w\");\n $file_saved = fwrite($json_file, json_encode($json_array,JSON_UNESCAPED_UNICODE));\n fclose($json_file);\n if(! $file_saved)\n {\n echo \"<div class=\\\"message error\\\">Problème durant la sauvegarde du fichier</div>\";\n die();\n }\n}", "title": "" }, { "docid": "f0ea47559e81b99e0b698ae9fb75ed1f", "score": "0.49095395", "text": "function toArray($data){\n\t$data = json_encode($data);\n\t$data = json_decode($data, true);\n\treturn $data;\n}", "title": "" }, { "docid": "933b8d0c30a0b85f8575a630514f83a0", "score": "0.49026024", "text": "private function load()\n {\n $decoder = new JsonDecoder();\n $decoder->setObjectDecoding(JsonDecoder::ASSOC_ARRAY);\n\n $this->json = file_exists($this->path)\n ? $decoder->decodeFile($this->path)\n : array();\n }", "title": "" }, { "docid": "fc7452837e61cc49458bd5787c452210", "score": "0.49002072", "text": "public function json()\n\t{\n\t\t$ret = array();\n\n\t\t$data = $this->fileread();\n\n\t\t// write if a value is given\n\t\tif ((isset($this->val) && $this->val != '') or $this->writeall)\n\t\t{\n\t\t\tforeach ($this->item as $item)\n\t\t\t{\n\t\t\t\t$data[$item] = $this->val;\n\t\t\t}\n\n\t\t\t$this->filewrite($data);\n\t\t}\n\n\t\tforeach ($this->item as $item)\n\t\t{\n\t\t\t$ret[$item] = isset($data[$item]) ? $data[$item] : null;\n\t\t}\n\n\t\treturn json_encode($ret);\n\t}", "title": "" }, { "docid": "b0091ac84da3e3c311286c1554bc6e9a", "score": "0.48993236", "text": "function JSONCorrectoAnnadir($recibido){\r\n\t\r\n\t$auxCorrecto = false;\r\n\t\r\n\tif(isset($recibido[\"peticion\"]) && $recibido[\"peticion\"] =\"del\" && isset($recibido[\"instalacionBorrar\"])){\r\n\t\t\r\n\t\t$auxInstalacion = $recibido[\"instalacionBorrar\"];\r\n\t\tif(isset($auxInstalacion[\"codparque\"])){\r\n\t\t\t$auxCorrecto = true;\r\n\t\t}\r\n\t\t\r\n\t}\r\n\t\r\n\t\r\n\treturn $auxCorrecto;\r\n\t\r\n}", "title": "" }, { "docid": "fd39199f2765d2e4811782b73306aaf0", "score": "0.48919317", "text": "function pack_files_as_JSON_array($array, $wrapper_name=\"data\"){\n\t$JSON_string = '{ \"' . $wrapper_name . '\" : [';\n\tforeach($array as $filename){\n\t\t$JSON_string .= '\"' . $filename . '\", ';\n\t}\n\t$JSON_string = rtrim($JSON_string, \", \");\n\t$JSON_string .= \"]}\";\n\treturn $JSON_string;\n}", "title": "" }, { "docid": "08c00ac4564fb855b6d63d44c0d280c1", "score": "0.4891385", "text": "function dSpaceJSONtoMetadataArray($json)\n\t{\n\t\t$json = json_decode($json, TRUE);\n\t\t\n\t\t$metadata = array();\n\t\t\n\t\tforeach($json as $entry)\n\t\t{\n\t\t $metadata[$entry['key']][] = array('value'=>$entry['value'],'language'=>$entry['language']);\n\t\t}\n\t\t\n\t\treturn $metadata;\n\t}", "title": "" }, { "docid": "e4e5db75ce3aaf61abff224edc4f1a64", "score": "0.4889789", "text": "public function serializeArray($a){\n\t\t$_array_return = array();\n $array_replace = array('['=>'',']'=>'');\n\t\tif( is_array($a) ){\n\t\t\tforeach($a as $c => $k){\n\t\t\t\t$_name = trim(strtolower($a[$c]['name']));\n $_value = trim($a[$c]['value']);\n $_pos = strpos($_name,'['); \n if( $_pos !== false ){\n $_cadena = strtr( substr($_name,$_pos) , $array_replace );\n $_name = substr($_name,0,$_pos);\n if( isset($_array_return[$_name][$_cadena])){\t\t\t\t\t\n \t\t\t\t\tif( is_array($_array_return[$_name][$_cadena]) )\n \t\t\t\t\t\t$_array_return[$_name][$_cadena][$_value]=true;\n \t\t\t\t\telse{\n \t\t\t\t\t\t$_tmp = $_array_return[$_name][$_cadena];\n \t\t\t\t\t\t$_array_return[$_name][$_cadena]=array($_tmp => true, $_value => true);\n \t\t\t\t\t}\n \t\t\t\t}\n \t\t\t\telse\n \t\t\t\t\t$_array_return[$_name][$_cadena] = $_value;\n \n }else{\n \t\t\t\tif( isset($_array_return[$_name])){\t\t\t\t\t\n \t\t\t\t\tif( is_array($_array_return[$_name]) )\n \t\t\t\t\t\t$_array_return[$_name][$_value]=true;\n \t\t\t\t\telse{\n \t\t\t\t\t\t$_tmp = $_array_return[$_name];\n \t\t\t\t\t\t$_array_return[$_name]=array($_tmp => true, $_value => true);\n \t\t\t\t\t}\n \t\t\t\t}\n \t\t\t\telse\n \t\t\t\t\t$_array_return[$_name] = $_value; \n }\n\t\t\t}\n\t\t}\t\t\n\t\treturn $_array_return;\n\t}", "title": "" }, { "docid": "3704f325172678dbf32749d1b74ee917", "score": "0.48895836", "text": "function modif_question(array $newQuest){\n $json=file_get_contents(FILE_QUESTIONS);\n \n // 2 convertir le json en tableau\n $arrayQuestion= json_decode($json,true);\n foreach($arrayQuestion as $key => $oldQuest){\n if ($oldQuest['id']==$newQuest['id']) {\n $arrayQuestion[$key]=$newQuest;\n \n }\n\n }\n $json = json_encode($arrayQuestion);\n file_put_contents(FILE_QUESTIONS , $json);\n\n}", "title": "" }, { "docid": "c12f4cdc94c87bae9e1fc9fe8d46e7f5", "score": "0.4889364", "text": "private function ReadFileIntoArray($filepath){\n\t\t$file_content = file_get_contents($filepath);\n\t\t\n\t\t// split every line \n\t\t$split_lines = preg_split(\"/\\r\\n|\\n|\\r/\", $file_content);\n\t\t$lines_count = count($split_lines);\n\t\tif($lines_count <= 0){\n\t\t\t// no lines\n\t\t\t$this->errors[] = \"This file is empty\";\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t$list_duplicates = array();\n\t\t$added_lines = 0;\n\t\t// loop the lines one by one\n\t\tfor($i = 0; $i < $lines_count; $i++){\n\t\t\t$line1 = $split_lines[$i]; // get the line data\n\t\t\t$line1 = trim($line1);\n\t\t\t// if line is empty\n\t\t\tif(strlen($line1) <= 1){\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t// check if its a comment line\n\t\t\tif(substr($line1,0,1) == \"#\"){\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t// split the line into key and value pairs\n\t\t\t$line_parts = explode(\"=\",$line1);\n\t\t\t\n\t\t\tif(!isset($line_parts[0])){\n\t\t\t\t$this->errors[] = \"Key not set!\";\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\tif(!isset($line_parts[1])){\n\t\t\t\t$this->errors[] = \"Value not set for key \".$line_parts[0];\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t$_key = trim($line_parts[0]);\n\t\t\t$_value = trim($line_parts[1]);\n\t\t\t\n\t\t\tif(in_array($_key,$list_duplicates)){\n\t\t\t\t// Duplicate Key\n\t\t\t\t$this->errors[] = \"Skip duplicate key \".$_key;\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t// check key is valid\n\t\t\tif(!preg_match(\"/^[a-zA-Z0-9-_]+$/\",$_key)){\n\t\t\t\t$this->errors[] = \"Invalid key \".$_key;\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t// track duplicate keys\n\t\t\t$list_duplicates[] = $_key;\n\t\t\t\n\t\t\t// store the key and value into a array\n\t\t\t$dx = array();\n\t\t\t$dx[\"key\"] = $_key;\n\t\t\t$dx[\"value\"] = \"\".$_value; \n\t\t\t$this->arrayData[] = $dx;\n\t\t\t$this->LoadEnvVars($_key,$_value);\n\t\t\t$added_lines++;\n\t\t\t// parse done\n\t\t}\n\t\t\n\t\tif($added_lines <=0){\n\t\t\t$this->errors[] = \"This file is empty\";\n\t\t}\n\t}", "title": "" }, { "docid": "9bc1268e211915cea3259fd3a2f30795", "score": "0.4889356", "text": "function populateArrayFromDatabase($filename) {\r\n //Initialize array return value\r\n $array = null;\r\n $numItems = countItemsInDatabase($filename);\r\n\r\n $fp = fopen($filename, \"r\") or die(\"Unable to open $filename file!\");\r\n $fs = filesize($filename);\r\n\r\n $contents = fread($fp, $fs);\r\n\r\n $arrayItem = explode(\";\", $contents);\r\n\r\n for ($i = 0; $i < $numItems; $i++) {\r\n $arrayItemData = explode(\",\", $arrayItem[$i]);\r\n\r\n for ($j = 0; $j < sizeOf($arrayItemData); $j++) {\r\n $array[$i][$j] = trim($arrayItemData[$j]);\r\n }\r\n }\r\n\r\n fclose($fp);\r\n\r\n return $array;\r\n }", "title": "" }, { "docid": "9690b08633a782b01486f093c2c33dce", "score": "0.48881817", "text": "public function storeTxtData($fname){\n\t\t$content = File::get('python_new/results/results_'.$fname.'.json');\n\t\t$array_data = array();\n\t\t$explodestr = explode('{',$content);\n\t\tif(!empty($explodestr))\n\t\t{\n\t\t\tforeach($explodestr as $expl)\n\t\t\t{\n\t\t\t\tif(strpos($expl, 'name') !== false) \n\t\t\t\t{\n\t\t\t\t\t$data = strstr($expl, '}', true);\n\t\t\t\t\t$explodeData = explode(\",\",$data);\n\t\t\t\t\tforeach ($explodeData as $key => $value)\n\t\t\t\t\t{\n\t\t\t\t\t\t$full_add =\"\";\n\t\t\t\t\t\tif(strpos($value, 'address') !== false) {\n\t\t\t\t\t\t\t\t $explode_str = explode(':',$value);\n\t\t\t\t\t\t\t\t// print_r($explode_str);exit;\n\t\t\t\t\t\t\t\t$address = preg_replace(\"/[']/\", ' ', $explode_str[1]); // Removes special chars.\n\t\t\t\t\t\t\t\t$FileName = preg_replace('/[^\\w]/', '', $address);\n\t\t\t\t\t\t }\n\t\t\t\t\t\t$email_add=\"\";\n\t\t\t\t\t\t$trim_email='';\n\t\t\t\t\t\t if(strpos($value, 'email') !== false) \n\t\t\t\t\t\t{\n\t\t\t\t\t\t $explode_str = explode(':',$value);\n\t\t\t\t\t\t $email_add = preg_replace(\"/[']/\", '', @$explode_str[1]); // Removes special chars.\n\t\t\t\t\t\t $repl_email = preg_replace('/[^\\w]/', '', $email_add);\n\t\t\t\t\t\t $trim_email=trim($repl_email);\n\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$trim_bname='';\n\t\t\t\t\t\t if(strpos($value, 'name') !== false) \n\t\t\t\t\t\t {\n\t\t\t\t\t\t\t$explode_str = explode(':',$value);\n\t\t\t\t\t\t\t$business_name = preg_replace('/[\"]/', '', @$explode_str[1]); // Removes special chars.\n\t\t\t\t\t\t\t$repl_bname =preg_replace('/[^\\w]/', '', $business_name);\n $trim_bname=trim($repl_bname);\n\t\t\t\t\t\t }\n $ifBname = Yelp_address::Where('email',$trim_email)\n ->where('business_name',$trim_bname)\n ->where('email','<>','')\n ->where('business_name','<>','')->count();\n\t\t\t\t\t\tif($ifBname<=0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$yelp_address= new Yelp_address();\n\t\t\t\t\t\t\t $yelp_address->email = $email_add;\n\t\t\t\t\t\t\t\t$yelp_address->business_name = $business_name;\n\t\t\t\t\t\t\t\t$yelp_address->address = $full_add;\n\t\t\t\t\t\t\t\t$yelp_address->location = $fname;\n\t\t\t\t\t\t\t\t$yelp_address->save();\n\t\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t }\n\t\t\t }\n\t\t }\n\t\t $data = Yelp_address::where('location', $fname)->get();\n\t\t return $data;\n\t }\n\telse{\n\t\t\treturn response()->json([\n\t\t\t\t'success' => false,\n\t\t\t\t'message' => 'No Data found.'\n\t\t\t], 422);\n\t\t}\n\t}", "title": "" }, { "docid": "3e6b036d4d5ddfbc80282179e8824585", "score": "0.48870096", "text": "public function jsonSerialize():array\n {\n\n return array(\n 'id' =>$this->id,\n 'nombre' => $this->nombre,\n 'ubicacion' => $this->ubicacion\n\n );\n\n }", "title": "" }, { "docid": "4376bace308094eabf2b73cb9835d9aa", "score": "0.4885086", "text": "public function compileJsonArray($column)\n {\n return 'json_array('.$this->wrap($column).')';\n }", "title": "" }, { "docid": "598ac4d29ea91db9a92aab2de0d3b303", "score": "0.48818287", "text": "private function ramos_json(){\n $ramos = $this->ramos->get();\n\n // add the pp and egresos count for each ramo\n foreach($ramos as $ramo){\n $ramo->id = (int)$ramo->id;\n $ramo->ramo = (int)$ramo->ramo;\n $ramo->pp = $this->pp->count_by_ramo($ramo->ramo);\n $ramo->egresos = $this->egresos->count_by_ramo($ramo->ramo);\n }\n\n return $ramos;\n }", "title": "" }, { "docid": "24408ae7dabf37c02c45f412d3024934", "score": "0.48732787", "text": "function get_json_schema() {\n $arr = array();\n\n foreach(array_keys($this->columns) as $key) {\n $field = array('key' => $key);\n\n if(!empty($this->yui_parsers[$key])) {\n $field['parser'] = $this->yui_parsers[$key];\n }\n\n if(!empty($this->yui_sorters[$key])) {\n $field['sortOptions'] = array('sortFunction' => $this->yui_sorters[$key]);\n }\n\n $arr[] = $field;\n }\n\n return json_encode(array('fields' => $arr));\n }", "title": "" } ]
13723369ee210991fbaeff150e6325a0
Display the specified resource.
[ { "docid": "324896da1e7066369a656d9921028154", "score": "0.0", "text": "public function show($id)\n {\n $employes=DB::table('employes')->select('employe_id','employes.matricule','employes.numero_sss','employes.id','employes.nom','employes.prenom','employes.password','employes.role','employes.civilite','employes.photo','employes.situation_matrimoniale','employes.origine','employes.nationnalite','employes.nbre_enfant','employes.contact_urgent','employes.sexe',\n 'employes.entite','employes.date_naissance','employes.tel_perso','employes.tel_pro','employes.mail_perso','employes.entite','employes.email','contrats.type_contrat','contrats.date_debut','contrats.date_fin')\n ->join('contrats','employes.id','=','contrats.id')->where('employe_id', '=', $id)->get()->first();\n return view('contrats.show',['employe' => $employes]);\n }", "title": "" } ]
[ { "docid": "ac91646235dc2026e2b2e54b03ba6edb", "score": "0.8190437", "text": "public function show(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "754e1795026ca4c71e3959656a533ca3", "score": "0.77020115", "text": "private function _displayResource() {\n\t\t// determine which action to take\n\t\t$lti_message_type = $this->lti_model->getLtiDataValue('lti_message_type');\n\t\tswitch( $lti_message_type ){\n\t\t\tcase 'ContentItemSelectionRequest' : // take user to the content item selector\n\t\t\t\t$this->_getContentItemSelectionRequest();\n\t\t\t\tbreak;\n\t\t\tcase 'basic-lti-launch-request' : // retrieve the requested resource\n\t\t\tdefault :\n\t\t\t\t// store LTI basic outcomes service details when an outcome is requested\n\t\t\t\t$this->lti_outcomes->saveLtiOutcomesValues();\n\t\t\t\t$this->getContent( $custom_resource_id );\n\t\t}\n\t}", "title": "" }, { "docid": "d77a1cf077ad489eb930bc1facfeb4a7", "score": "0.7348343", "text": "public function show($class_id, $resource)\n {\n //\n }", "title": "" }, { "docid": "26f38c42099a7c64fba7842c4ce19062", "score": "0.7230476", "text": "public function show(Resource $resource)\n {\n return view('actions.resource.show', compact('resource'));\n }", "title": "" }, { "docid": "b8de278532cf1b2d94016c0cd12737fd", "score": "0.7159185", "text": "public function show(Resource $resource)\n {\n $resource = new ResourceResource($resource);\n return $this->success('Resource Detail.', $resource);\n }", "title": "" }, { "docid": "48fb67ee8a54377a224740d572c17cdd", "score": "0.7143722", "text": "public function show(Resource $resource)\n {\n return view('resource.show',['resource'=>$resource]);\n }", "title": "" }, { "docid": "50078f2eddc7667a37be0da403d6d3e4", "score": "0.7131298", "text": "function display($resource_name, $cache_id = null, $compile_id = null) {\n // Был старый выхзов, учитывал кеширование\n //$this->fetch($resource_name, $cache_id, $compile_id, true);\n $this->render($resource_name);\n }", "title": "" }, { "docid": "860344e8f85b09bf11e41aa48e928f6e", "score": "0.6776001", "text": "public function showAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('BWBlogBundle:Resource')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Resource entity.');\n }\n\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('BWBlogBundle:Resource:show.html.twig', array(\n 'entity' => $entity,\n 'delete_form' => $deleteForm->createView(), ));\n }", "title": "" }, { "docid": "bc7cbf8f7bf2cdecfc58cc20b4ee76ef", "score": "0.6574996", "text": "public function show($course, Resource $resource)\n {\n\n\n $pageTitle = 'Resource';\n\n return view('resources.resource')->with(compact( 'resource', 'pageTitle'));\n }", "title": "" }, { "docid": "cc94e2329160f202733c635aa4bf0b30", "score": "0.65286446", "text": "public function show($param)\r\n {\r\n\r\n $data['resource_header'] = true;\r\n $user_id = ($this->auth)?$this->auth->id:null;\r\n $data['resource'] = Resource::with(['tags', 'likesCount', 'user', 'downloads', 'category', 'category.resources' => function($q){\r\n $q->limit(4);\r\n }, 'like' => function($q)use($user_id){\r\n $q->where('user_id', $user_id);\r\n }])\r\n ->where('slug', $param)\r\n ->orWhere('id', $param)\r\n ->firstOrFail();\r\n\r\n $author = User::with('profile')\r\n ->where('id', $data['resource']->user_id)\r\n ->get()\r\n ->toArray();\r\n\r\n if(count($author) > 0){\r\n $data['author'] = $author[0];\r\n }\r\n\r\n $data['latestResources'] = Resource::with('category')->orderBy('id', 'desc')->limit(5)->get();\r\n $data['tags'] = Tag::orderBy('id','desc')->get();\r\n\r\n return view('public.resource')->with($data);\r\n }", "title": "" }, { "docid": "69545e83d1d4c03b646757789a897b5b", "score": "0.6515112", "text": "public function show(Resource $resource)\n {\n //\n // $this->authorize('view',Resource::class);\n // $page=Page::all();\n // $resource=Resource::all();\n // return view('resource.show',compact('page','resource'));\n return response()->json($resource);\n }", "title": "" }, { "docid": "51abeaf13e315e938469da7a51936df5", "score": "0.6467601", "text": "public function show($id)\n {\n $query = '\"select\":\"*\",\"where\":\"id=' . $id . '\"';\n $data = ResourcesService::getResourcesTableRow($query);\n $resource = $data[\"Result\"][0];\n //$resource = Resource::findOrFail($id);\n\n return view('admin.resources.show', compact('resource'));\n }", "title": "" }, { "docid": "4869655563febeddc21b876b2d3bd399", "score": "0.6464456", "text": "public function showResource(Request $request, $id = 0);", "title": "" }, { "docid": "6e101e96500f24d567e50a803b6d00fb", "score": "0.64562225", "text": "public function show($id)\n\t{\n\t\t// Get the resource if it has not been provided by the child class\n\t\tif( ! $this->resource->getKey())\n\t\t\t$this->resource = $this->resource->findOrFail($id);\n\n\t\t$this->layout->subtitle = _('Details');\n\n\t\treturn $this->loadView(__FUNCTION__, $this->resource->getVisibleLabels());\n\t}", "title": "" }, { "docid": "0bfd2fab1690e405f8ae90f2f671725b", "score": "0.63684106", "text": "public function show($id)\n\t{\n\t\t$resource = Resource::findOrFail($id);\n\t\treturn View::make('resource/show', compact('resource'));\n\t}", "title": "" }, { "docid": "14f061e926b1904b496ec52586cb2b35", "score": "0.63535744", "text": "public function display() {\n\t\t\ttry {\n\t\t\t\tif(!is_null($this->id)) {\n\t\t\t\t\t$this->returnView($this->model->display($this->id));\n\t\t\t\t} else {\n\t\t\t\t\t$this->error404();\n\t\t\t\t}\n\t\t\t} catch(Exception $e) {\n\t\t\t\t$this->session->add('error', $e->getMessage());\n\t\t\t\texit(header('Location: '.$_SERVER['HTTP_REFERER']));\n\t\t\t}\n\t\t\t$this->session->sUnset('error');\n\t\t}", "title": "" }, { "docid": "30460e9f10fc35f6066e56c0edf07f11", "score": "0.62772554", "text": "public function resource($resource)\n {\n // TODO: Implement resource() method.\n }", "title": "" }, { "docid": "742c2b4cd2f26a04a82af80f8ee84057", "score": "0.62133056", "text": "public function show()\n {\n $dispatcher = Dispatcher::getSharedDispatcher();\n $dataProvider = $this->getDataProvider();\n $controller = $dataProvider->getControllerClassForPath($this->getPath());\n $action = $this->getIdentifier() . 'Action';\n $controller = GeneralUtility::makeInstance($controller);\n\n if (is_object($controller)) {\n $controller->setRequest($dispatcher->getRequest());\n }\n if (is_numeric($this->getIdentifier())\n && is_object($controller) && method_exists($controller, 'showAction')\n ) {\n $result = $controller->processAction('showAction', $this->getIdentifier());\n } elseif (is_object($controller) && method_exists($controller, $action)) {\n $result = $controller->processAction($action);\n } else {\n $result = false;\n }\n\n return $result ? $this->createResponse($result, 200) : $result;\n }", "title": "" }, { "docid": "f61677388a9b71138fce919e36a82ca0", "score": "0.61413664", "text": "public function show($id)\n {\n #$resource = resource::find($id);\n $resource = Resource::where('slug', '=', $id)->orWhere('id', '=', $id)->firstOrFail();\n\n $related_resources = Resource::where('id', \"!=\", $resource->id)\n ->orWhere('name', 'LIKE', '%' . $resource->name . '%')\n ->orWhere('description', 'LIKE', '%' . $resource->description . '%')->take(8)->get();\n\n $data = [\n 'resource' => $resource,\n 'related_resources' => $related_resources,\n ];\n\n return view('resources.show-resource')->with($data);\n }", "title": "" }, { "docid": "404169262f3328542c2f476a8bae067c", "score": "0.6073625", "text": "public function fetch($resource_name, $cache_id = null, $compile_id = null, $display = false)\n {\n $this->fixURI($resource_name);\n\n return parent::fetch($resource_name, $cache_id, $compile_id, $display);\n }", "title": "" }, { "docid": "90a025ba515ea1ffda1792e51f379566", "score": "0.6065236", "text": "public function show($id)\n {\n $resource = Resource::findOrFail($id);\n\n return view('resources.show')->with(compact('resource'));\n }", "title": "" }, { "docid": "d4b48f077d182386266a016e1934227a", "score": "0.60600674", "text": "public function render(&$objResource);", "title": "" }, { "docid": "120fe33c517800f7a36fd36a7d8ff2a0", "score": "0.6034755", "text": "public function showAction($id);", "title": "" }, { "docid": "691f9d494ebbd3698416c27402ce6045", "score": "0.6024695", "text": "public function show($id)\n {\n if (is_numeric($id)) {\n return new ActionResource (Action::find($id));\n }else{\n abort(404 , 'resource not found.');\n \n }\n \n }", "title": "" }, { "docid": "c6f154f853b604d366507e7f3651128c", "score": "0.59881043", "text": "public function index()\n\t{\n\t\t$this->load->view('resource');\n\t}", "title": "" }, { "docid": "78f674e0991329ee80d8bfe522602ce3", "score": "0.59581137", "text": "public function actionShow()\n {\n $this->render('show', array());\n }", "title": "" }, { "docid": "469e3d6c9afd54041becbee857df8ef8", "score": "0.5954321", "text": "public function edit(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "3411150986f3334a3ae059e3824a705e", "score": "0.59518707", "text": "public function showAction() {\n\n\t\t// ...\n\t\tif(isset($this->externalWebsiteUri)) {\n\t\t\t$this->view->assign('external_website_uri', $this->externalWebsiteUri);\n\t\t}\n\t}", "title": "" }, { "docid": "51df0e59505572a08a6c3c4ea6558bb4", "score": "0.5942475", "text": "public function showAction()\n\t{\n\t\t$this->loadLayout()->renderLayout();\n\t}", "title": "" }, { "docid": "7a089792dd9f8cefa56e79369d710cb2", "score": "0.59358656", "text": "public function show(Request $request, string $resource, string $id) {\n if(!Lyra::checkPermission('read', $resource)) abort(403);\n\n if(config('lyra.translator.enabled') && $request->has('lang')) App::setLocale($request->get('lang'));\n\n $resourcesNamespace = Lyra::getResources()[$resource];\n $modelClass = $resourcesNamespace::$model;\n\n if (method_exists($modelClass, 'trashed')) {\n $model = $modelClass::withTrashed()->find($id);\n } else {\n $model = $modelClass::find($id);\n }\n\n if (!Arr::first($model)) return abort(404, \"No query results for model [$modelClass]\");\n $resourceCollection = new $resourcesNamespace(collect([$model]));\n return $resourceCollection->getCollection($request, 'show');\n }", "title": "" }, { "docid": "a5fe9713f7fa35feab808a95acb937a5", "score": "0.59236246", "text": "public function show(Artist $artist)\n {\n\n\n return new ShowArtistResource($artist);\n\n\n }", "title": "" }, { "docid": "4dd721a222d59966f8999c2bf46a1634", "score": "0.5913372", "text": "public function url($resource = self::URL_RESOURCE, array $args = array()) \n {\n return parent::url($resource, $args);\n }", "title": "" }, { "docid": "eaff1ff5ad75e879908bb065beeea534", "score": "0.5910201", "text": "public function edit(Resource $resource)\n {\n return view('actions.resource.edit', compact('resource'));\n }", "title": "" }, { "docid": "f2800dcfd7234cc6b914253341f2a919", "score": "0.5905734", "text": "public function display()\n {\n $this->getAdapter()->display();\n }", "title": "" }, { "docid": "5fbd8c8a913f3d5a4f08b109b5762881", "score": "0.59036547", "text": "public function show()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "5fbd8c8a913f3d5a4f08b109b5762881", "score": "0.59036547", "text": "public function show()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "5fbd8c8a913f3d5a4f08b109b5762881", "score": "0.59036547", "text": "public function show()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "c6b5201b64b56afc1aba96e7f01df942", "score": "0.5895745", "text": "public function displayAction()\r\n\t\t{\r\n\r\n\t\t\t$q = Doctrine_Query::create()\r\n\t\t\t->from('Webteam_Model_User i')\r\n\t\t\t->where('i.UserName = ?', $this->identity['UserName']);\r\n\t\t\t$result = $q->fetchArray();\r\n\t\t\tif (count($result) == 1) {\r\n\t\t\t\t$this->view->item = $result[0];\r\n\t\t\t} else {\r\n\t\t\t\tthrow new Zend_Controller_Action_Exception('Page not found', 404);\r\n\t\t\t}\r\n\r\n\t\t}", "title": "" }, { "docid": "e1911719b5dbc5045d62ac4e5e20cd33", "score": "0.587909", "text": "protected function showAction() {\n\t\t$em = $this->getEntityManager();\n\t\t$book = $em->find('Entities\\\\Book', $_GET['id']);\n\t\t$this->addContext('book', $book);\n\t}", "title": "" }, { "docid": "9593ec2b031b164d16249f1ae81182ef", "score": "0.58776784", "text": "public function show(Retex $retex)\n {\n //\n }", "title": "" }, { "docid": "093db99e28544f24edb386d2bf2129f0", "score": "0.58682454", "text": "public function display() {\n\t\t$this->displayContent();\n\t}", "title": "" }, { "docid": "95d012dca84499e39b434e04c9f86031", "score": "0.58522356", "text": "public function showAction()\n\t{\n\t\tif (!isset($this->sGlobal->uId) && !Zend_Auth::getInstance ()->hasIdentity ()) {\n\t\t\t$this->_helper->redirector->gotoRoute ( array('action' => 'index', 'controller' => 'auth'), 'default' );\n\t\t}\n\t\t \n\t\t$dbRoutes = new Model_Ride_DbRoutes();\n\t\t\n\t\t$routes = $dbRoutes->getRoutesByUserId($this->sGlobal->uId);\n\t\t\n\t\t$this->view->routes = $routes;\n\t\t\n\t\t$this->view->deleteRideLink = $this->_helper->url->url(array('controller'=>'Ride', 'action'=>'deleteride'), 'default', true);\n\t\t\n\t}", "title": "" }, { "docid": "a6ea4c61d98549d6b82aa6c50e5153c9", "score": "0.58442765", "text": "public function show($id)\n {\n // return \"Show \".$id;\n abort(404);\n }", "title": "" }, { "docid": "57e04be30c8d73c6f1b1f97f0813c951", "score": "0.5839814", "text": "public function show($parm);", "title": "" }, { "docid": "7fa6d8ebb4c7b91b6b1219f34c1ccc2e", "score": "0.5827577", "text": "public function show()\n {\n return $this->resource->transform();\n }", "title": "" }, { "docid": "1f025b0828827877859e8e2f72f5add5", "score": "0.5824839", "text": "public function resourceAction();", "title": "" }, { "docid": "bc8b175839d90931dc37b6d17073534e", "score": "0.5824825", "text": "public function displayAction()\n {\n // set filters and validators for GET input\n $filters = array(\n 'id' => array('HtmlEntities', 'StripTags', 'StringTrim')\n );\n $validators = array(\n 'id' => array('NotEmpty', 'Int')\n );\n $input = new Zend_Filter_Input($filters, $validators);\n $input->setData($this->getRequest()->getParams());\n\n // test if input is valid\n // retrieve requested record\n // attach to view\n if ($input->isValid()) {\n $q = Doctrine_Query::create()\n ->from('Zf1_Model_Item i')\n ->leftJoin('i.Zf1_Model_Country c')\n ->leftJoin('i.Zf1_Model_Grade g')\n ->leftJoin('i.Zf1_Model_Type t')\n ->where('i.RecordID = ?', $input->id)\n ->addWhere('i.DisplayStatus = 1')\n ->addWhere('i.DisplayUntil >= CURDATE()');\n $sql = $q->getSqlQuery();\n $result = $q->fetchArray();\n if (count($result) == 1) {\n $this->view->item = $result[0];\n $this->view->images = array();\n $config = $this->getInvokeArg('bootstrap')->getOption('uploads');\n foreach (glob(\"{$config['uploadPath']}/{$this->view->item['RecordID']}_*\") as $file) {\n $this->view->images[] = basename($file);\n }\n $configs = $this->getInvokeArg('bootstrap')->getOption('configs');\n $localConfig = new Zend_Config_Ini($configs['localConfigPath']);\n $this->view->seller = $localConfig->user->displaySellerInfo;\n $registry = Zend_Registry::getInstance();\n $this->view->locale = $registry->get('Zend_Locale');\n $this->view->recordDate = new Zend_Date($result[0]['RecordDate']);\n } else {\n throw new Zend_Controller_Action_Exception('Page not found', 404);\n }\n } else {\n throw new Zend_Controller_Action_Exception('Invalid input');\n }\n }", "title": "" }, { "docid": "bcd5d6f048ed9967b2cc42a2b9c646e4", "score": "0.58217233", "text": "public function show($id)\n\t{\n\t\t//...\n\t}", "title": "" }, { "docid": "062f661f5aa2b0fb00beffc662c406c7", "score": "0.58164716", "text": "public function show($id)\n {\n $catalog_detail = Catalog::where(\"id\", \"=\", $id,)->first();\n\n if (!is_null($catalog_detail)) {\n return $this->ok(\"\", new CatalogResource($catalog_detail));\n }\n\n return $this->ok(__('global.record_not_found'));\n }", "title": "" }, { "docid": "e5b312e565cadd216286627cb156afa1", "score": "0.5814938", "text": "public function show() {\n $this->display = true;\n }", "title": "" }, { "docid": "3c83da877de5a8b9a28620cc567e154f", "score": "0.5812585", "text": "public function show($model)\n {\n $model = $this->getModel($model);\n\n $this->authorize('view', $model);\n\n $model = $this->showModel($model);\n\n $resource = resource($model);\n\n return ok($resource);\n }", "title": "" }, { "docid": "8fa3c5aa92241bd98bf245a72087750b", "score": "0.58067733", "text": "public function show($id)\n {\n return Resource::find($id);\n }", "title": "" }, { "docid": "305f64db85d64f68019d2fadcd0a85d2", "score": "0.58012545", "text": "public function show()\n\t{\n\t\t\n\t}", "title": "" }, { "docid": "7d4b687c2015cbab6585700fbd9fed75", "score": "0.5790671", "text": "protected function showResourceView($id)\n\t{\n\n\t\t$element = $this->getElements($id);\n\t\treturn Response::view('adm/Regions/element', array('data' => $element));\n\n\t}", "title": "" }, { "docid": "6d0ead3170a91374660511ebe07a7e52", "score": "0.57788694", "text": "public function display($file){\n\t\techo $this->fetch($file);\n\t}", "title": "" }, { "docid": "1ebe558af6c12f3e75c7741d736cd837", "score": "0.5773779", "text": "public function show($id)\n\t{\n\t\t$this->layout->nest('content', $this->view, ['car' => $this->resource]);\n\t}", "title": "" }, { "docid": "ff99e6923e061969deb024f038cd9fd9", "score": "0.5771933", "text": "public abstract function show();", "title": "" }, { "docid": "f37f81a8bf0d836ce01d6e66ee929689", "score": "0.57692647", "text": "public function show()\n {\n $ResourceRepo = new ResouceRepo();\n $res = $ResourceRepo->show();\n $count = $ResourceRepo->getcount();\n\n return view('ViewResource',['resources' => $res,'totalcount' =>$count]);\n }", "title": "" }, { "docid": "23d3f586042fc7ef9f98c33613fd010d", "score": "0.5757193", "text": "public function url($resource = 'instances', array $args = array())\n {\n return parent::url($resource, $args);\n }", "title": "" }, { "docid": "64ca047c763cbf564dd5de6f46e00c8a", "score": "0.5757105", "text": "public function display(){}", "title": "" }, { "docid": "be16c52b6734a0cf50cdaa52b26c8ee0", "score": "0.57546145", "text": "public function show(Resroom $resroom)\n {\n //\n }", "title": "" }, { "docid": "6552a6831d000ffc0b68b09357fd4a3c", "score": "0.5750852", "text": "public function show($id)\n\t{\n\t\techo $id;\n\t}", "title": "" }, { "docid": "58d82a32f57975c44fc660ccacd3a42f", "score": "0.5749565", "text": "public function resource( $resc= '')\n {\n return view('home.resource',['resource'=>$resc]);\n }", "title": "" }, { "docid": "c28bc00a20642b8f45cbb36b8f142bb6", "score": "0.5747548", "text": "public function show( $id );", "title": "" }, { "docid": "f3bc4ff0e0f2cc54bf914d77670e405e", "score": "0.5737612", "text": "public function edit(Resource $resource)\n {\n return view('resource.edit',['resource'=>$resource]);\n }", "title": "" }, { "docid": "a5c4f542acf75c65ff05c5578f254411", "score": "0.57365245", "text": "public function show($id)\t{\n\t\t//\n\t}", "title": "" }, { "docid": "c0c57945d6d1643edc1ffb95ae99eef9", "score": "0.5735039", "text": "public function show($id)\n { \n if( $this->checkShowModelRequest($id) ) return abort(404, \"Resource not found\");\n\n if(request()->expectsJson() || $this->onlyJsonResponse) \n return response()->json($this->showModelQueryResponse($id));\n\n return $this->renderView(\n $this->moduleName != null ? Str::plural($this->moduleName) . '.show' : 'show' ,\n $this->showResponse($id)\n );\n }", "title": "" }, { "docid": "1bb2758d3ba7fe86461bda00a9606e3e", "score": "0.5734708", "text": "public function show( $id )\n\t{\n\t\t$model = Input::get( 'model' );\n\n\t\tif ( !class_exists( $model ) ) {\n\t\t\treturn $this->renderResponse( false, \"That model does not exist\" );\n\t\t}\n\n\t\t$item = $model::find( $id );\n\n\t\tif ( !is_null( $item ) ) {\n\t\t\tif ( property_exists( $item, 'eager_relations' ) ) {\n\t\t\t\t$item->load( $item->eager_relations );\n\t\t\t}\n\t\t\treturn $this->renderResponse( true, $item->toArray( true ) );\n\t\t}\n\n\t\treturn $this->renderResponse( false, \"Resource not found\" );\n\t}", "title": "" }, { "docid": "ab8f27385173dda96b8eaafa7aa90f82", "score": "0.5734516", "text": "public function show(Hirtory $hirtory)\n {\n //\n }", "title": "" }, { "docid": "cb0625cb8bda35818012bd67fb011d73", "score": "0.5728958", "text": "protected function showAction()\n {\n $this->showAction\n ->setAccess($this, Access::CAN_SHOW)\n ->execute($this, NULL, UserActionEvent::class, NULL, __METHOD__)\n ->render()\n ->with(\n [\n 'user_log' => $this->userMeta->unserializeData(\n ['user_id' => $this->thisRouteID()],\n [\n 'login', /* array index 0 */\n 'logout', /* array index 1 */\n 'brute_force', /* index 2 */\n 'user_browser' /* index 3 */\n ]\n )\n ]\n )\n ->singular()\n ->end();\n }", "title": "" }, { "docid": "09abe18b0f313de0a8ae600fe6626d31", "score": "0.57271934", "text": "public function display() {\r\n\t\techo '<a href=\"' . $this->_link .\r\n\t\t\t\t'\" title=\"' . $this->_text .\r\n\t\t\t\t'\">' . $this->_text . '</a><br/>';\r\n\t}", "title": "" }, { "docid": "20397e06b8673db8692c5f84120c3011", "score": "0.5724891", "text": "public function show()\n\t{\n\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "d02c7bae2c97989fe256da11612461c7", "score": "0.5721667", "text": "function display()\n\t{\n\t\t$document \t=& JFactory::getDocument();\n\t\t$viewType\t= $document->getType();\t\n \t\t$viewName\t= JRequest::getCmd( 'view', $this->getName() );\n \t\t$view\t\t=& $this->getView( $viewName , '' , $viewType );\n \t\tif($this->checkPhotoAccess())\n \t\t\techo $view->get( __FUNCTION__ );\n\t}", "title": "" }, { "docid": "3e94f05854b4dbc5a4d900f54aa8043a", "score": "0.5719658", "text": "function index( $request ){\r\n\t\t\r\n\t\t// Look for \"resource\" in request //\r\n\t\t$requestVars = Router :: getRequestVars();\r\n\t\t\r\n\t\t// Show a help page if local //\r\n\t\tif( App :: get()->local ){\r\n\t\t\tif( !isset( $requestVars->resource )){\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t// Hard set the channel to simplify URLs to resource view //\r\n\t\tRouter :: resetChannel( 'resource' );\r\n\t\t\r\n\t}", "title": "" }, { "docid": "47171b843665ac85f7c5da2618a7ae0e", "score": "0.5718969", "text": "public function show($id) {}", "title": "" }, { "docid": "47171b843665ac85f7c5da2618a7ae0e", "score": "0.5718969", "text": "public function show($id) {}", "title": "" }, { "docid": "e2404ea37d0dd7d634ec1a88ba6e0b01", "score": "0.5708454", "text": "public function show() {\n\t\t$author = pick_arg(Author::class);\n\t\treturn $this->viewShow(compact('author'));\n\t}", "title": "" }, { "docid": "695e29ca27ebbcb0a342e19915e00ae9", "score": "0.57076776", "text": "protected function makeDisplayFromResource()\n\t{\n\t\t$query = Query::getQuery();\n\t\t$json = json_encode($this->activeResource);\n\t\tif(isset($query['callback']) && self::$jsonpEnable)\n\t\t{\n\t\t\t$this->mimeType = 'application/javascript';\n\t\t\t$callback = preg_replace('[^A-Za-z0-9]', '', $query['callback']);\n\t\t\treturn $callback . '(' . $json . ')';\n\t\t}else{\n\t\t\treturn $json;\n\t\t}\n\t}", "title": "" }, { "docid": "05ca915e5f597f0a1925a6b1a1e6afb0", "score": "0.57057405", "text": "public abstract function display();", "title": "" } ]
06b048169d6000dd8f2954c77b1ec598
Show the form for creating a new resource.
[ { "docid": "2a46fdbfc8cb01983bb03691388f0169", "score": "0.0", "text": "public function create()\n {\n //\n }", "title": "" } ]
[ { "docid": "735e465640db5c659ac193ab8af1f08c", "score": "0.75648046", "text": "public function createAction ()\n\t{\n\t\t$this->view->form = $this->_form;\n\t}", "title": "" }, { "docid": "c22dae1333d29c28ed855dcb7f069232", "score": "0.749277", "text": "public function create()\n {\n return view('resources.create');\n }", "title": "" }, { "docid": "1f9733369c1aaf55c73aa4d1a8a80882", "score": "0.7457956", "text": "public function create()\n {\n\n return view('resources.create');\n\n }", "title": "" }, { "docid": "1da53c4d224bfa3bc44c0fabd927bedd", "score": "0.7453354", "text": "public function create()\n {\n return view ('rol.form_create');\n }", "title": "" }, { "docid": "4c4b7c47a2d71e26b29b9caea091a07c", "score": "0.73904926", "text": "public function showCreateForm()\n {\n $this->authorize('create', Project::class);\n\n return view('project.create', [\n 'action' => 'create',\n ]);\n }", "title": "" }, { "docid": "edabb98341a0b5aadd47c2864942b8db", "score": "0.733851", "text": "protected function create()\n {\n $form = Form::create($this->resource);\n $model = $form->model;\n\n $model->hasAccessOrFail('create');\n\n $model->fill($this->getOldInput());\n\n $form->fields()->each(function (Field $field) use (&$model) {\n $field->setValue($model);\n });\n\n return view('crud::form.create', compact('form'));\n }", "title": "" }, { "docid": "4734584f2f8340a42973a0d555da6c67", "score": "0.7326605", "text": "public function create()\n {\n return view(\"superadmin.form\");\n }", "title": "" }, { "docid": "10d532d72b585493a6ca515a12bc3a2c", "score": "0.7320302", "text": "protected function showCreateForm()\n\t{\n\n\t\treturn Response::view('adm/IAS/create');\n\n\t}", "title": "" }, { "docid": "9814fd9ae63509e6eb41bf23f7a94615", "score": "0.7277869", "text": "public function create()\n {\n return view('forms.create');\n }", "title": "" }, { "docid": "6ed61a57fb61b517537e754054cffc2f", "score": "0.72555596", "text": "public function create()\n {\n return view(\"stok.form\");\n }", "title": "" }, { "docid": "d777482ca48a952bda74d0486cdad76a", "score": "0.723632", "text": "public function create()\n {\n return \"Here is the creating form page.\";\n }", "title": "" }, { "docid": "8a257056a97a8ef04b6027c8bfb8cad1", "score": "0.72293997", "text": "public function create()\n {\n\n $title = 'Add '. $this->getName();\n $form = $this->form($this->getFormClass(), [\n 'method' => 'POST',\n 'url' => route($this->getRouteFor('store')),\n ]);\n return view('.admin.form', compact('form', 'title'));\n }", "title": "" }, { "docid": "4b9c0332c0bc5feb4fa5c4c15ff4cda0", "score": "0.7221649", "text": "public function create()\n {\n $this->authorize('create', $this->getResourceModel());\n\n $class = $this->getResourceModel();\n return view($this->getResourceCreatePath(), $this->filterCreateViewData([\n 'record' => new $class(),\n ] + $this->resourceData()));\n }", "title": "" }, { "docid": "f5f050d80230f2f0b6313a13b65e7a0b", "score": "0.72211087", "text": "public function newAction()\n {\n $entity = new Faq();\n $form = $this->createCreateForm($entity);\n\n $form->add('question', 'text', array('label' => 'Ask Your Question :')); \n $form->add('answer', 'text', array('label' => 'Give an answer :'));\n $form->add('submit', 'submit', array('label' => 'Submit question'));\n\n return $this->render('FaqBundle:Faq:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "title": "" }, { "docid": "755e91a474eae625dfda22659e4c1f6c", "score": "0.7217913", "text": "public function create()\n {\n return view('form.create');\n }", "title": "" }, { "docid": "7e6cbda13a4d6999c8e363f25258eeb1", "score": "0.7206207", "text": "public function showCreateForm()\n {\n return view('user.create');\n }", "title": "" }, { "docid": "85bc1c405768493e40df217a0040f018", "score": "0.71893287", "text": "function showCreateForm(){\n return view('admin.Direktori.Pendeta.create');\n }", "title": "" }, { "docid": "9493a84894964b34fd6021b3786bcc7a", "score": "0.71867675", "text": "public function create()\n {\n return view('crops.forms.create');\n }", "title": "" }, { "docid": "68716ed8c8a7c02d13766dd274f478a3", "score": "0.7184405", "text": "public function create()\n {\n return view('user_resources/create');\n }", "title": "" }, { "docid": "643073da4582f0c5ee209f1f696bb305", "score": "0.7164174", "text": "public function create()\n {\n return view('admin/records/forms/record-create-form');\n }", "title": "" }, { "docid": "ca8a62edbc9efc96246dc89065570720", "score": "0.7162693", "text": "public function newAction()\n {\n $this->loggerStdout->log('UsersController: display the creation form');\n\n\n }", "title": "" }, { "docid": "86e44150333771a80ff3634ffc76f344", "score": "0.71504635", "text": "public function create()\n {\n return view('dashboard.form.create');\n }", "title": "" }, { "docid": "75889c35cd5f200bf02a5b21774293e1", "score": "0.7137173", "text": "public function create()\n {\n $this->data['titlePage'] = trans('admin.obj_new',['obj' => trans('admin.'.$this->titleSingle)]);\n $breadcrumbs = array();\n $breadcrumbs[] = [ 'title' => trans('admin.home'), 'link' => route($this->routeRootAdmin), 'icon' => $this->iconDashboard ];\n $breadcrumbs[] = [ 'title' => trans('admin.'.$this->titlePlural), 'link' => route(GetRouteAdminResource($this->resourceRoute)), 'icon' => $this->iconMain ];\n $breadcrumbs[] = [ 'title' => $this->data['titlePage'], 'icon' => $this->iconNew ];\n $this->data['breadcrumbs'] = $breadcrumbs;\n $this->data['category'] = $this->getModelArray($this->modelCategory);\n $this->data['province'] = $this->getModelArray($this->modelProvince);\n $this->data['district'] = $this->getModelArray($this->modelDistrict);\n $this->data['ward'] = $this->getModelArray($this->modelWard);\n $this->data['direction'] = $this->getModelArray($this->modelDirection);\n\n return view(GetViewAdminResource($this->resourceView, 'create'))->with($this->data);\n }", "title": "" }, { "docid": "0a067c68f8000d9eb913daf36e5e607c", "score": "0.71182096", "text": "public function create()\n {\n return view('FullForm.create');\n }", "title": "" }, { "docid": "fa84f7150b87a66588bfc89685d8fe4c", "score": "0.71129704", "text": "public function create()\n {\n return view('form');\n }", "title": "" }, { "docid": "fa84f7150b87a66588bfc89685d8fe4c", "score": "0.71129704", "text": "public function create()\n {\n return view('form');\n }", "title": "" }, { "docid": "fa84f7150b87a66588bfc89685d8fe4c", "score": "0.71129704", "text": "public function create()\n {\n return view('form');\n }", "title": "" }, { "docid": "c88daeaad1f2ef73dd9534351ceea67a", "score": "0.7093717", "text": "public function newAction()\n {\n $entity = new FormEntity();\n $entity->setTemplate('keltanasTrackingBundle:Form:form.html.twig');\n $form = $this->createCreateForm($entity);\n\n return $this->render('keltanasTrackingBundle:Form:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "title": "" }, { "docid": "c27004d00e3f9afb85f74623ec456ca9", "score": "0.70779085", "text": "public function create()\n {\n //\n return view('form');\n }", "title": "" }, { "docid": "856274cb86788ad9604003f12dd5060c", "score": "0.7072632", "text": "public function create()\n {\n return view('carusel.new');\n }", "title": "" }, { "docid": "7545e6950b9a4b4ee7a1ca28789b55aa", "score": "0.70706564", "text": "public function createAction ()\n\t{\n\t\t$this->view->form = $this->_form;\n\t\t$this->view->render('signin', 'create');\n\t}", "title": "" }, { "docid": "8e0fde88926c98fb2c54ba67ab5b36a7", "score": "0.70612365", "text": "public function create()\n\t{\n\t\treturn View::make('librarians.create');\n\t}", "title": "" }, { "docid": "345c70747deda30c3482e759c25c4d12", "score": "0.70575905", "text": "public function create()\n {\n return view('passenger.forms.create');\n }", "title": "" }, { "docid": "2b41dd9ed0cf1461dd65f8e05b0a94a1", "score": "0.7056524", "text": "public function create()\n {\n return $this->showForm();\n }", "title": "" }, { "docid": "20ab9d62fc4da5013c56daa9183bfe28", "score": "0.70548934", "text": "public function create()\n {\n return view('admin.client.form');\n }", "title": "" }, { "docid": "b7f63db5c5ecb7bba494b8a81ce69874", "score": "0.7049288", "text": "public function create(AdminResource $resource)\n {\n $form = $resource->getForm();\n\n return view('admin::resource.form', compact('form'));\n }", "title": "" }, { "docid": "8f53ed51f8136e8e32a2c0525120a50f", "score": "0.7044314", "text": "public function create()\n {\n //\n\n \n return view('student/ResourceStd');\n\n }", "title": "" }, { "docid": "f1f40cbb0cad3cf320b4c0ec09b3b428", "score": "0.7037469", "text": "public function create()\n {\n return view('form');\n\n }", "title": "" }, { "docid": "643fd44e4ced88a8aac481ced428c5ca", "score": "0.70245254", "text": "public function create()\n {\n $title = 'CRIAR REGISTRO';\n return view('forms.create',['title' => $title]);\n }", "title": "" }, { "docid": "40e93c68e66b0c86108e5ae59cc176d2", "score": "0.70199364", "text": "public function newAction()\n {\n $this->view->setVar('form', new ClientForm(null, ['edit' => false]));\n }", "title": "" }, { "docid": "8074165780da4d1be303d3e9d8c535ba", "score": "0.7009979", "text": "public function create()\n {\n return view ('owner/form');\n }", "title": "" }, { "docid": "06af90c4292c136aaaf9329cfae0b3fc", "score": "0.70096827", "text": "public function create()\r\n {\r\n //mengarahkan ke form\r\n return view('rental.form');\r\n }", "title": "" }, { "docid": "248b476c0f07013b389c79c904231f2a", "score": "0.70035815", "text": "public function create()\n {\n return view('admin.car.add');\n }", "title": "" }, { "docid": "75fb4bc6a7a5df1f1f5cd380b0cd4aec", "score": "0.69990563", "text": "public function create()\n {\n //New Property form\n return view('properties.addproperty');\n }", "title": "" }, { "docid": "c6f4cc7fdd05567403f39d82ae477eb4", "score": "0.6993963", "text": "public function create()\n\t{\n\t\treturn view('kasus.create');\n\t}", "title": "" }, { "docid": "753f9bd767a3748b9d6409cb957dc41f", "score": "0.6993081", "text": "public function createAction()\n {\n $action = $this->view->url(['action' => 'save'], 'controllers');\n $this->view->projectForm = $this->service->getFormForCreating($action);\n }", "title": "" }, { "docid": "355b502cb4384aeb8c0d1322a57b7677", "score": "0.69876677", "text": "public function create()\n {\n return view ('show.create', [\n ]); \n }", "title": "" }, { "docid": "7fdab24f12d98bab46a40db3c2f06831", "score": "0.698613", "text": "public function create()\n\t{\n\t\treturn View::make('back_setup/ProductForm');\n\t}", "title": "" }, { "docid": "afec885a1ddf009d317c5bca27be7983", "score": "0.6984491", "text": "public function create()\n {\n\t\treturn view('admin.pages.supplier-form-create', ['page' => 'supplier']);\n }", "title": "" }, { "docid": "93cdfcc841a0d10e976bbc17fe7020ec", "score": "0.6976729", "text": "public function create()\n {\n return view('rombel.create');\n }", "title": "" }, { "docid": "eb3ba5c68f25897de6ed50346b9959f7", "score": "0.69741565", "text": "public function create()\n {\n $crud = crud_entry(new \\App\\Employee);\n\n return view('crud::scaffold.bootstrap3-form', ['crud' => $crud]);\n }", "title": "" }, { "docid": "27f66e57741013d1d7bd227b0a1ae6cc", "score": "0.6969458", "text": "public function create()\n {\n return view('radars/create');\n }", "title": "" }, { "docid": "4e37d311d6990013b0ed72549d9fd35f", "score": "0.69613016", "text": "public function create()\n {\n return view('product.form');\n }", "title": "" }, { "docid": "58119c678c7b859b3d2fcb9d4e2544e9", "score": "0.69599855", "text": "public function create()\n {\n return view('forms.girders.create');\n }", "title": "" }, { "docid": "6e09ea0495ecf33b6615199f96a87dd9", "score": "0.6957388", "text": "public function create()\n {\n return view('inventaris.create');\n }", "title": "" }, { "docid": "57611366e6e3194f52047893b6a260ec", "score": "0.6957314", "text": "public function create()\n {\n \tAppGranted::grantedAccess('add', true);\n $data['module_title'] = \"Role\";\n $data['action'] = route('kantor.store');\n $data['action_type'] = \"add\";\n\n $data['breadcrumb'] = [ \n ['title' => 'Master Data','url' => '#'],\n ['title' => 'Kantor','url' => 'kantor'],\n ['title' => 'form','url' => 'form']\n ];\n\n $data['redirect'] = route(\"kantor.create\");\n \n return view('kantor::kantor_form',$data);\n }", "title": "" }, { "docid": "cfb06a7f594e86d7fe22432b5bd18371", "score": "0.6956602", "text": "public function newAction()\n {\n $entity = new Ministro();\n $form = $this->createCreateForm($entity);\n\n return $this->render('ParroquiaCertificadoBundle:Ministro:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "title": "" }, { "docid": "f0a4e435f6bebfce6162cc1be7c7ee0f", "score": "0.695377", "text": "public function create()\n {\n return view('conceptos.create');\n }", "title": "" }, { "docid": "9cc1ebbeb06fe2564e0fa603d2c72f75", "score": "0.69524705", "text": "public function create()\n {\n //\n return view('product.form');\n }", "title": "" }, { "docid": "ad86bd025139be91b2df85c83f79d4bd", "score": "0.6951772", "text": "public function create()\n {\n return view('syllabus.create');\n }", "title": "" }, { "docid": "7b8c9d5cbe582eab2f28c216421a2719", "score": "0.6949992", "text": "public function create()\n {\n return view('proyek.add');\n }", "title": "" }, { "docid": "29d1eb6a37de9bf5891c3b5b4ef4fa2d", "score": "0.69423175", "text": "public function newForm()\n {\n $this->pageTitle = \"Création d'une question\";\n\n //initialisation des selects list\n $this->initSelectList();\n\n parent::newForm();\n }", "title": "" }, { "docid": "353155b973a25b62f33cce0b6600b99c", "score": "0.6933329", "text": "public function create()\n {\n $data = array(\n 'title' => 'Ingreso de un nuevo Sector',\n 'message' => 'return confirm(\"¿Esta seguro que desea guardar el sector?\")',\n 'method' => 'POST',\n );\n return view('sector.form')\n ->with('data', $data);\n }", "title": "" }, { "docid": "7c12821aa5d613a86cc8ba0cf190e6fd", "score": "0.693066", "text": "public function create()\n {\n return view('tutores.new');\n }", "title": "" }, { "docid": "07e409b45065624d003704ab3b447aec", "score": "0.69249916", "text": "public function create()\n {\n return view('admin.product.form');\n }", "title": "" }, { "docid": "60c9cc4899b058bc51c74601c8025ebe", "score": "0.69225484", "text": "public function create()\n {\n return view('adminCreateForm');\n }", "title": "" }, { "docid": "38a6849d5b56a77b178a1fc8297c2e4e", "score": "0.6921667", "text": "public function create()\n\t{\n\t\treturn view('information.create');\n\t}", "title": "" }, { "docid": "466006539e9b1da8c7c2e06a069c4e2e", "score": "0.69203454", "text": "public function create()\n {\n return view('layout_admin.thenew.create_new');\n }", "title": "" }, { "docid": "a59dfad08f7be5f4bb5d898d16a6d3a3", "score": "0.69181395", "text": "public function newAction()\n {\n $entity = new Rector();\n $form = $this->createCreateForm($entity);\n\n return $this->render('ColegioAdminBundle:Rector:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "title": "" }, { "docid": "4bf33424414f342096092b367153c3ff", "score": "0.69180363", "text": "public function create()\n {\n return view('webinars.create');\n }", "title": "" }, { "docid": "1b49a8bc053be1715bbf5620cf797e18", "score": "0.6917381", "text": "public function create()\n\t{\n\t\treturn View::make('product.create'); //form to create new product \n\t}", "title": "" }, { "docid": "27e5069596828984f14a92c012c1e448", "score": "0.69130754", "text": "public function newAction()\n {\n $entity = new Inicio();\n $form = $this->createForm(new InicioType(), $entity);\n\n return $this->render('SisafBundle:Inicio:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "title": "" }, { "docid": "e90d65170f9bc3dd1e2b969826600c53", "score": "0.691302", "text": "public function create()\n {\n return view('ekskul.create');\n }", "title": "" }, { "docid": "51a5131df9fc2dcd5b65b5ca8aa614d0", "score": "0.69084007", "text": "public function create()\n {\n //To show the required create page when its clicked\n return view('admin.create');\n \n \n }", "title": "" }, { "docid": "4b3f5241c4a2f638b9ee19747079b7a2", "score": "0.69062227", "text": "public function create()\n {\n return view('stus.add');\n }", "title": "" }, { "docid": "ecc913c81504bfd8529f7b7feaef7080", "score": "0.69029534", "text": "public function create(){\n return view('person/form', ['action'=>'create']);\n }", "title": "" }, { "docid": "64d616e79a29573ea35b962756917c05", "score": "0.6899146", "text": "public function create()\n {\n\t\t$d['action'] = route('product.store');\n\t\treturn view('back.pages.product.form', $d);\n }", "title": "" }, { "docid": "61066352fa31a37b0f1d8bc9fd229ea9", "score": "0.6895845", "text": "public function create()\n {\n /* $this->authorize('create'); */\n return view('refugio.refugioForm');\n }", "title": "" }, { "docid": "70820d35b4d8e319baa89b6f91a3d029", "score": "0.6894885", "text": "public function newAction() {\n $entity = new Recommandation();\n $form = $this->createCreateForm($entity);\n\n return $this->render('MyAppFrontBundle:Recommandation:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "title": "" }, { "docid": "619fa64afd3457bdc8d1c1a041acff47", "score": "0.688799", "text": "public function create()\n {\n return View(\"$this->view_folder.form\", $this->data);\n }", "title": "" }, { "docid": "09fab99adf688ea100aa90694eab5889", "score": "0.6887706", "text": "public function create()\n {\n return view(\"Amenity::add\");\n }", "title": "" }, { "docid": "bdb0161d2f2f44cdaea93bf890a4c02e", "score": "0.68875104", "text": "public function create()\n {\n return view(\"create\");\n }", "title": "" }, { "docid": "9664795bf81cca0f3e65d94f0f595082", "score": "0.6878992", "text": "public function create()\n\t{\n\t\treturn view('questao.create');\n\t}", "title": "" }, { "docid": "623f899bed6c6f380a03ffc99508b73d", "score": "0.68776965", "text": "public function newAction()\n {\n $entity = new Candidato();\n $form = $this->createForm(new CandidatoType(), $entity);\n\n return $this->render('EleicaoAdmBundle:Candidato:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "title": "" }, { "docid": "06fe0499ccb2038bd9c25e7ef14289e2", "score": "0.6876303", "text": "public function create()\n {\n //Return item details form\n return view('home.create');\n }", "title": "" }, { "docid": "a3b3bbcce8f8a6239dadc2917240252b", "score": "0.6875676", "text": "public function showForm()\n {\n return view('AdminView.create');\n }", "title": "" }, { "docid": "47e62b5d5e96751bc9e8ab90f94e7ea4", "score": "0.6875128", "text": "public function create()\n {\n return view('manager.new');\n }", "title": "" }, { "docid": "3557ca31989d52aabfc94b29a8b4779e", "score": "0.68745774", "text": "public function create()\n {\n return view('hari.create');\n }", "title": "" }, { "docid": "b3998fa6dce49f97902e942f97d98ede", "score": "0.68714374", "text": "public function newAction()\n {\n $entity = new Escuelas();\n $form = $this->createForm(new EscuelasType(), $entity);\n\n return $this->render('QQiRecordappBundle:Escuelas:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "title": "" }, { "docid": "9f18b1b1a35a9af23eb1d4bbdba665f8", "score": "0.68683904", "text": "public function create()\n {\n return view('admin.car_com.create');\n }", "title": "" }, { "docid": "96c76b820b73f95fa584de07ad04ad0a", "score": "0.68645674", "text": "public function create()\n {\n return view('nasabah/addnasabah');\n }", "title": "" }, { "docid": "e3cfac3178d9c5cb5ab322fa4785604c", "score": "0.68615323", "text": "public function create()\n {\n return view('Prenda.create');\n }", "title": "" }, { "docid": "451c07a3106f3c6e3d62757717bfa763", "score": "0.6859866", "text": "public function create()\n\t{\n\t\treturn view('horas.create');\n\t}", "title": "" }, { "docid": "f4672fc37d04d0e3bef9bc80e57323e9", "score": "0.6858471", "text": "public function create()\n {\n //\n $question= new Question();\n return view('dashboard.question.form', [\n \"question\" => $question\n ]);\n }", "title": "" }, { "docid": "95a4952039c4b40b058cc67fba7cd2d7", "score": "0.68551123", "text": "public function create () {\n $course = new Course();\n $btnText = __(\"Enviar curso para revisión\");\n\n return view('courses.form', compact('course', 'btnText'));\n }", "title": "" }, { "docid": "ca80651480f4bbbd35305ceefd136182", "score": "0.68507105", "text": "public function newAction()\n {\n $entity = new Alumni();\n $form = $this->createForm(new AlumniType(), $entity);\n\n return $this->renderTwig('Master/Alumni:form', array(\n 'entity' => $entity,\n 'edit_form' => $form->createView()\n ));\n }", "title": "" }, { "docid": "d58534453dca5d05eb6bf9759a643eaa", "score": "0.6850256", "text": "public function create()\n\t{\n\t\treturn View::make('create');\n\t}", "title": "" }, { "docid": "783d7ee63b2e492087fc641fa43b1ef1", "score": "0.68470246", "text": "public function create()\n\t{\n\t\treturn View::make('fornecedors.create');\n\t}", "title": "" }, { "docid": "2d13aa784138fe895746ebaa36bda96f", "score": "0.684698", "text": "public function create()\n {\n return view('hr.create');\n }", "title": "" }, { "docid": "b1d677deef4bb08323db61d502e8dcee", "score": "0.6842864", "text": "public function create()\n {\n return view('backend.book.create');\n }", "title": "" }, { "docid": "b1d677deef4bb08323db61d502e8dcee", "score": "0.6842864", "text": "public function create()\n {\n return view('backend.book.create');\n }", "title": "" } ]
767b88e96ad53a4fd0d743e9f9422b39
Add a period to the end of an article title unless it is a ".", "?", or "!"
[ { "docid": "6a6f678a3d004ee012e22dcc5671dddc", "score": "0.7553057", "text": "public static function addPeriod($articleTitle)\n\t{\n\t\t$len = strlen($articleTitle);\n\t\t$lastChar = substr($articleTitle, $len - 1, 1);\n\t\tif (($lastChar != \".\") && ($lastChar != \"?\") && ($lastChar != \"!\")) {\n\t\t\t$articleTitle = $articleTitle . \".\";\n\t\t}\n\n\t\treturn $articleTitle;\n\t}", "title": "" } ]
[ { "docid": "f70b4b6b46ba821f77522dbfcb37435b", "score": "0.60736257", "text": "function mon_plugin_the_title($title){\n //remplace et dans le titre\n $title = str_replace('et','&amp;', $title);\n //retourne le titre modifié\n return $title;\n }", "title": "" }, { "docid": "66654974e5add5123c22e6af4fff3e1f", "score": "0.60310924", "text": "public static function TruncateTitle($title) {\r\n\t\t\r\n\t\tif(strlen($title) > 40) {\r\n\t\t\t\r\n\t\t\treturn substr($title, 0, 40) . \"...\";\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\treturn $title;\r\n\t\t\r\n\t}", "title": "" }, { "docid": "0ea87aad7f9e81f32ecde1a23d9710a7", "score": "0.58792216", "text": "function df_add_blog_name_to_title ( $title, $sep, $raw_title ) {\n $site_title = get_bloginfo( 'name' );\n $title .= apply_filters( 'df_add_blog_name_to_title', $site_title );\n return $title;\n }", "title": "" }, { "docid": "1e9e247c6c268a77e59760eaaae8ce74", "score": "0.5850758", "text": "function filter_title( $movie_title ) {\n\t\t\t\n\t\t\t// Examples of bad titles.\n\t\t\t//3D BIG HERO 6\n\t\t\t//3D BOOK OF LIFE, THE\n\n\t\t\t$movie_title = str_replace( ' alt-1', '', $movie_title );\n\t\t\t$movie_title = str_replace( ' alt-2', '', $movie_title );\n\t\t\t$movie_title = str_replace( '3D ', '', $movie_title );\n\n\t\t\tif ( strpos( $movie_title, ', THE' ) !== false ) {\n\t\t\t\t$movie_title = str_replace( ', THE', '', $movie_title );\n\t\t\t\t$movie_title = 'THE '. $movie_title;\n\t\t\t}\n\t\t\t\n\t\t\t$movie_title = strtolower( $movie_title );\n\t\t\t$movie_title = ucwords( $movie_title );\n\t\t\t\n\t\t\treturn $movie_title;\n\t\t}", "title": "" }, { "docid": "084e6edcd54fcb7b1ab4b769022f5559", "score": "0.58361405", "text": "function remove_dot_from_excerpt( $remove ){\n return ' <a href=\" '. get_the_permalink() . ' \">....</a>';\n}", "title": "" }, { "docid": "8095e7ecc755366b1178d3936b640260", "score": "0.5753747", "text": "static function titleFormat($strTitle) {\n \t\t$strTitle = trim($strTitle);\n\n \t\t$rest = substr($strTitle, -5);\n \t\tif (!$rest) {\n \t\t\treturn $strTitle;\n \t\t}\n\n \t\t// Title ends with ', The'\n \t\tif (strcmp($rest, \", The\") == 0) {\n \t\t\t$strTitle = \"The \" . substr($strTitle, 0 , (strlen($strTitle)-5));\n \t\t\treturn $strTitle;\n \t\t} else {\n \t\t\treturn $strTitle;\n \t\t}\n\t}", "title": "" }, { "docid": "63d666098e7613978d39c27a3d489ad3", "score": "0.57412547", "text": "function pw_spe_filter_title($title = '', $post_id = 0)\n{\n\n\tif (pw_spe_is_expired($post_id)) {\n\t\t// Post is expired so attach the prefix\n\t\t$prefix = __('Expired:', 'wpplugin-simple-post-expiration');\n\t\t$title = $prefix . '&nbsp;' . $title;\n\t}\n\n\treturn $title;\n}", "title": "" }, { "docid": "a29ec29fe4140ad3486da466d939d1f4", "score": "0.5713346", "text": "function formatTitle($title = ''){\n\tif($title){\n\t\t$title.= ' | ';\n\t}\n\t\n\t$title .= $GLOBALS['defaultTitle'];\n\t\n\treturn $title;\n}", "title": "" }, { "docid": "6de0c9c101a54535a13ca723cfc0534f", "score": "0.5712329", "text": "public function getTitle(){\n if(is_null($this->_prepearedTitle)){\n $this->_prepearedTitle = Text::mb_ucfirst(mb_strtolower($this->title));\n $this->_prepearedTitle = preg_replace('~[!.? ]+$~', '', $this->_prepearedTitle);\n }\n return $this->_prepearedTitle;\n }", "title": "" }, { "docid": "0c1ba2652d8d02203ab48358bf6dafad", "score": "0.5699037", "text": "public function articleTitle()\n {\n $title = $this->getTitle();\n\n $search = [\n '{{ noun }}',\n '{{ verb }}',\n '{{ adjective }}',\n '{{ adverb }}',\n ];\n\n $replace = [\n $this->getNoun(),\n $this->getVerb(),\n $this->getAdjective(),\n $this->getAdverb(),\n ];\n\n $title = ucfirst(str_replace($search, $replace, $title));\n\n return $title;\n }", "title": "" }, { "docid": "b9a356e6733add7a270732939cbb26ef", "score": "0.56758463", "text": "public static function filterTitle( $title )\n {\n $options = app()->make( Options::class );\n\n if( !empty( $options->get( 'app_name' ) ) ) {\n return sprintf( '%s &rsaquo; %s &mdash; %s', $title, $options->get( 'app_name' ), config( 'app.name' ) );\n }\n\n return sprintf( '%s &rsaquo; %s', $title, config( 'app.name' ) );\n }", "title": "" }, { "docid": "64fe9286450b553113669cda6238d116", "score": "0.5653578", "text": "function yp_get_short_title($title){\n\n\t$title = ucfirst(strip_tags($title));\n\n\tif($title == ''){\n\t\t$title = 'Untitled';\n\t}\n\n\tif(strlen($title) > 18){\n\t\treturn mb_substr($title,0,18,'UTF-8').'..';\n\t}else{\n\t\treturn $title;\n\t}\n\n}", "title": "" }, { "docid": "bd7b75607716a0847a88e4d23283eeab", "score": "0.5621144", "text": "function shortTitle ($title){\n\t\t$title = substr($title, 0, -4);\n\t\t$title = str_replace('_', ' ', $title);\n\t\t$title = ucwords($title);\n\t\treturn $title;}", "title": "" }, { "docid": "009d44b03337bdbe66208cb50b8a9bb9", "score": "0.5610785", "text": "function launcheffect_wp_title( $title, $sep ) {\n\tglobal $paged, $page;\n\n\tif ( is_feed() )\n\t\treturn $title;\n\n\t// Add the site name.\n\t$title .= get_bloginfo( 'name' );\n\n\t// Add the site description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) )\n\t\t$title = \"$title $sep $site_description\";\n\n\t// Add a page number if necessary.\n\tif ( $paged >= 2 || $page >= 2 )\n\t\t$title = \"$title $sep \" . sprintf( __( 'Page %s', 'launcheffect' ), max( $paged, $page ) );\n\n\treturn $title;\n}", "title": "" }, { "docid": "d70063b8fa4854c54ef485ca1922ec57", "score": "0.5607913", "text": "private function setCleanTitle()\n {\n $this->title = stripslashes($this->data['title']);\n $this->cleanTitle = $this->data['date'] . \"-\" . preg_replace('/[^A-Za-z0-9]/', '_', stripslashes($this->data['title']));\n }", "title": "" }, { "docid": "85004c535e1d703ccf353196925ca7f7", "score": "0.56072974", "text": "function fang_wp_title( $title, $sep ) {\n\t\tif ( is_feed() ) {\n\t\t\treturn $title;\n\t\t}\n\n\t\tglobal $page, $paged;\n\n\t\t// Add the blog name\n\t\t$title .= get_bloginfo( 'name', 'display' );\n\n\t\t// Add the blog description for the home/front page.\n\t\t$site_description = get_bloginfo( 'description', 'display' );\n\t\tif ( $site_description && ( is_home() || is_front_page() ) ) {\n\t\t\t$title .= \" $sep $site_description\";\n\t\t}\n\n\t\t// Add a page number if necessary:\n\t\tif ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) {\n\t\t\t$title .= \" $sep \" . sprintf( __( 'Page %s', 'fang' ), max( $paged, $page ) );\n\t\t}\n\n\t\treturn $title;\n\t}", "title": "" }, { "docid": "19b77b58685ec22b50e7aa62c5c4f625", "score": "0.55968577", "text": "function sanitize_title_with_dashes($title) {\n $title = strip_tags($title);\n // Preserve escaped octets.\n $title = preg_replace('|%([a-fA-F0-9][a-fA-F0-9])|', '---$1---', $title);\n // Remove percent signs that are not part of an octet.\n $title = str_replace('%', '', $title);\n // Restore octets.\n $title = preg_replace('|---([a-fA-F0-9][a-fA-F0-9])---|', '%$1', $title);\n\n $title = $this->remove_accents($title);\n if ($this->seems_utf8($title)) {\n if (function_exists('mb_strtolower')) {\n $title = mb_strtolower($title, 'UTF-8');\n }\n $title = $this->utf8_uri_encode($title, 200);\n }\n\n $title = strtolower($title);\n $title = preg_replace('/&.+?;/', '', $title); // kill entities\n $title = str_replace('.', '-', $title);\n $title = preg_replace('/[^%a-z0-9 _-]/', '', $title);\n $title = preg_replace('/\\s+/', '-', $title);\n $title = preg_replace('|-+|', '-', $title);\n $title = trim($title, '-');\n\n $title = $this->sanitize_html_class($title);\n\n return $title;\n }", "title": "" }, { "docid": "84794181016b25834759ee03262e8f2f", "score": "0.55953246", "text": "function alhenalite_title( $title, $sep ) {\n\tglobal $paged, $page;\n\n\tif ( is_feed() )\n\t\treturn $title;\n\n\t// Add the site name.\n\t$title .= get_bloginfo( 'name' );\n\n\t// Add the site description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) )\n\t\t$title = \"$title $sep $site_description\";\n\n\t// Add a page number if necessary.\n\tif ( $paged >= 2 || $page >= 2 )\n\t\t$title = \"$title $sep \" . sprintf( __( 'Page %s', 'twentytwelve' ), max( $paged, $page ) );\n\n\treturn $title;\n}", "title": "" }, { "docid": "e42bdde191d4044ecfb6b977d469b982", "score": "0.55919296", "text": "function tm_dione_wp_title( $title, $sep ) {\n\t\tif ( is_feed() ) {\n\t\t\treturn $title;\n\t\t}\n\n\t\tglobal $page, $paged;\n\n\t\t// Add the blog name.\n\t\t$title .= get_bloginfo( 'name', 'display' );\n\n\t\t// Add the blog description for the home/front page.\n\t\t$site_description = get_bloginfo( 'description', 'display' );\n\t\tif ( $site_description && ( is_home() || is_front_page() ) ) {\n\t\t\t$title .= \" $sep $site_description\";\n\t\t}\n\n\t\t// Add a page number if necessary.\n\t\tif ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) {\n\t\t\t$title .= \" $sep \" . sprintf( esc_html__( 'Page %s', 'tm-dione' ), max( $paged, $page ) );\n\t\t}\n\n\t\treturn $title;\n\t}", "title": "" }, { "docid": "17d95132f5d183ea1d7e78ea453e6c33", "score": "0.5589287", "text": "function rewriteToLegalTitle($title) {\n\t/* modeled to match $wgLegalTitle */\n\treturn str_replace(array('_', '[', ']', '{', '}', '|', '#', '<', '>', '%', '+', '?', '~'),\n\t\t\t array('_usc', '_sbo', '_sbc', '_cbo', '_cbc', '_bar', '_hash', '_lt', '_gt', '_pct', '_plus', '_q', '_til'), $title);\n}", "title": "" }, { "docid": "4dcb6a3dc5aee491920676809ad41561", "score": "0.55806637", "text": "public static function formatFilenameFromTitle($title) {\n $title_strip_terms = array(\n \"recipe from\",\n \"recipes\",\n \"recipe\",\n );\n\n $title = strtolower($title);\n foreach ($title_strip_terms as $strip) {\n $title = str_replace($strip, '', $title);\n }\n\n // Split title on \" - \" or \" | \" or \" : \".\n #$parts = preg_split(\"/[\\-\\-\\|\\:]/\", $title);\n #$title = $parts[0];\n\n $title = preg_replace('/[^A-Za-z]+/', '_', $title);\n\n $title = preg_replace(\"/\\s+\\W\\s+/\", \"_\", $title); // remove single non-word chars\n $title = preg_replace(\"/\\s+/\", \"_\", $title); // normalize spaces\n $title = str_replace(\"_s_\", \"s_\", $title); // common issue of stranded _s_ for possessives\n $title = preg_replace(\"/_s$/\", \"s\", $title); // common issue of stranded _s_ for possessives\n $title = str_replace(\"__\", \"_\", $title);\n $title = trim($title, '_');\n\n $parts = explode(\"_\", $title);\n while (count($parts) > 6) {\n array_pop($parts);\n }\n $title = implode(\"_\", $parts);\n\n return $title;\n }", "title": "" }, { "docid": "2b88ad8f3ef8a8f4fabfc75a57a5e85b", "score": "0.5577395", "text": "function grd_custom_archive_title( $title ) {\n\t\treturn preg_replace( '#^[\\w\\d\\s]+:\\s*#', '', strip_tags( $title ) );\n\t}", "title": "" }, { "docid": "e3098a55615e759a4b98c213e2e1b2b3", "score": "0.55758363", "text": "function getTitle() \n\t{\n\t\t$arURL = $this->parseURL();\n\t\tswitch ($arURL[0]) {\n\t\t\tcase '':\n\t\t\t\t$string=\"Article... Lorem Ipsum\";\n\t\t\t\tbreak;\n\t\t}\n\t\treturn $string;\n\t}", "title": "" }, { "docid": "0a63d0099465e8a27d9f940d8ad04913", "score": "0.5570823", "text": "function shortTitle ($title){\r\n\t\t$title = substr($title, 0, -4);\r\n\t\t$title = str_replace('_', ' ', $title);\r\n\t\t$title = ucwords($title);\r\n\t\treturn $title;}", "title": "" }, { "docid": "164231e426ab769b36a51bb8606f0fde", "score": "0.55651534", "text": "function hyphenate_title($url_title) {\n\n\n\t$url_title = strtolower($url_title);\n\n\t$patterns = array();\n\t$replacements = array();\n\t\n\t\n\t$patterns[0] = '/\\b[a-z]\\b/';\n\t$replacements[0] = '';\n\n\t$patterns[1] = '/\\b[a-z][a-z]\\b/';\n\t$replacements[1] = '';\n\n\t$patterns[2] = '/[0-9] (value|regular)\\b/';\n\t$replacements[2] = '';\n\n\t$patterns[3] = '/[0-9] (towards|spend)\\b/';\n\t$replacements[3] = '';\n\n\t$patterns[4] = '/\\b(for|the|and|are|but|you|reg|your|more)\\b/i';\n\t$replacements[4] = '';\n\n\t$patterns[5] = '/&[0-9a-z]+;/';\n\t$replacements[5] = '-';\n\n\t$patterns[6] = '/[^a-z0-9\\-]/';\n\t$replacements[6] = '-';\n\n\t$patterns[7] = '/\\b[0-9]+\\b/';\n\t$replacements[7] = '-';\n\t\n\t$patterns[8] = '/ /';\n\t$replacements[8] = '-';\n\n\t$patterns[9] = '/-+/';\n\t$replacements[9] = '-';\n\n\t$patterns[10] = '/deal-ends-soon/';\n\t$replacements[10] = '';\n\n\t$patterns[11] = '/^-/';\n\t$replacements[11] = '';\n\n\t$patterns[12] = '/-$/';\n\t$replacements[12] = '';\n\t\n\t$url_title = preg_replace($patterns, $replacements, $url_title);\n\t\n\tif ($url_title == \"\") {\n\t\t$url_title = \"deal\";\n\t}\n\n\n\treturn $url_title;\n}", "title": "" }, { "docid": "4d57f452708c3fcc703f49b177e5d953", "score": "0.5553178", "text": "function socbet_filtered_wp_title( $title, $sep ) {\n\t$title .= get_bloginfo( 'name' );\n\n\t// Add the site description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\n\t$title = \"$title $sep $site_description\";\n\n\treturn $title;\n}", "title": "" }, { "docid": "d707e8a7f58b1275895f301beaf14d75", "score": "0.5548388", "text": "function friendly_title($title) {\n\t\t\t$title = trim($title);\n\t\t\t$title = strtolower($title);\n\t\t\t$title = preg_replace(\"/[^\\w ]/\",\"\",$title); \n\t\t\t$title = str_replace(\" \",\"-\",$title);\n\t\t\t$title = str_replace(\"--\",\"-\",$title);\n\t\t\treturn $title;\n\t\t}", "title": "" }, { "docid": "ba3e7d32e50384d954a8a51a050768ac", "score": "0.5546749", "text": "function cleanForFileSystem($title) {\r\n\t\t$allowedChars = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!,@#^()-=+ _{}';\r\n\t\t$newTitle = '';\r\n\t\t\r\n\t\tfor($i = 0; $i < strlen($title); $i++) {\r\n\t\t\tif (stripos($allowedChars, $title[$i]) === false) {\r\n\t\t\t\t$newTitle .= '_';\r\n\t\t\t} else {\r\n\t\t\t\t$newTitle .= $title[$i];\r\n\t\t\t} \r\n\t\t} # for\r\n\t\t\r\n\t\treturn $newTitle;\r\n\t}", "title": "" }, { "docid": "b6ef73c3866eb34f582dd827ffbad165", "score": "0.55349153", "text": "function removeDots($text){\n // returns string without dots\n $punct = ['.'];\n $arPunctFree = str_replace($punct, '', $text);\n return $arPunctFree;\n}", "title": "" }, { "docid": "f4a5fd4a3eb8dcb740b11ba9a6892ec9", "score": "0.5527449", "text": "function the_title_trim($title) {\n\t$title = attribute_escape($title);\n\t// What to find in the title\n\t$findthese = array(\n\t\t'#Protected:#', // # is just the delimeter\n\t\t'#Private:#'\n\t);\n\t// What to replace it with\n\t$replacewith = array(\n\t\t'Protected:',\n\t\t'##Private:##' // What to replace private with\n\t);\n\t// Items replace by array key\n\t$title = preg_replace($findthese, $replacewith, $title);\n\treturn $title;\n}", "title": "" }, { "docid": "acdb607bed653ac79d3aa26612586998", "score": "0.55272174", "text": "public function add_title($title, $separator = \" - \", $before = FALSE)\n\t{\n\t\tif ($before)\n\t\t{\n\t\t\t$this->title = HTML::chars(strip_tags($title)).( ! empty($this->title) ? $separator.$this->title : \"\");\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->title = ( ! empty($this->title) ? $this->title.$separator : \"\").HTML::chars(strip_tags($title));\n\t\t}\n\t}", "title": "" }, { "docid": "081c76017ba9a23d43829a88d4153b4c", "score": "0.552512", "text": "public function getFullTitle($sep = ' > ')\n\t{\n\t\treturn implode($sep, $this->getTitleParts());\n\t}", "title": "" }, { "docid": "3bcffdfd8c701bd3ec28c20f9302f437", "score": "0.5503596", "text": "private function processTitle($title)\n {\n // a very long title\n return preg_replace(\"#\\s[\\d]+\\/[\\d]+\\/[\\d]+\\s[\\d]+-[\\d]+-[\\d]+(\\s[\\d]+)?#\", '', $title ?? '');\n }", "title": "" }, { "docid": "440898507febc213fc166e5ba9df6106", "score": "0.55017465", "text": "protected function filterTitle()\n {\n return Str::title(str_replace('-', ' ', $this->filterName()));\n }", "title": "" }, { "docid": "4ad75bd72b9920eeb943e274dc157990", "score": "0.5495417", "text": "public function getContentTitle()\n {\n return \"\\\"\" . Helpers::truncateText($this->title, 25) . \"\\\"\";\n }", "title": "" }, { "docid": "70d0d985230117d1baf7090531dc5959", "score": "0.54871255", "text": "public function split_title($title,$num){\r\n\t\t$str=strlen($title);\r\n\t\tif($str> $num){\r\n\t\t\t$title=mb_substr($title,0,$num,'UTF-8');\r\n\t\t\t$title=$title. \"... \";\r\n\t\t}\r\n\t\treturn $title;\r\n\t}", "title": "" }, { "docid": "c9bbf006a95a8147aab7b6a4c3e62dab", "score": "0.5483478", "text": "private function getArticleTitle()\n {\n $originalTitle = null;\n\n if ($this->getTitle()) {\n $originalTitle = $this->getTitle();\n } else {\n $this->logger->debug('[Metadata] Could not find title in metadata, searching for the title tag...');\n $titleTag = $this->dom->getElementsByTagName('title');\n if ($titleTag->length > 0) {\n $this->logger->info(sprintf('[Metadata] Using title tag as article title: \\'%s\\'', $titleTag->item(0)->nodeValue));\n $originalTitle = $titleTag->item(0)->nodeValue;\n }\n }\n\n if ($originalTitle === null) {\n return null;\n }\n\n $curTitle = $originalTitle = trim($originalTitle);\n $titleHadHierarchicalSeparators = false;\n\n /*\n * If there's a separator in the title, first remove the final part\n *\n * Sanity warning: if you eval this match in PHPStorm's \"Evaluate expression\" box, it will return false\n * I can assure you it works properly if you let the code run.\n */\n if (preg_match('/ [\\|\\-\\\\\\\\\\/>»] /i', $curTitle)) {\n $titleHadHierarchicalSeparators = (bool) preg_match('/ [\\\\\\\\\\/>»] /', $curTitle);\n $curTitle = preg_replace('/(.*)[\\|\\-\\\\\\\\\\/>»] .*/i', '$1', $originalTitle);\n\n $this->logger->info(sprintf('[Metadata] Found hierarchical separators in title, new title is: \\'%s\\'', $curTitle));\n\n // If the resulting title is too short (3 words or fewer), remove\n // the first part instead:\n if (count(preg_split('/\\s+/', $curTitle)) < 3) {\n $curTitle = preg_replace('/[^\\|\\-\\\\\\\\\\/>»]*[\\|\\-\\\\\\\\\\/>»](.*)/i', '$1', $originalTitle);\n $this->logger->info(sprintf('[Metadata] Title too short, using the first part of the title instead: \\'%s\\'', $curTitle));\n }\n } elseif (strpos($curTitle, ': ') !== false) {\n // Check if we have an heading containing this exact string, so we\n // could assume it's the full title.\n $match = false;\n for ($i = 1; $i <= 2; $i++) {\n foreach ($this->dom->getElementsByTagName('h' . $i) as $hTag) {\n // Trim texts to avoid having false negatives when the title is surrounded by spaces or tabs\n if (trim($hTag->nodeValue) === trim($curTitle)) {\n $match = true;\n }\n }\n }\n\n // If we don't, let's extract the title out of the original title string.\n if (!$match) {\n $curTitle = substr($originalTitle, strrpos($originalTitle, ':') + 1);\n\n $this->logger->info(sprintf('[Metadata] Title has a colon in the middle, new title is: \\'%s\\'', $curTitle));\n\n // If the title is now too short, try the first colon instead:\n if (count(preg_split('/\\s+/', $curTitle)) < 3) {\n $curTitle = substr($originalTitle, strpos($originalTitle, ':') + 1);\n $this->logger->info(sprintf('[Metadata] Title too short, using the first part of the title instead: \\'%s\\'', $curTitle));\n } elseif (count(preg_split('/\\s+/', substr($curTitle, 0, strpos($curTitle, ':')))) > 5) {\n // But if we have too many words before the colon there's something weird\n // with the titles and the H tags so let's just use the original title instead\n $curTitle = $originalTitle;\n }\n }\n } elseif (mb_strlen($curTitle) > 150 || mb_strlen($curTitle) < 15) {\n $hOnes = $this->dom->getElementsByTagName('h1');\n\n if ($hOnes->length === 1) {\n $curTitle = $hOnes->item(0)->nodeValue;\n $this->logger->info(sprintf('[Metadata] Using title from an H1 node: \\'%s\\'', $curTitle));\n }\n }\n\n $curTitle = preg_replace(NodeUtility::$regexps['normalize'], ' ', trim($curTitle));\n\n /*\n * If we now have 4 words or fewer as our title, and either no\n * 'hierarchical' separators (\\, /, > or ») were found in the original\n * title or we decreased the number of words by more than 1 word, use\n * the original title.\n */\n $curTitleWordCount = count(preg_split('/\\s+/', $curTitle));\n $originalTitleWordCount = count(preg_split('/\\s+/', preg_replace('/[\\|\\-\\\\\\\\\\/>»]+/', '', $originalTitle))) - 1;\n\n if ($curTitleWordCount <= 4 &&\n (!$titleHadHierarchicalSeparators || $curTitleWordCount !== $originalTitleWordCount)) {\n $curTitle = $originalTitle;\n\n $this->logger->info(sprintf('Using title from an H1 node: \\'%s\\'', $curTitle));\n }\n\n return $curTitle;\n }", "title": "" }, { "docid": "664cec01d7c58cd9e81d9514d473c4f4", "score": "0.54735804", "text": "function wpdocs_filter_wp_title( $title, $sep ) {\n global $paged, $page;\n\n if ( is_feed() )\n return $title;\n\n // Add the site name.\n $title .= get_bloginfo( 'name' );\n\n // Add the site description for the home/front page.\n $site_description = get_bloginfo( 'description', 'display' );\n if ( $site_description && ( is_home() || is_front_page() ) )\n $title = \"$title $sep $site_description\";\n\n // Add a page number if necessary.\n if ( $paged >= 2 || $page >= 2 )\n $title = \"$title $sep \" . sprintf( __( 'Page %s', 'twentytwelve' ), max( $paged, $page ) );\n\n return $title;\n}", "title": "" }, { "docid": "7244efc6b3f003666d200da2831dc7bf", "score": "0.5472984", "text": "function fmt_title ($title) {\n\treturn strtr ($title, \"_\", \" \");\n}", "title": "" }, { "docid": "b08ec9e32b0235881a0ed4f6b93e3f07", "score": "0.54709625", "text": "function process_ew_title($title)\n{\n global $custom_settings;\n\n $title = trim($title); // We always trim, whether you like it or not!\n $title = preg_replace('/\\s+/', ' ', $title); // We also always condense any whitespace characters down to single spaces\n\n if ($custom_settings['standardize_title_format']) {\n $title = ucwords($title);\n $title = preg_replace(\"/\\s{2,}/\", ' ', $title);\n $lc_words = ['and', 'of', 'the'];\n foreach ($lc_words as $lc_word) {\n $title = str_replace(ucwords($lc_word), $lc_word, $title);\n }\n $title = ucfirst($title);\n }\n\n return $title;\n}", "title": "" }, { "docid": "db0ad94a01c0c26ef19a8a4425236a4e", "score": "0.54689157", "text": "function wp_foundation_wp_title( $title, $sep ) {\n\tif ( is_feed() ) {\n\t\treturn $title;\n\t}\n\n\tglobal $page, $paged;\n\n\t// Add the blog name\n\t$title .= get_bloginfo( 'name', 'display' );\n\n\t// Add the blog description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) ) {\n\t\t$title .= \" $sep $site_description\";\n\t}\n\n\t// Add a page number if necessary:\n\tif ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) {\n\t\t$title .= \" $sep \" . sprintf( __( 'Page %s', 'wp_foundation' ), max( $paged, $page ) );\n\t}\n\n\treturn $title;\n}", "title": "" }, { "docid": "0cc03256067901c001aa722141aeadde", "score": "0.5462012", "text": "function wpdev_bk_get_escape_season_filter_name($title){\r\n\r\n $title = str_replace(' ','_',$title);\r\n $title = strtolower($title);\r\n $title = esc_attr($title);\r\n\r\n return $title;\r\n}", "title": "" }, { "docid": "548b89c4f70cc9cc11e54c793e1347a5", "score": "0.5461674", "text": "function get_title($title) {\n global $kiwi;\n return $title . (isset($kiwi['title_append']) ? $kiwi['title_append'] : null);\n}", "title": "" }, { "docid": "a1bbb8ccd4161360dabc5d13d35733ec", "score": "0.54331803", "text": "function the_title_trim($title) {\n\n $title = attribute_escape($title);\n\n $findthese = array(\n '#Protected:#',\n '#Private:#'\n );\n\n $replacewith = array(\n '', // What to replace \"Protected:\" with\n '' // What to replace \"Private:\" with\n );\n\n $title = preg_replace($findthese, $replacewith, $title);\n return $title;\n }", "title": "" }, { "docid": "16369002428bf0f16e6441f6a0b82207", "score": "0.54133934", "text": "function short_title($after = '...', $length = 6, $textlen = 10) {\r\n $thistitle = get_the_title();\r\n $mytitle = explode(' ', get_the_title());\r\n if ((count($mytitle)>$length) || (mb_strlen($thistitle)> $textlen)) {\r\n while(((count($mytitle)>$length) || (mb_strlen($thistitle)> $textlen)) && (count($mytitle)>1)) {\r\n array_pop($mytitle);\r\n $thistitle = implode(\" \",$mytitle);\r\n }\r\n $morewords = 1;\r\n } else {\r\n $morewords = 0;\r\n }\r\n if (mb_strlen($thistitle)> $textlen) {\r\n $thistitle = mb_substr($thistitle, 0, $textlen);\r\n $morewords = 1;\r\n }\r\n if ($morewords==1) {\r\n $thistitle .= $after;\r\n }\r\n return $thistitle;\r\n}", "title": "" }, { "docid": "39576b85a848fbe1da0468af0b4b9c55", "score": "0.5412791", "text": "public function __toTitle($title)\n {\n static $titles;\n if (!isset($titles)) {\n $titles = explode(\",\", strtolower(Mage::getStoreConfig(self::XML_CONFIG_PATH_API_TITLES_LIST)));\n }\n if (in_array(strtolower($title), $titles)) {\n return $title;\n }\n\n return '';\n }", "title": "" }, { "docid": "c382d1e291ec4b4c735cd6f8c70f98a2", "score": "0.5406862", "text": "public function protected_title_format() {}", "title": "" }, { "docid": "c382d1e291ec4b4c735cd6f8c70f98a2", "score": "0.5406862", "text": "public function protected_title_format() {}", "title": "" }, { "docid": "42402c2579d05ad03209636a64ab28e2", "score": "0.5403539", "text": "public static function document_title_separator () : void \n {\n add_filter(\"document_title_separator\", function () {\n return \" | \";\n });\n }", "title": "" }, { "docid": "1c9d6d71d6bdcc4b13e54438482b4d39", "score": "0.5394915", "text": "function dai_wp_title( $title, $sep ) {\n if ( is_feed() ) {\n return $title;\n }\n\n global $page, $paged;\n\n // Add the blog name\n $title .= get_bloginfo( 'name', 'display' );\n\n // Add the blog description for the home/front page.\n $site_description = get_bloginfo( 'description', 'display' );\n if ( $site_description && ( is_home() || is_front_page() ) ) {\n $title .= \" $sep $site_description\";\n }\n\n // Add a page number if necessary:\n if ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) {\n $title .= \" $sep \" . sprintf( __( 'Page %s', 'dai' ), max( $paged, $page ) );\n }\n\n return $title;\n }", "title": "" }, { "docid": "3a21a771793dade63ecc6eeaaf153233", "score": "0.5379123", "text": "static public function formatTitle($title) {\n $title = self::formatAsOneLine($title);\n $title = preg_replace(\"/Sponsored recipe:?/i\", \"\", $title);\n $title = preg_replace(\"/\\s+recipe$/i\", \"\", $title);\n $title = preg_replace(\"/^Recipe\\s+for\\s+/i\", \"\", $title);\n return trim($title);\n }", "title": "" }, { "docid": "514cbaaaa68599daa012a2333aee0308", "score": "0.5378792", "text": "function vendd_wp_title( $title, $sep ) {\n\tif ( is_feed() ) {\n\t\treturn $title;\n\t}\n\n\tglobal $page, $paged;\n\n\t// Add the blog name\n\t$title .= get_bloginfo( 'name', 'display' );\n\n\t// Add the blog description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) ) {\n\t\t$title .= \" $sep $site_description\";\n\t}\n\n\t// Add a page number if necessary:\n\tif ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) {\n\t\t$title .= \" $sep \" . sprintf( __( 'Page %s', 'vendd' ), max( $paged, $page ) );\n\t}\n\n\treturn $title;\n}", "title": "" }, { "docid": "72d7d42da005eba48df0c64441c42e81", "score": "0.53760165", "text": "function foundation_title( $title, $sep ) {\n\tglobal $paged, $page;\n\n\tif ( is_feed() )\n\t\treturn $title;\n\n\t// Add the site name.\n\t$title .= get_bloginfo( 'name' );\n\n\t// Add the site description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) )\n\t\t$title = \"$title $sep $site_description\";\n\n\t// Add a page number if necessary.\n\tif ( $paged >= 2 || $page >= 2 )\n\t\t$title = \"$title $sep \" . sprintf( __( 'Page %s', 'foundation' ), max( $paged, $page ) );\n\n\treturn $title;\n}", "title": "" }, { "docid": "08d13de3f6a1018716cd4fe9418567a6", "score": "0.53674144", "text": "public function getTruncatedSectionTitle() {\n\t\treturn $this->language->embedBidi( $this->language->truncateForVisual(\n\t\t\t$this->getParsedSectionTitle(),\n\t\t\tEchoEventPresentationModel::SECTION_TITLE_RECOMMENDED_LENGTH,\n\t\t\t'...',\n\t\t\tfalse\n\t\t) );\n\t}", "title": "" }, { "docid": "eca6b1f07e7556d3f83359b203c67935", "score": "0.53597766", "text": "function handleTitle() {\n global $HTML, $page;\t\n\tglobal $lang_suffix;\n\tglobal $title_add;\n\tglobal $htmltitle_add;\n\t\n\t$title = $page[\"pa_title$lang_suffix\"] . $title_add;\n\t$htmltitle = $page[\"pa_title$lang_suffix\"] . $htmltitle_add;\n\t$subtitle = $page[\"pa_subtitle$lang_suffix\"];\n\t\n \t$HTML = str_replace(\"%title%\", $title, $HTML);\n\t$HTML = str_replace(\"%htmltitle%\", $htmltitle, $HTML);\n\t$HTML = str_replace(\"%subtitle%\", $subtitle, $HTML);\n}", "title": "" }, { "docid": "ebad9ff7b9de92a9ed77ff8d020d4e13", "score": "0.53552467", "text": "function wp_title( $title, $sep ) {\n global $paged, $page;\n\n if ( is_feed() ) {\n return $title;\n }\n\n if ( dokan_is_store_page() ) {\n $site_title = get_bloginfo( 'name' );\n $store_user = get_userdata( get_query_var( 'author' ) );\n $store_info = dokan_get_store_info( $store_user->ID );\n $store_name = esc_html( $store_info['store_name'] );\n $title = \"$store_name $sep $site_title\";\n\n // Add a page number if necessary.\n if ( $paged >= 2 || $page >= 2 ) {\n $title = \"$title $sep \" . sprintf( __( 'Page %s', 'dokan' ), max( $paged, $page ) );\n }\n\n return $title;\n }\n\n return $title;\n }", "title": "" }, { "docid": "291a137471e526a1aceb908c208b113f", "score": "0.5337636", "text": "function custom_title() {\n global $wp_query, $post;\n $html_title = get_post_meta($post->ID, 'custom_title', true);\n if ($html_title) {\n\n $title_string = $html_title;\n if (strlen($title_string) >200) {\n\n // truncate string\n $title_stringCut = substr($title_string, 0, 200);\n\n // make sure it ends in a word so assassinate doesn't become ass...\n $title_string = substr($title_stringCut, 0, strrpos($title_stringCut, ' ')).'...';\n }\n\n echo $title_string;\n }\n // if it doesn't exist fallback to default title\n else {\n the_title();\n }\n // Reset Post Data\nwp_reset_postdata();\n}", "title": "" }, { "docid": "cfe2fc03b9c3e28177ce0f1df04d7e6e", "score": "0.5333654", "text": "function show_untitled_items($title)\n{\n // is empty.\n $prepTitle = trim(strip_formatting($title));\n if (empty($prepTitle)) }\n return '[Untitled]';\n }", "title": "" }, { "docid": "984b32f673864946995a57a97f6555e7", "score": "0.53302175", "text": "function _prep_filename($filename)\r\n\t{\r\n\t\tif (strpos($filename, '.') === FALSE)\r\n\t\t{\r\n\t\t\treturn $filename;\r\n\t\t}\r\n\t\t\r\n\t\t$parts\t\t= explode('.', $filename);\r\n\t\t$ext\t\t= array_pop($parts);\r\n\t\t$filename\t= array_shift($parts);\r\n\t\t\t\t\r\n\t\tforeach ($parts as $part)\r\n\t\t{\r\n\t\t\tif ($this->mimes_types(strtolower($part)) === FALSE)\r\n\t\t\t{\r\n\t\t\t\t$filename .= '.'.$part.'_';\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\t$filename .= '.'.$part;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t$filename .= '.'.$ext;\r\n\t\t\r\n\t\treturn $filename;\r\n\t}", "title": "" }, { "docid": "2b7375af38c7970a8d747aef7a9891f5", "score": "0.53299475", "text": "protected function formatTitle($name) {\n $new_words = array();\n foreach(explode('/', $name) as $word) {\n $new_words[] = ucwords($word);\n } \n return implode('/', $new_words);\n }", "title": "" }, { "docid": "27d18f2b4c8f527a5b854c5b4341b87c", "score": "0.5325727", "text": "public function latest_post_title( $before = '', $after = '', $echo = true )\n\t{\n\t\t$title = $this->get_latest_post()->post_title;\n\n\t\tif ( ! is_admin() ) {\n\t\t\tif ( ! empty( $this->get_latest_post()->post_password ) ) {\n\t\t\t\t$title = sprintf( __( 'Protected: %s' ), $title );\n\t\t\t} else if ( isset($post->post_status) && 'private' == $this->get_latest_post()->post_status ) {\n\t\t\t\t$title = sprintf( __( 'Private: %s' ), $title );\n\t\t\t}\n\t\t}\n\t\t$the_title = apply_filters( 'the_title', $title );\n\n\t\tif ( strlen($title) == 0 ) {\n\t\t\treturn;\n\t\t}\n\n\t\t$title = $before . $title . $after;\n\n\t\tif ( $echo ) {\n\t\t\techo $title;\n\t\t} else {\n\t\t\treturn $title;\n\t\t}\n\t}", "title": "" }, { "docid": "eea3226f5e9e3b25e1b637b40eb0f7fe", "score": "0.53219414", "text": "function wke2014_filter_wp_title( $title, $separator ) {\r\n // Don't affect wp_title() calls in feeds.\r\n if ( is_feed() )\r\n return $title;\r\n\r\n // The $paged global variable contains the page number of a listing of posts.\r\n // The $page global variable contains the page number of a single post that is paged.\r\n // We'll display whichever one applies, if we're not looking at the first page.\r\n global $paged, $page;\r\n\r\n if ( is_search() ) {\r\n // If we're a search, let's start over:\r\n $title = sprintf( __( 'Suchergebnisse f&uuml;r %s', 'wke2014' ), '\"' . get_search_query() . '\"' );\r\n // Add a page number if we're on page 2 or more:\r\n if ( $paged >= 2 )\r\n $title .= \" $separator \" . sprintf( __( 'Seite %s', 'wke2014' ), $paged );\r\n // Add the site name to the end:\r\n $title .= \" $separator \" . get_bloginfo( 'name', 'display' );\r\n // We're done. Let's send the new title back to wp_title():\r\n return $title;\r\n }\r\n\r\n // Otherwise, let's start by adding the site name to the end:\r\n $title .= get_bloginfo( 'name', 'display' );\r\n\r\n // If we have a site description and we're on the home/front page, add the description:\r\n $site_description = get_bloginfo( 'description', 'display' );\r\n if ( $site_description && ( is_home() || is_front_page() ) )\r\n $title .= \" $separator \" . $site_description;\r\n\r\n // Add a page number if necessary:\r\n if ( $paged >= 2 || $page >= 2 )\r\n $title .= \" $separator \" . sprintf( __( 'Seite %s', 'wke2014' ), max( $paged, $page ) );\r\n\r\n // Return the new title to wp_title():\r\n return $title;\r\n}", "title": "" }, { "docid": "a62cce24ddc9175d6c9c826bad6ba586", "score": "0.53135633", "text": "public function getTitlePageSuffix()\n {\n }", "title": "" }, { "docid": "d099a314d6bdd4dd233a1f3a6a66ca62", "score": "0.53047955", "text": "function anva_wp_title( $title, $sep ) {\n\tif ( is_feed() ) {\n\t\treturn $title;\n\t}\n\n\tglobal $page, $paged;\n\n\t// Add the blog name\n\t$title .= get_bloginfo( 'name', 'display' );\n\n\t// Add the blog description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) ) {\n\t\t$title .= \" $sep $site_description\";\n\t}\n\n\t// Add a page number if necessary:\n\tif ( $paged >= 2 || $page >= 2 ) {\n\t\t$title .= \" $sep \" . sprintf( anva_get_local( 'page' ) .' %s', max( $paged, $page ) );\n\t}\n\n\treturn $title;\n}", "title": "" }, { "docid": "4e0191b0ce6a7bbfb9117dc60aba463e", "score": "0.5303477", "text": "function domica_filter_theme_wp_title( $title, $sep ) {\n\tglobal $paged, $page;\n\n\tif ( is_feed() ) {\n\t\treturn $title;\n\t}\n\n\t// Add the site name.\n\t$title .= get_bloginfo( 'name', 'display' );\n\n\t// Add the site description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) ) {\n\t\t$title = \"$title $sep $site_description\";\n\t}\n\n\t// Add a page number if necessary.\n\tif ( $paged >= 2 || $page >= 2 ) {\n\t\t$title = \"$title $sep \" . sprintf( esc_html__( 'Page %s', 'domica'), max( $paged, $page ) );\n\t}\n\n\treturn $title;\n}", "title": "" }, { "docid": "efb02018ffb1a935ac17e0bec36abe61", "score": "0.5289307", "text": "public function sofa_link_format_title_filter($title) {\n return '<a class=\"with-icon\" data-icon=\"&#xf0C1;\"' . substr( $title, 2 );\n }", "title": "" }, { "docid": "71ea5734e90fb5bc83a58740f535332b", "score": "0.5287105", "text": "function jb_rewrite_title_rss($title) {\n\tglobal $wp_query;\n\t$postid = $wp_query->post->ID;\n\t\n\tif(is_feed() && get_post_format($postid)){\n\t\t$title = \"→ \". $title;\n\t}\n\t\n\treturn $title;\n}", "title": "" }, { "docid": "52c5dfd955b0f565c6cefd8cc9b6ba1d", "score": "0.5279732", "text": "function the_title_limit($length, $replacer = '...') {\n\t$string = the_title('','',false);\n\tif(strlen($string) > $length)\n\t$string = (preg_match('/^(.*)\\W.*$/', substr($string, 0, $length+1), $matches) ? $matches[1] : substr($string, 0, $length)) . $replacer;\n\techo $string;\n}", "title": "" }, { "docid": "87f68b429de5fc8fa5f53fc3e3289bb1", "score": "0.52619404", "text": "public function title() {\n return Html::escape($this->config->get('publications.title')) ?? 'Publications';\n }", "title": "" }, { "docid": "6b98609006c3b3b722d9bbae5405b08d", "score": "0.52491283", "text": "private function generateWithDotsWord()\n\t{\n\t\tforeach( $this->getWordLetters() as $key => $val )\n\t\t{\n\t\t\tif( !isset( $this->foundLettersHelper[ $key ] ) )\n\t\t\t{\n\t\t\t\t$this->foundLettersHelper[ $key ] = \".\";\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "14f2ed951d166259b2406dc1964d271b", "score": "0.52416587", "text": "function yucom_filter_title_text($title)\n{\n $scr = get_current_screen();\n if ('gmember' == $scr->post_type)\n $title = 'Mitglied Nickname eintragen';\n return ($title);\n}", "title": "" }, { "docid": "a9b6bb5046a7fd9342f7309648443535", "score": "0.52332115", "text": "function truncate_article($string)\n{\n return $truncated = (strlen($string) > 365) ? substr($string, 0, 365) . '...' : $string;\n}", "title": "" }, { "docid": "2cf59241d7aea4a80816c2dcac6c4b39", "score": "0.52325004", "text": "public function addTitleAfter($title, $sep = ', ') {\r\n\t\t$this->setMetaAfter('title', $title, $sep);\r\n\t}", "title": "" }, { "docid": "513c722c8a67b45c34d4defd1ade7617", "score": "0.5223464", "text": "public function document_title_parts( $title ) { \n\n\t\t\t// Home page or not amending inner pages\n\t\t\tif ( is_front_page() || ipress_is_home_page() ) { return $title; }\n\t\t\n\t\t\t// Append site name?\n\t\t\t$app_site_name = (bool) apply_filters( 'ipress_append_site_name', true );\n\t\t\t$title['site'] = ( $app_site_name ) ? get_bloginfo( 'name' ) : '';\n\n\t\t\t// Return\n\t\t\treturn $title; \n\t\t}", "title": "" }, { "docid": "4e15ebb41c30d1877efaf21eac8fb71a", "score": "0.52159876", "text": "function cbstdsys_filter_wp_title( $title, $separator ) {\n\t\t\t\tif ( is_feed() )\n\t\t\t\t\t\treturn $title;\n\n\t\t\t\tglobal $paged, $page, $post;\n\n\t\t\t\tif ( is_search() ) {\n\t\t\t\t\t\t$title = sprintf( __( 'Search results for %s', 'cb-std-sys' ), '\\'' . get_search_query() . '\\'' );\n\t\t\t\t\t\tif ( $paged >= 2 )\n\t\t\t\t\t\t\t\t$title .= \" $separator \" . sprintf( __( 'Page %s', 'cb-std-sys' ), $paged );\n\t\t\t\t\t\t$title .= \" $separator \" . get_bloginfo( 'name', 'display' );\n\t\t\t\t\t\treturn $title;\n\t\t\t\t}\n\n\t\t\t\tif ( is_singular() && has_category( $post ) ) {\n\t\t\t\t\t $cats = array_reverse( get_the_category( $post->ID ) );\n\t\t\t\t\t if (!empty($cats) ){\n\t\t\t\t\t\t\t\t$parents = get_category_parents( $cats[0]->term_id, false, $separator );\n\t\t\t\t\t\t\t\t$parents\t=\tsubstr($parents,0,-1) ;\n\t\t\t\t\t\t\t\t$parents = trim($parents);\n\t\t\t\t\t\t \t$parents = explode($separator,$parents);\n\t\t\t\t\t\t\t\t$parents = array_reverse($parents);\n\t\t\t\t\t\t\t\tarray_walk($parents, create_function('&$parents', '$parents = $parents.\" | \";'));\n\t\t\t\t\t\t\t\t$parents = implode(\" \",$parents );\n\t\t\t\t\t\t\t\t$title .= $parents;\n\t\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$title .= get_bloginfo( 'name', 'display' );\n\n\t\t\t\t$site_description = get_bloginfo( 'description', 'display' );\n\t\t\t\tif ( $site_description && ( is_home() || is_front_page() ) )\n\t\t\t\t\t\t$title .= \" $separator \" . $site_description;\n\n\t\t\t\tif ( $paged >= 2 || $page >= 2 )\n\t\t\t\t\t\t$title .= \" $separator \" . sprintf( __( 'Page %s', 'cb-std-sys' ), max( $paged, $page ) );\n\n\t\t\t\treturn $title;\n\t\t}", "title": "" }, { "docid": "6c3c889d034faaf735359ea23a4ad7b9", "score": "0.5214398", "text": "function mayflower_untitled_post( $title ) {\n\tif ( '' == $title ) {\n\t\treturn apply_filters( 'mayflower_untitled_post_title', '<em>(' . __( 'Untitled', 'mayflower' ) . ')</em>' );\n\t} else {\n\t\treturn $title;\n\t}\n}", "title": "" }, { "docid": "1754bbafe8b31aebcf874ffe7ca9d833", "score": "0.5213782", "text": "public function trigger_title($title) {\n return htmlspecialchars(strip_tags($title));\n }", "title": "" }, { "docid": "3d6103b514dcc4bde279c66738af1eaf", "score": "0.52130514", "text": "function _prep_filename($filename)\n\t{\n\t\tif (strpos($filename, '.') === FALSE)\n\t\t{\n\t\t\treturn $filename;\n\t\t}\n\n\t\t$parts\t\t= explode('.', $filename);\n\t\t$ext\t\t= array_pop($parts);\n\t\t$filename\t= array_shift($parts);\n\n\t\tforeach ($parts as $part)\n\t\t{\n\t\t\tif ($this->mimes_types(strtolower($part)) === FALSE)\n\t\t\t{\n\t\t\t\t$filename .= '.'.$part.'_';\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$filename .= '.'.$part;\n\t\t\t}\n\t\t}\n\n\t\t// file name override, since the exact name is provided, no need to\n\t\t// run it through a $this->mimes check.\n\t\t/*\n\t\tif ($this->file_name != '')\n\t\t{\n\t\t\t$filename = $this->file_name;\n\t\t}\n\t\t*/\n\n\t\t$filename .= '.'.$ext;\n\t\t\n\t\treturn $filename;\n\t}", "title": "" }, { "docid": "c7006a50e610263f87f2c698bf723534", "score": "0.52126807", "text": "function delespecialchars ($title){\n\t$a = \"Á É Í Ó Ú Ý á é í ó ú ý À È Ì Ò Ù à è ì ò ù Ä Ë Ï Ö Ü ä ë ï ö ü ÿ Â Ê Î Ô Û â ê î ô û Ç ç Ñ ñ º ª \\\\ \\\" · # $ ~ % & ¬ / ( ) = ? ' ¿ ¡ { } + ] [ * ^ . : , ; ´ ` - < > | @ €\";\n\t$a = explode(' ', $a);\n\t$title = str_replace($a, \"_\", $title);\n\t$title = str_replace(\" \", \"_\", $title);\n\treturn $title;\n}", "title": "" }, { "docid": "2cce921fe82db284b43dfd3653ae4d7a", "score": "0.52034473", "text": "function fancy_amp($title) {\n #if(in_the_loop()) {\n $title = preg_replace(\"@(?![^<]+>)&amp;@\", \"<span class=\\\"amp\\\">&amp;</span>\", \"$title\");\n $title = preg_replace(\"@(?![^<]+>)&#038;@\", \"<span class=\\\"amp\\\">&#038;</span>\", \"$title\");\n #}\n return $title;\n }", "title": "" }, { "docid": "ecbc09aacac1d2e8a6b5e85e49b7de4a", "score": "0.52030164", "text": "function truncate_string($title_string, $truncate_after_nr_chars = 50){\n\n\t$nr_of_chars = strlen($title_string);\n\tif($nr_of_chars >= $truncate_after_nr_chars){\n\t\t$title_string = substr_replace( $title_string, \"...\", $truncate_after_nr_chars, $nr_of_chars - $truncate_after_nr_chars);\n\t}\n\treturn $title_string;\n}", "title": "" }, { "docid": "0943662870b43175a5de7dfb318b285e", "score": "0.5198754", "text": "public static function prependDocumentTitle($title){\n\t\tself::$_documentTitle = $title.self::$_documentTitle;\n\t}", "title": "" }, { "docid": "f56c3745784b00accceab3fa717470d5", "score": "0.51968396", "text": "function ttfmake_wp_title( $title, $sep ) {\n\tglobal $page, $paged;\n\n\tif ( is_feed() ) {\n\t\treturn $title;\n\t}\n\n\t// Add the blog name\n\t$title .= get_bloginfo( 'name' );\n\n\t// Add the blog description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) ) {\n\t\t$title .= \" $sep $site_description\";\n\t}\n\n\t// Add a page number if necessary:\n\tif ( $paged >= 2 || $page >= 2 ) {\n\t\t$title .= \" $sep \" . sprintf( __( 'Page %s', 'make' ), max( $paged, $page ) );\n\t}\n\n\treturn $title;\n}", "title": "" }, { "docid": "583fc943d22bc6069ca5acf556282575", "score": "0.51924586", "text": "function writr_wp_title( $title, $sep ) {\n\tglobal $page, $paged;\n\n\tif ( is_feed() )\n\t\treturn $title;\n\n\t// Add the blog name\n\t$title .= get_bloginfo( 'name' );\n\n\t// Add the blog description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) )\n\t\t$title .= \" $sep $site_description\";\n\n\t// Add a page number if necessary:\n\tif ( $paged >= 2 || $page >= 2 )\n\t\t$title .= \" $sep \" . sprintf( __( 'Page %s', 'writr' ), max( $paged, $page ) );\n\n\treturn $title;\n}", "title": "" }, { "docid": "d0580e5a3f35784cd9f80318389ffcd9", "score": "0.5189111", "text": "function hillsborough_wp_title( $title, $sep ) {\n\tglobal $page, $paged;\n\n\tif ( is_feed() )\n\t\treturn $title;\n\n\t// Add the blog name\n\t$title .= get_bloginfo( 'name' );\n\n\t// Add the blog description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) )\n\t\t$title .= \" $sep $site_description\";\n\n\t// Add a page number if necessary:\n\tif ( $paged >= 2 || $page >= 2 )\n\t\t$title .= \" $sep \" . sprintf( __( 'Page %s', 'hillsborough' ), max( $paged, $page ) );\n\n\treturn $title;\n}", "title": "" }, { "docid": "fd69b7fd6a67406155d92c9b78b87df9", "score": "0.5183656", "text": "function intellipaat_wpseo_coursename_filter($var){\r\n\tglobal $post;\r\n\tif (is_singular() && $post->post_type == 'course' && !is_admin()) {\r\n\t\t\r\n\t\treturn str_replace(array('Training', 'training'), array('',''), $post->post_title);\r\n\r\n }\r\n\treturn $var;\r\n}", "title": "" }, { "docid": "c1d0841b229bac497d8245ca263e063f", "score": "0.5183584", "text": "public function convertTitle(): string\n {\n if ($this->title === null) {\n return '';\n }\n\n foreach ($this->splitWords() as $index => $word) {\n if ($this->wordShouldBeUppercase($index, $word)) {\n $this->rebuildTitle($index, $this->uppercaseWord($word));\n }\n }\n\n return $this->title ?? '';\n }", "title": "" }, { "docid": "6265f8e0440ccf54192566c25a9a9d5a", "score": "0.51806664", "text": "function desanitize_title($input) {\n\t\treturn ucwords(str_replace(array(\"-\",\"_\"), array(\" \",\" \"), $input));\n\t}", "title": "" }, { "docid": "08ce7bdd195028547eac1c1f6c5d44b1", "score": "0.5175588", "text": "function pojo_wp_title( $title, $sep ) {\n\tglobal $paged, $page;\n\n\tif ( is_feed() ) {\n\t\treturn $title;\n\t}\n\n\t// Add the site name.\n\t$title .= get_bloginfo( 'name', 'display' );\n\n\t// Add the site description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) ) {\n\t\t$title = \"$title $sep $site_description\";\n\t}\n\n\t// Add a page number if necessary.\n\tif ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) {\n\t\t$title = \"$title $sep \" . sprintf( __( 'Page %s', 'pojo' ), max( $paged, $page ) );\n\t}\n\n\treturn $title;\n}", "title": "" }, { "docid": "72b8c93fb35e11b401eeed0342d077b3", "score": "0.517508", "text": "function get_title($cut_at = '') {\r\n $buffy = '';\r\n if (!empty($this->title)) {\r\n $buffy .= '<h1 class=\"entry-title\">';\r\n if ($this->is_single === true) {\r\n $buffy .= $this->title;\r\n } else {\r\n $buffy .='<a href=\"' . $this->href . '\" rel=\"bookmark\" title=\"' . $this->title_attribute . '\">';\r\n $buffy .= $this->title;\r\n $buffy .='</a>';\r\n }\r\n $buffy .= '</h1>';\r\n }\r\n\r\n return $buffy;\r\n }", "title": "" }, { "docid": "0fd8383edef9e016549ff282e2495666", "score": "0.5167339", "text": "function ici_wp_title( $title, $sep ) {\n\tglobal $paged, $page;\n\n\tif ( is_feed() ) {\n\t\treturn $title;\n\t}\n\n\t// Add the site name.\n\t$title .= get_bloginfo( 'name', 'display' );\n\n\t// Add the site description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) ) {\n\t\t$title = \"$title $sep $site_description\";\n\t}\n\n\t// Add a page number if necessary.\n\tif ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) {\n\t\t$title = \"$title $sep \" . sprintf( __( 'Page %s', 'buenoste' ), max( $paged, $page ) );\n\t}\n\n\treturn $title;\n }", "title": "" }, { "docid": "777eb9d72fcf288c1bfc09cbf58732c8", "score": "0.5155542", "text": "function kittysite_wp_title( $title, $sep ) {\n\tglobal $paged, $page;\n\n\tif ( is_feed() )\n\t\treturn $title;\n\n\t// Add the site name.\n\t$title .= get_bloginfo( 'name' );\n\n\t// Add the site description for the home/front page.\n\t$site_description = get_bloginfo( 'description', 'display' );\n\tif ( $site_description && ( is_home() || is_front_page() ) )\n\t\t$title = \"$title $sep $site_description\";\n\n\t// Add a page number if necessary.\n\tif ( $paged >= 2 || $page >= 2 )\n\t\t$title = \"$title $sep \" . sprintf( __( 'Page %s', 'kittysite' ), max( $paged, $page ) );\n\n\treturn $title;\n}", "title": "" }, { "docid": "7ea6af41adc4bcb0578dd48850c37179", "score": "0.51547587", "text": "private function getExtNameNoUnderscores()\n {\n return str_replace('_', '', $this->extension);\n }", "title": "" }, { "docid": "a1d03a7b8e517c192bd0252517cb011e", "score": "0.51516896", "text": "function rosewellness_no_ellipsis($more) {\n global $post;\n return '';\n}", "title": "" }, { "docid": "a8c99220939a4a38ef515c103e095b16", "score": "0.51504654", "text": "function sanitise_topic_title($title)\n{\n\t$matches=array();\n\tif (preg_match('# \\(\\#(.*)\\)$#',$title,$matches)!=0)\n\t{\n\t\treturn $matches[1];\n\t}\n\treturn $title;\n}", "title": "" }, { "docid": "235f271d744f5701064dbcd8022b4941", "score": "0.5148893", "text": "public function title($title){\n return '<title>'.$title.'</title>';\n }", "title": "" }, { "docid": "f9e7619290ee3e8ab1819b66dff5661e", "score": "0.5145671", "text": "private function _getSanitizedWorkbookTitle($title)\n {\n return preg_replace('/[^aA-zZ0-9\\_\\-\\.]/', '', $title);\n }", "title": "" }, { "docid": "9906f40e314a5e0571b605ffa7a8e7e1", "score": "0.5142122", "text": "public function apaGetSecondaryTitle($title){\n\t\treturn ($title !== '' && $title != null ? ' ' . trim($title) : '');\n\t}", "title": "" }, { "docid": "717d7bafb529351719defbd81d7b7337", "score": "0.5138598", "text": "function recortar_titulo2($tit){\n $ret = \"\";\n if(strlen($tit) > 12){$ret = substr($tit, 0, 11). \"...\";}\n else{$ret = $tit;}\n return $ret;\n}", "title": "" }, { "docid": "e032f6cf17645cc0fbde93cb6ee68718", "score": "0.5134623", "text": "function filter_wp_title( $title ) {\n\t\tglobal $page, $paged;\n\n\t\tif ( is_feed() )\n\t\t\treturn $title;\n\n\t\t$site_description = get_bloginfo( 'description' );\n\n\t\t$filtered_title = $title . get_bloginfo( 'name' );\n\t\t$filtered_title .= ( ! empty( $site_description ) && ( is_home() || is_front_page() ) ) ? ' | ' . $site_description: '';\n\t\t$filtered_title .= ( 2 <= $paged || 2 <= $page ) ? ' | ' . sprintf( __( 'Page %s', 'neighborhood' ), max( $paged, $page ) ) : '';\n\n\t\treturn $filtered_title;\n\t}", "title": "" } ]
93a6fe1f583639e06c09ea68dbf2ee03
Specifies the directory where drush will store backups.
[ { "docid": "4a81254baa0da46069d27a9918b03320", "score": "0.5724389", "text": "public function setBackupLocation(PhingFile $directory) {\n $this->createOption()\n ->setName('backup-location')\n ->addText($directory->getAbsolutePath());\n }", "title": "" } ]
[ { "docid": "76a096542bd706f2da483768c1dcee13", "score": "0.60043246", "text": "protected function setUploadDirectory()\n {\n $config = Config::getInstance();\n $this->dir = '../' . $config->get('upload_dir') . '/users/' . $this->user->get('directory');\n }", "title": "" }, { "docid": "07c8f21436c9327acd20b1652a52bd3c", "score": "0.5858324", "text": "static protected function _backupDirectory (string $sPath = null) {\n if ($sPath) {\n self::$_sBackupPath = $sPath;\n }\n return self::$_sBackupPath;\n }", "title": "" }, { "docid": "f60293ba9aaee62969db15395bc5d9d5", "score": "0.5759663", "text": "function getDataDirectory()\n {\n return \"{$this->bagDirectory}/data\";\n }", "title": "" }, { "docid": "154e33aa23f08f397fb901327e913365", "score": "0.5661669", "text": "public function directory()\n\t{\n\t\treturn storage_path().\"/runs/$this->dir\";\n\t}", "title": "" }, { "docid": "e892dac65dbb4f8f39aa0d4f13d9313b", "score": "0.5617421", "text": "protected function assignSeedsDir()\n {\n $this->seeds_dir = BLEND_TEST_SEEDS_DIR;\n }", "title": "" }, { "docid": "e892dac65dbb4f8f39aa0d4f13d9313b", "score": "0.5617421", "text": "protected function assignSeedsDir()\n {\n $this->seeds_dir = BLEND_TEST_SEEDS_DIR;\n }", "title": "" }, { "docid": "49ebb0fbb1e35876cee0b4c59d3cc997", "score": "0.55819863", "text": "public function db_directory() {\n\t\t$path = $this->_config['db_dir'] . \\DIRECTORY_SEPARATOR;\n\t\tif ( \\array_key_exists( 'directory', $this->_config['db'][ $this->_env ] ) ) {\n\t\t\treturn $path . $this->_config['db'][ $this->_env ]['directory'];\n\t\t}\n\t\treturn $path . $this->_config['db'][ $this->_env ]['database'];\n\t}", "title": "" }, { "docid": "31853322641951c5d5ed30bf0df39686", "score": "0.55756193", "text": "private function set_dir()\n {\n getcwd();\n chdir('application');\n chdir('modules');\n chdir('compare');\n }", "title": "" }, { "docid": "fb3b32e45c89a8fdc665bcc0c742cba3", "score": "0.5513594", "text": "public function getVarDir()\n {\n return Mage::getBaseDir(Mage::helper('maverick_logs')->base_dir_type);\n }", "title": "" }, { "docid": "c6c19c6a9fa26a6183be2493c1913ba3", "score": "0.54744697", "text": "public function setDirectory($directory){ }", "title": "" }, { "docid": "bb8b45ecfa6629a2a6419a63035c1380", "score": "0.5451006", "text": "private function setDirectoryParameters()\n {\n $this->application['app_dir'] = realpath(__DIR__.'/../app');\n $this->application['cache_dir'] = realpath($this->application['app_dir'].'/cache');\n $this->application['logs_dir'] = realpath($this->application['app_dir'].'/logs');\n $this->application['config_dir'] = realpath($this->application['app_dir'].'/config');\n $this->application['src_dir'] = realpath(__DIR__);\n }", "title": "" }, { "docid": "95c482b8899dd5f76c2e013e2b2495a3", "score": "0.54433465", "text": "protected function setDirs()\n\t{\n\t\t$this->assignDirs(static::DIRS);\n\t}", "title": "" }, { "docid": "5c179d2e563dd3dd5da5a004a6d0c6fb", "score": "0.54189396", "text": "public function getSeedFolderPath() : string\n {\n return base_path() . '/database/seeders';\n }", "title": "" }, { "docid": "42dd2c804eb8d587fb0d95a544d4e156", "score": "0.5410262", "text": "public static function getBackupBase() {\n\t\treturn \\OCP\\Config::getSystemValue(\"datadirectory\", \\OC::$SERVERROOT . \"/data\") . '/updater_backup/';\n\t}", "title": "" }, { "docid": "de7d57b5198a9b3531810be081fbf48a", "score": "0.5394839", "text": "public function setDir($value)\n {\n $this->setProperty('dir', $value);\n }", "title": "" }, { "docid": "81dc9a55a1478c867a8f5d7fab2729d6", "score": "0.5360938", "text": "public function dnsmasqUserConfigDir()\n {\n return VALET_HOME_PATH . '/dnsmasq.d/';\n }", "title": "" }, { "docid": "910643d7e3a68cec75d3207df4d8b3e6", "score": "0.5354535", "text": "public function setDataDirPath($dataDirPath)\n {\n $this->dataDirPath = $dataDirPath;\n }", "title": "" }, { "docid": "1729a7bbce72d9a4760451592dae0b70", "score": "0.535378", "text": "public static function directory() {\n return DOCROOT . Symphony::Configuration()->get('directory', 'db_manager');\n }", "title": "" }, { "docid": "0e313ae84d4a32e6507262b6cc409937", "score": "0.5258564", "text": "public function directory();", "title": "" }, { "docid": "20be4c3db06dffdddc94086154c9e629", "score": "0.5252375", "text": "function gstore_dir($gstore_id=NULL)\n {\n\t if( !$gstore_id && $this->gstore_exists )\n $gstore_id = $this->gstore_info['gstore_id'];\n \n\t $subdir = $gstore_id+999-(($gstore_id-1)%1000);\n\t $gstoredir = \"./uploads_gstore/$subdir/$gstore_id/\";\n\t return $gstoredir;\n\t}", "title": "" }, { "docid": "b9a8d65a40cff9d6afb8761993f32188", "score": "0.5243361", "text": "public static function set_defaultconfigdirectory($dir) {\n\t\t\tself::$filedir = $dir;\n\t\t}", "title": "" }, { "docid": "deb9a8b16bd1393f751fc60a5a8f0134", "score": "0.5205888", "text": "public function setCacheDir($value)\n {\n // add a trailing DIRECTORY_SEPARATOR if necessary\n $value = rtrim($value, '\\\\/') . DIRECTORY_SEPARATOR;\n $this->setOption('cache_dir', $value);\n }", "title": "" }, { "docid": "da3f83962c927dd02f45690a4c54b871", "score": "0.5199831", "text": "protected function _configDirectory() {\n\t\t\treturn realpath(\n\t\t\t\tdirname(__FILE__) . DS . '..' . DS . 'config' . DS . 'transports'\n\t\t\t) . DS;\n\t\t}", "title": "" }, { "docid": "6f214913aa99588b66c780d2c9381e7c", "score": "0.5188375", "text": "public function getUploadDir()\n {\n return \"collages/{$this->id}\";\n }", "title": "" }, { "docid": "a659d3c0c4249f3eb3e107640d301b9c", "score": "0.5182724", "text": "public function SetDirectory( $save_dir = '' )\n\t{\n\t\tif ( ! empty($save_dir))\n\t\t{\n\t\t\tif (is_dir($save_dir)) $this->save_dir = $save_dir;\n\t\t\telse {\n\t\t\t\tif (@mkdir($save_dir)) // try to create the directory\n\t\t\t\t\t$this->save_dir = $save_dir;\n\t\t\t\telse exit('Error: The directory where to store the generated captchas could not be found nor created. Please create it manually!');\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "2f5d44eff0c5778a2e6facc0260faf6c", "score": "0.5181879", "text": "public function storagePath()\n {\n return $this->basePath.DIRECTORY_SEPARATOR.'var';\n }", "title": "" }, { "docid": "498df94a97c8c432b576ba51d8baa674", "score": "0.5171567", "text": "public function GetDirectory()\n\t{\n\t\treturn $this->save_dir;\n\t}", "title": "" }, { "docid": "a36095bdcc803297ae7f4431d4a0c423", "score": "0.5140876", "text": "public function directoryPath();", "title": "" }, { "docid": "ae8c59dcf4308991878c5e3c219909dc", "score": "0.5123746", "text": "public function getFileBaseDir(){\r\n return Mage::getBaseDir('media').DS.'brand'.DS.'file';\r\n }", "title": "" }, { "docid": "4041bea18ff542ad66d815f9f84b312e", "score": "0.5120594", "text": "public function __construct()\n {\n parent::__construct();\n $this->dir = 'database/seeds/sql/dumps/';\n }", "title": "" }, { "docid": "1fa646730477819163985fc1aca2bf1a", "score": "0.51197517", "text": "public function setDir($dir)\n {\n $this->dir = $dir;\n }", "title": "" }, { "docid": "daf084168dddaee928bc8e86a7166e9a", "score": "0.5118611", "text": "public function getCacheDirectory();", "title": "" }, { "docid": "daf084168dddaee928bc8e86a7166e9a", "score": "0.5118611", "text": "public function getCacheDirectory();", "title": "" }, { "docid": "73597e49f6a68cf7c7293ad5067261a9", "score": "0.51184434", "text": "protected function getConfigDir()\n {\n return dirname($this->getSettings()->getLocation());\n }", "title": "" }, { "docid": "d4a639bd8a2ffdd18b1aebf79bfd2d1e", "score": "0.51043075", "text": "protected function getUploadDir() {\n // when displaying uploaded doc/image in the view.\n return 'uploads/banners';\n }", "title": "" }, { "docid": "c3b7d7310b53c3e27c3c8a91fb6bd1d8", "score": "0.5101524", "text": "protected function getUploadDir()\n {\n return 'upload';\n }", "title": "" }, { "docid": "25bf741aadcfa188e53476b3c2439aeb", "score": "0.5099894", "text": "private function getDefaultDirectory(): string\n {\n $ds = DIRECTORY_SEPARATOR;\n\n return sprintf(\"%s{$ds}..{$ds}..{$ds}..{$ds}Databases{$ds}Migrations\", __DIR__);\n }", "title": "" }, { "docid": "29a3757a4e6748ffe8053aabc5addd85", "score": "0.50986934", "text": "public function dataPath()\n {\n return Configuration::dataDir();\n }", "title": "" }, { "docid": "11f740568b9d82f0fa48338eb2613fb2", "score": "0.5097912", "text": "public function createBackupFolders()\n {\n $backupDir = $this->c14mountDir . '/' . static::BACKUP_DIR;\n $this->mkdirOrDie($backupDir);\n $backupTempDir = $this->c14mountDir . '/' . $this->backupTempDir;\n $this->mkdirOrDie($backupTempDir);\n }", "title": "" }, { "docid": "55fb0be5a62608731c78a7f01ff814f7", "score": "0.50887233", "text": "protected function destinationUploadDir()\n {\n return public_path(env('UPLOAD_DIR_USER', 'media/images/users'));\n }", "title": "" }, { "docid": "3f11f11d03eca7c7fda49483137d4238", "score": "0.5087146", "text": "protected function getUploadRootDir()\r\r\n\t{\r\r\n\t\t// guardar los archivos cargados\r\r\n\t\treturn 'uploads/usuario/'.$this->id.'/';\r\r\n\t}", "title": "" }, { "docid": "e9804c87f67ff44511c5ebaa5155a6aa", "score": "0.5087107", "text": "protected function getUploadRootDir() {\n // documents should be saved\n return __DIR__ . '/../../../../web/uploads/banners/';\n }", "title": "" }, { "docid": "5a995d3bf53115f5f5ccf32972e2c86a", "score": "0.5081944", "text": "public function getStorageDir() {\n\t\treturn JPATH_ROOT . DS . str_replace(\".\", DS, JComponentHelper::getParams('com_jspace')->get('storage_directory')) . DS . 'packages' . DS . $this->id . DS ;\n\t}", "title": "" }, { "docid": "e0a0028504fddd1637584dc7caef084e", "score": "0.5062802", "text": "function getStorageDirPath($instance);", "title": "" }, { "docid": "a7462919ec60c78585848170de41943a", "score": "0.50441754", "text": "public function storagePath()\n {\n return BASE_PATH.DIRECTORY_SEPARATOR.'storage';\n }", "title": "" }, { "docid": "d7bb96828dc1023ae9168651be913d55", "score": "0.50386715", "text": "public function getCacheDir() {\n return $this->rootDir . '/cache/' . $this->customerFolderName . '/' . $this->environment;\n }", "title": "" }, { "docid": "0fc9df5f213717a3c1db21d7d67de5c4", "score": "0.5031788", "text": "function books_dir()\n{\n\treturn get_config_param('BOOKS_DIR');\n}", "title": "" }, { "docid": "b339f2dd1ee9fc13e752b630c3fff81b", "score": "0.5019466", "text": "public function setNfnExportDirectory()\n {\n $this->nfnExportDirectory = config('config.nfn_export_dir');\n }", "title": "" }, { "docid": "f242f1b36aea288b52ee660c20b66526", "score": "0.50152177", "text": "public function temporaryDirectoryPath(): string\n {\n return $this->getConfig('temporary-directory', storage_path('app/_backup-temp'));\n }", "title": "" }, { "docid": "5d609670e1a6c360629efecb368e15db", "score": "0.4998499", "text": "protected function cacheDirectory() {\n $directory = 'public://simplepie';\n file_prepare_directory($dir, FILE_CREATE_DIRECTORY | FILE_MODIFY_PERMISSIONS);\n return $directory;\n }", "title": "" }, { "docid": "d42f8c533a9e2231b7e4ed406cd4566b", "score": "0.4996099", "text": "public function storageDir(string $path = ''): string {\n return $this->rootDir('storage') . ($path ? \"/{$path}\" : '');\n }", "title": "" }, { "docid": "c1f2ea3859e5f845081fb5a1470cf0b9", "score": "0.4993348", "text": "public function setBackup($value);", "title": "" }, { "docid": "8b65dc2b1d112bd2c91fa0415537386e", "score": "0.49924183", "text": "protected function getUploadDir()\n {\n return 'uploads';\n }", "title": "" }, { "docid": "e13a905ae8b260352e9090c35bb49697", "score": "0.49850035", "text": "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/blogs';\n }", "title": "" }, { "docid": "0aaceafb908ebba8d301cf873f3308b5", "score": "0.49697056", "text": "public function getLogDir() {\n return $this->rootDir . '/logs/' . $this->customerFolderName;\n }", "title": "" }, { "docid": "8137a73f7a7de997e28ccb225e489858", "score": "0.4964248", "text": "public function setArchiveTarGz()\n {\n $this->archiveTarGz = $this->folderName . '.tar.gz';\n $this->archiveTarGzPath = $this->scratchDirectory . '/' . $this->archiveTarGz;\n }", "title": "" }, { "docid": "f6e70ac3b9ba88091462e2f1b6c48528", "score": "0.4963431", "text": "protected function getUploadRootDir()\r\r\n {\r\r\n \t// guardar los archivos cargados\r\r\n \treturn 'uploads/event/'.$this->id.'/';\r\r\n }", "title": "" }, { "docid": "d493b01562fcbf77e50ffe4b28d78067", "score": "0.49626175", "text": "private function makeBackup ()\n {\n $this->createDirectory($this->backupDirectory);\n $this->createDirectory($this->backupDirectory . '/config');\n\n File::copyDirectory('app', $this->backupDirectory . '/app');\n File::copyDirectory('bootstrap', $this->backupDirectory . '/bootstrap');\n File::copyDirectory('routes', $this->backupDirectory . '/routes');\n\n File::copy('composer.json', $this->backupDirectory . '/composer.json');\n File::copy('config/auth.php', $this->backupDirectory . '/config/auth.php');\n File::copy('config/database.php', $this->backupDirectory . '/config/database.php');\n }", "title": "" }, { "docid": "23583499c0f2d89baee13aef9fcc5811", "score": "0.4952723", "text": "public function getDefaultDirectory()\n {\n return $this->directory;\n }", "title": "" }, { "docid": "10884a3205dffa09890262ee93c94a05", "score": "0.49508134", "text": "public function get_saved_dir(){\n\t\treturn $this->v_saved_dir;\n\t}", "title": "" }, { "docid": "be9a6f7a6a8f072122f6bf5b7a145267", "score": "0.49497953", "text": "protected function getFixturesDirectory()\n {\n return __DIR__ . DIRECTORY_SEPARATOR . 'fixtures';\n }", "title": "" }, { "docid": "e7ea9acb8da9f7e85af343b8432aef31", "score": "0.49490607", "text": "protected function getUploadRootDir() {\r\r return $this->getTmpUploadRootDir().$this->getId().\"/\";\r\r }", "title": "" }, { "docid": "eb324d0b678cc6ff09b61f7c764457ad", "score": "0.49450794", "text": "protected function getUploadRootDir()\n {\n \t// guardar los archivos cargados\n \treturn 'uploads/producto/';\n }", "title": "" }, { "docid": "af690d2efcec063a9484df9c50e6b6c7", "score": "0.49449193", "text": "public function getBaseDir()\r\n\t{\r\n\t\treturn Mage::getBaseDir('media') . DS . self::MEDIA_PATH;\r\n\t}", "title": "" }, { "docid": "ecc21a0bc504ff5415ac0addcbd2f14b", "score": "0.49344394", "text": "protected function getUploadDir() {\n // when displaying uploaded doc/image in the view.\n return 'uploads/venues/albums';\n }", "title": "" }, { "docid": "985ea61c107c68ef73bcc8525662e109", "score": "0.49341434", "text": "public function setFileDestination($dest)\n {\n $this->_fileDestinationDir = $dest;\n }", "title": "" }, { "docid": "6d9dfa065225c012151069dde7134a2f", "score": "0.4931348", "text": "protected function getCacheDirectory()\n {\n return $this->_cache_path;\n }", "title": "" }, { "docid": "06af24495849f935f53b0455a2c905d6", "score": "0.49173194", "text": "public function getCacheDir()\n {\n $dir = $this->_data['cache_dir'];\n $this->createDirIfNotExists($dir);\n return $dir;\n }", "title": "" }, { "docid": "06af24495849f935f53b0455a2c905d6", "score": "0.49173194", "text": "public function getCacheDir()\n {\n $dir = $this->_data['cache_dir'];\n $this->createDirIfNotExists($dir);\n return $dir;\n }", "title": "" }, { "docid": "06af24495849f935f53b0455a2c905d6", "score": "0.49173194", "text": "public function getCacheDir()\n {\n $dir = $this->_data['cache_dir'];\n $this->createDirIfNotExists($dir);\n return $dir;\n }", "title": "" }, { "docid": "bcc20ac9ee1086a48574bcbd46c72c9e", "score": "0.49166685", "text": "public function getDownloadDirectory();", "title": "" }, { "docid": "5217706279a67f0fac071f4b39732ea3", "score": "0.49153358", "text": "public function getCacheDirectory() {\n\t\treturn $this->cacheDir;\n\t}", "title": "" }, { "docid": "e016ee852be9a201ed16f1c092941967", "score": "0.49139318", "text": "public function getCacheDir();", "title": "" }, { "docid": "e016ee852be9a201ed16f1c092941967", "score": "0.49139318", "text": "public function getCacheDir();", "title": "" }, { "docid": "cec3ca860998350c687b3ddae79d666b", "score": "0.49094483", "text": "public function baseDirectory()\n\t{\n\t\treturn $this->request['PWD'];\n\t}", "title": "" }, { "docid": "e6553e9559d5a3ab17d6834dd7aca5b1", "score": "0.49014077", "text": "public function getSourceBaseDir()\n {\n $basePath = Mage::getBaseDir();\n $configOption = Mage::getStoreConfig('dev/amdjs/sources');\n return $basePath . DS . $configOption;\n }", "title": "" }, { "docid": "0872c46c1677c230297732fba9a25e5d", "score": "0.48942056", "text": "protected function getBannerUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return $this->getUploadRootDir().\"banners/\";\n }", "title": "" }, { "docid": "2b7451230d6330bad327e286df1c91ae", "score": "0.48938504", "text": "public static function getBaseDir($type='base')\n {\n return Mage::getConfig()->getOptions()->getDir($type);\n }", "title": "" }, { "docid": "838657b796f6cceed3b7e36832a7cb62", "score": "0.4893591", "text": "public function getCacheDirectory()\n {\n return $this->cacheDirectory;\n }", "title": "" }, { "docid": "3d0e2a50f4be09cf3591f4931bf29766", "score": "0.4892227", "text": "protected function destinationUploadDir()\n {\n return public_path(env('UPLOAD_DIR_PRODUCT', 'media/images/products'));\n }", "title": "" }, { "docid": "c832732f11b1cf6493cf86d6e0aec9cb", "score": "0.48859704", "text": "public function getFileBaseDir()\n {\n return Mage::getBaseDir('media').DS.'cod'.DS.'file';\n }", "title": "" }, { "docid": "e0336fbe7a5da9ab39f3c3a543b468ba", "score": "0.48840898", "text": "public function initPath()\n {\n $this->upgradeContainer->getWorkspace()->createFolders();\n\n // set autoupgradePath, to be used in backupFiles and backupDb config values\n $this->autoupgradePath = $this->adminDir . DIRECTORY_SEPARATOR . $this->autoupgradeDir;\n $this->backupPath = $this->autoupgradePath . DIRECTORY_SEPARATOR . 'backup';\n $this->downloadPath = $this->autoupgradePath . DIRECTORY_SEPARATOR . 'download';\n $this->latestPath = $this->autoupgradePath . DIRECTORY_SEPARATOR . 'latest';\n $this->tmpPath = $this->autoupgradePath . DIRECTORY_SEPARATOR . 'tmp';\n $this->latestRootDir = $this->latestPath . DIRECTORY_SEPARATOR;\n\n if (!file_exists($this->backupPath . DIRECTORY_SEPARATOR . 'index.php')) {\n if (!copy(_PS_ROOT_DIR_ . DIRECTORY_SEPARATOR . 'config' . DIRECTORY_SEPARATOR . 'index.php', $this->backupPath . DIRECTORY_SEPARATOR . 'index.php')) {\n $this->_errors[] = $this->trans('Unable to create file %s', [$this->backupPath . DIRECTORY_SEPARATOR . 'index.php'], 'Modules.Autoupgrade.Admin');\n }\n }\n\n $tmp = \"order deny,allow\\ndeny from all\";\n if (!file_exists($this->backupPath . DIRECTORY_SEPARATOR . '.htaccess')) {\n if (!file_put_contents($this->backupPath . DIRECTORY_SEPARATOR . '.htaccess', $tmp)) {\n $this->_errors[] = $this->trans('Unable to create file %s', [$this->backupPath . DIRECTORY_SEPARATOR . '.htaccess'], 'Modules.Autoupgrade.Admin');\n }\n }\n }", "title": "" }, { "docid": "5025c5a473acb86535fc6d1c901d1499", "score": "0.48825634", "text": "public function getCacheDir()\n {\n // and warmup time.\n if ($this->getEnvironment() === 'dev' || $this->getEnvironment() === 'test') {\n return sprintf('/tmp/engineblock/cache/%s', $this->getEnvironment());\n }\n\n return $this->rootDir . '/cache/' . $this->environment;\n }", "title": "" }, { "docid": "31b45de65822c0a164c4e1ffd510ce2e", "score": "0.48772433", "text": "function setDirectory($target_directory) {\n $this->_target_directory = $target_directory;\n }", "title": "" }, { "docid": "45475e6617f482fba91fd872ada65b46", "score": "0.48755324", "text": "public function setCacheDir($cacheDir) {\n\t\tif(is_dir($cacheDir) && is_writeable($cacheDir)) {\n\t\t\t$this->_cacheDir = $cacheDir;\n\t\t}\n\t}", "title": "" }, { "docid": "2510828f1bc0b9361d9223d2ccdb5e5d", "score": "0.4872383", "text": "protected function getUploadRootDir() {\n return $this->getTmpUploadRootDir().$this->getId().\"/\";\n }", "title": "" }, { "docid": "03fc9198f4c4576fbc12497e6b776b46", "score": "0.48609892", "text": "public function setDir(PhingFile $d)\n {\n $this->dir = $d;\n }", "title": "" }, { "docid": "311fa0673f2368d1286ecb0bfb741c8d", "score": "0.4859624", "text": "public function getCacheDir()\n {\n return __DIR__ . '/../var/cache/' . $this->getEnvironment();\n }", "title": "" }, { "docid": "a68cb10a0185ecfc948054caddc40aea", "score": "0.4857702", "text": "public function getUploadDir()\n {\n return 'web/photos';\n }", "title": "" }, { "docid": "d22f333fb25a62c512e13338dce6d550", "score": "0.4854769", "text": "protected function _directory() {\n\t\tif (!isset($this->Folder)) {\n\t\t\t$this->Folder = new Folder();\n\t\t}\n\t\t\n\t\tif (mb_substr($this->uploadDir, 0, 1) == '/') {\n\t\t\t$this->uploadDir = mb_substr($this->uploadDir, 1);\n\t\t}\n\t\t\n\t\tif (mb_substr($this->uploadDir, -1) != '/' && $this->uploadDir != '') {\n\t\t\t$this->uploadDir .'/';\n\t\t}\n\t\t\n\t\t$fullUploadDir = WWW_ROOT . $this->uploadDir;\n\t\t\n\t\tif (!is_dir($fullUploadDir)) {\n\t\t\t$this->Folder->create($fullUploadDir, 0777);\n\t\t\t\n\t\t} else if (!is_writable($fullUploadDir)) {\n\t\t\t$this->Folder->chmod($fullUploadDir, 0777, false); \n\t\t}\n\t\t\n\t\t$this->finalDir = $fullUploadDir;\n\t}", "title": "" }, { "docid": "c419037281d5ccedf7026b05873e0642", "score": "0.4853173", "text": "public function migrations_directory( $key = '' ) {\n\t\t$migration_dir = '';\n\t\tif ( $key ) {\n\t\t\tif ( ! isset( $this->_config['migrations_dir'][ $key ] ) ) {\n\t\t\t\tthrow new Ruckusing_Exception( \\sprintf( 'No module %s migration_dir set in config', $key ), Ruckusing_Exception::INVALID_CONFIG );\n\t\t\t}\n\t\t\t$migration_dir = $this->_config['migrations_dir'][ $key ] . \\DIRECTORY_SEPARATOR;\n\t\t}\n\t\telseif ( \\is_array( $this->_config['migrations_dir'] ) ) {\n\t\t\t$migration_dir = $this->_config['migrations_dir']['default'] . \\DIRECTORY_SEPARATOR;\n\t\t}\n\t\telse {\n\t\t\t$migration_dir = $this->_config['migrations_dir'] . \\DIRECTORY_SEPARATOR;\n\t\t}\n\t\tif ( \\array_key_exists( 'directory', $this->_config['db'][ $this->_env ] ) ) {\n\t\t\treturn $migration_dir . $this->_config['db'][ $this->_env ]['directory'];\n\t\t}\n\t\treturn $migration_dir . $this->_config['db'][ $this->_env ]['database'];\n\t}", "title": "" }, { "docid": "33ce3cf3063875bd8a1e39133e5280e6", "score": "0.4848735", "text": "private function getUploadDir() {\r\n \treturn $this->getRequest()->getBaseUrl().($this->get('kernel')\r\n \t\t\t->getEnvironment()=='prod' ? '' : '/..').\"/upload/reporting/\";\r\n }", "title": "" }, { "docid": "32e3122169187d590513fda6e0243fc1", "score": "0.48473257", "text": "protected function setTemplateDir()\n\t{\n\t\t$this->templateDir = __DIR__ . DS . 'Templates';\n\t}", "title": "" }, { "docid": "398c6e55d17bdbb2cc38e2f6593a905d", "score": "0.48467577", "text": "public function storageDir(): string;", "title": "" }, { "docid": "685b9b5c13f30d428691a589e15ec66d", "score": "0.48440644", "text": "public function setArchiveExportPath()\n {\n $this->archiveExportPath = $this->nfnExportDirectory . '/' . $this->archiveTarGz;\n }", "title": "" }, { "docid": "d6d8ee2f5da2eab23843d21cbe722af1", "score": "0.48435226", "text": "public function setDir(string $workDirName): void\n {\n $this->workDirName = $workDirName;\n }", "title": "" }, { "docid": "ad0069b96bf07b4a4c43c8b7b7667ab0", "score": "0.4838593", "text": "protected function getUploadRootDir() {\n return __DIR__ . '/../../../../public_html/upload/store/images/' . $this->getId() . '/';\n }", "title": "" }, { "docid": "2d4f9622c809ae014326240de296b295", "score": "0.4834408", "text": "protected function getUploadDir() {\n return 'uploads/pictures';\n }", "title": "" }, { "docid": "7ba4c5e120c0178a8fe0fb020a49a6b4", "score": "0.48282424", "text": "public function getBackupDirectory ($cliArgument)\n {\n if (!empty($cliArgument))\n {\n return $cliArgument;\n }\n\n return $this->backupPath;\n }", "title": "" }, { "docid": "2dd356b012fbb4b70df2ea6be2f657ea", "score": "0.48243505", "text": "public function setWorkingDirectory($dir){\r\n\t\t$this->workingdir = t3lib_div::getFileAbsFileName($dir);\r\n\t}", "title": "" } ]
13723369ee210991fbaeff150e6325a0
Display the specified resource.
[ { "docid": "4bac3188558c3acab53dd8d5175c1d4e", "score": "0.0", "text": "public function show($id)\n {\n //\n }", "title": "" } ]
[ { "docid": "d7820004a578ddc16d57dff08d715ef0", "score": "0.70187664", "text": "public function showResource()\n\t{\n\t\treturn view('resources.list')->with('resources', Resources::all());\n\t}", "title": "" }, { "docid": "069b1d099b7ea4aa5397d961e2ee62da", "score": "0.6752789", "text": "public function show()\n {\n //find resource to display\n // $res = Resource::all();\n return view('resources/show');\n }", "title": "" }, { "docid": "426f9c78118dbbe009edc89fcf8571df", "score": "0.6748524", "text": "public function show(Resource $resource)\n {\n //\n\t\t\t\treturn response()->json($resource);\n }", "title": "" }, { "docid": "e383b8f1e186862fb82733fa719d3590", "score": "0.66141546", "text": "public function show(ResourceRetriever $listener, $resourceId);", "title": "" }, { "docid": "d9105f21226c250782ad227b6b2261e2", "score": "0.65124357", "text": "public function actionView()\n\t{ \n $id=isset($_GET['id']) ? (int) ($_GET['id']) : 0 ;\n $this->menu=array_merge($this->menu, \n array(\n array('label'=>t('cms','Update this Resource'), 'url'=>array('update','id'=>$id),'linkOptions'=>array('class'=>'button')),\n array('label'=>t('cms','View this Resource'), 'url'=>array('view','id'=>$id),'linkOptions'=>array('class'=>'button'))\n )\n );\n\t\t$this->render('resource_view');\n\t}", "title": "" }, { "docid": "7ac5c8e634cbf2fdc36370cd8ef57eee", "score": "0.6199778", "text": "function display($resource_name, $cache_id = null, $compile_id = null)\n\t{\n\t\techo \"<strong>Armored Core</strong>: ac_block:: display(): function <strong><u>ac_block::display()</u></strong> is disabled, please fetch html resource string by <strong><u>ac_block::fetch_block()</u></strong>.\";\n\t}", "title": "" }, { "docid": "33cfc48a18162e20c7127b1127d7db87", "score": "0.61841017", "text": "public function showAction()\n {\n $context = YuppContext::getInstance();\n \n $id = $this->params['id'];\n $clazz = String::firstToUpper( $context->getController() );\n\n // La clase debe estar cargada...\n eval ('$obj' . \" = $clazz::get( $id );\");\n\n $this->params['object'] = $obj;\n\n return $this->render(\"show\");\n }", "title": "" }, { "docid": "b4c5ad057e8d450658fdc27a7ae8a914", "score": "0.6173968", "text": "public function show($id)\n {\n $resource = Resource::find($id);\n\n return view('admin.resource.show', [\n 'resource' => $resource\n ]);\n }", "title": "" }, { "docid": "66ee2c88bf8fc141934fcb5cd1ba4add", "score": "0.61682713", "text": "public function output($resource) {\n\t\tprint $resource;\n\t\tif (isset(self::$_resources[$resource])) {\n\t\t\t$res =& self::$_resources[$resource];\n\n\t\t\tif ( $data = $this->getInternalResource($res['data']) ) {\n\t\t\t\t$filename = self::$embedding_file;\n\t\t\t} else {\n\t\t\t\t$filename = $res['data'];\n\t\t\t}\n\n\t\t\t// use last-modified time as etag; etag must be quoted\n\t\t\t$etag = '\"' . filemtime($filename) . '\"';\n\n\t\t\t// check headers for matching etag; if etag hasn't changed, use the cached version\n\t\t\tif (isset($_SERVER['HTTP_IF_NONE_MATCH']) && $_SERVER['HTTP_IF_NONE_MATCH'] == $etag) {\n\t\t\t\theader('HTTP/1.0 304 Not Modified');\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\theader('Etag: ' . $etag);\n\n\t\t\t// cache file for at most 30 days\n\t\t\theader('Cache-control: max-age=2592000');\n\n\t\t\t// output resource\n\t\t\theader('Content-type: ' . $res['mime']);\n\n\t\t\tif (isset($data)) {\n\t\t\t\tif (isset($res['base64'])) {\n\t\t\t\t\techo base64_decode($data);\n\t\t\t\t} else {\n\t\t\t\t\techo $data;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\treadfile($filename);\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "919d00fe86f81c1cf289acf24342adc1", "score": "0.61225873", "text": "public function show($id)\n {\n $resource = $this->service->find($id);\n if(empty($resource))\n {\n Flash::error('Resource não encontrado');\n return redirect(route('resources.index'));\n }\n return view('resources.show')->with('resource', $resource);\n }", "title": "" }, { "docid": "80a8e3a2ce7bc2d1abdfaec188d6155d", "score": "0.6094779", "text": "public function index(Resource $resource)\n {\n session(['resourceId' => $resource->id]);\n\n $contents = $this->getContents();\n\n $noSideBar = true;\n\n // Show the page\n return view('admin.content.index', compact('resource', 'contents', 'noSideBar'));\n }", "title": "" }, { "docid": "d1a990ee04cb4a4e2b071c7b3a0f4626", "score": "0.6077535", "text": "public function editResource($resource) {\n\n $resource = SiteImage::findOrFail($resource);\n\n return View('backoffice.pages.edit_resource', ['resource' => $resource]);\n }", "title": "" }, { "docid": "56e1414df8116772a62d14147c538ffe", "score": "0.6018325", "text": "public function displayAction()\n {\n $dummyEntity = $this->createSampleEntity();\n\n return $this->render('AppBundle:Display:display.html.twig', [\n 'entity' => $dummyEntity\n ]);\n }", "title": "" }, { "docid": "1e891653b5f4912aa409c758d50a1b98", "score": "0.5965172", "text": "function display()\n\t{\n\t\t$view = &$this->getView();\n\t\t$view->display();\n\t}", "title": "" }, { "docid": "6e55abfe4978a80ccc782aaf6093b19f", "score": "0.59554774", "text": "public function show($id)\n {\n // return new InformationResource(Information::FindOrFail($id));\n }", "title": "" }, { "docid": "469e3d6c9afd54041becbee857df8ef8", "score": "0.5954321", "text": "public function edit(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "7b8f897ba2297696b69f6d8202444107", "score": "0.59492433", "text": "public function displayAction()\n {\n $params = $this->dispatcher->getParams();\n if (isset($params[0]) && $firewall = Firewalls::findFirst(intval($params[0]) ? $params[0] : ['name=:name:', 'bind' => ['name' => $params[0]]])) {\n echo Las::display($firewall->name);\n }\n }", "title": "" }, { "docid": "89b549ed67b4702bbd94de618931239c", "score": "0.594717", "text": "public function show()\n {\n echo $this->render();\n }", "title": "" }, { "docid": "bb2e29f5f05ab065358c99c7225d6dc0", "score": "0.59295714", "text": "public function show(rc $rc)\n {\n //\n }", "title": "" }, { "docid": "69c007742a206b83dabf0105e287694e", "score": "0.5917445", "text": "public function show(CardType $resource)\n {\n $student = Student::find(request()->student_id);\n return view(\"card::card.\" . $resource->id, compact(\"student\"));\n }", "title": "" }, { "docid": "10dda82513aea0f93ead687a2ff8c827", "score": "0.5917097", "text": "public function show() {\n if (!$this->resource) return false;\n header(\"Content-Type: \" . $this->mime);\n switch ($this->ext) {\n case \"jpeg\":\n imagejpeg($this->resource);\n break;\n case \"png\":\n imagesavealpha($this->resource, true);\n imagepng($this->resource);\n break;\n }\n }", "title": "" }, { "docid": "d3213bec1042b484f9e7c8a52c4ef16a", "score": "0.5908313", "text": "public function edit(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "5fbd8c8a913f3d5a4f08b109b5762881", "score": "0.59036547", "text": "public function show()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cfa14f41ec1e2a6c61ae783842b28ca6", "score": "0.5901304", "text": "public function display() {\n $this->doDisplay();\n }", "title": "" }, { "docid": "f67dcafa85455ea74fc8196d8e104a85", "score": "0.5866919", "text": "public function show() //$id\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "478daa75047310b25e75447625fd98fb", "score": "0.58533454", "text": "public function show($id)\n {\n $resource = Resource::find($id);\n $categories = Category::all();\n\n if ($resource) {\n return view('pages.resource_show', compact('categories', 'resource'));\n }\n\n return abort(404);\n }", "title": "" }, { "docid": "e35556f0647fa2dc1cbf13447dae6b50", "score": "0.5820258", "text": "public function show($imageResource) {\n\t\theader('Content-type: image/jpeg');\n\t\theader('Content-disposition: inline');\n\t\timagejpeg($imageResource, null, 88);\n\t}", "title": "" }, { "docid": "004f965420f85c3776edacf6c258a0a6", "score": "0.58097786", "text": "public function display()\r\n {\r\n $this->render();\r\n }", "title": "" }, { "docid": "7960ba0bf337c86c8be237145807953e", "score": "0.5806929", "text": "public function displayAction()\n {\n if (!isset($this->params['nname']))\n {\n $this->flash['message'] = 'No se encuentra la pagina solicitada';\n $page = Page::get(1);\n }\n else\n {\n $pages = Page::findBy( Condition::EQ(Page::TABLE, 'normalizedName', $this->params['nname']), $this->params );\n \n if (count($pages) == 1) $page = $pages[0];\n else\n {\n $this->flash['message'] = 'No se encuentra la pagina solicitada';\n $page = Page::get(1);\n }\n }\n\n $this->params['page'] = $page;\n //return $this->render('../cms/displayPageRO');// no funciona en linux\n return $this->render('../cms/displayPageRO');// no funciona en linux\n }", "title": "" }, { "docid": "426c72f34858b1f8fc0c2377d1350691", "score": "0.58062166", "text": "public function show()\n {\n $arguments = func_get_args()[0];\n $id = $arguments[0];\n\n echo \"Show $id\";\n // return $this->view('example.show');\n }", "title": "" }, { "docid": "305f64db85d64f68019d2fadcd0a85d2", "score": "0.58012545", "text": "public function show()\n\t{\n\t\t\n\t}", "title": "" }, { "docid": "32187e8550924a28a85e5c258d9de919", "score": "0.5793539", "text": "public function display() {\n echo $this->fetch();\n }", "title": "" }, { "docid": "2a2a886f07a7eb66210fab7478b1c2f7", "score": "0.5767577", "text": "public function display()\n {\n\n echo $this->get_display();\n\n }", "title": "" }, { "docid": "0738931a1683e5ef17e57fcbeee2ab9f", "score": "0.5763775", "text": "public function show(Standard $standard)\n {\n //\n }", "title": "" }, { "docid": "0738931a1683e5ef17e57fcbeee2ab9f", "score": "0.5763775", "text": "public function show(Standard $standard)\n {\n //\n }", "title": "" }, { "docid": "e3b51ebfe04703c114ab39fc729ba43b", "score": "0.5749091", "text": "public function show(Entry $entry)\n {\n //\n }", "title": "" }, { "docid": "93802b97c6f44ae5e366b70deec744b9", "score": "0.5746085", "text": "public function show()\n {\n $results = $this->run('show');\n }", "title": "" }, { "docid": "8f15cdd2f287675d36c7b7df028043ec", "score": "0.5736634", "text": "public function show($id)\n\t{\n\t//\n\t}", "title": "" }, { "docid": "be63c4d6543bd1b7322d86668ae9ef60", "score": "0.5734784", "text": "public function show($id)\n {\n $resource = Str::singular(resourceName());\n $viewPath = collect(explode('/', request()->path()))->slice(0, -2)->implode('.') . '.'.$resource;\n return view($this->viewPrefix . $viewPath, [\"object\" => $this->getObjectFromRoute($id, $this->showWith), \"model\" => ucfirst($resource) ]);\n }", "title": "" }, { "docid": "6cf90dd8b5fe3cf8ddaee25472340d27", "score": "0.5733295", "text": "public function show(Responsable $responsable)\n {\n //\n }", "title": "" }, { "docid": "6cf90dd8b5fe3cf8ddaee25472340d27", "score": "0.5733295", "text": "public function show(Responsable $responsable)\n {\n //\n }", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "7d55c8c31eda9d3eeb688b4417d1ce54", "score": "0.5722562", "text": "public function show($id) {\n\t\t//\n\t}", "title": "" }, { "docid": "47171b843665ac85f7c5da2618a7ae0e", "score": "0.5718969", "text": "public function show($id) {}", "title": "" }, { "docid": "47171b843665ac85f7c5da2618a7ae0e", "score": "0.5718969", "text": "public function show($id) {}", "title": "" }, { "docid": "6c6591ff03468044c76e66dc3ecca033", "score": "0.57143193", "text": "public function display(): Response;", "title": "" }, { "docid": "1926665de574ded82e5d782a6ff9192f", "score": "0.57088506", "text": "public function show(Field $field){\n \treturn new FieldResource($field);\n }", "title": "" }, { "docid": "05ca915e5f597f0a1925a6b1a1e6afb0", "score": "0.57057405", "text": "public abstract function display();", "title": "" }, { "docid": "28c1222465a2cbce21a616ec72fbd790", "score": "0.57036674", "text": "public static function resource($resource, $controller, $options = array()){\n\t\t Illuminate\\Routing\\Router::resource($resource, $controller, $options);\n\t }", "title": "" }, { "docid": "12bf7179b06b190879842d1f1945365c", "score": "0.57026845", "text": "public function show( $id ) {\n\t\t//\n\t}", "title": "" }, { "docid": "560ae0fd472bad5f1d21beeed5dfbbdd", "score": "0.57012135", "text": "public function show(){}", "title": "" }, { "docid": "1708ac3bf00aa20f618f27d019302e26", "score": "0.5698314", "text": "public function show() \n {\n echo $this->get();\n }", "title": "" }, { "docid": "f434227a79e3f2ef6339c28c9de58720", "score": "0.56981796", "text": "public function show($id)\n {\n return \"display your post here\";\n }", "title": "" }, { "docid": "e9865313c984d3a82e52245c0631382c", "score": "0.56956863", "text": "public static function showResource($module ='', $model_name ='', $resource_id = 0, $resource_field = '', $relationship = [])\n\t{\n\t\t$source = \"\\App\\Modules\\\\\".$module.\"\\Models\\\\\".$model_name;\n\t\t$model = $source::find($resource_id);\n\t\tif (count($relationship)) {\n\t\t\t// $model = $source::with($relationship)->where($resource_field, '=', $resource_id)->first();\n\t\t\t$model = $source::with($relationship)->find($resource_id);\n\t\t}\n\t\tif ($model) {\n\t\t\t$response = [\n\t\t\t\t'code'\t\t=> '200',\n\t\t\t\t'status'\t=> StatusHelper::getSuccessResponseStatus(),\n\t\t\t\t'data'\t\t=> $model->toArray()\n\t\t\t];\n\t\t}\n\t\telse {\n\t\t\t$response = [\n\t\t\t\t'code'\t\t=> '404',\n\t\t\t\t'status'\t=> StatusHelper::getNotFoundResponseStatus(),\n\t\t\t\t'message'\t=> 'Resource not found.'\n\t\t\t];\n\t\t}\n\t\treturn $response;\n\t}", "title": "" }, { "docid": "9032057600ac1cb05d858c6264b8aed1", "score": "0.5693083", "text": "public function show()\n {\n return auth()->user()->getResource();\n }", "title": "" }, { "docid": "9032057600ac1cb05d858c6264b8aed1", "score": "0.5693083", "text": "public function show()\n {\n return auth()->user()->getResource();\n }", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "cb37955e47b2d1c708a039b4bfa190e0", "score": "0.5684962", "text": "public function show($id)\n\t{\n\t\t//\n\t}", "title": "" } ]
7b7f9ffceb68ec92c4d90b23b88322d0
end prepareUrl() Return curl information.
[ { "docid": "04f1980a5b9463f427c13b95d2cf6205", "score": "0.0", "text": "public static function v(string $type = 'version') : string|null\n {\n $info = curl_version();\n \n return array_key_exists($type, $info) ? $info[$type] : null;\n \n }", "title": "" } ]
[ { "docid": "15b05954188a546bd731b292cbe74c0e", "score": "0.7168305", "text": "protected function get_curl_info()\n {\n }", "title": "" }, { "docid": "216b412280efff21e51813e61894ec14", "score": "0.6863171", "text": "public function prepareUrl() {}", "title": "" }, { "docid": "d8d5c39e3a43742e8aa72db3e34face0", "score": "0.6373392", "text": "public function infoFromURL(&$url)\n {\n\n $curl = new Curl($url);\n $curl->options->SSL_VERIFYPEER = false;\n $curl->options->FOLLOWLOCATION = true;\n $curl->options->NOBODY = true;\n $curl->options->HEADER = true;\n $curl->options->FILETIME = true;\n $curl->options->CONNECTTIMEOUT = $this->connectTimeout;\n $curl->options->TIMEOUT = $this->curlTimeout;\n\n if ($this->cookiePath && $this->cookieFile) {\n $this->cookieFile = $this->cookiePath . \"{$this->cookieFile}\";\n $curl->options->COOKIEFILE = $this->cookieFile;\n $curl->options->COOKIEJAR = $this->cookieFile;\n }\n\n $headers = array(\n 'DNT: 1',\n );\n $curl->options->HTTPHEADER = $headers;\n\n $curl->execute();\n\n return $curl;\n }", "title": "" }, { "docid": "a0df2e0ae8669e3e6b2fca6410ce82f9", "score": "0.6287137", "text": "function get_curl( $url) {\n\n $request_headers = array();\n $request_headers[] = \"application/json\";\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_TIMEOUT, 60);\n curl_setopt($ch, CURLOPT_HTTPHEADER, $request_headers);\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n $output = curl_exec($ch);\n\n if (curl_errno($ch))\n {\n print \"Error: \" . curl_error($ch);\n }\n else\n {\n // Show me the result\n return $output;\n\n\n\n }\n }", "title": "" }, { "docid": "80a0f4acc0b2ee4034f00d3d742aee14", "score": "0.62289727", "text": "private function _curl_start()\n {\n $curl = curl_init();\n\n // Google URL ShortenerのAPIにリクエストを飛ばす\n curl_setopt($curl, CURLOPT_URL, 'https://www.googleapis.com/urlshortener/v1/url?key=' . $this->api_key);\n curl_setopt($curl, CURLOPT_HTTPHEADER, array('Content-type: application/json'));\n curl_setopt($curl, CURLOPT_CUSTOMREQUEST, 'POST');\n curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode(array('longUrl' => $this->before_url)));\n curl_setopt($curl, CURLOPT_HEADER, 1);\n curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($curl, CURLOPT_TIMEOUT, 15);\n curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($curl, CURLOPT_MAXREDIRS, 5);\n\n $res1 = curl_exec($curl);\n $res2 = curl_getinfo($curl);\n\n curl_close($curl) ;\n\n $json = substr($res1, $res2['header_size']);\n\n $obj = json_decode($json);\n\n return $obj;\n }", "title": "" }, { "docid": "1365d183c2730fc8456aeceb8102f811", "score": "0.61931187", "text": "public function getCurlInfo()\r\n\t{\r\n\t\treturn $this->pCurlInfo;\r\n\t}", "title": "" }, { "docid": "fa4b5521630cfb36a8667bb5d8d45181", "score": "0.61410207", "text": "function basicCurl($curlURL) {\n $url = $curlURL;\n $cURL = curl_init();\n curl_setopt($cURL, CURLOPT_URL, $url);\n curl_setopt($cURL, CURLOPT_HTTPGET, true);\n curl_setopt($cURL, CURLOPT_HTTPHEADER, array(\n 'Content-Type: application/json',\n 'Accept: application/json'\n ));\n curl_setopt($cURL, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($cURL, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($cURL, CURLOPT_USERAGENT, \"spider\");\n $result = curl_exec($cURL);\n \nif ($result === FALSE) {\n return \"cURL Error: \" . curl_error($cURL);\n} else {\n\treturn $result;\n}\n curl_close($cURL);\n \n}", "title": "" }, { "docid": "8bff81a5efe8025240db2d115d5b29cd", "score": "0.61300087", "text": "function GetURL($sURL, &$paData=null, $aPost=0){\n\n\t$oCurl = curl_init();\n\t$sHeader[0] = \"Accept: text/xml,application/xml,application/xhtml+xml,\";\n\t$sHeader[0] .= \"text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5\";\n\t$sHeader[] = \"Cache-Control: max-age=0\";\n\t$sHeader[] = \"Connection: keep-alive\";\n\t$sHeader[] = \"Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7\";\n\t// $sHeader[]=\"Cookie:_udid=w_cc0aa62c8cc348b3b8aa21a247300a2a; __qca=P0-1337783238-1489688389612; AMCVS_0FEC8C3E55DB4B027F000101%40AdobeOrg=1; AMCV_0FEC8C3E55DB4B027F000101%40AdobeOrg=1611084164%7CMCMID%7C08244970934108574413209010439311368783%7CMCAAMLH-1490293189%7C6%7CMCAAMB-1490293189%7CcIBAx_aQzFEHcPoEv0GwcQ%7CMCOPTOUT-1489695589s%7CNONE; logged_in=true; partners-platform-cookie=He1fN_0391L2CLShX89xFw.TMGnj0yBRCzrms_uXDCzy_ODXNRJ1qjy-h2b6SZxX-Z8xLJ_n9JO7Mr19mUYxC5nBohTAYu-KjJ3GM1MPFml6J3e-NOZM2PUvvib52YWrX9xZt2fguoa8G2iFFXXPQnlGnjEu3M0fZj6jKYeZmKENo4y46KSg7E1XF_XiWAi4fTWavsaJpLNYO4NlcdcefzJQ65eu4L5reBZNcZCnad-idj9hspYqbJv1C1soocTZ43Z8qNpvgocGvn-kmBckvgdw19QWne5XBcox4x6F9D5eHy6NOzzTrG-D0m1nw7ec1ibn-UQDhRrI4UunSmA2p1z6DDWaPqSoPqGPNpzhy9NVYnfpcJHeMLQlwql_JHR5dTZBANka7nzEUsi-a8VZDZmfTTMuwIXPApT9mZ-NwBM-24agJAimkhdmaJtanw4UDolftK7ztBCPEe-C4JXdXcAWmCKuP4TNDWGbMVEKHDpgbX8N_V2NxTqdT6R7xb0BzAiCpNos-CZwp9kl539-IaydCMeeqglZLMvtCIc_VSWQTwiv9lrnR4MexSD131XKtg38CtUD4Zsi6TqDn5YQ6j8dyE8CI9fKtiiMYcMPU_1ki_XUHbuqCPHjYuoFai4Lr6QetH2FOTtKI0q9y1bqMRxMgIbqlh7GwTd7KfyKWi8oYiwIOOsUwIoIZovRhovBWwpD9z169gxImvd7eFjuJrOKEC1TbI776ENTLw8RSLXfIXo3h2W325UuYHuA6_HxkFwpZbt-6w5EYVeOB4-UHx1blBri83J9LEWAoFbgdP1jeD1lIZbYe8rLoB3QbtHBgfwQ6lnOaB3a4p9vyWwtflOloWxrMxkDdcDU4_RgPkoHGc3fK-DyFfgiJt4o_Lh6riTuZBcqaKXlxLIc1Rml33Yk9jNz_amzhFbKyOofhzoqCJcFaPWj8LeWz3_w3pBPsM.1489688383741.1209600000.O-CehdcsnAcDO71U8Lp4EF8Z3DuIbiAuIdL9DEXNpOw; _gat_tealium_0=1; _ceg.s=omx6z3; _ceg.u=omx6z3; aam_uuid=08470434043248839663186524609758056016; utag_main=v_id:015ad858e056004dc2a7fe41540805071001c06900bd0$_sn:1$_ss:0$_pn:4%3Bexp-session$_st:1489690272233$ses_id:1489688387670%3Bexp-session$segment:b$optimizely_segment:b$dc_visit:1$dc_event:12%3Bexp-session$dc_region:eu-central-1%3Bexp-session$userid:79ba2a7f-9bf5-4576-a004-8b76f027709d; user=%7B%22uuid%22%3A%2279ba2a7f-9bf5-4576-a004-8b76f027709d%22%2C%22token%22%3A%225638bff3-1d39-4848-82b4-02864bab772d%22%7D; _ga=GA1.2.75499847.1489688389; _gat_UA_7157694_7=1; mp_mixpanel__c=0; mp_e39a4ba8174726fb79f6a6c77b7a5247_mixpanel=%7B%22distinct_id%22%3A%20%2215ad858e394624-034854ec281bfe-5b123112-1fa400-15ad858e395424%22%2C%22__mps%22%3A%20%7B%7D%2C%22__mpso%22%3A%20%7B%7D%2C%22__mpa%22%3A%20%7B%7D%2C%22__mpu%22%3A%20%7B%7D%2C%22__mpap%22%3A%20%5B%5D%2C%22Lead%20Page%22%3A%20%22https%3A%2F%2Flogin.uber.com%2Flogin%22%2C%22%24initial_referrer%22%3A%20%22%24direct%22%2C%22%24initial_referring_domain%22%3A%20%22%24direct%22%7D\";\n\n\n\t$sHeader[]=\"Cookie:_ua=%7B%22id%22%3A%220adfe820-0837-441e-8ec4-f3f3feb28fc2%22%2C%22ts%22%3A1493917457883%7D; __qca=P0-707996103-1490288458308; _udid=w_8fadae074e3844d38286f957e7aa97f8; AMCVS_0FEC8C3E55DB4B027F000101%40AdobeOrg=1; AMCV_0FEC8C3E55DB4B027F000101%40AdobeOrg=1611084164%7CMCMID%7C47344144760877631691352651521452402060%7CMCAAMLH-1494521363%7C6%7CMCAAMB-1494521363%7CNRX38WO0n5BH8Th-nqAG_A%7CMCOPTOUT-1493923763s%7CNONE; __lnkrntdmcvrd=uber.com; marketing_vistor_id=d883ee17-f4dc-4189-b85d-9dfb7bbfa099; optimizelyEndUserId=oeu1493024658032r0.6043721730547924; _ceg.s=opfu1x; _ceg.u=opfu1x; aam_uuid=46850037910629450221330228361444198803; sid=QA.CAESEOvN13zv50DNvmTBUS0Z2q0YioyIzAUiATEqJDc5YmEyYTdmLTliZjUtNDU3Ni1hMDA0LThiNzZmMDI3NzA5ZDJA9zLQ6apAeamqYQTtcZ0jlcrSAnH2tGcUmP2_UNWETcuem2by6yANNM06fW_BSHQfnx_37l_ri8P2LLbhpcLWgDoBMQ.rEiqj4sX6o2OL0bUSHH_lyPaU2oaz7WwVZUjEcvAdfU; csid=1.1501693450922.ZoASq4wamKATh3DTF+XT6vI4k5RZ9p244iIFD/Tcx/c=; session=2bdcd0b477a98452_590b5f0a.mJR_-cXYsZowA6O4jMfYIGA0OE8; partners-platform-cookie=tyVcSTFugBm_65y1gNAGVw.jh_CmLECRMEHqmAlmTNd2ifu1iFYpTo1TNou_YyZH8wt9X4Ibq_VTxyGa3qQy8ip6nPqXCd0IUR4fheWOC_y8TgNKO4djaX5O5ki4QOkbpimRzwW3BEQ7dTqf-wShxK5-Ot333MbegsAJMmEPPI-ZIXpeZvpBll20xUGtTvUmlV2mBiFyLCRAQLN-b4Bgcq3wSf6mrZ-JC0F0Rl6n6XC_9Kbu5wNe7eEb610gv6dfe4nsP2Wtpt1KrLxr1UTzZtcf0kh48DTc6pVsdsXrkpbL-vilMmSLyFigXH7f5I5CW_0owaakM_6IgNBFPTHK3ojzajhSUcuglI7r0tykLkehiC0ZmdboOkduU4Kz5z9TsltG2wk7i5cHXOLJ7-vrWlA3_zE4pJCLYmit4pUgQQEsOangCAJN80VRlxc1b8ZY6xm-DbOY6km_QQ20ReCzFMivDex9d_mMgGFU4F9VFKPK1VLGQcgQ96vzGC9HRCgq_4.1493917412315.1209600000.ZslWFNWCY0NiN86dwqEepGZjs7-kFke01SmWEbhatAk; mp_e39a4ba8174726fb79f6a6c77b7a5247_mixpanel=%7B%22distinct_id%22%3A%20%2215afc1d39c826b-027e74f21c5b4b-6a11157a-c0000-15afc1d39c955e%22%2C%22__mps%22%3A%20%7B%7D%2C%22__mpso%22%3A%20%7B%7D%2C%22__mpa%22%3A%20%7B%7D%2C%22__mpu%22%3A%20%7B%7D%2C%22__mpap%22%3A%20%5B%5D%2C%22Lead%20Page%22%3A%20%22https%3A%2F%2Flogin.uber.com%2Flogin%22%2C%22%24initial_referrer%22%3A%20%22%24direct%22%2C%22%24initial_referring_domain%22%3A%20%22%24direct%22%7D; mp_mixpanel__c=0; _ga=GA1.2.25308781.1490288458; _gid=GA1.2.2010175705.1493917458; __lnkrntafu=-1; utag_main=v_id:015afc1d38a0001f6dae6cb42ad20406c001c06400718$_sn:4$_ss:0$_st:1493919258362$segment:b$optimizely_segment:b$dc_visit:4$ses_id:1493916562768%3Bexp-session$_pn:6%3Bexp-session$dc_event:19%3Bexp-session$dc_region:eu-central-1%3Bexp-session; aam_uuid=46850037910629450221330228361444198803; fsid=8bee7gen-jmri-jloo-ulmr-x1yy8ux34y8d\";\n\t$sHeader[] = \"Accept-Language: ru-Ru,ru;q=0.5\";\n\t$sHeader[] = \"Pragma: \";\n\n\tcurl_setopt($oCurl, CURLOPT_URL, $sURL);\n\tcurl_setopt($oCurl, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 5.1; rv:5.0) Gecko/20100101 Firefox/5.0 Firefox/5.0');\n\tcurl_setopt($oCurl, CURLOPT_HTTPHEADER, $sHeader);\n\tcurl_setopt($oCurl, CURLOPT_HEADER, true);\n\tcurl_setopt($oCurl, CURLOPT_REFERER, 'https://partners.uber.com/p3/fleet/live');\n\tcurl_setopt($oCurl, CURLOPT_ENCODING, 'gzip,deflate');\n\tcurl_setopt($oCurl, CURLOPT_AUTOREFERER, true);\n\tcurl_setopt($oCurl, CURLOPT_RETURNTRANSFER, true);\n\t//curl_setopt($oCurl, CURLOPT_FOLLOWLOCATION, true); //CURLOPT_FOLLOWLOCATION Disabled...\n\tcurl_setopt($oCurl, CURLOPT_TIMEOUT, 0);\n\tcurl_setopt($oCurl, CURLOPT_SSL_VERIFYPEER, false);\n\t\n//curl_setopt($oCurl, CURLOPT_COOKIEJAR, '.cookie');\n//curl_setopt($oCurl, CURLOPT_COOKIEFILE, '.cookie');\n\n\tcurl_setopt($oCurl, CURLOPT_POST, $aPost!==0 );\n\tif($aPost) curl_setopt($oCurl, CURLOPT_POSTFIELDS, $aPost);\n\n\t$sHtml = curl_exec($oCurl);\n\t$aStatus = curl_getinfo($oCurl);\n\n\n\t$paData[$sURL]=$aStatus;\n\t$paData[$sURL]['HTML']=$sHtml;\n\n\tcurl_close($oCurl);\n\n\tif($aStatus['http_code']!=200){\n\t\tfnLog(\"GetURL: failed \".print_r($aStatus,true));\n\t\treturn false;\n\t}\n\n\treturn $sHtml;\n}", "title": "" }, { "docid": "e51d57dc4aee0acd9cbc19a567b6047a", "score": "0.6126823", "text": "function curl($url) {\n\t // Assigning cURL options to an array\n\t $options = Array(\n\t CURLOPT_RETURNTRANSFER => TRUE, // Setting cURL's option to return the webpage data\n\t CURLOPT_FOLLOWLOCATION => TRUE, // Setting cURL to follow 'location' HTTP headers\n\t CURLOPT_AUTOREFERER => TRUE, // Automatically set the referer where following 'location' HTTP headers\n\t CURLOPT_CONNECTTIMEOUT => 120, // Setting the amount of time (in seconds) before the request times out\n\t CURLOPT_TIMEOUT => 120, // Setting the maximum amount of time for cURL to execute queries\n\t CURLOPT_MAXREDIRS => 10, // Setting the maximum number of redirections to follow\n\t CURLOPT_USERAGENT => \"Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1a2pre) Gecko/2008073000 Shredder/3.0a2pre ThunderBrowse/3.2.1.8\", // Setting the useragent\n\t CURLOPT_URL => $url, // Setting cURL's URL option with the $url variable passed into the function\n\t );\n\t \n\t $ch = curl_init(); // Initialising cURL \n\t curl_setopt_array($ch, $options); // Setting cURL's options using the previously assigned array data in $options\n\t $data = curl_exec($ch); // Executing the cURL request and assigning the returned data to the $data variable\n\t curl_close($ch); // Closing cURL \n\t return $data; // Returning the data from the function \n\t }", "title": "" }, { "docid": "aef6ff20a33235de72f34f8424dc3dbb", "score": "0.61199796", "text": "function curl($url) {\r\n // Assigning cURL options to an array\r\n $options = Array(\r\n CURLOPT_RETURNTRANSFER => TRUE, // Setting cURL's option to return the webpage data\r\n CURLOPT_FOLLOWLOCATION => TRUE, // Setting cURL to follow 'location' HTTP headers\r\n CURLOPT_AUTOREFERER => TRUE, // Automatically set the referer where following 'location' HTTP headers\r\n CURLOPT_CONNECTTIMEOUT => 120, // Setting the amount of time (in seconds) before the request times out\r\n CURLOPT_TIMEOUT => 120, // Setting the maximum amount of time for cURL to execute queries\r\n CURLOPT_MAXREDIRS => 10, // Setting the maximum number of redirections to follow\r\n CURLOPT_USERAGENT => \"Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1a2pre) Gecko/2008073000 Shredder/3.0a2pre ThunderBrowse/3.2.1.8\", // Setting the useragent\r\n CURLOPT_URL => $url, // Setting cURL's URL option with the $url variable passed into the function\r\n );\r\n \r\n $ch = curl_init(); // Initialising cURL \r\n curl_setopt_array($ch, $options); // Setting cURL's options using the previously assigned array data in $options\r\n $data = curl_exec($ch); // Executing the cURL request and assigning the returned data to the $data variable\r\n curl_close($ch); // Closing cURL \r\n return $data; // Returning the data from the function \r\n }", "title": "" }, { "docid": "7814ae1f5281e1e1d2a7ff2635bbb6c0", "score": "0.6086527", "text": "function getCurl( $url ){\n\t $ch = curl_init();\n\t \n\t // Now set some options (most are optional)\n\t \n\t // Set URL to download\n\t curl_setopt($ch, CURLOPT_URL, $url );\n\t \n\t // Set a referer\n\t curl_setopt($ch, CURLOPT_REFERER, \"http:/iris.scanmine.com/\");\n\t \n\t // User agent\n\t curl_setopt($ch, CURLOPT_USERAGENT, \"MozillaXYZ/1.0\");\n\t \n\t // Include header in result? (0 = yes, 1 = no)\n\t curl_setopt($ch, CURLOPT_HEADER, 0);\n\t \n\t // Should cURL return or print out the data? (true = return, false = print)\n\t curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\t \n\t // Timeout in seconds\n\t curl_setopt($ch, CURLOPT_TIMEOUT, 10);\n\t \n\t // Download the given URL, and return output\n\t $output = curl_exec($ch);\n\t \n\t // Close the cURL resource, and free system resources\n\t curl_close($ch);\n\t \t\n\t\treturn $output;\n\t}", "title": "" }, { "docid": "3685bdb93424a5e2ea66a24c24d8ebb1", "score": "0.6025063", "text": "function curl($url) {\n $options = Array(\n CURLOPT_RETURNTRANSFER => TRUE, // Setting cURL's option to return the webpage data\n CURLOPT_FOLLOWLOCATION => TRUE, // Setting cURL to follow 'location' HTTP headers\n CURLOPT_AUTOREFERER => TRUE, // Automatically set the referer where following 'location' HTTP headers\n CURLOPT_CONNECTTIMEOUT => 400, // Setting the amount of time (in seconds) before the request times out\n CURLOPT_TIMEOUT => 400, // Setting the maximum amount of time for cURL to execute queries\n CURLOPT_MAXREDIRS => 50, // Setting the maximum number of redirections to follow\n CURLOPT_USERAGENT => \"Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1a2pre) Gecko/2008073000 Shredder/3.0a2pre ThunderBrowse/3.2.1.8\", // Setting the useragent\n CURLOPT_URL => $url, // Setting cURL's URL option with the $url variable passed into the function\n );\n \n $ch = curl_init(); // Initialising cURL \n curl_setopt_array($ch, $options); // Setting cURL's options using the previously assigned array data in $options\n $data = curl_exec($ch); // Executing the cURL request and assigning the returned data to the $data variable\n curl_close($ch); // Closing cURL \n return $data; // Returning the data from the function \n }", "title": "" }, { "docid": "1da20c2edf75f3254e4a66c6bf12f0cc", "score": "0.6016401", "text": "public function get_remote_data($url, $post_paramtrs=false, $extra=array('schemeless'=>true, 'replace_src'=>true, 'return_array'=>false, \"curl_opts\"=>[]))\t\n\t{ \n\t\t$c = curl_init(); \n\t\tcurl_setopt($c, CURLOPT_URL, $url);\n\t\tcurl_setopt($c, CURLOPT_RETURNTRANSFER, 1);\n\t\t//if parameters were passed to this function, then transform into POST method.. (if you need GET request, then simply change the passed URL)\n\t\tif($post_paramtrs){ curl_setopt($c, CURLOPT_POST,TRUE); curl_setopt($c, CURLOPT_POSTFIELDS, (is_array($post_paramtrs)? http_build_query($post_paramtrs) : $post_paramtrs) ); }\n\t\tcurl_setopt($c, CURLOPT_SSL_VERIFYHOST,false); \n\t\tcurl_setopt($c, CURLOPT_SSL_VERIFYPEER,false);\n\t\tcurl_setopt($c, CURLOPT_COOKIE, 'CookieName1=Value;'); \n\t\t\t$headers[]= \"User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:76.0) Gecko/20100101 Firefox/76.0\";\t $headers[]= \"Pragma: \"; $headers[]= \"Cache-Control: max-age=0\";\n\t\t\tif (!empty($post_paramtrs) && !is_array($post_paramtrs) && is_object(json_decode($post_paramtrs))){ $headers[]= 'Content-Type: application/json'; $headers[]= 'Content-Length: '.strlen($post_paramtrs); }\n\t\tcurl_setopt($c, CURLOPT_HTTPHEADER, $headers);\n\t\tcurl_setopt($c, CURLOPT_MAXREDIRS, 10); \n\t\t//if SAFE_MODE or OPEN_BASEDIR is set,then FollowLocation cant be used.. so...\n\t\t$follow_allowed= ( ini_get('open_basedir') || ini_get('safe_mode')) ? false:true; if ($follow_allowed){curl_setopt($c, CURLOPT_FOLLOWLOCATION, 1);}\n\t\tcurl_setopt($c, CURLOPT_CONNECTTIMEOUT, 15); \n\t\tcurl_setopt($c, CURLOPT_TIMEOUT, 25);\n\t\tcurl_setopt($c, CURLOPT_REFERER, $url); \n\t\tcurl_setopt($c, CURLOPT_AUTOREFERER, true);\n\t\tcurl_setopt($c, CURLOPT_ENCODING, 'gzip,deflate');\n\t\tcurl_setopt($c, CURLOPT_HEADER, !empty($extra['return_array']));\n\t\t//set extra options if passed\n\t\tif(!empty($extra['curl_opts'])) foreach($extra['curl_opts'] as $key=>$value) curl_setopt($c, constant($key), $value);\n\t\t$data = curl_exec($c);\n\t\tif(!empty($extra['return_array'])) { \n\t\t\tpreg_match(\"/(.*?)\\r\\n\\r\\n((?!HTTP\\/\\d\\.\\d).*)/si\",$data, $x); preg_match_all('/(.*?): (.*?)\\r\\n/i', trim('head_line: '.$x[1]), $headers_, PREG_SET_ORDER); foreach($headers_ as $each){ $header[$each[1]] = $each[2]; } $data=trim($x[2]); \n\t\t}\n\t\t$status=curl_getinfo($c); curl_close($c);\n\t\t// if redirected, then get that redirected page\n\t\tif($status['http_code']==301 || $status['http_code']==302) { \n\t\t\t//if we FOLLOWLOCATION was not allowed, then re-get REDIRECTED URL\n\t\t\t//p.s. WE dont need \"else\", because if FOLLOWLOCATION was allowed, then we wouldnt have come to this place, because 301 could already auto-followed by curl :)\n\t\t\tif (!$follow_allowed){\n\t\t\t\t//if REDIRECT URL is found in HEADER\n\t\t\t\tif(empty($redirURL)){if(!empty($status['redirect_url'])){$redirURL=$status['redirect_url'];}}\n\t\t\t\t//if REDIRECT URL is found in RESPONSE\n\t\t\t\tif(empty($redirURL)){preg_match('/(Location:|URI:)(.*?)(\\r|\\n)/si', $data, $m);\t if (!empty($m[2])){ $redirURL=$m[2]; } }\n\t\t\t\t//if REDIRECT URL is found in OUTPUT\n\t\t\t\tif(empty($redirURL)){preg_match('/moved\\s\\<a(.*?)href\\=\\\"(.*?)\\\"(.*?)here\\<\\/a\\>/si',$data,$m); if (!empty($m[1])){ $redirURL=$m[1]; } }\n\t\t\t\t//if URL found, then re-use this function again, for the found url\n\t\t\t\tif(!empty($redirURL)){$t=debug_backtrace(); return call_user_func( $t[0][\"function\"], trim($redirURL), $post_paramtrs);}\n\t\t\t}\n\t\t}\n\t\t// if not redirected,and nor \"status 200\" page, then error..\n\t\telseif ( $status['http_code'] != 200 ) { $data = \"ERRORCODE22 with $url<br/><br/>Last status codes:\".json_encode($status).\"<br/><br/>Last data got:$data\";}\n\t\t//URLS correction\n\t\t$answer = ( !empty($extra['return_array']) ? array('data'=>$data, 'header'=>$header, 'info'=>$status) : $data);\n\t\treturn $answer; \n\t}", "title": "" }, { "docid": "0855576450b5d61d0ce78fc54fded16c", "score": "0.60162956", "text": "function getCurl( $url ){\n\t\t// $url \t=\t\"http://iris.scanmine.com:8090/getpubtempl?lang=en\";\n\t \t\n\t \t// OK cool - then let's create a new cURL resource handle\n\t $ch = curl_init();\n\t \n\t // Now set some options (most are optional)\n\t \n\t // Set URL to download\n\t curl_setopt($ch, CURLOPT_URL, $url );\n\t \n\t // Set a referer\n\t curl_setopt($ch, CURLOPT_REFERER, \"http:/iris.scanmine.com/\");\n\t \n\t // User agent\n\t curl_setopt($ch, CURLOPT_USERAGENT, \"MozillaXYZ/1.0\");\n\t \n\t // Include header in result? (0 = yes, 1 = no)\n\t curl_setopt($ch, CURLOPT_HEADER, 0);\n\t \n\t // Should cURL return or print out the data? (true = return, false = print)\n\t curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\t \n\t // Timeout in seconds\n\t curl_setopt($ch, CURLOPT_TIMEOUT, 10);\n\t \n\t // Download the given URL, and return output\n\t $output = curl_exec($ch);\n\t \n\t // Close the cURL resource, and free system resources\n\t curl_close($ch);\n\t \t\n\t\treturn $output;\n\t}", "title": "" }, { "docid": "72e4915290575b2ecd370d72b7f68a81", "score": "0.60160345", "text": "function fetchCurl($url){\n // initialize curl and assign to a curl handler $ch\n $ch = curl_init($url);\n\n //prevent automatic output to the screen\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); // curl_setopt() has 3 parameters\n\n /*\n in case of MAMP issues\n write these two lines\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);\n */\n\n // execute our request\n $data = curl_exec($ch);\n\n // close curl\n curl_close($ch);\n\n // return result in json\n return json_decode($data);\n}", "title": "" }, { "docid": "13d48f7234f254b0a5cc9d2f1cfb7867", "score": "0.60157144", "text": "function curl($url) {\n $options = Array(\n CURLOPT_RETURNTRANSFER => TRUE, // Setting cURL's option to return the webpage data\n CURLOPT_FOLLOWLOCATION => TRUE, // Setting cURL to follow 'location' HTTP headers\n CURLOPT_AUTOREFERER => TRUE, // Automatically set the referer where following 'location' HTTP headers\n CURLOPT_CONNECTTIMEOUT => 120, // Setting the amount of time (in seconds) before the request times out\n CURLOPT_TIMEOUT => 120, // Setting the maximum amount of time for cURL to execute queries\n CURLOPT_MAXREDIRS => 10, // Setting the maximum number of redirections to follow\n CURLOPT_USERAGENT => \"Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1a2pre) Gecko/2008073000 Shredder/3.0a2pre ThunderBrowse/3.2.1.8\", // Setting the useragent\n CURLOPT_URL => $url, // Setting cURL's URL option with the $url variable passed into the function\n );\n \n $ch = curl_init(); // Initialising cURL \n curl_setopt_array($ch, $options); // Setting cURL's options using the previously assigned array data in $options\n $data = curl_exec($ch); // Executing the cURL request and assigning the returned data to the $data variable\n curl_close($ch); // Closing cURL \n return $data; // Returning the data from the function \n }", "title": "" }, { "docid": "d0cfe6ffcc81a41a86aae50d9a76922f", "score": "0.60091335", "text": "private static function curl($urlInfo, $type = \"GET\", $info = false)\n\t{\n\t $type = strtoupper(trim($type));\n\n\t if (isset($urlInfo['cookie'])) {\n\t $cookie = $urlInfo['cookie'];\n\t unset($urlInfo['cookie']);\n\t }\n\n\t if ($type == \"POST\") {\n\t $url = $urlInfo['url'];\n\t $data = $urlInfo['params'];\n\t } else {\n\t $urlArr = parse_url($urlInfo['url']);\n\n\t if (isset($urlInfo['params'])) {\n\t $params = \"\";\n\t foreach ($urlInfo['params'] as $key => $row) {\n\t if (is_array($row)) {\n\t foreach ($row as $value) {\n\t if ($params) {\n\t $params .= \"&\" . $key . \"=\" . $value;\n\t } else {\n\t $params .= $key . \"=\" . $value;\n\t }\n\t }\n\t } else {\n\t if ($params) {\n\t $params .= \"&\" . $key . \"=\" . $row;\n\t } else {\n\t $params .= $key . \"=\" . $row;\n\t }\n\t }\n\t }\n\t \n\t if (isset($urlArr['query'])) {\n\t if (preg_match(\"/&$/\", $urlArr['query'])) {\n\t $urlArr['query'] .= $params;\n\t } else {\n\t $urlArr['query'] .= \"&\" . $params;\n\t }\n\t } else {\n\t $urlArr['query'] = $params;\n\t }\n\t }\n\n\t if (isset($urlArr['host'])) {\n\t if (isset($urlArr['scheme'])) {\n\t $url = $urlArr['scheme'] . \"://\" . $urlArr['host'];\n\t } else {\n\t $url = $urlArr['host'];\n\t }\n\n\t if (isset($urlArr['port'])) {\n\t $url .= \":\" . $urlArr['port'];\n\t }\n\t if (isset($urlArr['path'])) {\n\t $url .= $urlArr['path'];\n\t }\n\t if (isset($urlArr['query'])) {\n\t $url .= \"?\" . $urlArr['query'];\n\t }\n\t if (isset($urlArr['fragment'])) {\n\t $url .= \"#\" . $urlArr['fragment'];\n\t }\n\t } else {\n\t $url = $urlInfo['url'];\n\t }\n\t }\n\t \n\t $httpHead = array(\n\t \"Accept:text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8\",\n\t \"Cache-Control:no-cache\",\n\t \"Connection:keep-alive\",\n\t \"Pragma:no-cache\",\n\t \"Upgrade-Insecure-Requests:1\",\n\t );\n\t \n\t $ch = curl_init();\n\t curl_setopt($ch, CURLOPT_URL, $url);\n\t if (isset($cookie)) {\n\t curl_setopt($ch, CURLOPT_COOKIE , $cookie);\n\t }\n\t curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);\n\t curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);\n\t curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t curl_setopt($ch, CURLOPT_HTTPHEADER, $httpHead);\n\t curl_setopt($ch, CURLOPT_ENCODING , \"gzip\");\n\t if ($type == \"POST\") {\n\t curl_setopt($ch, CURLOPT_POST, 1);\n\t @curl_setopt($ch, CURLOPT_POSTFIELDS, $data);\n\t } else {\n\t curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');\n\t }\n\t curl_setopt($ch, CURLOPT_USERAGENT, \"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.112 Safari/537.36\");\n\t @curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);\n\t curl_setopt($ch, CURLOPT_MAXREDIRS, 5);\n\t curl_setopt($ch, CURLOPT_HEADER, 0);\n\t curl_setopt($ch, CURLOPT_NOBODY, 0);\n\t $result = curl_exec($ch);\n\t $curlInfo = curl_getinfo($ch);\n\t curl_close($ch); \n\t \n\t if ($info) {\n\t return $curlInfo;\n\t } else {\n\t return $result;\n\t }\n\t}", "title": "" }, { "docid": "a745a3e26e304f376e22df4ef263e33d", "score": "0.5982754", "text": "protected function _extractAdditionalCurlParameter ()\n {\n\n /**\n * retrieve response code\n */\n $this->responseCode = curl_getinfo($this->curl, CURLINFO_HTTP_CODE);\n\n\n /**\n * try extract response type & charset.\n */\n $this->responseType = curl_getinfo($this->curl, CURLINFO_CONTENT_TYPE);\n\n if (!is_null($this->responseType) && count(explode(';', $this->responseType)) > 1) {\n\n list($this->responseType, $possibleCharset) = explode(';', $this->responseType);\n\n //extract charset\n if (preg_match('~^charset=(.+?)$~', trim($possibleCharset), $matches) && isset($matches[1])) {\n $this->responseCharset = strtolower($matches[1]);\n }\n }\n\n\n /**\n * try extract response length\n */\n $this->responseLength = curl_getinfo($this->curl, CURLINFO_CONTENT_LENGTH_DOWNLOAD);\n\n if((int)$this->responseLength === -1) {\n $this->responseLength = strlen($this->response);\n }\n }", "title": "" }, { "docid": "1c6351a0711805816a6d89bd8d5b0dc2", "score": "0.59794366", "text": "function parsercurl(&$parsercurlHandle,$parserurl){\n$parserch = curl_init();\ncurl_setopt($parserch, CURLOPT_URL, $parserurl);\ncurl_setopt($parserch, CURLOPT_TIMEOUT, 30);\ncurl_setopt($parserch, CURLOPT_RETURNTRANSFER, true);\ncurl_setopt($parserch, CURLOPT_HEADER, false);\ncurl_multi_add_handle($parsercurlHandle,$parserch);\nreturn $parserch;\n}", "title": "" }, { "docid": "e8b37a31f10fce0fdee07fc1af58a4af", "score": "0.59391415", "text": "function curl($url = '', $post = array(), $params = array()) {\n $resp = '';\n\n if ($url) {\n $url = str_replace(' ','+',$url);\n\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $url);\n //curl_setopt($ch, CURLOPT_HTTPHEADER, array('Accept: application/json'));\n //curl_setopt($ch, CURLOPT_HEADER, 1);\n if(stripos($url, 'https://') !== false){\n curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);\n }\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n //curl_setopt($ch, CURLOPT_AUTOREFERER, true);\n if ($post) {\n $post_str = '';\n if(is_array($post)){\n $post_str = http_build_query($post);\n }\n curl_setopt($ch, CURLOPT_POST, 1);\n curl_setopt($ch, CURLOPT_POSTFIELDS, $post_str);\n }\n if (isset($_SERVER['HTTP_USER_AGENT']) && $_SERVER['HTTP_USER_AGENT']) {\n //curl_setopt($ch, CURLOPT_USERAGENT, $_SERVER['HTTP_USER_AGENT']);\n }\n\n $useragent = 'Mozilla/5.0 (Windows NT 6.2; WOW64; rv:17.0) Gecko/20100101 Firefox/17.0';\n\n curl_setopt($ch, CURLOPT_USERAGENT, $useragent);\n curl_setopt($ch, CURLOPT_REFERER, 'http://www.vendezvotrevoiture.fr/valeur/10-8/step/2/');\n\n\n\n if(isset($params['jar']) && $params['jar']){\n curl_setopt($ch, CURLOPT_COOKIEJAR, $params['jar']);\n }\n if(isset($params['cookiefile']) && $params['cookiefile']){\n curl_setopt($ch, CURLOPT_COOKIEFILE, $params['cookiefile']);\n } \n //curl_setopt($ch, CURLOPT_HEADER, 1);\n $content = curl_exec($ch);\n\n // $response = curl_getinfo($ch);\n // \n // $this->pr('$response');\n // $this->pr($response);\n\n curl_close($ch);\n\n $resp = $content;\n }\n\n return $resp;\n }", "title": "" }, { "docid": "2ce0e8c7d572bb38a36ff1370da9c97c", "score": "0.59141326", "text": "function grabber($url,$options = array())\n{\n $ch = curl_init ();\n curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt ($ch, CURLOPT_URL, $url);\n curl_setopt ($ch, CURLOPT_TIMEOUT, 120);\n if (count($options) > 0) {\n foreach($options as $option) {\n curl_setopt ($ch, $option[0], $option[1]);\n }\n }\n return curl_exec($ch);\n //curl_close ($ch);\n}", "title": "" }, { "docid": "2ce0e8c7d572bb38a36ff1370da9c97c", "score": "0.59141326", "text": "function grabber($url,$options = array())\n{\n $ch = curl_init ();\n curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt ($ch, CURLOPT_URL, $url);\n curl_setopt ($ch, CURLOPT_TIMEOUT, 120);\n if (count($options) > 0) {\n foreach($options as $option) {\n curl_setopt ($ch, $option[0], $option[1]);\n }\n }\n return curl_exec($ch);\n //curl_close ($ch);\n}", "title": "" }, { "docid": "2ce0e8c7d572bb38a36ff1370da9c97c", "score": "0.59141326", "text": "function grabber($url,$options = array())\n{\n $ch = curl_init ();\n curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt ($ch, CURLOPT_URL, $url);\n curl_setopt ($ch, CURLOPT_TIMEOUT, 120);\n if (count($options) > 0) {\n foreach($options as $option) {\n curl_setopt ($ch, $option[0], $option[1]);\n }\n }\n return curl_exec($ch);\n //curl_close ($ch);\n}", "title": "" }, { "docid": "2ce0e8c7d572bb38a36ff1370da9c97c", "score": "0.59141326", "text": "function grabber($url,$options = array())\n{\n $ch = curl_init ();\n curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt ($ch, CURLOPT_URL, $url);\n curl_setopt ($ch, CURLOPT_TIMEOUT, 120);\n if (count($options) > 0) {\n foreach($options as $option) {\n curl_setopt ($ch, $option[0], $option[1]);\n }\n }\n return curl_exec($ch);\n //curl_close ($ch);\n}", "title": "" }, { "docid": "ab0c9c176276b816360ab61a9a82abd2", "score": "0.5913819", "text": "function get_data($url) {\n\t\n\t\t$ch = curl_init(); \n\t\t$timeout = .5;\n curl_setopt($ch, CURLOPT_URL, $url);\n\t\tcurl_setopt($ch, CURLOPT_POST, 1);\n\t\tcurl_setopt($ch, CURLOPT_POSTFIELDS, \"params=D7,HIGH\");\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, $timeout);\n $data = curl_exec($ch);\n //getinfo gets the data for the request\n $info = curl_getinfo($ch);\n //output the data to get more information.\n print_r($info);\n curl_close($ch);\n return $data;\n}", "title": "" }, { "docid": "7d5bc4903924de5bf1f5d5609b3a8da2", "score": "0.5907857", "text": "public function getRequestURL();", "title": "" }, { "docid": "7d5bc4903924de5bf1f5d5609b3a8da2", "score": "0.5907857", "text": "public function getRequestURL();", "title": "" }, { "docid": "d8312becd2a7ffea6ef2b99f12e4a67d", "score": "0.59032977", "text": "function curl($url) {\n // Grab global variables from `settings.inc`\n global $USE_CUSTOM_USERAGENT,$CUSTOM_USERAGENT,$DEFAULT_USERAGENT;\n global $RETURN_TRANSFER,$FOLLOW_LOCATION,$AUTO_REFERER,$CONNECT_TIMEOUT,$TIMEOUT,$MAX_REDIRS;\n \n $USER_AGENT = !empty($USE_CUSTOM_USERAGENT) ? $CUSTOM_USERAGENT : $DEFAULT_USERAGENT;\n // Assigning cURL options to an array\n $options = Array(\n CURLOPT_RETURNTRANSFER => $RETURN_TRANSFER, // Setting cURL's option to return the webpage data\n CURLOPT_FOLLOWLOCATION => $FOLLOW_LOCATION, // Setting cURL to follow 'location' HTTP headers\n CURLOPT_AUTOREFERER => $AUTO_REFERER, // Automatically set the referer where following 'location' HTTP headers\n CURLOPT_CONNECTTIMEOUT => $CONNECT_TIMEOUT, // Setting the amount of time (in seconds) before the request times out\n CURLOPT_TIMEOUT => $TIMEOUT, // Setting the maximum amount of time for cURL to execute queries\n CURLOPT_MAXREDIRS => $MAX_REDIRS, // Setting the maximum number of redirections to follow\n CURLOPT_USERAGENT => $USER_AGENT, // Setting the useragent\n CURLOPT_URL => $url, // Setting cURL's URL option with the $url variable passed into the function\n );\n \n $ch = curl_init(); // Initialising cURL \n curl_setopt_array($ch, $options); // Setting cURL's options using the previously assigned array data in $options\n $data = curl_exec($ch); // Executing the cURL request and assigning the returned data to the $data variable\n curl_close($ch); // Closing cURL \n return $data; // Returning the data from the function \n }", "title": "" }, { "docid": "9ef137315de195e707ef660f1d48503d", "score": "0.58853585", "text": "function putCurl( $url, $postData ){\n\n\t \t// OK cool - then let's create a new cURL resource handle\n\t $ch = curl_init();\n\t \n\t // Now set some options (most are optional)\n\t \n\t // Set URL to download\n\t curl_setopt($ch, CURLOPT_URL, $url );\n\t \n\t // Set a referer\n\t curl_setopt($ch, CURLOPT_REFERER, \"http:/iris.scanmine.com/\");\n\t \n\t // User agent\n\t curl_setopt($ch, CURLOPT_USERAGENT, \"MozillaXYZ/1.0\");\n\t \n\t // Include header in result? (0 = yes, 1 = no)\n\t curl_setopt($ch, CURLOPT_HEADER, 0);\n\t \n\t // Should cURL return or print out the data? (true = return, false = print)\n\t curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\n\t // set the Post property\n\t curl_setopt($ch,CURLOPT_POST,true);\n\n\t // send post datda\n\t curl_setopt($ch,CURLOPT_POSTFIELDS, $postData);\n\t \n\t // Timeout in seconds\n\t curl_setopt($ch, CURLOPT_TIMEOUT, 10);\n\t \n\t // Download the given URL, and return output\n\t $output = curl_exec($ch);\n\t \n\t // Close the cURL resource, and free system resources\n\t curl_close($ch);\n\n\t\treturn $output;\t\n\n\t}", "title": "" }, { "docid": "ed7a039a63c115e1737bc43f05b545c9", "score": "0.58762723", "text": "function curl($url) {\n\n $ch = curl_init(); // Initialising cURL\n curl_setopt($ch, CURLOPT_URL, $url); // Setting cURL's URL option with the $url variable passed into the function\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE); // Setting cURL's option to return the webpage data\n curl_setopt($ch, CURLOPT_HTTPHEADER, array(\n\t \t'Accept: application/json',\n\t \t'X-ELS-APIKey: 82b47f24bf707a447d642d170ae6e318'\n\t ));\n $data = curl_exec($ch); // Executing the cURL request and assigning the returned data to the $data variable\n curl_close($ch); // Closing cURL\n return $data; // Returning the data from the function\n }", "title": "" }, { "docid": "a7d18b48f4a37c21c63a15f90907b144", "score": "0.58727133", "text": "function getinfo(){\n return curl_getinfo($this->_cURL);\n }", "title": "" }, { "docid": "f560a6dd37170c8ffd89a6ecf240c0b5", "score": "0.58711636", "text": "function openurl($url) {\n\n$ch=curl_init();\ncurl_setopt($ch,CURLOPT_URL,$url);\n//curl_setopt($ch, CURLOPT_POST, 1);\n//curl_setopt($ch,CURLOPT_POSTFIELDS,$postvars);\ncurl_setopt($ch, CURLOPT_POST, 0);\ncurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); \ncurl_setopt($ch,CURLOPT_TIMEOUT, '3'); \n$content = trim(curl_exec($ch)); curl_close($ch); \n//echo $url;\n }", "title": "" }, { "docid": "3eabbd0214abaf8145db313444d56978", "score": "0.58609563", "text": "function curlGet($url){\r\n\t\t$ch = curl_init(); //initialising cURL session\r\n\t\t//Setting cURL options\r\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);\r\n\t\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);\r\n\t\tcurl_setopt($ch, CURLOPT_URL,$url);\r\n\t\t$results = curl_exec($ch); //Closing cURL session\r\n\t\treturn $results; //Return the results\r\n\t}", "title": "" }, { "docid": "bd5cbc5bf449068553db22ed8a7e4614", "score": "0.5833069", "text": "private function _create_short_url()\n {\n $tmp = $this->_curl_start();\n $this->short_url = $tmp->id;\n }", "title": "" }, { "docid": "3982132016cce020766fabcfb4653b0d", "score": "0.5832573", "text": "private function initCurl()\n {\n $ch = curl_init($this->url);\n\n curl_setopt_array($ch, [\n CURLOPT_URL => $this->url,\n CURLOPT_POST => false,\n CURLOPT_RETURNTRANSFER => true,\n CURLOPT_TIMEOUT => 60,\n CURLOPT_COOKIESESSION => true,\n CURLOPT_FOLLOWLOCATION => true,\n ]);\n\n curl_setopt($ch, CURLOPT_HTTPHEADER, [\n 'Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8',\n 'Accept-Encoding: none',\n 'Accept-Language: en-US,en;q=0.8,hu;q=0.6',\n 'Cache-Control: no-cache',\n 'Connection: close',\n 'Cookie: ' . file_get_contents(__DIR__ . self::COOKIE_FILE),\n 'Host: www.sainsburys.co.uk',\n 'Upgrade-Insecure-Requests: 1',\n 'User-Agent:Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36',\n ]);\n\n return $ch;\n }", "title": "" }, { "docid": "30caa638d90453ae4976a200b7792de0", "score": "0.58290327", "text": "function deCode($url) {\n $ch = curl_init(); \n curl_setopt($ch, CURLOPT_URL, $url); \n curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE); \n\t\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); \n\t\tcurl_exec($ch); \n\t\t$data= curl_getinfo($ch);\n curl_close($ch); \n return $data[\"redirect_url\"];\n }", "title": "" }, { "docid": "81ecbc59ea365e03a51263e36acf73bf", "score": "0.58264697", "text": "function opensam_create_and_prepare_curl( $url, $username, $password ) {\n // Allocate the curl object:\n $curlobj = curl_init( $url );\n if( !$curlobj ) return( \"LOGIN FAILED. Invalid Server URL: $url. (curl initialization failed)\" );\n\n //\n // Configure the CURL options to perform a request to the URL with an optimum chance of success.\n //\n $curl_options_array = array( \n CURLOPT_FAILONERROR => false,\n CURLOPT_HTTPAUTH => CURLAUTH_ANY,\n CURLOPT_UNRESTRICTED_AUTH => true,\n CURLOPT_SSL_VERIFYPEER => false,\n CURLOPT_SSL_VERIFYHOST => false,\n// CURLOPT_FOLLOWLOCATION cannot be activated when in safe_mode or an open_basedir is set\n// CURLOPT_FOLLOWLOCATION => true,\n\tCURLOPT_AUTOREFERER\t\t=> true,\n CURLOPT_RETURNTRANSFER => true,\n CURLOPT_CONNECTTIMEOUT => 15,\n CURLOPT_MAXREDIRS => 5,\n );\n \n // Give it the username, password via HTTP Authenticate if that is the method we are using:\n if( !empty( $password ) ) {\n\t$curl_options_array[CURLOPT_USERPWD] = \"$username:$password\"; // this is the funky syntax for curl.\n }\n\n $i = 1;\n foreach( $curl_options_array as $optionnum => $optionvalue ) { \n if( !curl_setopt( $curlobj, $optionnum, $optionvalue ) ) {\n return( \"LOGIN FAILED. System Error. (curl setopt() failed unexpectedly #$1)\" ); \n }\n ++$i;\n }\n \n return( $curlobj );\n}", "title": "" }, { "docid": "f6b92534a8dd67a2053082c386428bd7", "score": "0.58258116", "text": "function setCurl($url, $curlHeader, $curlPostFields, $curlPost) {\n curl_setopt_array($this->curl, array(\n CURLOPT_RETURNTRANSFER => 1,\n CURLOPT_VERBOSE => 1,\n CURLOPT_HEADER => 1,\n CURLOPT_URL => $url,\n CURLOPT_HTTPHEADER => $curlHeader\n ));\n if (!is_null($curlPostFields) && !is_null($curlPost)) {\n curl_setopt($this->curl, CURLOPT_POSTFIELDS, $curlPost);\n curl_setopt($this->curl, CURLOPT_POSTFIELDS, $curlPostFields);\n }\n $response = curl_exec($this->curl);\n $header_size = curl_getinfo($this->curl, CURLINFO_HEADER_SIZE);\n $header = substr($response, 0, $header_size);\n $body = substr($response, $header_size);\n curl_close($this->curl);\n return array(\n 'response' => $response,\n 'header_size' => $header_size,\n 'header' => $header,\n 'body' => $body\n );\n }", "title": "" }, { "docid": "2e25bde4496285221d5c7867641bc303", "score": "0.58222735", "text": "function curl($url) {\n\t\t$options = Array(\n\t\t\tCURLOPT_RETURNTRANSFER => TRUE, // Setting cURL's option to return the webpage data\n\t\t\tCURLOPT_FOLLOWLOCATION => TRUE, // Setting cURL to follow 'location' HTTP headers\n\t\t\tCURLOPT_AUTOREFERER => TRUE, // Automatically set the referer where following 'location' HTTP headers\n\t\t\tCURLOPT_CONNECTTIMEOUT => 120, // Setting the amount of time (in seconds) before the request times out\n\t\t\tCURLOPT_TIMEOUT => 120, // Setting the maximum amount of time for cURL to execute queries\n\t\t\tCURLOPT_MAXREDIRS => 10, // Setting the maximum number of redirections to follow\n\t\t\tCURLOPT_USERAGENT => \"Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1a2pre) Gecko/2008073000 Shredder/3.0a2pre ThunderBrowse/3.2.1.8\", // Setting the useragent\n\t\t\tCURLOPT_URL => $url, // Setting cURL's URL option with the $url variable passed into the function\n\t\t);\n\t\t\n\t\t$ch = curl_init(); // Initialising cURL \n\t\tcurl_setopt_array($ch, $options); // Setting cURL's options using the previously assigned array data in $options\n\t\t$data = curl_exec($ch); // Executing the cURL request and assigning the returned data to the $data variable\n\t\tcurl_close($ch); // Closing cURL \n\t\treturn $data; // Returning the data from the function \n\t}", "title": "" }, { "docid": "ce83908d85537572ab0c57b33cdabaa4", "score": "0.58186406", "text": "function curl($url,$opts=[],$data=[],$args=[],$string=true){\r\nif (!function_exists('curl_init')||empty($url))return;\r\n$ch = curl_init($url);\r\nif(!empty($args['login'][0])){\r\n curl_setopt($ch, CURLOPT_USERPWD, $args['login'][0].':'.$args['login'][1]);\r\n if($args['login'][2])$data['headers']['Authorization']='Basic '.base64_encode($data['login'][0].':'.$data['login'][1]);//also add BasicAuth to header\r\n }\r\nforeach($opts as $k=>$v){if($k=='headers')$k=CURLOPT_HTTPHEADER;if(!strstr('CURLOPT_',$k))$k=constant('CURLOPT_'.strtoupper($k));curl_setopt($ch,$k,$v);}\r\nif(is_array($data))$data=http_build_query($data);\r\nif(!empty($data)&&$args['method']!='get'){\r\ncurl_setopt($ch,CURLOPT_POST,1);\r\ncurl_setopt($ch,CURLOPT_POSTFIELDS,$data);\r\n} // echo $post.'<br />';\r\nif($string)curl_setopt($ch,CURLOPT_RETURNTRANSFER,true);\r\n //$this->print_r($url,1);$this->print_r($opts,1);$this->print_r($data,1);$this->print_r($args,1);$this->print_r($string,1);\r\n//resolving SSL problems\r\nif($args['ssl']===false)curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\r\nelseif($args['ssl']===true)curl_setopt($ch, CURLOPT_CAINFO, dirname(__FILE__).'/cacert.pem');\r\nelseif(!empty($args['ssl']))curl_setopt ($ch,$args['ssl']);\r\n\r\ncurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\r\n$result = curl_exec($ch); //var_dump($result); echo curl_errno($ch).' - '.curl_error($ch).'<br />';\r\n$this->curl_error=curl_error($ch);//nx:function curl_error() returns error_number,error_msg\r\ncurl_close($ch);\r\nif($string=='json'){if($result)return @json_decode($result,true);else return null;}\r\nelse return $result;\r\n}", "title": "" }, { "docid": "b5cf202d199cbf71fe7c89328cf0b0f6", "score": "0.5812874", "text": "private function shortenURL($url) { \n $ch = curl_init(); \n $timeout = 5; \n curl_setopt($ch,CURLOPT_URL,'http://tinyurl.com/api-create.php?url='.$url); \n curl_setopt($ch,CURLOPT_RETURNTRANSFER,1); \n curl_setopt($ch,CURLOPT_CONNECTTIMEOUT,$timeout); \n $data = curl_exec($ch); \n curl_close($ch); \n return $data; \n }", "title": "" }, { "docid": "2da7f4eaf7406abb2fa4dfb2da1fca39", "score": "0.5810637", "text": "public function curl() {\n\t\t$ch = curl_init();\n\t\tcurl_setopt($ch, CURLOPT_URL, $this->infos[\"url\"]);\n\t\tcurl_setopt($ch, CURLOPT_HEADER, false);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\t\tcurl_setopt($ch, CURLOPT_POST, true);\n\t\tcurl_setopt($ch, CURLOPT_POSTFIELDS, $this->infos[\"args\"]);\n\t\t$data = curl_exec($ch);\n\t\t$decode = json_decode($data);\n\t\tif(isset($decode->id)) \n\t\t\treturn $decode->id;\n\t}", "title": "" }, { "docid": "44f8b093d280f282decdc4d68d0bb6d1", "score": "0.5789735", "text": "function curl($url)\n {\n //$cookieFileLocation = \"cookie.txt\";\n $user_agent = 'Mozilla/5.0 (Windows NT 6.2; WOW64; rv:26.0) Gecko/20100101 Firefox/26.0';\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $url);\n //curl_setopt($ch, CURLOPT_HEADER, $header ? true : false);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n //curl_setopt($ch, CURLOPT_USERAGENT, $user_agent); gereksiz, bot bozulur olursa tekrar deneriz\n //curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 0);\n curl_setopt($ch, CURLOPT_TIMEOUT, 10);\n curl_setopt($ch, CURLOPT_REFERER, $url); // referrer burda belirt\n curl_setopt($ch, CURLOPT_USERAGENT, $user_agent); // siteye hangi tarayıcı ile bağlandığımı söyle\n $icerik = curl_exec($ch);\n curl_close($ch);\n\n return $icerik;\n }", "title": "" }, { "docid": "108bcab2902468e549321a31dca831de", "score": "0.578448", "text": "public function getURLInfo($url) {\t\t\t\t\t\t\n\t\t$url_info = parse_url(str_replace('&amp;', '&', $url));\n\t\t\n\t\t$url_info['scheme'] = isset($url_info['scheme']) ? $url_info['scheme'] . '://' : '';\n\t\t$url_info['user'] = isset($url_info['user']) ? $url_info['user'] : '';\n\t\t$url_info['pass'] = isset($url_info['pass']) ? ':' . $url_info['pass'] : '';\n\t\t$url_info['pass'] = ($url_info['user'] || $url_info['pass']) ? $url_info['pass'] . '@' : ''; \n\t\t$url_info['host'] = isset($url_info['host']) ? $url_info['host'] : '';\n\t\t$url_info['port'] = isset($url_info['port']) ? ':' . $url_info['port'] : '';\n\t\t$url_info['path'] = isset($url_info['path']) ? $url_info['path'] : '';\t\t\n\t\t\n\t\t$url_info['data'] = array();\n\t\t\n\t\tif (isset($url_info['query'])) {\n\t\t\tparse_str($url_info['query'], $url_info['data']);\n\t\t}\n\t\t\n\t\t$url_info['query'] = isset($url_info['query']) ? '?' . $url_info['query'] : '';\n\t\t$url_info['fragment'] = isset($url_info['fragment']) ? '#' . $url_info['fragment'] : '';\n\t\t\t\t\t\t\n\t\treturn $url_info;\n\t}", "title": "" }, { "docid": "8c8c725b5f18f068226b04334753879f", "score": "0.577382", "text": "private function _prepare($url) {\r\n $this->_HTTPRequest = & new HTTP_Request2($url,array(\r\n 'allowRedirects'=>$this->_REDIRECTS,\r\n 'maxRedirects'=>4,\r\n 'timeout'=>10\r\n ));\r\n $this->_HTTPRequest->clearPostData();\r\n\r\n $debugproxy = getenv('DEBUGPROXY');\r\n if (!empty ($debugproxy)) {\r\n $debugproxy = explode(':', $debugproxy);\r\n $this->_HTTPRequest->setProxy($debugproxy[0], $debugproxy[1]); // for fiddler debug proxy\r\n }\r\n\r\n if ($this->_USERNAME != '') {\r\n $this->_HTTPRequest->setBasicAuth($this->_USERNAME, $this->_PASSWORD);\r\n }\r\n\r\n $this->_HTTPRequest->setURL($url);\r\n $this->_URL = $url;\r\n\r\n unset ($this->_PARAMS_FROM_SERVER);\r\n unset ($this->_COOKIESIN);\r\n $this->_RESPONSECODE = null;\r\n $this->_RESPONSEBODY = false;\r\n\r\n if (count($this->_COOKIESOUT) > 0) {\r\n foreach ($this->_COOKIESOUT as $k => $v) {\r\n $this->_HTTPRequest->addCookie($k, $v);\r\n if (defined('DEBUG1')) {\r\n echo \"added cookie $k=$v\\n\";\r\n }\r\n }\r\n }\r\n\r\n if (count($this->_PARAMS_TO_SERVER) > 0) {\r\n foreach ($this->_PARAMS_TO_SERVER as $k => $v) {\r\n $this->_HTTPRequest->addHeader($k, $v);\r\n if (defined('DEBUG1')) {\r\n echo \"added header $k=$v\\n\";\r\n }\r\n }\r\n }\r\n $this->_HTTPRequest->addHeader('User-Agent', 'kataTest');\r\n\r\n if (count($this->_POSTPARAMS) > 0) {\r\n foreach ($this->_POSTPARAMS as $k => $v) {\r\n $this->_HTTPRequest->addPostData($k, $v);\r\n if (defined('DEBUG1')) {\r\n echo \"added post parameter $k=$v\\n\";\r\n }\r\n }\r\n }\r\n }", "title": "" }, { "docid": "93a717f7090823b4a76b015555674974", "score": "0.57687455", "text": "function get_data($url)\n{\n\n\n\t\tunset($_REQUEST[\"method\"]);\n\n\t\t$arr = array();\n\n\t\tforeach ($_REQUEST as $key => $value) {\n\t\t\t\t$arr[] = \"$key=$value\";\n\t\t}\n\n\t\t$var_str = implode(\"&\", $arr);\n\n $ch = curl_init();\n $timeout = 5;\n\n\t\t$userAgent = \"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)\";\n\t\tcurl_setopt($ch, CURLOPT_USERAGENT, $userAgent);\n\t\tcurl_setopt($ch, CURLOPT_FAILONERROR, true);\n\t\t// curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n\t\tcurl_setopt($ch, CURLOPT_AUTOREFERER, true);\n\t\tcurl_setopt($ch, CURLOPT_TIMEOUT, 10);\n\t\tcurl_setopt($ch,CURLOPT_URL,$url);\n\t\tcurl_setopt($ch,CURLOPT_RETURNTRANSFER,1);\n\t\t// curl_setopt($ch, CURLOPT_HEADER, 1);\n\t\tcurl_setopt($ch,CURLOPT_CONNECTTIMEOUT,$timeout);\n\t\tcurl_setopt($ch, CURLOPT_POST, 1);\n\t\t// from all\n\t\t// no_more false\n\t\t// page 3\n\t\t// page_count 253\n\t\t// thumb_size 1\n\t\tcurl_setopt($ch, CURLOPT_POSTFIELDS, \"$var_str\");\n\t\t $data = curl_exec($ch);\n\t\t curl_close($ch);\n\t\t return $data;\n}", "title": "" }, { "docid": "a5661b00d354aca9454a339e042b2417", "score": "0.5765024", "text": "function curl(&$curlHandle,$url){\n$ch = curl_init();\ncurl_setopt($ch, CURLOPT_URL, $url);\ncurl_setopt($ch, CURLOPT_TIMEOUT, 30);\ncurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\ncurl_setopt($ch, CURLOPT_HEADER, false);\ncurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\ncurl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.1) Gecko/20061204 Firefox/2.0.0.1');\ncurl_multi_add_handle($curlHandle,$ch);\nreturn $ch;\n}", "title": "" }, { "docid": "14b42cc4443afe403614370a11e41362", "score": "0.57607836", "text": "function fetchUrl($url){\n\t\t\t $ch = curl_init();\n\t\t\t curl_setopt($ch, CURLOPT_URL, $url);\n\t\t\t curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\t\t curl_setopt($ch, CURLOPT_TIMEOUT, 20);\n\t\t\t // You may need to add the line below\n\t\t\t // curl_setopt($ch,CURLOPT_SSL_VERIFYPEER,false);\n\n\t\t\t $feedData = curl_exec($ch);\n\t\t\t curl_close($ch); \n\n\t\t\t return $feedData;\n\t\t }", "title": "" }, { "docid": "48c38d256b401aa4de7a190c9cfa569d", "score": "0.57580847", "text": "function curlGetData($url) {\n /* Get data */\n $ch = curl_init($url);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n //curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($ch, CURLOPT_USERAGENT, USER_AGENT);\n curl_setopt($ch, CURLOPT_TIMEOUT, TIMEOUT);\n $data = curl_exec($ch);\n $error = curl_errno($ch);\n\n /* Did we get an error? */\n if ($error != 0) {\n $str = str_replace('\\'', '\\\\\\'', curl_error($ch));\n curl_close($ch);\n error_out('An error occurred when processing your request.\\n\\nError returned: ' . $error . ' - ' . $str);\n }\n curl_close($ch);\n\n return $data;\n}", "title": "" }, { "docid": "56d2013328cfa5b31b733cf6b5ca5e01", "score": "0.5740929", "text": "function getPageHtml($url, $curl){\n\n//$curl = curl_init();\n\ncurl_setopt($curl, CURLOPT_URL, $url);\ncurl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);\n \n\n$result = curl_exec($curl);\n\nreturn $result;\n}", "title": "" }, { "docid": "9f61ce2c4121e73aca5abe4a934ed792", "score": "0.5727911", "text": "public function curl_getinfo() {\n\t\t$this->setCurlInfos ( curl_getinfo ( $this->getConnexion () ) );\n\t\t$code_retour = curl_getinfo ( $this->getConnexion (), CURLINFO_HTTP_CODE );\n\t\t$this->setCodeRetourCurl ( $code_retour );\n\t\treturn $code_retour;\n\t}", "title": "" }, { "docid": "c9f4ffcf5bf586c53da43c3d30623575", "score": "0.5722904", "text": "function databasecurl(&$databasecurlHandle,$databaseurl){\r\n$databasech = curl_init();\r\ncurl_setopt($databasech, CURLOPT_URL, $databaseurl);\r\ncurl_setopt($databasech, CURLOPT_TIMEOUT, 30);\r\ncurl_setopt($databasech, CURLOPT_RETURNTRANSFER, true);\r\ncurl_setopt($databasech, CURLOPT_HEADER, false);\r\ncurl_multi_add_handle($databasecurlHandle,$databasech);\r\nreturn $databasech;\r\n}", "title": "" }, { "docid": "fec3a7990b7eda79cf75d8a1f2d0e7d8", "score": "0.57199126", "text": "function curl($url){\n $options = Array(\n CURLOPT_RETURNTRANSFER => TRUE, // Setting cURL's option to return the webpage data\n CURLOPT_FOLLOWLOCATION => TRUE, // Setting cURL to follow 'location' HTTP headers\n CURLOPT_AUTOREFERER => TRUE, // Automatically set the referer where following 'location' HTTP headers\n CURLOPT_CONNECTTIMEOUT => 120, // Setting the amount of time (in seconds) before the request times out\n CURLOPT_TIMEOUT => 120, // Setting the maximum amount of time for cURL to execute queries\n CURLOPT_MAXREDIRS => 10, // Setting the maximum number of redirections to follow\n //CURLOPT_USERAGENT => \"Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1a2pre) Gecko/2008073000 Shredder/3.0a2pre ThunderBrowse/3.2.1.8\", // Setting the useragent\n CURLOPT_URL => $url, // Setting cURL's URL option with the $url variable passed into the function\n );\n\n $ch = curl_init();\n curl_setopt_array($ch, $options);\n $data = curl_exec($ch);\n curl_close($ch);\n return $data;\n }", "title": "" }, { "docid": "ed2fce3b86cf41b926cf082307d2810f", "score": "0.5706559", "text": "public function prepare($curl, $query, $username = null, $password = null);", "title": "" }, { "docid": "8c24e19ece442ccb23ba431b4c750790", "score": "0.5696115", "text": "function curl($url) {\n\n $ch = curl_init();\n\n curl_setopt($ch, CURLOPT_HEADER, false);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_TIMEOUT, 5);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n $data = curl_exec($ch);\n // echo curl_error($ch);\n curl_close($ch);\n\n return $data;\n}", "title": "" }, { "docid": "7d83360b09d544ce71efd7a1f3a1cfba", "score": "0.5663601", "text": "function fetchData($url){\n\t\t $ch = curl_init();\n\t\t curl_setopt($ch, CURLOPT_URL, $url);\n\t\t curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\t curl_setopt($ch, CURLOPT_TIMEOUT, 20);\n\t\t $result = curl_exec($ch);\n\t\t curl_close($ch); \n\t\t return $result;\n\t\t}", "title": "" }, { "docid": "27cb7706d79eb5c34d69af79f70da4a0", "score": "0.56527305", "text": "private function buildCurl($url)\n {\n $restApiUrl = SecurityModel::TRADESHIFT_REST_API_URL . $url;\n\n $additionalHeaders = [\n 'Authorization: '.SecurityModel::HEADER_AUTHORIZATION_REQUEST_TYPE.' '. $this->getAccessToken()\n ];\n\n $ch = curl_init($restApiUrl);\n curl_setopt($ch, CURLOPT_HTTPHEADER, $additionalHeaders);\n curl_setopt($ch, CURLOPT_HEADER, false);\n curl_setopt($ch, CURLOPT_TIMEOUT, 30);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n return $ch;\n }", "title": "" }, { "docid": "6521cfd18eb0c53c22a91fd1ed8cfcd2", "score": "0.5650946", "text": "public function curl( $url )\n\t{\n\t\treturn parent::curl( $url );\n\t}", "title": "" }, { "docid": "b8de4a62404147317221708f5c36d3d6", "score": "0.56457466", "text": "function doCurl($url){\n\twriteToLog($GLOBALS['callid'], $GLOBALS['fh'], \"L0\", __FUNCTION__ . \" is called.\");\n\t\t$ch = curl_init();\n\t\tcurl_setopt($ch, CURLOPT_URL, $url);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($ch, CURLOPT_TIMEOUT, 20);\n\t\tcurl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 15);\n\t\t$result = curl_exec($ch);\n\t\tcurl_close($ch);\n\twriteToLog($GLOBALS['callid'], $GLOBALS['fh'], \"L0\", __FUNCTION__ . \" called with url: $url, is returning: $result\");\n\treturn $result;\n}", "title": "" }, { "docid": "e1d9e3dcac42adb661ecf39c43e30c3a", "score": "0.56415784", "text": "function curl_get_result($url) {\n\t\t$ch = curl_init();\n\t\t$timeout = 5;\n\t\tcurl_setopt($ch,CURLOPT_URL,$url);\n\t\tcurl_setopt($ch,CURLOPT_RETURNTRANSFER,1);\n\t\tcurl_setopt($ch,CURLOPT_CONNECTTIMEOUT,$timeout);\n\t\t$data = curl_exec($ch);\n\t\tcurl_close($ch);\n\t\treturn $data;\n\t}", "title": "" }, { "docid": "fcc6aeaa31c1357f9c940e0966bd6f31", "score": "0.56392086", "text": "public function curl($url) {\n\t\t$ch = curl_init();\n\t\tcurl_setopt($ch, CURLOPT_URL, $url); // Define target site\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE); // Return page in string\n\t\tcurl_setopt($ch, CURLOPT_ENCODING , \"gzip\"); \n\t\tcurl_setopt($ch, CURLOPT_TIMEOUT, 120); \n\t\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE); // Follow redirects\n\t\t\n\t\t$return = curl_exec($ch); \n\t\t$info = curl_getinfo($ch); \n\t\tcurl_close($ch);\n\t\treturn $return;\n\t}", "title": "" }, { "docid": "f3aa87972edc337c30f89cc7db4b833a", "score": "0.563749", "text": "function fetch_url($url, $ip=null, $timeout=5)\n\t{\n\t\t// set url to post to\n\t\tcurl_setopt($this->ch, CURLOPT_URL,$url);\n\n\t\t//set method to get\n\t\tcurl_setopt($this->ch, CURLOPT_HTTPGET,true);\n\n\t\t// return into a variable rather than displaying it\n\t\tcurl_setopt($this->ch, CURLOPT_RETURNTRANSFER,true);\n\n\t\t//bind to specific ip address if it is sent trough arguments\n\t\tif($ip)\n\t\t{\n\t\t\tif($this->debug)\n\t\t\t{\n\t\t\t\techo \"Binding to ip $ip\\n\";\n\t\t\t}\n\t\t\tcurl_setopt($this->ch,CURLOPT_INTERFACE,$ip);\n\t\t}\n\n\t\t//set curl function timeout to $timeout\n\t\tcurl_setopt($this->ch, CURLOPT_TIMEOUT, $timeout);\n\n\t\t//and finally send curl request\n\t\t$result = curl_exec($this->ch);\n\n\t\tif(curl_errno($this->ch))\n\t\t{\n\t\t\tif($this->debug)\n\t\t\t{\n\t\t\t\techo \"Error Occured in Curl\\n\";\n\t\t\t\techo \"Error number: \" .curl_errno($this->ch) .\"\\n\";\n\t\t\t\techo \"Error message: \" .curl_error($this->ch).\"\\n\";\n\t\t\t}\n\n\t\t\treturn false;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn $result;\n\t\t}\n\t}", "title": "" }, { "docid": "85f4731f3e9080c531be0b6726d6fe05", "score": "0.56369495", "text": "public function getUrlContent($url) {\r\n\t\t/*\r\n\t\t$splitIndex = strrpos($url, \"?\");\r\n\t\t$post = substr($url, $splitIndex+1);\r\n\t\t$url = substr($url,0,$splitIndex);\r\n\t\t\r\n\t\t$option[CURLOPT_POST] = 1;\r\n\t\t$option[CURLOPT_POSTFIELDS] = $post;\r\n\t\t*/\r\n\t\treturn $this->XCurl($url, array());\r\n\t}", "title": "" }, { "docid": "ca6b1169af6cf72567e2c0d7271bad87", "score": "0.5635319", "text": "function grab2($url){$ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url);\ncurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\ncurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, true);\ncurl_setopt($ch,CURLOPT_ENCODING,'gzip');\ncurl_setopt($ch, CURLOPT_SSL_VERIFYHOST, true);\ncurl_setopt($ch, CURLOPT_TIMEOUT, 10);\n$header[] = \"Accept-Language: en\";\n$header[] = \"User-Agent: Mozilla/5.0 (BlackBerry; U; BlackBerry 9800; en) AppleWebKit/534.1+ (KHTML, Like Gecko) Version/6.0.0.141 Mobile Safari/534.1+\";\n$header[] = \"Pragma: no-cache\";\n$header[] = \"Cache-Control: no-cache\";\n$header[] = \"Accept-Encoding: gzip,deflate\";\n$header[] = \"Content-Encoding: gzip\";\n$header[] = \"Content-Encoding: deflate\";\ncurl_setopt($ch, CURLOPT_HTTPHEADER, $header);\n$load = curl_exec($ch);\ncurl_close($ch);\nreturn $load;\n}", "title": "" }, { "docid": "39c1051aa299e105f5ecf3a0a87e21a8", "score": "0.5624294", "text": "public function get_url() {}", "title": "" }, { "docid": "eeb31e0e857ef492fe17ca461bedf989", "score": "0.56104493", "text": "public function get_url_params() {}", "title": "" }, { "docid": "588610d8dac2edd192274ed9753bb0d7", "score": "0.5606007", "text": "public function __construct($url)\n {\n $this->curl = curl_init($url);\n curl_setopt($this->curl, CURLOPT_RETURNTRANSFER, TRUE);\n }", "title": "" }, { "docid": "7ee01170814619790ca92fbeb31548c1", "score": "0.5603694", "text": "function parseURL($src_url) { \n\n // Alter from file_get_contents to use CURL\n $curl = curl_init();\n curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);\n curl_setopt($curl, CURLOPT_HEADER, false);\n curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($curl, CURLOPT_URL, $src_url);\n curl_setopt($curl, CURLOPT_REFERER, $src_url);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE);\n $str = curl_exec($curl);\n curl_close($curl);\n\n return $str;\n\n}", "title": "" }, { "docid": "8297d39c569e1c52fa79330c32670b82", "score": "0.5601545", "text": "private function doCurl($url) {\n\n // set username | password\n $userNamePassWord = $this->LOGIN.':'.$this->PASSWORD;\n $userNamePassWord64 = base64_encode($userNamePassWord);\n\n $curl = curl_init();\n curl_setopt($curl, CURLOPT_USERPWD, $userNamePassWord);\n curl_setopt($curl, CURLOPT_URL, $url);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($curl, CURLOPT_FOLLOWLOCATION, 1);\n curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, 0);\n curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, 0);\n\n $result = (curl_exec($curl));\n $result_object = json_decode($result);\n curl_close($curl);\n return $result_object;\n }", "title": "" }, { "docid": "982d10a7e32ebeeded8f6b1bdfcca87c", "score": "0.5598585", "text": "function curl($url) {\r\n $ch = curl_init(); // Initialising cURL\r\n curl_setopt($ch, CURLOPT_URL, $url); // Setting cURL's URL option with the $url variable passed into the function\r\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE); // Setting cURL's option to return the webpage data\r\n $data = curl_exec($ch); // Executing the cURL request and assigning the returned data to the $data variable\r\n curl_close($ch); // Closing cURL\r\n return $data; // Returning the data from the function\r\n }", "title": "" }, { "docid": "dfb6ae4ec4dbf4bd399eac66d20659f6", "score": "0.55947465", "text": "public function splitUrl(){\n\n /* Check if the url parameter in the query string is set */\n if(isset($_GET['url'])){\n\n /* Split the url in an array */\n /* Remove the '/' at the beginning / end */\n $url = trim($_GET['url']);\n /* Filter the URL to only have valid characters */\n $url = filter_var($url, FILTER_SANITIZE_URL);\n /* Splits the string */\n $url = explode('/', $url);\n\n /* Get the controller and action if set */\n $this->urlController = isset($url[0]) ? $url[0] : null;\n $this->urlAction = isset($url[1]) ? $url[1] : null;\n\n /* Put the remaining url in the parameters */\n $this->urlParameters = array_slice($url, 2);\n }\n }", "title": "" }, { "docid": "142b0a586d515fcfe82cd5fe1b705fdd", "score": "0.5594728", "text": "public function Get($_URL, $_vars = array());", "title": "" }, { "docid": "92cbb8f7c0786e52694f5433c3c8f880", "score": "0.55942875", "text": "function fetch_url($url)\n{\n\t\n\tif (empty($url))\n\t{\n\t\treturn FALSE;\n\t}\n\t\n\t$ch = curl_init(); \n\tcurl_setopt($ch, CURLOPT_URL, $url); \n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); \n\tcurl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 10); \n\t$html = curl_exec($ch);\n\tcurl_close($ch);\n\t\n\tif ($html === FALSE)\n\t{\n\t\techo curl_error($ch) . PHP_EOL;\n\t}\n\t\n\treturn $html;\n\t\n}", "title": "" }, { "docid": "250f8b393e494c27b620a519a6738a86", "score": "0.55940324", "text": "protected function curlInfos($ch)\n {\n $this->response->setCode(curl_getinfo($ch, CURLINFO_HTTP_CODE));\n\n if (($errno = curl_errno($ch)) !== 0) {\n $this->response->setErrorCode(curl_errno($ch));\n $this->response->setError(curl_error($ch));\n }\n\n $this->response->setProviderDatas(curl_getinfo($ch));\n }", "title": "" }, { "docid": "89d90f9c88c1e893cc03a95c0fb61354", "score": "0.5582401", "text": "public function parseUrl(){\n // Store get data\n $this->gets = $_GET;\n\n // Sanitize URL\n if (isset($this->gets['url'])){\n $this->url = filter_var(rtrim($this->gets['url'], '/'), FILTER_SANITIZE_URL);\n $this->urls = explode('/', $this->url);\n unset($this->gets['url']);\n }\n }", "title": "" }, { "docid": "08c9aea211f95afb82998e7310ddf4c5", "score": "0.55789924", "text": "function create_curl($url, $params = [], $headers = [])\n{\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\n curl_setopt($ch, CURLOPT_HEADER, 0);\n curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);\n curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 30);\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);\n curl_setopt($ch, CURLOPT_POST, 1);\n curl_setopt($ch, CURLOPT_POSTFIELDS, $params);\n\n //打印错误信息\n// $out_put = curl_error($ch);\n//return $out_put;\n $out_put = curl_exec($ch);\n\n return json_decode($out_put, true);\n}", "title": "" }, { "docid": "8a6845a42390669edc28e9e5bedfdecb", "score": "0.5577574", "text": "protected function setCurlOpts() {\r\n /**\r\n * CURLOPT_FORBID_REUSE \tTRUE to force the connection to explicitly close when it has finished processing, and not be pooled for reuse.\r\n * CURLOPT_FRESH_CONNECT \tTRUE to force the use of a new connection instead of a cached one.\r\n * CURLOPT_CONNECTTIMEOUT \tThe number of seconds to wait while trying to connect. Use 0 to wait indefinitely.\r\n * CURLOPT_TIMEOUT \t The maximum number of seconds to allow cURL functions to execute.\r\n */\r\n\r\n if ($this->method == \"POST\") {\r\n $url = preg_replace ( '/\\?(.*)/', '', $this->url );\r\n $data = preg_replace ( '/(.*)\\?/', '', $this->url );\r\n //set the URL of the curl request\r\n curl_setopt ( $this->curlHandle, CURLOPT_URL, $url );\r\n //set the method\r\n curl_setopt ( $this->curlHandle, CURLOPT_POST, 1 );\r\n curl_setopt ( $this->curlHandle, CURLOPT_POSTFIELDS, $data );\r\n } else {\r\n //set the URL of the curl request\r\n curl_setopt ( $this->curlHandle, CURLOPT_URL, $this->url );\r\n //set the method\r\n curl_setopt ( $this->curlHandle, CURLOPT_HTTPGET, $this->url );\r\n }\r\n\r\n\r\n //set whether to allow Header info in response\r\n curl_setopt($this->curlHandle,CURLOPT_HEADER, false);\r\n\r\n //allow to return the output as string\r\n curl_setopt($this->curlHandle,CURLOPT_RETURNTRANSFER, 1);\r\n\r\n //The maximum number of miliseconds to allow cURL functions to execute.\r\n curl_setopt($this->curlHandle,CURLOPT_TIMEOUT_MS, 360000);\r\n\r\n curl_setopt($this->curlHandle, CURLOPT_CONNECTTIMEOUT_MS, 360000);\r\n\r\n curl_setopt($this->curlHandle,CURLOPT_FORBID_REUSE, true);\r\n \r\n if($this->writeToFile == true) { //echo $this->outFile;exit;\r\n $fp = fopen($this->outFile,\"w\");\r\n curl_setopt($this->curlHandle,CURLOPT_FILE, $fp);\r\n }\r\n }", "title": "" }, { "docid": "aad492115194d1497339eba718b640f1", "score": "0.55741966", "text": "function get_fetch_url() {\r\n\tglobal $post, $plugopts;\n\t$perms=get_permalink();\n\t\r\n\t// which short url service should be used?\r\n\tif($plugopts['shorty'] == \"rims\") {\r\n\t\t$first_url = \"http://ri.ms/api-create.php?url=\".$perms;\r\n\t} elseif($plugopts['shorty'] == \"tinyarrow\") {\r\n\t\t$first_url = \"http://tinyarro.ws/api-create.php?url=\".$perms;\r\n\t} elseif($plugopts['shorty'] == \"cligs\") {\r\n\t\t$first_url = \"http://cli.gs/api/v1/cligs/create?url=\".$perms;\r\n\t} elseif($plugopts['shorty'] == \"tiny\") {\r\n\t\t$first_url = \"http://tinyurl.com/api-create.php?url=\".$perms;\r\n\t} elseif($plugopts['shorty'] == \"snip\") {\r\n\t\t$first_url = \"http://snipr.com/site/snip?&r=simple&link=\".$perms;\r\n\t} else {\r\n\t\t$first_url = \"http://e7t.us/create.php?url=\".$perms;\r\n\t}\n\t\r\n\t$fetch_url=get_post_meta($post->ID, '_damnsexybookmarks_shortUrl', true);\r\n\tif (!empty($fetch_url) && md5($perms)==get_post_meta($post->ID, '_damnsexybookmarks_permaHash', true)) {\r\n\t\t// no curl fetch neccessary.\r\n\t} else { //fetch and store\r\n\t\t// retrieve the shortened URL\r\n\t\tif (function_exists('curl_init')) {\r\n\t\t\t// Use cURL\r\n\t\t\t$ch = curl_init();\r\n\t\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\r\n\t\t\tcurl_setopt($ch, CURLOPT_URL, $first_url);\r\n\t\t\tcurl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 2);\r\n\t\t\tcurl_setopt($ch, CURLOPT_TIMEOUT, 3);\r\n\t\t\t$fetch_url = curl_exec($ch);\r\n\t\t\tcurl_close($ch);\r\n\t\t\t\r\n\t\t} elseif (function_exists('file_get_contents')) { // use file_get_contents()\r\n\t\t\t$fetch_url = file_get_contents($first_url);\r\n\t\t} else {\r\n\t\t\t$fetch_url='';\r\n\t\t}\r\n\r\n\t\tif ($fetch_url) { // remote call made and was successful\n\t\t\t$fetch_url=trim($fetch_url);\r\n\t\t\t// add/update values\r\n\t\t\t// tries updates first, then add if field does not already exist\r\n\t\t\tif (!update_post_meta($post->ID, '_damnsexybookmarks_shortUrl', $fetch_url)) {\r\n\t\t\t\tadd_post_meta($post->ID, '_damnsexybookmarks_shortUrl', $fetch_url);\r\n\t\t\t}\r\n\t\t\tif (!update_post_meta($post->ID, '_damnsexybookmarks_permaHash', md5($perms))) {\r\n\t\t\t\tadd_post_meta($post->ID, '_damnsexybookmarks_permaHash', md5($perms));\r\n\t\t\t}\r\n\t\t} else { // failed. use permalink.\r\n\t\t\t$fetch_url=$perms;\r\n\t\t}\r\n\t}\r\n\treturn $fetch_url;\r\n}", "title": "" }, { "docid": "12773d1a76f4f0d274d7ed66141500b6", "score": "0.5562874", "text": "function extractParamsAndBuildURL() {\n\n\t// accessing global vars\n\tglobal $baseUrl, $url, $api_key;\n\n\t// local vars\n\t$didGetParams = false;\n\t$origins = $_GET[\"origins\"];\n\t$destinations = $_GET[\"destinations\"];\n\t$mode = $_GET['travelMode'];\n\t$language = $_GET['responseLanguage'];\n\t$api_key = (isset($_GET['apiKey']))?$_GET['apiKey']:\"\";\n\t$type = (isset($_GET[\"responseType\"]))?$_GET[\"responseType\"]:\"json\";\n\n\t// generate URL only if required params were provided\n\tif (isset($origins) && isset($destinations) && isset($mode) && isset($language)) {\n\n\t\t// let caller know that params are ok\n\t\t$didGetParams = true;\n\n\t\t// building url based on received params\n\t\t$url = $baseUrl.$type.\"?\".\"origins=\".$origins.\"&destinations=\".$destinations.\"&language=\".$language.\"&mode=\".$mode.\"&key=\".$api_key;\n\t}\n\n\t// let caller know that params are ok\n\treturn $didGetParams;\n}", "title": "" }, { "docid": "800de700faf42b53c31204f83ccd22c1", "score": "0.555576", "text": "protected function _curl($url) {\n\t\t$timeout = 1000;\n\n\t\t$ch = curl_init();\n\t\tcurl_setopt($ch, CURLOPT_URL, $url);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($ch, CURLOPT_CONNECTTIMEOUT, $timeout);\n\n\t\tif ( isset($accepts) ) {\n\t\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, $accepts);\n\t\t}\n\n\t\t$data = curl_exec($ch);\t\t// run curl and retrieve data;\n\t\t$response = curl_getinfo( $ch );\n\n\t\tcurl_close($ch);\t//clean us curl\n\t\tif ($response['http_code'] == 301) {\n\t\t\t$ch = curl_init();\n\t\t\tcurl_setopt($ch, CURLOPT_URL, $response['redirect_url'] );\n\t\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\t\tcurl_setopt($ch, CURLOPT_CONNECTTIMEOUT, $timeout);\n\n\t\t\tif ( isset($accepts) ) {\n\t\t\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, $accepts);\n\t\t\t}\n\n\t\t\t$data = curl_exec($ch);\t// runn curl and retrieve data;\n\t\t\t$response = curl_getinfo( $ch );\n\n\t\t\tcurl_close($ch);\t//clean us curl\n\t\t}\n\n\t\tif ($data == false || $response['http_code'] != 200) {\n\t\t\tif ( $response['http_code'] != 200 ) {\n\t\t\t\tthrow new Exception('HTML Response Code: ' . $response['http_code']);\n\t\t\t} else {\n\t\t\t\tthrow new Exception(curl_error($ch));\n\t\t\t}\n\t\t}\n\t\treturn $data;\n\t}", "title": "" }, { "docid": "d42506c9ac41817b6e93665fd33fc6a4", "score": "0.5541231", "text": "public function getURL();", "title": "" }, { "docid": "d42506c9ac41817b6e93665fd33fc6a4", "score": "0.5541231", "text": "public function getURL();", "title": "" }, { "docid": "6ca44cece82acfc819163154be5bca38", "score": "0.5539675", "text": "function get_web_page( $url,$curl_data )\n{\n $options = array(\n CURLOPT_RETURNTRANSFER => true, // return web page\n CURLOPT_HEADER => false, // don't return headers\n CURLOPT_FOLLOWLOCATION => true, // follow redirects\n CURLOPT_ENCODING => \"\", // handle all encodings\n CURLOPT_USERAGENT => \"spider\", // who am i\n CURLOPT_AUTOREFERER => true, // set referer on redirect\n CURLOPT_CONNECTTIMEOUT => 120, // timeout on connect\n CURLOPT_TIMEOUT => 120, // timeout on response\n CURLOPT_MAXREDIRS => 10, // stop after 10 redirects\n CURLOPT_POST => 1, // i am sending post data\n CURLOPT_POSTFIELDS => $curl_data, // this are my post vars\n CURLOPT_SSL_VERIFYHOST => 0, // don't verify ssl\n CURLOPT_SSL_VERIFYPEER => false, //\n CURLOPT_VERBOSE => 1 //\n\n\n //CURLOPT_URL => false,\n //CURLOPT_FRESH_CONNECT => false,\n //CURLOPT_NOBODY => false,\n //CURLOPT_RETURNTRANSFER => false,\n //CURLINFO_HTTP_CODE => false,\n //CURLOPT_HTTPHEADER => array( \"Cache-Control: no-cache\" ),\n\n\n );\n\n $ch = curl_init($url);\n curl_setopt_array($ch,$options);\n $content = curl_exec($ch);\n $err = curl_errno($ch);\n $errmsg = curl_error($ch) ;\n $header = curl_getinfo($ch);\n curl_close($ch);\n\n // $header['errno'] = $err;\n // $header['errmsg'] = $errmsg;\n // $header['content'] = $content;\n return $header;\n}", "title": "" }, { "docid": "a5985bfdba953f4b3ab814d48c335e48", "score": "0.5533253", "text": "protected function getRequest($url) {\n\t\t$ch = curl_init($url);\n\t\t\n\t\t// Gotta have this! Without it the JSON is displayed immediately with no further parsing.\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);\n\t\t\n\t\t// Required authentication.\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array('SiteNumber: '.$this->auth['site_number']));\n\t\tcurl_setopt($ch, CURLOPT_USERPWD, $this->auth['username'].':'.$this->auth['password']);\n\n\t\t$result = curl_exec($ch);\n\t\tcurl_close($ch);\n\t\t\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "0fbe7f1e20a9acef0724942f4596ae2e", "score": "0.5531031", "text": "private function splitUrl()\n {\n if (isset($_GET['url'])) {\n\n // split URL\n $url = trim($_GET['url'], '/');\n $url = filter_var($url, FILTER_SANITIZE_URL);\n $url = explode('/', $url);\n\n $this->urlController = isset($url[0]) ? $url[0] : null;\n $this->urlController = substr($this->urlController, 0, -1);\n\n $this->urlAction = isset($url[1]) ? $url[1] : null;\n\n // Remove controller and action from the split URL\n unset($url[0], $url[1]);\n\n // Rebase array keys and store the URL params\n $this->urlParams = array_values($url);\n\n // Para debugar estas variáveis. descomente as linhas abaixo\n /*\n echo '<center><b>DEBUG</b><hr>';\n echo 'Controller: ' . $this->urlController . '<br>';\n echo 'Action: ' . $this->urlAction . '<br>';\n echo 'Parameters: ' . print_r($this->urlParams, true) . '<br>';\n die();\n */\n }\n }", "title": "" }, { "docid": "80d4fa3ba0945c1d75a587a13aeadc7d", "score": "0.55294716", "text": "function curl_get_result($url) {\n\t$ch = curl_init();\n\t$timeout = 5;\n\tcurl_setopt($ch,CURLOPT_URL,$url);\n\tcurl_setopt($ch,CURLOPT_RETURNTRANSFER,1);\n\tcurl_setopt($ch,CURLOPT_CONNECTTIMEOUT,$timeout);\n\t$data = curl_exec($ch);\n\tcurl_close($ch);\n\treturn $data;\n}", "title": "" }, { "docid": "dc80dfc36fe8619b6c79199b87436b9a", "score": "0.5529229", "text": "private static function _fetchTinyUrl($url) {\n\t\t$ch = curl_init();\n\t\t$timeout = 5;\n\t\tcurl_setopt($ch,CURLOPT_URL,'http://tinyurl.com/api-create.php?url='.$url);\n\t\tcurl_setopt($ch,CURLOPT_RETURNTRANSFER,1);\n\t\tcurl_setopt($ch,CURLOPT_CONNECTTIMEOUT,$timeout);\n\t\t\n\t\t\n\t\tcurl_setopt($ch,CURLOPT_ENCODING , \"gzip\");\n\t\t\n\t\t$data = curl_exec($ch);\n\t\tcurl_close($ch);\n\t\treturn $data;\n\t}", "title": "" }, { "docid": "8434874b80f21c3a34d9d0d3c040228b", "score": "0.5528677", "text": "public function getRequestUrl();", "title": "" }, { "docid": "7dc16a365f3f9d6a1d864a0996ee917d", "score": "0.55273473", "text": "function getCURL(string $url = '') : string {\n // create curl instance\n $curl = curl_init();\n curl_setopt($curl, CURLOPT_URL, $url);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);\n $output = curl_exec($curl);\n curl_close($curl);\n return $output;\n}", "title": "" }, { "docid": "83416aa98ba29e59170f57d366f12d09", "score": "0.55267966", "text": "function getUrl($url) {\n $ch = curl_init();\n curl_setopt($ch,CURLOPT_MAXCONNECTS,100);\n curl_setopt($ch,CURLOPT_CLOSEPOLICY,CURLCLOSEPOLICY_LEAST_RECENTLY_USED);\n curl_setopt($ch,CURLOPT_URL,$url);\n curl_setopt($ch,CURLOPT_MAXREDIRS,10);\n curl_setopt($ch,CURLOPT_HEADER,0);\n curl_setopt($ch,CURLOPT_RETURNTRANSFER,1);\n curl_setopt($ch,CURLOPT_TIMEOUT,30);\n curl_setopt($ch,CURLOPT_CONNECTTIMEOUT,10);\n curl_setopt($ch,CURLOPT_HTTPGET,1);\n $data = curl_exec($ch);\n curl_close($ch);\n\n return $data;\n}", "title": "" }, { "docid": "a9f5642d458143e84b4ea8894b36da14", "score": "0.5520129", "text": "function curlReturn($url) {\n\t$ch = curl_init();\n\tcurl_setopt($ch, CURLOPT_HEADER, 0);\n\tcurl_setopt($ch, CURLOPT_VERBOSE, 0);\n\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\tcurl_setopt($ch, CURLOPT_USERAGENT, \"Mozilla/4.0 (compatible;)\");\n\tcurl_setopt($ch,CURLOPT_URL, $url);\n\t$result = curl_exec($ch);\n\tcurl_close($ch);\n\treturn $result;\n}", "title": "" }, { "docid": "75aa3ae10741c51d946d673d0592ec4c", "score": "0.55193776", "text": "private function curl($url) {\n $ch = curl_init();\n //verify key\n // curl_setopt($ch, CURLOPT_HTTPHEADER, array('Authorization: AIzaSyBIVWasZ4AEs56TdYVip_wEXYzXbOwVOUo')); // send development key\n // Disable SSL verification\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n // Will return the response, if false it print the response\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n // Set the url\n curl_setopt($ch, CURLOPT_URL, $url);\n // Execute\n $result = curl_exec($ch); //echo \"<pre>\";print_r($result);exit;\n // Closing\n curl_close($ch);\n\n return $result;\n }", "title": "" }, { "docid": "f62f65d281a4e7f641b4a82f08c5a683", "score": "0.5518566", "text": "function geturl()\n {\n $url = '?';\n\n foreach($_GET as $var=>$value){\n \n $url .= $var.'='.$value.'&';\n }\n\n $trim_url = rtrim($url,'&');\n\n $url = str_replace('?','',$trim_url);\n\n //parse string into array\n parse_str($url,$urlarray);\n\n //remove msg variable\n if(array_key_exists('msgvalid',$urlarray)==true)\n {\n unset($urlarray['msgvalid']);\n }\n elseif(array_key_exists('msgerror',$urlarray))\n {\n unset($urlarray['msgerror']);\n }\n elseif(array_key_exists('order',$urlarray))\n {\n unset($urlarray['order']);\n }\n elseif(array_key_exists('pageno',$urlarray))\n {\n unset($urlarray['pageno']);\n }\n elseif(array_key_exists('task',$urlarray))\n {\n unset($urlarray['task']);\n }\n\n $rawUrl = '?'.$this->buildurl($urlarray);\n\n //an amp; is added into the url so toa hiyo\n return $currentUrl = str_replace('amp;','',$rawUrl);\n }", "title": "" }, { "docid": "0e202ca5ec02cc5730b6dba90cb643f0", "score": "0.5509433", "text": "abstract protected static function _url();", "title": "" }, { "docid": "16d2c12037811336cf0502faa395b0f5", "score": "0.55071265", "text": "public function fetchURL($url, $param)\n {\n $return = [];\n\n $ch = curl_init();\n\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($ch, CURLOPT_TIMEOUT, 0);\n curl_setopt($ch, CURLOPT_FORBID_REUSE, 1);\n curl_setopt($ch, CURLOPT_FRESH_CONNECT, 1);\n curl_setopt($ch, CURLOPT_HEADER, 1);\n curl_setopt($ch, CURLOPT_URL, $url);\n if (! empty($param)) {\n if (! empty($param['Header'])) {\n curl_setopt($ch, CURLOPT_HTTPHEADER, $param['Header']);\n }\n if (! empty($param['Post'])) {\n curl_setopt($ch, CURLOPT_POSTFIELDS, $param['Post']);\n }\n }\n\n if (! empty($this->proxyInfo)\n && ! empty($this->proxyInfo['ip'])\n && ! empty($this->proxyInfo['port'])\n ) {\n curl_setopt($ch, CURLOPT_PROXYAUTH, CURLAUTH_BASIC);\n curl_setopt($ch, CURLOPT_PROXY, $this->proxyInfo['ip']);\n curl_setopt($ch, CURLOPT_PROXYPORT, $this->proxyInfo['port']);\n if (! empty($this->proxyInfo['user_pwd'])) {\n curl_setopt($ch, CURLOPT_PROXYUSERPWD, $this->proxyInfo['user_pwd']);\n }\n curl_setopt($ch, CURLOPT_PROXYTYPE, CURLPROXY_SOCKS5);\n }\n\n $data = curl_exec($ch);\n if (curl_errno($ch)) {\n $return['ok'] = -1;\n $return['error'] = curl_error($ch);\n\n return $return;\n }\n\n if (is_numeric(strpos($data, 'HTTP/1.1 100 Continue'))) {\n $data = str_replace('HTTP/1.1 100 Continue', '', $data);\n }\n $data = preg_split(\"/\\r\\n\\r\\n/\", $data, 2, PREG_SPLIT_NO_EMPTY);\n if (! empty($data)) {\n $return['head'] = (isset($data[0]) ? $data[0] : null);\n $return['body'] = (isset($data[1]) ? $data[1] : null);\n } else {\n $return['head'] = null;\n $return['body'] = null;\n }\n\n $matches = [];\n $data = preg_match(\"/HTTP\\/[0-9.]+ ([0-9]+) (.+)\\r\\n/\", $return['head'], $matches);\n if (! empty($matches)) {\n $return['code'] = $matches[1];\n $return['answer'] = $matches[2];\n }\n\n $data = preg_match(\"/meta http-equiv=.refresh. +content=.[0-9]*;url=([^'\\\"]*)/i\", $return['body'], $matches);\n if (! empty($matches)) {\n $return['location'] = $matches[1];\n $return['code'] = '301';\n }\n\n if ($return['code'] == '200' || $return['code'] == '302') {\n $return['ok'] = 1;\n } else {\n $return['error'] = (($return['answer'] and $return['answer'] != 'OK') ? $return['answer'] : 'Something wrong!');\n $return['ok'] = 0;\n }\n\n foreach (preg_split('/\\n/', $return['head'], -1, PREG_SPLIT_NO_EMPTY) as $value) {\n $data = preg_split('/:/', $value, 2, PREG_SPLIT_NO_EMPTY);\n if (is_array($data) and isset($data['1'])) {\n $return['headarray'][$data['0']] = trim($data['1']);\n }\n }\n\n curl_close($ch);\n\n return $return;\n }", "title": "" }, { "docid": "9af8c6e96ef1ff36f167c6550337f29f", "score": "0.55062413", "text": "private function _initCurlSettings(){\n curl_setopt_array(\n $this->_curlHandler, \n array(\n CURLOPT_URL => $this->url,\n CURLOPT_USERAGENT => $this->_config['curlUserAgent'],\n CURLOPT_CONNECTTIMEOUT => $this->_config['curlConnectTimeout'],\n CURLOPT_TIMEOUT => $this->_config['curlTimeout'],\n CURLOPT_RETURNTRANSFER => $this->_config['curlReturnTransf'],\n CURLOPT_SSL_VERIFYPEER => $this->_config['curlSSLVerifyPeer'],\n CURLOPT_FOLLOWLOCATION => $this->_config['curlFollowLocation'],\n CURLOPT_PROXY => $this->_config['curlProxy'],\n CURLOPT_ENCODING => $this->_config['curlEncoding'],\n CURLOPT_HEADER => $this->_config['curlHeader'],\n CURLINFO_HEADER_OUT => $this->_config['curlHeaderOut']\n )\n );\n }", "title": "" }, { "docid": "d9052d12c88e3c1e7fb39aad00688ac8", "score": "0.55029047", "text": "private static function _getUrl()\n\t{\n\n\t\t// the method that was used to make the call\n\t\t$method = strtolower($_SERVER['REQUEST_METHOD']);\n\n\t\t// the url that was called\n\t\t$url = $_SERVER[\"REQUEST_URI\"];\n\n\t\t// split on the the question mark if there is one\n\t\t// removes the get variables\n\t\t$url = preg_split(\"/[?]/\", $url);\n\n\t\t// split on the period\n\t\t// get the extension\n\t\t$url = preg_split(\"/[.]/\", $url[0]);\n\n\t\t// set the extension to the second half of the split so that we can use it later\n\t\tself::$info_of_url['ext'] = isset($url[1])?$url[1]:'';\n\n\t\t// variable for the request that was made\n\t\t$uri = str_replace(dirname($_SERVER['SCRIPT_NAME']).\"/\",'',$url[0]);\n\n\t\t// if there is a / at the beginning\n\t\tif(strpos($uri,\"/\") === 0) $uri = substr($uri, 1);\n\n\t\t// if the uri is just a blank string use an array if it has length then break it into pieces\n\t\t$request = !empty($uri)?explode(\"/\", $uri):array(\"\");\n\n\t\t// if the uri is not in the routes\n\t\tif(!self::_checkRoutes($request, $method))\n\t\t{\n\n\t\t\t// if there is no controller\n\t\t\t// url: /\n\t\t\tif(empty($request[0]))\n\t\t\t{\n\t\t\t\tself::$info_of_url['controller'] = \"Controller_\".ucfirst(DEFAULT_CONTROLLER);\n\t\t\t}\n\t\t\t// if there is a controller\n\t\t\t// url: /controller/(action/params)/(params)\n\t\t\telse\n\t\t\t{\n\n\t\t\t\t// set the controller\n\t\t\t\tself::$info_of_url['controller'] = \"Controller_\".ucfirst($request[0]);\n\n\t\t\t\t// remove the controller from the request\n\t\t\t\tarray_shift($request);\n\n\t\t\t}\n\n\t\t\t// if there is an second value\n\t\t\tif (isset($request[0]) && (!empty($request[0]) || $request[0] === \"0\"))\n\t\t\t{\n\n\n\n\t\t\t\t// if the second request is a method\n\t\t\t\tif(method_exists(self::$info_of_url['controller'], $request[0]))\n\t\t\t\t{\n\t\t\t\t\t// set the action\n\t\t\t\t\t// url: /controller/action\n\t\t\t\t\tself::$info_of_url['action'] = $request[0];\n\n\t\t\t\t\t// remove the action from the request\n\t\t\t\t\tarray_shift($request);\n\n\t\t\t\t\t// set the params\n\t\t\t\t\t// url: /controller/action/param\n\n\t\t\t\t\tself::$info_of_url['params'] = array_merge(self::$info_of_url['params'], $request);\n\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t// set the params\n\t\t\t\t\t// url: /controller/action/param\n\t\t\t\t\tself::$info_of_url['params'] = array_merge(self::$info_of_url['params'], $request);\n\n\t\t\t\t\t// set the action\n\t\t\t\t\tself::_setAction($method);\n\t\t\t\t}\n\n\n\t\t\t}\n\t\t\t// if there is no second value\n\t\t\telse\n\t\t\t{\n\n\t\t\t\t// set the action\n\t\t\t\tself::_setAction($method);\n\n\t\t\t}\n\t\t\t// if the method doesn't exist\n\t\t\tif(!method_exists(self::$info_of_url['controller'], self::$info_of_url['action']))\n\t\t\t{\n\n\t\t\t\tforeach (self::$namespaces as $ns) {\n\t\t\t\t\tif(method_exists($ns.\"_\".self::$info_of_url['controller'], self::$info_of_url['action']))\n\t\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t\tself::error(\"404: Action: \".self::$info_of_url['action'].\" Not Found\",E_USER_ERROR);\n\t\t\t\treturn;\n\n\t\t\t}\n\n\t\t}\n\n\t\tif(DEBUG) {\n\n\t\t\tself::$debug['url'] = self::$info_of_url;\n\t\t}\n\t}", "title": "" }, { "docid": "175aa6aa09903ca2ec8c5bac5666418f", "score": "0.5501658", "text": "function get_effective_url()\n\t{\n\t\treturn curl_getinfo($this->ch, CURLINFO_EFFECTIVE_URL);\n\t}", "title": "" }, { "docid": "978f489651e104c4542d8fb439772305", "score": "0.549983", "text": "public function getCurlHandle();", "title": "" }, { "docid": "0ae6339194127f048e7eef320016aa3b", "score": "0.5488827", "text": "public function get_url() {\r\n }", "title": "" }, { "docid": "67daa0d619d9b8cdab6fb8bcdb93b455", "score": "0.5487461", "text": "function get_bitly_long_url($url,$login,$appkey,$format='txt') {\n\t\t$connectURL = 'http://api.bit.ly/v3/expand?login='.$login.'&apiKey='.$appkey.'&shortUrl='.urlencode($url).'&format='.$format;\n\t\treturn curl_get_result($connectURL);\n\t}", "title": "" } ]
8d532b2dea704a9bdef510de0a9b9b94
TODO: Implement execute() method.
[ { "docid": "85a7672fae9efec6a196d4fc3bbb137e", "score": "0.0", "text": "public function execute(array $parameters = array())\n {\n try\n {\n #Use the initialized statement to execute:\n $this->getStatement()->execute($parameters);\n return $this;\n }\n catch (\\PDOException $e)\n {\n throw new \\RuntimeException($e->getMessage());\n }\n }", "title": "" } ]
[ { "docid": "1a004dbd62759904e8408505203a5782", "score": "0.87422246", "text": "public function execute () {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8636612", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8636612", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8636612", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8636612", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8636612", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8636005", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8636005", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.86356694", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.86356694", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.86356694", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8635265", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8635265", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8635265", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8635265", "text": "public function execute() {}", "title": "" }, { "docid": "53e1c6b4284528b72c45a35aa8312fb8", "score": "0.8635265", "text": "public function execute() {}", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "d55e1f18965d363282e325ea85be49d6", "score": "0.8609109", "text": "public function execute();", "title": "" }, { "docid": "ef1bbfdf61b85a7af4a75bf715038310", "score": "0.8528816", "text": "abstract public function execute() ;", "title": "" }, { "docid": "8c3f6b2dcd92cf92b4e2526d2f0dc5b8", "score": "0.851345", "text": "protected function execute()\n {}", "title": "" }, { "docid": "f20edd409a3d2272c23b74376abaaf23", "score": "0.8510711", "text": "abstract public function execute();", "title": "" }, { "docid": "f20edd409a3d2272c23b74376abaaf23", "score": "0.8510711", "text": "abstract public function execute();", "title": "" }, { "docid": "f20edd409a3d2272c23b74376abaaf23", "score": "0.8510711", "text": "abstract public function execute();", "title": "" }, { "docid": "f20edd409a3d2272c23b74376abaaf23", "score": "0.8510711", "text": "abstract public function execute();", "title": "" }, { "docid": "f20edd409a3d2272c23b74376abaaf23", "score": "0.8510711", "text": "abstract public function execute();", "title": "" }, { "docid": "f20edd409a3d2272c23b74376abaaf23", "score": "0.8510711", "text": "abstract public function execute();", "title": "" }, { "docid": "7ffb8ecb375aa25d6e0f738ce6a08432", "score": "0.8487172", "text": "protected abstract function execute();", "title": "" }, { "docid": "4b8f377834a3aefd87bb0599d1507da7", "score": "0.8456164", "text": "public abstract function execute();", "title": "" }, { "docid": "4b8f377834a3aefd87bb0599d1507da7", "score": "0.8456164", "text": "public abstract function execute();", "title": "" }, { "docid": "da23bbee6d7fa2dd6cbc357f43286688", "score": "0.84148586", "text": "abstract protected function execute();", "title": "" }, { "docid": "c050c604062d78f85d5664d1295ef8a3", "score": "0.82995874", "text": "abstract function execute();", "title": "" }, { "docid": "c050c604062d78f85d5664d1295ef8a3", "score": "0.82995874", "text": "abstract function execute();", "title": "" }, { "docid": "8ef6c3e1d19d013d60aa032ff7a1ff40", "score": "0.8282771", "text": "protected function execute()\r\n {\r\n }", "title": "" }, { "docid": "8e1e35f0855ffff3ae4c7fd2cae31733", "score": "0.81620824", "text": "abstract protected function _execute();", "title": "" }, { "docid": "800d77629de6084d3d424016bd6cded1", "score": "0.80632585", "text": "public function execute()\n {\n }", "title": "" }, { "docid": "800d77629de6084d3d424016bd6cded1", "score": "0.80632585", "text": "public function execute()\n {\n }", "title": "" }, { "docid": "800d77629de6084d3d424016bd6cded1", "score": "0.80632585", "text": "public function execute()\n {\n }", "title": "" }, { "docid": "800d77629de6084d3d424016bd6cded1", "score": "0.80632585", "text": "public function execute()\n {\n }", "title": "" }, { "docid": "800d77629de6084d3d424016bd6cded1", "score": "0.80632585", "text": "public function execute()\n {\n }", "title": "" }, { "docid": "ec8494ff3f03066068f34ce1bae368b4", "score": "0.80616295", "text": "public function execute() {\n }", "title": "" }, { "docid": "cba034d4fb420ba221cfb8e3514cae80", "score": "0.79798836", "text": "public function execute()\n {\n \n }", "title": "" }, { "docid": "f7bf131e21e9330586f4e729b8f0ddfb", "score": "0.79202485", "text": "abstract public function execute(): void;", "title": "" }, { "docid": "0739455c899f08d0b6a56b725aead87a", "score": "0.791733", "text": "public function execute() : Result\n {\n }", "title": "" }, { "docid": "0739455c899f08d0b6a56b725aead87a", "score": "0.791733", "text": "public function execute() : Result\n {\n }", "title": "" }, { "docid": "0739455c899f08d0b6a56b725aead87a", "score": "0.791733", "text": "public function execute() : Result\n {\n }", "title": "" }, { "docid": "d33f1121aa866f65f7508d93a63a4d0f", "score": "0.7884448", "text": "public function execute()\n {\n\n }", "title": "" }, { "docid": "8c201858741bda826604c14e86b1d48c", "score": "0.7806294", "text": "protected function execute() {\n\t\treturn parent::execute();\n\t}", "title": "" }, { "docid": "bc27cfec77b4f7a41b9839023fb7a594", "score": "0.7782543", "text": "function execute()\r\n {\r\n }", "title": "" }, { "docid": "a3f2df4378571c5d361f8513ce1458ed", "score": "0.7772771", "text": "public function execute(): void;", "title": "" }, { "docid": "09837a8050ceffb7322e4327fb007521", "score": "0.7757891", "text": "function execute()\n {\n }", "title": "" }, { "docid": "1ff949c75ef4ce409f08e81d12bd0a8d", "score": "0.77565587", "text": "public abstract function doExecute();", "title": "" }, { "docid": "15b5c988cfa01e8747cc1c9ae915981a", "score": "0.7698261", "text": "protected abstract function doExecute();", "title": "" }, { "docid": "35aa500ab2e5c93576c8ca85fd527aff", "score": "0.7692926", "text": "function execute()\n\t{\n\t}", "title": "" }, { "docid": "39173e9bcb4546431e91ce6080a6aa42", "score": "0.7670245", "text": "public function execute(): void\n {\n }", "title": "" }, { "docid": "39173e9bcb4546431e91ce6080a6aa42", "score": "0.7670245", "text": "public function execute(): void\n {\n }", "title": "" }, { "docid": "b1604257b67ce17b59e7e59673fcf973", "score": "0.7633559", "text": "public function execute ()\n {\n return parent::execute();\n }", "title": "" }, { "docid": "33dae37f926e2ff6db9245bb768f0bb3", "score": "0.7456765", "text": "public function execute() \n {\n\n }", "title": "" }, { "docid": "585c844bb9ba9d0a574164fd0381f77d", "score": "0.7447685", "text": "function execute();", "title": "" }, { "docid": "585c844bb9ba9d0a574164fd0381f77d", "score": "0.7447685", "text": "function execute();", "title": "" }, { "docid": "8aa1bffcf4b23fb5b60eecfba236c24b", "score": "0.74125576", "text": "public function execute()\n\t{\n\t\treturn Database::execute($this);\n\t}", "title": "" }, { "docid": "8c27ba7811057e07f7d3950ba9500af9", "score": "0.73972386", "text": "public function executeCommand();", "title": "" }, { "docid": "0db497f7e5de3770f8efe6c728bc765b", "score": "0.7358094", "text": "abstract protected function executeInternal() ;", "title": "" }, { "docid": "dde12ed55fda97095ec17b8c807f17da", "score": "0.7184433", "text": "public function execute() : int {}", "title": "" }, { "docid": "dde12ed55fda97095ec17b8c807f17da", "score": "0.7182781", "text": "public function execute() : int {}", "title": "" }, { "docid": "ebd27f65054ebd4acd1e99122516f655", "score": "0.7156338", "text": "public function execute() : bool {}", "title": "" }, { "docid": "b64b9cdd0544ce9545950d24059b2c75", "score": "0.7112627", "text": "public function execute(){\n\t\tif($this->executed) return;\n\n\t\t$this->getQuery();\n\t\tparent::execute();\n\n\t}", "title": "" }, { "docid": "03fe49128cdbd52105f414636a336016", "score": "0.7062048", "text": "public function execute() {\t\n\t\tif ($this->queryType !== 'delete' && $this->queryType !== 'update') {\n\t\t\tthrow new Exception(\"Fetch only works on select queries!\");\n\t\t}\t\t\n\t\t$link = Database::getConnection();\n\t\tlist($query, $params) = $this->buildQuery();\n\t\t$stmt = $link->prepare($query);\n\t\treturn $stmt->execute($params);\n\t}", "title": "" }, { "docid": "47ab29aebde98c6fea9d084521535045", "score": "0.70497453", "text": "public function execute($data);", "title": "" }, { "docid": "d4206812563b2137e1e5da46a909b559", "score": "0.7048673", "text": "function execute() {\n return 1;\n }", "title": "" }, { "docid": "c11a9f0b2e5f7dbad779c671998d75f9", "score": "0.7016401", "text": "public function execute() : DbResultInterface;", "title": "" }, { "docid": "1c21aa7e0cc21a88f52235f126d842ff", "score": "0.70044726", "text": "public function execute() {\r\n return $this->connection->query((string) $this, array(), $this->queryOptions);\r\n }", "title": "" }, { "docid": "220d66b228fbd58acf79f94387970f83", "score": "0.7001726", "text": "abstract protected function exec();", "title": "" }, { "docid": "5d3ff8822378d0744f429f1ec41ac6ef", "score": "0.69660425", "text": "public function execute() {\n\t\treturn $this->dataMapper->mapToObjects($this->persistenceManager->getBackend()->getObjectDataByQuery($this));\n\t}", "title": "" }, { "docid": "105bc022e11f50818368eeb8b7e6109f", "score": "0.6926033", "text": "public function beginExecute()\n {}", "title": "" }, { "docid": "4b404b8840551b3fbb67eb3bdb31d3fd", "score": "0.6921449", "text": "public function execute() : RowResult\n {\n }", "title": "" }, { "docid": "e0a00254143b39513313393d9e3ee65e", "score": "0.689828", "text": "public function execute() {\r\n $values = array();\r\n if (count($this->condition)) {\r\n $this->condition->compile($this->connection, $this);\r\n $values = $this->condition->arguments();\r\n }\r\n \r\n return $this->connection->query((string) $this, $values, $this->queryOptions);\r\n }", "title": "" }, { "docid": "7f9642039bb5b4faed2f457979b0b60c", "score": "0.68912894", "text": "public function executeAll();", "title": "" }, { "docid": "f9eb33f0db0a2d0160b180047049a697", "score": "0.6883232", "text": "public function execQuery();", "title": "" }, { "docid": "0cc555b8fb389c22db69de8093af39fe", "score": "0.685625", "text": "public function exec()\n {\n }", "title": "" }, { "docid": "0cc555b8fb389c22db69de8093af39fe", "score": "0.685625", "text": "public function exec()\n {\n }", "title": "" }, { "docid": "93637ce501044ce7a6385e62c83d4c5e", "score": "0.6851938", "text": "public function execute()\n\t{\n\t\t$result = $this->query($this->buildQuery($this->type));\n\n\t\t// Clear elements\n\t\t$this->reset();\n\n\t\t// Return result of the query\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "1e706e8dc2739c8a31af5c9f40c2266b", "score": "0.6841672", "text": "public function execute(){\n\t\t$this->stmt->execute();\n\t}", "title": "" }, { "docid": "818507bdfadacf009845bc17461ff117", "score": "0.6797532", "text": "public function exec() \n {\n \n }", "title": "" }, { "docid": "18355d6339ee5fd55726485774e3e33c", "score": "0.67950493", "text": "public function exec();", "title": "" }, { "docid": "417748c311eb6713f84538e9881658ec", "score": "0.6794571", "text": "function execute()\n {\n if (!$this->pNativeClass->execute()) {\n $this->_throwError();\n }\n $this->_checkWarning();\n }", "title": "" }, { "docid": "ce1f9c5d3b97cb85eadfedba6ec43fd7", "score": "0.6791252", "text": "public function execute() : bool;", "title": "" }, { "docid": "aa64689a7ce53686505c1f524de9bec6", "score": "0.67612195", "text": "abstract protected function doExecuteQuery() : bool;", "title": "" } ]
87b823f331a432ea93e93261e153bd10
Init plugin options to white list our options
[ { "docid": "f361d86d288fa22358a26734dc7f0d6d", "score": "0.0", "text": "function ct_podcast_settings_init(){\n\tregister_setting( 'ct_podcast', 'ct_podcast_settings', 'ct_podcast_settings_validate' );\n}", "title": "" } ]
[ { "docid": "5e1e7724eb6ba57fafd8536842133270", "score": "0.8212031", "text": "protected function initOptions()\n\t{\n\t\n\t}", "title": "" }, { "docid": "0321829d08c18775c38fed77a5f1f26d", "score": "0.8131684", "text": "public function init()\n {\n $this->getPluginOptions();\n }", "title": "" }, { "docid": "f307d31f318111c2f781ae827e83e0fb", "score": "0.7994396", "text": "private function _init_options() {\n\t\t$defaults = array( 'api_token' => '', 'api_version' => '3.0', 'debug' => '1', 'pause_polling' => '0', 'curatedby' => '1' );\n\t\t$options = get_option( $this->option_name );\n\t\tif ( ! isset( $options ) || ! is_array( $options ) ) {\n\t\t\t$options = array ();\n\t\t}\n\t\t$this->_options = $options + $defaults;\n\t}", "title": "" }, { "docid": "e64b293172f181bd069ac121b1d0cde9", "score": "0.78120255", "text": "protected function initPluginOptions() {\n\t\treturn false;\n\t}", "title": "" }, { "docid": "3b9cd0fb05873a026a93613cc6994d18", "score": "0.76533526", "text": "public function init()\n {\n $pfx = $this->custom_plugin_data->plugin_settings_prefix;\n register_setting($pfx . '_plugin_options', $pfx . '_options', array(&$this, 'validate_options'));\n }", "title": "" }, { "docid": "5b8f7c63eb43360cea2532ca6ecee023", "score": "0.7532678", "text": "public function init() {\n\t\t\t$this->_default_options();\n\t\t}", "title": "" }, { "docid": "862ab1cedf1978da5cf9e0a1669a1d9f", "score": "0.7481009", "text": "public function init()\n { \n $defaults = array(\n 'name' => '',\n 'class' => 'widefat',\n 'description' => '',\n );\n $this->options = array_merge($defaults, (array) $this->options);\n }", "title": "" }, { "docid": "a18ddc62b67576178e77d446ac067add", "score": "0.74670243", "text": "protected function initOptions() {\n\n\t\t$isAdmin = is_admin();\n\n\t\tif ( $isAdmin ) {\n\t\t\t$this->getOption( self::OPTION_NAME_PLUGIN_VERSION );\n\t\t}\n\n\t\t// These options are always available\n\t\t$coreOptions = array(\n\t\t\tself::OPTION_NAME_MODE,\n\t\t\tself::OPTION_NAME_BUSINESS_MODEL,\n\t\t\tself::OPTION_NAME_USER_PROVIDER,\n\t\t\tself::OPTION_NAME_FEATURES,\n\t\t\tself::OPTION_NAME_APP_ID,\n\t\t\tself::OPTION_NAME_API_TOKEN,\n\t\t\tself::OPTION_NAME_PRIVATE_KEY,\n\t\t\tself::OPTION_NAME_DISABLED_FOR_PRIVILEGED,\n\t\t\tself::OPTION_NAME_TRUNCATION_MODE,\n\t\t\tself::OPTION_NAME_FIRST_CLICK_MODE,\n\t\t\tself::OPTION_NAME_DEBUG,\n\t\t\tself::OPTION_NAME_ENABLE_PREMIUM_TAG,\n\t\t\tself::OPTION_NAME_DISPLAY_MODE\n\t\t);\n\n\t\t// Load these options\n\t\tforeach ( $coreOptions as $option ) {\n\t\t\t$this->getOption( $option );\n\t\t}\n\n\t\t$businessModelOptions = array();\n\t\tif ( TinypassConfig::BUSINESS_MODEL_METERED === self::$business_model ) {\n\t\t\t// Load options for metered paywall\n\t\t\t$businessModelOptions = array(\n\t\t\t\tself::OPTION_NAME_PAYWALL_ID,\n\t\t\t\tself::OPTION_NAME_PAYWALL_OFFER_ID,\n\t\t\t\tself::OPTION_NAME_PAYWALL_TEMPLATE_ID,\n\t\t\t\tself::OPTION_NAME_METER_HOME_PAGE,\n\t\t\t);\n\t\t} elseif ( TinypassConfig::BUSINESS_MODEL_SUBSCRIPTION === self::$business_model ) {\n\t\t\t// Load options for hard paywall\n\t\t\t$businessModelOptions = array(\n\t\t\t\tself::OPTION_NAME_OFFER_ID,\n\t\t\t\tself::OPTION_NAME_OFFER_SET,\n\t\t\t\tself::OPTION_NAME_RESOURCES,\n\t\t\t\tself::OPTION_NAME_ENABLE_PPP,\n\t\t\t);\n\t\t}\n\n\t\t// Load options for the selected business model\n\t\tforeach ( $businessModelOptions as $option ) {\n\t\t\t$this->getOption( $option );\n\t\t}\n\n\t\tif ( $isAdmin ) {\n\t\t\t// Default access settings are only used in backend\n\t\t\t$this->getOption( self::OPTION_NAME_DEFAULT_ACCESS_SETTINGS );\n\t\t}\n\n\t\tif ( $isAdmin || ( TinypassConfig::MODE_CUSTOM === $this::$mode ) ) {\n\t\t\t// Dedicated environment url in frontend is only required when the mode is set to \"dedicated\"\n\t\t\t$this->getOption( self::OPTION_NAME_DEDICATED_ENVIRONMENT );\n\t\t}\n\n\t\tif ( $isAdmin || ( self::TRUNCATION_MODE_PARAGRAPHED === self::$truncation_mode ) ) {\n\t\t\t// Paragraphs count value in frontend is only required when truncation mode is set to \"paragraphed\"\n\t\t\t$this->getOption( self::OPTION_NAME_PARAGRAPHS_COUNT );\n\t\t}\n\n\t\tif ( $isAdmin || ( in_array( self::$first_click_mode, array( TinypassConfig::FIRST_CLICK_OPTION_EXCLUDE, TinypassConfig::FIRST_CLICK_OPTION_EXCLUDE ) ) ) ) {\n\t\t\t// Referrers for first click in frontend are only required when first click mode is set to \"include\" or \"exclude\n\t\t\t$this->getOption( self::OPTION_NAME_FIRST_CLICK_REFERRERS );\n\t\t}\n\n\t\tif ( is_array( self::$offer_set ) ) {\n\t\t\tself::$offer_id = isset( self::$offer_set[ self::$mode ] ) ? self::$offer_set[ self::$mode ] : null;\n\t\t} else {\n\t\t\tself::$offer_set = array();\n\t\t}\n\t}", "title": "" }, { "docid": "33df04365f1773560a6167546f075013", "score": "0.74265146", "text": "protected function initOptions()\n {\n $this->options = array_merge([\n 'class' => 'panel panel-default',\n ], $this->options);\n }", "title": "" }, { "docid": "7c84d4a8aea1f40cd942b0c66b6267e0", "score": "0.7405625", "text": "public function init_options() {\r\n\t\tregister_setting( 'kstats_admin_options', 'kstats_options', array( $this, 'validate_options' ) );\r\n\t}", "title": "" }, { "docid": "159a9d8af4650c71d21a039e56fc1603", "score": "0.7390392", "text": "public function initPlugin() {\n parent::initPlugin();\n\n $this->config->setDefault('antiwrongguid', 'enabled', false);\n $this->config->setDefault('antiwrongguid', 'mode', 'kick');\n $this->config->setDefault('antiwrongguid', 'reasonempty', 'Server detected empty GUID');\n $this->config->setDefault('antiwrongguid', 'reasonmulti', 'Multiple Key');\n }", "title": "" }, { "docid": "e2245057858d7aeb28b0e105f79f6533", "score": "0.73126876", "text": "public function __construct() {\n\t\t$this->options = $this->get_options();\n\t}", "title": "" }, { "docid": "9ec40146b7a7f1b863117b9ab68c4af1", "score": "0.7254879", "text": "public function init ($options = array())\n {\n }", "title": "" }, { "docid": "6647989d6d53b338b28bac148f8ae198", "score": "0.72390234", "text": "public function init($options_): void {\n }", "title": "" }, { "docid": "768d52c4fd9f74d66803a9841112afb6", "score": "0.7202433", "text": "private function ac_initialize_options(){\n\n //database version -----------------------------------------------------\n add_option( $this->shared->get('slug') . \"_database_version\",\"0\");\n \n //AIL ------------------------------------------------------------------\n add_option( $this->shared->get('slug') . '_default_open_new_tab', \"0\");\n\t add_option( $this->shared->get('slug') . '_default_use_nofollow', \"0\");\n\t add_option( $this->shared->get('slug') . '_default_activate_post_types', \"post, page\");\n\t add_option( $this->shared->get('slug') . '_default_case_insensitive_search', \"0\");\n\t add_option( $this->shared->get('slug') . '_default_string_before', \"1\");\n\t add_option( $this->shared->get('slug') . '_default_string_after', \"1\");\n add_option( $this->shared->get('slug') . '_default_max_number_autolinks_per_keyword', \"100\");\n add_option( $this->shared->get('slug') . '_default_priority', \"0\");\n \n //suggestions\n add_option( $this->shared->get('slug') . '_suggestions_pool_post_types', \"post, page\");\n add_option( $this->shared->get('slug') . '_suggestions_pool_size', 50);\n add_option( $this->shared->get('slug') . '_suggestions_titles', \"consider\");\n add_option( $this->shared->get('slug') . '_suggestions_categories', \"consider\");\n add_option( $this->shared->get('slug') . '_suggestions_tags', \"consider\");\n add_option( $this->shared->get('slug') . '_suggestions_post_type', \"consider\");\n \n //optimization ---------------------------------------------------------\n add_option( $this->shared->get('slug') . '_optimization_num_of_characters', 1000);\n add_option( $this->shared->get('slug') . '_optimization_delta', 2);\n \n //juice ----------------------------------------------------------------\n add_option( $this->shared->get('slug') . '_default_seo_power', 1000);\n add_option( $this->shared->get('slug') . '_penality_per_position_percentage', '1');\n add_option( $this->shared->get('slug') . '_remove_link_to_anchor', \"1\");\n add_option( $this->shared->get('slug') . '_remove_url_parameters', \"0\");\n \n //tracking -------------------------------------------------------------\n add_option( $this->shared->get('slug') . '_track_internal_links', \"1\");\n \n //analysis ----------------------------------------------------------\n add_option( $this->shared->get('slug') . '_set_max_execution_time', \"1\");\n add_option( $this->shared->get('slug') . '_max_execution_time_value', \"300\");\n add_option( $this->shared->get('slug') . '_set_memory_limit', \"0\");\n add_option( $this->shared->get('slug') . '_memory_limit_value', \"512\");\n add_option( $this->shared->get('slug') . '_limit_posts_analysis', \"1000\");\n add_option( $this->shared->get('slug') . '_dashboard_post_types', \"post, page\");\n add_option( $this->shared->get('slug') . '_juice_post_types', \"post, page\");\n \n //meta boxes -----------------------------------------------------------\n add_option( $this->shared->get('slug') . '_interlinks_options_post_types', \"post, page\");\n add_option( $this->shared->get('slug') . '_interlinks_optimization_post_types', \"post, page\");\n add_option( $this->shared->get('slug') . '_interlinks_suggestions_post_types', \"post, page\");\n \n //capabilities ----------------------------------------------------------\n add_option( $this->shared->get('slug') . '_dashboard_menu_required_capability', \"edit_others_posts\");\n add_option( $this->shared->get('slug') . '_juice_menu_required_capability', \"edit_others_posts\");\n add_option( $this->shared->get('slug') . '_hits_menu_required_capability', \"edit_others_posts\");\n add_option( $this->shared->get('slug') . '_ail_menu_required_capability', \"edit_others_posts\");\n add_option( $this->shared->get('slug') . '_interlinks_options_mb_required_capability', \"edit_others_posts\");\n add_option( $this->shared->get('slug') . '_interlinks_optimization_mb_required_capability', \"edit_posts\");\n add_option( $this->shared->get('slug') . '_interlinks_suggestions_mb_required_capability', \"edit_posts\");\n\n //Advanced\n add_option( $this->shared->get('slug') . '_default_enable_ail_on_post', \"1\");\n add_option( $this->shared->get('slug') . '_filter_priority', \"1\");\n\t add_option( $this->shared->get('slug') . '_ail_test_mode', \"0\");\n\t add_option( $this->shared->get('slug') . '_random_prioritization', \"0\");\n\t add_option( $this->shared->get('slug') . '_ignore_self_ail', \"1\");\n\t add_option( $this->shared->get('slug') . '_general_limit_mode', \"1\");\n\t add_option( $this->shared->get('slug') . '_characters_per_autolink', \"200\");\n\t add_option( $this->shared->get('slug') . '_max_number_autolinks_per_post', \"100\");\n\t add_option( $this->shared->get('slug') . '_same_url_limit', \"100\");\n\n //By default the following HTML tags are protected:\n\t $protected_tags = array(\n\t\t 'h1',\n\t\t 'h2',\n\t\t 'h3',\n\t\t 'h4',\n\t\t 'h5',\n\t\t 'h6',\n\t\t 'a',\n\t\t 'img',\n\t\t 'ul',\n\t\t 'ol',\n\t\t 'span',\n\t\t 'pre',\n\t\t 'code',\n\t\t 'table',\n\t\t 'iframe',\n\t\t 'script'\n\t );\n\t add_option($this->shared->get('slug') . '_protected_tags', $protected_tags);\n\n\t /*\n * By default all the Gutenberg Blocks except the following are protected:\n *\n * - Paragraph\n * - List\n * - Text Columns\n */\n\t $default_protected_gutenberg_blocks = array(\n\t\t //'paragraph',\n\t\t 'image',\n\t\t 'heading',\n\t\t 'gallery',\n\t\t //'list',\n\t\t 'quote',\n\t\t 'audio',\n\t\t 'cover-image',\n\t\t 'subhead',\n\t\t 'video',\n\t\t 'code',\n\t\t 'html',\n\t\t 'preformatted',\n\t\t 'pullquote',\n\t\t 'table',\n\t\t 'verse',\n\t\t 'button',\n\t\t 'columns',\n\t\t 'more',\n\t\t 'nextpage',\n\t\t 'separator',\n\t\t 'spacer',\n\t\t //'text-columns',\n\t\t 'shortcode',\n\t\t 'categories',\n\t\t 'latest-posts',\n\t\t 'embed',\n\t\t 'core-embed/twitter',\n\t\t 'core-embed/youtube',\n\t\t 'core-embed/facebook',\n\t\t 'core-embed/instagram',\n\t\t 'core-embed/wordpress',\n\t\t 'core-embed/soundcloud',\n\t\t 'core-embed/spotify',\n\t\t 'core-embed/flickr',\n\t\t 'core-embed/vimeo',\n\t\t 'core-embed/animoto',\n\t\t 'core-embed/cloudup',\n\t\t 'core-embed/collegehumor',\n\t\t 'core-embed/dailymotion',\n\t\t 'core-embed/funnyordie',\n\t\t 'core-embed/hulu',\n\t\t 'core-embed/imgur',\n\t\t 'core-embed/issuu',\n\t\t 'core-embed/kickstarter',\n\t\t 'core-embed/meetup-com',\n\t\t 'core-embed/mixcloud',\n\t\t 'core-embed/photobucket',\n\t\t 'core-embed/polldaddy',\n\t\t 'core-embed/reddit',\n\t\t 'core-embed/reverbnation',\n\t\t 'core-embed/screencast',\n\t\t 'core-embed/scribd',\n\t\t 'core-embed/slideshare',\n\t\t 'core-embed/smugmug',\n\t\t 'core-embed/speaker',\n\t\t 'core-embed/ted',\n\t\t 'core-embed/tumblr',\n\t\t 'core-embed/videopress',\n\t\t 'core-embed/wordpress-tv'\n\t );\n\t add_option($this->shared->get('slug') . '_protected_gutenberg_blocks',\n\t\t $default_protected_gutenberg_blocks);\n\t add_option($this->shared->get('slug') . '_protected_gutenberg_custom_blocks', '');\n\t add_option($this->shared->get('slug') . '_protected_gutenberg_custom_void_blocks', '');\n\t add_option( $this->shared->get('slug') . '_pagination_dashboard_menu', \"10\");\n\t add_option( $this->shared->get('slug') . '_pagination_juice_menu', \"10\");\n\t add_option( $this->shared->get('slug') . '_pagination_hits_menu', \"10\");\n\t add_option( $this->shared->get('slug') . '_pagination_ail_menu', \"10\");\n\n }", "title": "" }, { "docid": "cb8d00c57048f462d2dfe59e1f68055f", "score": "0.71989655", "text": "function fi_init() {\n\tregister_setting('fi_plugin_options', 'fi_options', 'fi_validate_options');\n}", "title": "" }, { "docid": "a2e92fa54a4492844f46567c5965f8e7", "score": "0.71936274", "text": "function pipjqui_initialize_options() {\n $foo = pipjqui_get_option_as_boolean( 'pipjqui_cdn', false );\n $foo = pipjqui_get_option_as_boolean( 'pipjqui_sri' );\n $foo = pipjqui_get_option_as_boolean( 'pipjqui_demo', false );\n $foo = pipjqui_get_cdnhost_option();\n $foo = pipjqui_get_default_theme_option();\n $test = get_option( 'pipjqui_plugin_version' );\n if ( ( is_bool ($test) ) && ( ! $test ) ) {\n add_option( 'pipjqui_plugin_version', PIPJQUI_PLUGIN_VERSION );\n } else {\n update_option( 'pipjqui_plugin_version', PIPJQUI_PLUGIN_VERSION );\n }\n $test = get_option( 'pipjqui_jquery_ui_version' );\n if ( ( is_bool ($test) ) && ( ! $test ) ) {\n add_option( 'pipjqui_jquery_ui_version', PIPJQUIV );\n } else {\n update_option( 'pipjqui_jquery_ui_version', PIPJQUIV );\n }\n}", "title": "" }, { "docid": "c52cf950b00c8a79273a470718b4cf85", "score": "0.71729666", "text": "function vilab_optoptions_init(){\n\tregister_setting( 'vilab_optoptions_options', 'vilab_opt', 'vilab_optoptions_validate' );\n}", "title": "" }, { "docid": "faca89311e8c7a7902a25f076fadd35f", "score": "0.7134107", "text": "protected function initOptions()\n {\n if (!isset($this->options['id'])) {\n $this->options['id'] = $this->getId();\n }\n }", "title": "" }, { "docid": "c88cf4c82526e8f3310b3252a889967d", "score": "0.71035755", "text": "public function __construct()\n {\n $this->options = $this->defaults;\n }", "title": "" }, { "docid": "7a748649acc40d92bc20acc67dc94f42", "score": "0.7085847", "text": "public function init()\n {\n global $wordpress_store_locator_options;\n\n if(!is_admin() || !current_user_can('administrator') || (defined('DOING_AJAX') && DOING_AJAX)){\n $wordpress_store_locator_options = get_option('wordpress_store_locator_options');\n }\n\n $tmp = array();\n if(isset($wordpress_store_locator_options['showCustomFields']) && is_array($wordpress_store_locator_options['showCustomFields'])) {\n $customFields = array_filter( $wordpress_store_locator_options['showCustomFields'] );\n if(!empty($customFields)) {\n foreach ($customFields as $customField) {\n $tmp[ $this->slugify($customField) ] = esc_html($customField);\n }\n }\n }\n $wordpress_store_locator_options['showCustomFields'] = $tmp;\n\n $this->options = $wordpress_store_locator_options;\n }", "title": "" }, { "docid": "c1ab542840a834a8b71e1d2a78c40b9d", "score": "0.7082289", "text": "public function options(){}", "title": "" }, { "docid": "872699750468f14e932863b979d896ff", "score": "0.7057274", "text": "protected function initOptions()\n {\n if (!isset($this->options['id'])) {\n $this->options['id'] = 'video-' . $this->getId();\n }\n if (!isset($this->options['class'])) {\n $this->options['class'] = 'video-js vjs-default-skin vjs-big-play-centered';\n }\n }", "title": "" }, { "docid": "9e7aaeed224b5b8d832c52fd94a855ee", "score": "0.69999236", "text": "function include_custom_options_init() {\r\n\tregister_setting(\r\n\t\t'icf_options_grp',\r\n\t\t'icf_options'\r\n\t);\r\n}", "title": "" }, { "docid": "d385699ea84fe70eae4e41c5bf06fb49", "score": "0.69952846", "text": "protected function readyAllPluginOptions() {\n\t\t$this->initPluginOptions();\n\t\t$this->populateAllPluginOptions();\n\t}", "title": "" }, { "docid": "d6a0cebae2eadf23b2e49bbb97a79965", "score": "0.69529915", "text": "function __construct() {\r\n\t\t$shared_google_api_key = get_option ( 'google_api_key' );\r\n\t\tif ( $shared_google_api_key ) {\r\n\t\t\t$this->default_options['overall']['google_key'] = $shared_google_api_key;\r\n\t\t}\r\n\t\t$this->options = $this->default_options;\r\n\t\t$settings = get_option ( 'geo_mashup_options' );\r\n\t\tif ( is_array ( $settings ) ) {\r\n\t\t\t$settings = $this->convert_old_settings ( $settings );\r\n\t\t\t$this->options = $this->valid_options ( $settings, $this->default_options, $add_missing = true );\r\n\t\t} else {\r\n\t\t\t$failed_options = $settings;\r\n\t\t\tif ( is_string ( $settings ) && !empty ( $settings ) ) {\r\n\t\t\t\t$this->corrupt_options = $settings;\r\n\t\t\t}\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "d32b03665f80616f0c3222fddf7a8fcc", "score": "0.6945679", "text": "function ssrch_initCode() {\r\n \t$plugin = plugin_basename(__FILE__);\r\n\t\t$this->options = wp_parse_args(get_option('ssrch_options'), $this->defaults);\r\n\r\n add_filter('posts_orderby', array( $this, 'ssrch_posts_orderby' ));\r\n add_filter('posts_fields', array( $this, 'ssrch_posts_fields' ));\r\n\t\tadd_filter(\"plugin_action_links_$plugin\", array( $this, 'settings_link' ));\r\n add_filter('plugin_row_meta', array( $this, 'plugin_meta_links' ), 10, 2 );\r\n\r\n if ($this->options['highlight']) {\r\n add_filter('the_title', array( $this, 'ssrch_filter_the_title' ));\r\n }\r\n if ($this->options['custom-excerpt']) {\r\n add_filter('get_the_excerpt', array($this, 'ssrch_filter_the_excerpt'));\r\n }\r\n }", "title": "" }, { "docid": "7a806bc7b2d80cd9be2914760eea205d", "score": "0.6942194", "text": "protected function initialization()\n {\n $this->name = 'settings';\n $this->hook = DIVIROIDS_PLUGIN_HOOK . '_' . $this->name;\n $this->slug = DIVIROIDS_PLUGIN_SLUG . '-' . $this->name;\n $this->settings_prefix_name = $this->slug;\n $this->acceptable_options = array('switch', 'switches', 'checkbox', 'checkboxes', 'select', 'select_multiple', 'text', 'textarea', 'password' );\n\n $this->load_settings();\n }", "title": "" }, { "docid": "724bdc72d7f168326edc754b7aee8ef7", "score": "0.68793947", "text": "protected function initOptions() {\r\n\t\t// get options file name\r\n\t\t$optionsFile = $this->getOptionsFilename();\r\n\t\t\r\n\t\t// create options file if doesn't exist\r\n\t\tif (!file_exists($optionsFile) || filemtime($optionsFile) <= 1) {\r\n\t\t\t\\wcf\\data\\option\\OptionEditor::rebuildFile($optionsFile);\r\n\t\t}\r\n\t\trequire_once($optionsFile);\r\n\t}", "title": "" }, { "docid": "f72bd2d1db4a6460940c0911baa46918", "score": "0.6851132", "text": "function init () {\r\n\r\n\t\t\t\t$this->getAdminOptions();\r\n\t\t\t}", "title": "" }, { "docid": "1f34080e0a026b1db6ccb5a709df35f0", "score": "0.6850806", "text": "protected function _init()\n {\n foreach ($this->_options AS $name => $value) {\n switch ($name) {\n case 'path':\n $this->setPath($value);\n break;\n }\n }\n }", "title": "" }, { "docid": "6d3ebfbdbcacb33c9df52cfcd0048f75", "score": "0.68378824", "text": "function __construct(){\n\t//$this->setOptions();\n\n\n}", "title": "" }, { "docid": "177a8fab318d657dd2da0f3b71a26374", "score": "0.68325895", "text": "protected function setup_plugin_config() {\n $this->site_id = $this->get_option( self::OP_SID );\n $this->mode_cache= (bool) $this->get_option( self::OP_CACHE );\n $this->exclude_users = $this->split_option( self::OP_EXC_USER );\n\n if (!$this->site_id && defined(strtoupper(self::DB_PREFIX . 'site_id'))) {\n $this->site_id = constant(strtoupper(self::DB_PREFIX . 'site_id'));\n }\n }", "title": "" }, { "docid": "a11c060b75745dcc99db73c0733f006f", "score": "0.68192476", "text": "protected function initOptions()\n {\n $this->fetchContentPage();\n \n parent::initOptions();\n \n $this->matchRequestVariables['name'] = $this->simplePageName;\n }", "title": "" }, { "docid": "f015589859a9adec507ab63c92b5bcdf", "score": "0.6816804", "text": "function get_options()\n {\n // don't forget to set up the default options\n if ( ! $the_options = get_option( $this->options_name) ) {\n $the_options = array(\n 'version' => '3.0',\n 'icons' => $this->get_default_icons(),\n 'css' => '',\n 'sprite' => ''\n );\n update_option($this->options_name, $the_options);\n }\n $this->options = $the_options;\n }", "title": "" }, { "docid": "debeb9662a4ef3a54baa989b74afe1e5", "score": "0.68048793", "text": "protected function options()\n {\n }", "title": "" }, { "docid": "e88dadc78ed2fb0da0f9f0f4ec48bc00", "score": "0.679328", "text": "public function init_plugin() {\n\n\t\t// stub\n\t}", "title": "" }, { "docid": "bca9fade1476de141ce45888725945ce", "score": "0.67899823", "text": "public static function init()\n {\n $version = get_option( MOBILE_CONTACT_BAR__NAME . '_version' );\n\n if( version_compare( $version, MOBILE_CONTACT_BAR__VERSION, '<' ))\n {\n $default_option = self::default_option();\n self::update_plugin_options( $default_option );\n }\n }", "title": "" }, { "docid": "8e3c525e7da0238f71580bebacbb87ff", "score": "0.67892087", "text": "protected function initOptions()\n\t{\n\t\t$this->options = array_merge(array(\n\t\t\t'class' => 'fade in',\n\t\t), $this->options);\n\n\t\t$this->addCssClass($this->options, 'alert');\n\n\t\tif ($this->closeButton !== null) {\n\t\t\t$this->closeButton = array_merge(array(\n\t\t\t\t'data-dismiss' => 'alert',\n\t\t\t\t'aria-hidden' => 'true',\n\t\t\t\t'class' => 'close',\n\t\t\t), $this->closeButton);\n\t\t}\n\t}", "title": "" }, { "docid": "541ed89a56b2a22ce59d5ebec326b158", "score": "0.6753422", "text": "protected function configureOptions()\n {\n }", "title": "" }, { "docid": "a00bd78bc02fcf4b8c94c9220f6796c1", "score": "0.6734684", "text": "public function __construct() {\n\t\t$this->onpage_option = $this->get_option();\n\t}", "title": "" }, { "docid": "6377e808498466c054d516d50c6dc0c2", "score": "0.67324966", "text": "function setOptions($options=[]) {\n\t\t$this->live_options = array_merge($this->live_options, $options);\n\n\t\t$options = array_merge( $this->default_options, $this->generator_options, $this->constructor_options, $this->live_options);\n\n\t\t$this->lang = $options[\"lang\"];\n\t\t$this->price_finder = $options[\"price_finder\"];\n\n\t\t$this->options = $options;\n\t}", "title": "" }, { "docid": "8e4b9daff78efc5f945c5572ea98a03e", "score": "0.6719107", "text": "public static function init() {\r\n\r\n\t\t\tself::$active_plugins = (array) get_option( 'active_plugins', array() );\r\n\r\n\t\t\tif ( is_multisite() )\r\n\t\t\t\tself::$active_plugins = array_merge( self::$active_plugins, get_site_option( 'active_sitewide_plugins', array() ) );\r\n\t\t}", "title": "" }, { "docid": "88588575e16b9fe3ae16e9ef81ea70fe", "score": "0.6716266", "text": "public static function init($options)\n {\n self::$options = $options;\n }", "title": "" }, { "docid": "643edaacc7e028e19a00a2e7e4c6d541", "score": "0.6716144", "text": "public function options() {}", "title": "" }, { "docid": "61a06c0ffa356b7258520c92cd678639", "score": "0.6701597", "text": "public function init( $opts=array() );", "title": "" }, { "docid": "f2ba28b066bf78dac3fc4f9550b6630a", "score": "0.6696647", "text": "public function onload() {\n $options = get_option( self::OPTION_NAME );\n if ( ! is_array( $options ) )\n $options = array();\n $this->existing_options = $options;\n\n $this->settings_api_init();\n }", "title": "" }, { "docid": "c91c840ad78f38feffe46c4be7687885", "score": "0.6691393", "text": "function plugin_settings(){\n\t\t}", "title": "" }, { "docid": "3850e3306a4275f302c107a015e4dd7f", "score": "0.66887134", "text": "public function init(array $options){\n $this->options = (array) $this->options + $options;\n }", "title": "" }, { "docid": "8fc627f534ed5f883a302a388140d0ea", "score": "0.66689837", "text": "function __construct($options = array())\n {\n $this->_options = $options;\n }", "title": "" }, { "docid": "1f37d84eb634d1340ac27f3733f8f51c", "score": "0.66687", "text": "function __construct($options = array()) {\n\t\t$this->options = $options;\n\t}", "title": "" }, { "docid": "7f30493fbcbc27fd9714901c213febe8", "score": "0.6658351", "text": "public function init()\n {\n $this->assetsDir = Yii::app()->assetManager->publish(__DIR__ . '/assets');\n\n $this->htmlOptions['multiple'] = $this->multiple;\n\n $this->settings = array('single' => !$this->multiple, 'filter' => $this->filter);\n\n if (isset($this->htmlOptions['placeholder'])) {\n $this->settings = CMap::mergeArray($this->settings, array('placeholder' => $this->htmlOptions['placeholder']));\n unset($this->htmlOptions['placeholder']);\n }\n\n if (isset($this->htmlOptions['multiSelectOptions'])) {\n $this->settings = CMap::mergeArray($this->settings, $this->htmlOptions['multiSelectOptions']);\n unset($this->htmlOptions['multiSelectOptions']);\n }\n\n parent::init();\n }", "title": "" }, { "docid": "d571ab4a16ff560d5229c7283e0fe24d", "score": "0.6657857", "text": "public function options();", "title": "" }, { "docid": "d571ab4a16ff560d5229c7283e0fe24d", "score": "0.6657857", "text": "public function options();", "title": "" }, { "docid": "e9c1dc52e8e901d1fe6af47e83bf3d6b", "score": "0.66442555", "text": "public function __construct($options = array()) {\n $this->options = $options + $this->defaults;\n }", "title": "" }, { "docid": "7d7201ac42901dd269dc34e547927ca9", "score": "0.66428024", "text": "function init_options($options_id) {\n\t\t$this->options_id = $options_id;\n\t\t$this->options = get_option($options_id); \n\t}", "title": "" }, { "docid": "8667c3f8531501a53ca6d9e13735033c", "score": "0.6640951", "text": "public function __construct()\n {\n parent::__construct($this->defineOptions());\n }", "title": "" }, { "docid": "20180a340da19015cc5886b81016231b", "score": "0.66405", "text": "function setAdditionalOptions();", "title": "" }, { "docid": "edb7d1070bf2752c6eccd7798da9f5e1", "score": "0.66359085", "text": "public function admin_init() {\n\n $this->options = $options = get_option( self::OPTION_KEY, $default = false );\n\n add_settings_section( self::SECTION, 'Google API Data:', array( &$this, 'section_cb' ), self::OPTION_PAGE );\n\n add_settings_field(\n self::PREFIX . 'plugin_text_id', 'Client ID', array( &$this, 'setting_field_fn' ), self::OPTION_PAGE, self::SECTION, array( 'field' => 'client_id' )\n );\n\n add_settings_field(\n self::PREFIX . 'plugin_text_secret', 'Client Secret', array( &$this, 'setting_field_fn' ), self::OPTION_PAGE, self::SECTION, array( 'field' => 'client_secret' )\n );\n\n // if we got the client id, let's check for authentication\n if ( $options[ 'client_id' ] != '' && $options[ 'client_secret' ] != '' ) {\n\n // build auth url\n $ga = $this->google_client();\n $data = array( 'url' => $ga->auth->buildAuthUrl() );\n\n add_settings_section( self::CHOOSE_USER_SECTION, 'Authorise plugin to access your data!', array( &$this, 'select_account_section_cb' ), self::OPTION_PAGE );\n\n // if no access_token, auth, else view reset button\n if ( $options[ 'access_token' ] == '' || ((time() - $options[ 'created_in' ]) >= $options[ 'token_expires' ])) {\n add_settings_field(\n self::PREFIX . 'plugin_button_authorize', 'Click this after you add your credentials', array( &$this, 'login_button_fb' ), self::OPTION_PAGE, self::CHOOSE_USER_SECTION, $data\n );\n }\n else {\n\n // Reset Button\n add_settings_field(\n self::PREFIX . 'plugin_button_reset', 'Reset', array( &$this, 'reset_button' ), self::OPTION_PAGE, self::CHOOSE_USER_SECTION\n );\n }\n }\n\n register_setting( self::PREFIX . 'option_group', self::OPTION_KEY, array( &$this, 'options_validator' ) );\n\n }", "title": "" }, { "docid": "e21dd4e96424b4224fb2a47bbf928a66", "score": "0.66358805", "text": "private function initializeApiOptions()\n {\n $this->apiOptions = new Options();\n $this->apiOptions->setBaseUrl(config('iyzipay.baseUrl'));\n $this->apiOptions->setApiKey(config('iyzipay.apiKey'));\n $this->apiOptions->setSecretKey(config('iyzipay.secretKey'));\n }", "title": "" }, { "docid": "fc31612f0c7037e25bd2eb75d0a5a73c", "score": "0.66249526", "text": "function tp_custom_phto_gallery_option_init(){\r\n\r\n\tregister_setting( 'tp_custom_gallery_options_setting', 'tp_light_gallery_custom_photo_width');\r\n\tregister_setting( 'tp_custom_gallery_options_setting', 'tp_light_gallery_custom_photo_height');\r\n\tregister_setting( 'tp_custom_gallery_options_setting', 'tp_light_gallery_custom_photo_bg_color');\r\n\tregister_setting( 'tp_custom_gallery_options_setting', 'tp_light_gallery_custom_photo_top_width');\r\n\tregister_setting( 'tp_custom_gallery_options_setting', 'tp_light_gallery_custom_photo_top_height');\r\n\t\r\n }", "title": "" }, { "docid": "927b9eb7eca2e3c02812470fb5fece70", "score": "0.66240656", "text": "protected function init() {\n global $ns_options;\n $ns_options = $this->options;\n\n // call super-class!\n parent::init();\n }", "title": "" }, { "docid": "66a76e22b3384d76ab00fd72175ec851", "score": "0.6622697", "text": "public function __construct() {\n\t\t\t$this->plugin_init();\n\t\t}", "title": "" }, { "docid": "26f2d71916c09b21b5d43399a06dc38f", "score": "0.66137785", "text": "public function init() {\n $this->instance_form_fields = include( 'includes/settings-bundle-rate.php' );\n $this->title = $this->get_option( 'title' );\n $this->tax_status = $this->get_option( 'tax_status' );\n $this->fee = $this->get_option( 'fee' );\n $this->apply_base_rate_once = $this->get_option( 'apply_base_rate_once', '1' ); \n }", "title": "" }, { "docid": "cb067fc7505d8f830bdbcb3fff120f70", "score": "0.6612413", "text": "public function initOptions()\n {\n if (empty($this->options['class'])) {\n $this->options['class'] = 'editor';\n }\n else {\n $classes = explode(' ', $this->options['class']);\n $classes[] = 'editor';\n $this->options['class'] = implode(' ', array_unique($classes));\n }\n $this->_fieldId = $this->options['id'];\n $this->options['id'] = 'editor-' . $this->id;\n }", "title": "" }, { "docid": "99f6d6d118e9d2eed5b3690b11d42a24", "score": "0.66071063", "text": "public function __construct() {\n\t\t$this->option = get_option( $this->option_handle );\n\t}", "title": "" }, { "docid": "38c1a4867dac2e45208f598f7cb6d0d0", "score": "0.6605386", "text": "function uwtheme_theme_options_init() {\n\n\t// If we have no options in the database, let's add them now.\n\tif ( false === uwtheme_get_theme_options() )\n\t\tadd_option( 'uwtheme_theme_options', uwtheme_get_default_theme_options() );\n\n\tregister_setting(\n\t\t'uwtheme_options', // Options group, see settings_fields() call in theme_options_render_page()\n\t\t'uwtheme_theme_options', // Database option, see uwtheme_get_theme_options()\n\t\t'uwtheme_theme_options_validate' // The sanitization callback, see uwtheme_theme_options_validate()\n\t);\n}", "title": "" }, { "docid": "2747d871bdb00407742a9394e9ed343c", "score": "0.6595851", "text": "function pexeto_init_options_functionality(){\n\tglobal $pexeto_options;\n\n\t$pexeto_options=array();\n\n\t//get all the categories\n\t$categories=get_categories('hide_empty=0');\n\t$pexeto_categories=array();\n\tfor($i=0; $i<sizeof($categories); $i++){\n\t\t$pexeto_categories[]=array('id'=>$categories[$i]->cat_ID, 'name'=>$categories[$i]->cat_name);\n\t}\n\n\t//load the files that contain the options\n\t$pexeto_options_files=array('general', 'pages', 'sliders', 'styles', 'translation', 'documentation');\n\tforeach($pexeto_options_files as $file){\n\t\trequire_once(PEXETO_OPTIONS_PATH.$file.'.php');\n\t}\n\n}", "title": "" }, { "docid": "0d2c3fdd671f24b2ae11f6e28d2668f6", "score": "0.6586146", "text": "public function init_settings()\n {\n // register the settings for this plugin\n register_setting(self::OPTIONS_GROUP, 'bh_username');\n register_setting(self::OPTIONS_GROUP, 'bh_password');\n register_setting(self::OPTIONS_GROUP, 'bh_api_key');\n }", "title": "" }, { "docid": "e218407683852c95e5c274bd7beccb46", "score": "0.658501", "text": "public function admin_init()\n {\n // Set up the settings for this plugin\n $this->init_settings();\n }", "title": "" }, { "docid": "38315ee2eb1956e6a079f38086c95de0", "score": "0.6580662", "text": "function __construct() {\n\t\tadd_action('admin_init', array(&$this, 'settings_init'));\n\t\tadd_action('admin_menu', array(&$this, 'bugify_admin_menu'));\n\t\tregister_activation_hook( __FILE__, array($this, 'activate') );\n\t\t\n\t\t$this->options['url'] = get_option($this->opt_name.'_url');\n\t\t$this->options['key'] = get_option($this->opt_name.'_key');\n\t\t$this->options['project'] = get_option($this->opt_name.'_project');\n\t\t$this->options['categories'] = get_option($this->opt_name.'_categories');\n\t\t$this->plugin_url = plugin_dir_url( __FILE__ );\n\n\t\tif($this->options['project'] > 0)\n\t\t\t$this->ready = true;\n\n\t\t$this->clean_url($this->options['url']);\n\n\t\tadd_action('admin_enqueue_scripts', array(&$this, 'register_style') );\n\t}", "title": "" }, { "docid": "c02e64aeeb475d85b2d4abed9f8685da", "score": "0.6572799", "text": "public function get_options(){\n $cache_id = Helper::get('PLUGIN_DATA_PREFIX') . GeneralHelpers::Cs_Md5_Hash( 'head_optons' );\n// if( ( $this->options = get_transient( $cache_id ) ) === false ){\n $this->options = CsGlobalOptions::get_options( $this->required_options, true );\n set_transient( $cache_id, $this->options, 6 * MONTH_IN_SECONDS );\n// }\n }", "title": "" }, { "docid": "eef0826f14b01e4b48124a97ed410230", "score": "0.6554354", "text": "function __construct(){\r\n global $wpdb;\r\n $this->wpdb = $wpdb;\r\n //$this->wpdb->show_errors = true;\r\n $this->options = get_option(\"usecurex_options\");\r\n }", "title": "" }, { "docid": "138c4fbb5801566c02636e14c94673eb", "score": "0.6550758", "text": "public function init_plugin() {\n $this->includes();\n $this->init_hooks();\n }", "title": "" }, { "docid": "4dd15b40aa178308a09c14df0eae48c8", "score": "0.6550576", "text": "public function onLoadOptions() {\n }", "title": "" }, { "docid": "2f3c35b6f8b1725cbcdf4379200adb7e", "score": "0.65283257", "text": "protected function __construct() {\n\t\tparent::__construct();\n\n\t\t/* Clear the cache on update/add. */\n\t\tadd_action( 'add_option_' . $this->option_name, array( 'WPSEO_Utils', 'clear_cache' ) );\n\t\tadd_action( 'update_option_' . $this->option_name, array( 'WPSEO_Utils', 'clear_cache' ) );\n\n\t\t/**\n\t\t * Filter the `wpseo` option defaults.\n\t\t *\n\t\t * @param array $defaults Array the defaults for the `wpseo` option attributes.\n\t\t */\n\t\t$this->defaults = apply_filters( 'wpseo_option_wpseo_defaults', $this->defaults );\n\t}", "title": "" }, { "docid": "9486bafdd712da34c1321417acb3f2d7", "score": "0.651532", "text": "public function init_plugin()\n {\n $this->includes();\n $this->init_hooks();\n }", "title": "" }, { "docid": "cf3f311d3d7d32013c6602c7f039e77e", "score": "0.65122014", "text": "function set_options($options){\n\t\t$this->options=$options;\n\t}", "title": "" }, { "docid": "c32782d9e760efab315983e8d1e69af0", "score": "0.6504245", "text": "function register_default_options() {\n\t\t\tif ($this->options)\n return;\n\t\t\t \n $option_defaults = array();\n \n $old_options = SC_WPPlugin::retrieve_options(\"spamcaptcher\");\n \n if ($old_options) {\n $option_defaults['account_id'] = $old_options['account_id']; // the public key for spamcaptcher\n $option_defaults['account_private_key'] = $old_options['account_private_key']; // the private key for spamcaptcher\n\n // placement\n $option_defaults['show_in_comments'] = $old_options['sc_comments']; // whether or not to show spamcaptcher on the comment post\n $option_defaults['show_in_registration'] = $old_options['sc_registration']; // whether or not to show spamcaptcher on the registration page\n\t\t\t $option_defaults['show_in_password_reset'] = $old_options['show_in_password_reset']; //whether or not to show spamcaptcher on the password reset page\n\t\t\t $option_defaults['show_in_account_login'] = $old_options['show_in_account_login']; //whether or not to show spamcaptcher on the login page\n\t\t\t \n\t\t\t // TrustMe Account\n\t\t\t $option_defaults['comments_force_tma'] = $old_options['comments_force_tma'];\n\t\t\t $option_defaults['registration_force_tma'] = $old_options['registration_force_tma'];\n\t\t\t \n // bypass levels\n $option_defaults['bypass_for_registered_users'] = ($old_options['sc_bypass'] == \"on\") ? 1 : 0; // whether to skip spamcaptchers for registered users\n $option_defaults['minimum_bypass_level'] = $old_options['sc_bypasslevel']; // who doesn't have to do the spamcaptcher (should be a valid WordPress capability slug)\n\n if ($option_defaults['minimum_bypass_level'] == \"level_10\") {\n $option_defaults['minimum_bypass_level'] = \"activate_plugins\";\n }\n\n // error handling\n $option_defaults['incorrect_response_error'] = $old_options['error_incorrect']; // message for incorrect CAPTCHA response\n\t\t\t \n\t\t\t // misc\n\t\t\t\tif ($this->is_ssl_capable()){\n\t\t\t\t\t$options_defaults['use_ssl'] = $old_options['use_ssl'];\n\t\t\t\t\t$options_defaults['ssl_capable'] = 1;\n\t\t\t\t}else{\n\t\t\t\t\t$options_defaults['use_ssl'] = 0;\n\t\t\t\t\t$options_defaults['ssl_capable'] = 0;\n\t\t\t\t}\n $options_defaults['send_spam_data'] = $old_options['send_spam_data'];\n\t\t\t $options_defaults['bind_to_form'] = $old_options['bind_to_form'];\n\t\t\t $options_defaults['toggle_opacity'] = $old_options['toggle_opacity'];\n\t\t\t $option_defaults['min_moderation_score'] = $old_options['min_moderation_score'];\n\t\t\t $option_defaults['max_moderation_score'] = $old_options['max_moderation_score'];\n\t\t\t $option_defaults['comments_use_proof_of_work'] = $old_options['comments_use_proof_of_work'];\n\t\t\t $option_defaults['comments_proof_of_work_time'] = $old_options['comments_proof_of_work_time'];\n\t\t\t $options_defaults['account_login_failed_attempt_count'] = $old_options['account_login_failed_attempt_count'];\n\t\t\t $options_defaults['account_login_reset_time'] = $old_options['account_login_reset_time'];\n }\n \n else {\n // keys\n $option_defaults['account_id'] = ''; // the account's id for spamcaptcher\n $option_defaults['account_private_key'] = ''; // the account's password for spamcaptcher\n\n // placement\n $option_defaults['show_in_comments'] = 1; // whether or not to show spamcaptcher on the comment post\n $option_defaults['show_in_registration'] = 1; // whether or not to show spamcaptcher on the registration page\n\t\t\t $option_defaults['show_in_password_reset'] = 1; //whether or not to show spamcaptcher on the password reset page\n\t\t\t $option_defaults['show_in_account_login'] = 1; //whether or not to show spamcaptcher on the login page\n\t\t\t \n // bypass levels\n $option_defaults['bypass_for_registered_users'] = 1; // whether to skip spamcaptchers for registered users\n $option_defaults['minimum_bypass_level'] = 'read'; // who doesn't have to do the spamcaptcher (should be a valid WordPress capability slug)\n\n // error handling\n $option_defaults['incorrect_response_error'] = '<span style=\\'color:red\\'><strong>ERROR</strong>: Incorrect SpamCaptcher response. Please try again.</span>'; \n\t\t\t \n\t\t\t // misc\n\t\t\t $options_defaults['ssl_capable'] = ($this->is_ssl_capable() ? 1 : 0);\n\t\t\t $options_defaults['use_ssl'] = $options_defaults['ssl_capable'];\n $options_defaults['send_spam_data'] = 1;\n\t\t\t $options_defaults['bind_to_form'] = 0;\n\t\t\t $options_defaults['toggle_opacity'] = 0;\n\t\t\t $option_defaults['min_moderation_score'] = 35;\n\t\t\t $option_defaults['max_moderation_score'] = 99;\n\t\t\t $option_defaults['comments_use_proof_of_work'] = 0;\n\t\t\t $option_defaults['comments_proof_of_work_time'] = 2;\n\t\t\t $options_defaults['account_login_failed_attempt_count'] = 3;\n\t\t\t $options_defaults['account_login_reset_time'] = 600;\n\t\t\t \n\t\t\t // TrustMe Account\n\t\t\t $option_defaults['comments_force_tma'] = 0;\n\t\t\t $option_defaults['registration_force_tma'] = 0;\n }\n \n // add the option based on what environment we're in\n SC_WPPlugin::add_options($this->options_name, $option_defaults);\n }", "title": "" }, { "docid": "6af2dc03bd08b011fa0d3bcf86f435f7", "score": "0.6503216", "text": "function pvw_slp_options_template_init(){\n\t\n\t$shortname = SLP_PVW_PLUGIN_SHORTCODE;\n\t\n\t// Set the Options Array\n\t$options = array();\n\t\n\t\n\t// ---------------------------------------------------------------------------------------------------------------------------------------------//\t\t\t\t\t\n\t\t\n\t$options[] = array( \"name\" => __('Shortcode',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\t\"type\" => \"heading\");\n\t\t\t\t\t\t\n\t$options[] = array( \"name\" => \"\",\n\t\t\t\t\t\t\"message\" => __('If you have issues finding a gig using the plugin, please check the gig at ',SLP_PVW_PLUGIN_LINK).'<a href=\"http://www.setlist.fm/\">setlist.fm</a>',\n\t\t\t\t\t\t\"type\" => \"intro\");\n\t\t\t\t\t\t\n\n\t$table_shots = array(\t\n\t\t\t\t\t\t\tarray(__('Parameter',SLP_PVW_PLUGIN_LINK),__('Default',SLP_PVW_PLUGIN_LINK),__('Options',SLP_PVW_PLUGIN_LINK),__('Description',SLP_PVW_PLUGIN_LINK)),\n\t\t\t\t\t\t\tarray('artist','','',__('Name of artist',SLP_PVW_PLUGIN_LINK)),\n\t\t\t\t\t\t\tarray('date','','',__('Date of gig. Use date format DD-MM-YYYY',SLP_PVW_PLUGIN_LINK)),\n\t\t\t\t\t\t\tarray('venue','','',__('Venue name of gig. eg. O2 Academy Bournemouth',SLP_PVW_PLUGIN_LINK))\n\t\t\t\t\t\t\n\t\t\t\t\t\t);\n\t\n\t$options[] = array( \"name\" => \"\",\n\t\t\t\t\t\t\"message\" => \tsprintf(__('The shortcode of %1$s can be used in posts and pages. It has the following options',SLP_PVW_PLUGIN_LINK), '<b>slp_get_setlist</b>').': <br/>'.\n\t\t\t\t\t\t\t\t\t\tslp_pvw_plugin_framework::pvw_table_generator($table_shots).\n\t\t\t\t\t\t\t\t\t\t'<b>'.__('Example',SLP_PVW_PLUGIN_LINK).': </b><br/>[slp_get_setlist artist=\\'Drake\\' date=\\'01-03-2012\\' venue=\\'Sprint Center\\']',\n\t\t\t\t\t\t\"type\" => \"note\");\n\t\t\t\t\t\t\n\t\n\t\t\t\t\t\t\t\t\t\t\t\n\t// ---------------------------------------------------------------------------------------------------------------------------------------------//\t\t\t\t\t\n\n\t$options[] = array( \"name\" => __('General Settings',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\t\"type\" => \"heading\");\n\t\t\t\t\t\t\n\t$options[] = array( \"name\" => \"\",\n\t\t\t\t\t\t\"message\" => __('These are general settings for the plugin',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\t\"type\" => \"intro\");\n\t\t\t\t\t\t\n\t\n\t\n\t$options[] = array( \"name\" => __('Enable Caching for Widgets and Shortcodes',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"desc\" => __('Check this to enable caching of the setlist.fm API data.',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"id\" => $shortname.\"_cache_config\",\n\t\t\t\t\t\"std\" => \"true\",\n\t\t\t\t\t\"type\" => \"checkbox\");\n\t\n\t$options[] = array( \"name\" => __('Cache Expiry',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"desc\" => __('Enter the expiry of the cache, in seconds. Default is a week. Only works if caching is enabled',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"id\" => $shortname.\"_cache_exp\",\n\t\t\t\t\t\"std\" => \"604800\",\n\t\t\t \t\t\"type\" => \"text\");\n\t\t\t\t\t\n\t$options[] = array( \"name\" => __('Clear Cache',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"desc\" => __('Clear the cache manually for widgets and shortcodes',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"id\" => $shortname.\"_cache_clear\",\n\t\t\t\t\t\"text\" => \"Clear\",\n\t\t\t\t\t\"method\" => \"clear_cache\",\n\t\t\t\t\t\"message\" => \"Cache cleared!\",\n\t\t\t\t\t\"type\" => \"button\");\n\t\t\t\t\t\n\t\t$options[] = array( \"name\" => sprintf(__('Create link to the %1$s plugin page',SLP_PVW_PLUGIN_LINK),SLP_PVW_PLUGIN_NAME),\n\t\t\t\t\t\"desc\" => __('Check this to enable a credit link to the plugin page at the end of the widget or shortcode output',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"id\" => $shortname.\"_sl_credit_link\",\n\t\t\t\t\t\"std\" => \"false\",\n\t\t\t\t\t\"type\" => \"checkbox\");\n\t\t\t\t\t\n\t// ---------------------------------------------------------------------------------------------------------------------------------------------//\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t$options[] = array( \"name\" => __('Custom Styling',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\t\"type\" => \"heading\");\n\t\t\t\t\t\t\n\t$options[] = array( \"name\" => \"\",\n\t\t\t\t\t\t\"message\" => __('Configure the look of the output created by this plugin. Style the elements created by the widget and shortcode',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\t\"type\" => \"intro\");\n\t\t\t\t\t\t\n\t$table_css = array(\t\n\t\t\t\t\t\t\tarray(__('CSS Class',SLP_PVW_PLUGIN_LINK),__('Parent Class',SLP_PVW_PLUGIN_LINK),__('Child Tags',SLP_PVW_PLUGIN_LINK),__('Used By',SLP_PVW_PLUGIN_LINK),__('Description',SLP_PVW_PLUGIN_LINK)),\n\t\t\t\t\t\t\tarray('.setlist','',array('ul','p','span.encore'),'slp_get_setlist',__('Overall wrapper div for the set list. Child tags include span for encore text.',SLP_PVW_PLUGIN_LINK)),\n\t\t\t\t\t\t\tarray('.setlist ul','','li','slp_get_setlist',__('Unordered list used for songs.',SLP_PVW_PLUGIN_LINK)),\n\t\t\t\t\t\t\tarray('.setlist p','',array('span.artist','span.venue','span.date'),'slp_get_setlist',__('You can style the artist, venue and date text which are wrapped in a span tag.',SLP_PVW_PLUGIN_LINK)),\n\t\t\t\t\t\t\tarray('.plugin_credit','.setlist','','slp_get_setlist',__('Plugin credit link at the end of set list.',SLP_PVW_PLUGIN_LINK)),\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t);\n\t\n\t$options[] = array( \"name\" => \"\",\n\t\t\t\t\t\t\"message\" => \t__('The plugin uses a variety of CSS classes that you can apply custom styling to',SLP_PVW_PLUGIN_LINK).': <br/>'.\n\t\t\t\t\t\t\t\t\t\tslp_pvw_plugin_framework::pvw_table_generator($table_css),\n\t\t\t\t\t\t\"type\" => \"note\");\n\t\n\t\n\t$css_options = array(\"default\" => \"Plugin's Default CSS\",\"custom\" => \"Custom CSS\", \"none\" => \"No Extra CSS, Use Theme's\"); \n\t\n\t$options[] = array( \"name\" => __('CSS Settings',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"desc\" => __('Select the set list is displayed',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"id\" => $shortname.\"_css_options\",\n\t\t\t\t\t\"std\" => \"default\",\n\t\t\t\t\t\"options\" => $css_options,\n\t\t\t\t\t\"type\" => \"radio\");\n\t\n\t$options[] = array( \"name\" => __('Custom CSS',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"desc\" => __('Insert your custom CSS ',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"id\" => $shortname.\"_custom_css\",\n\t\t\t\t\t\"std\" => \"\",\n\t\t\t\t\t\"options\" => array(\"rows\" => \"20\"),\n\t\t\t\t\t\"type\" => \"textarea\");\n\t\t\t\t\t\t\n\t\n\t// ---------------------------------------------------------------------------------------------------------------------------------------------//\t\t\t\t\t\n\t\n\t// PLUGIN DEBUG AND SUPPORT SECTION\n\t\n\t// ---------------------------------------------------------------------------------------------------------------------------------------------//\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t$options[] = array( \"name\" => __('Plugin Support',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\t\"type\" => \"heading\");\n\t\t\t\t\t\t\n\t$options[] = array( \"message\" => __('If you have any issues with the please visit the <a href=\"http://www.polevaultweb.com/support/forum/'.SLP_PVW_PLUGIN_LINK.'-plugin/\">Support Forum</a>.',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\t\"type\" => \"intro\");\n\t\t\t\t\t\t\n\t$options[] = array( \"name\" => __('Donations',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\t\"desc\" => __('If you like the plugin or receive support then please consider donating so we can keep on developing and supporting.',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\t\"type\" => \"donation\");\n\t\t\t\t\t\t\n\t$options[] = array( \"name\" => \"\",\n\t\t\t\t\t\"desc\" => __('If you raise a topic or reply on the Support Forum about an issue you are having, please send the following debug data so we can troubleshoot your issue',SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"id\" => $shortname.\"_send_debug\",\n\t\t\t\t\t\"text\" => __('Send Debug Data', SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"method\" => \"pvw_send_debug_data\",\n\t\t\t\t\t\"message\" => __('Debug data sent! Thank you', SLP_PVW_PLUGIN_LINK),\n\t\t\t\t\t\"std\" => \"debug\",\n\t\t\t\t\t\"type\" => \"button\");\n\t\t\t\t\t\t\n\t$options[] = array( \"name\" => \"\",\n\t\t\t\t\t\t\"type\" => \"debug\");\n\n\t\t\t\t\t\t\n\t\n\t\t\t\n\t\n\t// ---------------------------------------------------------------------------------------------------------------------------------------------//\t\t\t\t\t\n\t// Save options\n\t\n\tupdate_option('pvw_'.$shortname.'_template',$options); \n\t\n \n}", "title": "" }, { "docid": "ab1b070d671a8d8c05b41244453e8dbb", "score": "0.64945614", "text": "public static function init()\n {\n if( function_exists('acf_add_options_page') ) {\n acf_add_options_page(array(\n 'page_title' \t=> __('Option du thème', 'jb-starter-theme'),\n 'menu_title' \t=> __('Option du thème', 'jb-starter-theme'),\n 'menu_slug' \t=> 'theme-general-settings',\n ));\n }\n\n //acf_update_setting('google_api_key', 'AIzaSyC66J522Sqvke43rbOdL1XwjndHeWh2JRs');\n }", "title": "" }, { "docid": "ef4cda80c58d14debd48ee1679e933aa", "score": "0.64924693", "text": "public function __construct() {\n\t\tfor ($i = 2; $i < $GLOBALS['argc']; $i++) {\n\t\t\t$option = $this->fetchOption($i);\n\t\t\t$this->options[$option] = $this->fetchOptionParameter($option, $i);\n\t\t}\n\t}", "title": "" }, { "docid": "e6399e8b7969f87846716ddc8e0f1255", "score": "0.6484532", "text": "public function __construct($options=array())\n {\n $this->setOptions($options);\n }", "title": "" }, { "docid": "2c18f81e047f8c7398cf5c4401ad4d2a", "score": "0.6478954", "text": "function set_li_options () {\r\n add_option('link_improver','1','active the plugin');\r\n add_option('link_improver_notargets','0','external links opened in the same window');\r\n add_option('link_improver_notitles','0','remove the tips');\r\n add_option('link_improver_nomailevents','0','remove the events of the email');\r\n add_option('link_improver_internal','#FF0000','internal links color');\r\n add_option('link_improver_external','#0000FF','external links color');\r\n add_option('link_improver_subdomain','#800000','subdomain links color');\r\n add_option('link_improver_email','#008000','email links color');\r\n}", "title": "" }, { "docid": "f3ace5183f07fabd4444de09a47b70fb", "score": "0.64749926", "text": "function theme_options_init(){\n register_setting( 'sample_options', 'sample_theme_options', 'theme_options_validate' );\n}", "title": "" }, { "docid": "768e72cb21479d316b6d325779a4c07a", "score": "0.64708257", "text": "function of_option_setup()\t\n{\n\tglobal $of_options, $options_machine, $seo_options, $seo_machine, $comp_options, $comp_machine;\n\t$options_machine = new Options_Machine($of_options, 'data');\n\t\t\n\tif (!get_option(OPTIONS))\n\t{\n\t\tupdate_option(OPTIONS,$options_machine->Defaults);\n\t\tgenerate_options_css($options_machine->Defaults); //generate static css file\n\t}\n \n\t$seo_machine = new Options_Machine($seo_options, 'seo');\n\tif (!get_option(SEO_OPTIONS))\n\t{\n\t\tupdate_option(SEO_OPTIONS,$seo_machine->Defaults);\n\t}\n\t\n\t$comp_machine = new Options_Machine($comp_options, 'comp');\n\tif (!get_option(COMP_OPTIONS))\n\t{\n\t\tupdate_option(COMP_OPTIONS,$comp_machine->Defaults);\n\t}\n}", "title": "" }, { "docid": "a916c72d6e64ceb31b2a9278ca30a4f1", "score": "0.64682496", "text": "function pdev_plugin_admin_init(){\n\t$args = array(\n\t 'type' \t\t\t\t=> 'string', \n\t 'sanitize_callback' => 'pdev_plugin_validate_options',\n\t 'default' \t\t\t=> NULL\n\t);\n\n // Register our settings\n register_setting( 'pdev_plugin_options', 'pdev_plugin_options', $args );\n \n // Add a settings section\n add_settings_section( \n \t'pdev_plugin_main', \n \t'Dean\\'s Plugin Settings',\n 'pdev_plugin_section_text', \n 'pdev_plugin' \n );\n \n // Create our settings field for fname\n add_settings_field( \n \t'pdev_plugin_fname', \n \t'First Name',\n 'pdev_plugin_setting_fname', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n\n // Create our settings field for lname\n add_settings_field( \n 'pdev_plugin_lname', \n 'Last Name',\n 'pdev_plugin_setting_lname', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n \n // Create our settings field for level\n add_settings_field( \n \t'pdev_plugin_level', \n \t'Level',\n 'pdev_plugin_setting_level', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n\n // Create our radio settings field for gender\n add_settings_field( \n \t'pdev_plugin_gender', \n \t'Gender',\n 'pdev_plugin_setting_gender', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n \n // Create our checkbox setting field for mode\n add_settings_field( \n \t'pdev_plugin_mode', \n \t'Enable Mode?',\n 'pdev_plugin_setting_mode', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n\n // Create our textarea setting field for bio\n add_settings_field( \n \t'pdev_plugin_bio', \n \t'Bio',\n 'pdev_plugin_setting_bio', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n\n}", "title": "" }, { "docid": "a916c72d6e64ceb31b2a9278ca30a4f1", "score": "0.64682496", "text": "function pdev_plugin_admin_init(){\n\t$args = array(\n\t 'type' \t\t\t\t=> 'string', \n\t 'sanitize_callback' => 'pdev_plugin_validate_options',\n\t 'default' \t\t\t=> NULL\n\t);\n\n // Register our settings\n register_setting( 'pdev_plugin_options', 'pdev_plugin_options', $args );\n \n // Add a settings section\n add_settings_section( \n \t'pdev_plugin_main', \n \t'Dean\\'s Plugin Settings',\n 'pdev_plugin_section_text', \n 'pdev_plugin' \n );\n \n // Create our settings field for fname\n add_settings_field( \n \t'pdev_plugin_fname', \n \t'First Name',\n 'pdev_plugin_setting_fname', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n\n // Create our settings field for lname\n add_settings_field( \n 'pdev_plugin_lname', \n 'Last Name',\n 'pdev_plugin_setting_lname', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n \n // Create our settings field for level\n add_settings_field( \n \t'pdev_plugin_level', \n \t'Level',\n 'pdev_plugin_setting_level', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n\n // Create our radio settings field for gender\n add_settings_field( \n \t'pdev_plugin_gender', \n \t'Gender',\n 'pdev_plugin_setting_gender', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n \n // Create our checkbox setting field for mode\n add_settings_field( \n \t'pdev_plugin_mode', \n \t'Enable Mode?',\n 'pdev_plugin_setting_mode', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n\n // Create our textarea setting field for bio\n add_settings_field( \n \t'pdev_plugin_bio', \n \t'Bio',\n 'pdev_plugin_setting_bio', \n 'pdev_plugin', \n 'pdev_plugin_main' \n );\n\n}", "title": "" }, { "docid": "97ee523922b74cadb929d5257422682c", "score": "0.6467971", "text": "public function __construct($sections = array(), $args = array()){\n\t\t\t\t\n\t\t\t$defaults = array();\n\t\t\t\t\n\t\t\t$defaults['opt_name'] = '';//must be defined by theme/plugin\n\t\t\t\t\n\t\t\t\t\n\t\t\t$defaults['page_icon'] = 'icon-themes';\n\t\t\t$defaults['page_title'] = esc_html__('Options', 'zr_core');\n\t\t\t$defaults['page_slug'] = '_options';\n\t\t\t$defaults['page_cap'] = 'manage_options';\n\t\t\t$defaults['page_type'] = 'submenu';\n\t\t\t$defaults['page_position'] = 100;\n\t\t\t$defaults['allow_sub_menu'] = true;\n\t\t\t\n\t\t\t\t\n\t\t\t$defaults['show_import_export'] = false;\n\t\t\t$defaults['dev_mode'] = false;\n\t\t\t$defaults['stylesheet_override'] = false;\n\t\t\t\t\n\t\t\t//get args\n\t\t\t$this->args = wp_parse_args( $args, $defaults );\n\t\t\t$this->args = apply_filters( 'ZR_Options_args_' . $this->args['opt_name'], $this->args );\n\n\t\t\tif (!isset($this->args['opt_name'])) {\n\t\t\t\t$this->args['opt_name'] = $this->getOptionName();\n\t\t\t}\n\t\t\t\n\t\t\t//get sections\n\t\t\t$this->sections = apply_filters( 'ZR_Options_sections_' . $this->args['opt_name'], $sections );\t\t\t\t\n\t\t\t\n\t\t\t//set option with defaults\n\t\t\tadd_action('init', array(&$this, '_set_default_options'));\n\t\t\t\t\n\t\t\t//options page\n\t\t\tadd_action('admin_menu', array(&$this, '_options_page'));\n\t\t\t\t\n\t\t\t//register setting\n\t\t\tadd_action('admin_init', array(&$this, '_register_setting'));\n\t\t\t\t\n\t\t\t//add the js for the error handling before the form\n\t\t\tadd_action('zr-opts-page-before-form-'.$this->args['opt_name'], array(&$this, '_errors_js'), 1);\n\t\t\t\t\n\t\t\t//add the js for the warning handling before the form\n\t\t\tadd_action('zr-opts-page-before-form-'.$this->args['opt_name'], array(&$this, '_warnings_js'), 2);\n\t\t\t\t\n\t\t\t//hook into the wp feeds for downloading the exported settings\n\t\t\tadd_action('do_feed_yaopts-'.$this->args['opt_name'], array(&$this, '_download_options'), 1, 1);\n\t\t\t\t\n\t\t\t//get the options for use later on\n\t\t\t$this->options = get_option($this->args['opt_name']);\n\t\t\t\n\t\t\t$this->cleanCookie();\n\t\t\t\n\t\t}", "title": "" }, { "docid": "1e746381d2d33e39fa1d3bd46b924b8c", "score": "0.64614004", "text": "public function admin_options() {\n\n\t\t\trequire_once plugin_dir_path( __FILE__ ) . 'templates/admin-options.php';\n\t\t}", "title": "" }, { "docid": "f7e2caed66d09b0802a76aafc94ef740", "score": "0.64536667", "text": "public function init()\n {\n parent::init();\n if (!isset($this->options['id'])) {\n $this->options['id'] = $this->getId();\n }\n }", "title": "" }, { "docid": "7ca4e8bf1732b5eefda9b1a9b0768ce6", "score": "0.6451976", "text": "public function setArguments() {\n\n $theme = wp_get_theme(); // For use with some settings. Not necessary.\n\n $this->args = array(\n // TYPICAL -> Change these values as you need/desire\n 'opt_name' => 'helper_option',\n // This is where your data is stored in the database and also becomes your global variable name.\n 'display_name' => $theme->get( 'Name' ),\n // Name that appears at the top of your panel\n 'display_version' => $theme->get( 'Version' ),\n // Version that appears at the top of your panel\n 'menu_type' => 'menu',\n //Specify if the admin menu should appear or not. Options: menu or submenu (Under appearance only)\n 'allow_sub_menu' => true,\n // Show the sections below the admin menu item or not\n 'menu_title' => __( 'Theme Options', 'helper' ),\n 'page_title' => __( 'Theme Options', 'helper' ),\n // You will need to generate a Google API key to use this feature.\n // Please visit: https://developers.google.com/fonts/docs/developer_api#Auth\n 'google_api_key' => '',\n // Set it you want google fonts to update weekly. A google_api_key value is required.\n 'google_update_weekly' => false,\n // Must be defined to add google fonts to the typography module\n 'async_typography' => true,\n // Use a asynchronous font on the front end or font string\n //'disable_google_fonts_link' => true, // Disable this in case you want to create your own google fonts loader\n 'admin_bar' => true,\n // Show the panel pages on the admin bar\n 'admin_bar_icon' => 'dashicons-portfolio',\n // Choose an icon for the admin bar menu\n 'admin_bar_priority' => 50,\n // Choose an priority for the admin bar menu\n 'global_variable' => '',\n // Set a different name for your global variable other than the opt_name\n 'dev_mode' => false,\n // Enable ajax save\n 'ajax_save' => true,\n // Show the time the page took to load, etc\n 'update_notice' => true,\n // If dev_mode is enabled, will notify developer of updated versions available in the GitHub Repo\n 'customizer' => true,\n // Enable basic customizer support\n //'open_expanded' => true, // Allow you to start the panel in an expanded way initially.\n //'disable_save_warn' => true, // Disable the save warning when a user changes a field\n\n // OPTIONAL -> Give you extra features\n 'page_priority' => 61,\n // Order where the menu appears in the admin area. If there is any conflict, something will not show. Warning.\n 'page_parent' => 'themes.php',\n // For a full list of options, visit: http://codex.wordpress.org/Function_Reference/add_submenu_page#Parameters\n 'page_permissions' => 'manage_options',\n // Permissions needed to access the options panel.\n 'menu_icon' => get_template_directory_uri() .'/images/warrior-icon.png',\n // Specify a custom URL to an icon\n 'last_tab' => '',\n // Force your panel to always open to a specific tab (by id)\n 'page_icon' => 'icon-themes',\n // Icon displayed in the admin panel next to your menu_title\n 'page_slug' => 'warriorpanel',\n // Page slug used to denote the panel\n 'save_defaults' => true,\n // On load save the defaults to DB before user clicks save or not\n 'default_show' => false,\n // If true, shows the default value next to each field that is not the default value.\n 'default_mark' => '',\n // What to print by the field's title if the value shown is default. Suggested: *\n 'show_import_export' => true,\n // Shows the Import/Export panel when not used as a field.\n\n // CAREFUL -> These options are for advanced use only\n 'transient_time' => 60 * MINUTE_IN_SECONDS,\n 'output' => true,\n // Global shut-off for dynamic CSS output by the framework. Will also disable google fonts output\n 'output_tag' => true,\n // Allows dynamic CSS to be generated for customizer and google fonts, but stops the dynamic CSS from going to the head\n // 'footer_credit' => '', // Disable the footer credit of Redux. Please leave if you can help it.\n\n // FUTURE -> Not in use yet, but reserved or partially implemented. Use at your own risk.\n 'database' => '',\n // possible: options, theme_mods, theme_mods_expanded, transient. Not fully functional, warning!\n 'system_info' => false,\n // REMOVE\n\n // HINTS\n 'hints' => array(\n 'icon' => 'icon-question-sign',\n 'icon_position' => 'right',\n 'icon_color' => 'lightgray',\n 'icon_size' => 'normal',\n 'tip_style' => array(\n 'color' => 'light',\n 'shadow' => true,\n 'rounded' => false,\n 'style' => '',\n ),\n 'tip_position' => array(\n 'my' => 'top left',\n 'at' => 'bottom right',\n ),\n 'tip_effect' => array(\n 'show' => array(\n 'effect' => 'slide',\n 'duration' => '500',\n 'event' => 'mouseover',\n ),\n 'hide' => array(\n 'effect' => 'slide',\n 'duration' => '500',\n 'event' => 'click mouseleave',\n ),\n ),\n )\n );\n\n // SOCIAL ICONS -> Setup custom links in the footer for quick links in your panel footer icons.\n $this->args['share_icons'][] = array(\n 'url' => 'https://www.facebook.com/themewarrior',\n 'title' => 'Like us on Facebook',\n 'icon' => 'el el-facebook'\n );\n $this->args['share_icons'][] = array(\n 'url' => 'http://twitter.com/themewarrior',\n 'title' => 'Follow us on Twitter',\n 'icon' => 'el el-twitter'\n );\n $this->args['share_icons'][] = array(\n 'url' => 'http://themeforest.net/user/ThemeWarriors/portfolio',\n 'title' => 'See our portfolio',\n 'icon' => 'el el-shopping-cart'\n );\n\n // Panel Intro text -> before the form\n $this->args['intro_text'] = __('<p>If you like this theme, please consider giving it a 5 star rating on ThemeForest. <a href=\"http://themeforest.net/downloads\" target=\"_blank\">Rate now</a>.</p>', 'helper');\n\n // Add content after the form.\n // $this->args['footer_text'] = __( '<p>This text is displayed below the options panel. It isn\\'t required, but more info is always better! The footer_text field accepts all HTML.</p>', 'helper' );\n }", "title": "" }, { "docid": "b2af90cea16f43decb3bfd2977e0bc6a", "score": "0.6450745", "text": "public function init(array $options): void;", "title": "" }, { "docid": "4b4fec10dc0bfa09ee483e2349f64b3b", "score": "0.6450682", "text": "public function antours_options_init() {\n register_setting(\n self::$optionsGroupName,\n self::$optionName,\n array($this, \"sanitizer\")\n );\n\n add_settings_section(\n self::$sectionId,\n self::$sectionTitle,\n array( $this, \"render_section_information\" ),\n self::$optionPageName\n );\n\n // telephone field, clonable => true\n $fieldName = self::$telephoneFieldName;\n add_settings_field(\n \"contact_telephone_field\",\n \"Telephone\",\n array( $this, \"render_clonable_field\" ),\n self::$optionPageName,\n self::$sectionId,\n array(\n \"name\" => self::$optionName . \"[{$fieldName}][]\",\n \"key\" => $fieldName,\n \"type\" => \"tel\",\n \"cssClasses\" => array(\n \"telephone_field\",\n \"antours_option_field\"\n ),\n \"placeholder\" => \"Phone number\",\n \"button\" => array(\n \"cssClass\" => array(\"button\", \"button-primary\", \"asBlock\"),\n \"label\" => \"Add Telephone\",\n \"id\" => \"clon_telephone_field\"\n )\n )\n );\n\n // email field, clonable => true\n $fieldName = self::$emailFieldName;\n add_settings_field(\n \"contact_email_field\",\n \"Email\",\n array( $this, \"render_clonable_field\" ),\n self::$optionPageName,\n self::$sectionId,\n array(\n \"name\" => self::$optionName . \"[{$fieldName}][]\",\n \"key\" => $fieldName,\n \"type\" => \"email\",\n \"cssClasses\" => array(\n \"email_field\",\n \"antours_option_field\"\n ),\n \"placeholder\" => \"Email Address\",\n \"button\" => array(\n \"cssClass\" => array(\"button\", \"button-primary\", \"asBlock\"),\n \"label\" => \"Add Email\",\n \"id\" => \"clon_email_field\"\n )\n )\n );\n\n // facebook url field, clonable => false\n $fieldName = self::$fbFieldName;\n add_settings_field(\n \"contact_fb_url_field\",\n \"Facebook Link\",\n array( $this, \"render_social_network_field\" ),\n self::$optionPageName,\n self::$sectionId,\n array(\n \"name\" => self::$optionName . \"[{$fieldName}]\",\n \"key\" => $fieldName,\n \"cssClasses\" => array(\"w-50\"),\n \"placeholder\" => \"Facebook URL\"\n )\n );\n\n // twiiter url field, clonable => false\n $fieldName = self::$twitterFieldName;\n add_settings_field(\n \"contact_twitter_url_field\",\n \"Twitter Link\",\n array( $this, \"render_social_network_field\" ),\n self::$optionPageName,\n self::$sectionId,\n array(\n \"name\" => self::$optionName . \"[{$fieldName}]\",\n \"key\" => $fieldName,\n \"cssClasses\" => array(\"w-50\"),\n \"placeholder\" => \"Twitter URL\"\n )\n );\n\n // Instagram url field, clonable => false\n $fieldName = self::$instagramFieldName;\n add_settings_field(\n \"contact_instagram_url_field\",\n \"Instagram Link\",\n array( $this, \"render_social_network_field\" ),\n self::$optionPageName,\n self::$sectionId,\n array(\n \"name\" => self::$optionName . \"[{$fieldName}]\",\n \"key\" => $fieldName,\n \"cssClasses\" => array(\"w-50\"),\n \"placeholder\" => \"Instagram URL\"\n )\n );\n }", "title": "" }, { "docid": "0beb6ad385f595488236493ed4f75994", "score": "0.64332885", "text": "private function setCommonOptions()\n\t{\n\t\t$sanitizedParams = $this->getSanitizer();\n\n\t\t$this->setOption('name', $sanitizedParams->getString('name'));\n\t\t$this->setDuration($sanitizedParams->getInt('duration', $this->getDuration()));\n\t\t$this->setUseDuration($sanitizedParams->getCheckbox('useDuration'));\n\t\t$this->setOption('enableStat', $sanitizedParams->getString('enableStat'));\n\n\t\t// Map Options\n\t\t$this->setOption('useDisplayLocation', $sanitizedParams->getCheckbox('useDisplayLocation'));\n\t\t$this->setOption('longitude', $sanitizedParams->getDouble('longitude'));\n\t\t$this->setOption('latitude', $sanitizedParams->getDouble('latitude'));\n\t\t$this->setOption('zoom', $sanitizedParams->getInt('zoom'));\n\t\t$this->setOption('language', $sanitizedParams->getString('language'));\n\t\t$this->setOption('mapType', $sanitizedParams->getString('mapType'));\n\t\t$this->setOption('isInteractive', $sanitizedParams->getCheckbox('isInteractive'));\n\t\t$this->setOption('showZoom', $sanitizedParams->getCheckbox('showZoom'));\n\t\t$this->setOption('overlayType', $sanitizedParams->getString('overlayType'));\n\t\t$this->setOption('showLegend', $sanitizedParams->getCheckbox('showLegend'));\n\t\t$this->setOption('legendPosition', $sanitizedParams->getString('legendPosition'));\n\n\t\t//Pin Options\n\t\t$this->setOption('showPin', $sanitizedParams->getCheckbox('showPin'));\n\t\t$this->setOption('useMapLatLong', $sanitizedParams->getCheckbox('useMapLatLong'));\n\t\tif ($this->getOption('useMapLatLong')) {\n\t\t\t$this->setOption('pinLatitude', $this->getOption('latitude'));\n\t\t\t$this->setOption('pinLongitude', $this->getOption('longitude'));\n\t\t} else {\n\t\t\t$this->setOption('pinLatitude', $sanitizedParams->getDouble('pinLatitude'));\n\t\t\t$this->setOption('pinLongitude', $sanitizedParams->getDouble('pinLongitude'));\n\t\t}\n\t\t$this->setOption('customPinShadowImage', $sanitizedParams->getInt('customPinShadowImage'));\n\t\t$this->setOption('customPinImage', $sanitizedParams->getInt('customPinImage'));\n\t\t$this->setOption('usePinDefault', $sanitizedParams->getCheckbox('usePinDefault'));\n\t\t$this->setOption('pinWidth', $sanitizedParams->getInt('pinWidth'));\n\t\t$this->setOption('pinHeight', $sanitizedParams->getInt('pinHeight'));\n\t\t$this->setOption('pinShadowWidth', $sanitizedParams->getInt('pinShadowWidth'));\n\t\t$this->setOption('pinShadowHeight', $sanitizedParams->getInt('pinShadowHeight'));\n\n\t\t//City Options\n\t\t$this->setOption('showCities', $sanitizedParams->getCheckbox('showCities'));\n\t\t$this->setOption('units', $sanitizedParams->getString('units'));\n\t\t$this->setOption('iconSet', $sanitizedParams->getString('iconSet'));\n\t\t$this->setOption('cityTemplate', $sanitizedParams->getInt('cityTemplate'));\n\t}", "title": "" }, { "docid": "1d3445f48d697fd01630f5aeedf168ea", "score": "0.64324147", "text": "protected function initOptions() \n {\n $this->containerOptions = array_merge([\n 'id' => $this->getId()\n ],$this->containerOptions);\n Html::addCssClass($this->containerOptions, 'owl-carousel');\n }", "title": "" }, { "docid": "aa330b955b4efa4548ec8f01eff44a49", "score": "0.6419362", "text": "function init() {\n\t\t$this->init_form_fields(); // This is part of the settings API. Override the method to add your own settings\n\t\t$this->init_settings(); // This is part of the settings API. Loads settings you previously init.\n\n\t\t$this->enabled\t\t\t= $this->get_option( 'enabled' );\n\t\t$this->title \t\t\t= $this->get_option( 'title' );\n\t\t$this->api \t\t\t\t= $this->get_option( 'api' );\n\t\t$this->api_username \t= $this->get_option( 'api_username' );\n\t\t$this->api_password \t= $this->get_option( 'api_password' );\n\t\t$this->print_label\t\t= $this->get_option( 'print_label' );\n\t\t$this->base_cost \t\t= $this->get_option( 'base_cost' );\n\t\t$this->free_shipping\t= $this->get_option( 'free_shipping' );\n\t\t$this->sending_depot \t= $this->get_option( 'sending_depot' );\n\n\t\t$this->company_name\t\t= $this->get_option('company_name');\n\t\t$this->company_street \t= $this->get_option('company_street');\n\t\t//$this->company_country\t= $this->get_option('company_country');\n\t\t$this->company_postcode\t= $this->get_option('company_postcode');\n\t\t$this->company_city\t\t= $this->get_option('company_city');\n\t\t$this->gmaps_api_key = $this->get_option('gmaps_api_key');\n\n\t\t// Save settings in admin if you have any defined\n\t\tadd_action( 'woocommerce_update_options_shipping_' . $this->id, array( $this, 'process_admin_options' ) );\n\t\tadd_action( 'woocommerce_update_options_shipping_' . $this->id, array( $this, 'process_countries' ) );\t\n\t\tadd_action( 'woocommerce_update_options_shipping_' . $this->id, array( $this, 'process_api' ) );\t\t\n\t}", "title": "" }, { "docid": "b5d9fc86600b4ad04fda35af3bd79c4a", "score": "0.6416059", "text": "public function init_plugin() {\n $this->includes();\n $this->init_hooks();\n\n //do_action( 'equipeer_loaded' );\n }", "title": "" }, { "docid": "133a80362de3b1945a94cedabc25136b", "score": "0.64080113", "text": "public function __construct()\r\n {\r\n //delete_option(self::OPTION_NAME);\r\n\r\n $data = json_decode(get_option(self::OPTION_NAME), true);\r\n\r\n if (is_array($data)) {\r\n $this->_data = $data;\r\n } else {\r\n $this->_data = array();\r\n }\r\n\r\n //Rootd::debug($this->_data, Rootd::DEBUG_CONTINUE);\r\n\r\n unset($data);\r\n }", "title": "" }, { "docid": "a9c30f368ee9bbedfe729120a1b93db3", "score": "0.6405711", "text": "function activate() {\n $pluginOptions = get_option('wpcdn_options');\n \n if ( !$pluginOptions ) {\n add_option ( 'wpcdn_options' , $this -> options );\n }\n }", "title": "" }, { "docid": "1982e69a1811153f416b602844d8b880", "score": "0.64034027", "text": "public static function initPlugins() {}", "title": "" } ]
58b6cf1f5b08692d88ab8710b17f2039
Set the common header information.
[ { "docid": "ba3456deba763329134c4963638c9df7", "score": "0.8239573", "text": "private function _setCommonHeader()\r\n {\r\n if (empty($this->_header)) {\r\n // Set version header.\r\n $this->_setHeader('MIME-Version', '1.0');\r\n\r\n // Set User Agent for mail sock header.\r\n $this->_setHeader('User-Agent', $this->_user_agent);\r\n\r\n // Set X-Sender header information.\r\n $this->_setHeader('X-Sender', $this->_relay_mail);\r\n\r\n // Set X-Mailer header information.\r\n $this->_setHeader('X-Mailer', 'By ' . $this->_user_agent . '(PHP/' . PHP_VERSION . ').');\r\n\r\n // Set X-Priority header information.\r\n $this->_setHeader('X-Priority', $this->_priorities[$this->priority]);\r\n\r\n // Set From header information.\r\n $this->_setHeader('From', \"{$this->disp_name}<{$this->_relay_mail}>\");\r\n }\r\n }", "title": "" } ]
[ { "docid": "21c7f1d96322444e0beb205d3829c49a", "score": "0.7361771", "text": "public function setHeader()\n {\n ;\n }", "title": "" }, { "docid": "1c4611a051d958dd7f7fe1ca2b8ca794", "score": "0.72189265", "text": "protected function setHeader()\n {\n $headers = array();\n foreach ($this->headers as $key => $value) {\n $headers[] = $key . ': ' . $value;\n }\n curl_setopt($this->request, CURLOPT_HTTPHEADER, $headers);\n\n }", "title": "" }, { "docid": "724483e78e1a26ca22a0faa3d0b6c202", "score": "0.71706074", "text": "protected function setHeaders() // : void\n {\n foreach ($this->server as $key => $val) {\n if (substr($key, 0, 5) == 'HTTP_') {\n $key = substr($key, 5);\n $key = str_replace('_', '-', strtolower($key));\n $this->headers[$key] = $val;\n }\n }\n\n // RFC 3875 headers not prefixed with HTTP_*\n if (isset($this->server['CONTENT_LENGTH'])) {\n $this->headers['content-length'] = $this->server['CONTENT_LENGTH'];\n }\n\n if (isset($this->server['CONTENT_TYPE'])) {\n $this->headers['content-type'] = $this->server['CONTENT_TYPE'];\n }\n }", "title": "" }, { "docid": "a53a0b9ac6eef7386238a3f12824db08", "score": "0.71462405", "text": "private function set_header() {\n\t\t$tmp = new stdClass();\n\t\t$tmp->type = 'string';\n\t\t$tmp->name = 'title';\n\t\tarray_push($this->fields, $tmp);\n\t\tunset($tmp);\n\n\t\t$tmp = new stdClass();\n\t\t$tmp->type = 'string';\n\t\t$tmp->name = 'createdDate';\n\t\tarray_push($this->fields, $tmp);\n\t\tunset($tmp);\n\n\t}", "title": "" }, { "docid": "b85fc6a677a9727aa8bbf19465acb15c", "score": "0.71428454", "text": "public function setHeaders() {\n\t\t$this->headers = $this->getAllHeaders();\n\t}", "title": "" }, { "docid": "a16442866e281a8495921cd7c798144a", "score": "0.70437443", "text": "private function setStaticHeaders()\n\t{\n\t\t$this->staticHeaderConfiguration = $this->getStaticHeaderConfiguration($this->params);\n\n\t\tif (empty($this->staticHeaderConfiguration))\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tforeach ($this->staticHeaderConfiguration as $headerAndClient => $value)\n\t\t{\n\t\t\t$headerAndClient = explode('#', $headerAndClient);\n\t\t\t$header = $headerAndClient[0];\n\t\t\t$client = isset($headerAndClient[1]) ? $headerAndClient[1] : 'both';\n\n\t\t\tif (!$this->app->isClient($client) && $client != 'both')\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$this->app->setHeader($header, $value, true);\n\t\t}\n\t}", "title": "" }, { "docid": "e94a8e86bbaf98b2a00bddcd2ff40e2b", "score": "0.703917", "text": "protected function initHeaders()\n {\n // set default headers\n $this->setHeaders($this->getDefaultHeaders());\n }", "title": "" }, { "docid": "e94a8e86bbaf98b2a00bddcd2ff40e2b", "score": "0.703917", "text": "protected function initHeaders()\n {\n // set default headers\n $this->setHeaders($this->getDefaultHeaders());\n }", "title": "" }, { "docid": "0166967cd1363557876f6b174cb46b48", "score": "0.7003742", "text": "private function set_headers () {\n\t\t\t//\tthat cURL expects\n\t\t\t$arr=array();\n\t\t\tforeach ($this->headers as $key=>$value) $arr[]=sprintf(\n\t\t\t\t'%s:%s',\n\t\t\t\t$key,\n\t\t\t\t$value\n\t\t\t);\n\t\t\t\n\t\t\t$this->set(CURLOPT_HTTPHEADER,$arr);\n\t\t\n\t\t}", "title": "" }, { "docid": "866106be4c353a01c7b37cd7cd574315", "score": "0.6959269", "text": "protected function setInfoFromHeader(){\n\t\tif ( isset($this->packageInfo['header']) && !empty($this->packageInfo['header']) ){\n\t\t\t$this->setMappedFields($this->packageInfo['header'], $this->headerMap);\n\t\t\t$this->setThemeDetailsUrl();\n\t\t}\n\t}", "title": "" }, { "docid": "3b3a52867a9295d70e3984b12b675e0c", "score": "0.6950449", "text": "public function assignCommonHeaderData()\n {\n $this->setShopId();\n $id_shop = (int) $this->shop->id;\n $shop_name = Configuration::get('PS_SHOP_NAME', null, null, $id_shop);\n\n $logo = $this->getLogo();\n\n $width = 0;\n $height = 0;\n if (!empty($logo)) {\n list($width, $height) = getimagesize(_PS_IMG_DIR_ . $logo);\n }\n\n // Limit the height of the logo for the PDF render\n $maximum_height = 100;\n if ($height > $maximum_height) {\n $ratio = $maximum_height / $height;\n $height *= $ratio;\n $width *= $ratio;\n }\n\n $this->smarty->assign(array(\n 'logo_path' => Tools::getShopProtocol() . Tools::getMediaServer(_PS_IMG_) . _PS_IMG_ . $logo,\n 'img_ps_dir' => Tools::getShopProtocol() . Tools::getMediaServer(_PS_IMG_) . _PS_IMG_,\n 'img_update_time' => Configuration::get('PS_IMG_UPDATE_TIME'),\n 'date' => $this->date,\n 'title' => $this->title,\n 'shop_name' => $shop_name,\n 'shop_details' => Configuration::get('PS_SHOP_DETAILS', null, null, (int) $id_shop),\n 'width_logo' => $width,\n 'height_logo' => $height,\n ));\n }", "title": "" }, { "docid": "31c46dc1bbdbfba16e009f097209b511", "score": "0.6937275", "text": "public function setHeaders()\n {\n $this->headers = \\Yii::app()->request->getAllHeaders();\n }", "title": "" }, { "docid": "2c653f8ea5ec09e690459a19b82df3b2", "score": "0.693564", "text": "function setHeader($header)\n {\n $this->header = $header;\n }", "title": "" }, { "docid": "1ae88c2105324b14071eb06cf54aef1b", "score": "0.68843794", "text": "public function set_header($header)\n {\n $this->header = $header;\n }", "title": "" }, { "docid": "b92c9049b9f5d187c17b36723edd6bba", "score": "0.6861108", "text": "function setHeader($header);", "title": "" }, { "docid": "429f308dafd0517990c40c1d5f684499", "score": "0.6786682", "text": "public function set_header($key, $value)\n {\n }", "title": "" }, { "docid": "80e03f3d5cdee3cbb9b9ba5047f683b4", "score": "0.6775394", "text": "private function setHeader($header) {\n\t\t$this->header = $header;\n\t}", "title": "" }, { "docid": "24c891ef81a68c7f23a007deb1a47ffb", "score": "0.6715281", "text": "public function setHeaders() {\n }", "title": "" }, { "docid": "24c891ef81a68c7f23a007deb1a47ffb", "score": "0.6715281", "text": "public function setHeaders() {\n }", "title": "" }, { "docid": "24c891ef81a68c7f23a007deb1a47ffb", "score": "0.6715281", "text": "public function setHeaders() {\n }", "title": "" }, { "docid": "ea7ba1338d81e972316e8e380ea43222", "score": "0.66776246", "text": "private function set_headers()\n {\n $date = new DateTime(null, new DateTimeZone('UTC'));\n $this->curl_headers = [\n 'Date: ' . $date->format('D, d M Y H:i:s') . ' GMT', // RFC 1123\n 'Accept: application/json',\n 'Accept-Charset: utf-8',\n 'Accept-Encoding: gzip',\n 'Cookie: auth_tkt=foo'\n ];\n\n if ($this->api_key) {\n $this->curl_headers[] = 'Authorization: ' . $this->api_key;\n }\n }", "title": "" }, { "docid": "86806cb948ab33fe18d3872e042f4286", "score": "0.667361", "text": "public function setHeader($key, $value);", "title": "" }, { "docid": "574908420c0ac07f48e14baa3152a840", "score": "0.66454774", "text": "function setHeader($field, $value);", "title": "" }, { "docid": "06b4fc5f6fa7681ff1cec56853d5b9c1", "score": "0.6632753", "text": "public function setHeader($header)\n {\n $this->_header = $header;\n }", "title": "" }, { "docid": "8464d65e052c2fa622fec2f6bb3e36fc", "score": "0.66299605", "text": "function setHeader($name) {\n $path = $name;\n if(substr($name,-11) != '.header.php') {\n $path = '/_includes/headers/' . $name . '.header.php';\n }\n $this->header = $_SERVER['DOCUMENT_ROOT'] . $path;\n }", "title": "" }, { "docid": "a45a7693f1d48bb1b8b8065866c84fd8", "score": "0.6628462", "text": "public function setHeader($header) {\n $this->header = $header;\n }", "title": "" }, { "docid": "784b21582bd8008d8edcaf6e4f560fca", "score": "0.6620566", "text": "protected function headerSettings()\n {\n $this->setPrintHeader(\n RC_Config::get('tcpdf::config.header_on')\n );\n\n $this->setHeaderFont(array(\n RC_Config::get('tcpdf::config.header_font'),\n '',\n RC_Config::get('tcpdf::config.header_font_size')\n ));\n\n $this->setHeaderMargin(\n RC_Config::get('tcpdf::config.header_margin')\n );\n\n $this->SetHeaderData(\n RC_Config::get('tcpdf::config.header_logo'),\n RC_Config::get('tcpdf::config.header_logo_width'),\n RC_Config::get('tcpdf::config.header_title'),\n RC_Config::get('tcpdf::config.header_string')\n );\n }", "title": "" }, { "docid": "e65ee9dd4748c048422b2ba2c9287a1c", "score": "0.6609064", "text": "function setHeader($header) {\n \tarray_push($this->headers, $header);\n }", "title": "" }, { "docid": "da7df6d8c2f2624c6959d533dd46ab10", "score": "0.6596936", "text": "public function setHeader(string $key, string $value): void;", "title": "" }, { "docid": "10fccd9099368ed56f8da072e2ecee96", "score": "0.65742224", "text": "public function includeHeader () {\n $this->withHeader = TRUE ;\n }", "title": "" }, { "docid": "e58b14a30a23792865a3d2616d71f315", "score": "0.6562414", "text": "function setHeader($name, $value) {\n $this->header[$name] = $value;\n }", "title": "" }, { "docid": "84cd774cdb57845c363b19d3464e61ee", "score": "0.6553057", "text": "public function setHeader( $name, $value );", "title": "" }, { "docid": "fa250c33427cd00f7cf5e9d2ec335736", "score": "0.65272313", "text": "public function headerinfo()\n\t{\n\t\t\\header($this->status);\n\t\t// process meta\n\t\tforeach ($this->meta as $key => $value)\n\t\t{\n\t\t\t\\header(\"$key: $value\");\n\t\t}\n\t}", "title": "" }, { "docid": "01f8096ff3f0b6b7bf722d4162f6889e", "score": "0.65053105", "text": "function set_header($header, $value)\n {\n }", "title": "" }, { "docid": "c7e84a83b3c4b0146630049537df4df9", "score": "0.6496829", "text": "function set_header( $header, $value ) {\n\t\t$this->headers[ $header ] = $value;\n\t}", "title": "" }, { "docid": "f906027bfd1fd9832a10b28e800cfd9c", "score": "0.64963603", "text": "public function initHeader()\r\n\t{\r\n\t\tparent::initHeader();\r\n\t\t\r\n\t\tif(Module::isInstalled('agilemultipleshop'))\r\n\t\t{\r\n\t\t\tinclude_once(_PS_ROOT_DIR_ . \"/modules/agilemultipleshop/agilemultipleshop.php\");\r\n\t\t\tAgileMultipleShop::init_shop_header();\r\n\t\t\tAgileMultipleShop::clear_blockcategory_cache();\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "693bff64472e69278227f076a49635f3", "score": "0.6495032", "text": "protected function setCorrectHeaders(): void\n {\n $this->data[0] = $this->headers;\n }", "title": "" }, { "docid": "06c9475a7bda18cfcf211cc7ab6861c8", "score": "0.64710385", "text": "public function setHeader(string $key, $value);", "title": "" }, { "docid": "a5906e1992d594c90e1d438cf529017b", "score": "0.6443512", "text": "protected function setRequestHeader()\n {\n $eWayHeaderData \t\t\t\t= new \\stdClass;\n $eWayHeaderData->eWAYCustomerID = new \\SoapVar($this->eWAYCustomerID,XSD_STRING,null, null, 'eWAYCustomerID',$this->ns);\n $eWayHeaderData->Username \t\t= new \\SoapVar($this->Username,XSD_STRING,null, null, 'Username',$this->ns);\n $eWayHeaderData->Password \t\t= new \\SoapVar($this->Password,XSD_STRING,null, null, 'Password',$this->ns);\n $headerData \t\t\t\t\t= new \\SoapVar($eWayHeaderData,SOAP_ENC_OBJECT);\n $SoapHeader \t\t\t\t = new \\SoapHeader($this->ns,'eWAYHeader',$headerData, false);\n $this->addSoapInputHeader($SoapHeader);\n }", "title": "" }, { "docid": "9daf732bac7a4920779443ba1785c2da", "score": "0.6413765", "text": "private function setHeaders()\r\n\t\t{\r\n\t\t\theader(\"HTTP/1.1 \".$this->_iCode.\" \".$this->getStatusMessage());\r\n\t\t\theader(\"Content-Type:\".$this->_sContentType);\r\n\t\t}", "title": "" }, { "docid": "2ee048883425d2f4af5d4ecc7988cacc", "score": "0.64137423", "text": "protected function set_request_headers()\r\n {\r\n $headers = array();\r\n foreach ($this->headers as $key => $value)\r\n {\r\n $headers[] = $key . ': ' . $value;\r\n }\r\n $this->setopt(CURLOPT_HTTPHEADER, $headers);\r\n }", "title": "" }, { "docid": "883012b9a14f064f5f18a34c1ef9bc4a", "score": "0.64035887", "text": "function set_CSVheaders()\n {\n $this->logI(\"CSVParser\", \"set_CSVheaders function called\");\n $this->csvfile_header = $this->_getCSVHeaderData();\n }", "title": "" }, { "docid": "1a8e9949452aeb576164646cd0f4ac1c", "score": "0.64015007", "text": "private function set_headers() {\n header(\"HTTP/1.1 \" . $this->_code . \" \" . $this->get_status_message());\n header(\"Content-Type:\" . $this->_content_type);\n }", "title": "" }, { "docid": "5ed7f027839e2f7ac1e21ff708d16992", "score": "0.64009386", "text": "public function setResponseHeaders()\n {\n $this->response->headers->set(Arr::get($this->config, 'headers.current-version'), $this->currentVersion, true);\n $this->response->headers->set(Arr::get($this->config, 'headers.request-version'), $this->requestVersion, true);\n $this->response->headers->set(Arr::get($this->config, 'headers.response-version'), $this->responseVersion, true);\n }", "title": "" }, { "docid": "4fe3b15a85c9e7237dcb6bd3e7633cfc", "score": "0.63992494", "text": "private function load_headers() {\n $headers = $this->parsed_page->headers();\n if (isset($headers['title'])) {\n $this->title = $headers['title'];\n }\n if (isset($headers['template'])) {\n $this->template = $headers['template'];\n }\n }", "title": "" }, { "docid": "f717de9cd4b8f816e655e6126e51dedf", "score": "0.6394813", "text": "function set_header($name, $value) {\n $this->headers[$name] = $value;\n }", "title": "" }, { "docid": "b40388d64d7e3df7a62a19d89d07a969", "score": "0.63856214", "text": "private function setHeaders()\n {\n if (function_exists('getallheaders')) {\n \n $this->headers = getallheaders();\n }\n else {\n \n $headers = []; \n \n foreach (array_keys($_SERVER) as $header) {\n \n if (substr($header, 0, 5) == 'HTTP_') { \n \n $headers[str_replace(' ', '-', ucwords(strtolower(str_replace('_', ' ', substr($header, 5)))))] = filter_input(INPUT_SERVER, $header); \n } \n } \n\n $this->headers = $headers; \n }\n }", "title": "" }, { "docid": "05b0d7d49830b6c4eac412e82eb2513e", "score": "0.6384721", "text": "public function set_headers() {\n global $CFG;\n\n $this->headers = array(\n 'Authorization: Bearer ' . $this->apikey,\n 'X-Turnitin-Integration-Name: Moodle',\n 'X-Turnitin-Integration-Version: tii-v' . get_config('plagiarism_turnitinsim', 'version'). '.' . $CFG->version\n );\n }", "title": "" }, { "docid": "40bfe830757aa6000517c42253a5f2dd", "score": "0.6383499", "text": "public function setHeader($file)\n {\n $this->header = $file;\n }", "title": "" }, { "docid": "7c88a2edc053f0b8be1c4ac763f73b73", "score": "0.6359715", "text": "protected function headerSettings()\n {\n $this->setPrintHeader(\n Config::get('laravel-tcpdf::header_on')\n );\n\n $this->setHeaderFont(array(\n Config::get('laravel-tcpdf::header_font'),\n '',\n Config::get('laravel-tcpdf::header_font_size')\n ));\n\n $this->setHeaderMargin(\n Config::get('laravel-tcpdf::header_margin')\n );\n\n $this->SetHeaderData(\n Config::get('laravel-tcpdf::header_logo'),\n Config::get('laravel-tcpdf::header_logo_width'),\n Config::get('laravel-tcpdf::header_title'),\n Config::get('laravel-tcpdf::header_string')\n );\n }", "title": "" }, { "docid": "8bfe942879ca79996cb40498f6a6b169", "score": "0.6359391", "text": "public function setHeader($header, $value);", "title": "" }, { "docid": "0f1baa46b6ea2ffffa136d24e0d6f283", "score": "0.6355426", "text": "function __set($header, $value) {\n\t\tif ($header == 'status')\n\t\t\t$this->setStatus($value);\n\t\telse\n\t\t\t$this->headers[$header] = (string)$value;\n\t}", "title": "" }, { "docid": "a26c364a2d80e442da6d022335fd24e0", "score": "0.63530743", "text": "public function UpdateHeaders () {\n\t\t$rawHeaders = headers_list();\n\t\t$name = '';\n\t\t$value = '';\n\t\tforeach ($rawHeaders as $rawHeader) {\n\t\t\t$doubleDotPos = strpos($rawHeader, ':');\n\t\t\tif ($doubleDotPos !== FALSE) {\n\t\t\t\t$name = trim(substr($rawHeader, 0, $doubleDotPos));\n\t\t\t\t$value = trim(substr($rawHeader, $doubleDotPos + 1));\n\t\t\t} else {\n\t\t\t\t$name = $rawHeader;\n\t\t\t\t$value = '';\n\t\t\t}\n\t\t\tif (!isset($this->disabledHeaders[$name]))\n \t\t\t\t$this->headers[$name] = $value;\n\t\t}\n\t}", "title": "" }, { "docid": "96a33053ce89bd368f645501c353bd7c", "score": "0.63460886", "text": "public function setHeader($headerStr, $type = NULL) {\n if($type == NULL ) $this->theme->header['attrs'][] = $headerAttr;\n if(strtolower($type) == 'meta') $this->theme->header['metas'][] = $headerStr;\n if(strtolower($type) == 'title') $this->theme->header['title'] = $headerStr;\n }", "title": "" }, { "docid": "859ab721cf66af8805bfa08c41dba9a9", "score": "0.63299054", "text": "function set_header( $header_name, $value ) {\n\t\tif ($value != '') {\n\t\t\t$header_name = $this->_format_header_name( $header_name );\n\t\t\t$this->_headers[$header_name] = $value;\n\t\t}\n\t}", "title": "" }, { "docid": "8437a81f353e9c1e2a6729e78a092edf", "score": "0.63290894", "text": "private function _start_header() {\n $this->_write('{\"header\":{');\n $this->_write('\"version\":\"2013-04\"');\n $this->_write(',\"scope\":[\"all\"]');\n $this->_write('}}');\n }", "title": "" }, { "docid": "271224ec19d50b2748d502d6ae92c2ca", "score": "0.6322168", "text": "function setAppHeader($head) {\n if ( $this->session_get('APP_HEADER') !== $head) {\n $this->session_put('APP_HEADER', $head);\n }\n }", "title": "" }, { "docid": "d3580a444a694d779efeb8fd4b90c0dd", "score": "0.6319792", "text": "public function prepareHeaders()\n {\n // set current date before render it\n $this->addHeader(HttpProtocol::HEADER_DATE, gmdate(DATE_RFC822));\n\n // render content length to header\n $this->addHeader(HttpProtocol::HEADER_CONTENT_LENGTH, $this->getContentLength());\n }", "title": "" }, { "docid": "24484b56d3170159cff746924c0a0b95", "score": "0.6307761", "text": "protected function set_request_headers() {\n $headers = array();\n foreach ($this->headers as $key => $value) {\n $headers[] = $key . ': ' . $value;\n }\n curl_setopt($this->request, CURLOPT_HTTPHEADER, $headers);\n }", "title": "" }, { "docid": "7004fbd4d6ad7506db7970b686e9968b", "score": "0.6298563", "text": "public function set_header($header)\n {\n $this->_headers[] = $header;\n }", "title": "" }, { "docid": "9cdef40feef85202d7e8e4021b71dfff", "score": "0.62977284", "text": "public function setHeader($header, $value = null);", "title": "" }, { "docid": "c96c5d10f7b1a0c3961a09fba32787cd", "score": "0.6282952", "text": "public function setHeader(string $header): void\n {\n $this->header = $header;\n\n }", "title": "" }, { "docid": "f83f13e63338869c824f3087e72882f4", "score": "0.62813157", "text": "protected function set_header( $header ) : void {\n\t\theader( $header );\n\t}", "title": "" }, { "docid": "f88bca43acb94da8f2963d41b2bd97ef", "score": "0.6281287", "text": "protected function setCurlHTTPRequestHeaders() {\n $idxed_headers = array();\n foreach ($this->headers as $name => $value) {\n $idxed_headers[] = \"$name: $value\";\n }\n \n curl_setopt($this->curl, CURLOPT_HTTPHEADER, $idxed_headers);\n }", "title": "" }, { "docid": "5cf218c2c8fd27accf41e56cabcb73bd", "score": "0.62760526", "text": "public function setHeader($header){\n list($k,$v) = explode(':',$header,2);\n foreach($this->headers as $_k => $_v){\n if(trim(strtolower($_k)) == trim(strtolower($k))){\n $k = $_k;\n break;\n }\n }\n $this->headers[trim($k)] = trim($v);\n }", "title": "" }, { "docid": "61a2d0ca2064782e9e59533a3299a579", "score": "0.6269915", "text": "protected function LoadHeaders()\n\t{\n\t\t$this->headers[] = 'Content-Type: application/json';\n\t}", "title": "" }, { "docid": "dd03b71316dc86ccdf37fdadfb82b51f", "score": "0.62617284", "text": "public function setHeaders() {\n\t\tglobal $wgOut;\n\t\t$wgOut->setArticleRelated( false );\n\t\t$wgOut->setRobotPolicy( 'noindex,nofollow' );\n\t\t$wgOut->setPageTitle( $this->getDescription() );\n\t}", "title": "" }, { "docid": "01c4d27c14f04da0baa6102a1d669f88", "score": "0.62581307", "text": "function _print_header_information()\n\t{\n\t\t$this->config->load('header_info');\n \n $this->up_templater->assign('site_charset', $this->config->item('site_charset'));\n\t\t$this->up_templater->assign('logo_full', $this->config->item('logo_full'));\n\t\t$this->up_templater->assign('site_keywords', $this->config->item('site_keywords'));\n\t\t$this->up_templater->assign('site_add_keywords', $this->config->item('site_add_keywords'));\n\t\t$this->up_templater->assign('author', $this->config->item('author'));\n\t\t$this->up_templater->assign('copyright', $this->config->item('copyright'));\n\t\t$this->up_templater->assign('favicon', $this->config->item('favicon'));\n\t\t$this->up_templater->assign('cssname', $this->app_mode);\n\t\t\n\t\t$this->up_templater->assign('appversion', $this->config->item('appversion'));\n\t\t$this->up_templater->assign('sitename', $this->config->item('sitename'));\n\t}", "title": "" }, { "docid": "a71d803f56fbee75e6737384bbb98ad2", "score": "0.6250011", "text": "public function updateHeader() {\n if (strpos($this->type, 'h') != 0) {\n $this->type = 'h1';\n }\n else {\n $count = (int)str_replace('h', '', $this->type);\n $count++;\n $this->type = \"h$count\";\n }\n }", "title": "" }, { "docid": "bf5cc632ee36be92ef1cb7403f38b0a1", "score": "0.62449014", "text": "protected function LoadHeaders()\n\t{\n\t}", "title": "" }, { "docid": "dae55ba8e1139542b150a63cb3f87646", "score": "0.6239689", "text": "public function setHeaders()\n {\n header('Content-type: application/json');\n\n // Calculate Expires Headers if set to > 0\n $expires = $this->grav['config']->get('system.pages.expires');\n if ($expires > 0) {\n $expires_date = gmdate('D, d M Y H:i:s', time() + $expires) . ' GMT';\n header('Cache-Control: max-age=' . $expires);\n header('Expires: ' . $expires_date);\n }\n\n // TODO: Set Last-Modified\n // TODO: Set the ETag\n // TODO: Set the HTTP response code\n // TODO: Set the Date\n }", "title": "" }, { "docid": "e81c9aa1fb4b91fc0c509891e3689436", "score": "0.6222971", "text": "public function set_header($key, $val)\n\t{\n\t\t$this->headers[$key] = $val;\n\t}", "title": "" }, { "docid": "fdc87670014d7da466edccd74de2f655", "score": "0.6208198", "text": "public function setHeader($header) {\n if (gettype($header) === \"array\") {\n foreach ($header as $key => $value)\n header($value);\n } else {\n header($header);\n }\n }", "title": "" }, { "docid": "4349ce14142034825cc5985f8e1885cb", "score": "0.620339", "text": "function resetHeaderLines() {\n\t\t$this->headerLines = Array();\n\t\t\n\t\t/*******************************************************************************/\n\t\t/************** YOU MAX SET THE USER AGENT STRING HERE *******************/\n\t\t/* */\n\t\t/* default is \"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)\", */\n\t\t/* which means Internet Explorer 6.0 on WinXP */\n\t\t\n\t\t$this->headerLines[\"User-Agent\"] = \"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)\";\n\t\t\n\t\t/*******************************************************************************/\n\t\t\n\t}", "title": "" }, { "docid": "dd20041a2f95a89203b8750db0cffbef", "score": "0.6202948", "text": "private function normalize_header() {\n\t\tif (!$this->skeleton->built('header')) {\n\t\t\t$header = self::fetch('vendor_header', [':vendors_id' => $this->id()]);\n\t\t}\n\t\telse {\n\t\t\t$header = $this->skeleton->get('header');\n\t\t\t$this->skeleton->rebuild('header');\n\t\t}\n\n\t\tforeach (['date_account_created', 'last_modified', 'last_login_date'] as $field) {\n\t\t\t$header[$field] = ck_datetime::datify($header[$field]);\n\t\t}\n\n\t\t$this->skeleton->load('header', $header);\n\t}", "title": "" }, { "docid": "10369c2d358a197377a8d4e862f4b638", "score": "0.6197385", "text": "function setHeader($name, $value) {\n\n\t\t\t$this->headers[$name] = $value;\n\t\t}", "title": "" }, { "docid": "2912b1585dbf4e259f20d7ae4e97c23f", "score": "0.6183063", "text": "protected function set_headers(){\n\t\t\t$this->args = array();\n\t\t}", "title": "" }, { "docid": "559465f85866994850c999b2f22e948d", "score": "0.61786145", "text": "static function setHeader($header, $value) {\n header($header . ': ' . $value);\n }", "title": "" }, { "docid": "cf46ea4b4f0892fbba37c64b02a6746b", "score": "0.61668235", "text": "function setCustomHeader($g)\n\t{\n\t\t$this->customHeader = $g;\n\t}", "title": "" }, { "docid": "b5c0c0e378e80dfecf8bd510c31740e6", "score": "0.61650044", "text": "public function modifyHeader($key, $value)\n {\n $this->header->$key = $value;\n }", "title": "" }, { "docid": "d7f718f8dfbc2a036842917eeb86b478", "score": "0.61586267", "text": "protected function setHeaderForServer()\n {\n header($this->protocol().' '.$this->getStatusCode().' '.ResponseHeader::$httpStatus[$this->getStatusCode()]);\n }", "title": "" }, { "docid": "19aff8816d7cdc8a135eeb7cb2320aad", "score": "0.61417174", "text": "public function setHeader($header, $info)\n {\n // do nothing in base class\n return $this;\n }", "title": "" }, { "docid": "3716f105f830212ced15f0d62436ccf0", "score": "0.61372054", "text": "public function setHeader(UIComponent $header) {\n $this->getFacets()->put(\"header\", $header);\n }", "title": "" }, { "docid": "a70b6be7595e2f8c281e8e6a232732bd", "score": "0.6136797", "text": "protected function setHeaders($headers){\n }", "title": "" }, { "docid": "f25e653fb033acd725b44eaa0cd9ea6e", "score": "0.61321664", "text": "public function setHeader($header)\n {\n if (is_array($header))\n {\n curl_setopt($this->_handle, CURLOPT_HTTPHEADER, $header);\n }\n }", "title": "" }, { "docid": "681fe451cd7c6e0aff753d1bb39f71e5", "score": "0.6131739", "text": "function setHeaders($headers) {\n $this->header = array_merge($this->header, $headers);\n }", "title": "" }, { "docid": "1dcab97085348f8bc3142edcfa412f12", "score": "0.6117642", "text": "private function writeHeader()\n {\n $this->write(AvroDataIO::magic());\n $this->datumWriter->writeData(AvroDataIO::metadatSchema(), $this->metadata, $this->encoder);\n $this->write($this->syncMarker);\n }", "title": "" }, { "docid": "36c569a367cadc85b6dc674a040f8349", "score": "0.610799", "text": "public function setHeader($header)\n {\n header($header);\n }", "title": "" }, { "docid": "b24d035cd37e2fa5a1ca2a96bed7321d", "score": "0.6106335", "text": "public function testSetHeader()\n {\n $this->todo('stub');\n }", "title": "" }, { "docid": "9200a4bfb2d8c1a45d1139e70161f0e0", "score": "0.60998034", "text": "public function initHeader() {\n\n // Added powered by for builtwith.com\n header('Powered-By: ephenyx');\n // Hooks are voluntary out the initialize array (need those variables already assigned)\n $this->context->smarty->assign(\n [\n 'time' => time(),\n 'img_update_time' => Configuration::get('EPH_IMG_UPDATE_TIME'),\n 'static_token' => Tools::getToken(false),\n 'token' => Tools::getToken(),\n 'priceDisplayPrecision' => _EPH_PRICE_DISPLAY_PRECISION_,\n 'content_only' => (int) Tools::getValue('content_only'),\n\t\t\t\t'display_slider' => Configuration::get('EPH_HOME_SLIDER_ACTIVE'),\n\n ]\n );\n\n $this->context->smarty->assign($this->initLogoAndFavicon());\n }", "title": "" }, { "docid": "79cc93cb88eda09ee3db5e802370e47d", "score": "0.60930157", "text": "public function setHeader($key, $value)\n {\n $this->headers[$key] = $value;\n }", "title": "" }, { "docid": "79cc93cb88eda09ee3db5e802370e47d", "score": "0.60930157", "text": "public function setHeader($key, $value)\n {\n $this->headers[$key] = $value;\n }", "title": "" }, { "docid": "a29610345fabc29be9571cf9f82ac799", "score": "0.6081159", "text": "public function setHeader($name, $value)\n { \n $this->_headers[$name] = $value;\n }", "title": "" }, { "docid": "712024ccd9789c1f008fb90fc22f3c96", "score": "0.60739934", "text": "protected function LoadHeaders()\n\t{\n\t\tif (isset($this->params['statuscode']) && !empty($this->params['statuscode'])) {\n\t\t\t$partialHeader = $this->StatusCodeHeader($this->params['statuscode']);\n\t\t\tif (!empty($partialHeader)) {\n\t\t\t\tif (substr(php_sapi_name(), 0, 8) == 'cgi-fcgi') {\n\t\t\t\t\t/*\n\t\t\t\t\t * FastCGI requires a different header\n\t\t\t\t\t */\n\t\t\t\t\t$this->headers[] = 'Status: ' . $partialHeader;\n\t\t\t\t} else {\n\t\t\t\t\t$this->headers[] = 'HTTP/1.1 ' . $partialHeader;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "c285c3e5a32cafd3cf90e8a3f26ff653", "score": "0.6073897", "text": "public function setHeaderImage($headerImage) {\r\n $this->headerImage = $headerImage;\r\n }", "title": "" }, { "docid": "b42e7f2225f541891ea3607f3f075857", "score": "0.6072435", "text": "function setGssHeader($value = true) {\n \t$this->withGssHeader = $value;\n }", "title": "" }, { "docid": "9de2318a8883af671cf43c3239ab8778", "score": "0.60711765", "text": "private function normalize_header() {\n\t\tif (!$this->skeleton->built('header')) {\n\t\t\t$header = self::fetch('rma_header', [':rma_id' => $this->id()]);\n\t\t}\n\t\telse {\n\t\t\t$header = $this->skeleton->get('header');\n\t\t\t$this->skeleton->rebuild('header');\n\t\t}\n\n\t\t$date_fields = ['follow_up_date', 'created_on'];\n\t\tforeach ($date_fields as $field) {\n\t\t\t$header[$field] = ck_datetime::datify($header[$field]);\n\t\t}\n\n\t\t$bool_fields = ['closed', 'refund_shipping', 'refund_coupon'];\n\t\tforeach ($bool_fields as $field) {\n\t\t\t$header[$field] = CK\\fn::check_flag($header[$field]);\n\t\t}\n\n\t\t$this->skeleton->load('header', $header);\n\t}", "title": "" }, { "docid": "0e1ec73a9b3807fa90ec376864030a7e", "score": "0.6067748", "text": "public function header($header, $value){\n $this->headers[$header] = $value;\n }", "title": "" }, { "docid": "a9816744fef0719b0f7a3b23d48aba6b", "score": "0.6067596", "text": "private function writeHeader() {\n $this->write(AvroDataIO::magic());\n AvroDataIO::metadataSchema()->write($this->metadata, $this->encoder);\n $this->write($this->syncMarker);\n }", "title": "" }, { "docid": "f4098e81ae87d12b2554fd4abc560eaa", "score": "0.60673684", "text": "protected function setHeaderForServer()\n {\n header($this->protocol().' '.$this->getStatusCode().' '.static::$httpStatus[$this->getStatusCode()]);\n }", "title": "" } ]
9b0701713a2da837188af6ecd6f8200a
1.8 Upgrades. a. Upgrade checkbox settings to radio button settings. a. Update form meta for new metabox settings.
[ { "docid": "16c00ebce3a00e5fae8c696f9bf92c3d", "score": "0.7444866", "text": "function give_v18_upgrades() {\n\t// Upgrade checkbox settings to radio button settings.\n\tgive_v18_upgrades_core_setting();\n}", "title": "" } ]
[ { "docid": "e2d817fa309b439c81f454b1b0121d51", "score": "0.6500074", "text": "function update_me_admin()\n {\n global $xoouserultra, $uultra_group;\n\n require_once(ABSPATH . 'wp-includes/pluggable.php');\n\n $user_id = $_POST['user_id'];\n\n //get user form\n $custom_form = $this->get_user_meta_custom($user_id, 'uultra_custom_registration_form');\n\n if($custom_form!=\"\")\n {\n $custom_form = 'usersultra_profile_fields_'.$custom_form;\n $array = get_option($custom_form);\n\n }else{\n\n $array = get_option('usersultra_profile_fields');\n\n }\n\n $array_check = $array;\n\n\n // Get list of dattime fields\n $date_time_fields = array();\n\n foreach ($array as $key => $field)\n {\n extract($field);\n\n if (isset($array[$key]['field']) && $array[$key]['field'] == 'checkbox')\n {\n //echo \"is meta field: \" .$meta;\n update_user_meta($user_id, $meta, null);\n }\n\n // Filter date/time custom fields\n if (isset($array[$key]['field']) && $array[$key]['field'] == 'datetime')\n {\n array_push($date_time_fields, $array[$key]['meta']);\n }\n\n\n }\n\n /* Check if the were errors before updating the profile */\n if (!isset($this->errors))\n {\n /* Now update all user meta */\n foreach($this->usermeta as $key => $value)\n {\n // save checkboxes\n if (is_array($value))\n { // checkboxes\n $value = implode(', ', $value);\n }\n //echo $key. \" \";\n update_user_meta($user_id, \"hide_\".$key, \"\");\n\n\n if($key==\"display_name\")\n {\n wp_update_user( array( 'ID' => $user_id, 'display_name' => esc_attr($value) ) );\n }\n\n\n if ($this->field_allow_html($key,$array_check))\n {\n update_user_meta($user_id, $key, $value);\n\n }else{\n\n update_user_meta($user_id, $key, esc_attr($value));\n\n\n }\n\n\n }\n\n //upate activity\n\n\n }\n\n\n //update user groups\n if($user_id !='' && isset($uultra_group))\n {\n //delete user's groups\n $uultra_group->groups_and_users_rel_del($user_id);\n\n $groups = array();\n\n if(isset($_POST['uultra_user_group']))\n {\n $groups = $_POST['uultra_user_group'];\n\n foreach ($groups as $group )\n {\n //add user to group\n $uultra_group->save_user_group_rel($user_id, $group);\n\n }\n\n }\n\n }\n\n\n\n }", "title": "" }, { "docid": "108a05cc5982573216df1f1f90fb94f8", "score": "0.6441303", "text": "function theme_front_page_settings() { \r\n// Check that the user is allowed to update options \r\nif (!current_user_can('manage_options')) { \r\n wp_die('You do not have sufficient permissions to access this page.'); \r\n} \r\n\r\n\r\nif (isset($_POST[\"update_settings\"])) { \r\n\tupdate_option(\"metroui_theme_show_navbar\", (isset($_POST['nav-bar']) ? true : false)); \r\n\tupdate_option(\"metroui_theme_show_sidebar\", (isset($_POST['sidebar']) ? true : false)); \r\n\tupdate_option(\"metroui_theme_show_search\", (isset($_POST['search']) ? true : false)); \r\n\tupdate_option(\"metroui_theme_show_credits\", (isset($_POST['show-credits']) ? true : false)); \r\n\tupdate_option(\"metroui_theme_show_social\", (isset($_POST['social']) ? true : false)); \r\n\tupdate_option(\"metroui_theme_comment_cs\", $_POST['comment-cs']);\r\n} \r\n \r\n?>\r\n<style>\r\nform {\r\n\tpadding:20px;\r\n\tfont-size:16px;\r\n}\r\nlabel {\r\n\tline-height:30px;\r\n}\r\ninput[type=checkbox], input[type=radio]\r\n{\r\n\theight:25px;\r\n -ms-transform: scale(2); /* IE */\r\n -moz-transform: scale(2); /* FF */\r\n -webkit-transform: scale(2); /* Safari and Chrome */\r\n -o-transform: scale(2); /* Opera */\r\n\r\n}\r\n</style>\r\n <?php screen_icon('themes'); ?> <h2>MetroUI Theme Options</h2> \r\n <div class=\"major-publishing-actions\"> \r\n\t\t<form action=\"\" method=\"post\">\r\n\t\t\t <input id=\"nav-bar\" name=\"nav-bar\" type=\"checkbox\" <?php echo get_option(\"metroui_theme_show_navbar\")? 'checked=\"checked\"': \"\"; ?> > <label for=\"nav-bar\">Show Top Navigation Bar</label>\r\n\t\t\t<br><br>\r\n\t\t\t<input id=\"search\" name=\"search\" type=\"checkbox\" <?php echo get_option(\"metroui_theme_show_search\")? 'checked=\"checked\"': \"\"; ?> > <label for=\"search\">Show Search Form</label> \r\n\t\t\t<br><br>\r\n\t\t\t<input id=\"sidebar\" name=\"sidebar\" type=\"checkbox\" <?php echo get_option(\"metroui_theme_show_sidebar\")? 'checked=\"checked\"': \"\"; ?> > <label for=\"sidebar\">Show Sidebar</label> \r\n\t\t\t<br><br>\r\n\t\t\t<input id=\"show-credits\" name=\"show-credits\" type=\"checkbox\" <?php echo get_option(\"metroui_theme_show_credits\")? 'checked=\"checked\"': \"\"; ?> > <label for=\"show-credits\">Show Credits</label> \r\n\t\t\t<br><br>\r\n\t\t\t<input id=\"social\" name=\"social\" type=\"checkbox\" <?php echo get_option(\"metroui_theme_show_social\")? 'checked=\"checked\"': \"\"; ?> > <label for=\"social\">Show Social Buttons</label> \r\n\t\t\t<br><br>\r\n\t\t\tComment Bar Color Scheme<br>\r\n\t<input id=\"light\" value=\"light\" name=\"comment-cs\" type=\"radio\" <?php if(get_option(\"metroui_theme_comment_cs\")==\"light\") echo 'checked=\"checked\"'; ?> > <label for=\"light\">Light</label> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\r\n\t<input id=\"dark\" value=\"dark\" name=\"comment-cs\" type=\"radio\" <?php if(get_option(\"metroui_theme_comment_cs\")==\"dark\") echo 'checked=\"checked\"'; ?>> <label for=\"dark\">Dark</label> \r\n\t\t\t<br><br>\r\n\t\t\t<?php if (isset($_POST[\"update_settings\"])) echo \"Setting Updated<br><br>\"; ?>\r\n\t\t\t<input type=\"hidden\" name=\"update_settings\" value=\"Y\" /> \r\n\t\t\t<input type=\"submit\" value=\"Save Settings\" class=\"button button-primary\">\r\n\t\t</form>\r\n\t</div>\r\n<?php\r\n}", "title": "" }, { "docid": "45e0744cedf8c8f7ce221c857ad446fc", "score": "0.6295479", "text": "function _set_manage_form($form, &$form_state) {\n $default = _get_serialized();\n $active = variable_get('easysignup_active', array());\n $form['choose'] = array(\n '#type' => 'fieldset',\n '#title' => t('Your interests'),\n '#collapsible' => TRUE,\n '#collapsed' => FALSE,\n );\n $form['choose']['description'] = array(\n '#type' => 'markup',\n '#markup' => t('Update your subscription'),\n );\n foreach ($active as $type => $cnf) {\n $form['choose'][$type] = array(\n '#type' => 'checkbox',\n '#title' => _get_node_name($type),\n '#default_value' => isset($default[$type]) ? 1 : 0,\n );\n $form['choose']['container_|_' . $type] = array(\n '#type' => 'container',\n '#title' => t('Options'),\n '#prefix' => '<div class=\"sub-container\">',\n '#suffix' => '</div>',\n );\n if ($cnf['comment'] == 1) {\n $form['choose']['container_|_' . $type][$type . '_|_comment'] = array(\n '#type' => 'checkbox',\n '#title' => t('Comments'),\n '#default_value' => (isset($default[$type]) && $default[$type]['comment'] == 1) ? 1 : 0,\n '#prefix' => '<div class=\"sub-comment\">',\n '#suffix' => '</div>'\n );\n }\n }\n $form['submit'] = array(\n '#type' => 'submit',\n '#prefix' => '<div class=\"form-actions\">',\n '#suffix' => '</div>',\n '#value' => t('Submit'),\n );\n $form['#attributes']['class'][] = 'manage-subscription';\n $form['#submit'][] = '_set_manage_form_submit';\n //dpm(get_defined_vars());\n return $form;\n}", "title": "" }, { "docid": "37134f5eb4a8446bec4b815bc91d8b4d", "score": "0.62515473", "text": "function xmlimport_admin_settings_submit($form, &$form_state) {\n\n // ... and save the settings\n system_settings_form_submit($form, $form_state);\n}", "title": "" }, { "docid": "a92f8e4b36d90b2937f413bc1e6ca466", "score": "0.61613727", "text": "function nm_meta_box () {\n\tglobal $post;\n\t// Use nonce for verification\n\techo '<input type=\"hidden\" name=\"nm_nonce\" id=\"nm_nonce\" value=\"' . \n\twp_create_nonce( plugin_basename(__FILE__) ) . '\" />';\n\t\n\t//Output checkboxes \n\t$fields = array(\n\t\t'original_source' => 'Original Source (*)',\n\t\t'cancelled' => 'NM Cancelled',\n\t);\n\t$defaults = nm_default_options();\n\tforeach ($fields as $field => $legend) {\n\t\t$current_setting = get_post_meta($post->ID, $field, true);\n\t\tif (! $current_setting) {\n\t\t\t$current_setting = $defaults[$field];\n\t\t}\n\t\t$current_setting = $current_setting != 'no';\n?>\n<label for=\"nm_<?php echo $field; ?>\">\n\t<input type=\"checkbox\" name=\"nm_<?php echo $field; ?>\" id=\"nm_<?php echo $field; ?>\" <?php\n\t\tif ($current_setting) echo ' checked=\"checked\"';\n\t?>/>\n\t<?php echo $legend; ?>\n</label>\n<br /> \n<?php\n\t}\n}", "title": "" }, { "docid": "92837dbf6c4dd5540140eb2bc5c6d064", "score": "0.6141551", "text": "function formantibot_upgrade($oldversion)\n{\n // Upgrade dependent on old version number\n switch($oldversion) {\n case '0.1.0':\n\n if (!xarModRegisterHook('item', 'create', 'API',\n 'formantibot', 'admin', 'createhook')) {\n return false;\n }\n\n if (!xarModRegisterHook('item', 'new', 'GUI',\n 'formantibot', 'admin', 'newhook')) {\n return false;\n }\n\n xarModSetVar('formantibot','registered',false);\n\n case '0.5.0':\n\n //get rid of this one - creates problems calling it too early\n if (!xarModUnregisterHook('item', 'create', 'API',\n 'formantibot', 'admin', 'createhook')) {\n return false;\n }\n if (!xarModRegisterHook('item', 'submit', 'API',\n 'formantibot', 'admin', 'submithook')) {\n return false;\n }\n case '0.6.0':\n $settingstring = xarModGetVar('formantibot','settings');\n $settings = unserialize($settingstring);\n $settings['ttf_file_path']= 'modules/formantibot/fonts';\n $settings['ttf_file_name'] = 'elephant.ttf';\n $settings['ttf_file'] = $settings['ttf_file_path'].'/'.$settings['ttf_file_name'];\n xarModSetVar('formantibot','settings',serialize($settings));\n case '0.6.1': //current version\n $settingstring = xarModGetVar('formantibot','settings');\n $settings = unserialize($settingstring);\n $settings['removeambichars'] = false;\n $settings['caseinsensitive'] = false;\n xarModSetVar('formantibot','settings',serialize($settings));\n case '0.6.2':\n case '0.6.3':\n $settingstring = xarModGetVar('formantibot','settings');\n $settings = unserialize($settingstring);\n $settings['uppercaseonly'] = false;\n xarModSetVar('formantibot','settings',serialize($settings));\n case '0.7.0':\n //Delete any nasty vars\n $dbconn = xarDBGetConn();\n $tables = xarDBGetTables();\n $modBaseInfo = xarMod_getBaseInfo('formantibot');\n $query = 'DELETE FROM '.$tables['module_vars'].' WHERE xar_modid = ? and xar_name LIKE ?';\n $result = $dbconn->Execute($query, array($modBaseInfo['systemid'],'code%'));\n $result->close();\n\n case '0.7.1':\n //update to reflect move to 1.4.0 xarigami only code\n $settingstring = xarModGetVar('formantibot','settings');\n $settings = unserialize($settingstring);\n $settings['captchaprivate'] = '';\n $settings['captchapublic'] = '';\n xarModSetVar('formantibot','settings',serialize($settings));\n case '0.8.0':\n case '0.8.1': //indicate code changes for 1.4.0\n case '0.8.2': //current version\n break;\n\n }\n return TRUE;\n}", "title": "" }, { "docid": "04924f1374f60ff087c3685d747bd627", "score": "0.6129395", "text": "function ncstate_official_form_system_theme_settings_alter(&$form, $form_state) {\n\n// Generate the form using Forms API. http://api.drupal.org/api/7\n $form['custom'] = array(\n '#title' => 'Custom theme settings', \n '#type' => 'fieldset', \n );\n \n $form['custom']['title_image_url'] = array(\n '#title' => 'Site Title Image Full URL',\n '#description' => t('Transparent PNG / GIF title of your site. OIT Design (http://oitdesign.ncsu.edu) can create this correctly for you. Must include http:// or https://'),\n '#type' => 'textfield',\n '#default_value' => theme_get_setting('title_image_url'),\n '#size' => 120,\n '#maxlength' => 255,\n '#required' => TRUE,\n );\n\n $form['custom']['site_title_vertical_offset'] = array(\n '#title' => 'Site Title Vertical Offset (px)',\n '#description' => t('Move the site title vertically (helpful if you change the size or font options). NOTE: include \"px\" on the end of your offset.'),\n '#type' => 'textfield',\n '#default_value' => theme_get_setting('site_title_vertical_offset'),\n '#size' => 6,\n '#maxlength' => 5,\n '#required' => TRUE,\n );\n\n $form['custom']['site_title_horizontal_offset'] = array(\n '#title' => 'Site Title Horizontal Offset (px)',\n '#description' => t('Move the site title horizontally (helpful if you change the size or font options). NOTE: include \"px\" on the end of your offset.'),\n '#type' => 'textfield',\n '#default_value' => theme_get_setting('site_title_horizontal_offset'),\n '#size' => 6,\n '#maxlength' => 5,\n '#required' => TRUE,\n );\n\n $form['custom']['show_breadcrumbs'] = array(\n '#title' => 'Show Breadcrumbs when available',\n '#type' => 'select',\n '#default_value' => theme_get_setting('show_breadcrumbs'),\n '#options' => array(\n 0 => 'False',\n 1 => 'True',\n ),\n );\n\n $form['custom']['breadcrumb_separator'] = array(\n '#title' => 'Breadcrumb Separator',\n '#description' => t('The character that will go in between breadcrumb items. Include spaces if necessary'),\n '#type' => 'textfield',\n '#default_value' => theme_get_setting('breadcrumb_separator'),\n '#size' => 15,\n '#maxlength' => 10,\n '#required' => FALSE,\n );\n\n $form['custom']['show_post_info_on_search'] = array(\n '#title' => 'Show Post Information on Search Results',\n '#type' => 'select',\n '#default_value' => theme_get_setting('show_post_info_on_search'),\n '#options' => array(\n 0 => 'False',\n 1 => 'True',\n ),\n );\n\n $sliderTransitionTimeArray = array(\n 1000 => '1 Second',\n 3000 => '3 Seconds',\n 5000 => '5 Seconds',\n 10000 => '10 Seconds',\n 15000 => '15 Seconds',\n 20000 => '20 Seconds',\n 30000 => '30 Seconds',\n 60000 => '60 Seconds',\n );\n\n $form['custom']['slider_transition_time'] = array(\n '#type' => 'select',\n '#title' => t('Set the slider transition time'),\n '#default_value' => theme_get_setting('slider_transition_time'),\n '#description' => t(\"<p>This is the amount of seconds each slide will display before transitioning to the next panel. If you are not using a slider anywhere on your site, ignore this setting.</p>\"),\n '#required' => TRUE,\n '#options' => $sliderTransitionTimeArray,\n );\n\n $form['custom']['copyright_information'] = array(\n '#title' => 'Copyright information',\n '#description' => t('Information about copyright holder of the website - will show up at the bottom of the page'),\n '#type' => 'textfield',\n '#default_value' => theme_get_setting('copyright_information'),\n '#size' => 60,\n '#maxlength' => 128,\n '#required' => FALSE,\n );\n\n $form['custom']['footer_contact_information'] = array(\n '#title' => 'Footer Contact Information',\n '#description' => t('For example: North Carolina State University Raleigh, NC 27695 Phone: (919) 515-2011'),\n '#type' => 'textfield',\n '#default_value' => theme_get_setting('footer_contact_information'),\n '#size' => 60,\n '#maxlength' => 128,\n '#required' => TRUE,\n );\n \n $form['custom']['social_facebook_url'] = array(\n '#title' => 'Facebook page URL',\n '#description' => t('Change this to your own facebook URL, or leave as the default (http://facebook.com/ncstate)'),\n '#type' => 'textfield',\n '#default_value' => theme_get_setting('social_facebook_url'),\n '#size' => 60,\n '#maxlength' => 128,\n '#required' => TRUE,\n );\n \n \n $form['custom']['social_youtube_url'] = array(\n '#title' => 'Youtube Account URL',\n '#description' => t('Change this to your own youtube channel URL, or leave as the default (http://youtube.com/ncstate)'),\n '#type' => 'textfield',\n '#default_value' => theme_get_setting('social_youtube_url'),\n '#size' => 60,\n '#maxlength' => 128,\n '#required' => TRUE,\n );\n \n \n $form['custom']['social_twitter_url'] = array(\n '#title' => 'Twitter Account URL',\n '#description' => t('Change this to your own twitter account URL, or leave as the default (http://twitter.com/ncstate)'),\n '#type' => 'textfield',\n '#default_value' => theme_get_setting('social_twitter_url'),\n '#size' => 60,\n '#maxlength' => 128,\n '#required' => TRUE,\n );\n\n}", "title": "" }, { "docid": "1a713de4fd18c4f51593c2836fcf0346", "score": "0.6098431", "text": "function updateForms() {\r\n\t\r\n\tglobal $db;\r\n\t\r\n\t$db->setFetchMode( DB_FETCHMODE_ASSOC );\r\n\t\r\n\tinclude_once( DOC_ROOT . 'manage/settingsList.php' );\r\n\t\r\n\t$forms = $db->getAll( 'select * from '. DB_PREFIX.'_forms' );\r\n\t\r\n\t$replaceValues = array(\r\n\t\t'mail_to_address' => 'form_to',\r\n\t\t'copy_to' => 'form_cc',\r\n\t\t'mail_subject' => 'form_subject',\r\n\t\t'login_form' => 'login_form',\r\n\t\t'generate_report' => 'generate_report',\r\n\t\t'is_default' => 'is_default',\r\n\t\t'skin_id' => 'skin_id',\r\n\t\t'title' => 'form_title',\r\n\t\t'description' => 'form_desc',\r\n\t);\r\n\t\r\n\tforeach( $forms as $num=>$form ) {\r\n\t\t\r\n\t\t$site_data = $db->getRow( 'select default_resource_type, default_resource_id, login_form_id from '. DB_PREFIX.\"_sites where site_key='$form[site_key]'\" );\r\n\t\t\r\n\t\tif ( $site_data['default_resource_type'] == 'form' && $site_data['default_resource_id'] == $form['id'] )\r\n\t\t\t$form['is_default'] = 'yes';\r\n\t\telse\r\n\t\t\t$form['is_default'] = 'no';\r\n\t\t\t\r\n\t\tif ( $site_data['login_form_id'] == $form['id'] )\r\n\t\t\t$form['login_form'] = 'yes';\r\n\t\telse\r\n\t\t\t$form['login_form'] = 'no';\r\n\t\t\t\r\n\t\t$form['generate_report'] = $form['generate_report'] == 1 ? 'yes' : 'no';\r\n\t\t\r\n\t\t\r\n foreach( $formSettings as $property=>$setting ) {\r\n \r\n\t\t\tif ( array_key_exists( $property, $replaceValues ) )\r\n\t\t\t\t$value = $form[$replaceValues[$property]];\r\n\t\t\telse\r\n\t\t\t\t$value = $setting[2];\r\n\t\t\t\r\n $exists = $db->getOne( 'select resource_id from '.DB_PREFIX.\"_settings where resource_type='form' and resource_id='{$form['id']}' and property='$property'\" );\r\n \r\n if ( !$exists )\r\n\t\t\t\t$db->query( 'insert into '. DB_PREFIX.\"_settings ( site_key, resource_type, resource_id, property, value ) values ( '$form[site_key]', 'form', '$form[id]', '$property', '$value' )\" );\r\n }\r\n\t}\r\n}", "title": "" }, { "docid": "dc22dfefa51704ea5e22130e5f7e5a83", "score": "0.60753953", "text": "function islandora_solr_custom_admin_settings() {\n // set form variable\n $form = array();\n\n // check if there are any changes between solrconfig.xml/luke and the DB.\n $solr_check = _islandora_solr_custom_check();\n //kpr($solr_check);\n $updates = FALSE;\n // if it's not empty (there are changes), put up a message.\n if (!empty($solr_check)) {\n // changes are detected, put a message up.\n $message = '<p>';\n\n if (isset($solr_check['add'])) {\n foreach ($solr_check['add'] as $key => $value) {\n $message .= '<span class=\"islandora_solr_custom_add\">+ ' . $value . '</span><br />';\n }\n }\n\n if (isset($solr_check['remove'])) {\n foreach ($solr_check['remove'] as $key => $value) {\n $message .= '<span class=\"islandora_solr_custom_remove\">- ' . $value . '</span><br />';\n }\n }\n $message .= '</p>';\n\n //kpr($message);\n\n $form['updates'] = array(\n '#type' => 'fieldset',\n// '#title' => t('Field updates'),\n '#collapsible' => FALSE,\n '#collapsed' => FALSE,\n '#weight' => -10,\n '#description' => '<div class=\"messages warning\"><strong>' . t('Warning!') . '</strong><br />' . t('The following changes are detected between solrconfig.xml (or luke) and the values saved in the DB. To apply these changes re-submit the form.') . '</div>',\n );\n\n $form['updates']['updates_markup'] = array(\n '#type' => 'markup',\n '#value' => $message,\n );\n\n\n // set updates variable for the hidden field\n $updates = TRUE;\n }\n\n // add a hidden field\n $form['islandora_solr_custom_updates'] = array(\n '#type' => 'hidden',\n '#value' => $updates,\n '#weight' => -1,\n );\n\n \n \n \n // form: General settings\n $form['general_settings'] = array(\n '#type' => 'fieldset',\n '#title' => t('General settings'),\n '#collapsible' => TRUE,\n '#collapsed' => FALSE,\n '#tree' => TRUE, // this attribute is important to return the submitted values in a deeper nested arrays in $form_state['values'] . See http://drupal.org/node/751826\n '#weight' => -6,\n );\n $form['general_settings']['human_readable_name'] = array(\n '#type' => 'textfield',\n '#title' => t('Human readable name'),\n '#default_value' => variable_get('islandora_solr_custom_human_readable_name', t('Custom')),\n '#description' => t('Set the user readable name for this display'),\n '#weight' => -10,\n );\n\n\n \n \n\n\n\n\n\n\n // form: Field settings\n // create a new fieldset where we can put the rendered table in. Couldn't make that work with the actual fieldset of the table form items.\n $form['islandora_solr_custom_table_output'] = array(\n '#type' => 'fieldset',\n '#title' => t('Field settings'),\n '#collapsible' => TRUE,\n '#collapsed' => FALSE,\n '#tree' => FALSE, // not needed as this fieldset just outputs the rendered table.\n '#description' => t('Modify the field settings'),\n '#weight' => -5,\n );\n $form['islandora_solr_custom_table_output']['table_output_markup'] = array(\n '#type' => 'markup',\n '#value' => '',\n );\n\n // set the table form items\n $form['islandora_solr_custom_table'] = array(\n '#type' => 'fieldset',\n '#tree' => TRUE, // this attribute is important to return the submitted values in a deeper nested arrays in\n //$form_state['values'] . See http://drupal.org/node/751826\n );\n\n\n\n $solrconfig = _islandora_solr_custom_db_values($check = FALSE); // get the solrconfig.xml and DB results. Also fix the differences between solrconfig.xml and the DB\n foreach ($solrconfig as $field) {\n\n $fieldname = $field['field'];\n\n $form['islandora_solr_custom_table'][$fieldname]['field'] = array(\n '#type' => 'markup',\n '#value' => $field['field'],\n '#weight' => -1,\n );\n $form['islandora_solr_custom_table'][$fieldname]['hidden'] = array(\n '#type' => 'hidden',\n '#value' => $field['field'], // to know which row in the DB to update with the new values on save.\n '#weight' => -1,\n );\n // if the row is just added.\n if (isset($field['new'])) {\n $form['islandora_solr_custom_table'][$fieldname]['new'] = array(\n '#type' => 'hidden',\n '#value' => $field['new'], // to know if this row is added in the same POST request as the _submit request. We don't update the DB then. It would override the default settings with empty values.\n '#weight' => -1,\n );\n }\n $form['islandora_solr_custom_table'][$fieldname]['label'] = array(\n '#type' => 'textfield',\n '#default_value' => $field['label'],\n '#weight' => -1,\n );\n $form['islandora_solr_custom_table'][$fieldname]['exclude_label'] = array(\n '#type' => 'checkbox',\n '#default_value' => $field['exclude_label'],\n '#weight' => -1,\n );\n $form['islandora_solr_custom_table'][$fieldname]['markup'] = array(\n '#type' => 'checkbox',\n '#default_value' => $field['markup'],\n '#weight' => -1,\n );\n\n }\n\n\n // form: Display style\n $form['display_style'] = array(\n '#type' => 'fieldset',\n '#title' => t('Display style'),\n '#collapsible' => TRUE,\n '#collapsed' => FALSE,\n '#tree' => TRUE, // this attribute is important to return the submitted values in a deeper nested arrays in $form_state['values'] . See http://drupal.org/node/751826\n '#description' => t('Configure the display style.'),\n '#weight' => -4,\n );\n $form['display_style']['display'] = array(\n '#type' => 'select',\n '#title' => t('Default display style'),\n '#default_value' => variable_get('islandora_solr_custom_display', 'div'),\n '#options' => array(\n 'div' => t('Div'),\n 'table' => t('Table'),\n ),\n '#description' => t('Set the display style of the solr search results.'),\n '#weight' => -10,\n );\n $form['display_style']['switch'] = array(\n '#type' => 'checkbox',\n '#title' => t('Add display switch link?'),\n '#default_value' => variable_get('islandora_solr_custom_switch', 0),\n '#description' => t('Check if you want to include a link to switch between the two display styles.'),\n );\n $form['display_style']['css'] = array(\n '#type' => 'checkbox',\n '#title' => t('Include css?'),\n '#default_value' => variable_get('islandora_solr_custom_css', 1),\n '#description' => t('Check if you want to include some basic css styling. You can still overwrite css in the theme layer. Only uncheck if you really want to take full control over the css styling. This will not affect the table display.'),\n );\n\n\n // RSS settings\n $form['rss'] = array(\n '#type' => 'fieldset',\n '#title' => t('RSS'),\n '#collapsible' => TRUE,\n '#collapsed' => FALSE,\n '#tree' => TRUE, // this attribute is important to return the submitted values in a deeper nested arrays in $form_state['values'] . See http://drupal.org/node/751826\n '#description' => '<p>' . t('You can set a default limit on items in your RSS feed by setting a default in the field below. Additionally, you can force a limit on rss results simply by adding a limit argument to the rss url. For example if you want to limit your items to 15 add this argument to your RSS url: <strong>&limit=15</strong>') . '</p>' .\n '<p>' . t('The variables for the values of the RSS items and channel are set in theme functions. You can overwrite these functions in the theme layer and add an additional argument in the theme layer to set conditions in the function based on the value of the argument. For example: if you use <strong>&feed=myrss</strong> in the RSS url, then \\'myrss\\' will become available in the $feed variable in the theme functions, which you can use in a conditional statement to modify the variables.') . '</p>',\n '#weight' => -3,\n );\n $form['rss']['default_limit'] = array(\n '#type' => 'textfield',\n '#title' => t('Default RSS item limit'),\n '#default_value' => variable_get('islandora_solr_custom_rss_limit', 25),\n '#description' => t('The default limit of results to show in the RSS feed.'),\n '#size' => 2,\n '#maxlength' => 128,\n '#required' => FALSE,\n );\n\n\n $save = t('Save');\n if ($updates == TRUE) {\n $save = t('Save & update table');\n }\n\n $form['buttons']['submit'] = array(\n '#type' => 'submit',\n '#value' => $save\n );\n $form['buttons']['reset'] = array(\n '#type' => 'submit',\n '#value' => t('Reset to defaults')\n );\n\n if (!empty($_POST) && form_get_errors()) {\n drupal_set_message(t('The settings have not been saved because of the errors.'), 'error');\n }\n\n $form['custom_markup'] = array(\n '#type' => 'fieldset',\n '#title' => t('Custom markup'),\n '#collapsible' => TRUE,\n '#collapsed' => FALSE,\n '#description' => '<p>' . t('In your theme create a template file called <strong>islandora-solr-custom.tpl.php</strong> and paste in the code below. This will give you a nice start to customize your solr search results. You can then add wrapper elements, change labels, generate images from the repository, etc. Don\\'t forget to rebuild the theme registry after doing this.') . '</p>' .\n '<p>' . t(\"Label overrides provided by the table above are applied, but label exclusion and showing markup when empty are not. Goal is for you to take full control over the output. It is also possible to override the theme functions of the table display and the switch link.\") . '</p>' .\n '<p>' . _islandora_solr_custom_template_overwrite() . '</p>',\n );\n $form['custom_markup']['islandora_solr_custom_output'] = array(\n '#type' => 'markup',\n '#value' => _islandora_solr_custom_markup_render(_islandora_solr_custom_solrconfig()),\n );\n\n $form['#submit'][] = 'islandora_solr_custom_settings_form_submit';\n //$form['#validate'][] = 'islandora_solr_custom_settings_form_validate';\n $form['#theme'] = 'islandora_solr_custom_admin_settings';\n //$form['#theme'] = 'system_settings_form';\n\n return $form;\n}", "title": "" }, { "docid": "4e8c4a9adb5d044310d0ec68837f574b", "score": "0.6058686", "text": "function wsod_admin_form() {\n\n $form['wsod'] = array(\n '#type' => 'fieldset',\n '#title' => t('Diagnostics Tools for WSOD'),\n '#collapsible' => TRUE,\n ); \n\n $form['wsod']['wsod_rebuild'] = array(\n '#type' => 'submit',\n '#value' => t('Rebuild menu'),\n '#submit' => array('wsod_rebuild_submit'),\n ); \n\n $form['wsod']['wsod_live_checking'] = array(\n '#type' => 'checkbox',\n '#title' => t('Check for WSOD on every page load (only for debugging purpose).'),\n '#description' => t('WSOD is checked on every page load. Loading performance of your website could be decreased!'),\n '#default_value' => variable_get('wsod_live_checking', FALSE),\n );\n\n $form['wsod']['wsod_checking_on_post'] = array(\n '#type' => 'checkbox',\n '#title' => t('Check for WSOD on submitted forms as well.'),\n '#description' => t('Activate WSOD checking on submitted forms (by default WSOD are checked only for non-submitted forms).'),\n '#default_value' => variable_get('wsod_checking_on_post', FALSE),\n '#disabled' => !variable_get('wsod_live_checking', FALSE),\n );\n\n $form['wsod']['wsod_verbose_mode'] = array(\n '#type' => 'checkbox',\n '#title' => t('Activate verbose mode'),\n '#description' => t('Activate verbose mode on WSOD pages (debug messages are sent directly to website output). Please use it only for debug purposes, because it could break your theme!'),\n '#default_value' => variable_get('wsod_verbose_mode', FALSE),\n '#disabled' => !variable_get('wsod_live_checking', FALSE),\n );\n\n //$form['#validate'] = array('personalized_settings_admin_form_validate');\n\n return system_settings_form($form); \n}", "title": "" }, { "docid": "3eb57c85c86f2947c9ff6560825205a3", "score": "0.6036489", "text": "function give_v18_upgrades_form_metadata() {\n\t/* @var Give_Updates $give_updates */\n\t$give_updates = Give_Updates::get_instance();\n\n\t// form query\n\t$forms = new WP_Query( array(\n\t\t\t'paged' => $give_updates->step,\n\t\t\t'status' => 'any',\n\t\t\t'order' => 'ASC',\n\t\t\t'post_type' => 'give_forms',\n\t\t\t'posts_per_page' => 20,\n\t\t)\n\t);\n\n\tif ( $forms->have_posts() ) {\n\t\t$give_updates->set_percentage( $forms->found_posts, ( $give_updates->step * 20 ) );\n\n\t\twhile ( $forms->have_posts() ) {\n\t\t\t$forms->the_post();\n\n\t\t\t// Form content.\n\t\t\t// Note in version 1.8 display content setting split into display content and content placement setting.\n\t\t\t// You can delete _give_content_option in future\n\t\t\t$show_content = give_get_meta( get_the_ID(), '_give_content_option', true );\n\t\t\tif ( $show_content && ! give_get_meta( get_the_ID(), '_give_display_content', true ) ) {\n\t\t\t\t$field_value = ( 'none' !== $show_content ? 'enabled' : 'disabled' );\n\t\t\t\tgive_update_meta( get_the_ID(), '_give_display_content', $field_value );\n\n\t\t\t\t$field_value = ( 'none' !== $show_content ? $show_content : 'give_pre_form' );\n\t\t\t\tgive_update_meta( get_the_ID(), '_give_content_placement', $field_value );\n\t\t\t}\n\n\t\t\t// \"Disable\" Guest Donation. Checkbox\n\t\t\t// See: https://github.com/WordImpress/Give/issues/1470\n\t\t\t$guest_donation = give_get_meta( get_the_ID(), '_give_logged_in_only', true );\n\t\t\t$guest_donation_newval = ( in_array( $guest_donation, array( 'yes', 'on' ) ) ? 'disabled' : 'enabled' );\n\t\t\tgive_update_meta( get_the_ID(), '_give_logged_in_only', $guest_donation_newval );\n\n\t\t\t// Offline Donations\n\t\t\t// See: https://github.com/WordImpress/Give/issues/1579\n\t\t\t$offline_donation = give_get_meta( get_the_ID(), '_give_customize_offline_donations', true );\n\t\t\tif ( 'no' === $offline_donation ) {\n\t\t\t\t$offline_donation_newval = 'global';\n\t\t\t} elseif ( 'yes' === $offline_donation ) {\n\t\t\t\t$offline_donation_newval = 'enabled';\n\t\t\t} else {\n\t\t\t\t$offline_donation_newval = 'disabled';\n\t\t\t}\n\t\t\tgive_update_meta( get_the_ID(), '_give_customize_offline_donations', $offline_donation_newval );\n\n\t\t\t// Convert yes/no setting field to enabled/disabled.\n\t\t\t$form_radio_settings = array(\n\t\t\t\t// Custom Amount.\n\t\t\t\t'_give_custom_amount',\n\n\t\t\t\t// Donation Gaol.\n\t\t\t\t'_give_goal_option',\n\n\t\t\t\t// Close Form.\n\t\t\t\t'_give_close_form_when_goal_achieved',\n\n\t\t\t\t// Term & conditions.\n\t\t\t\t'_give_terms_option',\n\n\t\t\t\t// Billing fields.\n\t\t\t\t'_give_offline_donation_enable_billing_fields_single',\n\t\t\t);\n\n\t\t\tforeach ( $form_radio_settings as $meta_key ) {\n\t\t\t\t// Get value.\n\t\t\t\t$field_value = give_get_meta( get_the_ID(), $meta_key, true );\n\n\t\t\t\t// Convert meta value only if it is in yes/no/none.\n\t\t\t\tif ( in_array( $field_value, array( 'yes', 'on', 'no', 'none' ) ) ) {\n\n\t\t\t\t\t$field_value = ( in_array( $field_value, array( 'yes', 'on' ) ) ? 'enabled' : 'disabled' );\n\t\t\t\t\tgive_update_meta( get_the_ID(), $meta_key, $field_value );\n\t\t\t\t}\n\t\t\t}\n\t\t}// End while().\n\n\t\twp_reset_postdata();\n\n\t} else {\n\t\t// No more forms found, finish up.\n\t\tgive_set_upgrade_complete( 'v18_upgrades_form_metadata' );\n\t}\n}", "title": "" }, { "docid": "0e0aff091db1a19b5ebef112017dda6c", "score": "0.6032976", "text": "private function setupCheckboxes() {\n\t\t$this->setOptions('active', 'User is Active.', 'Inactive user cannot login.');\n\t\t$this->setOptions('editpage', 'Page management available.', 'Page management blocked.');\n\t\t$this->setOptions('delpage', 'Page delete available.', 'Page delete blocked.');\n\t\t$this->setOptions('edituser', 'User can manage other users.', 'User cannot manage other users.');\n\t\t$this->setOptions('deluser', 'User can delete other users.', 'User cannot delete other users.');\n\t\t$this->setOptions('editsettings', 'Template Settings management available.', 'Template Settings management blocked.');\n\t\t$this->setOptions('editcont', 'Template Controller management available.', 'Template Controller management blocked.');\n\t\t$this->setOptions('editlayout', 'Template Layout management available.', 'Template Layout management blocked.');\n\t\t$this->setOptions('editcss', 'Stylesheet management available.', 'Stylesheet management blocked.');\n\t\t$this->setOptions('editjs', 'Javascript management available.', 'Javascript management blocked.');\n\t}", "title": "" }, { "docid": "f0fecec4debfba1e7207ea6719485209", "score": "0.601207", "text": "private function _setFields()\n\t{\n\t\t$this->_fieldsAutoUpgrade['PS_AUTOUP_DONT_SAVE_IMAGES'] = array(\n\t\t\t'title' => $this->l('Don\\'t save images'), 'cast' => 'intval', 'validation' => 'isBool',\n\t\t\t'type' => 'bool', 'desc'=>$this->l('You can exclude the image directory from backup if you already saved it by another method (not recommended)'),\n\t\t);\n\n\t\t$this->_fieldsAutoUpgrade['PS_AUTOUP_KEEP_DEFAULT_THEME'] = array(\n\t\t\t'title' => $this->l('Keep theme \"prestashop\"'), 'cast' => 'intval', 'validation' => 'isBool',\n\t\t\t'type' => 'bool', 'desc'=>$this->l('If you have customized PrestaShop default theme, you can protect it from upgrade (not recommended)'),\n\t\t);\n\n\t\t$this->_fieldsAutoUpgrade['PS_AUTOUP_KEEP_TRAD'] = array(\n\t\t\t'title' => $this->l('Keep translations'), 'cast' => 'intval', 'validation' => 'isBool',\n\t\t\t'type' => 'bool', 'desc'=>$this->l('If set too yes, you will keep all your translations'),\n\t\t);\n\t\t// allow manual mode only for dev\n\t\tif (defined('_PS_MODE_DEV_') AND _PS_MODE_DEV_)\n\t\t\t$this->_fieldsAutoUpgrade['PS_AUTOUP_MANUAL_MODE'] = array(\n\t\t\t\t'title' => $this->l('Manual mode'),\t'cast' => 'intval',\t'validation' => 'isBool',\n\t\t\t\t'type' => 'bool',\t'desc'=>$this->l('Check this if you want to stop after each step'),\n\t\t\t);\n\n\t\tif (defined('_PS_ALLOW_UPGRADE_UNSTABLE_') AND _PS_ALLOW_UPGRADE_UNSTABLE_ AND function_exists('svn_checkout'))\n\t\t{\n\t\t\t$this->_fieldsAutoUpgrade['PS_AUTOUP_USE_SVN'] = array(\n\t\t\t\t'title' => $this->l('Use Subversion'), 'cast' => 'intval', 'validation' => 'isBool',\n\t\t\t\t'type' => 'bool',\t'desc' => $this->l('check this if you want to use unstable svn instead of official release'),\n\t\t\t);\n\t\t}\n\t}", "title": "" }, { "docid": "dfb96a8b83f577d69579392a35828226", "score": "0.6009117", "text": "function _set_manage_form_submit(&$form, &$form_state) {\n $abo = array();\n $content_types = variable_get('easysignup_active');\n foreach ($content_types as $type => $opt) {\n if (array_key_exists($type, $form_state['values'])) {\n if ($form_state['values'][$type] == 1) {\n if (isset($form_state['values'][$type . '_|_comment']) &&\n $form_state['values'][$type . '_|_comment'] == 1) {\n $abo[$type]['comment'] = 1;\n }\n else {\n $abo[$type]['comment'] = 0;\n }\n }\n }\n }\n $bundles = serialize($abo);\n _update_user_preferences($bundles);\n //dpm(get_defined_vars());\n}", "title": "" }, { "docid": "e8415ef0c42324dd20898883af09839a", "score": "0.6006811", "text": "function cf_update_field_type_setting($setting_id, $info)\n{\n global $g_table_prefix, $L;\n\n // if all goes well, this is what we return. Let's start optimistically...\n $success = true;\n $message = $L[\"notify_field_type_setting_updated\"];\n\n $info = ft_sanitize($info);\n $field_label = $info[\"field_label\"];\n $field_type = $info[\"field_type\"];\n\n $default_value_type = $info[\"default_value_type\"];\n if ($default_value_type == \"static\")\n $default_value = $info[\"default_value_static\"];\n else\n $default_value = $info[\"default_value_dynamic\"];\n\n $field_type_id = $info[\"field_type_id\"];\n $sortable_id = $info[\"sortable_id\"];\n\n $num_field_type_settings = _cf_get_num_field_type_settings($field_type_id);\n $list_order = $num_field_type_settings + 1;\n\n $field_orientation = \"na\";\n if ($field_type == \"radios\" || $field_type == \"checkboxes\")\n $field_orientation = $info[\"field_orientation\"];\n\n $query = mysql_query(\"\n UPDATE {$g_table_prefix}field_type_settings\n SET field_label = '$field_label',\n field_type = '$field_type',\n field_orientation = '$field_orientation',\n default_value_type = '$default_value_type',\n default_value = '$default_value'\n WHERE setting_id = $setting_id\n \");\n\n if (!$query)\n {\n $success = false;\n $message = $L[\"notify_problem_updating_field_type_setting\"];\n }\n\n // now update the options\n $sortable_rows = explode(\",\", $info[\"{$sortable_id}_sortable__rows\"]);\n $sortable_new_groups = explode(\",\", $info[\"{$sortable_id}_sortable__new_groups\"]);\n\n mysql_query(\"DELETE FROM {$g_table_prefix}field_type_setting_options WHERE setting_id = $setting_id\");\n\n if (in_array($field_type, array(\"radios\", \"checkboxes\", \"select\", \"multi-select\")))\n {\n $new_row_count = 1;\n foreach ($sortable_rows as $row_number)\n {\n $option_value = $info[\"option_value_{$row_number}\"];\n $option_text = $info[\"option_text_{$row_number}\"];\n $is_new_sort_group = in_array($row_number, $sortable_new_groups) ? \"yes\" : \"no\";\n\n mysql_query(\"\n INSERT INTO {$g_table_prefix}field_type_setting_options (setting_id, option_text, option_value,\n option_order, is_new_sort_group)\n VALUES ($setting_id, '$option_text', '$option_value', '$new_row_count', '$is_new_sort_group')\n \");\n $new_row_count++;\n }\n }\n\n return array($success, $message);\n}", "title": "" }, { "docid": "3ed67b874a92163aaceb758930baa276", "score": "0.5992972", "text": "function mywidget_edit_form_submit($form, &$form_state) {\n foreach (array_keys($form_state['plugin']['defaults']) as $key) {\n if (isset($form_state['values'][$key])) {\n $form_state['conf'][$key] = $form_state['values'][$key];\n }\n }\n}", "title": "" }, { "docid": "b0e86e6800de4bbd51e09f1e28390211", "score": "0.59760284", "text": "function wdm_save_meta_box_data( $post_id ) {\n\n /*\n * We need to verify this came from our screen and with proper authorization,\n * because the save_post action can be triggered at other times.\n */\n\n // Check if our nonce is set.\n if ( !isset( $_POST['wdm_meta_box_nonce'] ) ) {\n return;\n }\n\n // Verify that the nonce is valid.\n if ( !wp_verify_nonce( $_POST['wdm_meta_box_nonce'], 'wdm_meta_box' ) ) {\n return;\n }\n\n // If this is an autosave, our form has not been submitted, so we don't want to do anything.\n if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n return;\n }\n\n // Check the user's permissions.\n if ( !current_user_can( 'edit_post', $post_id ) ) {\n return;\n }\n\n// Checks for input and saves if needed\nif( isset( $_POST[ 'the_name_of_the_radio_buttons' ] ) ) {\nupdate_post_meta( $post_id, 'meta-radio', $_POST[ 'the_name_of_the_radio_buttons' ] );\n}\n // Sanitize user input.\n $new_meta_value = ( isset( $_POST['the_name_of_the_radio_buttons'] ) ? sanitize_html_class( $_POST['the_name_of_the_radio_buttons'] ) : '' );\n\n // Update the meta field in the database.\n update_post_meta( $post_id, 'my_key', $new_meta_value );\n \n \n\n}", "title": "" }, { "docid": "d9c4d9a889e87a35bf73769a81f05f1e", "score": "0.59666467", "text": "function setup_bf_metabox( $options ){\r\n\r\n /**\r\n * 3. => Meta Box Options\r\n */\r\n\r\n\r\n $fields = array();\r\n\r\n /**\r\n * => Post Options\r\n */\r\n $fields['_post_options'] = array(\r\n 'name' => __( 'Post', 'better-studio' ),\r\n 'id' => '_post_options',\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-page-text',\r\n );\r\n if( ! is_admin() || bf_get_admin_current_post_type() == 'post' ) {\r\n\r\n $fields['_bm_featured_post'] = array(\r\n 'name' => __('Featured Slider Post?', 'better-studio'),\r\n 'id' => '_bm_featured_post',\r\n 'std' => '0',\r\n 'type' => 'switch',\r\n 'on-label' => __( 'Yes', 'better-studio' ),\r\n 'off-label' => __( 'No', 'better-studio' ),\r\n );\r\n\r\n }\r\n $fields['_bm_disable_post_featured'] = array(\r\n 'name' => __( 'Show Featured Image/Video', 'better-studio' ),\r\n 'id' => '_bm_disable_post_featured',\r\n 'std' => 'default',\r\n 'type' => 'select',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n $fields['_featured_video_code'] = array(\r\n 'name' => __( 'Featured Video Code', 'better-studio' ),\r\n 'id' => '_featured_video_code',\r\n 'desc' => __( 'Paste YouTube, Vimeo or self hosted video URL then player automatically will be generated.', 'better-studio' ),\r\n 'type' => 'textarea',\r\n 'std' => '',\r\n );\r\n\r\n if( ! is_admin() || bf_get_admin_current_post_type() == 'post' ) {\r\n\r\n $fields['_bs_primary_category'] = array(\r\n 'name' => __( 'Primary Category', 'better-studio' ),\r\n 'desc' => __( 'When you have multiple categories for a post, auto detection chooses one in alphabetical order. These used for show an label above image in listings and breadcrumb.', 'better-studio' ),\r\n 'id' => '_bs_primary_category',\r\n 'std' => 'auto-detect',\r\n 'type' => 'select',\r\n 'options' => array(\r\n 'auto-detect' => __( 'Auto Detect', 'better-studio' ),\r\n array(\r\n 'label' => __( 'Categories', 'better-studio' ),\r\n 'options' => array( 'category_walker' => 'category_walker' ),\r\n )\r\n )\r\n );\r\n }\r\n\r\n $fields['_hide_page_title'] = array(\r\n 'name' => bf_get_admin_current_post_type() == 'post' ? __( 'Hide Post Title?', 'better-studio' ) : __( 'Hide Page Title?', 'better-studio' ),\r\n 'id' => '_hide_page_title',\r\n 'type' => 'switch',\r\n 'std' => '0',\r\n 'on-label' => __( 'Yes', 'better-studio' ),\r\n 'off-label' => __( 'No', 'better-studio' ),\r\n 'desc' => __( 'Enable this for hiding page title', 'better-studio' ),\r\n );\r\n\r\n $fields['_show_comments'] = array(\r\n 'name' => __( 'Show Comments', 'better-studio' ),\r\n 'id' => '_show_comments',\r\n 'desc' => __( 'Choose to show or hide comments area.', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n\r\n if( ! is_admin() || bf_get_admin_current_post_type() == 'post' ){\r\n\r\n $fields['_hide_post_meta'] = array(\r\n 'name' => __( 'Show Post Meta', 'better-studio' ),\r\n 'id' => '_hide_post_meta',\r\n 'desc' => __( 'Choose to show or hide post meta', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n\r\n }\r\n\r\n if( ! is_admin() || bf_get_admin_current_post_type() == 'page' ) {\r\n\r\n $fields['_social_share'] = array(\r\n 'name' => __( 'Share Box', 'better-studio' ),\r\n 'id' => '_social_share',\r\n 'desc' => __( 'Choose to show or hide share box', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'hide',\r\n 'options' => array(\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n 'top' => __( 'Top', 'better-studio' ),\r\n 'bottom' => __( 'Bottom', 'better-studio' ),\r\n 'bottom-top'=> __( 'Top & Bottom', 'better-studio' ),\r\n )\r\n );\r\n\r\n }\r\n\r\n if( ! is_admin() || bf_get_admin_current_post_type() == 'post' ){\r\n\r\n $fields['_show_social_share'] = array(\r\n 'name' => __( 'Show Share Box', 'better-studio' ),\r\n 'id' => '_show_social_share',\r\n 'desc' => __( 'Choose to show or hide share box', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n $fields['_show_related_posts'] = array(\r\n 'name' => __( 'Show Related Posts', 'better-studio' ),\r\n 'id' => '_show_related_posts',\r\n 'desc' => __( 'Choose to show or hide related posts on this post', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n\r\n $fields['_show_post_navigation'] = array(\r\n 'name' => __( 'Show Previous/Next Pagination', 'better-studio' ),\r\n 'id' => '_show_post_navigation',\r\n 'desc' => __( 'Choose to show or hide the post navigation', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n\r\n $fields['_show_author_box'] = array(\r\n 'name' => __( 'Show Author Info Box', 'better-studio' ),\r\n 'id' => '_show_author_box',\r\n 'desc' => __( 'Choose to show or hide the author info box', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n\r\n $fields['_show_post_categories'] = array(\r\n 'name' => __( 'Show Post Categories', 'better-studio' ),\r\n 'id' => '_show_post_categories',\r\n 'desc' => __( 'Choose to show or hide the categories', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n\r\n $fields['_show_post_tags'] = array(\r\n 'name' => __( 'Show Post Tags', 'better-studio' ),\r\n 'id' => '_show_post_tags',\r\n 'desc' => __( 'Choose to show or hide the tags', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n\r\n }\r\n\r\n\r\n /**\r\n * => Page Options\r\n */\r\n $fields['_page_options'] = array(\r\n 'name' => __( 'Page Style', 'better-studio' ),\r\n 'id' => '_page_options',\r\n 'std' => '0' ,\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-paint',\r\n );\r\n\r\n $fields['_layout_style'] = array(\r\n 'name' => __( 'Page Layout Style', 'better-studio' ),\r\n 'id' => '_layout_style',\r\n 'std' => 'default',\r\n 'type' => 'image_select',\r\n 'section_class' => 'style-floated-left bordered',\r\n 'desc' => __( 'Select page layout style.', 'better-studio' ),\r\n 'options' => array(\r\n 'default' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/style-' . Better_Mag::get_option( 'layout_style' ) .'.png',\r\n 'label' => __( 'Default', 'better-studio' ),\r\n ),\r\n 'full-width'=> array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/style-full-width.png',\r\n 'label' => __( 'Full Width', 'better-studio' ),\r\n ),\r\n 'boxed' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/style-boxed.png',\r\n 'label' => __( 'Boxed', 'better-studio' ),\r\n ),\r\n 'boxed-padded'=> array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/style-boxed-padded.png',\r\n 'label' => __( 'Boxed (Padded)', 'better-studio' ),\r\n ),\r\n )\r\n );\r\n\r\n $fields['_bg_color'] = array(\r\n 'name' => __( 'Page Background Color', 'better-studio' ),\r\n 'id' => '_bg_color',\r\n 'type' => 'color',\r\n 'std' => Better_Mag::get_option( 'bg_color' ),\r\n 'save-std' => false,\r\n 'desc' => __( 'Setting a body background image below will override it.', 'better-studio' ),\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body',\r\n 'body.boxed',\r\n ),\r\n 'prop' => array(\r\n 'background-color' => '%%value%%'\r\n )\r\n )\r\n ),\r\n );\r\n $fields['_bg_image'] = array(\r\n 'name' => __( 'Page Background Image', 'better-studio' ),\r\n 'id' => '_bg_image',\r\n 'type' => 'background_image',\r\n 'std' => '',\r\n 'save-std' => false,\r\n 'upload_label' => __( 'Upload Image', 'better-studio' ),\r\n 'desc' => __( 'Use light patterns in non-boxed layout. For patterns, use a repeating background. Use photo to fully cover the background with an image. Note that it will override the background color option.', 'better-studio' ),\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body'\r\n ),\r\n 'prop' => array( 'background-image' ),\r\n 'type' => 'background-image'\r\n )\r\n ),\r\n );\r\n\r\n $fields['_gallery_images_bg_slides'] = array(\r\n 'name' => __( 'Show Gallery Images as Background Slide Show!?', 'better-studio' ),\r\n 'id' => '_gallery_images_bg_slides',\r\n 'desc' => __( 'Enabling this will be shows images of first gallery in post as background slide show in page', 'better-studio' ),\r\n 'type' => 'switch',\r\n 'std' => '0',\r\n 'on-label' => __( 'Yes', 'better-studio' ),\r\n 'off-label' => __( 'No', 'better-studio' ),\r\n );\r\n\r\n\r\n $fields[] = array(\r\n 'name' => __( 'Content Padding', 'better-studio' ),\r\n 'type' => 'group',\r\n 'state' => 'close',\r\n );\r\n $fields['_content_top_padding'] = array(\r\n 'name' => __( 'Page Content Top Padding', 'better-studio' ),\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'id' => '_content_top_padding',\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Leave empty for default value.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .post-content',\r\n 'body .page-content',\r\n ),\r\n 'prop' => array( 'padding-top' => '%%value%%px' ),\r\n )\r\n ),\r\n );\r\n $fields['_content_bottom_padding'] = array(\r\n 'name' => __( 'Page Content Bottom Padding', 'better-studio' ),\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'id' => '_content_bottom_padding',\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Leave empty for default value.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .post-content',\r\n 'body .page-content',\r\n ),\r\n 'prop' => array( 'padding-bottom' => '%%value%%px' ),\r\n )\r\n ),\r\n );\r\n $fields['_content_left_padding'] = array(\r\n 'name' => __( 'Page Content Left Padding', 'better-studio' ),\r\n 'id' => '_content_left_padding',\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Leave empty for default value.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .post-content',\r\n 'body .page-content'\r\n ),\r\n 'prop' => array( 'padding-left' => '%%value%%px' ),\r\n )\r\n ),\r\n );\r\n $fields['_content_right_padding'] = array(\r\n 'name' => __( 'Page Content Right Padding', 'better-studio' ),\r\n 'id' => '_content_right_padding',\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Leave empty for default value.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .post-content',\r\n 'body .page-content'\r\n ),\r\n 'prop' => array( 'padding-right' => '%%value%%px' ),\r\n )\r\n ),\r\n );\r\n\r\n\r\n\r\n /**\r\n * => Header Options\r\n */\r\n $fields['_header_options'] = array(\r\n 'name' => __( 'Header', 'better-studio' ),\r\n 'id' => '_header_options',\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-header',\r\n );\r\n $fields['_header_show_topbar'] = array(\r\n 'name' => __( 'Display Top Bar', 'better-studio' ),\r\n 'id' => '_header_show_topbar',\r\n 'desc' => __( 'Choose to show or top bar', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n\r\n $fields['_header_show_header'] = array(\r\n 'name' => __( 'Display Header', 'better-studio' ),\r\n 'id' => '_header_show_header',\r\n 'desc' => __( 'Choose to show or header', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'show',\r\n 'options' => array(\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n $fields[] = array(\r\n 'name' => __( 'Main Navigation', 'better-studio' ),\r\n 'type' => 'group',\r\n 'state' => 'open',\r\n );\r\n $menus['default'] = __( 'Default Main Navigation', 'better-studio' );\r\n $menus[] = array(\r\n 'label' => __( 'Menus', 'better-studio' ),\r\n 'options' => BF_Query::get_menus(),\r\n );\r\n $fields['_main_nav_menu'] = array(\r\n 'name' => __( 'Main Navigation Menu', 'better-studio' ),\r\n 'id' => '_main_nav_menu',\r\n 'desc' => __( 'Select which menu displays on this page.', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => $menus\r\n );\r\n $fields['_main_menu_style'] = array(\r\n 'name' => __( 'Main Navigation Style', 'better-studio' ),\r\n 'id' => '_main_menu_style',\r\n 'desc' => __( 'Select header menu style. ', 'better-studio' ),\r\n 'std' => 'default',\r\n 'type' => 'image_select',\r\n 'section_class' => 'style-floated-left bordered',\r\n 'options' => array(\r\n 'default' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/menu-style-' . Better_Mag::get_option( 'main_menu_style' ) .'.png',\r\n 'label' => __( 'Default', 'better-studio' ),\r\n ),\r\n 'normal' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/menu-style-normal.png',\r\n 'label' => __( 'Normal', 'better-studio' ),\r\n ),\r\n 'normal-center' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/menu-style-normal-center.png',\r\n 'label' => __( 'Normal - Center Align', 'better-studio' ),\r\n ),\r\n 'large' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/menu-style-large.png',\r\n 'label' => __( 'Large', 'better-studio' ),\r\n ),\r\n 'large-center' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/menu-style-large-center.png',\r\n 'label' => __( 'Large - Center Align', 'better-studio' ),\r\n ),\r\n ),\r\n );\r\n $fields['_main_menu_layout'] = array(\r\n 'name' => __( 'Main Navigation Layout', 'better-studio' ),\r\n 'id' => '_main_menu_layout',\r\n 'desc' => __( 'Select whether you want a boxed or a full width menu. ', 'better-studio' ),\r\n 'std' => 'default',\r\n 'type' => 'image_select',\r\n 'section_class' => 'style-floated-left bordered',\r\n 'options' => array(\r\n 'default' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/header-menu-boxed.png',\r\n 'label' => __( 'Default', 'better-studio' ),\r\n ),\r\n 'boxed' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/header-menu-boxed.png',\r\n 'label' => __( 'Boxed', 'better-studio' ),\r\n ),\r\n 'full-width' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/header-menu-full-width.png',\r\n 'label' => __( 'Full Width', 'better-studio' ),\r\n ),\r\n ),\r\n );\r\n $fields[] = array(\r\n 'name' => __( 'Header Background', 'better-studio' ),\r\n 'type' => 'group',\r\n 'state' => 'close',\r\n );\r\n $fields['_header_bg_color'] = array(\r\n 'name' => __( 'Header Background Color', 'better-studio' ),\r\n 'id' => '_header_bg_color',\r\n 'type' => 'color',\r\n 'std' => Better_Mag::get_option( 'header_bg_color' ),\r\n 'save-std' => false,\r\n 'desc' => __( 'Setting a header background pattern below will override it.','better-studio'),\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .header'\r\n ),\r\n 'prop' => array(\r\n 'background-color' => '%%value%%'\r\n )\r\n )\r\n )\r\n );\r\n\r\n $fields['_header_bg_image'] = array(\r\n 'name' => __( 'Header Background Image', 'better-studio' ),\r\n 'id' => '_header_bg_image',\r\n 'type' => 'background_image',\r\n 'std' => array( 'img' => '', 'type' => 'cover' ),\r\n 'save-std' => false,\r\n 'upload_label' => __( 'Upload Image', 'better-studio' ),\r\n 'desc' => __( 'Please use a background pattern that can be repeated. Note that it will override the header background color option.','better-studio'),\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .header'\r\n ),\r\n 'prop' => array( 'background-image' ),\r\n 'type' => 'background-image'\r\n )\r\n ),\r\n\r\n );\r\n\r\n $fields[] = array(\r\n 'name' => __( 'Header Padding', 'better-studio' ),\r\n 'type' => 'group',\r\n 'state' => 'close',\r\n );\r\n $fields['_header_top_padding'] = array(\r\n 'name' => __( 'Header Top Padding', 'better-studio' ),\r\n 'id' => '_header_top_padding',\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Leave empty for default value.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body.single .header'\r\n ),\r\n 'prop' => array( 'padding-top' => '%%value%%px' ),\r\n )\r\n ),\r\n );\r\n $fields['_header_bottom_padding'] = array(\r\n 'name' => __( 'Header Bottom Padding', 'better-studio' ),\r\n 'id' => '_header_bottom_padding',\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Leave empty for default value. Values lower than 60px will break the style.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body.single .header'\r\n ),\r\n 'prop' => array( 'padding-bottom' => '%%value%%px' ),\r\n )\r\n ),\r\n );\r\n\r\n\r\n\r\n /**\r\n * => Sidebar Options\r\n */\r\n $fields['_sidebar_options'] = array(\r\n 'name' => __( 'Sidebar', 'better-studio' ),\r\n 'id' => '_sidebar_options',\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-sidebar',\r\n );\r\n\r\n $fields['_default_sidebar_layout'] = array(\r\n 'name' => bf_get_admin_current_post_type() == 'post' ? __( 'Post Sidebar Layout', 'better-studio' ) : __( 'Page Sidebar Layout', 'better-studio' ),\r\n 'id' => '_default_sidebar_layout',\r\n 'std' => 'default',\r\n 'type' => 'image_select',\r\n 'section_class' => 'style-floated-left bordered',\r\n 'desc' => __( 'Select the sidebar layout for page.', 'better-studio' ),\r\n 'options' => array(\r\n 'default' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-' . Better_Mag::get_option( 'default_sidebar_layout' ) . '.png',\r\n 'label' => __( 'Default', 'better-studio' ),\r\n ),\r\n 'left' => array(\r\n 'img' => is_rtl() ? BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-right.png' : BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-left.png',\r\n 'label' => is_rtl() ? __( 'Right Sidebar', 'better-studio' ) : __( 'Left Sidebar', 'better-studio' ),\r\n ),\r\n 'right' => array(\r\n 'img' => is_rtl() ? BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-left.png' : BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-right.png',\r\n 'label' => is_rtl() ? __( 'Left Sidebar', 'better-studio' ) : __( 'Right Sidebar', 'better-studio' ),\r\n ),\r\n 'no-sidebar'=> array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-no-sidebar.png',\r\n 'label' => __( 'No Sidebar', 'better-studio' ),\r\n ),\r\n )\r\n );\r\n\r\n\r\n /**\r\n * => Footer Options\r\n */\r\n $fields['_footer_options'] = array(\r\n 'name' => __( 'Footer', 'better-studio' ),\r\n 'id' => '_footer_options',\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-footer',\r\n );\r\n\r\n $fields['_footer_show_large'] = array(\r\n 'name' => __( 'Display Large Footer', 'better-studio' ),\r\n 'id' => '_footer_show_large',\r\n 'desc' => __( 'Choose to show or hide large footer', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n\r\n $fields['_footer_show_lower'] = array(\r\n 'name' => __( 'Display Lower Footer', 'better-studio' ),\r\n 'id' => '_footer_show_lower',\r\n 'desc' => __( 'Choose to show or hide lower footer', 'better-studio' ),\r\n 'type' => 'select',\r\n 'std' => 'default',\r\n 'options' => array(\r\n 'default' => __( 'Default', 'better-studio' ),\r\n 'show' => __( 'Show', 'better-studio' ),\r\n 'hide' => __( 'Hide', 'better-studio' ),\r\n )\r\n );\r\n\r\n $fields[] = array(\r\n 'name' => __( 'Large Footer Padding', 'better-studio' ),\r\n 'type' => 'group',\r\n 'state' => 'close',\r\n );\r\n $fields['_footer_large_top_padding'] = array(\r\n 'name' => __( 'Large Footer Top Padding', 'better-studio' ),\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'id' => '_footer_large_top_padding',\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Leave empty for default.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .footer-larger-wrapper'\r\n ),\r\n 'prop' => array(\r\n 'padding-top' => '%%value%%px'\r\n ),\r\n )\r\n ),\r\n );\r\n $fields['_footer_large_bottom_padding'] = array(\r\n 'name' => __( 'Large Footer Top Padding', 'better-studio' ),\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'id' => '_footer_large_bottom_padding',\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Leave empty for default.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .footer-larger-wrapper'\r\n ),\r\n 'prop' => array( 'padding-bottom' => '%%value%%px' ),\r\n )\r\n ),\r\n );\r\n\r\n $fields[] = array(\r\n 'name' => __( 'Lower Footer Padding', 'better-studio' ),\r\n 'type' => 'group',\r\n 'state' => 'close',\r\n );\r\n $fields['_footer_lower_top_padding'] = array(\r\n 'name' => __( 'Lower Footer Top Padding', 'better-studio' ),\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'id' => '_footer_lower_top_padding',\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Leave empty for default.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .footer-lower-wrapper'\r\n ),\r\n 'prop' => array(\r\n 'padding-top' => '%%value%%px'\r\n ),\r\n )\r\n ),\r\n );\r\n $fields['_footer_lower_bottom_padding'] = array(\r\n 'name' => __( 'Lower Footer Top Padding', 'better-studio' ),\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'id' => '_footer_lower_bottom_padding',\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Leave empty for default.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .footer-lower-wrapper'\r\n ),\r\n 'prop' => array( 'padding-bottom' => '%%value%%px' ),\r\n )\r\n ),\r\n );\r\n\r\n\r\n\r\n /**\r\n * => Slider Options\r\n */\r\n $fields['_slider_options'] = array(\r\n 'name' => __( 'Slider', 'better-studio' ),\r\n 'id' => '_slider_options',\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-slider',\r\n );\r\n $fields['_show_slider'] = array(\r\n 'name' => __( 'Slider Type', 'better-studio' ),\r\n 'desc' => __( 'Select the type of slider that displays.', 'better-studio' ),\r\n 'id' => '_show_slider',\r\n 'std' => 'no' ,\r\n 'type' => 'select',\r\n 'options' => array(\r\n 'no' => __( 'No Slider', 'better-studio' ),\r\n 'better'=> __( 'BetterSlider', 'better-studio' ),\r\n 'rev' => __( 'Revolution Slider', 'better-studio' ),\r\n )\r\n );\r\n $fields['show_slider'] = array(\r\n 'name' => __( 'BetterSlider Settings', 'better-studio' ),\r\n 'type' => 'group',\r\n 'state' => 'open',\r\n );\r\n $fields['_slider_just_featured'] = array(\r\n 'name' => __( 'Show Only Featured Posts in Slider', 'better-studio' ),\r\n 'id' => '_slider_just_featured',\r\n 'std' => '0' ,\r\n 'type' => 'switch',\r\n 'on-label' => __( 'Only Featured', 'better-studio' ),\r\n 'off-label' => __( 'All Posts', 'better-studio' ),\r\n 'desc' => __( 'Turn Off for showing latest posts in slider or On for showing posts that specified as featured posts in slider.', 'better-studio' )\r\n );\r\n\r\n $fields['_slider_style'] = array(\r\n 'name' => __( 'Slider Style', 'better-studio' ),\r\n 'id' => '_slider_style',\r\n 'std' => 'default',\r\n 'type' => 'image_select',\r\n 'section_class' => 'style-floated-left bordered',\r\n 'options' => array(\r\n 'default' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-' . Better_Mag::get_option( 'slider_style' ) . '.png',\r\n 'label' => __( 'Default', 'better-studio' ),\r\n ),\r\n 'style-1' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-style-1.png',\r\n 'label' => __( 'Style 1', 'better-studio' ),\r\n ),\r\n 'style-2' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-style-2.png',\r\n 'label' => __( 'Style 2', 'better-studio' ),\r\n ),\r\n 'style-3' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-style-3.png',\r\n 'label' => __( 'Style 3', 'better-studio' ),\r\n ),\r\n 'style-4' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-style-4.png',\r\n 'label' => __( 'Style 4', 'better-studio' ),\r\n ),\r\n 'style-5' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-style-5.png',\r\n 'label' => __( 'Style 5', 'better-studio' ),\r\n ),\r\n 'style-6' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-style-6.png',\r\n 'label' => __( 'Style 6', 'better-studio' ),\r\n ),\r\n 'style-7' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-style-7.png',\r\n 'label' => __( 'Style 7', 'better-studio' ),\r\n ),\r\n 'style-8' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-style-8.png',\r\n 'label' => __( 'Style 8', 'better-studio' ),\r\n ),\r\n 'style-9' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-style-9.png',\r\n 'label' => __( 'Style 9', 'better-studio' ),\r\n ),\r\n 'style-10' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/slider-style-10.png',\r\n 'label' => __( 'Style 10', 'better-studio' ),\r\n ),\r\n )\r\n );\r\n $fields['_slider_bg_color'] = array(\r\n 'name' => __( 'Slider Background Color', 'better-studio' ),\r\n 'id' => '_slider_bg_color',\r\n 'desc' => __( 'Customize slider background color.', 'better-studio' ),\r\n 'type' => 'color',\r\n 'std' => Better_Mag::get_option( 'slider_bg_color' ),\r\n 'save-std' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => 'body .main-slider-wrapper' ,\r\n 'prop' => array('background-color')\r\n )\r\n ),\r\n );\r\n $fields['_slider_cats'] = array(\r\n 'name' => __( 'Filter Slider by Categories', 'better-studio' ),\r\n 'id' => '_slider_cats',\r\n 'type' => 'ajax_select',\r\n 'std' => Better_Mag::get_option( 'slider_cats' ),\r\n 'desc' => __( 'Select categories for showing post of them in slider. you can use combination of multiple category and tag.', 'better-studio' ),\r\n 'placeholder' => __(\"Search and find category...\", 'better-studio'),\r\n \"callback\" => 'BF_Ajax_Select_Callbacks::cats_callback',\r\n \"get_name\" => 'BF_Ajax_Select_Callbacks::cat_name',\r\n );\r\n $fields['_slider_tags'] = array(\r\n 'name' => __( 'Filter Slider by Tags', 'better-studio' ),\r\n 'id' => '_slider_tags',\r\n 'type' => 'ajax_select',\r\n 'std' => Better_Mag::get_option( 'slider_tags' ),\r\n 'desc' => __( 'Select tags for showing post of them in slider. you can use combination of multiple category and tag.', 'better-studio' ),\r\n 'placeholder' => __(\"Search and find tag...\", 'better-studio'),\r\n \"callback\" => 'BF_Ajax_Select_Callbacks::tags_callback',\r\n \"get_name\" => 'BF_Ajax_Select_Callbacks::tag_name',\r\n );\r\n $fields[] = array(\r\n 'name' => __( 'Slider Custom Post Type', 'better-studio' ),\r\n 'desc' => __( 'Enter your custom post types here. Separate with ,', 'better-studio' ),\r\n 'id' => 'slider_post_type',\r\n 'type' => 'text',\r\n 'std' => '',\r\n );\r\n $fields[] = array(\r\n 'name' => __( 'Revolution Slider Settings', 'better-studio' ),\r\n 'type' => 'group',\r\n 'state' => 'open',\r\n );\r\n $fields['_slider_rev_id'] = array(\r\n 'name' => __( 'Select Default Revolution Slider', 'better-studio' ),\r\n 'desc' => __( 'Select the unique name of the slider.', 'better-studio' ),\r\n 'id' => '_slider_rev_id',\r\n 'std' => '0' ,\r\n 'type' => 'select',\r\n 'options' => array(\r\n '0' => __( 'Select A Slider', 'better-studio' ),\r\n ) + BF_Query::get_rev_sliders()\r\n );\r\n $fields[] = array(\r\n 'name' => __( 'Slider Padding', 'better-studio' ),\r\n 'type' => 'group',\r\n 'state' => 'close',\r\n );\r\n $fields['_slider_top_padding'] = array(\r\n 'name' => __( 'Slider Top Padding', 'better-studio' ),\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'id' => '_slider_top_padding',\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Default padding is 20px.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .main-slider-wrapper'\r\n ),\r\n 'prop' => array(\r\n 'padding-top' => '%%value%%px'\r\n ),\r\n )\r\n ),\r\n );\r\n $fields['_slider_bottom_padding'] = array(\r\n 'name' => __( 'Slider Bottom Padding', 'better-studio' ),\r\n 'suffix' => __( 'Pixel', 'better-studio' ),\r\n 'id' => '_slider_bottom_padding',\r\n 'desc' => __( 'In pixels without px, ex: 20. <br>Default padding is 20px.', 'better-studio' ),\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'css-echo-default' => false,\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .main-slider-wrapper'\r\n ),\r\n 'prop' => array( 'padding-bottom' => '%%value%%px' ),\r\n )\r\n ),\r\n );\r\n\r\n /**\r\n * Breadcrumb\r\n */\r\n $fields[] = array(\r\n 'name' => __( 'Breadcrumb' , 'better-studio' ),\r\n 'id' => 'breadcrumb_settings',\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-link'\r\n );\r\n $fields['_breadcrumb_style'] = array(\r\n 'name' => __( 'Breadcrumb Style', 'better-studio' ),\r\n 'id' => '_breadcrumb_style',\r\n 'desc' => __( 'Select breadcrumb style. ', 'better-studio' ),\r\n 'std' => 'default',\r\n 'type' => 'image_select',\r\n 'section_class' => 'style-floated-left bordered',\r\n 'options' => array(\r\n 'default' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/breadcrumb-style-' . Better_Mag::get_option( 'breadcrumb_style' ) . '.png',\r\n 'label' => __( 'Default', 'better-studio' ),\r\n ),\r\n 'normal' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/breadcrumb-style-normal.png',\r\n 'label' => __( 'Normal', 'better-studio' ),\r\n ),\r\n 'normal-center' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/breadcrumb-style-normal-center.png',\r\n 'label' => __( 'Center Align', 'better-studio' ),\r\n ),\r\n ),\r\n );\r\n\r\n\r\n /**\r\n * => Custom Javascript / CSS\r\n */\r\n $fields['_custom_css_settings'] = array(\r\n 'name' => __( 'Custom CSS' , 'better-studio' ),\r\n 'id' => '_custom_css_settings',\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-css3',\r\n 'margin-top'=> '20',\r\n );\r\n $fields['_custom_css_code'] = array(\r\n 'name' => __( 'Custom CSS Code', 'better-studio' ),\r\n 'id' => '_custom_css_code',\r\n 'type' => 'textarea',\r\n 'std' => '',\r\n 'desc' => __( 'Paste your CSS code, do not include any tags or HTML in the field. Any custom CSS entered here will override the theme CSS. In some cases, the !important tag may be needed.', 'better-studio' )\r\n );\r\n $fields['_custom_css_class'] = array(\r\n 'name' => __( 'Custom Body Class', 'better-studio' ),\r\n 'id' => '_custom_css_class',\r\n 'type' => 'text',\r\n 'std' => '',\r\n 'desc' => __( 'This classes will be added to body.<br> Separate classes with space.', 'better-studio' )\r\n );\r\n $fields[] = array(\r\n 'name' => __( 'Responsive CSS', 'better-studio' ),\r\n 'type' => 'group',\r\n 'state' => 'close',\r\n 'desc' => 'Paste your custom css in the appropriate box, to run only on a specific device',\r\n );\r\n $fields['_custom_css_desktop_code'] = array(\r\n 'name' => __( 'Desktop', 'better-studio' ),\r\n 'id' => '_custom_css_desktop_code',\r\n 'type' => 'textarea',\r\n 'std' => '',\r\n 'desc' => __( '1200px +', 'better-studio' )\r\n );\r\n $fields['_custom_css_ipad_landscape_code'] = array(\r\n 'name' => __( 'iPad Landscape', 'better-studio' ),\r\n 'id' => '_custom_css_ipad_landscape_code',\r\n 'type' => 'textarea',\r\n 'std' => '',\r\n 'desc' => __( '1019px - 1199px', 'better-studio' )\r\n );\r\n $fields['_custom_css_ipad_portrait_code'] = array(\r\n 'name' => __( 'iPad Portrait', 'better-studio' ),\r\n 'id' => '_custom_css_ipad_portrait_code',\r\n 'type' => 'textarea',\r\n 'std' => '',\r\n 'desc' => __( '768px - 1018px', 'better-studio' )\r\n );\r\n $fields['_custom_css_phones_code'] = array(\r\n 'name' => __( 'Phones', 'better-studio' ),\r\n 'id' => '_custom_css_phones_code',\r\n 'type' => 'textarea',\r\n 'std' => '',\r\n 'desc' => __( '768px - 1018px', 'better-studio' )\r\n );\r\n\r\n\r\n //\r\n // Support custom post types\r\n //\r\n $pages = array( 'post', 'page' );\r\n if( Better_Mag::get_option( 'advanced_post_options_types' ) != '' )\r\n $pages = array_merge( explode( ',', Better_Mag::get_option( 'advanced_post_options_types' ) ), $pages );\r\n\r\n\r\n /**\r\n * 3.1. => General Post Options\r\n */\r\n $options['better_options'] = array(\r\n 'config' => array(\r\n 'title' => bf_get_admin_current_post_type() == 'page' ? __( 'Better Page Options', 'better-studio' ) : __( 'Better Post Options', 'better-studio' ),\r\n 'pages' => $pages,\r\n 'context' => 'normal',\r\n 'prefix' => false,\r\n 'priority' => 'high'\r\n ),\r\n 'panel-id' => '__better_mag__theme_options',\r\n 'fields' => $fields\r\n );\r\n\r\n\r\n /**\r\n * 3.3. => WooCommerce Product Page Options\r\n */\r\n if( function_exists( 'is_woocommerce' ) ){\r\n\r\n $fields = array();\r\n $fields['_layout'] = array(\r\n 'name' => __( 'Layout', 'better-studio' ),\r\n 'id' => '_layout',\r\n 'std' => '0' ,\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-paint',\r\n );\r\n $fields['_default_sidebar_layout'] = array(\r\n 'name' => __( 'Sidebar Position', 'better-studio' ),\r\n 'id' => '_default_sidebar_layout',\r\n 'std' => 'default',\r\n 'type' => 'image_select',\r\n 'section_class' => 'style-floated-left bordered',\r\n 'desc' => __( 'Select the sidebar layout for product. <br><br> <strong>Note:</strong> Default option image shows what style selected for default sidebar layout in theme options.', 'better-studio' ),\r\n 'options' => array(\r\n 'default' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-' . Better_Mag::get_option( 'shop_sidebar_layout' ) . '.png',\r\n 'label' => __( 'Default', 'better-studio' ),\r\n ),\r\n 'left' => array(\r\n 'img' => is_rtl() ? BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-right.png' : BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-left.png',\r\n 'label' => is_rtl() ? __( 'Right Sidebar', 'better-studio' ) : __( 'Left Sidebar', 'better-studio' ),\r\n ),\r\n 'right' => array(\r\n 'img' => is_rtl() ? BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-left.png' : BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-right.png',\r\n 'label' => is_rtl() ? __( 'Left Sidebar', 'better-studio' ) : __( 'Right Sidebar', 'better-studio' ),\r\n ),\r\n 'no-sidebar'=> array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/sidebar-no-sidebar.png',\r\n 'label' => __( 'No Sidebar', 'better-studio' ),\r\n ),\r\n )\r\n );\r\n\r\n $fields['_style'] = array(\r\n 'name' => __( 'Page Layout', 'better-studio' ),\r\n 'id' => '_style',\r\n 'std' => 'default',\r\n 'type' => 'image_select',\r\n 'section_class' => 'style-floated-left bordered',\r\n 'desc' => __( 'Select page layout style. <br><br> <strong>Note:</strong> Default option image shows default style that selected for page in theme options.', 'better-studio' ),\r\n 'options' => array(\r\n 'default' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/style-' . Better_Mag::get_option( 'layout_style' ) .'.png',\r\n 'label' => __( 'Default', 'better-studio' ),\r\n ),\r\n 'full-width'=> array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/style-full-width.png',\r\n 'label' => __( 'Full Width', 'better-studio' ),\r\n ),\r\n 'boxed' => array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/style-boxed.png',\r\n 'label' => __( 'Boxed', 'better-studio' ),\r\n ),\r\n 'boxed-padded'=> array(\r\n 'img' => BETTER_MAG_ADMIN_ASSETS_URI . 'images/style-boxed-padded.png',\r\n 'label' => __( 'Boxed (Padded)', 'better-studio' ),\r\n ),\r\n )\r\n );\r\n $fields['_style_options'] = array(\r\n 'name' => __( 'Page Style', 'better-studio' ),\r\n 'id' => '_style_options',\r\n 'std' => '0' ,\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-paint',\r\n );\r\n $fields['_bg_color'] = array(\r\n 'name' => __( 'Page Background Color', 'better-studio' ),\r\n 'id' => '_bg_color',\r\n 'type' => 'color',\r\n 'std' => Better_Mag::get_option( 'bg_color' ),\r\n 'save-std' => false,\r\n 'desc' => __( 'Setting a body background image below will override it.', 'better-studio' ),\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body',\r\n 'body.boxed',\r\n ),\r\n 'prop' => 'background-color'\r\n )\r\n ),\r\n );\r\n\r\n $fields['_bg_image'] = array(\r\n 'name' => __( 'Page Background Image', 'better-studio' ),\r\n 'id' => '_bg_image',\r\n 'type' => 'background_image',\r\n 'std' => '',\r\n 'save-std' => false,\r\n 'upload_label' => __( 'Upload Image', 'better-studio' ),\r\n 'desc' => __( 'Use light patterns in non-boxed layout. For patterns, use a repeating background. Use photo to fully cover the background with an image. Note that it will override the background color option.', 'better-studio' ),\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body'\r\n ),\r\n 'prop' => 'background-image',\r\n 'type' => 'background-image'\r\n )\r\n ),\r\n );\r\n $fields['_header_options'] = array(\r\n 'name' => __( 'Header', 'better-studio' ),\r\n 'id' => '_header_options',\r\n 'std' => '0' ,\r\n 'type' => 'tab',\r\n 'icon' => 'bsai-header',\r\n );\r\n $fields['_header_bg_color'] = array(\r\n 'name' => __( 'Header Background Color', 'better-studio' ),\r\n 'id' => '_header_bg_color',\r\n 'type' => 'color',\r\n 'std' => Better_Mag::get_option( 'header_bg_color' ),\r\n 'save-std' => false,\r\n 'desc' => __( 'Setting a header background pattern below will override it.','better-studio'),\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .header'\r\n ),\r\n 'prop' => array(\r\n 'background-color' => '%%value%%'\r\n )\r\n )\r\n )\r\n );\r\n $fields['_header_bg_image'] = array(\r\n 'name' => __( 'Header Background Image', 'better-studio' ),\r\n 'id' => '_header_bg_image',\r\n 'type' => 'background_image',\r\n 'std' => array( 'img' => '', 'type' => 'cover' ),\r\n 'save-std' => false,\r\n 'upload_label' => __( 'Upload Image', 'better-studio' ),\r\n 'desc' => __( 'Please use a background pattern that can be repeated. Note that it will override the header background color option.','better-studio'),\r\n 'css' => array(\r\n array(\r\n 'selector' => array(\r\n 'body .header'\r\n ),\r\n 'prop' => array( 'background-image' ),\r\n 'type' => 'background-image'\r\n )\r\n ),\r\n\r\n );\r\n $options['woocommerce_layout_metabox'] = array(\r\n 'config' => array(\r\n 'title' => __( 'Better Product Options', 'better-studio' ),\r\n 'pages' => array( 'product' ),\r\n 'context' => 'normal',\r\n 'prefix' => false,\r\n 'priority' => 'high'\r\n ),\r\n 'fields' => $fields,\r\n 'panel-id' => '__better_mag__theme_options',\r\n );\r\n }\r\n\r\n return $options;\r\n\r\n }", "title": "" }, { "docid": "10c0f8080ab9893edb2f4ddcb8792d46", "score": "0.59631056", "text": "public function item_custom_fields_to_form() {\n // 1. special management for fields equipped with \"free\" checkbox\n // nothing to do: they don't exist in this plugin\n\n // 2. special management for composite fields\n // nothing to do: they don't exist in this plugin\n\n // 3. special management for defaultvalue\n // nothing to do: defaultvalue doesn't need any further care\n }", "title": "" }, { "docid": "4c7749cf9fa19fef45a3641471d3f2e8", "score": "0.5961022", "text": "function wpcf_fields_checkboxes_meta_box_form( $field, $field_object ) {\n $options = array();\n if ( !empty( $field['data']['options'] ) ) {\n global $pagenow;\n foreach ( $field['data']['options'] as $option_key => $option ) {\n // Set value\n $options[$option_key] = array(\n '#value' => $option['set_value'],\n '#title' => wpcf_translate( 'field ' . $field['id'] . ' option '\n . $option_key . ' title', $option['title'] ),\n '#default_value' => (!empty( $field['value'][$option_key] )// Also check new post\n || ($pagenow == 'post-new.php' && !empty( $option['checked'] ))) ? 1 : 0,\n '#name' => 'wpcf[' . $field['id'] . '][' . $option_key . ']',\n '#id' => $option_key . '_'\n . wpcf_unique_id( serialize( $field ) ),\n '#inline' => true,\n '#after' => '<br />',\n );\n }\n }\n return array(\n '#type' => 'checkboxes',\n '#options' => $options,\n );\n}", "title": "" }, { "docid": "9c86843060259d79fa5a620e6f0d71f9", "score": "0.59608257", "text": "public function update_settings(){\n\t}", "title": "" }, { "docid": "a8db6da668b0ad6089490c699aa715a8", "score": "0.59559816", "text": "function globallink_adaptor_settings() {\n $form = array();\n\n $form['globallink_adaptor_settings'] = array(\n '#type' => 'fieldset',\n '#title' => t('Adaptor Settings'),\n '#collapsible' => TRUE,\n '#collapsed' => TRUE,\n );\n\n $form['globallink_adaptor_settings']['globallink_pager_limit'] = array(\n '#type' => 'textfield',\n '#title' => t('Dashboard Pager Limit'),\n '#default_value' => variable_get('globallink_pager_limit', 10),\n '#required' => TRUE,\n '#size' => 20,\n );\n\n $form['globallink_adaptor_settings']['globallink_enable_preview'] = array(\n '#type' => 'radios',\n '#title' => t('Enable Preview For Receive Translations'),\n '#default_value' => variable_get('globallink_enable_preview', 1),\n '#options' => array(t('No'), t('Yes')),\n );\n\n $form['globallink_adaptor_settings']['globallink_implementation_type'] = array(\n '#type' => 'radios',\n '#title' => t('Node/Field Translation Filter Implementation'),\n '#default_value' => variable_get('globallink_implementation_type', 0),\n '#description' => t('Changing this value will remove and reload the contents on the Dashboard based on the selected value. Please make sure that there are no active submissions.'),\n '#options' => array(t('Standard'), t('Using Hook (Refer documentation and hook_sample.php)')),\n );\n\n $form['globallink_adaptor_settings']['globallink_publish_node'] = array(\n '#type' => 'radios',\n '#title' => t('Publish Translated Content'),\n '#default_value' => variable_get('globallink_publish_node', 0),\n '#options' => array(t('No'), t('Yes'), t('Use Source Content Setting')),\n );\n\n $form['globallink_adaptor_settings']['globallink_cron_type'] = array(\n '#type' => 'radios',\n '#title' => t('Automatic Update Status'),\n '#default_value' => variable_get('globallink_cron_type', 0),\n '#options' => array(t('Disabled'), t('Drupal Cron')),\n );\n\n $form['globallink_adaptor_settings']['globallink_proxy_url'] = array(\n '#type' => 'textfield',\n '#title' => t('Proxy URL'),\n '#default_value' => variable_get('globallink_proxy_url', ''),\n '#required' => FALSE,\n '#size' => 50,\n );\n\n $form['globallink_adaptor_settings']['submit_general_save'] = array(\n '#type' => 'submit',\n '#value' => t('Save Adaptor Settings')\n );\n\n return $form;\n}", "title": "" }, { "docid": "5046fecf178357977cfb252c6ba824e3", "score": "0.5955271", "text": "function opts_upgrade_wrapper()\n\t{\n\t\t//Do a nonce check, prevent malicious link/form problems\n\t\tcheck_admin_referer($this->unique_prefix . '_admin_upgrade');\n\t\t//Grab the database options\n\t\t$opts = $this->get_option($this->unique_prefix . '_options');\n\t\tif(is_array($opts))\n\t\t{\n\t\t\t//Feed the just read options into the upgrade function\n\t\t\t$this->opts_upgrade($opts, $this->get_option($this->unique_prefix . '_version'));\n\t\t\t//Always have to update the version\n\t\t\t$this->update_option($this->unique_prefix . '_version', $this::version);\n\t\t\t//Store the options\n\t\t\t$this->update_option($this->unique_prefix . '_options', $this->opt);\n\t\t\t//Send the success message\n\t\t\t$this->messages[] = new mtekk_adminKit_message(esc_html__('Settings successfully migrated.', $this->identifier), 'success');\n\t\t}\n\t\telse\n\t\t{\n\t\t\t//Run the install script\n\t\t\t$this->install();\n\t\t\t//Send the success message\n\t\t\t$this->messages[] = new mtekk_adminKit_message(esc_html__('Default settings successfully installed.', $this->identifier), 'success');\n\t\t}\n\t\tadd_action('admin_notices', array($this, 'messages'));\n\t}", "title": "" }, { "docid": "5a70d6525b86c357d248784d818b2cef", "score": "0.5945888", "text": "function nik__theme_settings_submit(&$form, FormStateInterface &$form_state) {\n\n}", "title": "" }, { "docid": "e7c4aaf024faac2a586aa20662725c37", "score": "0.5934597", "text": "function theme_options_do_page() {\n global $select_options, $radio_options;\n\n if ( ! isset( $_REQUEST['settings-updated'] ) )\n $_REQUEST['settings-updated'] = false;\n\n ?>\n <div class=\"wrap\">\n <?php screen_icon(); echo \"<h2>\" . __( ' Theme Options', 'bamboo' ) . \"</h2>\"; ?>\n\n <?php if ( false !== $_REQUEST['settings-updated'] ) : ?>\n <div class=\"updated fade\"><p><strong><?php _e( 'Options saved', 'bamboo' ); ?></strong></p></div>\n <?php endif; ?>\n\n <form method=\"post\" action=\"options.php\">\n <?php settings_fields( 'bamboo_options' ); ?>\n <?php $options = get_option( 'bamboo_theme_options' ); ?>\n\n <table class=\"form-table\">\n\n <?php\n /**\n * Google Analytics\n */\n ?>\n <tr valign=\"top\"><th scope=\"row\"><?php _e( 'Google Analytics', 'bamboo' ); ?></th>\n <td>\n <input id=\"bamboo_theme_options[google_analytics]\" class=\"regular-text\" type=\"text\" name=\"bamboo_theme_options[google_analytics]\" value=\"<?php esc_attr_e( $options['google_analytics'] ); ?>\" />\n <label class=\"description\" for=\"bamboo_theme_options[google_analytics]\"><?php _e( 'Google Analytics ID', 'bamboo' ); ?></label>\n </td>\n </tr>\n\n <?php\n /**\n * Email\n */\n ?>\n <tr valign=\"top\"><th scope=\"row\"><?php _e( 'Email', 'bamboo' ); ?></th>\n <td>\n <input id=\"bamboo_theme_options[email]\" class=\"regular-text\" type=\"text\" name=\"bamboo_theme_options[email]\" value=\"<?php esc_attr_e( $options['email'] ); ?>\" />\n <label class=\"description\" for=\"bamboo_theme_options[email]\"><?php _e( 'Email address', 'bamboo' ); ?></label>\n </td>\n </tr>\n\n <?php\n /**\n * Twitter\n */\n ?>\n <tr valign=\"top\"><th scope=\"row\"><?php _e( 'Twitter', 'bamboo' ); ?></th>\n <td>\n <input id=\"bamboo_theme_options[twitter]\" class=\"regular-text\" type=\"text\" name=\"bamboo_theme_options[twitter]\" value=\"<?php esc_attr_e( $options['twitter'] ); ?>\" />\n <label class=\"description\" for=\"bamboo_theme_options[twitter]\"><?php _e( 'Twitter profile URL', 'bamboo' ); ?></label>\n </td>\n </tr>\n\n <?php\n /**\n * LinkedIn\n */\n ?>\n <tr valign=\"top\"><th scope=\"row\"><?php _e( 'LinkedIn', 'bamboo' ); ?></th>\n <td>\n <input id=\"bamboo_theme_options[linkedin]\" class=\"regular-text\" type=\"text\" name=\"bamboo_theme_options[linkedin]\" value=\"<?php esc_attr_e( $options['linkedin'] ); ?>\" />\n <label class=\"description\" for=\"bamboo_theme_options[linkedin]\"><?php _e( 'LinkedIn profile URL', 'bamboo' ); ?></label>\n </td>\n </tr>\n\n <?php\n /**\n * Google Plus\n */\n ?>\n <tr valign=\"top\"><th scope=\"row\"><?php _e( 'Google Plus', 'bamboo' ); ?></th>\n <td>\n <input id=\"bamboo_theme_options[gplus]\" class=\"regular-text\" type=\"text\" name=\"bamboo_theme_options[gplus]\" value=\"<?php esc_attr_e( $options['gplus'] ); ?>\" />\n <label class=\"description\" for=\"bamboo_theme_options[gplus]\"><?php _e( 'Google Plus profile URL', 'bamboo' ); ?></label>\n </td>\n </tr>\n\n\n </table>\n\n <p class=\"submit\">\n <input type=\"submit\" class=\"button-primary\" value=\"<?php _e( 'Save Options', 'bamboo' ); ?>\" />\n </p>\n </form>\n </div>\n\n <?php\n}", "title": "" }, { "docid": "d2412e300590688cbd3f56055de1d251", "score": "0.593263", "text": "private function updateSystemCheck() {\n update_site_option( 'metaslider_systemcheck', $this->options );\n }", "title": "" }, { "docid": "11cfb2df52c36401aa8dadd1b51ad643", "score": "0.59221137", "text": "public function setFields()\n\t{\n\n\t\tforeach ($this->managers as $key => $value)\n\t\t{\n\t\t\t$args[] = array(\n\t\t\t\t'id' => $key,\n\t\t\t\t'title' => $value,\n\t\t\t\t'callback' => array ($this->callbacks_mngr , 'checkboxField'),\n\t\t\t\t'page' => 'mtk_plugin', //The slug of the page\n\t\t\t\t'section' => 'mtk_admin_index', // The id of the seciton\n\t\t\t\t'args' => array(\n\t\t\t\t\t'option_name' => 'mtk_plugin',\n\t\t\t\t\t'label_for' => $key, /* The label should always match the id, that is the way we are sending the information to the callback function */\n\t\t\t\t\t'class' => 'ui-toggle'\n\n\t\t\t\t)\n\t\t\t);\n\n\t\t}\n\t\t$this->settings->setFields( $args );\n\t}", "title": "" }, { "docid": "f3160dc608cb3dbf3ee9caba3231ddc7", "score": "0.59092724", "text": "function save_post_type_settings(){\n\t\tif ( ! empty( $_POST['post_check_submit'] ) && check_admin_referer( 'custom_post_settings', 'custom-post-settings-fields' ) ) {\n\t\t // process form data\n\t\t\tif(!empty($_POST['post_type_title'])){\n\t\t\t\t$option_name = 'post_type_title';\n\t\t\t\t$option_name_value = $_POST['post_type_title'];\n\t\t\t}else{\n\t\t\t\t$option_name = 'post_type_title';\n\t\t\t\t$option_name_value = NULL;\n\t\t\t}\n\n\t\t\tif(array_key_exists('post_type_check', $_POST)){\n\t\t\t\t$option_name1 = 'post_type_check';\n\t\t\t\t$option_name_value1 = maybe_serialize($_POST['post_type_check']);\n\t\t\t}else{\n\t\t\t\t$option_name1 = 'post_type_check';\n\t\t\t\t$option_name_value1 = NULL;\n\t\t\t}\n\n\t\t\t$res_arr = array();\n\t\t\tif ( get_option( $option_name ) !== false ) {\n\t update_option( $option_name, $option_name_value );\n\t $res_arr[] = 'update';\n\t } else {\n\t $deprecated = null;\n\t $autoload = 'no';\n\t add_option( $option_name, $option_name_value, $deprecated, $autoload );\n\t $res_arr[] = 'save';\n\t }\n\t if ( get_option( $option_name1 ) !== false ) {\n\t update_option( $option_name1, $option_name_value1 );\n\t $res_arr[] = 'update';\n\t } else {\n\t $deprecated1 = null;\n\t $autoload1 = 'no';\n\t add_option( $option_name1, $option_name_value1, $deprecated1, $autoload1 );\n\t $res_arr[] = 'save'; \n\t }\n\t if(in_array('update', $res_arr)){\n\t \tjob_errors()->add('Update', __('Setting updated successfully'));\n\t }else{\n\t \tjob_errors()->add('Save', __('Setting saved successfully'));\n\t }\n\t\t}\t\n }", "title": "" }, { "docid": "33c334fb6421fa717810fcf6154aba5f", "score": "0.5907067", "text": "public function setSettings()\n\t{\n\n\t\t$args = array(\n\t\t\tarray(\n\t\t\t\t'option_group' => 'mtk_plugin_settings',\n\t\t\t\t'option_name' => 'mtk_plugin', //same name as the page slug\n\t\t\t\t'callback' => array( $this->callbacks_mngr, 'checkboxSanitize' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->settings->setSettings( $args );\n\t}", "title": "" }, { "docid": "1e606afb7dc3e086c99e2d264b8f8571", "score": "0.59036297", "text": "function product_options_meta_box_save($post_id)\n{\n if( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;\n \n // if our nonce isn't there, or we can't verify it, bail\n if( !isset( $_POST['product_options_meta_box_nonce'] ) || !wp_verify_nonce( $_POST['product_options_meta_box_nonce'], 'product_options_meta_box' ) ) return;\n \n // if our current user can't edit this post, bail\n if ( !current_user_can( 'edit_post', $post_id ) ) return;\n\n if( isset( $_POST['page_product_layout'] ) )\n update_post_meta( $post_id, 'page_product_layout', esc_attr( $_POST['page_product_layout'] ) );\n\n if( isset( $_POST['page_product_youtube'] ) )\n update_post_meta( $post_id, 'page_product_youtube', esc_attr( $_POST['page_product_youtube'] ) );\n\n $chk = isset($_POST['product_full_screen_description_meta_box_check']) ? 'on' : 'off';\n update_post_meta( $post_id, 'product_full_screen_description_meta_box_check', $chk );\n}", "title": "" }, { "docid": "4efe33f899386f2f359d3acbf2fd23ed", "score": "0.58932537", "text": "function mailfish_admin_settings_form() {\n $form = array();\n $form['mailfish_types'] = array(\n '#title' => t('The content types to enable MailFish subscriptions for'),\n '#description' => t('On the specified node types, a MailFish subscription option will be available and can be enabled while that node is being edited.'),\n '#type' => 'checkboxes',\n '#options' => node_type_get_names(),\n '#default_value' => variable_get('mailfish_types', array()),\n );\n return system_settings_form($form);\n}", "title": "" }, { "docid": "78a72d8da6ac198c4365a8b05c8bcdad", "score": "0.58812207", "text": "protected function initExtendedSettings()\n\t{\n\t\tif(is_object($this->form))\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\tinclude_once('Services/Form/classes/class.ilPropertyFormGUI.php');\n\t\t$this->form = new ilPropertyFormGUI();\n\t\t$this->form->setFormAction($this->ctrl->getFormAction($this));\n\t\t$this->form->setTitle($this->lng->txt('ext_cat_settings'));\n\t\t$this->form->addCommandButton('updateInfo',$this->lng->txt('save'));\n\t\t$this->form->addCommandButton('editInfo',$this->lng->txt('cancel'));\n\n\t\tinclude_once('Services/AdvancedMetaData/classes/class.ilAdvancedMDRecordGUI.php');\n\t\t$this->record_gui = new ilAdvancedMDRecordGUI(ilAdvancedMDRecordGUI::MODE_EDITOR,'cat',$this->object->getId());\n\t\t$this->record_gui->setPropertyForm($this->form);\n\t\t$this->record_gui->parse();\n\t\t\n\t\treturn true;\n\t}", "title": "" }, { "docid": "f61b63ba00ee2089ade6c46c294e4fe1", "score": "0.58773744", "text": "function dmforms_plugin_update_db_check()\n{\n global $dmforms_plugin_db_version;\n if (get_site_option('dmforms_plugin_db_version') != $dmforms_plugin_db_version) {\n dmforms_plugin_install();\n }\n}", "title": "" }, { "docid": "b3cacfd84cd5f083b66292fe5ddf3986", "score": "0.587521", "text": "function meta_save(){\n\t\tglobal $post;\n\t\t$type = $post->post_type;\n\t\n\t\t//Make sure this is valid\n\t\tif ( defined('DOING_AUTOSAVE' ) && DOING_AUTOSAVE )\n\t\t\treturn;\n\t\tif ( !wp_verify_nonce( $_POST[$type.'_meta_box'], plugin_basename(__FILE__ ) ) )\n\t\t\treturn;\n\t\n\t\t//Go through the options extra fields\n\t\tforeach( $this ->{$type . '_meta_fields'} as $field ){\n\t\t\tupdate_post_meta( $post->ID, $field, $_POST[$field ] );\n\t\t}\n\t\n\t\n\t}", "title": "" }, { "docid": "fe2b5bfcd20122dbb990f7a9df33b93c", "score": "0.5873013", "text": "public function adminSettingsSubform () {\n }", "title": "" }, { "docid": "0aec3744357537735357569e4182c4bb", "score": "0.58619565", "text": "function theme_options_do_page() {\n global $select_options, $radio_options;\n\n if ( ! isset( $_REQUEST['settings-updated'] ) )\n $_REQUEST['settings-updated'] = false;\n ?>\n\n <div class=\"wrap\"> \n <h2>Theme Options</h2>\n\n <?php if ( false !== $_REQUEST['settings-updated'] ) : ?>\n <div class=\"updated fade\"><p><strong><?php _e( 'Options saved', 'maju' ); ?></strong></p></div>\n <?php endif; ?>\n\n <form method=\"post\" action=\"options.php\">\n <?php settings_fields( 'maju_options' ); ?>\n <?php $options = get_option( 'maju_theme_options' ); ?>\n\n <table class=\"form-table\">\n <tr valign=\"top\">\n <th scope=\"row\" class=\"option_name\"><?php _e( 'Logo URL', 'maju' ); ?></th>\n <td>\n <input id=\"maju_theme_options[logo_url]\" class=\"regular-text\" type=\"text\" name=\"maju_theme_options[logo_url]\" value=\"<?php esc_attr_e( $options['logo_url'] ); ?>\" />\n </td>\n </tr>\n <tr valign=\"top\">\n <th scope=\"row\" class=\"option_name\"><?php _e( 'Favico URL', 'maju' ); ?></th>\n <td>\n <input id=\"maju_theme_options[favico_url]\" class=\"regular-text\" type=\"text\" name=\"maju_theme_options[favico_url]\" value=\"<?php esc_attr_e( $options['favico_url'] ); ?>\" />\n </td>\n </tr>\n <tr valign=\"top\">\n <th scope=\"row\" class=\"option_name\"><?php _e( 'Apple Touch Icon URL', 'maju' ); ?></th>\n <td>\n <input id=\"maju_theme_options[appleicon_url]\" class=\"regular-text\" type=\"text\" name=\"maju_theme_options[appleicon_url]\" value=\"<?php esc_attr_e( $options['appleicon_url'] ); ?>\" />\n </td>\n </tr>\n <tr valign=\"top\">\n <th scope=\"row\" class=\"option_name\"><?php _e( 'Links color', 'maju' ); ?></th>\n <td class=\"color\">\n <span class=\"description\"><?php _e('Links:', 'maju'); ?></span>\n <input id=\"maju_theme_options_links_color\" class=\"small-text\" type=\"text\" name=\"maju_theme_options[links_color]\" value=\"<?php esc_attr_e( $options['links_color'] ); ?>\" />\n <span class=\"description\"><?php _e('Hover:', 'maju'); ?></span>\n <input id=\"maju_theme_options_links_color_hover\" class=\"small-text\" type=\"text\" name=\"maju_theme_options[links_hover]\" value=\"<?php esc_attr_e( $options['links_hover'] ); ?>\" />\n <br />\n <span class=\"description\"><?php _e('Leave fields blank to set default color, enter hex values or color name', 'maju'); ?></span>\n </td>\n </tr>\n <tr valign=\"top\">\n <th scope=\"row\" class=\"option_name\"><?php _e( 'Footer &copy;', 'maju' ); ?></th>\n <td>\n <input id=\"maju_theme_options[footer_copy]\" class=\"regular-text\" type=\"text\" name=\"maju_theme_options[footer_copy]\" value=\"<?php esc_attr_e( $options['footer_copy'] ); ?>\" />\n </td>\n </tr>\n <tr valign=\"top\">\n <th scope=\"row\" class=\"option_name\"><?php _e( 'G analytics', 'maju' ); ?></th>\n <td>\n <input id=\"maju_theme_options[g_a]\" class=\"regular-text\" type=\"text\" name=\"maju_theme_options[g_a]\" value=\"<?php esc_attr_e( $options['g_a'] ); ?>\" />\n <span class=\"description\"><?php _e('Insert G analytics like \"UA-29723403-1\"', 'maju'); ?></span>\n </td>\n </tr>\n <tr valign=\"top\">\n <th scope=\"row\" class=\"option_name\"><?php _e( 'Custom CSS', 'maju' ); ?></th>\n <td>\n <textarea id=\"maju_theme_options[custom_css]\" class=\"large-text code\" name=\"maju_theme_options[custom_css]\" cols=\"\" rows=\"10px\"><?php echo stripslashes(htmlspecialchars($options['custom_css'] )); ?></textarea>\n <span class=\"description\"><?php _e('Add your own styles, use only if you know what you are doing.', 'maju'); ?></span>\n </td>\n </tr>\n <tr valign=\"top\">\n <th scope=\"row\" class=\"option_name\"><?php _e( 'Custom Javascript', 'maju' ); ?></th>\n <td>\n <textarea id=\"maju_theme_options[custom_javascript]\" class=\"large-text code\" name=\"maju_theme_options[custom_javascript]\" cols=\"\" rows=\"10px\"><?php echo stripslashes($options['custom_javascript']); ?></textarea>\n <span class=\"description\"><?php _e('Add your own scripts, use only if you know what you are doing.', 'maju'); ?></span>\n </td>\n </tr>\n <tr valign=\"top\">\n <td colspan=\"2\">\n <p class=\"submit\">\n <input type=\"submit\" class=\"button-primary\" value=\"<?php _e( 'Save Options', 'maju' ); ?>\" />\n </p>\n </td>\n </tr>\n </table>\n </form>\n </div>\n <?php\n}", "title": "" }, { "docid": "3028777bf20028b452ae857422a42ff9", "score": "0.58594066", "text": "function save_meta_settings($post_id) { \n global $meta_settings; \n \n // verify nonce \n if (!isset($_POST['meta_settings_nonce']) || !wp_verify_nonce($_POST['meta_settings_nonce'], basename(__FILE__))) \n return $post_id; \n\t\t\n // check autosave \n if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) \n return $post_id;\n\t\t\n // check permissions \n if ('page' == $_POST['post_type']) { \n if (!current_user_can('edit_page', $post_id)) \n return $post_id; \n } elseif (!current_user_can('edit_post', $post_id)) { \n return $post_id; \n } \n \n // loop through fields and save the data \n foreach ($meta_settings as $field) { \n $old = get_post_meta($post_id, $field['id'], true); \n $new = $_POST[$field['id']]; \n if ($new && $new != $old) { \n update_post_meta($post_id, $field['id'], $new); \n } elseif ('' == $new && $old) { \n delete_post_meta($post_id, $field['id'], $old); \n } \n } // end foreach \n}", "title": "" }, { "docid": "43831ee71bc6bc6886e80d28976c98ed", "score": "0.582125", "text": "function clockwork_interface_metabox( $post ) {\n\n\t// Add an nonce field so we can check for it later.\n\twp_nonce_field( 'clockwork_interface', 'clockwork_meta_box_nonce' );\n\n\t/*\n\t * Use get_post_meta() to retrieve an existing value\n\t * from the database and use the value for the form.\n\t */\n\t$value = get_post_meta( $post->ID, 'clockwork_interface_state', true );\n\n\t$clockwork_metas = get_post_meta( $post->ID, 'clockwork_metas', true );\n\n\t$temp = '';\n\n\techo \t'\t<label for=\"clockwork_interface_state\">';\n\t\t\t\t\t_e( 'Clockwork Interface State : ', 'calibrefx' );\n\techo \t'\t</label> ';\n\n\techo \t'\t<select name=\"clockwork_interface_state\" id=\"clockwork_interface_state\" value=\"'.esc_attr( $value ).'\">\n\t\t\t\t\t<option '. ( esc_attr( $value ) == 1 ? 'selected': '' ) .' value=\"1\">Active</option>\n\t\t\t\t\t<option '. ( esc_attr( $value ) == 0 ? 'selected': '' ) .' value=\"0\">Inactive</option>\n\t\t\t\t</select>';\n\n\tif( $value == 1 ){\n\n\t\t$temp .= \t'\t<br>';\n\n\t\t$temp .= \t'\tHook Control';\n\n\t\t$temp .= \t'\t<br>';\n\n\t\t$temp .= \t'\t<label for=\"clockwork_interface_state\">add_action => </label> ';\n\n\t\t// $temp .= \t'\t<input type=\"text\" name=\"calibrefx_settings_clockwork_test\" value=\"'. $value2 .'\" />';\n\t\t$temp .= \t'\t<input type=\"text\" name=\"clockwork_metas[loop_hook]\" value=\"'. ( $clockwork_metas['loop_hook'] ? $clockwork_metas['loop_hook'] : '' ) .'\" />';\n\t\t$temp .= \t'\t<input type=\"text\" name=\"clockwork_metas[loop_template]\" value=\"'. ( $clockwork_metas['loop_template'] ? $clockwork_metas['loop_template'] : '' ) .'\" />';\n\t\t$temp .= \t'\t<input type=\"text\" name=\"clockwork_metas[loop_priority]\" value=\"'. ( $clockwork_metas['loop_priority'] ? $clockwork_metas['loop_priority'] : '' ) .'\" />';\n\t\t$temp .= \t'\t<br>';\n\t\t$temp .= \t'\tremove_action => <input type=\"checkbox\" name=\"clockwork_metas[loop_remove]\" value=\"remove\" '. ( $clockwork_metas['loop_remove'] ? 'checked' : '' ) .' />';\n\t\t$temp .= \t'\t<input type=\"text\" name=\"clockwork_metas[loop_remove_hook]\" value=\"'. ( $clockwork_metas['loop_remove_hook'] ? $clockwork_metas['loop_remove_hook'] : '' ) .'\" />';\n\t}\n\n\techo \t'\t<div class=\"row\">\n\t\t\t\t\t<div class=\"col-md-12\">\n\t\t\t\t\t\t<div id=\"clockwork_customize_wrapper\" class=\"clockwork-settings-slug-'. $post->post_title .' clockwork-settings-id-'. $post->post_title .'\">\n\t\t\t\t\t\t\t'. $temp .'\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</div>';\n}", "title": "" }, { "docid": "0b99e071c690195b480a5b0022449a13", "score": "0.5816483", "text": "function servicebot_embedded_form_content_type_edit_form_submit($form, &$form_state) {\n foreach (array_keys($form_state['plugin']['defaults']) as $key) {\n if (isset($form_state['values'][$key])) {\n $form_state['conf'][$key] = $form_state['values'][$key];\n }\n }\n}", "title": "" }, { "docid": "a11a866ead0f8c8ef62a61d9358225bb", "score": "0.5814728", "text": "function settings_form(){}", "title": "" }, { "docid": "c0342753914ac6195486be128c156d97", "score": "0.5813687", "text": "function as_quick_add_admin_menu_page_func(){\n\t$as_save = false;\n\tif (empty($_POST['as_submit']) === false) {\n\t\tif (empty($_POST['as_name']) === false) {\n\t\t\t$as_save = as_quick_add_admin_menu_init($_POST['as_name']);\n\t\t}\n\t}\n\n\t$data = get_option('as_quick_meta_option');\n\n?>\n<div class=\"wrap\">\n\t<h2>Add Meta Box</h2>\n<?php if ($as_save === true): ?>\n\t<div id=\"setting-error-settings_updated\" class=\"updated settings-error notice is-dismissible\"> \n\t<p><strong>Meta options saved.</strong></p><button type=\"button\" class=\"notice-dismiss\"><span class=\"screen-reader-text\">Dismiss this notice.</span></button></div>\n\n<?php endif ?>\n\n\t<div class=\"as_add_meta_box_container\">\n\t\t<div class=\"as_add_meta_box_row\">\n\t\t\t<form action=\"<?php echo home_url( 'wp-admin/admin.php?page=add-meta-box' ); ?>\" id=\"as_add_meta_box_form\" method=\"post\">\n\t\t\t\t<ul>\n\t\t\t\t\t<?php if (empty($data) === false): ?>\n\t\t\t\t\t\t<?php foreach ($data as $key => $value): ?>\n\t\t\t\t\t<li>\n\t\t\t\t\t\t<span class=\"as_label\">Name</span>\n\t\t\t\t\t\t<input type=\"text\" class=\"widefat\" name=\"as_name[]\" value=\"<?php echo $value; ?>\">\n\t\t\t\t\t\t<span class=\"button button-default\" onclick=\"as_remove_meta_box_item(this)\">Remove</span>\n\t\t\t\t\t</li>\n\t\t\t\t\t\t<?php endforeach ?>\n\t\t\t\t\t<?php else: ?>\n\t\t\t\t\t<li>\n\t\t\t\t\t\t<span class=\"as_label\">Name</span>\n\t\t\t\t\t\t<input type=\"text\" class=\"widefat\" name=\"as_name[]\" value=\"\">\n\t\t\t\t\t\t<span class=\"button button-default\" onclick=\"as_remove_meta_box_item(this)\">Remove</span>\n\t\t\t\t\t</li>\n\t\t\t\t\t<?php endif ?>\n\t\t\t\t</ul>\n\t\t\t\t<input type=\"submit\" class=\"button button-primary\" id=\"as_add_meta_box_submit\" value=\"Save\" name=\"as_submit\" >\n\t\t\t\t<span class=\"button button-primary\" id=\"as_add_meta_box_add_new\" >Add New</span>\n\t\t\t</form>\t\t\t\n\t\t</div>\n\t</div>\n</div>\n<?php\n}", "title": "" }, { "docid": "a9c468a12ea98f1175b028a9a63f4eca", "score": "0.5794897", "text": "abstract public function settingsForm(&$form, &$form_state);", "title": "" }, { "docid": "fe4b1c41f4143eca8ce9da5e5d55b240", "score": "0.5786381", "text": "function wpcf_fields_checkboxes_editor_submit( $data, $field, $context ) {\n $add = '';\n $shortcode = '';\n if ( $context == 'usermeta' ) {\n $add .= wpcf_get_usermeta_form_addon_submit();\n } elseif ( $context == 'termmeta' ) {\n $add .= wpcf_get_termmeta_form_addon_submit();\n\t}\n if ( !empty( $data['options'] ) ) {\n if ( $data['display'] == 'display_all' ) {\n $separator = !empty( $data['cbs_separator'] ) ? $data['cbs_separator'] : '';\n $_add = $add . ' separator=\"' . $separator . '\"';\n if ( $context == 'usermeta' ) {\n $shortcode .= wpcf_usermeta_get_shortcode( $field, $_add );\n\t\t\t} elseif ( $context == 'termmeta' ) {\n\t\t\t\t$shortcode = wpcf_termmeta_get_shortcode( $field, $add );\n } else {\n $shortcode .= wpcf_fields_get_shortcode( $field, $_add );\n }\n } else {\n $i = 0;\n foreach ( $data['options'] as $option ) {\n if ( $data['display'] == 'value' ) {\n $checked_add = $add . ' option=\"' . $i . '\" state=\"checked\"';\n $unchecked_add = $add . ' option=\"' . $i . '\" state=\"unchecked\"';\n\n if ( $context == 'usermeta' ) {\n $shortcode_checked = wpcf_usermeta_get_shortcode( $field,\n $checked_add, $option['selected'] );\n $shortcode_unchecked = wpcf_usermeta_get_shortcode( $field,\n $unchecked_add, $option['not_selected'] );\n\t\t\t\t\t} elseif ( $context == 'termmeta' ) {\n\t\t\t\t\t\t$shortcode_checked = wpcf_termmeta_get_shortcode( $field,\n $checked_add, $option['selected'] );\n $shortcode_unchecked = wpcf_termmeta_get_shortcode( $field,\n $unchecked_add, $option['not_selected'] );\n } else {\n $shortcode_checked = wpcf_fields_get_shortcode( $field,\n $checked_add, $option['selected'] );\n $shortcode_unchecked = wpcf_fields_get_shortcode( $field,\n $unchecked_add, $option['not_selected'] );\n }\n $shortcode .= $shortcode_checked . $shortcode_unchecked;\n } else {\n $add = ' option=\"' . $i . '\"';\n if ( $context == 'usermeta' ) {\n $add .= wpcf_get_usermeta_form_addon_submit();\n\t\t\t\t\t\t$shortcode .= wpcf_usermeta_get_shortcode( $field, $add );\n } elseif ( $context == 'termmeta' ) {\n\t\t\t\t\t\t$add .= wpcf_get_termmeta_form_addon_submit();\n\t\t\t\t\t\t$shortcode = wpcf_termmeta_get_shortcode( $field, $add );\n } else {\n $shortcode .= wpcf_fields_get_shortcode( $field, $add );\n }\n }\n $i++;\n }\n }\n } else {\n\t\t if ( $context == 'usermeta' ) {\n\t\t\t$shortcode .= wpcf_usermeta_get_shortcode( $field, $add );\n\t\t} elseif ( $context == 'termmeta' ) {\n\t\t\t$shortcode = wpcf_termmeta_get_shortcode( $field, $add );\n } else {\n $shortcode .= wpcf_fields_get_shortcode( $field, $add );\n }\n }\n return $shortcode;\n}", "title": "" }, { "docid": "6c7f669a9e4a00097cccd5b3fc33c868", "score": "0.5786043", "text": "public function upgrade() {\n $db = Loader::db();\n $sql = 'SELECT * FROM information_schema.COLUMNS WHERE TABLE_SCHEMA = \"'.DB_DATABASE.'\" AND TABLE_NAME = \"atRemoPagelistAttributeSettings\" AND COLUMN_NAME = \"displayMultilingualSection\"';\n $row = $db->GetAll($sql);\n if (empty($row)) {\n $sql = 'ALTER TABLE atRemoPagelistAttributeSettings ADD displayMultilingualSection INT(255) after displayDropDown';\n $db->Execute($sql);\n Log::addEntry(t('Table atRemoPagelistAttributeSettings expanded with column displayMultilingualSection'), 'packages');\n }\n\n\t\t$pkg = Package::getByHandle($this->pkgHandle);\n\t\t$ci = new ContentImporter();\n\t\ttry {\n\t\t\t$ci->importContentFile($pkg->getPackagePath() . '/install.xml');\n\t\t} catch (Exception $ex) {\n\t\t\t\n\t\t}\n \n\t\tparent::upgrade();\n\t}", "title": "" }, { "docid": "9e7966d1121d7b461ab94695604fc944", "score": "0.5785202", "text": "function options_version_update( $settings ) {\n\n\t\t// nothing here yet\n\n\t}", "title": "" }, { "docid": "d61b3aad22fb3a4954e1f5a0bc362223", "score": "0.5781562", "text": "function contact_form_user_admin_settings_alter(&$form, &$form_state) {\n $form['contact'] = array(\n '#type' => 'fieldset',\n '#title' => t('Contact settings'),\n '#weight' => 0,\n );\n $form['contact']['contact_default_status'] = array(\n '#type' => 'checkbox',\n '#title' => t('Enable the personal contact form by default for new users.'),\n '#description' => t('Changing this setting will not affect existing users.'),\n '#default_value' => variable_get('contact_default_status', 1),\n );\n}", "title": "" }, { "docid": "691082176e462106080dbe6961f5ef27", "score": "0.57732445", "text": "public function wp_facebook_webmasters_admin_action_handler () \n {\n $values = serialize( $_POST );\n\n if( isset( $_POST['webmasters-submit'] ) ) \n {\n\n if ( get_option( static::$option_name ) !== false ) {\n update_option( static::$option_name, $values );\n } else {\n add_option( static::$option_name, $values );\n }\n\n if ( wp_redirect( 'admin.php?page='.static::$plugin_page ) ) {\n exit;\n }\n \n }\n\n \n }", "title": "" }, { "docid": "a7f3ae3f33ac25b644aaa7f3acf4993c", "score": "0.5769005", "text": "function updateSettings($link)\n{\n if (isset($_POST['update-settings'])) {\n updateStudioName($link);\n updateVisibility($link);\n updateAllowFork($link);\n updateDescription($link);\n updateGenres($link);\n addCollaborator($link);\n removeCollaborator($link);\n }\n}", "title": "" }, { "docid": "ae4069221e5590178ebbbe225acd7b41", "score": "0.57681704", "text": "public function admin_update() {\n\n /**\n * Remove admin metaboxs\n */\n add_filter('add_meta_boxes', array(&$this, 'remove_meta_boxes'));\n add_filter('wpseo_metabox_prio', function () {\n return 'low';\n });\n\n /**\n * Adding custom admin JS\n */\n if (is_admin()) {\n add_action('in_admin_footer', array(\n &$this,\n 'addAdminJsHack'\n )); // Global Admin JS Hack\n }\n\n /**\n * Admin Tweaks\n */\n // No self ping\n add_action('pre_ping', array(&$this, 'noSelfPing'));\n // Enable more buttons in tinyMCE\n add_filter('mce_buttons', array(&$this, 'enableMoreButtons'));\n // Remove various items from dashboard.\n add_action('admin_menu', array(&$this, 'customDashboardWidgets'));\n }", "title": "" }, { "docid": "5cb411c45218df8ac81ad749cc692a26", "score": "0.5766418", "text": "function miba_options_settings_init() {\n\t\n\tregister_setting('theme_miba_options','theme_miba_options', 'miba_options_validate');\n\t\n\tadd_settings_section('miba_settings_frontpage','Froside','miba_settings_frontpage_text', 'miba');\n\tadd_settings_field('miba_setting_front_slug', 'Forside slagord', 'miba_setting_front_slug', 'miba', 'miba_settings_frontpage');\n\t\n\tadd_settings_section('miba_settings_footer','Footer','miba_settings_footer_text', 'miba');\n\tadd_settings_field('miba_setting_footer_copy', 'Footer instillinger', 'miba_setting_footer_copy', 'miba', 'miba_settings_footer');\n\t\n\tadd_settings_section('miba_settings_sosialemedier', 'Sosiale Medier', 'miba_settings_sosialemedier_text', 'miba');\n\tadd_settings_field('miba_setting_sm', 'Medier', 'miba_setting_sm', 'miba', 'miba_settings_sosialemedier');\n\t\n\t\n}", "title": "" }, { "docid": "8460cf72f7a5c71b081fdf523d6b7440", "score": "0.57614255", "text": "public function load_settings_fields() {\n\t\t\t$field_name_wrap = false;\n\t\t\t$this->setting_option_fields = array(\n\t\t\t\t'titleHidden' => array(\n\t\t\t\t\t'name' => 'titleHidden',\n\t\t\t\t\t'name_wrap' => $field_name_wrap,\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'label' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: quiz.\n\t\t\t\t\t\tesc_html_x( 'Hide %s title', 'placeholder: quiz', 'learndash' ),\n\t\t\t\t\t\tLearnDash_Custom_Label::label_to_lower( 'quiz' )\n\t\t\t\t\t),\n\t\t\t\t\t'help_text' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: quiz.\n\t\t\t\t\t\tesc_html_x( 'The title serves as %s heading.', 'placeholder: quiz', 'learndash' ), \n\t\t\t\t\t\tLearnDash_Custom_Label::label_to_lower( 'quiz' )\n\t\t\t\t\t),\n\t\t\t\t\t'value' => $this->pro_quiz_edit->isTitleHidden() ? true : '',\n\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t'1' => esc_html__( 'Activate', 'learndash' ),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'btnRestartQuizHidden' => array(\n\t\t\t\t\t'name' => 'btnRestartQuizHidden',\n\t\t\t\t\t'name_wrap' => $field_name_wrap,\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'label' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: quiz.\n\t\t\t\t\t\tesc_html_x( 'Hide \"Restart %s\" button', 'placeholder: quiz', 'learndash' ),\n\t\t\t\t\t\tLearnDash_Custom_Label::label_to_lower( 'quiz' )\n\t\t\t\t\t),\n\t\t\t\t\t'help_text' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: quiz.\n\t\t\t\t\t\tesc_html_x( 'Hide the \"Restart %s\" button in the Frontend.', 'placeholder: quiz', 'learndash' ), \n\t\t\t\t\t\tLearnDash_Custom_Label::label_to_lower( 'quiz' )\n\t\t\t\t\t),\n\t\t\t\t\t'value' => $this->pro_quiz_edit->isBtnRestartQuizHidden() ? true : '',\n\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t'1' => esc_html__( 'Activate', 'learndash' ),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'btnViewQuestionHidden' => array(\n\t\t\t\t\t'name' => 'btnViewQuestionHidden',\n\t\t\t\t\t'name_wrap' => $field_name_wrap,\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'label' => esc_html__( 'Hide \"View question\" button', 'learndash' ),\n\t\t\t\t\t'help_text' => esc_html__( 'Hide the \"View question\" button in the Frontend.', 'learndash' ),\n\t\t\t\t\t'value' => $this->pro_quiz_edit->isBtnViewQuestionHidden() ? true : '',\n\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t'1' => esc_html__( 'Activate', 'learndash' ),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'questionRandom' => array(\n\t\t\t\t\t'name' => 'questionRandom',\n\t\t\t\t\t'name_wrap' => $field_name_wrap,\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'label' => esc_html__( 'Display question randomly', 'learndash' ),\n\t\t\t\t\t'help_text' => esc_html__( 'Display question randomly in the Frontend.', 'learndash' ),\n\t\t\t\t\t'value' => $this->pro_quiz_edit->isQuestionRandom() ? true : '',\n\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t'1' => esc_html__( 'Activate', 'learndash' ),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'answerRandom' => array(\n\t\t\t\t\t'name' => 'answerRandom',\n\t\t\t\t\t'name_wrap' => $field_name_wrap,\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'label' => esc_html__( 'Display answers randomly', 'learndash' ),\n\t\t\t\t\t'help_text' => esc_html__( 'Display answers randomly in the Frontend.', 'learndash' ),\n\t\t\t\t\t'value' => $this->pro_quiz_edit->isAnswerRandom() ? true : '',\n\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t'1' => esc_html__( 'Activate', 'learndash' ),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'answerRandom' => array(\n\t\t\t\t\t'name' => 'answerRandom',\n\t\t\t\t\t'name_wrap' => $field_name_wrap,\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'label' => esc_html__( 'Sort questions by category', 'learndash' ),\n\t\t\t\t\t'help_text' => esc_html__( 'Also works in conjunction with the \"display randomly question\" option.', 'learndash' ),\n\t\t\t\t\t'value' => $this->pro_quiz_edit->isSortCategories() ? true : '',\n\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t'1' => esc_html__( 'Activate', 'learndash' ),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'timeLimit' => array(\n\t\t\t\t\t'name' => 'timeLimit',\n\t\t\t\t\t'type' => 'number',\n\t\t\t\t\t'label' => esc_html__( 'Time limit', 'learndash' ),\n\t\t\t\t\t'input_label' => esc_html__( 'Seconds', 'learndash' ),\n\t\t\t\t\t'help_text' => esc_html__( '0 = no limit', 'learndash' ),\n\t\t\t\t\t'value' => $this->pro_quiz_edit->getTimeLimit(),\n\t\t\t\t\t'class' => 'small-text',\n\t\t\t\t\t'attrs' => array(\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'timeLimit' => array(\n\t\t\t\t\t'name' => 'timeLimit',\n\t\t\t\t\t'type' => 'number',\n\t\t\t\t\t'label' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: Quiz.\n\t\t\t\t\t\tesc_html_x( 'Use cookies for %s Answers', 'placeholder: Quiz', 'learndash' ),\n\t\t\t\t\t\tLearnDash_Custom_Label::get_label( 'quiz' )\n\t\t\t\t\t),\n\t\t\t\t\t'input_label' => esc_html__( 'Seconds', 'learndash' ),\n\t\t\t\t\t'help_text' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: Quiz.\n\t\t\t\t\t\tesc_html_x( \"0 = Don't save answers. This option will save the user's answers into a browser cookie until the %s is submitted.\", 'placeholders: Quiz', 'learndash' ),\n\t\t\t\t\t\tLearnDash_Custom_Label::get_label( 'quiz' )\n\t\t\t\t\t),\n\t\t\t\t\t'value' => $this->pro_quiz_edit->getTimeLimitCookie(),\n\t\t\t\t\t'class' => 'small-text',\n\t\t\t\t\t'attrs' => array(\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'statisticsOn' => array(\n\t\t\t\t\t'name' => 'statisticsOn',\n\t\t\t\t\t'name_wrap' => $field_name_wrap,\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'label' => esc_html__( 'Statistics', 'learndash' ),\n\t\t\t\t\t'help_text' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: Quiz.\n\t\t\t\t\t\tesc_html_x( 'Statistics about right or wrong answers. Statistics will be saved by completed %s, not after every question. The statistics is only visible over administration menu. (internal statistics)', 'placeholders: quiz', 'learndash' ),\n\t\t\t\t\t\tLearnDash_Custom_Label::label_to_lower( 'quiz' )\n\t\t\t\t\t),\n\t\t\t\t\t'value' => $this->pro_quiz_edit->isStatisticsOn() ? true : '',\n\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t'1' => esc_html__( 'Activate', 'learndash' ),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'statisticsIpLock' => array(\n\t\t\t\t\t'name' => 'timeLimitstatisticsIpLock',\n\t\t\t\t\t'type' => 'number',\n\t\t\t\t\t'label' => esc_html__( 'Statistics IP-lock', 'learndash' ),\n\t\t\t\t\t'input_label' => esc_html__( 'in minutes (recommended 1440 minutes = 1 day)', 'learndash' ),\n\t\t\t\t\t'help_text' => esc_html__( 'Protect the statistics from spam. Result will only be saved every X minutes from same IP. (0 = deactivated)', 'learndash' ),\n\t\t\t\t\t'value' => $this->pro_quiz_edit->getStatisticsIpLock(),\n\t\t\t\t\t'class' => 'small-text',\n\t\t\t\t\t'attrs' => array(\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t),\n\t\t\t\t),\n\n\t\t\t);\n\n\t\t\t$this->setting_option_fields = apply_filters( 'learndash_settings_fields', $this->setting_option_fields, $this->settings_metabox_key );\n\n\t\t\tparent::load_settings_fields();\n\t\t}", "title": "" }, { "docid": "4c77452008bd4e66596ae1d685fb4367", "score": "0.5761121", "text": "function system_theme_settings($form, &$form_state, $key = '') {\n // Default settings are defined in theme_get_setting() in includes/theme.inc\n if ($key) {\n $var = 'theme_' . $key . '_settings';\n $themes = list_themes();\n $features = $themes[$key]->info['features'];\n }\n else {\n $var = 'theme_settings';\n }\n\n $form['var'] = array('#type' => 'hidden', '#value' => $var);\n\n // Toggle settings\n $toggles = array(\n 'logo' => t('Logo'),\n 'name' => t('Site name'),\n 'slogan' => t('Site slogan'),\n 'node_user_picture' => t('User pictures in posts'),\n 'comment_user_picture' => t('User pictures in comments'),\n 'comment_user_verification' => t('User verification status in comments'),\n 'favicon' => t('Shortcut icon'),\n 'main_menu' => t('Main menu'),\n 'secondary_menu' => t('Secondary menu'),\n );\n\n // Some features are not always available\n $disabled = array();\n if (!variable_get('user_pictures', 0)) {\n $disabled['toggle_node_user_picture'] = TRUE;\n $disabled['toggle_comment_user_picture'] = TRUE;\n }\n if (!module_exists('comment')) {\n $disabled['toggle_comment_user_picture'] = TRUE;\n $disabled['toggle_comment_user_verification'] = TRUE;\n }\n\n $form['theme_settings'] = array(\n '#type' => 'fieldset',\n '#title' => t('Toggle display'),\n '#description' => t('Enable or disable the display of certain page elements.'),\n );\n foreach ($toggles as $name => $title) {\n if ((!$key) || in_array($name, $features)) {\n $form['theme_settings']['toggle_' . $name] = array('#type' => 'checkbox', '#title' => $title, '#default_value' => theme_get_setting('toggle_' . $name, $key));\n // Disable checkboxes for features not supported in the current configuration.\n if (isset($disabled['toggle_' . $name])) {\n $form['theme_settings']['toggle_' . $name]['#disabled'] = TRUE;\n }\n }\n }\n\n if (!element_children($form['theme_settings'])) {\n // If there is no element in the theme settings fieldset then do not show\n // it -- but keep it in the form if another module wants to alter.\n $form['theme_settings']['#access'] = FALSE;\n }\n\n // Logo settings\n if ((!$key) || in_array('logo', $features)) {\n $form['logo'] = array(\n '#type' => 'fieldset',\n '#title' => t('Logo image settings'),\n '#description' => t('If toggled on, the following logo will be displayed.'),\n '#attributes' => array('class' => array('theme-settings-bottom')),\n );\n $form['logo']['default_logo'] = array(\n '#type' => 'checkbox',\n '#title' => t('Use the default logo'),\n '#default_value' => theme_get_setting('default_logo', $key),\n '#tree' => FALSE,\n '#description' => t('Check here if you want the theme to use the logo supplied with it.')\n );\n $form['logo']['settings'] = array(\n '#type' => 'container',\n '#states' => array(\n // Hide the logo settings when using the default logo.\n 'invisible' => array(\n 'input[name=\"default_logo\"]' => array('checked' => TRUE),\n ),\n ),\n );\n $form['logo']['settings']['logo_path'] = array(\n '#type' => 'textfield',\n '#title' => t('Path to custom logo'),\n '#description' => t('The path to the file you would like to use as your logo file instead of the default logo.'),\n '#default_value' => theme_get_setting('logo_path', $key),\n );\n $form['logo']['settings']['logo_upload'] = array(\n '#type' => 'file',\n '#title' => t('Upload logo image'),\n '#maxlength' => 40,\n '#description' => t(\"If you don't have direct file access to the server, use this field to upload your logo.\")\n );\n }\n\n if ((!$key) || in_array('favicon', $features)) {\n $form['favicon'] = array(\n '#type' => 'fieldset',\n '#title' => t('Shortcut icon settings'),\n '#description' => t(\"Your shortcut icon, or 'favicon', is displayed in the address bar and bookmarks of most browsers.\"),\n );\n $form['favicon']['default_favicon'] = array(\n '#type' => 'checkbox',\n '#title' => t('Use the default shortcut icon.'),\n '#default_value' => theme_get_setting('default_favicon', $key),\n '#description' => t('Check here if you want the theme to use the default shortcut icon.')\n );\n $form['favicon']['settings'] = array(\n '#type' => 'container',\n '#states' => array(\n // Hide the favicon settings when using the default favicon.\n 'invisible' => array(\n 'input[name=\"default_favicon\"]' => array('checked' => TRUE),\n ),\n ),\n );\n $form['favicon']['settings']['favicon_path'] = array(\n '#type' => 'textfield',\n '#title' => t('Path to custom icon'),\n '#description' => t('The path to the image file you would like to use as your custom shortcut icon.'),\n '#default_value' => theme_get_setting('favicon_path', $key),\n );\n $form['favicon']['settings']['favicon_upload'] = array(\n '#type' => 'file',\n '#title' => t('Upload icon image'),\n '#description' => t(\"If you don't have direct file access to the server, use this field to upload your shortcut icon.\")\n );\n }\n\n // Inject human-friendly values for logo and favicon.\n foreach (array('logo' => 'logo.png', 'favicon' => 'favicon.ico') as $type => $default) {\n if (isset($form[$type]['settings'][$type . '_path'])) {\n $element = &$form[$type]['settings'][$type . '_path'];\n\n // If path is a public:// URI, display the path relative to the files\n // directory; stream wrappers are not end-user friendly.\n $original_path = $element['#default_value'];\n $friendly_path = NULL;\n if (file_uri_scheme($original_path) == 'public') {\n $friendly_path = file_uri_target($original_path);\n $element['#default_value'] = $friendly_path;\n }\n }\n }\n\n if ($key) {\n // Call engine-specific settings.\n $function = $themes[$key]->prefix . '_engine_settings';\n if (function_exists($function)) {\n $form['engine_specific'] = array(\n '#type' => 'fieldset',\n '#title' => t('Theme-engine-specific settings'),\n '#description' => t('These settings only exist for the themes based on the %engine theme engine.', array('%engine' => $themes[$key]->prefix)),\n );\n $function($form, $form_state);\n }\n\n // Create a list which includes the current theme and all its base themes.\n if (isset($themes[$key]->base_themes)) {\n $theme_keys = array_keys($themes[$key]->base_themes);\n $theme_keys[] = $key;\n }\n else {\n $theme_keys = array($key);\n }\n\n // Save the name of the current theme (if any), so that we can temporarily\n // override the current theme and allow theme_get_setting() to work\n // without having to pass the theme name to it.\n $default_theme = !empty($GLOBALS['theme_key']) ? $GLOBALS['theme_key'] : NULL;\n $GLOBALS['theme_key'] = $key;\n\n // Process the theme and all its base themes.\n foreach ($theme_keys as $theme) {\n // Include the theme-settings.php file.\n $filename = DRUPAL_ROOT . '/' . str_replace(\"/$theme.info\", '', $themes[$theme]->filename) . '/theme-settings.php';\n if (file_exists($filename)) {\n require_once $filename;\n }\n\n // Call theme-specific settings.\n $function = $theme . '_form_system_theme_settings_alter';\n if (function_exists($function)) {\n $function($form, $form_state);\n }\n }\n\n // Restore the original current theme.\n if (isset($default_theme)) {\n $GLOBALS['theme_key'] = $default_theme;\n }\n else {\n unset($GLOBALS['theme_key']);\n }\n }\n\n $form = system_settings_form($form);\n // We don't want to call system_settings_form_submit(), so change #submit.\n array_pop($form['#submit']);\n $form['#submit'][] = 'system_theme_settings_submit';\n $form['#validate'][] = 'system_theme_settings_validate';\n return $form;\n}", "title": "" }, { "docid": "6c93f58fd4effad837a060f96f43293f", "score": "0.5753374", "text": "function swift_framework_topic_header_content_type_edit_form_submit($form, &$form_state) {\n foreach (array_keys($form_state['plugin']['defaults']) as $key) {\n $form_state['conf'][$key] = $form_state['values'][$key];\n }\n}", "title": "" }, { "docid": "3fe70a8cd15f52e32454b868ea92626c", "score": "0.5752835", "text": "function init_form_fields() {\n $this->form_fields = array(\n 'enabled' => array(\n 'title' => __( 'Habilita/Desabilita', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Habilita envio por Correios', 'woothemes' ),\n 'default' => 'yes'\n ),\n 'title' => array(\n 'title' => __( 'Título', 'woothemes' ),\n 'type' => 'text',\n 'description' => __( 'Título a ser exibido durante o checkout.', 'woothemes' ),\n 'default' => __( 'Correios', 'woothemes' )\n ),\n 'postalcode' => array(\n 'title' => __( 'CEP de Origem', 'woothemes' ),\n 'type' => 'text',\n 'description' => __( 'CEP onde se encontra o produto para calcular o frete.', 'woothemes' ),\n 'default' => __( '00000000', 'woothemes' )\n ),\n 'debug' => array(\n 'title' => __( 'Debug', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Habilita escrita de log <code>/woocommerce/logs/correios.log</code>.', 'woothemes' ),\n 'default' => 'yes'\n ),\n 'enable_shipping_box' => array(\n 'title' => __( 'Habilita o uso de caixa de envio?', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'O uso de caixas de envio permite o sistema calcular o volume do pedido e definir a melhor caixa do pacote para enviar para os correios, sendo mais asertivo nos valores de frete.', 'woothemes' ),\n 'default' => 'yes'\n ),\n 'caixa1' => array(\n 'title' => __( 'Dimensões da Caixa PP', 'woothemes' ),\n 'type' => 'text',\n 'description' => __( '[comprimento]x[largura]x[altura] (em cm). Importante para o cálculo da melhor caixa para o pedido.', 'woothemes' ),\n 'default' => __( '', 'woothemes' )\n ),\n 'caixa2' => array(\n 'title' => __( 'Dimensões da Caixa P', 'woothemes' ),\n 'type' => 'text',\n 'description' => __( '[comprimento]x[largura]x[altura] (em cm). Importante para o cálculo da melhor caixa para o pedido.', 'woothemes' ),\n 'default' => __( '', 'woothemes' )\n ),\n 'caixa3' => array(\n 'title' => __( 'Dimensões da Caixa M', 'woothemes' ),\n 'type' => 'text',\n 'description' => __( '[comprimento]x[largura]x[altura] (em cm). Importante para o cálculo da melhor caixa para o pedido.', 'woothemes' ),\n 'default' => __( '', 'woothemes' )\n ),\n 'caixa4' => array(\n 'title' => __( 'Dimensões da Caixa G', 'woothemes' ),\n 'type' => 'text',\n 'description' => __( '[comprimento]x[largura]x[altura] (em cm). Importante para o cálculo da melhor caixa para o pedido.', 'woothemes' ),\n 'default' => __( '', 'woothemes' )\n ),\n 'caixa5' => array(\n 'title' => __( 'Dimensões da Caixa GG', 'woothemes' ),\n 'type' => 'text',\n 'description' => __( '[comprimento]x[largura]x[altura] (em cm). Importante para o cálculo da melhor caixa para o pedido.', 'woothemes' ),\n 'default' => __( '', 'woothemes' )\n ),\n 'enable_pac' => array(\n 'title' => __( 'PAC', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Habilita envio por PAC.', 'woothemes' ),\n 'default' => 'yes'\n ),\n 'enable_sedex' => array(\n 'title' => __( 'SEDEX', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Habilita envio por SEDEX.', 'woothemes' ),\n 'default' => 'yes'\n ),\n 'enable_sedex_cobrar' => array(\n 'title' => __( 'SEDEX a Cobrar', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Habilita envio por SEDEX à cobrar (necessita declaração de valor).', 'woothemes' ),\n 'default' => 'no'\n ),\n 'enable_sedex10' => array(\n 'title' => __( 'SEDEX 10', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Habilita envio por SEDEX 10.', 'woothemes' ),\n 'default' => 'no'\n ),\n 'enable_sedex_hoje' => array(\n 'title' => __( 'SEDEX Hoje', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Habilita envio por SEDEX Hoje.', 'woothemes' ),\n 'default' => 'no'\n ),\n 'enable_esedex' => array(\n 'title' => __( 'e-Sedex', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Habilita envio por e-SEDEX (necessita contrato com correios).', 'woothemes' ),\n 'default' => 'no'\n ),\n 'valor_declarado' => array(\n 'title' => __( 'Declarar Valor?', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Utiliza a opção de valor declarado no pacote para os correios. Necessário para Sedex à cobrar.', 'woothemes' ),\n 'default' => 'no'\n ),\n 'mao_propria' => array(\n 'title' => __( 'Mão própria?', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Utiliza a opção de mão própria no pacote para os correios.', 'woothemes' ),\n 'default' => 'no'\n ),\n 'aviso_recebimento' => array(\n 'title' => __( 'Aviso de Recebimento?', 'woothemes' ),\n 'type' => 'checkbox',\n 'label' => __( 'Utiliza a opção de aviso de recebimento no pacote para os correios.', 'woothemes' ),\n 'default' => 'no'\n ),\n 'cod_empresa' => array(\n 'title' => __( 'Código Administrativo', 'woothemes' ),\n 'type' => 'text',\n 'description' => __( 'Código informado pelos correios ao firmar o contrato (necessário para e-SEDEX).', 'woothemes' ),\n 'default' => ''\n ),\n 'senha' => array(\n 'title' => __( 'Senha', 'woothemes' ),\n 'type' => 'text',\n 'description' => __( 'Senha de acesso do seu contrato nos correios (necessário para e-SEDEX).', 'woothemes' ),\n 'default' => ''\n )\n );\n }", "title": "" }, { "docid": "2c9a1109f582255a186a7ed56bec678e", "score": "0.5744289", "text": "function vm_video_manager_setting_form($form, &$form_state) {\n\n $form ['setting_form'] = array(\n '#type' => 'vertical_tabs',\n );\n // This is the field fieldset.\n $form['common'] = array(\n '#type' => 'fieldset',\n '#title' => t('Common Config'),\n '#collapsible' => TRUE,\n '#description' => t('Common Config.'),\n '#group' => 'setting_form'\n );\n\n // Adding a simple textarea.\n $form['common']['mailbody'] = array(\n '#type' => 'textarea',\n '#required' => TRUE,\n '#default_value' => 'Default',\n '#title' => t('Contact mail.'),\n '#description' => t('Body text when a new comment is posted by users.'),\n '#group' => 'setting_form'\n );\n $form['FE'] = array(\n '#type' => 'fieldset',\n '#title' => t('Config for view FE'),\n '#collapsible' => TRUE,\n '#description' => t('Config for view FE.'),\n '#group' => 'setting_form'\n );\n $form ['FE']['custom_class_for_view'] = array(\n '#type' => 'textfield',\n '#title' => t('Custom Class For View'),\n '#default_value' => variable_get('custom_class_for_view', 'col-md-12'),\n '#group' => 'setting_form'\n );\n $form ['FE']['allow_user_font_awesome'] = array(\n '#type' => 'checkbox',\n '#title' => t('Allow User Font Awesome'),\n '#default_value' => variable_get('allow_user_font_awesome', 1),\n '#group' => 'setting_form'\n );\n $form ['FE']['allow_user_bootstrap'] = array(\n '#type' => 'checkbox',\n '#title' => t('Allow User Bootstrap'),\n '#default_value' => variable_get('allow_user_bootstrap', 1),\n '#group' => 'setting_form'\n );\n $form ['FE']['path_of_file_custom_css'] = array(\n '#type' => 'textarea',\n '#title' => t('Path of file custom CSS'),\n '#default_value' => variable_get('path_of_file_custom_css', ''),\n '#description' => t('File Custom CSS Must be inside module video_manager, suggest put in to /video_manager/assets/css/[your_file], enter if have more than one file css'),\n '#group' => 'setting_form'\n );\n $form ['FE']['path_of_file_custom_js'] = array(\n '#type' => 'textfield',\n '#title' => t('Path of file custom JS'),\n '#default_value' => variable_get('path_of_file_custom_js', ''),\n '#description' => t('File Custom Js Must be inside module video_manager, suggest put in to /video_manager/assets/js/[your_file]'),\n '#group' => 'setting_form'\n );\n\n\n $form = system_settings_form($form);\n return $form;\n}", "title": "" }, { "docid": "fa18eefdb1bd598c5e0f92ca350a2227", "score": "0.57434624", "text": "function uultra_reload_custom_fields_set ()\r\n\t{\r\n\r\n\t\tglobal $xoouserultra;\r\n\r\n\t\t$custom_form = $_POST[\"uultra_custom_form\"];\r\n\r\n\t\tif($custom_form!=\"\") //use a custom form\r\n\t\t{\r\n\t\t\t//check if fields have been added\r\n\t\t\t$custom_form = 'usersultra_profile_fields_'.$custom_form;\r\n\r\n\t\t\tif (!get_option($custom_form)) //we need to create a default field set for this form\r\n\t\t\t{\r\n\r\n\t\t\t\t$this->xoousers_create_standard_form_fields($custom_form);\r\n\t\t\t\t$fields = get_option($custom_form);\r\n\r\n\t\t\t}else{\r\n\r\n\t\t\t\t//fields have been added to the custom form.\r\n\t\t\t\t$fields = get_option($custom_form);\r\n\r\n\r\n\t\t\t}\r\n\r\n\r\n\t\t}else{ //use the default registration from\r\n\r\n\t\t\t$fields = get_option('usersultra_profile_fields');\r\n\r\n\r\n\t\t}\r\n\r\n\t\tksort($fields);\r\n\r\n\t\t$i = 0;\r\n\t\tforeach($fields as $pos => $array)\r\n\t\t{\r\n\t\t extract($array); $i++;\r\n\r\n\t\t if(!isset($required))\r\n\t\t $required = 0;\r\n\r\n\t\t if(!isset($fonticon))\r\n\t\t $fonticon = '';\r\n\r\n\r\n\t\t\tif ($type == 'seperator' || $type == 'separator') {\r\n\r\n\t\t\t\t$class = \"separator\";\r\n\t\t\t\t$class_title = \"\";\r\n\t\t\t} else {\r\n\r\n\t\t\t\t$class = \"profile-field\";\r\n\t\t\t\t$class_title = \"profile-field\";\r\n\t\t\t}\r\n\t\t ?>\r\n\r\n <li class=\"uultra-profile-fields-row <?php echo $class_title?>\" id=\"<?php echo $pos; ?>\">\r\n\r\n\r\n <div class=\"heading_title <?php echo $class?>\">\r\n\r\n <h3>\r\n <?php\r\n\r\n\t\t\tif (isset($array['name']) && $array['name'])\r\n\t\t\t{\r\n\t\t\t echo $array['name'];\r\n\t\t\t}\r\n\t\t\t?>\r\n\r\n <?php\r\n\t\t\tif ($type == 'separator') {\r\n\r\n\t\t\t echo __(' - Separator','xoousers');\r\n\r\n\t\t\t} else {\r\n\r\n\t\t\t echo __(' - Profile Field','xoousers');\r\n\r\n\t\t\t}\r\n\t\t\t?>\r\n\r\n </h3>\r\n\r\n\r\n <div class=\"options-bar\">\r\n\r\n <p>\r\n <input type=\"submit\" name=\"submit\" value=\"<?php _e('Edit','xoousers'); ?>\"\t\t\t\t\t\tclass=\"button uultra-btn-edit-field button-primary\" data-edition=\"<?php echo $pos; ?>\" /> <input type=\"button\" value=\"<?php _e('Delete','xoousers'); ?>\"\tdata-field=\"<?php echo $pos; ?>\" class=\"button button-secondary uultra-delete-profile-field-btn\" />\r\n </p>\r\n\r\n </div>\r\n\r\n\r\n\r\n\r\n </div>\r\n\r\n\r\n <div class=\"user-ultra-success uultra-notification\" id=\"uultra-sucess-delete-fields-<?php echo $pos; ?>\"><?php _e('Success! This field has been deleted ','xoousers'); ?></div>\r\n\r\n\r\n\r\n <!-- edit field -->\r\n\r\n <div class=\"user-ultra-sect-second uultra-fields-edition user-ultra-rounded\" id=\"uu-edit-fields-bock-<?php echo $pos; ?>\">\r\n\r\n </div>\r\n\r\n\r\n <!-- edit field end -->\r\n\r\n </li>\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\t<?php\r\n\r\n\t}\r\n\r\n\t\tdie();\r\n\r\n\r\n\t}", "title": "" }, { "docid": "3412bba432d326e3ae9979a6112480a5", "score": "0.57412726", "text": "function classy_theme_settings_page() {\nglobal $enable_disable, $disable_enable, $theme_skins, $backgrounds, $slider_types, $slider_effects, $hp_highlights_columns, $hp_blog_columns, $portfolio_columns, $hp_services_columns, $services_columns, $footer_columns, $body_font_sizes, $fonts, $post_orderby, $post_order;\n\nif ( ! isset( $_REQUEST['updated'] ) )\n$_REQUEST['updated'] = false;\n\n?>\n<div class=\"wrap\">\n\n<?php\n// If the form has just been submitted, this shows the notification\nif ( $_GET['settings-updated'] ) { ?>\n<div id=\"message\" class=\"updated fade classy-message\"><p><?php _e('Options Saved','classy'); ?></p></div>\n<?php } ?>\n\n<h2 class=\"dummy-heading\"></h2>\n\n<div id=\"options-header\">\n\t<h2><?php _e( 'Theme Settings','classy'); ?><div id=\"icon-options-general\" class=\"icon32\"></div></h2>\n</div>\n<!-- END header -->\n\n<div id=\"panel-content\">\n<form method=\"post\" action=\"options.php\">\n\n<?php\nsettings_fields( 'classy_settings' );\n$options = get_option( 'classy_theme_settings' );\n?>\n\n\n<div id=\"wrap-left\">\n <ul class=\"tabs\">\n <li><a href=\"#tab1\"><?php _e('General Settings','classy'); ?></a></li>\n <li><a href=\"#tab2\"><?php _e('Styling','classy'); ?></a></li>\n <li><a href=\"#tab3\"><?php _e('Fonts','classy'); ?></a></li>\n <li><a href=\"#tab4\"><?php _e('Homepage','classy'); ?></a></li>\n <li><a href=\"#tab5\"><?php _e('Homepage Slider','classy'); ?></a></li>\n <li><a href=\"#tab6\"><?php _e('Portfolio','classy'); ?></a></li>\n <li><a href=\"#tab7\"><?php _e('Services','classy'); ?></a></li>\n <li><a href=\"#tab8\"><?php _e('Staff','classy'); ?></a></li>\n <li><a href=\"#tab9\"><?php _e('Blog','classy'); ?></a></li>\n <li><a href=\"#tab10\"><?php _e('Footer','classy'); ?></a></li>\n <li><a href=\"#tab11\"><?php _e('CSS','classy'); ?></a></li>\n </ul>\n</div><!-- END wrap-left -->\n\n\n<div id=\"wrap-right\">\n<div class=\"tab_container\">\n\n\n<!-- General Settings -->\n<div id=\"tab1\" class=\"tab_content\">\n<ul>\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e('Site Logo','classy'); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[upload_mainlogo]\" class=\"regular-text upload_field\" type=\"text\" size=\"36\" name=\"classy_theme_settings[upload_mainlogo]\" value=\"<?php esc_attr_e( $options['upload_mainlogo'] ); ?>\" />\n<input class=\"upload_image_button button-secondary\" type=\"button\" value=\"Choose Image\" />\n\n<?php if($options['upload_mainlogo']) { ?>\n<br /><br />\n<img src=\"<?php echo $options['upload_mainlogo']; ?>\" alt=\"logo\" width=\"220\" class=\"ta_image_preview\" />\n<?php } ?>\n\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[upload_mainlogo]\"><?php _e( 'Upload an image, choose an image from your media libray (make sure to hit \"insert to post\") or type in the URL for the main logo. This is the main logo for your website','classy'); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Enable/Disable Full-Width Logo', 'classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[enable_full_logo]\">\n<?php foreach ($disable_enable as $option) { ?>\n<option <?php if ($options['enable_full_logo'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[enable_full_logo]\"><?php _e( 'Enable this option to show your image across the whole header. This means you can add a logo without any top, left, right or bottom margin.' ,'classy' ); ?></label>\t\n</div><!-- End one_half -->\n\t\t\t\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Favicon' ,'classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[upload_favicon]\" class=\"regular-text upload_field\" type=\"text\" size=\"36\" name=\"classy_theme_settings[upload_favicon]\" value=\"<?php esc_attr_e( $options['upload_favicon'] ); ?>\" />\n\n<?php if($options['upload_favicon']) { ?>\n<br /><br />\n<img src=\"<?php echo $options['upload_favicon']; ?>\" alt=\"favicon\" class=\"ta_favicon_preview\" />\n<?php } ?>\n\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description abouttxtdescription\" for=\"classy_theme_settings[upload_favicon]\"><?php _e( 'Type in the URL for the site favicon.' ,'classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Analytics Code', 'classy' ); ?></h3>\n\n<div class=\"one_half\">\n<textarea id=\"classy_theme_settings[analytics]\" class=\"regular-text\" name=\"classy_theme_settings[analytics]\" rows=\"5\"><?php esc_attr_e( $options['analytics'] ); ?></textarea>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[analytics]\"><?php _e( 'Enter your analytics tracking code. This code is added to your header tag.' ,'classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\">\n\n<h3><?php _e( 'Enable/Disable Search Bar', 'classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_search]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_search'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[phone]\"><?php _e( 'Select to enable or disable the search bar in the theme header.' ,'classy' ); ?></label>\n\n</div><!-- End one_half -->\n\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Header Phone Number' ,'classy' ); ?></h3>\n\n<div class=\"one_half\">\n<textarea id=\"classy_theme_settings[phone]\" class=\"regular-text\" name=\"classy_theme_settings[phone]\" rows=\"5\"><?php esc_attr_e( $options['phone'] ); ?></textarea>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[phone]\"><?php _e( 'Enter a phone number for your header region above the search bar. Leave blank to disable.<br />HTML is allowed.' ,'classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n</ul>\n</div>\n<!--end main tab-->\n\n\n\n<!-- Styling -->\n<div id=\"tab2\" class=\"tab_content\">\n<ul>\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Color Skin','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[theme_skin]\">\n<?php foreach ($theme_skins as $option) { ?>\n<option <?php if ($options['theme_skin'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\t\n</div><!-- End one_half -->\t\t\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[theme_skin]\"><?php _e( 'Choose your color skin. Default is white/gray.','classy' ); ?></label>\t\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Enable/Disable Custom Color Options','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_custom_colors]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_custom_colors'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_custom_colors]\"><?php _e( 'Disable this option if you arent using the custom color options below to keep your header clean.','classy' ); ?></label>\t\n</div><!-- End one_half -->\n\t\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Background Image','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[body_background]\">\n<?php foreach ($backgrounds as $option) { ?>\n<option <?php if ($options['body_background'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\t\t\t\t\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[body_background]\"><?php _e( 'Choose a body background image from the built-in patterns. To upload your own background set this option to \"none\" then go to Apperance --> Backgrounds in your editor.','classy' ); ?></label>\t\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Background Color','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<script type=\"text/javascript\">\njQuery(document).ready(function($) { \n $('.cp_background_color').ColorPicker({\n\tonSubmit: function(hsb, hex, rgb) {\n\t\t$('.cp_background_color').val('#'+hex);\n\t},\n\tonBeforeShow: function () {\n\t\t$(this).ColorPickerSetColor(this.value);\n\t\treturn false;\n\t},\n\tonChange: function (hsb, hex, rgb) {\n\t\t$('#cp_preview_background_color div').css({'backgroundColor':'#'+hex, 'backgroundImage': 'none', 'borderColor':'#'+hex});\n\t\t$('#cp_preview_background_color').prev('input').attr('value', '#'+hex);\n\t}\n })\t\n .bind('keyup', function(){\n\t$(this).ColorPickerSetColor(this.value);\n });\n});\n</script>\n<input id=\"classy_theme_settings[background_color]\" class=\"regular-text cp_background_color\" type=\"text\" name=\"classy_theme_settings[background_color]\" value=\"<?php esc_attr_e( $options['background_color'] ); ?>\"/>\n<div id=\"cp_preview_background_color\" class=\"color-preview\">\n\t<div style=\"background-color: <?php esc_attr_e( $options['background_color'] ); ?>;\"></div>\n</div>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[background_color]\"><?php _e( 'Choose a color for the site background.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Main Text Color','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<script type=\"text/javascript\">\njQuery(document).ready(function($) { \n $('.cp_content_text_color').ColorPicker({\n\tonSubmit: function(hsb, hex, rgb) {\n\t\t$('.cp_content_text_color').val('#'+hex);\n\t},\n\tonBeforeShow: function () {\n\t\t$(this).ColorPickerSetColor(this.value);\n\t\treturn false;\n\t},\n\tonChange: function (hsb, hex, rgb) {\n\t\t$('#cp_preview_content_text_color div').css({'backgroundColor':'#'+hex, 'backgroundImage': 'none', 'borderColor':'#'+hex});\n\t\t$('#cp_preview_content_text_color').prev('input').attr('value', '#'+hex);\n\t}\n })\t\n .bind('keyup', function(){\n\t$(this).ColorPickerSetColor(this.value);\n });\n});\n</script>\n<input id=\"classy_theme_settings[content_text_color]\" class=\"regular-text cp_content_text_color\" type=\"text\" name=\"classy_theme_settings[content_text_color]\" value=\"<?php esc_attr_e( $options['content_text_color'] ); ?>\"/>\n<div id=\"cp_preview_content_text_color\" class=\"color-preview\">\n\t\t<div style=\"background-color: <?php esc_attr_e( $options['content_text_color'] ); ?>;\"></div>\n</div>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[content_text_color]\"><?php _e( 'Choose a color for the main content text.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Headings Color: h1,h2,h3...','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<script type=\"text/javascript\">\njQuery(document).ready(function($) { \n $('.cp_headings_color').ColorPicker({\n\tonSubmit: function(hsb, hex, rgb) {\n\t\t$('.cp_headings_color').val('#'+hex);\n\t},\n\tonBeforeShow: function () {\n\t\t$(this).ColorPickerSetColor(this.value);\n\t\treturn false;\n\t},\n\tonChange: function (hsb, hex, rgb) {\n\t\t$('#cp_preview_headings_color div').css({'backgroundColor':'#'+hex, 'backgroundImage': 'none', 'borderColor':'#'+hex});\n\t\t$('#cp_preview_headings_color').prev('input').attr('value', '#'+hex);\n\t}\n })\t\n .bind('keyup', function(){\n\t$(this).ColorPickerSetColor(this.value);\n });\n});\n</script>\n<input id=\"classy_theme_settings[headings_color]\" class=\"regular-text cp_headings_color\" type=\"text\" name=\"classy_theme_settings[headings_color]\" value=\"<?php esc_attr_e( $options['headings_color'] ); ?>\"/>\n<div id=\"cp_preview_headings_color\" class=\"color-preview\">\n\t\t<div style=\"background-color: <?php esc_attr_e( $options['headings_color'] ); ?>;\"></div>\n</div>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[headings_color]\"><?php _e( 'Choose a color for your headings.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Link Color','classy' ); ?></h3>\n<div class=\"one_half\">\n<script type=\"text/javascript\">\njQuery(document).ready(function($) { \n $('.cp_link_color').ColorPicker({\n\tonSubmit: function(hsb, hex, rgb) {\n\t\t$('.cp_link_color').val('#'+hex);\n\t},\n\tonBeforeShow: function () {\n\t\t$(this).ColorPickerSetColor(this.value);\n\t\treturn false;\n\t},\n\tonChange: function (hsb, hex, rgb) {\n\t\t$('#cp_preview_link_color div').css({'backgroundColor':'#'+hex, 'backgroundImage': 'none', 'borderColor':'#'+hex});\n\t\t$('#cp_preview_link_color').prev('input').attr('value', '#'+hex);\n\t}\n })\t\n .bind('keyup', function(){\n\t$(this).ColorPickerSetColor(this.value);\n });\n});\n</script>\n<input id=\"classy_theme_settings[link_color]\" class=\"regular-text cp_link_color\" type=\"text\" name=\"classy_theme_settings[link_color]\" value=\"<?php esc_attr_e( $options['link_color'] ); ?>\"/>\n<div id=\"cp_preview_link_color\" class=\"color-preview\">\n\t\t<div style=\"background-color: <?php esc_attr_e( $options['link_color'] ); ?>;\"></div>\n</div>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[link_color]\"><?php _e( 'Choose a color for your main links.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Link Hover Color','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<script type=\"text/javascript\">\njQuery(document).ready(function($) { \n $('.cp_link_hover_color').ColorPicker({\n\tonSubmit: function(hsb, hex, rgb) {\n\t\t$('.cp_link_hover_color').val('#'+hex);\n\t},\n\tonBeforeShow: function () {\n\t\t$(this).ColorPickerSetColor(this.value);\n\t\treturn false;\n\t},\n\tonChange: function (hsb, hex, rgb) {\n\t\t$('#cp_preview_link_hover_color div').css({'backgroundColor':'#'+hex, 'backgroundImage': 'none', 'borderColor':'#'+hex});\n\t\t$('#cp_preview_link_hover_color').prev('input').attr('value', '#'+hex);\n\t}\n })\t\n .bind('keyup', function(){\n\t$(this).ColorPickerSetColor(this.value);\n });\n});\n</script>\n<input id=\"classy_theme_settings[link_hover_color]\" class=\"regular-text cp_link_hover_color\" type=\"text\" name=\"classy_theme_settings[link_hover_color]\" value=\"<?php esc_attr_e( $options['link_hover_color'] ); ?>\"/>\n<div id=\"cp_preview_link_hover_color\" class=\"color-preview\">\n\t\t<div style=\"background-color: <?php esc_attr_e( $options['link_hover_color'] ); ?>;\"></div>\n</div>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[link_hover_color]\"><?php _e( 'Choose a color for your main links.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n</ul>\n</div><!--end styling tab-->\n\n\n<!-- Fonts -->\n\n<div id=\"tab3\" class=\"tab_content\">\n<h2><?php _e('Font Options','classy') ;?></h2>\n<p class=\"ta_description\"><span><?php _e('This theme allows you to choose between some really great Web fonts provided by Google. If you want to see what these fonts look like please checkout the','classy') ;?> <a href=\"http://www.google.com/webfonts\"><?php _e('Google Web Fonts Directory','classy') ;?></a>. <br /><br /><strong><?php _e('Note:','classy') ;?></strong> <?php _e('Some fonts look better then others at different sizes. If the text looks bad, try changing the font-size. If you change the navigation font and it looks horrible, try removing the bold from the navigation in style.css under \".sf-menu a\"','classy') ;?></span></p>\n\n<ul>\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Body Font Size','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[body_font_sizes]\">\n<?php foreach ($body_font_sizes as $option) { ?>\n<option <?php if ($options['body_font_sizes'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\t\n</div><!-- End one_half -->\t\t\t\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[body_font_sizes]\"><?php _e( 'Select a font size for your main body text. Default is 12.','classy' ); ?></label>\t\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Body Font','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[body_font]\">\n<?php foreach ($fonts as $option) { ?>\n<option <?php if ($options['body_font'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\t\t\n</div><!-- End one_half -->\t\n\n<div class=\"one_half\">\t\n<label class=\"description\" for=\"classy_theme_settings[body_font]\"><?php _e( 'Choose your body font. I really like \"Open Sans\".','classy' ); ?></label>\t\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Headings Font','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[header_font]\">\n<?php foreach ($fonts as $option) { ?>\n<option <?php if ($options['header_font'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\t\n</div><!-- End one_half -->\t\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[header_font]\"><?php _e( 'Choose your headings font. I really like \"Open Sans\" and \"San Serif\".','classy' ); ?></label>\t\n</div><!-- End one_half -->\n\t\t\t\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Navigation Menu Font','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[nav_font]\">\n<?php foreach ($fonts as $option) { ?>\n<option <?php if ($options['nav_font'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\t\n<label class=\"description\" for=\"classy_theme_settings[nav_font]\"><?php _e( 'Choose your navigation bar font.','classy' ); ?></label>\t\t\n</div><!-- End one_half -->\n\t\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Phone Number Font','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[phone_font]\">\n<?php foreach ($fonts as $option) { ?>\n<option <?php if ($options['phone_font'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\t\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\t\t\n<label class=\"description\" for=\"classy_theme_settings[phone_font]\"><?php _e( 'Choose your phone number font.','classy' ); ?></label>\t\t\n</div><!-- End one_half -->\n\t\n</li>\n<!-- option block -->\n\n</ul>\n</div>\n\n<!-- Homepage -->\n\n<div id=\"tab4\" class=\"tab_content\">\n<ul>\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Blog Style Home','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\t\n<select name=\"classy_theme_settings[enable_blog_home]\">\n<?php foreach ($disable_enable as $option) { ?>\n<option <?php if ($options['enable_blog_home'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\t\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[enable_blog_home]\"><?php _e( 'Select to enable or disable the blog style homepage.','classy' ); ?></label>\t\n</div><!-- End one_half -->\n\t\t\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Homepage Highlights Columns','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[hp_highlights_column]\">\n<?php foreach ($hp_highlights_columns as $option) { ?>\n<option <?php if ($options['hp_highlights_column'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\t\t\t\t\t\n<label class=\"description\" for=\"classy_theme_settings[hp_highlights_column]\"><?php _e( 'Select how many columns you want for the homepage highlights.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Home Services','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_home_services]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_home_services'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_home_services]\"><?php _e( 'Select to enable or disable the services section on the homepage.','classy' ); ?></label>\n</div><!-- End one_half -->\n\t\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Services Title','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[home_services_title]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[home_services_title]\" value=\"<?php esc_attr_e( $options['home_services_title'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_services_title]\"><?php _e( 'Enter a custom title for the services homepage section.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Service Category Slug','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[service_home_slug]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[service_home_slug]\" value=\"<?php esc_attr_e( $options['service_home_slug'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[service_home_slug]\"><?php _e( 'Enter the slug of the service category you want for your homepage. This is used if you want just 1 category of services to show up on the home.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'How Many Services Columns?', 'classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[hp_services_columns]\">\n<?php foreach ($hp_services_columns as $option) { ?>\n<option <?php if ($options['hp_services_columns'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\t\t\t\t\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\t\n<label class=\"description\" for=\"classy_theme_settings[hp_services_columns]\"><?php _e( 'Select how many columns you want for the homepage services.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'How Many Services?','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[home_services_count]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[home_services_count]\" value=\"<?php esc_attr_e( $options['home_services_count'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_services_count]\"><?php _e( 'Select how many services you want to show on the homepage, based on published date - aka: your latest services.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Links On Services','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_hp_services_title_link]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_hp_services_title_link'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\t\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_hp_services_title_link]\"><?php _e( 'Select to enable or disable links on your homepage services titles.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n\t\t\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Portfolio Carousel','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_home_portfolio]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_home_portfolio'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_home_portfolio]\"><?php _e( 'Select to enable or disable the homepage portfolio carousel.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n\t\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Portfolio Carousel Title','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[home_portfolio_title]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[home_portfolio_title]\" value=\"<?php esc_attr_e( $options['home_portfolio_title'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_portfolio_title]\"><?php _e( 'Enter a custom title for the Recent Work homepage section.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Portfolio Item Count','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[home_portfolio_count]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[home_portfolio_count]\" value=\"<?php esc_attr_e( $options['home_portfolio_count'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_portfolio_count]\"><?php _e( 'Enter the ammount of posts you want to show for the homepage portfolio carousel.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Portfolio Carousel Auto Play','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[home_portfolio_auto_play]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['home_portfolio_auto_play'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_portfolio_count]\"><?php _e( 'Enter the ammount of posts you want to show for the homepage portfolio carousel.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Portfolio Carousel Delay Time','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[home_portfolio_slide_delay]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[home_portfolio_slide_delay]\" value=\"<?php esc_attr_e( $options['home_portfolio_slide_delay'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_portfolio_slide_delay]\"><?php _e( 'Enter a delay time in milliseconds for your homepage portfolio carousel. Default is 150.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Portfolio Carousel Scroll Speed','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[home_portfolio_slide_speed]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[home_portfolio_slide_speed]\" value=\"<?php esc_attr_e( $options['home_portfolio_slide_speed'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_portfolio_slide_speed]\"><?php _e( 'Enter a slide speed in milliseconds for your homepage portfolio carousel. Default is 500.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Latest Blog Posts','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_home_blog]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_home_blog'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_home_blog]\"><?php _e( 'Select to enable or disable the latest blog posts section on the homepage.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n\t\t\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Latest Blog Posts Title','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[home_blog_title]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[home_blog_title]\" value=\"<?php esc_attr_e( $options['home_blog_title'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_blog_title]\"><?php _e( 'Enter a custom title for the latest blog posts homepage section.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block --\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Recent Blog Posts Columns','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[hp_blog_column]\">\n<?php foreach ($hp_blog_columns as $option) { ?>\n<option <?php if ($options['hp_blog_column'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\t\t\t\n<label class=\"description\" for=\"classy_theme_settings[hp_blog_column]\"><?php _e( 'Select how many columns you want the homepage recent blog posts section.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'How Many Latest Blog Posts?','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[home_blog_count]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[home_blog_count]\" value=\"<?php esc_attr_e( $options['home_blog_count'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_blog_count]\"><?php _e( 'How many latest blog posts do you want to show on the homepage?','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Latest Blog Posts Excerpt Length','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[home_blog_excerpt]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[home_blog_excerpt]\" value=\"<?php esc_attr_e( $options['home_blog_excerpt'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_blog_excerpt]\"><?php _e( 'How many words do you want for the latest blog posts excerpt?','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n</ul>\n</div>\n<!-- end homepage -->\n\n\n<!-- Slider -->\n<div id=\"tab5\" class=\"tab_content\">\n<ul>\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Homepage Slider','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_home_slider]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_home_slider'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_home_slider]\"><?php _e( 'Select to enable your homepage slider.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Static Slider Alternative','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<textarea id=\"classy_theme_settings[home_static]\" class=\"regular-text\" name=\"classy_theme_settings[home_static]\" rows=\"8\"><?php esc_attr_e( $options['home_static'] ); ?></textarea>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[home_static]\"><?php _e( 'If you disabled the homepage slider you may want to add a static image or embeded video. Insert your HTML here. If the slider is not disabled it will show up right below the slider.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Homepage Slider Type','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[slider_type]\">\n<?php foreach ($slider_types as $option) { ?>\n<option <?php if ($options['slider_type'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\t\t\t\n<label class=\"description\" for=\"classy_theme_settings[slider_type]\"><?php _e( 'Select your slider style. Below are the options for each slider.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Content Slider - Slide Speed','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[slides_speed]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[slides_speed]\" value=\"<?php esc_attr_e( $options['slides_speed'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[slides_speed]\"><?php _e( 'Type in the time in milliseconds for your desired sliding animation speed. Default is 350.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Content Slider - Play Time','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[slides_play_time]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[slides_play_time]\" value=\"<?php esc_attr_e( $options['slides_play_time'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[slides_play_time]\"><?php _e( 'Type in the play time in milliseconds for your content slider. This is the transition speed. Default is 5000.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'NivoSlider - Transition','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[nivo_transition_effect]\">\n<?php foreach ($slider_effects as $option) { ?>\n<option <?php if ($options['nivo_transition_effect'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\t\n</div><!-- End one_half -->\t\t\t\t\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[nivo_transition_effect]\"><?php _e( 'Choose the type of transition you want your slider to have.Default is random.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'NivoSlider - Slices','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[nivo_slices]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[nivo_slices]\" value=\"<?php esc_attr_e( $options['nivo_slices'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[nivo_slices]\"><?php _e( 'Type in the amount of slices for the slider.Default is 15.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'NivoSlider - Box Columns','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[nivo_box_columns]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[nivo_box_columns]\" value=\"<?php esc_attr_e( $options['nivo_box_columns'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[nivo_box_columns]\"><?php _e( 'Type in the amount of box columns for the slider. Default is 4.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'NivoSlider - Box Rows','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[nivo_box_rows]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[nivo_box_rows]\" value=\"<?php esc_attr_e( $options['nivo_box_rows'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[nivo_box_rows]\"><?php _e( 'Type in the amount of box rows for the slider. Default is 4.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'NivoSlider - Animation Speed','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[nivo_animation_speed]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[nivo_animation_speed]\" value=\"<?php esc_attr_e( $options['nivo_animation_speed'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[nivo_animation_speed]\"><?php _e( 'Type in the speed for the slide transitions in milliseconds. Default is 500.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'NivoSlider - Pause Time','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[nivo_pause_time]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[nivo_pause_time]\" value=\"<?php esc_attr_e( $options['nivo_pause_time'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[nivo_pause_time]\"><?php _e( 'This is the time the image is displayed before it transits to the next, in milliseconds. Default is 3000.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'NivoSlider - Enable/Disable Slider Caption','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_caption]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_caption'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\t\t\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_caption]\"><?php _e( 'Enable or disable the slider caption. This is the bar underneath the image slider that shows the title.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n\t\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'NivoSlider - Enable/Disable Slider Arrow Navigation','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_nivo_buttons]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_nivo_buttons'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_nivo_buttons]\"><?php _e( 'Enable or disable the nivo image slider arrow navigation (next and previous arrows)','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'NivoSlider - Enable/Disable Slider Bullet Navigation','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_nivo_bullets]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_nivo_bullets'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_nivo_bullets]\"><?php _e( 'Enable or disable the nivo image slider bullet navigation.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n</ul>\n</div><!--end sldier tab-->\n\n\n\n<!-- Portfolio -->\n<div id=\"tab6\" class=\"tab_content\">\n<ul>\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Portfolio Page URL','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[portfolio_url]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[portfolio_url]\" value=\"<?php esc_attr_e( $options['portfolio_url'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[portfolio_url]\"><?php _e( 'Enter your portfolio page URL for use in the portfolio category navigation. This creates the all link','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Portfolio Template Columns','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[portfolio_columns]\">\n<?php foreach ($portfolio_columns as $option) { ?>\n<option <?php if ($options['portfolio_columns'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\t\t\n<label class=\"description\" for=\"classy_theme_settings[portfolio_columns]\"><?php _e( 'Select how many columns you want for the portfolio page template. Default is 4.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'How Many Portfolio Items Per Page','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[portfolio_post_count]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[portfolio_post_count]\" value=\"<?php esc_attr_e( $options['portfolio_post_count'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[portfolio_post_count]\"><?php _e( 'How many portfolio items do you want to show per page (used for portfolio pagination).','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Organize Portfolio Items By','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[portfolio_orderby]\">\n<?php foreach ($post_orderby as $option) { ?>\n<option <?php if ($options['portfolio_orderby'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[portfolio_orderby]\"><?php _e( 'Select if you want your portfolio template items organized by date or title.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Portfolio Category Navigation','classy' ); ?></h3>\n\n<div class=\"one_half\">\t\n<select name=\"classy_theme_settings[disable_portfolio_cats]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_portfolio_cats'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_portfolio_cats]\"><?php _e( 'Enable or disable your portfolio category navigation. These are the links at the top that go to the various portfolio categories.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Portfolio Page Titles','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_portfolio_titles]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_portfolio_titles'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_portfolio_titles]\"><?php _e( 'Enable or disable the portfolio titles on the main portfolio page.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Portfolio Descriptions','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_portfolio_description]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_portfolio_description'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_portfolio_description]\"><?php _e( 'Enable or disable the portfolio descriptions on the main portfolio template.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Related Projects Title','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[related_portfolio_title]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[related_portfolio_title]\" value=\"<?php esc_attr_e( $options['related_portfolio_title'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[related_portfolio_title]\"><?php _e( 'Enter a custom name for the \"related projects\" title.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Related Portfolio Items','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_related_portfolio]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_related_portfolio'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_related_portfolio]\"><?php _e( 'Enable or disable the related portfolio items on single portfolio posts.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'How Many Related Portfolio Items','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[related_portfolio_count]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[related_portfolio_count]\" value=\"<?php esc_attr_e( $options['related_portfolio_count'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[related_portfolio_count]\"><?php _e( 'How many related portfolio posts do you want to show in the single portfolio carousel. Default is 8.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n</ul>\n</div>\n\n\n<!-- Services -->\n<div id=\"tab7\" class=\"tab_content\">\n<ul>\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Main Service Page URL','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[service_url]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[service_url]\" value=\"<?php esc_attr_e( $options['service_url'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[portfolio_url]\"><?php _e( 'Enter your service page URL for use in the service category navigation. This creates the all link.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Services Category Navigation','classy' ); ?></h3>\n\n<div class=\"one_half\">\t\n<select name=\"classy_theme_settings[disable_services_cats]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_services_cats'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_services_cats]\"><?php _e( 'Enable or disable your services category navigation. These are the links at the top that go to the various services categories.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'How Many Columns For The Services Template','classy'); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[services_column]\">\n<?php foreach ($services_columns as $option) { ?>\n<option <?php if ($options['services_column'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\t\t\t\n<label class=\"description\" for=\"classy_theme_settings[services_column]\"><?php _e( 'Select how many columns you want for the services page template.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Links On Services Titles','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_services_title_link]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_services_title_link'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_services_title_link]\"><?php _e( 'Enable or disable the links on the services titles. Great if you do not want detailed service pages.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n</ul>\n</div>\n\n\n<!-- Staff -->\n<div id=\"tab8\" class=\"tab_content\">\n<ul>\n\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Staff Page URL','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[staff_url]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[staff_url]\" value=\"<?php esc_attr_e( $options['staff_url'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[staff_url]\"><?php _e( 'Enter your staff page template URL to create the \"all\" link in the staff page navigation.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Staff Category Navigation','classy' ); ?></h3>\n\n<div class=\"one_half\">\t\n<select name=\"classy_theme_settings[disable_staff_cats]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_staff_cats'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_staff_cats]\"><?php _e( 'Enable or disable your staff category navigation. These are the links at the top that go to the various staff categories on the main staff page.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n</ul>\n</div>\n\n\n<!-- Blog -->\n<div id=\"tab9\" class=\"tab_content\">\n<ul>\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Blog Excerpt Length','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<input id=\"classy_theme_settings[blog_excerpt_length]\" class=\"regular-text\" type=\"text\" name=\"classy_theme_settings[blog_excerpt_length]\" value=\"<?php esc_attr_e( $options['blog_excerpt_length'] ); ?>\" />\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[blog_excerpt_length]\"><?php _e( 'Enter your desidered blog excerpt length (# of words) for blog and archive pages. Default is 60 words.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Full Blog Posts Instead of Excerpts','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_excerpt]\">\n<?php foreach ($disable_enable as $option) { ?>\n<option <?php if ($options['disable_excerpt'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_excerpt]\"><?php _e( 'Enable or disable full blog posts instead of excerpts on the blog page and archive pages.','classy' ); ?></label>\n</div><!-- End one_half -->\n\t\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Thumbnails On Blog Entries','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_entry_thumbnail]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_entry_thumbnail'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_entry_thumbnail]\"><?php _e( 'Enable or disable automatic thumbnails on blog entries.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Thumbnails On Blog Posts','classy' ); ?></h3>\n\n<div class=\"one_half\">\t\n<select name=\"classy_theme_settings[disable_post_thumbnail]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_post_thumbnail'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_post_thumbnail]\"><?php _e( 'Enable or disable auto thumbnails on single blog posts.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable About The Author Sections','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_author]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_author'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_author]\"><?php _e( 'Enable or disable about the author sections on single blog posts.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Related Posts','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_related_posts]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_related_posts'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_related_posts]\"><?php _e( 'Enable or disable related posts on single blog posts.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n</ul>\n</div><!--end blog tab-->\n\n\n\n<!-- Footer -->\n\n<div id=\"tab10\" class=\"tab_content\">\n<ul>\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'Enable/Disable Widgetized Footer','classy' ); ?></h3>\t\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[disable_widgetized_footer]\">\n<?php foreach ($enable_disable as $option) { ?>\n<option <?php if ($options['disable_widgetized_footer'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[disable_widgetized_footer]\"><?php _e( 'Enable or disable the widgetized footer region.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n<!-- option block -->\n<li class=\"clearfix\"><h3><?php _e( 'How Many Columns For The Footer','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<select name=\"classy_theme_settings[footer_columns]\">\n<?php foreach ($footer_columns as $option) { ?>\n<option <?php if ($options['footer_columns'] == $option ){ echo 'selected=\"selected\"'; } ?>><?php echo htmlentities($option); ?></option>\n<?php } ?>\n</select>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\t\n<label class=\"description\" for=\"classy_theme_settings[footer_columns]\"><?php _e( 'Select how many columns do you want for your widgetized footer?','classy' ); ?></label>\n</div><!-- End one_half -->\n\n\n<!-- option block -->\n<li class=\"clearfix\">\n<h3><?php _e( 'Custom Copyright Notice','classy' ); ?></h3>\n\n<div class=\"one_half\">\n<textarea id=\"classy_theme_settings[copyright]\" class=\"regular-text\" name=\"classy_theme_settings[copyright]\" rows=\"7\"><?php esc_attr_e( $options['copyright'] ); ?></textarea>\n</div><!-- End one_half -->\n\n<div class=\"one_half\">\n<label class=\"description\" for=\"classy_theme_settings[copyright]\"><?php _e( 'Enter a custom copyright message for your footer area. HTML is allowed if you want links.','classy' ); ?></label>\n</div><!-- End one_half -->\n\n</li>\n<!-- option block -->\n\n</li>\n<!-- option block -->\n\n</ul>\n</div><!--end footer tab-->\n\n\n\n\n<!-- CSS -->\n\n<div id=\"tab11\" class=\"tab_content\">\n<ul>\n\n<!-- option block -->\n<li class=\"clearfix\" style=\"border-top: 0px;\">\n<h3><?php _e( 'Custom CSS Code','classy' ); ?></h3>\n<label class=\"description\" for=\"classy_theme_settings[custom_css]\"><?php _e( 'Enter your custom css here if you don not want to override the style.css file','classy' ); ?></label>\n<textarea id=\"classy_theme_settings[custom_css]\" class=\"regular-text\" name=\"classy_theme_settings[custom_css]\" rows=\"20\"><?php esc_attr_e( $options['custom_css'] ); ?></textarea>\n\n\n</li>\n<!-- option block -->\n\n</ul>\n</div><!--end css tab-->\n\n\n</div><!--end tab container-->\n</div><!-- END wrap-right -->\n<div class=\"clear\"></div>\n\n<p class=\"submit-changes\">\n<input type=\"submit\" class=\"button-primary\" value=\"<?php _e( 'Save Options', 'classy' ); ?>\" />\n</p>\n</form>\n</div><!-- END panel-content -->\n</div><!-- END wrap -->\n<?php\n}", "title": "" }, { "docid": "759ca4768d3250654c9540bb52d4d1e2", "score": "0.5738745", "text": "public function removeMetaBoxes()\n {\n if (function_exists('get_field')) {\n if (get_field('event_update_button', 'option') == false) {\n remove_meta_box('submitdiv', $this->post_type, 'side');\n }\n }\n remove_meta_box('acf-group_56c33cf1470dc', $this->post_type, 'side');\n remove_meta_box('pageparentdiv', $this->post_type, 'side');\n }", "title": "" }, { "docid": "62b86473bb3ae63ff1ff868556cd4ba9", "score": "0.5730867", "text": "function admin_page()\n\t{\n\t\tglobal $wp_taxonomies;\n\t\t$this->security();\n\t\t$this->version_check(get_option($this->unique_prefix . '_version'));\n\t\t?>\n\t\t<div class=\"wrap\"><h2><?php _e('Relatively Perfect Settings', 'bt_magic'); ?></h2>\t\t\n\t\t<p<?php if($this->_has_contextual_help): ?> class=\"hide-if-js\"<?php endif; ?>><?php \n\t\t\tprint $this->_get_help_text();\t\t\t \n\t\t?></p>\n\t\t<form action=\"options-general.php?page=bt_magic\" method=\"post\" id=\"<?php echo $this->unique_prefix;?>-options\">\n\t\t\t<?php settings_fields($this->unique_prefix . '_options');?>\n\t\t\t<div id=\"hasadmintabs\">\n\t\t\t<fieldset id=\"general\" class=\"<?php echo $this->unique_prefix;?>_options\">\n\t\t\t\t<h3><?php _e('General', 'bt_magic'); ?></h3>\n\t\t\t\t<table class=\"form-table\">\n\t\t\t\t\t<?php\n\t\t\t\t\t\tfor($i = 0; $i < 8; $i++)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->input_text(sprintf(__('Title %s', 'bt_magic'), $i), 'stitle_'.$i, '32', false, sprintf(__('Title for button %s', 'bt_magic'), $i));\n\t\t\t\t\t\t\t$this->input_text(sprintf(__('Image URL %s', 'bt_magic'), $i), 'simg_url_'.$i, '32', false, sprintf(__('Image for button %s', 'bt_magic'), $i));\n\t\t\t\t\t\t\t$this->input_text(sprintf(__('Link URL %s', 'bt_magic'), $i), 'slink_url_'.$i, '32', false, sprintf(__('Destination URL for button %s', 'bt_magic'), $i));\n\t\t\t\t\t\t}\n\t\t\t\t\t?>\n\t\t\t\t</table>\n\t\t\t</fieldset>\n\t\t\t<fieldset id=\"message\" class=\"<?php echo $this->unique_prefix;?>_options\">\n\t\t\t\t<h3><?php _e('Message', 'bt_magic'); ?></h3>\n\t\t\t\t<table class=\"form-table\">\n\t\t\t\t\t<?php\n\t\t\t\t\t\t$this->input_check(__('Show Message', 'bt_magic'), 'bshow_message', __('Show message to the users', 'bt_magic'));\n\t\t\t\t\t\t$this->textbox(__('Message', 'bt_magic'), 'hmessage', '3', false, __('Message to display on the user landing page.', 'bt_magic'));\n\t\t\t\t\t?>\n\t\t\t\t</table>\n\t\t\t</fieldset>\n\t\t\t</div>\n\t\t\t<p class=\"submit\"><input type=\"submit\" class=\"button-primary\" name=\"<?php echo $this->unique_prefix;?>_admin_options\" value=\"<?php esc_attr_e('Save Changes') ?>\" /></p>\n\t\t</form>\n\t\t<?php $this->import_form(); ?>\n\t\t</div>\n\t\t<?php\n\t}", "title": "" }, { "docid": "3193ebb3d84ffefc887aff78b887e35e", "score": "0.57253265", "text": "function nik__theme_settings_validate(&$form, FormStateInterface &$form_state) {\n\n}", "title": "" }, { "docid": "870d1a649c0662eebde85ccc09e1e5aa", "score": "0.5724483", "text": "function giftgrid_options_page() {\n?>\n<div>\n<h2>Gift Grid options</h2>\n<form action=\"options.php\" method=\"POST\">\n<?php settings_fields('gg_plugin_options');\ndo_settings_sections('giftgrid');?>\n<input name=\"Submit\" type=\"submit\" value=\"<?php esc_attr_e('Save Changes'); ?>\" />\n</form></div>\n \n<?php\n}", "title": "" }, { "docid": "a1b893f486d0b2a1b9faa384e9011521", "score": "0.57213986", "text": "function views_ui_admin_settings_basic() {\n $form = array();\n $form['#attached']['css'] = views_ui_get_admin_css();\n\n $options = array();\n foreach (list_themes() as $name => $theme) {\n if ($theme->status) {\n $options[$name] = $theme->info['name'];\n }\n }\n\n // This is not currently a fieldset but we may want it to be later,\n // so this will make it easier to change if we do.\n $form['basic'] = array();\n\n $form['basic']['views_ui_show_listing_filters'] = array(\n '#type' => 'checkbox',\n '#title' => t('Show filters on the list of views'),\n '#default_value' => variable_get('views_ui_show_listing_filters', FALSE),\n );\n $form['basic']['views_ui_show_advanced_help_warning'] = array(\n '#type' => 'checkbox',\n '#title' => t('Show advanced help warning'),\n '#default_value' => variable_get('views_ui_show_advanced_help_warning', TRUE),\n );\n\n $form['basic']['views_ui_show_master_display'] = array(\n '#type' => 'checkbox',\n '#title' => t('Always show the master display'),\n '#description' => t('Advanced users of views may choose to see the master (i.e. default) display.'),\n '#default_value' => variable_get('views_ui_show_master_display', FALSE),\n );\n\n $form['basic']['views_ui_show_advanced_column'] = array(\n '#type' => 'checkbox',\n '#title' => t('Always show advanced display settings'),\n '#description' => t('Default to showing advanced display settings, such as relationships and contextual filters.'),\n '#default_value' => variable_get('views_ui_show_advanced_column', FALSE),\n );\n\n $form['basic']['views_ui_display_embed'] = array(\n '#type' => 'checkbox',\n '#title' => t('Show the embed display in the ui.'),\n '#description' => t('Allow advanced user to use the embed view display. The plugin itself works if it\\'s not visible in the ui'),\n '#default_value' => variable_get('views_ui_display_embed', FALSE),\n );\n\n $form['basic']['views_ui_custom_theme'] = array(\n '#type' => 'select',\n '#title' => t('Custom admin theme for the Views UI'),\n '#options' => array('_default' => t('- Use default -')) + $options,\n '#default_value' => variable_get('views_ui_custom_theme', '_default'),\n '#description' => t('In some cases you might want to select a different admin theme for the Views UI.')\n );\n\n $form['basic']['views_exposed_filter_any_label'] = array(\n '#type' => 'select',\n '#title' => t('Label for \"Any\" value on non-required single-select exposed filters'),\n '#options' => array('old_any' => '<Any>', 'new_any' => t('- Any -')),\n '#default_value' => variable_get('views_exposed_filter_any_label', 'new_any'),\n );\n\n $form['live_preview'] = array(\n '#type' => 'fieldset',\n '#title' => t('Live preview settings'),\n );\n\n $form['live_preview']['views_ui_always_live_preview'] = array(\n '#type' => 'checkbox',\n '#title' => t('Automatically update preview on changes'),\n '#default_value' => variable_get('views_ui_always_live_preview', TRUE),\n );\n\n// $form['live_preview']['views_ui_always_live_preview_button'] = array(\n// '#type' => 'checkbox',\n// '#title' => t('Always show the preview button, even when the automatically update option is checked'),\n// '#default_value' => variable_get('views_ui_always_live_preview_button', FALSE),\n// );\n\n $form['live_preview']['views_ui_show_preview_information'] = array(\n '#type' => 'checkbox',\n '#title' => t('Show information and statistics about the view during live preview'),\n '#default_value' => variable_get('views_ui_show_preview_information', TRUE),\n );\n\n $form['live_preview']['views_ui_show_sql_query_where'] = array(\n '#type' => 'radios',\n '#options' => array(\n 'above' => t('Above the preview'),\n 'below' => t('Below the preview'),\n ),\n '#id' => 'edit-show-sql',\n '#default_value' => variable_get('views_ui_show_sql_query_where', 'above'),\n '#dependency' => array('edit-views-ui-show-preview-information' => array(TRUE)),\n '#prefix' => '<div id=\"edit-show-sql-wrapper\" class=\"views-dependent\">',\n '#suffix' => '</div>',\n );\n\n $form['live_preview']['views_ui_show_sql_query'] = array(\n '#type' => 'checkbox',\n '#title' => t('Show the SQL query'),\n '#default_value' => variable_get('views_ui_show_sql_query', FALSE),\n '#dependency' => array('edit-views-ui-show-preview-information' => array(TRUE)),\n );\n $form['live_preview']['views_ui_show_performance_statistics'] = array(\n '#type' => 'checkbox',\n '#title' => t('Show performance statistics'),\n '#default_value' => variable_get('views_ui_show_performance_statistics', FALSE),\n '#dependency' => array('edit-views-ui-show-preview-information' => array(TRUE)),\n );\n\n $form['live_preview']['views_show_additional_queries'] = array(\n '#type' => 'checkbox',\n '#title' => t('Show other queries run during render during live preview'),\n '#description' => t(\"Drupal has the potential to run many queries while a view is being rendered. Checking this box will display every query run during view render as part of the live preview.\"),\n '#default_value' => variable_get('views_show_additional_queries', FALSE),\n '#dependency' => array('edit-views-ui-show-preview-information' => array(TRUE)),\n );\n\n// $form['live_preview']['views_ui_show_performance_statistics_where'] = array(\n\n return system_settings_form($form);\n}", "title": "" }, { "docid": "fbaa4a9115987e32b5dd1a9c54c5bf30", "score": "0.57147264", "text": "function admin_menu_page() { \n if($_POST['USGS_Flow_Class_save']){\n if (! wp_verify_nonce($_POST['_wpnonce'], 'USGS_Flow_Class-update-options') ) die('Whoops! There was a problem with the data you posted. Please go back and try again.'); \n $this->options['USGS_Flow_Class_path'] = $_POST['USGS_Flow_Class_path']; \n $this->options['USGS_Flow_Class_allowed_groups'] = $_POST['USGS_Flow_Class_allowed_groups'];\n $this->options['USGS_Flow_Class_enabled'] = ($_POST['USGS_Flow_Class_enabled']=='on')?true:false;\n $this->options['USGS_Flow_Class_sites'] = $this->saveAdminOptions();\n \n echo '<div class=\"updated\"><p>Success! Your changes were sucessfully saved!</p></div>';\n }\n?>\n <div class=\"wrap\">\n <h2>USGS Flow Plugin</h2>\n <form method=\"post\" id=\"USGS_Flow_Class_options\">\n <?php wp_nonce_field('USGS_Flow_Class-update-options'); ?>\n <table width=\"100%\" cellspacing=\"2\" cellpadding=\"5\" class=\"form-table\"> \n <tr valign=\"top\"> \n <th width=\"33%\" scope=\"row\"><?php _e('Option 1:', $this->localizationDomain); ?></th> \n <td><input name=\"USGS_Flow_Class_path\" type=\"text\" id=\"USGS_Flow_Class_path\" size=\"45\" value=\"<?php echo $this->options['USGS_Flow_Class_path'] ;?>\"/>\n </td> \n </tr>\n <tr valign=\"top\"> \n <th width=\"33%\" scope=\"row\"><?php _e('Option 2:', $this->localizationDomain); ?></th> \n <td><input name=\"USGS_Flow_Class_allowed_groups\" type=\"text\" id=\"USGS_Flow_Class_allowed_groups\" value=\"<?php echo $this->options['USGS_Flow_Class_allowed_groups'] ;?>\"/>\n </td> \n </tr>\n <tr valign=\"top\"> \n <th><label for=\"USGS_Flow_Class_enabled\"><?php _e('CheckBox #1:', $this->localizationDomain); ?></label></th><td><input type=\"checkbox\" id=\"USGS_Flow_Class_enabled\" name=\"USGS_Flow_Class_enabled\" <?=($this->options['USGS_Flow_Class_enabled']==true)?'checked=\"checked\"':''?>></td>\n </tr>\n <tr>\n <th colspan=2><input type=\"submit\" name=\"USGS_Flow_Class_save\" value=\"Save\" /></th>\n </tr>\n </table>\n </form>\n <?php\n }", "title": "" }, { "docid": "17eecc20cd029167d365022b3f7d45e8", "score": "0.5714465", "text": "public function admin_page_upgrade() {\n\n\t\t\tinclude_once 'partials/ws-form-upgrade.php';\n\t\t}", "title": "" }, { "docid": "e993f61701086a4819019d16ef9279fe", "score": "0.5711177", "text": "function shanti_sarvaka_form_system_theme_settings_alter(&$form, $form_state) {\n global $base_path;\n $form['shanti_sarvaka_shanti_site'] = array(\n '#type' => 'checkbox',\n '#title' => t('Shanti Site'),\n '#default_value' => theme_get_setting('shanti_sarvaka_shanti_site'),\n '#description' => t(\"Check if you want Shanti Logo and title to appear in top bar\"),\n );\n $form['shanti_sarvaka_use_admin_site_title'] = array(\n '#type' => 'checkbox',\n '#title' => t('Use Admin Site Title'),\n '#default_value' => theme_get_setting('shanti_sarvaka_use_admin_site_title'),\n '#description' => t(\"Use site title in <a href=\\\"/admin/config/system/site-information\\\">admin settings</a>.\"),\n '#states' => array(\n 'visible' => array(\n ':input[name=\"shanti_sarvaka_shanti_site\"]' => array('checked' => TRUE),\n ),\n ),\n );\n $form['shanti_sarvaka_default_title'] = array(\n '#type' => 'textfield',\n '#title' => t('Default Title for Banner'),\n '#default_value' => theme_get_setting('shanti_sarvaka_default_title'),\n '#description' => t(\"The default page title to display in colored banner if no page title is found\"),\n );\n $form['shanti_sarvaka_prefix_default_title'] = array(\n '#type' => 'checkbox',\n '#title' => t('Prefix Default Title before all Page Titles in Banner'),\n '#default_value' => theme_get_setting('shanti_sarvaka_prefix_default_title'),\n '#description' => t(\"Prefix the default title before every page name\"),\n '#states' => array(\n 'invisible' => array(\n ':input[name=\"shanti_sarvaka_default_title\"]' => array('value' => ''),\n ),\n ),\n );\n $form['shanti_sarvaka_breadcrumb_intro'] = array(\n '#type' => 'textfield',\n '#title' => t('Text before breadcrumbs'),\n '#default_value' => theme_get_setting('shanti_sarvaka_breadcrumb_intro'),\n '#description' => t(\"The text to display in front of the breadcrumbs\"),\n );\n $form['shanti_sarvaka_breadcrumb_prefix'] = array(\n '#type' => 'select',\n '#title' => t('Choose the prefix you want for your breadcrumbs'),\n '#options' \t\t\t => array(\n 1 => t('None'),\n 2 => t('Collection Only'),\n 3 => t('Username and Collection'),\n 4 => t('Home'),\n ),\n '#default_value' => theme_get_setting('shanti_sarvaka_breadcrumb_prefix'),\n '#description' => t(\"Select the option for your breadcrumb prefix\"),\n );\n $form['shanti_sarvaka_breadcrumb_nohome'] = array(\n '#type' => 'checkbox',\n '#title' => t('Remove \"Home\" as first item in breadcrumbs'),\n '#default_value' => theme_get_setting('shanti_sarvaka_breadcrumb_nohome'),\n '#description' => t(\"Check this box to remove the first breadcrumb, \\\"Home\\\"\"),\n );\n $form['shanti_sarvaka_icon_class'] = array(\n '#type' => 'textfield',\n '#title' => t('Icon Class Name for Banner'),\n '#default_value' => theme_get_setting('shanti_sarvaka_icon_class'),\n '#description' => t('Icon in title banner for this site. Use the class name as listed on the <a href=\"@link\" target=\"_blank\">Shanticon Reference Page</a> without the \"shanticon-\" prefix.', \n array(\"@link\" => $base_path . drupal_get_path('theme', 'shanti_sarvaka') . '/fonts/shanticon/bin/demo.html')),\n );\n $form['shanti_sarvaka_site_body_tag'] = array(\n '#type' => 'textfield',\n '#title' => t('Unique Body Class for Site'),\n '#default_value' => theme_get_setting('shanti_sarvaka_site_body_tag'),\n '#description' => t(\"A unique class identifying the site to add to the body tag\"),\n );\n $form['shanti_sarvaka_show_login_link'] = array(\n '#type' => 'checkbox',\n '#title' => t('Show Login Link in Main Menu'),\n '#default_value' => theme_get_setting('shanti_sarvaka_show_login_link'),\n '#description' => t('Uncheck this box to prevent the login link from appearing in the main menu'),\n );\n // Custom submit handler for validation\n $form['#submit'][] = 'shanti_sarvaka_form_system_theme_settings_submit';\n}", "title": "" }, { "docid": "a234fdc17d9329f7a3c9e5cf9cfbf99f", "score": "0.57097477", "text": "function kale_kirki_update_3015(){\n $switches = array( 'kale_image_logo_show', 'kale_frontpage_featured_posts_show', 'kale_frontpage_large_post_show',\n 'kale_blog_feed_meta_show', 'kale_posts_meta_show', 'kale_sidebar_size');\n foreach($switches as $switch) {\n $val = get_theme_mod( $switch, true ) ;\n if($val == \"0\") set_theme_mod( $switch, false );\n }\n}", "title": "" }, { "docid": "efa4fc7d52ee3793dee13b358e1f6d93", "score": "0.57079875", "text": "function dwc_settings_page(){\n\n\t$reseted_plugin_data = '';\n\tif (isset($_POST['dwc_options_submit']) && $_POST['dwc_options_submit'] ) {\n\t\t\n\t\t$dwc_shop_wishlist_btn \t\t\t= (isset($_POST['dwc_shop_wishlist_btn'])) ? $_POST['dwc_shop_wishlist_btn'] : '';\n\t\t$dwc_shop_wishlist_btn_text \t= (isset($_POST['dwc_shop_wishlist_btn_text'])) ? $_POST['dwc_shop_wishlist_btn_text'] : '';\n\n\t\t$dwc_single_wishlist_btn \t\t= (isset($_POST['dwc_single_wishlist_btn'])) ? $_POST['dwc_single_wishlist_btn'] : '';\n\t\t$dwc_single_wishlist_btn_text \t= (isset($_POST['dwc_single_wishlist_btn_text'])) ? $_POST['dwc_single_wishlist_btn_text'] : '';\n\t\t$dwc_shop_wishlist_browse_page \t= (isset($_POST['dwc_shop_wishlist_browse_page'])) ? $_POST['dwc_shop_wishlist_browse_page'] : '';\n\t\t\n\t\t$dwc_plugin_options_data = array(\n\t\t\t'dwc_shop_wishlist_btn' \t\t\t=>\t$dwc_shop_wishlist_btn,\n\t\t\t'dwc_shop_wishlist_btn_text' \t\t=>\t$dwc_shop_wishlist_btn_text,\n\t\t\t'dwc_single_wishlist_btn' \t\t\t=>\t$dwc_single_wishlist_btn,\n\t\t\t'dwc_single_wishlist_btn_text' \t\t=>\t$dwc_single_wishlist_btn_text,\n\t\t\t'dwc_shop_wishlist_browse_page' \t=>\t$dwc_shop_wishlist_browse_page,\n\t\t);\n\t\t$old_data = dwc_get_theme_options();\n\t\t$dwc_plugin_options_data = array_merge($old_data,$dwc_plugin_options_data);\n\n\t\t// Update Theme Options\n\t\tupdate_option( 'dwc_plugin_options', $dwc_plugin_options_data, '', 'yes' );\n\t\t//$reseted_plugin_data = '<p>Data Saved!</p>';\n\n\t} // End process of save data\n\n ?>\n <div class=\"wrap dwc_settings\">\n\t\t<h1>Dwc Plugins Settings</h1>\n\n\t\t\t<!-- <div class=\"dwc_header widefat\">\n\t\t\t\t<h3>Welcome to theme options</h3>\n\t\t\t</div> -->\n\n\t\t\t<div class=\"widefat dwc_settings\">\n\t\t\t\t<?php if ($reseted_plugin_data) { ?>\n\t\t\t\t\t<!-- Update Notificatiion -->\n\t\t\t\t\t<div id=\"message\" class=\"updated notice notice-success is-dismissible\">\n\t\t\t\t\t\t<?php echo $reseted_plugin_data; ?>\n\t\t\t\t\t\t<button type=\"button\" class=\"notice-dismiss\"><span class=\"screen-reader-text\">Dismiss this notice.</span></button>\n\t\t\t\t\t</div>\n\t\t\t\t<?php } ?>\n\n\t\t\t\t<form class=\"dwc_setting_form\" method=\"post\" action=\"\">\n\n\t\t\t\t\t<?php settings_fields( 'dwc_plugin_options_group' ); ?>\n\t\t\t\t\t<?php do_settings_sections( 'dwc_plugin_options_group' ); ?>\n\n\t\t\t\t\t<table class=\"widefat striped\">\n\t\t\t\t\t\t<tbody>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t<!-- Shop Page Options -->\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t<tr class=\"dwc_sec_title\"><td class=\"row-title\">DWC Shop Page Options</td></tr>\n\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t<th scope=\"row\"><label>Show Wishlist Button On Shop Page</label></th>\n\t\t\t\t\t\t\t\t<?php $shop_wishlist_chk = dwc_get_theme_options('dwc_shop_wishlist_btn'); ?>\n\t\t\t\t\t\t\t\t<?php $shop_wishlist_chk = ($shop_wishlist_chk) ? 'checked' : ''; ?>\n\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t<label class=\"switch\">\n\t\t\t\t\t\t\t\t\t \t<input type=\"checkbox\" <?php echo $shop_wishlist_chk; ?> name=\"dwc_shop_wishlist_btn\">\n\t\t\t\t\t\t\t\t\t \t<div class=\"slider round\"></div>\n\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t<th scope=\"row\"><label>Wishlist Button Text</label></th>\n\t\t\t\t\t\t\t\t<td><input type=\"text\" class=\"regular-text\" name=\"dwc_shop_wishlist_btn_text\" value=\"<?php echo dwc_get_theme_options('dwc_shop_wishlist_btn_text'); ?>\"></td>\n\t\t\t\t\t\t\t</tr>\n\n\t\t\t\t\t\t\t<!-- Single Page Options -->\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t<tr class=\"dwc_sec_title\"><td class=\"row-title\">Single Product Page Options</td></tr>\n\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t<th scope=\"row\"><label>Show Wishlist Button on Single Page</label></th>\n\t\t\t\t\t\t\t\t<?php $single_wishlist_chk = dwc_get_theme_options('dwc_single_wishlist_btn'); ?>\n\t\t\t\t\t\t\t\t<?php $single_wishlist_chk = ($single_wishlist_chk) ? 'checked' : ''; ?>\n\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t<label class=\"switch\">\n\t\t\t\t\t\t\t\t\t \t<input type=\"checkbox\" <?php echo $single_wishlist_chk; ?> name=\"dwc_single_wishlist_btn\">\n\t\t\t\t\t\t\t\t\t \t<div class=\"slider round\"></div>\n\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t<th scope=\"row\"><label>Wishlist Button Text</label></th>\n\t\t\t\t\t\t\t\t<td><input type=\"text\" class=\"regular-text\" name=\"dwc_single_wishlist_btn_text\" value=\"<?php echo dwc_get_theme_options('dwc_single_wishlist_btn_text'); ?>\"></td>\n\t\t\t\t\t\t\t</tr>\n\n\t\t\t\t\t\t\t<!-- Other Options -->\n\t\t\t\t\t\t\t<tr class=\"dwc_sec_title\"><td class=\"row-title\">DWC Other Options</td></tr>\n\n\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t<th scope=\"row\"><label>Select Page for browse Wishlist</label></th>\n\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t<select name=\"dwc_shop_wishlist_browse_page\">\n\t\t\t\t\t\t\t\t\t\t<option><?php echo esc_attr( __( 'Select page' ) ); ?></option>\n\t\t\t\t\t\t\t\t\t\t<?php \n\t\t\t\t\t\t\t\t\t\t$pages = get_pages(); \n\t\t\t\t\t\t\t\t\t\tforeach ( $pages as $page ) {\n\t\t\t\t\t\t\t\t\t\t\tif (dwc_get_theme_options('dwc_shop_wishlist_browse_page') == $page->ID) {\n\t\t\t\t\t\t\t\t\t\t\t\techo '<option value=\"' .$page->ID. '\" selected >'.$page->post_title.'</option>';\t\n\t\t\t\t\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t\t\t\t\techo '<option value=\"' .$page->ID. '\">'.$page->post_title.'</option>';\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t?>\n\t\t\t\t\t\t\t\t\t</select>\n\t\t\t\t\t\t\t\t\t<p>Select Page for Browser Wishlist. ( Page contents: [dwc_wishlist] )</p>\n\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t<tr class=\"submit\">\n\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t<input type=\"submit\" name=\"dwc_options_submit\" value=\"Save Changes\" />\n\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t</tr>\n\n\t\t\t\t\t\t</tbody>\n\t\t\t\t\t</table>\n\t\t\t\t</form>\n\t\t\t</div>\n\t\t</div>\n<?php\n\t\n\tadd_action( 'admin_init', 'dwc_register_settings' );\n\tfunction dwc_register_settings() { // whitelist options\n\t\tregister_setting( 'dwc_plugin_options_group', 'dwc_plugin_options' );\n\t}\t\n\n}", "title": "" }, { "docid": "37985cedaf4ee53d347242d4201ecdbd", "score": "0.5699377", "text": "function wdm_add_meta_box() {\n\n add_meta_box(\n 'wdm_sectionid', 'Radio Buttons Meta Box', 'wdm_meta_box_callback', 'wpcm_player', 'side', 'high'\n ); //you can change the 4th paramter i.e. post to custom post type name, if you want it for something else\n\n}", "title": "" }, { "docid": "de1d6d4dc4e72c3b1e278cd4158fb571", "score": "0.5698839", "text": "public function setOptionFormElements()\n {\n register_setting(\"wpstg_settings\", \"wpstg_settings\", [$this, \"sanitizeOptions\"]);\n }", "title": "" }, { "docid": "dca054f9042fba4d2099602af657922b", "score": "0.5697368", "text": "static function import_old_version( $force = '' ) {\r\n\t\t\r\n\t\t// ***** Import global options *****\r\n\r\n // upgrade import only back to version 2.5.6, because before that, there was no 'es_contact_form_gb' setting\r\n\t\tself::$old_global_options = get_option( 'es_contact_form_gb' );\r\n\t\tif ( empty( self::$old_global_options ) ) {\r\n\t\t\treturn;\r\n\t\t}\r\n//print_r(self::$old_global_options).\"<br>\\n\";\r\n\t\tself::$global_options = ESCF_Util::get_global_options();\r\n\r\n // import a few global options\r\n\t\t$copy_fields = array( 'donated', 'vcita_dismiss' );\r\n\t\tforeach ( $copy_fields as $field ) {\r\n\t\t\tif ( ! empty( self::$old_global_options[$field] ) )\r\n\t\t\t\tself::$global_options[$field] = self::$old_global_options[$field];\r\n\t\t}\r\n // import this global option\r\n // Highest form ID (used to assign ID to new form)\r\n\t\t// When forms are deleted, the remaining forms are NOT renumberd, so max_form_num might be greater than\r\n\t\t// the number of existing forms\r\n\t\tif ( ! empty( self::$old_global_options['max_forms'] ) )\r\n\t\t\tself::$global_options['max_form_num'] = self::$old_global_options['max_forms'];\r\n//print 'max_form_num:'.self::$global_options['max_form_num'].\"<br>\\n\";\r\n\t\t// ***** Import form options *****\r\n $max_fields_shim = 8;\r\n\r\n if($force == 'force') {\r\n // force is when they pressed the button import from 3.xx, they are warned this replaces the 4.xx forms\r\n self::$global_options['form_list'] = array(); // delete current form list\r\n // delete current 4.xx forms\r\n delete_option('es_contact_global');\r\n\r\n // delete up to 100 forms (a unique configuration for each contact form)\r\n for ($i = 1; $i <= 100; $i++) {\r\n delete_option(\"es_contact_form$i\");\r\n }\r\n }\r\n\t\tfor ($frm=1; $frm<=self::$global_options['max_form_num']; $frm++) {\r\n//print 'importing form:'.$frm.\"<br>\\n\";\r\n\t\t\t$old_opt_name = 'es_contact_form';\r\n\t\t\t$old_opt_name .= ($frm==1) ? '': $frm;\r\n\t\t\tself::$old_form_options = get_option($old_opt_name);\r\n\t\t\tif ( ! self::$old_form_options ) continue;\r\n\r\n\r\n if($force == 'force') {\r\n\r\n\r\n } else {\r\n // Make sure that the options for this form doesn't already exist\r\n self::$form_options = ESCF_Util::get_form_options($frm, $use_defaults=false);\r\n\t\t\t if ( self::$form_options ) continue;\r\n }\r\n\r\n // if max fields is missing it will be 8, or the value of the last one in the loop.\r\n if (isset(self::$old_form_options['max_fields']) && self::$old_form_options['max_fields'] > 0)\r\n $max_fields_shim = self::$old_form_options['max_fields'];\r\n else\r\n self::$old_form_options['max_fields'] = $max_fields_shim;\r\n\r\n\t\t\t$new_form_options = self::convert_form_options(self::$old_form_options, self::$old_form_options['max_fields']);\r\n//print_r($new_form_options).\"<br>\\n\";\r\n\t\t\t// Save the imported form\r\n\t\t\t$form_option_name = 'es_contact_form' . $frm;\r\n\t\t\t// Add form name to the form list...\r\n if ($new_form_options['form_name'] == '')\r\n $new_form_options['form_name'] = __( 'imported', 'easy-softonic-contact-form' );\r\n\r\n\t\t\tself::$global_options['form_list'][$frm] = $new_form_options['form_name'];\r\n\t\t\tupdate_option ( $form_option_name, $new_form_options );\r\n\r\n\t\t}\t// end for loop (forms)\r\n\r\n\t\tself::$global_options['import_success'] = true;\r\n\t\tself::$global_options['import_msg'] = true;\r\n // recalibrate max_form_num to the highest form number (not count)\r\n ksort( self::$global_options['form_list'] );\r\n self::$global_options['max_form_num'] = max(array_keys(self::$global_options['form_list']));\r\n//print_r(self::$global_options).\"<br>\\n\";\r\n\t\tupdate_option( 'es_contact_global', self::$global_options );\r\n\r\n\t\t// Display a notice on the admin page\r\n\t\tESCF_Util::add_admin_notice(__( 'Easy Softonic Contact Form has imported settings from the old version.', 'easy-softonic-contact-form' ), 'updated');\r\n\r\n // Force reload of global and form options\r\n\t\tESCF_Options::unload_options();\r\n\t\t\r\n\t}", "title": "" }, { "docid": "7a61b113f923c59b869f8830f93fcd80", "score": "0.5693275", "text": "function my_admin() {\nadd_meta_box( 'slide_settings_meta_box', 'Slide Settings', 'display_slide_settings_meta_box', 'w45_slides', 'normal', 'high' );\n}", "title": "" }, { "docid": "ce9283f9bfd17a6a8f2f8d737c784c65", "score": "0.5693231", "text": "function activity_settings_form(&$form_state = NULL) {\n $form['activity_expiration'] = array(\n '#type' => 'fieldset',\n '#title' => t('Activity Expiration Settings'),\n '#element_validate' => array('activity_expire_validate'),\n );\n \n $form['activity_expiration']['activity_expire'] = array(\n '#type' => 'select',\n '#title' => t('Activity log purge'),\n '#description' => t(\"Allows you to set a time limit for storing activity records. Select 0 to keep all activity records.\"),\n '#options' => drupal_map_assoc(array(0, 3600, 7200, 14400, 21600, 43200, 86400, 604800, 1209600, 2419200, 7257600, 15724800, 31536000), 'format_interval'),\n '#default_value' => variable_get('activity_expire', 0),\n );\n \n $form['activity_expiration']['activity_min_count'] = array(\n '#type' => 'select',\n '#title' => t('Minimum Activities'),\n '#description' => t('This is the minimum number activities that the user must have created before deleting any old activities.'),\n '#options' => drupal_map_assoc(range(0, 200, 10)),\n '#default_value' => variable_get('activity_min_count', 0),\n );\n \n\n // Allow realms provided by modules.\n $realms = array();\n foreach (activity_cache_get('all_realms') as $realm => $information) {\n $realms[$realm] = $information['name'];\n }\n\n // Set up the default value for this set of checkboxes.\n $enabled = array();\n foreach (activity_cache_get('realms') as $realm => $information) {\n $enabled[$realm] = $realm;\n }\n\n $form['activity_access'] = array(\n '#type' => 'fieldset',\n '#title' => t('Activity Access Control'),\n '#attributes' => array('id' => 'activity-access-fieldset'),\n );\n $form['activity_access']['activity_access_realms'] = array(\n '#type' => 'checkboxes',\n '#title' => t('Realms'),\n '#description' => t('Select the realms for which Activity access records should be recorded. These realms will allow a View to filter in more then just one users Activity.'),\n '#options' => $realms,\n '#default_value' => $enabled,\n );\n\n $form['activity_access']['activity_access_rebuild'] = array(\n '#type' => 'submit',\n '#value' => t('Rebuild Activity Access Table'),\n '#submit' => array('activity_access_batch_set'),\n );\n\n // This tells system_settings_form to use array_filter for the checkboxes.\n $form['array_filter'] = array('#type' => 'value', '#value' => TRUE);\n\n return system_settings_form($form);\n}", "title": "" }, { "docid": "2e65d6e12b654d40d19ecd766155296a", "score": "0.56893617", "text": "public function add_fields_settings() {\n\t\t$option_name = \"{$this->domain}_{$this->tab}\";\n\t\tif ($this->tab == 'controls') {\n\t\t\tadd_settings_field('available', __('Booking available', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'available'));\n\t\t\tadd_settings_field('closed_page', __('Closed Page', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'closed_page'));\n\t\t\tadd_settings_field('start_accepting', __('Close accepting', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'start_accepting'));\n\t\t\tadd_settings_field('cancel', __('Cancel available', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'cancel'));\n\t\t\tadd_settings_field('output_margin', __('Output in the margin', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'output_margin'));\n\t\t\tadd_settings_field('period', __('Period', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'period'));\n\t\t\tadd_settings_field('vacant_mark', __('Vacant Mark', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'vacant_mark'));\n\t\t\tadd_settings_field('booked_mark', __('Booked Mark', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'booked_mark'));\n\t\t\tadd_settings_field('low_mark', __('Low Mark', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'low_mark'));\n\t\t\tadd_settings_field('full_mark', __('Full Mark', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'full_mark'));\n\t\t\tadd_settings_field('disable', __('Disable Mark', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'disable'));\n\t\t\tadd_settings_field('vacant_rate', __('Vacant Rate', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'vacant_rate'));\n\t\t\tadd_settings_field('count', __('Count Number', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'count'));\n\t\t\tadd_settings_field('message', __('Message', $this->domain), array($this, 'controls_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'message'));\n\n\t\t} else if ($this->tab == 'premise') {\n\t\t\tadd_settings_field('name', __('The name of premise', $this->domain), array($this, 'premise_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'name'));\n\t\t\tadd_settings_field('postcode', __('Postcode', $this->domain), array($this, 'premise_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'postcode'));\n\t\t\tadd_settings_field('address1', __('Address 1', $this->domain), array($this, 'premise_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'address1'));\n\t\t\tadd_settings_field('address2', __('Address 2', $this->domain), array($this, 'premise_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'address2'));\n\t\t\tadd_settings_field('tel', __('Tel', $this->domain), array($this, 'premise_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'tel'));\n\t\t\tadd_settings_field('fax', __('Fax', $this->domain), array($this, 'premise_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'fax'));\n\t\t\tadd_settings_field('email', __('E-Mail', $this->domain), array($this, 'premise_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'email'));\n\t\t\tadd_settings_field('mobile', __('Mobile Mail', $this->domain), array($this, 'premise_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'mobile'));\n\t\t\tadd_settings_field('web', __('Web Site URL', $this->domain), array($this, 'premise_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'web'));\n\n\t\t} else if ($this->tab == 'reserve') {\n\t\t\tadd_settings_field('column', __('Column Setting', $this->domain), array($this, 'reserve_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'column'));\n\t\t\tadd_settings_field('column_order', __('Column Order', $this->domain), array($this, 'reserve_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'column_order'));\n\t\t\tadd_settings_field('title', __('Subject', $this->domain), array($this, 'reserve_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'title'));\n\t\t\tadd_settings_field('header', __('Mail Header', $this->domain), array($this, 'reserve_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'header'));\n\t\t\tadd_settings_field('footer', __('Mail Footer', $this->domain), array($this, 'reserve_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'footer'));\n\t\t\tadd_settings_field('cancel_title', __('Cancel Subject', $this->domain), array($this, 'reserve_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'cancel_title'));\n\t\t\tadd_settings_field('cancel_body', __('Cancel Body', $this->domain), array($this, 'reserve_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'cancel_body'));\n\n\t\t} else if ($this->tab == 'contact') {\n\t\t\tadd_settings_field('column', __('Column Setting', $this->domain), array($this, 'contact_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'column'));\n\t\t\tadd_settings_field('title', __('Subject', $this->domain), array($this, 'contact_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'title'));\n\t\t\tadd_settings_field('header', __('Mail Header', $this->domain), array($this, 'contact_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'header'));\n\t\t\tadd_settings_field('footer', __('Mail Footer', $this->domain), array($this, 'contact_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'footer'));\n\n\t\t} else if ($this->tab == 'miscellaneous') {\n\t\t\tadd_settings_field('adminbar', __('Admin Bar', $this->domain), array($this, 'miscellaneous_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'adminbar'));\n\t\t\tadd_settings_field('schedule_dialog', __('Schedule Dialog', $this->domain), array($this, 'miscellaneous_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'schedule_dialog'));\n\n\t\t} else if ($this->tab == 'charge') {\n\t\t\tadd_settings_field('accedence', __('Accedence Checkbox', $this->domain), array($this, 'charge_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'accedence'));\n\t\t\tadd_settings_field('terms_url', __('Terms and conditions URL', $this->domain), array($this, 'charge_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'terms_url'));\n\t\t\tadd_settings_field('charge_list', __('Charge List', $this->domain), array($this, 'charge_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'charge_list'));\n\t\t\tadd_settings_field('currency_code', __('Currency Code', $this->domain), array($this, 'charge_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'currency_code'));\n\t\t\tadd_settings_field('tax_notation', __('Tax Notation', $this->domain), array($this, 'charge_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'tax_notation'));\n\t\t\tadd_settings_field('consumption_tax', __('Consumption tax(%)', $this->domain), array($this, 'charge_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'consumption_tax'));\n\t\t\tadd_settings_field('pay_first', __('Payment Required', $this->domain), array($this, 'charge_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'pay_first'));\n\t\t\tadd_settings_field('checkout', __('Checkout Function', $this->domain), array($this, 'charge_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'checkout'));\n\t\t\tadd_settings_field('unsettled_mail', __('Not Paid Sentence', $this->domain), array($this, 'charge_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'unsettled_mail'));\n\t\t\tadd_settings_field('settled_mail', __('Paid Sentence', $this->domain), array($this, 'charge_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'settled_mail'));\n\n\t\t} else if ($this->tab == 'paypal') {\n\t\t\tadd_settings_field('pp_username', __('API Username', $this->domain), array($this, 'paypal_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'pp_username'));\n\t\t\tadd_settings_field('pp_password', __('API Password', $this->domain), array($this, 'paypal_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'pp_password'));\n\t\t\tadd_settings_field('pp_signature', __('Signature', $this->domain), array($this, 'paypal_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'pp_signature'));\n\t\t\tadd_settings_field('https_url', __('HTTPS URL', $this->domain), array($this, 'paypal_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'https_url'));\n\t\t\tadd_settings_field('logo_url', __('Logo image URL', $this->domain), array($this, 'paypal_form'),\n\t\t\t\t$option_name, $option_name, array('label_for' => 'logo_url'));\n add_settings_field('use_sandbox', __('Use Sandbox', $this->domain), array($this, 'paypal_form'),\n $option_name, $option_name, array('label_for' => 'use_sandbox'));\n\t\t}\n\t}", "title": "" }, { "docid": "3b016ac54a3e4847955beed15d6a1e4b", "score": "0.5689059", "text": "function jr_mt_v7init_required() {\n\t\tglobal $jr_mt_plugin_data;\n\t\tif ( current_user_can( 'manage_options' ) ) {\n\t\t\techo '<div class=\"updated\"><p><b>' . $jr_mt_plugin_data['Name'] . ' plugin: Version '. $jr_mt_plugin_data['Version'] . ' update requires visit to <a href=\"'\n\t\t\t\t. admin_url( 'options-general.php?page=jr_mt_settings' )\n\t\t\t\t. '\">Settings page</a> to check and update its Settings.</b></p></div>';\n\t\t}\n\t}", "title": "" }, { "docid": "f71e05b95ffcaa6e79c701cf1b961749", "score": "0.56854945", "text": "function wpwq_options_metabox() {\r\n\t\r\n\t// Start with an underscore to hide fields from custom fields list\r\n\t$prefix = 'wpwq_opt_';\r\n\t\r\n\t// Initiate the metabox\r\n\t$cmb = new_cmb2_box( array(\r\n\t\t'id'\t\t\t=> $prefix . 'single_options',\r\n\t\t'title'\t\t\t=> __( 'Wpwq Options', 'wpwq' ),\r\n\t\t'object_types'\t=> wpwq_get_post_types(),\r\n\t\t'context'\t\t=> 'side',\r\n\t\t'priority'\t\t=> 'default',\r\n\t\t'show_names'\t=> true,\r\n\t\t'show_on_cb'\t=> 'wpwq_options_metabox_show_on_cb',\r\n\t) );\r\n\r\n\t$cmb->add_field( array(\r\n\t\t'id' => $prefix . 'meta_desc',\r\n\t\t'type' => 'title',\r\n\t\t'desc' => __('Metabox added by <a title=\"Settings -> Waterproof Wrap Query Plugin\" target=\"_blank\" href=\"' . get_admin_url() . 'options-general.php?page=wpwq_options\">Waterproof Wrap Query Plugin</a>','wpwq'),\r\n\t) );\r\n\t\r\n\t$cmb->add_field( array(\r\n\t\t'name' => __('Has Single', 'wpwq'),\r\n\t\t'id' => $prefix . 'has_single',\r\n\t\t'type' => 'radio_inline',\r\n\t\t'desc' => __('Is this posty thing viewable as single? If not, user will be redirected to parent page or home. But this post can still be used for listings.','wpwq'),\r\n\t\t'default' => 'yes',\r\n\t\t'options' => array(\r\n\t\t\t'yes' => __( 'Yes', 'wpwq' ),\r\n\t\t\t'no' => __( 'No', 'wpwq' ),\r\n\t\t),\r\n\t) );\r\n\t\r\n}", "title": "" }, { "docid": "3e74bc589c91e7af06848908696fbe23", "score": "0.56853753", "text": "function clpr_setup_meta_box() {\n\n\tadd_meta_box( 'coupon-meta-box', __( 'Coupon Meta Fields', APP_TD ), 'clpr_custom_fields_meta_box', APP_POST_TYPE, 'normal', 'high' );\n\n\tremove_meta_box( 'tagsdiv-stores', APP_POST_TYPE, 'core' );\n\tremove_meta_box( 'coupon_typediv', APP_POST_TYPE, 'core' );\n\n\tremove_meta_box( 'postexcerpt', APP_POST_TYPE, 'normal' );\n\tremove_meta_box( 'authordiv', APP_POST_TYPE, 'normal' );\n\n\t//custom post statuses\n\t//temporary hack until WP will fully support custom post statuses\n\tremove_meta_box( 'submitdiv', APP_POST_TYPE, 'core' );\n\tadd_meta_box( 'submitdiv', __( 'Publish', APP_TD ), 'clpr_post_submit_meta_box', APP_POST_TYPE, 'side', 'high' );\n\n}", "title": "" }, { "docid": "ccce6dc3277f7dfb52360a5842c44c66", "score": "0.5682949", "text": "public function save_metabox(){\n\t}", "title": "" }, { "docid": "e8d10d81fa0c9222e4dcc6010d48085a", "score": "0.5669037", "text": "function uc_store_store_settings_form() {\n $form['uc_store_name'] = uc_textfield(t('Store name'), variable_get('uc_store_name', NULL), FALSE, NULL, 64);\n $form['uc_store_owner'] = uc_textfield(t('Store owner'), variable_get('uc_store_owner', NULL), FALSE, NULL, 64);\n\n $form['uc_store_email'] = array(\n '#type' => 'textfield',\n '#title' => t('E-mail address'),\n '#description' => NULL,\n '#size' => 32,\n '#maxlength' => 128,\n '#required' => TRUE,\n '#default_value' => uc_store_email(),\n '#summary' => uc_store_email() ? t('Store e-mail address is %email.', array('%email' => uc_store_email())) : t('Store e-mail address is not set.'),\n );\n\n $form['uc_store_email_include_name'] = array(\n '#type' => 'checkbox',\n '#title' => t('Include the store name in the \"From\" line of store e-mails.'),\n '#description' => t('May not be available on all server configurations. Turn off if this causes problems.'),\n '#default_value' => variable_get('uc_store_email_include_name', TRUE),\n '#summary callback' => uc_store_email() ? NULL : 'summarize_null',\n );\n\n $form['uc_store_phone'] = uc_textfield(t('Phone number'), variable_get('uc_store_phone', NULL), FALSE);\n $form['uc_store_fax'] = uc_textfield(t('Fax number'), variable_get('uc_store_fax', NULL), FALSE);\n\n $form['store_address'] = array('#summary callback' => '_uc_store_address_summarize');\n $form['store_address']['uc_store_street1'] = uc_textfield(uc_get_field_name('street1'), variable_get('uc_store_street1', NULL), FALSE, NULL, 128);\n $form['store_address']['uc_store_street2'] = uc_textfield(uc_get_field_name('street2'), variable_get('uc_store_street2', NULL), FALSE, NULL, 128);\n $form['store_address']['uc_store_city'] = uc_textfield(uc_get_field_name('city'), variable_get('uc_store_city', NULL), FALSE);\n $form['store_address']['uc_store_country'] = uc_country_select(uc_get_field_name('country'), uc_store_default_country());\n\n if (isset($_POST['uc_store_country'])) {\n $country_id = intval($_POST['uc_store_country']);\n }\n else {\n $country_id = uc_store_default_country();\n }\n $form['store_address']['uc_store_zone'] = uc_zone_select(uc_get_field_name('zone'), variable_get('uc_store_zone', NULL), NULL, $country_id);\n $form['store_address']['uc_store_postal_code'] = uc_textfield(uc_get_field_name('postal_code'), variable_get('uc_store_postal_code', NULL), FALSE, NULL, 10);\n\n $form['uc_store_help_page'] = array(\n '#type' => 'textfield',\n '#title' => t('Store help page'),\n '#description' => t('The Drupal page for the store help link.'),\n '#default_value' => variable_get('uc_store_help_page', ''),\n '#size' => 32,\n '#field_prefix' => url(NULL, array('absolute' => TRUE)) . (variable_get('clean_url', 0) ? '' : '?q='),\n '#summary' => variable_get('uc_store_help_page', '') ? t('Help page is <a href=\"!url\">!url</a>.', array('!url' => url(variable_get('uc_store_help_page', ''), array('absolute' => TRUE)))) : t('Help page is not set.'),\n );\n\n // Register additional validation handler\n $form['#validate'][] = 'uc_store_store_settings_form_validate';\n\n return system_settings_form($form);\n}", "title": "" }, { "docid": "00eba1cc6532e95c70c34c324b2a9ad4", "score": "0.5667963", "text": "function wpeppsubNCX_plugin_options() {\r\n\r\n\tif ( !current_user_can( \"manage_options\" ) ) {\r\n\t\twp_die( __( \"You do not have sufficient permissions to access this page. Please sign in as an administrator.\" ));\r\n\t}\r\n\r\n\t?>\r\n\t\r\n\t<form method='post' action='<?php $_SERVER[\"REQUEST_URI\"]; ?>'>\r\n\t\t\r\n\t\t<?php\r\n\t\t// save and update options\r\n\t\tif (isset($_POST['update'])) {\r\n\r\n\t\t\tif (!isset($_POST['action_save']) || ! wp_verify_nonce($_POST['action_save'],'nonce_save') ) {\r\n\t\t\t print 'Sorry, your nonce did not verify.';\r\n\t\t\t exit;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$options['currency'] =\t\t\tintval($_POST['currency']);\r\n\t\t\tif (!$options['currency']) { \t$options['currency'] = \"25\"; }\r\n\t\t\t\t\r\n\t\t\t$options['language'] = \t\t\tintval($_POST['language']);\r\n\t\t\tif (!$options['language']) { \t$options['language'] = \"3\";\t}\r\n\t\t\t\t\r\n\t\t\t$options['testmode'] = \t\t\t\tintval($_POST['testmode']);\r\n\t\t\tif (!$options['testmode']) { \t\t$options['testmode'] = \"1\";\t}\r\n\t\t\t\t\t\t\r\n\t\t\t$options['xmlMode'] = \tintval($_POST['xmlMode']);\r\n\t\t\tif (!$options['xmlMode']) { \t\t$options['xmlMode'] = \"0\";\t}\r\n\t\t\t\t\t\t\r\n\t\t\t$options['hideBillMode'] = \tintval($_POST['hideBillMode']);\r\n\t\t\tif (!$options['hideBillMode']) { \t\t$options['hideBillMode'] = \"0\";\t}\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t$options['size'] = \t\t\t\tintval($_POST['size']);\r\n\t\t\tif (!$options['size']) { \t\t$options['size'] = \"1\";\t}\r\n\t\t\t\t\r\n\t\t\t$options['opens'] = \t\t\tintval($_POST['opens']);\r\n\t\t\tif (!$options['opens']) { \t\t$options['opens'] = \"1\"; }\r\n\t\t\t\t\r\n\t\t\t$options['no_shipping'] = \t\tintval($_POST['no_shipping']);\r\n\t\t\tif (!$options['no_shipping']) { $options['no_shipping'] = \"0\"; }\r\n\t\t\t\r\n\t\t\t$options['content'] = \t\t\tsanitize_text_field($_POST['content']);\r\n\t\t\t$options['hideadmin'] = \t\tsanitize_text_field($_POST['hideadmin']);\r\n\t\t\t$options['subscriber'] = \t\tsanitize_text_field($_POST['subscriber']);\t\t\t\r\n\t\t\t$options['merchant_id'] = \t\tsanitize_text_field($_POST['merchant_id']); \t\t\t\r\n\t\t\t$options['cancelled_text'] = \tsanitize_text_field($_POST['cancelled_text']);\r\n\t\t\t$options['guest_text'] = \t\tsanitize_text_field($_POST['guest_text']);\t\t\t\r\n\t\t\t$options['cancel'] = \t\t\tsanitize_text_field($_POST['cancel']);\r\n\t\t\t$options['return'] = \t\t\tsanitize_text_field($_POST['return']);\r\n\t\t\t$options['log'] = \t\t\t\tsanitize_text_field($_POST['log']);\r\n\t\t\t$options['logging_id'] = \t\tsanitize_text_field($_POST['logging_id']);\r\n\t\t\t$options['uninstall'] = \t\tsanitize_text_field($_POST['uninstall']);\r\n\t\t\t\r\n\t\t\tupdate_option(\"wpeppsubNCX_settingsoptions\", $options);\r\n\t\t\t\r\n\t\t\techo \"<br /><div class='updated'><p><strong>\"; _e(\"Settings Updated.\"); echo \"</strong></p></div>\";\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\tif (isset($_GET['wpeppsubNCX_clear_logs']) && $_GET['wpeppsubNCX_clear_logs'] == \"1\") {\t\t\t\r\n\t\t\tcheck_admin_referer('clear_log');\t\t\t\r\n\t\t\twpeppsubNCX_clear_log();\r\n\t\t\techo'<script>window.location=\"?page=wpeppsubNCX_settings&hidden_tab_value=4\"; </script>';\r\n\t\t\texit;\r\n\t\t}\r\n\t\tif (isset($_GET['wpeppsubNCX_reload_logs']) && $_GET['wpeppsubNCX_reload_logs'] == \"1\") {\t\t\t\r\n\t\t\tcheck_admin_referer('reload');\t\t\t\r\n\t\t\techo'<script>window.location=\"?page=wpeppsubNCX_settings&hidden_tab_value=4\"; </script>';\r\n\t\t\texit;\r\n\t\t}\r\n\t\t\t\t \r\n\t\t$options = get_option('wpeppsubNCX_settingsoptions');\r\n\t\tforeach ($options as $k => $v ) {\r\n\t\t\t\r\n\t\t\t$value[$k] = wp_kses($v, array(\r\n\t\t\t\t\t'a' => array(\r\n\t\t\t\t\t'href' => array(),\r\n\t\t\t\t\t'title' => array()\r\n\t\t\t\t),\r\n\t\t\t\t'br' => array(),\r\n\t\t\t\t'em' => array(),\r\n\t\t\t\t'strong' => array(),\r\n\t\t\t));\t\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\t$siteurl = get_site_url();\r\n\t\t\r\n\t\t// tabs menu\r\n\t\t?>\r\n\t\t\r\n\t\t<table width='100%'><tr><td width='75%' valign='top'><br />\r\n\t\r\n\t\t<table width=\"100%\"><tr><td>\r\n\t\t\t<br />\r\n\r\n\t\t\t<span style=\"font-size:20pt;\">Nochex Settings</span>\r\n\t\t\t</td><td valign=\"bottom\">\r\n\t\t\t<?php echo wp_nonce_field('nonce_save','action_save'); ?>\r\n\t\t\t<input type=\"submit\" name='btn2' class='button-primary' style='font-size: 14px;height: 30px;float: right;' value=\"Save Settings\">\r\n\t\t</td></tr></table>\r\n\t\t\t\r\n\t\t\t<?php\r\n\t\t\tif (isset($saved)) {\r\n\t\t\t\techo \"<div class='updated'><p>Settings Updated.</p></div>\";\r\n\t\t\t}\r\n\t\t\t?>\r\n\t\t\r\n\t\t<?php\r\n\t\t\r\n\t\tif (isset($_REQUEST['hidden_tab_value'])) {\r\n\t\t\t$active_tab = $_REQUEST['hidden_tab_value'];\r\n\t\t} else {\r\n\t\t\t$active_tab = isset( $_GET[ 'tab' ] ) ? $_GET[ 'tab' ] : '1';\r\n\t\t}\r\n\t\t\r\n\t\t// media uploader\r\n\t\tfunction wpplugin_nochex_button_load_scripts() {\r\n\t\t\twp_enqueue_script('media-upload');\r\n\t\t\twp_enqueue_script('thickbox');\r\n\t\t\twp_enqueue_style('thickbox');\r\n\t\t}\r\n\t\twpplugin_nochex_button_load_scripts();\r\n\t\t?>\r\n\r\n\t\t<script>\r\n\t\t\tjQuery(document).ready(function() {\r\n\t\t\t\tvar formfield;\r\n\t\t\t\tjQuery('.upload_image_button').click(function() {\r\n\t\t\t\t\tjQuery('html').addClass('Image');\r\n\t\t\t\t\tformfield = jQuery(this).prev().attr('name');\r\n\t\t\t\t\ttb_show('', 'media-upload.php?type=image&amp;TB_iframe=true');\r\n\t\t\t\t\treturn false;\r\n\t\t\t\t});\r\n\t\t\t\twindow.original_send_to_editor = window.send_to_editor;\r\n\t\t\t\twindow.send_to_editor = function(html){\r\n\t\t\t\t\tif (formfield) {\r\n\t\t\t\t\t\tfileurl = jQuery('img',html).attr('src');\r\n\t\t\t\t\t\tjQuery('#'+formfield).val(fileurl);\r\n\t\t\t\t\t\ttb_remove();\r\n\t\t\t\t\t\tjQuery('html').removeClass('Image');\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\twindow.original_send_to_editor(html);\r\n\t\t\t\t\t}\r\n\t\t\t\t};\r\n\t\t\t});\r\n\t\t</script>\r\n\t\t\r\n\t\t<script type=\"text/javascript\">\r\n\t\t\t\r\n\t\t\twindow.onload = function(){\r\n\t\t\t\r\n\t\t\tvar full_url = document.URL; // Get current url\r\n\t\t\tvar url_array = full_url.split('#') // Split the string into an array with / as separator\r\n\t\t\tvar last_segment = url_array[url_array.length-1]; // Get the last part of the array (-1)\r\n\t\t\t\r\n\t\t\tif(last_segment == \"Started\"){\t\t\t\r\n\t\t\t\tnewtab(\"1\");\r\n\t\t\t\tclosetabs(\"3\");\t\t\t\r\n\t\t\t}else if(last_segment == \"Nochex\"){\r\n\t\t\t\tnewtab(\"3\");\r\n\t\t\t\tclosetabs(\"1\");\t\t\t\r\n\t\t\t}else{\t\t\t\r\n\t\t\t\tnewtab(\"1\");\r\n\t\t\t\tclosetabs(\"3\");\t\t\t\r\n\t\t\t}\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tfunction closetabs(ids) {\r\n\t\t\t\tvar x = ids;\r\n\t\t\t\ty = x.split(\",\");\r\n\t\t\t\t\r\n\t\t\t\tfor(var i = 0; i < y.length; i++) {\r\n\t\t\t\t\t//console.log(y[i]);\r\n\t\t\t\t\tdocument.getElementById(y[i]).style.display = 'none';\r\n\t\t\t\t\tdocument.getElementById(\"id\"+y[i]).classList.remove('nav-tab-active');\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tfunction newtab(id) {\r\n\t\t\t\tvar x = id;\r\n\t\t\t\tdocument.getElementById(x).style.display = 'block';\r\n\t\t\t\tdocument.getElementById(\"id\"+x).classList.add('nav-tab-active');\r\n\t\t\t\tdocument.getElementById('hidden_tab_value').value=x;\r\n\t\t\t}\r\n\t\t</script>\r\n\t\t\r\n\t\t<br />\r\n\r\n\t\t\t<a style='border-bottom:1px solid #ccc' onclick='closetabs(\"3\");newtab(\"1\");' href=\"#Started\" id=\"id1\" class=\"nav-tab <?php echo $active_tab == '1' ? 'nav-tab-active' : ''; ?>\">Information</a>\r\n\t\t\t<a style='border-bottom:1px solid #ccc' onclick='closetabs(\"1\");newtab(\"3\");' href=\"#Nochex\" id=\"id3\" class=\"nav-tab <?php echo $active_tab == '3' ? 'nav-tab-active' : ''; ?>\">Nochex</a>\r\n\t\r\n\t\t<br /><br /><br />\r\n\t\t\r\n\t\t<div id=\"1\" style=\"display:none;border: 1px solid #CCCCCC;<?php echo $active_tab == '1' ? 'display:block;' : ''; ?>\">\r\n\t\t\t<div style=\"background-color:#E4E4E4;padding:8px;color:#000;font-size:15px;color:#464646;font-weight: 700;border-bottom: 1px solid #CCCCCC;\">\r\n\t\t\t\tInformation\r\n\t\t\t</div>\r\n\t\t\t<div style=\"background-color:#fff;padding:8px;\"> \r\n\t\t\t\t<br />\r\n\t\t\t\tThis plugin will allow you to accept credit / debit card payments on your website by Nochex.\r\n\t\t\t<br /><br />\t<img src=\"https://www.nochex.com/logobase-secure-images/logobase-banners/clear.png\" alt=\"Logobase\" style=\"max-width:300px\" />\r\n\t\t\t</div>\r\n\t\t</div>\r\n\t\t\r\n\t\t<div id=\"3\" style=\"display:none;border: 1px solid #CCCCCC;<?php echo $active_tab == '3' ? 'display:block;' : ''; ?>\">\r\n\t\t\t<div style=\"background-color:#E4E4E4;padding:8px;color:#000;font-size:15px;color:#464646;font-weight: 700;border-bottom: 1px solid #CCCCCC;\">\r\n\t\t\t\t&nbsp; Nochex Settings </div>\r\n\t\t\t<div style=\"background-color:#fff;padding:8px;\">\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t<table><tr><td colspan=\"2\"></td></tr><tr><td>\r\n\t\t\t\t\r\n\t\t\t\t<b>Merchant ID:</b> </td><td><input type='text' style=\"width:200px;\" name='merchant_id' value='<?php echo $value['merchant_id']; ?>'> Required </td></tr>\r\n\t\t\t\t<tr><td></td><td colspan=\"2\"></td></tr>\r\n\t\t\t\t\r\n\t\t\t\t<tr><td colspan=\"2\">\r\n\t\t\t\t\r\n\t\t\t\t<br />\r\n\t\t\t\t\r\n\t\t\t\t<h3>Options</h3></td></tr><tr><td>\r\n\t\t\t\t\r\n\t\t\t\t<b>Test Mode:</b> </td><td>\r\n\t\t\t\t&nbsp; &nbsp; <input <?php if ($value['testmode'] == \"1\") { echo \"checked='checked'\"; } ?> type='radio' name='testmode' value='1'>On (Test mode)\r\n\t\t\t\t&nbsp; &nbsp; &nbsp;<input <?php if ($value['testmode'] == \"2\") { echo \"checked='checked'\"; } ?> type='radio' name='testmode' value='2'>Off (Live mode)\r\n\t\t\t\t\r\n\t\t\t\t</td></tr> \r\n\t\t\t\t\r\n\t\t\t\t<tr><td>\t\t\t\t\r\n\t\t\t\t<b>Payment Page - Detailed Information:</b> </td><td>\r\n\t\t\t\t&nbsp; &nbsp; <input <?php if ($value['xmlMode'] == \"1\") { echo \"checked='checked'\"; } ?> type='radio' name='xmlMode' value='1'>Yes\r\n\t\t\t\t&nbsp; &nbsp; &nbsp;<input <?php if ($value['xmlMode'] == \"2\") { echo \"checked='checked'\"; } ?> type='radio' name='xmlMode' value='2'>No\r\n\t\t\t\t&nbsp; &nbsp; &nbsp; A setting of 'Yes' will show a table structured format on your Nochex payment page.\t\t\t\r\n\t\t\t\t</td></tr>\r\n\t\t\t\t\r\n\t\t\t\t<tr><td>\t\t\t\t\r\n\t\t\t\t<b>Hide Billing Details:</b> </td><td>\r\n\t\t\t\t&nbsp; &nbsp; <input <?php if ($value['hideBillMode'] == \"1\") { echo \"checked='checked'\"; } ?> type='radio' name='hideBillMode' value='1'>Yes\r\n\t\t\t\t&nbsp; &nbsp; &nbsp;<input <?php if ($value['hideBillMode'] == \"2\") { echo \"checked='checked'\"; } ?> type='radio' name='hideBillMode' value='2'>No\r\n\t\t\t\t&nbsp; &nbsp; &nbsp; A setting of 'Yes' will hide the billing address details. Note: You must have Extra Details enabled in order for this to work.\r\n\t\t\t\t</td></tr>\r\n\t\t\t\t\r\n\t\t\t\t</table>\r\n\t\t\t\t\r\n\t\t\t\t<br /><br />\r\n\t\t\t</div>\r\n\t\t</div>\r\n\t\t\r\n\t\t<input type='hidden' name='update'>\r\n\t\t<input type='hidden' name='hidden_tab_value' id=\"hidden_tab_value\" value=\"<?php echo $active_tab; ?>\">\r\n\t\t\r\n\t</form>\r\n\t\r\n\t</td></tr></table>\r\n\t\r\n\t<?php\r\n\t\r\n}", "title": "" }, { "docid": "79b65c098e67b15329067eadb4d4ac5e", "score": "0.56625676", "text": "function mt_settings_page() {\n\n\n //must check that the user has the required capability \n if (!current_user_can('manage_options'))\n {\n wp_die( __('You do not have sufficient permissions to access this page.') );\n }\n\n // variables for the field and option names \n $opt_name = 'mt_alive_username';\n $hidden_field_name = 'mt_submit_hidden';\n $data_field_name = 'mt_alive_username';\n\n // Read in existing option value from database\n $opt_val = get_option( $opt_name );\n\n // See if the user has posted us some information\n // If they did, this hidden field will be set to 'Y'\n if( isset($_POST[ $hidden_field_name ]) && $_POST[ $hidden_field_name ] == 'Y' ) {\n // Read their posted value\n $opt_val = $_POST[ $data_field_name ];\n\n$alive_url=\"http://\".$opt_val.\".alive.io/interface/xml\";\n\n\n$xml = getXMLfromURL($alive_url);\nif($xml)\n{\n$result = $xml->value[0];\n}\nif($xml && $result != -1)\n{\n \n \n // Save the posted value in the database\n update_option( $opt_name, $opt_val );\t\n\n // echo $alive_url.\" url exist\"\n\n // Put an settings updated message on the screen\n\n?>\n<div class=\"updated\"><p><strong><?php _e('Your username has been linked! Your alive.io widget is now live!', 'menu-alive.io' ); ?></strong></p></div>\n<?php\n}else\n{\n\n//echo \"You have not registered with alive.io yet.\";\n$opt_val = \"\";\nupdate_option( $opt_name, $opt_val );\n?>\n<div class=\"updated\"><p><strong><?php _e('We couldn\\'t link the username you entered to alive.io =(. Maybe you haven\\'t <a href=\"http://www.alive.io/user/new\" target=\"_blank\">registered</a>?', 'menu-alive.io' ); ?></strong></p></div>\n<?php\n}\n\n}\n\n // Now display the settings editing screen\n\n echo '<div class=\"wrap\">';\n\n // header\n\n echo \"<h2>\" . __( 'Alive.io Settings', 'menu-alive.io' ) . \"</h2>\";\n // settings form\n ?>\n\n<h1> Welcome to Alive.IO </h1>\n<h2> Ever wondered how will your viewers know if you pass away?</h2>\n<h2> Let <a href=\"http://www.alive.io\" target=\"_blank\">Alive.IO</a> help you keep your online identity on par with your real one.</h2>\n<h2> Three simple steps to put your alive.io status on your blog! </h2>\n<h3> 1. Put your <a href=\"http://www.alive.io\" target=\"_blank\">Alive.IO</a> username below.<br> \n 2. Go to Apearance->Widgets and pull in the alive.io widget to your widget area. <br> \n 3. In Widget Options Set the messages you want to display while alive or deceased.</h3>\n<h3>\n<form name=\"form1\" method=\"post\" action=\"\">\n<input type=\"hidden\" name=\"<?php echo $hidden_field_name; ?>\" value=\"Y\">\n\n<p><?php _e(\"Username:\", 'menu-alive.io' ); ?> \n<input type=\"text\" name=\"<?php echo $data_field_name; ?>\" value=\"<?php echo $opt_val; ?>\" size=\"20\">\n<input type=\"submit\" name=\"submit\" class=\"button-primary\" value=\"<?php esc_attr_e('Save') ?>\" /> <br>\nDon't have an <a href=\"http://www.alive.io\" target=\"_blank\">Alive.IO</a> username?<a href=\"http://www.alive.io/\" target=\"_blank\">Register now!!</a>\n</p>\n</form>\n</h3>\n</div>\n<?php\n}", "title": "" }, { "docid": "cba0ae3e33c0bea51489dd5a2c376416", "score": "0.56585073", "text": "function adminInit(){\r\n\t\tregister_setting('bottledBugOptions', 'bottledMainSettings', array($this, 'validateOptions'));\r\n\t\tadd_settings_section('bottled_main', 'Main Settings', array($this,'plugin_section_text'), 'bottledMainOptions'); \r\n\t\tadd_settings_field('plugin_text_string', 'Plugin Text Input', array($this,'plugin_setting_string'), 'bottledMainOptions', 'bottled_main');\r\n\t}", "title": "" }, { "docid": "362c2114e9263b75d15f86d00fc23c13", "score": "0.56562644", "text": "function get_settings_fields() {\n $settings_fields = array(\n 'wp_brander_favicons' => array(\n array(\n 'name' => 'text_val',\n 'label' => __( 'Text Input (integer validation)', 'wedevs' ),\n 'desc' => __( 'Text input description', 'wedevs' ),\n 'type' => 'text',\n 'default' => 'Title',\n 'sanitize_callback' => 'intval'\n ),\n array(\n 'name' => 'textarea',\n 'label' => __( 'Textarea Input', 'wedevs' ),\n 'desc' => __( 'Textarea description', 'wedevs' ),\n 'type' => 'textarea'\n ),\n array(\n 'name' => 'checkbox',\n 'label' => __( 'Checkbox', 'wedevs' ),\n 'desc' => __( 'Checkbox Label', 'wedevs' ),\n 'type' => 'checkbox'\n ),\n array(\n 'name' => 'radio',\n 'label' => __( 'Radio Button', 'wedevs' ),\n 'desc' => __( 'A radio button', 'wedevs' ),\n 'type' => 'radio',\n 'options' => array(\n 'yes' => 'Yes',\n 'no' => 'No'\n )\n ),\n array(\n 'name' => 'multicheck',\n 'label' => __( 'Multile checkbox', 'wedevs' ),\n 'desc' => __( 'Multi checkbox description', 'wedevs' ),\n 'type' => 'multicheck',\n 'options' => array(\n 'one' => 'One',\n 'two' => 'Two',\n 'three' => 'Three',\n 'four' => 'Four'\n )\n ),\n array(\n 'name' => 'selectbox',\n 'label' => __( 'A Dropdown', 'wedevs' ),\n 'desc' => __( 'Dropdown description', 'wedevs' ),\n 'type' => 'select',\n 'default' => 'no',\n 'options' => array(\n 'yes' => 'Yes',\n 'no' => 'No'\n )\n ),\n array(\n 'name' => 'password',\n 'label' => __( 'Password', 'wedevs' ),\n 'desc' => __( 'Password description', 'wedevs' ),\n 'type' => 'password',\n 'default' => ''\n ),\n array(\n 'name' => 'file',\n 'label' => __( 'File', 'wedevs' ),\n 'desc' => __( 'File description', 'wedevs' ),\n 'type' => 'file',\n 'default' => ''\n )\n ),\n 'wp_brander_login' => array(\n array(\n 'name' => 'text',\n 'label' => __( 'Text Input', 'wedevs' ),\n 'desc' => __( 'Text input description', 'wedevs' ),\n 'type' => 'text',\n 'default' => 'Title'\n ),\n array(\n 'name' => 'textarea',\n 'label' => __( 'Textarea Input', 'wedevs' ),\n 'desc' => __( 'Textarea description', 'wedevs' ),\n 'type' => 'textarea'\n ),\n array(\n 'name' => 'checkbox',\n 'label' => __( 'Checkbox', 'wedevs' ),\n 'desc' => __( 'Checkbox Label', 'wedevs' ),\n 'type' => 'checkbox'\n ),\n array(\n 'name' => 'radio',\n 'label' => __( 'Radio Button', 'wedevs' ),\n 'desc' => __( 'A radio button', 'wedevs' ),\n 'type' => 'radio',\n 'default' => 'no',\n 'options' => array(\n 'yes' => 'Yes',\n 'no' => 'No'\n )\n ),\n array(\n 'name' => 'multicheck',\n 'label' => __( 'Multile checkbox', 'wedevs' ),\n 'desc' => __( 'Multi checkbox description', 'wedevs' ),\n 'type' => 'multicheck',\n 'default' => array('one' => 'one', 'four' => 'four'),\n 'options' => array(\n 'one' => 'One',\n 'two' => 'Two',\n 'three' => 'Three',\n 'four' => 'Four'\n )\n ),\n array(\n 'name' => 'selectbox',\n 'label' => __( 'A Dropdown', 'wedevs' ),\n 'desc' => __( 'Dropdown description', 'wedevs' ),\n 'type' => 'select',\n 'options' => array(\n 'yes' => 'Yes',\n 'no' => 'No'\n )\n ),\n array(\n 'name' => 'password',\n 'label' => __( 'Password', 'wedevs' ),\n 'desc' => __( 'Password description', 'wedevs' ),\n 'type' => 'password',\n 'default' => ''\n ),\n array(\n 'name' => 'file',\n 'label' => __( 'File', 'wedevs' ),\n 'desc' => __( 'File description', 'wedevs' ),\n 'type' => 'file',\n 'default' => ''\n )\n )\n );\n \n return $settings_fields;\n }", "title": "" }, { "docid": "7769518884e6787cbb15d9abc0418541", "score": "0.5651853", "text": "function process_momapix_default_value() {\nif ( !current_user_can( 'manage_options' ) )\nwp_die( 'Not allowed' );\n// Check that nonce field created in configuration form\n// is present\ncheck_admin_referer( 'momapix' );\n// Retrieve original plugin options array\n$options = get_option( 'momapix_default_value' );\n// Cycle through all text form fields and store their values\n// in the options array\nforeach ( array( 'momapix_account','momapix_api_key' ) as $option_name ) {\nif ( isset( $_POST[$option_name] ) ) {\n$options[$option_name] =\nsanitize_text_field( $_POST[$option_name] );\n}\n}\n\n// Store updated options array to database\n\nupdate_option( 'momapix_default_value', $options );\n// Redirect the page to the configuration form that was\n// processed\nwp_redirect( add_query_arg(\narray( 'page' => 'momapixpage',\n'message' => '1' ),\nadmin_url( 'options-general.php' ) ) );\nexit;\n}", "title": "" }, { "docid": "3e0b249a265484eeaa7da8f5753be0c5", "score": "0.5646476", "text": "function _update_options($options) {\r\n\t\tif (!is_array($this->_options) && empty($this->_options)) {\r\n\t\t\tif ($this->_get_options() === FALSE) { return FALSE; }\r\n\t\t}\r\n\r\n\t\tif (is_array($options) && !empty($options)) {\r\n\t\t\tforeach ($this->_options as $option_id => $option_values) {\r\n\t\t\t\tif (isset($options[$option_id])) {\r\n\t\t\t\t\t$this->_options[$option_id]['value'] = $options[$option_id];\r\n\t\t\t\t} elseif (!isset($options[$option_id]) && $option_values['type'] == 'checkbox') {\r\n\t\t\t\t\tif (is_array($this->__meta_boxes[$options['__page_id']]) && !empty($this->__meta_boxes[$options['__page_id']])) {\r\n\t\t\t\t\t\tforeach ($this->__meta_boxes[$options['__page_id']] as $context) {\r\n\t\t\t\t\t\t\tforeach ($context as $box) {\r\n\t\t\t\t\t\t\t\t$box_options = explode(',', $box['options']);\r\n\t\t\t\t\t\t\t\tif (array_search($option_id, $box_options) !== FALSE) {\r\n\t\t\t\t\t\t\t\t\t$this->_options[$option_id]['value'] = FALSE;\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (is_array($options['widget-id']) && !empty($options['widget-id'])) {\r\n\t\t\t\t\t\tforeach ($options['widget-id'] as $widget_id) {\r\n\t\t\t\t\t\t\tif (is_array($this->__meta_boxes[$widget_id]) && !empty($this->__meta_boxes[$widget_id])) {\r\n\t\t\t\t\t\t\t\tforeach ($this->__meta_boxes[$widget_id] as $context) {\r\n\t\t\t\t\t\t\t\t\tforeach ($context as $box) {\r\n\t\t\t\t\t\t\t\t\t\t$box_options = explode(',', $box['options']);\r\n\t\t\t\t\t\t\t\t\t\tif (array_search($option_id, $box_options) !== FALSE) {\r\n\t\t\t\t\t\t\t\t\t\t\t$this->_options[$option_id]['value'] = FALSE;\r\n\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn update_option($this->__plugin_folder, $this->_options);\r\n\t\t} else { return FALSE; }\r\n\t}", "title": "" }, { "docid": "9c93b18b43a45b7d28834a95a259914e", "score": "0.5645052", "text": "function quiz_master_install()\r\n{\r\n\r\n\t$data = \"Name\";\r\n\tif ( ! get_option('quiz_master_from_name'))\r\n\t{\r\n\t\tadd_option('quiz_master_from_name');\r\n\t}\r\n\t\r\n\t$data = \"Email Address\";\r\n\tif ( ! get_option('quiz_master_from_address'))\r\n\t{\r\n\t\tadd_option('quiz_master_from_address');\r\n\t}\r\n\t\r\n\t$data = true;\r\n\tif ( ! get_option('quiz_master_are_correct'))\r\n\t{\r\n\t\tadd_option('quiz_master_are_correct' , $data);\r\n \t}\r\n\t\r\n\t$data = false;\r\n\tif ( ! get_option('quiz_master_show_quiz_email'))\r\n\t{\r\n\t\tadd_option('quiz_master_show_quiz_email' , $data);\r\n \t}\r\n\t\r\n\t$data = false;\r\n\tif ( ! get_option('quiz_master_use_points'))\r\n\t{\r\n\t\tadd_option('quiz_master_use_points' , $data);\r\n \t}\r\n\t\r\n\t$data = 0;\r\n\tif ( ! get_option('quiz_master_table_width'))\r\n\t{\r\n\t\tadd_option('quiz_master_table_width' , $data);\r\n \t}\r\n\t\r\n\t$data = 0;\r\n\tif ( ! get_option('quiz_master_quiz_views'))\r\n\t{\r\n\t\tadd_option('quiz_master_quiz_views' , $data);\r\n \t}\r\n\t\r\n\t$data = 0;\r\n\tif ( ! get_option('quiz_master_quiz_taken'))\r\n\t{\r\n\t\tadd_option('quiz_master_quiz_taken' , $data);\r\n \t}\r\n\t\r\n\t$data = false;\r\n\tif ( ! get_option('quiz_master_show_correct'))\r\n\t{\r\n\t\tadd_option('quiz_master_show_correct' , $data);\r\n \t}\r\n\t\r\n\t$data = true;\r\n\tif ( ! get_option('quiz_master_show_name'))\r\n\t{\r\n\t\tadd_option('quiz_master_show_name' , $data);\r\n \t} \r\n\t\r\n\t$data = true;\r\n\tif ( ! get_option('quiz_master_require_name'))\r\n\t{\r\n\t\tadd_option('quiz_master_require_name' , $data);\r\n \t}\r\n\r\n\t$data = false;\r\n\tif ( ! get_option('quiz_master_show_business'))\r\n\t{\r\n\t\tadd_option('quiz_master_show_business' , $data);\r\n \t} \t\r\n\t\r\n\t$data = false;\r\n\tif ( ! get_option('quiz_master_require_business'))\r\n\t{\r\n\t\tadd_option('quiz_master_require_business' , $data);\r\n \t} \r\n\t\r\n\t$data = true;\r\n\tif ( ! get_option('quiz_master_show_email'))\r\n\t{\r\n\t\tadd_option('quiz_master_show_email' , $data);\r\n \t} \r\n\t\r\n\t$data = true;\r\n\tif ( ! get_option('quiz_master_require_email'))\r\n\t{\r\n\t\tadd_option('quiz_master_require_email' , $data);\r\n \t} \r\n\t\r\n\t$data = false;\r\n\tif ( ! get_option('quiz_master_show_phone_number'))\r\n\t{\r\n\t\tadd_option('quiz_master_show_phone_number' , $data);\r\n \t} \r\n\t\r\n\t$data = false;\r\n\tif ( ! get_option('quiz_master_require_phone_number'))\r\n\t{\r\n\t\tadd_option('quiz_master_require_email' , $data);\r\n \t} \r\n\t\r\n\t$data = true;\r\n\tif ( ! get_option('quiz_master_send_user_email'))\r\n\t{\r\n\t\tadd_option('quiz_master_send_user_email' , $data);\r\n \t}\r\n\t\r\n\t$data = \"Thank you for testing the Quiz Master\";\r\n\tif ( ! get_option('quiz_master_user_email_message'))\r\n\t{\r\n\t\tadd_option('quiz_master_user_email_message' , $data);\r\n \t}\r\n\r\n\t$data = false;\r\n\tif ( ! get_option('quiz_master_send_admin_email'))\r\n\t{\r\n\t\tadd_option('quiz_master_send_admin_email' , $data);\r\n \t}\r\n\r\n\t$data = \"\";\r\n\tif ( ! get_option('quiz_master_admin_email'))\r\n\t{\r\n\t\tadd_option('quiz_master_admin_email' , $data);\r\n \t}\r\n\r\n\t$data = \"Please take the quiz below:\";\r\n\tif ( ! get_option('quiz_master_quiz_above_message'))\r\n\t{\r\n\t\tadd_option('quiz_master_quiz_above_message' , $data);\r\n \t}\r\n\t\r\n\t$data = \"Enter Completion Text Here\";\r\n\tif ( ! get_option('quiz_master_completion_message'))\r\n\t{\r\n\t\tadd_option('quiz_master_completion_message' , $data);\r\n \t}\r\n\t\r\n\t$data = true;\r\n\tif ( ! get_option('quiz_master_display_order'))\r\n\t{\r\n\t\tadd_option('quiz_master_display_order' , $data);\r\n \t} \r\n\r\n\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_0'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_0' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_0' , $data);\r\n\t}\r\n\t\r\n\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_1'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_1' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_1' , $data);\r\n\t}\r\n\t\r\n\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_2'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_2' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_2' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_3'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_3' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_3' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_4'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_4' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_4' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_5'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_5' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_5' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_6'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_6' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_6' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_7'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_7' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_7' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_8'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_8' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_8' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_9'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_9' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_9' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_10'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_10' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_10' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_11'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_11' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_11' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_12'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_12' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_12' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_13'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_13' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_13' , $data);\r\n\t}\r\n\t\r\n\t\t$data = 1;\r\n\tif ( ! get_option('quiz_master_question_amount_14'))\r\n\t{\r\n\t\tadd_option('quiz_master_question_amount_14' , $data);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_question_amount_14' , $data);\r\n\t}\r\n\t\r\n\t$data = \"#000000\";\r\n\tif ( ! get_option('quiz_master_font_color'))\r\n\t{\r\n\t\tadd_option('quiz_master_font_color' , $data);\r\n \t}\r\n\t\r\n\t$data = array(0,0,0,0,0,0,0,0,0,0,0);\r\n\tif ( ! get_option('quiz_master_stats'))\r\n\t{\r\n\t\tadd_option('quiz_master_stats' , $data);\r\n \t}\r\n\t\r\n\t\r\n\t$data = \"Enter In Your Questions and Answers\";\r\n\t/*\r\n\t$questions = array\r\n\t(\r\n\t\tarray($data,$data,$data,$data,$data),\r\n\t\tarray($data,$data,$data,$data,$data),\r\n\t\tarray($data,$data,$data,$data,$data)\r\n\t);\r\n\t*/\r\n\t$questions = array\r\n\t(\r\n\t\t\tarray\r\n\t\t\t(\r\n\t\t\t\t$data,\r\n\t\t\t\tarray($data,true,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data)\r\n\t\t\t),\r\n\t\t\tarray\r\n\t\t\t(\r\n\t\t\t\t$data,\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,true,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data)\r\n\t\t\t),\r\n\t\t\tarray\r\n\t\t\t(\r\n\t\t\t\t$data,\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data)\r\n\t\t\t),\r\n\t\t\tarray\r\n\t\t\t(\r\n\t\t\t\t$data,\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data)\r\n\t\t\t),\r\n\t\t\tarray\r\n\t\t\t(\r\n\t\t\t\t$data,\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data)\r\n\t\t\t),\r\n\t\t\tarray\r\n\t\t\t(\r\n\t\t\t\t$data,\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data)\r\n\t\t\t),\r\n\t\t\tarray\r\n\t\t\t(\r\n\t\t\t\t$data,\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data)\r\n\t\t\t),\r\n\t\t\tarray\r\n\t\t\t(\r\n\t\t\t\t$data,\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data),\r\n\t\t\t\tarray($data,false,$data)\r\n\t\t\t)\r\n\t);\r\n\tif ( ! get_option('quiz_master_questions_0'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_0' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_0' , $questions);\r\n\t}\r\n\t\t\r\n\tif ( ! get_option('quiz_master_questions_1'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_1' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_1' , $questions);\r\n\t}\r\n\t\r\n\tif ( ! get_option('quiz_master_questions_2'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_2' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_2' , $questions);\r\n\t}\r\n\t\t\r\n\tif ( ! get_option('quiz_master_questions_3'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_3' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_3' , $questions);\r\n\t}\r\n\t\r\n\t\tif ( ! get_option('quiz_master_questions_4'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_4' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_4' , $questions);\r\n\t}\r\n\t\t\r\n\tif ( ! get_option('quiz_master_questions_5'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_5' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_5' , $questions);\r\n\t}\r\n\t\r\n\t\tif ( ! get_option('quiz_master_questions_6'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_6' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_6' , $questions);\r\n\t}\r\n\t\t\r\n\tif ( ! get_option('quiz_master_questions_7'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_7' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_7' , $questions);\r\n\t}\r\n\t\r\n\t\tif ( ! get_option('quiz_master_questions_8'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_8' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_8' , $questions);\r\n\t}\r\n\t\t\r\n\tif ( ! get_option('quiz_master_questions_9'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_9' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_9' , $questions);\r\n\t}\r\n\t\r\n\t\tif ( ! get_option('quiz_master_questions_10'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_10' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_10' , $questions);\r\n\t}\r\n\t\t\r\n\tif ( ! get_option('quiz_master_questions_11'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_11' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_11' , $questions);\r\n\t}\r\n\t\r\n\t\tif ( ! get_option('quiz_master_questions_12'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_12' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_12' , $questions);\r\n\t}\r\n\t\t\r\n\tif ( ! get_option('quiz_master_questions_13'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_13' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_13' , $questions);\r\n\t}\r\n\t\r\n\t\tif ( ! get_option('quiz_master_questions_14'))\r\n\t{\r\n\t\tadd_option('quiz_master_questions_14' , $questions);\r\n \t}\r\n\telse\r\n\t{\r\n\t\tupdate_option('quiz_master_questions_14' , $questions);\r\n\t}\r\n}", "title": "" }, { "docid": "818b6db8233d4412c4e8a697c2041ff2", "score": "0.56401825", "text": "function optionsframework_admin_init()\r\r\n{\r\r\n // Rev up the Options Machine\r\r\n global $of_options, $options_machine;\r\r\n $options_machine = new Options_Machine($of_options);\r\r\n\r\r\n\r\r\n //if reset is pressed->replace options with defaults\r\r\n if (isset($_REQUEST['page']) && $_REQUEST['page'] == 'optionsframework') {\r\r\n if (isset($_REQUEST['of_reset']) && 'reset' == $_REQUEST['of_reset']) {\r\r\n\r\r\n $nonce = $_POST['security'];\r\r\n\r\r\n if (!wp_verify_nonce($nonce, 'of_ajax_nonce')) {\r\r\n\r\r\n header('Location: themes.php?page=optionsframework&reset=error');\r\r\n die('Security Check');\r\r\n\r\r\n } else {\r\r\n\r\r\n $defaults = (array)$options_machine->Defaults;\r\r\n update_option(OPTIONS, $defaults);\r\r\n\r\r\n header('Location: themes.php?page=optionsframework&reset=true');\r\r\n die($options_machine->Defaults);\r\r\n }\r\r\n }\r\r\n }\r\r\n}", "title": "" }, { "docid": "f15a56920e471c4f675b5c4ab4341d9a", "score": "0.5639751", "text": "function pk_stt2_admin_upgrade_db(){\n?>\n\t<div class=\"postbox-container\" style=\"width: 98%;\">\n\t\t<div class=\"metabox-holder\">\n\t\t\t<div class=\"meta-box-sortables ui-sortable\">\n\t\t\t\t<div id=\"upgrade_db\" class=\"postbox\">\n\t\t\t\t\t<div class=\"handlediv\" title=\"Click to toggle\">\n\t\t\t\t\t</div>\n\t\t\t\t\t<h3 class=\"hndle\"><span>Database Upgrade for Faster Performance and International Characters Support</span></h3>\n\t\t\t\t\t<div class=\"inside\">\n\t\t\t\t\t\t<form method = \"post\">\n\t\t\t\t\t\t<p>This upgrade will update your current database structure to gain better performance and lower server resources. Backup of your current database will be available on <strong><?php global $wpdb; echo $wpdb->prefix.'stt2_meta_backup'; ?></strong> table.</p>\n\n\t\t\t\t\t\t<p>The possibility for the occurrence of error is very small, <span style=\"color:red\"><i>but it is highly recommended to create a database backup before upgrading</i></span>. Detailed information on <a href=\"http://codex.wordpress.org/Backing_Up_Your_Database\" target=\"_blank\">how to backing up your WordPress database can be found here</a>.</p>\n\t\t\t\t\t\t<p class=\"submit\">\t\t\t\t\t\t\n\t\t\t\t\t\t <input class=\"button-primary\" type = \"submit\" name=\"upgrade_db_structure\" value=\"Upgrade Now\" />\n\t\t\t\t\t\t</p>\t\t\t\t\t\t\n\t\t\t\t\t </form>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</div>\n\t</div>\n\t<?php\n}", "title": "" }, { "docid": "d4b93c2a704cea9b66518c477dcb598d", "score": "0.56362873", "text": "function form_handler() {\n\t\tif ( empty($_POST['action']) )\n\t\t\treturn false;\n\n\t\tcheck_admin_referer($this->nonce);\n\n\t\tforeach ( $this->formdata as $name => $value )\n\t\t\t$new_data[$name] = $_POST[$name];\n\n\t\t$this->formdata = $this->validate($new_data, $this->formdata);\n\n\t\tif ( isset($this->options) )\n\t\t\t$this->options->update($this->formdata);\n\n\t\t$this->admin_msg(__('Settings <strong>saved</strong>.', $this->textdomain));\n\t}", "title": "" }, { "docid": "e19fbe54d8f73671542c3166b91d9e2b", "score": "0.5635685", "text": "function og_admin_settings() {\n $form['og_settings'] = _og_content_types();\n\n $form['og_settings']['group_details'] = array(\n '#type' => 'fieldset',\n '#title' => t('Group details'),\n '#description' => t('The default behavior of new groups.'),\n '#collapsible' => TRUE,\n '#collapsed' => TRUE\n );\n // Groups directory visibility\n $options = array(\n t(\"New groups don't appear in the groups directory. Administrators control the directory exclusively.\"),\n t('New groups always appear in the groups directory.'),\n t('Group creator chooses whether her group appears in the directory. Defaults to <em>in directory</em>.'),\n t('Group creator chooses whether her group appears in the directory. Defaults to <em>not in directory</em>.'),\n );\n $form['og_settings']['group_details']['og_visibility_directory'] = array(\n '#type' => 'radios',\n '#title' => t('Groups directory control'),\n '#default_value' => variable_get('og_visibility_directory', OG_DIRECTORY_CHOOSE_TRUE),\n '#description' => t('Site admins always see the checkbox for adding a group to the <em>groups directory</em>. Note that changing this setting has no effect on existing posts. Re-save those posts to acquire this new setting.'),\n '#options' => $options\n );\n\n // Groups registration visibility.\n $options = array(\n t(\"New groups don't appear on the registration form. Administrators control the form exclusively.\"),\n t('New groups always appear on the registration form.'),\n t('Group creator chooses whether her group appears on the registration form. Defaults to <em>on form</em>.'),\n t('Group creator chooses whether her group appears on the registration form. Defaults to <em>not on form</em>.'),\n );\n $form['og_settings']['group_details']['og_visibility_registration'] = array(\n '#type' => 'radios',\n '#title' => t('Registration form control'),\n '#default_value' => variable_get('og_visibility_registration', OG_REGISTRATION_CHOOSE_FALSE),\n '#description' => t('OG admins always see the checkbox for adding a group to the <em>registration form</em>. Note that changing this setting has no effect on existing posts. Re-save those posts to acquire this new setting.'),\n '#options' => $options\n );\n\n // Audience form element\n $form['og_settings']['group_details']['og_audience'] = array(\n '#type' => 'checkbox',\n '#title' => t('Audience form element'),\n '#default_value' => variable_get('og_audience', TRUE),\n '#description' => t('Show a form element for the user to choose the \"Audience\" of the content. This enables the member to place her post into multiple groups. If unchecked, simplify the user interface by omitting the audience form element and assume the user wants to post into the current group. This simplification only applies to new nodes, and not to edits of existing content. Group administrators always see the audience form element.')\n );\n\n // audience required\n $options = array(t('Optional'), t('Required'));\n $form['og_settings']['group_details']['og_audience_required'] = array(\n '#type' => 'radios',\n '#title' => t('Audience required'),\n '#default_value' => variable_get('og_audience_required', 0),\n '#options' => $options,\n '#description' => t('Do you require that all (non administrator) posts be affiliated with a group? Note that changing this setting will affect existing posts when they are edited.')\n );\n unset($options);\n\n\n return system_settings_form($form);\n}", "title": "" }, { "docid": "3cdbf87e14b3e859390792b433e8512f", "score": "0.5635299", "text": "public function init_form_fields(){\r\n\t\t\t$this->form_fields = array(\r\n\t\t\t\t'enabled' => array(\r\n\t\t\t\t\t'title' \t\t=> __( 'Enable/Disable', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'label' \t=> __( 'Enable MS Midtrans-GoPay', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type' \t=> 'checkbox',\r\n\t\t\t\t\t'description' \t=> '',\r\n\t\t\t\t\t'default' \t=> 'no'\r\n\t\t\t\t),\r\n\t\t\t\t'title' => array(\r\n\t\t\t\t\t'title' \t=> __( 'Title', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type' \t=> 'text',\r\n\t\t\t\t\t'description' \t=> __( 'This controls the title which the user sees during checkout.', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'default' \t=> 'GoPay',\r\n\t\t\t\t\t'desc_tip' \t=> true,\r\n\t\t\t\t),\r\n\t\t\t\t'description' => array(\r\n\t\t\t\t\t'title' \t=> __( 'Description', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type' \t=> 'textarea',\r\n\t\t\t\t\t'description' \t=> __( 'This controls the description which the user sees during checkout.', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'default' \t=> __( 'Pay with GoPay via our super-cool payment gateway.', 'ms-midtrans-gopay' ),\r\n\t\t\t\t),\r\n\t\t\t\t'instructions' => array(\r\n\t\t\t\t\t'title' \t=> __( 'Instructions', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type' \t=> 'textarea_html',\r\n\t\t\t\t\t'description' \t=> __( 'This controls the instructions which the user sees during checkout.', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'default' \t=> __( 'Pay with GoPay via our super-cool payment gateway.', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'desc_tip' \t=> true,\r\n\t\t\t\t),\r\n\t\t\t\t'sandbox_mode' => array(\r\n\t\t\t\t\t'title' \t=> __( 'Sandbox mode', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'label' \t=> __( 'Enable Sandbox Mode', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type' \t=> 'checkbox',\r\n\t\t\t\t\t'description' \t=> __( 'Place the payment gateway in sandbox mode.', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'default' \t=> 'yes',\r\n\t\t\t\t\t'desc_tip' \t=> true,\r\n\t\t\t\t),\r\n\t\t\t\t'merchant_id'\t \t=> array(\r\n\t\t\t\t\t'title'\t\t \t=> __( 'Merchant ID', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type'\t\t \t=> 'text'\t\r\n\t\t\t\t),\r\n\t\t\t\t'client_key' => array(\r\n\t\t\t\t\t'title' \t=> __( 'Client Key', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type' \t=> 'text'\r\n\t\t\t\t),\r\n\t\t\t\t'server_key' => array(\r\n\t\t\t\t\t'title' \t=> __( 'Server Key', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type' \t=> 'text',\r\n\t\t\t\t),\r\n\t\t\t\t'expiry_time' => array(\r\n\t\t\t\t\t'title'\t\t \t=> __( 'Payment Expiry Duration', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type'\t\t \t=> 'number',\r\n\t\t\t\t\t'default'\t \t=> 30,\r\n\t\t\t\t\t'step'\t\t \t=> 1,\r\n\t\t\t\t\t'description' \t=> __( 'If blank default expiry time form Midtrans will be used.', 'ms-midtrans-gopay' )\r\n\t\t\t\t),\r\n\t\t\t\t'expiry_unit' => array(\r\n\t\t\t\t\t'title'\t\t \t=> __( 'Payment Expiry Unit', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type'\t\t \t=> 'select',\r\n\t\t\t\t\t'options'\t \t=> array(\r\n\t\t\t\t\t\t'second' \t=> __( 'Second', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t\t'minute' \t=> __( 'Minute', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t\t'hour'\t \t=> __( 'Hour', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t\t'day'\t \t=> __( 'Day', 'ms-midtrans-gopay' )\r\n\t\t\t\t\t),\r\n\t\t\t\t\t'default'\t \t=> 'minute'\t\t\r\n\t\t\t\t),\r\n\t\t\t\t'callback_url' => array(\r\n\t\t\t\t\t'title' \t=> __( 'Callback URL', 'ms-midtrans-gopay' ),\r\n\t\t\t\t\t'type' \t=> 'text',\r\n\t\t\t\t\t'description' \t=> __( 'If blank default callback will be disabled.', 'ms-midtrans-gopay' )\r\n\t\t\t\t),\r\n\t\t\t\t'notifcation_url' => array(\r\n\t\t\t\t\t'title'\t\t \t\t=> 'Notification URL',\r\n\t\t\t\t\t'type'\t\t \t\t=> 'hidden',\r\n\t\t\t\t\t'custom_attributes' => array(\r\n\t\t\t\t\t\t'disabled' => 'true'\t\r\n\t\t\t\t\t),\r\n\t\t\t\t\t'description' \t\t=> '<code>' . home_url( '/wc-api/ms-midtrans-gopay-status/' ) . '</code><br/>Please make sure permalink already set to %postname%'\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\t}", "title": "" }, { "docid": "be279e445a23b1e1c0d850fbbc62ff9f", "score": "0.5630012", "text": "function nmpl_options() {\n\n\techo '<form method=\"post\" action=\"options.php\" enctype=\"multipart/form-data\" >';\n\tsettings_fields( 'nmpl_option_group' );\n\tdo_settings_sections( 'nmpl_option_group' );?>\n\t\n\t<?php submit_button( 'Save Settings', 'primary', 'nmpl_sub_btn' );\n\techo '<form>';\n}", "title": "" }, { "docid": "19ddec63abb9f14985e5089bcd4adcea", "score": "0.56280905", "text": "function wpcf_admin_general_settings_form()\n{\n $settings = wpcf_get_settings();\n\n $form = array();\n $form['#form']['callback'] = 'wpcf_admin_general_settings_form_submit';\n\n $form['open-table'] = array(\n '#type' => 'markup',\n '#markup' => '<table class=\"form-table\"><tbody>',\n );\n\n $form['images'] = array(\n '#id' => 'add_resized_images_to_library',\n '#name' => 'wpcf_settings[add_resized_images_to_library]',\n '#title' => __('Images', 'wpcf'),\n '#type' => 'checkbox',\n '#label' => __('Add resized images to the media library', 'wpcf'),\n '#description' => __('Types will automatically add the resized images as attachments to the media library.', 'wpcf'),\n '#inline' => true,\n '#default_value' => !empty($settings['add_resized_images_to_library']),\n '#pattern' => '<tr><th scope=\"row\"><TITLE></th><td><ELEMENT><LABEL><DESCRIPTION>',\n );\n $form['images_remote'] = array(\n '#title' => __('Remote Images', 'wpcf'),\n '#id' => 'images_remote',\n '#name' => 'wpcf_settings[images_remote]',\n '#type' => 'checkbox',\n '#label' => __('Allow resizing of remote images', 'wpcf'),\n '#description' => __('Types will try to scale remote images.', 'wpcf'),\n '#inline' => true,\n '#default_value' => !empty($settings['images_remote']),\n '#pattern' => '<br /><ELEMENT><LABEL><DESCRIPTION>',\n );\n $form['images_remote_clear'] = array(\n '#id' => 'images_remote_cache_time',\n '#name' => 'wpcf_settings[images_remote_cache_time]',\n '#type' => 'select',\n '#title' => __('Images cache', 'wpcf'),\n '#pattern' => sprintf(\n '<br />%s',\n __('Invalidate cached images that are more than <ELEMENT> hours old.', 'wpcf')\n ),\n '#options' => array(\n __('Never', 'wpcf') => '0',\n '24' => '24',\n '36' => '36',\n '48' => '48',\n '72' => '72',\n ),\n '#inline' => true,\n '#default_value' => intval($settings['images_remote_cache_time']),\n );\n $form['clear_images_cache'] = array(\n '#type' => 'submit',\n '#name' => 'clear-cache-images',\n '#id' => 'clear-cache-images',\n '#attributes' => array('id' => 'clear-cache-images','class' => 'button-secondary'),\n '#value' => __('Clear Cached Images', 'wpcf'),\n '#inline' => true,\n '#pattern' => '<br /><ELEMENT>',\n );\n $form['clear_images_cache_outdated'] = array(\n '#id' => 'clear-cache-images-outdated',\n '#type' => 'submit',\n '#name' => 'clear-cache-images-outdated',\n '#attributes' => array('id' => 'clear-cache-images-outdated','class' => 'button-secondary'),\n '#value' => __('Clear Outdated Cached Images', 'wpcf'),\n '#inline' => true,\n '#pattern' => ' <ELEMENT></td></tr>',\n );\n\n\n if (function_exists('icl_register_string')) {\n $form['register_translations_on_import'] = array(\n '#id' => 'register_translations_on_import',\n '#name' => 'wpcf_settings[register_translations_on_import]',\n '#type' => 'checkbox',\n '#title' => __('WPML Integration', 'wpcf'),\n '#label' => __(\"When importing, add texts to WPML's String Translation table\", 'wpcf'),\n '#inline' => true,\n '#default_value' => !empty($settings['register_translations_on_import']),\n '#pattern' => '<tr><th scope=\"row\"><TITLE></th><td><ELEMENT><LABEL><DESCRIPTION></td></th>',\n '#inline' => true,\n );\n }\n\n $form['help-box'] = array(\n '#id' => 'help_box',\n '#name' => 'wpcf_settings[help_box]',\n '#type' => 'radios',\n '#options' => array(\n 'all' => array(\n '#value' => 'all',\n '#title' => __(\"Show promotional messages on all custom post editing screens and on all Types create/edit pages\", 'wpcf')\n ),\n 'by_types' => array(\n '#value' => 'by_types',\n '#title' => __(\"Show promotional messages only on post types that were created by Types and on all Types create/edit pages\", 'wpcf')\n ),\n 'no' => array(\n '#value' => 'no',\n '#title' => __(\"Don't show promotional messages anywhere\", 'wpcf')\n ),\n ),\n '#inline' => true,\n '#default_value' => $settings['help_box'],\n '#pattern' => '<tr><th scope=\"row\"><TITLE></th><td><ELEMENT><DESCRIPTION></td></th>',\n '#title' => __('Help Box', 'wpcf'),\n );\n\n $form['hide_standard_custom_fields_metabox'] = array(\n '#id' => 'hide_standard_custom_fields_metabox',\n '#name' => 'wpcf_settings[hide_standard_custom_fields_metabox]',\n '#type' => 'radios',\n '#options' => array(\n 'all' => array(\n '#value' => 'show',\n '#title' => __('Show standard WordPress Custom Field Metabox', 'wpcf')\n ),\n 'by_types' => array(\n '#value' => 'hide',\n '#title' => __('Hide standard WordPress Custom Field Metabox', 'wpcf')\n ),\n ),\n '#inline' => true,\n '#default_value' => preg_match('/^(show|hide)$/', $settings['hide_standard_custom_fields_metabox'])? $settings['hide_standard_custom_fields_metabox']:'show',\n '#title' => __('Custom Field Metabox', 'wpcf'),\n '#pattern' => '<tr><th scope=\"row\"><TITLE></th><td><ELEMENT><DESCRIPTION></td></th>',\n );\n\n /* This is obsolete with our new way to handle these messages (see types-508)\n if ( !WPCF_Types_Marketing_Messages::check_register() ) {\n $form['toolset_messages'] = array(\n '#id' => 'toolset_messages',\n '#name' => 'wpcf_settings[toolset_messages]',\n '#type' => 'checkbox',\n '#label' => __('Disable all messages about other Toolset components', 'wpcf'),\n '#default_value' => isset($settings['toolset_messages'])? intval($settings['toolset_messages']):0,\n '#title' => __('Toolset Messages', 'wpcf'),\n '#pattern' => '<tr><th scope=\"row\"><TITLE></th><td><ELEMENT><LABEL><DESCRIPTION></td></th>',\n '#inline' => true,\n );\n }\n */\n\n $form['postmeta-unfiltered-html'] = array(\n '#id' => 'postmeta_unfiltered_html',\n '#name' => 'wpcf_settings[postmeta_unfiltered_html]',\n '#type' => 'radios',\n '#title' => __('Custom fields - unfiltered HTML', 'wpcf'),\n '#options' => array(\n 'on' => array(\n '#value' => 'on',\n '#title' => __('Allow saving unfiltered HTML in Types custom fields for users with higher roles', 'wpcf'),\n ),\n 'off' => array(\n '#value' => 'off',\n '#title' => __('Disallow saving unfiltered HTML in Types custom fields for all users', 'wpcf'),\n ),\n ),\n '#inline' => false,\n '#default_value' => $settings['postmeta_unfiltered_html'],\n '#pattern' => '<tr><th scope=\"row\"><TITLE></th><td><ELEMENT><DESCRIPTION></td></th>',\n );\n $form['usermeta-unfiltered-html'] = array(\n '#id' => 'usermeta_unfiltered_html',\n '#name' => 'wpcf_settings[usermeta_unfiltered_html]',\n '#type' => 'radios',\n '#title' => __('Usermeta fields - unfiltered HTML', 'wpcf'),\n '#options' => array(\n 'on' => array(\n '#value' => 'on',\n '#title' => __(\"Allow saving unfiltered HTML in Types usermeta fields for users with higher roles\", 'wpcf'),\n ),\n 'off' => array(\n '#value' => 'off',\n '#title' => __(\"Disallow saving unfiltered HTML in Types usermeta fields for all users\", 'wpcf')\n ),\n ),\n '#inline' => false,\n '#default_value' => $settings['usermeta_unfiltered_html'],\n '#pattern' => '<tr><th scope=\"row\"><TITLE></th><td><ELEMENT><DESCRIPTION></td></th>',\n );\n\n $form['open-close'] = array(\n '#type' => 'markup',\n '#markup' => '</tbody></table>',\n );\n\n $form['submit'] = array(\n '#type' => 'submit',\n '#name' => 'submit',\n '#attributes' => array('id'=>'general-settings-submit','class' => 'button-primary'),\n '#value' => __('Save Changes', 'wpcf'),\n );\n return $form;\n}", "title": "" }, { "docid": "9c54943071770039d3df172ddda885ff", "score": "0.56239396", "text": "function pk_stt2_admin_print_admin_page(){\n\t$options = get_option('pk_stt2_settings');\t\n\t$auto_cleanup = intval( get_option ( 'pk_stt2_auto_cleanup' ) );\n\t$auto_cleanup = ( 0 == $auto_cleanup ) ? PK_AUTO_CLEANUP : $auto_cleanup;\t\n\t$promote_old_post = get_option('pk_stt2_promote_old_post');\n\t$badwords = get_option('pk_stt2_badwords');\n\tif ( empty($badwords) ){\n\t $badwords = PK_BADWORDS;\n update_option ( 'pk_stt2_badwords', trim( $badwords,' ,.' ) );\t\n };\n\t?>\n\t<div class=\"postbox-container\" style=\"width: 74%;\">\n\t\t<div class=\"metabox-holder\">\n\t\t\t<div class=\"meta-box-sortables ui-sortable\"> \t\t\n\t\t\t\t<div id=\"stt2settings\" class=\"postbox\">\n\t\t\t\t\t<div class=\"handlediv\" title=\"Click to toggle\">\n\t\t\t\t\t\t<br/>\n\t\t\t\t\t</div>\n\t\t\t\t\t<h3 class=\"hndle\">\n\t\t\t\t\t\t<span>General Settings ( Widgets has it own settings )</span></h3>\n\t\t\t\t\t<div class=\"inside\">\n\t\t\t\t\t\t<form id=\"stt2-options\" method=\"post\" action=\"\">\n\t\t\t\t\t\t\t<table class=\"stt2-table\">\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td width=\"350px\">\n\t\t\t\t\t\t\t\t\t\t<label> Enabled:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<input type=\"checkbox\" <?php if( 1 == get_option('pk_stt2_enabled') ){ echo 'checked'; }; ?> value=\"1\" name=\"enabled\"/>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td width=\"350px\">\n\t\t\t\t\t\t\t\t\t\t<label> Max number of search terms:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<input type = \"text\" name = \"max\" value = \"<?php echo $options['max']; ?>\" size=\"10\"/>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<label> Text and code for list header:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<input type = \"text\" name = \"list_header\" value = \"<?php echo htmlspecialchars(stripslashes($options['list_header'])); ?>\" size=\"50\"/>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<label> Text and code before and after the list:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td> Before:\n\t\t\t\t\t\t\t\t\t\t<input type = \"text\" name = \"before_list\" value = \"<?php echo htmlspecialchars(stripslashes($options['before_list'])); ?>\" size=\"10\"/> &nbsp;&nbsp;After:\n\t\t\t\t\t\t\t\t\t\t<input type = \"text\" name = \"after_list\" value = \"<?php echo htmlspecialchars(stripslashes($options['after_list'])); ?>\" size=\"10\"/>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<label> Text and code before and after each keyword:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td> Before:\n\t\t\t\t\t\t\t\t\t\t<input type = \"text\" name = \"before_keyword\" value = \"<?php echo htmlspecialchars(stripslashes($options['before_keyword'])); ?>\" size=\"10\"/> &nbsp;&nbsp;After:\n\t\t\t\t\t\t\t\t\t\t<input type = \"text\" name = \"after_keyword\" value = \"<?php echo htmlspecialchars(stripslashes($options['after_keyword'])); ?>\" size=\"10\"/>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td style=\"vertical-align: top;\">\n\t\t\t\t\t\t\t\t\t\t<label> Convert search terms into links:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"auto_link\" value=\"1\" <?php if ( 1 == $options['auto_link'] ){ echo 'checked'; } ;?> /> Yes, link to post content<br />\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"auto_link\" value=\"2\" <?php if ( 2 == $options['auto_link'] ){ echo 'checked'; } ;?> /> Yes, link to search page ( Not Recommended )<br />\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"auto_link\" value=\"0\" <?php if ( 0 == $options['auto_link'] ){ echo 'checked'; } ;?> /> No\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<label> Display search counts for each search term:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"show_count\" value=\"1\" <?php if ( 1 == $options['show_count'] ){ echo 'checked'; } ;?> /> Yes&nbsp;&nbsp;\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"show_count\" value=\"0\" <?php if ( 0 == $options['show_count'] ){ echo 'checked'; } ;?> /> No\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<label> Add list automatically right after post content:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"auto_add\" value=\"1\" <?php if ( 1 == $options['auto_add'] ){ echo 'checked'; } ;?> /> Yes&nbsp;&nbsp;\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"auto_add\" value=\"0\" <?php if ( 0 == $options['auto_add'] ){ echo 'checked'; } ;?> /> No\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<label> Save popular search terms as post tags:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"auto_tag\" value=\"1\" <?php if ( 1 == get_option('pk_stt2_auto_tag') ){ echo 'checked'; } ;?> /> Yes&nbsp;&nbsp;\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"auto_tag\" value=\"0\" <?php if ( 0 == get_option('pk_stt2_auto_tag') ){ echo 'checked'; } ;?> /> No\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<label> Auto clean up unused search terms after:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<input type = \"text\" name = \"auto_cleanup\" value = \"<?php echo $auto_cleanup; ?>\" size=\"10\"/> days ( default is 90 days )\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td valign=\"top\" style=\"padding-top:10px;\">\n\t\t\t\t\t\t\t\t\t\t<label>Block the following bad words:</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<textarea name = \"badwords\" cols=\"55\" rows=\"3\" ><?php echo $badwords; ?></textarea>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<label> Promote old post with no search engine traffic:\n\t\t\t\t\t\t\t\t\t\t</label>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"promote_old_post\" value=\"1\" <?php if ( 1 == $promote_old_post ){ echo 'checked'; } ;?> /> Yes&nbsp;&nbsp;\n\t\t\t\t\t\t\t\t\t\t<Input type=\"radio\" name=\"promote_old_post\" value=\"0\" <?php if ( 0 == $promote_old_post ){ echo 'checked'; } ;?> /> No\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td colspan=2>\n\t\t\t\t\t\t\t\t\t\t<br />\n\t\t\t\t\t\t\t\t\t\t<span class=\"submit\" style=\"margin-top:14px;\">\n\t\t\t\t\t\t\t\t\t\t\t<input class=\"button-primary\" type = \"submit\" name=\"submit\" value=\"Save Changes\" />\n\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t</table>\n\t\t\t\t\t\t</form>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t\t<div id=\"stt2-cleanup\" class=\"postbox\">\n\t\t\t\t\t<div class=\"handlediv\" title=\"Click to toggle\">\n\t\t\t\t\t</div>\n\t\t\t\t\t<h3 class=\"hndle\">\n\t\t\t\t\t\t<span>Auto Clean Up Unused Search Terms:</span></h3>\n\t\t\t\t\t<div class=\"inside\">\n\t\t\t\t\t\t<p><ul style=\"margin: 0pt 0pt 14px 30px; list-style-type: circle;\">\n\t\t\t\t\t\t\t<?php $last_cleanup = get_option('pk_stt2_last_clean_up'); ?>\n\t\t\t\t\t\t\t<li>Last database cleaned up: <?php if (!empty($last_cleanup)) { echo $last_cleanup; } else { echo 'Never'; } ?></li>\n\t\t\t\t\t\t\t<li>Next scheduled database clean up on\n\t\t\t\t\t\t\t<?php echo date('F j, Y, g:i A',wp_next_scheduled('pk_stt2_admin_event_hook')); ?>.</li>\n\t\t\t\t\t\t</ul></p>\n\t\t\t\t\t\t<p>Once a day, we perform database clean up by removing search terms that are never used again within <?php echo $auto_cleanup; ?> days. It is necessary to prevent an excessive use of server resources, especially if you use shared web hosting.</p>\n\t\t\t\t\t\t<p>If your blog has more than a thousand visitors per day, we recommend to reduce the auto clean up setting. You are free to determine when a search term is considered not useful, 7, 15, or 30 days maybe?</p>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t\t<div id=\"stt2-promote-post\" class=\"postbox\">\n\t\t\t\t\t<div class=\"handlediv\" title=\"Click to toggle\">\n\t\t\t\t\t</div>\n\t\t\t\t\t<h3 class=\"hndle\">\n\t\t\t\t\t\t<span>Promote Post With No Search Engine Traffic</span></h3>\n\t\t\t\t\t<div class=\"inside\">\n\t\t\t\t\t\t<p><ul style=\"margin: 0pt 0pt 14px 30px; list-style-type: circle;\">\n\t\t\t\t\t\t\t<?php \n\t\t\t\t\t\t\t\t$wo_traffic = pk_stt2_db_get_number_of_posts_wo_traffic(); \n\t\t\t\t\t\t\t\t$total = pk_stt2_db_get_number_of_posts();\n\t\t\t\t\t\t\t\t$percentage = intval(( $wo_traffic / $total ) * 100); ?>\t\t\n\t\t\t\t\t\t\t<li>Number of posts with no search engine traffic: <?php echo \"$wo_traffic of $total ( $percentage% )\"; ?></li>\n\t\t\t\t\t\t\t<li>Last promoted blog post: <?php pk_stt2_the_last_promoted_post(); ?></li>\n\t\t\t\t\t\t\t<li>Next scheduled promotion on\t<?php echo date('F j, Y, g:i A',wp_next_scheduled('pk_stt2_promote_old_post_event_hook')); ?>.</li>\n\t\t\t\t\t\t</ul></p>\n\t\t\t\t\t\t<p>To ensure that the promoted post get indexed, use free services such as <a href=\"http://twitterfeed.com/\" target=\"_blank\">TwitterFeed</a> to publish your blog feed into social network sites such as Twitter, Facebook, Ping.fm etc.</p>\n\t\t\t\t\t\t<p>As an alternative, you can also use a premium plugin like <a href=\"http://9cab9omg4qgd8r98wbjl1jucfe.hop.clickbank.net/?tid=stt2\" target=\"_blank\">Indexing Tool</a> to make sure that your articles are indexed.</p>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\t\t\t\t\n\t\t\t\t<div id=\"stt2-del\" class=\"postbox\">\n\t\t\t\t\t<div class=\"handlediv\" title=\"Click to toggle\">\n\t\t\t\t\t</div>\n\t\t\t\t\t<h3 class=\"hndle\">\n\t\t\t\t\t\t<span>Delete Search Terms:</span></h3>\n\t\t\t\t\t<div class=\"inside\">\n\t\t\t\t\t\t<form id=\"stt2-delete\" method=\"post\" action=\"\">\n\t\t\t\t\t\t\t<p> Enter the search terms you want to delete, separate them with a comma ( e.g.: keyword1,keyword2 ): </p>\n\t\t\t\t\t\t\t<p><textarea name = \"delete_terms\" cols=\"75\" rows=\"2\" ></textarea></p>\n\t\t\t\t\t\t\t<p>\n\t\t\t\t\t\t\t\t<span class=\"submit\">\n\t\t\t\t\t\t\t\t\t<input type = \"submit\" name=\"delete\" value=\"Delete\" /><br /><br /> &nbsp;&nbsp;&nbsp;OR <br /><br />\n\t\t\t\t\t\t\t\t\t<input type = \"submit\" name=\"delete_all\" value=\"Delete All ( Reset )\" />\n\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t</form>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</div>\n\t</div>\n\t<div class=\"postbox-container\" style=\"width: 25%;\">\n\t\t<div class=\"metabox-holder\">\n\t\t\t<div class=\"meta-box-sortables ui-sortable\">\n\t\t\t\t<div id=\"stt2-donate\" class=\"postbox\">\n\t\t\t\t\t<div class=\"handlediv\" title=\"Click to toggle\">\n\t\t\t\t\t</div>\n\t\t\t\t\t<h3 class=\"hndle\">\n\t\t\t\t\t\t<span>Please Donate to Support Us:\n\t\t\t\t\t\t</span></h3>\n\t\t\t\t\t<div class=\"inside\">\n\t\t\t\t\t\t<div class=\"frame list\">\n\t\t\t\t\t\t\t<?php echo pk_stt2_admin_donate(); ?>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t\t<div id=\"stt2-top\" class=\"postbox\">\n\t\t\t\t\t<div class=\"handlediv\" title=\"Click to toggle\">\n\t\t\t\t\t</div>\n\t\t\t\t\t<h3 class=\"hndle\">\n\t\t\t\t\t\t<span>Popular Search Terms:\n\t\t\t\t\t\t</span></h3>\n\t\t\t\t\t<div class=\"inside\">\n\t\t\t\t\t\t<div class=\"frame list\">\n\t\t\t\t\t\t\t<?php echo pk_stt2_admin_print_searchterms( 'popular' ); ?>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t\t<div id=\"stt2-recent\" class=\"postbox\">\n\t\t\t\t\t<div class=\"handlediv\" title=\"Click to toggle\">\n\t\t\t\t\t</div>\n\t\t\t\t\t<h3 class=\"hndle\">\n\t\t\t\t\t\t<span>Recent Search Terms:\n\t\t\t\t\t\t</span></h3>\n\t\t\t\t\t<div class=\"inside\">\n\t\t\t\t\t\t<div class=\"frame list\">\n\t\t\t\t\t\t\t<?php echo pk_stt2_admin_print_searchterms( 'recent' ); ?>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t\t<div id=\"stt2-mainkeywords\" class=\"postbox\">\n\t\t\t\t\t<div class=\"handlediv\" title=\"Click to toggle\">\n\t\t\t\t\t</div>\n\t\t\t\t\t<h3 class=\"hndle\">\n\t\t\t\t\t\t<span>Popular Home Keywords:\n\t\t\t\t\t\t</span></h3>\n\t\t\t\t\t<div class=\"inside\">\n\t\t\t\t\t\t<div class=\"frame list\">\n\t\t\t\t\t\t\t<?php echo pk_stt2_admin_print_searchterms( 'home' ); ?>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\t\t\t\t\n\t\t\t</div>\n\t\t</div>\n\t</div>\n\t<?php\n}", "title": "" }, { "docid": "1afdac28f152b458d25b92dccea63d27", "score": "0.5623084", "text": "function _pre_update_option( $new_value, $old_value ) {\n /**\n * This only going to be saving one form's worth of data yet the settings can have many forms, like:\n *\n * $settings = array(\n * '_form1' => array( ... ),\n * '_form2' => array( ... ),\n * '_form3' => array( ... ),\n * );\n *\n * So the next 3 lines grab all the old values of the other forms and uses the new values for this form.\n */\n if ( ! isset( $new_value['state'] ) ) {\n $return_value = $new_value;\n } else {\n $return_value = $old_value;\n $settings_key = \"_{$new_value['state']['form']}\";\n $old_value[$settings_key] = $new_value[$settings_key];\n $old_value['state'] = $new_value['state'];\n /**\n * Set the 'decrytped' value to 'true' for the form that is being submitted.\n */\n $old_value['state']['decrypted'][$new_value['state']['form']] = true;\n $this->update_settings( $old_value );\n }\n\n return $return_value;\n }", "title": "" }, { "docid": "b9832a14b7e9e6bec9594d525b5309c0", "score": "0.5622397", "text": "function aa_metabox_options() {\n $titan = TitanFramework::getInstance( 'sportway' );\n \n /**\n * First metabox.\n */\n \n $aa_metbox = $titan->createMetaBox( array(\n 'name' => 'Metabox Options', // Name the options menu.\n 'post_type' => array( 'page'), // Can be a string or array.\n // 'page_template' => 'page-servizi.php',\n 'hide_custom_fields' => true,\n ) );\n\n\n /**\n\t * Create the options for metabox.\n\t *\n\t * Now we will create options for our metabox that we just created called `$aa_metbox`.\n\t */\n\t \n\t$aa_metbox->createOption( array(\n\t 'id' => 'aa_mb_txt', // The id which will be used to get the value of this option.\n\t 'type' => 'text', // Type of option we are creating.\n\t 'name' => 'My Text Option', // Name of the option which will be displayed in the admin panel.\n\t 'desc' => 'This is our option' // Description of the option which will be displayed in the admin panel.\n\t) );\n\n\t\t$aa_metbox->createOption( array(\n\t 'id' => 'aa_mb_txt2', // The id which will be used to get the value of this option.\n\t 'type' => 'text', // Type of option we are creating.\n\t 'name' => 'My Text Option', // Name of the option which will be displayed in the admin panel.\n\t 'desc' => 'This is our option' // Description of the option which will be displayed in the admin panel.\n\t) );\n \n}", "title": "" }, { "docid": "56e75746258917cd2a3821f159d89cd1", "score": "0.56220436", "text": "function xmldb_qtype_digitalliteracy_upgrade($oldversion) {\r\n global $CFG, $DB;\r\n $dbman = $DB->get_manager();\r\n\r\n if ($oldversion < 2020120100) {\r\n // Define field fontparams to be added to qtype_digitalliteracy_option.\r\n $table = new xmldb_table('qtype_digitalliteracy_option');\r\n\r\n $field = new xmldb_field('hastemplatefile', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '0', 'filetypeslist');\r\n // Launch rename field showtemplatefile.\r\n $dbman->rename_field($table, $field, 'showtemplatefile');\r\n\r\n $field = new xmldb_field('fontparams', XMLDB_TYPE_INTEGER, '4', null, XMLDB_NOTNULL, null, '1', 'checkbutton');\r\n // Conditionally launch add field fontparams.\r\n if (!$dbman->field_exists($table, $field)) {\r\n $dbman->add_field($table, $field);\r\n }\r\n\r\n $field = new xmldb_field('grouponecoef', XMLDB_TYPE_INTEGER, '3', null, XMLDB_NOTNULL, null, '100', 'fontparams');\r\n // Launch rename field group1coef.\r\n $dbman->rename_field($table, $field, 'group1coef');\r\n\r\n $field = new xmldb_field('grouptwocoef', XMLDB_TYPE_INTEGER, '3', null, XMLDB_NOTNULL, null, '0', 'group1coef');\r\n // Launch rename field group2coef.\r\n $dbman->rename_field($table, $field, 'group2coef');\r\n\r\n $field = new xmldb_field('groupthreecoef', XMLDB_TYPE_INTEGER, '3', null, XMLDB_NOTNULL, null, '0', 'group2coef');\r\n // Launch rename field group3coef.\r\n $dbman->rename_field($table, $field, 'group3coef');\r\n\r\n $field = new xmldb_field('grouponeparamone', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group3coef');\r\n // Launch rename field group1param1.\r\n $dbman->rename_field($table, $field, 'group1param1');\r\n\r\n $field = new xmldb_field('grouponeparamtwo', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group1param1');\r\n // Launch rename field group1param2.\r\n $dbman->rename_field($table, $field, 'group1param2');\r\n\r\n $field = new xmldb_field('grouponeparamthree', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group1param2');\r\n // Launch rename field group1param3.\r\n $dbman->rename_field($table, $field, 'group1param3');\r\n\r\n $field = new xmldb_field('grouponeparamfour', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group1param3');\r\n // Launch rename field group1param4.\r\n $dbman->rename_field($table, $field, 'group1param4');\r\n\r\n $field = new xmldb_field('grouptwoparamone', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group1param4');\r\n // Launch rename field group2param1.\r\n $dbman->rename_field($table, $field, 'group2param1');\r\n\r\n $field = new xmldb_field('grouptwoparamtwo', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group2param1');\r\n // Launch rename field group2param2.\r\n $dbman->rename_field($table, $field, 'group2param2');\r\n\r\n $field = new xmldb_field('grouptwoparamthree', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group2param2');\r\n // Launch rename field group2param3.\r\n $dbman->rename_field($table, $field, 'group2param3');\r\n\r\n $field = new xmldb_field('grouptwoparamfour', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group2param3');\r\n // Launch rename field group2param4.\r\n $dbman->rename_field($table, $field, 'group2param4');\r\n\r\n $field = new xmldb_field('groupthreeparamone', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group2param4');\r\n // Launch rename field group3param1.\r\n $dbman->rename_field($table, $field, 'group3param1');\r\n\r\n $field = new xmldb_field('groupthreeparamtwo', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group3param1');\r\n // Launch rename field group3param2.\r\n $dbman->rename_field($table, $field, 'group3param2');\r\n\r\n $field = new xmldb_field('groupthreeparamthree', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group3param2');\r\n // Launch rename field group3param3.\r\n $dbman->rename_field($table, $field, 'group3param3');\r\n\r\n $field = new xmldb_field('groupthreeparamfour', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '1', 'group3param3');\r\n // Launch rename field group3param4.\r\n $dbman->rename_field($table, $field, 'group3param4');\r\n\r\n // Digitalliteracy savepoint reached.\r\n upgrade_plugin_savepoint(true, 2020120100, 'qtype', 'digitalliteracy');\r\n }\r\n\r\n return true;\r\n}", "title": "" }, { "docid": "e65e2733e26184d11c9506e328eb9c55", "score": "0.56174916", "text": "function form_shroud_settings_edit_submit($form, $form_state) {\n $shroud_registry = db_select('form_shroud_registry', 'f')->fields('f')->condition('fsid', $form_state['values']['fsid'])->execute()->fetchAssoc();\n $elements = module_invoke_all('shroud_define');\n\n foreach ($elements[$shroud_registry['form_id']]['options'] as $key => $form_element) {\n foreach ($form_element as $machine_name => $property) {\n if (is_array($property)) {\n foreach ($property as $gen => $var) {\n if (is_array($var)) {\n foreach ($var as $key_value => $stored_value) {\n if (is_array($stored_value)) {\n foreach ($stored_value as $another_key => $more_values) {\n if ($form_state['values'][$another_key]) {\n $insert[$machine_name][$gen][$key_value][$another_key] = 1;\n }\n }\n }\n else {\n if ($form_state['values'][$key_value]) {\n $insert[$machine_name][$gen][$key_value] = 1;\n }\n }\n }\n }\n else {\n if ($form_state['values'][$gen]) {\n $insert[$machine_name][$gen] = 1;\n }\n }\n }\n }\n else {\n if ($form_state['values'][$machine_name]) {\n $insert[$machine_name] = 1;\n }\n }\n }\n }\n $settings = (!empty($insert)) ? serialize($insert) : '';\n drupal_set_message(t('The form elements have been shrouded.'));\n db_update('form_shroud_registry')\n ->fields(array('settings' => $settings, 'form_id' => $form_state['values']['form_type']))\n ->condition('fsid', $form_state['values']['fsid'])\n ->execute();\n drupal_goto('admin/config/user-interface/formshroud');\n}", "title": "" }, { "docid": "d0d1ab45491c17d73b9d90da78b70b40", "score": "0.5609215", "text": "function hk_setupMetabox(){\n\tadd_action('add_meta_boxes', 'hk_metabox_fn');\n\t// METABOX CALLBACK\n\tfunction hk_metabox_fn(){\n\t\tadd_meta_box('youyube_video_id', 'Youtube Video ID', 'hk_metabox_ui', 'post', 'side', 'high');\n\t}\n\n\t// CREATE METABOX UI \n\tfunction hk_metabox_ui($post){\n\t\t$hk_sources_youtube = get_post_meta($post->ID, 'hk_sources_youtube', true);\n\t\twp_nonce_field(__FILE__, 'post_video_meta_nonce');\n\t\techo \"<input type='text' class='widefat' id='hk_sources_youtube' name='hk_sources_youtube' value='$hk_sources_youtube'/>\";\n\t\techo \"<br/><br />\";\n\t}\n\n\t// SAVE METABOX\n\tadd_action('save_post', function($post_id){\n\t\tif ( isset( $_POST['hk_sources_youtube'] ) ){\n\t\t\tupdate_post_meta($post_id, 'hk_sources_youtube', $_POST['hk_sources_youtube']);\n\t\t}\n\t});\n}", "title": "" }, { "docid": "08e0804d17cd2154457969d09502e4af", "score": "0.560829", "text": "function update_wysiwyg_general_config()\n {\n $db = DataAccess::getInstance();\n\n //if set to 0, set it to PHP false\n $wysiwyg = ($_POST['use_admin_wysiwyg']) ? $_POST['use_admin_wysiwyg'] : false;\n\n $db->set_site_setting('use_admin_wysiwyg', $wysiwyg);\n $db->set_site_setting('wysiwyg_css_uri', trim($_POST['wysiwyg_css_uri']));\n\n\n //settings for codemirror\n\n $theme = $_POST['codemirrorTheme'];\n if (!in_array($theme, $this->codemirrorThemes)) {\n //set false for default\n $theme = false;\n }\n $db->set_site_setting('codemirrorTheme', $theme);\n\n $codemirrorAutotab = (isset($_POST['codemirrorAutotab']) && $_POST['codemirrorAutotab']) ? 1 : false;\n $db->set_site_setting('codemirrorAutotab', $codemirrorAutotab);\n\n $codemirrorSearch = (isset($_POST['codemirrorSearch']) && $_POST['codemirrorSearch']) ? 1 : false;\n $db->set_site_setting('codemirrorSearch', $codemirrorSearch);\n\n return true;\n }", "title": "" }, { "docid": "37e9ea0db5adb7c20dd81163a27498be", "score": "0.5607163", "text": "public function update_plugin_options() {\n\t\tregister_setting(\n\t\t\t$this->plugin_name, // option group.\n\t\t\t$this->plugin_name, // option name.\n\t\t\tarray( $this, 'validate_settings' ) // santize callback.\n\t\t);\n\t}", "title": "" } ]
e4cf9747fa0ba12875cd293d410ade6d
Constructs a ne PhoneNumbers element
[ { "docid": "61ad5a92428cb7c3e04aa61a833c920e", "score": "0.0", "text": "public function __construct() {\n $this->entries = array();\n }", "title": "" } ]
[ { "docid": "e3a6c8ae482190635896e7900e82727a", "score": "0.62356263", "text": "function createPhoneNumber(array $digits): string {\n return sprintf(\"(%d%d%d) %d%d%d-%d%d%d%d\", ...$digits);\n}", "title": "" }, { "docid": "865e2aba370c97c52aa0611808072d09", "score": "0.6233007", "text": "public static function phoneNumber()\n {\n return self::numerify(self::pickOne(array(\n '###-###-####', '(###)###-####', '1-###-###-####', '###.###.####', '###-###-####', '(###)###-####',\n '1-###-###-####', '###.###.####', '###-###-#### x###', '(###)###-#### x###', '1-###-###-#### x###',\n '###.###.#### x###', '###-###-#### x####', '(###)###-#### x####', '1-###-###-#### x####',\n '###.###.#### x####', '###-###-#### x#####', '(###)###-#### x#####', '1-###-###-#### x#####',\n '###.###.#### x#####'\n )));\n }", "title": "" }, { "docid": "9f56d984cf863b4ba17e3b63d8ecc637", "score": "0.60281473", "text": "function createPhoneNumber($numbersArray) {\n $exact = 10;\n if (count($numbersArray) != $exact) \n return false;\n\n $part = \"(\"; \n for ($i=0; $i < $exact; $i++) {\n if ($i===2) {\n $part .= \"$numbersArray[$i]) \";\n } else if ($i===5) {\n $part .= \"$numbersArray[$i]-\";\n } else {\n $part .= $numbersArray[$i];\n }\n }\n \n return $part;\n}", "title": "" }, { "docid": "2a962276ae53b6f2d5563df53b0cc2bd", "score": "0.59593624", "text": "function shipTo_phoneNumber()\n\t{\n\t\tif (isset($this->params['shipTo_phoneNumber']))\n\t\t{\n\t\t\tif ((strlen($this->params['shipTo_phoneNumber']) > 0) && (strlen($this->params['shipTo_phoneNumber']) <= 25))\n\t\t\t{\n\t\t\t\treturn \"<phoneNumber>\" . $this->params['shipTo_phoneNumber'] . \"</phoneNumber>\";\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$this->error_messages[] .= 'Phone number must be up to 25 digits (no letters). Ex. (123)123-1234';\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "1ff44e958a0d649c203179ca92e7bcb7", "score": "0.5940037", "text": "public function mwListNumbers( ) {\n\n\t\t$addresses = get_option( 'business_address' );\n\t\t$addressChoice = get_option( 'main_address' );\n\n\t\t$html = '';\n\t\t\n\t\t$html .= '<ul class=\"numbers\">';\n\n\t\tforeach ($addresses as $addressName => $addressDetails) {\n\n\t\t\tif ( $addressName == $addressChoice ) {\n\n\t\t\t\t$schema = ' itemprop=\"telephone\"';\n\n\t\t\t} else {\n\n\t\t\t\t$schema = '';\n\n\t\t\t}\n\n\t\t\tif ( isset($addressDetails['telephone_number'] ) && $addressDetails['telephone_number'] != '' ) {\n\n\t\t\t\t$telephoneNumberSlug = str_replace( ' ', '', $addressDetails['telephone_number']);\n\t\t\t\t$html .= '<li '.$schema .' ><a id=\"'.$addressName.'-phone\" href=\"tel:'.$telephoneNumberSlug.'\">'.$addressDetails['telephone_number'].'</a></li>';\n\n\t\t\t}\n\t\t\t\n\n\t\t}\n\n\t\t$html .= '</ul>';\n\n\t\treturn $html;\n\n\t}", "title": "" }, { "docid": "6fd95fa5b391cecdccfa2c71376e0798", "score": "0.59153223", "text": "function billTo_phoneNumber()\n\t{\n\t\tif (isset($this->params['billTo_phoneNumber']))\n\t\t{\n\t\t\tif ($this->update === true)\n\t\t\t{\n\t\t\t\treturn \"<phoneNumber>\" . $this->params['billTo_phoneNumber'] . \"</phoneNumber>\";\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tif ((strlen($this->params['billTo_phoneNumber']) > 0) && (strlen($this->params['billTo_phoneNumber']) <= 25))\n\t\t\t\t{\n\t\t\t\t\treturn \"<phoneNumber>\" . $this->params['billTo_phoneNumber'] . \"</phoneNumber>\";\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$this->error_messages[] .= 'Phone number must be up to 25 digits (no letters). Ex. (123)123-1234';\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "fc05b40e23818fb909142c6f144fcbf6", "score": "0.5854985", "text": "private function _createNumberField()\n {\n $number = new Zend_Form_Element_Text('number');\n $number->setLabel('accountNumber')\n ->addFilter(new Zend_Filter_StringTrim())\n ->addFilter(new Zend_Filter_StripTags())\n ->addValidator(new Zend_Validate_StringLength(array(2, 60)))\n ->setRequired();\n\n return $number;\n }", "title": "" }, { "docid": "b2395d62147a23932848717364915fbb", "score": "0.5742854", "text": "public function organizationNumberPhone(): string;", "title": "" }, { "docid": "00a30f6ee226ba8dd8de74df6fd0d1ae", "score": "0.57349676", "text": "public function getPhoneNumber();", "title": "" }, { "docid": "00a30f6ee226ba8dd8de74df6fd0d1ae", "score": "0.57349676", "text": "public function getPhoneNumber();", "title": "" }, { "docid": "bbb44a9041388a56dd56af5b6cbbb41d", "score": "0.5712551", "text": "public function telephone()\n {\n $prefix = $this->getRandomKey('tellphone');\n return string('0' . $prefix . randomNumber(7));\n }", "title": "" }, { "docid": "b767ae269e312c6b740fe66800e25f61", "score": "0.57059866", "text": "function addPhonenumber($id=null ,$phonenumbertype_id = null, $phonenumber=null){\n if($id === null){\n $id = rand(-1,-99999);\n }\n $this->Phonenumbers[] = array(\n 'id' => $id, //to relate to preferred address\n 'phonenumbertype_id' => $phonenumbertype_id,\n 'phonenumber' => $phonenumber\n );\n }", "title": "" }, { "docid": "c4287ad9c5872acb628fc1ed39325e13", "score": "0.56525177", "text": "public function providerPhoneNumbers() {\n return [\n 'standard phone number' => ['123456789', '123456789'],\n 'whitespace is removed' => ['1234 56789', '123456789'],\n 'parse_url(0) return FALSE workaround' => ['0', '0-'],\n 'php bug 70588 workaround - lower edge check' => ['1', '1-'],\n 'php bug 70588 workaround' => ['123', '1-23'],\n 'php bug 70588 workaround - with whitespace removal' => ['1 2 3 4 5', '1-2345'],\n 'php bug 70588 workaround - upper edge check' => ['65534', '6-5534'],\n 'php bug 70588 workaround - edge check' => ['65535', '6-5535'],\n 'php bug 70588 workaround - invalid port number - lower edge check' => ['65536', '6-5536'],\n 'php bug 70588 workaround - invalid port number - upper edge check' => ['99999', '9-9999'],\n 'lowest number not affected by php bug 70588' => ['100000', '100000'],\n ];\n }", "title": "" }, { "docid": "618d64b78e0759df3d8b6d54dbbc9f2b", "score": "0.54770756", "text": "private function telefon_numarasi(){\n\t\t// return \"+90\".$kodlar[array_rand($kodlar)].mt_rand(1111111,9999999);\n\t\treturn \"+90851\".mt_rand(1111111,9999999);\n\t}", "title": "" }, { "docid": "a94916e8aaa031ce781e3e55136ef798", "score": "0.5474207", "text": "public static function safePhoneNumber()\n {\n return self::numerify(self::pickOne(array(\n '555-###-####', '(555)###-####', '1-555-###-####', '555.###.####', '555-###-####', '(555)###-####',\n '1-555-###-####', '555.###.####', '555-###-#### x###', '(555)###-#### x###', '1-555-###-#### x###',\n '555.###.#### x###', '555-###-#### x####', '(555)###-#### x####', '1-555-###-#### x####',\n '555.###.#### x####', '555-###-#### x#####', '(555)###-#### x#####', '1-555-###-#### x#####',\n '555.###.#### x#####'\n )));\n }", "title": "" }, { "docid": "c2f920d636c95d79c4336ecf57f7d858", "score": "0.54677576", "text": "public function createAdditionalNumbersSpan()\n {\n $extraPhonesCount = $this->extraPhones !== null ? count($this->extraPhones) : 0;\n\n if ($extraPhonesCount > 0) {\n $numArr = [];\n $numArr[] = $this->phone;\n foreach ($this->extraPhones as $number) {\n $numArr[] = $number;\n }\n $numStr = \"<span style='color: red' data-toggle=\\\"tooltip\\\" title=\\\"\" . implode('<br>', $numArr) . \"\\\"> (+\" . $extraPhonesCount . \")</span>\";\n } else {\n $numStr = '';\n }\n\n return $numStr;\n }", "title": "" }, { "docid": "0aa027575db447bc9cae431086a3d048", "score": "0.54658926", "text": "function getPhonePrefix();", "title": "" }, { "docid": "539a605c1664ff6fc4f80920b36af8e9", "score": "0.54495615", "text": "public function createAdditionalNumbersSpan()\n {\n $extraPhonesCount = $this->extraPhones !== null ? count($this->extraPhones) : 0;\n if ($extraPhonesCount > 0) {\n $numArr = [];\n $numArr[] = $this->phone;\n foreach ($this->extraPhones as $number) {\n $numArr[] = $number;\n }\n $numStr = \"<span style='color: red' data-toggle=\\\"tooltip\\\" title=\\\"\" . implode('<br>', $numArr) . \"\\\"> (+\" . $extraPhonesCount . \")</span>\";\n } else {\n $numStr = '';\n }\n\n return $numStr;\n }", "title": "" }, { "docid": "095b5fe84bc8cb0b64a1a2e780bd669a", "score": "0.5437316", "text": "public function anonymousPhone(): string\n {\n return '9999999999';\n }", "title": "" }, { "docid": "1d564839bbc58df1889dcd210af44dff", "score": "0.54361445", "text": "function set_phone_nums($phone_nums, $record_index, $count_inner_fields, $field_index, $length)\n\t\t{\n\t\t\tglobal $client_info;\n\t\t\t\n\t\t\t$phone_type = \"Work\";\n\t\t\t$work_phone_num = get_phone_num($phone_nums, $length, $phone_type, strlen($phone_type));\n\t\t\t$client_info[$record_index][$field_index+$count_inner_fields++] = $work_phone_num;\n\t\t\t\n\t\t\t$phone_type = \"Home\";\n\t\t\t$home_phone_num = get_phone_num($phone_nums, $length, $phone_type, strlen($phone_type));\n\t\t\t$client_info[$record_index][$field_index+$count_inner_fields++] = $home_phone_num;\n\t\t\t\n\t\t\t$phone_type = \"Mobile\";\n\t\t\t$home_phone_num = get_phone_num($phone_nums, $length, $phone_type, strlen($phone_type));\n\t\t\t$client_info[$record_index][$field_index+$count_inner_fields] = $home_phone_num;\n\t\t\t\n\t\t\treturn $count_inner_fields;\n\t\t}", "title": "" }, { "docid": "0bfe7d77ab96f8f147ab358a7e26c3eb", "score": "0.54003954", "text": "public function getPhoneNumber()\n {\n return $this->country_code.$this->phone;\n }", "title": "" }, { "docid": "546ff9ff20019c9b7364e80fcd36a23b", "score": "0.5385836", "text": "public function getMobilePhoneNumber();", "title": "" }, { "docid": "abfbd177501687453d3742b3e2f7b526", "score": "0.5378549", "text": "public function getPhoneNumber(): string;", "title": "" }, { "docid": "5c1493423ce56ddf3302403bd84d2d81", "score": "0.5340091", "text": "function getNumber ()\n {\n return $this->phone;\n }", "title": "" }, { "docid": "fc6b47ee618a0c689a0916cab31bea13", "score": "0.5325954", "text": "public function getTelephone();", "title": "" }, { "docid": "c053217e3de17d785343c2c45f827149", "score": "0.5317521", "text": "public function getPhoneNumbers()\n {\n return $this->phone_numbers;\n }", "title": "" }, { "docid": "43688575c463f852013f172bcd460f21", "score": "0.53020597", "text": "public function getPhone();", "title": "" }, { "docid": "43688575c463f852013f172bcd460f21", "score": "0.53020597", "text": "public function getPhone();", "title": "" }, { "docid": "5e1446d7dc27218470fc6f7583bb5fae", "score": "0.52992123", "text": "private function addXInvoiceNum() {\n\t\t$elementName = 'x_invoice_num';\n\t\t$addressOpts = array('required'=>true,'readonly' => true,'value'=>$this->invoice);\n\t\t$this->addElement('hidden',$elementName,$addressOpts);\n\t\t$this->getElement($elementName)->removeDecorator('Htmltag');\n\t\t$this->getElement($elementName)->removeDecorator('Label');\n\t\t$this->addToGroup( $elementName );\n\t}", "title": "" }, { "docid": "c5e0b786e1330f14f48febbb1bad7cad", "score": "0.5298725", "text": "public function mobileNumbers()\n {\n return $this->mno;\n }", "title": "" }, { "docid": "49f1787bed7d1c719c1eef49af5911f0", "score": "0.52956694", "text": "public function getName()\n {\n return 'phone_number';\n }", "title": "" }, { "docid": "00dea83fc4f06a20a4ad89c1d99cd7cb", "score": "0.52699655", "text": "public function addPhone($phone) {\n $this->phones[] = (int) $phone;\n $this->phones = array_unique($this->phones);\n return $this;\n }", "title": "" }, { "docid": "2c5eb17142f8fe9cbef45840843d15fa", "score": "0.5268839", "text": "public function setPhones($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::MESSAGE, \\Google\\Protobuf\\Examples\\AddressBook\\Person\\PhoneNumber::class);\n $this->phones = $arr;\n\n return $this;\n }", "title": "" }, { "docid": "9355454e843905485383c15d20ccf2f3", "score": "0.52497685", "text": "public function provider_phone()\n\t{\n\t\treturn [\n\t\t\t['0163634840', NULL, TRUE],\n\t\t\t['+27173634840', NULL, TRUE],\n\t\t\t['123578', NULL, FALSE],\n\t\t\t// Some uk numbers\n\t\t\t['01234456778', NULL, TRUE],\n\t\t\t['+0441234456778', NULL, FALSE],\n\t\t\t// Google UK case you're interested\n\t\t\t['+44 20-7031-2017', [12], TRUE],\n\t\t\t// BT Corporate\n\t\t\t['020 7356 5000',\t NULL, TRUE],\n\t\t\t// Empty test\n\t\t\t['', NULL, FALSE],\n\t\t\t[NULL, NULL, FALSE],\n\t\t\t[FALSE, NULL, FALSE],\n\t\t];\n\t}", "title": "" }, { "docid": "fe571820f549471b737417d8b0b824c7", "score": "0.52360314", "text": "public function phone($params)\n\t{\n\t\t$req = ($params[3]) ? ' cmc_req' : '';\n\t\t$title = $this->noEntities(JText::_($params[2]));\n\t\t$inter = '';\n\n\t\tif ($this->phoneFormat == 'inter')\n\t\t{\n\t\t\t$inter = 'inter';\n\t\t}\n\n\t\t$phone = '\n\t\t<field name=\"' . $params[0] . '\"\n\t\ttype=\"phone\"\n\t\tid=\"cmc-phone-' . $params[0] . '\"\n\t\tclass=\"phone input-medium validate-digits ' . $inter . $req . '\"\n\t\tlabelclass=\"form-label cmc-label\"'\n\t\t\t. ($params[3] ? ' required=\"required\" ' : ' ') .\n\t\t\t'size=\"40\" ' .\n\t\t\t'hint=\"' . $title . ' ' . ($req ? '*' : '') . '\" ' .\n\t\t\t'label=\"' . $title . '\"\n\t\t/>';\n\n\t\treturn $phone;\n\t}", "title": "" }, { "docid": "d63de7e8188e080b485199297fdfdd45", "score": "0.5231796", "text": "public function phoneNumbers()\n {\n return $this->hasMany(AccountPhone::class);\n }", "title": "" }, { "docid": "56aef2bf3fca48bfb5a70e08221d85e7", "score": "0.52258676", "text": "public function getPhoneNumber()\n {\n return clone $this->phoneNumber;\n }", "title": "" }, { "docid": "74c05dc505bb99f3fb15bc1af1fab813", "score": "0.5207955", "text": "public function it_can_add_phone_number()\n {\n $member = $this->member;\n $countryDiallingCode = '44';\n $phoneNumber = '1493334010';\n\n $member->addPhoneNumber($countryDiallingCode, $phoneNumber);\n\n $this->assertEquals(\n '+44 1493334010',\n $member->getPhoneNumber()->toString()\n );\n }", "title": "" }, { "docid": "6ed61b11640f88242b3cce7562d85b17", "score": "0.5207479", "text": "public function setUserTelephoneNumber($val)\n {\n $this->_propDict[\"userTelephoneNumber\"] = $val;\n return $this;\n }", "title": "" }, { "docid": "b799799a02976b7ada4458937a7d568a", "score": "0.5201174", "text": "function format_telephone_number($number) {\n\n\t\tif (strlen(preg_replace('/[^0-9]/', '', strval($number))) < 6) {\n\n\t\t\t\t// 1234 Street Name\n\t\t\t\t// Ex Directory\n\t\t\t\t// not given\n\t\t\t\t// Don't have a phone\n\n\t\t\treturn NULL;\n\n\t\t} else {\n\n\t\t\t\t// 000 0000 0000 Ex 00\n\t\t\t\t// 00000 000000, mob - 00000000000\n\t\t\t\t// 00000000000 or 00000000000\n\t\t\t\t// 00000000000 / W: 00000000000\n\t\t\t\t// 00000000 0000 (WORK)\n\t\t\t\t// 00000000000 (txt only)\n\t\t\t\t// 00000 000000 (after 2PM only)\n\t\t\t\t// 00000 000000 not to be use for marketing\n\t\t\t\t// 00000 000000 or +00 00 000 0000(S.Korea)\n\t\t\t\t// US 000 000 0000\n\t\t\t\t// (US Home) 0000000000\n\t\t\t\t// c/o 00000 000000\n\n\t\t\t\t// Try to tidy up \"oo00000000000\" or \"OI000 000000\", but not \"c/o 00000 000000\"\n\n\t\t\t$chars = preg_split('//u', $number, -1, PREG_SPLIT_NO_EMPTY); // UTF-8 character splitting\n\t\t\t$length = ($chars === false ? 0 : count($chars));\n\t\t\t$dividers = array(' ', '(', ')', '-');\n\n\t\t\tfor ($k = 0; $k < $length; $k++) {\n\t\t\t\tif (in_array($chars[$k], array('i', 'I', 'o', 'O'))) {\n\t\t\t\t\tif ($k > 0 && !ctype_digit($chars[$k - 1]) && !in_array($chars[$k - 1], $dividers)) { // Only apply if start of string, or preceding char is a digit/divider.\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t$new = $chars;\n\t\t\t\t\twhile ($k < $length) {\n\t\t\t\t\t\tif (in_array($chars[$k], array('i', 'I'))) {\n\t\t\t\t\t\t\t$new[$k] = 1;\n\t\t\t\t\t\t} else if (in_array($chars[$k], array('o', 'O'))) {\n\t\t\t\t\t\t\t$new[$k] = 0;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$k++;\n\t\t\t\t\t}\n\t\t\t\t\tif ($k == $length || ctype_digit($chars[$k]) || in_array($chars[$k], $dividers)) { // Only apply if end of string, or following char is a digit/divider.\n\t\t\t\t\t\t$chars = $new;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn implode('', $chars);\n\n\t\t}\n\n\t}", "title": "" }, { "docid": "3d24034d1c24262037da9c92fc6c6c8a", "score": "0.5196809", "text": "public function setPhoneNumber($value){\n if(!empty($value)){\n if(preg_match('/^0[0-9]{3}[0-9]{6}$/', $value)){\n $this->phoneNumber = $value;\n }else{\n return self::INVALID_FORMAT;\n }\n }\n }", "title": "" }, { "docid": "35a17b05e5893b339aaec424af74f1db", "score": "0.5158102", "text": "public function getBillingPhone();", "title": "" }, { "docid": "c0bf598448bb29951cde66ec1a444b64", "score": "0.5151831", "text": "function number_identification($phone_number='', &$error){\n global $config;\n \n $phone_number = preg_replace (\"/[^\\d]+/i\", \"\", $phone_number); // only digits allowed\n \n require_once \"$config[root_dir]/includes/ccfd/NumberIdentification.php\";\n \n $ni = new NumberIdentification;\n $h = array();\n \n // Set inputs and store them in a hash\n // See http://www.maxmind.com/app/telephone_form for more details on the input fields\n \n // Enter your license key here\n $h[\"l\"] = $config['ccfd_license_key'];\n \n // Enter your telephone number here\n $h[\"phone\"] = $phone_number;\n\n // If you want to disable Secure HTTPS or don't have Curl and OpenSSL installed\n // uncomment the next line\n // $ni->isSecure = 0;\n \n //set the time out to be 30 seconds\n $ni->timeout = 30;\n \n //uncomment to turn on debugging\n //$ni->debug = 1;\n \n //how many seconds the cache the ip addresses\n $ni->wsIpaddrRefreshTimeout = 3600*5;\n \n //where to store the ip address\n $ni->wsIpaddrCacheFile = \"/tmp/maxmind.ws.cache\";\n \n // if useDNS is 1 then use DNS, otherwise use ip addresses directly\n $ni->useDNS = 1;\n \n // next we set up the input hash to be passed to the server\n $ni->input($h);\n \n // then we query the server\n $ni->query();\n \n // then we get the result from the server\n $h = $ni->output();\n \n if ($h['err']){\n $error = $h['err'];\n }\n\n // check return values\n if (in_array($h['phoneType'], $config['tni_phone_types']))\n return true;\n else\n return false;\n}", "title": "" }, { "docid": "aa01971275eef9a0e10329a0714543e7", "score": "0.51303864", "text": "public function getTelephoneNumber(): string\n {\n return $this->telephoneNumber;\n }", "title": "" }, { "docid": "610f2f895de08a3983719fbd508abc64", "score": "0.51302576", "text": "public function addTel(string $phoneNumber, string $nationcode = '86')\n {\n array_push($this->list, [\n 'mobile' => (string) $phoneNumber,\n 'nationcode' => (string) $nationcode\n ]);\n\n return $this;\n }", "title": "" }, { "docid": "b1cc0373645f4216a850c8ddcd9344e2", "score": "0.50970054", "text": "public function setPhoneNumber($number, $type='')\n\t{\n\t\t$key = 'TEL';\n\t\tif ($type!='') {\n\t\t\t$key .= ';'. $type;\n\t\t}\n\t\t$key.= ';ENCODING=QUOTED-PRINTABLE';\n\n\t\t$this->_properties[$key] = $this->quoted_printable_encode($number);\n\t}", "title": "" }, { "docid": "0aef455ad3360e2c46eb65c109b9c7ba", "score": "0.50957334", "text": "public function getPhoneNumber()\n\t\t{\n\t\t\tif(isset($this->_phone_no)){\n\t\t\t\treturn $this->_phone_no;\t\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "623f669498baab5749fd6a445d852246", "score": "0.5082044", "text": "function phoneNumber($number, $requireAreaCode = true)\n {\n $servicePrefix = array(\"0800\", \"0900\", \"0508\");\n\n $areaCodes = array(\"024099\", // for the Scott Base in the Ross Dependency\n \"03\", // for the South Island and the Chatham Islands\n \"04\", // for the Wellington Region to Kapiti, but not the Wairarapa and Otaki\n \"06\", // for the he remaining southern and eastern North Island including Taranaki, Manawatu-Wanganui (excluding Taumarunui), Hawke's Bay, Gisborne, the Wairarapa, and Otaki\n \"07\", // for the Waikato, the Bay of Plenty and Taumarunui\n \"09\", // for Auckland and Northland\n );\n\n // Remove non-numeric characters that we still accept\n $number = str_replace(array(\"+\", \" \", \"(\", \")\", \"-\",), \"\", trim($number));\n\n // Sanity check\n if (!ctype_digit($number)) {\n return false;\n }\n\n // http://en.wikipedia.org/wiki/Telephone_numbers_in_New_Zealand#Mobile_Phones\n $mobilePrefix = array(\"orcon\" => \"020\", // Orcon\n \"vodafone\" => \"021\", // Vodafone; 6-8 digits\n \"2degrees\" => \"022\", // 2degrees; 7 digits; 2degrees was launched in August 2009.\n \"telstraClear_unused\" => \"023\", // Unused; Owned by TelstraClear\n \"expansion\" => \"024\", // Unused; Protected by Management Committee 30.01.09 to preserve the potential code expansion option.\n \"telecomNZ_deprecated\" => \"025\", // Was used by Telecom New Zealand until it was shut down on 31 March 2007. All numbers have now migrated to 027 (7-digit) and 0274 (6-digit).\n \"telecomNZ\" => \"027\", // Telecom New Zealand; 7 digits\n \"compass\" => \"0280\", // Compass Communications\n \"callPlus\" => \"028\", // CallPlus or BLACK + WHITE\n \"teletraders\" => \"0283\", // Teletraders MVNO\n \"m2\" => \"02885\", // M2 MVNO\n \"airnet\" => \"02896\", // Airnet NZ Ltd\n \"telstraClear\" => \"029\", // TelstraClear\n );\n\n // Is it a mobile number?\n foreach ($mobilePrefix as $provider => $prefix) {\n // Does it start with a recognised provider prefix?\n if (substr($number, 0, strlen($prefix)) != $prefix) {\n continue;\n }\n // Is it the Scott base / Ross Dependency?\n if (substr($number, 0, 6) == '024099') {\n continue;\n }\n\n switch ($provider) {\n // Vodafone; 6-8 digits\n case 'vodafone':\n if (preg_match('/^021[0-9]{6,8}$/', $number)) {\n return true;\n }\n break;\n // 2degress; 7 digits\n case '2degrees':\n if (preg_match('/^022[0-9]{7}$/', $number)) {\n return true;\n }\n break;\n\n // These providers offer numbers with 02, then 7-9 digits\n case 'orcon':\n case 'compass':\n case 'callPlus':\n case 'teletraders':\n case 'm2':\n case 'airnet':\n case 'telstraClear':\n case 'telecomNZ':\n if (preg_match('/^02[0,7,8,9][0-9]{6,8}$/', $number)) {\n return true;\n }\n break;\n\n // These providers aren't valid as of 1/03/2011\n case 'expansion':\n case 'telstraClear_unused':\n case 'telecomNZ_deprecated':\n break;\n }\n }\n\n // Is it a service number of some type?\n if (in_array(substr($number, 0, 4), $servicePrefix)) {\n // Is 0800,0900 or 0508 number\n if (preg_match(\"(^0(8|9|5)0(0|8)[0-9]{6}$)\", $number)) {\n return true;\n }\n }\n\n // Is 0800 with 7 digits?\n if (substr($number, 0, 4) == '0800') {\n if (preg_match(\"(^0800[0-9]{7}$)\", $number)) {\n return true;\n }\n }\n\n // Is it a general landline of some type?\n foreach ($areaCodes as $prefix) {\n // Does it start with a recognised area prefix?\n if (substr($number, 0, strlen($prefix) != $prefix)) {\n continue;\n }\n\n if (!$requireAreaCode) {\n // Is land line w/o area code\n if (preg_match(\"(^[0-9]{7}$)\", $number)) {\n return true;\n }\n } else {\n // Is land line with area code\n if (preg_match(\"(^0(3|4|6|7|9)[0-9]{7}$)\", $number)) {\n return true;\n }\n }\n }\n\n // Is land line with country code\n if (substr($number, 0, 3) == \"640\") {\n if (preg_match(\"(^640(3|4|6|7|9)[0-9]{7})\", $number)) {\n return true;\n }\n }\n\n return false;\n }", "title": "" }, { "docid": "1fc642cf07d9e3aa170baa18c070b32d", "score": "0.50751644", "text": "public function isTypePhoneNumber(): self\n {\n $this->payload['type'] = ButtonType::PHONE_NUMBER;\n\n return $this;\n }", "title": "" }, { "docid": "88231d2ca252d8b4106d0f36b554116b", "score": "0.5069045", "text": "public function getLocalNomorTelpAttribute()\n\t{\n\t\treturn PhoneNumber::make($this->nomor_telp, 'ID')->formatNational();\n\t}", "title": "" }, { "docid": "dc1de9fd7ac129ad96e662b0b611fcd6", "score": "0.5067633", "text": "function storePhoneNo($data) {\n\treturn \"'\" . substr((preg_replace('/[^0-9]/','',$data)), 0, 10) . \"'\";\n}", "title": "" }, { "docid": "e1c8063e356f2ece0a0208b5e872c2e4", "score": "0.505616", "text": "public function phone_number_unique()\n {\n \t$loginsession = Yii::$app->session->get('loginid');\n \t$phone_number = $this->phone_number;\n \t$phone_length = strlen($this->phone_number);\n \t$email = strtolower($this->contact_email);\n \t$httpurl = $_SERVER['HTTP_REFERER'];\n \t$httpurl = explode('/',$httpurl);\n \t$httpurl = end($httpurl);\n \tif ($httpurl == 'create') {\n \t\t$sql = \\app\\models\\Users::find()->select('phone_number')->column();\n \t} else {\n \t\t$sql = \\app\\models\\Users::find()->select('phone_number')->where(['!=', 'email_address', $email])->column();\n \t}\n \tif ((in_array($phone_number, $sql) || in_array('91'.$phone_number, $sql) || in_array(substr($phone_number, -10), $sql)) && $phone_length != 11) {\n \t\t$this->addError('phone_number', \"Phone Number already exist. Please try another one\");\n \t\treturn false;\n \t} elseif ($phone_length == 11) {\n \t\t$this->addError('phone_number', \"Phone Number format is wrong. Please try again\");\n \t\treturn false;\n \t} else {\n \t\treturn true;\n \t}\n }", "title": "" }, { "docid": "4ce3812d87fe2dacd3183c99fa963145", "score": "0.5048088", "text": "public function mwGetNumber( $atts ) {\n\n\t\t$mainAddresses = get_option('business_address');\n\t\t$html = '';\n\t\t$numberTitle = $atts['title'];\n\n\t\tif ( isset($atts['class']) ) {\n\t\t\n\t\t\t$customClass = 'class=\"'.$atts['class'].'\"';\n\n\t\t} else {\n\n\t\t\t$customClass = '';\n\n\t\t}\n\t\t\n\t\t$html .= '<div class=\"mw-business-details mw-business-details-section numbers\">';\n\t\t$html .= '<p class=\"h3 schemaTitle\">'. $numberTitle .'</p>';\n\n\t\tif ( $atts['address'] ) {\n\n\t\t\t$numberChoice = $atts['address'];\n\n\t\t\tforeach ( $mainAddresses as $mainAddressName => $mainAddressDetails ) {\n\n\t\t\t\t$mainAddressNameSlug = $mainAddressName;\n\t\t\t\t$mainAddressName = str_replace( '-', ' ', $mainAddressName);\n\t\t\t\t$mainAddressName = ucwords($mainAddressName);\n\t\t\t\t$telNumber = $mainAddressDetails['telephone_number'];\n\n\t\t\t\tif ( $numberChoice == $mainAddressNameSlug && $telNumber != '' ) {\n\t\t\t\t\n\t\t\t\t\t$html .= '<a '. $customClass .' itemprop=\"telephone\"href=\"tel:'.$telNumber.'\" title=\"Call Today\" id=\"'.$mainAddressNameSlug.'-phone\"><span class=\"calltrack_number\">'.$telNumber.'</span></a><br/>';\n\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t} else {\n\n\t\t\tforeach ( $mainAddresses as $mainAddressName => $mainAddressDetails ) {\n\n\t\t\t\t$mainAddressNameSlug = $mainAddressName;\n\t\t\t\t$mainAddressName = str_replace( '-', ' ', $mainAddressName);\n\t\t\t\t$mainAddressName = ucwords($mainAddressName);\n\t\t\t\t$telNumber = $mainAddressDetails['telephone_number'];\n\t\t\t\t$html .= '<a class=\"phone\" itemprop=\"telephone\"href=\"tel:'.$telNumber.'\" title=\"Call Today\" id=\"'. $pageID .'-'.$mainAddressNameSlug.'-phone\"><span>'.$mainAddressName.': </span><span class=\"calltrack_number\">'.$telNumber.'</span></a><br/>';\n\n\t\t\t}\t\t\t\n\t\t}\n\n\t\t$html .= '</div>';\n\n\t\treturn $html;\n\n\t}", "title": "" }, { "docid": "8fef27ace28f25e8a059fb2290f753be", "score": "0.5046846", "text": "public function setPhoneNumbers($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::MESSAGE, \\Google\\Cloud\\Talent\\V4beta1\\Phone::class);\n $this->phone_numbers = $arr;\n\n return $this;\n }", "title": "" }, { "docid": "53addf298c07d1181b00be9d19a232be", "score": "0.50468075", "text": "function displayPhoneNo($data) {\n\tif ($data === null) {\n\t\treturn \"-\";\n\t}\n\t$len = strlen((string)$data);\n\tif($len == 10) {\n\t\t$firstThree = substr($data, 0, 3);\n\t\t$middleThree = substr($data, 3, 3);\n\t\t$finalFour = substr($data, 6, 4);\n\t\treturn '(' . $firstThree . ') ' . $middleThree . '-' . $finalFour;\n\t} else {\n\t\treturn $data;\n\t}\n}", "title": "" }, { "docid": "9499c9378e12fa86b3fff8275bbb8ccb", "score": "0.5037552", "text": "public function CreatePhoneNumber($phoneNum){\n return new PhoneEntity($phoneNum);\n }", "title": "" }, { "docid": "22b56884fa68e509f5fad13a44a1013a", "score": "0.503506", "text": "public function setMobileNumbers(array $numbers)\n {\n $this->mno = array();\n foreach ($numbers as $item)\n $this->appendMobileNumber($item);\n\n return $this;\n }", "title": "" }, { "docid": "55505b1020792a352e85ebedbbb80bc3", "score": "0.50345564", "text": "public function createNumber($fields)\n {\n $validation = new Validation;\n $validation->validate([\n 'number' => 'required|string',\n 'list_id' => 'required|numeric|max:32',\n 'country_id' => 'nullable|numeric|max:32',\n 'name' => 'nullable|string',\n 'email' => 'nullable|email',\n ], $fields);\n\n if ($validation->run()) {\n return self::_makeRequest('numbers/create/', $fields);\n }\n $validation->showErrors();\n }", "title": "" }, { "docid": "fe9c64d67955bffc15933d55ffd0a29f", "score": "0.50335234", "text": "function internationalizePhonenumber($phonenumber, $prefix = '+31') {\n\t$number = str_replace(array(' ', '-'), '', $phonenumber);\n\tif ($number[0] === '0') {\n\t\t// vergelijken met == 0 levert problemen op want (int) '+' = 0 dankzij php\n\t\tif ($number[1] === '0') {\n\t\t\treturn '+' . substr($number, 2);\n\t\t}\n\t\treturn $prefix . substr($number, 1);\n\t} else {\n\t\treturn $phonenumber;\n\t}\n}", "title": "" }, { "docid": "91a41b3e260d8192d7728774950d0992", "score": "0.5027851", "text": "public function registerPhoneNumber(EmployeeNumber $employeeNumber, PhoneNumber $phoneNumber): void\n {\n }", "title": "" }, { "docid": "5d73ab031e28ab953c622d12aae57cdf", "score": "0.5006002", "text": "public function getPhoneNumber()\r\n {\r\n return $this->phone_number;\r\n }", "title": "" }, { "docid": "a9875a25b92fcbe0470bab7dabbb3824", "score": "0.49830654", "text": "public function getPhoneNumber()\n {\n return $this->PhoneNumber;\n }", "title": "" }, { "docid": "a9875a25b92fcbe0470bab7dabbb3824", "score": "0.49830654", "text": "public function getPhoneNumber()\n {\n return $this->PhoneNumber;\n }", "title": "" }, { "docid": "a9875a25b92fcbe0470bab7dabbb3824", "score": "0.49830654", "text": "public function getPhoneNumber()\n {\n return $this->PhoneNumber;\n }", "title": "" }, { "docid": "044594912ae80b8baa4bd14c0373001b", "score": "0.49778813", "text": "public function setPhoneNumber($var)\n {\n GPBUtil::checkString($var, True);\n $this->phone_number = $var;\n\n return $this;\n }", "title": "" }, { "docid": "e34cd8a6416e41876033c5b8e5d392ed", "score": "0.49771598", "text": "function __construct($number, $name = '') {\n\t\t$this->number = $number;\n\t\t$this->name = $name;\n\t}", "title": "" }, { "docid": "09439ce68212deee24f12654b0b69569", "score": "0.49683198", "text": "public function appendPhoneNumList($value)\n {\n return $this->append(self::PHONENUMLIST, $value);\n }", "title": "" }, { "docid": "151024741ffdabbdd201fdccdb231f5d", "score": "0.49683106", "text": "function ConvertPhoneNumber($aPhone) {\n\nif (strlen($aPhone)>9) {\n\nfor ($i=0; $i<strlen($aPhone); $i++){ \nif ( ereg(\"[0-9]{1}\",substr($aPhone,$i,1) ) ) {$aAllNumbers .= substr($aPhone,$i,1); }\n} //END for ($i=0; $i<strlen($aPhone); $i++){ \n\n$aOut = substr($aAllNumbers,0,3) . \"-\" . substr($aAllNumbers,3,3) . \"-\" . substr($aAllNumbers,6,4);\nreturn $aOut;\n\n}else{\nreturn \"\";\n\n} //END if (strlen($aPhone)>11) {\n\n}", "title": "" }, { "docid": "8ede8aada8a566a02650461afb45af20", "score": "0.49525806", "text": "public function getPhone() : string;", "title": "" }, { "docid": "f7c3867caa08492b67bc981bf41793e7", "score": "0.49478352", "text": "function online_get_person_phones_markup( $post ) {\n\tif ( $post->post_type !== 'person' ) { return; }\n\n\tob_start();\n\tif ( have_rows( 'person_phone_numbers', $post->ID ) ):\n?>\n\t<div class=\"row\">\n\t\t<div class=\"col-sm-4 col-md-5 person-label\">\n\t\t\tPhone\n\t\t</div>\n\t\t<div class=\"col-sm-8 col-md-7 person-attr\">\n\t\t\t<ul class=\"list-unstyled mb-0\">\n\t\t\t<?php\n\t\t\twhile ( have_rows( 'person_phone_numbers', $post->ID ) ): the_row();\n\t\t\t\t$phone = get_sub_field( 'number' );\n\t\t\t\tif ( $phone ):\n\t\t\t?>\n\t\t\t\t<li>\n\t\t\t\t\t<a href=\"tel:<?php echo preg_replace( \"/\\D/\", '', $phone ); ?>\" class=\"person-tel\">\n\t\t\t\t\t\t<?php echo $phone; ?>\n\t\t\t\t\t</a>\n\t\t\t\t</li>\n\t\t\t<?php\n\t\t\t\tendif;\n\t\t\tendwhile;\n\t\t\t?>\n\t\t\t</ul>\n\t\t</div>\n\t</div>\n\t<hr class=\"my-2\">\n<?php\n\tendif;\n\treturn ob_get_clean();\n}", "title": "" }, { "docid": "7bf26019abef7e379fd17a2d32e7209f", "score": "0.49419007", "text": "public function getPhoneNumber()\n {\n return $this->phone_number;\n }", "title": "" }, { "docid": "7bf26019abef7e379fd17a2d32e7209f", "score": "0.49419007", "text": "public function getPhoneNumber()\n {\n return $this->phone_number;\n }", "title": "" }, { "docid": "7bf26019abef7e379fd17a2d32e7209f", "score": "0.49419007", "text": "public function getPhoneNumber()\n {\n return $this->phone_number;\n }", "title": "" }, { "docid": "aeea36862642f26f017494db547004ac", "score": "0.49405563", "text": "public function appendMobileNumber($number)\n {\n if (!is_string((string)$number))\n throw new \\InvalidArgumentException(\"The number should be a string.\");\n\n if (strlen($number) > 20)\n throw new ValueToLongException(\"The mobile number cannot have more than 20 characters\");\n\n if (!preg_match('#^[0-9]+$#', $number))\n throw new InvalidCharacterException(\"Only digits together with the country code are supported. Instead of plus sign (+) double zero (00) may be used.\");\n\n $this->mno[] = $number;\n\n return $this;\n }", "title": "" }, { "docid": "a7cc91b3c0d0c36b118bc2c938c88c1e", "score": "0.49162444", "text": "public function getPhoneNumber($arg=array())\n {\n return $this->faker->phoneNumber();\n }", "title": "" }, { "docid": "7a4c14573658251717f420dae53c5aef", "score": "0.4914008", "text": "public function phone_number()\n\t{\n\t\t$this->form_validation->set_rules('phone', 'Phone', 'trim|required');\n\t\t\t\n\t\tif($this->form_validation->run() == FALSE){\n\t\t\techo 0;\n\t\t}else{\n\n\t\t\tif($this->Template_model->insert_or_update_phone_info()){\n\t\t\t\techo 1;\n\t\t\t}else{\n\t\t\t\techo 0;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "419acd75d3606f7b17857d02766a73e7", "score": "0.4896946", "text": "private function addPhones($phones, $customerId)\n {\n foreach ($phones as $phone) {\n $phone['customer_id'] = $customerId;\n if (ine($phone, 'label') && ine($phone, 'number')) {\n //remove special character, alphabets, and special symbols\n $phone['number'] = preg_replace('/\\D/', '', $phone['number']);\n $this->phone->create($phone);\n }\n }\n }", "title": "" }, { "docid": "9b050b5b87356e68ea23cc18c23b1b99", "score": "0.48833224", "text": "public function getAdressNumber()\n {\n return $this->get('adress_number', 'user');\n }", "title": "" }, { "docid": "1eb9b73f485eb792f8cb864a39f4f25c", "score": "0.485498", "text": "public static function phoneNumberFormat($phoneNumber){\n $phone = preg_replace('/[\\+\\- ]+/','',$phoneNumber);\n if(!empty($phone)){\n $nig = array('070','071','080','081','090','091');\n if(in_array(substr($phone,0,3),$nig)){\n $phone = substr_replace($phone,'234',0,1);\n }\n if(substr($phone,0,3) == '234' and strlen($phone) != 13){ $phone = null; }\n }\n $errorMsg = 'Valid {var} is required.';\n return (ctype_digit($phone)) ? [true,$phone] : [null,$errorMsg];\n }", "title": "" }, { "docid": "0cbf626e70d809385a1ec9badf7e0c3e", "score": "0.48535514", "text": "private function evaluateStudentPhone($number){\n global $utilities;\n\n $clean_phone = \"\";\n for($i=0; $i<strlen($number); $i++)\n if(is_numeric($number[$i])){\n $clean_phone.=$number[$i];\n }\n\n $regex = \"^[0-9]{1}[0-9]{8,13}$\";\n if(!preg_match(\"/$regex/\",$clean_phone)){\n $this->errors['phone'] = $utilities->createUserMessage('phone');\n return false;}\n else{return true;}\n\n\n }", "title": "" }, { "docid": "13f17bc93e219624222a3fdac6c9c3c2", "score": "0.48465312", "text": "public function testTelephoneWidget() {\n $this->drupalGet('node/add/article');\n $this->assertSession()->fieldValueEquals(\"field_telephone[0][value]\", '');\n $this->assertSession()->responseContains('placeholder=\"123-456-7890\"');\n }", "title": "" }, { "docid": "cbe9927dc89357fad2ec34c102d2c5a4", "score": "0.4841081", "text": "public function telLink($phoneNumber, $text = null)\n {\n return $this->a(\"tel:{$phoneNumber}\", $text ?: $phoneNumber);\n }", "title": "" }, { "docid": "9f7979035e462569d5336a4389bf4d63", "score": "0.48323545", "text": "public function setPhoneNumber($phone_number)\r\n {\r\n $this->phone_number = $phone_number;\r\n\r\n return $this;\r\n }", "title": "" }, { "docid": "6907fd1e3741a5099a87c2f074c01fc6", "score": "0.48306477", "text": "protected function createPhone()\n {\n foreach ($this->request->phone as $key => $value) {\n $dados = ['ddd' => $this->request->ddd[$key], 'phone' => $this->request->phone[$key],\n 'cont_type_id' => $this->request->phone_type_id[$key], 'person_id' => $this->request->person_id];\n $contPhone = new ContPhone();\n $validator = validator($dados, $contPhone->rulesStore());\n\n if ($validator->fails()) {\n return redirect()->route(\"{$this->groupRoute}.create\")\n ->withErrors($validator)\n ->withInput();\n }\n ContPhone::updateOrCreate(\n ['id' => $this->request->phone_id[$key]],\n ['ddd' => $this->request->ddd[$key], 'phone' => $this->request->phone[$key],\n 'cont_type_id' => $this->request->phone_type_id[$key], 'person_id' => $this->request->person_id]\n );\n }\n }", "title": "" }, { "docid": "eef59b70498ba85b444f09a2b07bca50", "score": "0.48291412", "text": "function format_phone_data($phone_number = 0)\n {\n return geoNumber::phoneFormat($phone_number);\n }", "title": "" }, { "docid": "eaf37fd7b38d71d681f8de6eddfebb29", "score": "0.48230368", "text": "public function __construct($phone)\n {\n $this->phone = $phone;\n }", "title": "" }, { "docid": "144cc6cb427d0a688121b9dd9eff3fcc", "score": "0.48191038", "text": "public function phone(string $phone)\n {\n $this->phone = $phone;\n\n return $this;\n }", "title": "" }, { "docid": "50c75056f8abee79b1363407d7b88116", "score": "0.48118234", "text": "public function addNumber(Tx_Addresses_Domain_Model_Number $number) {\n  \t\t$this->numbers[] = $number;\n\t}", "title": "" }, { "docid": "86c652b338cea0d064195185ce83f5d3", "score": "0.48088962", "text": "public function getPhoneNumber()\n {\n return $this->phoneNumber;\n }", "title": "" }, { "docid": "86c652b338cea0d064195185ce83f5d3", "score": "0.48088962", "text": "public function getPhoneNumber()\n {\n return $this->phoneNumber;\n }", "title": "" }, { "docid": "86c652b338cea0d064195185ce83f5d3", "score": "0.48088962", "text": "public function getPhoneNumber()\n {\n return $this->phoneNumber;\n }", "title": "" }, { "docid": "86c652b338cea0d064195185ce83f5d3", "score": "0.48088962", "text": "public function getPhoneNumber()\n {\n return $this->phoneNumber;\n }", "title": "" }, { "docid": "86c652b338cea0d064195185ce83f5d3", "score": "0.48088962", "text": "public function getPhoneNumber()\n {\n return $this->phoneNumber;\n }", "title": "" }, { "docid": "bf1ac012f400569d322f717e49d4e61b", "score": "0.48087612", "text": "public function buildEmptyShippingContact();", "title": "" }, { "docid": "22ae5db4f9d16c7296b52e722544c7d6", "score": "0.4807061", "text": "public function phone_number()\n\t{\n\t\t$this->form_validation->set_rules('phone', 'Phone', 'trim|required');\n\t\t\t\n\t\tif($this->form_validation->run() == FALSE){\n\t\t\techo 0;\n\t\t}else{\n\n\t\t\tif($this->Page_model->insert_or_update_phone_info()){\n\t\t\t\techo 1;\n\t\t\t}else{\n\t\t\t\techo 0;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "8e2957c9685833ded3b50c5b1ba7bd73", "score": "0.4792128", "text": "public function getPhone(): string\n {\n return !empty($this->phone)? $this->phone : \"\";\n }", "title": "" }, { "docid": "8c53ccc6abe8af9453f5834b5a83784d", "score": "0.47745425", "text": "public function validateInput($arr){\n $e = $this->_applicationPage->getPage()->getElementByFixedId(self::FID_REGISTRATION_NUMBER);\n $key = 'el'.$e->getId();\n $arr[$key] = preg_replace('#[^0-9]#','', $arr[$key]);\n $arr[$key] = ltrim($arr[$key], '0');\n return parent::validateInput($arr);\n }", "title": "" }, { "docid": "cfc4d92151ae9f260ca1beb39986ebeb", "score": "0.47743398", "text": "function md_custom_woocommerce_checkout_fields( $fields ) \n{\n $fields['order']['order_comments']['placeholder'] = 'Gift Note';\n $fields['order']['order_comments']['label'] = 'ADD A MESSAGE TO YOUR BOX';\n $fields['billing']['billing_phone']['custom_attributes'] = array( \"pattern\" => \".{10,10}\" );\n return $fields;\n}", "title": "" }, { "docid": "7ca15f2e88e7756becb71ad518a6bbcf", "score": "0.47487587", "text": "public function setPhoneNumber($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Protobuf\\StringValue::class);\n $this->phone_number = $var;\n\n return $this;\n }", "title": "" }, { "docid": "72ba67356fbcf39e82bd73650466a681", "score": "0.47480038", "text": "public function setTelefono($telefono)\n\t\t{\n\t\t\t\t$this->telefono = $telefono;\n\n\t\t\t\treturn $this;\n\t\t}", "title": "" }, { "docid": "cfe675113e291685c7ab804b2646e1af", "score": "0.4746681", "text": "public function getShippingPhone();", "title": "" } ]
a6d28bcfc1f5f0e5997ec3c010217bbe
Update the specified resource in storage.
[ { "docid": "61b1a8b5fbb2ff6d7955d9ba5405a8c1", "score": "0.0", "text": "public function update(Request $request, $id)\n {\n $test = Test::find($id);\n return $test->update($request->all());\n }", "title": "" } ]
[ { "docid": "ae90a700efd6cf3cd7c51c1c4442503a", "score": "0.7658553", "text": "public function update(ResourceInterface $resource);", "title": "" }, { "docid": "d6a508508d13bb02f2a247e9bf196f78", "score": "0.71877676", "text": "function update ( $id, $resource ) {\r\n\r\n }", "title": "" }, { "docid": "8466495927f3bd478b5fd2d917f45f08", "score": "0.7099208", "text": "public function update(Request $request, Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "b66d45ed275220a344f3f222ce4980b5", "score": "0.70558053", "text": "public function update(Request $request, Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "9a55d4f96f94897978c13d34337c1901", "score": "0.6808637", "text": "public function update(StoreResource $request, $id)\n {\n $input = $request->all();\n \n $resource = Resource::find($id);\n \n $resource->fill($input);\n \n $resource->save();\n\n // redirect\n Session::flash('message', 'Successfully saved resource!');\n return redirect('resources');\n }", "title": "" }, { "docid": "cce47cfb911f4e7678d10bb61eec6271", "score": "0.6523108", "text": "public function update(Request $request, Resource $resource)\n {\n $this->validate($request, [\n 'name' => 'required|max:255',\n ]);\n \n $resource->update($request->except(['_method', '_token']));\n \n flash('El recurso fue actualizado');\n \n return redirect()->route('resource.index');\n }", "title": "" }, { "docid": "1414dc19f0f4ccb3b9d9b0c2f9754c1a", "score": "0.64248925", "text": "public function update(Request $request, Storage $storage)\n {\n //\n $storage->update($request->all());\n\n return redirect()->route('storage.index');\n }", "title": "" }, { "docid": "8b641f5e241101e64f479c764289bfd7", "score": "0.64144814", "text": "public function update(Request $request, Resource $resource)\n {\n\n try {\n $this->validate($request, [\n 'name' => 'required|string|unique:resources,name,' . $resource->id,\n 'group' => 'required|exists:groups,id',\n \"description\" => \"nullable|string\"\n ]);\n $resource->name = $request->name;\n $resource->group_id = $request->group;\n $resource->description = $request->description;\n $resource->save();\n session()->flash('flash_success', 'Updated Successfully.');\n return Redirect::route('resources.index');\n } catch (ValidationException $exception) {\n return Redirect::back()->withErrors($exception->errors())->withInput();\n } catch (Exception $e) {\n session()->flash('flash_error', 'Something went wrong');\n return $e->getMessage();\n return Redirect::back();\n }\n }", "title": "" }, { "docid": "d131fb800138c5d8889803afda8ecf7b", "score": "0.62923384", "text": "public function updateResource(){\n\t\t$this->setTitle('Update resource');\n $this->name = $_POST['name'];\n $this->id = $_POST['resource_id'];\n $this->rate = $_POST['rate'];\n $this->description = $_POST['description'];\n $this->type = $_POST['type'];\n $this->loadModel('resource');\n\t\t$this->added_resource = $this->model->updateResources($this->id,$this->name,$this->rate,$this->description,$this->type);\n $this->render('resource/_bewerkt.tpl');\n\t}", "title": "" }, { "docid": "6644414d1c8deb86d17216b9f77e38da", "score": "0.62589455", "text": "public function updateStream($path, $resource, $config = null);", "title": "" }, { "docid": "35958bbf8b0dca0d5dcadddf00962ef1", "score": "0.6193939", "text": "public function update() {\n \t\t//Does the Resource object have an id?\n if ( is_null( $this->id ) ) trigger_error (\"Resource::update(): Attempt to update an Resource object that does not have its ID property set.\", E_USER_ERROR );\n\n\t\t//Update the Resource\n $conn = new mysqli( $DB_HOST, $DB_USERNAME, $DB_PASSWORD, $DB_NAME );\n $sql = \"UPDATE resources SET title=:?, summary=?, url=?, content=?, category=?, is_free=?, is_featured=?, is_favorite=?, date_created=? WHERE id = ?\";\n $st = $conn->prepare ( $sql );\n $st->bind_param( 'sssssiiisi', $this->title, $this->summary, $this->url, $this->content, $this->category, $this->is_free, $this->is_featured, $this->is_favorite, date(\"Y-m-d H:i:s\"), $this->id );\n\n $st->execute();\n $conn = null;\n}", "title": "" }, { "docid": "27fdfad09c0210d824e7b3fabe4e253e", "score": "0.6178334", "text": "public function update(Request $request, $id)\n {\n // if(Auth::user()->admin){\n $storage = Storage::findOrFail($id);\n $storage->name = $request->name;\n $storage->address = $request->address;\n $storage->save();\n Session::flash('success','You successfully updated storage!');\n// }\n// else{\n// Session::flash('error','You do not have enough permission!');\n// }\n return redirect()->route('storage.index');\n }", "title": "" }, { "docid": "a25688f30a6b62a181559b84d042105c", "score": "0.6148197", "text": "public function update(Request $request, $resource)\n {\n $this->authorize('update', $resource);\n\n $resource->load($this->with);\n\n $this->form()->setModel($resource)->save(function($data,$form) use (&$resource){\n $general = $data->pull('general'); \n $relations = $data->get('relations');\n\n $admin = \\Auth::guard('admin')->user();\n \n $resource->forceFill($general->toArray()); \n\n $this->event('updating', $resource); \n\n $resource->save(); \n\n $this->syncRelations($relations, $resource); \n\n $this->event('updated', $resource); \n\n return $resource;\n }); \n\n $this->checkOwner($resource);\n\n return $this->redirect($request, $resource); \n }", "title": "" }, { "docid": "9a5dcd97258a1dde56734d3bfd713b95", "score": "0.6116463", "text": "public function updateResource(Request $request, $id)\n {\n $validatedData = $request->validate(\n [\n 'title' => 'required',\n 'description' => 'required',\n 'uploadedfile' => 'mimes:flv,mp4,avi,wmv,3gp,mov,mkv,vob'\n ],\n [\n 'title.required' => 'Please enter video title.',\n 'description.required' => 'Please enter description.',\n 'uploadedfile.mimes' => 'Video format not supported.'\n ]\n );\n\n if($file = $request->hasFile('uploadedfile')) {\n \n $file = $request->file('uploadedfile') ; \n $fileName = $file->getClientOriginalName() ;\n $destinationPath = public_path().'/storage/resource' ;\n $file->move($destinationPath,$fileName);\n $resourceUpdate = DB::table('table_resources')->where([\n ['id','=',$id],\n ])->update(array(\n 'title' => $request->title,\n 'description' => $request->description,\n 'url' => $fileName\n ));\n if($resourceUpdate) {\n return redirect()->back()->with('message', 'Resource successfully updated.');\n } else {\n return redirect()->back()->withErrors(['Nothing changed. Please try again.']);\n }\n \n } else {\n $resourceUpdate = DB::table('table_resources')->where([\n ['id','=',$id],\n ])->update(array(\n 'title' => $request->title,\n 'description' => $request->description \n ));\n if($resourceUpdate) {\n return redirect()->back()->with('message', 'Resource successfully updated.');\n } else {\n return redirect()->back()->withErrors(['Nothing changed. Please try again.']);\n }\n\n }\n\n }", "title": "" }, { "docid": "7bfce29a195f384d1bcc21b603c792d2", "score": "0.6033452", "text": "public function update(Request $request, $id){\n\n $this->validate($request, $this->getValidationRules($request), $this->getValidationMessages($request));\n \n if($request->file('image')){\n $rules = [\n 'image' => 'image|mimes:jpg,jpeg,png'\n ];\n\n $this->validate($request, $rules);\n }\n\n \n try {\n $resource = Resource::withTrashed()->findOrFail($id); \n }catch (ModelNotFoundException $e){\n $errors = collect(['El recurso con ID '.$id.' no se encuentra.']);\n return back()\n ->withInput()\n ->with('errors', $errors);\n }\n $this->setResource($resource, $request);\n \n $resource->spaces()->detach();\n $resource->spaces()->attach($request->spaces);\n\n return redirect()->route('resources.index')\n ->with('session_msg', '¡El recurso, se ha editado correctamente!');\n }", "title": "" }, { "docid": "88d2a1e76ebbaa8bd165532adff21092", "score": "0.6013595", "text": "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n $resource = Resource::where('product_id', $id)->first();\n\n $this->validate(request(), [\n 'category_id' => 'required',\n 'name' => 'required',\n 'short_name' => 'required',\n// 'article' => 'required',\n 'price' => 'required',\n 'collection_id' => 'required',\n 'atribut_id' => 'required',\n ]);\n\n $product->category_id = $request->get('category_id');\n $product->name = $request->get('name');\n $product->short_name = $request->get('short_name');\n// $product->article = $request->get('article');\n $product->price = $request->get('price');\n $product->collection_id = $request->get('collection_id');\n $product->atribut_id = $request->get('atribut_id');\n\n $method = __METHOD__;\n LogFile::ProductLog($product, $method);\n $product->save(); //Сохраняем изменения продукта\n\n return redirect('admin/products')->with('update', 'Продукт обновлен');\n }", "title": "" }, { "docid": "9349dc7f33c6326d0383abd536af6ce3", "score": "0.596908", "text": "public function updated(\n $resource = null,\n array $links = [],\n $meta = null,\n array $headers = []\n ): Response {\n return $this->getResourceResponse($resource, $links, $meta, $headers);\n }", "title": "" }, { "docid": "4e5acd860dcda74c61d836d96050b079", "score": "0.59593076", "text": "public function put(Storage $storage);", "title": "" }, { "docid": "215d42ed153b26bc9b49ae5c5951d499", "score": "0.5955367", "text": "public function update(StoragesUpdateRequest $request, $id)\n {\n $now = \\Carbon\\Carbon::now();\n $storage = Storage::find($id);\n $by_id = Auth::user()->id;\n\n $storage->fill([\n 'maker' => $request->maker,\n 'model_number' => $request->model_number,\n 'serial_number' => $request->serial_number,\n 'size' => $request->size,\n 'types' => $request->types,\n 'supported_os' => $request->supported_os,\n 'recovery_key' => $request->recovery_key,\n 'storage_password' => $request->storage_password,\n 'deleted_at' => $request->deleted_at === \"1\" ? $now : null,\n 'reason' => $request->reason,\n 'updated_by' => $by_id,\n ])\n ->save();\n\n return redirect()->route('storages.show', $storage->id)->with('information', 'レコードを更新しました。');\n }", "title": "" }, { "docid": "da49ecf5dc35b8e5edb8b21644469290", "score": "0.5939757", "text": "public function update(RespondentStoreRequest $request, $id)\n {}", "title": "" }, { "docid": "b96bbe109f16f366cfd72892d0d0be64", "score": "0.5903822", "text": "public function update(Request $Request, Resource $Resource)\n {\n\t\t\t$Actions = ($Request->actions)?:[1];\n\t\t\t$Action = \"0.\" . implode(\"\",array_replace(array_fill(1,max($Actions),0),array_fill_keys($Actions,1)));\n\t\t\t$Request->action = $Action;\n\t\t\t$UpdateArray = []; $Rules = Resource::ValidationRules(); $MyRules = [];\n\t\t\tforeach($Resource->FillableFields() as $Field){\n\t\t\t\tif($Field == \"code\") continue;\n\t\t\t\tif($Request->$Field != $Resource->$Field){\n\t\t\t\t\t$Resource->$Field = $UpdateArray[$Field] = $Request->$Field;\n\t\t\t\t\tif(isset($Rules[$Field])) $MyRules[$Field] = $Rules[$Field];\n\t\t\t\t}\n\t\t\t}\n\t\t\tif(empty($UpdateArray)) return redirect()->back()->with([\"info\"=>true,\"type\"=>\"info\",\"text\"=>\"No fields to update.\"]);\n\t\t\t$Validator = Validator::make($UpdateArray,$MyRules,Resource::ValidationMessages());\n\t\t\tif($Validator->fails()) return redirect()->back()->withErrors($Validator);\n\t\t\tif($Resource->status == \"ACTIVE\" && $Resource->save()) return redirect()->route('resource.index')->with([\"info\"=>true,\"type\"=>\"info\",\"text\"=>\"The Resource: \" . $Resource->displayname . \", updated successfully\"]);\n\t\t\treturn view(\"resource.error\");\n }", "title": "" }, { "docid": "469e3d6c9afd54041becbee857df8ef8", "score": "0.5890722", "text": "public function edit(Resource $resource)\n {\n //\n }", "title": "" }, { "docid": "f78906153226222ee5bdfc9d13a06d23", "score": "0.58857", "text": "protected function save($resource) {\n if (isset($resource['public_id'])) {\n $this->collection->update(array('public_id' => $resource['public_id']), $resource, array('upsert' => TRUE));\n }\n }", "title": "" }, { "docid": "99960e81f0d443f90e5e0aa954abd481", "score": "0.5885372", "text": "public function update($id, Request $request) {\n $this->validate($request, isset($this->model->rules_update) ? $this->model->rules_update : $this->model->rules);\n\n ${$this->resource} = $this->model->findOrFail($id);\n\n $fillable_data = array_only($request->all(), $this->model->getFillable());\n\n App::setLocale(Helpers::getLang());\n\n ${$this->resource}->update($fillable_data);\n\n Admin::handleFileUpload('image', ${$this->resource}, 'image');\n\n return Redirect::route($this->view_path . '.index')->with('success', 'yeah');\n }", "title": "" }, { "docid": "a516665e3766b23c94ab33c5940aab8d", "score": "0.5874832", "text": "public function update(UpdateRequest $request, $id)\n {\n $data = $request->all();\n $product = Product::findOrFail($id);\n\n DB::beginTransaction();\n try {\n\n tap($product)->update($data);\n\n if ($request->hasFile('image')) {\n @unlink('products' . $product->image);\n $product->image = time() . '-' . $product->description . '.' . $request->file('image')\n ->getClientOriginalExtension();\n $request->file('image')->move('products', $product->image);\n }\n\n $product->save();\n\n $productResource = new ProductResource($product);\n\n DB::commit();\n return $this->responseSuccess([\n 'message' => trans('response.ProductController.update.success'),\n 'data' => $productResource,\n ]);\n } catch (\\Exception $exception) {\n DB::rollBack();\n return $this->responseError([\n 'message' => trans('response.ProductController.update.error'),\n 'errors' => $exception->getMessage(),\n ], Response::HTTP_INTERNAL_SERVER_ERROR);\n }\n }", "title": "" }, { "docid": "dbe374356cb114ab5e44b198d87b232f", "score": "0.58492017", "text": "public function put($resource, $data){\n $client = new Client([\n 'base_uri' => $this->baseUri\n ]);\n\n //Trim left slashes\n $resource = ltrim($resource,'/');\n\n //Cache miss call to API\n $res = $client->request('PUT', $resource, [\n 'json' => $data,\n 'headers' => [\n 'Authorization' => 'Bearer ' . $this->accessToken,\n 'User-Agent' => env('BASECAMP_AGENT')\n ]\n ]);\n\n //Get JSON payload\n $json = $res->getBody()->getContents();\n\n return json_decode($json);\n }", "title": "" }, { "docid": "0bb389e7c0c131b01dec97c33ec501e0", "score": "0.579422", "text": "public function update(Request $request, $id)\n {\n $resource = MyResource::find($id);\n if ($resource != null) {\n if ($resource->user->id == $request->user()->id || $request->user()->hasRole('Admin')) {\n $request->merge(['module_id' => $request->get('module_id')]);\n $request->validate(['title' => 'required|string', 'description' => 'nullable|string', 'google_drive' => 'nullable|url|max:255', 'publish_year' => 'required|numeric|digits:4|between:2008,' . date('Y'), 'module_id' => 'required|integer|exists:modules,id']);\n $resource->update($request->all());\n\n return redirect()->route('resources.index')\n ->with('success', 'Resource updated successfully');\n }\n return abort(401, 'You\\'re not allowed to edit this resource!');\n }\n return abort('404', 'User not found!');\n }", "title": "" }, { "docid": "7dec035d65557a5fa957575b344e390d", "score": "0.5787175", "text": "protected function saveResource(&$resource) {\n $this->getConfig()->set($resource['key'], $resource['value']);\n\n $resource['id'] = $resource['key'];\n }", "title": "" }, { "docid": "231bf07a63b0a16b02c083ef86c176fd", "score": "0.57833594", "text": "public function update(Request $request, $id)\n {\n $input=$request->file_path;\n if(isset($input)) {\n $File = $this->fileUpload($input);\n }\n else{\n $File = \"course_resource/default.jpg\";\n }\n\n\n $course_resources = CourseResource::whereId($id)->firstOrFail();\n $course_resources->course_id = $request->get('course_id');\n $course_resources->title = $request->get('title');\n $course_resources->description = $request->get('description');\n $course_resources->file_path = $File;\n\n\n $course_resources->save();\n return redirect(action('CourseResourcesController@edit', $course_resources->id))->with('status', 'The file has been updated!');\n }", "title": "" }, { "docid": "611dd800c7185eb18c8f75c9a8595a6c", "score": "0.57606536", "text": "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n $product->name = $request->name;\n $product->rock = $request->rock;\n $product->weight = $request->weight;\n $product->carat = $request->carat;\n $product->stock = $request->stock;\n $product->price = $request->price;\n $product->color = $request->color;\n $product->category_id =Category::find($request->category_id)->id;\n\n if($request->hasFile(\"image\")){\n //delete old image and save new image\n unlink(storage_path('app/public/productImages/'. $product->src));\n $product->src=$request->image->hashName();\n $request->image->store(\"productImages\",\"public\");\n }\n \n if($product->save()){\n return redirect()->route('products.index');\n }else{\n return view(\"partials.error\");\n }\n }", "title": "" }, { "docid": "3b6c3aaa23b4fb918ebc093545c13dc6", "score": "0.57525045", "text": "public function update($entity);", "title": "" }, { "docid": "eaf18f66946228a152f8b83c6b49e31e", "score": "0.5747208", "text": "public function update($id, $data) {}", "title": "" }, { "docid": "ab7c78237c36ea0911a0a7aba52fe065", "score": "0.5722473", "text": "public function updateEntities($resource)\n {\n $json = [\n 'resource' => $resource,\n ];\n $body = json_encode($json);\n $request = new Request('PUT', '/entities', [], $body);\n $response = $this->send($request);\n return $response;\n }", "title": "" }, { "docid": "94a50f00a1fdfc16d75925e06f8f3ece", "score": "0.5718023", "text": "public function update($resource, $id, array $data = [], array $fileData = [],\n array $options = []\n ) {\n $request = new Request(Request::UPDATE, $resource);\n $request->setId($id)\n ->setContent($data)\n ->setFileData($fileData)\n ->setOption($options);\n return $this->execute($request);\n }", "title": "" }, { "docid": "8d0a97cdf24a3e49996a055c1d6f9ee9", "score": "0.5674049", "text": "public function put($data);", "title": "" }, { "docid": "dd89d251e44d4f4288498c4f3fcdbd27", "score": "0.5669232", "text": "public function update(StoreQuestionRequest $request, Question $question)\n {\n $question->update($request->all());\n return (new QuestionResource($question))->response()->setStatusCode(Response::HTTP_OK);\n }", "title": "" }, { "docid": "07d0f77b1ff351c39ea339ec0c30336e", "score": "0.5668569", "text": "public function update(Request $request, $id)\n {\n $product=Product::find($id);\n $photo=$product->photo;\n if($request->file('photo')){\n $photo=$request->file('photo')->store('public/products');\n \\Storage::delete($product->photo);\n \n \n }\n $product->name=$request->name;\n $product->category_id=$request->category;\n $product->subcategory_id=$request->subcategory;\n $product->description=$request->description;\n $product->photo=$photo;\n $product->price=$request->price;\n $product->quantity=10;\n $product->update();\n notify()->success('Product Update Successfully!');\n return redirect('/product');\n }", "title": "" }, { "docid": "50feec899487537246234315718a4677", "score": "0.56560737", "text": "public function updated(Octocat $resource)\n {\n session()->flash('title', $resource->name);\n session()->flash('message', \"Octocat successfully updated\");\n session()->flash('type', 'success');\n }", "title": "" }, { "docid": "6310b8a0a92465d8b22379c86deeecd7", "score": "0.564211", "text": "public function put($resource, array $parameters = [], $headers = [])\n {\n return $this->request('PUT', $resource, [\n 'form_params' => $parameters,\n 'headers' => $headers,\n ]);\n }", "title": "" }, { "docid": "d31fe3056f944a65fa9ec19317300e44", "score": "0.5622648", "text": "public function update(Request $request)\n {\n \t$validator = Validator::make($request->all(), [\n 'title' => 'required',\n 'id' => 'required',\n 'url' => 'required'\n ]);\n if ($validator->fails()) {\n return redirect(route('manage-contractor-resources-edit', $request->id))\n ->withErrors($validator)\n ->withInput();\n }\n\n $info['title'] = $request->title;\n $info['url'] = $request->url;\n $info['chapter'] = $request->chapter;\n $info['description'] = $request->description;\n $id = $info['id'] =$request->id;\n if(!$id){ \n $request->session()->flash('error', \"Nothing to update (or) unable to update.\");\n return redirect(route('manage-contractor-resources'))->withInput();\n }\n if((new ContractorResource)->updateContractorResource($info)) {\n $request->session()->flash('success', \"Contractor Resource Updated Successfully.\");\n return redirect(route('manage-contractor-resources'));\n } else { \n $request->session()->flash('error', \"Nothing to update (or) unable to update.\");\n return redirect(route('manage-contractor-resources'))->withInput();\n }\n }", "title": "" }, { "docid": "45805699e2ef60790309007e165386e9", "score": "0.5617589", "text": "public function update(Request $request, $id)\n {\n if(count($request->all()) == 0)\n {\n return redirect()->route('home');\n }\n $item = Item::where('id', $id)->first();\n \n if($item)\n { $this->validate($request, [\n 'itemDescription' => ['required']\n ]); \n $item->itemDescription = $request->get('itemDescription');\n $item->inventoryID = $request->get('inventoryID');\n if($request->file('select_file'))\n { \n $this->validate($request, ['select_file' => 'image|mimes:jpeg,png,jpg,gif|max:2048']);\n $image = $request->file('select_file');\n $path = $image->store('stock', 's3');\n\n $item->photoUploadLink = $path;\n }\n $item->save();\n return redirect()->route('stock')->with('success','Stock was successfully updated.');\n }\n else{\n return redirect()->route('stock')->with('error','Unfortunately an error has occurred.');\n }\n }", "title": "" }, { "docid": "0ca7ba7cd4456dc2a52499c097eb460d", "score": "0.5611832", "text": "public function update(Request $request, Memory $memory)\n {\n \n }", "title": "" }, { "docid": "28ac32d59483ead96eb99c3920d2d977", "score": "0.56017566", "text": "public function update( Request $request, $id ) {\n if ( $request->hasFile( 'newphoto' ) ) {\n\n $file = $request->file( 'newphoto' );\n $file_name = time() . '.' . $file->extension();\n $file->move( public_path( 'backend/supplier/' ), $file_name );\n\n $supplier = Supplier::find( $id );\n\n $oldPhoto = $supplier->photo;\n\n if ( $oldPhoto ) {\n $photo_url = $oldPhoto;\n $part = explode( '/', $photo_url );\n $slicedArr = array_slice( $part, 3 );\n $photoStr = implode( '/', $slicedArr );\n unlink( $photoStr );\n }\n\n $supplier->name = $request->name;\n $supplier->email = $request->email;\n $supplier->address = $request->address;\n $supplier->phone = $request->phone;\n $supplier->shopname = $request->shopname;\n $supplier->photo = asset( \"backend/supplier/{$file_name}\" );\n $supplier->save();\n return $request;\n } else {\n $supplier = Supplier::find( $id );\n\n $supplier->name = $request->name;\n $supplier->email = $request->email;\n $supplier->address = $request->address;\n $supplier->phone = $request->phone;\n $supplier->shopname = $request->shopname;\n $supplier->photo = $request->photo;\n $supplier->save();\n return $request;\n }\n }", "title": "" }, { "docid": "a9e48624384796f4304eebd40f4ae1bc", "score": "0.5599046", "text": "public function update()\n {\n $id = Input::get('id');\n $obj = Product::find($id);\n if ($obj == null) {\n return view('404');\n }\n $obj->name = Input::get('name');\n $obj->images = Input::get('images');\n $obj->description = Input::get('description');\n $obj->price = Input::get('price');\n $obj->save();\n return redirect('/admin/product');\n }", "title": "" }, { "docid": "feafa85fd136a8bfa7378058dbef8934", "score": "0.55935574", "text": "public function update(StoreQuestion $request, Question $question)\n {}", "title": "" }, { "docid": "5583a1a1065b5e63099c0ebbfcc38083", "score": "0.55854446", "text": "public function modifyResource($uri,\n $sparql = \"\",\n $headers = [],\n $transaction = \"\") {\n $options = [];\n\n // Set content.\n $options['body'] = $sparql;\n\n // Set headers.\n $options['headers'] = $headers;\n $options['headers']['Content-Type'] = 'application/sparql-update';\n\n // Ensure uri takes transaction into account.\n $uri = $this->prepareUri($uri, $transaction);\n\n $response = $this->client->request(\n 'PATCH',\n $uri,\n $options\n );\n\n return null;\n }", "title": "" }, { "docid": "4016847dea9b55e59a4acd18600a30f5", "score": "0.55813426", "text": "public function update($request, $id);", "title": "" }, { "docid": "15b871253c843a97a53c3d5984ec74b9", "score": "0.5576059", "text": "public function update(Request $request, $id)\n {\n //\n $this->validate($request, [\n 'name' => 'required',\n 'price' => 'required',\n 'image_url' => 'image|nullable|max:1999'\n ]);\n\n $product = Product::find($id);\n $product->name = $request->input('name');\n $product->price = $request->input('price');\n $product->groups = $request->input('groups');\n $product->stocks = $request->input('stocks');\n $product->description = $request->input('description');\n //to handle file in updload this way if no new image added the image \n //wont be updated.\n if ($request->hasFile('image_url')){\n //to get the filename with ext\n $file = $request->file('image_url')->getClientOriginalName();\n //get file name\n $filename = pathinfo($file, PATHINFO_FILENAME);\n //get extensiopn\n $ext = $request->file('image_url')->getClientOriginalExtension();\n //new filename\n $fileNameToStore = $filename.'_'.time().'.'.$ext;\n #upload\n $path = $request->file('image_url')->storeAs('public/images', $fileNameToStore);\n }else{\n $fileNameToStore = $product->image_url;\n }\n $product->image_url= $fileNameToStore;\n $product->save();\n\n return redirect('/');\n }", "title": "" }, { "docid": "d30de7511ec7de74e32f94e01d31fafe", "score": "0.5566411", "text": "public function update(Request $r, $id){\n $prk = Portkey::find($id);\n $prk->name = $r->name;\n \n if(isset($r->image)){\n Storage::disk('portkeyMap')->delete($prk->image);\n $path = $r->file('image')->store('', 'portkeyMap');\n $prk->image = $path;\n }\n $prk->save();\n return redirect()->route('portkey.index');\n }", "title": "" }, { "docid": "f77c93b62808595a63d9f6f31b1f80e0", "score": "0.55661047", "text": "public function updateStream($path, $resource, Config $config)\n {\n return $this->writeStream($path, $resource, $config);\n }", "title": "" }, { "docid": "0af57b3d439623d9ddfbbd2c23e24b1f", "score": "0.55599797", "text": "public function update($id, $data);", "title": "" }, { "docid": "8f8dacf3ca2fb2c9044973cfcebc7c92", "score": "0.555745", "text": "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n if(!empty($request->input('tags'))){\n $product->tags()->sync($request->input('tags'));\n }else {\n $product->tags()->detach();\n }\n\n //gestion sup image\n if($request->input('delete_picture')=='true'){\n if(!is_null($product->picture)) {\n Storage::delete($product->picture->uri);\n $product->picture->delete();\n }\n }\n\n //gestion de la modification image\n if(!is_null($request->file('thumbnail'))){\n if(!is_null($product->picture)) {\n Storage::delete($product->picture->uri);\n $product->picture->delete();\n }\n\n $im = $request->file('thumbnail');\n $ext = $im->getClientOriginalExtension();\n $uri = str_random(12).'.'.$ext;\n $picture = Picture::create([\n 'uri' => $uri,\n 'type' => $ext,\n 'size' => $im->getClientSize(),\n 'product_id' => $product->id\n ]);\n\n $request->file('thumbnail')->move(env('UPLOAD_PATH','./uploads'), $picture->uri);\n\n }\n\n $product->update($request->all());\n return redirect('product')->with(['message'=>'success']);\n }", "title": "" }, { "docid": "603c333c3d11c6ec2de9c240d7fa4363", "score": "0.55474466", "text": "public function update(Request $request, $id)\n {\n $image = $request->file('image')->store('product', 'public');\n $product = Product::find($id);\n\n $product->nombre = $request->input('nombre');\n $product->descripcion = $request->input('descripcion');\n $product->precio = $request->input('precio');\n $product->stock = $request->input('stock');\n $product->category_id = $request->input('category_id');\n $product->image = $image;\n \n $product->save();\n\n return redirect(\"/$product->id/showProduct\"); \n }", "title": "" }, { "docid": "7412cf8d4f3cd118bf4c8ef71352185b", "score": "0.5544467", "text": "public function update(Request $request, Restify $restify)\n {\n //\n }", "title": "" }, { "docid": "4c0ab51ecbeaff3788498a88d8e05dde", "score": "0.55394554", "text": "public function update($id) {\n \n }", "title": "" }, { "docid": "66139d48c34ab92a5f49f5d92e5064cc", "score": "0.55334014", "text": "public function put_products($productName)\n{\n $raw = file_get_contents('php://input');\n $newProduct = Product::fromJson($raw);\n\n $db = new DataStore();\n $db->beginTransaction();\n $oldProduct = Product::productByName($db, $productName);\n if (is_null($oldProduct))\n throw new RESTException('Product not found.', 404);\n\n $oldProduct->update($db, $newProduct);\n $db->commit();\n echo('Product ' . $productName . ' updated.');\n}", "title": "" }, { "docid": "45a4f9a4a649b70b7c4d70ad32264661", "score": "0.5530422", "text": "public function update(Request $request,$id)\n { \n $slider = Slider::find($id);\n //start image upload\n if($request->file('image') != \"\"){\n $_IMAGE = $request->file('image');\n $name = time().$_IMAGE->getClientOriginalName();\n $uploadPath = 'public/frontend/images/main-slider/';\n $_IMAGE->move($uploadPath,$name);\n $_imageUrl = $uploadPath.$name;\n\n //delete previous image\n if(!empty($slider->image)){\n try{\n unlink(\"$slider->image\");\n }\n catch(\\Exception $e){\n\n }\n finally{\n $flag = true; \n }\n }\n //store updated image\n $slider->image = $_imageUrl;\n\n }\n //end image upload\n $slider->type = $request->type;\n $slider->title = $request->title;\n $slider->sub_title = $request->sub_title;\n $slider->redirect_link = $request->redirect_link;\n $slider->active = $request->active;\n $slider->slider_order = $request->slider_order;\n $slider->save();\n\n return redirect('/admin/sliders')->with('success',' Data Updated');\n }", "title": "" }, { "docid": "0b10222182779f95692d101f822f75b6", "score": "0.55273986", "text": "public function update(Request $request, $id)\n {\n\n $slider=Slider::findorfail($id);\n $this->validate($request,[\n \"title\"=>\"required|max:100\",\n \"image\"=>\"nullable|image\"\n ]);\n\n $slider->name=$request->get(\"title\");\n if($request->hasFile(\"image\")){\n $old_location=public_path(\"images/slider/\".$slider->image_url);\n if(file_exists($old_location))\n unlink($old_location);\n\n $dblocation=uniqid(true).'.png';\n $location=public_path('images/slider/'.$dblocation);\n $file=$request->file(\"image\");\n Image::make($file)->encode(\"png\")->save($location);\n $slider->image_url=$dblocation;\n }\n\n $slider->save();\n Session::flash(\"success\",\"Slider has been updated\");\n\n return redirect()->back();\n\n\n }", "title": "" }, { "docid": "122628d1e06ea888611a75c166b89b4c", "score": "0.552677", "text": "public function patch($data) {\n if (isset($data['id']) && !is_numeric($data['id'])) {\n // Throw an error....\n return new ResourceResponse(\n [\n 'error' => t('You must provide an valid ID when updating a resource.'),\n ],\n ResourceResponse::HTTP_BAD_REQUEST\n );\n }\n $file_system_access_entity = entity_load('file_system_access', $data['id']);\n if (empty($file_system_access_entity)) {\n return new ResourceResponse(\n [\n 'error' => t('Resource not found.'),\n ],\n 404\n );\n }\n if (isset($data['entity_id']) && is_numeric($data['entity_id'])) {\n $file_system_access_entity->set('entity_id', $data['entity_id']);\n }\n if (isset($data['entity_type'])) {\n $file_system_access_entity->set('entity_type', $data['entity_type']);\n }\n if (isset($data['can_view']) && in_array($data['can_view'], [0, 1])) {\n $file_system_access_entity->set('can_view', $data['can_view']);\n }\n if (isset($data['can_write']) && in_array($data['can_write'], [0, 1])) {\n $file_system_access_entity->set('can_write', $data['can_write']);\n }\n if (isset($data['notify_of_upload']) && in_array($data['notify_of_upload'], [0, 1])) {\n $file_system_access_entity->set('notify_of_upload', $data['notify_of_upload']);\n }\n if (isset($data['user_id'])) {\n $file_system_access_entity->set('user_id', ['target_id' => $data['user_id']]);\n }\n // Save the FileSystemAccess Entity.\n $file_system_access_entity->save();\n // Return reponse.\n return new ModifiedResourceResponse(NULL, 202);\n }", "title": "" }, { "docid": "a82e18d865c6a0f13355d38c12c144b4", "score": "0.5523652", "text": "public function updateFilepath(){\n if(!empty($this->originalResource)){\n $this->setFilepath($this->getOriginalResource()->getIdentifier());\n }\n }", "title": "" }, { "docid": "c2ba30e945f68db8e69ec9299a2bf860", "score": "0.55200166", "text": "public function setResource($resource){\n $this->resource = $resource;\n }", "title": "" }, { "docid": "66fbae8975fea1c3ac6a3142735e3664", "score": "0.55114806", "text": "public function update(Request $request, $id)\n {\n $lens = Lens::find($id);\n\n File::delete(str_replace('public','storage',$lens->image));\n\n $lens->delete();\n\n $path = $request->file('image')->store('public');\n\n $lens = Lens::create($request->all());\n\n $lens->image = $path;\n $lens->update();\n\n return redirect()->route('lens.index');\n }", "title": "" }, { "docid": "265c7e4e1d9ccb8f2d919846c5c6d0e1", "score": "0.55072427", "text": "public function update($id, $input);", "title": "" }, { "docid": "70d4983ca950042ec52182066262a01f", "score": "0.55057055", "text": "public function update(Request $request, Product $product)\n {\n \n $product->name = $request->name;\n $product->price = $request->price;\n $product->description = $request->description;\n $product->featured = $request->featured;\n $product->image = $request->image;\n $product->category_id = $request->category_id;\n $product->brand_id = $request->brand_id;\n\n $product->save();\n\n return response([\n 'data' => new ProductResource($product)\n ],Response::HTTP_CREATED);\n }", "title": "" }, { "docid": "a1981e95d8e1e839e57300bff0e83269", "score": "0.5500746", "text": "abstract public function update_storage_site();", "title": "" }, { "docid": "012a18ea3549362ce2727f6242b46f5a", "score": "0.5497882", "text": "public function update(UpdateProductRequest $request, $id)\n {\n $products = Product::find($id);\n $path = null;\n $requestData = $request->all();\n if ($request->file('image')) {\n $path = $request->file('image')->store('public');\n @unlink('storage/'. $products->image);\n }\n if($request->hasFile('image')) {\n //\\File::delete($events->image);\n $requestData['image'] = $path;\n// $requestData['image'] = IdomNotification::uploadAndResize($request->file('image'));\n }\n\n\n\n\n// dd($data);\n $products->update($requestData);\n// $idoms->update($requestData);\n\n return redirect('/admin/products')->with('success','Item update successfully!');\n }", "title": "" }, { "docid": "631ec05d06376fc3d4e4c009809fbc97", "score": "0.54973245", "text": "public function update(SliderRequestUpdate $request, $id)\n {\n $slider=Slider::find($id);;\n $slider->TituloSlider=$request->TituloSlider;\n $slider->DescripcionSlider=$request->DescripcionSlider;\n $slider->EstadoSlider=$request->EstadoSlider;\n\n if ($request->file('file')) {\n \n Storage::disk('s3')->delete('sliders/'.$slider->file_name);\n\n $nameFile = $request->file('file');\n \n $newName = time().rand().'.'.$nameFile->getClientOriginalExtension();\n #Amazon\n\n $path = $nameFile->storeAs('sliders', $newName,'s3');\n Storage::disk('s3')->setVisibility($path, 'public');\n \n $slider->file_url=Storage::disk('s3')->url($path);\n $slider->file=$nameFile->getClientOriginalName();\n $slider->file_name=$newName;\n $slider->file_type=$nameFile->getClientOriginalExtension();\n\n }\n\n \n # $slider->file_url\n $slider->update();\n\n return $slider;\n }", "title": "" }, { "docid": "5ec7d4d96d210f32e09b80058c55a490", "score": "0.5496931", "text": "public function update(Request $request, $id){\n $product = Product::find($id);\n // dd($product);\n if($product){\n if($request->description){\n $product->description = $request->description;\n }\n if($request->name){\n $product->name = $request->name;\n }\n if($request->qty){\n $product->qty = $request->qty;\n }\n if($request->price){\n $product->price = $request->price;\n }\n if ($request->hasFile('image')) {\n $img_src = $request->file('image')->store('public/images');\n $product->image_src = $img_src;\n }\n\n return $product->save() ? 'product updated!' : 'could not update the product';\n }else{\n return 'product not found';\n }\n \n }", "title": "" }, { "docid": "ba09590827a6c41287d661376548ea80", "score": "0.5494963", "text": "public function update(Request $request, $client, $resource)\n\t{\n\t\t$resource = Resource::findBySlug($client, $resource);\n\n\t\tif (!$resource) {\n\t\t\treturn response(view('resources.404'), 404);\n\t\t}\n\n\t\t$resource->load('client');\n\t\t$client = $resource->client;\n\n\t\t$this->authorize('manage', $resource);\n\n\t\t$this->validate($request, [\n\t\t\t'name' => ['required', 'max:255'],\n\t\t\t'slug' => [\n\t\t\t\t'required',\n\t\t\t\t'max:255',\n\t\t\t\t'alpha_dash',\n\t\t\t\t'unique:resources,slug,'.$request->input('slug', $resource->slug).',slug,client_id,'.$resource->client->id,\n\t\t\t\t'not_in:create,destroy,edit,prune'\n\t\t\t],\n\t\t\t// 'metadata' => ['array'],\n\n\t\t\t'attachments' => ['array'],\n\t\t\t'uploads' => ['array'],\n\n\t\t\t'type' => ['required'],\n\n\t\t\t'client' => ['required', 'exists:clients,id'],\n\n\t\t\t'tags' => ['array'],\n\t\t\t'tags.*' => ['exists:tags,id'],\n\t\t]);\n\n\t\tif (($newClient = $request->input('client', $resource->client->id)) != $resource->client->id) {\n\t\t\t$client = Client::find($newClient);\n\t\t\t$resource->client()->associate($client);\n\t\t}\n\n\t\t$resource->name = $request->input('name');\n\t\t$resource->slug = $request->input('slug');\n\t\t$resource->metadata = $request->input('metadata', []);\n\n\t\t$attachments = $request->input('attachments', []);\n\n\t\tif ($request->hasFile('uploads')) {\n\t\t\t$uploads = $request->file('uploads');\n\t\t\t$attachments = array_merge($attachments, $uploads);\n\t\t}\n\n\t\t$resource->attachments = $attachments;\n\n\t\t// set type\n\t\tif (!($type = ResourceType::findBySlug($request->input('type')))) {\n\t\t\t$type = ResourceType::create([\n\t\t\t\t'name' => $request->input('type'),\n\t\t\t\t'slug' => str_slug($request->input('type')),\n\t\t\t]);\n\t\t}\n\n\t\t$resource->type()->associate($type);\n\n\t\t$resource->save();\n\n\t\t$resource->tags()->sync($request->input('tags', []));\n\n\t\treturn redirect()->route('clients.resources.show', ['client' => $resource->client->url, 'resource' => $resource->url])\n\t\t\t->with('alert-success', 'Resource updated!');\n\t}", "title": "" }, { "docid": "ebfc2a23b89e301d5a4b298c50156e0d", "score": "0.54949397", "text": "public function update($id);", "title": "" }, { "docid": "ebfc2a23b89e301d5a4b298c50156e0d", "score": "0.54949397", "text": "public function update($id);", "title": "" }, { "docid": "96e3e53de207d1c0165b2f8d9b2e8bd8", "score": "0.5492371", "text": "public function update(Request $request, $id)\n {\n $book = Book::findOrFail($id);\n $path = Storage::putfile('public',$request->file('image'));\n $url = Storage::url($path);\n\n $book->title = $request->title;\n $book->price = $request->price;\n $book->image = $url;\n $book->subject = $request->subject;\n $book->author = $request->author;\n $book->pub_house = $request->pub_house;\n $book->description = $request->description;\n $book->update();\n\n return redirect()->route('land_page');\n }", "title": "" }, { "docid": "f34e0cee27ed61fcc8d340527f1d9673", "score": "0.5490983", "text": "#[Put('/{slug}', middleware: ['auth', 'can:update,slug'])]\n #[Operation(tags: ['Articles'], security: 'BearerToken')]\n #[RequestBody(factory: UpdateArticleRequestBody::class)]\n #[Response(factory: SingleArticleResponse::class, statusCode: 200)]\n #[Response(factory: ErrorValidationResponse::class, statusCode: 422)]\n public function update(Article $slug, UpdateArticleRequest $request): SingleArticleResource\n {\n $slug->update($request->input('article'));\n\n return new SingleArticleResource($slug->loadCount('favoritedBy'));\n }", "title": "" }, { "docid": "4d408504ca6fc63ae1c9b25f108a04b1", "score": "0.5490762", "text": "public function update(Request $request, $id)\n {\n $item = Item::find($id);\n $item->fill($request->all())->save();\n\n //file upload\n if($request->file('image_img')){\n $path = Storage::disk('public')->put('images/photos' , $request->file('image_img'));\n $item->fill(['image_img' => asset($path)])->save();\n }\n\n //tags\n $item->tags()->sync($request->get('tags'));\n\n return redirect()->route('item.index')->with('flash','Article actualizado correctamente.');\n }", "title": "" }, { "docid": "2f3b20927c08bdb57df533acda52a1fe", "score": "0.5490345", "text": "public function update(Request $request) {\n $this->validateItemInput($request);\n \n $item = Db::get()\n ->find(\n $this->classCall, $request->attributes->get('id')\n );\n if (!($item instanceof $this->classCall)) {\n $response = new Response('Trying to update non existing item.');\n $response->setStatusCode(400);\n return $response;\n }\n $oldPath = $item->path;\n $item->update($request->request->all());\n if ($oldPath !== $item->path) {\n $item->path = $this->getUniquePath($item->path);\n }\n Db::get()->persist($item);\n return $item;\n }", "title": "" }, { "docid": "eb69ca57c3bde9f06755b1a82e717baa", "score": "0.54793954", "text": "public function update(Request $request, $id)\n {\n $item = Item::findOrFail($id);\n \n $currentPhoto = $item->photo;\n if ($request->photo != $currentPhoto) {\n $name = time().'.' . explode('/',explode(':', substr($request->photo, 0, strpos($request->photo, ';')))[1])[1];\n\n \\Image::make($request->photo)->save(public_path('/img/item/').$name);\n $request->merge(['photo' => $name]);\n\n $itemPhoto = public_path('/img/item/').$currentPhoto;\n if (file_exists($itemPhoto)) {\n @unlink($itemPhoto);\n }\n }\n $item->update($request->all());\n \n return ['message' => 'Updated Success'];\n }", "title": "" }, { "docid": "ceac6ee3c36ec0367a2b9490feebe7a9", "score": "0.5478989", "text": "public function update(Request $request, $id)\n {\n\n $requestData = $request->all();\n $imagePaths = [];\n\n if ($request->hasFile('path')) {\n for ( $index = 0; $index < sizeof( $requestData['path']); $index++) {\n $imagePath = 'storage/' . $request->file('path')[$index]\n ->store('uploads', 'public');\n array_push($imagePaths, $imagePath);\n }\n }\n $image = Image::findOrFail($id);\n\n if (sizeof($imagePaths) === 0) {\n $requestData['path'] = $image->path;\n $image->update($requestData);\n }\n else {\n $oldImagePath = $image->path;\n $oldImagePath = str_replace(\"storage/\",storage_path('') . '/app/public/' , $oldImagePath);\n\n foreach ($imagePaths as $imagePath){\n\n $requestData['path'] = $imagePath;\n $image->update($requestData);\n }\n\n if(File::exists($oldImagePath)){\n File::delete($oldImagePath);\n }\n }\n\n\n\n return redirect('images/' . $request->get('post_id'))->with('flash_message', 'Image updated!');\n }", "title": "" }, { "docid": "6dbe9a80c3cc7c4c7214a73b919cb78b", "score": "0.54670787", "text": "public function update($request);", "title": "" }, { "docid": "2840f4acb2ccb4170d4557d937e25de4", "score": "0.5465156", "text": "public function update(Request $request, $id)\n {\n $data = Image::find($id);\n $all = $request->all();\n if(is_null($data))\n return response()->json(['error' => 'Resource introuvable'], 404);\n else\n {\n if(isset($all['url']))\n {\n $name = File::image($all['url']);\n if($name)\n {\n $all['url'] = $name;\n }else $all['url'] = $data->url;\n }\n\n $data->update($all);\n $data->categories()->sync($request->categories);\n $data->tags()->sync($request->tags);\n\n return response()->json(new ImageResource($data), 200);\n }\n }", "title": "" }, { "docid": "9080726c97000b95123e3a3548679cb5", "score": "0.5464735", "text": "public function update(Request $request, $id)\n {\n $this->slider = $this->slider->find($id);\n $rule =$this->slider->getRules('update');\n $request->validate($rule);\n $data = $request->except('image');\n\n if($request->image){\n $image_name = uploadImage($request->image,'slider','500x300');\n if($image_name){\n $data['image'] = $image_name;\n if($this->slider->image!= ''){\n deleteImage($this->slider->image,'slider');\n };\n }\n }\n $update = $this->slider->update($data);\n if($update){\n request()->session()->flash('success','Product has been updated');\n }else {\n request()->session()->flash('error','Product has not Been updated');\n\n }\n return redirect()->route('slider.index');\n\n }", "title": "" }, { "docid": "a1d61f0aa122378fb9049378295f5945", "score": "0.54586715", "text": "public function update($entity)\n {\n }", "title": "" }, { "docid": "a1d61f0aa122378fb9049378295f5945", "score": "0.54586715", "text": "public function update($entity)\n {\n }", "title": "" }, { "docid": "a1d61f0aa122378fb9049378295f5945", "score": "0.54586715", "text": "public function update($entity)\n {\n }", "title": "" }, { "docid": "536db9f9519d6601d2b49cdcde95f013", "score": "0.5458005", "text": "public function update(Request $request, $id)\n {\n //\n $this->validate($request,[\n 'id_manufacture' => 'required',\n 'asset_tag' => 'required',\n 'id_category' => 'required',\n 'order_number' => 'required',\n 'qty' => 'required',\n 'min_qty' => 'required',\n 'id_location' => 'required'\n ]);\n $input = $request->all();\n $asset = Assets::find($id);\n if(!empty($input['image'])){\n Storage::delete(public_path('storage'),$asset->image);\n $input['image'] = time().'.'.$request->image->getClientOriginalExtension();\n $request->image->move(public_path('storage/assets/'), $input['image']);\n }else {\n $input = array_except($input, array('image'));\n }\n $input['created_by'] = Auth::user()->name;\n $asset->update($input);\n return redirect()->route('assets.index')->with(['success' => 'Asset updated successfully', 'class' => 'close']);\n }", "title": "" }, { "docid": "db3837780a308513dc99c922897e898e", "score": "0.54579574", "text": "public function update()\n {\n $this->delete();\n $this->save();\n }", "title": "" }, { "docid": "5f36cdc3217c7c251089de9b1597e8a0", "score": "0.54572374", "text": "public static function put(string $resource, array $body = []) {\r\n $response = self::getClient()->request(\r\n \"PUT\",\r\n self::createUrl($resource),\r\n self::createHeaders(!empty($body)),\r\n NullStripper::strip($body)\r\n );\r\n\r\n if (!self::isSuccessful($response)) {\r\n self::handleFailure($response);\r\n }\r\n return self::handleSuccess($response);\r\n }", "title": "" }, { "docid": "8f4a12a4a3962d1da8617ab2c1add338", "score": "0.5455601", "text": "public function update(Request $request, Product $product)\n {\n if($request->image != NULL) {\n #Image uploading\n $storedPath = $request->file('image')->store('public/products'); \n }\n \n \n #Update the current product\n $product->update([\n 'title' => $request->title,\n 'body' => $request->body,\n 'price' => auth()->user()->id == $product->user_id ? $request->price : $product->price,\n 'category' => $request->category,\n 'image_path' => $request->image != NULL ? $storedPath : $product->image_path,\n 'status' => $request->status\n ]);\n\n #Return back to list page\n return redirect('/products');\n }", "title": "" }, { "docid": "19323452d4f8b1e3cc766b966234512d", "score": "0.54551905", "text": "public function update($obj) {\n }", "title": "" }, { "docid": "236d64bd92646776ec0d62483983f6b1", "score": "0.5442009", "text": "public function update($id, $data)\n {\n try {\n $this->logger->info(\"Trying to update resource in database table\");\n $this->checkId($id);\n\n $putValues = $this->putValues($id, $data);\n\n $query = \"UPDATE guest.student SET name = :name, surname = :surname, indexno = :indexno, address = :address WHERE id = :id\";\n $stmt = $this->conn->prepare($query);\n\n $stmt->bindParam(\":id\", $id);\n $stmt->bindParam(\":name\", $putValues[\"name\"]);\n $stmt->bindParam(\":surname\", $putValues[\"surname\"]);\n $stmt->bindParam(\":indexno\", $putValues[\"indexno\"]);\n $stmt->bindParam(\":address\", $putValues[\"address\"]);\n\n $stmt->execute();\n echo \"Resource successfully updated\";\n $this->logger->info(\"Updating resource successful in database table\");\n\n } catch (InvalidIdException $e) {\n $this->logger->warning(\"ID doesn't exist in database table\");\n echo \"Error: \" . $e->getMessage();\n } catch (\\Exception $e) {\n $this->logger->warning(\"Error updating resource in database table\");\n echo \"Error updating resource: \" . $e->getMessage();\n }\n }", "title": "" }, { "docid": "a098fb5d396525d0b997679afe399e81", "score": "0.54363286", "text": "public function update(Request $request, $id)\n {\n\n $product = $this->productRepo->getById($id);\n $request_data = $request->except(['_method', '_token', 'photo', 'product_cats', 'ar', 'en']);\n\n $locale = $request->only('ar', 'en');\n $cats = $request->product_cats;\n\n\n if ($request->hasFile('photo')) {\n /*delete old photo*/\n $oldPath = public_path('/images/products/' . $product->photo);\n $oldThumbPPath = public_path('/images/products/thumb/' . $product->photo);\n File::delete($oldPath, $oldThumbPPath);\n\n $image = $this->upload($request->photo, 'products', true);\n $request_data['photo'] = $image;\n\n }\n\n $this->productRepo->updateData($id, $request_data, $locale, $cats);\n\n return redirect()->route('products.index')->with('update', 'data updated successfully');\n\n\n }", "title": "" }, { "docid": "78c9828cfb522a8b15c9e25aecac3a44", "score": "0.54266506", "text": "public function update(Request $request, $id)\n {\n $order = Order::findOrFail($id);\n $previous_qty = $order->quantity;\n $order->user_id = auth()->id();\n $order->product_id = $request['product_id'];\n $order->quantity = $request['quantity'];\n\n if ($order->save()) {\n Inventory::where('product_id', $order->product_id)->decrement('quantity', $order->quantity);\n Inventory::where('product_id', $order->product_id)->increment('quantity', $previous_qty);\n return new OrderResource($order);\n }\n }", "title": "" }, { "docid": "ecf201c555a1f2a407beb441493f659d", "score": "0.5425398", "text": "public function update(Request $request, $id)\n {\n //\n // dd($request);\n $this->validate($request, [\n 'name' => 'required',\n 'price' => 'required',\n 'point' => 'required',\n 'category' => 'required',\n 'image' => 'image|mimes:jpeg,png,jpg,gif|max:2048',\n ]);\n $new_name = \"\";\n if ($request->hasFile('image')) {\n $image = $request->file('image');\n $new_name = time() . '.' . $image->getClientOriginalExtension();\n Image::make($image)->resize(450, 400)->save(public_path('picture/product/' . $new_name));\n $out_of_stock = Out_of_stock::find($id);\n $out_of_stock->name = $request->get('name');\n $out_of_stock->price = $request->get('price');\n $out_of_stock->point = $request->get('point');\n $out_of_stock->category = $request->get('category');\n $oldpruductname = $out_of_stock->picture;\n $out_of_stock->picture = $new_name;\n Storage::delete('product/'.$oldpruductname);\n } else {\n $out_of_stock = Out_of_stock::find($id);\n $out_of_stock->name = $request->get('name');\n $out_of_stock->price = $request->get('price');\n $out_of_stock->point = $request->get('point');\n $out_of_stock->category = $request->get('category');\n }\n\n $out_of_stock->save();\n return back()->with('success', 'Edit data success');\n }", "title": "" }, { "docid": "4da53910fe95b40fc7708d69a5bc4caf", "score": "0.54252774", "text": "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'title' => 'required',\n 'sub_title' => 'required',\n 'image' => 'required|mimes:jpeg,bmp,png'\n ]);\n $slider = Slider::find($id);\n $image = $request->file('image');\n $filename = $image->getClientOriginalName();\n $filename = time(). '.' . $filename;\n $path = 'upload/slider/'.$filename;\n $storage = Storage::disk('s3');\n $storage->put($path, fopen($image, 'r+'), 'public');\n\n $slider->title = $request->title;\n $slider->sub_title = $request->sub_title;\n $slider->image = $path;\n $slider->save();\n Toastr::success('Slider Successefully Updated!', 'Success', [\"positionClass\" =>\"toast-top-right\"]);\n return redirect()->route('slider.index');\n }", "title": "" }, { "docid": "a4ae1c30e150f5cf694572b68551bd23", "score": "0.5425028", "text": "public function update(Request $request, $id)\n {\n $this->validate($request,[\n 'title'=>'required',\n 'content'=>'required',\n 'date'=>'required',\n 'image'=>'required|image',\n ]);\n $product = Product::find($id);\n $product->edit($request->all());\n $product -> uploadImage($request->file('image'));\n $product->setCategory($request->get('category_id'));\n $product->toggleStock($request->get('in_stock'));\n\n return redirect()->route('products.index');\n }", "title": "" }, { "docid": "f08541062169cb53c21e52b58cdb2dcd", "score": "0.5424735", "text": "public function update(Request $request, $id)\n {\n //\n $id = $request->id;\n $store_edit = Store::find($id);\n $store_edit->store_name = $request->store_name;\n $store_edit->store_tel = $request->store_tel;\n $store_edit->store_type_id = $request->store_type;\n $store_edit->store_lineid = $request->store_line;\n $store_edit->store_contact = $request->store_contact;\n $store_edit->store_address = $request->store_address;\n $store_edit->store_detail = $request->store_detail;\n $store_edit->store_status = $request->store_status;\n $store_edit->store_tax_contact = $request->store_tax_contact;\n $store_edit->store_tax_name = $request->store_tax_name;\n $store_edit->store_tax_id = $request->store_tax_id;\n $store_edit->confirm = $request->confirm;\n $store_edit->store_lat = $request->store_lat;\n $store_edit->store_lng = $request->store_lng;\n $tmp = '';\n if($request->check_list){\n foreach($request->check_list as $key => $item){\n if($key == 0){\n $tmp = $item;\n }\n else{\n $tmp = $item.','.$tmp;\n } \n }\n }\n $store_edit->store_promotion = $tmp;\n $store_edit->store_status = $request->store_status;\n\n\n if($request->hasFile('storeimage')){\n Storage::disk('do_spaces')->delete('stores/'.$store_edit->store_image); \n $newFileName = uniqid().'.'.$request->storeimage->extension();//gen name\n $imageStore = $request->file('storeimage');\n $t = Storage::disk('do_spaces')->put('stores/'.$newFileName, file_get_contents($imageStore), 'public');\n $store_edit->store_image = $newFileName;\n }\n if($request->hasFile('storeimageline')){\n Storage::disk('do_spaces')->delete('stores/'.$store_edit->store_lineid_image);\n $newFileName = uniqid().'.'.$request->storeimageline->extension();//gen name\n $imageStoreLine = $request->file('storeimageline');\n $t = Storage::disk('do_spaces')->put('stores/'.$newFileName, file_get_contents($imageStoreLine), 'public');\n $store_edit->store_lineid_image = $newFileName;\n }\n if($request->hasFile('storeimagetax')){\n Storage::disk('do_spaces')->delete('stores/'.$store_edit->store_tax_image);\n $newFileName = uniqid().'.'.$request->storeimagetax->extension();//gen name\n $imageStoreTax = $request->file('storeimagetax');\n $t = Storage::disk('do_spaces')->put('stores/'.$newFileName, file_get_contents($imageStoreTax), 'public');\n $store_edit->store_tax_image = $newFileName;\n }\n $store_edit->save();\n return redirect()->route('store.index')->with('feedback' ,'แก้ไขข้อมูลเรียบร้อยแล้ว');\n }", "title": "" }, { "docid": "2ed05e577c404795cab2b1dde733d75c", "score": "0.5418497", "text": "public function update(Request $request, $id)\n {\n $datos = $request->except('_token','_method');\n\n if ($request->hasFile('foto')) {\n $artista = Artista::findOrfail($id);\n Storage::delete('public/uploads/'.$artista->id.'/'. $artista->foto);\n $datos['foto'] = $request->file('foto')->getClientOriginalName();\n $request->file('foto')->storeAs('public/uploads/'.$artista->id, $datos['foto']);\n }\n\n Artista::where('id','=',$id)->update($datos);\n return redirect('artista');\n }", "title": "" }, { "docid": "da9aacaea3d57116c579322deaba3198", "score": "0.5416959", "text": "public function update(Request $request, $id)\n {\n try {\n $result = $this->model->find($id);\n\n if ($result) {\n $inputs = $request->except('_token');\n\n if ($request->hasFile('image')) {\n $fileName = time() . '.' . $request->image->getClientOriginalExtension();\n $file = $request->file('image');\n\n Storage::put($this->dishImageStoragePath . $fileName, file_get_contents($file), 'public');\n\n $inputs['image'] = $fileName;\n\n if (isset($result->image) && $result->image) {\n if (Storage::exists($this->dishImageStoragePath . $result->image)) {\n Storage::delete($this->dishImageStoragePath . $result->image);\n }\n }\n }\n\n $isSaved = $result->update($inputs);\n\n if ($isSaved) {\n return redirect($this->moduleRoute)->with(\"success\", __($this->moduleName . \" updated!\"));\n }\n }\n return redirect($this->moduleRoute)->with(\"error\", __(\"Something went wrong, please try again later.\"));\n } catch (\\Exception $e) {\n return redirect($this->moduleRoute)->with('error', $e->getMessage());\n }\n }", "title": "" }, { "docid": "9909c434dfa1fa2de013b52dc098057a", "score": "0.54166603", "text": "public function updateProduct();", "title": "" }, { "docid": "83fd3d73dd82fcaecb92e078c534bdfe", "score": "0.54161036", "text": "public function update(Request $request, $id)\n {\n $data = array();\n $data['status'] = $request->status;\n \n \n $image = $request->newphoto;\n\n if ($image) {\n $position = strpos($image, ';');\n $sub = substr($image, 0, $position);\n $ext = explode('/', $sub)[1];\n\n $name = time().\".\".$ext;\n $img = Image::make($image)->resize(240,200);\n $upload_path = 'backend/supplier/';\n $image_url = $upload_path.$name;\n $success = $img->save($image_url);\n \n if ($success) {\n $data['photo'] = $image_url;\n $img = DB::table('patients')->where('id',$id)->first();\n $image_path = $img->photo;\n $done = unlink($image_path);\n $user = DB::table('patients')->where('id',$id)->update($data);\n }\n \n }else{\n $oldphoto = $request->photo;\n $data['photo'] = $oldphoto;\n $user = DB::table('patients')->where('id',$id)->update($data);\n }\n }", "title": "" }, { "docid": "fa90d4335b5457d60aed5f93219c9fb9", "score": "0.5414578", "text": "function update($resource_id,$options)\n\t{\n\t\t//allowed fields\n\t\t$valid_fields=array(\n\t\t\t//'resource_id',\n\t\t\t//'survey_id',\n\t\t\t'dctype',\n\t\t\t'title',\n\t\t\t'subtitle',\n\t\t\t'author',\n\t\t\t'dcdate',\n\t\t\t'country',\n\t\t\t'language',\n\t\t\t//'id_number',\n\t\t\t'contributor',\n\t\t\t'publisher',\n\t\t\t'rights',\n\t\t\t'description',\n\t\t\t'abstract',\n\t\t\t'toc',\n\t\t\t'subjects',\n\t\t\t'filename',\n\t\t\t'dcformat',\n\t\t\t'changed');\n\n\t\t//add date modified\n\t\t$options['changed']=date(\"U\");\n\t\t\t\t\t\n\t\t//remove slash before the file path otherwise can't link the path to the file\n\t\tif (isset($options['filename']))\n\t\t{\n\t\t\tif (substr($options['filename'],0,1)=='/')\n\t\t\t{\n\t\t\t\t$options['filename']=substr($options['filename'],1,255);\n\t\t\t}\n\t\t}\n\t\t\n\t\t//pk field name\n\t\t$key_field='resource_id';\n\t\t\n\t\t$update_arr=array();\n\n\t\t//build update statement\n\t\tforeach($options as $key=>$value)\n\t\t{\n\t\t\tif (in_array($key,$valid_fields) )\n\t\t\t{\n\t\t\t\t$update_arr[$key]=$value;\n\t\t\t}\n\t\t}\n\t\t\n\t\t//update db\n\t\t$this->db->where($key_field, $resource_id);\n\t\t$result=$this->db->update('resources', $update_arr); \n\t\t\n\t\treturn $result;\t\t\n\t}", "title": "" }, { "docid": "cc834cb0ddf4d709f9b0966aeba0c395", "score": "0.5407511", "text": "public function update(Request $request, Product $product)\n {\n\n if (Auth::id()==$product->user_id) {\n $product->update($request->all());\n\n return response([\n 'data'=>new ProductResource($product)\n ],Response::HTTP_CREATED); \n }\n\n \nelse {\n return response([\n 'error'=>'product doesnt belong to current user'\n ],Response::HTTP_NOT_FOUND); \n}\n // return response()->json(new ProductResource($product), 200); \n\n \n\n \n }", "title": "" } ]
29962c0d7707f3c658863b96defa74cc
Recommend index action(supplier admin)
[ { "docid": "adf3cb72f78b52febbd48c5c72391e10", "score": "0.8367385", "text": "public function actionRecommendAdminIndexSupplier()\n {\n $type = (int)Yii::$app->request->get('type', GoodsRecommend::RECOMMEND_GOODS_TYPE_CAROUSEL);\n if (!in_array($type, GoodsRecommendSupplier::$types)) {\n $code = 1000;\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n $ret = [\n 'code' => 200,\n 'msg' => 'OK',\n 'data' => [\n 'recommend_admin_index_supplier' => [\n 'details' => []\n ]\n ],\n ];\n\n $supplier = UserRole::roleUser(Yii::$app->user->identity, Yii::$app->params['supplierRoleId']);\n $where = 'delete_time = 0 and type = ' . $type . ' and supplier_id = ' . $supplier->id;\n\n $ret['data']['recommend_admin_index_supplier']['details'] = GoodsRecommendSupplier::pagination(\n $where,\n GoodsRecommendSupplier::$adminFields,\n 1,\n GoodsRecommendSupplier::PAGE_SIZE_DEFAULT_ADMIN_INDEX,\n ['sorting_number' => SORT_ASC]);\n return Json::encode($ret);\n }", "title": "" } ]
[ { "docid": "d259910e44b1634fd8e3946aff3cb9bb", "score": "0.7042133", "text": "public function updateSupplierSearchIndex() {\n WP_CLI::success('Beginning Search index update on Suppliers.');\n\n $suppliers = $this->supplierRepository->findAll();\n\n WP_CLI::success(count($suppliers) . ' Suppliers found');\n\n $count = 0;\n\n /** @var \\App\\Model\\Supplier $supplier */\n foreach ($suppliers as $supplier) {\n\n $liveFrameworks = $this->frameworkRepository->findSupplierLiveFrameworks($supplier->getSalesforceId());\n $dpsFrameworkCount = 0;\n $totalFrameworkCount = 0;\n\n /** @var \\App\\Model\\Framework $liveFramework */\n if (!empty($liveFrameworks))\n {\n $totalFrameworkCount = count($liveFrameworks);\n\n foreach ($liveFrameworks as $liveFramework)\n {\n $lots = $this->lotRepository->findAllByFrameworkIdSupplierId($liveFramework->getSalesforceId(), $supplier->getSalesforceId());\n $liveFramework->setLots($lots);\n\n if ($liveFramework->getTerms() == 'DPS' || $liveFramework->getType() == 'Dynamic purchasing system' ){\n $dpsFrameworkCount++;\n }\n }\n }\n\n $alternativeTradingNames = [];\n $lotSuppliers = $this->lotSupplierRepository->findAllById($supplier->getSalesforceId(), 'supplier_id');\n\n if (!empty($lotSuppliers))\n {\n /** @var LotSupplier $lotSupplier */\n foreach ($lotSuppliers as $lotSupplier)\n {\n if (!empty($lotSupplier->getTradingName())) {\n $alternativeTradingNames[$lotSupplier->getTradingName()] = $lotSupplier->getTradingName();\n }\n }\n\n if (!empty($supplier->getTradingName())) {\n $alternativeTradingNames[$supplier->getTradingName()] = $supplier->getTradingName();\n }\n\n $supplier->setAlternativeTradingNames(array_values($alternativeTradingNames));\n }\n\n\n if($this->checkSupplierHaveGuarantor($supplier->getSalesforceId())){\n $supplier->setHaveGuarantor(true);\n }\n\n if (!$liveFrameworks || $dpsFrameworkCount == $totalFrameworkCount ) {\n // Remove Supplier from index\n $this->supplierSearchClient->removeDocument($supplier);\n } else {\n // Either create or update Supplier in index\n $this->supplierSearchClient->createOrUpdateDocument($supplier, $liveFrameworks);\n }\n\n $count++;\n\n if ($count % 50 == 0) {\n WP_CLI::success($count . ' Suppliers imported...');\n }\n\n }\n\n WP_CLI::success('Operation completed successfully.');\n\n return;\n }", "title": "" }, { "docid": "5af43bd3b2a50ac18a325605c2a30ada", "score": "0.7026548", "text": "function supplier()\n\t{\n\t\t$data_supplier = $this->model->get_table('tbl_suppliers');\n\n\t\t# 2. Load supplier view\n\t\t$this->view->load_index('master/suppliers', array('supplier' => $data_supplier));\n\t}", "title": "" }, { "docid": "ba36d6eca7c77cec36e5e209739cfc16", "score": "0.69465965", "text": "public function index()\n {\n return view('admin.supplier.index')\n ->with('suppliers', Supplier::all());\n }", "title": "" }, { "docid": "af983cd79b767a16792e8f0983eb421d", "score": "0.69304526", "text": "public function index()\n {\n return view('admin.supplier.index', ['suppliers' => Supplier::paginate('5')]);\n }", "title": "" }, { "docid": "e2457dae1d2468d9d86ade40701989ae", "score": "0.6857944", "text": "public function index(){\r\n\t\t$data['data'] = $this->supplier_model->getSuppliers();\r\n\t\t$this->load->view('supplier/list',$data);\r\n\t}", "title": "" }, { "docid": "9f4908fa542bae6ce7b4cc539d6ae41a", "score": "0.68499637", "text": "public function index()\n {\n $supplier = Supplier::paginate(7);\n return view('admin.suppliers.index',['supplier'=>$supplier]);\n }", "title": "" }, { "docid": "5968b2103daf2c661e945288c76388f7", "score": "0.6801018", "text": "public function index()\n {\n //\n return view('supplier.index');\n }", "title": "" }, { "docid": "ab5a7c6331820efc608c5dbb9c5daf24", "score": "0.67976326", "text": "public function index()\n {\n //获取推荐数据\n $recommends = DB::table('recommend')->get();\n return view('admin.recommend.index',['recommends'=>$recommends]);\n }", "title": "" }, { "docid": "4cfd7af39f9ea3071d4327cf47f64239", "score": "0.67953616", "text": "public function index()\n {\n $suppliers = Supplier::all();\n return view('admin.supplier.index',compact('suppliers'));\n }", "title": "" }, { "docid": "b2d24cdca6f7231c5ab89fc4f2800af6", "score": "0.67645866", "text": "public function index()\n {\n //\n $supplier = Supplier::all();\n return view('Supplier.index')->with('supplier', $supplier);\n \n \n }", "title": "" }, { "docid": "061f367205e641c06375bfd24141349a", "score": "0.6741578", "text": "public function index()\n {\n $user_id = auth()->user()->id;\n $users_id = User::find($user_id);\n $suppliers = Supplier::All();\n \n return view('supplier.index')->with('users_id',$users_id)->with('suppliers', $suppliers);\n }", "title": "" }, { "docid": "b3c4b794b34f39c5769aad3693f4d8b8", "score": "0.671815", "text": "public function index()\n {\n $suppliers = Supplier::all();\n\n return view('admin.supplier.index')->with('suppliers', $suppliers);\n }", "title": "" }, { "docid": "da7f55936abdd1d990c3a7eb547e271b", "score": "0.67035913", "text": "public function index()\n {\n $suppliers = Supplier::all()->toArray();\n return view('admin.supplier.index',compact('suppliers'));\n }", "title": "" }, { "docid": "06c7a28fa9cef68e91ade7309dec2b6c", "score": "0.670237", "text": "public function admin_index() {\n\n\t}", "title": "" }, { "docid": "06c7a28fa9cef68e91ade7309dec2b6c", "score": "0.670237", "text": "public function admin_index() {\n\n\t}", "title": "" }, { "docid": "07cc5b6d0a4190052977ac0651465339", "score": "0.670188", "text": "public function index()\n {\n $suppliers = Supplier::orderBy('id','desc')->get();\n return view('admin.supplier.index',compact('suppliers'));\n }", "title": "" }, { "docid": "204b52f4c0ace8e3afcf36bf223f9629", "score": "0.66967934", "text": "public function actionIndex()\n {\n $dataProvider = new ActiveDataProvider([\n 'query' => MapProductsupplier::find(),\n ]);\n\t\t$model = new MapProductsupplier();\n $model->load(Yii::$app->request->queryParams);\n\t\t\n return $this->render('index', [\n 'dataProvider' => $dataProvider,\n\t\t\t'model' => $model\n ]);\n }", "title": "" }, { "docid": "02299f394a5fa526c4e505bd72a6a1a1", "score": "0.66847825", "text": "public function index()\n {\n $pageSize = config('app.pageSize');\n $data = DB::table('supplier')->paginate($pageSize);\n return view('supplier.index',['data'=>$data]);\n }", "title": "" }, { "docid": "b093a842e84a2adf148b300a55eeac1c", "score": "0.6675802", "text": "public function suggestAction()\n\t{\n\t\t$rooturl = $this->registry->conf['rooturl'];\n\t\t$rooturl_cms = $this->registry->conf['rooturl_cms'];\n\t\t$rooturl_profile = $this->registry->conf['rooturl_profile'];\n\t\t$rooturl_admin = $this->registry->conf['rooturl_admin'];\n\t\t$currentTemplate = $this->registry->conf['rooturl'] . 'templates/default/';\n\t\t$lang = $this->registry->lang['controller'];\n\t\t\n\t\t//search book\n\t\t$keyword = htmlspecialchars($_GET['q']);\n\t\t\n\t\t$stopSelect = 0;\n\t\t//$keyword = Helper::codau2khongdau($keyword);\n\t\tif(mb_strlen($keyword) < 3)\n\t\t{\n\t\t\t$stopSelect = 1;\n\t\t} \n\t\t\n\t\t//search using Sphinx api\n //search product\n $searchEngine = new SearchEngine();\n $searchEngine->addtable('productindex');\n $searchEngine->searcher->SetFieldWeights(array('pi_title' => 3, 'pi_content' => 1));\n $searchEngine->searcher->SetSortMode(SPH_SORT_EXTENDED, 'pi_onsitestatus DESC, @weight DESC');\n $searchEngine->searcher->setLimits(0, 5, 50000);\n $result = $searchEngine->search($keyword);\n unset($searchEngine);\n\n //search news\n $searchEngine = new SearchEngine();\n $searchEngine->searcher->setLimits(0, 5, 50000);\n $searchEngine->addtable('news');\n $resultExtend = $searchEngine->search($keyword);\n\n //echodebug($result, true);\n\n $seperator = \"|\";\n\n if(count($result['productindex']) > 0)\n {\n echo $rooturl_cms . 'product'.$seperator.$this->registry->lang['controller']['product'].$seperator.'&nbsp;'.$seperator.'0'.$seperator.'&nbsp;'.$seperator.'seperator' . \"\\n\";\n\n foreach($result['productindex'] as $product)\n {\n if(!$product['result_found'])\n {\n $myProduct = new Core_Product($product['id'], true);\n\n $finalprice = Core_RelRegionPricearea::getPriceByProductRegion($myProduct->barcode, $this->registry->region);\n if($finalprice > 0) \n $myProduct->sellprice = $finalprice;\n\n if($myProduct->image == '')\n $imagePath = $currentTemplate . 'images/default.jpg';\n else\n $imagePath = $myProduct->getSmallImage();\n \n $myProduct->name = str_replace('|', '&#124;', $myProduct->name);\n echo $rooturl_cms.'product/edit/id/'.$myProduct->id.$seperator.$myProduct->name.$seperator.$imagePath.$seperator.'&nbsp;'.$seperator.($myProduct->sellprice > 0 ? number_format($myProduct->sellprice) . '&#272;' : 'Hết hàng').$seperator.'product' . \"\\n\";\n }\n }\n }\n\n \n\n if(count($resultExtend['news']) > 0)\n {\n echo $rooturl_cms . 'news'.$seperator.$this->registry->lang['controller']['news'].$seperator.'&nbsp;'.$seperator.'0'.$seperator.'&nbsp;'.$seperator.'seperator' . \"\\n\";\n\n foreach($resultExtend['news'] as $news)\n {\n if(!$news['result_found'])\n {\n $myNews = new Core_News();\n $myNews->id = $news['id'];\n $myNews->title = $news['attrs']['n_title'];\n $myNews->image = $news['attrs']['n_image'];\n $myNews->slug = $news['attrs']['n_slug'];\n\n if($myNews->image == '')\n $imagePath = $currentTemplate . 'images/default.jpg';\n else\n $imagePath = $rooturl . 'uploads/news/' .$myNews->image;\n\n $myNews->title = str_replace('|', '&#124;', $myNews->title);\n echo $rooturl_cms.'news/edit/id/'.$myNews->id.$seperator.$myNews->title.$seperator.$imagePath.$seperator.'&nbsp;'.$seperator.'&nbsp;'.$seperator.'news' . \"\\n\";\n }\n }\n }\n\n\t\t//////////////////////////////////////////////////////////////////////\n\t\t//////////////////////////////////////////////////////////////////////\n\t\t//////////////////////////////////////////////////////////////////////\n\t\t//search user\n\t\t\n\t\t//echo $this->registry->conf['rooturl_admin'] . 'user|'.$this->registry->lang['controller']['user'].'|&nbsp;|0|&nbsp;|seperator' . \"\\n\";\n\t\t/*\n\t\t//if login, search in friend and fanpage\n\t\t$myUserIdList = array();\n\t\t$myFriendIds = Core_Backend_Friend::getFriendIds($this->registry->me->id);\n\t\t\n\t\t$friendList = Core_User::getUsers(array('fidlist' => $myUserIdList, 'fkeywordFilter' => $keyword), '', '', 2);\n\t\t\n\t\t\n\t\tif(!empty($friendList))\n\t\t{\n\t\t\techo $this->registry->me->getUserPath() . '/friend/search?keyword='.$keyword.'|'.$this->registry->lang['default']['mFriend'] . ' &amp; Page'.'|&nbsp;|0|&nbsp;|seperator' . \"\\n\";\n\t\t\tfor($i = 0; $i < count($friendList); $i++)\n\t\t\t{\n\t\t\t\t$authorReplacement = '';\n\t\t\t\tif($friendList[$i]->ispage())\n\t\t\t\t{\n\t\t\t\t\t$myPage = new Core_Page($friendList[$i]->id);\n\t\t\t\t\t$authorReplacement = $myPage->countLike . ' ' . $this->registry->lang['default']['mMember'];\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$authorReplacement = $friendList[$i]->getRegionName(false);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\techo $friendList[$i]->getUserPath() . '|' . $friendList[$i]->fullname . '|' . $friendList[$i]->getSmallImage() . '|&nbsp;|'.$authorReplacement.'|' . 'user' . \"\\n\";\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\tif(strlen($keyword) > 6)\n\t\t{\n\t\t\t$userListTmp = Core_User::getUsers(array('fkeywordFilter' => $keyword), '', '', 2);\n\t\t\t$userList = array();\n\t\t\tfor($i = 0; $i < count($userListTmp); $i++)\n\t\t\t{\n\t\t\t\tif(!in_array($userListTmp[$i]->id, $myUserIdList))\n\t\t\t\t\t$userList[] = $userListTmp[$i];\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\tif(!empty($userList))\n\t\t\t{\n\t\t\t\techo $this->registry->conf['rooturl'] . 'member?search=1&keyword='.$keyword.'|'.$this->registry->lang['default']['mMember'].'|&nbsp;|0|&nbsp;|seperator' . \"\\n\";\n\t\t\t\tfor($i = 0; $i < count($userList); $i++)\n\t\t\t\t{\n\t\t\t\t\t$authorReplacement = '';\n\t\t\t\t\tif($userList[$i]->ispage())\n\t\t\t\t\t{\n\t\t\t\t\t\t$myPage = new Core_Page($userList[$i]->id);\n\t\t\t\t\t\t$authorReplacement = $myPage->countLike . ' ' . $this->registry->lang['default']['mMember'];\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$authorReplacement = $friendList[$i]->getRegionName(false);\n\t\t\t\t\t}\n\t\t\t\t\techo $userList[$i]->getUserPath() . '|' . $userList[$i]->fullname . '|' . $userList[$i]->getSmallImage() . '|&nbsp;|'.$authorReplacement.'|' . 'user' . \"\\n\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t*/\n\t\t\n\t\t\n\t\t\n\t\t//////////////////////////////////////////////////////////////////////\n\t\t//////////////////////////////////////////////////////////////////////\n\t\t//////////////////////////////////////////////////////////////////////\n\t\t//search controller such as: Dang ky, dang nhap, lien he...\n\t\t$c = array();\n\t\t$c['product'] = array($lang['product'], $rooturl_cms . 'product', 4);\n\n\t\t//synonym\n\t\t$c['sanpham'] = $c['product'];\n\t\t\n\t\t//foundController\n\t\t$foundController = array();\n\t\t$foundControllerId = array();\n\t\tforeach($c as $k => $v)\n\t\t{\n\t\t\tif(strpos($k, $keyword) !== false && !in_array($v[2], $foundControllerId))\n\t\t\t{\n\t\t\t\t//array tuan tu, vi de lay phan tu dau index = 0 de set default url cho seperator o duoi\n\t\t\t\t$foundController[] = $v;\n\t\t\t\t$foundControllerId[] = $v[2];\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\t\n\t\tif(count($foundController) > 0)\n\t\t{\n\t\t\techo $foundController[0][1] . '|Quick Menu|&nbsp;|0|&nbsp;|seperator' . \"\\n\";\n\t\t\tforeach($foundController as $controller)\n\t\t\t{\n\t\t\t\techo $controller[1] . '|' . $controller[0] . '|'.$this->registry->currentTemplate . 'images/plainicon.jpg' . ' |0|&nbsp;|' . 'controller' . \"\\n\";\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "2a879b0638edb397026c9e171b2e66d6", "score": "0.66694134", "text": "public function index()\n {\n $datas=Suplier::get();\n return view('admin.supplier.manage_supplier',compact('datas'));\n }", "title": "" }, { "docid": "fc4ff4b7216ad7e7aad88e93c5146244", "score": "0.66559327", "text": "public function index()\n {\n $suppliers = Supplier::latest()->get();\n return view('admin.supplier.index', compact('suppliers'));\n }", "title": "" }, { "docid": "5f28cf37253db7d6229b297aefc83f7a", "score": "0.6653773", "text": "public function admin_index() {\n }", "title": "" }, { "docid": "af6b1e4eb8e91f0405a9d6718459105d", "score": "0.6651259", "text": "public function index()\n {\n $data['title'] = \"Supplier\";\n $data['supplier'] = $this->admin->get('supplier');\n $this->template->load('templates/dashboard', 'supplier/data', $data);\n }", "title": "" }, { "docid": "3c1808db6189f621916fb5394028fbec", "score": "0.66334903", "text": "public function index()\n {\n return view('pages.supplier.index');\n }", "title": "" }, { "docid": "5b953f83880f46dd3a06f235539541cc", "score": "0.66233337", "text": "public function supplier(){\n\n $data = $this->get_session_data();\n\n $data['title'] = 'ALS - Supplier';\n $this->parser->parse('templates/header.php', $data);\n\n $this->load->model('Supplier_model');\n $data['records'] = $this->Supplier_model->select_all();\n $this->parser->parse('masters/suppliers/index.php', $data);\n\n $this->parser->parse('templates/footer.php', $data);\n }", "title": "" }, { "docid": "5fed4d35cbb98bed56bbfb5d39da0f8f", "score": "0.66141206", "text": "public function actionIndex()\n {\n $searchModel = new YaeSupplierSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "title": "" }, { "docid": "18eb9ceeae8713d6e1f5297ea38b061c", "score": "0.661202", "text": "public function index()\n {\n $title='Supplier';\n $supplier=Supplier::paginate(5);\n //dd($suplier);\n return view('admin.supplier',compact('title','supplier'));\n //\n }", "title": "" }, { "docid": "021095f79d38faca4932beec6ee1e20d", "score": "0.6609608", "text": "public function index()\n {\n if(Auth::User()->role == 'Super Admin'){\n $supplier = Supplier::all();\n //para ascending\n $suppliers = \\DB::table('suppliers')->orderBy('id','desc')->get();\n // \\Session::flash('flash_message','You are now logged in!.'){{ Auth::user()->name }};\n return view('/supplier/index', compact('supplier'));\n }\n return back();\n }", "title": "" }, { "docid": "0a07774dc03dbb2428705694786f624a", "score": "0.6598737", "text": "public function moderator_index()\n {\n // TODO same as index()\n }", "title": "" }, { "docid": "f069d67647ea740aaf7c5f3666bad0e3", "score": "0.6597923", "text": "public function index()\n {\n $suppliers = Supplier::orderBy('name')->paginate(10);\n return view('supplier.index', compact('suppliers'));\n }", "title": "" }, { "docid": "1c49f1332d9834746de95b18b05da611", "score": "0.6596826", "text": "public function index()\n {\n return view('admin.supplier');\n }", "title": "" }, { "docid": "3faff779eba5f8e6dec1083f400023f5", "score": "0.65783614", "text": "public function index()\n {\n $suppliers = Supplier::all();\n return view('Supplier/index',['suppliers' => $suppliers]);\n }", "title": "" }, { "docid": "a52c8972b39801a7c869d384669d6950", "score": "0.65607476", "text": "public function index()\n {\n $models =Client::orderBy('id','DESC')->where('type','Supplier')->get();\n return view('admin.supplier.index',compact('models'));\n }", "title": "" }, { "docid": "0423994c363763851372aeebdd91b02b", "score": "0.6557328", "text": "public function index()\n {\n return view('suppliers.supplier');\n }", "title": "" }, { "docid": "e6f1fff968dcbcc121c3ffa764a57e0e", "score": "0.654647", "text": "public function index()\n {\n $supplier = Suppliermodel::all();\n $data['supplier'] = $supplier;\n\n return view('admin/supplier', $data);\n }", "title": "" }, { "docid": "bb41e322deeec1b685ad11677ba1c235", "score": "0.65438956", "text": "public function index(){\n $total_supplier = supplier::count();\n $supplier_data = supplier::all();\n\n return view('supplier.index',compact('total_supplier','supplier_data'));\n }", "title": "" }, { "docid": "ac3d2d01b338ba6a575aeda06c86ab14", "score": "0.65364826", "text": "public function index()\n {\n //\n $suppliers = Supplier::paginate(10);\n\n return $suppliers;\n }", "title": "" }, { "docid": "28085ca1f82ecc1cdd30de2ff59e4a64", "score": "0.6523209", "text": "public function actionRecommendAddSupplier()\n {\n $recommend = new GoodsRecommendSupplier;\n $recommend->attributes = Yii::$app->request->post();\n $recommend->status = GoodsRecommend::STATUS_ONLINE;\n if (isset($recommend->district_code)) {\n unset($recommend->district_code);\n }\n\n $code = 1000;\n\n if (!$recommend->validate()) {\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n if ($recommend->sku) {\n $supplier = UserRole::roleUser(Yii::$app->user->identity, Yii::$app->params['supplierRoleId']);\n if (!Goods::checkSupplierGoodsBySupplierIdAndSku($supplier->id, $recommend->sku)) {\n $code = 1039;\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n $goods = Goods::find()->where(['sku' => $recommend->sku])->one();\n $recommend->supplier_id = $supplier->id;\n $recommend->supplier_name = $supplier->shop_name;\n $recommend->url = $goods->id;\n $recommend->platform_price = $goods->platform_price;\n $recommend->description = $goods->subtitle;\n $recommend->title = $goods->title;\n }\n\n if (!$recommend->save()) {\n $code = 500;\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n return Json::encode([\n 'code' => 200,\n 'msg' => 'OK',\n ]);\n }", "title": "" }, { "docid": "9d69d884bb1332c73753029335878887", "score": "0.6505359", "text": "public function index()\n {\n $data = Supplier::all();\n return response()->json([\n 'success' => true,\n 'message' => 'Ini Index Supplier',\n 'data' => $data\n ], 201);\n }", "title": "" }, { "docid": "2cae5da299113e708d16ad7f55ca86b5", "score": "0.64998764", "text": "public function indexAction()\n\t{\t// TODO: database lookup for current proposals\n\t}", "title": "" }, { "docid": "01ef2d95502588c2e9efef3bce1d7fee", "score": "0.6497888", "text": "public function action_index() {\n }", "title": "" }, { "docid": "d4d07652a76e0bbba2b6bfb10d267887", "score": "0.6491157", "text": "function admin_index() {\n\t\t//\n\t}", "title": "" }, { "docid": "5a63015e6e8bc8e83b5ce245a372a2f0", "score": "0.6489133", "text": "public function index()\n {\n $suppliers = Supplier::orderBy('id', 'desc')->get();\n return view('inventory.pages.supplier.index', compact('suppliers'));\n }", "title": "" }, { "docid": "0dfb85b58e27dab03481144e58090679", "score": "0.6475004", "text": "public function index()\n {\n $sups = supplier::all();\n return view('supplier.show',compact('sups'));\n }", "title": "" }, { "docid": "f836828301ea7f6c831944da44e6e988", "score": "0.6461148", "text": "public function index()\n {\n $rewardSuppliers = RewardSupplier::all();\n return $rewardSuppliers;\n }", "title": "" }, { "docid": "0af6900e298f4670636aa57f1e20e955", "score": "0.6456998", "text": "public function index()\n {\n $suppliers= Supplier::all();\n return view('pages.supplier-list', compact('suppliers'));\n }", "title": "" }, { "docid": "69c79c80acee9160f638c33152197fe6", "score": "0.645582", "text": "public function index()\n {\n //\n //$suppliers = Supplier::all();\n $suppliers = Supplier::where('state', 1)\n ->orderBy('id','desc')\n ->get();\n return view('Suppliers.index', compact('suppliers'));\n }", "title": "" }, { "docid": "6297bbe78fbe424ff5df1edc137e7688", "score": "0.644301", "text": "public function index()\n {\n return $Supplier = Supplier::orderBy('id', 'DESC')->get();\n }", "title": "" }, { "docid": "7c7ebee3e25e9c9fc62c535cc7eb35b9", "score": "0.64383566", "text": "public function index()\n\t{\n\t\t$data['content'] = $this->db->get('supplier');\n\t\t$this->load->view('viewSupplier', $data);\n\t}", "title": "" }, { "docid": "f1d6936f14c26f75c8d9cf3f4160e5f4", "score": "0.64334697", "text": "public function actionRecommendEditSupplier()\n {\n $code = 1000;\n\n $id = (int)Yii::$app->request->post('id', 0);\n $recommend = GoodsRecommendSupplier::findOne($id);\n if (!$recommend) {\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n $postData = Yii::$app->request->post();\n if (isset($postData['id'])) {\n unset($postData['id']);\n }\n if (isset($postData['supplier_id'])) {\n unset($postData['supplier_id']);\n }\n if (isset($postData['supplier_name'])) {\n unset($postData['supplier_name']);\n }\n\n $recommend->attributes = $postData;\n\n if (!empty($postData['sku'])) {\n $supplier = UserRole::roleUser(Yii::$app->user->identity, Yii::$app->params['supplierRoleId']);\n if (!Goods::checkSupplierGoodsBySupplierIdAndSku($supplier->id, $recommend->sku)) {\n $code = 1039;\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n $goods = Goods::find()->where(['sku' => $recommend->sku])->one();\n $recommend->supplier_id = $supplier->id;\n $recommend->supplier_name = $supplier->shop_name;\n $recommend->url = $goods->id;\n $recommend->platform_price = $goods->platform_price;\n $recommend->description = $goods->subtitle;\n $recommend->title = $goods->title;\n }\n\n if (!$recommend->validate()) {\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n if (!$recommend->save()) {\n $code = 500;\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n return Json::encode([\n 'code' => 200,\n 'msg' => 'OK',\n ]);\n }", "title": "" }, { "docid": "03a8b47400213af4fe74c54e1e1f9b47", "score": "0.64181334", "text": "public function index()\n {\n $suppliers = Supplier::orderByDesc('active')->get();\n\n return view('suppliers.index', compact('suppliers'));\n }", "title": "" }, { "docid": "3cf63455703b5f27270ec835f4e00fae", "score": "0.64140993", "text": "public function index()\n {\n Flash::message('List of your suppliers and their total amount you have paid them (Restock Cost per supplier)',\n 'info');\n $page = Input::get('page', 1);\n //$path = Input::path(); Input::query\n $sort = Input::only('sortBy', 'direction');\n $search = Input::only('search');\n $suppliers = $this->supplier->all(compact('sort', 'page', 'search'));\n $supplierAmountReport = $this->supplier->suppliersReportAmount();\n $message = \"List of all suppliers and what you have spent on them\";\n $data = json_encode($supplierAmountReport);\n $data = str_replace(\"'\", \"\", $data);\n return View('suppliers/index')->with(compact('suppliers', 'message'))->with('supplierAmountReport', $data);\n }", "title": "" }, { "docid": "59e3003fc975cd1a6598a9717f508fe7", "score": "0.64102834", "text": "public function actionGoodsListAdmin()\n {\n $code = 1000;\n\n $user = Yii::$app->user->identity;\n if (!$user) {\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n $sort = Yii::$app->request->get('sort', []);\n $model = new Goods;\n $orderBy = $sort ? ModelService::sortFields($model, $sort) : ModelService::sortFields($model);\n if ($orderBy === false) {\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n $status = (int)Yii::$app->request->get('status', Goods::STATUS_ONLINE);\n if (!in_array($status, array_keys(Goods::$statuses))) {\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n $where = \"status = {$status}\";\n $keyword = trim(Yii::$app->request->get('keyword', ''));\n if ($keyword) {\n $where .= \" and (sku like '%{$keyword}%' or title like '%{$keyword}%')\";\n }\n\n if ($user->login_role_id == Yii::$app->params['supplierRoleId']) {\n $supplier = Supplier::find()->where(['uid' => $user->id])->one();\n if (!$supplier) {\n $code = 500;\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n $where .= \" and supplier_id = {$supplier->id}\";\n } else {\n $supplierId = (int)Yii::$app->request->get('supplier_id', 0);\n if (!$supplierId) {\n return Json::encode([\n 'code' => $code,\n 'msg' => Yii::$app->params['errorCodes'][$code],\n ]);\n }\n\n $where .= \" and supplier_id = {$supplierId}\";\n }\n\n $page = (int)Yii::$app->request->get('page', 1);\n $size = (int)Yii::$app->request->get('size', GoodsCategory::PAGE_SIZE_DEFAULT);\n $fromLhzz = $user->login_role_id == Yii::$app->params['lhzzRoleId'];\n\n return Json::encode([\n 'code' => 200,\n 'msg' => 'OK',\n 'data' => [\n 'goods_list_admin' => [\n 'total' => (int)Goods::find()->where($where)->asArray()->count(),\n 'details' => Goods::pagination($where, Goods::FIELDS_ADMIN, $page, $size, $orderBy, $fromLhzz)\n ]\n ],\n ]);\n }", "title": "" }, { "docid": "fe6b3db4ec9ca5737f58a285760a4adf", "score": "0.6407579", "text": "public function index()\n {\n return SupplierResource::collection(Supplier::all());\n }", "title": "" }, { "docid": "493f4947b3aab25354473d65038f5f8e", "score": "0.63976437", "text": "public function index()\n {\n $datas = Supplier::paginate(10);\n\n return view('dashboard.admin.supplier', compact('datas'));\n }", "title": "" }, { "docid": "8fe7d0a626a48ae95cc3c908d6442f5d", "score": "0.6392615", "text": "public function actionIndex() {\n echo \"\n--limit = Number \\n\\t use it if you want to increase/decrease the amount of data that will \\n\\t be withdrawn from the Database and stored in Solr at each loop until \\n\\t the end of all data , this is optional by default limit=3000\\n\n--collection = Number \\n\\t use it if you want to perform method on specfic solr component \\n\\t , this is optional by default \\n\\t performs the method on jordan shard solr.\\n \";\n echo $this->getHelp();\n }", "title": "" }, { "docid": "7e6895ede1279836343143cba0d3c50b", "score": "0.6381783", "text": "public function admincp_index() {\n $toolBar = array('addNew','edit', 'show', 'hide', 'delete');\n getToolbar($this->module, $toolBar);\n\n $default_func = 'update';\n $default_sort = 'DESC';\n $data = array(\n 'module' => $this->module,\n\n 'default_func' => $default_func,\n 'default_sort' => $default_sort\n );\n $this->template->write_view('content', 'BACKEND/index', $data);\n $this->template->render();\n }", "title": "" }, { "docid": "dea3d4d0f488a8b988763bd793ad1490", "score": "0.6381225", "text": "public function index()\n {\n if (!Auth::guard('admin_user')->user()->can('suppliers'))\n {\n return view('admin.un-authorized');\n }\n\n return view('admin.supplier_types.index');\n }", "title": "" }, { "docid": "b58dace6323a891ea0373e597c9c0a0b", "score": "0.63801324", "text": "function indexAction() {\n\t\t\t\t\n }", "title": "" }, { "docid": "ada35a329fe97775e0e7d7f7f572d779", "score": "0.63781124", "text": "public function actionIndex() {\n\n try {\n\n $request = Yii::$app->request;\n $getParam = $request->get();\n $searchpage = 'product';\n if(isset($getParam['search-delete']) && !empty($getParam['search-delete'])) // Deleting Search Item\n {\n $this->saveSearches->deleteSearchData($getParam['search-delete']);\n }\n if ($this->saveSearches->getSearchData($searchpage)) {\n $this->searchData = $this->saveSearches->getSearchData($searchpage);\n }\n if ((isset($getParam['search']) && $getParam['search'] == \"true\") || (isset($getParam['filter']))) {\n $this->product->setSearchAttributeValue($getParam); // setting properties of Product models\n }\n if (isset($getParam['Product']) && is_array($getParam['Product'])) {\n $this->product = Helper::setModelByParams($this->product, $getParam['Product']);\n }\n if (Helper::isSeller()) {\n $this->product->employeeIds = AssociateSeller::getAssociatedSeller();\n $this->sellerInfo = AssociateSeller::getAssociatedSellerList();\n \n } else {\n $this->sellerInfo = AssociateSeller::getAllSellerList();\n }\n if(!empty($getParam['sellers']))\n {\n $this->product->employeeIds = $getParam['sellers'];\n }\n \n $this->sellers = AssociateSeller::getAllSellerList();\n \n // // getting all the Products for listing by \n $dataProvider = $this->product->search($getParam);\n $l3cats = $this->product->getL3category();\n\n return $this->render('index', [\n 'searchModel' => $this->product,\n 'dataProvider' => $dataProvider,\n 'l3cats' => $l3cats,\n 'getParam' => $getParam,\n 'searchData' => $this->searchData,\n 'sellers' => $this->sellers,\n 'sellerDetails' => $this->sellerInfo,\n ]);\n } catch (Exception $e) {\n CustomException::errorLog($e->getMessage(), __FUNCTION__, __FILE__, __LINE__);\n }\n }", "title": "" }, { "docid": "536e0ffdd513ea7098eca65eff306c72", "score": "0.637181", "text": "abstract function index_action();", "title": "" }, { "docid": "5f52f341df5cbf39f5d4536e1cc916cf", "score": "0.6370739", "text": "function index() {\n\t\t\n\t\t// no publish filter\n\t\t$conds['no_publish_filter'] = 1;\n\n\t\t$selected_shop_id = $this->session->userdata('selected_shop_id');\n\t\t$shop_id = $selected_shop_id['shop_id'];\n\n\t\t$conds['shop_id'] = $shop_id;\n\n\t\t// get rows count\n\t\t$this->data['rows_count'] = $this->Collection->count_all_by( $conds );\n\n\t\t// get discounts\n\t\t$this->data['collections'] = $this->Collection->get_all_by( $conds , $this->pag['per_page'], $this->uri->segment( 4 ) );\n\n\t\t// load index logic\n\t\tparent::index();\n\t}", "title": "" }, { "docid": "28f53e65aaba3785f9965146cccfee50", "score": "0.63406265", "text": "public function indexAction() {\n \n }", "title": "" }, { "docid": "3e40b68924c6edaec8b53ee7b4117df4", "score": "0.6328403", "text": "public function indexAction() {\n\t\n\t}", "title": "" }, { "docid": "cf5c6f04314ebc02ad2b684fb1390b4e", "score": "0.6326294", "text": "public function admin_index(){\n }", "title": "" }, { "docid": "14dafa73ae621c1804d13da91ff16002", "score": "0.6316313", "text": "public function actionIndex()\n\t{\n\t\t$this->actionAdmin();\n\n\t}", "title": "" }, { "docid": "c0730d65911e0cc05703978c3e1d6a5b", "score": "0.6313645", "text": "public function index()\n {\n $suppliers = Supplier::latest()->get();\n return view('supplier.all-supplier', compact('suppliers'));\n }", "title": "" }, { "docid": "81639ab2485fdb22a4b82c7a2e5c6dfc", "score": "0.6308676", "text": "public function index()\n {\n $suppliers = AddSupplier::all();\n return view('dash.qualified_supplier', ['suppliers' => $suppliers]);\n }", "title": "" }, { "docid": "3669e5ac595af8c636c6b834d800ad9c", "score": "0.63071847", "text": "public function actionIndex()\n\t {\n\t}", "title": "" }, { "docid": "09a9790c8b210d565b9a40d39dd42ed0", "score": "0.6290971", "text": "public function index()\n {\n //TODO: All quizes that I have taken\n }", "title": "" }, { "docid": "7ccb7431ac9d8f84f28c9b9561603fd3", "score": "0.6286154", "text": "public function show($supplier) {\n //\n }", "title": "" }, { "docid": "dcc86bf387ca668a41a2bfd4fab8ed9d", "score": "0.62854046", "text": "public function actionIndex(){\r\n\t\t\r\n\t\t$model = new Pro();\r\n\t\t$criteria = new CDbCriteria();\r\n\t\t\r\n\t\t//$criteria->addCondition(\"is_show=1\");\r\n\t\t$criteria->order = 'id asc';\r\n\t\t$pros = $model->findAll($criteria);\r\n\t\t\r\n\t\t$render='index';\r\n\t\tif($this->_type==2){\r\n\t\t\t$render='index2';\r\n\t\t}\r\n\t\t\r\n\t\t$this->render($render,array(\r\n\t\t\t'pros'=>$pros,\r\n\t\t\t\r\n\t\t));\r\n\t}", "title": "" }, { "docid": "e52a9edd7d69791dd62cc3b0f6c758a4", "score": "0.6279266", "text": "public function actionIndex()\n {\n self::checkAdmin();\n \n $productsList = Product::getProductsList();\n \n require_once (ROOT . '/views/admin_product/index.php');\n return true;\n }", "title": "" }, { "docid": "14e43a363bb0b6ea845b365303a5456d", "score": "0.6269543", "text": "public function index()\n {\n try{\n $suppliers = $this->contactRepository->supplier();\n\n\n return view('report::supplier_report.index', compact('suppliers'));\n } catch (\\Exception $e) {\n \\LogActivity::errorLog($e->getMessage());\n Toastr::error('Operation Failed','Error!');\n return back();\n }\n\n }", "title": "" }, { "docid": "d6111f19a7aca7d26ffbe0986ebf3edd", "score": "0.62612087", "text": "public function indexAction()\n {\n $this->listAction();\n }", "title": "" }, { "docid": "eccba07e77f684551ff39cfae2d492e0", "score": "0.623851", "text": "public function indexAction() {\n\n\t}", "title": "" }, { "docid": "4ff72e66e3b232060d593e2e3f4d16ec", "score": "0.62330186", "text": "public function index() \n {\n $productModel = new ProductModel();\n \n $this->data['newProducts'] = $productModel->getRandomNewProducts(10);\n $this->data['discountProducts'] = $productModel->getRandomDiscountProducts(10);\n \n $this->indexRender();\n }", "title": "" }, { "docid": "cbba1aa63b955ceb578ab073f9e842fb", "score": "0.622787", "text": "public function index()\n {\n $data['page_title'] = 'Supplier Lists';\n\n $data['suppliers'] = Supplier::all();\n\n return view('suppliers.index', $data);\n }", "title": "" }, { "docid": "3fd4e7ba343834c11926ee1296a7a5cc", "score": "0.62273", "text": "public function index()\n {\n $suppliers = Supplier::orderby('name', 'ASC')->get();\n\n return view('suppliers.index', compact('suppliers'));\n }", "title": "" }, { "docid": "cac76b0ebf88d866c6972a78a2c6355a", "score": "0.6226639", "text": "public function indexAction()\n {\n //Check admin logedin or not\n\n $this->checklogin();\n $this->view->messages = $this->_helper->flashMessenger->getMessages();\n $crud = new Admin_Model_CRUD();\n $getData = array();\n if($this->getRequest()->isPost())\n {\n $getData = $this->getRequest()->getPost();\n $searchArr = array(\n 'Title'=>$getData['Title'],\n 'rows'=>$getData['rows'],\n 'page'=>$getData['page'],\n );\n $resulsetold = $crud->getCount( $this->tablefootermnage,['status' =>1 , 'columnType' =>'recommendation'],'id'); \n $crud->searchArr = $searchArr;\n $resultset = $crud->rv_select_static( $this->tablefootermnage,['*'],['columnType'=>'recommendation' ],['id'=> 'DESC']); \n if (count($resultset) > 0) {\n foreach ($resultset as $resultkey => $resultval) {\n $result1[] = [\n 'id' => $resultval['id'],\n 'title' => $resultval['title'],\n 'url' => $resultval['url'],\n 'openType' => $resultval['openType']==1?'New Tab':'Same Tab',\n 'status' => $resultval['status']==1?'Active':'Deactive',\n ];\n }\n }\n $result = Zend_Json::encode($result1);\n $newResult = Zend_Json::decode($result,false); \n $finalResult[\"total\"]=$resulsetold[0]['id'];\n $finalResult[\"rows\"]=$newResult;\n echo json_encode($finalResult);\n exit; \n }\n }", "title": "" }, { "docid": "738846eeddeea5f22d7d75d92f611959", "score": "0.6213687", "text": "function index()\r\n\t{\r\n\t\t$this->advanced();\r\n\t}", "title": "" }, { "docid": "178b927d80a84483365b57cdf46d03c0", "score": "0.6197774", "text": "public function indexAction() {\n\t}", "title": "" }, { "docid": "f47bb73e79ccc72ff679ad7cc5c0c929", "score": "0.6180797", "text": "public function actionIndex()\n\t{\n\t\t$this->actionEdit();\n\t}", "title": "" }, { "docid": "a0bca620873ead4719a089010020371c", "score": "0.6178071", "text": "public function index()\n\t{\n\t\t$data['result']=NULL;\n\t\t$this->setIndex($data);\n\t}", "title": "" }, { "docid": "5f0dcd599be9947bce2dab5f8e2b3599", "score": "0.61744726", "text": "public function indexAction() {}", "title": "" }, { "docid": "449ae4d4d329e09116699113d21893a3", "score": "0.617347", "text": "function adminindexAction() {\n\t\tif ($this->_request->getParam('page')) {\n\t\t\t$this->_curPage = $this->_request->getParam('page');\n\t\t}\n\t\t$db = Zend_Registry :: get('db');\n\t\t$select = $db->select();\n\t\t$select->from(\"campaign_pre_invitation\", '*');\n\t\t//\t\t$select->where(\"campaign_invitation.state = 'ACCEPTED'\");\n\t\t//\t\t$select->where(\"campaign_invitation.consumer_id = ?\", $this->_currentUser->id);\n\t\t$select->order('state desc');\n\t\t$campaignPreInvitations = $db->fetchAll($select);\n //paging\n $this->view->controller = $this->_request->getControllerName();\n $this->view->action = $this->_request->getActionName();\n\t\t$paginator = new Zend_Paginator(new Zend_Paginator_Adapter_Array($campaignPreInvitations));\n\t\t$paginator->setCurrentPageNumber($this->_curPage)->setItemCountPerPage($this->_rowsPerPage);\n\t\t$this->view->paginator = $paginator;\n\t\t$this->_helper->layout->setLayout(\"layout_admin\");\n\t}", "title": "" }, { "docid": "0e1993dbdef63a0642ed947639b0ba01", "score": "0.61680496", "text": "public function actionIndex()\n {\n $recommender = User::find()->count();\n $delicate = Delicate::find()->count();\n $candidate = Candidate::find()->count();\n $position = POsition::find()->count();\n\n return $this->render('index', [\n 'recommender' => $recommender,\n 'delicate' => $delicate,\n 'candidate' => $candidate,\n 'position' => $position,\n\n // 'president' => count($president),\n // 'vicepresident' => count($vicepresident)\n \n ]);\n }", "title": "" }, { "docid": "3f14ff15a31a6f7fb6c09f0fd9d37dcc", "score": "0.6166884", "text": "public function index()\n\t{\n\t\treturn redirect()->to('/supplier');\n\t}", "title": "" }, { "docid": "c59f35b33d456622e68822c3bc7ce23c", "score": "0.61562634", "text": "public function action_index()\n\t{\n\t\t// Call the right method... wait, we only know how to do\n\t\t// one thing (and do it well! :P)\n\t\t$this->action_stats();\n\t}", "title": "" }, { "docid": "9e070a956c74fd9a1f81abc71bbdffd5", "score": "0.61549735", "text": "public function indexAction()\n {\n \n }", "title": "" }, { "docid": "9e070a956c74fd9a1f81abc71bbdffd5", "score": "0.61549735", "text": "public function indexAction()\n {\n \n }", "title": "" }, { "docid": "9e070a956c74fd9a1f81abc71bbdffd5", "score": "0.61549735", "text": "public function indexAction()\n {\n \n }", "title": "" }, { "docid": "d5bb9ca1ae34ecbf67cf7137eed76a76", "score": "0.6152997", "text": "public function index()\n {\n $data = Supplier::all();\n \n return view('supplier.data', compact('data'));\n }", "title": "" }, { "docid": "580824ca6f9cf172b69dea922f92ec72", "score": "0.614805", "text": "function index()\n {\n $this->actionNotFound('index');\n }", "title": "" }, { "docid": "38c551891a2510dc998c42717a5eae06", "score": "0.61449534", "text": "public function actionIndex()\n {\n }", "title": "" }, { "docid": "7d52dac899f7360899b04c1a5ef97f4c", "score": "0.6144427", "text": "private function voltarIndexAction () {\n // Retorna a sessão das preferências do usuário para essa grid\n $sessao = new Orcamento_Business_Sessao ();\n $url = $sessao->retornaOrdemFiltro($this->_controle);\n\n if ($url) {\n // Redireciona para a url salva em sessão\n $this->_redirect($url);\n } else {\n // Redireciona para a url combinada entre modulo/controle/index\n $this->_redirect($this->_modulo . '/' . $this->_controle);\n }\n }", "title": "" }, { "docid": "4e01ae27bb896a684ff78a91ac2ffff5", "score": "0.6143782", "text": "public function indexAction() {\r\n }", "title": "" }, { "docid": "59ba727ea9f764dc224a0b7ba003bc1a", "score": "0.6139558", "text": "function index(){\n\t\t\t// Or could have complete table of sgRNAs...\n\t\t}", "title": "" }, { "docid": "fd3111d58f3bb24eda92daa95c8abff3", "score": "0.61327946", "text": "public function index()\n {\n $username=auth()->user()->username;\n $sql = supplier::where('kd_vendor','=',$username)->first();\n\n $notif = \"Belum Disetujui\";\n if($sql){\n if($sql->vendor_status == '1'){\n $notif=\"Sudah Disetujui\";\n }\n }\n\n $data['page_title'] = 'Supplier';\n return view('supplier::index')->with($data);\n }", "title": "" }, { "docid": "d4e368a18cdbb838044e2e2d43a3665e", "score": "0.61305434", "text": "public function indexAction() {\n return $this->redirectToRoute('product_index');\n }", "title": "" } ]
3b7b4d786819464da9f89d4a80dfd225
Add an external stylesheet that is needed Mostly used by plugins, when they need to have a specified stylesheet added to the page.
[ { "docid": "b5d70ddeac22d302542fad6a60e96e8d", "score": "0.0", "text": "public function addCss($cssName, $useCssPath = true)\n {\n $css = ($useCssPath === true ? $this->cssPath . $cssName : $cssName);\n\n if (!in_array($css, $this->externalCss)) {\n $this->externalCss[] = $css;\n }\n return $this;\n }", "title": "" } ]
[ { "docid": "480bf4884573d5a7498afa7606a6801e", "score": "0.7564229", "text": "static public function add_stylesheet() {\n\t\twp_register_style( 'jquery-ui', self::$protocol . self::$jQueryCssUrl );\n\t\twp_register_style( 'travelmap', self::$pluginPath . 'screen.css' );\n\t\twp_enqueue_style( 'jquery-ui' );\n\t\twp_enqueue_style( 'travelmap' );\n\t}", "title": "" }, { "docid": "90493123e768ea4968f2f297dedda0b9", "score": "0.74898183", "text": "function add_my_stylesheet() {\n $myStyleUrl = WP_PLUGIN_URL . '/cleaner-tags/styles.css';\n $myStyleFile = WP_PLUGIN_DIR . '/cleaner-tags/styles.css';\n if ( file_exists($myStyleFile) ) {\n wp_register_style('myStyleSheets', $myStyleUrl);\n wp_enqueue_style('myStyleSheets');\n }\n }", "title": "" }, { "docid": "475bb4999765af960a49f9f464cb44fb", "score": "0.7238101", "text": "function wppb_add_stylesheet() {\n\n\tif ( is_admin() or ! is_super_admin() ) {\n\t\treturn;\n\t}\n\n\t$wp_version = get_bloginfo( 'version' );\n\n\tif ( $wp_version >= '3.8' ) {\n\t\t$is_older_than_3_8 = '';\n\t} else {\n\t\t$is_older_than_3_8 = '-old';\n\t}\n\n\t$stylesheet_path = plugins_url( 'css/main' . $is_older_than_3_8 . '.css', __FILE__ );\n\twp_register_style( 'current-template-style', $stylesheet_path );\n\twp_enqueue_style( 'current-template-style' );\n\twp_enqueue_script( 'wppb', plugins_url( '/js/app.js', __FILE__ ), array( 'jquery' ) );\n}", "title": "" }, { "docid": "a968c54925b671af5399b1b1687fc3b1", "score": "0.7035206", "text": "public function addStyleSheet($url)\n\t{\n\t\tif (!in_array($url, $this->css)) {\n\t\t\tarray_push($this->css, $url);\n\t\t}\n\t}", "title": "" }, { "docid": "6f3769ac3c9d811c0bd27ed367971063", "score": "0.70244974", "text": "function ldap_addstylesheet() {\r\n\tglobal $current_blog;\r\n\t$schema = ( isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) == 'on' ) ? 'https://' : 'http://';\r\n $myStyleUrl = $schema.$current_blog->domain.$current_blog->path.MUPLUGINDIR.'/ldap/public/ldap_auth.css';\r\n $myStyleFile = WPMU_PLUGIN_DIR . '/ldap/public/ldap_auth.css';\r\n if ( file_exists($myStyleFile) ) {\r\n wp_register_style('wpmu-ldap-css', $myStyleUrl);\r\n wp_enqueue_style('wpmu-ldap-css');\r\n }\r\n}", "title": "" }, { "docid": "83bda485a7bb1012695aebfd6189e5d6", "score": "0.7011272", "text": "public function include_stylesheet($fn)\n {\n if ($this->output->type == 'html') {\n $src = $this->resource_url($fn);\n $this->output->add_header(html::tag('link', array('rel' => \"stylesheet\", 'type' => \"text/css\", 'href' => $src)));\n }\n }", "title": "" }, { "docid": "d8ed5a2cbedc5e20e8a07b6ffc0514ad", "score": "0.6873849", "text": "public function loadAdditionalStyle()\n {\n if ($this->additionalStyle) {\n $this->addStyle($this->additionalStyle);\n return \"<link rel='stylesheet' href='{$this->additionalStyle}' type='text/css'/>\\n\";\n }\n }", "title": "" }, { "docid": "16da0dd6149d219fba147cdb3b443de5", "score": "0.6866581", "text": "function addExternal($css_url, $clear_previous = false)\n\t{\n\t\t// create a new cURL resource\n\t\t$ch = curl_init();\n\t\t\n\t\t// set URL and other appropriate options\n\t\tcurl_setopt($ch, CURLOPT_URL, $css_url);\n\t\tcurl_setopt($ch, CURLOPT_HEADER, 0);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\t\n\t\t// grab URL and pass it to the browser\n\t\t$css = curl_exec($ch);\n\n\t\t$curl_info = curl_getinfo($ch, CURLINFO_CONTENT_TYPE);\n\t\t// close cURL resource, and free up system resources\n\t\tif($curl_info != 'text/css')\n\t\t{\t\t\n\t\t\t$css ='';\n\t\t}//end else\n\t\t\n\t\tcurl_close($ch);\n\t\t\n\t\tif($clear_previous)\n\t\t{\n\t\t\t$this->theme = array();\n\t\t\t$this->theme[$theme] = $css;\n\t\t}//end if\n\t\telse\n\t\t{\n\t\t\t$this->theme[$theme] = $css;\n\t\t}//end else\n\t}", "title": "" }, { "docid": "552f3caaa68f68bd11ea0a318b554de3", "score": "0.6863446", "text": "public static function addStylesheet($filename)\n\t{\n\t\t$app = Factory::getApplication();\n\t\t$doc = Factory::getDocument();\n\n\t\t// Pfade zum suchen von CSS Dateien – werden auch für den URL benutzt!\n\t\t$paths = array(\n\t\t\t\t\t'/templates/' . $app->getTemplate() . '/html/mod_articles_head/css/', // 1. User Override\n\t\t\t\t\t'/media/mod_articles_head/css/' // 2. Basis\n\t\t\t\t\t);\n\t\t\n\t\t// Priorität der Dateierweiterung. Minified-Stylesheets haben die höhere Priorität.\n\t\t$extensions = array(\n\t\t\t\t\t'.min.css',\n\t\t\t\t\t'.css'\n\t\t\t\t\t);\n\n\t\t$parts = explode('.', $filename);\n\n\t\tforeach ($paths as $path)\n\t\t{\n\t\t\tforeach ($extensions as $ext)\n\t\t\t{\n\t\t\t\tif (File::exists(JPATH_ROOT . $path . $parts[0] . $ext))\n\t\t\t\t{\n\t\t\t\t\t$doc->addStylesheet(Uri::root(true) . $path . $parts[0] . $ext);\n\t\t\t\t\tbreak 2;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "d5a652e4fdfa0666a3a9fe951b8d096f", "score": "0.6797756", "text": "public function addStyle($style) {\n\n $getCheck = explode('?', $style);\n\n if (is_file($getCheck[0])) {\n $styleDom = $this->html->createElement('link');\n $domAttribute = $this->html->createAttribute('rel');\n $domAttribute->value = 'stylesheet';\n $styleDom->appendChild($domAttribute);\n $domAttribute = $this->html->createAttribute('href');\n $domAttribute->value = $style;\n $styleDom->appendChild($domAttribute);\n\n } else\n $styleDom = $this->html->createElement('style', $style);\n\n\n $domAttribute = $this->html->createAttribute('type');\n $domAttribute->value = 'text/css';\n\n $styleDom->appendChild($domAttribute);\n\n $this->head->appendChild($styleDom);\n \n }", "title": "" }, { "docid": "f58cc9d7c2dbf92196e0f5b67d16e490", "score": "0.67748976", "text": "function addStylesheet( $src = '', $attributes = array(), $content = '' ) {\n \tglobal $xoops;\n\t\tif ( !empty( $src ) ) {\n\t\t\t$attributes['href'] = $xoops->url( $this->resourcePath( $src ) );\n\t\t}\n\t\tif ( !isset($attributes['type']) ) {\n\t\t\t$attributes['type'] = 'text/css';\n\t\t}\n\t\tif ( !empty( $content ) ) {\n\t\t\t$attributes['_'] = $content;\n\t\t}\n \t$this->setMeta( 'stylesheet', $src, $attributes );\n }", "title": "" }, { "docid": "1c3004cae0ee28c8f14da3aed880fc59", "score": "0.67498374", "text": "function ams_add_style(){\n\t\n\t\tkula_enqueue_style('stylesheet', get_bloginfo('stylesheet_directory').'/css/style.css?v=2', array(), false, 'all');\n\t}", "title": "" }, { "docid": "f19806d1b4d772215d7a316516883893", "score": "0.6696209", "text": "public function addStylesheet($path, $version = null)\n {\n if ($file = $this->path->url($path)) {\n $this->getClass()->addStylesheet($file . $this->getVersion($version));\n }\n }", "title": "" }, { "docid": "6225e65cdac62f670e39326286f2ff75", "score": "0.668406", "text": "protected function addStylesheet($name, $file)\n {\n $GLOBALS['TL_CSS'][$name] = $file;\n }", "title": "" }, { "docid": "069ca992bf0d201c7d3510dc903a29c3", "score": "0.6682736", "text": "protected function loadCustomStyles()\n {\n $this->setVariable('customSheets', \"<link rel='stylesheet' href='\" . \\Config::OPTIONS['baseURI'] . \"stylesheets/customtheme.css'>\");\n }", "title": "" }, { "docid": "d00dea28f9850f2c1eaa8eab0b63b311", "score": "0.66541576", "text": "function add_style ($path, $media='all') {\n\t\tif(isset($path)) {\n\t\t\t$this->__style[] = '<link rel=\"stylesheet\" media=\"'.$media.'\" href=\"'.$path.'\" type=\"text/css\">';\n\t\t} else {\n\t\t\t$this->__style[] = '<style type=\"text/css\">'.$media.'</style>';\n\t\t}\n\t}", "title": "" }, { "docid": "a0f7de69f65a9ab7d3427234c645520b", "score": "0.66116315", "text": "public function add_css() {\n\t\techo '<link rel=\"stylesheet\" href=\"' . SNLM_URL . '/assets/style.css\" type=\"text/css\" media=\"all\" />';\n\t}", "title": "" }, { "docid": "a2a60886798d96c3ddc794412a2d6ffa", "score": "0.66106945", "text": "public static function addStylesheet($filename, $media='screen')\n {\n self::$_css[$filename] = $media;\n }", "title": "" }, { "docid": "37799eb95bb5838a08975be6785085bc", "score": "0.6600329", "text": "function add_css()\n{\n link_custom_css('/info-page.css');\n link_custom_css('/search.css');\n}", "title": "" }, { "docid": "2e03fd6e9928068d8b8898f0eb857e94", "score": "0.652764", "text": "public function enqueue_stylesheet() {\n $load = true;\n // If enqueue fails, maybe the file doesn't exist...\n if (!$this->test_and_enqueue()) {\n // Try to generate it right now.\n $id = Themify_Builder_Model::get_ID();\n $post_data = $GLOBALS['ThemifyBuilder_Data_Manager']->get_data($id);\n\t\t\t\n if ($post_data) {\n // Write Stylesheet\n $this->write_stylesheet(array('id' => $id, 'data' => $post_data));\n $load = !$this->test_and_enqueue();\n }\n }\n else{\n $load =false;\n }\n if ($load) {\n // No luck. Let's do it inline.\n add_action('themify_builder_background_styling', array($this, 'render_styling'), 10, 4);\n }\n }", "title": "" }, { "docid": "559bb45e3cab0f42f3d4db4456278d94", "score": "0.6501819", "text": "function efu_add_stylesheet () {\n\twp_register_style ('Easy_FTP_Upload_css', '/wp-content/plugins/easy-ftp-upload/Easy_FTP_Upload.css');\n\twp_enqueue_style ('Easy_FTP_Upload_css', '/wp-content/plugins/easy-ftp-upload/Easy_FTP_Upload.css');\n}", "title": "" }, { "docid": "415a8240fecba527b849eba72ad8b7ca", "score": "0.6493805", "text": "function add_css()\r\n\t{\r\n\t\twp_register_style('annonces_css_main', ANNONCES_CSS_URL . 'annonce.css', '', ANNONCE_PLUGIN_VERSION);\r\n\t\twp_enqueue_style('annonces_css_main');\r\n\t\twp_register_style('annonces_css_fileuploader', ANNONCES_CSS_URL . 'fileuploader.css', '', ANNONCE_PLUGIN_VERSION);\r\n\t\twp_enqueue_style('annonces_css_fileuploader');\r\n\t}", "title": "" }, { "docid": "a7f0563d7cf3b931e836b0b649478b97", "score": "0.6474102", "text": "public static function add_admin_stylesheet() {\n\t\twp_enqueue_style( 'axisWP', plugins_url( 'css/axis.css', __file__ ), array( 'dashicons' ), '1.0' );\n\n\t\t$params = array(\n\t\t\t'axisJSPath' => plugins_url( 'bower_components/axisjs/dist/index.html', __file__ ),\n\t\t);\n\n\t\tglobal $post;\n\t\tif ( isset($post->ID) ){\n\t\t\t$params['parentID'] = $post->ID;\n\t\t}\n\t\twp_localize_script( 'jquery', 'axisWP', $params ); // Hooking to jQuery just 'cause.\n\t}", "title": "" }, { "docid": "2543c2b60d3bec89222bf692ca39ab9b", "score": "0.64524937", "text": "public function addStyleSheet($source,$globalScope = true){\n $currentFile = $this->getFileLocation(\"$source\");\n if (file_exists($currentFile)){\n echo \"file exists: $currentFile\";\n }\n else {\n echo \"couldn't find file: $currentFile\";\n }\n \n parent::addStyleSheet($source);\n array_push($this->linkScope,$globalScope);\n }", "title": "" }, { "docid": "3786e62e7cf6bf3780d5fbe38e6204f2", "score": "0.6437542", "text": "function urr_custom_stylesheets() {\n\tinclude('main.php');\n}", "title": "" }, { "docid": "7861a59cb830912f437a48d7a6673ec2", "score": "0.6433556", "text": "function addCSS($path) {\n\t\t$this->resources[$path] = __RESOURCE_TYPE_CSS;\n\t}", "title": "" }, { "docid": "34d38b44612ce91c4af9a2be87edda44", "score": "0.64248943", "text": "function cplw_stylesheet() {\n wp_register_style( 'main-style', plugins_url('/css/main.css', __FILE__) );\n wp_enqueue_style( 'main-style' );\n}", "title": "" }, { "docid": "7fffbad54009988dcdff1062d8b1108e", "score": "0.6405995", "text": "function additional_stylesheets() {\n wp_register_style( 'bootstrap', get_template_directory_uri().'/assets/css/bootstrap.min.css' );\n wp_register_style( 'main-styles', get_template_directory_uri().'/assets/css/main-style.css');\n wp_register_style( 'page-styles', get_template_directory_uri().'/assets/css/page-styles.css' );\n // register another file here\n wp_enqueue_style( 'bootstrap' );\n wp_enqueue_style( 'main-styles' );\n wp_enqueue_style( 'page-styles' );\n // wp_enqueue_style( 'font-awesome1' );\n // enqueue another file here\n }", "title": "" }, { "docid": "8ae43dda26f13cc63a99579e02834950", "score": "0.6405588", "text": "function enqueue_styles() { \n\tif( function_exists( 'w3tc_styles' ) ) {\n\n\t\tw3tc_styles( 'include' );\n\t\n\t/* Otherwise, add stylesheet in the head */\n\t} else {\n\n\t\twp_register_style( 'dynamic', get_bloginfo('home') . '/?css=dynamic' );\n\n\t\twp_enqueue_style( 'dynamic' );\n\t}\n}", "title": "" }, { "docid": "5da0e2a0a5405dcf7d112a6ae7bad245", "score": "0.64040136", "text": "public function add_css($css)\r\n\t{\r\n\t\t$css = file_get_contents($css);\r\n\t\t$this->pdf->WriteHTML($css, 1);\r\n\t}", "title": "" }, { "docid": "4f175d59b73a18cd73e2145af7403774", "score": "0.63974285", "text": "private function addCSS($link) {\r\n $this->css_files .= \"<link href='{$link}' rel='stylesheet' type='text/css'>\";\r\n }", "title": "" }, { "docid": "1e363367bb0bccfd0bb85a74175f574d", "score": "0.638573", "text": "function add_css() {\n echo '<link rel=\"stylesheet\" href=\"'\n . get_settings('home')\n . \"/wp-content/plugins/coolcode/coolcode.css\\\" />\\n\";\n }", "title": "" }, { "docid": "8071f7d0328021ed51656e138e769e37", "score": "0.6384229", "text": "public function stylesheetAdd( $handle, $src = '', $deps = [], $ver = false, $media = 'all' )\n\t{\n\t\t$this->stylesheets_to_add[] = [\n\t\t\t'handle' => $handle,\n\t\t\t'src' => $src,\n\t\t\t'deps' => $deps,\n\t\t\t'ver' => $ver,\n\t\t\t'media' => $media,\n\t\t];\n\t}", "title": "" }, { "docid": "8e1e295d460ae24752edf0532774e771", "score": "0.63685805", "text": "public function add_css(){\n\n\t\tif ($this->use['css'] == 1){\n\t\t\twp_enqueue_style( 'banner-aquit', $this->plugin_url.'plugin/jquery.cycle.css', null, null);\n\t\t}\n\t\t\t\n\t}", "title": "" }, { "docid": "ebce0c03ddc11f71db7541b975946fd2", "score": "0.63667285", "text": "public function addStylesheet($file, $position = '', $options = array())\n {\n $this->validatePosition($position);\n $this->stylesheets[$position][$file] = $options;\n }", "title": "" }, { "docid": "296d74c6e9415b036ace761703f9b005", "score": "0.63540554", "text": "function _stylesheetScript($path){\n $rtn = \"<script type='text/javascript'>\\n<!--\\n\";\n $rtn .= \"var link = document.createElement('link');\\n\";\n $rtn .= \"link.setAttribute('href', '$path');\\n\";\n $rtn .= \"link.setAttribute('rel', 'stylesheet');\\n\";\n $rtn .= \"link.setAttribute('type', 'text/css');\\n\";\n $rtn .= \"var head = document.getElementsByTagName('head').item(0);\\n\";\n $rtn .= \"head.appendChild(link);\\n\";\n $rtn .= \"//-->\\n</script>\\n\";\n return $rtn;\n }", "title": "" }, { "docid": "15a5e77e7af7ff062093bee260e678cc", "score": "0.63202417", "text": "public function add_editor_stylesheet() {\n\t\t$stylesheet = $this->assets_manager->webpack_manifest->asset( 'css/admin/editor-style.css' );\n\n\t\tif ( $stylesheet ) {\n\t\t\tadd_editor_style( $stylesheet );\n\t\t}\n\t}", "title": "" }, { "docid": "3f246d6c335b295a145dc4d5ba24e233", "score": "0.6294244", "text": "public function importStyleSheet($stylesheet);", "title": "" }, { "docid": "43b322a2e9a3ace4dfff121b020593fe", "score": "0.6252367", "text": "public function addLocalCss($css_url){\n $this->_localCss[] = $css_url;\n }", "title": "" }, { "docid": "98dc9b32b6b35a4af0fb3851f26a4f68", "score": "0.62429464", "text": "public function addAdminStyles()\n\n\n {\n\n\n\n\n\n wp_enqueue_style( $this->adminStylesheet['name'] );\n\n\n }", "title": "" }, { "docid": "47429a47ef42c6c61b4cbfbcc0cf067e", "score": "0.62214476", "text": "function add_css(){\n\t\techo '<link rel=\"stylesheet\" href=\"'.get_bloginfo('wpurl').'/wp-content/plugins/no-categories/style.css\" type=\"text/css\" media=\"screen\" />';\n\t\techo ''; \n\t}", "title": "" }, { "docid": "f32c54fed41e075952fbe70a3b15692e", "score": "0.6220467", "text": "public function addPluginFrontendStylesheets() {\n global $laterpay_version;\n\n wp_register_style(\n 'laterpay-post-view',\n LATERPAY_ASSET_PATH . '/css/laterpay-post-view.css',\n array(),\n $laterpay_version\n );\n wp_register_style(\n 'laterpay-dialogs',\n 'https://static.sandbox.laterpaytest.net/webshell_static/client/1.0.0/laterpay-dialog/css/dialog.css'\n );\n wp_enqueue_style('laterpay-post-view');\n wp_enqueue_style('laterpay-dialogs');\n }", "title": "" }, { "docid": "b1e9aeb07f4886dedf74a7ad703e335b", "score": "0.61763227", "text": "function addCSSLink ($file) {\n echo \"<link rel=\\\"stylesheet\\\" type=\\\"text/css\\\" href=\\\"$file\\\">\\n\";\n}", "title": "" }, { "docid": "e0e34defe32f9c4fdcbeccd0c503217c", "score": "0.6175105", "text": "static function add_css($attr){\n\t\t# Allow string arguments, defining source.\n\t\tif (is_string($attr)){\n\t\t\t$new = array();\n\t\t\t$new['src'] = $attr;\n\t\t\t$attr = $new;\n\t\t}\n\n\t\tif (!isset($attr['src'])){\n\t\t\tthrow new ArgumentException('add_css expects argument array to contain key \"src\"');\n\t\t}\n\t\t$default = array(\n\t\t\t'name' => self::generate_name($attr['src'], '.css'),\n\t\t\t'media' => 'all',\n\t\t\t'admin' => False,\n\t\t);\n\t\t$attr = array_merge($default, $attr);\n\n\t\t$is_admin = (is_admin() or is_login());\n\n\t\tif (\n\t\t\t($attr['admin'] and $is_admin) or\n\t\t\t(!$attr['admin'] and !$is_admin)\n\t\t){\n\t\t\twp_deregister_style($attr['name']);\n\t\t\twp_enqueue_style($attr['name'], $attr['src'], null, null, $attr['media']);\n\t\t}\n\t}", "title": "" }, { "docid": "06a81c856f7bd14f197e4352670e86a0", "score": "0.6169462", "text": "function wgg_add_stylesheets_to_frontend() {\n\t// Add style as selected in options\n\twp_register_style( 'wgGlossaryStyle', WP_PLUGIN_URL . '/wordgallery-glossary/view/style/' . get_option(\"wgGlossary_display_style\") );\n\twp_enqueue_style('wgGlossaryStyle');\n}", "title": "" }, { "docid": "f4aa091b1193cefd850b6edb7b0f8828", "score": "0.6156628", "text": "function addCSS( $css = '' ) {\r\n\t\tglobal $live_site, $option;\r\n\r\n\t\tif( !$css ) {\r\n\t\t\t$css = 'help';\r\n\t\t}\r\n\r\n\t\t$html = '<link href=\"' . $live_site\r\n\t\t. '/administrator/components/' . $option . '/help/'\r\n\t\t. $css . '.css\" rel=\"stylesheet\" type=\"text/css\" media=\"all\" />';\r\n\r\n\t\tif( CustomQuickIcons::_CheckCMSVersion() ) {\r\n\t\t\t$doc =& JFactory::getDocument();\r\n\t\t\t$doc->addStyleSheet( $live_site . '/administrator/components/' . $option . '/help/' . $css . '.css' );\r\n\t\t}else{\r\n\t\t\techo $html;\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "1efc9d25a0a1cb69e6b0ea05eb4cd551", "score": "0.6154261", "text": "function addCSSFiles()\n\t{\n\t\t\n\t\t$this->pageObject->AddCSSFile(\"jquery-ui.css\");\n\t\t\n\t\t\n\t}", "title": "" }, { "docid": "8b211fcfa2c5f5a4567dfbaa1137174f", "score": "0.6147308", "text": "public static function addCSS($strFileName) {\n $obj = self::initialize();\n $obj->addCSSFileName($strFileName);\n }", "title": "" }, { "docid": "837271bdbfa5249df7df24b20bcb4fa2", "score": "0.6145771", "text": "function custom_style_sheet()\n{\n\twp_register_style('custom-style', plugin_dir_url(__FILE__).'/css/style.css');\n\twp_enqueue_style('custom-style');\n}", "title": "" }, { "docid": "835e8313b979c46aa78ef800efae402b", "score": "0.61358225", "text": "function add_ews_service_stylesheet() {\r\n\t$plugin_url = plugin_dir_url( __FILE__ );\r\n\twp_enqueue_style( 'my-theme-ie', $plugin_url .'assets/bootstrap.css' );\r\n\twp_enqueue_style( 'my-theme-fa', 'https://maxcdn.bootstrapcdn.com/font-awesome/4.6.3/css/font-awesome.min.css' );\r\n wp_enqueue_script( 'script-name', 'https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js', array(), '1.0.0', true );\r\n wp_enqueue_script( 'script-name2', 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js', array(), '1.0.0', true );\r\n\twp_enqueue_script( 'script-name3', $plugin_url .'assets/ews-service.js', array(), '1.0.0', true );\r\n}", "title": "" }, { "docid": "1117b5febef4fd5a945bb3aee03ab777", "score": "0.61334825", "text": "function includeExternalStyle($location){\n $string = \"<link rel='stylesheet' type='text/css' href='\".$location.\"' />\\n\";\n echo $string;\n}", "title": "" }, { "docid": "b616316fb2c4bcb4956768afdeea4968", "score": "0.6133431", "text": "function cssFile($params) {\n // This stops styles inadvertently clashing with the main site.\n if (strpos($_SERVER['REQUEST_URI'], '/plugins/plugincreationwizard/') === 0) {\n echo '<link rel=\"stylesheet\" type=\"text/css\" href=\"'.$this->getThemePath().'/css/style.css\" />';\n }\n }", "title": "" }, { "docid": "77153f0554b8955554995439d9083c89", "score": "0.6124993", "text": "function zfz_add_css() {\n if(!is_admin()) {\n wp_enqueue_style('zfz-ajax-search', plugins_url('zfz-ajax-search.css', __FILE__ ), false, '1', 'screen');\n }\n}", "title": "" }, { "docid": "5f0e8b2adb68fdfc8b4b1525b1767311", "score": "0.6122075", "text": "function dynamic_css_wpHead(){\n\t\techo '<style type=\"text/css\">';\n\t\t\t$this->dynamic_css();\n\t\techo '</style>';\n\t}", "title": "" }, { "docid": "9f823017f31132d85740359d6ce99ea0", "score": "0.61211616", "text": "public function addCSS($file)\n\t{\n\t\tforeach ($this->css as $css)\n\t\t{\n\t\t\tif (strpos($css, $file) !== false)\n\t\t\t{\n\t\t\t\t// File already in list\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\t\n\t\t$this->css[] = '<link rel=\"stylesheet\" type=\"text/css\" href=\"'.$file.'\">';\n\t}", "title": "" }, { "docid": "9f33ef69fc3fd0ec8f085ed709744b79", "score": "0.611911", "text": "public function insert_inline_css() {\n }", "title": "" }, { "docid": "9f33ef69fc3fd0ec8f085ed709744b79", "score": "0.611911", "text": "public function insert_inline_css() {\n }", "title": "" }, { "docid": "9f33ef69fc3fd0ec8f085ed709744b79", "score": "0.611911", "text": "public function insert_inline_css() {\n }", "title": "" }, { "docid": "0fc22ff374685138856919b464bdf1eb", "score": "0.611712", "text": "function css_adition(){\n\t\twp_register_style('wiki-headers-extending',plugins_url('/',__FILE__).'css/headers-extending.css');\n\t\twp_enqueue_style('wiki-headers-extending');\t\t\n\t\t\n\t}", "title": "" }, { "docid": "228380258928c44b45d0ecef52f44981", "score": "0.61077744", "text": "function wp_enqueue_style_special($handle, $srcString, $depArray, $version, $media, $loadMethod){\n global $specialLoadHnds;\n array_push($specialLoadHnds->styles->{$loadMethod},$handle);\n wp_enqueue_style($handle, $srcString, $depArray, $version, $media);\n}", "title": "" }, { "docid": "b16175f1d4c3ef53326dc3aa4abaab72", "score": "0.6104638", "text": "function add_event_espresso_bp_stylesheet() {\n $ee_bp_style_url = WP_PLUGIN_URL . '/espresso-members/styles/style.css';\n $ee_bp_style_file = WP_PLUGIN_DIR . '/espresso-members/styles/style.css';\n if ( file_exists($ee_bp_style_file) ) {\n wp_register_style('ee_bp_styles', $ee_bp_style_url);\n wp_enqueue_style( 'ee_bp_styles');\n }\n}", "title": "" }, { "docid": "1f18715f7dc914887d41bd151085037f", "score": "0.61025745", "text": "public function addStylesheet(string $file)\n {\n $this->variable['assetsCss'][] = $file;\n return $this;\n }", "title": "" }, { "docid": "d7d98afc1fb69de00df1d33c13f03bcf", "score": "0.6099448", "text": "function include_css() \n\t{\n\t global $post;\n\n\t if ( $post && strstr( $post->post_content, '[slam-display-results]' ) ) {\n\t echo '<link rel=\"stylesheet\" href=\"' .$this->plugin_url . '/slam-manager.css\" />';\n\t }\n\t}", "title": "" }, { "docid": "0e4a6e56edb11b27036296f0c2d683d1", "score": "0.608717", "text": "function dynamic_css_wpHead_action(){\n\t\tadd_action('wp_head', array($this, 'dynamic_css_wpHead'));\n\t}", "title": "" }, { "docid": "da6fee24cec920ff61e1243f4239803e", "score": "0.6083654", "text": "public function stylesheet() {\n\t\tif(Template::exists(Application::getRouter()->getParam('name'))) {\n\t\t\t// Retrieve template\n\t\t\t$_template = Template::get(Application::getRouter()->getParam('name'));\n\t\t\t// Preset headers\n\t\t\theader(\"Cache-Control: public\");\n\t\t\theader('Expires: ' . gmdate('D, d M Y H:i:s', time() + 86400) . ' GMT');\n\t\t\theader(\"Content-type: text/css\");\n\t\t\t// Generate contents; parameter 'minify' minimises output\n\t\t\tif(is_null(Application::getRouter()->getParam('minify')))\n\t\t\t\techo $_template->css;\n\t\t\telse\n\t\t\t\techo self::minifyCSS($_template->css);\n\t\t\texit();\n\t\t} else {\n\t\t\tthrow new \\Exception(\"Stylesheet '\".Application::getRouter()->getParam('uri').\"' cannot be located\");\n\t\t}\n\t}", "title": "" }, { "docid": "b5fe37b958490a791bb1c5bfb0edea3e", "score": "0.6076022", "text": "public function addStylesheet($src = '', $attributes = array(), $content = '', $name = '')\n {\n if (empty($attributes)) {\n $attributes = array();\n }\n if (!empty($src)) {\n $src = $GLOBALS['xoops']->url($this->resourcePath($src));\n $attributes['href'] = $src;\n }\n if (!isset($attributes['type'])) {\n $attributes['type'] = 'text/css';\n }\n if (!empty($content)) {\n $attributes['_'] = $content;\n }\n if (empty($name)) {\n $name = md5(serialize($attributes));\n }\n $this->addMeta('stylesheet', $name, $attributes);\n }", "title": "" }, { "docid": "5bc00ea04a00f8e24a6db6ab0c3cfde0", "score": "0.60734475", "text": "function _stylesheetHTML($path){\n $rtn = \"<link type='text/css' rel='stylesheet' href='$path' />\\n\";\n return $rtn;\n }", "title": "" }, { "docid": "2d835c953201402411cdf7f106d185aa", "score": "0.6073156", "text": "public static function print_linked_custom_css() {\n\t\theader( 'Content-type: text/css' );\n\t\theader( 'Expires: ' . gmdate( 'D, d M Y H:i:s', time() + YEAR_IN_SECONDS ) . ' GMT' );\n\t\techo wp_get_custom_css();\n\t\texit;\n\t}", "title": "" }, { "docid": "b10265b7111d1f61f0d6107e357045a2", "score": "0.60705495", "text": "function append_custom_css() {\n\n\t\tbf_add_style_file( self::get_css_version(), array( $this, 'get_final_css' ) );\n\n\t\tif ( bf_is_doing_ajax( 'fetch-mce-view-shortcode' ) ) {\n\t\t\tbf_enqueue_tinymce_style( 'extra', self::get_css_version() );\n\t\t}\n\n\t\t// clear memory\n\t\t$this->final_css = '';\n\t}", "title": "" }, { "docid": "c3dbc85f54227d4172eece661d0214af", "score": "0.6066192", "text": "abstract protected function addCssFiles(): void;", "title": "" }, { "docid": "80f65a976563f7a3496117eb8ae1a9dd", "score": "0.6046516", "text": "function mes_horaires_add_stylesheet_to_admin() {\n\n wp_enqueue_script('jquery');\n wp_enqueue_script('field-date-js', 'Field_Date.js', array('jquery', 'jquery-ui-core', 'jquery-ui-datepicker'), time(), true ); \n wp_enqueue_style( 'jquery-ui-datepicker-style' , '//ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/themes/smoothness/jquery-ui.css');\n wp_enqueue_style( 'admin', plugins_url('admin.css', __FILE__) );\n wp_enqueue_script( 'custom-script', plugins_url('custom-script.js', __FILE__), array( 'jquery' ) );\n }", "title": "" }, { "docid": "327003276d7ff8732ae146b2289518e8", "score": "0.60189235", "text": "private function _include_theme_css($file) {\n\t\t$this->EE->cp->add_to_head('<link rel=\"stylesheet\" type=\"text/css\" href=\"'.$this->_theme_url().'markdown/'.$file.'?'.MARKDOWN_VER.'\" />');\n\t}", "title": "" }, { "docid": "71defd8f519dfd709d76e62cfc1e20f2", "score": "0.6015029", "text": "public function installStyles() {\r\n\t\t//wp_enqueue_style('simple-slider', WP_PLUGIN_URL . $this->_plugin_dir . 'style.css');\r\n\t}", "title": "" }, { "docid": "2b754be6914379390ef9a964d489da75", "score": "0.60092914", "text": "public function addCSS($script = \"\")\n {\n if (!in_array($script, $this->css)) {\n $this->css[] = $script;\n }\n }", "title": "" }, { "docid": "e19afd0fcdaacf12104df462bf517bee", "score": "0.60076886", "text": "function add_admin_custom_css() {\n\t\t\t$style = WP_PLUGIN_URL . '/' . dirname(plugin_basename(__FILE__)) . '/extra-table.css';\n\t\t\twp_register_style('ldap-auth-extra', $style, array('colors'));\n\t\t\twp_enqueue_style('ldap-auth-extra');\n\t\t}", "title": "" }, { "docid": "eb42e4a5e9d55f00f366424f692e8ce4", "score": "0.6006896", "text": "function register_my_css() {\n wp_enqueue_style('bus-safety', get_stylesheet_directory_uri() . '/style.css', false, null);\n wp_enqueue_script('mobile-toggle', get_stylesheet_directory_uri() . '/bundled.js', ['jquery'], null, true);\n}", "title": "" }, { "docid": "b07a639e8e61b837e514fae5395f5323", "score": "0.5989336", "text": "public function registerStyles()\n {\n wp_enqueue_style('rd-downloads-font-awesome5');\n\n wp_enqueue_style('rd-downloads-edit-form', plugin_dir_url(RDDOWNLOADS_FILE) . 'assets/css/admin/Downloads/Management/pageEdit.css', [], RDDOWNLOADS_VERSION);\n }", "title": "" }, { "docid": "d475265e838201ba3dc4d26bbd652f6b", "score": "0.59883666", "text": "public function the_css() {\n wp_register_style('multiple-header-images', plugins_url('css/style.css', $this->plugin_file()));\n wp_enqueue_style('multiple-header-images');\n }", "title": "" }, { "docid": "5f6f0c67d8b3cd1a90e4d1109a4761ec", "score": "0.5978051", "text": "private function _browser_css()\n\t{\n\t\tee()->cp->add_to_head(ee()->view->head_link('css/file_browser.css'));\n\t}", "title": "" }, { "docid": "5dedd49232ac291560d8a3ca62c05a5f", "score": "0.5977709", "text": "function technews_templatic_load_theme_stylesheet(){\n\t\tinclude(get_stylesheet_directory().'/css/admin-style.php');\n\t}", "title": "" }, { "docid": "1bad3666b8847548ba49518324399080", "score": "0.5975086", "text": "public function addRequiredResources() {\n module_load_include('inc', 'citeproc', 'CiteProcJS');\n drupal_add_css(drupal_get_path('module', 'scholar') . '/css/Record.css');\n CiteProcJS::addResources(); // Includes javascript and other fun things.\n }", "title": "" }, { "docid": "0cbe9cedb13eed8e4b333a9c1c8a634c", "score": "0.5969758", "text": "static function addCss($cssfile) {\n $cssFile = self::getFileUrl(\"skin\",$cssfile);\n $string = <<<end\n <link rel=\"stylesheet\" type=\"text/css\" href=\"{$cssFile}\" media=\"all\">\nend;\n return $string;\n }", "title": "" }, { "docid": "54f4f825d17fbcbaf6c19448fddf07ee", "score": "0.5965404", "text": "private function _insert_theme_css($file)\n\t{\n\t\tif (!isset($this->EE->session->cache['taggable']['stylesheets'][$file]))\n\t\t{\n\t\t\t$this->EE->cp->add_to_head('<link rel=\"stylesheet\" type=\"text/css\" href=\"'.$this->_theme_url().'css/'.$file.'\" />');\n\t\t\t$this->EE->session->cache['taggable']['stylesheets'][$file] = TRUE;\n\t\t}\n\t}", "title": "" }, { "docid": "86854ffb78da8765453df1d9f86708f1", "score": "0.5963863", "text": "function code_add_style() {\n wp_enqueue_style( 'bootstrap-css', get_template_directory_uri() . '/css/bootstrap.min.css' );\n wp_enqueue_style( 'main-css', get_template_directory_uri() . '/css/style.css' );\n }", "title": "" }, { "docid": "604140090014b29be8b5fe7e24266761", "score": "0.5950839", "text": "function options_stylesheets_alt_style() {\n if ( of_get_option('stylesheet') ) {\n wp_enqueue_style( 'options_stylesheets_alt_style', of_get_option('stylesheet'), array(), null );\n }\n}", "title": "" }, { "docid": "d2d7d243ec7fbfd846b4f83d5009a3ff", "score": "0.59491277", "text": "function stylesheet($sheetName = NULL,$directory = NULL){\r\n\t$sheetName = htmlentities($sheetName);\r\n\t$directory = htmlentities($directory);\r\n\tif($sheetName != NULL){\r\n\t\tif($directory != NULL){\r\n\t\t $sheetName = $directory.\"/\".$sheetName;\r\n\t\t}\r\n\t\tprint('<link rel=\"stylesheet\" type=\"text/css\" href=\"'.$sheetName.'\" />');\r\n\t\tnl();\r\n\t}\r\n}", "title": "" }, { "docid": "abcadf0fd01627bd81a8d9841fa6eae0", "score": "0.5931943", "text": "function knacc_add_custom_css() {\n\n\t$custom_css = get_field('custom_css', 'options');\n\n\tif ($custom_css) {\n\t\twp_add_inline_style('show-tell-style', $custom_css);\n\t}\n}", "title": "" }, { "docid": "f71b59ccd370cbffd2f44baaad2317c9", "score": "0.592297", "text": "public function asex_add_style($handle, $src = false, $deps = array(), $ver = false, $media = 'all')\n {\n $style = apply_filters($this->config['main_class']['FILTER_STYLE'], array(\n 'handle' => $handle,\n 'src' => $src,\n 'deps' => $deps,\n 'ver' => $ver,\n 'media' => $media\n ));\n wp_register_style($style['handle'], $style['src'], $style['deps'], $style['ver'], $style['media']);\n wp_enqueue_style($style['handle']);\n }", "title": "" }, { "docid": "290252d5377a6a7ae8a2be0f7e777be9", "score": "0.5919756", "text": "public function custom_plugin_stylesheet() {\n\t\t\t\twp_register_style( 'social-buttons-stylesheet', plugins_url('/css/social.css', __FILE__) );\n\t\t\t\twp_enqueue_style( 'social-buttons-stylesheet' );\n\t\t\t\t\n\t\t\t\t$social_buttons_display_lightbox\t= get_option( 'social_buttons_display_lightbox' );\n\t\t\t\tif($social_buttons_display_lightbox)\n\t\t\t\t{\n\t\t\t\t\twp_register_style( 'social-buttons-display', plugins_url('/css/basic.css', __FILE__) );\n\t\t\t\t\t//wp_register_style( 'social-buttons-display-ie', plugins_url('/css/basic_ie.css', __FILE__) );\n\t\t\t\t\twp_enqueue_style( 'social-buttons-display' );\n\t\t\t\t\t//wp_enqueue_style( 'social-buttons-display-ie' );\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "a243a89a7ce8dae8ce0308d972b5f189", "score": "0.5917999", "text": "public function onWpPrintStyles()\n {\n // wp_register_style('unique id', '/path/to/css');\n }", "title": "" }, { "docid": "8a9ddca15e13214f3c0fbe964d366e76", "score": "0.5917517", "text": "function addCss($css, $path = WEB_PATH_CSS, $bCheckIfExists = true)\n {\n if (DEVELOPMENT_ENVIRONMENT && ($path === WEB_PATH_CSS))\n {\n $compiled_css = $this->auto_compile_less($css, $path);\n\n if ($compiled_css !== true)\n {\n Util::logit(\"Failed to compile LESS file: {$css}\", __FILE__, __LINE__);\n return;\n }\n }\n\n $this->addResource('css', $path . DS . $css, $bCheckIfExists);\n }", "title": "" }, { "docid": "6b815291b3c31fdea48f3499e4079b4c", "score": "0.59112954", "text": "public function setStylesheet($path)\n {\n $this->stylesheet = $path;\n }", "title": "" }, { "docid": "4b3a0b2a26d5ffb8e538329c9179e2b2", "score": "0.5909189", "text": "function the7_register_style( $handle, $src, $deps = array(), $ver = false, $media = 'all' ) {\n\t\t$src = the7_add_asset_suffix( $src, '.css' );\n\n\t\twp_register_style( $handle, $src, $deps, $ver ? $ver : THE7_VERSION, $media );\n\t}", "title": "" }, { "docid": "8c37e2ad043dffa7380f7e9b8920ff0c", "score": "0.5905313", "text": "function insert_css()\n{\n wp_enqueue_style( 'style', get_stylesheet_uri() );\n \n // adding fonts\n\twp_register_style('custom-google-fonts', 'https://fonts.googleapis.com/css?family=Merriweather', false);\n\twp_enqueue_style('custom-google-fonts');\n \n\t// adding jQuery\n\twp_register_script('jquery2','https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js');\n\twp_enqueue_script('jquery2');\n\t\n\t// adding other libraries\n\twp_register_script('scroll','https://unpkg.com/scrollreveal/dist/scrollreveal.min.js');\n\twp_enqueue_script('scroll');\n\t\n\t// adding Font Awesome css\n\twp_enqueue_style( 'font-awesome', THEME_DIR_URI . '/includes/css/font-awesome.min.css', false, '4.1.0' );\n}", "title": "" }, { "docid": "c83643cf65bdf75b114e15156c3af76d", "score": "0.5900046", "text": "public function wp_varejoecom_register_style_sheets() : void\n {\n wp_register_style('wp_varejoecom-style', plugins_url() . '/wp_varejoecom/dist/css/style.css');\n wp_enqueue_style( 'wp_varejoecom-style' );\n\n wp_register_style('wp_varejoecom-style-bootstrap', plugins_url() . '/wp_varejoecom/dist/css/framework/bootstrap/css/bootstrap.min.css');\n wp_enqueue_style( 'wp_varejoecom-style-bootstrap' );\n }", "title": "" }, { "docid": "659f769451c946940fc821d42351c57e", "score": "0.589785", "text": "function cssFile($params) {\n // This stops styles inadvertently clashing with the main site.\n if (strpos($_SERVER['REQUEST_URI'], $this->getPluginPath()) === 0) {\n echo '<link rel=\"stylesheet\" type=\"text/css\" href=\"'.$this->getThemePath().'/css/style.css\" />';\n }\n }", "title": "" }, { "docid": "2774d32bdd8acfe46b86f2b66dfd2076", "score": "0.58959645", "text": "function acfoc_add_styles() {\n wp_register_style('oc_styles', plugins_url('/lib/owlcarousel/assets/owl.carousel.min.css', __FILE__));\n wp_register_style('oc_styles_default', plugins_url('/lib/owlcarousel/assets/owl.theme.default.min.css', __FILE__));\n wp_register_style('custom_styles', plugins_url('/css/custom.css', __FILE__));\n\n wp_enqueue_style('oc_styles');\n wp_enqueue_style('oc_styles_default');\n wp_enqueue_style('custom_styles');\n}", "title": "" }, { "docid": "4d6ae91c58546826acd68a9ff81e35c6", "score": "0.58944637", "text": "public function addCssInclude($cssFilePath){\n\t\t\n\t\t$this->_resources['css'][] = $cssFilePath;\n\t\t\n\t}", "title": "" }, { "docid": "b21942ff5db052d202bb798cf3982f65", "score": "0.5883934", "text": "function tfuse_add_css()\n {\n\n wp_register_style( 'bootstrap', tfuse_get_file_uri('/css/bootstrap.css', false, '') );\n wp_enqueue_style( 'bootstrap' );\n\n wp_register_style( 'fonts', 'http://fonts.googleapis.com/css?family=Montserrat:400,700|Magra:400,700');\n wp_enqueue_style( 'fonts' );\n\n wp_register_style( 'font-awesome', tfuse_get_file_uri('/css/font-awesome.css', false, '') );\n wp_enqueue_style( 'font-awesome' );\n \n wp_register_style( 'style', get_stylesheet_uri());\n wp_enqueue_style( 'style' );\n \n wp_register_style( 'screen', tfuse_get_file_uri('/screen.css'));\n wp_enqueue_style( 'screen' );\n \n wp_register_style( 'custom_admin', tfuse_get_file_uri('/css/custom_admin.css', false, '') );\n wp_enqueue_style( 'custom_admin' );\n\n wp_register_style( 'prettyPhoto', TFUSE_ADMIN_CSS . '/prettyPhoto.css', false, '' );\n wp_enqueue_style( 'prettyPhoto' );\n \n wp_register_style( 'cusel', tfuse_get_file_uri('/css/cusel.css', false, '') );\n wp_enqueue_style( 'cusel' );\n \n wp_register_style( 'shCore', tfuse_get_file_uri('/css/shCore.css', true, '') );\n wp_enqueue_style( 'shCore' );\n \n wp_register_style( 'settings', tfuse_get_file_uri('/rs-plugin/css/settings.css', true, '') );\n wp_enqueue_style( 'settings' );\n \n wp_register_style( 'shThemeDefault', tfuse_get_file_uri('/css/shThemeDefault.css', true, '') );\n wp_enqueue_style( 'shThemeDefault' );\n \n wp_register_style( 'jquery-ui-1.10.3.custom', tfuse_get_file_uri('/css/dark-theme/jquery-ui-1.10.3.custom.css', true, '') );\n wp_enqueue_style( 'jquery-ui-1.10.3.custom' );\n }", "title": "" }, { "docid": "858f73d1dcfbbbc33a5ed6e77fc71009", "score": "0.5878842", "text": "function loadStylesheet($sCSSin, $sPath=null){\n if($this && isset($this->aStylesheets[$sCSSin])){\n return $this->_stylesheetScript($this->aStylesheets[$sCSSin]);\n }else{\n $sCSS = basename($sCSSin); // just in case its not just a file name\n if(!$sPath){ // no path supplied so I'll do my best to find it ...\n if(basename($_SERVER['PHP_SELF']) == 'admin.php'){\n $sRelPath = $this->aThemes['pathAdmin'] . $sCSS;\n if(!file_exists($sRelPath)){\n $look = $GLOBALS['config']['dir_tpl'] . 'admin/' . $sCSS;\n if(file_exists($look)) $sRelPath = $look;\n }\n }else{\n $sRelPath = $this->aThemes['path'] . $sCSS;\n if(!file_exists($sRelPath)){\n $look = $GLOBALS['config']['dir_tpl'] . $sCSS;\n if(file_exists($look)) $sRelPath = $look;\n }\n }\n }else{\n $sRelPath = rtrim($sPath,'/') . '/' . $sCSS;\n }\n if($this){ $this->aStylesheets[$sCSSin] = $sRelPath; }\n return $this->_stylesheetScript($sRelPath);\n }\n }", "title": "" }, { "docid": "4fb9be5985406669869d94c52b9960b5", "score": "0.5875696", "text": "function css_theme(moodle_url $url) {\n // create the string url\n $css_url = $url->scheme.\"://\".$url->host.$url->path;\n\n // check if any parameters\n if(count($url->params) > 0){\n $first = true;\n foreach($url->params as $param => $value){\n if($first) {\n $css_url .= \"?\".$param.\"=\".$value;\n $first = false;\n } else {\n $css_url .= \"&amp;\".$param.\"=\".$value;\n }\n }\n }\n\n // add meta (it will be inside HEAD tag)\n $this->meta .= '<link rel=\"stylesheet\" type=\"text/css\" href=\"'.$css_url.'\" />';\n }", "title": "" } ]
735446f7b54b188a54a4c4f0b34646a9
/ Modify a user
[ { "docid": "ef4e0db1e18a81695b41b9a3511246b9", "score": "0.0", "text": "function addSem()\r\n{\r\n\r\n\t$semId = $_POST['semId'];\r\n$userId = $_POST['userId'];\r\n$attendance = $_POST['attendance'];\r\n$remarks = $_POST['remarks'];\r\n\t\t\r\n\t\t\r\n\t$images = uploadProductImage('fleImage', SRV_ROOT . 'profileImages/');\r\n\r\n\t$mainImage = $images['image'];\r\n\t$thumbnail = $images['thumbnail'];\r\n\t\r\n\t\r\n\t\t$sql = \"INSERT INTO tbl_sematt (a_semid, a_teacher, a_status, a_remark, a_cert)\r\n\t\t VALUES ('$semId', '$userId', '$attendance', '$remarks', '$mainImage')\";\r\n\t\r\n\t\tdbQuery($sql);\r\n\t\theader('Location: index.php?view=teacher&search='.$semId.'&success=' . urlencode('You have Successfully Checked Attendance'));\t\r\n\r\n}", "title": "" } ]
[ { "docid": "171eff99d3f79cd5035d7f3c5b477b57", "score": "0.8296296", "text": "public function modifyUser($idUser){\r\n\t}", "title": "" }, { "docid": "f957f0d31a7970b37c7a9b700435a5dd", "score": "0.77956563", "text": "public function updateUser(\\PHPAuth\\Model\\User $user);", "title": "" }, { "docid": "72a5a1236a7490f23fdcfa5ec03b1279", "score": "0.7651468", "text": "public function modify() {\n\n // Validate given user ID\n $id = $this->input->post(\"user_id\");\n if (!is_numeric($id) || !$this->user->load($id)) {\n\n XCMS_JSON::loadingFailureMessage();\n return;\n\n }\n\n try {\n\n // Validate provided input\n if (!$this->form_validation->run()) {\n throw new UnexpectedValueException();\n }\n\n // Validate authorization to modify profile (protect administrator)\n if ($this->user->get(\"id\") == 1 && $this->user->get(\"id\") != XCMS_Authentication::getUserId()) {\n\n XCMS_JSON::modificationFailureMessage(\"Only the main administrator can modify this profile.\");\n return;\n\n }\n\n // Set & save new updates\n $this->user->set(\"usergroup_id\", $this->input->post(\"user_usergroup_id\"));\n $this->user->set(\"real_name\", $this->input->post(\"user_real_name\"));\n $this->user->set(\"username\", $this->input->post(\"user_username\"));\n $this->user->set(\"email\", $this->input->post(\"user_email\"));\n $this->user->validate();\n $this->user->save();\n\n // Inform user\n XCMS_JSON::modificationSuccessMessage();\n\n } catch (Exception $e) {\n\n XCMS_JSON::validationFailureMessage($e->getMessage());\n\n }\n\n }", "title": "" }, { "docid": "fbe7b59d092ae7d539e85f191d610856", "score": "0.74725753", "text": "public function modifyUser(): void\n {\n $database = $this->connectDatabase();\n $lastName = htmlspecialchars($_POST[\"lastName\"]);\n $firstName = htmlspecialchars($_POST[\"firstName\"]);\n $mail = htmlspecialchars($_POST[\"mail\"]);\n $city = htmlspecialchars($_POST[\"city\"]);\n $zipCode = htmlspecialchars($_POST[\"zipCode\"]);\n $userId = $_SESSION[\"userId\"];\n //on récupère les données remplies sur le compte utilisateur pour les insérer dans la table user et modifier les données de l'utilisateur connecté\n $myQuery = \"UPDATE `_user` SET user_firstname = :firstname, user_lastname = :lastname, user_email = :email, user_city = :city, user_zipcode = :zipcode where USER_ID = :userId\";\n $queryUser = $database->prepare($myQuery);\n $queryUser->bindValue(':firstname', $firstName, PDO::PARAM_STR);\n $queryUser->bindValue(':lastname', $lastName, PDO::PARAM_STR);\n $queryUser->bindValue(':email', $mail, PDO::PARAM_STR);\n $queryUser->bindValue(':city', $city, PDO::PARAM_STR);\n $queryUser->bindValue(':zipcode', $zipCode, PDO::PARAM_STR);\n $queryUser->bindValue(':userId', $userId, PDO::PARAM_INT);\n $queryUser->execute();\n }", "title": "" }, { "docid": "fcdf6897e4dac1f30500e6e93ed46283", "score": "0.7429526", "text": "public function testUpdateUser()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "title": "" }, { "docid": "c1fd622b63ea72beedc213f1bae85771", "score": "0.72824466", "text": "public function updating($user)\n {\n \t// $user->UNumeroId = 10;\n \tdebug('prueba');\n }", "title": "" }, { "docid": "6b90b77f41829999d3a887905dfde095", "score": "0.7222041", "text": "public function edit()\n {\n $user = User::getOne($_GET['id']);\n if (isset($_POST['userName'])) {\n $user->setUserName($_POST['userName']);\n $user->setUserId($user->getUserId());\n $user->edit();\n $this->redirectTo(\"index.php?controller=User\");\n }\n $this->renderView('admin/edit_user', [\n \"user\" => $user\n ]);\n }", "title": "" }, { "docid": "bdea1c2570403c4ef82a7db4a96744bf", "score": "0.7203543", "text": "public function updateUser($id) {\n\n\t}", "title": "" }, { "docid": "74a589df6f735f79ec840aecbfa5e4d4", "score": "0.7198305", "text": "public function update(Data\\User $user)\n {\n }", "title": "" }, { "docid": "3df7702af45c73d5e2ad0657c6f8773e", "score": "0.7170988", "text": "public function update() {\n\t\t$this->loadDao('User');\n\n\t\t$user = $this->DaoUser->read($_SESSION['id']);\n\t\t$this->DaoUser->update($user);\n\t\t\n\t\tif (!empty($this->input['nom'])) {\n \t$user->setNom(htmlentities($this->input['nom']));\n\t\t} \n\t\tif (!empty($this->input['prenom'])) {\n \t\t$user->setPrenom(htmlentities($this->input['prenom']));\n\t\t}\n\t\tif (!empty($this->input['email'])) {\n \t$user->setEmail(htmlentities($this->input['email']));\n\t\t} \n\t\tif (!empty($this->input['pass'])) {\n\t\t\t$user->setPass(htmlentities(sha1($this->input['pass'])));\n }\n\t\t\n\t\t$this->DaoUser->update($user);\n\t\t\n\t\t$d['user'] = $user;\n\t\t$this->set($d);\n\n\t\t$this->read($_SESSION['id']);\n\n}", "title": "" }, { "docid": "9aac95ab706a968f6df4d075c61d6b9e", "score": "0.7118913", "text": "public function testUpdateUser() : void\n {\n $id = $this->getSingleUser();\n $newUserName = md5(rand(1,199));\n $this->json('PUT', \"/api/users/$id\", ['name' => $newUserName]);\n $this->json('GET', \"/api/users/$id\");\n $response = json_decode($this->response->content());\n $this->assertEquals($newUserName, $response->name);\n }", "title": "" }, { "docid": "5cc40298271aec27ba5ba0b3a2c62504", "score": "0.7082278", "text": "public function edit_user_by_admin()\n {\n $this->actingAsAdmin();\n\n $user = factory(User::class)->create();\n $user->fullname = 'Plaintain Testing';\n $user->save();\n $this->actingAs($user)->put('/user/'.$user->id,$user->toArray());\n $this->assertDatabaseHas('users',['id'=>$user->id,'fullname'=>$user->fullname]);\n }", "title": "" }, { "docid": "f8cbdfe884c39f818c74372001c074e6", "score": "0.7077598", "text": "public function update()\n\t{\n\t\t $user = User::find(Input::get('user_id'));\n\n $user->password = Hash::make(Input::get('password'));\n \n $user->save();\n \n /* $user->makeEmployee('member'); */\n \n \t\tSession::flash('message', 'Successfully update User!');\n return Redirect::to('admin/users');\n\t}", "title": "" }, { "docid": "082ff3afda448f2742d477ea73287869", "score": "0.70646197", "text": "abstract protected function updateUser($user, $args);", "title": "" }, { "docid": "6b65d654b24285e5d2ca31d154ace0a4", "score": "0.7054402", "text": "function edit_user($document) {\n $document['modify_date'] = date('Y-m-d H:i:s');\n if (isset($document['id'])) {\n $this->db->where('id', $document['id']);\n }\n return $this->db->update('users', $document);\n //return $user;\n }", "title": "" }, { "docid": "c050def32fa2e64499b0ad358bb79386", "score": "0.70514303", "text": "function DoUserEdit()\n\t{\n\t\t$this->html->EditUser();\n\t}", "title": "" }, { "docid": "fd9b258242483869db242bb229f83de3", "score": "0.704113", "text": "public function editAccount($userId, $password);", "title": "" }, { "docid": "c1420effdf7bd35fba707d1210f42470", "score": "0.70218927", "text": "public function update($dataUser);", "title": "" }, { "docid": "30197a0b18a2439c61ad020f8f703c1c", "score": "0.7002358", "text": "public function modify_user(){\n\t\t$query = \"UPDATE users SET loginUsers = '\".$_POST[\"login\"].\"', passUsers = '\".$_POST[\"pass\"].\"', \n\t\t\temailUser = '\".$_POST[\"email\"].\"', statusUsers = '\".$_POST[\"status\"].\"'\n\t\t\tWHERE idUsers = '\".$_POST[\"idUsers\"].\"' \";\n\t\t$this->objDb->update($query);\n\t\t\n\t\t$query = \"DELETE FROM user_pro WHERE idUsers = '\".$_POST[\"idUsers\"].\"' \";\n\t\t$this->objDb->delete($query);\n\t\t\n\t\t$query = \"SELECT * FROM profiles\";\n\t\t$this->result = $this->objDb->select($query);\n\t\twhile($row=mysql_fetch_array($this->result)){\n\t\t\t$namePro = \"pro\" . $row[\"idProfile\"];\n\t\t\tif(isset($_POST[$namePro])){\n\t\t\t\tif($row[\"idProfile\"] == $_POST[\"profile\"]){\n\t\t\t\t\tmysql_query(\"INSERT INTO user_pro VALUES('', '\".$row[\"idProfile\"].\"', '\".$_POST[\"idUsers\"].\"', '1')\");\n\t\t\t\t}else{\n\t\t\t\t\tmysql_query(\"INSERT INTO user_pro VALUES('', '\".$row[\"idProfile\"].\"', '\".$_POST[\"idUsers\"].\"', '0')\");\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t}", "title": "" }, { "docid": "ca97fbbca78fb72d98f272b72d6595ea", "score": "0.69900876", "text": "public function updateUser($id='')\r\n\t{\r\n\t}", "title": "" }, { "docid": "cca9b60152181b36ba6acb259623efd0", "score": "0.6986532", "text": "public function admin_edit()\n {\n if( $_POST && isset( $_POST['user_id'] ) ) {\n \n $id = ( $_POST['user_id'] ?? null );\n\n $result = $this->model->update( $_POST, $id );\n\n if( $result ) {\n Session::setFlash( 'The user was successfully updated!', Session::SEVERITY_SUCCESS );\n Router::redirect( '/admin/' . App::getRouter()->getLanguage() . '/users' );\n \n } else {\n Session::setFlash( 'Error: User data could not be edited!', Session::SEVERITY_WARNING );\n Router::redirect( '/admin/' . App::getRouter()->getLanguage() . '/users' );\n }\n }\n \n if( isset( $this->params[0] ) ) {\n $id = (int) $this->params[0];\n $this->data['user'] = $this->model->getById( $id, false );\n \n } else {\n Session::setFlash ( 'Wrong page requested!', 'alert-warning' );\n Router::redirect( '/admin/' . App::getRouter()->getLanguage() . '/users' );\n }\n }", "title": "" }, { "docid": "3454bcb912fc8b94c74c922b700204b8", "score": "0.6976092", "text": "public static function editUser($user) {\n\t\t$query = \"UPDATE Users SET firstName = :firstName, lastName = :lastName, userName = :userName, email = :email WHERE userId = :userId\";\n\t\ttry {\n\t\t\tif (is_null ( $user ) || $user->getErrorCount () > 0)\n\t\t\t\treturn $user;\n\t\t\t$db = Database::getDB ();\n\t\t\t$statement = $db->prepare ( $query );\n\t\t\t$statement->bindValue ( \":firstName\", $user->getFirstName () );\n\t\t\t$statement->bindValue ( \":lastName\", $user->getLastName () );\n\t\t\t$statement->bindValue ( \":userName\", $user->getUserName () );\n\t\t\t$statement->bindValue ( \":email\", $user->getEmail () );\n\t\t\t$statement->bindValue ( \":userId\", $user->getUserId () );\n\t\t\t$statement->execute ();\n\t\t\t$statement->closeCursor ();\n\t\t} catch ( Exception $e ) {\n\t\t\t$user->setError ( 'userId', 'USER_INVALID' );\n\t\t\techo $e;\n\t\t}\n\t\treturn $user;\n\t}", "title": "" }, { "docid": "40475a142c9e6040ec72743b05373d4b", "score": "0.69565094", "text": "public function modifyUser($fields, $id){\n if(isset($fields['role'], $fields['name'])) {\n if (strlen($fields['username']) > 1 && strlen($fields['username']) < 40) {\n $role = (new DB())->sanitize($fields['role']);\n $name = (new DB())->sanitize($fields['name']);\n\n $userObject = new User($name, null, $role, $id);\n (new UserManager())->modifyUser($userObject);\n }\n }\n\n $this->render('modify.user', \"Modifier un utilisateur\", [\n 'value' => (new UserManager())->getById($id)\n ]);\n }", "title": "" }, { "docid": "d587061c8ce1390f9d9268454ac389cc", "score": "0.69506615", "text": "private function updateUser(){\n\t\t\tif($this->get_request_method() != \"POST\"){\n\t\t\t\t$this->response('',406);\n\t\t\t}\n\t\t\t$id = trim($this->_request['id']);\n\t\t\t$nombre = trim($this->_request['nombre']);\n\t\t\t$apellidos = trim($this->_request['apellidos']);\n\t\t\t$celular = trim($this->_request['celular']);\n\t\t\t$userRepository = $this->em->getRepository('User');\n\t\t\t$user = $userRepository->find($id);\n\t\t\tif($user!=NULL){\n\t\t\t\t$user->nombre = $nombre;\n\t\t\t\t$user->apellidos = $apellidos;\n\t\t\t\t$user->celular = $celular;\n\t\t\t\t$this->em->merge($user);\n\t\t\t\t$this->em->flush();\n\n\t\t\t\t$this->response($this->json($user), 200);\n\t\t\t}\n\t\t\t$error = array('status' => \"Failed\", \"msg\" => utf8_encode(\"El usuario no existe\"));\n\t\t\t$this->response($this->json($error), 400);\n\n\t\t}", "title": "" }, { "docid": "3e376d736c37002d91ec42306539c286", "score": "0.69426876", "text": "public function updateProfile() {\r\n\r\n $userEntity = $this->Users->newEntity();\r\n $userPatch = $this->Users->patchEntity($userEntity,$this->request->getData());\r\n $userPatch->id = $this->Auth->user('id');\r\n $userSave = $this->Users->save($userPatch);\r\n if($userSave) {\r\n $user = $this->Users->find('all', [\r\n 'conditions' => [\r\n 'id' => $this->Auth->user('id')\r\n ]\r\n ])->hydrate(false)->first();\r\n\r\n $this->Auth->setUser($user);\r\n echo '0';die();\r\n }\r\n }", "title": "" }, { "docid": "2414ee044f24837e3991f0b6c86bd77d", "score": "0.6909103", "text": "public function editUser($email, $accessLevel, $firstname, $lastname, $phone, $oldemail);", "title": "" }, { "docid": "2f8b50d69028be9ca774c0dd256e29f1", "score": "0.69049513", "text": "public function edit(User $user)\n {\n\n }", "title": "" }, { "docid": "1db52e7f2040a7045713eafc23318302", "score": "0.68986446", "text": "public function edit_user($user_id,$user_name,$user_email,$password,$picture,$ext,$room_id) {\n $res = mysqli_query($this->con, \"update `users` set user_name='\" . $user_name . \"',user_email='\" . $user_email . \"' ,\n password='\" . $password . \"',picture='\" . $picture . \"',ext=\" . $ext . \",room_id=\" . $room_id . \" WHERE user_id= \" . $user_id . \" \");\n return $res;\n }", "title": "" }, { "docid": "26a98d328e74fd8554bca904b119bb52", "score": "0.68965876", "text": "public function updated(User $user);", "title": "" }, { "docid": "a9a1c9a2858f567c8faa0d8f71e49a3a", "score": "0.68723726", "text": "public function p_edit()\n {\n if(!$this->user) {\n Flash::set(\"Please log in.\");\n Router::redirect(\"/users/login\");\n return;\n }\n Helper::csrf_protect($_POST);\n if($this->userObj->update($_POST)) {\n Flash::set(\"Your settings have been saved.\");\n Router::redirect(\"/stories/welcome\");\n } else {\n Flash::set(\"Update failed: \" . $this->userObj->error_message());\n Router::redirect(\"/users/edit\");\n }\n }", "title": "" }, { "docid": "952ec5e2a8a6f656aa60c4958fc364cd", "score": "0.68645924", "text": "public function edit(User $user) {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "247ff1a29dbd220ec57d1db69b56ab55", "score": "0.68565434", "text": "public function edit(User $user)\n {\n //\n }", "title": "" }, { "docid": "9ffb1fd2973e3847af005756880621fc", "score": "0.6829335", "text": "private function EditUser( ) \n\t{\n\t\tJSession::checkToken() or jexit(JText::_('COM_QUESTIONS_JINVALID_TOKEN'));\n\t jimport('joomla.user.helper');\n\t jimport('joomla.database.table');\n\t\t\t\t\n\t\t$db \t\t\t=& JFactory::getDBO();\n\t\t$acl\t\t\t=& JFactory::getACL();\n\t\t$currentUser \t=& JFactory::getUser();\n\n\t\t$cid \t= JFactory::getApplication()->input->get( 'cid', array(), '', 'array' );\n\t\t$number=0;\n\t\tJArrayHelper::toInteger( $cid );\n\t\tif (count( $cid ) < 1) {\n\t\t\tJError::raiseWarning(500, JText::_( 'SELECTUSERS', true ) );\n\t\t}\n\t\tforeach ($cid as $id){\n\t\t$sql = \"UPDATE #__questions_userprofile\"\n \t. \"\\n SET blocked = 1\"\n \t. \"\\n WHERE id =\". $id\n \t;\n \t$db->setQuery( $sql );\n \tif (!$db->query()) {\t \n \t\tdie(\"SQL error\" . $db->stderr(true));\n \t}\n\t\t$number++;\n\t\t}\n \t//return true;\n\t\t$this->setRedirect( 'index.php?option=com_questions&view=profiles', JText::sprintf(JText::_('COM_QUESTIONS_USERBLOCKED'), $number));\n }", "title": "" }, { "docid": "71fd065c86b0010b0f754ca80ba02fb6", "score": "0.6826398", "text": "function update_user($userid, $par){\n\t\t$ret = GalleryEmbed::updateUser($userid, $par);\n\t\treturn $ret;\n}", "title": "" }, { "docid": "df89dd43c3a6bd5efa2a417d2186b3ab", "score": "0.6823765", "text": "public function updateUser(array $user);", "title": "" }, { "docid": "bc8f7b84090c8644a0b04f9b8ebd03c9", "score": "0.6805101", "text": "public function edit(){\n $user = User::show(Application::$app->session->get('id'));\n \n $user->rules = [\n 'username' => [User::RULE_REQUIRED, [User::RULE_MIN, 'min'=>3], [User::RULE_MAX, 'max'=>18]],\n 'email' => [User::RULE_REQUIRED, User::RULE_EMAIL],\n ];\n \n if(Request::isPost()){\n $user->populate(Request::getData());\n\n if ($user->validate()){\n if($user->update()){\n Application::$app->session->setFlash('success', 'Les modifications ont été enregistrées');\n header('Location: /mon-compte');\n return;\n }\n }\n }\n // Page data\n $data = [\n 'title' => 'Modifier mon compte',\n 'description' => \"Espace personnel permet de visualiser les informations de votre compte sur le site de partage Kercode\",\n 'user' => $user\n ];\n\n return self::render('back/userEditAccount',$data);\n }", "title": "" }, { "docid": "7526a12629381e97f51f94752543249c", "score": "0.6803583", "text": "public function edit() {\n\t\t//1. Select the user\n\t\t$id = $_GET['id'] ?? null;\n\t\t$userManager = new UserManager();\n\t\t$user = $userManager->getUser($id);\n\n\t\t//Form has been submitted\n\t\tif(isset($_POST['name']) && isset($_POST['email'])) {\n\t\t\t//3b. Check the validity of datas\n\t\t\t$user->setName($_POST['name']);\n\t\t\t$user->setEmail($_POST['email']);\n\t\t\t$userManager->updateUser($user);\n\n\t\t\theader('Location: index.php?ctrl=user&action=index');\n\t\t}\n\n\t\t//2. Prepare the form\n\t\t$name = $user->getName();\n\t\t$email = $user->getEmail();\n\n\t\t//3. Display the form\n\t\trequire __DIR__ . '/../view/user/edit.php';\n\t}", "title": "" }, { "docid": "882a6faa628729ef4a4325a61af70718", "score": "0.6798827", "text": "public function edit(User $user)\n {\n $this->authorize('update', $user);\n }", "title": "" }, { "docid": "0cc51221dba041a1f1f65416df7fd464", "score": "0.6795197", "text": "public function admin_edit_user() {\n\t\t$this->loadModel('User');\n\t\t$this->User->id = $this->request->data['User']['id'];\n\n\t\tif (!$this->User->exists()) {\n\t\t\tthrow new NotFoundException(__('Invalid user'));\n\t\t}\n\t\tif(!$this->request->is('post')) {\n\t\t\tthrow new MethodNotAllowedException();\n\t\t}\n\n\t\t$data = $this->request->data;\n\t\tif ($this->User->save($data)) {\n\t\t\t$this->Session->setFlash(__('User updated'), 'flash_success');\n\t\t} else {\n\t\t\t$this->Session->setFlash(__('User NOT updated'), 'flash_failure');\n\t\t}\n\n\t\t$url = array('controller' => 'sites', 'action' => 'users', 'admin' => true);\n\n\t\treturn $this->redirect($url);\n\t}", "title": "" }, { "docid": "a1999777ddf58ee14e57753a2e5c3d7c", "score": "0.6794351", "text": "public function update(User $user)\n {\n// return $user->checkPermissionAccess(config('permissions.access.edit-theloai'));\n }", "title": "" }, { "docid": "0e4059cb28ce2bce2f3178f1ddc250d1", "score": "0.67931366", "text": "public function edit(User $user)\n {\n //\n\n }", "title": "" }, { "docid": "b9c343ac580a2abd4ce7c067af5afd72", "score": "0.6791991", "text": "public function update(User $user, odel=Test $odel=Test)\n {\n //\n }", "title": "" }, { "docid": "9af175a1b0a400c0fee9a4b0836e193f", "score": "0.678401", "text": "public function setEditUser($data){\r\n\t\t\tif(!empty($data['id'])){\r\n\t\t\t\t$query =\"UPDATE users SET name='\".$data['name'].\"',last_name='\".$data['last_name'].\"', email='\".$data['email'].\"' WHERE id=\".$data['id'];\r\n\t\t\t\t$result =mysqli_query($this->link,$query);\r\n\t\t\t\tif($result){\r\n\t\t\t\t\treturn true;\r\n\t\t\t\t}else{\r\n\t\t\t\t\treturn false;\r\n\t\t\t\t}\r\n\t\t\t}else{\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}", "title": "" }, { "docid": "54e5885da34ed7b78bffc310c58625c0", "score": "0.6768891", "text": "public function update(User $user) : User;", "title": "" }, { "docid": "c073c7ba86852e02e69764f995f008ee", "score": "0.6764693", "text": "public function update_user(){\n array_push($this->doc['users'], user);\n $this->update();\n }", "title": "" }, { "docid": "a3d3671b4a1e13e4c6929acab075ef37", "score": "0.67615736", "text": "public function edit(User $user)\n {\n // Not used\n }", "title": "" }, { "docid": "f5bc3bf5b51604c335cb5cb9752753de", "score": "0.6744391", "text": "public function updateuserinfos()\n {\n if (!empty($_POST['email'])) {\n $email = $this->request->getParameter(\"email\");\n $firstname = $_POST[\"firstname\"];\n $name = $_POST[\"name\"];\n $city = $_POST[\"city\"];\n $linkedin = $_POST[\"linkedin\"];\n $github = $_POST[\"github\"];\n $twitter = $_POST[\"twitter\"];\n $website = $_POST[\"website\"];\n $date_birth = $_POST[\"date_birth\"];\n $user = $this->request->getSession()->getAttribut(\"user\");\n $this->user->changeUser($email, $firstname, $name, $city, $linkedin, $github, $twitter, $website, $date_birth);\n $this->message->userUpdated();\n $user = $this->user->getUser($id_user);\n if ($user === false) {\n throw new Exception('Impossible de modifier l\\' utilisateur !');\n } else {\n $this->request->getSession()->setAttribut(\"user\", $user);\n $this->generateView();\n }\n }\n }", "title": "" }, { "docid": "bcc098dcd5597179e6b0a198c3350111", "score": "0.67390937", "text": "function modifyUser()\r\n{\r\n\t$userId = (int)$_POST['hidUserId'];\t\r\n\t$FName = $_POST['txtFName'];\r\n $LName = $_POST['txtLName'];\r\n $userName = $_POST['txtUserName'];\r\n $Password = $_POST['txtPassword'];\r\n $Position = $_POST['txtPosition'];\r\n\t\r\n\t$sql = \"UPDATE tbl_user \r\n\t SET user_password = PASSWORD('$Password'), user_fname='$FName', user_lname='$LName', user_position='$Position'\r\n\t\t\t WHERE user_id = $userId\";\r\n\r\n\tdbQuery($sql);\r\n\theader('Location: index.php?success=' . urlencode('You have Successfully Modified this User'));\r\n\r\n}", "title": "" }, { "docid": "79b9d85e1468e51405f12e62f46782ad", "score": "0.67369", "text": "public function editUser($id){\n if(!(isset($_SESSION['admin_logged']) && !empty($_SESSION['admin_logged']))) {\n header(\"Location: \".BASE_URL.\"admin/login\");\n exit;\n }\n $dados = array();\n $dados['title'] = 'Admin - Editar Usuário';\n\n $this->loadAdminTemplate('admin/users/editUser', $dados);\n }", "title": "" }, { "docid": "1fd5702e6be4eaad8e4917297adbfda1", "score": "0.6735859", "text": "function ModifyUser($userId,$CompanyId, $FirstName, $LastName, $Province, $Role, $KmRate, $Language, $Email){\n\tinclude('conn.php'); //remove surement\n\tsession_start(); //remove surement\n\ttry{\n\t\t$result = $conn->prepare(\"UPDATE users SET CompanyId= :CompanyId, FirstName= :FirstName, LastName= :LastName, Province= :Province, Role= :Role, KmRate= :KmRate, Language= :Language, Email= :Email WHERE UserId= :userId\");\n\t\t$result->bindValue(':CompanyId',$CompanyId);\n\t\t$result->bindParam(':FirstName',$FirstName);\n\t\t$result->bindParam(':LastName',$LastName);\n\t\t$result->bindParam(':Province',$Province);\n\t\t$result->bindParam(':Role',$Role);\n\t\t$result->bindParam(':KmRate',$KmRate);\n\t\t$result->bindParam(':Language',$Language);\n\t\t$result->bindParam(':Email',$Email);\n\t\t$result->bindParam(':userId',$userId);\n\t\t$result->execute();\t\n\n\t} catch(Exception $e){\n\t\tdie($e);\n\t\tprint_r ($result->errorInfo()); //remove surement\n\t}\n}", "title": "" }, { "docid": "3cf9e7af16c5cf852bcc339af7503d6d", "score": "0.6732115", "text": "public function changeuserstatusAction()\n {\n $params = $this->_request->getParams();\n $user_obj = new Ep_User_User();\n $data = array(\"status\" => $params['status'], \"changestatus_by\" => $this->adminLogin->userId, \"changestatus_at\" => date(\"Y-m-d H:i:s\"));\n $query = \"identifier= '\" . $params['user_id'] . \"'\";\n $user_obj->updateUser($data, $query);\n\n }", "title": "" }, { "docid": "7350bd3f4fcf92a432af24ecc22667e7", "score": "0.67088", "text": "public static function profile_update( $id_user, $old_user_data ) {\n\n }", "title": "" }, { "docid": "28edf8697165838fff794cb7a3fb20db", "score": "0.670648", "text": "public function updatePassword(User $user) : User;", "title": "" }, { "docid": "d1ce6cbb5d3da289521c7b63724f1b63", "score": "0.6703787", "text": "function updateUser($userid, $password, $fname, $sname,$email,$telno,$usertype,$departmentid){\n $query = \"UPDATE User SET userid='\".$userid.\"', firstname='\".$fname.\"',\"\n . \"surname='\".$sname.\"',email='\".$email.\"', tel_no='\".$telno.\"',\"\n . \"user_type='\".$usertype.\"', departmentId='\".$departmentid.\"'\"\n . \"WHERE userid='\".$userid.\"';\";\n\n $result = DataManager::executeQuery($query);\n \n $query = \"UPDATE Login SET userid='\".$userid.\"', password='\".$password.\"' \"\n . \"WHERE userid='\".$userid.\"';\";\n \n $result = DataManager::executeQuery($query);\n }", "title": "" }, { "docid": "6ebc92d01ba37f0c40640a0d355e8b03", "score": "0.67025626", "text": "public function testUpdateUser()\n {\n $client = new Client();\n\n $hash = uniqid();\n $name = \"UpdateTest {$hash}\";\n $email = \"{$hash}-update@example.org\";\n\n $newUpdateUser = $client->user()->create($name, $email, \"Participant\");\n\n $this->assertIsInt($newUpdateUser->id);\n $this->assertEquals($name, $newUpdateUser->name);\n\n // Now let's update it!\n $hash2 = str_shuffle($hash);\n\n $update = [\n 'name' => \"UpdateTest1 {$hash2}\"\n ];\n\n // Update the user on the server\n $client->user()->update($newUpdateUser->id, $update);\n\n // Fetch it from scratch to ensure the change took effect\n $retrievedUser = $client->user()->get($newUpdateUser->id);\n\n // If this passes, the API has saved this change\n $this->assertEquals(\"UpdateTest1 {$hash2}\", $retrievedUser->name);\n\n }", "title": "" }, { "docid": "6d4f9abf401939b7fb5b02eb2502f7d5", "score": "0.668497", "text": "public function changeOwner($user_name);", "title": "" }, { "docid": "f41b086e660cbb904ddb32b0f60d3f69", "score": "0.66784585", "text": "public function changePassword( $user ) {\n\t\t\n\t}", "title": "" }, { "docid": "39eed0e16e1f15004e753491a37da2d5", "score": "0.6648099", "text": "public function modify_attributes() {\n\n // Validate given user ID\n $id = $this->input->post(\"user_id\");\n if (!is_numeric($id) || !$this->user->load($id)) {\n\n XCMS_JSON::loadingFailureMessage();\n return;\n\n }\n\n // Set & save new updates\n foreach ($this->user->getAttributes() as $attribute) {\n\n $this->user->setAttribute($attribute->name, \"\");\n if ($value = $this->input->post(\"attr_\" . $attribute->name)) {\n $this->user->setAttribute($attribute->name, $value);\n }\n\n }\n\n $this->user->validate();\n $this->user->save();\n\n // Inform user\n XCMS_JSON::modificationSuccessMessage();\n\n }", "title": "" }, { "docid": "9fd8b97886a8ee0f78744a93f50b37b1", "score": "0.66272515", "text": "public function editUser($id, $email, $first_name, $last_name, $pos, $phone, $client, $site, $welcome_page, $type, $role, $lang, $specialty, $can_add_result, $special,$read, $user_group, $can_acces_schedule)\r\n {\r\n $pdo = $this->pdo;\r\n if (!(isset($email) && isset($first_name) && isset($last_name) && filter_var($email, FILTER_VALIDATE_EMAIL))) {\r\n $this->msg = \"form.all_required\";\r\n return false;\r\n }\r\n $welcome_page = (!empty($welcome_page))? $welcome_page : NULL;\r\n $stmt=$pdo->prepare('UPDATE users SET first_name=:first_name, last_name=:last_name, email=:email, position=:position, phone_number=:phone_number, id_client=:id_client, id_site_user=:id_site_user, welcome_page=:welcome_page, user_type=:user_type, user_role=:user_role, user_lang=:user_lang, tech_group=:tech_group, add_results=:add_results, special_id=:special_id, read_only=:read_only, user_group=:user_group, can_acces_schedule=:can_acces_schedule WHERE id=:id');\r\n if ($stmt->execute([\r\n 'first_name' => $first_name,\r\n 'last_name' => $last_name,\r\n 'email' => $email,\r\n 'position' => $pos,\r\n 'phone_number' => $phone,\r\n 'id_client' => $client,\r\n 'id_site_user' => $site,\r\n 'welcome_page' => $welcome_page,\r\n 'user_type' => $type,\r\n 'user_role' => $role,\r\n 'user_lang' => $lang,\r\n 'tech_group' => $specialty,\r\n 'add_results' => $can_add_result,\r\n 'special_id' => $special,\r\n 'read_only' => $read, \r\n 'user_group' => $user_group, \r\n 'can_acces_schedule' => $can_acces_schedule, \r\n 'id' => $id\r\n ])) {\r\n $_SESSION['user_group'] = json_decode($user_group, true);\r\n return true;\r\n } else {\r\n $this->msg = \"user.modify_failed\";\r\n return false;\r\n }\r\n }", "title": "" }, { "docid": "2c5a312faaf2a68b12366cb4b07f91e4", "score": "0.66268545", "text": "public function edit() {\n\t\tif (($this->request->is('put') || $this->request->is('post') ) && !empty($this->request->data)) {\n\t\t\t$users_exists = $this->__validateUser();\n\t\t\tif (is_array($users_exists)) {\n\t\t\t\treturn $this->outFalseResponse($users_exists);\n\t\t\t}\n\t\t\t$this->__validateRequest();\n\t\t\t$userSaved = $this->User->save($this->request->data);\n\t\t\tif ($userSaved) {\n\t\t\t\t$user = $this->User->findById($this->User->id);\n\t\t\t\t$user = $this->clearFields($user);\n\t\t\t\t$result = $this->getResult($user);\n\t\t\t\treturn $this->out($result, $user,'Response');\n\t\t\t} else {\n\t\t\t\t$error = $this->getValidationErrors($this->User->validationErrors);\n\t\t\t\treturn $this->outFalseResponse($error);\n\t\t\t}\n\t\t}\n\t\treturn $this->outFalseResponse();\n\t}", "title": "" } ]
5e11252fa22507c7c76aab39623cfef8
Initialize the language class for translating strings.
[ { "docid": "aba02b4f4dac1903739682a37f13fe39", "score": "0.0", "text": "public function __construct($directory, $language = null)\n {\n if(!file_exists($directory))\n throw new \\Exception(\"Languages directory not found.\");\n\n $this->translations = null;\n\n $this->directory = $directory;\n\n $this->SetLanguage($language);\n }", "title": "" } ]
[ { "docid": "50336aea6c51f19c252b595fd8a553e6", "score": "0.76273364", "text": "function initTranslator()\n {\n $langSupported=array(\"de\"=>true,\"en\"=>true);\n include_once 'HTTP.php';\n define(\"LC_LANG\",HTTP::negotiateLanguage($langSupported,$this->cfg['i18n']['default']));\n $langSelected='rc_'.LC_LANG;\n include_once $this->cfg['i18n']['directory'].LC_LANG.\".php\";\n $this->lang = new $langSelected;\n }", "title": "" }, { "docid": "e3dc9cc6c467d34916c47f568f0369da", "score": "0.7497246", "text": "public function __construct()\n\t{\n\t\t$this->LoadLanguageFile();\n\t}", "title": "" }, { "docid": "191fae6cec879a35e940a081d0b10fa2", "score": "0.7230617", "text": "public function __construct()\n {\n try\n {\n $this->lang = LANG\\Language::getInstance();\n $this->lang->addLanguageTags(__DIR__ . '/../../lang/page.ini');\n $this->lang->addLanguageTags(__DIR__ . '/../../lang/weight.ini');\n $this->lang->setDefault('de');\n $this->lang->setLanguage('de');\n }\n catch (LANG\\LanguageException $e)\n {\n echo $e->getMessage();\n }\n }", "title": "" }, { "docid": "6abe8686fa3dcc69a5fe1691b73664b0", "score": "0.72042686", "text": "function __construct() {\n\t\t\t\tparent :: __construct();\n\t\t\t\t$this->langdef = DEFLANG;\n\t\t}", "title": "" }, { "docid": "07797c66fda9ac438e9fd2d0f75f3f0b", "score": "0.70540226", "text": "public function __construct() {\n //====================================================================//\n // Load Default Language\n Splash::Local()->LoadDefaultLanguage();\n }", "title": "" }, { "docid": "a53d59df68f20f2327f5ef41e71486c2", "score": "0.6996164", "text": "public function __construct()\r\n\t{\r\n\t\tparent::__construct();\r\n\r\n\t\t// Lang is set to default\r\n\t\t$this->setLang(_DEFAULT_LANG);\r\n\r\n\t\t// Try to use the visitor's lang\r\n\t\t// If not possible, use the default one\r\n\t\t//TODO\r\n\t\t// $this->setLang();\r\n\t}", "title": "" }, { "docid": "807eeef1291e5d5bb4256746e3b6723c", "score": "0.69897735", "text": "public function __construct() {\n\t\t// Create an instance of language. Needed in order to make the em_index work\n\t\t$GLOBALS['LANG'] = t3lib_div::makeInstance('language');\n\t\t$GLOBALS['LANG']->csConvObj = t3lib_div::makeInstance('t3lib_cs');\n\t}", "title": "" }, { "docid": "42b10d4d4f190735584716a5aa82ab76", "score": "0.69834065", "text": "public function __construct() {\n\t\tif (!empty($this->locallangFile)) {\n\t\t\t$GLOBALS['LANG']->includeLLFile($this->locallangFile);\n\t\t}\n\t}", "title": "" }, { "docid": "c7da169b6c97ac6410973999fcb8bb6b", "score": "0.69483393", "text": "public function init()\n {\n parent::init();\n $this->registerTranslations();\n }", "title": "" }, { "docid": "ba07e9ecdc25f57d7b6a37ea2d44a717", "score": "0.6941164", "text": "public function __construct() {\n parent::__construct();\n $this->lang->load('translate', $this->language);\n $this->lang->load('urls', $this->language);\n $this->load->model('mod_translate');\n $this->load->helper('translation');\n }", "title": "" }, { "docid": "116a91b895db12997886f5d3f9506d33", "score": "0.69344175", "text": "private function initTranslation()\n {\n // get locale\n $language = Zend_Registry::get(\"Zend_Locale\");\n if (is_object($language)) {\n $language = $language->__toString();\n }\n \n // create translation object\n $this->view->translate = new Zend_Translate('csv', PIMCORE_PLUGINS_PATH . ColorPicker_Plugin::getTranslationFile($language), $language, array('delimiter' => ','));\n }", "title": "" }, { "docid": "37bfd0c163f14bab2ad5105c4a5c9956", "score": "0.69322985", "text": "protected function _initLang()\n {\n\t\t$translate = Zend_Registry::get('Zend_Translate');\n $translate->addTranslation(dirname(__FILE__) .'/languages/views.xml', $_SESSION['default']['language']);\n }", "title": "" }, { "docid": "9c0a12ce1f7f617294e9171ef6fce81e", "score": "0.69225484", "text": "function __construct() {\n\t\t$this->addTranslation(__FILE__);\n//\t\t$this->translater->__construct(__FILE__);\n\t}", "title": "" }, { "docid": "aad9ca2ab6e79615d22d88d27bfe8d89", "score": "0.69075817", "text": "public function __construct()\n\t{\n\t\tt('lang')->load('modules/user/common');\n\t}", "title": "" }, { "docid": "4293462da136a749a5a054d6513e4e7d", "score": "0.6884598", "text": "public function __construct()\n\t{\n\t\tparent::__construct();\n\n\t\tt('lang')->load('modules/deposit/common');\n\t\tt('lang')->load('modules/deposit/deposit_card');\n\t\tt('lang')->load('admin/deposit_card');\n\t\t\n\t}", "title": "" }, { "docid": "7b01e9754f4ef5b0ae9eb19ec24d1809", "score": "0.6862902", "text": "public function __construct(){\n\n\t\t$this->translations = array();\t\n\t}", "title": "" }, { "docid": "6f5db04b3f4d5bcdccc8fbc5b2179266", "score": "0.68556523", "text": "public function __construct()\n\t{\n\t\t//$this->SetLanguage('synapse', VENDOR . '/phpmailer/language/');\n\t}", "title": "" }, { "docid": "96f782ec885ccddf62cba705c4c5620b", "score": "0.67934644", "text": "public function __construct()\n {\n // t('lang')->load('admin/lesson_order');\n }", "title": "" }, { "docid": "d9f233514671678a30d9a46c152f998c", "score": "0.67892337", "text": "public function init()\n {\n require_lang('disastr');\n }", "title": "" }, { "docid": "ba8300e3d4e1f2f026b644f8d0b473c2", "score": "0.67763317", "text": "public function init() {\n // Set up localisation.\n $this->load_plugin_textdomain();\n }", "title": "" }, { "docid": "ba658b953cb95a474bbf831cd3496596", "score": "0.6739989", "text": "function __construct()\n {\n /** @var $this ->t8tools TranslationConfigurationProvider */\n $this->t8Tools = GeneralUtility::makeInstance(TranslationConfigurationProvider::class);\n\n // Find all system languages:\n $this->sys_languages = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows(\n '*',\n 'sys_language',\n ''\n );\n }", "title": "" }, { "docid": "3927582c7945e4c24b40ad610b2cb8ff", "score": "0.672846", "text": "public function __construct($sLanguage = 'en') {\n self::$_oObject = $this;\n self::$_aLang = array();\n self::load($sLanguage);\n }", "title": "" }, { "docid": "265f62f12819002b8c724ab1e441a4c7", "score": "0.6715207", "text": "function __construct( $userLang='' ) {\n\t\t$this->_strings = array();\n\n\t\tif( isset( $this->_locale ) ) {\n\t\t\tsetlocale (LC_TIME, $this->_locale);\n\t\t}\n\t\t$this->_defaultLang = 'english';\n\t\t$this->_userLang = $userLang;\n\t}", "title": "" }, { "docid": "ec01364c4c4f6f4291f327306c485049", "score": "0.6704229", "text": "public function __construct(){\n\t\t$this->default_language='fr';\n\t\t\n\t\t/**\n\t\t * All languages that could exists... \n\t\t * if not in supported language, we have to create a file and a directory for it translation\n\t\t */\n\t\t$this->all_languages = array(\n\t\t'auto',//auto detection\n\t\t'af', // afrikaans.\n\t\t'ar', // arabic.\n\t\t'bg', // bulgarian.\n\t\t'ca', // catalan.\n\t\t'cs', // czech.\n\t\t'da', // danish.\n\t\t'de', // german.\n\t\t'el', // greek.\n\t\t'en', // english.\n\t\t'es', // spanish.\n\t\t'et', // estonian.\n\t\t'fi', // finnish.\n\t\t'fr', // french.\n\t\t'gl', // galician.\n\t\t'he', // hebrew.\n\t\t'hi', // hindi.\n\t\t'hr', // croatian.\n\t\t'hu', // hungarian.\n\t\t'id', // indonesian.\n\t\t'it', // italian.\n\t\t'ja', // japanese.\n\t\t'ko', // korean.\n\t\t'ka', // georgian.\n\t\t'lt', // lithuanian.\n\t\t'lv', // latvian.\n\t\t'ms', // malay.\n\t\t'nl', // dutch.\n\t\t'no', // norwegian.\n\t\t'pl', // polish.\n\t\t'pt', // portuguese.\n\t\t'ro', // romanian.\n\t\t'ru', // russian.\n\t\t'sk', // slovak.\n\t\t'sl', // slovenian.\n\t\t'sq', // albanian.\n\t\t'sr', // serbian.\n\t\t'sv', // swedish.\n\t\t'th', // thai.\n\t\t'tr', // turkish.\n\t\t'uk', // ukrainian.\n\t\t'zh', // chinese.\n\t\t'debug' // debug language file.\n\t\t);\n\t\t$this->getSupportedLanguages();\n\n\t\t/**\n\t\t * All languages we can manage \n\t\t */\n\t\t$this->getAllLanguages();\n\t\t\n\t\t/**\n\t\t * Current config language \n\t\t */\n\t\t$this->current_language= $this->getCurrentLanguage();\n\t}", "title": "" }, { "docid": "1e13ea4f00a26d8a45b62c482ed6891b", "score": "0.6654261", "text": "public function _initErrorMessageLanguage()\r\n {\r\n $translator = new Zend_Translate(\r\n array(\r\n 'adapter' => 'array',\r\n 'content' => APPLICATION_PATH . '/../library/resources/languages',\r\n 'locale' => 'de_DE',\r\n 'scan' => Zend_Translate::LOCALE_DIRECTORY\r\n )\r\n );\r\n Zend_Validate_Abstract::setDefaultTranslator($translator);\r\n }", "title": "" }, { "docid": "39c245f4ff2a5623f1fb31915038587a", "score": "0.6626046", "text": "public function init()\n {\n\n // Load the shared translation adapter from the zend registry\n $this->adapter = Zend_Registry::get('Zend_Translate');\n }", "title": "" }, { "docid": "ceb2026026fdf44ea8be29cf3a3587f3", "score": "0.66218925", "text": "public function init_translations() {\n\t\t// Load translations\n\t\tload_plugin_textdomain( 'bea-projecthuddle', false, BEA_PROJECTHUDDLE_PLUGIN_DIRNAME . '/languages' );\n\t}", "title": "" }, { "docid": "cd3cc1aeae0b5e66106f90f30be7a85d", "score": "0.66115415", "text": "public function init()\n {\n if (!$this->lang->family) {\n $this->lang->load('family');\n }\n }", "title": "" }, { "docid": "2ae7aa40ab7fa8fe9ed58e9a6e6db1cf", "score": "0.66026753", "text": "private function __initLanguage() {\n \n //params key #3 holds the language\n $langCode = $this->_getParam('3', false);\n if ($langCode) { \n $langModel = new Model_Language();\n $language = $langModel->getLanguageIdByCode($langCode);\n if (isset($language['id'])) {\n $ns = new Zend_Session_Namespace('application');\n $ns->language_id= $language['id'];\n }\n } \n }", "title": "" }, { "docid": "7324f937f211d928aefe00de580f8306", "score": "0.6591119", "text": "public function __construct() {\n\n $language[Language::INVALID_DATA] = \"Dũ liệu không hợp lệ.\";\n $language[Language::BUTTON_NEXT] = \"Tiếp tục\";\n $language[Language::ACCESS_TOKEN_EXPIRE] = \"Tạm thời đăng nhập đã hết hạn vui lòng thử lại.\";\n $language[Language::EMPTY_BTCE] = \"Vui lòng nhập số BTC-E Code.\";\n $language[Language::BTC_COIN_FILTER] = \"Hệ thống tạm thời chỉ cho phép đổi BTC-E Code USD.\";\n $language[Language::SYSTEM_ERROR] = \"Lỗi hệ thống vui lòng thử lại sau\";\n $language[Language::AMOUNT_INVALID] = \"Mệnh giá không hợp lệ.\";\n $language[Language::RECHARGE_FAILED] = \"Nạp tiền vào game thất bại.\";\n $language[Language::SUBMIT_INVALID] = \"Thao tác không hợp lệ.\";\n $language[Language::SERVICE_INVALID] = \"Dịch vụ chưa sẵn sàn\";\n $language[Language::NOT_ENUOGH_DATA] = \"Dữ liệu không đủ để thực hiện thao tác này\";\n $language[Language::SYSTEM_BTC_ERROR] = \"Hệ thống nạp BTC-E lỗi\";\n $language[Language::RECHARGE_SUCCESS] = \"Nạp tiền thành công\";\n $language[Language::EMPTY_SERIAL] = \"Serial không được bổ trống\";\n $language[Language::EMPTY_PIN] = \"Pin không được bổ trống\";\n $language[Language::EMPTY_VOUCHER] = \"Voucher không được bổ trống\";\n parent::__construct($language);\n }", "title": "" }, { "docid": "fe6e6ca595df1af3f31bc39add3f8720", "score": "0.6581697", "text": "public static function translations();", "title": "" }, { "docid": "d3b15bd04c1ae07fe405e33a2917ccad", "score": "0.6564828", "text": "static public function initialize() {\n session_start();\n if (!self::getLanguage()) {\n self::setLanguage(Languages::getRequestedLanguage());\n }\n self::setDisplayTexts(Languages::getDisplayTexts());\n }", "title": "" }, { "docid": "88a89b71005b6b2e7904dd020dd59e41", "score": "0.65426654", "text": "private function translations()\n\t{\n\t}", "title": "" }, { "docid": "5eadbb5ff9379371b5f26552685e96a5", "score": "0.6500627", "text": "public function initTranslatableContext()\n {\n $translate = Translator::instance();\n $this->translatableContext = $translate->getLocale();\n $this->translatableDefault = $translate->getDefaultLocale();\n }", "title": "" }, { "docid": "a2f333183b9496ab6e37e8d7e51f0b10", "score": "0.64939415", "text": "function init_language()\n{\n\tglobal $vbulletin, $phrasegroups;\n\tglobal $copyrightyear, $timediff, $timenow, $datenow;\n\n\t// define languageid\n\tdefine('LANGUAGEID', iif(empty($vbulletin->userinfo['languageid']), $vbulletin->options['languageid'], $vbulletin->userinfo['languageid']));\n\n\t// define language direction (preferable to use $stylevar[textdirection])\n\tdefine('LANGUAGE_DIRECTION', iif(($vbulletin->userinfo['lang_options'] & $vbulletin->bf_misc_languageoptions['direction']), 'ltr', 'rtl'));\n\n\t// define html language code (lang=\"xyz\") (preferable to use $stylevar[languagecode])\n\tdefine('LANGUAGE_CODE', $vbulletin->userinfo['lang_code']);\n\n\t// initialize the $vbphrase array\n\t$vbphrase = array();\n\n\t// populate the $vbphrase array with phrase groups\n\tforeach ($phrasegroups AS $phrasegroup)\n\t{\n\t\t$tmp = unserialize($vbulletin->userinfo[\"phrasegroup_$phrasegroup\"]);\n\t\tif (is_array($tmp))\n\t\t{\n\t\t\t$vbphrase = array_merge($vbphrase, $tmp);\n\t\t}\n\t\tunset($vbulletin->userinfo[\"phrasegroup_$phrasegroup\"], $tmp);\n\t}\n\n\t// prepare phrases for construct_phrase / sprintf use\n\t//$vbphrase = preg_replace('/\\{([0-9])+\\}/siU', '%\\\\1$s', $vbphrase);\n\n\t// pre-parse some global phrases\n\t$tzoffset = iif($vbulletin->userinfo['tzoffset'], ' ' . $vbulletin->userinfo['tzoffset']);\n\t$vbphrase['all_times_are_gmt_x_time_now_is_y'] = construct_phrase($vbphrase['all_times_are_gmt_x_time_now_is_y'], $tzoffset, $timenow, $datenow);\n\t$vbphrase['vbulletin_copyright'] = construct_phrase($vbphrase['vbulletin_copyright'], $vbulletin->options['templateversion'], $copyrightyear);\n\t$vbphrase['powered_by_vbulletin'] = construct_phrase($vbphrase['powered_by_vbulletin'], $vbulletin->options['templateversion'], $copyrightyear);\n\t$vbphrase['timezone'] = construct_phrase($vbphrase['timezone'], $timediff, $timenow, $datenow);\n\n\t// all done\n\treturn $vbphrase;\n}", "title": "" }, { "docid": "af077d2768d5ed9e2538d7d0442b1228", "score": "0.64833635", "text": "public function __construct()\n {\n $lang = Session::get('locale');\n if ($lang != null) App::setLocale($lang);\n }", "title": "" }, { "docid": "664409a90428896ed0b51b24a9ff6fe1", "score": "0.64760864", "text": "public function translations();", "title": "" }, { "docid": "5fb98c333e27aaa95ab3130db9129993", "score": "0.6475199", "text": "function _init_locale() {\n\t/**\n\t * @since 1.0.0\n\t */\n\t\\load_plugin_textdomain(\n\t\t'autodescription',\n\t\tfalse,\n\t\t\\dirname( THE_SEO_FRAMEWORK_PLUGIN_BASENAME ) . DIRECTORY_SEPARATOR . 'language'\n\t);\n}", "title": "" }, { "docid": "1504f0f94da7e90bc983af70b8ef8fb8", "score": "0.6470984", "text": "function MyApp_Messages_Init()\n {\n $this->MyLanguage_Init();\n $this->MyLanguage_Messages_Files_Add($this->MessageFiles);\n $this->MyApp_Messages_Files_Read();\n }", "title": "" }, { "docid": "8a570b28960be2fc17511a816b29a397", "score": "0.6455577", "text": "public function init()\r\n {\r\n \theader('content-type: text/html; charset=utf8');\r\n \tdefined('BASE_URL')\t|| define('BASE_URL', Zend_Controller_Front::getInstance()->getBaseUrl());\r\n \t$this->tr = Application_Form_FrmLanguages::getCurrentlanguage();\r\n\t}", "title": "" }, { "docid": "dd9fd680c7cbac1b092c4bdafdf15b80", "score": "0.644419", "text": "public function init()\r\n {\r\n \theader('content-type: text/html; charset=utf8');\r\n \tdefined('BASE_URL')\t|| define('BASE_URL', Zend_Controller_Front::getInstance()->getBaseUrl());\r\n \t$this->tr = Application_Form_FrmLanguages::getCurrentlanguage();\r\n }", "title": "" }, { "docid": "36f26173664b59b02d6c1c9ef684d188", "score": "0.64336914", "text": "function __construct() {\n $this->en_US = $raw_us;\n $this->es_MX = $raw_es;\n }", "title": "" }, { "docid": "8b8f1a5a479323ccc2771fad17cde1c7", "score": "0.6432335", "text": "public function init()\n {\n if (function_exists('determine_locale')) {\n $locale = determine_locale();\n } else {\n // @todo Remove when start supporting WP 5.0 or later.\n $locale = is_admin() ? get_user_locale() : get_locale();\n }\n $locale = apply_filters('plugin_locale', $locale, 'jobsearch-resume-export');\n unload_textdomain('jobsearch-resume-export');\n load_textdomain('jobsearch-resume-export', WP_LANG_DIR . '/plugins/jobsearch-resume-export-' . $locale . '.mo');\n load_plugin_textdomain('jobsearch-resume-export', false, dirname(dirname(plugin_basename(__FILE__))) . '/languages');\n }", "title": "" }, { "docid": "bc3a6e67f8af6dda5eeee25aa07dc257", "score": "0.6423532", "text": "public function __construct()\n {\n $language = isset($_SESSION['lang']) ? $_SESSION['lang'] : '';\n\n // Check if language exist and set english if requested language doesn't exist\n if (!file_exists(APPDIR . 'include/lang/' . $language . '/index.php')) {\n $_SESSION['lang'] = 'english'; // Change language in session\n $language = 'english'; // Default language\n }\n\n require APPDIR . 'include/lang/' . $language . '/index.php';\n\n // Additional localization files\n $langdir = explode('/', REQUEST_URI);\n\n // Localization based on controller filename\n if (file_exists(APPDIR . \"include/lang/\" . $language . \"/\" . $langdir[1] . \".php\")) require APPDIR . \"include/lang/\" . $language . \"/\" . $langdir[1] . \".php\";\n\n // Localization file based on first two params from URL\n if (isset($langdir[1]) && isset($langdir[2]) && !empty($langdir[1]) && !empty($langdir[2]) && file_exists(APPDIR . \"include/lang/\" . $language . \"/\" . $langdir[1] . \"/\" . $langdir[2] . \".php\")) require APPDIR . \"include/lang/\" . $language . \"/\" . $langdir[1] . \"/\" . $langdir[2] . \".php\";\n\n // Localization data\n $this->language_data = $language_data;\n $this->strings = $lang_home;\n $this->all = array_merge($this->language_data, $this->strings);\n }", "title": "" }, { "docid": "ff96b4aad6c87c96ad0a0c3b9a00cdf3", "score": "0.64229923", "text": "public function __construct()\n {\n self::$_log = new Log;\n self::$_translation = new Translation;\n self::$_language_service = new LanguageService;\n\n $this->_log_channel = 'translation';\n }", "title": "" }, { "docid": "c839135ed4d943a959cf60524506f369", "score": "0.6411607", "text": "public static function init($lang) {\n $LANG_DIR = dirname(__FILE__).DIRECTORY_SEPARATOR.'lang'.DIRECTORY_SEPARATOR;\n // Test if the language file exists before it is included. If a language file does not exist\n // for the preferred language then load english\n if(!file_exists($LANG_DIR.\"$lang.php\")) {\n $lang = 'en';\n }\n include ($LANG_DIR.\"$lang.php\");\n self::$locale_text_array = $locale_text_array;\n setlocale(LC_ALL, self::$locale_text_array[\"php_locale\"]);\n }", "title": "" }, { "docid": "eb92280f68c52a08d488f105dd3ca971", "score": "0.64041775", "text": "function nf_i18n_initialize()\n{\n\tglobal $nf_project_dir;\n\tglobal $nf_i18n;\n\tglobal $nf_cfg;\n\n\t$lang = Nin::language();\n\n\t$nf_i18n = [];\n\tnf_i18n_loadtable(__DIR__ . '/i18n/' . $lang . '.php');\n\tnf_i18n_loadtable($nf_project_dir . '/i18n/' . $lang . '.php');\n}", "title": "" }, { "docid": "877b2de5dc29084fd78b0b3c239215cb", "score": "0.6396655", "text": "private function __construct() {\n\t\t\tsetlocale (LC_ALL, 'en_US.UTF-8');\n\t\t}", "title": "" }, { "docid": "d80241601f6c522be46ddf03dc015c69", "score": "0.6388573", "text": "public function __construct() {\n $lines = file(dirname(__FILE__).'/langnames.txt');\n foreach($lines as $line) {\n $line = preg_replace('/#.*$/', '', $line);\n $line = trim($line);\n if($line == '') continue;\n\n list($code, $name) = preg_split('/\\s+/', $line, 2);\n $this->langnames[$code] = $name;\n ksort($this->langnames);\n }\n }", "title": "" }, { "docid": "86a001b915132eeae2351dc44457080c", "score": "0.6381958", "text": "public function init()\n\t{\n\t\tparent::init();\n\n\t\t\\Yii::$app->getI18n()->translations['core.*'] = [\n\t\t\t'class' => 'yii\\i18n\\PhpMessageSource',\n\t\t\t'basePath' => __DIR__.'/messages',\n\t\t];\n\t\t$this->setAliases([\n\t\t\t'@core' => __DIR__\n\t\t]);\n }", "title": "" }, { "docid": "6ba91fa453d085cdca1ef97c97f677f1", "score": "0.6380327", "text": "public function __construct($locale) { }", "title": "" }, { "docid": "d716f575a672f185a96c030857ee8d28", "score": "0.6379466", "text": "public static function load() {\n self::$active_locale = Options::get('I18N_DEFAULT_LOCALE');\n require __DIR__ . '/../../app/translations/index.php';\n setLocale(LC_ALL, self::$active_locale . '.UTF8');\n }", "title": "" }, { "docid": "0739cb6171a4c2d71c0b8f7080dda59a", "score": "0.6363665", "text": "protected function _initI18N()\r\n\t{\r\n\t\t// Get view parameters\r\n\t\t$oCache = $GLOBALS['asap_cache'];\r\n\t\t$sKey = 'asap.config.i18n';\r\n\t\tif ($oCache->has($sKey))\r\n\t\t{\r\n\t\t\t$aI18NParams = $oCache->get($sKey);\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t$oAsap = $GLOBALS['asap'];\r\n\t\t\t$aI18NParams = $this->getParameter('i18n', 'asap');\r\n\t\t\t$aI18NParams['class'] = ucfirst($aI18NParams['method']);\r\n\t\t\t$oCache->set($sKey, $aI18NParams);\r\n\t\t}\r\n\r\n\t\t$this->_i18n = $aI18NParams;\r\n\r\n\t\t// If needed, initialize\r\n\t\tif (!empty($aI18NParams['active']))\r\n\t\t\tAsap_I18N_Generic::getInstance($aI18NParams);\r\n\t}", "title": "" }, { "docid": "724532a9beab1fff3d665d71a68b9757", "score": "0.6360316", "text": "public function __construct(TranslationInterface $string_translation) {\n $this->stringTranslation = $string_translation;\n }", "title": "" }, { "docid": "724532a9beab1fff3d665d71a68b9757", "score": "0.6360316", "text": "public function __construct(TranslationInterface $string_translation) {\n $this->stringTranslation = $string_translation;\n }", "title": "" }, { "docid": "51a6feb6a34f7c990cabc0431b3daac8", "score": "0.6358968", "text": "public function load_localisation () {\r\n\t\tload_plugin_textdomain( $this->token, false, dirname( plugin_basename( $this->file ) ) . '/lang/' );\r\n\t}", "title": "" }, { "docid": "5121492c6965b972842e8ac03fa3b67a", "score": "0.6339987", "text": "public function load_translation() {\n\n\t\tload_plugin_textdomain( 'woocommerce-gateway-authorize-net-aim', false, dirname( plugin_basename( $this->get_file() ) ) . '/i18n/languages' );\n\t}", "title": "" }, { "docid": "8dd106dc0d319be5014cef2b0f37cfd4", "score": "0.6332075", "text": "public function load_localisation () {\n\t\tload_plugin_textdomain( $this->token, false, dirname( plugin_basename( $this->file ) ) . '/lang/' );\n\t}", "title": "" }, { "docid": "8dd106dc0d319be5014cef2b0f37cfd4", "score": "0.6332075", "text": "public function load_localisation () {\n\t\tload_plugin_textdomain( $this->token, false, dirname( plugin_basename( $this->file ) ) . '/lang/' );\n\t}", "title": "" }, { "docid": "ba4156cd7ca8f57142f691c70279ce2f", "score": "0.63074845", "text": "function piwibar_lang_init(){\n\tload_language('plugin.lang', PIWIBAR_PATH);\n}", "title": "" }, { "docid": "52a16e203307b08359ac0dd6f66c22e3", "score": "0.6307344", "text": "protected function _init()\r\n\t{\r\n\t\t// Try to load from cache first\r\n\t\t$bWasFromCache = false;\r\n\t\t$aMessages = $this->_loadLocale($this->_locale, $bWasFromCache);\r\n\r\n\t\tif ($bWasFromCache == true)\r\n\t\t{\r\n\t\t\t$this->_messages = $aMessages;\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\t// Not loaded in cache, load fallback i18n first\r\n\t\t$sFallback = $this->_params['fallback'];\r\n\t\tif ($sFallback != $this->_locale)\r\n\t\t{\r\n\t\t\t$this->_messages = $this->_loadLocale($sFallback, $bWasFromCache);\r\n\t\t\tif (!$bWasFromCache)\r\n\t\t\t\t$this->_updateCache($sFallback);\r\n\t\t}\r\n\t\telse\r\n\t\t\t$this->_messages = $aMessages;\r\n\r\n\t\tif ($this->_messages === false)\r\n\t\t{\r\n\t\t\tif ($GLOBALS['asap']->isDebug())\r\n\t\t\t\tthrow new Exception('Default language file not found for locale ' . $sFallback . ' : ' . $this->_getFileName($sFallback));\r\n\t\t\telse\r\n\t\t\t\t$this->_messages = array();\r\n\t\t}\r\n\t\t// Change locale to use fallback because no translation file was found for the given language\r\n\t\tif ($aMessages === false)\r\n\t\t{\r\n\t\t\tif ($GLOBALS['asap']->isDebug())\r\n\t\t\t\tthrow new Exception('Language file not found for locale ' . $this->_locale . ' : ' . $this->_getFileName($this->_locale) . ' (in non-debug environment, we would have silently switched to fallback language)');\r\n\t\t\t$this->setLocale($sFallback);\r\n\t\t}\r\n\r\n\t\t// Return is fallback is current language\r\n\t\tif ($sFallback == $this->_locale)\r\n\t\t\treturn;\r\n\r\n\t\t// If we want to load a language other than fallback, update the cache\r\n\t\t$this->_messages = array_merge($this->_messages, $aMessages);\r\n\t\t$this->_updateCache($this->_locale);\r\n\t}", "title": "" }, { "docid": "7f71ca795445e9a6b63fcbf98d0b87d6", "score": "0.6300263", "text": "public function init_translations(): void {\n\t\t// Load translations\n\t\tload_plugin_textdomain( 'bea-plugin-boilerplate', false, dirname( BEA_PB_PLUGIN_BASENAME ) . '/languages' );\n\t}", "title": "" }, { "docid": "56ecc12eafd43d39c7080a0cf6e0bd7c", "score": "0.6288059", "text": "function lang_load( $p_lang ) {\r\n global $g_lang_strings, $g_active_language;\r\n global $TLS_STRINGFILE_CHARSET;\r\n\r\n $g_active_language = $p_lang;\r\n\r\n if ( isset( $g_lang_strings[ $p_lang ] ) ) {\r\n return;\r\n }\r\n\r\n $t_lang_dir_base = TL_ABS_PATH . 'locale' . DIRECTORY_SEPARATOR;\r\n $lang_resource_path = $t_lang_dir_base . $p_lang . DIRECTORY_SEPARATOR . 'strings.txt';\r\n if (file_exists($lang_resource_path) && is_readable($lang_resource_path))\r\n {\r\n require($lang_resource_path);\r\n }\r\n else\r\n {\r\n require($t_lang_dir_base . 'en_GB' . DIRECTORY_SEPARATOR . 'strings.txt');\r\n }\r\n \r\n $lang_resource_path = $t_lang_dir_base . $p_lang . DIRECTORY_SEPARATOR . 'description.php';\r\n if (file_exists($lang_resource_path))\r\n {\r\n require($lang_resource_path );\r\n }\r\n else\r\n {\r\n require($t_lang_dir_base . 'en_GB' . DIRECTORY_SEPARATOR . 'description.php');\r\n }\r\n \r\n // Allow overriding strings declared in the language file.\r\n // custom_strings_inc.php can use $g_active_language\r\n $lang_resource_path = $t_lang_dir_base . $p_lang . DIRECTORY_SEPARATOR . 'custom_strings.txt';\r\n if (file_exists( $lang_resource_path ) ) {\r\n require_once( $lang_resource_path );\r\n }\r\n\r\n $t_vars = get_defined_vars();\r\n foreach( array_keys($t_vars) as $t_var ) \r\n {\r\n $t_lang_var = preg_replace( '/^TLS_/', '', $t_var );\r\n if ( $t_lang_var != $t_var) \r\n {\r\n $g_lang_strings[$p_lang][$t_lang_var] = $$t_var;\r\n }\r\n }\r\n}", "title": "" }, { "docid": "7ef4678885ac0c2a501280cbdeb451e2", "score": "0.6287337", "text": "public function __construct()\n\t{\n\t\t$this->collection = new LocaleCollection;\n\t}", "title": "" }, { "docid": "65cbe6cb291067876719af65b53aa772", "score": "0.6269827", "text": "public function __construct()\n\t{\n $languara = \\Languara\\Laravel\\Wrapper\\LanguaraWrapper::get_instance();\n $this->description = $languara->get_message_text('notice_translate_command_info');\n \n\t\tparent::__construct();\n\t}", "title": "" }, { "docid": "ae90d2dc13f63d4e889b56108e4fe18f", "score": "0.6255782", "text": "private function set_locale() {\n\n\t\t$plugin_i18n = new Simple_Plugin_i18n();\n\n\t\t$this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );\n\n\t}", "title": "" }, { "docid": "ca1d6c5490e07cbd56fcf9afbd9458e6", "score": "0.62523055", "text": "public function initializeLocale() {\n\t\t$this->objectManager->getObject('F3\\FLOW3\\Locale\\Service', $this->settings)->initialize();\n\t}", "title": "" }, { "docid": "3bcfd3a0540229dc865705985241827e", "score": "0.6251815", "text": "private function setLocale()\n {\n $pluginLocale = new Localize();\n $this->loader->addAction('plugins_loaded', $pluginLocale, 'load_plugin_textdomain');\n }", "title": "" }, { "docid": "135042926ae8e05ccc1e964117ce4dc5", "score": "0.62500423", "text": "public function init()\n {\n // Get Language from storage such as Session or Cookie\n $language = $this->_getFromStorage();\n\n if ($language) {\n // Has storage record remark\n $this->_hasStorageRecord = true;\n // Set to current language\n $this->set($language);\n } else {\n // Refer Yii::$app->language as default language\n if (Yii::$app->language) {\n $this->set(Yii::$app->language);\n } else {\n $this->setByIndex(0);\n } \n }\n }", "title": "" }, { "docid": "24616b4a658c4d38f3d72e9f0877a774", "score": "0.6248886", "text": "public function __construct($translationNeeded = FALSE) {\n $this->_translationNeeded = $translationNeeded;\n }", "title": "" }, { "docid": "2c4005db7b518fec4f12dfd8d2ca3f75", "score": "0.62098485", "text": "private function set_locale() {\n $plugin_i18n = new Ambiverse_ELD_i18n();\n $this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );\n }", "title": "" }, { "docid": "8b71082b4c0c1f2db085b5d0e8a00193", "score": "0.61761904", "text": "public function init()\r\n {\r\n parent::init();\r\n\r\n // View\r\n switch($this->_languageId)\r\n {\r\n case 1: $langLocale = 'en'; break;\r\n case 2: $langLocale = 'id'; break;\r\n }\r\n $this->view->languageID = $langLocale;\r\n\r\n }", "title": "" }, { "docid": "490a44005a2adff72a4dd0d098de40ca", "score": "0.6171319", "text": "public static function _init()\n\t{\n\t\t/**\n\t\t * start off with using the current URI and default\n\t\t * settings\n\t\t */\n\t\tstatic::$segments_raw = static::split_uri(URI::current());\n\t\tstatic::translate();\n\t}", "title": "" }, { "docid": "73f09983c04e184af73a656a18d561b8", "score": "0.6169881", "text": "private function set_locale() {\n\t\t$i18n = new AIOVG_i18n();\n\t\t$this->loader->add_action( 'plugins_loaded', $i18n, 'load_plugin_textdomain' );\n\t}", "title": "" }, { "docid": "9670fa0720365ae6bb03a8d972d8e27b", "score": "0.61681575", "text": "public function __construct()\n {\n /** initialise the views object */\n $this->view = new View();\n\n /** initialise the language object */\n $this->language = new Language();\n $this->language->setLanguage('vi');\n }", "title": "" }, { "docid": "d304f39e7da3232bf3bf40741aaa6cc3", "score": "0.6168139", "text": "protected static function translator()\n {\n }", "title": "" }, { "docid": "c475172aa71508d31d12c20778a3b465", "score": "0.616806", "text": "function init() {\n $language = ereg_replace( '[\\\\|/]', '', getLanguageName());\n if (file_exists($this->getDirectory().$language.'.php'))\n include_once($this->getDirectory().$language.'.php');\n else\n include_once($this->getDirectory().'english.php');\n\n// determine the language of this page if skin is being parsed\n\t\t$this->currentLanguage = intval(cookieVar('NP_MultiLanguage'));\n\t}", "title": "" }, { "docid": "7d1ff399683ddf77bc48f0d19a040881", "score": "0.6162357", "text": "public function initLocale()\n {\n $this->before(function () {\n $this['translator']->setLocale($this['config']['site']['language']);\n });\n }", "title": "" }, { "docid": "614023075f7b0bb93b32f94225309efb", "score": "0.61602706", "text": "public function __construct()\n {\n if (isset($GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['lang']['availableLanguages'])) {\n $this->selectedLocales = $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['lang']['availableLanguages'];\n } else {\n $configurationManager = GeneralUtility::makeInstance(ConfigurationManager::class);\n $configurationManager->setLocalConfigurationValueByPath(\n $this->configurationPath,\n ['availableLanguages' => []]\n );\n }\n }", "title": "" }, { "docid": "bf7c3de171ad931013a866f3011b6413", "score": "0.6156324", "text": "protected function set_locale(): void {\n\t\tI18n::init(\n\t\t\t$this->loader,\n\t\t\tarray(\n\t\t\t\t'domain' => 'rfd-woo-variable-table',\n\t\t\t\t'plugin_rel_path' => RFD_WOO_VARIABLE_TABLE_PLUGIN_DIR . 'languages' . DIRECTORY_SEPARATOR,\n\t\t\t)\n\t\t);\n\t}", "title": "" }, { "docid": "425f9a3b712a3be2790f0246f76f6515", "score": "0.6153564", "text": "protected static function _initLocaleTranslation(Zend_Locale $locale)\n {\n $defaultDomain = 'message';\n $availableDomains = array(\n 'message',\n 'time',\n 'validate',\n );\n\n // init available gettext domains\n foreach ($availableDomains as $domain) {\n bindtextdomain($domain, LOCALES_PATH);\n bind_textdomain_codeset($domain, 'UTF-8');\n }\n\n // set default domain\n textdomain($defaultDomain);\n\n // mandatory for gettext\n putenv('LANGUAGE=' . $locale);\n\n setlocale(LC_MESSAGES, $locale . '.utf8');\n setlocale(LC_TIME, $locale . '.utf8');\n\n /*\n $gettextService = new BaseZF_Service_GetText();\n $gettextService->iniTranslation($locale, array('message'));\n */\n }", "title": "" }, { "docid": "fec228fc5316a495b8b6de8ea5b65cc6", "score": "0.61531115", "text": "protected function __construct()\n\t{\n\t\tGettext::$config = Kohana::config('gettext');\n\n\t\tif (Gettext::$config['regenerate_var'] AND isset($_GET[Gettext::$config['regenerate_var']]))\n\t\t{\n\t\t\t// Regenerate language files\n\t\t\tGettext::generate_po_files();\n\t\t}\n\n\t\t$cache = Cache::instance();\n\n\t\t$refresh = FALSE;\n\n\t\tif (Gettext::$config['auto_refresh'] !== FALSE)\n\t\t{\n\t\t\t$time = $cache->get('gettext-refresh');\n\n\t\t\tif ($time !== NULL AND time() > ($time + Gettext::$config['auto_refresh']))\n\t\t\t{\n\t\t\t\t// Force a refresh from language data expiring\n\t\t\t\t$refresh = TRUE;\n\t\t\t}\n\t\t}\n\n\t\tif (Gettext::$config['refresh_var'] AND isset($_GET[Gettext::$config['refresh_var']]))\n\t\t{\n\t\t\t// Force a refresh from get var\n\t\t\t$refresh = TRUE;\n\t\t}\n\n\t\tif ($refresh)\n\t\t{\n\t\t\t// Forcing a reload of language settings, otherwise Apache has to be restarted\n\t\t\t$time = time();\n\n\t\t\tforeach (Gettext::$config['locales'] as $locale)\n\t\t\t{\n\t\t\t\t$file = APPPATH.Gettext::$config['directory'].'/'.$locale.'/LC_MESSAGES/'.Gettext::$config['domain'];\n\n\t\t\t\tif (($old_time = $cache->get('gettext-refresh')) !== NULL)\n\t\t\t\t{\n\t\t\t\t\t// Delete old language file if it exists\n\t\t\t\t\t@unlink($file.'-'.$old_time.'.mo');\n\t\t\t\t}\n\n\t\t\t\tif (is_file($file.'.mo'))\n\t\t\t\t{\n\t\t\t\t\t// Copy default language file to a temporary language file to be loaded in\n\t\t\t\t\tcopy($file.'.mo', $file.'-'.$time.'.mo');\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Set new refresh value to current time\n\t\t\t$cache->set('gettext-refresh', $time, NULL, 0);\n\t\t}\n\n\t\t$domain = Gettext::$config['domain'];\n\n\t\tif (($time = $cache->get('gettext-refresh')) !== NULL)\n\t\t{\n\t\t\t// Grab temporary language file to use if one is set, otherwise use default\n\t\t\t$domain .= '-'.$time;\n\t\t}\n\n\t\t// Bind text domain\n\t\tbindtextdomain($domain, APPPATH.Kohana::config('gettext.directory'));\n\t\ttextdomain($domain);\n\n\t\t// Grab current locale\n\t\t$locale = Kohana::config('locale.language');\n\n\t\t// Update environment to current locale\n\t\tputenv('LC_ALL='.$locale[0]);\n\t}", "title": "" }, { "docid": "7b8fa004bf92f2d0f368d99dc5aaa6b4", "score": "0.61530817", "text": "function __construct($language) {\n\t\tparent::__construct($language);\n\t}", "title": "" }, { "docid": "2ca8d544fbc370131e1fc0c5180e7cb8", "score": "0.61486685", "text": "function load_language ()\n\t{\n\t\t$file_name = $this->language_path . $this->language . '.php';\n\t\tif ( !is_readable($file_name))\n\t\t{\n\t\t\t$this->error = GESHI_ERROR_NO_SUCH_LANG;\n\t\t\treturn;\n\t\t}\n\t\trequire($file_name);\n\t\t// Perhaps some checking might be added here later to check that\n\t\t// $language data is a valid thing but maybe not\n\t\t$this->language_data = $language_data;\n\t\t// Set strict mode if should be set\n\t\tif ( $this->language_data['STRICT_MODE_APPLIES'] == GESHI_ALWAYS )\n\t\t{\n\t\t\t$this->strict_mode = true;\n\t\t}\n\t\t// Set permissions for all lexics to true\n\t\t// so they'll be highlighted by default\n\t\t$this->enable_highlighting();\n\t\t// Set default class for CSS\n\t\t$this->overall_class = $this->language;\n\t}", "title": "" }, { "docid": "40ce781defccf4bc097fd569645d56bb", "score": "0.6146483", "text": "public function initLanguage()\n {\n if ($this->request->getParam('lang') !== null)\n {\n $this->setLanguage($this->request->getParam('lang'));\n }\n\n }", "title": "" }, { "docid": "f871506751a0304cd7705fbd8371670e", "score": "0.61435026", "text": "public static function init() {\n\n // Create the array of CodeSnippetOnline programming language names\n self::$cso_languages = array(\n \"c++\",\n \"c#\",\n \"c\",\n \"java\",\n \"javascript\",\n \"python\",\n \"lua\",\n \"php\",\n \"html\"\n );\n\n // Create the array of AceEditor programming language names\n self::$ace_languages = array(\n \"c_cpp\",\n \"csharp\",\n \"c_cpp\",\n \"java\",\n \"javascript\",\n \"python\",\n \"lua\",\n \"php\",\n \"html\"\n );\n\n }", "title": "" }, { "docid": "d53640297eb30619bc7ba277fe746838", "score": "0.6134648", "text": "public function initialize()\n {\n $this->request = Request::createFromGlobals();\n $this->language = Intl::getLanguageBundle();\n\n\n // Add Extension template path\n $this->app['twig.loader.filesystem']->addPath(__DIR__ . '/assets');\n\n // and register the included Twig functions and filters\n $this->addTwigFunction('i18n_lang', 'languageNameFromLocale');\n $this->addTwigFunction('i18n_link', 'languageLink');\n $this->addTwigFunction('i18n_menu', 'localizedMenu');\n $this->addTwigFunction('i18n_langmenu', 'languageMenu');\n $this->addTwigFunction('i18n_attribute', 'localizedField');\n $this->addTwigFunction('i18n_key', 'localizedFieldKey');\n\n $this->addTwigFilter('i18n_lang', 'languageNameFromLocale');\n $this->addTwigFilter('i18n_link', 'languageLink');\n $this->addTwigFilter('i18n_attribute', 'localizedField');\n $this->addTwigFilter('i18n_key', 'localizedFieldKey');\n\n\n // Handle locale setup\n $this->default_locale = $this->app['config']->get('general/locale', Application::DEFAULT_LOCALE);\n $this->session = $this->app['session'];\n $this->saveLocale($this->getLocale());\n\n // Indicate content menu shall be fetched from translation\n if ( $this->locale == $this->default_locale)\n $this->app['i18n'] = $this->locale;\n\n // Make language change in administration menu available\n $this->languageMenuAdmin();\n\n // Add i18n Content fields\n $this->i18nContent();\n }", "title": "" }, { "docid": "85ec7f390b7b3737af8b31e7768401a5", "score": "0.61309063", "text": "protected function init_i18n_support() {\n\t\tif ( $this->i18n_support_loaded ) {\n\t\t\treturn;\n\t\t}\n\t\tload_plugin_textdomain( 'tablepress', false, dirname( TABLEPRESS_BASENAME ) . '/i18n' );\n\t\t$this->i18n_support_loaded = true;\n\t}", "title": "" }, { "docid": "0c8f1ac58195a5afce5e3b26fcfdb9c1", "score": "0.61272067", "text": "function __construct () {\n\t\tparent::__construct();\n\t\t$this->load->model(\"smssettings_m\");\n\t\t$language = $this->session->userdata('lang');\n\t\t$this->lang->load('smssettings', $language);\n\t}", "title": "" }, { "docid": "2fef3119822d038e8f87cb5e7cae7b37", "score": "0.6126945", "text": "function __construct(){\t\t\t\r\n\t\t\t$this->pluginURL = WP_PLUGIN_URL . '/' . dirname(plugin_basename(__FILE__));\r\n\t\t\t$this->pluginDIR = WP_PLUGIN_DIR . '/' . dirname(plugin_basename(__FILE__));\r\n\r\n\t\t\t//Language Setup\r\n\t\t\t$locale = get_locale();\r\n\t\t\t$mo = $this->pluginDIR . \"/languages/\" . strtolower($locale).\".mo\";\r\n\t\t\tload_textdomain($this->localized, $mo);\r\n\t\t\t\r\n\t\t\t$this->query_wordpress_apis();\r\n\t\t\t$this->determine_theme_override();\r\n\t\t\t$this->register_hooks();\r\n\t\t}", "title": "" }, { "docid": "05219b5116df37b94e50b43d25a141c1", "score": "0.6111104", "text": "public function __construct()\n {\n // load languages\n $this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);\n }", "title": "" }, { "docid": "bfb0cb343f70d2ac1bdfdade20973a19", "score": "0.61087775", "text": "private function initLocale() {\r\n $this->register(new TranslationServiceProvider(), array (\r\n 'locale_fallbacks' => array (\r\n LOCALE \r\n ),\r\n 'locale' => LOCALE \r\n ) );\r\n }", "title": "" }, { "docid": "4e829ed9514b299915d39545ba0c1b5c", "score": "0.6101448", "text": "protected function lang()\n {\n }", "title": "" }, { "docid": "c1faaeb11f728b0d06ac1ff09c562870", "score": "0.6094557", "text": "public function init()\n {\n \n $this->getI18n();\n\n return true;\n \n }", "title": "" }, { "docid": "b5c8db22de095c7bdf555d56ab1d0c8c", "score": "0.60842943", "text": "public function load_localisation () {\n\t\t\n\t\tload_plugin_textdomain( $this->settings->plugin->slug, false, dirname( plugin_basename( $this->file ) ) . '/lang/' );\n\t}", "title": "" }, { "docid": "1456cec68f03c8ec090c9b25c585f7fa", "score": "0.60794175", "text": "public function __construct($runtimeContext) {\n\n\t\t// a little magic to find the current instantiated class's folder\n\t\t$currClass = new ReflectionClass(get_class($this));\n\t\t$currClassFolder = dirname($currClass->getFileName());\n\n\t\t$defaultLangFileStr = Core::getDefaultLanguageFile();\n\t\t$currentLangFileStr = Core::$language->getCurrentLanguageFile();\n\n\t\t$currentLangFile = $currClassFolder . \"/lang/\" . $currentLangFileStr . \".php\";\n\t\t$defaultLangFile = $currClassFolder . \"/lang/\" . $defaultLangFileStr . \".php\";\n\n\t\tif (file_exists($currentLangFile)) {\n\t\t\trequire($currentLangFile);\n\t\t} else if (file_exists($defaultLangFile)) {\n\t\t\trequire($defaultLangFile);\n\t\t}\n\n\t\tif (isset($L)) {\n\t\t\t$this->L = $L;\n\t\t}\n\t}", "title": "" }, { "docid": "8295ed3ae3a558bdd3b336fdd96ed5a2", "score": "0.6076634", "text": "private static function set_locale() {\n\n $plugin_i18n = new PTB_Submission_i18n();\n $plugin_i18n->set_domain(self::$plugin_name);\n $plugin_i18n->load_plugin_textdomain();\n }", "title": "" }, { "docid": "676e903540d75250f68b6e2e1b312854", "score": "0.6060909", "text": "public function localization_setup() {\n load_plugin_textdomain( 'snhotel', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n }", "title": "" }, { "docid": "22d233c3f782647aaa4e0ebea0bd4de5", "score": "0.60529405", "text": "public function localization() {\r\n\r\n\t\tload_plugin_textdomain(\r\n\t\t\t'mediahub', // Unique identifier\r\n\t\t\tfalse, // Deprecated abs path\r\n\t\t\tdirname( plugin_basename( __FILE__ ) ) . '/languages/' // Languages folder\r\n\t\t);\r\n\r\n\t}", "title": "" }, { "docid": "98ebaf946a25307d6a12bf4779cdf121", "score": "0.6046245", "text": "public function load_translation() {\n\n\t\tload_plugin_textdomain( 'wc-pre-orders', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );\n\t}", "title": "" }, { "docid": "7776b77326f4ac1d6898d401e2230283", "score": "0.60444283", "text": "protected function _initTranslate() {\n\n if (php_sapi_name() != 'cli') {\n\n if (strcmp(substr($_SERVER['SERVER_NAME'], 0, 4), 'api.') !== 0) {\n\n //Register translate plugin\n $frontController = Zend_Controller_Front::getInstance(); \n $frontController->registerPlugin(new Nexva_Plugin_Translate());\n \n }\n }\n }", "title": "" } ]
a5d8b6ef64e6b39186c085edd3cb578c
Return the number of vertices in the graph.
[ { "docid": "4d64e8125a89c557880fd20e49104e17", "score": "0.73249537", "text": "public function countAllVertices();", "title": "" } ]
[ { "docid": "4cbef8029fb965b85545b6c699ef6065", "score": "0.682634", "text": "function get_num_vertices($thefile){\n $content = file($thefile, FILE_IGNORE_NEW_LINES);\n return count($content);\n}", "title": "" }, { "docid": "31b4306b2657b303eb7d02a47ed61262", "score": "0.66949606", "text": "public function count()\n {\n return count($this->nodes);\n }", "title": "" }, { "docid": "31b4306b2657b303eb7d02a47ed61262", "score": "0.66949606", "text": "public function count()\n {\n return count($this->nodes);\n }", "title": "" }, { "docid": "0eb807b1918e3368a94a7e4088095672", "score": "0.6688573", "text": "public function count(): int\n\t{\n\t\treturn count( $this->nodes );\n\t}", "title": "" }, { "docid": "e6cd34cb030bb82917db110db611861a", "score": "0.66758627", "text": "public function count() {\n return count($this->nodes);\n }", "title": "" }, { "docid": "f40c07cc6ed2fc8978db100cc58b2d16", "score": "0.646535", "text": "public function vertices();", "title": "" }, { "docid": "673030a0dd1d06682ea2ac577fcb536b", "score": "0.6447813", "text": "public function getNumNodes()\n {\n return $this->num_nodes;\n }", "title": "" }, { "docid": "85226349cbf5c2ec96f475e803da5015", "score": "0.6352108", "text": "public function getNumberOfNodes()\n {\n return count($this->nodeList);\n }", "title": "" }, { "docid": "d2be4ee55cb6c5829839a69d4e0003b6", "score": "0.62130606", "text": "public function count()\n {\n return count( $this->visited );\n }", "title": "" }, { "docid": "24dff1325a64babc79d3f33d739176f3", "score": "0.61375606", "text": "public function getNodeCount()\n {\n return $this->node_count;\n }", "title": "" }, { "docid": "b9a6afe9017170424d8e32919e42d12d", "score": "0.6125842", "text": "public function count()\n {\n return count($this->rootNode);\n }", "title": "" }, { "docid": "4091b14a7bbf9c382b09f79bebd2f7e6", "score": "0.60249496", "text": "protected function countVerts($row) {\n\t\t$count = 0;\n\t\t$pos = strpos($row, '|');\n\t\twhile ($pos !== false) {\n\t\t\t$count++;\n\t\t\t$pos = strpos($row, '|', $pos+1);\n\t\t}\n\t\treturn $count;\n\t}", "title": "" }, { "docid": "5a3a68a1498137d48664e27a5c0396d6", "score": "0.5931995", "text": "public function count()\n {\n return count($this->vector);\n }", "title": "" }, { "docid": "c1537ba04d261b588df118baf298a3ff", "score": "0.59245855", "text": "public function countAllEdges();", "title": "" }, { "docid": "ce13a8631db6368323e2bbd3aaa19bd3", "score": "0.5913384", "text": "public function getVertices(): array\n {\n return $this->vertices;\n }", "title": "" }, { "docid": "56e4ba18afb146a442420e09fcb2a0fc", "score": "0.5774818", "text": "public function length(): int\n {\n return count($this->getCoordinates());\n }", "title": "" }, { "docid": "5d434de2a9613bfcf01beb2469c121cf", "score": "0.5700742", "text": "private function _countNodes() {\n $sql = sprintf('SELECT COUNT(`%1$s`) FROM `%2$s` AS `count`',\n $this->table['nid'], $this->table['tbl']);\n\n if (!$result->$this->db->query($sql)) {\n return $this->_setError(100, '_countNodes()', $sql);\n }\n\n if (!$result->num_rows) {\n return $this->_setError(201, '_countNodes()', $sql);\n }\n\n $row = $result->fetch_assoc();\n\n return $row['count'];\n }", "title": "" }, { "docid": "0984f51a3582da85e0ab49aa13181c8c", "score": "0.56975234", "text": "public function count(): int\n {\n return count($this->pairs);\n }", "title": "" }, { "docid": "a54cc42b631759fdc273fa791b31a115", "score": "0.564178", "text": "public function getNumberOfAncestors()\n {\n return count($this->ancestry);\n }", "title": "" }, { "docid": "911dfb4bf2ede3f49118aa9f1ba76563", "score": "0.56307507", "text": "public function count(): int\n {\n $count = 1;\n foreach ($this->constraints as $constraint) {\n $count += count($constraint);\n }\n\n return $count;\n }", "title": "" }, { "docid": "8f98aeaee73dd02b6258aec3b93c8abf", "score": "0.56270033", "text": "public function numberClients()\n {\n $query = (\"SELECT clientes.id_cliente FROM clientes\");\n $conn = Connection::prepare($query);\n $conn->execute();\n return $conn->rowCount();\n }", "title": "" }, { "docid": "30b58125b489a64ab6de820500eb1100", "score": "0.56212574", "text": "function getDepth()\n {\n return count($this->getPath());\n }", "title": "" }, { "docid": "13562b5d8f1f36f9d4aeac3f514a9759", "score": "0.5617073", "text": "public function getNumberOfVersions()\n {\n return $this->_numberOfVersions;\n }", "title": "" }, { "docid": "7e3fb6426f6be80ad8abb0414bbcc6d8", "score": "0.56006306", "text": "public function count() : int\n {\n return count($this->rings);\n }", "title": "" }, { "docid": "3bebca4b259cd719024626dd5c9af66e", "score": "0.5599565", "text": "public function count(): int\n {\n return $this->engine()->count($this);\n }", "title": "" }, { "docid": "f1607515d4dad8c2b61b962042a2c5d9", "score": "0.5585134", "text": "public function GetCount( ) {\n \n return count( $this->m_a_constraints );\n \n }", "title": "" }, { "docid": "e869cfbee7ce4a2642022c4ea477d4f9", "score": "0.55815107", "text": "public function count(): int {\n return count($this->children);\n }", "title": "" }, { "docid": "15fb36bb68f2eb359b67b51265c7381d", "score": "0.557867", "text": "public function getPathCount() {\n return count($this->getPathArray());\n }", "title": "" }, { "docid": "7acad272a88c0f92520e45c077ba9142", "score": "0.5576726", "text": "public function count() : int {\n return $this->size();\n }", "title": "" }, { "docid": "f070a6298619d2508d3e93f41cf206b3", "score": "0.5549786", "text": "public function count()\n {\n return $this->_collection->getSize();\n }", "title": "" }, { "docid": "c89ac7e936ffab6dbf414e5d149cfdef", "score": "0.5536211", "text": "public function count()\n {\n return $this->getNeuronCount();\n }", "title": "" }, { "docid": "89b5a68f67cce90fa50b724137c89a4b", "score": "0.5530588", "text": "public function count() {\n\t\treturn $this->_iterator->count();\n\t}", "title": "" }, { "docid": "8adb5384754989bf5ab57715d6846279", "score": "0.5509202", "text": "public function getClientCount()\n {\n return $this->_intClients;\n }", "title": "" }, { "docid": "c2a087745bfb90178ac48f9ee5c82e4c", "score": "0.54822135", "text": "public function count()\n\t{\n\t\t//\t@TODO use array_* functions to count in a more performant way\n\n\t\t$count = 0;\n\t\t/** @var Collection $collection */\n\t\tforeach ($this->hashes as $collection)\n\t\t{\n\t\t\t$count += $collection->count();\n\t\t}\n\n\t\treturn $count;\n\t}", "title": "" }, { "docid": "6573d2e9eedf703be7465e58ed9dde9b", "score": "0.5476233", "text": "public function count() : int\n {\n return count($this->data);\n }", "title": "" }, { "docid": "c7f09ee591aeacb8cab5b5803ee972a1", "score": "0.54591274", "text": "public function count() : int\n {\n return count($this->data);\n }", "title": "" }, { "docid": "84d4a6dae66c05e56a8fbca17ecb8f33", "score": "0.5451944", "text": "public function count(): int\n {\n return count($this->_objData);\n }", "title": "" }, { "docid": "2ef4fafc441baa26a6d372f4a3442dac", "score": "0.54502726", "text": "public function count()\n {\n return count($this->rings);\n }", "title": "" }, { "docid": "a02c0e7c35e0fc49939dcfb1c6790a9f", "score": "0.54433984", "text": "function count() {\n return count($this->parts);\n }", "title": "" }, { "docid": "41166d22c6c3dc5ecca5fd8287820615", "score": "0.5441399", "text": "public function count()\n\t{\n\t\treturn $this->_db->query('SELECT COUNT(*) FROM client')->fetchColumn();\n\t}", "title": "" }, { "docid": "090b897894fb0f26cdae1f9575e7c4e2", "score": "0.5441176", "text": "public function count()\n\t{\n\t\treturn count($this->_data);\n\t}", "title": "" }, { "docid": "090b897894fb0f26cdae1f9575e7c4e2", "score": "0.5441176", "text": "public function count()\n\t{\n\t\treturn count($this->_data);\n\t}", "title": "" }, { "docid": "7f6a900372293c5afb5fb94873f09d85", "score": "0.5436281", "text": "public function count()\n {\n return count($this->variables);\n }", "title": "" }, { "docid": "fb84cb9c635322d03ba8027ec712fe7d", "score": "0.5436178", "text": "public function count(){\r\n return count($this->collection);\r\n }", "title": "" }, { "docid": "3b80f88cec166765ce2e9a416949deaa", "score": "0.54340035", "text": "public function count(): int {\n return count($this->data);\n }", "title": "" }, { "docid": "628fa839362f23bd41ef81add55ddc0f", "score": "0.54281443", "text": "public function count()\n {\n return $this->getIterator()->count();\n }", "title": "" }, { "docid": "82441e944ae93ca356eedde54d8bc437", "score": "0.54266334", "text": "public function count()\n {\n return $this->length();\n }", "title": "" }, { "docid": "e3924bb5ca94f10b5ced9a97d82ddf2f", "score": "0.5421648", "text": "public function count()\n {\n return $this->length;\n }", "title": "" }, { "docid": "25187bda6491daaced620013f82fa93d", "score": "0.5418793", "text": "public function count()\n {\n return count($this->connections);\n }", "title": "" }, { "docid": "beeec13384c5b6a3cd8f011424dde8e9", "score": "0.5412803", "text": "public function getRowCount()\n {\n if (array_key_exists(\"rowCount\", $this->_propDict)) {\n return $this->_propDict[\"rowCount\"];\n } else {\n return null;\n }\n }", "title": "" }, { "docid": "3e0fb3257cd2f3932629dc6ba6f2acca", "score": "0.5410897", "text": "public function count(): int\n {\n return count($this->data);\n }", "title": "" }, { "docid": "fc109158413f4f06d5021ba478e08e07", "score": "0.54073524", "text": "public function count(){\n return count($this->componentes);\n }", "title": "" }, { "docid": "d18ef1f0776c1790647068a8d9f533d3", "score": "0.5406707", "text": "public function count()\n {\n return count($this->_data);\n }", "title": "" }, { "docid": "517042f4212c0105140f4dc28c673f98", "score": "0.54039294", "text": "public function count() {\n return count($this->epGetVars()); // oid included\n }", "title": "" }, { "docid": "dc2435d3c429f31b07f024fbe475c69c", "score": "0.54037935", "text": "public function count() {\n\t\treturn count($this->data);\n\t}", "title": "" }, { "docid": "dc2435d3c429f31b07f024fbe475c69c", "score": "0.54037935", "text": "public function count() {\n\t\treturn count($this->data);\n\t}", "title": "" }, { "docid": "2ec430cfe9e6de6106d8c7a1b6e23e69", "score": "0.53977203", "text": "public function getCount()\n {\n $count = 0;\n \n if(!$this->getData()) {\n return $count;\n }\n \n foreach($this->getData() as $vhosts) {\n $count = ($count + count($vhosts));\n }\n \n return $count;\n }", "title": "" }, { "docid": "f0c17ab86c316d0809cb18b32baf5786", "score": "0.53972566", "text": "public function count() {\n\t\treturn count($this->data); \n\t}", "title": "" }, { "docid": "b9d1527b6bd00ffacbad11f9322c195e", "score": "0.53963804", "text": "public function count()\n {\n return $this->numOfRows;\n }", "title": "" }, { "docid": "ba6b23a397ca47236a9176dd04393db1", "score": "0.53919005", "text": "public function getNumberOfEntries()\n {\n return $this->createQuery()->count();\n }", "title": "" }, { "docid": "2b77c34f256909d11c9c86dede346d7e", "score": "0.53911483", "text": "public function count()\n {\n return count($this->getRoutes());\n }", "title": "" }, { "docid": "6197a6f68ecd514e7ee0c50d23ab1450", "score": "0.53901094", "text": "public function count() {\n\t\treturn count( $this->data );\n\t}", "title": "" }, { "docid": "e2ce62862f103296dc86f2295163f8f6", "score": "0.5385359", "text": "public function clientsCount() {\n $query = 'SELECT * FROM `clair_users` WHERE `idUserType` = 3 ';\n $result = $this->BDD->query($query);\n $result->execute();\n $usersCount = $result->rowCount();\n return $usersCount;\n }", "title": "" }, { "docid": "6f285fc81cd4229984f1d51cfb8bfa90", "score": "0.53849167", "text": "public function count()\n {\n return $this->numberOfElements;\n }", "title": "" }, { "docid": "e334e71e592a58059774fb4d340a1307", "score": "0.5379107", "text": "public function count() {\n\t\treturn count($this->dataArray);\n\t}", "title": "" }, { "docid": "6ad5aad53f7093aa354bc8830c8158ac", "score": "0.53779006", "text": "public function count() {\n\t\treturn $this->size;\n\t}", "title": "" }, { "docid": "da2d14b5e9d98d79527d97a5d4566af3", "score": "0.537744", "text": "public function count()\n\t{\n\t\treturn $this->getCount();\n\t}", "title": "" }, { "docid": "b5ec4ece8764003caeb712b9e341fc49", "score": "0.5375608", "text": "public function size() {\n return count($this->data);\n }", "title": "" }, { "docid": "dbdb9af0422eebf1aa47533a7bd4aa3d", "score": "0.5371161", "text": "public function count()\n {\n return count($this->collection());\n }", "title": "" }, { "docid": "2ca51f60340875e1bc0ae2abd2bbd377", "score": "0.53686714", "text": "public function count(): int\n {\n return count($this->elements);\n }", "title": "" }, { "docid": "5f886ba70bca15405e3b2455b0eb0c5e", "score": "0.53672516", "text": "public function getRowCount(): int\n\t{\n\t\treturn intval(\n\t\t\t$this\n\t\t\t\t->createQueryBuilder('u')\n\t\t\t\t->select('COUNT(u)')\n\t\t\t\t->getQuery()\n\t\t\t\t->getSingleScalarResult()\n\t\t);\n\t}", "title": "" }, { "docid": "cb5c2c12fb848d78a6a38cc3639f39e1", "score": "0.536694", "text": "public function count()\n\t{\n\t return $this->_db->query('SELECT COUNT * FROM clients')->fetchColumn();\n\t}", "title": "" }, { "docid": "96c186fa55464b968d90a412208fd61f", "score": "0.53642696", "text": "public function getVisitors()\n {\n return (int) $this->getProperty('visitors');\n }", "title": "" }, { "docid": "b1661402f81a934a93f9d1527d80f810", "score": "0.53629744", "text": "public function getMinNodeCount()\n {\n return $this->min_node_count;\n }", "title": "" }, { "docid": "47965a574549a9ea6160695e69ccf783", "score": "0.53602177", "text": "public function count()\n {\n return count($this->collection);\n }", "title": "" }, { "docid": "47965a574549a9ea6160695e69ccf783", "score": "0.53602177", "text": "public function count()\n {\n return count($this->collection);\n }", "title": "" }, { "docid": "47965a574549a9ea6160695e69ccf783", "score": "0.53602177", "text": "public function count()\n {\n return count($this->collection);\n }", "title": "" }, { "docid": "47965a574549a9ea6160695e69ccf783", "score": "0.53602177", "text": "public function count()\n {\n return count($this->collection);\n }", "title": "" }, { "docid": "677f8c15f6b2a23bcd66888d871b14e8", "score": "0.53584784", "text": "public function count() {\n\t\treturn count($this->properties);\n\t}", "title": "" }, { "docid": "75f70daee992504b23fe7483c541fa8c", "score": "0.5358128", "text": "public function getRowCount()\n\t\t{\n\t\t\treturn count($this->rows);\n\t\t}", "title": "" }, { "docid": "75f70daee992504b23fe7483c541fa8c", "score": "0.5358128", "text": "public function getRowCount()\n\t\t{\n\t\t\treturn count($this->rows);\n\t\t}", "title": "" }, { "docid": "5ffc90151bc7d513ea76368f8a61f5d9", "score": "0.53534824", "text": "public function getRowCount()\n {\n return $this->row_count;\n }", "title": "" }, { "docid": "5ffc90151bc7d513ea76368f8a61f5d9", "score": "0.53534824", "text": "public function getRowCount()\n {\n return $this->row_count;\n }", "title": "" }, { "docid": "43e4ac073620439e3a02b88dad9feaa3", "score": "0.5348117", "text": "public function count()\n {\n return count($this->_elements);\n }", "title": "" }, { "docid": "a7e1de06f0205b6134c809d52aac7019", "score": "0.5347355", "text": "public function getNumberOfDiaNodes()\n {\n return count($this->diaNodeList);\n }", "title": "" }, { "docid": "43743b7a3fcb3f90d9dd5b7fa09147f2", "score": "0.53473103", "text": "public function count()\n {\n $count = 0;\n foreach ($this->routes as $route) {\n $count += $route instanceof RouteCollection ? count($route) : 1;\n }\n\n return $count;\n }", "title": "" }, { "docid": "490178d83b3a392e10531d2f84a0ce5d", "score": "0.5345563", "text": "public static function count($key)\n\t{\n\n\t\t$query = \\Drupal::database()->select('node__nodekey', 'nk');\n\t\t$query->condition('nk.nodekey_value', $key);\n\t\t$stmt = $query->execute();\n\t\t$results = $stmt->fetchAll();\n\n\t\treturn count($results);\n\t}", "title": "" }, { "docid": "e52e746d51c72da701cea82f99985143", "score": "0.5337766", "text": "public function count()\n\t{\n\t\treturn count($this->elements);\n\t}", "title": "" }, { "docid": "5c4fd076099caf57e00842d8b1baf128", "score": "0.53334904", "text": "public function countVotes ()\n\t{\n\t\treturn count($this->_Votes) ;\n\t}", "title": "" }, { "docid": "0bb0229e1ca3836cbfe843d8e7ee4ba8", "score": "0.5331623", "text": "public function count()\n {\n return count($this->data);\n }", "title": "" }, { "docid": "4e1961cc6a3b3ea4748dd739d6a54bef", "score": "0.5327294", "text": "public function get_venue_count()\n {\n return $this->db->count_all($this->table_name);\n }", "title": "" }, { "docid": "7199aa13a27c9efb81c5abdf7421b747", "score": "0.53250533", "text": "public function getSegsCount()\n {\n return $this->count(self::SEGS);\n }", "title": "" }, { "docid": "ed4750e7542a5e95029c5b01642c2e32", "score": "0.532046", "text": "public function count()\n {\n return count($this->data);\n }", "title": "" }, { "docid": "ed4750e7542a5e95029c5b01642c2e32", "score": "0.532046", "text": "public function count()\n {\n return count($this->data);\n }", "title": "" }, { "docid": "ed4750e7542a5e95029c5b01642c2e32", "score": "0.532046", "text": "public function count()\n {\n return count($this->data);\n }", "title": "" }, { "docid": "ed4750e7542a5e95029c5b01642c2e32", "score": "0.532046", "text": "public function count()\n {\n return count($this->data);\n }", "title": "" }, { "docid": "ed4750e7542a5e95029c5b01642c2e32", "score": "0.532046", "text": "public function count()\n {\n return count($this->data);\n }", "title": "" }, { "docid": "ed4750e7542a5e95029c5b01642c2e32", "score": "0.532046", "text": "public function count()\n {\n return count($this->data);\n }", "title": "" }, { "docid": "ed4750e7542a5e95029c5b01642c2e32", "score": "0.532046", "text": "public function count()\n {\n return count($this->data);\n }", "title": "" }, { "docid": "ed4750e7542a5e95029c5b01642c2e32", "score": "0.532046", "text": "public function count()\n {\n return count($this->data);\n }", "title": "" } ]
03c661f5664214d3659bb15e7814ac3e
put your code here
[ { "docid": "f65208b33d15cd3c48024540e61a12eb", "score": "0.0", "text": "public function init() {\n \n //Charge entity\n $this->addElement('text', 'condition_type', array(\n 'label' => 'Vehicle condition',\n 'required' => true,\n ));\n \n //charge id\n $this->addElement('hidden', 'condition_id');\n \n //save btn\n $this->addElement('submit', 'sub', array(\n 'class' => 'fan-sub btn btn-primary ',\n 'required' => false,\n 'ignore' => true,\n 'label' => 'Submit',\n 'decorators' => array(\"ViewHelper\"\n )));\n }", "title": "" } ]
[ { "docid": "2b8f8c258221a7336b898b1eb6e48695", "score": "0.62954557", "text": "protected function run() {\n\t\t\n\t}", "title": "" }, { "docid": "657b97cd6a1d79b798c25b9f5cd4053d", "score": "0.5984761", "text": "public function run()\n\t{\n\t\t\n\t}", "title": "" }, { "docid": "e3d82f58ec0321319c4baa899d713d08", "score": "0.59769094", "text": "public function run()\n {\n //they do not have to all be in their own files\n }", "title": "" }, { "docid": "1cc71ec31f252c60a7b5ef45f1ab9d56", "score": "0.59494543", "text": "public function run()\n {\n\n \n }", "title": "" }, { "docid": "8700585e82506e1800ed11a852350b58", "score": "0.59041286", "text": "public function run()\n {\n\n\n\n\n\n\n\n }", "title": "" }, { "docid": "9589236b286cd97682f035bfd34627a3", "score": "0.5902813", "text": "public function run()\n {\n\n\n }", "title": "" }, { "docid": "1125b9b9060aa78a85f16c2b3ad0cc32", "score": "0.5896888", "text": "public function run()\n\t{\n\n\t}", "title": "" }, { "docid": "07c6991c3acfd5a15f5b043afb196f08", "score": "0.5889101", "text": "public function main(){\n\t\t/*TODO Not Implemented Yet*/\n\t}", "title": "" }, { "docid": "d90346d9c55e5bc9132fa41fa092a051", "score": "0.58529335", "text": "public function run()\n {\n \n }", "title": "" }, { "docid": "5287a3cae09de3f82dfc3a3521cc84aa", "score": "0.5840664", "text": "public function run(){\n }", "title": "" }, { "docid": "97366c9dcf73017823698a01acd21ff7", "score": "0.5838488", "text": "public function run()\n {\n \n }", "title": "" }, { "docid": "97366c9dcf73017823698a01acd21ff7", "score": "0.5838488", "text": "public function run()\n {\n \n }", "title": "" }, { "docid": "60f44aa73f8af8546ad75b8860da3711", "score": "0.5835068", "text": "public function run()\n\t{\n\t}", "title": "" }, { "docid": "60f44aa73f8af8546ad75b8860da3711", "score": "0.5835068", "text": "public function run()\n\t{\n\t}", "title": "" }, { "docid": "60f44aa73f8af8546ad75b8860da3711", "score": "0.5835068", "text": "public function run()\n\t{\n\t}", "title": "" }, { "docid": "60f44aa73f8af8546ad75b8860da3711", "score": "0.5835068", "text": "public function run()\n\t{\n\t}", "title": "" }, { "docid": "40910eec646c76ba4e3004dc7c1d4590", "score": "0.58256304", "text": "public function run()\n {\n \n }", "title": "" }, { "docid": "4c9d60823941369a5f02a0fc5ccc8814", "score": "0.5814271", "text": "public function run()\n {\n //\n }", "title": "" }, { "docid": "4c9d60823941369a5f02a0fc5ccc8814", "score": "0.5814271", "text": "public function run()\n {\n //\n }", "title": "" }, { "docid": "4c9d60823941369a5f02a0fc5ccc8814", "score": "0.5814271", "text": "public function run()\n {\n //\n }", "title": "" }, { "docid": "4c9d60823941369a5f02a0fc5ccc8814", "score": "0.5814271", "text": "public function run()\n {\n //\n }", "title": "" }, { "docid": "564f1c018a8e177afc3c3c2af7aec5e4", "score": "0.5795906", "text": "public function run() {\n\t}", "title": "" }, { "docid": "21a30009fef12e59eadcef41e7faaab3", "score": "0.5793063", "text": "public function run() {\n\t\t// do something\n\t}", "title": "" }, { "docid": "b38b490aee2837b62af372de03ca6936", "score": "0.5784379", "text": "public function code()\n {\n// $code->make();\n\n }", "title": "" }, { "docid": "b3658b5635f72356515889ff6c051561", "score": "0.5763963", "text": "public function run ();", "title": "" }, { "docid": "65d01385f3dba96529f031c98c37d295", "score": "0.5732597", "text": "public function run(){\n\n }", "title": "" }, { "docid": "82eceef9bb908615d58be88162ab80b9", "score": "0.572564", "text": "public function mahasiswa()\n\t{\n\t\t// YOUR_CODE_HERE\n\n\t}", "title": "" }, { "docid": "c5f7bc6bfbb03ae36eb1d257d2f88a5e", "score": "0.5724911", "text": "function OnPreContent()\n\t\t{\n\t\t}", "title": "" }, { "docid": "7575f7e169bd1a9358ffde8bd5ba93b9", "score": "0.5706711", "text": "protected function _bgin(){\n\t}", "title": "" }, { "docid": "7b7ac68985784575d7255019056a6cc0", "score": "0.5704364", "text": "public function jurusan()\n\t{\n\t\t// YOUR_CODE_HERE\n\n\t}", "title": "" }, { "docid": "79a75c16e6070f8ca8980033953a9fb9", "score": "0.5686811", "text": "public function run()\r\n {\r\n }", "title": "" }, { "docid": "6ee05f51d85cc86d492118a196c236d6", "score": "0.5684617", "text": "public function run()\n {\n\n }", "title": "" }, { "docid": "6ee05f51d85cc86d492118a196c236d6", "score": "0.5684617", "text": "public function run()\n {\n\n }", "title": "" }, { "docid": "6ee05f51d85cc86d492118a196c236d6", "score": "0.5684617", "text": "public function run()\n {\n\n }", "title": "" }, { "docid": "6ee05f51d85cc86d492118a196c236d6", "score": "0.5684617", "text": "public function run()\n {\n\n }", "title": "" }, { "docid": "6ee05f51d85cc86d492118a196c236d6", "score": "0.5684617", "text": "public function run()\n {\n\n }", "title": "" }, { "docid": "4a7c00843ec61953ca53f436a64dfcd9", "score": "0.5672524", "text": "public function process() {\n\t\t\n\t}", "title": "" }, { "docid": "7ef36dc5497662568b799d5810f473ad", "score": "0.5663446", "text": "function run()\n {\n }", "title": "" }, { "docid": "aa6f34c4fc15424f3cbaa1218a070fa5", "score": "0.56619155", "text": "public function runForSecretary()\n {\n // do something here ...\n }", "title": "" }, { "docid": "aa6f34c4fc15424f3cbaa1218a070fa5", "score": "0.56619155", "text": "public function runForSecretary()\n {\n // do something here ...\n }", "title": "" }, { "docid": "b81656bae00549ac5ecbacd4b9eb1845", "score": "0.5652412", "text": "public function exec()\r\n\t{\r\n\t\t\r\n\t}", "title": "" }, { "docid": "944a66d5d35a86ff51dd61db239ee2d8", "score": "0.56460613", "text": "public function ingresar(){\n\t\t}", "title": "" }, { "docid": "f0a743a6e678a1b58368783f7d76731a", "score": "0.5640017", "text": "protected function render_content() {\r\n\r\n\t}", "title": "" }, { "docid": "dd79160e84707e8545d7c73b5920ee0c", "score": "0.5615621", "text": "public function asasasd (){\n \t\n }", "title": "" }, { "docid": "71fd9eb280553614419d16367e7c4a5c", "score": "0.56068903", "text": "public function run()\n {\n }", "title": "" }, { "docid": "71fd9eb280553614419d16367e7c4a5c", "score": "0.56068903", "text": "public function run()\n {\n }", "title": "" }, { "docid": "71fd9eb280553614419d16367e7c4a5c", "score": "0.56068903", "text": "public function run()\n {\n }", "title": "" }, { "docid": "71fd9eb280553614419d16367e7c4a5c", "score": "0.56068903", "text": "public function run()\n {\n }", "title": "" }, { "docid": "2e370e0b6efd4a09f08173960a1082d7", "score": "0.5605902", "text": "function function_to_execute(){\n}", "title": "" }, { "docid": "0cfe26304987c534085fe1f46a146e45", "score": "0.5591545", "text": "public function onRun()\n {\n }", "title": "" }, { "docid": "2d2411d7e5fb86ac73072c5ba81f2474", "score": "0.5590587", "text": "public function run()\n {\n parent::run();\n }", "title": "" }, { "docid": "ce7165ef6cd0778e7f535e2648658b6b", "score": "0.55866945", "text": "public function main() {\n \n }", "title": "" }, { "docid": "426b49169f8c7fd319bdbb509ef3d2c0", "score": "0.55736256", "text": "public function index()\n\t{\n\t\t// YOUR_CODE_HERE\n\n\t}", "title": "" }, { "docid": "4dda28c64b2e2afc51b0bf58286bee59", "score": "0.5569824", "text": "function pre_execute() {\n }", "title": "" }, { "docid": "a71f23a67c13fa160cb71e3bca41ba2e", "score": "0.55636305", "text": "public function run() {\n }", "title": "" }, { "docid": "683729ba620ccfb808b0f281e9cd2992", "score": "0.55600923", "text": "private function render()\r\n {\r\n \r\n }", "title": "" }, { "docid": "683729ba620ccfb808b0f281e9cd2992", "score": "0.55600923", "text": "private function render()\r\n {\r\n \r\n }", "title": "" }, { "docid": "7addd717d7fb5262f0a0832a8791fd1b", "score": "0.55518186", "text": "public function crunch() {\n\n\t}", "title": "" }, { "docid": "37b59249947037390ed09920f857a34f", "score": "0.5540965", "text": "function run(){\n }", "title": "" }, { "docid": "0e2bf6b1f4fafb6382b68b25ef04a31c", "score": "0.5539323", "text": "protected function postExecute() {}", "title": "" }, { "docid": "4ff621d0bd952cba81cd39b8cad82142", "score": "0.55240816", "text": "protected function render_content() {\n\t}", "title": "" }, { "docid": "e37a77d3e13afa0fe5d50c8e4f8c7ea2", "score": "0.5523464", "text": "public function run()\n {\n if ($this->registerLinkTags) {\n $this->registerLinkTags();\n }\n echo $this->renderPageContent();\n }", "title": "" }, { "docid": "b127e93b5de90bed38fa52ce2ed95448", "score": "0.55233693", "text": "function postGenerate($code)\r\n {\r\n }", "title": "" }, { "docid": "80ef0efb3d7a1253c9efd3d64c87dfff", "score": "0.5522207", "text": "public function render_content() {\n\n\t}", "title": "" }, { "docid": "e1ab1f4fe3cbcc3d59b6d6c0208ab766", "score": "0.55034596", "text": "public function render_content() {\n\t}", "title": "" }, { "docid": "11403a5b8ef9b72966b6a4413a96d386", "score": "0.5501648", "text": "function preGenerate($code)\r\n {\r\n }", "title": "" }, { "docid": "853a7281c6ec041ad2076942d5121ec4", "score": "0.5477813", "text": "public static function run() \n {\n }", "title": "" }, { "docid": "50bee8fa336d0780a7c7763bd1d877a1", "score": "0.5463167", "text": "protected function _preRun()\n {\n }", "title": "" }, { "docid": "da6792666bdd3372b07644d3efda9b4d", "score": "0.54624856", "text": "function ins(){\n //TODO INS TAG CODE HERE\n\n}", "title": "" }, { "docid": "49027cfb34c58cce6d773249983884a0", "score": "0.5460163", "text": "function OnPostContent()\n\t\t{\t\t\t\n\t\t}", "title": "" }, { "docid": "3d0f35a765391f30e988575de992ebed", "score": "0.54592985", "text": "protected function _postRun()\n {\n }", "title": "" }, { "docid": "0eccd3fe59960c131878585c8048d01c", "score": "0.5453906", "text": "function start()\n {\n\t\thighlight_file($this->getAttrib(\"src\").\".php\");\n\t}", "title": "" }, { "docid": "dd729c980376986c5924d86d657fb8b5", "score": "0.5431284", "text": "public function cnpjrawAction(){\n\t}", "title": "" }, { "docid": "c30bb30b137c9e9c966eab8a09fc6d7f", "score": "0.5426377", "text": "public function render()\n {\n //\n }", "title": "" }, { "docid": "8a5010089a18516e82afe82c4d7d5546", "score": "0.54060566", "text": "protected function Execute_Processing() {\n\t}", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "4a41d9793afc4e93c518b703d0a37cbb", "score": "0.5401934", "text": "public function run();", "title": "" }, { "docid": "c66b640a6426d52f0f96ddddcafdd860", "score": "0.53858167", "text": "public function run()\r\n\t{\r\n\t\t$this->renderSummary();\r\n\t}", "title": "" }, { "docid": "bc2b1fa2c73c37ae2c1b85dcc46d7e50", "score": "0.5385346", "text": "public function postRun() {\n\n\t}", "title": "" }, { "docid": "9b24281c6786204198b9cda72e6eead6", "score": "0.5384571", "text": "function setrecoreds(){\n\n\t\techo \"here is your data \\n\";\n\t}", "title": "" }, { "docid": "6aacf09bf83878836b30e9cfa43185dc", "score": "0.5378832", "text": "public function postExecute()\n {\n }", "title": "" }, { "docid": "3bc7947e23e002491d65055b7ea9587c", "score": "0.5377122", "text": "public function run() {\n Yii::app()->clientScript->registerCssFile('/css/ads300x250.css');\n echo CHtml::openTag($this->tagName, $this->htmlOptions) . \"\\n\";\n echo $this->dataProvider;\n echo CHtml::closeTag($this->tagName);\n }", "title": "" }, { "docid": "db237144d168374b28f42ae71ad3ca06", "score": "0.5369166", "text": "function run(){}", "title": "" }, { "docid": "447f07a081c3573811b9203b65c29a2c", "score": "0.53656536", "text": "function input_admin_head()\n {\n\n }", "title": "" }, { "docid": "be4a2349a01136eb0bd3d6d087c8f138", "score": "0.5365522", "text": "public function run() {}", "title": "" }, { "docid": "be4a2349a01136eb0bd3d6d087c8f138", "score": "0.5365522", "text": "public function run() {}", "title": "" }, { "docid": "0e821227fa6ab212a042a862c353cc9f", "score": "0.53603786", "text": "public function render()\r\n\t{\r\n\t\t\r\n\t}", "title": "" }, { "docid": "a0bc0f0c2abeacaed79a2aeebe3f9609", "score": "0.5345555", "text": "function mediatags_admin_head_proc()\n{\n}", "title": "" }, { "docid": "0908c6d00ed6a786508adad9c5c3c5b6", "score": "0.5339845", "text": "function _custom_page(){\n\t\n\t\n\t\n\t\n\t}", "title": "" }, { "docid": "f6730b7079c7e06a3b334221aedeca57", "score": "0.5331466", "text": "protected function _minutely() {\n\n }", "title": "" } ]
26d71a0b0829d496c8e6bbe23ccaa28a
Display a listing of the resource.
[ { "docid": "d847f88b40caa21fb5d773eca43fa11f", "score": "0.0", "text": "public function index()\n {\n $offers = Offer::all();\n\n\n return view('offer.index')->with([\"offers\"=>$offers]);;\n }", "title": "" } ]
[ { "docid": "a2c82e645f33199ca3af4df01daa0da0", "score": "0.73454344", "text": "public function listAction()\n {\n $this->view->headTitle('Book Listing ','PREPEND');\n $this->view->books = $this->bookService->listService();\n }", "title": "" }, { "docid": "2ecb35785c4b9e881de2de7a961178df", "score": "0.7216204", "text": "public function action_list(){\n\t\t$v = View::factory(static::$entity.'/list');\n\t\t$this->template->body = $v;\n\t}", "title": "" }, { "docid": "dad0a13a73bcf8293bb4d9e710796f56", "score": "0.7157767", "text": "public function listAction()\n {\n $this->processList();\n }", "title": "" }, { "docid": "e5d3acc1f5204195de85b93044bfcb61", "score": "0.71494645", "text": "function listAction()\n {\n $pageTitle = 'Golf listings';\n $listLinkStyle = 'current_page';\n $isLoggedIn = $this->isLoggedInFromSession();\n $username = $this->usernameFromSession();\n\n $golfRepository = new GolfRepository();\n $golfs = $golfRepository->getAll();\n\n require_once __DIR__ . '/../templates/list.php';\n }", "title": "" }, { "docid": "bd3a7b4e07a2548dae8d575849df412a", "score": "0.7130363", "text": "public function index() {\n return view('admin.resources.index', [\n 'resources' => Resource::paginate(10)\n ]);\n }", "title": "" }, { "docid": "174c016a6d20963698d0780d8861782d", "score": "0.710266", "text": "function showListPage() {\n\t\t$this->setCacheLevelNone();\n\n\t\t$this->render($this->getTpl('list'));\n\t}", "title": "" }, { "docid": "598d9caa73e88220c1d2180531a736f9", "score": "0.70930976", "text": "public function index()\n {\n $className = $this->modelClass;\n $model = $className::orderby('created_at', 'desc')->paginate(10);\n \n return view('admin.listing')\n ->with('pageTitle', $this->pageTitle)\n ->with('secondTitle', $this->secondTitle)\n ->with('columns', $this->columns)\n ->with('urlName', $this->urlName)\n ->with('model', $model);\n }", "title": "" }, { "docid": "3e6e80d5cb774ecfe48382a53469b26e", "score": "0.70829386", "text": "public function listAction()\n\t {\n\t\t$model = $this->_getModel();\n\t\t$result = $model->getContents();\t\n\t\t$page = (int)($this->_request->getParam('page'));\n\t\tGlobals::doPaging($result, $page, $this->view); \n\t\t\t\t\t\t\n\t\t$this->view->page = $page;\n\t }", "title": "" }, { "docid": "4033d77018807de6b615c3ca97da7bef", "score": "0.70523685", "text": "public function index()\n {\n return TodoListResource::collection($this->listRepository->list());\n }", "title": "" }, { "docid": "fbd940db6024ed547d75a84196b6efcc", "score": "0.7010042", "text": "public function index()\n {\n //get shows\n $shows = ShowsModel::paginate(10);\n\n return ShowsResource::collection($shows);\n }", "title": "" }, { "docid": "22e061b6e387c7871a6d54e088305a74", "score": "0.69801855", "text": "public function index()\n {\n return RecipeListResource::collection(Recipe::all());\n }", "title": "" }, { "docid": "937d8c67ef1e241cc6f04440a03a35d5", "score": "0.6966139", "text": "public function listing(){\n return view('interface/listing');\n }", "title": "" }, { "docid": "43a3797d462201f8486a324b4e596f68", "score": "0.6948928", "text": "public function list()\n {\n $flash = '';\n\n if(!empty($_SESSION['flash'])){\n $flash = $_SESSION['flash'];\n $_SESSION['flash'] = '';\n }\n\n # it will be populated\n $data = [];\n\n $bookInstance = new Book();\n $books = $bookInstance->select()->get();\n\n # fill data\n $data['flash'] = $flash;\n $data['books'] = $books;\n $data['loggedUser'] = $this->loggedUser;\n $data['url'] = Request::getUrl();\n\n $this->render('library', $data);\n }", "title": "" }, { "docid": "a74b64d14d05fcd4b8d8543c548d39b6", "score": "0.69425523", "text": "public function listAction() {\n $this->_datatable();\n return $this->render('BackendBundle:FeastStageArtist:list.html.twig');\n }", "title": "" }, { "docid": "161606f4dde01f5513c0d576501b3cb7", "score": "0.6905698", "text": "public function _index()\n\t{\n\t\t_root::getRequest()->setAction('list');\n\t\t$this->_list();\n\t}", "title": "" }, { "docid": "836499ad8af32deefc4b356617470307", "score": "0.6899619", "text": "public function index()\n {\n return view('laramanager::entries.index.index')\n ->with('resource', $this->resource)\n ->with('entries', $this->entriesRepository->getList($this->resource));\n }", "title": "" }, { "docid": "378b941376864b0adca2a47f6d9cbc14", "score": "0.6898765", "text": "public function action_index(){\n\t\t$v = View::factory(static::$entity.'/list');\n\t\t$this->template->body = $v;\n\t}", "title": "" }, { "docid": "a657a499da3c1e94405a12a48a398286", "score": "0.6889014", "text": "public function action_list()\n\t{\n\t\t$recordings = Model_Recording::factory()\n\t\t\t->with('Quotes')\n\t\t\t->find_all();\n\n\t\t// Generate and output the view\n\t\t$content = View::factory('recording/list')\n\t\t\t\t ->set('recordings', $recordings);\n\t\t$template = View::factory('templates/default')\n\t\t\t\t\t->set('title', 'All recordings')\n\t\t\t\t\t->set('content', $content->render());\n\n\t\t$this->response->body($template->render());\n\t}", "title": "" }, { "docid": "b41517724d4cdbc80c63a80b966a7b01", "score": "0.68746614", "text": "public function listAction() {\n\n\t\t}", "title": "" }, { "docid": "e908ab42fc450a9a0594cc9564f4eeb9", "score": "0.68608236", "text": "public function listAction() {\n $this->model->updateStatus();\n Zend_View_Helper_PaginationControl::setDefaultViewPartial('pagecontrol.phtml');\n\n $where = '1 = 1';\n\n $filter = $this->_request->getParam('search');\n $this->view->filter = $filter;\n\n if ($filter == 'active') {\n $where = 'status = 0';\n } else if ($filter == 'disabled') {\n $where = 'status = 2';\n } else if ($filter == 'expired') {\n $where = 'status = 1';\n }\n\n $sort = $this->_request->getParam('sort');\n if (!$sort) {\n $sort = 'description';\n }\n\n if (!isset($this->session_sorting->sort)) {\n $this->session_sorting->sort = 0;\n }\n\n if ($this->session_sorting->sort == 0) {\n $this->session_sorting->sort = 1;\n $data = $this->table->fetchAll($this->table->select()->where($where)->order($sort . ' desc'));\n } else {\n $this->session_sorting->sort = 0;\n $data = $this->table->fetchAll($this->table->select()->where($where)->order($sort . ' asc'));\n }\n\n $paginator = Zend_Paginator::factory($data);\n $paginator->setCurrentPageNumber($this->_getParam('page', 1));\n $paginator->setItemCountPerPage(10);\n\n $this->view->page = $this->_getParam('page');\n $this->view->discounts = $paginator;\n }", "title": "" }, { "docid": "8ef49cf3a3eb21ff0a74662ea3579be6", "score": "0.68547213", "text": "public function index()\n {\n // Get cards\n $cards = Card::orderBy('created_at', 'desc')->paginate(10);\n\n // Return collection of cards as a resource\n return CardResource::collection($cards);\n }", "title": "" }, { "docid": "6e9ab9b623d3bae20d9be7b36335891d", "score": "0.68502206", "text": "public function listAction()\n {\n $this->forward('index');\n }", "title": "" }, { "docid": "d6111f19a7aca7d26ffbe0986ebf3edd", "score": "0.68407434", "text": "public function indexAction()\n {\n $this->listAction();\n }", "title": "" }, { "docid": "88277ff9376f997f91e6b5491575d7bb", "score": "0.6833471", "text": "public function index()\n {\n return ShoppingListResource::collection(ShoppingList::paginate(15));\n }", "title": "" }, { "docid": "546b231c03944da42a8e98b848f51fa9", "score": "0.68256605", "text": "public function list()\n {\n $shelves = Bookshelf::visible();\n\n return $this->apiListingResponse($shelves, [\n 'id', 'name', 'slug', 'description', 'created_at', 'updated_at', 'created_by', 'updated_by', 'owned_by',\n ]);\n }", "title": "" }, { "docid": "755da2e01052312a756038c9d166d9cb", "score": "0.6794544", "text": "public function listAction() {\n $this->view->headTitle($this->view->translate('List of templates'), 'PREPEND');\n $templateModel = new Unisender_Model_UnisenderTemplate();\n $this->view->template_list = $templateModel->getAll();\n }", "title": "" }, { "docid": "d05cc4d736f09bef3c6bdf24844ac8c6", "score": "0.67895305", "text": "public function index()\n\t{\n\t\t$artists = Artist::paginate(100);\n\n\t\treturn $this->respond([\n\t\t\t'data' => $this->artistTransformer->transformCollection($artists->all())\n\t\t]);\n\t}", "title": "" }, { "docid": "89d40e37a12f5ea687a94247a2fdb4da", "score": "0.6786343", "text": "public function actionIndex()\n {\n $this->layout = '@backend/views/layouts/list';\n return $this->render('index', [\n 'dataProvider' => $this->getDataProvider(),\n 'model' => $this->getModelSearch(),\n 'currentView' => $this->getCurrentView(),\n 'availableViews' => $this->getAvailableViews()\n ]);\n }", "title": "" }, { "docid": "1647b90a06fcd39c33c32b33bf9fa133", "score": "0.67860115", "text": "public function index()\n {\n return view('list_wrapper', [\n 'entityType' => 'itemscanner',\n 'datatable' => new ItemScannerDatatable(),\n 'title' => mtrans('itemscanner', 'itemscanner_list'),\n ]);\n }", "title": "" }, { "docid": "487c93a93f48c83d96a649e03fdb104d", "score": "0.6774347", "text": "public function index()\n {\n //\n return DishResource::collection(Dish::orderBy('id', 'asc')->paginate());\n }", "title": "" }, { "docid": "6265f2e35f1c819b84733e2d894fc9f3", "score": "0.6763496", "text": "public function __list()\r\n {\r\n $current = SamsonLocale::current();\r\n\r\n $default = 'ru';\r\n\r\n if (defined('DEFAULT_LOCALE')){\r\n $default = DEFAULT_LOCALE;\r\n }\r\n\r\n // Render all available locales\r\n $html = '';\r\n foreach (SamsonLocale::get() as $locale) {\r\n if ($current != $default) {\r\n $urlText = substr(url()->text,strlen($current)+1);\r\n } else {\r\n $urlText = url()->text;\r\n }\r\n if ($locale == $default) {\r\n $url = 'http://'.$_SERVER['HTTP_HOST'].__SAMSON_BASE__.$urlText;\r\n } else {\r\n $url = 'http://'.$_SERVER['HTTP_HOST'].__SAMSON_BASE__.$locale.'/'.$urlText;\r\n }\r\n\t $localeName = '';\r\n\t if ($this->isLocaleLinkText) {\r\n\t\t $localeName = $this->translate($locale, $current);\r\n\t }\r\n $html .= $this->view('list/item')\r\n ->css(self::CSS_PREFIX)\r\n ->locale($locale == SamsonLocale::DEF && SamsonLocale::DEF == ''? 'def' : $locale)\r\n ->active($locale == $current ? self::CSS_PREFIX.'active':'')\r\n ->url($url)\r\n\t ->name($localeName)\r\n ->output();\r\n }\r\n\r\n // Set locale list view\r\n $this->view('list/index')->locale($current)->css(self::CSS_PREFIX)->items($html);\r\n }", "title": "" }, { "docid": "9574508ae15a68d9552788d66f6069d4", "score": "0.67439693", "text": "public function all()\n\t{\n\t\t$recipes = Recipe::findRecipe(array('recipe_images.is_cover'=>'yes'));\t\n\t\t\n\t\t$this->template->recipes = $recipes;\n\t\t$this->template->display('list.html.php');\n\t}", "title": "" }, { "docid": "e1224469d7f8380d5b96958c49bfc327", "score": "0.67368996", "text": "public function index()\n {\n $offers = Offer::filter()->paginate();\n\n return OfferResource::collection($offers);\n }", "title": "" }, { "docid": "e89b2c9176e1e2ba1660cebc077dc45d", "score": "0.6728091", "text": "public function index()\n {\n $user = $this->userContract->findWith(request()->user()->id, ['profile']);\n $resources = $this->resourceContract->getResourcesOrdered();\n $trashed = $this->resourceContract->getTrashedResourcesOrdered();\n\n return view('backend.resources.index', compact('user', 'resources', 'trashed'));\n }", "title": "" }, { "docid": "2422a439354b2d9d0c8e13222d75b791", "score": "0.67135084", "text": "public function indexAction()\r\n {\r\n \t$this->openApi->getItems();\r\n $this->view->data = $this->openApi->getDataResponse();\r\n }", "title": "" }, { "docid": "f38c30f9e765863f55cf5c7e5b441e0a", "score": "0.6695974", "text": "public function listAction()\n {\n $this->_title($this->__('System'))->_title($this->__('Index Management'));\n\n $this->loadLayout();\n $this->_setActiveMenu('system/index');\n $this->renderLayout();\n }", "title": "" }, { "docid": "c28bf83f5ff7f88cca0b895b2e8d3ae8", "score": "0.669245", "text": "public function listAction() {\n\t\t$this->view->title = $this->translator->translate(\"Reviews list\");\n\t\t$this->view->description = $this->translator->translate(\"Here you can see all the reviews.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"/admin/reviews/new/\", \"label\" => $this->translator->translate('New'), \"params\" => array('css' => null)));\r\n\t\t$this->datagrid->setConfig ( Reviews::grid() )->datagrid ();\n\t}", "title": "" }, { "docid": "a90256f37c65707c557ad75ce4efde1a", "score": "0.66915387", "text": "public function index()\n {\n return $this->service->getList();\n }", "title": "" }, { "docid": "4cc7c30861d929f90a57a50b59a5a1f5", "score": "0.66879165", "text": "public function listAction(){\n\t\t//Passes values from the Todo Mysql table into the $todos value\n\t\t$todos = $this->getDoctrine()\n\t\t\t\t\t ->getRepository('AppBundle:Todo')\n\t\t\t\t\t ->findAll();\n\t\t//Loading the todo view in here...\n return $this->render('todo/index.html.twig', array(\n\t\t\t'todos' => $todos\n\t\t));\n }", "title": "" }, { "docid": "1a9cb6255c77fe1bff8fb9d77615f930", "score": "0.66870624", "text": "public function list(): Response\n {\n return $this->renderList(\n [],\n ['artist' => 'ASC', 'title' => 'ASC']\n );\n }", "title": "" }, { "docid": "a8ee22092f12cd9a55fa2d36291251f4", "score": "0.6683523", "text": "public function action_list() {\n if (Input::method() != 'GET') { $this->response($this->no_access); return; }\n\n $params = Input::get();\n $user = $this->user_login->user;\n\n try {\n $resp = $this->listStuff($params, $user);\n } catch (Exception $exc) {\n return $this->_error_response($exc->getMessage());\n }\n \n // Set the output\n $data = array('data' => array('offers' => $resp[\"all_offers\"]), 'meta' => $resp[\"meta\"]);\n $this->response($data);\n\t}", "title": "" }, { "docid": "5a18d2c52cb259d958c945d4d6a9ea33", "score": "0.6676733", "text": "public function listAction()\n {\n $task = new Task($this->config);\n $tasks = $task->getAll();\n $amountOfTasks = $task->getAmountTasks();\n \n // load views.\n $this->view('task/list', [\n 'tasks' => $tasks,\n 'amountOfTasks' => $amountOfTasks\n ]);\n }", "title": "" }, { "docid": "fb257c74bec9eb0cfbe648823975e645", "score": "0.6653098", "text": "public function index()\n {\n $requests = ModelsRequests::paginate();\n\n return ResourcesRequests::collection($requests);\n }", "title": "" }, { "docid": "f186543d4e229fe60c320d197652a0ac", "score": "0.6648046", "text": "public function index()\n {\n return BookResource::collection(Book::paginate());\n }", "title": "" }, { "docid": "097ff24f05f0eef21fe921e55bd3b80d", "score": "0.66470236", "text": "public function listAction()\n {\n try {\n $cd = $this->currentFolder();\n return new ViewModel(array(\n 'currentFolder' => $cd,\n 'seperator' => $this->seperator,\n 'entries' => $this->directoryContent($this->getEntity(), $cd)\n ));\n } catch (\\Exception $e) {\n echo Json::encode(array(\n 'error' => $e->getCode()\n ));\n exit();\n }\n }", "title": "" }, { "docid": "59475f9f5ef859f09d1ee48e7e27d0ea", "score": "0.66406596", "text": "public function index()\n {\n return $this->showAll(SpeciesResource::collection(Species::get()));\n }", "title": "" }, { "docid": "3e9e7ace6967f2049a9e3a5287aa7bc1", "score": "0.6639121", "text": "public function index()\n {\n if ($ref = \\Request::get('getRef')) {\n return $this->getRef($ref);\n }\n\n $per_page = \\Request::get('perPage');\n $data = $this->repository->paginate($per_page);\n\n return $this->sendSuccess($data, __('api.success_list', ['name' => $this->name]));\n }", "title": "" }, { "docid": "aa0d5690d16cbfb9dc97e701071da2f2", "score": "0.6637484", "text": "public function listAction() {\n $imageService = $this->container->get(\"dft_foapi.image\");\n return $this->render('dftFoapiBundle:Common:data.json.twig', array(\n \"data\" => $imageService->fetchAll(\n $this->getAuthenticatedUserIdAndSubAccountIds()\n )\n )\n );\n }", "title": "" }, { "docid": "479fb582c4dbcbc65e4bb28c2bb3a697", "score": "0.66345435", "text": "public function list()\n {\n // and this sorting and paging logics must be in separate components\n // but for our case ... ))\n $sortTypes = ['author', 'email', 'done', 'author DESC', 'email DESC', 'done DESC'];\n $sort = input('sort', null);\n if ($sort && in_array($sort, $sortTypes)) {\n $sortSql = \" ORDER BY {$sort} \";\n } else {\n $sortSql = '';\n }\n $offset = (int) input('offset', 0);\n $offsetSql = \" LIMIT {$offset}, \" . static::PER_PAGE;\n $sql = '1 ' . $sortSql . $offsetSql;\n $todos = R::findAll('todo', $sql);\n $total = R::count('todo');\n\n //paging\n $next = false;\n $prev = false;\n\n if ($total > $offset + static::PER_PAGE) {\n $next = $offset + static::PER_PAGE;\n }\n\n if ($offset !== 0) {\n $prev = $offset - static::PER_PAGE;\n }\n\n //sorting\n $sortings = [];\n foreach (['author', 'email', 'done'] as $sortAttribute) {\n if (strpos($sort, $sortAttribute) !== false && $sort === $sortAttribute) {\n $sortings[$sortAttribute] = \"{$sortAttribute} DESC\";\n } else {\n $sortings[$sortAttribute] = $sortAttribute;\n }\n }\n\n return $this->render('list', compact('todos', 'next', 'prev', 'sortings', 'total'));\n }", "title": "" }, { "docid": "317c606a7e54f34736590f60393be790", "score": "0.662934", "text": "function index()\n\t{\n\t\t$this->items();\n\t}", "title": "" }, { "docid": "0ef8e5b1a7ba68c743bcff23cd0cf130", "score": "0.6628069", "text": "public function index()\n {\n return Resource::all();\n }", "title": "" }, { "docid": "fda26526263c4f32a26eb1c3721263e4", "score": "0.6623293", "text": "public function index()\n {\n $listings = $this->listing->latest()->paginate(50);\n\n return view('admin.listings.index', compact('listings'));\n }", "title": "" }, { "docid": "7c0e8a5f42c42d1c4f18968bb494ad0e", "score": "0.6621373", "text": "public function paginatedListAction() {\n return $this->getList();\n }", "title": "" }, { "docid": "0e1a46d9ea752b3e205c54aab701c4fd", "score": "0.6619698", "text": "public function listings() {\r\n $data = $this->model->getData();\r\n $this->template->data = $data;\r\n $this->set('general/list');\r\n }", "title": "" }, { "docid": "3e2ce9e0dce5419c500b0a60774b7605", "score": "0.6616485", "text": "public function index()\n {\n return $this->service->lists();\n }", "title": "" }, { "docid": "bca6e37ce935bd0d2b77093989d408cd", "score": "0.6612557", "text": "public function actionIndex()\n {\n $searchModel = new ListingSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "title": "" }, { "docid": "67562fbc2bb858bc588d4a91237cb673", "score": "0.6603778", "text": "function index() {\r\n\t\t// Getting the whole list\r\n\t\t$itemList = $this->model->find('all');\r\n\r\n\t\t$this->set('itemList', $itemList);\r\n\t}", "title": "" }, { "docid": "8ec8da14e071283716d59393a382ab24", "score": "0.65982807", "text": "public function listAction()\n {\n\t\t$identity = Zend_Auth::getInstance()->getIdentity();\n\t\n\t\t// if identity and user aren't the same identity, add an entry to the identityBoard (menu )\n\t\tif( $identity->id != $this->_user->id ){\n\t\t\tApplication_Model_Ui_Boards_IdentityBoard::getInstance()->addEntry(\n\t\t\t\tAnta_Core::getBase().\"/documents/\".$this->_user->cryptoId,\n\t\t\t\tI18n_Json::get( 'userDocumentList' ).' @ '.$this->_user->username , array( \n\t\t\t\t\t'class' => 'admin entry-selected'\n\t\t\t));\n\t\t\tApplication_Model_Ui_Boards_IdentityBoard::getInstance()->addEntry(\n\t\t\t\tAnta_Core::getBase().\"/gexf/entities/user/\".$this->_user->cryptoId,\n\t\t\t\tI18n_Json::get( 'gexf' ).' @ '.$this->_user->username , array( \n\t\t\t\t\t'class' => 'admin'\n\t\t\t));\n\n\t\t}\n\t\t$this->view->dock = new Application_Model_Ui_Docks_Dock();\n\t\t\n\t\t$this->view->dock->addCraft( new Application_Model_Ui_Crafts_Cargo( 'documents', I18n_Json::get( 'documentsList' ).\": \".$this->_user->username ) );\n\t\t\n\t\t$totalDocuments = Application_Model_DocumentsMapper::getNumberOfDocuments( $this->_user ); \n\t\t\n\t\t// no documents? send directly to upload, with a link, and stop this script\n\t\tif( $totalDocuments == 0 ){\n\t\t\t\n\t\t\t// draw nice upload link \"start uploading file!\" and welcome message as well\n\t\t\t$this->view->dock->documents->setHeader( new Ui_Crafts_Headers_Welcome( $this->_user ) );\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t// remove menu items\n\t\t\tUi_Board::getInstance( \"Documents\", array( 'user' => $this->_user ) )->removeItem(\n\t\t\t\t\"documents.import-tags\", \n\t\t\t\t\"documents.export-tags\",\n\t\t\t\t\"api.reset\"\n\t\t\t);\n\t\t\t\n\t\t\treturn $this->render( 'index');\n\t\t}\n\t\t\n\t\t// start listening to request filter, or default vars here\n\t\t// values and their validators\n\t\tDnst_Filter::start( array(\n\t\t\t\t\"offset\" => 0,\n\t\t\t\t\"limit\" => 100,\n\t\t\t\t\"order\" => array( \"mimetype DESC\" ),\n\t\t\t\t\"tags\"\t => array(),\n\t\t\t\t\"query\" => \"\",\n\t\t\t\t\"date_start\"=>\"\",\n\t\t\t\t\"date_end\" =>\"\"\n\t\t\t), array (\n\t\t\t\t\"order\" => new Dnst_Filter_Validator_Array( array(\n\t\t\t\t\t\"id_document DESC\", \"id_document ASC\",\n\t\t\t\t\t\"title ASC\", \"title DESC\", \"date ASC\", \"date DESC\",\"`ignore` DESC\", \"`ignore` ASC\",\n\t\t\t\t\t\"status ASC\", \"status DESC\",\n\t\t\t\t\t\"language ASC\", \"language DESC\", \"mimetype ASC\", \"mimetype DESC\",\n\t\t\t\t)),\n\t\t\t\t\"offset\" => new Dnst_Filter_Validator_Range( 0, 10000000 ),\n\t\t\t\t\"limit\" => new Dnst_Filter_Validator_Range( 1, 500 ),\n\t\t\t\t\"query\" => new Dnst_Filter_Validator_Pattern( 0, 100 )\n\t\t\t)\n\t\t);\n\t\t\n\t\tif( !Dnst_Filter::isValid() ){\n\t\t\t// if you set the filters properly, then these variables MUST be in place\n\t\t\tAnta_Core::setError(\"uhm..not valid string..\".Dnst_Filter::getErrors() );\n\t\t\treturn $this->render( 'index' );\n\t\t}\n\t\t// print_r( Dnst_Filter::read() );\n\t\t// get all the documents\n\t\t$documents = Application_Model_DocumentsMapper::select(\n\t\t\t$this->_user,\n\t\t\tDnst_Filter::read()\n\t\t);\n\t\t// send some variables to the view\n\t\t$this->view->totalItems = $documents->totalItems;\n\t\t$this->view->loadedItems = count( $documents->results );\n\t\t\n\t\t// query to group documents by month according to number of groups\n\t\t$stmt = Anta_Core::mysqli()->query(\"\n\t\t\tSELECT COUNT(*) as countable, DATE_FORMAT(date,'%d.%m.%Y') as simple_date FROM anta_{$this->_user->username}.`documents` GROUP BY (`simple_date`)\"\n\t\t);\n\t\t$timestamps = array();\n\t\twhile ( $row = $stmt->fetchObject() ){\n\t\t\t$timestamps[] =\tnew Ui_D3_Timeline_Point( \n\t\t\t\t$row->simple_date, \n\t\t\t\tarray( \n\t\t\t\t\t\"y\" => $row->countable,\n\t\t\t\t\t\"title\" => $row->simple_date .\" (\".$row->countable.\")\",\n\t\t\t\t\t\"href\" => $_SERVER['REFERRER_URI'].'?'.Dnst_Filter::setProperty( 'date_start', $row->simple_date )\n\t\t\t\t) \n\t\t\t);\t\n\t\t}\n\t\t\n\t\t// prepare headers\n\t\t$header = new Anta_Ui_Header_Documents();\n\t\t$header->user = $this->_user;\n\t\t$header->loadedItems = count( $documents->results );\n\t\t$header->totalItems = $documents->totalItems;\n\t\t$header->offset = Dnst_Filter::getProperty( \"offset\" );\n\t\t$header->limit = Dnst_Filter::getProperty( \"limit\" );\n\t\t$header->searchQuery = Dnst_Filter::getProperty( \"query\" );\n\t\t$header->setTimeline( new Ui_D3_Timeline( \n\t\t\t$timestamps, \"dd.mm.yy\", \n\t\t\tarray( \"width\"=>832, \"height\"=>40)\n\t\t));\n\t\t\n\t\t$this->view->dock->documents->setHeader( \n\t\t\t$header\n\t\t);\n\t\t\n\t\t\n\t\t\n\t\tforeach (array_keys( $documents->results ) as $k ){\n\t\t\t$this->view->dock->documents->addItem( new Anta_Ui_Item_Document( $documents->results[ $k ] ) );\n\t\t}\n\t\t\n\t\t$this->render( 'index' );\n\t\t\n }", "title": "" }, { "docid": "51ab41ffa64c6b6b7fbb813516203da1", "score": "0.6593938", "text": "public function index()\n {\n return PharmacyResource::collection($this->pharmacyRepoInstance->paginate(self::PER_PAGE, ['id', 'name', 'address']));\n }", "title": "" }, { "docid": "be3ed76ca60da4c3caa2d8528ae5c319", "score": "0.659177", "text": "public function actionIndex()\n {\n if(Yii::$app->user->can('admin')){\n $dataProvider = new ActiveDataProvider([\n 'query' => Resource::find()->where(['size'=>0]),\n ]);\n return $this->render('index', [\n 'dataProvider' => $dataProvider,\n ]);\n }\n else{\n $dataProvider = new ActiveDataProvider([\n 'query' => Resource::find(),\n ]);\n return $this->render('list', [\n 'dataProvider' => $dataProvider,\n ]);\n }\n\n\n }", "title": "" }, { "docid": "ccecdc5f92158721af216deee02beaf2", "score": "0.65850216", "text": "public function action_index() \n\t{\n\t\t$this->rest_output(array(\n\t\t\t'GET example!', \n\t\t));\n\t}", "title": "" }, { "docid": "c971fcbed7a0406b3764b8ecdb481920", "score": "0.6572927", "text": "protected function listAction()\r\n {\r\n $contentUid = $this->configurationManager->getContentObject()->data['uid'];\r\n $configuration = $this->configurationManager->getConfiguration(ConfigurationManagerInterface::CONFIGURATION_TYPE_FRAMEWORK);\r\n if (!isset($configuration['view']['pluginNamespace'])) {\r\n $configuration['view']['pluginNamespace'] = 'tx_ameosfilemanager_fe_filemanager';\r\n }\r\n\r\n $this->settings['columnsTable'] = explode(',', $this->settings['columnsTable']);\r\n $this->settings['actionDetail'] = explode(',', $this->settings['actionDetail']);\r\n $this->view->assign('settings', $this->settings);\r\n\r\n $args = $this->request->getArguments();\r\n $t = $this->fileRepository->findBySearchCriterias($args, $this->settings['startFolder'], $configuration['view']['pluginNamespace'], $this->settings['recursion']);\r\n $this->view->assign('files', $t);\r\n $this->view->assign('value', $args); \r\n $this->view->assign('content_uid', $contentUid);\r\n\r\n if (isset($_SERVER['HTTP_X_REQUESTED_WITH']) && $_SERVER['HTTP_X_REQUESTED_WITH'] == 'XMLHttpRequest'\r\n && $contentUid == GeneralUtility::_POST('ameos_filemanager_content')) {\r\n header('Content-Type: text/json; charset=utf8;');\r\n echo json_encode(['html' => $this->view->render()]);\r\n die();\r\n }\r\n }", "title": "" }, { "docid": "ef4fec830260d9dfb3f1e7e325eac9e0", "score": "0.6572855", "text": "public function actionList()\n {\n $products = new ActiveDataProvider([\n 'query' => Product::find(),\n 'pagination' => [\n 'pageSize' => 10\n ]\n ]);\n return $this->render('list', ['products' => $products]);\n }", "title": "" }, { "docid": "9500e1733deedb51878d2d909f31751a", "score": "0.65667915", "text": "public function actionList()\r\n {\r\n $objectClassId = $this->_input->filterSingle('object_class_id', XenForo_Input::STRING);\r\n $class = $this->_getClassOrError($objectClassId);\r\n\r\n $objectModel = $this->_getObjectModel();\r\n\r\n $objects = $objectModel->getObjects(array(\r\n 'object_class_id' => $objectClassId\r\n ));\r\n\r\n $viewParams = array(\r\n 'class' => $class,\r\n 'objects' => $objects\r\n );\r\n\r\n return $this->responseView('ThemeHouse_Objects_ViewAdmin_Object_List', 'object_list', $viewParams);\r\n }", "title": "" }, { "docid": "6b6ca26ff623891fbb04a6646a0e894c", "score": "0.6566177", "text": "public function index(Request $request)\n {\n $this->checkRole();\n\n //\tGet all records of the model and set default ordering\n $builder = $this->model('orderBy', $request->orderby ?: ((property_exists($this, 'list_order_by')) ? $this->list_order_by : 'name'), $request->order ?: ((property_exists($this, 'list_order')) ? $this->list_order : 'desc'));\n\n //\tRetrieve the fields which will be used in records table\n $fields = new RenderList($this->getFieldsForList());\n\n // Handle list search\n if ($request->has('s')) {\n $builder->where($this->list_search_on, 'LIKE', '%' . $request->s . '%');\n }\n\n // Handle list filtering\n if ($request->has('filter') && $request->has('set')) {\n $builder->where($request->filter, $request->set);\n }\n\n // Move $builder to $records with default paging of 40 p/p\n $records = $builder->paginate(40);\n\n //\tLoad the view\n return view('crud::templates.index', $this->parseViewData(compact('records', 'fields')));\n }", "title": "" }, { "docid": "22313e01879ad9cf6aefe5b6cf7eaac2", "score": "0.65648544", "text": "public function listeAction()\n {\n // des éléments de contrôle de la pagination pour plus d'informations\n Zend_View_Helper_PaginationControl::setDefaultViewPartial('controls.phtml');\n\n $mapper = new Application_Model_FilmMapper();\n $film = new Application_Model_Film();\n $film = $mapper->obtenirAllFilms();\n\n // Créons un paginateur pour cette requête\n $paginator = Zend_Paginator::factory($film);\n\n // Nous lisons le numéro de page depuis la requête. Si le paramètre n'est pas précisé\n // la valeur 1 sera utilisée par défaut\n $paginator->setCurrentPageNumber($this->_getParam('page', 1));\n\n // Assignons enfin l'objet Paginator à notre vue\n $this->view->paginator = $paginator;\n }", "title": "" }, { "docid": "ea842597a9d8fad1df58d74c6b12ab97", "score": "0.6560148", "text": "public function index()\n {\n $statuses = Status::all();\n $statuses->transformer = StatusCollection::class;\n return $this->showAll($statuses);\n }", "title": "" }, { "docid": "9854a8a0b5996147689b1cfb93901fba", "score": "0.65570813", "text": "public function index()\n {\n $entities = Entity::all();\n\n return view('actions.entity.read', compact('entities'));\n }", "title": "" }, { "docid": "6eadfe639301106d65142408b4536a7d", "score": "0.65397066", "text": "public function index()\n {\n return CentroResource::collection(Centro::paginate());\n }", "title": "" }, { "docid": "b1c6918b8a647032258b39902afb3198", "score": "0.6532946", "text": "public function index()\n {\n $this->initialiseRequest();\n $items = $this->queryRepository->all();\n if (!$items) {\n return $this->apiManager->respondNotFound('Items do not exist.');\n }\n $itemsResource = new Collection($items, $this->transformer);\n $processedItems = $this->fractalManager->createData($itemsResource)->toArray();\n return $this->apiManager->respond($processedItems);\n }", "title": "" }, { "docid": "47bc2129e22deb7b10f9cd1b3ca97140", "score": "0.65329", "text": "public function index()\n {\n\n if ($this->model->count() <> 0) {\n return $this->resource::collection($this->model);\n }\n return Response::json([\n 'error' => 'Record not found'\n ], 404);\n\n }", "title": "" }, { "docid": "b09ff22d2468ad0a34a73b6be1c564e7", "score": "0.6529856", "text": "public function index()\n {\n $questions = Question::pimp()->paginate();\n\n QuestionResource::collection($questions);\n\n return $this->sendResponse(compact('questions'));\n }", "title": "" }, { "docid": "289c02bb55888cea68db6bb293329f8b", "score": "0.65295684", "text": "public function listAction()\n {\n if (false === $this->admin->isGranted('LIST')) {\n throw new AccessDeniedException();\n }\n\n /** @var \\Symfony\\Component\\HttpFoundation\\Request $request */\n $request = $this->container->get('request_stack')->getCurrentRequest();\n\n /** @var \\Sonata\\MediaBundle\\Provider\\Pool $mediaPool */\n $mediaPool = $this->container->get('sonata.media.pool');\n\n $contexts = $mediaPool->getContexts();\n\n reset($contexts);\n $contextName = key($contexts);\n $datagrid = $this->admin->getDatagrid($request->get('context', $contextName));\n $datagrid->setValue('context', null, $this->admin->getPersistentParameter('context'));\n\n $formView = $datagrid->getForm()->createView();\n\n // set the theme for the current Admin Form\n $this->get('twig')->getExtension('form')->renderer->setTheme($formView, $this->admin->getFilterTheme());\n\n return $this->render(\n $this->admin->getTemplate('list'),\n array(\n 'action' => 'list',\n 'form' => $formView,\n 'datagrid' => $datagrid,\n 'csrf_token' => $this->getCsrfToken('sonata.batch'),\n )\n );\n }", "title": "" }, { "docid": "9541d55e53804985d6027f052d293580", "score": "0.652877", "text": "public function index()\n {\n return $this->render('index', [\n 'model' => $this->model,\n 'endpoints' => $this->getAvailableApiEndpoints(),\n 'groupsCount' => $this->model->getGroups()->count(),\n ]);\n }", "title": "" }, { "docid": "9541d55e53804985d6027f052d293580", "score": "0.652877", "text": "public function index()\n {\n return $this->render('index', [\n 'model' => $this->model,\n 'endpoints' => $this->getAvailableApiEndpoints(),\n 'groupsCount' => $this->model->getGroups()->count(),\n ]);\n }", "title": "" }, { "docid": "cc3607ce8a88164b64b1133094816f12", "score": "0.6522748", "text": "public function index()\n {\n $this->crud->hasAccessOrFail('list');\n\n $this->data['crud'] = $this->crud;\n $this->data['title'] = ucfirst(($this->chapter ? $this->chapter->name . ' --> ' : '') . $this->crud->entity_name_plural);\n\n // load the view from /resources/views/vendor/backpack/crud/ if it exists, otherwise load the one in the package\n return view($this->crud->getListView(), $this->data);\n }", "title": "" }, { "docid": "cdc6c11bca5c8d643c1f6a1a0d80d23d", "score": "0.65212315", "text": "public function indexAction()\r\n {\r\n $this->parseRequestForPager();\r\n\r\n $pager = $this->getPager();\r\n $form = $this->getFilterForm()->createView();\r\n\r\n $result = array(\r\n 'list' => $this->getList($pager),\r\n 'pager' => $this->getPagination($pager),\r\n 'filters' => $this->get('pizone_form')->formDataToArray($form)\r\n );\r\n\r\n $view = new View($result);\r\n return $this->handleView($view);\r\n }", "title": "" }, { "docid": "d06d606c40c9d56f52b80f958f43b5ce", "score": "0.65188295", "text": "public function index()\n\t{\n\t\t// will show list of Data\n\t}", "title": "" }, { "docid": "3f1eb8293a667a2878f4d80d96280084", "score": "0.6518673", "text": "public function index()\n {\n return BookResource::collection(Book::paginate(25));\n }", "title": "" }, { "docid": "d44d85e06d4eeb7940282586d59ecb10", "score": "0.65124106", "text": "public function index()\n {\n return UnitResource::collection(Unit::paginate(5));\n }", "title": "" }, { "docid": "81a94e8c32b6134de5e7342f4235e4ec", "score": "0.6507357", "text": "public function index()\n {\n\n // Get articles\n $chairs = Chair::paginate(15);\n\n // Return collection of articles as a resource\n return ChairResource::collection($chairs);\n\n }", "title": "" }, { "docid": "22fb95b3636c2f407abebe88d13d8888", "score": "0.6505021", "text": "public function index()\n {\n $authors = Author::all();\n return AuthorResource::collection($authors);\n }", "title": "" }, { "docid": "1071b7d841a42ebb958087fb23ea72c9", "score": "0.64993095", "text": "public function index()\n {\n //return $this->repository->all();\n return $this->service->showAll();\n }", "title": "" }, { "docid": "cad2135c8b884f5e32721aec5b9bea32", "score": "0.6497837", "text": "public function index()\n {\n return CategoryResource::collection(Category::paginate());\n }", "title": "" }, { "docid": "1a823c7469d426833399140a05c28243", "score": "0.64936584", "text": "public function listAction()\n\t{\n\t\t$asResponse = array();\n\t\t$client = new Zend_Http_Client($this->ssUri.'/list');\n\t\t$client->setParameterGet(array('bIsRest' => true));\n\t\t$client->setConfig(array('timeout' => 30));\n\t\t$ssResponse = $client->request('GET');\n\t\t\n\t\tif($ssResponse->isSuccessful())\n\t\t{\n\t\t\t$ssResponseBody = $ssResponse->getBody();\n\t\t\t$asResponse = Zend_Json_Decoder::decode($ssResponseBody,Zend_Json::TYPE_ARRAY);\n\t\t}\n\t\t$this->view->users = $asResponse;\n\t}", "title": "" }, { "docid": "516498e2faf9e3833f4a0c0889c0d1a6", "score": "0.64926285", "text": "public function index()\n {\n $this->authorize('index', Category::class);\n\n return CategoryResource::collection(Category::paginate(15));\n }", "title": "" }, { "docid": "baeb75c01b41d5a02e946acdd0870ae9", "score": "0.6491589", "text": "public function showBooksAction()\n {\n $result = $this->model->getBooks();\n // Get params of books and pagination\n $data = $result[0];\n $pagination_params = $result[1];\n\n $this->view->render('List of books', $data, $pagination_params);\n }", "title": "" }, { "docid": "7029a5ba2d86ddb638223bf9a830e61a", "score": "0.648616", "text": "public function actionIndex()\r\n {\r\n $dataProvider = $this->getIndex('api/books', 'app\\models\\Book');\r\n\r\n return $this->render('index', [\r\n 'dataProvider' => $dataProvider\r\n ]);\r\n }", "title": "" }, { "docid": "ad2789681d764a50f799c66b64e9e3f5", "score": "0.64843917", "text": "public function index()\n {\n $data = GuestResource::collection(\n $this->guest->paginate(request()->per_page)\n );\n\n if (! $data) {\n return response()->json([\n 'message' => 'Failed to retrieve resource'\n ], 400);\n }\n\n return $data;\n }", "title": "" }, { "docid": "64c5cb71d29bff854bd1d4c026363eb2", "score": "0.6484192", "text": "public function index()\n {\n $cust = Customers::paginate(20);\n return CustomersResource::collection($cust);\n }", "title": "" }, { "docid": "fc608464ab00efa2883cbaa1ca108cd1", "score": "0.6481522", "text": "public function index()\n {\n return $this->collection($this->repository->all());\n }", "title": "" }, { "docid": "c22119f1d6e05e764e700b1cf1e15c3a", "score": "0.648076", "text": "public function index()\n {\n // Get articles\n $trackings = Tracking::paginate(10);\n\n // Return\n return BackendResource::collection($trackings);\n }", "title": "" }, { "docid": "90f607a4b7e80fdd2bcd6f3ce3d9959e", "score": "0.6477766", "text": "public function index()\n {\n $perPage = request('perPage', 10);\n $products = Product::paginate($perPage);\n return ProductResource::collection($products);\n }", "title": "" }, { "docid": "59002099eafa8643a05ba19fcbd9fedd", "score": "0.6477562", "text": "public function index()\n {\n //\n $items = Item::orderBy('id')->paginate(10);\n \n return view('manage.item.items_list', compact('items'));\n \n }", "title": "" }, { "docid": "c8bce961d8c00f94db1cc45bb581d8eb", "score": "0.6476608", "text": "public function index()\n {\n $products = Product::all();\n return ProductResource::collection($products);\n }", "title": "" }, { "docid": "c1799a28a7e3f24be756df7e3d5ed18d", "score": "0.6474707", "text": "public function index()\n {\n $people = QueryBuilder::for(Person::class)\n ->defaultSort('created_at')\n ->allowedSorts([\n 'created_at'\n ])\n ->paginate(10)\n ->appends(request()->query());\n\n return PersonResource::collection($people);\n }", "title": "" }, { "docid": "974e723cf42c91c850116aa22b80f587", "score": "0.6472995", "text": "public function index()\n {\n //\n $parent_details = \\App\\ParentDetail::orderBy('id', 'desc')->paginate(10);\n return ParentDetailResource::collection($parent_details);\n }", "title": "" }, { "docid": "b6d79dbbd4bd8f24a2ee993dec416fde", "score": "0.64697886", "text": "public function index() {\n\t\t\t$datas=DAO::getAll($this->model);\n\t\t\techo $this->_getResponseFormatter()->get($datas);\n\t}", "title": "" }, { "docid": "85336711eddcf6c317cce3da86408817", "score": "0.6469765", "text": "public function actionList()\n {\n $users = User::find()\n ->orderBy('id')\n ->all();\n if (count($users)) {\n $separator = sprintf(self::LIST_FORMAT_SEP.PHP_EOL, str_repeat('-', 10), str_repeat('-', 22), str_repeat('-', 9), str_repeat('-', 32), str_repeat('-', 42));\n echo $separator;\n printf(self::LIST_FORMAT_HEADER.PHP_EOL, 'id', 'username', 'status', 'fullname', 'email');\n echo $separator;\n foreach ($users as $user) {\n printf(self::LIST_FORMAT_LINE.PHP_EOL, $user->id, $user->username, $this->statusMap[$user->status], $user->fullname, $user->email);\n }\n echo $separator;\n }\n return Controller::EXIT_CODE_NORMAL;\n }", "title": "" }, { "docid": "f9d8426baa3f2a5993b5c1f018099562", "score": "0.64684117", "text": "public function resources_index()\n\t{\n\t\t$init = new admin_model();\n\t\t$resources = $init->getAllResources()->getResultArray();\n\n\t\t$menus = $init->getAllMenu()->getResultArray();\n\t\t$this->data = ['menus' => $menus, 'resources' => $resources];\n\t\treturn view('admin' . DIRECTORY_SEPARATOR . 'resources' . DIRECTORY_SEPARATOR . 'index', $this->data);\n\t}", "title": "" }, { "docid": "b9a94eb6086245c9e4f089dc9aede055", "score": "0.64675385", "text": "public function index(Request $request)\n {\n $this->authorize('listing', [$this->authorizedModel]);\n\n return response(\n $this->obj->getAll(\n ($request->has('limit') ? $request->input('limit') : 0),\n ($request->has('sort') ? $request->input('sort') : 'id'),\n ($request->has('order') ? $request->input('order') : 'desc'),\n ($request->has('offset') ? $request->input('offset') : 0)\n )\n );\n }", "title": "" } ]
7d099626d0663378925ab5f75fb878e3
/ Primary Key Finder
[ { "docid": "96e5348681acdb9fa72425f4d5171a55", "score": "0.0", "text": "public function findById($id)\n {\n $sql=\"SELECT * FROM assinante WHERE id='$id' LIMIT 1\";\n return $this->getSelfObject($sql);\n }", "title": "" } ]
[ { "docid": "eb4196e17bab16a1cc2d8af869ca82c2", "score": "0.77222747", "text": "abstract public function getPrimaryKey();", "title": "" }, { "docid": "04f6e330e457bfd1ad498e98d656390c", "score": "0.7685921", "text": "abstract protected function getPrimaryKey();", "title": "" }, { "docid": "e2a1440b3adccdc33704c015a2bf6e5c", "score": "0.76437795", "text": "public static function GetPrimaryKey () {}", "title": "" }, { "docid": "39bdfc7239a53334026c328b524de9b8", "score": "0.7525424", "text": "public function getPrimaryKey();", "title": "" }, { "docid": "39bdfc7239a53334026c328b524de9b8", "score": "0.7525424", "text": "public function getPrimaryKey();", "title": "" }, { "docid": "39bdfc7239a53334026c328b524de9b8", "score": "0.7525424", "text": "public function getPrimaryKey();", "title": "" }, { "docid": "39bdfc7239a53334026c328b524de9b8", "score": "0.7525424", "text": "public function getPrimaryKey();", "title": "" }, { "docid": "39bdfc7239a53334026c328b524de9b8", "score": "0.7525424", "text": "public function getPrimaryKey();", "title": "" }, { "docid": "fd993a92829fb671a6a3197ffe51ecdf", "score": "0.7420466", "text": "public function getPK();", "title": "" }, { "docid": "45caf89db79ee73773f5f75273f99d36", "score": "0.7251362", "text": "public static function primary_key() {\n\t\t\treturn array('id');\t\n\t\t}", "title": "" }, { "docid": "c94cf0e41489b7937735e041045b735c", "score": "0.7205675", "text": "public function get_primary_key(): string;", "title": "" }, { "docid": "341c5a59656a2388e64226c1906baa10", "score": "0.70528173", "text": "public function getPrimaryKey(): array;", "title": "" }, { "docid": "eae2f806fcee500896efb04c79e397a8", "score": "0.69512653", "text": "function getPrimaryKey() {\n\n $count = $this->find('count');\n $primaryKey = $count + 1;\n\n if ($this->find('count', array('conditions' => array($this->name . '.' . $this->primaryKey => $primaryKey))) > 0) {\n\n $i = (int) $count;\n\n while ($i >= 1) {\n\n $i += 1;\n\n $primaryKey = $i;\n\n $returnValue = $this->find('count', array('conditions' => array($this->name . '.' . $this->primaryKey => $primaryKey)));\n\n if ($returnValue == 0) {\n\n break;\n }\n\n $i++;\n }\n\n return $primaryKey;\n } else {\n\n return $primaryKey;\n }\n }", "title": "" }, { "docid": "eae2f806fcee500896efb04c79e397a8", "score": "0.69512653", "text": "function getPrimaryKey() {\n\n $count = $this->find('count');\n $primaryKey = $count + 1;\n\n if ($this->find('count', array('conditions' => array($this->name . '.' . $this->primaryKey => $primaryKey))) > 0) {\n\n $i = (int) $count;\n\n while ($i >= 1) {\n\n $i += 1;\n\n $primaryKey = $i;\n\n $returnValue = $this->find('count', array('conditions' => array($this->name . '.' . $this->primaryKey => $primaryKey)));\n\n if ($returnValue == 0) {\n\n break;\n }\n\n $i++;\n }\n\n return $primaryKey;\n } else {\n\n return $primaryKey;\n }\n }", "title": "" }, { "docid": "eae2f806fcee500896efb04c79e397a8", "score": "0.69512653", "text": "function getPrimaryKey() {\n\n $count = $this->find('count');\n $primaryKey = $count + 1;\n\n if ($this->find('count', array('conditions' => array($this->name . '.' . $this->primaryKey => $primaryKey))) > 0) {\n\n $i = (int) $count;\n\n while ($i >= 1) {\n\n $i += 1;\n\n $primaryKey = $i;\n\n $returnValue = $this->find('count', array('conditions' => array($this->name . '.' . $this->primaryKey => $primaryKey)));\n\n if ($returnValue == 0) {\n\n break;\n }\n\n $i++;\n }\n\n return $primaryKey;\n } else {\n\n return $primaryKey;\n }\n }", "title": "" }, { "docid": "5e6fe28661ad9ed116b75e394e28416d", "score": "0.69433874", "text": "public function getPrimaryKey()\n {\n $primary_key = $this->getPrimaryKeyName();\n\n if (is_array($primary_key)) {\n $result = array();\n foreach ($primary_key as $key) {\n $result[$key] = $this->$key;\n }\n\n return $result;\n } else {\n return $this->$primary_key;\n }\n\n }", "title": "" }, { "docid": "27871e3fd01a58d9cc29fccd2af65521", "score": "0.69360006", "text": "public function primaryKey(): string;", "title": "" }, { "docid": "13b2a68a93271c66bb3d5d92295b91f3", "score": "0.6924501", "text": "abstract protected function getPrimaryKeyName();", "title": "" }, { "docid": "096644ed3dd86428a2a33b14ef70454b", "score": "0.69124705", "text": "function getPrimaryKeys() {\n \treturn $this->db->getPrimaryKeys($this->table);\n }", "title": "" }, { "docid": "0e66a5bad54353095b845519e09476e5", "score": "0.6834853", "text": "public function primaryKeySingle() : string;", "title": "" }, { "docid": "7ff0bd11e9e588782770511aeb5d64dd", "score": "0.6774786", "text": "public abstract function pkey_sql();", "title": "" }, { "docid": "afcbfef3cd6dcfd9ff464da335f28318", "score": "0.67638695", "text": "public function getPrimaryKeyName();", "title": "" }, { "docid": "098aff16667e706b68126322502c1838", "score": "0.6759989", "text": "public function PK($table_name){\n $PK = DB::select('SELECT FNC_GETPK(\"'.$table_name.'\");');\n foreach ($PK as $value) {\n $result = $value;\n }\n foreach ($result as $id) {\n $result = $id; // primary key\n }\n\n return $id;\n }", "title": "" }, { "docid": "98695b095d93e68bff6e85e038602768", "score": "0.67124355", "text": "public function getPrimaryKey(): ?string;", "title": "" }, { "docid": "123815d4a6eca6e5ee095991d39a09ae", "score": "0.67065585", "text": "function key_for($class_object){\n $className = get_class($class_object);\n $className = substr($className, strrpos($className, '\\\\') + 1);\n $columnToCheck = $className . \"_id\";\n $valueToCheck = $class_object->id;\n $db = new database();\n $result = $db->query(\"SELECT * FROM `dev_keys` WHERE `$columnToCheck`='$valueToCheck' AND `user_id`='$this->id'\");\n if($result && $result->num_rows > 0){\n /* @var $key key */\n $key = $result->fetch_object(\"\\DTD\\key\");\n $db->close();\n return $key;\n }\n $db->close();\n return false;\n }", "title": "" }, { "docid": "c12b7f005c26d7dcbdf8c56442fffc54", "score": "0.67040414", "text": "function find_primary_key_array($link,$table)\n{\n\t$sql_p='SHOW KEYS FROM `'.$table.'` WHERE Key_name = \\'PRIMARY\\'';\n\tif(!$result_p=mysqli_query($link,$sql_p)){echo mysqli_error($link);return FALSE;}\n\t$pk=array();\n\twhile($array_p=mysqli_fetch_assoc($result_p))\n\t{\n\t\t$pk[]=$array_p['Column_name'];\n\t}\n\treturn $pk;\n}", "title": "" }, { "docid": "d1ca2298896b2bba45d1f8494caf330c", "score": "0.6701924", "text": "private function get_primary_key_from_model() {\n try {\n ($this->debug_on_file) ? error_log(logTime() . basename(__FILE__) . \" \" . __FUNCTION__ . PHP_EOL, 3, 'logs/fn.log') : false;\n\n $model = $this->table_model;\n foreach ($model as $value) {\n if ($value[\"CONSTRAINT_TYPE\"] == \"PRIMARY_KEY\") {\n return $value[\"COL\"];\n }\n }\n } catch (Exception $e) {\n error_log(LogTime() . \" \" . message_err($e), 3, 'logs/error.log');\n throw new Exception(message_err($e));\n }\n }", "title": "" }, { "docid": "ce2b27e1358f3755db557b03c0b4816f", "score": "0.66889256", "text": "function getPrimaryKeys(java.lang.String catalog, java.lang.String schema, java.lang.String table){\r\n\t\tdie('Not implemented');\r\n\t}", "title": "" }, { "docid": "f0250d86e5bf63c323b7e0531d48562b", "score": "0.6669559", "text": "public function getPrimaryKey()\n\t{\n\t\tif(empty($this->primaryKey))\n\t\t{\n\t\t\tforeach($this->getSchema() as $field)\n\t\t\t{\n\t\t\t\tif($field[\"Key\"] == \"PRI\")\n\t\t\t\t{\n\t\t\t\t\t$this->setPrimaryKey($field[\"Field\"]);\n\t\t\t\t\treturn $this->getPrimaryKey();\n\t\t\t\t}\n\t\t\t}\n\t\t\tthrow new Recipe_Exception_Generic(\"Table <b>\".$this->getName().\"</b> has no primary key defined.\");\n\t\t}\n\t\treturn $this->primaryKey;\n\t}", "title": "" }, { "docid": "d0f99faef98615b274cbe45f00d68b7d", "score": "0.66580945", "text": "protected function _primaryKey()\n\t{\n\t\treturn $this->repo->getModel()->getKeyName();\n\t}", "title": "" }, { "docid": "0a9e931b692418e30f7e461edb2331ed", "score": "0.66488945", "text": "static function getPrimaryKeys() {\n\t\treturn Session::$_primaryKeys;\n\t}", "title": "" }, { "docid": "b2e5691826721c7ffb2b2e4fea1792d5", "score": "0.663629", "text": "public function get_primary_key() {\n $retour = array();\n foreach (self::get_primary_key_fields() as $primary_key_field) {\n $retour[$primary_key_field] = $this->get_model_id_by_joining_field($primary_key_field);\n }\n\n return $retour;\n }", "title": "" }, { "docid": "f8665052fdd20760860181742dbea202", "score": "0.66329604", "text": "public function getKey()\n {\n return $this->primaryKey;\n }", "title": "" }, { "docid": "f17d1c3cc625b2c631b9272294918bc1", "score": "0.6631447", "text": "protected function _getPrimaryKey() {\n\t $primaryKey = array();\n\t if ( count($this->_dbColumns)==0 ) {\n\t return false;\n\t }\n\t foreach ($this->_dbColumns as $field) {\n\t if ( in_array(\"primary_key\",$field[\"flags\"]) ) {\n\t $primaryKey[] = array(\"name\"=>$field[\"name\"],\"type\"=>$field[\"type\"],\"value\"=>null);\n\t }\n }\n return $primaryKey;\n\t}", "title": "" }, { "docid": "f5f3eb2399a13b00df2b296bc01f6903", "score": "0.662148", "text": "static function getPrimaryKey() {\n\t\treturn Session::$_primaryKey;\n\t}", "title": "" }, { "docid": "4f338a938223e659b268fd1438a32338", "score": "0.6604774", "text": "public function primaryKey() {\r\n $metadata = $this->getData();\r\n $result = array();\r\n foreach ($metadata as $key => $value) {\r\n if ($value->primary_key == '1') {\r\n $result[] = $value->name;\r\n }\r\n }\r\n return $result;\r\n }", "title": "" }, { "docid": "dde76ce04522b7bf40001dcabdc177df", "score": "0.6600789", "text": "public function getPrimaryKey()\n {\n if (empty($this->indexes['PRIMARY'])) {\n return false;\n }\n\n $pk = $this->indexes['PRIMARY']->fields;\n\n return is_array($pk) && count($pk) > 1 ? $pk : array_shift($pk);\n }", "title": "" }, { "docid": "e067bd0307d64ba52ff5c25cb09f692b", "score": "0.657587", "text": "public function getPrimaryKey()\n {\n $pks = array();\n $pks[0] = $this->getOehdnbr();\n $pks[1] = $this->getOedtline();\n\n return $pks;\n }", "title": "" }, { "docid": "6b96f272c4f66766e92578dcf36962a7", "score": "0.65723515", "text": "protected function _setupPrimaryKey()\n {\n if (!$this->_primary) {\n $this->_setupMetadata();\n $this->_primary = array();\n foreach ($this->_metadata as $col) {\n if ($col['PRIMARY']) {\n $this->_primary[ $col['PRIMARY_POSITION'] ] = $col['COLUMN_NAME'];\n if ($col['IDENTITY']) {\n $this->_identity = $col['PRIMARY_POSITION'];\n }\n }\n }\n // if no primary key was specified and none was found in the metadata\n // then throw an exception.\n if (empty($this->_primary)) {\n //require_once 'Zend/Db/Table/Exception.php';\n //throw new Zend_Db_Table_Exception('A table must have a primary key, but none was found');\n exit('A table must have a primary key, but none was found');\n }\n } else if (!is_array($this->_primary)) {\n $this->_primary = array(1 => $this->_primary);\n } else if (isset($this->_primary[0])) {\n array_unshift($this->_primary, null);\n unset($this->_primary[0]);\n }\n \n $cols = $this->_getCols();\n if (! array_intersect((array) $this->_primary, $cols) == (array) $this->_primary) {\n //require_once 'Zend/Db/Table/Exception.php';\n //throw new Zend_Db_Table_Exception\n throw new Exception(\"Primary key column(s) (\"\n . implode(',', (array) $this->_primary)\n . \") are not columns in this table (\"\n . implode(',', $cols)\n . \")\");\n }\n \n $primary = (array) $this->_primary;\n }", "title": "" }, { "docid": "b08fa8e8065ceb55127380ccd47dd24e", "score": "0.6567899", "text": "function hasPrimaryKey() {\n \tforeach($this->getIndices() as $index) {\n \t if($index->getType() == DBIndex::PRIMARY) {\n \t return true;\n \t } // if\n \t} // foreach\n \t\n \treturn false;\n }", "title": "" }, { "docid": "d22f853eaf484d66b7e2c84d4837a466", "score": "0.65525734", "text": "protected static function primaryKey(): string\n {\n return 'id';\n }", "title": "" }, { "docid": "d35123695ecc0800b2851b9d436bce79", "score": "0.654353", "text": "protected function getPrimaryKeys() {\n $keys = array();\n foreach ($this->info['columns'] as $field => $info) {\n if (strtolower($info['key']) == 'pri') {\n $keys[] = $field;\n }\n }\n return $keys;\n }", "title": "" }, { "docid": "4ce7d23177e94a63ae24b520fa86d1ac", "score": "0.6535909", "text": "public function getPrimaryKey() {\r\n\t\tforeach($this->fields as $index => $content) {\r\n\t\t\tif($content['field']['options']['primary'] == true) {\r\n\t\t\t\treturn $content;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t$modelName = get_class($this->modelObj);\r\n\t\tPhpBURN_Message::output(\"<b>$modelName</b> [!has no Primary Key. How did you did it?!]\", PhpBURN_Message::EXCEPTION);\r\n\t}", "title": "" }, { "docid": "4b4b0cb8732fe481866e0455d4230d18", "score": "0.65328276", "text": "function getPrimary_key()\n {\n if (!isset($this->aPrimary_key)) {\n $this->aPrimary_key = array('id_item_ex' => $this->iid_item_ex, 'id_enc' => $this->iid_enc);\n }\n return $this->aPrimary_key;\n }", "title": "" }, { "docid": "e83b168a6eabed21320a8dca40eba8ca", "score": "0.65300333", "text": "public function hasPrimaryKey(): bool;", "title": "" }, { "docid": "641fc7cea78e0ee0d3d3f7c5aa03ba81", "score": "0.65228915", "text": "function getPrimary_key()\n {\n if (!isset($this->aPrimary_key)) {\n $this->aPrimary_key = array('id_item' => $this->iid_item, 'id_enc' => $this->iid_enc, 'id_nom' => $this->iid_nom);\n }\n return $this->aPrimary_key;\n }", "title": "" }, { "docid": "202ad13cee83de5e80c2348eb4b91de5", "score": "0.6521351", "text": "public function schemaPK() {\n return $this->primaryKeyArray;\n }", "title": "" }, { "docid": "202ad13cee83de5e80c2348eb4b91de5", "score": "0.6521351", "text": "public function schemaPK() {\n return $this->primaryKeyArray;\n }", "title": "" }, { "docid": "202ad13cee83de5e80c2348eb4b91de5", "score": "0.6521351", "text": "public function schemaPK() {\n return $this->primaryKeyArray;\n }", "title": "" }, { "docid": "897bbd22ff98813fd951c19121c8bb66", "score": "0.65143603", "text": "protected function getTablePrimaryKey($table)\n {\n \n switch ($this->databaseEngine) {\n case 'mysql':\n $primaryKeyResult = \\DB::select(\n \"SELECT COLUMN_NAME\n FROM information_schema.COLUMNS \n WHERE TABLE_SCHEMA = '\" . env(\"DB_DATABASE\") . \"' AND \n TABLE_NAME = '{$table}' AND \n COLUMN_KEY = 'PRI'\"); \n break;\n\n case 'sqlsrv':\n case 'dblib':\n\n $primaryKeyResult = \\DB::select(\n \"SELECT ku.COLUMN_NAME\n FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS AS tc\n INNER JOIN INFORMATION_SCHEMA.KEY_COLUMN_USAGE AS ku\n ON tc.CONSTRAINT_TYPE = 'PRIMARY KEY' \n AND tc.CONSTRAINT_NAME = ku.CONSTRAINT_NAME\n WHERE ku.TABLE_CATALOG ='\" . env(\"DB_DATABASE\") . \"' AND ku.TABLE_NAME='{$table}';\");\n break;\n\n case 'pgsql':\n \n $primaryKeyResult = \\DB::select(\n \"SELECT ku.COLUMN_NAME AS \\\"COLUMN_NAME\\\"\n FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS AS tc\n INNER JOIN INFORMATION_SCHEMA.KEY_COLUMN_USAGE AS ku\n ON tc.CONSTRAINT_TYPE = 'PRIMARY KEY' \n AND tc.CONSTRAINT_NAME = ku.CONSTRAINT_NAME\n WHERE ku.TABLE_CATALOG ='\" . env(\"DB_DATABASE\") . \"' AND ku.TABLE_NAME='{$table}';\");\n break;\n \n }\n\n if (count($primaryKeyResult) == 1){\n return $primaryKeyResult[0]->COLUMN_NAME;\n }\n\n return null;\n }", "title": "" }, { "docid": "b9cea1aa7e79e2012a108677139c6617", "score": "0.6512682", "text": "static public function primaryKey()\n {\n return (new static())->getKeyName();\n }", "title": "" }, { "docid": "dbf65c0f8410b9fc3d55935b86e0565d", "score": "0.6508494", "text": "private function getIdentifier()\n\t{\n\t\t\n\t\tif ( ! empty( static::$primary ) ){\n\t\t\t\n\t\t\t$method_name = 'get' . ucfirst( static::$primary );\n\t\t\t\n\t\t\t$id_key = $this->$method_name();\n\t\t\t\n\t\t\treturn $id_key;\n\t\t\t\n\t\t}\n\t\telse{\n\t\t\t\n\t\t\t$this->logger->error('Não foi informado um campo identificador do model ' . static::$source);\n\n\t\t\tthrow new \\Exception('Não foi informado um campo identificador.');\n\t\t\t\n\t\t}\n\t\t\n\t}", "title": "" }, { "docid": "5f9901e14fd5848c644f51310272e131", "score": "0.6486054", "text": "public function idKeyName(): ?string;", "title": "" }, { "docid": "5f9901e14fd5848c644f51310272e131", "score": "0.6486054", "text": "public function idKeyName(): ?string;", "title": "" }, { "docid": "acbac88769887da6c4d61eb21af7215c", "score": "0.6467325", "text": "public function getPrimaryKey()\n {\n $pks = array();\n $pks[0] = $this->getSessionid();\n $pks[1] = $this->getRecno();\n $pks[2] = $this->getOrderno();\n\n return $pks;\n }", "title": "" }, { "docid": "b1f2031982e2f73f6568885fe3da6522", "score": "0.64653665", "text": "public function PrimaryKey() {\n\t\t\treturn $this->strListaCursoId;\n\t\t}", "title": "" }, { "docid": "5314b8a1a4d18b295e6121efeac05e00", "score": "0.64638025", "text": "function pk() {\n return $this->_primary_key;\n }", "title": "" }, { "docid": "cc45ed45dfbe44389056c953aaffb518", "score": "0.6452035", "text": "public static function primaryKey()\r\n {\r\n return ['id'];\r\n }", "title": "" }, { "docid": "86268543a322551c6fe170954341116a", "score": "0.6451693", "text": "public function getPrimaryKey(): string\n\t{\n\t\treturn $this->primaryKey;\n\t}", "title": "" }, { "docid": "39dd97b86b49c6d8891eb27154dc701a", "score": "0.64493823", "text": "public function primaryKey(): string\n {\n return 'id';\n }", "title": "" }, { "docid": "f0a885cd5358b3ecb06fa333af2956ae", "score": "0.6440785", "text": "function getPrimary_key()\n {\n if (!isset($this->aPrimary_key)) {\n $this->aPrimary_key = array('id_item' => $this->iid_item);\n }\n return $this->aPrimary_key;\n }", "title": "" }, { "docid": "b689139aaa29c97dc0f99691ab30f33b", "score": "0.64398336", "text": "public function getPrimaryKey()\n {\n $pks = array();\n $pks[0] = $this->getSessionid();\n $pks[1] = $this->getPohdnbr();\n\n return $pks;\n }", "title": "" }, { "docid": "3882a11ce980b59ccb43dc5c03eac8bc", "score": "0.64292127", "text": "public function get_primary_key($table)\n\t{\n\t\t$original_db = $this->get_database();\n\n\t\t$this->called_from = __FUNCTION__;\n\t\t//if ($this->select_db('information_schema') === FALSE)\n\t\t//\treturn FALSE;\n\n\t\t//$this->called_from = __FUNCTION__;\n\t\t//$this->query(\"SELECT `COLUMN_NAME` AS `PrimaryKey` FROM `KEY_COLUMN_USAGE` WHERE `TABLE_NAME` = '{$table}' AND `CONSTRAINT_NAME` = 'PRIMARY'\");\n\t\t$this->query(\"SELECT `k`.`column_name` FROM `information_schema`.`table_constraints` `t` JOIN `information_schema`.`key_column_usage` `k` USING(`constraint_name`, `table_schema`, `table_name`) WHERE `t`.`constraint_type` = 'PRIMARY KEY' AND `t`.`table_schema` = '{$original_db}' AND `t`.`table_name` = '{$table}';\");\n\t\t//die(print_r($this->result));\n\n\t\t//if ($this->result === FALSE)\n\t\t//\treturn FALSE;\n\n\t\t//$this->called_from = __FUNCTION__;\n\t\t//if ($this->select_db($original_db) === FALSE)\n\t\t//\treturn FALSE;\n\n\t\tif ($this->result === FALSE || ($this->result !== FALSE && (\n\t\t\t\t\tisset($this->result->rows[0]) === FALSE ||\n\t\t\t\t\tis_object($this->result->rows[0]) === FALSE ||\n\t\t\t\t\tisset($this->result->rows[0]->column_name) === FALSE) ) )\n\t\t\treturn FALSE;\n\n\t\t//return $this->result->rows[$last_row]->PrimaryKey;\n\t\treturn $this->result->rows[0]->column_name;\n\t}", "title": "" }, { "docid": "d7d4386e638ee453f5070c76def1dfa7", "score": "0.64217883", "text": "public function primaryKeyPrefix()\n {\n return;\n }", "title": "" }, { "docid": "eac9e349836715e101e1388f03d81edb", "score": "0.64215845", "text": "function getPrimaryKey($vc_comp_code) {\n\n $count = $this->find('count');\n\n $primaryKey = (string) ( strtoupper($vc_comp_code) . '-ASS-' . ($count + 1) );\n\n if ($this->find('count', array('conditions' => array($this->name . '.' . $this->primaryKey => $primaryKey))) > 0) {\n\n $i = (int) $count;\n\n while ($i >= 1) {\n\n $i += 1;\n\n $primaryKey = (string) ( strtoupper($vc_comp_code) . '-ASS-' . ($i) );\n\n $returnValue = $this->find('count', array('conditions' => array($this->name . '.' . $this->primaryKey => $primaryKey)));\n\n if ($returnValue == 0) {\n\n break;\n }\n\n $i++;\n }\n\n return $primaryKey;\n } else {\n\n return $primaryKey;\n }\n }", "title": "" }, { "docid": "c052aaba3e52287a5c77cd4e2ac4c82f", "score": "0.6420913", "text": "public function getPrimaryKey()\n {\n $pk = array();\n foreach($this->getAttributes() as $name => $attribute /* @var Attribute $attribute */) {\n if ($attribute->isPrimaryKey)\n $pk[] = $name;\n }\n $count = count($pk);\n if (!$count)\n return 'id';\n else if ($count == 1)\n return $pk[0];\n else\n return $pk;\n }", "title": "" }, { "docid": "ee1d64aafbd26a95167b790b028f7747", "score": "0.6413998", "text": "public function key ( /* void */ )\n {\n /*\n The key is the primary key.\n */\n return $this->__record[$this->__pk];\n }", "title": "" }, { "docid": "60012396a3a2a2ee06e7abdbddcefbad", "score": "0.64002055", "text": "abstract public function getPrimaryKeys(string $tableName): array;", "title": "" }, { "docid": "8c41b40a59d0611e74bcca0be3f57a29", "score": "0.6394", "text": "private function getFirstPk()\r\n\t{\r\n\t\t$keys = array_keys($this->table['PK']);\r\n\t\treturn $keys[0];\r\n\t}", "title": "" }, { "docid": "91fa934eb4387192ad533365acf4fa8d", "score": "0.63901055", "text": "public function primaryKey()\n {\n return $this->_primaryKey;\n }", "title": "" }, { "docid": "595aeba520f61456697983870d7c79c9", "score": "0.6382527", "text": "public function getPrimaryKey($row)\n\t{\n\t\t$primary_key = $this->primary_key;\n\t\t\n\t\treturn $row->$primary_key;\n\t}", "title": "" }, { "docid": "728de31879899e43a31c2660e5893bca", "score": "0.63815874", "text": "function get_primary_key($Table){\n if (is_string($Table)){\n $Table = $this->getColumnNames($Table, \"\", false);\n }\n if (is_array($Table)){\n foreach($Table as $Key => $Value){\n if(isset($Value['autoIncrement'])){\n return $Key;\n }\n }\n }\n }", "title": "" }, { "docid": "8013f700a9c47b8ec5c5420be7ce20c9", "score": "0.63786197", "text": "public function getPk();", "title": "" }, { "docid": "379e9f45c0c8a3fbc023dcb03a418f7f", "score": "0.6377828", "text": "public function get_primary_key(){\r\n\t\t\treturn $this->column_primary_key;\r\n\t\t}", "title": "" }, { "docid": "faae82444f9b0b06fed66683ea856d83", "score": "0.63773704", "text": "public function get_primary_key(): string {\n\t\treturn 'file_id';\n\t}", "title": "" }, { "docid": "2f0700bfa29ca7a1946e7f7178da969f", "score": "0.6356534", "text": "private function model_order_primary_key() {\n ($this->debug_on_file) ? error_log(logTime() . basename(__FILE__) . \" \" . __FUNCTION__ . PHP_EOL, 3, 'logs/fn.log') : false;\n\n $model = $this->table_model;\n $key_row = [];\n $ar2 = []; //ord aray with ID/PRIMARY KEY with first element\n //while ($row = current($ar)) {\n foreach ($model as $value) {\n if ($value[\"CONSTRAINT_TYPE\"] == \"PRIMARY_KEY\") {\n $key_row = $value;\n } else {\n $ar2[] = $value;\n }\n }\n $model_ord = array_merge([$key_row], $ar2); //model order by primary key\n return $model_ord;\n }", "title": "" }, { "docid": "2fa82722cf6eec185779b1634c66dd3b", "score": "0.63493216", "text": "public function getPrimaryKey()\n {\n return $this->_primaryKey;\n }", "title": "" }, { "docid": "f87057dc8f6593358ae5c104786bffab", "score": "0.6345268", "text": "public function getPrimaryKey()\r\n\t{\r\n\t\treturn $this->_primaryKey;\r\n\t}", "title": "" }, { "docid": "bf047a8add0d7711ef0333de78737882", "score": "0.63421935", "text": "public function find($table, $key, $identifier);", "title": "" }, { "docid": "101cc89b253585cbb7639ccb2a6fe2f2", "score": "0.63390404", "text": "public function getPrimaryKey()\n {\n return $this->primaryKey;\n }", "title": "" }, { "docid": "101cc89b253585cbb7639ccb2a6fe2f2", "score": "0.63390404", "text": "public function getPrimaryKey()\n {\n return $this->primaryKey;\n }", "title": "" }, { "docid": "101cc89b253585cbb7639ccb2a6fe2f2", "score": "0.63390404", "text": "public function getPrimaryKey()\n {\n return $this->primaryKey;\n }", "title": "" }, { "docid": "88adc05bd695f33c16e749123a34bad0", "score": "0.6323505", "text": "public function reverseEngineerPK()\n {\n $q = \"SHOW INDEX FROM `{$this->getName()}` WHERE Key_name='PRIMARY'\";\n $stmt = $this->pdo->query($q);\n $key = '';\n while ($col = $stmt->fetchColumn(4)) {\n $key = $col;\n }\n\n return $key;\n }", "title": "" }, { "docid": "5df44cb90ab34012d185ae37507f54f2", "score": "0.6307027", "text": "static function getPrimaryKey() {\n\t\treturn FileType::$_primaryKey;\n\t}", "title": "" }, { "docid": "f00f8a0a8bc3b6733f8bc5d36dc5ddda", "score": "0.6306632", "text": "public function getPrimaryKey()\n\t{\n\t\treturn array('id');\n\t}", "title": "" }, { "docid": "5992b41be2a9ebc4f3c5d3c465a55d99", "score": "0.6304451", "text": "public function findByKey($key);", "title": "" }, { "docid": "9e3d06a5bdd4a3c9806a18e97761f915", "score": "0.62963253", "text": "public function getPrimaryKey()\n\t{\n\t\treturn $this->getGruCodigo();\n\t}", "title": "" }, { "docid": "3a3fb738f60b606bfafc4b3873f904b7", "score": "0.6296094", "text": "abstract protected function getKey();", "title": "" }, { "docid": "993b0dd254bab4898edd2afa08ae9ef9", "score": "0.6293634", "text": "public function primaryKey()\n\t{\n\t\treturn 'keyCode';\n\t}", "title": "" }, { "docid": "a3797df65611d61d2e0e7460c9aba39a", "score": "0.6293282", "text": "function get_record_by_id($table, $primary_key, $id) {\n $conn = get_connection();\n\n $query = $conn->prepare(\n 'SELECT * FROM ' . $table . ' WHERE ' . $primary_key . ' = :id');\n $query->bindValue(':id', $id);\n $result = $query->execute()->fetchArray(SQLITE3_ASSOC);\n $conn->close();\n\n return $result;\n}", "title": "" }, { "docid": "bd4a611f1dfd6e104c23510c1a2e2b45", "score": "0.62915367", "text": "public function getPrimaryKey()\n\t{\n\t\treturn $this->primaryKey;\n\t}", "title": "" }, { "docid": "3b44aecb75cc9dfb07fe8db286a7b220", "score": "0.6287992", "text": "protected function getPrimaryKey(): array\n {\n $primary = array_flip($this->getTable()->getPrimaryKey());\n\n return array_intersect_key($this->toArray(), $primary);\n }", "title": "" }, { "docid": "441e24beef3f28baa6264d1c1d7b3233", "score": "0.62769735", "text": "public function getPrimaryKey()\n {\n return $this->getSekolahId();\n }", "title": "" }, { "docid": "b4c99b9f322a91bb526f0cd8a169c879", "score": "0.62714", "text": "public function getHasPrimaryKey()\r\n\t{\r\n\t\tforeach($this->indices AS $index)\r\n\t\t{\r\n\t\t\tif($index->INDEX_NAME == 'PRIMARY')\r\n\t\t\t{\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "title": "" }, { "docid": "f78278c63a9ba74a0f7b78a6255d4d18", "score": "0.6263802", "text": "public function getKeyName(): string\n {\n return $this->primaryKey;\n }", "title": "" }, { "docid": "c018c1b040cbe7ddd356d26d9700a842", "score": "0.62607104", "text": "static function getPrimaryKeys() {\n\t\treturn FileType::$_primaryKeys;\n\t}", "title": "" }, { "docid": "230d0cf7a3c3c080e0cbf814808785a5", "score": "0.6246758", "text": "public function getPrimaryKey() {\n\t\treturn $this->primaryKey;\n\t}", "title": "" }, { "docid": "45998694e685d4bdcac47d9e90ae98e4", "score": "0.62457556", "text": "public function primaryKey()\n\t{\n\t\treturn NULL;\n\t}", "title": "" }, { "docid": "f95475d291d8065c3b6cf2ec14c8e585", "score": "0.6241226", "text": "function table_primary_key($table=NULL,$db=NULL){\n $PK=NULL;\n if(DB_ENGINE==DB_ENGINE_MYSQL || !defined('DB_ENGINE')){\n // MySQL\n $p_query=mysql_query(\"\n SELECT COLUMN_NAME \n FROM KEY_COLUMN_USAGE \n WHERE CONSTRAINT_SCHEMA = '\".$db.\"'\n AND TABLE_NAME = '$table' AND CONSTRAINT_NAME = 'PRIMARY'\n \");\n if(mysql_num_rows($p_query)>0){\n $primk=mysql_fetch_assoc($p_query);\n $PK=$primk['COLUMN_NAME'];\n }\n }elseif(DB_ENGINE==DB_ENGINE_MSSQL){\n // MS SQL Server 2005 y 2000\n $p_query=mssql_query(\"\n SELECT KU.*\n FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS AS TC\n INNER JOIN\n INFORMATION_SCHEMA.KEY_COLUMN_USAGE AS KU\n ON TC.CONSTRAINT_TYPE = 'PRIMARY KEY' AND\n TC.CONSTRAINT_NAME = KU.CONSTRAINT_NAME\n WHERE TC.TABLE_NAME = '$table'\n \");\n if(mssql_num_rows($p_query)>0){\n $primk=mssql_fetch_assoc($p_query);\n $PK=$primk['COLUMN_NAME'];\n }\n }\n return $PK;\n}", "title": "" }, { "docid": "6736694735d45bd42ae4e3d7f9181bee", "score": "0.6240244", "text": "public function hasPrimaryKey()\n {\n // Tool creator session container\n $container = new Container('melistoolcreator');\n $tcSteps = $container['melis-toolcreator'];\n $tcfDbTbl = $tcSteps['step3']['tcf-db-table'];\n return $this->getTablePK($tcfDbTbl);\n }", "title": "" }, { "docid": "2529216eff6d30d539a4799dea6eea14", "score": "0.62309295", "text": "public function primaryKey() {\n\t\treturn 'id';\n\t}", "title": "" } ]
f0e118454b9e81104130fb73fc0490a4
Checks to see if the user is adding users to their public draft
[ { "docid": "af93e65d906aad23e93f642fe78cd660", "score": "0.6866609", "text": "protected static function userIsAddingUsersToDraft($requestURI = null)\n {\n $addUsersToDraftUrl = RoutingUtil::buildUrl(Config::ROUTING_LOCATION, 'addUsersToDraft', ['draftName' => self::guessDraftName($requestURI)], Config::WEB_DIR);\n\n return (($addUsersToDraftUrl === $requestURI) || (isset($_GET['concert']) && $_GET['concert'] === 'addUsers'));\n }", "title": "" } ]
[ { "docid": "6ff582d0cbe2278f4dab965ee8a778f2", "score": "0.71099025", "text": "protected static function userIsSavingPublicDraft()\n {\n return (isset($_POST['saveAction']) && $_POST['saveAction'] === 'savePublicDraft');\n }", "title": "" }, { "docid": "d7a75ad8e55d702d734a937cc2a60ddf", "score": "0.6615729", "text": "private function _validate_user() {\n\t\treturn (current_user_can(\"edit_posts\") && current_user_can(\"edit_pages\") && !empty($this->buttons));\n\t}", "title": "" }, { "docid": "ed37ef4d4dea556cf532eea9ecf63442", "score": "0.6428168", "text": "function user_can_create_draft($user_id, $blog_id = 1, $category_id = 'None')\n {\n }", "title": "" }, { "docid": "9283479ee3897dda607dd7d777718ec0", "score": "0.6425521", "text": "protected function hasAccessOnPublished()\n\t{\n\t\treturn $this->User->hasAccess($GLOBALS['TL_DCA'][$this->strTable]['config']['ptable'] . '::published', 'alexf');\t\t\n\t}", "title": "" }, { "docid": "2074f862e7c7b4a573b27b8f863cf053", "score": "0.6393627", "text": "protected static function userIsSavingPrivateDraft()\n {\n return (isset($_POST['saveAction']) && $_POST['saveAction'] === 'savePrivateDraft');\n }", "title": "" }, { "docid": "832ebec8f4497ee302229d0f8d15b3a5", "score": "0.6274822", "text": "public function hasWpUserId(){\n return $this->_has(7);\n }", "title": "" }, { "docid": "a9324e46878dc1dc36607e0b2e0de77d", "score": "0.6230153", "text": "protected static function userIsSavingDraft()\n {\n return (self::userIsSavingPublicDraft() || self::userIsSavingPrivateDraft());\n }", "title": "" }, { "docid": "8273c51a2f16b6931aeced7cc594b571", "score": "0.61801535", "text": "public static function userCreationAllowed(): bool\n {\n return self::isConfigured(self::ACTION_ADD_USER);\n }", "title": "" }, { "docid": "c25a1bd19d88aba0e2c017e175e76828", "score": "0.6176537", "text": "protected static function userIsViewingDraft()\n {\n return (isset($_GET['concert']) && $_GET['concert'] === 'viewDraft');\n }", "title": "" }, { "docid": "67908e2c8e6a88fb51952089136cf6d6", "score": "0.61682636", "text": "protected static function userIsDeletingDraft()\n {\n return (isset($_POST['saveAction']) && $_POST['saveAction'] === 'discardDraft');\n }", "title": "" }, { "docid": "63dfd472db5b296d6c3ab514fa9531b1", "score": "0.61673814", "text": "protected static function userIsEditingDraft()\n {\n return (isset($_GET['concert']) && $_GET['concert'] === 'editDraft');\n }", "title": "" }, { "docid": "619bebfd5ba053045754c9f2b8223785", "score": "0.6132123", "text": "function _check_users()\n\t{\n\t\tif(!empty($_POST['user']))\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\treturn false;\n\t}", "title": "" }, { "docid": "e57864b2b80b68034a39e3700b275b10", "score": "0.61266047", "text": "protected static function isDraftRequest()\n {\n return (self::userIsViewingDraft() || self::userIsSavingDraft() || self::userIsDeletingDraft() || self::userIsEditingDraft() || self::userIsAddingUsersToDraft());\n }", "title": "" }, { "docid": "97773151be2fa4e5c1c7606af5d0f8bd", "score": "0.61022556", "text": "function _hasAccess()\r\n {\r\n // create user object\r\n $user =& User::singleton();\r\n\r\n $timePoint =& TimePoint::singleton($_REQUEST['sessionID']);\r\n $candID = $timePoint->getCandID();\r\n\r\n $candidate =& Candidate::singleton($candID);\r\n\r\n // check user permissions\r\n return ($user->hasPermission('access_all_profiles') || $user->getData('CenterID') == $candidate->getData('CenterID') || $user->getData('CenterID') == $timePoint->getData('CenterID'));\r\n }", "title": "" }, { "docid": "9d1c476a72abf36b43992fe6ce3f1301", "score": "0.6074353", "text": "public function isAssigned()\n {\n return $this->users->count() > 0;\n }", "title": "" }, { "docid": "9ee8a0a9ef2a51b728f705d0bbaf0739", "score": "0.6035504", "text": "public function isDraft();", "title": "" }, { "docid": "4abd5d7d94547f12ce2d7a0db82ef0a4", "score": "0.6025343", "text": "public function isAuthorized($user) {\n if ($this->action === 'add') {\n return true;\n }\n\n // The owner of a post can edit and delete it\n if (in_array($this->action, array('edit', 'delete'))) {\n $postId = $this->request->params['pass'][0];\n if ($this->Post->isOwnedBy($postId, $user['id'])) {\n return true;\n }\n }\n\n return parent::isAuthorized($user);\n\t}", "title": "" }, { "docid": "4f1e14876ce989207a2db8de14f53805", "score": "0.6024936", "text": "public function is_exists() {\n\t\treturn ( $this->user->ID > 0 ) && ( false !== get_userdata( $this->user->ID ) );\n\t}", "title": "" }, { "docid": "aa02b80b6308ba8f408bea8759108765", "score": "0.60142076", "text": "public function create(User $user)\n {\n return $user->hasAccess('create-announcement');\n }", "title": "" }, { "docid": "ef66baba8d9f3a1eee8ce056322148cf", "score": "0.5982208", "text": "public function isAuthorized($user) {\n\t\tif ($this->action === 'add') {\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\t// The owner of a post can edit and delete it\n\t\tif (in_array ( $this->action, array (\n\t\t\t\t'edit',\n\t\t\t\t'delete' \n\t\t) )) {\n\t\t\t$postId = $this->request->params ['pass'] [0];\n\t\t\tif ($this->Post->isOwnedBy ( $postId, $user ['id'] )) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn parent::isAuthorized ( $user );\n\t}", "title": "" }, { "docid": "311a4029b2157e30f66610d4bb01521d", "score": "0.5969989", "text": "function canCreatePage() {\n return ($this->isAdmin() || ($this->userType == 'author'));\n }", "title": "" }, { "docid": "11f865b3eb7d34c9a6e7b8cdd9dea796", "score": "0.59685594", "text": "public function isAuthorized($user) {\n if (in_array($this->action, array(\n 'pageChanges',\n 'add',\n ))){\n \n return true;\n }\n \n // If we get here, not authorized \n //$this->Session->setFlash(__('Sorry, you\\'re not authorized to access that.'), 'flash/auth_error');\n return parent::isAuthorized($user);\n }", "title": "" }, { "docid": "de8006ddd4c63e6d18bdaeddbaf90322", "score": "0.5961879", "text": "public function isOwned()\n {\n return Auth::user() && $this->recipient_id === Auth::id();\n }", "title": "" }, { "docid": "29a59fe04bf8b73305f8dc06832c479a", "score": "0.59475815", "text": "public function authorize()\n {\n $accessor = $this->user();\n\n return $accessor->isAdmin() || $accessor->hasKey('post-users');\n }", "title": "" }, { "docid": "86a4a9a1ca0f6fc40aa86715081731c3", "score": "0.5936129", "text": "function checkPermissions() {\n \t//If blog owner or super user\n \t$current_user = wp_get_current_user();\n\t\tif(is_super_admin() || (get_bloginfo('admin_email') === $current_user->user_email)) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "title": "" }, { "docid": "7ae306218ef72ca7462ca4569674655b", "score": "0.59119314", "text": "public function has_user_fundraiser()\n {\n return ( ! empty( $this->get_user_fundraiser() ) );\n }", "title": "" }, { "docid": "a8126db7c8afd8a3e039e972de75e66b", "score": "0.59015113", "text": "public function publish(User $user)\n {\n return $user->hasPermissionTo('publish campaign');\n }", "title": "" }, { "docid": "72bfce97aeef7aa61d07c6d1b1231e47", "score": "0.5901467", "text": "protected function allowedUserForInvitationNewAndCreate()\n {\n if (empty($this->settings['invitation']['allowedUserGroups'] ?? [])) {\n return true;\n }\n $allowedUsergroupUids = GeneralUtility::trimExplode(\n ',',\n $this->settings['invitation']['allowedUserGroups'] ?? [],\n true\n );\n $currentUsergroupUids = UserUtility::getCurrentUsergroupUids();\n\n // compare allowedUsergroups with currentUsergroups\n if (count(array_intersect($allowedUsergroupUids, $currentUsergroupUids))) {\n return true;\n }\n\n // current user is not allowed\n $this->addFlashMessage(\n LocalizationUtility::translateByState(Log::STATUS_INVITATIONRESTRICTEDPAGE),\n '',\n AbstractMessage::ERROR\n );\n return new ForwardResponse('status');\n }", "title": "" }, { "docid": "c2de0e06dcdb67352fd375986fa8ab4a", "score": "0.5900655", "text": "function can_edit() {\n\tglobal $post;\n\t// Get User Info\n\t$current_user = wp_get_current_user();\n\t$user = get_userdata( $current_user->ID );\n\t$user_roles = $user->roles;\n\t// Get Author ID\n\t$author_id = $post->post_author;\n\n\tif ( $author_id == $current_user->ID ) {\n\t\t// User is Author. Can edit.\n\t\treturn true;\n\t} elseif ( in_array( 'managed', $user_roles, true ) ) {\n\n\t\t// MANAGED ACCOUNT. Compare to Author\n\t\t$author = get_userdata( $author_id );\n\t\t$author_email = $author->user_email;\n\n\t\t$manager = get_user_meta( $current_user->ID, 'mepr__managed', true );\n\n\t\tif( $manager ) {\n\t\t\t// User has the \"_managed\" field properly set. Use it!\n\t\t\tif( $author_email == $manager ) {\n\t\t\t\t// This account is managed by the author. Bingo!\n\t\t\t\treturn true;\n\t\t\t} else {\n\t\t\t\t// This account is managed, but not by the author.\n\t\t\t\treturn false;\n\t\t\t}\n\t\t} else {\n\t\t\t// The user doesn't have anything set in the \"_managed\" field.\n\t\t\t// Compare emails.\n\t\t\t$user_email = $user->user_email;\n\t\t\t$author_domain = explode('@', $author_email)[1];\n\t\t\t$user_domain = explode('@', $user_email)[1];\n\n\t\t\t// Compare Email Domain Names\n\t\t\tif( $author_domain == $user_domain ) {\n\t\t\t\treturn true;\n\t\t\t} else {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\n\t} else {\n\t\t// User is not Author or Managed. Can not edit.\n\t\treturn false;\n\t}\n\n}", "title": "" }, { "docid": "b8ca78789339b38c2793224bd7512f6b", "score": "0.5897908", "text": "protected static function userIsDoneEditingDraft()\n {\n return (isset($_GET['draftAction']) && $_GET['draftAction'] === 'stopEditing');\n }", "title": "" }, { "docid": "2e3a77227942cac77a167b6535523e50", "score": "0.58762026", "text": "function isViewer($wpUser){\n for($i = 0; $i < count($wpUser->roles); $i++){\n if(strpos($wpUser->roles[$i], SARON_ROLE_PREFIX . SARON_ROLE_VIEWER) !== FALSE){ // CHECK IF THE USER IS A MEMBER OF THE GROUP (test)saron_edit\n return true;\n }\n } \n return false; \n }", "title": "" }, { "docid": "56479c728f0053a3239443158adeb22c", "score": "0.5875972", "text": "protected function creatingNewUser() {\n return ($this->request_exists('user_choice') && $this->request('user_choice') == 'new' );\n }", "title": "" }, { "docid": "cce96cc9fce732515249b04aa28ba14c", "score": "0.5865043", "text": "public function show_add() {\n\t\tif (Auth::instance()->has_permission('add', $this)) {\n\t\t\treturn true;\n\t\t}\n\t}", "title": "" }, { "docid": "19a0ea0e8ddc9e851d7542254258ec27", "score": "0.5861154", "text": "public function isAuthorized($user) {\n\t\treturn true;\n\t /* if ($this->action === 'add') {\n\t\t\treturn true;\n\t\t}\n\n\t\t// The owner of a post can edit and delete it\n\t\tif (in_array($this->action, array('edit', 'delete'))) {\n\t\t\t$postId = (int) $this->request->params['pass'][0];\n\t\t\tif ($this->Post->isOwnedBy($postId, $user['id'])) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn parent::isAuthorized($user);*/\n\t}", "title": "" }, { "docid": "c73e48c939471570899dd4ced6711615", "score": "0.58564365", "text": "public function accessibleByCurrentUser(){\n // return true if AYC user\n if(\\Auth::isSuperAdmin()) return true;\n\n // otherwise check if personally added to this\n $allowedPages = \\Auth::getAllowedPages();\n if(in_array($this->id, $allowedPages)) return true;\n\n // if not specifically added personally to this page\n // check the user group can access this page\n if($this->groupHasPermission(\\Auth::getUserLevel())) return true;\n\n // otherwise return false\n return false;\n\n }", "title": "" }, { "docid": "a5238fe813e145f39ea82fa869333d6b", "score": "0.584952", "text": "protected function handleCreate(User $user)\n {\n if ($user->teamSubscriptions->count() == 0) {\n return false;\n }\n\n foreach ($user->teamSubscriptions as $teamSubscription) {\n if ($teamSubscription->isAdmin() && $this->activeTeam->get()->id == $teamSubscription->team_id) {\n return true;\n }\n }\n\n return false;\n }", "title": "" }, { "docid": "0daefa6a08d91d7b39fcb96d297aeb93", "score": "0.58362", "text": "function osc_is_public_profile() {\n return osc_is_current_page('user', 'pub_profile');\n }", "title": "" }, { "docid": "d198b990625c3f5aab32c3cdb4ae1559", "score": "0.5834468", "text": "public function isPublishedField()\n {\n return $this->get('check_publish') == 1;\n }", "title": "" }, { "docid": "ab48ff3e4a5e8e7eb5910009c9e690a3", "score": "0.58295023", "text": "public function create(User $user)\n {\n $lastReply = $user->fresh()->lastReply;\n\n\t\tif (!$lastReply) return true;\n\t\treturn !$lastReply->wasJustPublished();\n }", "title": "" }, { "docid": "7b3f657f834307a9c0b76719b7ea3b0c", "score": "0.5821866", "text": "public static function isPublic($userId = false)\n {\n $rez = false;\n\n $config = static::getUserConfig($userId);\n if (!empty($config['public_access'])) {\n $rez = true;\n }\n\n return $rez;\n }", "title": "" }, { "docid": "1b73bd8f6aa69bc026516f82452e2246", "score": "0.58151966", "text": "function isUser(){\n\tglobal $USER;\n\tif(isset($USER['_id']) && isNum($USER['_id'])){return true;}\n\treturn false;\n}", "title": "" }, { "docid": "9213086aa5b45340e895061b353ea2e5", "score": "0.58125615", "text": "function local_institutions_can_edit() {\n global $USER;\n\t\n return isloggedin() && !isguestuser() && is_siteadmin($USER->id);\n}", "title": "" }, { "docid": "904d1a5384959366f543b9a9bbbbb352", "score": "0.5801274", "text": "public function user_has_access() {\n\t\treturn current_user_can( 'pvm_delegated_authorship' );\n\t}", "title": "" }, { "docid": "3da98a8de8e9b5d24d7d28ff0628fb06", "score": "0.5801215", "text": "public function isUsable(){\n return ($this->isValid() && $this->isEnabled() && !$this->isDeleted());\n }", "title": "" }, { "docid": "02f97738222cba5b43aaa89b96b81663", "score": "0.58005434", "text": "private function hasValidOwnerForImport() {\n\t\tif (!$this->globalConfiguration->getAsBoolean(\n\t\t\t'onlyImportForRegisteredFrontEndUsers'\n\t\t)) {\n\t\t\treturn TRUE;\n\t\t}\n\n\t\ttry {\n\t\t\t$this->realtyObject->getOwner();\n\t\t} catch (tx_oelib_Exception_NotFound $exception) {\n\t\t\treturn FALSE;\n\t\t}\n\n\t\t$allowedFrontEndUserGroups = $this->globalConfiguration\n\t\t\t->getAsString('allowedFrontEndUserGroups');\n\n\t\t// An empty string is interpreted as any FE user group being allowed.\n\t\t$result = ($allowedFrontEndUserGroups == '')\n\t\t\t|| $this->realtyObject->getOwner()->hasGroupMembership(\n\t\t\t\t$allowedFrontEndUserGroups\n\t\t\t);\n\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "6a5cd11283c8d515a75f777af51966cc", "score": "0.57978463", "text": "public function create(User $user)\n {\n return $user->hasPermissionTo('Add Favourite Collection');\n }", "title": "" }, { "docid": "af6d73d4e7ad1644dba2f3773c7dd8f8", "score": "0.57908976", "text": "function canCreatePost() {\n return ($this->isAdmin() || ($this->userType == 'author'));\n }", "title": "" }, { "docid": "4515d2cfb5ae30c248dad22ae6197c2f", "score": "0.57842296", "text": "public function has() {\n\t\t$userid = $this->get();\n\t\treturn ! empty( $userid );\n\t}", "title": "" }, { "docid": "d82f473d9e631ae489c1883679c08985", "score": "0.57842183", "text": "protected function isCurrentPageEditableByUser() {\n\n\t\t$title = $this->getTitle();\n\t\t$user = $this->getUser();\n\t\treturn $title->quickUserCan( 'edit', $user )\n\t\t\t&& ( $title->exists() || $title->quickUserCan( 'create', $user ) );\n\t}", "title": "" }, { "docid": "8af6f4c7ea49a315a63769f7ae3af539", "score": "0.5783459", "text": "function visible_to_admin_user()\n\t{\n\t\treturn true;\n\t}", "title": "" }, { "docid": "0ec33939cae1a5d524a53db3cfaeda72", "score": "0.57776415", "text": "public function hasUser(): bool;", "title": "" }, { "docid": "61fec8d5e7aea59fd633ba815b8323d4", "score": "0.5775727", "text": "public function userIsMember()\n {\n $session = new SessionManager();\n $userId = $session->get('userId');\n \n if (!empty($userId)) {\n return true;\n }\n\n return false;\n }", "title": "" }, { "docid": "06a168ba8534c6fbb80fe7a0250467dd", "score": "0.5773627", "text": "public function create(User $user)\n {\n return $user->id>0; //aggiungere subscription al canale\n }", "title": "" }, { "docid": "8591812abbe771ba58b71dca2f58df21", "score": "0.57725203", "text": "function check_user() {\n\treturn false; // update allowed\n\treturn true; //no update allowed\n}", "title": "" }, { "docid": "c4464b96289d7bc2000f6ea99b4fb4e3", "score": "0.5771951", "text": "public static function canAddTrans($user, $expence)\n {\n return $user == Expence::find($expence)->user;\n }", "title": "" }, { "docid": "f400941b118a27c42772c712873744bc", "score": "0.5768515", "text": "function isEditor($wpUser){\n for($i = 0; $i < count($wpUser->roles); $i++){\n if(strpos($wpUser->roles[$i], SARON_ROLE_PREFIX . SARON_ROLE_EDITOR) !== FALSE){ // CHECK IF THE USER IS A MEMBER OF THE GROUP (test)saron_edit\n return true;\n }\n } \n return false;\n }", "title": "" }, { "docid": "d5d80f56f582df2fac51de8be1ae2a75", "score": "0.57646", "text": "public function newUsersAllowed(): bool {\n return USER_LIMIT === 0 || $this->getEnabledUsersCount() < USER_LIMIT;\n }", "title": "" }, { "docid": "7bba789ea6bb2d58a7bb49ad53a67540", "score": "0.57599413", "text": "public function authorize()\n {\n return $this->user()->hasPermissionTo('create users');\n }", "title": "" }, { "docid": "dcae1f7f00ad9b53c307f9cf92606229", "score": "0.5748688", "text": "public function hasSignupId(){\n return $this->_has(4);\n }", "title": "" }, { "docid": "0a4bdd313c501bd81d1202efcbca8068", "score": "0.57480204", "text": "public function hasUsers() {\n\t\tif (!is_array($this->deletedUsers)) {\n\t\t\t$this->fetchDeletedUsers();\n\t\t}\n\t\treturn is_array($this->deletedUsers) && (count($this->deletedUsers) > 0);\n\t}", "title": "" }, { "docid": "2ce396c91362896452c350bf98c66856", "score": "0.57469696", "text": "function is_any_parcours_completed() {\n\t\n\t$id_user = get_current_user_id();\n\tglobal $wpdb;\n\t$results = $wpdb->get_results(\"SELECT * FROM parcours_user WHERE id_user = $id_user AND completed = 1\", ARRAY_A);\n\tif(!empty($results)) return true;\t\n\treturn false;\n}", "title": "" }, { "docid": "4c1aaae6278020283dad9aa48086ab7c", "score": "0.57359225", "text": "public function isPublished()\n {\n if(!strcmp($this->getStatus(), 'approved')) {\n return true;\n }\n\n return false;\n }", "title": "" }, { "docid": "1b0eb3d5484c9f67e66da4edcc3b6202", "score": "0.5733265", "text": "public function canPost()\n {\n $role = $this->role;\n if($role == 'author' || $role == 'admin')\n {\n return true;\n } else {\n return false;\n }\n }", "title": "" }, { "docid": "d2ddc25df62ec2ee9fc877de87fd0dee", "score": "0.5732621", "text": "function test_is_user_member_of_blog() {\n\t\t$old_current = get_current_user_id();\n\n\t\t$user_id = self::factory()->user->create( array( 'role' => 'subscriber' ) );\n\t\twp_set_current_user( $user_id );\n\n\t\t$this->assertTrue( is_user_member_of_blog() );\n\t\t$this->assertTrue( is_user_member_of_blog( 0, 0 ) );\n\t\t$this->assertTrue( is_user_member_of_blog( 0, get_current_blog_id() ) );\n\t\t$this->assertTrue( is_user_member_of_blog( $user_id ) );\n\t\t$this->assertTrue( is_user_member_of_blog( $user_id, get_current_blog_id() ) );\n\n\t\t// Will only remove the user from the current site in multisite; this is desired\n\t\t// and will achieve the desired effect with is_user_member_of_blog().\n\t\twp_delete_user( $user_id );\n\n\t\t$this->assertFalse( is_user_member_of_blog( $user_id ) );\n\t\t$this->assertFalse( is_user_member_of_blog( $user_id, get_current_blog_id() ) );\n\n\t\twp_set_current_user( $old_current );\n\t}", "title": "" }, { "docid": "903b201af96280bff3374bf25b0455d0", "score": "0.5729742", "text": "function test_is_user_member_of_blog() {\n\t\t$old_current = get_current_user_id();\n\n\t\t$user_id = $this->factory->user->create( array( 'role' => 'subscriber' ) );\n\t\twp_set_current_user( $user_id );\n\n\t\t$this->assertTrue( is_user_member_of_blog() );\n\t\t$this->assertTrue( is_user_member_of_blog( 0, 0 ) );\n\t\t$this->assertTrue( is_user_member_of_blog( 0, get_current_blog_id() ) );\n\t\t$this->assertTrue( is_user_member_of_blog( $user_id ) );\n\t\t$this->assertTrue( is_user_member_of_blog( $user_id, get_current_blog_id() ) );\n\n\t\t// Will only remove the user from the current site in multisite; this is desired\n\t\t// and will achieve the desired effect with is_user_member_of_blog().\n\t\twp_delete_user( $user_id );\n\n\t\t$this->assertFalse( is_user_member_of_blog( $user_id ) );\n\t\t$this->assertFalse( is_user_member_of_blog( $user_id, get_current_blog_id() ) );\n\n\t\twp_set_current_user( $old_current );\n\t}", "title": "" }, { "docid": "cf52ab74cf573c435e15ebf578b8da9d", "score": "0.57279086", "text": "static function user_has_added_user($user1, $user2) {\n global $con;\n $sql = \"SELECT COUNT(`id`) AS 'count' \n FROM `relationship` \n WHERE `user1` = \".$user1.\" AND `user2` = \".$user2.\" AND `relationship`.`type` = 1;\";\n $query = mysqli_query($con, $sql);\n return (mysqli_fetch_object($query)->count == 1);\n }", "title": "" }, { "docid": "b21d53e0e94705d4ec33ccb97faf2881", "score": "0.571388", "text": "public function hasAccess()\n\t{\n\t\t/* Check Permissions */\n\t\treturn \\IPS\\Member::loggedIn()->hasAcpRestriction( \"core\",\"members\" );\n\t}", "title": "" }, { "docid": "733c8035f8fa863d2b4dab96e924ad64", "score": "0.5713623", "text": "function userCanCreateUser( $sessionID ) {\r\n\t\treturn $this->getAccessLevel() > 9;\r\n\t}", "title": "" }, { "docid": "b8cacf28c4145c97df4897f0721cf05a", "score": "0.57088166", "text": "protected function userIsEditingPublicDraft($requestURI)\n {\n if (self::userIsSavingPublicDraft() && isset($_POST['filePath'])) {\n // user is trying to save the draft. We know that the specified file gets sent as well, so let's see if this file is representing public draft\n $requestURI = $_POST['filePath'];\n }\n\n if (strpos($requestURI, '?') !== false) {\n // we need to break the requestURI up\n $parts = parse_url($requestURI);\n if (isset($parts['path'])) {\n // we only need the path as we aren't doing anything with query params here.\n $requestURI = $parts['path'];\n }\n }\n $requestURI = rawurldecode($requestURI);\n\n $editDraftUrl = $this->buildUrl('editDraft', ['draftName' => self::guessDraftName($requestURI)]);\n\n if (strpos($requestURI, $editDraftUrl) !== false) {\n return true;\n } else if (self::userIsEditingDraft()) {\n // we need to do some extra checks to see if the user is viewing a public draft.\n $draftName = self::getDraftFromRequest();\n\n if (empty($draftName)) {\n return false;\n }\n\n $fm = new FileManager($this->getLoggedInUsername(), $requestURI, null, $this->getDB());\n $draft = $fm->getDraft($draftName);\n\n return ($draft && $draft['type'] === Config::PUBLIC_DRAFT);\n }\n return false;\n }", "title": "" }, { "docid": "11711284ddbba43f2b631eb0e9a55c98", "score": "0.57083106", "text": "public function isAuthorizedTransferWallet($user) {\n if ($this->action === 'add') {\n return true;\n }\n\n // The owner of a post can edit and delete it\n if (in_array($this->action, array('edit', 'delete'))) {\n $postId = (int) $this->request->params['pass'][0];\n if ($this->TransferWallet->isOwnedBy($postId, $user['id'])) {\n return true;\n }\n }\n\n return parent::isAuthorized($user);\n }", "title": "" }, { "docid": "1ddd2181ab23d0d594ccf33566b27c4c", "score": "0.57031775", "text": "public function user_is_editing() {\n global $USER;\n return !empty($USER->editing) && $this->user_allowed_editing();\n }", "title": "" }, { "docid": "625cbc08cd466b2dfe8736097ec13402", "score": "0.5703065", "text": "public function create(User $user)\n {\n return $user->id > 0;\n }", "title": "" }, { "docid": "5e823d904290588e83996a6af80d54d5", "score": "0.5700182", "text": "function capitalp_is_public_capitalist( $user_id ) {\n\treturn ! get_user_meta( $user_id, 'hidden_capitalist', true );\n}", "title": "" }, { "docid": "00804957b39ebfb7ee71ae2a86491a65", "score": "0.56985754", "text": "function canWriteToFeed($userid, $recipientid)\n{\n\tif($result = mysql_query(\"SELECT COUNT(*) FROM access WHERE reader = '$userid' AND writer = '$recipientid';\")) {\n\t\t//echo $result;\n\t\t$number = mysql_fetch_array($result, MYSQL_NUM);\n\n\t\tif($number[0] > 0) {\n\t\t\treturn true;\n\t\t}\n\t}\n\n\treturn false;\n}", "title": "" }, { "docid": "41fa84437f7067454aeaffa011080d4e", "score": "0.5694041", "text": "function user_has_unpublished_repo_access($user_id,$repositoryid)\n\t{\n\t\tif($user_id==NULL)\n\t\t{\n\t\t\t$user=$this->current_user();\n\t\t\t\n\t\t\tif (!$user)\n\t\t\t{\n\t\t\t\treturn FALSE;\n\t\t\t}\n\t\t\t\n\t\t\t$user_id=$user->id;\n\t\t}\n\n\t\t$unlimited=$this->user_has_unlimited_access();\n\t\t\n\t\tif ($unlimited)\n\t\t{\n\t\t\treturn TRUE;\n\t\t}\n\t\t\n\t\t//validate if user has access to the selected repository\n\t\t$user_repositories=$this->get_user_repositories();\n\t\t\n\t\tforeach($user_repositories as $repo)\n\t\t{\n\t\t\tif ($repo[\"repositoryid\"]==$repositoryid)\n\t\t\t{\n\t\t\t\treturn TRUE;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn FALSE;\n\t}", "title": "" }, { "docid": "f9cf043f0bc889de32ebdbcda45dfbaf", "score": "0.56935173", "text": "public function hasUserId(){\n return $this->_has(2);\n }", "title": "" }, { "docid": "f9cf043f0bc889de32ebdbcda45dfbaf", "score": "0.56935173", "text": "public function hasUserId(){\n return $this->_has(2);\n }", "title": "" }, { "docid": "f9cf043f0bc889de32ebdbcda45dfbaf", "score": "0.56935173", "text": "public function hasUserId(){\n return $this->_has(2);\n }", "title": "" }, { "docid": "f9cf043f0bc889de32ebdbcda45dfbaf", "score": "0.56935173", "text": "public function hasUserId(){\n return $this->_has(2);\n }", "title": "" }, { "docid": "f9cf043f0bc889de32ebdbcda45dfbaf", "score": "0.56935173", "text": "public function hasUserId(){\n return $this->_has(2);\n }", "title": "" }, { "docid": "886fcafe79ac1110df05a3598cb992f5", "score": "0.568828", "text": "function canEdit() {\r\n\t\tif($this->owner->ID == Member::currentUserID())\r\n\t\t\treturn true;\r\n\r\n\t\t$member = Member::currentUser();\r\n\t\tif($member)\r\n\t\t\treturn $member->isAdmin();\r\n\r\n\t\treturn false;\r\n\t}", "title": "" }, { "docid": "eaaa66cdedd8f9719104a80cf82dadfa", "score": "0.56862545", "text": "public function isOwned()\n {\n if (!Auth::check()) {\n return false;\n }\n\n if (Auth::id() !== $this->getOwnerId()) {\n return false;\n }\n\n return true;\n }", "title": "" }, { "docid": "b778c059d6c8d2d4894a72b47357b072", "score": "0.5683188", "text": "function isOrgEditor($wpUser){\n for($i = 0; $i < count($wpUser->roles); $i++){\n if(strpos($wpUser->roles[$i], SARON_ROLE_PREFIX . SARON_ROLE_ORG) !== FALSE){ // CHECK IF THE USER IS A MEMBER OF THE GROUP (test)saron_edit\n return true;\n }\n } \n return false; \n }", "title": "" }, { "docid": "b0e41740977285c58bd02ee6e04941c7", "score": "0.5680931", "text": "public function canUserAssignUsage()\n {\n $user = $this->getUser();\n\n return $user->isAdmin || \\in_array('tl_news::usage', $user->alexf, true);\n }", "title": "" }, { "docid": "b46bfb4fa090fa130e4ccc60eb4ef862", "score": "0.56788325", "text": "public function create(User $user)\n {\n return $user->id > 0;\n }", "title": "" }, { "docid": "fbb90ea927fa35e382dcd0d3055609fa", "score": "0.5678016", "text": "function get_users_drafts($user_id)\n {\n }", "title": "" }, { "docid": "4c7b518c6961ad0d6df47d913682b0d9", "score": "0.56771815", "text": "public function userHasCreatePermission(){\n//\t\tif(\\GO\\Base\\Model\\Acl::hasPermission($this->getPermissionLevel(),\\GO\\Base\\Model\\Acl::CREATE_PERMISSION)){\n//\t\t\treturn true;\n//\t\t}else \n\t\tif(\\GO::modules()->isInstalled('freebusypermissions')){\n\t\t\treturn \\GO\\Freebusypermissions\\FreebusypermissionsModule::hasFreebusyAccess(\\GO::user()->id, $this->user_id);\n\t\t} else {\n\t\t\treturn true;\n\t\t}\n\t}", "title": "" }, { "docid": "09f504335878cb0e4d8f0e28a6d8cebf", "score": "0.56761605", "text": "private function isActived(){\n $user = $this->getUser();\n return $user->activedMe ? true : false;\n }", "title": "" }, { "docid": "afaa4b82c39add296f90336aec1abdb2", "score": "0.56748503", "text": "public function isSetUserId()\n {\n return count ($this->_fields['UserId']['FieldValue']) > 0;\n }", "title": "" }, { "docid": "db52027b58cf4858f44e1af54e5c0d2b", "score": "0.56676996", "text": "function canCreate(){\n\t\t\tif(!isset($_POST['action'])) return false;\n\t\t\tif($_POST['action'] !== 'create_profile') return false;\n\t\t\tif($_POST['profile_folder'] === '') return false;\n\t\t\tif($_POST['profile_name'] === '') return false;\n\t\t\treturn true;\n\t\t}", "title": "" }, { "docid": "c129c5089ba61b61dc60f018178a1b93", "score": "0.5663851", "text": "public function getHasEmailedResults() {\n\t\t$submission = $this->getSubmission();\n\t\tif ($submission && $submission->exists() && $submission->UserEmail !== null) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}", "title": "" }, { "docid": "4fb5fe636453c65da34b9c0491992d1f", "score": "0.5660034", "text": "public function add(User $user): bool {\n if ($user->is_super_admin) {\n return true;\n }else if ($user->tokenCan(['add-registrations-dev', 'add-registrations-stage', 'add-registrations-prod'])) {\n return true;\n }else {\n return false;\n }\n }", "title": "" }, { "docid": "780d7997c348e948424c7a28eb64d4d2", "score": "0.5659207", "text": "public function authorize()\n {\n $accessor = $this->user();\n $user = $this->route('user');\n\n return $accessor->isAdmin() || \n ($accessor->isCommittee() && $accessor->hasKey('put-users')) || \n ($accessor->isEntrant() && $accessor->entry->id === $user->entry_id) || \n $accessor->id === $user->id;\n }", "title": "" }, { "docid": "3970d029c6dc58f60f2dcaf6b1717698", "score": "0.5657123", "text": "private function wf_user_permission(){\n\t\t$current_user = wp_get_current_user();\n\t\t$user_ok = false;\n\t\tif ($current_user instanceof WP_User) {\n\t\t\tif (in_array('administrator', $current_user->roles) || in_array('shop_manager', $current_user->roles)) {\n\t\t\t\t$user_ok = true;\n\t\t\t}\n\t\t}\n\t\treturn $user_ok;\n\t}", "title": "" }, { "docid": "f8f827f11d2960c447ce19441d58fec5", "score": "0.5654082", "text": "public function is_watched_by_auth_user() {\n $id = Auth::id();\n\n\n $watcher_user_ids = [];\n\n foreach($this->watchers as $watcher) {\n\n //ja polnime nizata so user_id-s od konkretniot watcher\n $watcher_user_ids[] = $watcher->user_id;\n\n }\n\n // go sporeduvame sekoj user_id od watchers so id-to na logiraniot user\n if(in_array($id, $watcher_user_ids)){\n\n return true;\n }else{\n\n return false;\n }\n\n\n }", "title": "" }, { "docid": "b0e5b7d6e0e47bc40cacc31eb56dceb0", "score": "0.5648897", "text": "protected function userIsViewingPublicDraft($requestURI)\n {\n if (strpos($requestURI, '?') !== false) {\n // we need to break the requestURI up\n $parts = parse_url($requestURI);\n if (isset($parts['path'])) {\n // we only need the path as we aren'd doing anything with query params here.\n $requestURI = $parts['path'];\n }\n }\n\n $viewPublicDraftUrl = $this->buildUrl('drafts', ['draft' => basename($requestURI)]);\n\n if (strpos($requestURI, $viewPublicDraftUrl) !== false) {\n // user is viewing a public draft from concert root\n return true;\n } else if (self::userIsViewingDraft()) {\n // we need to do some extra checks to see if the user is viewing a public draft.\n $draftName = self::getDraftFromRequest();\n\n if (empty($draftName)) {\n return false;\n }\n\n $fm = new FileManager($this->getLoggedInUsername(), $requestURI, null, $this->getDB());\n $draft = $fm->getDraft($draftName);\n\n return ($draft && $draft['type'] === Config::PUBLIC_DRAFT);\n }\n return false;\n }", "title": "" }, { "docid": "31b7e48659be9ba40b5fa485a03b301b", "score": "0.5648279", "text": "function uservalidationbyadmin_allow_new_user_can_edit($hook, $type, $value, $params) {\n\t// $params['user'] is the user to check permissions for.\n\t// we want the entity to check, which is a user.\n\t$user = elgg_extract('entity', $params);\n\n\tif (!($user instanceof ElggUser)) {\n\t\treturn;\n\t}\n\n\t$context = elgg_get_context();\n\tif ($context == 'uservalidationbyadmin_new_user' || $context == 'uservalidationbyadmin_validate_user') {\n\t\treturn TRUE;\n\t}\n\n\treturn;\n}", "title": "" }, { "docid": "481601b7625bd252e760656cccaef07c", "score": "0.56474835", "text": "public function isAuthorized($user) {\n \tif ($this->action === 'add') {\n\t return true;\n \t}\n \t// The owner of a pedido can edit and delete it\n \tif (in_array($this->action, array('edit', 'delete'))) {\n \t$pedidoId = $this->request->params['pass'][0];\n \tif ($this->Pedido->isOwnedBy($pedidoId, $user['id'])) {\n \treturn true;\n \t}\n \t}\n\t\treturn parent::isAuthorized($user);\n\t}", "title": "" }, { "docid": "bdc2720f814592af1efdcd440d950513", "score": "0.56463337", "text": "function is_admin() {\n\treturn (isset($_SESSION['user_id']) && ($_SESSION['user_id'] == 1 || $_SESSION['user_id'] == 2));\n}", "title": "" }, { "docid": "088781ba596ba6452122a36b3d6dde8e", "score": "0.5637207", "text": "protected function checkPermissions()\n\t{\n\t\treturn ($this->user->id==$this->post->user_id);\n\t}", "title": "" } ]
ea78ca5fcc5cbd2a6703db7c0b093e4d
Gets the application environment $config=[ 'env'=>'dev', ...
[ { "docid": "c6e8c1d39ed1b25a2a1dd02bd0d10970", "score": "0.8018153", "text": "public static function getEnvironment()\n {\n global $config;\n return App::getConfig('env', $config);\n }", "title": "" } ]
[ { "docid": "0b201d83fedd2b20bd4bbc4d7bd5a4ae", "score": "0.808693", "text": "public static function GetConfigEnvironment ();", "title": "" }, { "docid": "15b5a63e4a56c84d89cf9e304b596153", "score": "0.7427339", "text": "function app_env(): string\n {\n return app()->environment();\n }", "title": "" }, { "docid": "464d0ab9839a3d816ac3592301825976", "score": "0.7369161", "text": "function app_env(): string\n{\n return Springy\\Core\\Configuration::getInstance()->getEnvironment();\n}", "title": "" }, { "docid": "61e15f317fcdc83b93b323b61fe4e39c", "score": "0.73282456", "text": "public function getEnvironment()\n {\n return Zend_Registry::get('configGlobal')->get('environment', 'production');\n }", "title": "" }, { "docid": "82281e26cdc934ac5278bcfae4773b17", "score": "0.7220539", "text": "private function getConfigForEnvironment()\n {\n return isset($this->environmentConfigurations[$this->environment])\n ? $this->environmentConfigurations[$this->environment]\n : null;\n }", "title": "" }, { "docid": "d47d9267c2dac42e7d3cfdfa12ff526c", "score": "0.7220077", "text": "public static function environment(): string\n {\n return self::$configurations[self::APP_ENV];\n }", "title": "" }, { "docid": "f5794f9acdc9076116aa42a86e682e86", "score": "0.72080934", "text": "public function get_env()\n {\n $options = get_option('transact-settings');\n return $options['environment'];\n }", "title": "" }, { "docid": "d7309167352482ecd21e859b761422f5", "score": "0.7112206", "text": "public static function getEnv()\n\t{\n\t\treturn static::getConfig()->getClass(\"env\");\n\t}", "title": "" }, { "docid": "22b9618a548b8a9bec563d136414524a", "score": "0.70689124", "text": "protected function getEnvironmentConfiguration()\n {\n $config = [];\n\n $environment = env('APP_ENV');\n\n if ($environment && file_exists($configPath = base_path().'/config/'.$environment.'/environment.php')) {\n try {\n $config = require $configPath;\n }\n catch (Exception $ex) {\n //\n }\n }\n elseif (file_exists($configPath = base_path().'/config/environment.php')) {\n try {\n $config = require $configPath;\n }\n catch (Exception $ex) {\n //\n }\n }\n\n return $config;\n }", "title": "" }, { "docid": "334633de64606489ddd8eaed21d985db", "score": "0.70561576", "text": "function getConfig($name) {\n $val = getenv($name);\n // look for the config var defined in config.php\n if(!$val && isset($GLOBALS[$name])) {\n $val = $GLOBALS[$name];\n }\n // check that it exists\n if(!$val) {\n echo \"env var $name is required ($val)\";\n die();\n }\n return $val;\n}", "title": "" }, { "docid": "9c95047d4e0e9e76436163dd203c3c3e", "score": "0.69754267", "text": "public static function loadEnvironmentConfig()\n {\n global $config;\n $env = strtolower(App::getEnvironment());\n //C:\\xampp\\htdocs\\myframework\\app\\environment\\dev\\congfig.php\n require_once App::getBasePath() . '\\\\app\\\\environment\\\\' . $env . '\\\\config\\environment.properties';\n App::$_config = array_merge($config, $environment);\n }", "title": "" }, { "docid": "3a973caaad29a35c1fe9865437b195bb", "score": "0.69668406", "text": "private static function getAppEnv() {\n if (isset($_SERVER ['SHELL'])) {\n return 'shell';\n }\n\n return 'production';\n }", "title": "" }, { "docid": "ce42263a166904d37ee9e1eb3b3762e4", "score": "0.6941349", "text": "protected function _getEnvironment()\n {\n $environment = self::$forceEnvironment;\n\n // Check if the environment has been manually set (forced).\n if ($environment !== null) {\n if (!isset($this->_environments[$environment])) {\n throw new Exception('Environment configuration for \"' . $environment . '\" could not be found.');\n }\n }\n // If no manual setting is available, use \"host:port\" to decide which config to use.\n if ($environment === null && !empty($_SERVER['HTTP_HOST'])) {\n $host = (string)$_SERVER['HTTP_HOST'];\n foreach ($this->_environments as $env => $envConfig) {\n if (isset($envConfig['domain']) && in_array($host, $envConfig['domain'])) {\n $environment = $env;\n break;\n }\n }\n }\n // If there is no host:port match, try \"host\" only.\n if ($environment === null && !empty($_SERVER['SERVER_NAME'])) {\n $host = (string)$_SERVER['SERVER_NAME'];\n foreach ($this->_environments as $env => $envConfig) {\n if (isset($envConfig['domain']) && in_array($host, $envConfig['domain'])) {\n $environment = $env;\n break;\n }\n }\n }\n // If no host matched then try to use the APP path.\n if ($environment === null && ($serverPath = $this->_getRealAppPath())) {\n foreach ($this->_environments as $env => $envConfig) {\n if (isset($envConfig['path']) && in_array($serverPath, $envConfig['path'])) {\n $environment = $env;\n break;\n }\n }\n }\n // No environment could be identified -> we are on a dev machine.\n if (!$environment) {\n $environment = 'local';\n }\n\n return $environment;\n }", "title": "" }, { "docid": "4cfe91dfefc1e1e3d64b09cfe91a9a60", "score": "0.69234014", "text": "public function getEnvironment();", "title": "" }, { "docid": "4cfe91dfefc1e1e3d64b09cfe91a9a60", "score": "0.69234014", "text": "public function getEnvironment();", "title": "" }, { "docid": "4cfe91dfefc1e1e3d64b09cfe91a9a60", "score": "0.69234014", "text": "public function getEnvironment();", "title": "" }, { "docid": "53352ae56e95ed8d753948ca704df9c4", "score": "0.69212055", "text": "static public function readEnviroment(){\n\t\t$application = Router::getApplication();\n\t\t$config = self::getConfigurationFrom($application, 'environment.ini');\n\t\t$core = self::getConfigurationFrom($application, 'config.ini');\n\t\tif(!isset($core->application->mode)){\n\t\t\t/**\n\t\t\t * No se ha definido el entorno por defecto\n\t\t\t */\n\t\t\t$message = CoreLocale::getErrorMessage(-12);\n\t\t\tthrow new CoreConfigException($message, -12);\n\t\t}\n\t\t//Carga las variables db del modo indicado\n\t\t$mode = $core->application->mode;\n\t\tif(isset($config->$mode)){\n\t\t\tforeach($config->$mode as $conf => $value){\n\t\t\t\tif(preg_match('/([a-z0-9A-Z]+)\\.([a-z0-9A-Z]+)/', $conf, $registers)){\n\t\t\t\t\tif(!isset($config->{$registers[1]})){\n\t\t\t\t\t\t$config->{$registers[1]} = new stdClass();\n\t\t\t\t\t}\n\t\t\t\t\t$config->{$registers[1]}->{$registers[2]} = $value;\n\t\t\t\t} else {\n\t\t\t\t\t$config->$conf = $value;\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\t/**\n\t\t\t * No existe el entorno en environment.ini\n\t\t\t */\n\t\t\t$message = CoreLocale::getErrorMessage(-13, $mode);\n\t\t\tthrow new CoreConfigException($message, -13);\n\t\t}\n\n\t\t//Carga las variables de la seccion [project]\n\t\tif(isset($config->project)){\n\t\t\tforeach($config->project as $conf => $value){\n\t\t\t\tif(preg_match(\"/([a-z0-9A-Z]+)\\.([a-z0-9A-Z]+)/\", $conf, $registers)){\n\t\t\t\t\tif(!isset($config->{$registers[1]})){\n\t\t\t\t\t\t$config->{$registers[1]} = new stdClass();\n\t\t\t\t\t}\n\t\t\t\t\t$config->{$registers[1]}->{$registers[2]} = $value;\n\t\t\t\t} else {\n\t\t\t\t\t$config->$conf = $value;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $config;\n\t}", "title": "" }, { "docid": "d0b695caf9f5d8f1f95386c130f55c3b", "score": "0.6909909", "text": "public static function environment(){\n\t\treturn \\Illuminate\\Foundation\\Application::environment();\n\t}", "title": "" }, { "docid": "f68ace013d1244e7fb3889f3b7c96da1", "score": "0.69081324", "text": "public function environment()\n {\n return $this->config->get('broadcasting.connections.apn.environment');\n }", "title": "" }, { "docid": "b0509d6c1fffa34686c884ab0750799e", "score": "0.687153", "text": "public function getEnvironment($environment);", "title": "" }, { "docid": "3f93d8a30b06f40ad7bd34c4dc7d7ad8", "score": "0.6863657", "text": "protected function config()\n {\n return $this->app['config'];\n }", "title": "" }, { "docid": "f402813a77d86c34e16b1458c00992c1", "score": "0.68145365", "text": "public function env()\n {\n return $this->env;\n }", "title": "" }, { "docid": "b571f5a84ea4cbb5dabe3cb1edbe75fc", "score": "0.6802963", "text": "public function getEnvironment()\n {\n return C::App()->getEnvironment();\n }", "title": "" }, { "docid": "a1ee10c855a2faa2b9d8de61181081b4", "score": "0.6759911", "text": "public function GetEnvironment();", "title": "" }, { "docid": "60bf3ff504a7af59c1791743a0c2dba2", "score": "0.6710107", "text": "public static function GetConfigEnvironmentPath ();", "title": "" }, { "docid": "8c5875c225ddef37a34d3aef5887726b", "score": "0.6684523", "text": "public function getEnvironment()\n {\n return $this->getMethodValue(self::KEY_ENVIRONMENT);\n }", "title": "" }, { "docid": "92d08f94b39f11d440f388d0b41715e2", "score": "0.66690487", "text": "private static function config() {\n return nil::get(Configuration::getValue('app'), array());\n }", "title": "" }, { "docid": "83bf44e620e6f59e193261b01a6ca6d7", "score": "0.66600424", "text": "public function getEnvironment() {\r\n return (string) $this->getValue(self::KEY_ENVIRONMENT);\r\n }", "title": "" }, { "docid": "a8d40a009f494cffc70f28e86a1df06e", "score": "0.66594625", "text": "public function getEnvironment() {\n \n if (REQUEST_TYPE !== 'web') {\n return REQUEST_TYPE;\n }\n \n $hostname = isset($_SERVER['HTTP_HOST']) ? $_SERVER['HTTP_HOST'] : 'localhost';\n \n if (preg_match('/^localhost$/', $hostname) !== 0) {\n return 'development'; \n } else if (preg_match('/(.*)koolvps\\.nl$/', $hostname) !== 0) {\n return 'staging';\n } else {\n return 'production';\n }\n \n \n \n }", "title": "" }, { "docid": "c47460eb814fb82a440b34652d7cf452", "score": "0.6655877", "text": "public function environment(): string;", "title": "" }, { "docid": "44f877752a4924868348ecb034643c65", "score": "0.6639908", "text": "public static function environment()\n {\n $clientId = config('paypal.client');\n $clientSecret = config('paypal.secret');\n if (config('paypal.settings.mode') == 'sandbox') {\n return new SandboxEnvironment($clientId, $clientSecret);\n }\n\n if (config('paypal.settings.mode') == 'production') {\n return new ProductionEnvironment($clientId, $clientSecret);\n }\n\n }", "title": "" }, { "docid": "e28494714f1fdd9377ea7100174d52bb", "score": "0.66303855", "text": "public function getEnvironment(): string\n {\n return $this->environment;\n }", "title": "" }, { "docid": "c0c2186a1bbb33e6c4a319f36029c34f", "score": "0.66276443", "text": "public function environment():string;", "title": "" }, { "docid": "0b8dcf773ca56bea0ad27edd19424367", "score": "0.66084975", "text": "public static function getEnvironment() {\n return self::$environment;\n }", "title": "" }, { "docid": "9290c5d24ee2a1d1a58e8d53fd78c2d0", "score": "0.66064626", "text": "public function getEnv()\n {\n return $this->env;\n }", "title": "" }, { "docid": "9bccbf610d2b39958d1bde823a3111ba", "score": "0.6592182", "text": "public function getPlatformEnvironment()\n {\n return $this->wrapper->request(self::GET_METHOD, 'environment');\n }", "title": "" }, { "docid": "8b22c6f63806fd879471f15b107be7af", "score": "0.65809464", "text": "public static function & GetEnvironmentDetectionData (\\MvcCore\\IConfig $config);", "title": "" }, { "docid": "ebab9df264292715eb8164320e353d3c", "score": "0.65736336", "text": "public function getGlobalConfig();", "title": "" }, { "docid": "5551a62e052e00cb92b0aadb90e84b30", "score": "0.6571339", "text": "public function getEnvironment()\n\t{\n\t\treturn $this->endpointEnv;\n\t}", "title": "" }, { "docid": "358439d0918cd48a329a99b8e21609e0", "score": "0.65641546", "text": "function env($name){\n return getenv($name);\n}", "title": "" }, { "docid": "37ec4cc40e88084bf0ca15a92b261e4e", "score": "0.6561689", "text": "function getAppEnv()\n{\n static $env = [\n 'jig_compilecheck' => 'COMPILE_CHECK_MTIME',\n 'caching_setting' => 'caching.revalidate',\n 'script_packing' => false,\n ];\n\n return $env;\n}", "title": "" }, { "docid": "02cbf7a1ede5aa0f32708b242b75c2d3", "score": "0.6550912", "text": "public static function getEnvironment()\n {\n if (static::$environment === null) {\n static::$environment = getenv('SYMFONY_ENV');\n\n /* SYMFONY_ENV is not defined. This means execution skipped .htaccess file */\n if (!static::$environment) {\n /* All right, let's steal the environment from .htaccess */\n $htaccessFile = EDIRECTORY_ROOT.DIRECTORY_SEPARATOR.\".htaccess\";\n\n if (file_exists($htaccessFile)) {\n $htaccessFileContent = file_get_contents($htaccessFile);\n\n $matches = [];\n preg_match(\"/(?<=setEnv SYMFONY\\\\_ENV \\\\')\\\\w+(?=\\\\')/\", $htaccessFileContent, $matches);\n\n /* Got it */\n $matches and static::$environment = array_pop($matches);\n } else {\n /* When all else fails, we'll take the safe bet */\n static::$environment = \"prod\";\n }\n }\n }\n\n return static::$environment;\n }", "title": "" }, { "docid": "7f95e0f4492adac473f9a7b532cbd953", "score": "0.65347505", "text": "public static function getConfig()\n {\n return self::$di->getShared('config');\n }", "title": "" }, { "docid": "09e8b2b6420f709ee2a49dd9e74bff04", "score": "0.6525734", "text": "public function getEnv() {\n\t\treturn $this->env;\n\t}", "title": "" }, { "docid": "a245d97d17d6fb3d73fc70f7fe5b4396", "score": "0.65256584", "text": "public function get_environment() {\n\t\tif ( isset( $this->environment ) ) {\n\t\t\treturn $this->environment;\n\t\t}\n\t\t$this->environment = ! empty( $_ENV['PANTHEON_ENVIRONMENT'] ) ? $_ENV['PANTHEON_ENVIRONMENT'] : '';\n\t\treturn $this->environment;\n\t}", "title": "" }, { "docid": "514fdcc47d7056d14c42b026c898964f", "score": "0.65231586", "text": "public static function environment()\n {\n $mode = config('paypal.mode');\n $clientId = null;\n $clientSecret = null;\n if ($mode == 'sandbox') {\n $clientId = config('paypal.sandbox_client_id');\n $clientSecret = config('paypal.sandbox_client_secret');\n return new SandboxEnvironment($clientId, $clientSecret);\n } elseif ($mode == 'live') {\n $clientId = config('paypal.live_client_id');\n $clientSecret = config('paypal.live_client_secret');\n return new ProductionEnvironment($clientId, $clientSecret);\n } else {\n $clientId = config('paypal.live_client_id');\n $clientSecret = config('paypal.live_client_secret');\n return new ProductionEnvironment($clientId, $clientSecret);\n }\n }", "title": "" }, { "docid": "e778ad38e8d335162c0ac8762b212617", "score": "0.6495565", "text": "public static function getEnvironments() {\n return [\n 'prod' => [\n 'baseUrl' => 'http://acesso.evolutto.com.br',\n 'script' => '/'\n ],\n 'teste3' => [\n 'baseUrl' => 'http://teste3.templum.com.br',\n 'script' => '/'\n ],\n 'dev' => [\n 'baseUrl' => 'http://templum.dev',\n 'script' => '/app_vagrant.php'\n ],\n ];\n }", "title": "" }, { "docid": "86be40780835056c0a55d190577def9c", "score": "0.6487954", "text": "public function app(){\n\n return $this->config['app'];\n\n }", "title": "" }, { "docid": "f688d9230d0700bb6ebe9a7fdb067fed", "score": "0.6390672", "text": "public function getEnvironment()\n {\n return $this->environment;\n }", "title": "" }, { "docid": "f688d9230d0700bb6ebe9a7fdb067fed", "score": "0.6390672", "text": "public function getEnvironment()\n {\n return $this->environment;\n }", "title": "" }, { "docid": "f688d9230d0700bb6ebe9a7fdb067fed", "score": "0.6390672", "text": "public function getEnvironment()\n {\n return $this->environment;\n }", "title": "" }, { "docid": "f688d9230d0700bb6ebe9a7fdb067fed", "score": "0.6390672", "text": "public function getEnvironment()\n {\n return $this->environment;\n }", "title": "" }, { "docid": "f688d9230d0700bb6ebe9a7fdb067fed", "score": "0.6390672", "text": "public function getEnvironment()\n {\n return $this->environment;\n }", "title": "" }, { "docid": "f688d9230d0700bb6ebe9a7fdb067fed", "score": "0.6390672", "text": "public function getEnvironment()\n {\n return $this->environment;\n }", "title": "" }, { "docid": "f688d9230d0700bb6ebe9a7fdb067fed", "score": "0.6390672", "text": "public function getEnvironment()\n {\n return $this->environment;\n }", "title": "" }, { "docid": "f688d9230d0700bb6ebe9a7fdb067fed", "score": "0.6390672", "text": "public function getEnvironment()\n {\n return $this->environment;\n }", "title": "" }, { "docid": "cd8bbd50f9b245d00008b770e93f3915", "score": "0.6368768", "text": "public function getEnv() { return $this->_env; }", "title": "" }, { "docid": "88036d2d3b38154d8ff418b57d7d58db", "score": "0.6356456", "text": "public function getConfig();", "title": "" }, { "docid": "88036d2d3b38154d8ff418b57d7d58db", "score": "0.6356456", "text": "public function getConfig();", "title": "" }, { "docid": "88036d2d3b38154d8ff418b57d7d58db", "score": "0.6356456", "text": "public function getConfig();", "title": "" }, { "docid": "88036d2d3b38154d8ff418b57d7d58db", "score": "0.6356456", "text": "public function getConfig();", "title": "" }, { "docid": "0e477280b84382be6061445ef74fdc8f", "score": "0.63379", "text": "static public function getConfig()\n {\n if(file_exists(__DIR__.'/config/local.php')){\n return include __DIR__.'/config/local.php';\n }\n return include __DIR__.'/config/global.php';\n }", "title": "" }, { "docid": "710f9227971fcc2770d1fa5df615a1ec", "score": "0.6327693", "text": "public static function config()\n {\n return self::$config;\n }", "title": "" }, { "docid": "9846f604a90855e120cc947ac639aff3", "score": "0.6326945", "text": "protected function readConfigFromEnv() {\n $config = [];\n\n // Site.\n $config['site']['title'] = getenv('SITE_TITLE');\n $config['site']['mail'] = getenv('SITE_MAIL');\n $config['site']['admin_email'] = getenv('SITE_ADMIN_EMAIL');\n $config['site']['admin_user'] = getenv('SITE_ADMIN_USERNAME');\n $config['site']['admin_password'] = getenv('SITE_ADMIN_PASSWORD');\n\n // Environment.\n $config['environment']['hash_salt'] = getenv('HASH_SALT');\n\n // Clean up NULL values and empty arrays.\n $array_clean = function (&$item) use (&$array_clean) {\n foreach ($item as $key => $value) {\n if (is_array($value)) {\n $array_clean($item[$key]);\n }\n if (empty($item[$key]) && $value !== '0') {\n unset($item[$key]);\n }\n }\n };\n\n $array_clean($config);\n\n return $config;\n }", "title": "" }, { "docid": "744183d3f365f5727274d60ee4cff27e", "score": "0.63212204", "text": "private function getConfig()\n {\n $config = [\n 'host' => Env::get('CACHE_HOST') ?: 'localhost',\n 'port' => Env::get('CACHE_PORT') ?: 11211\n ];\n\n return $config;\n }", "title": "" }, { "docid": "16ee343b3795cf013ac33b41e0d85e85", "score": "0.6314771", "text": "function dotenv( $config = null ) {\n\t\tstatic $dotenv;\n\n\t\tif ( ! is_null( $config ) ) {\n\t\t\t$dotenv = Dotenv\\Dotenv::create( $config );\n\t\t}\n\n\t\tif ( ! $dotenv ) {\n\t\t\tthrow new \\Exception( \"dotenv() helper is not initialized. Call dotenv('path to .env') first.\" );\n\t\t}\n\n\t\treturn $dotenv;\n\t}", "title": "" }, { "docid": "47e552aca5947edaf519cd213b7b037e", "score": "0.62991476", "text": "static public function flattenConfigurationWithEnvironment()\n {\n $cq_context = cqContext::getInstance();\n $configCache = $cq_context->getConfiguration()->getConfigCache();\n\n // load base gatekeeper\n include($configCache->checkConfig('config/gatekeeper.yml'));\n if ($file = $configCache->checkConfig('config/gatekeeper.yml', true))\n {\n $config = include($file);\n }\n\n $env = cqConfig::get('sf_environment');\n\n // Admin users get the settings from the \"next\" environment\n if ($env === 'prod' && $cq_context->getUser()->isAdmin())\n {\n $env = 'next';\n }\n\n return sfToolkit::arrayDeepMerge(\n isset($config['default']) && is_array($config['default']) ? $config['default'] : array(),\n isset($config['all']) && is_array($config['all']) ? $config['all'] : array(),\n isset($config[$env]) && is_array($config[$env]) ? $config[$env] : array()\n );\n }", "title": "" }, { "docid": "1deac46b30941e9b050e5de1c3b1e0b6", "score": "0.629678", "text": "public static function environment($environment = null)\n {\n if (null !== $environment) {\n static::$environment = $environment;\n return;\n }\n\n $result = static::DEFAULT_APPLICATION_ENV;\n if (defined('APPLICATION_ENV')) {\n $result = constant('APPLICATION_ENV');\n } elseif (static::$environment) {\n $result = static::$environment;\n } elseif (getenv('APPLICATION_ENV')) {\n $result = getenv('APPLICATION_ENV');\n } elseif (static::config('environment')) {\n $result = static::config('environment');\n }\n\n return $result;\n }", "title": "" }, { "docid": "fe2f406ed0630d70026bf3f5880f016a", "score": "0.6295052", "text": "static public function getConfig() {\n return self::$config;\n }", "title": "" }, { "docid": "bc745551c0def6a2d00094999ba9c024", "score": "0.62931406", "text": "public function getApplicationConfig()\n {\n return $this->applicationConfig;\n }", "title": "" }, { "docid": "dc9e5d3942ebe6a9c303be1a18c7f704", "score": "0.6292942", "text": "public function getEnvironment()\n\t{\n\t\treturn $this->environment;\n\t}", "title": "" }, { "docid": "f1e959666769e53bb14adbe5e2623c35", "score": "0.6285542", "text": "function env($key)\n{\n return parse_ini_file(FCPATH.\".env\")[$key];\n}", "title": "" }, { "docid": "fc5df6cd46b055d178460da80ca4fa5c", "score": "0.6281618", "text": "public function getEnvironment() {\n return $this->environment;\n }", "title": "" }, { "docid": "1d98cf501e3012a6eca437d1c86ee370", "score": "0.62744796", "text": "protected function getEnvironments()\n {\n return ['prod', 'dev', 'test'];\n }", "title": "" }, { "docid": "c35ddd1733169929daea131400f2b360", "score": "0.626851", "text": "public function getEnvironment() {\r\n\t\treturn $this->environment;\r\n\t}", "title": "" }, { "docid": "6d93f9b9f895848aa3ddd6339e908799", "score": "0.62673414", "text": "function getEnv($name) {\n\t\tif (isset($this->env[$name]))\n\t\t\treturn $this->env[$name];\n\t\telse\n\t\t\treturn null;\n\t}", "title": "" }, { "docid": "fbc068e24eeb71b8daacf19ab8c255ec", "score": "0.626207", "text": "private static function getConfig() {\n return require __BASE__ . DS . 'config.php';\n }", "title": "" }, { "docid": "2d4e76115a7eebc782bf5020da3f33f9", "score": "0.62549466", "text": "function environment() {\n\t\tif ( func_num_args() > 0 ) {\n\t\t\treturn call_user_func_array( [ container(), 'getEnvironment' ], func_get_args() );\n\t\t}\n\n\t\treturn container()->getEnvironment();\n\t}", "title": "" }, { "docid": "9d7953c8d1267e6d841ee535f4e7cf9d", "score": "0.6253895", "text": "function environment() {\n\t$uri = $_SERVER['REQUEST_URI'];\n\n\tif (strpos($uri, 'phppreview') !== false) {\n\t\t$environment = 'cms';\n\t} else {\n\t\t$environment = 'live';\n\t}\n\n\treturn $environment;\n}", "title": "" }, { "docid": "2122deddf25d84134aa634fd4e785e44", "score": "0.62463135", "text": "public static function get() {\n return self::$config;\n }", "title": "" }, { "docid": "f41027dfd54e69c89ebce11a959771a3", "score": "0.62429386", "text": "public function getEnvironment()\n {\n return ! is_null($this->attributes['environment']) ? json_decode($this->attributes['environment']) : [];\n }", "title": "" }, { "docid": "a601fca9d8537bf9d36c9f7208334b5f", "score": "0.6226673", "text": "public function getEnvironment(): Environment;", "title": "" }, { "docid": "5751b27ae2bdafe29049acbafe32258d", "score": "0.62261426", "text": "public static function getConfig()\n {\n return self::getInstance()->config;\n }", "title": "" }, { "docid": "3c2ae6eba10fcc01d6c5c718d6aa5207", "score": "0.62030745", "text": "public function config()\n {\n return Config::get('meta::config');\n }", "title": "" }, { "docid": "cc21545508be79f10f75bdd64f4fecdd", "score": "0.61924607", "text": "public function practice2() {\n dump(config('app.debug')); // do dump(config('app')); to see ALL settings\n }", "title": "" }, { "docid": "2427fdab034d212091490b38c556e2bd", "score": "0.6172649", "text": "protected function getEnvironmentSetUp($app)\n {\n // Get the helper\n $helper = $this->getHelper();\n\n // Fill the config\n config(['tikkie.api-key' => $helper->getRandomString(10)]);\n config(['tikkie.sandbox' => 'true']);\n config(['tikkie.app-token' => $this->createTikkieApplication()]);\n }", "title": "" }, { "docid": "77f65fb1663f22d9f64fe29dcfd32d63", "score": "0.616703", "text": "protected function determineEnvironment()\n {\n return ServerUtility::determineEnvironment();\n }", "title": "" }, { "docid": "1230bc92ce715540e37912746bfe1a18", "score": "0.6163132", "text": "public function environment() {\n // get the value of the server uri\n $uri = $_SERVER['REQUEST_URI'];\n\n if (strpos($uri, 'phppreview') !== false) {\n $environment = 'cms';\n } else {\n $environment = 'live';\n }\n\n return $environment;\n }", "title": "" }, { "docid": "dbf2e420d96607c7e2278fb195f7ed5d", "score": "0.61529326", "text": "protected static function whichEnv() {\n\n if(!isset(self::$envType)) {\n if (strpos(self::$env, 'dev') !== false) {\n self::$envType = 1;\n return 1;\n }\n return 0;\n } else\n return self::$envType;\n\n }", "title": "" }, { "docid": "5be9190f805bf1319b41bbd835988353", "score": "0.6151427", "text": "protected function detectEnvironment()\n {\n $hostname = gethostname();\n if ($this->env != null) {\n return;\n }\n $this->envArray = include ROOT .'app'. DS .'environments.php';\n foreach ($this->environments() as $current) {\n if (in_array($hostname, $this->envArray[$current])) {\n $this->env = $current;\n break;\n }\n }\n if ($this->env == null) {\n die('We could not detect your application environment, please correct your <b>app/environments.php</b> hostnames.');\n }\n }", "title": "" }, { "docid": "41f244529aa6dcc22a6e7884a3a9cca7", "score": "0.6144299", "text": "public static function getConfig() {\n\t\treturn self::$_config;\n\t}", "title": "" }, { "docid": "b30fd2c5d8f5701524b2390f65e85854", "score": "0.6139321", "text": "public function getEnvironment($storeId = null) {\r\n return $this->getValue(Config::KEY_ENVIRONMENT, $storeId);\r\n }", "title": "" }, { "docid": "a65a08b9caff3470fe8ec8f4200efd6e", "score": "0.6130069", "text": "public function envPath()\n {\n return APP .'config'. DS . $this->env() . DS;\n }", "title": "" }, { "docid": "12054fbb250fc78f786944d5e71f1495", "score": "0.61299884", "text": "public function getEnv(): array;", "title": "" }, { "docid": "0c9e2e28444fc58332cd68c493259769", "score": "0.6129084", "text": "public function getConfig(){\n if (!$this->config) {\n $this->config = \\Drupal::config('laravel.settings');\n }\n\n return $this->config;\n }", "title": "" }, { "docid": "0837d186f8e0f54cd219d86f78070e34", "score": "0.6128145", "text": "public static function env()\n {\n return function () {\n // Use config from environment variables, if available\n $endpointsType = getenv(self::ENV_ENDPOINTS_TYPE);\n if (!empty($endpointsType)) {\n return Promise\\promise_for(\n new Configuration($endpointsType)\n );\n }\n\n return self::reject('Could not find environment variable config'\n . ' in ' . self::ENV_ENDPOINTS_TYPE);\n };\n }", "title": "" }, { "docid": "4716c65775d4658226c405fd74028252", "score": "0.6121462", "text": "public function getEnv(): array\n {\n return $this->env;\n }", "title": "" }, { "docid": "88802af71b5b6a30f23e9fc529be187f", "score": "0.61190933", "text": "public function config()\n {\n return $this->app['config']->get('imgur::imgur');\n }", "title": "" }, { "docid": "c96145177f0920150f374d93d17a25be", "score": "0.611891", "text": "public function getConfig()\n {\n return Config::getInstance();\n }", "title": "" }, { "docid": "d9cd38be5a781ae109ae238629009a9e", "score": "0.6114302", "text": "public static function getConfig()\n {\n return self::$_config;\n }", "title": "" } ]
c3336340d8e0a6a63895d3be0edd9d46
fungsi hapus data Mahasiswa
[ { "docid": "453c5ec8be515076b1ef05ddfa6c4dc2", "score": "0.0", "text": "public function deleteMahasiswa($id){\n $this->db->query(\"DELETE FROM $this->tabel WHERE id=:id\");\n $this->db->bind('id', $id);\n $this->db->execute();\n return $this->db->rowCount();\n }", "title": "" } ]
[ { "docid": "50fe8d188998dc38b04ce9489bbdb591", "score": "0.7734803", "text": "public function tampilDataGalang(){\n\t\t\n\t}", "title": "" }, { "docid": "1bedd228a15e59270f4252d62222361f", "score": "0.718863", "text": "public function daftarMahasiswa()\n {\n $this->load->model('Model_mahasiswa', 'mahasiswa');\n $data['mahasiswa'] = $this->mahasiswa->getDataMahasiswa();\n echo json_encode($data['mahasiswa']);\n }", "title": "" }, { "docid": "e0289914cc5cfacf94b7fe8968454594", "score": "0.71736526", "text": "public function tampil_data(){\n $sql= \"Select * From penjualan Order By id_penjualan DESC\";\n $data=$this->konek->query($sql);\n while ($row=mysqli_fetch_array($data)) {\n $hasil[]=$row;\n }\n return $hasil;\n }", "title": "" }, { "docid": "68469255163a7787281a47299e39c216", "score": "0.71423024", "text": "function data_mhs(){\r\n\t\t\techo \"KodeMataKuliah : \".$this->KodeMataKuliah.\"<br />\";\r\n\t\t\techo \"SKS : \".$this->SKS.\"<br />\";\r\n\t\t\techo \"Daftar matakuliah yang diambil:<br />\";\r\n\t\t\t\r\n\t\t\t$i = 0; // nomor urut daftar SKS matakuliah yang diambil\r\n\t\t\tforeach($this->NamaMataKuliah as $mk){\r\n\t\t\t\techo ++$i.\". \".$mk.\"<br />\";\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Cuma buat ganti baris aja kok :-)\r\n\t\t\techo \"<br />\";\r\n\t\t}", "title": "" }, { "docid": "5d88017cdb5ce9a9aaea9001c3081598", "score": "0.71391815", "text": "public function mahasiswa()\n {\n $data['halaman'] = \"Data Mahasiswa\";\n $data['mahasiswa'] = $this->mod->m_get_all_mahasiswa_plus_dosen();\n // print('<pre>');print_r($data);exit();\n $this->load->view('head.php', $data);\n $this->load->view('sidebar.php');\n $this->load->view('header.php');\n $this->load->view('dosen/mahasiswa.php', $data);\n $this->load->view('footer.php');\n }", "title": "" }, { "docid": "f817ab7522b639d31094925dab68b6df", "score": "0.70961726", "text": "public function data_tahun_ajaran()\n\t{\n\t\t$data['data'] = $this->m_aka->data_tahun_ajaran(); \n\t\t$data['pagination'] = $this->pagination->create_links();\n\t\t$data['content'] = 'mata_kuliah/data_tahun_ajaran';\n\t\t$this->load->view('content', $data);\n\t}", "title": "" }, { "docid": "3f3cab7014e4809ac239d18391fc38cf", "score": "0.705712", "text": "function semuaMahasiswa($query)\n{\n //karena $conn yang ada di file database.php berada diluar function semuaMahasiswa. jadi buat variable global untuk memanggilnya\n // agar variable $conn dapat digunakan\n global $conn;\n\n // array kosong untuk menyimpan dataMahasiswa\n\n $dataMahasiswa = $conn->query($query);\n return $dataMahasiswa; // untuk membuat function ini bernilai data 'dataMahasiswa'\n}", "title": "" }, { "docid": "9521d4d1aec75b5d0523b3832d93d9a8", "score": "0.70065045", "text": "function _dispen_hari(){\n\t\t$CI =& get_instance();\n\t\t$api_url \t= URL_API_SIA.'sia_sistem/data_view';\n\t\t$parameter = array('api_kode' =>200002, 'api_subkode' => 1, 'api_search' => array());\n\t\t$data \t\t= $CI->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\treturn $data[0]->KADALUWARSA_HARI1;\n\t}", "title": "" }, { "docid": "8208a22c66e03d3ed75d99337712c5a4", "score": "0.7005511", "text": "public function dataMahasiswa()\n\t{\n\t\t$this->db->select('*');\n\t\t$this->db->from('tb_mahasiswa');\n\t\t$this->db->order_by('nim', 'asc');\n\t\t$data = $this->db->get('');\n\t\treturn $data;\n\t}", "title": "" }, { "docid": "026ea64f30c3ab0304dba30b6fa18b64", "score": "0.698762", "text": "public function displaymahasiswa()\r\n {\r\n $query = \"select * from data_mahasiswa\";\r\n return $this->db->query($query);\r\n }", "title": "" }, { "docid": "bdab4f011196c58020cae435da552971", "score": "0.69860697", "text": "function getDataMahassiwa()\n{\n\t$data = array(\n\t\t\t\t\t\"nama\" => \"Edward\",\n\t\t\t\t\t\"npm\" \t=> \"17117369\",\n\t\t\t\t\t\"fakultas\" => \"Fakultas Ilmu Komputer & Teknologi Informasi\",\n\t\t\t\t\t\"jurusan\" => \"Sistem Informasi\"\n\t\t\t\t\t);\n\treturn $data;\n}", "title": "" }, { "docid": "371358e6361e8c228c162b48998bfc95", "score": "0.6977463", "text": "function hapusData($kodeKamar)\n {\n //membuat variabel untuk menampung data where id dari inputan view\n //yg kiri nama atribute di database, yg kanan nama 'name' dari inputan view\n $where = ['kode_kamar' => $kodeKamar];\n\n try {\n //membuat variabel baru dengan nama hapus untuk melempar data ke model\n //objek model menjalankan method hapusData yang berada di model dan mengirim data array nya dengan tabel\n //menambahkam parameter where sebagai parameter menggunakan id\n $hapus = $this->mkamar->hapusData($this->table, $where);\n //jika hapus berhasil maka :\n if ($hapus) {\n //menjalankan script alert dan me redirect ke controller /kamar\n echo \"<script>alert('Data berhasil dihapus'); window.location='\" . base_url('/kamar') . \"';</script>\";\n //jika gagal maka :\n } else {\n echo \"<script>alert('Data gagal dihapus'); window.location='\" . base_url('/kamar') . \"';</script>\";\n }\n //jika data sudah ada maka :\n } catch (\\Exception $e) {\n echo \"<script>alert('Data sudah ada'); window.location='\" . base_url('/kamar') . \"';</script>\";\n }\n }", "title": "" }, { "docid": "f4cf5a79dad150259313ff3110a2ca3e", "score": "0.69337684", "text": "public function tratarDados(){\r\n\t\r\n\t\r\n }", "title": "" }, { "docid": "4f230df9146c760b8ac5420826a8d81c", "score": "0.6913483", "text": "function tampil_data($tabel)\n {\n $row = $this->db->prepare(\"SELECT * FROM sms\");\n $row->execute();\n return $hasil = $row->fetchAll();\n }", "title": "" }, { "docid": "20695ba05a46f57e31e4e5fd27fdfe3c", "score": "0.69006854", "text": "public function data_biaya_kuliah()\n\t{\n\t\t$data['data'] = $this->m_aka->data_biaya_kuliah(); \n\t\t$data['pagination'] = $this->pagination->create_links();\n\t\t$data['content'] = 'keuangan/data_biaya_kuliah';\n\t\t$this->load->view('content', $data);\n\t}", "title": "" }, { "docid": "caf753a5f2015a0a1513564f3d55b2d6", "score": "0.68813163", "text": "function ambil_data(){\n\t\t$this->db->order_by($this->id_admin,$this->order);\n\t\treturn $this->db->get($this->nama_table)->result();\n\t}", "title": "" }, { "docid": "5d0f085f660b2926be4656e6ce96eec5", "score": "0.6869817", "text": "function _get_data()\r\n {\r\n $model_dangtin =& m('qldangtin');\r\n $dangtin = $model_dangtin->find(array(\r\n 'limit' => 4,\r\n\t 'count' => true,\r\n\t 'order' => 'thoigianup DESC',\r\n ));\r\n $this->assign('dangtin', $dangtin);\t\r\n // var_dump($dangtin);\r\n //Tin khuyen mai\r\n $value='1';\r\n $model_dangtin =& m('qldangtin');\r\n $khuyenmai = $model_dangtin->find(array(\r\n 'limit' => 4,\r\n\t 'count' => true,\r\n\t 'order' => 'thoigianup DESC',\r\n\t\t'conditions' => 'khuyenmai ='.$value,\r\n ));\r\n $this->assign('khuyenmai', $khuyenmai);\r\n // var_dump($khuyenmai);\r\n //san pham moi\r\n $model_sanpham =& m('goods');\r\n $sanpham = $model_sanpham->find(array(\r\n 'limit' => 4,\r\n\t 'count' => true,\r\n\t 'order' => 'add_time DESC',\r\n ));\r\n $this->assign('sanpham', $sanpham);\r\n\r\n \r\n }", "title": "" }, { "docid": "68e79fa3a65c269ca79ac44f2da9149b", "score": "0.68695205", "text": "public function simpan_data_penerima_bansos()\n {\n $noKK = $this->request->getVar('noKK');\n $kepalaKeluarga = $this->request->getVar('kepalaKeluarga');\n $idBansos = $this->request->getVar('idBansos');\n $namaBansos = $this->request->getVar('namaBansos');\n $kategori = $this->request->getVar('kategori');\n $pendamping = $this->request->getVar('pendamping');\n $nominal = $this->request->getVar('nominal');\n $jumlahData = count($noKK);\n $jumlahBerhasil = 0;\n $jumlahGagal = 0;\n $jumlahTerdaftar = 0;\n $jumlahDataKKTidakDitemukan = 0;\n $jumlahDataBansosTidakDitemukan = 0;\n $jumlahBelumDisetujui = 0;\n for ($i = 0; $i < $jumlahData; $i++) {\n // cek apakah fieldnya kosong\n if ($noKK[$i] == 0 || $idBansos[$i] == 0) {\n $jumlahGagal++;\n } else {\n // cek pada database apakah data KK tersebut ada\n $dataKeluarga = $this->KeluargaModel->where('noKK', $noKK[$i])->first();\n if ($dataKeluarga) {\n // cek pada database apakah data bansos ada\n $dataBansos = $this->DataBansosModel->where('idBansos', $idBansos[$i])->first();\n if ($dataBansos) {\n // cek apakah data keluarga sudah\n $status = 'Disetujui';\n $disetujui = $this->KeluargaModel->where('noKK', $noKK[$i])->where('status', $status)->first();\n if ($disetujui) {\n // cek data peserta apakah sudah terdaftar\n $pesertaBansos = $this->BansosModel->where('noKK', $noKK[$i])->where('idBansos', $idBansos[$i])->first();\n if ($pesertaBansos) {\n $jumlahTerdaftar++;\n } else {\n\n $this->BansosModel->save([\n 'noKK' => $noKK[$i],\n 'kepalaKeluarga' => $kepalaKeluarga[$i],\n 'idBansos' => $idBansos[$i],\n 'namaBansos' => $namaBansos[$i],\n 'kategori' => $kategori[$i],\n 'pendamping' => $pendamping[$i],\n 'nominal' => $nominal[$i],\n 'statusAnggota' => 'Aktif'\n ]);\n $jumlahBerhasil++;\n }\n } else {\n $jumlahBelumDisetujui++;\n }\n } else {\n $jumlahDataBansosTidakDitemukan++;\n }\n } else {\n $jumlahDataKKTidakDitemukan++;\n }\n }\n }\n session()->setFlashdata('pesan', '' . $jumlahBerhasil . ' Berhasil Disimpan, ' . $jumlahTerdaftar . ' Telah Terdaftar, ' . $jumlahDataKKTidakDitemukan . ' Data KK Tidak Ditemukan, ' . $jumlahDataBansosTidakDitemukan . ' Data Bansos Tidak Ditemukan dan ' . $jumlahBelumDisetujui . ' Belum Disetujui');\n return redirect()->to('/Admin/penerima_bansos');\n }", "title": "" }, { "docid": "5f4eecd7f8ae9839b13a0424cef7e34c", "score": "0.68680716", "text": "public function getTableAcara(){\r\r\n\t\t$key = 1;\r\r\n\t\tif($this->input->post(\"key\")!==NULL){\r\r\n\t\t\t$key = intval($this->input->post(\"key\"));\r\r\n\t\t\tif($key < 0) $key = 1;\r\r\n\t\t}\r\r\n\t\t$s=true;\r\r\n\t\t$string = \"<h4>Informasi Acara</h4><div class='well'>Data Tidak ditemukan</div>\";\r\r\n\t\t$n = 1;\r\r\n\t\t$z = 1;\r\r\n\t\t$koko = 0;\r\r\n\t\t$this->loadLib('ControlEvent');\r\r\n\t\t$tempKejadian = (new ControlEvent($this->gateControlModel))->getAllData();\r\r\n\t\tif($tempKejadian){\r\r\n\t\t\twhile($tempKejadian->getNextCursor()){\r\r\n\t\t\t\tif($n <= 5 && $z == $key){\r\r\n\t\t\t\t\tif($s){\r\r\n\t\t\t\t\t\t$string = \"<h4>Informasi Acara</h4>\";\r\r\n\t\t\t\t\t\t$s = false;\t\r\r\n\t\t\t\t\t}\t\t\t\r\r\n\t\t\t\t\tif($tempKejadian->getKode() == '1'){\t\r\r\n\t\t\t\t\t\t$string .= \"<div class='well'>\";\r\r\n\t\t\t\t\t\t$string .= $tempKejadian->getJudul().\"<br>\".$tempKejadian->getIsi();\r\r\n\t\t\t\t\t\t//$string .= $tempKejadian->getJudul().\"<br>\".$tempKejadian->getIsi().\" Pada tahun ajaran \".substr($tempKejadian->getTahunAk(),0,strlen($tempKejadian->getTahunAk())-1).\"-\".(intval(substr($tempKejadian->getTahunAk(),0,strlen($tempKejadian->getTahunAk())-1))+1).\" Semester \".$tempKejadian->getTahunAk()[4].\" dimulai pada tanggal \".$tempKejadian->getMulai().\" hingga tanggal \".$tempKejadian->getBerakhir();\r\r\n\t\t\t\t\t\t$string .= \"</div>\";\t\r\r\n\t\t\t\t\t}else{\r\r\n\t\t\t\t\t\t$string .= \"<div class='well'>\";\r\r\n\t\t\t\t\t\t$string .= $tempKejadian->getJudul().\"<br>\".$tempKejadian->getIsi();\r\r\n\t\t\t\t\t\t$string .= \"</div>\";\r\r\n\t\t\t\t\t}\r\r\n\t\t\t\t\t$koko ++;\r\r\n\t\t\t\t\t$n++;\r\r\n\t\t\t\t}else if($n == 5 && $z < $key){\r\r\n\t\t\t\t\t$n = 1;\r\r\n\t\t\t\t\t$z++;\r\r\n\t\t\t\t}else{\r\r\n\t\t\t\t\t$n++;\r\r\n\t\t\t\t}\r\r\n\t\t\t}\r\r\n\t\t}\r\r\n\t\techo \"1\".$string;\r\r\n\t\tif($key == 1){\r\r\n\t\t\tif($koko == 5)\r\r\n\t\t\t\techo '<div class=\"dataTables_paginate paging_two_button\">\r\r\n\t\t\t\t\t\t<a class=\"paginate_disabled_previous\" tabindex=\"0\" role=\"button\" aria-controls=\"DataTables_Table_0\"> Sebelumnya </a>\r\r\n\t\t\t\t\t\t<a class=\"paginate_enabled_next\" tabindex=\"0\" role=\"button\" aria-controls=\"DataTables_Table_0\" onclick=\"nextPageBerandaBase();\"> Sesudahnya </a>\r\r\n\t\t\t\t\t</div>';\r\r\n\t\t\telse\r\r\n\t\t\t\techo '<div class=\"dataTables_paginate paging_two_button\">\r\r\n\t\t\t\t\t\t<a class=\"paginate_disabled_previous\" tabindex=\"0\" role=\"button\" aria-controls=\"DataTables_Table_0\"> Sebelumnya </a>\r\r\n\t\t\t\t\t\t<a class=\"paginate_disabled_next\" tabindex=\"0\" role=\"button\" aria-controls=\"DataTables_Table_0\"> Sesudahnya </a>\r\r\n\t\t\t\t\t</div>';\r\r\n\t\t}else{\r\r\n\t\t\tif($koko == 5)\r\r\n\t\t\t\techo '<div class=\"dataTables_paginate paging_two_button\">\r\r\n\t\t\t\t\t\t<a class=\"paginate_enabled_previous\" tabindex=\"0\" role=\"button\" aria-controls=\"DataTables_Table_0\" onclick=\"previousPageBerandaBase();\"> Sebelumnya </a>\r\r\n\t\t\t\t\t\t<a class=\"paginate_enabled_next\" tabindex=\"0\" role=\"button\" aria-controls=\"DataTables_Table_0\" onclick=\"nextPageBerandaBase();\"> Sesudahnya </a>\r\r\n\t\t\t\t\t</div>';\r\r\n\t\t\telse\r\r\n\t\t\t\techo '<div class=\"dataTables_paginate paging_two_button\">\r\r\n\t\t\t\t\t\t<a class=\"paginate_enabled_previous\" tabindex=\"0\" role=\"button\" aria-controls=\"DataTables_Table_0\" onclick=\"previousPageBerandaBase();\"> Sebelumnya </a>\r\r\n\t\t\t\t\t\t<a class=\"paginate_disabled_next\" tabindex=\"0\" role=\"button\" aria-controls=\"DataTables_Table_0\"> Sesudahnya </a>\r\r\n\t\t\t\t\t</div>';\r\r\n\t\t}\r\r\n\t\t\r\r\n\t}", "title": "" }, { "docid": "cbfa94f33e6c32cd62c378314a015189", "score": "0.68394554", "text": "public function add_data_mahasiswa()\n\t{\n\t\t$save = $this->input->post('add_mahasiswa');\n\t\t$kelas = 't_kelas';\n\t\t$tahun = 't_tahun_akademik';\n\t\t$prodi = \"t_prodi\";\n\t\t$data['kelas'] = $this->m_aka->get_all($kelas);\n\t\t$data['tahun_aka'] = $this->m_aka->get_all($tahun);\n\t\t$data['prodi'] = $this->m_aka->get_all($prodi);\n\t\t$data['content'] = 'mahasiswa/tambah_mahasiswa';\n\t\t$this->load->view('content', $data);\n\t}", "title": "" }, { "docid": "29bb059014b4c24295d5f0448be1ca7d", "score": "0.6817553", "text": "function BBdekat_tempatIbadah(){\n\t\t$this->db->select('batas_bawah');\n\t\t$this->db->where('nama_parameter', 'dekat');\n\t\t$q = $this->db->get('parameter');\n\t\t$data = $q->result_array();\n\n\t\treturn $hasil = $data[1]['batas_bawah'];\n\t}", "title": "" }, { "docid": "ce9c44b6ab7e4dbdf0481c6ef51e7d98", "score": "0.6816438", "text": "public function index()\n {\n $data = DB::select(DB::raw(\"SELECT pustaka.ID ,pustaka.JUMLAH as jumlah, pustaka.JUDUL as judul, GROUP_CONCAT(peminjaman.ID_PUSTAKA) as peminjaman, GROUP_CONCAT(data_fisik.id_barcode) as data_fisik FROM pustaka LEFT JOIN data_fisik ON data_fisik.id_buku = pustaka.ID LEFT JOIN peminjaman ON peminjaman.ID_PUSTAKA LIKe concat('%',pustaka.ID, '%') AND peminjaman.STATUS = 'pinjam' GROUP BY pustaka.ID \n \"));\n \n \n $arr = [];\n foreach($data as $d)\n {\n $testing = HelperHelp::dataada($d->peminjaman, $d->data_fisik);\n \n array_push($arr,[\n 'ID' => $d->ID,\n 'Tersedia' => $testing,\n 'Tidak Tersedia' => HelperHelp::caridata($testing,$d->jumlah)\n \n \n \n ]);\n \n }\n \n \n $tersedia = [\n count(array_merge(...array_column($arr,'Tersedia'))),\n count(array_merge(...array_column($arr,'Tidak Tersedia')))\n \n ];\n \n \n return $tersedia;\n }", "title": "" }, { "docid": "887de758d6530dc94d1f7608370df9e4", "score": "0.68058604", "text": "public function ubah_data()\n {\n $id = $this->request->getVar('id');\n $jumlahAktif = 0;\n $jumlahTidakAktif = 0;\n if ($id) {\n $jumlahData = count($id);\n for ($i = 0; $i < $jumlahData; $i++) {\n $currentData = $this->BansosModel->where('id', $id[$i])->first();\n if ($currentData['statusAnggota'] == 'Aktif') {\n $db = \\Config\\Database::connect();\n $builder = $db->table('bansos');\n $builder->set('statusAnggota', 'Tidak Aktif');\n $builder->where('id', $id[$i]);\n $builder->update();\n $jumlahTidakAktif++;\n } else {\n $db = \\Config\\Database::connect();\n $builder = $db->table('bansos');\n $builder->set('statusAnggota', 'Aktif');\n $builder->where('id', $id[$i]);\n $builder->update();\n $jumlahAktif++;\n }\n }\n } else {\n session()->setFlashdata('gagal', 'Tidak Ada Data Yang Dipilih');\n return redirect()->to('/Admin/penerima_bansos');\n }\n session()->setFlashdata('pesan', '' . $jumlahAktif . ' Data Statusnya Dibuah Menjadi Aktif dan ' . $jumlahTidakAktif . ' Data Statusnya Diubah Menjadi Tidak Aktif');\n return redirect()->to('/Admin/penerima_bansos');\n }", "title": "" }, { "docid": "5c94b41151ca2507a1b0e0e77a0e9abc", "score": "0.6779781", "text": "function tampilkan(){\r\n\t\t\t$query \t= \"SELECT * FROM data\";\r\n\t\t\treturn result($query);\r\n\t\t}", "title": "" }, { "docid": "907d01a29ec785f539d8e130d2bc0386", "score": "0.6777767", "text": "public function index()\r\n\t{\r\n\t\t$data['sangsi'] = $this->M_sangsi->tampil();\r\n\t\t$this->template->utama('sangsi/data_sangsi',$data);\r\n\t}", "title": "" }, { "docid": "8fed17034b364e8e6e15ba069a307015", "score": "0.67557216", "text": "public function get_pembeli_darat() {\r\n $nama = $this->input->get('term'); //variabel kunci yang di bawa dari input text id kode\r\n $tipe = \"darat\";\r\n $query = $this->master->get_pembeli($tipe,$nama); //query model\r\n\r\n if($query == TRUE){\r\n $pelanggan = array();\r\n foreach ($query as $data) {\r\n $pelanggan[] = array(\r\n 'label' => $data->nama_pengguna_jasa, //variabel array yg dibawa ke label ketikan kunci\r\n 'id' => $data->id_pengguna_jasa,\r\n 'nama' => $data->nama_pengguna_jasa , //variabel yg dibawa ke id nama\r\n 'alamat' => $data->alamat, //variabel yang dibawa ke id alamat\r\n 'no_telp' => $data->no_telp, //variabel yang dibawa ke id no telp\r\n 'pengguna'=> $data->pengguna_jasa_id_tarif, //variabel yang dibawa ke id pengguna jasa\r\n );\r\n }\r\n }\r\n\r\n echo json_encode($pelanggan); //data array yang telah kota deklarasikan dibawa menggunakan json\r\n }", "title": "" }, { "docid": "ae5dfb37907d0ba27aab76485048c44c", "score": "0.6754853", "text": "public function data_jadwal_kuliah()\n\t{\n\t\t$data['data'] = $this->m_aka->data_jadwal_kuliah(); \n\t\t$data['pagination'] = $this->pagination->create_links();\n\t\t$data['content'] = 'mata_kuliah/data_jadwal_kuliah';\n\t\t$this->load->view('content', $data);\n\t}", "title": "" }, { "docid": "3cdb7734bab14b51509576032cae877f", "score": "0.67472994", "text": "function jabatan_data()\n\t{\t\t\n\t\t$data['j'] = $this->M_master->data_jabatan();\t\n\t\t$data['title'] = 'Data Jabatan';\t\t\n\t\t$data['isi'] = 'contents/jabatan_data';\n\t\t$this->load->view('wrapper', $data);\n\t}", "title": "" }, { "docid": "9fcdf1b9a36338e1e9cf4c9621fbb670", "score": "0.67246884", "text": "public function index(){\n\t#\t{\n $data['data_obat']=$this->db->query('select * from data_obat where stok between 1 and 10');\n $data['data_obat']=$data['data_obat']->num_rows();\n $data['rawat_jalan'] = $this->m_crud->tampil_data('data_rawat_jalan')->result();\n\t\t$this->load->view('admin/jalan/v_data_rawat_jalan',$data);\n # }\n #else {\n # \t\tdie(\"<script>alert('Silahkan Login Admin');window.location='../dashboard'</script>\");\n # \t}\t\n \n }", "title": "" }, { "docid": "7a411caeac7da5df52afb79ffda54afd", "score": "0.6693845", "text": "public function data_blok()\n {\n $data = ['aktif' => 'blok',\n 'data_blok' => $this->M_prospektus->tampil_data_blok(),\n 'kawasan' => $this->M_prospektus->get_data_kawasan()->result_array()\n ];\n\n $this->template->load('template','prospektus/V_data_blok', $data);\n }", "title": "" }, { "docid": "adeed850db0f1b5eafde91d2a888d299", "score": "0.66927415", "text": "function tampil_mahasiswa($id_mhs){\n\t\t\tglobal $con;\n\n\t\t\t$query=mysqli_query($con, \"SELECT a.*,b.*\n\t\t\t\t\t\t\t\t\t\tFROM tb_mahasiswa a,tb_prodi b \n\t\t\t\t\t\t\t\t\t\tWHERE a.id_prodi=b.id_prodi\n\t\t\t\t\t\t\t\t\t\tAND a.id_mhs='$id_mhs'\");\n\t\t\twhile($row=mysqli_fetch_array($query))\n\t\t\t\t$data[] = $row;\n\n\t\t\t\treturn $data;\n\t\t}", "title": "" }, { "docid": "a04864ee77c64ad69a261a599e767fbd", "score": "0.66920096", "text": "function list_kelas_pertemuan_get()\n {\n $query = $this->M_kelas_pertemuan->tampil_data('kelas_pertemuan');\n\n // variable array\n $result = array();\n $result['kelas_pertemuan'] = array();\n\n if ($query->num_rows() > 0) {\n\n // mengeluarkan data dari database\n foreach ($query->result_array() as $row) {\n\n // ambil detail data db\n $data = array(\n 'id_kelas_p' => $row[\"id_kelas_p\"],\n 'id_pengajar' => $row[\"id_pengajar\"],\n 'id_mata_pelajaran' => $row[\"id_mata_pelajaran\"],\n 'hari' => $row[\"hari\"],\n 'jam_mulai' => $row[\"jam_mulai\"],\n 'jam_berakhir' => $row[\"jam_berakhir\"],\n 'harga_fee' => $row[\"harga_fee\"],\n 'harga_spp' => $row[\"harga_spp\"],\n 'id_sharing' => $row[\"id_sharing\"],\n 'nama_sharing' => $row[\"nama_sharing\"],\n );\n\n array_push($result['kelas_pertemuan'], $data);\n\n // membuat array untuk di transfer\n $result[\"success\"] = \"1\";\n $result[\"message\"] = \"success berhasil mengambil data\";\n $this->response($result, 200);\n }\n } else {\n // membuat array untuk di transfer ke API\n $result[\"success\"] = \"0\";\n $result[\"message\"] = \"error data tidak ada\";\n $this->response($result, 200);\n }\n }", "title": "" }, { "docid": "752cdcfc62a4dc4255a303062c52ac4f", "score": "0.6691492", "text": "public static function tambah($data)\n {\n \nerror_reporting(\"E_ALL\") ;\n\n // data\n $detailgaji\t \t\t\t= new Detailgajiku;\n $detailgaji->kd_potongan\t\t= $data['kd_potongan'];\n\t\n $detailgaji->nomor \t\t= $data['nomor'];\n $detailgaji->jumlah \t\t= $data['jumlah'];\t\n\t\n // simpan\n return ($detailgaji->save()) ? true : false;\n }", "title": "" }, { "docid": "335c8acc191943e767f5c235fecded46", "score": "0.6688193", "text": "function tampil(){ \n\t\t$query = $this->db->get('data_fans');\n //menampilkan hasil dari query di atas\n\t\treturn $query->result();\n\t}", "title": "" }, { "docid": "a4994090c9baf6f094523c351e46a583", "score": "0.667886", "text": "public function stok(){\n\n $hasil = $this->pemilik_model->ambilDataStok();\n $data['hasil'] = $hasil;\n\n $this->load->view('pemilik/header');\n $this->load->view('pemilik/stok', $data);\n $this->load->view('front/footer');\n\n }", "title": "" }, { "docid": "dd5ea19a899292810ebad6c566d7f1ac", "score": "0.66689926", "text": "function data_prosesan()\n{\n //$jadual['medan'][]='*';\n /*$jadual['medan'][]='newss,ssm,nama,tel,fax,responden,' .\n '(SELECT keterangan FROM msic WHERE msic=msic2000 LIMIT 1,1) as keterangan,' .\n 'msic2000,msicB2000,fe';*/\n $sama='j1.newss,concat(j1.tahun_rujukan,\"-\",j1.siri_kekerapan) as blnthn, ';\n $sama2='j2.newss,concat(j2.tahun_rujukan,\"-\",j2.siri_kekerapan) as blnthn, ';\n //$jadual['medan'][]=$sama . 'ssm, nama, operator, sv, kekerapan_sv'; \n //$jadual['medan'][]=$sama . 'ng, po, data_anggaran, cara_maklum_balas, cara_terima, sumber_pertubuhan, kategori_sample';\n //$jadual['medan'][]=$sama . 'status_operasi, status_lain_pbb, bil_bulan_bco, siasatan_bermula, siasatan_berakhir';\n //$jadual['medan'][]=$sama . 'no_jln_bgn, tmn_kg, bandar_kawasan, poskod, negeri, daerah, catatan';\n //$jadual['medan'][]=$sama . 'responden, jawatan, email, notel, lamanweb, tarikh';\n //$jadual['medan'][]=$sama . 'responden2, jawatan2, email2, notel2, nofax2';\n //$jadual['medan'][]=$sama . '`no_jln_bgn-lokasi`, `tmn_kg-lokasi`, `bandar_kawasan-lokasi`, ' .\n //'`poskod-lokasi`, `negeri-lokasi` ng, `daerah-lokasi` dp';\n $jadual['medan'][]='j1.newss,j1.ssm,j1.nama,concat(j1.tahun_rujukan,\"-\",j1.siri_kekerapan) as blnthn ';\n $jadual['medan'][]=$sama . \"\\r\" . 'msic_lama, (SELECT keterangan FROM msic WHERE msic=msic_lama LIMIT 1,1) as keterangan,' . \n 'msic_baru, utama '; \n //$jadual['medan'][]=$sama . \"\\r\\t\" . 'F3001, F3002, catatan_soalan3, ' . 'F5001, F5002, F5003, F5104, catatan_soalan5';\n $jadual['medan'][]=$sama . 'F6001, F6002, F6003, F6004, F6005, F6101, F6102, F6103, F6104, F6105, catatan_soalan6';\n $jadual['medan'][]=$sama . 'F7001, F7002, F7003, catatan_soalan7, ' .\n 'F8001, catatan_soalan8, F9001, catatan_soalan9';\n //$jadual['medan'][]=$sama . 'cara_anggaran, bulan_terakhir_data_sebenar, bil_bulan_data_telah_dianggar';\n\n //$jadual['medan'][]=$sama . 'Deskripsi_Produk_Oleh_Responden, Produk_Tetap, Deskripsi_Produk_Tetap,\n //Produk_Tambahan, Deskripsi_Produk_Tambahan, UnitKuantitiAsal, UnitKuantitiLain'; \n $produk='Deskripsi_Produk_Tetap Nama, Produk_Tetap Kod, ';\n $jadual['medan'][]=$sama . $produk . 'KuantitiPengeluaran, KuantitiJualan, NilaiJualan, ' .\n 'format(NilaiJualan/KuantitiJualan,2) as HargaUnit, UnitKuantitiKini';\n //$jadual['medan'][]=$sama . $produk . 'ProsesanKuantitiPengeluaran, ProsesanKuantitiJualan, ProsesanNilaiJualan, AUP';\n $jadual['medan'][]=$sama . $produk . 'F2497, F2498, F2499, Catatan';\n $jadual['medan'][]=$sama . \"\\r\\t\" . \n 'F3001, F3002, catatan_soalan3, ' .\n 'F5001, F5002, F5003, F5104, catatan_soalan5';\n\n //$jadual['medan'][]=$sama . 'catatan';\n $jadual['medan'][]=$sama . 'F4001, F4002, F4003, F4004';\n $jadual['medan'][]=$sama . 'F4101, F4102, F4103, F4104';\n $jadual['medan'][]=$sama . 'F4201, F4202, F4203, F4204';\n $jadual['medan'][]=$sama . 'catatan \"Nota \", F4302, F4303, F4304';\n\n // bulanan\n //$bulan=($_GET['bln']==null)? '':'AND siri_kekerapan=\"'.bersih($_GET['bln']).'\"';\n $bulan_penuh = array('Januari', 'Februari', 'Mac', 'April', \n 'Mei', 'Jun', 'Julai', 'Ogos', \n 'September', 'Oktober', 'November', 'Disember');\n //$kerap='\"'.$bulan_penuh[0].'\",\"'.$bulan_penuh[1].'\",\"'.$bulan_penuh[2].'\"';\n //$bulan=($_GET['bln']==null)? '':'AND j1.siri_kekerapan in ('.$kerap.')';\n //$myJadual=array('mm_rangka','mm_rangka');\n for($z=1;$z <= 4;$z++) { $jadual['nama'][]='prosesmm_info'; } // bil medan = 15\n for($z=1;$z <= 2;$z++) { $jadual['nama'][]='prosesmm_jualan'; }\n $jadual['nama'][]='prosesmm_info';\n for($z=1;$z <= 4;$z++) { $jadual['nama'][]='prosesmm_gajistaf'; }\n $join1='prosesmm_info';\n $join2='prosesmm_jualan';\n $join3='prosesmm_gajistaf';\n \n return $jadual;\n}", "title": "" }, { "docid": "6fc1ead1e544348f6920cae3f318641d", "score": "0.66686946", "text": "public function lihatDataGaleri(){\n\t\t$this->db->where(\"tipe\",1);\n\t\treturn $this->db->get(\"galeri\");\n\t}", "title": "" }, { "docid": "ea86e9b497d5aad797c825ffea430ee0", "score": "0.66677654", "text": "public function data_bahan_kuliah()\n\t{\n\t\t$this->load->model(\"m_aka\");\n\t\t$data['data'] = $this->m_aka->data_bahan_kuliah(); \n\t\t$data['pagination'] = $this->pagination->create_links();\n\t\t$data['content'] = 'posting_pengumuman/data_bahan_kuliah';\n\t\t$this->load->view('content', $data);\n\t}", "title": "" }, { "docid": "dbe45174c306691424381c1229f015d0", "score": "0.66626555", "text": "function data_usulan_tb()\n {\n $query = $this->db->query(\"SELECT\n id_pegawai as id_pegawai,\n nama as nama,\n nip as nip,\n tgl_akhir as tgl_akhir,\n path_foto as path_foto,\n selisih as selisih\n FROM data_tgsbelajar_notif\n WHERE selisih <= 60 \");\n\n return $query->result();\n }", "title": "" }, { "docid": "b86c53ee6d58611e43d3a5939f0db776", "score": "0.6659361", "text": "function cariObat()\n\t{\n\t\tif ($this->input->get() != NULL) {\n\t\t\t$dataForm = $this->input->get();\n\t\t\t\n\t\t\t$dataReturn = $this->db->query(\" SELECT * FROM logistik WHERE nama LIKE '%\".$dataForm['term']['term'].\"%' ESCAPE '!' AND stok > 0\")->result();\t\t\t\n\n\t\t\t$data = array();\n\t\t\tforeach ($dataReturn as $key => $value) {\n\t\t\t\t$data[$key]['id'] = $value->id.\"|\".$value->nama;\n\t\t\t\t$data[$key]['text'] = $value->nama;\n\t\t\t\t$data[$key]['stok'] = $value->stok;\n\t\t\t\tif ($value->kadaluarsa < date(\"Y-m-d-d\")) {\n\t\t\t\t\t$data[$key]['stok'] .= \" Sudah kadaluarsa\";\n\t\t\t\t}\n\t\t\t\t$data[$key]['satuan'] = $value->satuan;\n\t\t\t}\n\t\t\techo json_encode($data);\n\t\t}else{\n\t\t\tredirect();\n\t\t}\t\t\n\t}", "title": "" }, { "docid": "01e4448fd20bb30777a4a69a60fc2725", "score": "0.6655306", "text": "function getDataSingkat($conn,$key,$pengajar=true,$nip='') {\n\t\t\t$sql = \"select k.thnkurikulum, k.kodemk, c.namamk, k.kodeunit, k.periode, k.kelasmk, k.koderuang,\n\t\t\t\t\tk.nohari, k.jammulai, k.jamselesai, k.nohari2, k.jammulai2, k.jamselesai2, k.nilaimasuk, k.kuncinilai,\n\t\t\t\t\tk.dayatampung,k.jumlahpeserta,k.isonline\n\t\t\t\t\tfrom \".static::table().\" k join \".static::table('ak_kurikulum').\" c using (thnkurikulum,kodemk,kodeunit)\n\t\t\t\t\twhere \".static::getCondition($key,null,'k');\n\t\t\t$row = $conn->GetRow($sql);\n\t\t\t\n\t\t\t$row['jadwal'] = Date::indoDay($row['nohari']).', '.CStr::formatjam($row['jammulai']).' - '.CStr::formatjam($row['jamselesai']);\n\t\t\t$row['jadwal2'] = Date::indoDay($row['nohari2']).', '.CStr::formatjam($row['jammulai2']).' - '.CStr::formatjam($row['jamselesai2']);\n\t\t\t\n\t\t\t// ambil data pengajar\n\t\t\tif($pengajar) {\n\t\t\t\t$sql = \"select p.idpegawai::text as nipdosen, akademik.f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as nama from \".static::table('ak_mengajar').\" a\n\t\t\t\t\t\tjoin sdm.ms_pegawai p on a.nipdosen::text = p.idpegawai::text\n\t\t\t\t\t\twhere \".static::getCondition($key,null,'a').\" order by a.nipdosen\";\n\t\t\t\t$rs = $conn->Execute($sql);\n\t\t\t\t\n\t\t\t\t$a_ajar = array();\n\t\t\t\twhile($rowa = $rs->FetchRow())\n\t\t\t\t\t$a_ajar[] = $rowa['nama'];\n\t\t\t\t\n\t\t\t\t$row['pengajar'] = implode('<br>',$a_ajar);\n\t\t\t}\n\t\t\tif(!empty($nip)){\n\t\t\t\t$sql = \"select idpegawai::text as nik, akademik.f_namalengkap(gelardepan,namadepan,namatengah,namabelakang,gelarbelakang) as nama \n\t\t\t\t\t\tfrom sdm.ms_pegawai where nik='$nip' or idpegawai::text='$nip'\";\n\t\t\t\t$rs=$conn->GetRow($sql);\n\t\t\t\t$row['pengajar'] =$rs['nama'];\n\t\t\t}\n\t\t\treturn $row;\n\t\t}", "title": "" }, { "docid": "bb5a27d231b936df107be3b40006fadf", "score": "0.6651752", "text": "public function themmh($loai=\"\")\r\n {\r\n $khoa_result=$this->mmonhoc->get_khoa();\r\n $loai_monhoc_result=$this->mmonhoc->get_loai_monhoc();\r\n $nhom_monhoc_result=$this->mmonhoc->get_ma_monhoc_nhom();\r\n $data[\"khoa_result\"]=$khoa_result;\r\n $data[\"loai_monhoc_result\"]=$loai_monhoc_result;\r\n $data[\"nhom_monhoc_result\"]=$nhom_monhoc_result;\r\n $data[\"loai\"]=$loai; \r\n \r\n \r\n $data[\"data_title\"]=\"Thao tác thêm môn học\";\r\n \r\n \r\n $data[\"title\"]=\"Trang thêm môn học\"; \r\n $this->load->view(\"admin/vmonhoc_add\",$data); \r\n }", "title": "" }, { "docid": "a3d4b48813bfb426672626b48306df6c", "score": "0.66485643", "text": "public function data_kohort(){\n\t\t$tahun = \"t_tahun_akademik\";\n\t\t$kelas = \"t_kelas\";\n\t\t$prodi = \"t_prodi\";\n\t\t$data['content'] = \"report/kohort\";\n\t\t$data['data_tahun'] = $this->m_aka->get_all($tahun);\n\t\t$data['kelas'] = $this->m_aka->get_all($kelas);\n\t\t$data['prodi'] = $this->m_aka->get_all($prodi);\n\t\t$this->load->view(\"content\", $data);\n\t}", "title": "" }, { "docid": "d275ee0104648e9a961f6b8247d32356", "score": "0.66456515", "text": "function tampil_data()\n\t{\n\t\t# perintah join digunakan untuk menggabungkan 2 table, yaitu penduduk dan kematian, agar data yang tampil lebih detail, karena pada tabel kematian hanya terdapat sedikit kolom, sehingga dengan menambah kolom nik, maka data yang ada di tabel penduduk juga otomatis terdeteksi karena perintah join, dengan aturan, nik harus sama antara tabel kematian dan nik yang ada di penduduk.\n\t\treturn $this->db->query(\"SELECT*FROM `kematian` left join penduduk on kematian.nik = penduduk.nik\")->result();\n\t}", "title": "" }, { "docid": "817134b314f3f32bb8980114b011a949", "score": "0.6631652", "text": "function pengguna() {\n global $conn; //memanggil variabel global koneksi\n //select di database berdasarkan nama pengguna yang tercatat di sesi dan dijoinkan dengan tabel jenis pengguna untuk keterangan yang login admin atukah customer\n $q = $conn->prepare(\"SELECT * FROM pengguna p JOIN jenis_pengguna j ON p.jenis_pengguna=j.id WHERE p.nama_pengguna='{$_SESSION['nama-pengguna']}'\");\n $q->execute();\n return @$q->fetchAll()[0]; //direrurn berupa array, ditambah @ akan mereturn false jika data tidak ada\n}", "title": "" }, { "docid": "d12d88a3d6cdc1d3cc94313a759d9c27", "score": "0.6621984", "text": "public\n function getThongbao()\n {\n// $tinChuaDoc = DuyetBai::all()->where('status', 0)->count();\n// Carbon::setLocale('vi');\n// if ($baiDuyet != null) {\n// for ($i = 0; $i < count($baiDuyet); $i++) {\n// $baiDuyet[$i]['created_at'] = Carbon::parse($baiDuyet[$i]['created_at'])->diffForHumans(null, null, true, 2);\n// $baiDuyet[$i]['get_nha_tuyen_dung']['tai_khoan'] = NhaTuyenDung::query()->find($baiDuyet[$i]['get_nha_tuyen_dung']['id'])->getTaiKhoan->toArray();\n// $baiDuyet[$i]['trang_thai_xem_tin'] = DuyetBai::query()->where('bai_dang_id', $baiDuyet[$i]['id'])->first('status');\n// }\n//\n// $data['duyet_tin'] = $baiDuyet;\n// $data['tin_chua_doc'] = $tinChuaDoc;\n// }\n\n return [];\n }", "title": "" }, { "docid": "92f242d92d736762ee829b356084e57a", "score": "0.6602401", "text": "public function list_data_pejabat_berwenang()\n {\n $data['admin'] = $this->db->get_where('admin', ['id_admin' =>\n $this->session->userdata('id_admin')])->row_array();\n $data['jumlah_pesan_masuk'] = $this->m_admin->jumlah_pesan_masuk()->result();\n $data['jumlah_permohonan_masuk'] = $this->m_admin->jumlah_permohonan_masuk()->result();\n $data['jumlah_pesan_masuk'] = $this->m_admin->jumlah_pesan_masuk()->result();\n\n $data_pejabat['data_pejabat'] = $this->m_admin->get_data_pejabat()->result();\n\n $this->load->view('header');\n $this->load->view('admin/sidebar_admin');\n $this->load->view('topbar', $data);\n $this->load->view('admin/list_data_pejabat_berwenang', $data_pejabat);\n $this->load->view('footer');\n }", "title": "" }, { "docid": "c5a238c137a9fa66b814f7b66a010c66", "score": "0.6602268", "text": "function getTabelSurat($surat,$nomor_pasien)\n\t{\n\t\t// select * from suratrujukan WHERE nomor_pasien='001-006-01-02-07-2018' ORDER BY id DESC limit 1 ;\n\t\t// sebelumnya telah dibuatkan data pada tabel surat rujukan, actionnya saat klink tombol surat rujukan pada pemeriksaan\n\t\t$data = json_encode($this->Kesehatan_M->rawQuery(\"SELECT * FROM surat\".$surat.\" WHERE nomor_pasien='\".$nomor_pasien.\"' ORDER BY id DESC limit 1 \")->result());\n\t\techo $data;\n\t}", "title": "" }, { "docid": "13b78952b65b786c645fc1132a5cd890", "score": "0.65976965", "text": "public function index()\n {\n $akun =dataakun::where('nama_instansi', Auth::user()->name)->get();\n foreach ($akun as $key => $value) {\n $id = $value[\"id\"];\n } \n $datapenyakit = datapenyakit::where('status','Belum dikonfirmasi')->where('id_instansi',$id)->get();\n $kelurahan = kelurahan::all();\n $kecamatan = kecamatan::all();\n return view('keloladatapenyakit.keloladata', compact('datapenyakit', 'kelurahan', 'kecamatan'));\n // return view('keloladatapenyakit.keloladata');\n\n }", "title": "" }, { "docid": "e31564d8088109a310c95b86ca23c47a", "score": "0.6597456", "text": "public function simpan_data_misi()\n {\n $aksi = $this->input->post('aksi');\n $id_misi = $this->input->post('id_misi');\n $misi = $this->input->post('nama_misi');\n\n $data = ['misi' => $misi,\n 'add_time' => date(\"Y-m-d H:i:s\", now('Asia/Jakarta')),\n 'add_by' => $this->session->userdata('id_user')\n ];\n\n if ($aksi == 'Tambah') {\n $this->M_master->input_data('m_misi', $data);\n } elseif ($aksi == 'Ubah') {\n $this->M_master->ubah_data('m_misi', $data, array('id_misi' => $id_misi));\n } elseif ($aksi == 'Hapus') {\n $this->M_master->hapus_data('m_misi', array('id_misi' => $id_misi));\n }\n\n echo json_encode($aksi);\n }", "title": "" }, { "docid": "f246ab2356103890b18af3bf4cf43d6c", "score": "0.65967715", "text": "function ambil_data(){ //fungsi yang akan mengambil data pada table user\n\t\treturn $this->db->get('user'); //mengambil data dari database, mengembalikan data yang ditangkap pada controller yang memanggil function ambil_data\n\t}", "title": "" }, { "docid": "8f07107fb9fb64208b84178fd2ec8631", "score": "0.65948135", "text": "function tampil_bentuk_sedia(){\n $data['login'] = 'Halaman Login';\n $data['title'] = 'Kelola Satuan Sedia';\n $data['query'] = $this->m_barang->tampil_satuan_sedia();\n $this->template->load('static','barang/satuan/satuansedia', $data);\n }", "title": "" }, { "docid": "616199053bb3dc31f3a26605d516360d", "score": "0.6594427", "text": "public function index()\n\t{\n\t\t$paket['array']=$this->Mdl_soal->ambildata();\t\n\t\t$this->load->view('soal/soal_cfit',$paket);\n\t}", "title": "" }, { "docid": "2446edf685fddff532aeab1b0b8b6300", "score": "0.65905035", "text": "public function semuaData(){ \n return Mata_Kuliah::find(3)->Mahasiswa()->detach(); //gausah diisi arraynya\n }", "title": "" }, { "docid": "8547985938a508056526ad53b970df06", "score": "0.65891075", "text": "public function tabel_pengantaran(){\r\n $result = $this->darat->get_tabel_transaksi();\r\n $data = array();\r\n $no = 1;\r\n\r\n if (is_array($result) || is_object($result)){\r\n foreach ($result as $row){\r\n $aksi = \"\";\r\n \r\n if($row->waktu_mulai_pengantaran == NULL){\r\n $aksi = '&nbsp;<a class=\"btn btn-sm btn-info glyphicon glyphicon-road\" href=\"javascript:void(0)\" title=\"Pengantaran\" onclick=\"pengantaran('.\"'\".$row->id_transaksi.\"'\".');\"></a>';\r\n }else if($row->waktu_selesai_pengantaran != NULL){\r\n $aksi = \"\";\r\n }else{\r\n $aksi = '&nbsp;<a class=\"btn btn-sm btn-primary glyphicon glyphicon-ok\" href=\"javascript:void(0)\" title=\"Realisasi\" onclick=\"realisasi('.\"'\".$row->id_transaksi.\"'\".')\"></a>';\r\n }\r\n $format_tgl = date('d-m-Y H:i', strtotime($row->tgl_transaksi ));\r\n $format_tgl_pengantaran = date('d-m-Y H:i', strtotime($row->tgl_perm_pengantaran ));\r\n \r\n if($row->status_delivery == 1){\r\n $status_pengantaran = \"Sudah Diantar\";\r\n }else if($row->waktu_mulai_pengantaran != NULL){\r\n $status_pengantaran = \"Sedang Dalam Pengantaran\";\r\n }else{\r\n $status_pengantaran = \"Belum Diantar\";\r\n }\r\n \r\n if(($row->status_pembayaran == 1 || $row->status_invoice == 1) && $row->status_delivery == 0 && $row->batal_nota == 0 && $row->batal_kwitansi == 0){\r\n $data[] = array(\r\n 'no' => $no,\r\n 'nama' => $row->nama_pemohon,\r\n 'alamat' => $row->alamat,\r\n 'no_telp' => $row->no_telp,\r\n 'tanggal' => $format_tgl,\r\n 'tanggal_permintaan' => $format_tgl_pengantaran,\r\n 'total_pengisian' => $row->total_permintaan,\r\n 'status_pengantaran' => $status_pengantaran,\r\n 'aksi' => $aksi\r\n );\r\n $no++;\r\n }\r\n }\r\n }\r\n \r\n echo json_encode($data);\r\n }", "title": "" }, { "docid": "98a527ba357d76c35c35f13f0927763b", "score": "0.65864325", "text": "public function list_data_mantan_pejabat_berwenang()\n {\n $data['admin'] = $this->db->get_where('admin', ['id_admin' =>\n $this->session->userdata('id_admin')])->row_array();\n $data['jumlah_pesan_masuk'] = $this->m_admin->jumlah_pesan_masuk()->result();\n $data['jumlah_permohonan_masuk'] = $this->m_admin->jumlah_permohonan_masuk()->result();\n $data['jumlah_pesan_masuk'] = $this->m_admin->jumlah_pesan_masuk()->result();\n\n $data_pejabat['data_pejabat'] = $this->m_admin->get_data_mantan_pejabat()->result();\n\n $this->load->view('header');\n $this->load->view('admin/sidebar_admin');\n $this->load->view('topbar', $data);\n $this->load->view('admin/list_data_mantan_pejabat_berwenang', $data_pejabat);\n $this->load->view('footer');\n }", "title": "" }, { "docid": "e7e6743711ce37c38cb1bc57228840a8", "score": "0.657958", "text": "function spefisik($dataid_kematian)\n\t{\n\n\t\t# codenya sql sepert select*from penduduk where nik = $datanik dimna $datanik adalah yg sudah dipilih. jadi cuma 1 row.\n\t\t$query = $this->db->query(\"SELECT*FROM `kematian` left join penduduk on kematian.nik = penduduk.nik where id_kematian = '$dataid_kematian' \");\n\n\t\t// itu adalah perintah sql join 2 table, yaitupenduduk dan kematian, karena data yanglenkap ada ditable pendudukjadiharus dijoin, \n\t\treturn $query->row();\n\t\t\n\t}", "title": "" }, { "docid": "0e2dae6fa456d3da47518069d40c4833", "score": "0.6576183", "text": "private function _dataMahasiswa($id)\n\t{\n\t\t$dataMahasiswa = $this->admin->get_data_user($id)->result_array();\n\t\tforeach($dataMahasiswa as $rowMahasiswa) {\n\t\t\t$data['idUser'] = $rowMahasiswa['id_user'];\n\t\t\t$data['namaMahasiswa'] = $rowMahasiswa['nama'];\n\t\t\t$data['npmMahasiswa'] = $rowMahasiswa['npm'];\n\t\t\t$data['emailMahasiswa'] = $rowMahasiswa['email'];\n\t\t\t$data['npmMahasiswa'] = $rowMahasiswa['npm'];\n\t\t\t$data['npmMahasiswa'] = $rowMahasiswa['npm'];\n\t\t\t$data['jurusan'] = $rowMahasiswa['id_jurusan'];\n\t\t}\n\t\t$data['pilihanJurusan'] = $this->admin->get_data_jurusan()->result_array();\n\t\treturn $data;\n\t}", "title": "" }, { "docid": "211e9c8bf2ea9a85f56c1d7a0ec892f0", "score": "0.6574805", "text": "public function getDataUmum()\n {\n return DataTables::of(DataUmum::with(['Kecamatan'])->select(['id', 'kecamatan_id', 'tipologi', 'luas_wilayah', 'jumlah_penduduk','bts_wil_utara','bts_wil_timur','bts_wil_selatan','bts_wil_barat'])->get())\n ->addColumn( 'action', function ( $data ) {\n $edit_url = route('data.data-umum.edit', $data->id );\n\n $data['edit_url'] = $edit_url;\n\n return view('forms.action', $data);\n })\n ->make();\n }", "title": "" }, { "docid": "a189acd784253aaa4f0653ecf9e6b591", "score": "0.65712327", "text": "public function stok(){\n\n $hasil = $this->admin_model->ambilDataStok();\n $data['hasil'] = $hasil;\n\n $this->load->view('admin/header');\n $this->load->view('admin/stok', $data);\n $this->load->view('front/footer');\n\n }", "title": "" }, { "docid": "7ca430abab2fa9e61c97b3013b9860ed", "score": "0.65659374", "text": "public function data_matkul(){\n\t\t$tahun = \"t_tahun_akademik\";\n\t\t$mk = \"t_mk\";\n\t\t$data['content'] = \"report/matkul\";\n\t\t$data['data_tahun'] = $this->m_aka->get_all($tahun);\n\t\t$data['mk'] = $this->m_aka->get_all($mk);\n\t\t$this->load->view(\"content\", $data);\n\t}", "title": "" }, { "docid": "2fedd253cdcff3417717b565cee6ea31", "score": "0.65656084", "text": "public function anggotaKom_list()\n\t{\n\t\t$requestData\t= $_REQUEST;\n\t\t$fetch\t\t\t= $this->model_anggota->anggota_by_data($requestData['search']['value'], $requestData['order'][0]['column'], $requestData['order'][0]['dir'], $requestData['start'], $requestData['length']);\n\t\t$totalData\t\t= $fetch['totalData'];\n\t\t$totalFiltered\t= $fetch['totalFiltered'];\n\t\t$query\t\t\t= $fetch['query'];\n\n\t\t$data\t= array();\n\t\tforeach ($query->result_array() as $row) {\n\t\t\t$datanya = array();\n\t\t\t$datanya[]\t= $row['nomora'];\n\t\t\t$datanya[]\t= $row['nama_kader'];\n\t\t\t$datanya[]\t= $row['alamat'];\n\t\t\t$datanya[]\t= $row['no_hp'];\n\t\t\t$datanya[]\t= [$row['tmp_lahir'], \" \" . date(\"d-m-Y\", strtotime($row['tgl_lahir']))];\n\t\t\tif ($this->session->userdata['jenis'] == 4) {\n\t\t\t\t$datanya[]\t= $row['nama_komisariat'];\n\t\t\t}\n\t\t\t$datanya[] = '<a class=\"btn btn-warning btn-sm\" href=\"javascript:void(0)\" title=\"Ubah\" onclick=\"anggota_ubah(' . \"'\" . $row['id'] . \"'\" . ')\"><i class=\"fa fa-edit\"></i></a>\n\t\t\t <button class=\"btn btn-danger btn-sm konfirmasiHapus-anggota\" data-id=\"' . $row['id'] . '\" data-toggle=\"modal\" data-target=\"#konfirmasiHapus\"><i class=\"fa fa-trash\"></i></button>\n\t\t\t <a class=\"btn btn-sm btn-secondary\" href=\"javascript:void(0)\" title=\"Detail Username\" onclick=\"detail_username(' . \"'\" . $row['id'] . \"'\" . ')\"><i class=\"fa fa-user\"></i></a>\n\t\t\t <button class=\"btn btn-dark btn-sm konfirmasiReset-anggota\" title=\"Reset Username dan password kedefault\" data-id=\"' . $row['id'] . '\" data-toggle=\"modal\" data-target=\"#konfirmasiReset\"><i class=\"fa fa-key\"></i></button>\n\t\t\t <a class=\"btn btn-sm btn-info\" href=\"javascript:void(0)\" title=\"Detail lengkap Anggota\" onclick=\"detail_anggota(' . \"'\" . $row['id'] . \"'\" . ')\"><i class=\"fa fa-info-circle\"></i></a>\n\t\t\t ';\n\n\t\t\t$data[] = $datanya;\n\t\t}\n\n\t\t$json_data = array(\n\t\t\t\"draw\" => intval($requestData['draw']),\n\t\t\t\"recordsTotal\" => intval($totalData),\n\t\t\t\"recordsFiltered\" => intval($totalFiltered),\n\t\t\t\"data\" => $data\n\t\t);\n\n\t\techo json_encode($json_data);\n\t}", "title": "" }, { "docid": "28b1e2ae9bc104dfc2464df14abd0471", "score": "0.6563374", "text": "public function index()\n {\n //bisa menggunakan tanggal atau created_at\n $data_tamu=DB::table('tamu')\n ->whereDate('tanggal',now())\n ->get();\n\n // menggunakan lambang\"=>\" untuk pengambilan data \n return view('tamu',['data_tamu'=>$data_tamu]);\n }", "title": "" }, { "docid": "6a0c4a300f9a95011eed278d7da44ed8", "score": "0.65604806", "text": "function data($jenis, $detail = null, $action = null){\n\t\t\t\n\t\t$jenis = $this->security->xss_clean($this->uri->segment(5));\n\t\t$data['kode'] = $jenis;\n\t\t# set parameters \n\t\t$kd_dosen = $this->session->userdata(\"kd_dosen\");\n\t\t$thn = $this->session->userdata(\"ta\");\n\t\t$smt = $this->session->userdata(\"smt\");\n\t\t$status = $this->session->userdata(\"jenis_dosen\");\n\t\t\n\t\t$kd_ta = $this->setting->_generate_kd_ta($thn);\n\t\t$kd_smt = $this->setting->_generate_kd_smt($smt);\n\t\t\n\t\t $data['is_crud'] = $this->setting->_is_crud_bkd_lalu($kd_ta, $kd_smt);\n\t\t/*if($data['is_crud'] == 1){\n\t\t\t$data['tombol'] = 'style=\"display:block\"';\n\t\t}else{\n\t\t\t$data['tombol'] = 'style=\"display:none\"';\n\t\t} */\n\t\t\t\t\n\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/get_jadwal';\n\t\t$parameter = array();\n\t\t$jadwal = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\tif(!empty($jadwal)){\n\t\t\t$data['tombol'] = 'style=\"display:block\"';\n\t\t}else{\n\t\t\t$data['tombol'] = 'style=\"display:none\"';\n\t\t\t$data['tombol2'] = 'style=\"display:;\"';\n\t\t\t$data['tombol3'] = 'style=\"display:;pointer-events:none; cursor:default;\"';\n\t\t}\t\n\t\t\n\t\tif ($detail !== null){\n\t\t\tif ($action !== ''){\n\t\t\t\tswitch ($action){\n\t\t\t\t\tcase 'penugasan-isi': $data['view'] = 'dosen/isi_dokumen'; break;\n\t\t\t\t\tcase 'penugasan-cari': {\n\t\t\t\t\t\t\t$data['view'] = 'dosen/cari_dokumen';\n\t\t\t\t\t\t}break;\n\t\t\t\t\tcase 'penugasan-upload': $data['view'] = 'dosen/upload_dokumen'; break;\n\t\t\t\t\tcase 'kinerja-isi': $data['view'] = 'dosen/isi_dokumen'; break;\n\t\t\t\t\tcase 'kinerja-cari': {\n\t\t\t\t\t\t\t$data['view'] = 'dosen/cari_dokumen'; \n\t\t\t\t\t}break;\n\t\t\t\t\tcase 'kinerja-upload': $data['view'] = 'dosen/upload_dokumen'; break;\n\t\t\t\t\tdefault : $data['view'] = 'dosen/isi_dokumen'; break;\n\t\t\t\t}\n\t\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/current_data_bkd';\n\t\t\t\t$parameter = array('api_search' => array($detail, $data['kode']));\n\t\t\t\t$data['current_data'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\n\t\t\t\t# GET PARTNER\n\t\t\t\t$api_url \t= URL_API_BKD.'bkd_dosen/partner';\n\t\t\t\t$parameter = array('api_kode' => 11000, 'api_subkode' => 1, 'api_search' => array($detail,'PENELITIAN'));\n\t\t\t\t$data['partner'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t\t\t\n\t\t\t\t$data['nama_partner'] = array();\n\t\t\t\tforeach ($data['partner'] as $p){\n\t\t\t\t\t$data['nama_partner'][$p->PARTNER] = $this->get_nama_partner($p->PARTNER);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/current_data_bkd';\n\t\t\t$parameter = array('api_search' => array($detail, $data['kode']));\n\t\t\t$data['current_data'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t}\n\t\t\n\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/data_bebankerja';\n\t\t$parameter = array('api_search' => array($data['kode'], $kd_dosen, $thn, $smt));\n\t\t$data['data_beban'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\n\t\t// $temp_sks =0;\n\t\t// foreach ($data['data_beban'] as $key) {\n\t\t// \t$n_sks = (float) str_replace(\",\", \".\", $key->SKS_BKT);\n\t\t// \t$temp_sks +=$n_sks;\n\t\t// }\n\t\t\n\t\t//berubah dari sini \n\t\t//============================================\n\t\t$temp_sks = array();\n\t\tforeach ($data['data_beban'] as $key) {\n\t\t\t$n_sks = (float) str_replace(\",\", \".\", $key->SKS_BKT);\n\t\t\t//$temp_sks +=$n_sks;\n\n\t\t\tif(isset($temp_sks[$key->KD_KAT])){\n\t\t\t\t$temp_sks[$key->KD_KAT] += $n_sks;\n\t\t\t}else{\n\t\t\t\t$temp_sks[$key->KD_KAT] = $n_sks;\n\t\t\t}\n\t\t}\n\n\t\t//===========================================\n\n\n\n\t\t$kd=$this->session->userdata('kd_dosen');\n\t\t$ta = $this->session->userdata('kd_ta');\n\t\t$smt = $this->session->userdata('kd_smt');\n\n\t\t$kd_ta = $this->_generate_ta($ta);\n\t\t$kd_smt = $this->_generate_smt($smt);\n\t\t$this->session->unset_userdata('jenis_dosen');\n\t\t$this->session->set_userdata('jenis_dosen', $this->history->_status_DS($kd, $kd_ta, $kd_smt));\n\n\t\t\n\t\tswitch ($jenis) {\n\t\t\tcase 'A':\n\t\t\t\t$subkode = 1;//syarat pendidikan\n\t\t\t\tbreak;\n\t\t\tcase 'B':\n\t\t\t\t$subkode = 2;//syarat penelitian\n\t\t\t\tbreak;\n\t\t\tcase 'C':\n\t\t\t\t$subkode = 3;//syarat pengabdian\n\t\t\t\tbreak;\n\t\t\tcase 'D': case 'F': case 'H':\n\t\t\t\t$subkode = 4;//syarat penunjang\n\t\t\t\tbreak;\n\n\t\t}\n\t\t//get syarat dari API\n\t\t\t$syarat_minimal = $this->s00_lib_api->get_api_json(\n\t\t\t\t\t\tURL_API_BKD.'/bkd_beban_kerja/get_syarat_kesimpulan',\n\t\t\t\t\t\t'POST',\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'api_kode' => 1000,\n\t\t\t\t\t\t\t'api_subkode' => $subkode, //untuk PENDIDIKAN\n\t\t\t\t\t\t\t'api_search' => array($this->history->_status_DS($kd, $kd_ta, $kd_smt))\n\t\t\t\t\t\t)\n\t\t\t\t\t);\n\t\t\n\t\t//$temp_sks;\n\t\tif(isset($syarat_minimal['NILAI'])){\n\t\t\t$syarat_sks = $syarat_minimal['NILAI'];\n\t\t}else{\n\t\t\t$syarat_sks = 0;\n\t\t}\n\t\t\n\t\t$i=0;\n\t\tforeach ($data['data_beban'] as $key) {\n\t\t\t$kd_bk = $key->KD_BK;\n\t\t\t$kd_kat = $key->KD_KAT;\n\t\t\t$status_pindah = $key->STATUS_PINDAH;\n\t\t\tif($status_pindah == 1){\n\t\t\t\t$kd_kat_remun = $kd_kat;\n\t\t\t}elseif($status_pindah == 0){\n\t\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/get_kd_kat_remun2';\n\t\t\t\t$parameter = array('api_search' => array($kd_kat));\n\t\t\t\t$kd_kat_remun = $this->s00_lib_api->get_api_json($api_url,'POST',$parameter);\n\t\t\t}\n\n\t\t\t//=======\n\n\t\t\t$temp_syarat = $this->s00_lib_api->get_api_json(\n\t\t\t\t\t\tURL_API_BKD.'/bkd_beban_kerja/get_syarat_kesimpulan_kat',\n\t\t\t\t\t\t'POST',\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'api_kode' => 1000,\n\t\t\t\t\t\t\t'api_subkode' => $subkode, //untuk PENDIDIKAN\n\t\t\t\t\t\t\t'api_search' => array($this->history->_status_DS($kd, $kd_ta, $kd_smt), $kd_kat)\n\t\t\t\t\t\t)\n\t\t\t\t\t);\n\n\t\t\t$data['data_beban'][$i]->MINIMAL_SKS = $temp_syarat;\n\n\t\t\t//=======\n\n\t\t\t$data['data_beban'][$i]->KD_KAT_REMUN = $kd_kat_remun;\n\t\t\tif((($temp_sks[$kd_kat] - $data['data_beban'][$i]->SKS_BKT) >= $temp_syarat) AND $data['data_beban'][$i]->STATUS_PINDAH==0){\n\t\t\t\t$data['data_beban'][$i]->SYARAT_PINDAH = 1;//dapat dipindah\n\t\t\t}else{\n\t\t\t\t$data['data_beban'][$i]->SYARAT_PINDAH = 0;//tidak dapat dipindah\n\t\t\t}\n\t\t\t\n\t\t\t$i++;\n\t\t\t/*echo \"<pre>\";\n\t\t\tprint_r($key);\n\t\t\techo \"<pre>\";*/\n\n\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/get_kd_kat';\n\t\t\t$parameter \t= array('api_search'=>array($kd_bk));\n\t\t\t$kd_kat = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\n\t\t\t//cek di tabel konversi apakah kd_kat memiliki kd_kat remun\n\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/cek_kd_konversi';\n\t\t\t$parameter \t= array('api_search'=>array($kd_kat));\n\t\t\t$data['konversi'][$kd_kat] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t}\n\n\t\t// echo '<pre>';\n\t\t// print_r($data['data_beban']);\n\t\t// echo '</pre>';\n\n\t\t// die();\n\n\t\t/*die();*/\n\t\t/*\n\n\t\tdie();*/\n\t\t#print_r($data['data_beban']);\n\t\t# load view\n\n\t\t/*mekanisme cek data asesor, untuk melihat apakah dosen sudah mengisi data asesor atau belum*/\n\t\t$data['nira'] = $this->get_data_asesor_dosen_by_nip();\n\t\t\n\t\t$this->cek_nira_asesor_dosen_uin();\n\t\t$this->auto_insert_penelitian();\n\n\t\t/*$this->auto_insert_pengabdian();*/ /*SUDAH BISA INSERT TINGGAL TUNGGU KEPUTUSAN DATA PENGABDIAN*/\n\n\t\t$this->output99->output_display('dosen/daftar_beban_kerja',$data);\n\t}", "title": "" }, { "docid": "441ab2ad66e4439cab3259bad2c8060f", "score": "0.65603757", "text": "public function getAllMahasiswa(){\n // melakukan prepare query\n $this->db->query('SELECT * FROM '. $this->tabel);\n // eksekusi query dan mengambil semua data mahasiswa\n return $this->db->resultAll();\n }", "title": "" }, { "docid": "710452d6371fe249fb08317d8ebf1242", "score": "0.6559371", "text": "public function k_yazar()\n {\n $result = $this->dtbs->list('k_yazar');\n $data['info'] = $result;\n $this->load->view('back/k_yazar/anasehife',$data);\n }", "title": "" }, { "docid": "786008e5cc890ed8eeb4ee4be53ee7e5", "score": "0.6546973", "text": "public function informasi()\n {\n //Query untuk mengambil semua data informasi yang diuurutkan berdasarkan tanggal\n $query = $this->db->query(\"SELECT A.tanggal, A.subject, A.pesan, A.id_informasi, C.nama FROM informasi A \n LEFT JOIN karyawan C ON C.nik = A.id_user\n ORDER BY A.tanggal DESC\");\n return $query;\n }", "title": "" }, { "docid": "711f270ffb9eb00cd2310f79fc41fb67", "score": "0.65442497", "text": "function getDataSingkatPrakt($conn,$key,$pengajar=true,$nip='') {\n\t\t\t$sql = \"select k.thnkurikulum, k.kodemk, k.kodeunit, k.periode, k.kelasmk, k.koderuang,\n\t\t\t\t\tk.nohari, k.jammulai, k.jamselesai, c.namamk\n\t\t\t\t\tfrom \".static::table('ak_kelaspraktikum').\" k join \".static::table('ak_kurikulum').\" c using (thnkurikulum,kodemk,kodeunit)\n\t\t\t\t\twhere \".static::getCondition($key,null,'k');\n\t\t\t$row = $conn->GetRow($sql);\n\t\t\t\n\t\t\t$row['jadwal'] = Date::indoDay($row['nohari']).', '.CStr::formatjam($row['jammulai']).' - '.CStr::formatjam($row['jamselesai']);\n\t\t\t//$row['jadwal2'] = Date::indoDay($row['nohari2']).', '.CStr::formatjam($row['jammulai2']).' - '.CStr::formatjam($row['jamselesai2']);\n\t\t\t\t\n\t\t\t// ambil data pengajar\n\t\t\tif($pengajar) {\n\t\t\t\t$sql = \"select p.idpegawai::text as nipdosen, akademik.f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as nama from \".static::table('ak_mengajar').\" a\n\t\t\t\t\t\tjoin sdm.ms_pegawai p on a.nipdosen::text = p.idpegawai::text\n\t\t\t\t\t\twhere \".static::getCondition($key,null,'a').\" order by a.nipdosen\";\n\t\t\t\t$rs = $conn->Execute($sql);\n\t\t\t\t\n\t\t\t\t$a_ajar = array();\n\t\t\t\twhile($rowa = $rs->FetchRow())\n\t\t\t\t\t$a_ajar[] = $rowa['nama'].' ('.$rowa['nipdosen'].')';\n\t\t\t\t\n\t\t\t\t$row['pengajar'] = implode('<br>',$a_ajar);\n\t\t\t}\n\t\t\tif(!empty($nip)){\n\t\t\t\t$sql = \"select idpegawai::text as nik, akademik.f_namalengkap(gelardepan,namadepan,namatengah,namabelakang,gelarbelakang) as nama \n\t\t\t\t\t\tfrom sdm.ms_pegawai where nik='$nip' or idpegawai::text='$nip'\";\n\t\t\t\t$rs=$conn->GetRow($sql);\n\t\t\t\t$row['pengajar'] =$rs['nama'].\" (\".$rs['nik'].\")\";\n\t\t\t}\n\t\t\treturn $row;\n\t\t}", "title": "" }, { "docid": "8bb56dbc86a47f15b1ce28e3756139bf", "score": "0.65428793", "text": "public function content_pengiriman_otw($id_cabang)\n {\n $query = \"\n select id_pk_penerimaan,id_pk_brg_pemenuhan,id_pk_brg_pengiriman,brg_pengiriman_qty,brg_pengiriman_note,brg_pemenuhan_status,pengiriman_tgl,cabang_daerah,toko_nama,toko_kode,brg_nama,brg_kode,ifnull(penerimaan_tgl,'-') as penerimaan_tgl\n from tbl_brg_pengiriman\n inner join mstr_pengiriman on mstr_pengiriman.id_pk_pengiriman = tbl_brg_pengiriman.id_fk_pengiriman and mstr_pengiriman.pengiriman_status = 'aktif' #harus yang jadi terkirim bukan yang dicancel\n inner join mstr_cabang on mstr_cabang.id_pk_cabang = mstr_pengiriman.id_fk_cabang #dapetin daerah cabang\n inner join mstr_toko on mstr_toko.id_pk_toko = mstr_cabang.id_fk_toko #dapetin nama toko\n inner join tbl_brg_pemenuhan on tbl_brg_pemenuhan.id_pk_brg_pemenuhan = tbl_brg_pengiriman.id_fk_brg_pemenuhan #cuman untuk dapetin id_cabang_minta & id_barang\n inner join tbl_brg_permintaan on tbl_brg_permintaan.id_pk_brg_permintaan = tbl_brg_pemenuhan.id_fk_brg_permintaan and tbl_brg_permintaan.id_fk_cabang = ? #menentukan peminta barang yang akan jadi penerima\n inner join mstr_barang on mstr_barang.id_pk_brg = tbl_brg_permintaan.id_fk_brg #dapetin detail barang\n left join tbl_brg_penerimaan on tbl_brg_penerimaan.id_fk_brg_pengiriman = tbl_brg_pengiriman.id_pk_brg_pengiriman and tbl_brg_penerimaan.brg_penerimaan_qty > 0 #dianggap diterima apabila brgditerima > 0 (klo delete, ini ke 0 sendiri)\n left join mstr_penerimaan on mstr_penerimaan.id_pk_penerimaan = tbl_brg_penerimaan.id_fk_penerimaan and mstr_penerimaan.penerimaan_status = 'aktif' and mstr_penerimaan.penerimaan_tipe = 'permintaan' #dianggap diterima apabila status penerimaan > 0\n where tbl_brg_pengiriman.brg_pengiriman_qty > 0 #dianggap terkirim apabila tidak di cancel (klo cancel, qty jadi 0)\n and brg_pemenuhan_status = 'perjalanan'\n union\n select id_pk_penerimaan,id_pk_brg_pemenuhan,id_pk_brg_pengiriman,brg_pengiriman_qty,brg_pengiriman_note,brg_pemenuhan_status,pengiriman_tgl,warehouse_alamat as cabang_daerah,warehouse_nama as toko_nama,'-' as toko_kode,brg_nama,brg_kode,ifnull(penerimaan_tgl,'-') as penerimaan_tgl\n from tbl_brg_pengiriman\n inner join mstr_pengiriman on mstr_pengiriman.id_pk_pengiriman = tbl_brg_pengiriman.id_fk_pengiriman and mstr_pengiriman.pengiriman_status = 'aktif' #harus yang jadi terkirim bukan yang dicancel\n inner join mstr_warehouse on mstr_warehouse.id_pk_warehouse = mstr_pengiriman.id_fk_warehouse\n inner join mstr_cabang on mstr_cabang.id_pk_cabang = mstr_warehouse.id_fk_cabang #dapetin daerah cabang\n inner join mstr_toko on mstr_toko.id_pk_toko = mstr_cabang.id_fk_toko #dapetin nama toko\n inner join tbl_brg_pemenuhan on tbl_brg_pemenuhan.id_pk_brg_pemenuhan = tbl_brg_pengiriman.id_fk_brg_pemenuhan #cuman untuk dapetin id_cabang_minta & id_barang\n inner join tbl_brg_permintaan on tbl_brg_permintaan.id_pk_brg_permintaan = tbl_brg_pemenuhan.id_fk_brg_permintaan and tbl_brg_permintaan.id_fk_cabang = ? #menentukan peminta barang yang akan jadi penerima\n inner join mstr_barang on mstr_barang.id_pk_brg = tbl_brg_permintaan.id_fk_brg #dapetin detail barang\n left join tbl_brg_penerimaan on tbl_brg_penerimaan.id_fk_brg_pengiriman = tbl_brg_pengiriman.id_pk_brg_pengiriman and tbl_brg_penerimaan.brg_penerimaan_qty > 0 #dianggap diterima apabila brgditerima > 0 (klo delete, ini ke 0 sendiri)\n left join mstr_penerimaan on mstr_penerimaan.id_pk_penerimaan = tbl_brg_penerimaan.id_fk_penerimaan and mstr_penerimaan.penerimaan_status = 'aktif' and mstr_penerimaan.penerimaan_tipe = 'permintaan' #dianggap diterima apabila status penerimaan > 0\n where tbl_brg_pengiriman.brg_pengiriman_qty > 0 #dianggap terkirim apabila tidak di cancel (klo cancel, qty jadi 0)\n and brg_pemenuhan_status = 'perjalanan'\n order by pengiriman_tgl DESC\";\n $args = array(\n $id_cabang, $id_cabang\n );\n //executeQuery($query,$args); echo $this->db->last_query();\n return executeQuery($query, $args);\n }", "title": "" }, { "docid": "1498eae49f6320c1f3a42e0357600121", "score": "0.6534318", "text": "function select_tb_penduduk(){\n\t\t$this->load->model('mamdani');\n\t\t//$klasifikasi['klasifikasi']=$this->mamdani->getdata();\n\t\t$klasifikasi['jumlah_aset']=$this->mamdani->jumlah_aset();\n\t\t$klasifikasi['tingkat']= $this->mamdani->klasifikasi3();\n\n\t\t$this->load->view('templates/header');\n\t\t$this->load->view('admin/lihatdata/tabel_klasifikasi_penduduk',$klasifikasi);\n\t\t$this->load->view('templates/footer');\n\t\t// var_dump($jml_aset);\n\t\t// die;\n\n\t}", "title": "" }, { "docid": "aba18b394de31eaa1b6d0842b7f2b2d6", "score": "0.6532719", "text": "function datagolongan() {\n\t\t\t\t$koneksi = $this->koneksi;\n\t\t\t\t// SQL\n\t\t\t\t$query\t\t\t= \"SELECT * FROM golongan\";\n\t\t\t\t\n\t\t\t\t$sql\t\t\t= mysqli_query($koneksi,$query);\n\t\t\t\t\n\t\t\t\treturn $sql;\n\t\t\t}", "title": "" }, { "docid": "0849f58647931053e934ffcfd099a498", "score": "0.6529235", "text": "public function get_data(){\n // $id = 2;\n // $stmt = $this->verivied()->prepare(\"SELECT * FROM emptab WHERE id= :id\");\n // $stmt->bindParam(':id', $id);\n // $stmt->execute();\n // $data = $stmt->fetchAll(PDO::FETCH_ASSOC);\n // return $data;\n // select by id;\n $data1 = $this->Xgen->select('id,nama')->from('emptab')->where('id = :id', 4)->go();\n // select all;\n //$data = $this->Xgen->select('id,nama')->from('emptab')->go();\n // inser data\n // $data = $this->Xgen->insert_query('emptab',[\n // 'nama' => 'bxel'\n // ])->go();\n //update data\n //$data = $this->Xgen->update_query('emptab', ['nama' => 'new name'])->where('id = :id', 4)->go();\n //DELETE\n //$data1 = $this->Xgen->delete('emptab','id = :id',4)->go();\n\n }", "title": "" }, { "docid": "54c47fc57b97ab56b781d5ed34e1f681", "score": "0.6522247", "text": "public function karyawan(){\n $this->setActualJadwal(TRUE);\n $this->load->model('jadwal_detail_model', 'jdm');\n $periodeTerpilih = $this->input->post('periode');\n if(empty($periodeTerpilih)){\n $tanggalTerpilih = date('Y-m-d');\n }else{\n $tanggalTerpilih = date($periodeTerpilih.'-01');\n }\n \n $idJadwal = $this->jdm->fields(['jadwal_id'])->get_by(['nik' => $this->getNIK(), 'tanggalabsensi' => $tanggalTerpilih]);\n if(!empty($idJadwal)){\n $this->load->model('User_model', 'um');\n $_POST['key'] = ['id' => $idJadwal->jadwal_id];\n $bawahan = $this->getBawahan();\n $nikBawahan = array_column($this->um->as_array()->fields('ref_nik')->get_many(array_keys($bawahan)),'ref_nik');\n $this->setFilterNik($nikBawahan);\n $this->setMarkToday(TRUE);\n $this->edit();\n }else{\n echo 'Data jadwal tidak ditemukan untuk tanggal '.tglIndonesia($tanggalTerpilih);\n }\n }", "title": "" }, { "docid": "53db2ef6e5acfc16280160c9ac5ea951", "score": "0.6522008", "text": "function HapusDataPromosi()\n\t{\n\t\tinclude '../../koneksi/koneksi.php';\n\n\t\t//inisialisasi\n\t\t$id_promosi = $_GET['id_promosi'];\n\n\t\t//hapus dari tabel produk\n\t\t$sql = \"DELETE FROM promosi WHERE id_promosi = ?\";\n\t\t$stmt = $db->prepare($sql);\n\t\t$stmt->bind_param('i', $id_promosi);\n\t\tif($stmt->execute()){\n\t\t\t$_SESSION['status_operasi_promosi'] = \"berhasil_menghapus\";\n\t\t}else{\n\t\t\t$_SESSION['status_operasi_promosi'] = \"gagal_menghapus\";\n\t\t}\n\t\t$stmt->close();\n\t}", "title": "" }, { "docid": "4b3f641e2036287bdc2f699058a45454", "score": "0.6520994", "text": "public function tampil()\n\t{\t\n\t\t\n\t\t$this->session->set_userdata(\"judul\",\"Data Master\");\n\t\t$ba = [\n\t\t'judul' => \"Data Master\",\n\t\t'subjudul' => \"Pasien\",\n\t\t];\n\t\t$d = [\n\t\t'gelar' => $this->pasien->get_enum(\"srk_pasien\", \"psn_gelar\"),\n\t\t'jk' => $this->pasien->get_enum(\"srk_pasien\", \"psn_jk\"),\n\t\t'jkitas' => $this->pasien->get_enum(\"srk_pasien\", \"psn_jkitas\"),\n\t\t];\n\t\t$this->load->helper('url');\n\t\t$this->load->view('background_atas', $ba);\n\t\t$this->load->view('pasien',$d);\n\t\t$this->load->view('background_bawah');\n\t}", "title": "" }, { "docid": "903f973438002be98b66ab95ccf1957a", "score": "0.6520305", "text": "function getData($id){\n // ineed to be more clear about where to get this data because i need to nkow where i should pick up this data from?\n return $this->db->get_where(\"mahasiswa\",array('nim' => $id))->row();\n }", "title": "" }, { "docid": "e7eaad5f02307f6802a29ca2bb9d6ca1", "score": "0.65191483", "text": "public function get_data()\n {\n $post = $this->input->post(null, true);\n if ($post) {\n // ambil data dari model\n $list = $this->hasil->get_datatables();\n $data = array();\n $no = $post['start'];\n foreach ($list as $field) {\n $no++;\n $row = array();\n $row[] = $no;\n $row[] = $field->nama_akun;\n $row[] = $this->date->tanggal($field->tgl, 's');\n $row[] = $field->nilai;\n $data[] = $row;\n }\n\n $output = array(\n \"draw\" => $post['draw'],\n \"recordsTotal\" => $this->hasil->count_all(),\n \"recordsFiltered\" => $this->hasil->count_filtered(),\n \"data\" => $data,\n );\n // tampilkan data\n echo json_encode($output);\n } else {\n $this->index();\n }\n }", "title": "" }, { "docid": "273e46ff3c086b292af266e6be6e2180", "score": "0.6518706", "text": "function auto_menguji_ta(){\n\t\t\t\t$ta = $this->session->userdata('kd_ta');\n\t\t\t\t$smt = $this->session->userdata('kd_smt');\n\n\t\t\t\t$data = $this->get_current_ujian_ta(2); //mengambil data menguji tugas akhir pada semester ini (2)\n\n\t\t\t\tforeach ($data as $ta) {\n\t\t\t\t\t$cek_nilai_mhs = $this->get_status_ta($ta['NIM']);\n\t\t\t\t\tif($cek_nilai_mhs){\n\t\t\t\t\t\t$nim = $ta['NIM'];\n\t\t\t\t\t\t$judul_ta = $ta['JUDUL'];\n\t\t\t\t\t\t$kd_kur_mhs = $this->kurikulum_mahasiswa($nim);\n\t\t\t\t\t\t$temp = $this->get_data_mhs($nim);\n\t\t\t\t\t\t$jenjang = $temp[0]['NM_JENJANG'];\n\t\t\t\t\t\t$prodi = $temp[0]['NM_PRODI'];\n\t\t\t\t\t\t$prodi = str_replace(\"'\", \"\", $prodi);\n\t\t\t\t\t\t$prodi = strip_tags($prodi);\n\n\t\t\t\t\t\t$list_mk = $this->api->get_api_json(\n\t\t\t\t\t\t\tURL_API_SIA.'sia_kurikulum/data_search',\n\t\t\t\t\t\t\t'POST',\n\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t'api_kode'=>40000,\n\t\t\t\t\t\t\t\t'api_subkode' => 15,\n\t\t\t\t\t\t\t\t'api_search' => array($kd_kur_mhs)\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t);\n\n\t\t\t\t\t\tforeach ($list_mk as $mk) {\n\t\t\t\t\t\t\t$get_makul = strtoupper($mk['NM_MK']);\n\t\t\t\t\t\t\t$get_jenjang = strtoupper($mk['NM_PEND']);\n\t\t\t\t\t\t\tif($get_jenjang == \"S0\"){\n\t\t\t\t\t\t\t\tif($get_makul == \"TUGAS AKHIR\" || $get_makul == \"SKRIPSI\" || $get_makul == \"TUGAS AKHIR/SKRIPSI\" || $get_makul == \"SKRIPSI/TUGAS AKHIR\"){\n\t\t\t\t\t\t\t\t\t$jml_sks = $mk['SKS_MK'];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}else if($get_jenjang == \"S1\"){\n\t\t\t\t\t\t\t\tif($get_makul == \"TUGAS AKHIR\" || $get_makul == \"SKRIPSI\" || $get_makul == \"TUGAS AKHIR/SKRIPSI\" || $get_makul == \"SKRIPSI/TUGAS AKHIR\"){\n\t\t\t\t\t\t\t\t\t$jml_sks = $mk['SKS_MK'];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}else if($get_jenjang==\"S2\"){\n\t\t\t\t\t\t\t\tif($get_makul == \"TESIS\" || $get_makul == \"TESIS/TUGAS AKHIR\" || $get_makul == \"TUGAS AKHIR/TESIS\"){\n\t\t\t\t\t\t\t\t\t$jml_sks = $mk['SKS_MK'];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}else if($get_jenjang==\"S3\"){\n\t\t\t\t\t\t\t\tif($get_makul == \"DISERTASI\" || $get_makul == \"DISERTASI/TUGAS AKHIR\" || $get_makul == \"TUGAS AKHIR/DISERTASI\"){\n\t\t\t\t\t\t\t\t\t$jml_sks = $mk['SKS_MK'];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t//BUAT NARASI + INPUT DATA KE DB + ADA CEK DUPLUKASI DATA :\n\n\t\t\t\t\t\t$narasi = \"Menguji Tugas Akhir \".$jenjang.\", Program Studi \".$prodi.\", Judul \".$judul_ta.\", \".$jml_sks.\" SKS\";\n\t\t\t\t\t\t$narasi = str_replace(\"'\", \"\", $narasi);\n\t\t\t\t\t\t$narasi = strip_tags($narasi);\n\t\t\t\t\t\t//$narasi = str_replace(\",\", \"\", $narasi);\n\t\t\t\t\t\t//$sks_rule = round($this->aturan_beban_sks2(strtoupper($jenjang), $jml_sks, 1, 'TUGAS_AKHIR'),2);\n\t\t\t\t\t\t$jml_mhs = 1;\n\n\t\t\t\t\t\t//ATURAN SKS_RULE UNTUK MENGUJI TA\n\t\t\t\t\t\t$kd_kat = '74'; //4 untuk menguji (sebagai ketua dan anggota)\n\t\t\t\t\t\tif($jenjang == 'S0'){\n\t\t\t\t\t\t\t//sks_rule sementara untuk menguji TA S0 \n\t\t\t\t\t\t\t//$sks_rule = round(($sks_rule*(0.5)), 2);\n\t\t\t\t\t\t\t$sks_rule \t= $this->sksrule->_nilai_sks($jml_mhs, 1003, 2);\n\t\t\t\t\t\t\t$kd_kat = '74';\n\t\t\t\t\t\t}elseif($jenjang == 'S1'){\n\t\t\t\t\t\t\t//sks_rule sementara untuk menguji TA S0 \n\t\t\t\t\t\t\t//$sks_rule = round(($sks_rule*(0.5)), 2);\n\t\t\t\t\t\t\t$sks_rule \t= $this->sksrule->_nilai_sks($jml_mhs, 1003, 2);\n\t\t\t\t\t\t\t$kd_kat = '74';\n\t\t\t\t\t\t}\n\t\t\t\t\t\telseif($jenjang == 'S2'){\n\t\t\t\t\t\t\t//$sks_rule = round(($sks_rule*(0.5)), 2);\n\t\t\t\t\t\t\t$sks_rule \t= $this->sksrule->_nilai_sks($jml_mhs, 1003, 3);\n\t\t\t\t\t\t\t$kd_kat = '74'; //74 untuk menguji sebagai anggota\n\t\t\t\t\t\t}elseif($jenjang == 'S3'){\n\t\t\t\t\t\t\t//$sks_rule = round(($sks_rule*(0.5)), 2);\n\t\t\t\t\t\t\t$sks_rule \t= $this->sksrule->_nilai_sks($jml_mhs, 1003, 4);\n\t\t\t\t\t\t\t$kd_kat = '74'; //74 untuk menguji sebagai anggota\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$smt = $this->session->userdata('kd_smt');\n\t\t\t\t\t\t$ta = $this->session->userdata('kd_ta');\n\n\t\t\t\t\t\t// $kd_jbk = 'A';\n\t\t\t\t\t\t$kd_dosen = $this->session->userdata('kd_dosen');\n\t\t\t\t\t\t$jenis_kegiatan = $narasi;\n\t\t\t\t\t\t/*$jenis_kegiatan ='test';*/\n\t\t\t\t\t\t$bukti_penugasan = '-';\n\t\t\t\t\t\t// $sks_penugasan = $sks_rule;\n\t\t\t\t\t\t$masa_penugasan = '1 Semester';\n\t\t\t\t\t\t$bkt_dokumen = '-';\n\t\t\t\t\t\t$kd_jbk \t\t= 'A';\n\t\t\t\t\t\t$bkt_penugasan \t= '-';\n\t\t\t\t\t\t$bkt_dokumen \t= '-';\n\t\t\t\t\t\t$rekomendasi \t= 'LANJUTKAN';\n\t\t\t\t\t\t$capaian \t\t= 100;\n\t\t\t\t\t\t$jml_jam \t\t= 1;\n\t\t\t\t\t\t$outcome \t\t= '-';\n\t\t\t\t\t\t$file_penugasan = '-';\n\t\t\t\t\t\t$file_capaian \t= '-';\n\t\t\t\t\t\t// $sks_bkt = $sks_rule;\n\t\t\t\t\t\t$thn = $this->session->userdata('ta');\n\t\t\t\t\t\tif($smt == 2) $semester = 'GENAP'; else $semester = 'GANJIL';\n\n\n\n\t\t\t\t\t\t//cek kemana data akan pergi :)\n\t\t\t\t\t\t$kewajiban_serdos = $this->cek_kewajiban_serdos($kd_dosen);\n\n\t\t\t\t\t\t$status_pindah = $this->get_status_pindah($kd_kat);\n\n\t\t\t\t\t\t$jalur_data = 0;\n\t\t\t\t\t\tif($status_pindah == 0){\n\t\t\t\t\t\t\t$jalur_data = $this->cek_jalur_data_kat($kd_kat);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$sts_pakai = 1;\n\t\t\t\t\t\tif($status_pindah == 0){\n\t\t\t\t\t\t\tif($kewajiban_serdos == 0){\n\t\t\t\t\t\t\t\t$sts_pakai = 0;\n\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\tif($jalur_data != 0){\n\t\t\t\t\t\t\t\t\t$sts_pakai = 0;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\n\t\t\t\t\t\t//cek apakah sudah ada data atau belum ?\n\t\t\t\t\t\t $cek_mhs_bimbingan = $this->cek_api_mhs_ujian($nim);\n\n\t\t\t\t\t\t //cek nilai mahasiswa ta sudah ada apa belum :\n\t\t\t\t\t\t //$cek_nilai_mhs = $this->get_status_ta($nim);\n\t\t\t\t\t\t $cek_mhs_ujian_ta = $this->cek_api_data_pendidikan($kd_dosen, $ta, $smt, $kd_kat, $nim);\n\t\t\t\t\t\t $cek_status_ketua_ta = $this->cek_api_data_pendidikan($kd_dosen, $ta, $smt, '73', $nim);\n\t\t\t\t\t\t \n\t\t\t\t\t\t//if(!$cek_mhs_bimbingan){\n\t\t\t\t\t\tif(!$cek_mhs_ujian_ta && !$cek_status_ketua_ta){\n\n\t\t\t\t\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/simpan_beban_kerja_sia_ta_maps';\n\t\t\t\t\t\t\t$parameter = array('api_search'=>array($kd_jbk, $kd_dosen, $jenis_kegiatan, $bkt_penugasan, $sks_rule, $masa_penugasan, $bkt_dokumen, $sks_rule, $thn, $semester, $rekomendasi, $jml_jam, $capaian, $outcome, $file_penugasan, $file_capaian, $ta, $smt, $sts_pakai));\n\t\t\t\t\t\t\t$simpan = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t\t\t\t\t\tif($simpan){\n\n\t\t\t\t\t\t\t\t$getid = $simpan;\n\t\t\t\t\t\t\t\t$nm_keg = $jenis_kegiatan;\n\n\t\t\t\t\t\t\t\t$status_pindah = $this->get_status_pindah($kd_kat);\n\n\t\t\t\t\t\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/simpan_data_pendidikan_ta';\n\t\t\t\t\t\t\t\t$parameter\t= array('api_search' => array($getid, $kd_kat, $nm_keg, $jenjang, '-', '1', $jml_sks, '1', '1', 'A', '1', $prodi, $nim, $status_pindah));\n\t\t\t\t\t\t\t\t$simpan = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t\t\t\t\t\t\tif($simpan){\n\t\t\t\t\t\t\t\t\t//echo 'simpan ke data pendidikan sukses'; echo '<br>';\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\t\t\n\t\t}", "title": "" }, { "docid": "d37099526413c7c2d7d7abe0f99c1f4e", "score": "0.6518582", "text": "function halamanf3($jum)\n{// function halaman() - mula\n $mula = '<div style=\"background-color: #fffaf0; color:black;text-align:center\">';\n $tamat = '</div>';\n $page = $jum['page'];\n // Tentukan had query berasaskan nombor halaman semasa.\n //$jum['dari'] = (($jum['page'] * $jum['max']) - $jum['max']); \n // Tentukan bilangan halaman. $jum['muka_surat'] \n\t$jum['max'] = 30; // ubahsuai bil max untuk cetakf3\n\t$muka_surat = ceil($jum['bil_semua'] / $jum['max']);\n $bil_semua = $jum['bil_semua'];\n $baris_max = $jum['max'];\n \n $url = dpt_url(); // sepatutnya kawalan/semua/30/1/amin/\n $class = ( !isset($url[0]) ) ? null : $url[0]; //'kawalan'; \n $fungsi = 'cetakf3'; //( !isset($url[1]) ) ? null : $url[1]; //'semua'; \n $batch = ( !isset($url[2]) ) ? null : $url[2]; //'30'; \n $item = ( !isset($url[3]) ) ? null : $url[3]; //'30'; \n $ms = ( !isset($url[4]) ) ? null : $url[4]; //'ms'; \n //$fe = ( !isset($url[4]) ) ? null : $url[4]; //'fe'; \n \n //return \"\\$batch:$batch|\\$bil_semua:$bil_semua|\\$baris_max:$baris_max|\\$muka_surat:$muka_surat\";\n\t\n\t$senarai = URL . \"$class/$fungsi/$batch/$baris_max/\";\n $halaman = \"\\n$mula\\r\" \n\t\t. '<ul class=\"pagination pagination-sm\">' \n\t\t. \"\\r<li><a>Bil:($bil_semua) ms($muka_surat)- Papar halaman</a></li>\";\n \n if($page > 1) // Bina halaman sebelum\n $halaman .= \"\\r<li><a href='$senarai\" . ($page-1) . \"'>&laquo;</a></li>\";\n for($i = 1; $i <= $muka_surat; $i++) // Bina halaman terkini\n {$halaman .= ($page==$i)? \"\\r<li><a href='$senarai$i'>($i)</a></li>\" : \n\t\t\"\\r<li><a href='$senarai$i'>$i</a></li>\";}\n if($page < $muka_surat) // Bina halaman akhir\n $halaman .= \"\\r<li><a href='$senarai\" . ($page+1) . \"'>&raquo;</a></li>\";\n \n $halaman .= \"\\n</ul>\\n$tamat\";\n\n return $halaman;\n\t\n}", "title": "" }, { "docid": "c985ea5ad55d3344e5b42e5eea881a27", "score": "0.6516805", "text": "public function pilih_prodi()\n {\n if ($this->session->userdata('id_siswa')) {\n $sis = $this->session->userdata('id_siswa');\n $data['siswa'] = $this->Loginmodel->get_siswa($sis);\n $data['data'] = $this->Mpassing->tampil_prodi();\n $data['nilai'] = $this->Mworkout1->nilai_tertinggi();\n $data['log'] = $this->Loginmodel->getlogact();\n $data['dataa']= $this->Mpassing->tampilphoto(); \n $data['jur'] = $this->Loginmodel->get_siswa($sis)[0]->jurusan_pelajaran;\n $data['status'] = $this->Loginmodel->get_siswa($sis)[0]->status_path;\n\n $this->load->view('template/siswa2/v-header',$data);\n $this->load->view('baru/v-pilih-programstudi',$data);\n $this->load->view('template/siswa2/v-footer'); \n }\n else{\n redirect('Login');\n } \n }", "title": "" }, { "docid": "153ece3ead00a6fa7aec6951ad5cae84", "score": "0.65159106", "text": "function lihatdata()\n {\n return $this->db->get('tb_santriwati');\n }", "title": "" }, { "docid": "b0fe634d3b243f62009b25d672d373dd", "score": "0.6513766", "text": "public function Kuitansi_Honor_Uang_Saku($data) {\n $id = $data;\n\n $result = $this->query(\"SELECT penerima, value, npwp, deskripsi, honor_output, honor_profesi, pajak FROM rabfull where id='$id' \");\n $data = $this->fetch_array($result);\n\n ob_start();\n echo ' <p align=\"right\">No...............................................</p>'; \n require_once __DIR__ . \"/../utility/report/header_dikti.php\";\n echo ' <p align=\"center\" style=\"font-weight:bold; font-size:1.2em\">KUINTANSI</p>\n <table style=\"width: 100%; font-size:80%;\" border=\"0\"> \n <tr>\n <td align=\"left\" width=\"20%\">Sudah Terima Dari </td>\n <td align=\"left\">: '.$data[penerima].'</td>\n </tr> \n <tr>\n <td align=\"left\">Jumlah Uang</td>\n <td align=\"left\" style=\"background-color:gray\">: Rp. '.$data[value].'</td>\n </tr> \n <tr>\n <td align=\"left\">Uang Sebesar</td>\n <td align=\"left\">: '.$this->terbilang($data[value],1).'</td>\n </tr> \n <tr>\n <td align=\"left\">Untuk Pembayaran</td>\n <td align=\"left\">: '.$data[deskripsi].'</td>\n </tr> \n\n </table>';\n \n echo '<br></br>\n <table style=\"text-align: center; width: 100%; font-size:84%; font-family:serif\" >\n \n <tr>\n <td style=\"text-align: center;\"> Mengetahui/Setuju dibayar </td>\n <td style=\"text-align: center;\">Lunas Dibayar</td>\n <td style=\"text-align: center;\">........................ 2016</td>\n </tr> \n <tr>\n <td style=\"text-align: center;\">Pejabat Pembuat Komitmen,</td>\n <td style=\"text-align center;\">Tgl...........................</td>\n <td style=\"text-align: center;\">Penerima</td>\n </tr>\n <tr>\n <td><br></br> <br></br> <br></br></td>\n <td><br></br> <br></br> <br></br></td>\n </tr>\n <tr>\n <td style=\"text-align: center;\">'.'..................................'.'</td>\n <td style=\"text-align: center;\">'.'..................................'.'</td>\n <td style=\"text-align: center;\">'.'(..................................)'.'</td>\n </tr> \n\n <tr>\n <td style=\"text-align: center;\">NIP'.'..........................'.'</td>\n <td style=\"text-align: center;\">NIP'.\" \".'..........................'.'</td>\n <td style=\"text-align: center;\"></td>\n </tr>\n </table>';\n echo '<p>__ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __</p>';\n\n echo '<table style=\" text-align: left; border-collapse: collapse; margin-left: auto; margin-right: auto; width: 100%; font-size:0.8em; font-family:serif; \" align=\"center\">\n <tr>\n <td rowspan=\"4\" width=\"13%\"><img src=\"<../../static/dist/img/dirjenpajak.png\" height=\"8%\" /></td>\n <td style= \"vertical-align: bottom;\">KEMENTERIAN KEUANGAN REPUBLIK INDONESIA</td>\n \n </tr>\n <tr>\n <td style= \"vertical-align: bottom;\">DIREKTORAT JENDERAL PAJAK </td>\n </tr>\n <tr>\n <td style= \"vertical-align: bottom;\" style=\" font-weight:bold; text-align: center;\">BUKTI PEMOTONGAN PPh pasal 21</td>\n </tr> \n <tr>\n <td style= \"vertical-align: bottom;\" style=\" font-weight:bold; text-align: center;\" >Nomor : ........................</td>\n </tr> \n \n\n </table>';\n echo ' <table style=\"width: 100%; font-size:80%;\" border=\"0\"> \n <tr>\n <td align=\"left\" width=\"17%\">Nama Wajib Pajak </td>\n <td align=\"left\">: </td>\n </tr> \n <tr>\n <td align=\"left\" width=\"17%\">NPWP</td>\n <td align=\"left\">:</td>\n </tr> \n <tr>\n <td align=\"left\" width=\"17%\">Alamat</td>\n <td align=\"left\">: </td>\n </tr> \n\n </table>';\n echo '<br></br>\n <table style=\"text-align: left; width: 100%; font-size:84%; font-family:serif\" >\n \n <tr>\n <td > Penghasilan </td>\n <td >Jumlah</td>\n <td >Tarif</td>\n <td >Pph yang dipotong</td>\n </tr> \n <tr>\n <td >1. Honorarium</td>\n <td style=\"text-align center;\">Rp.................</td>\n <td >................... %</td>\n <td >Rp................... </td>\n </tr>\n\n <tr>\n <td >2. Imbalan Lainnya</td>\n <td style=\"text-align center;\">Rp.................</td>\n <td >................... %</td>\n <td >Rp................... </td>\n </tr>\n <tr>\n <td ></td>\n <td style=\"text-align center;\"></td>\n <td >JUMLAH</td>\n <td >Rp................... </td>\n </tr>\n <tr>\n <td style=\"text-align: center;\"></td>\n <td style=\"text-align center;\"></td>\n <td style=\"text-align: center;\"></td>\n <td style=\"text-align: center;\">Jakarta, .............................................</td>\n </tr>\n\n <tr>\n <td style=\"text-align: center;\"></td>\n <td style=\"text-align center;\"></td>\n <td style=\"text-align: center;\"></td>\n <td style=\"text-align: center; font-size:0.7em;\">Pemotong Pajak :</td>\n </tr>\n <tr>\n <td style=\"text-align: center;\"></td>\n <td style=\"text-align center;\"></td>\n <td style=\"text-align: center;\"></td>\n <td width=\"27%\" style=\"text-align: center; font-size:0.7em;\">Nama : Bendahara Pengeluaran Direktorat Jenderal Kelembagaann IPTEK dan DIKTI</td>\n </tr>\n <tr>\n <td style=\"text-align: center;\"></td>\n <td style=\"text-align center;\"></td>\n <td style=\"text-align: center;\"></td>\n <td width=\"27%\" style=\"text-align: center; font-size:0.7em;\">NPWP : 00.493.675.3-077.000</td>\n </tr>\n <br></br>\n <br></br>\n <br></br>\n <br></br>\n <tr >\n <td style=\"text-align: center;\"></td>\n <td style=\"text-align center;\"></td>\n <td style=\"text-align: center;\"></td>\n <td style=\"text-align: center;\">Josephine Margaretta</td>\n </tr>\n <tr>\n <td style=\"text-align: center;\"></td>\n <td style=\"text-align center;\"></td>\n <td style=\"text-align: center;\"></td>\n <td style=\"text-align: center;\">NIP. 19870613 201012 2 009</td>\n </tr>\n\n\n\n </table>';\n \n $html = ob_get_contents(); \n $this->create_pdf(\"Kw_Honor_Uang_Saku\",\"A4\",$html);\n \n }", "title": "" }, { "docid": "1a85389b9f90d090146500f4524b3089", "score": "0.6511771", "text": "public function index()\n {\n //mengambil data dari table data_mahasiswa\n $index = DB::table('data_mahasiswa')->paginate(10);\n \n //mengirim data pegawai ke view index\n return view('mahasiswa.index',['data_mahasiswa' => $index]);\n }", "title": "" }, { "docid": "d14df13846525070b08e8ab303cc3545", "score": "0.6504561", "text": "public function kosongkanDataBarang() {\n $this->daftar_barang = [];\n $this->editData();\n }", "title": "" }, { "docid": "110a76b30c8d730a8783b3d3a02a58bb", "score": "0.65031695", "text": "function HapusDataTemplatePesan()\n\t{\n\t\tinclude '../../koneksi/koneksi.php';\n\n\t\t//inisialisasi\n\t\t$id = $_GET['id'];\n\n\t\t$status_hapus = \"0\";\n\n\t\t//hapus dari tabel pesan\n\t\t$sql = \"UPDATE pesan SET status_hapus = ? WHERE id = ?\";\n\t\t$stmt = $db->prepare($sql);\n\t\t$stmt->bind_param('si', $status_hapus, $id);\n\t\tif($stmt->execute()){\n\t\t\t$_SESSION['status_operasi_tp'] = \"berhasil_menghapus\";\n\t\t}else{\n\t\t\t$_SESSION['status_operasi_tp'] = \"gagal_menghapus\";\n\t\t}\n\t\t$stmt->close();\n\t}", "title": "" }, { "docid": "adc343dd5701bea54834e2769da782e9", "score": "0.6502692", "text": "public function no_faktur(){\n $tahun_sekarang = date('Y');\n $bulan_sekarang = date('m');\n $tahun_terakhir = substr($tahun_sekarang, 2);\n \n //mengecek jumlah karakter dari bulan sekarang\n $cek_jumlah_bulan = strlen($bulan_sekarang);\n\n //jika jumlah karakter dari bulannya sama dengan 1 maka di tambah 0 di depannya\n if ($cek_jumlah_bulan == 1) {\n $data_bulan_terakhir = \"0\".$bulan_sekarang;\n }\n else{\n $data_bulan_terakhir = $bulan_sekarang;\n }\n \n //ambil bulan dan no_faktur dari tanggal penjualan terakhir\n $penjualan = Penjualan::select([DB::raw('MONTH(created_at) bulan'), 'no_faktur'])->orderBy('id','DESC')->first();\n\n if ($penjualan != NULL) {\n $ambil_nomor = substr($penjualan->no_faktur, 0, -8);\n $bulan_akhir = $penjualan->bulan;\n }\n else{\n $ambil_nomor = 1;\n $bulan_akhir = 13;\n }\n \n /*jika bulan terakhir dari penjualan tidak sama dengan bulan sekarang, \n maka nomor nya kembali mulai dari 1, jika tidak maka nomor terakhir ditambah dengan 1\n */\n if ($bulan_akhir != $bulan_sekarang) {\n $no_faktur = \"1/IM/\".$data_bulan_terakhir.\"/\".$tahun_terakhir;\n }\n else {\n $nomor = 1 + $ambil_nomor ;\n $no_faktur = $nomor.\"/IM/\".$data_bulan_terakhir.\"/\".$tahun_terakhir;\n }\n\n return $no_faktur;\n //PROSES MEMBUAT NO. FAKTUR ITEM MASUK\n }", "title": "" }, { "docid": "be213a1eb19da2e2ea542222e7f9f087", "score": "0.6498151", "text": "function index_get() {\n $id = $this->get('id_formk');\n if ($id == '') {\n $admintaxi = $this->db->get('t_form_kotamobagu')->result();\n } else {\n $this->db->where('id_formk', $id);\n $admintaxi = $this->db->get('t_form_kotamobagu')->result();\n }\n $this->response($admintaxi, 200);\n }", "title": "" }, { "docid": "2cd43f109c87d1f629292d649a13379d", "score": "0.6497236", "text": "public function simpan_data_field_sppa()\n {\n $aksi = $this->input->post('aksi');\n $id_field_sppa = $this->input->post('id_field_sppa');\n $field_sppa = $this->input->post('field_sppa');\n\n $data = [ 'field_sppa' => $field_sppa,\n 'add_time' => date(\"Y-m-d H:i:s\", now('Asia/Jakarta')),\n 'add_by' => $this->session->userdata('id_user')\n ];\n\n if ($aksi == 'Tambah') {\n $this->M_master->input_data('m_field_sppa', $data);\n } elseif ($aksi == 'Ubah') {\n $this->M_master->ubah_data('m_field_sppa', $data, array('id_field_sppa' => $id_field_sppa));\n } elseif ($aksi == 'Hapus') {\n $this->M_master->hapus_data('m_field_sppa', array('id_field_sppa' => $id_field_sppa));\n }\n\n echo json_encode($aksi);\n }", "title": "" }, { "docid": "6845e7f710f9006efdde8c12fc1675f4", "score": "0.64969605", "text": "public function data_kbaak()\n\t{\n\t\t$data['data'] = $this->m_aka->data_kbaak(); \n\t\t//$data['pagination'] = $this->pagination->create_links();\n\t\t$data['content'] = 'kbaak/data_kbaak';\n\t\t$this->load->view('content', $data);\n\t}", "title": "" }, { "docid": "32c257d35b68ded82d4dba87a63c76a9", "score": "0.6496647", "text": "public function simpanDataPengadilan($post){\n\t\t$connection \t= $this->db;\n\t\t$isNewRecord \t= htmlspecialchars($post['isNewRecord'], ENT_QUOTES);\n\t\t$tingkat \t\t= htmlspecialchars($post['tingkat'], ENT_QUOTES);\n\t\t$propinsi \t\t= htmlspecialchars($post['propinsi'], ENT_QUOTES);\n\t\t$kabupaten \t\t= htmlspecialchars($post['kabupaten'], ENT_QUOTES);\n\t\t$deskripsi \t\t= htmlspecialchars($post['deskripsi'], ENT_QUOTES);\n\t\t$alamat \t\t= htmlspecialchars($post['alamat'], ENT_QUOTES);\n\t\t\n\t\tif($tingkat == \"\" || $propinsi == \"\"){\n\t\t\treturn array(\"hasil\"=>false, \"error\"=>\"* Tingkat pengadilan, dan provinsi harus diisi\");\n\t\t} else if($tingkat == \"2\" && ($propinsi == \"\" || $kabupaten == \"\")){\n\t\t\treturn array(\"hasil\"=>false, \"error\"=>\"* Tingkat pengadilan, provinsi, dan kabupaten harus diisi\");\n\t\t} else{\n\t\t\t$transaction = $connection->beginTransaction();\n\t\t\ttry {\n\t\t\t\tif($isNewRecord){\n\t\t\t\t\tif($tingkat == 1){\n\t\t\t\t\t\t$cek1 = \"select deskripsi from datun.m_propinsi where id_prop = '\".$propinsi.\"'\";\n\t\t\t\t\t\t$prop = $connection->createCommand($cek1)->queryScalar();\n\t\t\t\t\t\t$sql1 = \"insert into datun.pengadilan_tk1 values('\".$propinsi.\"', 'Pengadilan Tinggi \".ucwords(strtolower($prop)).\"', '\".$alamat.\"')\";\n\t\t\t\t\t} else if($tingkat == 2){\n\t\t\t\t\t\t$cek1 = \"select deskripsi_kabupaten_kota from datun.m_kabupaten where id_prop = '\".$propinsi.\"' and id_kabupaten_kota = '\".$kabupaten.\"'\";\n\t\t\t\t\t\t$prop = $connection->createCommand($cek1)->queryScalar();\n\t\t\t\t\t\t$sql1 = \"insert into datun.pengadilan_tk2 values('\".$propinsi.\"', '\".$kabupaten.\"', 'Pengadilan Negeri \".ucwords(strtolower($prop)).\"', '\".$alamat.\"')\";\n\t\t\t\t\t}\n\t\t\t\t} else{\n\t\t\t\t\tif($kabupaten == '00'){\n\t\t\t\t\t\t$sql1 = \"update datun.pengadilan_tk1 set deskripsi_tk1 = '\".$deskripsi.\"', alamat = '\".$alamat.\"' where kode_pengadilan_tk1 = '\".$propinsi.\"'\";\n\t\t\t\t\t} else{\n\t\t\t\t\t\t$sql1 = \"update datun.pengadilan_tk2 set deskripsi_tk2 = '\".$deskripsi.\"', alamat = '\".$alamat.\"' where kode_pengadilan_tk1 = '\".$propinsi.\"' \n\t\t\t\t\t\t\t\tand kode_pengadilan_tk2 = '\".$kabupaten.\"'\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$connection->createCommand($sql1)->execute();\n\t\t\t\t$transaction->commit();\n\t\t\t\treturn array(\"hasil\"=>true, \"error\"=>\"Maaf, data gagal disimpan\");\n\t\t\t} catch (\\Exception $e) {\n\t\t\t\t$transaction->rollBack();\n\t\t\t\treturn array(\"hasil\"=>false, \"error\"=>\"Maaf, data gagal disimpan\");\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "331f85688b376d91a854f45d89794988", "score": "0.6486363", "text": "public function data_mata_kuliah()\n\t{\n\t\t$query1 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '1' AND prodi = 'Analisis Kimia'\";\n\t\t$query2 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '1' AND prodi = 'Penjaminan Mutu Industri Pangan'\";\n\t\t$query3 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '1' AND prodi = 'Pengolahan Limbah Industri'\";\n\t\t$query4 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '2' AND prodi = 'Analisis Kimia'\";\n\t\t$query5 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '2' AND prodi = 'Penjaminan Mutu Industri Pangan'\";\n\t\t$query6 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '2' AND prodi = 'Pengolahan Limbah Industri'\";\n\t\t$data['semester1A'] = $this->m_aka->query_aka($query1);\n\t\t$data['semester2A'] = $this->m_aka->query_aka($query4);\n\t\t$data['semester1B'] = $this->m_aka->query_aka($query2);\n\t\t$data['semester2B'] = $this->m_aka->query_aka($query5);\n\t\t$data['semester1C'] = $this->m_aka->query_aka($query3);\n\t\t$data['semester2C'] = $this->m_aka->query_aka($query6);\n\t\t$data['data'] = $this->m_aka->data_mata_kuliah(); \n\t\t$data['pagination'] = $this->pagination->create_links();\n\t\t$data['content'] = 'mata_kuliah/data_mata_kuliah';\n\t\t$this->load->view('content', $data);\n\t}", "title": "" }, { "docid": "d1ffc6440976236da1115de1d435fa8f", "score": "0.6484757", "text": "public function tambah_pelanggan_all()\n {\n\n $layanan = Data_layanan::all();\n $kategori = Data_kategori::all();\n $pop = Data_pop::all();\n $sektor = Data_sektor::all();\n $tipe = Data_tipe_pengguna::all();\n $tipebandwith = Data_tipe_bw::all();\n\n\n return view('pelanggan/tambah_pelanggan_all', ['datalayanan' => $layanan, 'kategori' => $kategori, 'pop' => $pop, 'sektor' => $sektor, 'tipe' => $tipe, 'datatipebw' => $tipebandwith]);\n }", "title": "" }, { "docid": "5fefe610516c64dcbcb06b52f2925d14", "score": "0.6483847", "text": "public function input_mata_kuliah(){\n\t\t$mk = \"t_mk\";\n\t\t$data['content'] = 'mata_kuliah/input_mata_kuliah';\n\t\t$data['mata_kuliah'] = $this->m_aka->get_all($mk);\n\t\t$this->load->view('content',$data);\n\t}", "title": "" }, { "docid": "07bd76c8319f509cfe81ced3df0bbea9", "score": "0.648326", "text": "function haki($param = null, $id = null){\n\t\t$kd_dosen = $this->session->userdata('kd_dosen');\n\t\t\n\t\t$data['p_ta'] = $this->input->post(\"thn\");\n\t\t$data['p_smt'] = $this->input->post(\"smt\");\n\t\tif ($data['p_ta'] == null && $data['p_smt'] == null){\n\t\t\t$data['ta'] = $this->session->userdata('ta');\n\t\t\t$data['smt'] = $this->session->userdata('smt');\t\t\n\t\t}else{\n\t\t\t$data['ta'] = $this->input->post(\"thn\");\n\t\t\t$data['smt'] = $this->input->post(\"smt\");\n\t\t}\n\t\t\n\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/get_data_haki';\n\t\t$parameter = array('api_search' => array($kd_dosen));\n\t\t$data['haki'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\t\n\t\t# get data dosen prodi \n\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/get_all_dosen';\n\t\t\t$parameter = array('api_search' => array());\n\t\t\t$data['dosen'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/data_bebankerja';\n\t\t\t\n\t\t\t$thn= $this->session->userdata('ta');\n\t\t\t$smt=$this->session->userdata('smt');\n\t\t\t$parameter = array('api_search' => array('H',$kd_dosen, $thn, $smt));\n\t\t\t$data['data_beban'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\n\t\tif ($param != null){\n\t\t\t$data['jenis_haki'] = $this->s00_lib_api->get_api_jsob(URL_API_BKD.'bkd_beban_kerja/get_jenis_haki','POST',array());\t\n\t\t\tif($param == 'tambah'){\n\t\t\t\tif($id != null){\n\t\t\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/current_data_haki';\n\t\t\t\t\t$parameter = array('api_search' => array($id));\n\t\t\t\t\t$ch=$data['curr_haki'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\t\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/current_data_bkd';\n\t\t\t\t\t$parameter = array('api_search' => array($ch->KD_BK, 'H'));\n\t\t\t\t\t$data['current_data'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t\t\t}\n\t\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/get_all_dosen';\n\t\t\t\t$parameter = array('api_search' => array());\n\t\t\t\t$data['dosen'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t\t\t\n\t\t\t\t#$this->output99=$this->s00_lib_output;\n\t\t\t\t$this->output99->output_display('dosen/form_haki',$data);\n\t\t\t}\n\t\t\telse if ($param == 'detail'){\n\t\t\t\t$api_url \t= URL_API_BKD.'bkd_beban_kerja/current_data_haki';\n\t\t\t\t$parameter = array('api_search' => array($id));\n\t\t\t\t$data['curr_haki'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\t\t\t\t\t\t\t\t\n\n\t\t\t\t# GET PARTNER\n\t\t\t\t$api_url \t= URL_API_BKD.'bkd_dosen/partner';\n\t\t\t\t$parameter = array('api_kode' => 11000, 'api_subkode' => 1, 'api_search' => array($id,'HAKI'));\n\t\t\t\t$data['partner'] = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\t\n\t\t\t\t#print_r($data['partner']); die();\n\t\t\t\t$data['nama_partner'] = array();\n\t\t\t\tforeach ($data['partner'] as $p){\n\t\t\t\t\t$data['nama_partner'][$p->PARTNER] = $this->get_nama_partner($p->PARTNER);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t#$this->output99=$this->s00_lib_output;\n\t\t\t\t$this->output99->output_display('dosen/daftar_haki',$data);\n\t\t\t}\n\t\t\telse{\n\t\t\t\t#$this->output99=$this->s00_lib_output;\n\t\t\t\t$this->output99->output_display('dosen/daftar_haki',$data);\n\t\t\t}\n\t\t}else{\n\t\t\t#$this->output99=$this->s00_lib_output;\n\t\t\t$this->output99->output_display('dosen/daftar_haki',$data);\n\t\t}\n\t}", "title": "" }, { "docid": "4701c3ba1b442a6fa8ac0124c147592b", "score": "0.64766246", "text": "function tampil_data(){\n\t\t//query select user\n\t\t$data = mysqli_query($this->conn, \"SELECT * FROM table_1\");\n\t\twhile($d = mysqli_fetch_array($data)){\n\t\t\t$hasil[] = $d;\n\t\t}\n\t\treturn $hasil;\n\n\t}", "title": "" }, { "docid": "480f16578b26cebdd14bb37f498ac41f", "score": "0.6476388", "text": "public function absen(){\n\t\t\t$id_kelas = $this->input->post('id_kelas');\n\t\t\t$keterangan = $this->input->post('keterangan');\n\t\t\t$tanggal = $this->input->post('tanggal');\n\t\t\t$sesi = $this->input->post('sesi');\n\n\t\t\t$presensiInfo = array(\n\t\t\t\t'id_kelas'=>$id_kelas,\n\t\t\t\t'tgl_pertemuan'=>$tanggal,\n\t\t\t\t'keterangan'=>$keterangan,\n\t\t\t\t'sesi'=>$sesi,\n\t\t\t\t'status_pertemuan'=>'Tidak Hadir',\n\t\t\t\t\"createDtm\"=>date('Y-m-d H:s:i')\n\t\t\t);\n\n\t\t\t//get id_pertemuan yang barusaja dibuat\n\t\t\t$result = $this->JadwalAkademikM->presensi($presensiInfo);\n\n\t\t\tif($result > 0){\n\t\t\t\t$this->session->set_flashdata('success','Presensi berhasil dibuat');\n\t\t\t}else{\n\t\t\t\t$this->session->set_flashdata('error','Presensi gagal dibuat');\n\t\t\t}\n\n\t\t\tredirect('jadwalAkademikR');\n\t\t}", "title": "" }, { "docid": "9d59ea5a1559e825cbb1bfe6b0421274", "score": "0.6474281", "text": "public function data_kelas()\n\t{\n\t\t$query1 = \"SELECT t_kelas.id_kelas,t_kelas.nama_kelas,t_kelas.id_prodi,t_prodi.id_prodi,t_prodi.prodi FROM t_kelas INNER JOIN t_prodi ON t_kelas.id_prodi=t_prodi.id_prodi WHERE prodi = 'Analisis Kimia'\";\n\t\t$query2 = \"SELECT t_kelas.id_kelas,t_kelas.nama_kelas,t_kelas.id_prodi,t_prodi.id_prodi,t_prodi.prodi FROm t_kelas INNER JOIN t_prodi ON t_kelas.id_prodi=t_prodi.id_prodi WHERE prodi = 'Penjaminan Mutu Industri Pangan'\";\n\t\t$query3 = \"SELECT t_kelas.id_kelas,t_kelas.nama_kelas,t_kelas.id_prodi,t_prodi.id_prodi,t_prodi.prodi FROm t_kelas INNER JOIN t_prodi ON t_kelas.id_prodi=t_prodi.id_prodi WHERE prodi = 'Pengolahan Limbah Industri'\";\n\t\t$data['prodi1'] = $this->m_aka->query_aka($query1);\n\t\t$data['prodi2'] = $this->m_aka->query_aka($query2);\n\t\t$data['prodi3'] = $this->m_aka->query_aka($query3);\n\t\t$data['data'] = $this->m_aka->data_kelas(); \n\t\t$data['pagination'] = $this->pagination->create_links();\n\t\t$data['content'] = 'data_kelas';\n\t\t$this->load->view('content', $data);\n\t}", "title": "" }, { "docid": "6c44ccb717c3498d97e8bc41215b8db8", "score": "0.64711666", "text": "public function data_pengumuman_akademik()\n\t{\n\t\t$data['data'] = $this->m_aka->data_pengumuman_akademik(); \n\t\t$data['pagination'] = $this->pagination->create_links();\n\t\t$data['content'] = 'posting_pengumuman/data_pengumuman_akademik';\n\t\t$this->load->view('content', $data);\n\t}", "title": "" }, { "docid": "5bc4d66b70e255fd824506ca343683f0", "score": "0.6470439", "text": "function sawlihat($id)\n\t{\n\t\t//$a = 'A1';\n\t\t//foreach ($q2 as $key) {\n\t\t\t//echo \"<br/>\";\n\t\t\t//echo $key->nidn.\" = \".$a;\n\t\t\t//echo \"<br/>\";\n\t\t\t\n\t\t\t//echo \"Hasil Akhir = \".number_format($kumulatip,2);\n\t\t\t//echo \"<br/>\";\n\t\t\t//$a++;\n\t\t//}\n\t\t$data['tahun'] = $id;\n\t\t$data['q2'] = $this->db->query(\"SELECT DISTINCT nidn,nama_karyawan FROM tbl_jadwal_matakuliah a JOIN tbl_karyawan b on a.nidn = b.nik where tahunajaran = '\".$id.\"'\")->result();\n\t\t$data['page'] = 'penilaian/saw_lihat';\n\t\t$this->load->view('template', $data);\t\n\t}", "title": "" }, { "docid": "7ab46fa90ec2545fe87f5c14350274ef", "score": "0.64702964", "text": "function index(){\n\t\t$this->load->library('lita');\n\t\t// code ini untuk memanggil method yang ada pada library lita\n\t\t$this->lita->nama_saya();\n\t\t\t\techo \"<br/>\";\n\t\t\t\t// code ini untuk memanggil method dengan parameter\n $this->lita->nama_kamu(\"Lita\");\n\t}", "title": "" }, { "docid": "663efb7b1e9f2a2f375f3d6152221ae0", "score": "0.64673895", "text": "public function latihan() {\n $date = null;\n $var = [\n 'page' => 'admin/laporan/latihan',\n 'title' => 'Jadwal Latihan',\n 'latihan' => $this->m_app->getLatihan(null, null, $date)->result(),\n 'user' => $this->m_app->getPelatih()->result(),\n 'anggota' => $this->m_app->getAnggota()->result(),\n ];\n $this->load->view('layout/admin', $var);\n }", "title": "" } ]
e45e609e22a75ccfbd0ce1c71f8790b3
Codes a real value to binary format
[ { "docid": "a35cfa995dc0a340f414e6015f0c99c8", "score": "0.7485936", "text": "protected function realToBinary($val) {\n $bdata = self::typeBytes(\"2\", 3); // 2 is 0010, type indicator for reals\n return $bdata.strrev(pack(\"d\", (float)$val));\n }", "title": "" } ]
[ { "docid": "c2014b120cae2a8c38b6b99a5e1b0323", "score": "0.68076605", "text": "public function numToBinary($value) {\n $saved_object_count = $this->writtenObjectCount++;\n\n $val = \"\";\n if(intval($value) == $value && !is_float($value) && strpos($value,'.') === false) $val = $this->intToBinary($value);\n else $val = $this->realToBinary($value);\n\n $this->objectTable[$saved_object_count] = $val;\n return $saved_object_count;\n }", "title": "" }, { "docid": "3a1730c3e24a7a429807532e0b18e6a2", "score": "0.6754311", "text": "public function encode()\n {\n if($this->value < 0){ $this->value += 65536; }\n // pack into binary string as signed integer big endian byte order\n return pack('n',$this->value);\n }", "title": "" }, { "docid": "3ff0c29c8ae0a2f9f602b1e45b766be7", "score": "0.67046183", "text": "public function toBits(): string\n {\n //return str_pad(BinaryField::base256ToBase2($this->value), strlen(static::$modulo[$this->instanceID]), '0', STR_PAD_LEFT);\n return BinaryField::base256ToBase2($this->value);\n }", "title": "" }, { "docid": "85d65220480d6b955e48c64920ea8d93", "score": "0.66800755", "text": "public function castBinary()\n {\n return 'data:;base64,' . $this->value;\n }", "title": "" }, { "docid": "7066dd98acbc65940d15d2ddee64b48f", "score": "0.6594567", "text": "public function dataToBinary($val) {\n $saved_object_count = $this->writtenObjectCount++;\n\n $bdata = self::typeBytes(\"4\", strlen($val)); // a is 1000, type indicator for data\n $this->objectTable[$saved_object_count] = $bdata.$val;\n\n return $saved_object_count;\n }", "title": "" }, { "docid": "7b3d21439b2c1fabbe1c2979b6c56e39", "score": "0.65078616", "text": "protected function intToBinary($value) {\n $nbytes = 0;\n if($value > 0xFF) $nbytes = 1; // 1 byte integer\n if($value > 0xFFFF) $nbytes += 1; // 4 byte integer\n if($value > 0xFFFFFFFF) $nbytes += 1; // 8 byte integer\n if($value < 0) $nbytes = 3; // 8 byte integer, since signed\n\n $bdata = self::typeBytes(\"1\", $nbytes); // 1 is 0001, type indicator for integer\n $buff = \"\";\n\n if($nbytes < 3) {\n if($nbytes == 0) $fmt = \"C\";\n elseif($nbytes == 1) $fmt = \"n\";\n else $fmt = \"N\";\n\n $buff = pack($fmt, $value);\n }\n else {\n if(PHP_INT_SIZE > 4) {\n // 64 bit signed integer; we need the higher and the lower 32 bit of the value\n $high_word = $value >> 32;\n $low_word = $value & 0xFFFFFFFF;\n }\n else {\n // since PHP can only handle 32bit signed, we can only get 32bit signed values at this point - values above 0x7FFFFFFF are\n // floats. So we ignore the existance of 64bit on non-64bit-machines\n if($value < 0) $high_word = 0xFFFFFFFF;\n else $high_word = 0;\n $low_word = $value;\n }\n $buff = pack(\"N\", $high_word).pack(\"N\", $low_word);\n }\n\n return $bdata.$buff;\n }", "title": "" }, { "docid": "d7e4d7de306c8109dd765668faa86146", "score": "0.64035606", "text": "public function byteValue()\n {\n return decbin(self::intValue());\n }", "title": "" }, { "docid": "7985048a5359249a7ca0979414f90316", "score": "0.6371743", "text": "public function boolToBinary($val) {\n $saved_object_count = $this->writtenObjectCount++;\n $this->objectTable[$saved_object_count] = $val ? \"\\x9\" : \"\\x8\"; // 0x9 is 1001, type indicator for true; 0x8 is 1000, type indicator for false\n return $saved_object_count;\n }", "title": "" }, { "docid": "b4056f430ef302b2462db4eb08a359fa", "score": "0.63273376", "text": "private function binary_cast($p_x)\r\n\t\t{\r\n\t\t\t$taille = sizeof($p_x) - 1;\r\n\t\t\tif($taille == -1)\r\n\t\t\t\t$pos_pow = 0;\r\n\t\t\telse\r\n\t\t\t\t$pos_pow = $p_x[$taille];\r\n\t\t\t$binary = '';\r\n\t\t\t$i = $taille;\r\n\r\n\t\t\tdo{\r\n\r\n\t\t\t\tif($i >= 0 && ($p_x[$i] == $pos_pow /*|| $p_x[$i] == -1 */))\r\n\t\t\t\t{\r\n\t\t\t\t\t$binary = $binary.'1';\r\n\t\t\t\t\t$i -= 1;\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t{\r\n\t\t\t\t\t$binary = $binary.'0';\r\n\t\t\t\t}\r\n\t\t\t\t$pos_pow -= 1;\r\n\t\t\t\r\n\t\t\t}while($pos_pow >= 0);\r\n\t\t\t\r\n\t\t\treturn $binary;\r\n\t\t}", "title": "" }, { "docid": "779b181c89e54a5be6c4223f29d84685", "score": "0.6322476", "text": "function _integer_to_binary($term)\n{\n if (0 <= $term and $term <= 255)\n return pack('CC', TAG_SMALL_INTEGER_EXT, $term);\n elseif (-2147483648 <= $term and $term <= 2147483647)\n return pack('CN', TAG_INTEGER_EXT, $term);\n else\n return _bignum_to_binary($term);\n}", "title": "" }, { "docid": "2328771b68624b40b50cda02614f48cb", "score": "0.62650234", "text": "function bindec($binary_number) {}", "title": "" }, { "docid": "35a8035cf3a1c949c55b947254e91937", "score": "0.62595534", "text": "protected function blob($value) {\n\t\treturn \"x'\" . bin2hex($value) . \"'\";\n\t}", "title": "" }, { "docid": "762d110508320835b3def9149bbc45fd", "score": "0.624334", "text": "function getRealBit()\n {\n $bit =\"\";\n /*\n\n */\n $this->firstBit = \"\";\t// inisialisasi bit awal\n\t\tfor ($i = 0; $i < strlen($this->textInside); $i++) { //melakukan perulangan untuk setiap char dalam text\n $letter = $this->textInside[$i]; //mengambil char ke-i dalam text\n\t $this->firstBit .= sprintf(\"%08d\",decbin(ord($letter)));\t\t//menambahkan binary char ke-i dan disimpan ke firstbit\n }\n $bit = $this->firstBit; //masih ada padding & flag\n $flag = substr($bit,-8); //ngambil 8 digit terakhir dr biner\n $padding = bindec($flag); //ngubah dr flag jadi des\n $bit = substr($bit, 0, strlen($bit)-$padding-8); //untuk mengurangi nilai total bit dengan padding&flag \n return $bit;\t\t//mengembalikan nilai frekuensi dalam array\n }", "title": "" }, { "docid": "1527adfbd0a2287fd227a3afb5a8547f", "score": "0.621078", "text": "function int2binary($number) {\r\n\r\n\tif ($number == 0) {\r\n\t\treturn 0;\r\n\t}\r\n\r\n\t$result_string = \"\";\r\n\t\r\n\tfor($i = 0; $i < (PHP_INT_SIZE * 8); ++$i) {\r\n\t\t/**\r\n\t\t * Using right shift \">>\" and operator \"&\" 32-64 times \r\n\t\t * to get the bits from every 32-64 bit integer\r\n\t\t * depending from PHP_INT_SIZE\r\n\t\t */\r\n\t\t$bit = ($number >> $i) & 1;\r\n\t\t/**\r\n\t\t * Appending every $bit value as a string \r\n\t\t * in the beginning of the $result_string\r\n\t\t */\r\n\t\t$result_string = $bit . $result_string;\r\n\t}\r\n\t/**\r\n\t * Get rid of all zeros in the left\r\n\t */\r\n\t$result_string = ltrim($result_string, \"0\");\r\n\r\n\t\r\n\treturn $result_string;\r\n}", "title": "" }, { "docid": "ae1c968aeaa0f848bd96b51e749210cc", "score": "0.6202212", "text": "public function decodeVarbinary($value);", "title": "" }, { "docid": "71e32c983e673dc2d0ece63dde974d65", "score": "0.61843807", "text": "function cBin($VALUE){\n\tif($VALUE=='off')\n\t\treturn 0;\n\telseif ($VALUE=='on')\n\t\treturn 1;\n\telse return false;\n}", "title": "" }, { "docid": "b00e38d5d733c899b3d66d577c6144d2", "score": "0.61709964", "text": "protected function encodeBinary(): string\n {\n /** @var BigInteger $m */\n /** @var BigInteger $e */\n /** @var int $sign */\n [$base, $sign, $m, $e] = $this->prepareBinaryEncoding();\n $zero = BigInteger::of(0);\n $byte = 0x80;\n if ($sign < 0) {\n $byte |= 0x40;\n }\n // normalization: mantissa must be 0 or odd\n if ($base === 2) {\n // while last bit is zero\n while ($m->isGreaterThan(0) && $m->and(0x01)->isEqualTo($zero)) {\n $m = $m->shiftedRight(1);\n $e = $e->plus(1);\n }\n } elseif ($base === 8) {\n $byte |= 0x10;\n // while last 3 bits are zero\n while ($m->isGreaterThan(0) && $m->and(0x07)->isEqualTo($zero)) {\n $m = $m->shiftedRight(3);\n $e = $e->plus(1);\n }\n } else { // base === 16\n $byte |= 0x20;\n // while last 4 bits are zero\n while ($m->isGreaterThan(0) && $m->and(0x0f)->isEqualTo($zero)) {\n $m = $m->shiftedRight(4);\n $e = $e->plus(1);\n }\n }\n // scale factor\n $scale = 0;\n while ($m->isGreaterThan(0) && $m->and(0x01)->isEqualTo($zero)) {\n $m = $m->shiftedRight(1);\n ++$scale;\n }\n $byte |= ($scale & 0x03) << 2;\n // encode exponent\n $exp_bytes = (BigInt::create($e))->signedOctets();\n $exp_len = mb_strlen($exp_bytes, '8bit');\n if ($exp_len > 0xff) {\n throw new RangeException('Exponent encoding is too long.');\n }\n if ($exp_len <= 3) {\n $byte |= ($exp_len - 1) & 0x03;\n $bytes = chr($byte);\n } else {\n $byte |= 0x03;\n $bytes = chr($byte) . chr($exp_len);\n }\n $bytes .= $exp_bytes;\n // encode mantissa\n $bytes .= (BigInt::create($m))->unsignedOctets();\n return $bytes;\n }", "title": "" }, { "docid": "0da45bff2783fc505b8025b757c6f417", "score": "0.61653143", "text": "function raw_to_bin_s($rawstr)\n{\n\t$result = '';\n\tfor($i = 0; $i < strlen($rawstr); $i++){\n\t\t$result .= str_pad(decbin(ord($rawstr[$i])), 8, '0', STR_PAD_LEFT);\n\t}\n\treturn $result;\n\n}", "title": "" }, { "docid": "19a6ba51ef18bea80e714a6d82cf322e", "score": "0.61549366", "text": "function _to_bin($cadenas) {\n $cadenas = str_split($cadenas, 4);\n $bin = '';\n for ($i=0; $i < count($cadenas); $i++) {\n $bin = $bin . str_pad( decbin( hexdec( bin2hex( $cadenas[$i] ) ) ), strlen($cadenas[$i])*8, \"0\", STR_PAD_LEFT );\n }\n return $bin;\n}", "title": "" }, { "docid": "a13601ac0a4103eaea1e71581b0580a4", "score": "0.61445427", "text": "function _bignum_to_binary($term)\n{\n $bignum = abs($term);\n if ($term < 0)\n $sign = 1;\n else\n $sign = 0;\n $l = '';\n while ($bignum > 0)\n {\n $l .= chr($bignum & 255);\n $bignum >>= 8;\n }\n $length = strlen($l);\n if ($length <= 255)\n return pack('CCC', TAG_SMALL_BIG_EXT, $length, $sign) . $l;\n elseif ($length <= 4294967295)\n return pack('CNC', TAG_LARGE_BIG_EXT, $length, $sign) . $l;\n else\n throw new OutputException('uint32 overflow');\n}", "title": "" }, { "docid": "5813801ce7cafe628b4336cd639ff39c", "score": "0.6089052", "text": "function bin_s_to_raw($binary)\n{\n $bytes = str_split($binary, 8);\n $result = '';\n foreach($bytes as $byte) {\n\t\t$result .= chr(bindec($byte));\n\t}\n return $result; \n}", "title": "" }, { "docid": "3ed51ca0bc4cce5a14a61de8a9386dd2", "score": "0.60667306", "text": "function sqlite_udf_encode_binary($data) {}", "title": "" }, { "docid": "acc51147b89fb5ca3d604989acf68a37", "score": "0.5979558", "text": "function fmt_binary($x, $numbits, $retbit) {\n // Convert to binary\n $bin = decbin($x);\n $bin = substr(str_repeat(0,$numbits),0,$numbits - strlen($bin)) . $bin;\n // Split into x 4-bits long\n $rtnval = '';\n for ($x = 0; $x < $numbits/4; $x++) {\n $rtnval .= ' ' . substr($bin,$x*4,4);\n }\n \t// Get rid of first space.\n\t return ltrim($rtnval[$retbit]);\n}", "title": "" }, { "docid": "0c3fecc3b5078877dab02e3df67eb1e5", "score": "0.5964093", "text": "public static function encode($val) {\n\t\t$str = '';\n\t\tdo {\t\n\t\t\t$m = bcmod($val, self::$BASE);\n\t\t\t$str = self::$CHARS[$m] . $str;\n\t\t\t$val = bcdiv(bcsub($val, $m), self::$BASE);\n\t\t} while(bccomp($val,0) > 0);\n\t\treturn $str; \n\t}", "title": "" }, { "docid": "0a04e2084a165701008e265f51eec626", "score": "0.59594846", "text": "private function binconvert($bin) {\n $ret = base64_encode($bin);\n $ret = str_replace(\"=\", \"\", $ret);\n return $ret;\n }", "title": "" }, { "docid": "9008214e5c5e94f1859268ea298c4d30", "score": "0.5904197", "text": "public function as_binary($format = '%s') {\n\t\t$binary = base_convert($this->hexcode, 16, 2);\n\t\tif ($format != '%s') { // this is done for efficiency\n\t\t\treturn sprintf($format, $binary);\n\t\t}\n\t\treturn $binary;\n\t}", "title": "" }, { "docid": "fd3e0dcaec008e0133fadb69daeb41d3", "score": "0.5899797", "text": "function codificar( $valor )\n{\n\treturn escape(Base64.encode($valor));\n}", "title": "" }, { "docid": "f308a7124b94a0026a0eb91b0b94260b", "score": "0.58773", "text": "function bin2bStr($input)\n{\n if (!is_string($input)) return null;\n // Pack into a string\n $input = str_split($input, 4);\n $str = '';\n foreach ($input as $v) {\n $str .= base_convert($v, 2, 16);\n }\n $str = pack('H*', $str);\n return $str;\n}", "title": "" }, { "docid": "4395a737883a42965b039424cc359012", "score": "0.5863571", "text": "function int2bin($num)\n {\n $bi = new Math_BigInteger($num, 10);\n return _byte_strrev($bi->toBytes());\n }", "title": "" }, { "docid": "dea22676fbfd0501955fe168a83167de", "score": "0.5837737", "text": "public abstract function writeByte($value);", "title": "" }, { "docid": "db11d35a2ca53bb5bd3c9a86e3b075c1", "score": "0.5817261", "text": "public static function toBase64($value) {}", "title": "" }, { "docid": "5cd4ef3a627a55113e58a87c9d8e66b9", "score": "0.57760984", "text": "public function as_binary($format = '%s') {\n\t\t$binary = '';\n\t\tforeach ($this->values as $field => $value) {\n\t\t\t$binary = substr(static::unpack($value, $this->boundary), $this->boundary - $this->pattern[$field]) . $binary;\n\t\t}\n\t\t$binary = str_pad($binary, $this->boundary, '0', STR_PAD_LEFT);\n\t\tif ($format != '%s') { // this is done for efficiency\n\t\t\treturn sprintf($format, $binary);\n\t\t}\n\t\treturn $binary;\n\t}", "title": "" }, { "docid": "03360f76fb90a628bcec235f648db8d0", "score": "0.57691634", "text": "public function dateToBinary($val) {\n $saved_object_count = $this->writtenObjectCount++;\n\n $hour = gmdate(\"H\",$val);\n $min = gmdate(\"i\",$val);\n $sec = gmdate(\"s\",$val);\n $mday = gmdate(\"j\",$val);\n $mon = gmdate(\"n\",$val);\n $year = gmdate(\"Y\",$val);\n\n $val = gmmktime($hour,$min,$sec,$mon,$mday,$year) - CFDate::DATE_DIFF_APPLE_UNIX; // CFDate is a real, number of seconds since 01/01/2001 00:00:00 GMT\n\n $bdata = self::typeBytes(\"3\", 3); // 3 is 0011, type indicator for date\n $this->objectTable[$saved_object_count] = $bdata.strrev(pack(\"d\", $val));\n\n return $saved_object_count;\n }", "title": "" }, { "docid": "708e1956647ef2f9b2702c32a58e94b3", "score": "0.5764795", "text": "public function\tencode($data)\r\n\t{\r\n\t\tif (!is_string($data))\r\n\t\t\t$data = serialize($data);\r\n\t\tif (empty($data))\r\n\t\t\treturn '';\r\n\t\tif ($this->dictionnary === null)\r\n\t\t\t$this->generateDictionnary($data);\r\n\t\t$binaryString = '';\r\n\t\tfor ($i = 0; isset($data[$i]); ++$i)\r\n\r\n\t\t\t$binaryString .= $this->dictionnary->get($data[$i]);\r\n\t\t\t//echo $binaryString.\"<br/>\";\r\n\t\t$splittedBinaryString = str_split($binaryString,8);\r\n\t\t//print_r($splittedBinaryString);\r\n\r\n\t\t$binaryString = '';\r\n\t\tforeach ($splittedBinaryString as $i => $c)\r\n\t\t{\r\n\t\t\t\t//echo $c.\"<br/>\";\r\n\t\t\twhile (strlen($c) < 8)\r\n\t\t\t\t$c .= '0';\r\n\t\t\t$binaryString .= chr(bindec($c));\r\n\t\t//echo $binaryString;\r\n\t\t}\r\n\t\treturn $binaryString;\r\n\t}", "title": "" }, { "docid": "8aa754deb516137e2534dc502feb4745", "score": "0.5762837", "text": "public function writeBcd8421($value){\n\n $len = strlen($value);\n // 奇数,前补零\n if (($len & 0x1) == 1) {\n $value = \"0\" . $value;\n }\n $bytes=[];\n for ($i = 0; $i < $len; $i+=2) {\n $high = $value[$i];\n $low = $value[$i+1];\n $bytes[] = chr(($high << 4) | $low);\n }\n return $this->write($bytes);\n }", "title": "" }, { "docid": "f45904d37130a71fc60211b3aca493f0", "score": "0.57429355", "text": "function bin2hex($data) {}", "title": "" }, { "docid": "c8f577df1fcdb01cb17490f817b1b026", "score": "0.57409316", "text": "function hex2bin($hexvalue)\n {\n if (!is_string($hexvalue)) return null;\n $bin='';\n for ($a=0; $a<strlen($hexvalue); $a+=2) \n { \n $bin.=chr(hexdec($hexvalue{$a}.$hexvalue{($a+1)})); \n }\n return $bin;\n }", "title": "" }, { "docid": "600f97f88402ed33c3dccee4f2640e3a", "score": "0.5738337", "text": "public function toBinary() {\n $this->uniqueTable = Array();\n $this->countObjects = 0;\n $this->stringSize = 0;\n $this->intSize = 0;\n $this->miscSize = 0;\n $this->objectRefs = 0;\n\n $this->writtenObjectCount = 0;\n $this->objectTable = Array();\n $this->objectRefSize = 0;\n\n $this->offsets = Array();\n\n $binary_str = \"bplist00\";\n $value = $this->getValue(true);\n $this->uniqueAndCountValues($value);\n\n $this->countObjects += count($this->uniqueTable);\n $this->objectRefSize = self::bytesNeeded($this->countObjects);\n $file_size = $this->stringSize + $this->intSize + $this->miscSize + $this->objectRefs * $this->objectRefSize + 40;\n $offset_size = self::bytesNeeded($file_size);\n $table_offset = $file_size - 32;\n\n $this->objectTable = Array();\n $this->writtenObjectCount = 0;\n $this->uniqueTable = Array(); // we needed it to calculate several values\n $value->toBinary($this);\n\n $object_offset = 8;\n $offsets = Array();\n\n for($i=0;$i<count($this->objectTable);++$i) {\n $binary_str .= $this->objectTable[$i];\n $offsets[$i] = $object_offset;\n $object_offset += strlen($this->objectTable[$i]);\n }\n\n for($i=0;$i<count($offsets);++$i) {\n $binary_str .= self::packItWithSize($offset_size, $offsets[$i]);\n }\n\n\n $binary_str .= pack(\"x6CC\", $offset_size, $this->objectRefSize);\n $binary_str .= pack(\"x4N\", $this->countObjects);\n $binary_str .= pack(\"x4N\", 0);\n $binary_str .= pack(\"x4N\", $table_offset);\n\n return $binary_str;\n }", "title": "" }, { "docid": "76f89f2de1b8af18aa3b6805f9f1efa5", "score": "0.57187563", "text": "function binify($data){\n\n\t\t$result='';\n\t\tforeach($data as $d){\n\t\t\t$m=array();\n\t\t\tpreg_match('/0x[0-9]{4}: (.*)/',$d,$m);\n\t\t\t$result.=@$m[1];\n\t\t}\n\t\t$result = str_replace(' ','',$result);\n\t\t$result = @pack('H*',$result);\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "31eac2cb6b80d180bef805c77dea0630", "score": "0.57149285", "text": "function decToBinary($x) {\n $bin = 0;\n $rem; $i = 1; $step = 1;\n while ($x != 0) {\n $rem = $x % 2;\n $x = floor($x / 2);\n $bin = $bin + $rem * $i;\n $i = $i * 10;\n }\n echo \"$bin\";\n}", "title": "" }, { "docid": "2e97e16d416d12f9f6b0196cdc976229", "score": "0.5683359", "text": "public function toBinary(CFBinaryPropertyList &$bplist) {\n return $bplist->numToBinary($this->value);\n }", "title": "" }, { "docid": "182557ecdb9e87367bccba80e9ce229b", "score": "0.56787896", "text": "public function __toString() {\n\t\treturn $this->as_binary();\n\t}", "title": "" }, { "docid": "2982c94c3809c6ed45dfe892ad7678ea", "score": "0.56769115", "text": "function odbc_binmode($result_id, $mode) {}", "title": "" }, { "docid": "c7de5a099d22ecf766794ce55442c74b", "score": "0.5649757", "text": "public function toBytes(): string\n {\n return str_pad($this->value, strlen(static::$modulo[$this->instanceID]), \"\\0\", STR_PAD_LEFT);\n }", "title": "" }, { "docid": "b2269d544c82e43e4cf093911934bbf8", "score": "0.561923", "text": "public static function toBinary($number)\r\n {\r\n return str_pad(decbin((int)$number), self::OCTETLENGTHBIN(), '0', STR_PAD_LEFT);\r\n }", "title": "" }, { "docid": "484763663780d86641efe56abda92b52", "score": "0.561527", "text": "public function arrayToBinary($val) {\n $saved_object_count = $this->writtenObjectCount++;\n\n $bdata = self::typeBytes(\"a\", count($val->getValue())); // a is 1010, type indicator for arrays\n\n foreach($val as $v) {\n $bval = $v->toBinary($this);\n $bdata .= self::packItWithSize($this->objectRefSize, $bval);\n }\n\n $this->objectTable[$saved_object_count] = $bdata;\n return $saved_object_count;\n }", "title": "" }, { "docid": "93300d619bb4c3b1e95e25125ce73e2f", "score": "0.55911326", "text": "function let_to_bit($sValue)\n {\n // Split value from name\n if (!preg_match('/([0-9]+)([ptgmkb]{1,2}|)/ui', $sValue, $aMatches))\n { // Invalid input\n return FALSE;\n }\n\n if (empty($aMatches[2]))\n { // No name -> Enter default value\n $aMatches[2] = 'KB';\n }\n\n if (strlen($aMatches[2]) == 1)\n { // Shorted name -> full name\n $aMatches[2] .= 'B';\n }\n\n $iBit = (substr($aMatches[2], -1) == 'B') ? 1024 : 1000;\n // Calculate bits:\n\n switch (strtoupper(substr($aMatches[2], 0, 1)))\n {\n case 'P':\n $aMatches[1] *= $iBit;\n case 'T':\n $aMatches[1] *= $iBit;\n case 'G':\n $aMatches[1] *= $iBit;\n case 'M':\n $aMatches[1] *= $iBit;\n case 'K':\n $aMatches[1] *= $iBit;\n break;\n }\n\n // Return the value in bits\n return $aMatches[1];\n }", "title": "" }, { "docid": "031b55081c4907b3123bbc627e0d0105", "score": "0.55876637", "text": "abstract public function toPHP($value);", "title": "" }, { "docid": "4b0947374cc07c4eec32a8660f4cc44b", "score": "0.55808985", "text": "public static function toHex($value) {}", "title": "" }, { "docid": "8f856a8df5a68381a95026435447b210", "score": "0.5549088", "text": "function hexToBinary($input) {\n $input_binary = \"\";\n for ($i = 0; $i < strlen($input); $i++) {\n $input_binary = $input_binary . getBinValue(substr($input, $i, 1));\n }\n return $input_binary;\n }", "title": "" }, { "docid": "e2f1be784ea2f3e029a17097841183f6", "score": "0.5547711", "text": "public function bin()\n {\n return $this->bin;\n }", "title": "" }, { "docid": "1c08bb656f7d0cae3cbbae2896506e36", "score": "0.55448365", "text": "function asc2bin($char)\r\n{\r\n\t// eg; asc2bin(\"a\") returns 01100001\r\n\treturn str_pad(decbin(ord($char)), 8, \"0\", STR_PAD_LEFT);\r\n}", "title": "" }, { "docid": "adc7890c8e2184980d80b7f756fbab8a", "score": "0.5516694", "text": "public function dictToBinary($val) {\n $saved_object_count = $this->writtenObjectCount++;\n $bdata = self::typeBytes(\"d\", count($val->getValue())); // d=1101, type indicator for dictionary\n\n foreach($val as $k => $v) {\n $str = new CFString($k);\n $key = $str->toBinary($this);\n $bdata .= self::packItWithSize($this->objectRefSize, $key);\n }\n\n foreach($val as $k => $v) {\n $bval = $v->toBinary($this);\n $bdata .= self::packItWithSize($this->objectRefSize, $bval);\n }\n\n $this->objectTable[$saved_object_count] = $bdata;\n return $saved_object_count;\n }", "title": "" }, { "docid": "f9a944416355f03f31f5b6d91c763f56", "score": "0.55039763", "text": "function _string_to_binary($term)\n{\n $length = strlen($term);\n if ($length == 0)\n {\n return chr(TAG_NIL_EXT);\n }\n elseif ($length <= 65535)\n {\n return pack('Cn', TAG_STRING_EXT, $length) . $term;\n }\n elseif ($length <= 4294967295)\n {\n $term_packed = '';\n foreach (str_split($term) as $c)\n {\n $term_packed .= chr(TAG_SMALL_INTEGER_EXT) . $c;\n }\n return pack('CN', TAG_LIST_EXT, $length) . $term_packed .\n chr(TAG_NIL_EXT);\n }\n else\n {\n throw new OutputException('uint32 overflow');\n }\n}", "title": "" }, { "docid": "86137ae5e31a7e7b95e9e3017e52f727", "score": "0.54991275", "text": "public abstract function encode($val);", "title": "" }, { "docid": "23677f469ea827f65b096edea18009c9", "score": "0.5497596", "text": "function binaryToChar($input) {\n $input_hex = \"\";\n for ($i = 0; $i < strlen($input); $i+=8) {\n $value_dec = base_convert(substr($input, $i, 8), 2, 10);\n $input_hex = $input_hex . chr($value_dec);\n }\n return $input_hex;\n }", "title": "" }, { "docid": "321f0c85db963610d67e9a2b07024052", "score": "0.547543", "text": "private function BOF() {\n $this->data .= pack(\"ssssss\", 0x809, 0x8, 0x0, 0x10, 0x0, 0x0);\n }", "title": "" }, { "docid": "325cb5702e7b84733cf2e19eb8636ace", "score": "0.54751575", "text": "function txt2bin($text)\n{\n\t$bin = '';\n\tfor ($i = 0; $i < strlen($text); $i++)\n\t{\n\t\t$bin .= substr(\"0000\".base_convert(ord(\n\t\t\tsubstr($text,$i,1)),10,2),-8);\n\t}\n\treturn $bin;\n}", "title": "" }, { "docid": "07eaf7d310663026759e931ececfad1b", "score": "0.5446148", "text": "public function escapeBytea($binary) {}", "title": "" }, { "docid": "9e77960f44c4cffc4b2eba08ebce4f48", "score": "0.5430339", "text": "function decimalToBi($value, $max)\n {\n /**\n * Convert the decimal value to certain length of binary, with padding if needed\n */\n $quantity = decbin($value);\n $result = \"{$quantity}\";\n\n if (strlen($result) < $max) {\n $padding = '';\n for ($i = 0; $i < ($max - strlen($result)); $i++) {\n $padding .= \"0\";\n }\n $result = $padding . $result;\n }\n\n return $result;\n }", "title": "" }, { "docid": "60a44c1a27dcdf4fb72c54c09c317006", "score": "0.54274017", "text": "public function getRawValue();", "title": "" }, { "docid": "435d569da11cc6af744d922f1fa3d1ee", "score": "0.54268444", "text": "public function getCodedValue() {\n return $this->value;\n }", "title": "" }, { "docid": "d7b9ea57df6326e36053ee3c05fb39c1", "score": "0.54182756", "text": "public function stringToBinary($val) {\n $saved_object_count = -1;\n\n if(!isset($this->uniqueTable[$val])) {\n $saved_object_count = $this->writtenObjectCount++;\n $this->uniqueTable[$val] = $saved_object_count;\n $utf16 = false;\n\n for($i=0;$i<strlen($val);++$i) {\n if(ord($val{$i}) >= 128) {\n $utf16 = true;\n break;\n }\n }\n\n if($utf16) {\n $bdata = self::typeBytes(\"6\", mb_strlen($val,'UTF-8')); // 6 is 0110, unicode string (utf16be)\n $val = self::convertCharset($val, 'UTF-8', 'UTF-16BE');\n $this->objectTable[$saved_object_count] = $bdata.$val;\n }\n else {\n $bdata = self::typeBytes(\"5\", strlen($val)); // 5 is 0101 which is an ASCII string (seems to be ASCII encoded)\n $this->objectTable[$saved_object_count] = $bdata.$val;\n }\n }\n else $saved_object_count = $this->uniqueTable[$val];\n\n return $saved_object_count;\n }", "title": "" }, { "docid": "6f131045c872d6b3e8e3aaac163cbb3e", "score": "0.54096115", "text": "public function binaryToString($value)\n {\n if (is_resource($value)) {\n rewind($value);\n $string = stream_get_contents($value);\n fclose($value);\n return $string;\n }\n\n return preg_replace_callback(\"/(?:\\\\\\'|\\\\\\\\\\\\\\\\|\\\\\\\\\\d{3})/\", array($this, 'binaryToStringCallback'), $value);\n }", "title": "" }, { "docid": "19652efd8a96bb80ede3d55212e5e3be", "score": "0.5392593", "text": "public function __toString() { \n return $this->encoder->encode($this->value);\n }", "title": "" }, { "docid": "59e4ac733b4ddd120d40c1b631f81b5f", "score": "0.5379239", "text": "private static function _bin($hex)\r\r\n\t{\r\r\n\t\t$bin = '';\r\r\n\t\t$length = strlen($hex);\r\r\n\t\tfor ($i = 0; $i < $length; $i += 2) {\r\r\n\t\t\t$tmp = sscanf(substr($hex, $i, 2), '%x');\r\r\n\t\t\t$bin .= chr(array_shift($tmp));\r\r\n\t\t}\r\r\n\t\treturn $bin;\r\r\n\t}", "title": "" }, { "docid": "bd914166305c20a979e2f0fc3724be11", "score": "0.53737473", "text": "function str2bin($text){\n\t$bin = array();\n\tfor($i=0; strlen($text)>$i; $i++)\n\t\t$bin[] = decbin(ord($text[$i]));\n\treturn implode(' ', $bin);\n}", "title": "" }, { "docid": "6de21bf757c6045109c4b5141cde4fbd", "score": "0.5350877", "text": "function hex2bin($data)\r\n\t{\t$len = strlen($data);\r\n\t\tfor($i=0;$i<$len;$i+=2)\t\t$newdata .= pack(\"C\",hexdec(substr($data,$i,2)));\r\n\t\treturn $newdata;\r\n\t}", "title": "" }, { "docid": "78927bdb69f202bebe62ab9f43ed6a3e", "score": "0.53441685", "text": "function bin2str($bin){\n\t$text = array();\n\t$bin = explode(' ', $bin);\n\tfor($i=0; count($bin)>$i; $i++)\n\t\t$text[] = chr(@bindec($bin[$i]));\n\treturn implode($text);\n}", "title": "" }, { "docid": "419fa00d2e8ee5f25f89bbaad77d024d", "score": "0.53372097", "text": "public function getBinarySafeString()\n {\n $bytes = [\n '01011001', '11010001', '00001111', '11101001', '10010100', '01010110', '10111110', '00111011',\n '10001101', '11100010', '00110110', '10101100', '11000100', '01010100', '10100010', '11110001',\n '01100101', '01000001', '01100010', '01001000', '01000110', '01011001', '11001000', '10111010',\n '01100000', '11010111', '00001111', '00011011', '10011011', '11010011', '01011110', '01110100',\n '10000111', '11001001', '10000111', '11011111', '11010000', '00111000', '10001011', '11110000',\n '01111111', '00110010', '00010010', '11101110', '00011101', '11101001', '11000111', '10111101',\n '11000001', '00110011', '01101001', '11010010', '01011011', '01110011', '11000111', '00101101',\n '01010001', '11010110', '00000001', '11101111', '00100001', '00111110', '11100110', '10111011',\n '11010010', '00100101', '10101001', '01100101', '01101011', '10000101', '11111000', '00000101',\n '01000101', '01101011', '11100101', '01100001', '10010001', '01011011', '01110100', '11101010',\n '01001111', '01011011', '00010001', '00110100', '11001000', '00001101', '01000010', '00101011',\n '11010010', '00001100', '10111001', '10100001', '01011001', '10100100', '10100000', '10001110',\n '11010111', '10011011', '00111001', '01100010', '11001000', '00001101', '01000010', '00101011',\n ];\n $binarySafeString = null;\n foreach ($bytes as $binary) {\n $binarySafeString .= pack('H*', dechex(bindec($binary)));\n }\n return $binarySafeString;\n }", "title": "" }, { "docid": "a61708ccb1f0123bf868d6841af3effe", "score": "0.5328962", "text": "public abstract function toBinary(CFBinaryPropertyList &$bplist);", "title": "" }, { "docid": "07d0612364d9eaec92203847e872fb06", "score": "0.5321382", "text": "public function hex() {\n\n\t\tif( $this->type == \"string\" ) {\n\t\t\treturn $this->chain( hexdec( $this->val ) );\n\t\t} else {\n\t\t\treturn $this->val;\n\t\t}\n\n\t}", "title": "" }, { "docid": "5c55faa3e3fb5d02a95dd8ebbb93db1d", "score": "0.53173625", "text": "public function toBinary(CFBinaryPropertyList &$bplist) {\n return $bplist->stringToBinary($this->value);\n }", "title": "" }, { "docid": "84a8e3cb4836d0c5e3394a9846e79b65", "score": "0.5315925", "text": "public function toBinary(CFBinaryPropertyList &$bplist) {\n return $bplist->dataToBinary($this->getValue());\n }", "title": "" }, { "docid": "2f6a99de92b66718dbe6ad11ed5b6bdd", "score": "0.53093576", "text": "function tenToBinary($num,$j){\n\t$tem=pow(2,-$j);\n\tif($j>23){\n\t\treturn '';\n\t}else if(($num-$tem)==0){\n\t\treturn '1';\n\t}else{\n\t\tif(($num-$tem)>0){\n\t\t\treturn '1'.tenToBinary($num-$tem,++$j);\n\t\t}else{\n\t\t\treturn '0'.tenToBinary($num,++$j);\n\t\t}\t\t\n\t}\n}", "title": "" }, { "docid": "fd291dd843b531ff4f6b450f896263a2", "score": "0.5306766", "text": "public function toPrimitive();", "title": "" }, { "docid": "11324acc301a4671bdfa150d4d9ea7e5", "score": "0.53020066", "text": "public function toBinary() {\n return Util::base64url_decode($this->data['k']);\n }", "title": "" }, { "docid": "2d56b536e545f360a853c33ff34d42a6", "score": "0.52920425", "text": "public function writeI64($value) {\n // 64-bit twos-complement arithmetic since PHP wants to treat all ints\n // as signed and any int over 2^31 - 1 as a float\n if (PHP_INT_SIZE == 4) {\n $neg = $value < 0;\n\n if ($neg) {\n $value *= -1;\n }\n\n $hi = (int)($value / 4294967296);\n $lo = (int)$value;\n\n if ($neg) {\n $hi = ~$hi;\n $lo = ~$lo;\n if (($lo & (int)0xffffffff) == (int)0xffffffff) {\n $lo = 0;\n $hi++;\n } else {\n $lo++;\n }\n }\n $data = pack('N2', $hi, $lo);\n\n } else {\n $hi = $value >> 32;\n $lo = $value & 0xFFFFFFFF;\n $data = pack('N2', $hi, $lo);\n }\n\n $this->trans_->write($data, 8);\n return 8;\n }", "title": "" }, { "docid": "29ebe3cd667f5442845c28d65d721558", "score": "0.5267659", "text": "function verCodLong($acceso,$valor){\t\n\t$cont = verCo($acceso,$valor);\n\t\tif($cont<100000)\n\t\t\t$cont=\"0\".$cont;\n\t\tif($cont<1000000)\n\t\t\t$cont=\"0\".$cont;\n\t\tif($cont<10000000)\n\t\t\t$cont=\"0\".$cont;\n\treturn $cont;\t\n}", "title": "" }, { "docid": "0310502752ed7aa0ccdb0613ef6ef9bf", "score": "0.52578837", "text": "public function getBin() {\n return $this->bin;\n }", "title": "" }, { "docid": "de4f1d8da049971ea87d287bacacfa15", "score": "0.5246234", "text": "function fake_bin($s): string {\n\t$s = str_split($s);\n\t$b = [];\n\tforeach($s as $v){\n\t\tif($v <= 4){\n\t\t\t$b[] = 0;\n\t\t}else{\n\t\t\t$b[] = 1;\n\t\t}\n\t}\n\treturn implode('', $b);\n}", "title": "" }, { "docid": "98edec8949bbc0035ef982ca75fb7470", "score": "0.5243563", "text": "protected static function pack($binary) {\n\t\treturn bindec($binary);\n\t}", "title": "" }, { "docid": "333ec5705f5b3ba19ab9d861caf03eea", "score": "0.5216209", "text": "private function _encodeInteger($data = null)\n {\n $data = is_null($data) ? $this->_data : $data;\n return sprintf('i%.0fe', $data);\n }", "title": "" }, { "docid": "1483f10bf150a689382e719d3797688f", "score": "0.5210102", "text": "public function toBinary(CFBinaryPropertyList &$bplist) {\n return $bplist->dateToBinary($this->value);\n }", "title": "" }, { "docid": "c87a9288cf408e52ae3f408628319291", "score": "0.5207317", "text": "public function asBinary(): IBinaryTypeReference;", "title": "" }, { "docid": "419ec2113fb5d2a130da88abd76e733e", "score": "0.52021885", "text": "function mhex2bin($s) \r\n{\r\n $mp['0'] = \"0000\"; \r\n $mp['1'] = \"0001\"; \r\n $mp['2'] = \"0010\"; \r\n $mp['3'] = \"0011\"; \r\n $mp['4'] = \"0100\"; \r\n $mp['5'] = \"0101\"; \r\n $mp['6'] = \"0110\"; \r\n $mp['7'] = \"0111\"; \r\n $mp['8'] = \"1000\"; \r\n $mp['9'] = \"1001\"; \r\n $mp['A'] = \"1010\"; \r\n $mp['B'] = \"1011\"; \r\n $mp['C'] = \"1100\"; \r\n $mp['D'] = \"1101\"; \r\n $mp['E'] = \"1110\"; \r\n $mp['F'] = \"1111\"; \r\n $bin = \"\";\r\n\r\n for ($i = 0; $i < strlen($s); $i++) { \r\n $bin .= $mp[$s[$i]]; \r\n } \r\n return $bin; \r\n}", "title": "" }, { "docid": "d5d6f6b6255cbe3e2cf51420d9f06815", "score": "0.51766586", "text": "function mask2bin ( $mask ) {\n if ( count ( explode (\".\", $mask) ) == 4 ) {\n return ip2long ($mask);\n } else {\n if ( $mask <= 32 && $mask >= 0 ) {\n $bin_mask = compat_str_pad ( \"\", $mask, \"1\" );\n $bin_mask = compat_str_pad ( $bin_mask, 32, \"0\", STR_PAD_RIGHT );\n return $bin_mask;\n } else {\n return compat_str_pad ( \"\", 32, \"1\" );\n }\n }\n}", "title": "" }, { "docid": "1c4d3a156a0e3c56d9bc2990e14a5f7d", "score": "0.5172716", "text": "public function toHex(): string\n {\n return Strings::bin2hex($this->toBytes());\n }", "title": "" }, { "docid": "d853e1b2e6d01cdd83f196a080d88178", "score": "0.51705945", "text": "function _postEncode($barnumber) {\r\n\t\t$encTable\t= array(\"11000\", \"00011\", \"00101\", \"00110\", \"01001\", \"01010\", \"01100\", \"10001\", \"10010\", \"10100\");\r\n\t\t$sum\t\t= 0;\r\n\t\t$encstr\t\t= \"\";\r\n\r\n\t\t// Encoding data\r\n\t\tfor($i=0; $i<strlen($barnumber); $i++) {\r\n\t\t\t$sum\t+= (int)$barnumber[$i];\r\n\t\t\t$encstr\t.= $encTable[(int)$barnumber[$i]];\r\n\t\t}\r\n\r\n\t\t// Creating check digit\r\n\t\tif($sum % 10 != 0)\r\n\t\t\t$check = (int)(10 - ($sum % 10));\r\n\r\n\t\t$encstr\t.= $encTable[$check];\r\n\t\t$encstr\t= \"1\".$encstr.\"1\";\r\n\r\n\t\t// Return encoded data\r\n\t\treturn $encstr;\r\n\t}", "title": "" }, { "docid": "c7347e9a685cb2fd591d755aaadd9d91", "score": "0.5159083", "text": "function trinaryToStr($str1){\r\n$rtn_data =\"\";\r\n$string_data = str_split($str1,5);\r\nfor ($i=0; $i<count($string_data); $i++){\r\n $rtn_data .= base_convert($string_data[$i],3,16);\r\n}\r\nreturn hexToStr($rtn_data);\r\n}", "title": "" }, { "docid": "67f3bdd9496fa577a50413b8e24282c6", "score": "0.51575553", "text": "public function __toString()\n {\n return (string) intval($this->toNative());\n }", "title": "" }, { "docid": "61739ee3592eba4b4643bd7e70c986d8", "score": "0.5153466", "text": "public function encode();", "title": "" }, { "docid": "709346e78b056c6d02c94775097e0b97", "score": "0.51491654", "text": "function _openid_btwoc($num) {\n return pack('H*', $num);\n}", "title": "" }, { "docid": "ab8047a5219174ad2a1973226d958092", "score": "0.5142884", "text": "public function encodeValue($value, $inputType);", "title": "" }, { "docid": "b16c82dbed07ff565e9991d623fbd654", "score": "0.5139238", "text": "function ifx_byteasvarchar($mode)\n{\n}", "title": "" }, { "docid": "427bf444e21bd2c45439b8a34a01899e", "score": "0.5136103", "text": "function ip2bin($ip){\n\t$i\t= explode('.',$ip);\n\treturn sprintf(\".%08b.%08b.%08b.%08b\",$i[0],$i[1],$i[2],$i[3]);\n}", "title": "" }, { "docid": "b3075558975ed6781062a278989740c8", "score": "0.5133943", "text": "function xmlrpc_encode($value) {}", "title": "" }, { "docid": "30d6b069c38054969cf5b47c5f90ec95", "score": "0.51106423", "text": "function sqlite_udf_decode_binary($data) {}", "title": "" }, { "docid": "497895a95ec72724eb1dc9d6418e66e8", "score": "0.5106844", "text": "public function getOperatesBinary()\n {\n return static::OPERATES_BINARY;\n }", "title": "" }, { "docid": "9e135e8d93e110d8c0b2129e383d0bbd", "score": "0.5086094", "text": "public function __toString() {\n return $this->hex();\n }", "title": "" } ]
22a63645d57a5624f5ce0386d22b7231
Get total lessons no set preview
[ { "docid": "b0d0b41ba321588dc35e25a83b83ffe6", "score": "0.61041045", "text": "public function get_total_no_preview_items( $total_preview_items = 0 ) {\n\t\tglobal $wpdb;\n\t\t$query = $wpdb->prepare( \"\n\t\t SELECT COUNT(ID)\n\t\t FROM {$wpdb->posts} p\n\t\t WHERE p.post_type = %s\n\t\t AND p.post_status NOT LIKE 'auto-draft'\n\t\t AND p.post_status NOT LIKE 'trash'\n\t\t \", LP_LESSON_CPT );\n\n\t\treturn $wpdb->get_var( $query ) - $total_preview_items;\n\t}", "title": "" } ]
[ { "docid": "b41b3e4b820b7e84d0a002070e387a88", "score": "0.6739828", "text": "public function get_total_preview_items() {\n\t\t$query = $this->wpdb->prepare( \"\n\t\t SELECT COUNT(ID) FROM $this->tb_posts p\n\t\t INNER JOIN {$this->tb_postmeta} pm\n\t\t ON p.ID = pm.post_id\n\t\t AND pm.meta_key = %s\n\t\t WHERE pm.meta_value = %s\n\t\t AND p.post_type = %s\",\n\t\t\t'_lp_preview', 'yes', LP_LESSON_CPT );\n\n\t\treturn $this->wpdb->get_var( $query );\n\t}", "title": "" }, { "docid": "6c11696033570d9c71fc0643a0731258", "score": "0.6017182", "text": "public function count_preview_items() {\n\t\t\t$count_preview = $this->get_preview_items();\n\n\t\t\tif ( false === $count_preview ) {\n\t\t\t\t$count_preview = 0;\n\t\t\t\t$items = $this->get_items();\n\n\t\t\t\tif ( $items ) {\n\t\t\t\t\t$count_all = sizeof( $items );\n\t\t\t\t\t$count_no_preview = 0;\n\t\t\t\t\t$no_preview_items = $this->get_items( '', false );\n\n\t\t\t\t\tif ( $no_preview_items ) {\n\t\t\t\t\t\t$count_no_preview = sizeof( $no_preview_items );\n\t\t\t\t\t}\n\n\t\t\t\t\t$count_preview = $count_all - $count_no_preview;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$count_preview = sizeof( $count_preview );\n\t\t\t}\n\n\t\t\treturn apply_filters( 'learn-press/count-preview-items', $count_preview, $this->get_id() );\n\t\t}", "title": "" }, { "docid": "8cbf00959587e03f03353a956f8f4f69", "score": "0.5938966", "text": "function show_total_original() {\n return $this->total_original;\n }", "title": "" }, { "docid": "0de5d0746ee28bb9bf2b70243e2364b8", "score": "0.5886829", "text": "public function getNumberDisplays()\n {\n return $this->getDataDisplays()->count();\n }", "title": "" }, { "docid": "c9a863304624bbb5abded264688c09dc", "score": "0.57718974", "text": "function get_user_forum_new_count ( ) {\n $view = views_get_view ( 'advanced_forum_new_topics' );\n $display_id = 'default';\n \n if ( $view ) {\n $view->preview ( $display_id );\n if ($view->result) {\n return ( $view->total_rows ); \n } else {\n return null;\n }\n \n }\n}", "title": "" }, { "docid": "0885e1baad0b715e84f9b81aa547b8f1", "score": "0.57082796", "text": "protected function _getNrDemoRecommendations ()\r\n\t{\r\n\t\t$oConfig = $this->getConfig();\r\n\t\tif ( !$oConfig->getShopConfVar( 'az_epoq_blDemoRec' ) ) {\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t\t\r\n \treturn $oConfig->getShopConfVar( 'az_epoq_iDemoRec' );\r\n\t}", "title": "" }, { "docid": "f7f98fb286b569142224236c32579460", "score": "0.5704234", "text": "public function tbreviewcount();", "title": "" }, { "docid": "7121ccfbf6bd3d401caa61fe06fa4323", "score": "0.5652022", "text": "public function total_sponsors() {\r\n\t\t$this->layout = '';\r\n\t\t$data = $this->Sponsor->find(\r\n\t\t\t'count',\r\n\t\t\tarray(\r\n\t\t\t\t'conditions' => array('delete_status' => 0)\r\n\t\t\t)\r\n\t\t);\r\n\t\treturn $data;\r\n\t}", "title": "" }, { "docid": "647ec59affc08d42fe30d03f8a52dfe0", "score": "0.5650312", "text": "public function getNbMoisPreavis() {\n return $this->nbMoisPreavis;\n }", "title": "" }, { "docid": "2fc7de570b2bdb504d55f8698e6d3060", "score": "0.5619495", "text": "function awepop_get_view_count() {\n\t\tglobal $post;\n\t\t$current_views = get_post_meta($post->ID, \"awepop_views\", true);\n\t\tif(!isset($current_views) OR empty($current_views) OR !is_numeric($current)views) {\n\t\t\t$current_views = 0;\n\t\t}\n\t\t\n\t\treturn $current_views;\n\t\t\n\t}", "title": "" }, { "docid": "4a716109824c41c189adf75662b20e9a", "score": "0.55997473", "text": "function popular_get_view_count(){\n\tglobal $post;\n\t$current_views = get_post_meta($post->ID, \"pop_post_views\", true);\n\tif(!isset($current_views) OR empty($current_views) OR !is_numeric($current_views)){\n\t\t$current_views = 0;\n\t}\n\treturn $current_views;\n}", "title": "" }, { "docid": "408acb3b20eacd53920645e466e4b23b", "score": "0.5573401", "text": "public function countVisible(): int;", "title": "" }, { "docid": "573fb2674fe5c236b47e727219fea08b", "score": "0.5545909", "text": "function GetNumPoints() {\n return $this->num_points;\n }", "title": "" }, { "docid": "a6e74e6e9ad822134e63a095930aff8e", "score": "0.54936755", "text": "public function getTotalNonHidden() {\n return $this->getTotalNonHiddenNonExtraCredit() + $this->getTotalNonHiddenExtraCredit();\n }", "title": "" }, { "docid": "b8043abfbb28f827dd45f43f48aeaa4d", "score": "0.5479136", "text": "public function lessons()\n {\n }", "title": "" }, { "docid": "a66f2954a99bf0fe42b58c68d0e60f85", "score": "0.54700416", "text": "protected function get__reviews()\n\t{\n\t\treturn $this->count_reviews;\n\t}", "title": "" }, { "docid": "63a68017523f0e164f7678d6e3bc0bdf", "score": "0.5440581", "text": "public function getTotalNb() {\n return $this->totalNb;\n }", "title": "" }, { "docid": "74b40bd1923574def7c53ca2e9c04fec", "score": "0.5439298", "text": "public function total_fornecedores(){\n \n return $this->find('count');\n \n }", "title": "" }, { "docid": "8232830a80f63fa7e993410c6d0239d8", "score": "0.543819", "text": "public function getChapters()\n {\n return \"El total de capitulos del libro es: \".count($this->index);\n }", "title": "" }, { "docid": "b2397b4e440c15478370c641d6f2a4f1", "score": "0.5424736", "text": "public function numNews()\n {\n return $this->newsManager()->numNews();\n }", "title": "" }, { "docid": "29ce8549e2635a41ad0c66f5eea83c5c", "score": "0.5424568", "text": "function getNbrArticle(){\n\n\treturn count($this->panier);\n\n}", "title": "" }, { "docid": "c94637fef9879a762a179de359d0355d", "score": "0.5414836", "text": "public function getNumVoie() {\n return $this->numVoie;\n }", "title": "" }, { "docid": "c94637fef9879a762a179de359d0355d", "score": "0.5414836", "text": "public function getNumVoie() {\n return $this->numVoie;\n }", "title": "" }, { "docid": "c94637fef9879a762a179de359d0355d", "score": "0.5414836", "text": "public function getNumVoie() {\n return $this->numVoie;\n }", "title": "" }, { "docid": "26f3c151a24077e481dee256f0365f52", "score": "0.53766644", "text": "public function countDetalhes()\n {\n return count($this->movimentos);\n }", "title": "" }, { "docid": "21e340d27261c75b9555a6f1e03accc2", "score": "0.5372628", "text": "public function getNumCptReflechi() {\n return $this->numCptReflechi;\n }", "title": "" }, { "docid": "a0af81a167201cafaf3f76fccf57a3e4", "score": "0.53618807", "text": "public function total(): int {\n\t\treturn $this->model->get_topics_number() + $this->model->get_quizzes_number();\n\t}", "title": "" }, { "docid": "6f44085f20d3664b369d6ce81e17a5f3", "score": "0.53608835", "text": "public function getNumVoieLivraison() {\n return $this->numVoieLivraison;\n }", "title": "" }, { "docid": "cd408b3040d6d4c9fc317bfbf057544b", "score": "0.5350606", "text": "public function getPagesToShow()\n {\n return min($this->getPagesCount(), $this->_pagesToShowOption());\n }", "title": "" }, { "docid": "e406f72fb37ff056fc66f1e874ae19d7", "score": "0.5340161", "text": "public function getNbRep()\n {\n return $this->nbRep;\n }", "title": "" }, { "docid": "e8abb1d0d7ad9a1cde950db62a901588", "score": "0.5338098", "text": "function get_n_news($link) {\n $query=sprintf(\"select num from newssiterazd where id='%d'\",$this->razd);\n $link->query($query);\n $f=$link->next_record();\n return $f['num'];\n }", "title": "" }, { "docid": "4283c76aadf21c35b83838fd882df351", "score": "0.5328326", "text": "function show_total() {\n return $this->total;\n }", "title": "" }, { "docid": "6955f32577b41ed634644d62ee3e1426", "score": "0.5323611", "text": "public function getNiveauAnalytique(): ?int {\n return $this->niveauAnalytique;\n }", "title": "" }, { "docid": "a5e2caaed6b3ee511dc8ee9268d9eb85", "score": "0.5317808", "text": "public function countLigne_produit_compose(){\n\t\t\t\t\t return count($this->listeLigne_produit_compose());\n\t\t\t\t\t }", "title": "" }, { "docid": "12f374e7dee8f5cb62701342d44c341e", "score": "0.5310326", "text": "public function getArticleCount() {\n\n return tx_ptgsashop_articleAccessor::getInstance()->selectOnlineArticlesQuantity();\n \n }", "title": "" }, { "docid": "80cac6dff468c8375852245f206127cb", "score": "0.5307118", "text": "protected function get__unapprovedReviews()\n\t{\n\t\treturn $this->count_reviews_hidden;\n\t}", "title": "" }, { "docid": "1aa2b0b58708393801aa3083f375b860", "score": "0.53024673", "text": "public function getNbControlesPrevus() {\n return $this->nbControlesPrevus;\n }", "title": "" }, { "docid": "d51610f8b811b78c4ccff412b351aad6", "score": "0.5285178", "text": "function show_total_records()\n\t{\n\t\treturn $this->total_rows;\n\t\n\t}", "title": "" }, { "docid": "85c2bf2d193e3d8a2e3aa365163acf00", "score": "0.52703404", "text": "function total_campos(){\n\n return count($this->campos);\n\n }", "title": "" }, { "docid": "8132ec46d0a492a83541ddb6baa6ca72", "score": "0.52649444", "text": "public function getNummodule6()\n {\n return $this->nummodule6;\n }", "title": "" }, { "docid": "47ef55b559dd8eb3e1a31c01071586ca", "score": "0.5264698", "text": "public function getCommentsNb()\n {\n return 0;\n }", "title": "" }, { "docid": "4b7335fec22ef52963791fc9f7c36b4b", "score": "0.5262135", "text": "public function numberOfReviews()\n { \n $number = request('total');\n $film_id = request('film_id');\n $reviews = Reviews::where('film_id','=',$film_id)->orderBy('helpfullreviewcount','desc')->take($number)->get()->toArray();\n //return count($reviews);\n return view('student.ajaxLoadReview', compact('reviews'));\n }", "title": "" }, { "docid": "c2d27b901cc237b92eb6383a1c04c6e6", "score": "0.52601635", "text": "public function num_introductions()\n\t{\n\t\t$query = DB::query('SELECT * FROM `actionsteps` WHERE boat_share_id='.$this->id.' AND (type=\"introduction\" OR actionstep_set_id=1)');\n\t\treturn count($query->as_object()->execute());\t\n\t}", "title": "" }, { "docid": "937a2e8f6d03dd2fcea794fa2cef5e1d", "score": "0.5253369", "text": "function getNumberOfReviews() {\n return $this->_totalReviews;\n }", "title": "" }, { "docid": "b73379dbda841eee814b3a343f9d8411", "score": "0.5241364", "text": "public function getNumConta(){\n return $this->numConta;\n }", "title": "" }, { "docid": "6ebaa7af84519ba7e4c6f03ac22ddb4d", "score": "0.52394783", "text": "public function getViewCount()\n {\n return $this->viewCount;\n }", "title": "" }, { "docid": "8ce25b9b1f8802981d8004ccaff63da6", "score": "0.52313817", "text": "function num_ControlLabs(){\n $this->db->order_by(\"idControlLab\", \"desc\");\n $number = $this->db->query(\"select count(*) as number from ControlLab\")->row()->number;\n return intval($number);\n }", "title": "" }, { "docid": "732d79065be9154e9c328a03924a9990", "score": "0.5225968", "text": "public function getExampleCount()\n {\n return $this->example_count;\n }", "title": "" }, { "docid": "2235a423c788b05528c4cdc642484bb7", "score": "0.521594", "text": "function star_ratings_review_count() {\n\t\tglobal $post;\n\n\t\t$rating = get_post_meta( $post->ID, CRITIC_PAVG_KEY, true );\n\t\t$total = get_post_meta( $post->ID, CRITIC_PVOTE_KEY, true );\n\n\t\t$results = '<div class=\"critic-rating-result-wrap\"><span class=\"critic-rating-result\" data-rating=\"' . esc_attr( (float) $rating ) . '\"></span> <span class=\"critic-rating-total\">(' . number_format( (int) $total ) . ')</span></div>';\n\n\t\t/**\n\t\t * Filter the total rating stars and results html.\n\t\t *\n\t\t * @since 4.0.0\n\t\t *\n\t\t * @param string $results The html review star rating and total count.\n\t\t * @param int $rating The avg star rating number.\n\t\t * @param int $total The total number of reviews.\n\t\t * @param WP_Post $post Post object.\n\t\t */\n\t \techo apply_filters( 'cp_star_ratings_review_count', $results, $rating, $total, $post );\n\t}", "title": "" }, { "docid": "816ade7894734e65aa08bb31c34d9757", "score": "0.5211071", "text": "function draft_num(){\n\t$posts_draft = get_posts_a('count(*)' ,' WHERE `status` = 0 ');\n\t$count = $posts_draft[\"0\"][\"count(*)\"];\n\t\n\treturn $count;\n}", "title": "" }, { "docid": "904a59f6a2e7e921b7d64d188f6a3beb", "score": "0.52073056", "text": "public function getArticuleVisitCnt()\n {\n return $this->articuleVisitCnt;\n }", "title": "" }, { "docid": "a1414865b7cebca51b9fa4b6d1f6ce24", "score": "0.519684", "text": "public static function ctrMostrarTotalGastos(){\n\n\n\n\t\t$tabla = 'presupuesto';\n\n\n\n\t\t$respuesta = ModeloPresupuesto::mdlMostrarTotalGasto($tabla);\n\n\n\n\t\treturn $respuesta;\n\n\n\n\t}", "title": "" }, { "docid": "b7dd6894575045c82d31f3bb334640db", "score": "0.5183098", "text": "public function getNbJourAnnee() {\n return $this->nbJourAnnee;\n }", "title": "" }, { "docid": "affefb4497810c68f898d28c2ef98a3e", "score": "0.51710993", "text": "function sensei_courses_per_row(){\n\n echo Sensei_Course::get_loop_number_of_columns();\n\n}", "title": "" }, { "docid": "5ad0c9383b4f536d7ae91de4fe34cf93", "score": "0.51685536", "text": "public function getViewCounter()\n {\n return $this->viewRepository->getCount();\n }", "title": "" }, { "docid": "054ac88ade3f669e4eb0e1f88fc9e539", "score": "0.516602", "text": "public function getLinesNb()\n {\n return $this->lines_nb;\n }", "title": "" }, { "docid": "ab9e0512a5bd1825a75f3ea1c942f224", "score": "0.5165842", "text": "public function getNiveau()\n {\n return $this->niveau;\n }", "title": "" }, { "docid": "53dc18510cb0947da30ce23025df5941", "score": "0.51597804", "text": "public function getTotalCount(): int;", "title": "" }, { "docid": "5e7b543479643fdfb350e39b0f5b55ba", "score": "0.5151612", "text": "public function getNiveau()\n {\n return $this->_niveau;\n }", "title": "" }, { "docid": "7a8faf586607c5afcf4ab86d9f25dfe8", "score": "0.51514155", "text": "private function _getTotalLines() {\n return $this->_lines[\"total\"];\n }", "title": "" }, { "docid": "8d941dfb25c3d3edccd9ab7f1b419456", "score": "0.5151405", "text": "public function getNbPieceLogement() {\n return $this->nbPieceLogement;\n }", "title": "" }, { "docid": "8ab3c6b06924d8e9a6c6aff72f8583fb", "score": "0.5150857", "text": "public function getStepisCount() {\n return $this->count(self::STEPIS);\n }", "title": "" }, { "docid": "31fa6e15421c982cabf18728fb68a748", "score": "0.5136229", "text": "public function listLenght(){\n return $this->cont;\n }", "title": "" }, { "docid": "3967a60582378b5ea7f5692eac1ee2c1", "score": "0.5133981", "text": "public function getNumstrett()\n {\n return $this->numstrett;\n }", "title": "" }, { "docid": "277f9545491d58c5c7c64ddc544d7e9c", "score": "0.5130251", "text": "public function getTotalNum()\r\n {\r\n return $this->totalNum;\r\n }", "title": "" }, { "docid": "f308287dd0f5029ba56f3c54ed4ae32a", "score": "0.51271784", "text": "public function count_items( $type = '', $include_preview = true ) {\n\t\t\tglobal $wpdb;\n\n\t\t\t$item_types = learn_press_get_course_item_types();\n\t\t\t$item_type_format = array_fill( 0, sizeof( $item_types ), '%s' );\n\n\t\t\t// $query =$wpdb->prepare(\"\n\t\t\t// SELECT it.ID\n\t\t\t// FROM {$wpdb->posts} c\n\t\t\t// INNER JOIN {$wpdb->learnpress_sections} s ON s.section_course_id = c.ID\n\t\t\t// INNER JOIN {$wpdb->learnpress_section_items} si ON si.section_id = s.section_id\n\t\t\t// INNER JOIN {$wpdb->posts} it ON it.ID = si.item_id\n\t\t\t// WHERE c.ID = %d\n\t\t\t// AND it.post_type IN (\".join(',', $item_type_format).\")\n\t\t\t// \", );\n\n\t\t\tif ( $type === '' && $include_preview === true ) {\n\t\t\t\t$count_items = $this->get_meta( 'count_items' );\n\n\t\t\t\tif ( false === $count_items ) {\n\t\t\t\t\t$items = $this->get_item_ids();\n\t\t\t\t\t$count_items = sizeof( $items );\n\t\t\t\t\t$this->update_meta( 'count_items', $count_items );\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$key = md5(\n\t\t\t\t\tserialize(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'course' => $this->get_id(),\n\t\t\t\t\t\t\t'type' => $type,\n\t\t\t\t\t\t\t'preview' => $include_preview,\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t);\n\n\t\t\t\t$count_items = LP_Object_Cache::get( $key, 'learn-press/count-items' );\n\t\t\t\tif ( false === $count_items ) {\n\t\t\t\t\t$count_items = 0;\n\t\t\t\t\t$items = $this->get_items( $type, $include_preview );\n\n\t\t\t\t\tif ( $items ) {\n\t\t\t\t\t\t$count_items = sizeof( $items );\n\t\t\t\t\t}\n\n\t\t\t\t\tLP_Object_Cache::set( $key, $count_items, 'learn-press/count-items' );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn apply_filters( 'learn-press/count-items', $count_items, $type, $include_preview, $this->get_id() );\n\t\t}", "title": "" }, { "docid": "f906ad997c4a45b88939369d345aa042", "score": "0.5117436", "text": "function getNumRows() {\n return $this->number;\n }", "title": "" }, { "docid": "d14d8a6141c7fe087bed94edb7ef837f", "score": "0.51171565", "text": "function total_reponses($question){\n $args = array(\n 'champs_cibles'=>array('count(*) as nb'), \n 'clause_where'=>array('ID_question'=>$question)\n );\n \n $total = execute_sql(\"SELECT\", \"reponses\", $args);\n $total = $total->fetch(PDO::FETCH_ASSOC);\n\n return $total['nb'];\n }", "title": "" }, { "docid": "e763d2ebec457fe014800834ce5f98c9", "score": "0.51034766", "text": "public function getNbredeplans()\n {\n return $this->nbredeplans;\n }", "title": "" }, { "docid": "a918987f8c274d73bb9c9cec8a0ad72d", "score": "0.50974536", "text": "public function getPromotionPoints(): ?int\n {\n return $this->promotionPoints;\n }", "title": "" }, { "docid": "9265f75700a8252a0f7982de86f57cc2", "score": "0.5093783", "text": "public function getNumComments(){\n $num = $this->comments()->count();\n if($num <= 1) {\n return $num. ' Commentaire';\n }\n return $num. ' Commentaires';\n }", "title": "" }, { "docid": "ddde09e7d203a28722197e6cf2e2a2cc", "score": "0.5081274", "text": "public function getTotalNonExtraCredit() {\n return $this->getTotalNonHiddenNonExtraCredit() + $this->getTotalHiddenNonExtraCredit();\n }", "title": "" }, { "docid": "b445d7ee3222e05614e09d750717bfe3", "score": "0.50778526", "text": "abstract function getExaminedDocumentCount();", "title": "" }, { "docid": "6937136b7ffc5941c84a27e6c65f0855", "score": "0.50734776", "text": "public function count()\n {\n return $this->total;\n }", "title": "" }, { "docid": "6937136b7ffc5941c84a27e6c65f0855", "score": "0.50734776", "text": "public function count()\n {\n return $this->total;\n }", "title": "" }, { "docid": "a001285f95873e657fd890401c09dc71", "score": "0.5073247", "text": "function total_lesser() {\n\t\t\n\t}", "title": "" }, { "docid": "44f136dc92237bd0c2b1d0b53c21b887", "score": "0.50659263", "text": "public function getTotalfls(){\n return $this->totalfls;\n }", "title": "" }, { "docid": "d771a7efc65db627e6eb4c482039e88d", "score": "0.5056613", "text": "public function getTotalCount(): ?int;", "title": "" }, { "docid": "75bdad7348f22321a047e37aca1b37ae", "score": "0.50482255", "text": "function getDesignTotalRecords() { return $this->_designtotalrecords; }", "title": "" }, { "docid": "c7b9a79dd746c1e79ef05ac184c63e69", "score": "0.50468254", "text": "public function getRemainderCount() {\n return $this->get(self::REMAINDERCOUNT);\n }", "title": "" }, { "docid": "31966ed27e6925d1ffdd0d08285486d5", "score": "0.5046638", "text": "function get_total_pages ()\r\n {\r\n return $this->total_pages;\r\n }", "title": "" }, { "docid": "820fb88304f2ac427f74113ec2f36156", "score": "0.5044176", "text": "public function getPageviews() : ?int\n {\n $rtn = $this->data['pageviews'];\n\n return $rtn;\n }", "title": "" }, { "docid": "db64abd0e8d7dcc1d5276a4cb0eec12f", "score": "0.50440687", "text": "function preview() {\n if (!$this->is_batched()) {\n // Can replace with return parent::preview() when views 2.12 lands.\n if (!empty($this->view->live_preview)) {\n // Change the items per page:\n $this->view->set_items_per_page(20);\n return '<p>' . t('A maximum of 20 items will be shown here, all results will be shown on export.') . '</p><pre>' . check_plain($this->view->render()) . '</pre>';\n }\n return $this->view->render();\n }\n return '';\n }", "title": "" }, { "docid": "b19a96d555f170e9a7e9f0ba02135057", "score": "0.50402945", "text": "public function getTotalCount();", "title": "" }, { "docid": "b9707718f803aca2272f60037064f0dd", "score": "0.50387776", "text": "public function getNumVoie(): ?string {\n return $this->numVoie;\n }", "title": "" }, { "docid": "b9707718f803aca2272f60037064f0dd", "score": "0.50387776", "text": "public function getNumVoie(): ?string {\n return $this->numVoie;\n }", "title": "" }, { "docid": "b9707718f803aca2272f60037064f0dd", "score": "0.50387776", "text": "public function getNumVoie(): ?string {\n return $this->numVoie;\n }", "title": "" }, { "docid": "9250ee8ded819948537130e4d148cc73", "score": "0.5035545", "text": "function size()\n\t{\n\t\treturn $this->nb;\n\t}", "title": "" }, { "docid": "cfe56d86e07a702d35de9c76607895c4", "score": "0.5032846", "text": "public function more()\n\t{\n\t\treturn $this->scope->more;\n\t}", "title": "" }, { "docid": "2544a98f74e32ea398697a982e6e6e21", "score": "0.50168467", "text": "public function getNumberPages()\r\n {\r\n $request = $this->db->prepare('SELECT COUNT(*) AS chaptersNumber FROM chapters');\r\n $request->execute();\r\n return $request->fetchColumn()/5;\r\n }", "title": "" }, { "docid": "93ec471449bce1731144d5f3e5cfa9f1", "score": "0.50156105", "text": "public function hasLookCount(){\r\n return $this->_has(6);\r\n }", "title": "" }, { "docid": "c08b9de658d481c005a9d935c83e2d0b", "score": "0.5014462", "text": "public function reviewCount(){\n $count = $this->reviews()->count();\n if(empty($count)){\n return 0;\n }\n return $count;\n }", "title": "" }, { "docid": "acaaef3d8dbc71190e968182b1c79498", "score": "0.50088215", "text": "public function get_total_used() {\r\n return apply_filters( 'wpcoupon_coupon_total_used', intval( $this->_wpc_used ), $this->ID , $this );\r\n }", "title": "" }, { "docid": "7447140b1f95d3cf35dbd589ce677046", "score": "0.50067246", "text": "public function getUsedDisplayCount()\n\t{\n\t\t$sql = \"SELECT count(*) FROM display where status='used'\";\n\n\t\t$this->_db->setQuery($sql);\n\t\treturn $this->_db->loadResult();\n\t}", "title": "" }, { "docid": "a31a0c123fd75867a26710c8a3aeba02", "score": "0.5006183", "text": "public function nbSupports()\r\n\t\t{\r\n\t\treturn $this->lesSupports->count();\r\n\t\t}", "title": "" }, { "docid": "dc9fff943740d27c96b26188d2819b17", "score": "0.500069", "text": "public function getCartSummaryCount()\n {\n // return Mage::helper('checkout/cart')->getSummaryCount();\n }", "title": "" }, { "docid": "cb66427320b9c23383288951f767e84d", "score": "0.5000683", "text": "function getNbVps() {\n\t\treturn $this->nbVps;\n\t}", "title": "" }, { "docid": "1a6a700ac1070d14fdfa92e04b5b4bed", "score": "0.5000141", "text": "public function getActiveCautionCount();", "title": "" }, { "docid": "363e443afc4b24189da2d762ade92c72", "score": "0.4994996", "text": "function assist_count() {\n return $this->db->count_all(\"afro_virtual_assistant\");\n }", "title": "" }, { "docid": "101503b1fd4fa208c28a35b6aa6b8ed7", "score": "0.49948642", "text": "public function get_viewsmilies();", "title": "" } ]
f18b865186576b596fb80e81aa505fed
Operation getTelephonyProvidersEdgesCertificateauthoritiesWithHttpInfo Get the list of certificate authorities.
[ { "docid": "a9056a1ffb2909ad014902c9ce786821", "score": "0.7511512", "text": "public function getTelephonyProvidersEdgesCertificateauthoritiesWithHttpInfo()\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\CertificateAuthorityEntityListing';\n $request = $this->getTelephonyProvidersEdgesCertificateauthoritiesRequest();\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\CertificateAuthorityEntityListing',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" } ]
[ { "docid": "146eb3751c2362ac9bcf0cede2f7005b", "score": "0.7530957", "text": "public function getTelephonyProvidersEdgesCertificateauthoritiesAsyncWithHttpInfo()\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\CertificateAuthorityEntityListing';\n $request = $this->getTelephonyProvidersEdgesCertificateauthoritiesRequest();\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "2ea6f8a33d603bb0a985dadfaf336594", "score": "0.737226", "text": "public function getTelephonyProvidersEdgesCertificateauthorities()\n {\n list($response) = $this->getTelephonyProvidersEdgesCertificateauthoritiesWithHttpInfo();\n return $response;\n }", "title": "" }, { "docid": "f581c498576d6a6a2fd6f99caaf7131e", "score": "0.7152735", "text": "public function getTelephonyProvidersEdgesCertificateauthoritiesAsync()\n {\n return $this->getTelephonyProvidersEdgesCertificateauthoritiesAsyncWithHttpInfo()\n ->then(\n function ($response) {\n return $response[0];\n }\n );\n }", "title": "" }, { "docid": "b6dd180b735d4a4178d5d2c49b2a8a8e", "score": "0.6987891", "text": "public function postTelephonyProvidersEdgesCertificateauthorities($body)\n {\n list($response) = $this->postTelephonyProvidersEdgesCertificateauthoritiesWithHttpInfo($body);\n return $response;\n }", "title": "" }, { "docid": "6538acdf6f0ffd240936f74096860092", "score": "0.6510676", "text": "public function postTelephonyProvidersEdgesCertificateauthoritiesAsyncWithHttpInfo($body)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\DomainCertificateAuthority';\n $request = $this->postTelephonyProvidersEdgesCertificateauthoritiesRequest($body);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "5fb47a0a00e09708f08e4e08369d129e", "score": "0.6464088", "text": "public function postTelephonyProvidersEdgesCertificateauthoritiesWithHttpInfo($body)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\DomainCertificateAuthority';\n $request = $this->postTelephonyProvidersEdgesCertificateauthoritiesRequest($body);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\DomainCertificateAuthority',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "08e87ddfef5bbb97886c0ae87467ef23", "score": "0.6407726", "text": "public function postTelephonyProvidersEdgesCertificateauthoritiesAsync($body)\n {\n return $this->postTelephonyProvidersEdgesCertificateauthoritiesAsyncWithHttpInfo($body)\n ->then(\n function ($response) {\n return $response[0];\n }\n );\n }", "title": "" }, { "docid": "9951945dbd512cca9593af58a7894abd", "score": "0.6059403", "text": "protected function getTelephonyProvidersEdgesCertificateauthoritiesRequest()\n {\n\n $resourcePath = '/api/v2/telephony/providers/edges/certificateauthorities';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "c05c1fa279ec2ef7ceff52fac7cf9933", "score": "0.49241102", "text": "protected function postTelephonyProvidersEdgesCertificateauthoritiesRequest($body)\n {\n // verify the required parameter 'body' is set\n if ($body === null || (is_array($body) && count($body) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $body when calling postTelephonyProvidersEdgesCertificateauthorities'\n );\n }\n\n $resourcePath = '/api/v2/telephony/providers/edges/certificateauthorities';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n\n // body params\n $_tempBody = null;\n if (isset($body)) {\n $_tempBody = $body;\n }\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'POST',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "bce20d1c6f30e9c1bc1d5e95137ff472", "score": "0.45543522", "text": "public function getTelephonyProvidersEdgesCertificateauthorityWithHttpInfo($certificateId)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\DomainCertificateAuthority';\n $request = $this->getTelephonyProvidersEdgesCertificateauthorityRequest($certificateId);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\DomainCertificateAuthority',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "8577dfb7bdbbed2081e02344866c6cf6", "score": "0.45239055", "text": "public function getTelephonyProvidersEdgesAsyncWithHttpInfo($pageSize = '25', $pageNumber = '1', $name = null, $siteId = null, $edgeGroupId = null, $sortBy = 'name', $managed = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\EdgeEntityListing';\n $request = $this->getTelephonyProvidersEdgesRequest($pageSize, $pageNumber, $name, $siteId, $edgeGroupId, $sortBy, $managed);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "a5964bf909c8a659c5581bdd59db26ca", "score": "0.45010254", "text": "public function getTelephonyProvidersEdgesWithHttpInfo($pageSize = '25', $pageNumber = '1', $name = null, $siteId = null, $edgeGroupId = null, $sortBy = 'name', $managed = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\EdgeEntityListing';\n $request = $this->getTelephonyProvidersEdgesRequest($pageSize, $pageNumber, $name, $siteId, $edgeGroupId, $sortBy, $managed);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\EdgeEntityListing',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "8ad241ccb092ae2bf4e7be29df6ac84a", "score": "0.4376655", "text": "public function putTelephonyProvidersEdgesCertificateauthorityWithHttpInfo($certificateId, $body)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\DomainCertificateAuthority';\n $request = $this->putTelephonyProvidersEdgesCertificateauthorityRequest($certificateId, $body);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\DomainCertificateAuthority',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "812de735d7edd5eba7049de7178dad14", "score": "0.4368785", "text": "public function getTelephonyProvidersEdgesSitesAsyncWithHttpInfo($pageSize = '25', $pageNumber = '1', $sortBy = 'name', $sortOrder = 'ascending', $name = null, $locationId = null, $managed = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\SiteEntityListing';\n $request = $this->getTelephonyProvidersEdgesSitesRequest($pageSize, $pageNumber, $sortBy, $sortOrder, $name, $locationId, $managed);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "8f476b5764d1ed3465fabdb65c1962d4", "score": "0.4280996", "text": "public function deleteTelephonyProvidersEdgesCertificateauthorityWithHttpInfo($certificateId)\n {\n $returnType = '';\n $request = $this->deleteTelephonyProvidersEdgesCertificateauthorityRequest($certificateId);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n return [null, $statusCode, $response->getHeaders()];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "02f9992130f25edb9a7ce3c745c33b6a", "score": "0.42378965", "text": "protected function getCoverageForFulfillmentCentersWithHttpInfo(): array\n {\n $request = $this->getCoverageForFulfillmentCentersRequest();\n $this->writeDebug($request);\n $this->writeDebug((string) $request->getBody());\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n $this->writeDebug($response);\n $this->writeDebug((string) $response->getBody());\n } catch (RequestException $e) {\n $hasResponse = !empty($e->hasResponse());\n $body = (string) ($hasResponse ? $e->getResponse()->getBody() : '[NULL response]');\n $this->writeDebug($e->getResponse());\n $this->writeDebug($body);\n\n throw new ApiException(\n \"[{$e->getCode()}] {$body}\",\n (int) $e->getCode(),\n $hasResponse ? $e->getResponse()->getHeaders() : null,\n $body\n );\n } catch (ConnectException $e) {\n $this->writeDebug($e->getMessage());\n\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n (int) $e->getCode(),\n null,\n null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n (string) $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n (string) $response->getBody()\n );\n }\n switch ($statusCode) {\n case 200:\n if ('\\Walmart\\Models\\MP\\US\\Settings\\FulfillmentCenterCoverageDetail[]' === '\\SplFileObject') {\n $content = $response->getBody(); //stream goes to serializer\n } else {\n $content = (string) $response->getBody();\n if ('\\Walmart\\Models\\MP\\US\\Settings\\FulfillmentCenterCoverageDetail[]' !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return ObjectSerializer::deserialize($content, '\\Walmart\\Models\\MP\\US\\Settings\\FulfillmentCenterCoverageDetail[]', $response->getHeaders());\n }\n\n $returnType = '\\Walmart\\Models\\MP\\US\\Settings\\FulfillmentCenterCoverageDetail[]';\n if ($returnType === '\\SplFileObject') {\n $content = $response->getBody(); //stream goes to serializer\n } else {\n $content = (string) $response->getBody();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return ObjectSerializer::deserialize($content, $returnType, $response->getHeaders());\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\Walmart\\Models\\MP\\US\\Settings\\FulfillmentCenterCoverageDetail[]',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n\n $this->writeDebug($e);\n throw $e;\n }\n }", "title": "" }, { "docid": "5a80625a75821380984d894126297dd1", "score": "0.42190439", "text": "public function getTelephonyProvidersEdgesCertificateauthorityAsyncWithHttpInfo($certificateId)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\DomainCertificateAuthority';\n $request = $this->getTelephonyProvidersEdgesCertificateauthorityRequest($certificateId);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "0a863401cb8f21dabaacf7b8001c80eb", "score": "0.42151234", "text": "public function getCoverageForFulfillmentCenters(): array\n {\n return $this->getCoverageForFulfillmentCentersWithHttpInfo();\n }", "title": "" }, { "docid": "26b1fcf9f576b96cbfa05391a0172bad", "score": "0.41848567", "text": "public function getAuthorities();", "title": "" }, { "docid": "2c755119bdd217d79318d45d7c78dd60", "score": "0.4158835", "text": "public function getTelephonyProvidersEdgesSitesWithHttpInfo($pageSize = '25', $pageNumber = '1', $sortBy = 'name', $sortOrder = 'ascending', $name = null, $locationId = null, $managed = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\SiteEntityListing';\n $request = $this->getTelephonyProvidersEdgesSitesRequest($pageSize, $pageNumber, $sortBy, $sortOrder, $name, $locationId, $managed);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\SiteEntityListing',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "23429ad1293b016a6c7f5c610b879a6b", "score": "0.4137951", "text": "public function getAuthors(): array\n {\n if (null === $this->_authors) {\n $this->_authors = $this->loadAuthors($this->getNestedProperty('header.permissions.authors', []));\n }\n\n return $this->_authors;\n }", "title": "" }, { "docid": "1faa03d4529c3a0881925f5e6e2f65da", "score": "0.4069033", "text": "public function getGrantedAuthorities ()\n {\n \n // encode our data into the remote call signature.\n $params = array(\n $this->_getToken(), \n );\n $params = call_user_func_array(array('self', '_soapEncode'), $params);\n \n try\n {\n $result = $this->soapClient->getGrantedAuthorities($params);\n // always return an array\n if (is_null($result->out->string)) {\n return array();\n }\n elseif (is_string($result->out->string)) {\n return array($result->out->string);\n }\n elseif (is_array($result->out->string)) {\n return $result->out->string;\n }\n }\n catch (SoapFault $e)\n {\n $args = func_get_args();\n return $this->_manageException(__FUNCTION__, $args, $e);\n }\n }", "title": "" }, { "docid": "a83a48573b902e8e2b02c1762d80dc13", "score": "0.40312394", "text": "public function getTelephonyProvidersEdgesLinesAsyncWithHttpInfo($pageSize = '25', $pageNumber = '1', $name = null, $sortBy = 'name', $expand = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\LineEntityListing';\n $request = $this->getTelephonyProvidersEdgesLinesRequest($pageSize, $pageNumber, $name, $sortBy, $expand);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "6e253204f14ff296a71eeeb46cb1f06e", "score": "0.402062", "text": "public function postTelephonyProvidersEdgesWithHttpInfo($body)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\Edge';\n $request = $this->postTelephonyProvidersEdgesRequest($body);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\Edge',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "67355940a6b094d00d97c8c6b564d0e3", "score": "0.40175492", "text": "public function getTelephonyProvidersEdgesExtensionsAsyncWithHttpInfo($pageSize = '25', $pageNumber = '1', $sortBy = 'number', $sortOrder = 'ascending', $number = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\ExtensionEntityListing';\n $request = $this->getTelephonyProvidersEdgesExtensionsRequest($pageSize, $pageNumber, $sortBy, $sortOrder, $number);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "2e8d69c461df8c7f6092662d7122e499", "score": "0.3985505", "text": "public function postTelephonyProvidersEdgesAsyncWithHttpInfo($body)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\Edge';\n $request = $this->postTelephonyProvidersEdgesRequest($body);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "26e505cd1b0ce4d3269ce8368d1cf56b", "score": "0.397105", "text": "public function putTelephonyProvidersEdgesCertificateauthorityAsyncWithHttpInfo($certificateId, $body)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\DomainCertificateAuthority';\n $request = $this->putTelephonyProvidersEdgesCertificateauthorityRequest($certificateId, $body);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "c86e5c69f272de06bec01a5c4ddc43cf", "score": "0.39509436", "text": "public function actionGetcoauthor()\n {\n if (!Yii::app()->request->isAjaxRequest)\n throw new CHttpException(404);\n\n $interiorId = Yii::app()->request->getParam('interiorId');\n $interior = Interior::model()->findByPk($interiorId);\n if (is_null($interior))\n throw new CHttpException(404);\n\n $this->layout = false;\n\n $result = $this->renderPartial('_getCoAuthorItem', array(\n 'interior' => $interior,\n 'coauthor' => Coauthor::createRow($interior->id, Config::INTERIOR),\n ), true);\n echo CJSON::encode(array('success' => true, 'data' => $result));\n return;\n }", "title": "" }, { "docid": "7f5691ff15417e1f4ca1804b7dc35d69", "score": "0.39460355", "text": "public function getTelephonyProvidersEdgesEdgegroupsAsyncWithHttpInfo($pageSize = '25', $pageNumber = '1', $name = null, $sortBy = 'name', $managed = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\EdgeGroupEntityListing';\n $request = $this->getTelephonyProvidersEdgesEdgegroupsRequest($pageSize, $pageNumber, $name, $sortBy, $managed);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "7d9dab42547fd17612f30da871c4ae7d", "score": "0.39310086", "text": "public function getTelephonyProvidersEdgesEdgegroupsWithHttpInfo($pageSize = '25', $pageNumber = '1', $name = null, $sortBy = 'name', $managed = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\EdgeGroupEntityListing';\n $request = $this->getTelephonyProvidersEdgesEdgegroupsRequest($pageSize, $pageNumber, $name, $sortBy, $managed);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\EdgeGroupEntityListing',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "c4159070aab4e5b0a67ef4f79b5fe2fb", "score": "0.38877845", "text": "public function obtainAuthors()\n {\n return $this->performRequest('GET', 'authors');\n }", "title": "" }, { "docid": "2672628e46b9c992317687835cb8a1aa", "score": "0.3871829", "text": "public function obtainAuthors()\n {\n return $this->perfomRequest(\"GET\", \"/authors\");\n }", "title": "" }, { "docid": "668710fcd35762b17ed6716995e87429", "score": "0.3864793", "text": "protected function getTelephonyProvidersEdgesCertificateauthorityRequest($certificateId)\n {\n // verify the required parameter 'certificateId' is set\n if ($certificateId === null || (is_array($certificateId) && count($certificateId) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $certificateId when calling getTelephonyProvidersEdgesCertificateauthority'\n );\n }\n\n $resourcePath = '/api/v2/telephony/providers/edges/certificateauthorities/{certificateId}';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n // path params\n if ($certificateId !== null) {\n $resourcePath = str_replace(\n '{' . 'certificateId' . '}',\n ObjectSerializer::toPathValue($certificateId),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "d68c4603a8ed96d6fc2ccf0ebbae7449", "score": "0.38634172", "text": "function magazinevibe_edge_get_authors_VC(){\n return array_flip(magazinevibe_edge_get_authors());\n }", "title": "" }, { "docid": "883025fe536b37c21abdbd195dcd54cc", "score": "0.38319692", "text": "public function getExternalcontactsOrganizationsAsyncWithHttpInfo($pageSize = '20', $pageNumber = '1', $q = null, $trustorId = null, $sortOrder = null, $expand = null, $includeTrustors = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\ExternalOrganizationListing';\n $request = $this->getExternalcontactsOrganizationsRequest($pageSize, $pageNumber, $q, $trustorId, $sortOrder, $expand, $includeTrustors);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "8e0de2e733b27922f0dd4fbadceaf79d", "score": "0.3827238", "text": "public function getTelephonyProvidersEdgesDidpoolsAsyncWithHttpInfo($pageSize = '25', $pageNumber = '1', $sortBy = 'number')\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\DIDPoolEntityListing';\n $request = $this->getTelephonyProvidersEdgesDidpoolsRequest($pageSize, $pageNumber, $sortBy);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "d8612ab333441ebbb2ee36a43d651417", "score": "0.38188198", "text": "public function edgeResolver(\n LengthAwarePaginator $root,\n array $args,\n $context = null,\n ResolveInfo $info = null\n ) {\n $first = $root->firstItem();\n\n return $root->values()->map(function ($item, $x) use ($first) {\n $cursor = $first + $x;\n $encodedCursor = $this->encodeGlobalId('arrayconnection', $cursor);\n\n return ['cursor' => $encodedCursor, 'node' => $item];\n });\n }", "title": "" }, { "docid": "cab7f03f0271a2f5d8588b6816a0e9dd", "score": "0.3770303", "text": "public function getIncidentEdges()\n\t\t{\n\t\t\treturn $this->graph->getIncidentEdges($this->number);\n\t\t}", "title": "" }, { "docid": "20a8fac31d0e438ceffd2061d6054baf", "score": "0.37596554", "text": "function getIncidentEdges();", "title": "" }, { "docid": "d62ee8a63f22205600bff4a41c709965", "score": "0.37542024", "text": "public function getAuthors(): array {\n return $this->data['authors'];\n }", "title": "" }, { "docid": "00512e9554aff953d56c150bd3d609fe", "score": "0.37357953", "text": "public function getTelephonyProvidersEdgesCertificateauthority($certificateId)\n {\n list($response) = $this->getTelephonyProvidersEdgesCertificateauthorityWithHttpInfo($certificateId);\n return $response;\n }", "title": "" }, { "docid": "981c2af55ff55a1e821736081917299c", "score": "0.37306517", "text": "public function getTelephonyProvidersEdgesPhonesAsyncWithHttpInfo($pageNumber = '1', $pageSize = '25', $sortBy = 'name', $sortOrder = 'ascending', $siteId = null, $webRtcUserId = null, $phoneBaseSettingsId = null, $linesLoggedInUserId = null, $linesDefaultForUserId = null, $phoneHardwareId = null, $linesId = null, $linesName = null, $name = null, $expand = null, $fields = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\PhoneEntityListing';\n $request = $this->getTelephonyProvidersEdgesPhonesRequest($pageNumber, $pageSize, $sortBy, $sortOrder, $siteId, $webRtcUserId, $phoneBaseSettingsId, $linesLoggedInUserId, $linesDefaultForUserId, $phoneHardwareId, $linesId, $linesName, $name, $expand, $fields);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "eae8ab8e0cee189add46ffa2e28295b4", "score": "0.37154573", "text": "public function deleteTelephonyProvidersEdgesCertificateauthorityAsyncWithHttpInfo($certificateId)\n {\n $returnType = '';\n $request = $this->deleteTelephonyProvidersEdgesCertificateauthorityRequest($certificateId);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n return [null, $response->getStatusCode(), $response->getHeaders()];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "0085395d7d8631e1c3a8fa0d2d83a565", "score": "0.37117276", "text": "public function putTelephonyProvidersEdgesCertificateauthority($certificateId, $body)\n {\n list($response) = $this->putTelephonyProvidersEdgesCertificateauthorityWithHttpInfo($certificateId, $body);\n return $response;\n }", "title": "" }, { "docid": "c93a20995c32544e997eeca1eab2c05d", "score": "0.37022382", "text": "public function getEauth()\n {\n return $this->hasMany(ClientEauth::className(), ['user_id' => 'id']);\n }", "title": "" }, { "docid": "8a6299303e98cd81bf5b68d8769eaf9d", "score": "0.3701638", "text": "public function getTelephonyProvidersEdgesCertificateauthorityAsync($certificateId)\n {\n return $this->getTelephonyProvidersEdgesCertificateauthorityAsyncWithHttpInfo($certificateId)\n ->then(\n function ($response) {\n return $response[0];\n }\n );\n }", "title": "" }, { "docid": "e24f4d1b513e42d5c829784f34941833", "score": "0.37016073", "text": "public function cieinfo() {\n global $CFG;\n\n $url = 'GetCieInfo';\n\n $data = '<soap:Envelope xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" ';\n $data .= 'xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" ';\n $data .= 'xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\">';\n $data .= '<soap:Body>';\n $data .= \"<cApiCieInfo>\";\n $data .= \"<ApiID>\".get_config('via', 'via_apiid').\"</ApiID>\";\n $data .= \"<CieID>\".get_config('via', 'via_cleid').\"</CieID>\";\n $data .= \"</cApiCieInfo>\";\n $data .= \"</soap:Body>\";\n $data .= \"</soap:Envelope>\";\n $response = $this->send_saop_enveloppe($data, $url);\n\n if (!$resultdata = $response['dataxml'][\"soap:Envelope\"][\"soap:Body\"][\"cApiCieInfo\"]) {\n throw new Exception(\"Problem getting cie info for via version restrictions\");\n }\n\n if ($resultdata['Result']['ResultState'] == \"ERROR\") {\n throw new Exception($resultdata['Result']['ResultDetail']);\n }\n\n return $resultdata;\n }", "title": "" }, { "docid": "b15e2c8b3a3e533c4014d6b5a3311fbf", "score": "0.36969054", "text": "public function authorizations() : array {\n\t\tif(NULL === $this->authorizations) {\n\t\t\treturn array();\n\t\t}\n\t\treturn $this->authorizations;\n\t}", "title": "" }, { "docid": "960b76b3b2805d1c3466fd690a0d0ecd", "score": "0.36967057", "text": "public function getConfigurationSchemasEdgesVnextAsyncWithHttpInfo($pageSize = '25', $pageNumber = '1')\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\SchemaCategoryEntityListing';\n $request = $this->getConfigurationSchemasEdgesVnextRequest($pageSize, $pageNumber);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "57b1043029df06eec99cd6afe4769084", "score": "0.36900073", "text": "public function getTelephonyProvidersEdgesPhonesWithHttpInfo($pageNumber = '1', $pageSize = '25', $sortBy = 'name', $sortOrder = 'ascending', $siteId = null, $webRtcUserId = null, $phoneBaseSettingsId = null, $linesLoggedInUserId = null, $linesDefaultForUserId = null, $phoneHardwareId = null, $linesId = null, $linesName = null, $name = null, $expand = null, $fields = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\PhoneEntityListing';\n $request = $this->getTelephonyProvidersEdgesPhonesRequest($pageNumber, $pageSize, $sortBy, $sortOrder, $siteId, $webRtcUserId, $phoneBaseSettingsId, $linesLoggedInUserId, $linesDefaultForUserId, $phoneHardwareId, $linesId, $linesName, $name, $expand, $fields);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\PhoneEntityListing',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "14ae44ea507b3cf5257d065c9834de8e", "score": "0.36867195", "text": "public function getTelephonyProvidersEdgesEdgeversionreportAsyncWithHttpInfo()\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\EdgeVersionReport';\n $request = $this->getTelephonyProvidersEdgesEdgeversionreportRequest();\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "51b3da73adfe96803cd3d0d989a1ee41", "score": "0.36757872", "text": "public function getCCEmailAddresses()\n\t{\n\t\t$response = $this->sendRequest(\n\t\t\t'/cc/invoices',\n\t\t\t[ ],\n\t\t\ttrue,\n\t\t\t'get',\n\t\t\tnull,\n\t\t\ttrue\n\t\t);\n\n\t\t$return = new IterableResponse();\n\n\t\tforeach( $response as $email )\n\t\t{\n\t\t\t$return->add(\n\t\t\t\tnew Entity\\EmailAddress(\n\t\t\t\t\t$email->{'email-address'},\n\t\t\t\t\t$email->id\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\treturn $return;\n\t}", "title": "" }, { "docid": "bfbbf4475e060430ab136813fb073685", "score": "0.36679944", "text": "private function setClustersInfo() {\r\n\t\t$clustersInfo = array ();\r\n\t\t\r\n\t\tif (! empty ( $this->clusteredEntities ))\r\n\t\t\tforeach ( $this->clusteredEntities as $key => $entities )\r\n\t\t\t\t$clustersInfo [$key] = sizeof ( $entities );\r\n\t\t\r\n\t\t$this->clutersInfo = $clustersInfo;\r\n\t}", "title": "" }, { "docid": "95b3ed19cb112d5c529a0f92aac58f89", "score": "0.36569977", "text": "public function getTelephonyProvidersEdgesAvailablelanguagesAsyncWithHttpInfo()\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\AvailableLanguageList';\n $request = $this->getTelephonyProvidersEdgesAvailablelanguagesRequest();\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "74e480435c3363b31523efe4a1ea095e", "score": "0.36551082", "text": "public function getEnclaves($authorization = null, $created = 'true', $limit = '30', $offset = '0', $status = null)\n {\n list($response) = $this->getEnclavesWithHttpInfo($authorization, $created, $limit, $offset, $status);\n return $response;\n }", "title": "" }, { "docid": "5e6c4a8e811c150fae74ee3d2768085a", "score": "0.3651556", "text": "public function getIdentityVerificationAttributes(array $identities): array\n {\n try {\n return $this->client->getIdentityVerificationAttributes(['Identities' => $identities])->toArray();\n } catch (SesException $exception) {\n $this->parseException($exception);\n }\n }", "title": "" }, { "docid": "5d420437db2b19f0e967857398befdb7", "score": "0.36483797", "text": "public function getTelephonyProvidersEdgesExtensionsWithHttpInfo($pageSize = '25', $pageNumber = '1', $sortBy = 'number', $sortOrder = 'ascending', $number = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\ExtensionEntityListing';\n $request = $this->getTelephonyProvidersEdgesExtensionsRequest($pageSize, $pageNumber, $sortBy, $sortOrder, $number);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ExtensionEntityListing',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "bbc8885cb8cd36d19cf9ff3b43cdc028", "score": "0.36467168", "text": "public function getTelephonyProvidersEdgesLinesWithHttpInfo($pageSize = '25', $pageNumber = '1', $name = null, $sortBy = 'name', $expand = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\LineEntityListing';\n $request = $this->getTelephonyProvidersEdgesLinesRequest($pageSize, $pageNumber, $name, $sortBy, $expand);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\LineEntityListing',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "77bdcb96c47753c6d9d80643e71c5e4e", "score": "0.36437404", "text": "public function setAttrAuthoritiesCertValues(array $attrAuthoritiesCertValues)\n {\n $this->attrAuthoritiesCertValues = $attrAuthoritiesCertValues;\n return $this;\n }", "title": "" }, { "docid": "9a116210188500e1fb48337364d4fe2c", "score": "0.3611995", "text": "public function getTelephonyProvidersEdgesOutboundroutesAsyncWithHttpInfo($pageSize = '25', $pageNumber = '1', $name = null, $siteId = null, $externalTrunkBasesIds = null, $sortBy = 'name')\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\OutboundRouteEntityListing';\n $request = $this->getTelephonyProvidersEdgesOutboundroutesRequest($pageSize, $pageNumber, $name, $siteId, $externalTrunkBasesIds, $sortBy);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "73a6606f8b58553845d08d1ed478d894", "score": "0.36117706", "text": "public function getExternalcontactsOrganizationsWithHttpInfo($pageSize = '20', $pageNumber = '1', $q = null, $trustorId = null, $sortOrder = null, $expand = null, $includeTrustors = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\ExternalOrganizationListing';\n $request = $this->getExternalcontactsOrganizationsRequest($pageSize, $pageNumber, $q, $trustorId, $sortOrder, $expand, $includeTrustors);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ExternalOrganizationListing',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "9555dd6bc84551d6e413f90e91027c7d", "score": "0.36082152", "text": "protected function getTelephonyProvidersEdgesSitesRequest($pageSize = '25', $pageNumber = '1', $sortBy = 'name', $sortOrder = 'ascending', $name = null, $locationId = null, $managed = null)\n {\n\n $resourcePath = '/api/v2/telephony/providers/edges/sites';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n // query params\n if ($pageSize !== null) {\n $queryParams['pageSize'] = ObjectSerializer::toQueryValue($pageSize);\n }\n // query params\n if ($pageNumber !== null) {\n $queryParams['pageNumber'] = ObjectSerializer::toQueryValue($pageNumber);\n }\n // query params\n if ($sortBy !== null) {\n $queryParams['sortBy'] = ObjectSerializer::toQueryValue($sortBy);\n }\n // query params\n if ($sortOrder !== null) {\n $queryParams['sortOrder'] = ObjectSerializer::toQueryValue($sortOrder);\n }\n // query params\n if ($name !== null) {\n $queryParams['name'] = ObjectSerializer::toQueryValue($name);\n }\n // query params\n if ($locationId !== null) {\n $queryParams['location.id'] = ObjectSerializer::toQueryValue($locationId);\n }\n // query params\n if ($managed !== null) {\n $queryParams['managed'] = ObjectSerializer::toQueryValue($managed);\n }\n\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "4b9eb54933329b7a942f4f6962221f10", "score": "0.35846144", "text": "public function acinfo(): AttributeCertificateInfo\n {\n return $this->_acinfo;\n }", "title": "" }, { "docid": "2faeda25e33fcde108017918e3a0fae2", "score": "0.35829997", "text": "public function getAuthorsColumns($columns, $where, array $markers = []);", "title": "" }, { "docid": "51150ecb6bf16f9b8d3488214e48ce64", "score": "0.35746077", "text": "public function getAuthors()\n {\n return (array) $this->_authors;\n }", "title": "" }, { "docid": "626fe4ed9b52c5bb6d9e9370bb66d8cf", "score": "0.35714817", "text": "public function postTelephonyProvidersEdgesSitesAsyncWithHttpInfo($body)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\Site';\n $request = $this->postTelephonyProvidersEdgesSitesRequest($body);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "b4c07ee6682a0009d7caca0f8c8b11a4", "score": "0.3568015", "text": "private function getCorsesArray()\n {\n $corsesArray = [];\n if (count($this->getCorses()) == 1) {\n $corsesArray = [\n Resources::XTAG_CORS_RULE => $this->getCorses()[0]->toArray(),\n ];\n } elseif ($this->getCorses() != []) {\n foreach ($this->getCorses() as $cors) {\n $corsesArray[] = [Resources::XTAG_CORS_RULE => $cors->toArray()];\n }\n }\n\n return $corsesArray;\n }", "title": "" }, { "docid": "c67a4a9b2a0fb57ea097652632349958", "score": "0.35637414", "text": "protected function putTelephonyProvidersEdgesCertificateauthorityRequest($certificateId, $body)\n {\n // verify the required parameter 'certificateId' is set\n if ($certificateId === null || (is_array($certificateId) && count($certificateId) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $certificateId when calling putTelephonyProvidersEdgesCertificateauthority'\n );\n }\n // verify the required parameter 'body' is set\n if ($body === null || (is_array($body) && count($body) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $body when calling putTelephonyProvidersEdgesCertificateauthority'\n );\n }\n\n $resourcePath = '/api/v2/telephony/providers/edges/certificateauthorities/{certificateId}';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n // path params\n if ($certificateId !== null) {\n $resourcePath = str_replace(\n '{' . 'certificateId' . '}',\n ObjectSerializer::toPathValue($certificateId),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n if (isset($body)) {\n $_tempBody = $body;\n }\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'PUT',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "6b1014c44306fcda7938e943c2fe44df", "score": "0.35617933", "text": "protected function getCoverageForFulfillmentCentersAsyncWithHttpInfo(): PromiseInterface\n {\n $returnType = '\\Walmart\\Models\\MP\\US\\Settings\\FulfillmentCenterCoverageDetail[]';\n $request = $this->getCoverageForFulfillmentCentersRequest();\n $this->writeDebug($request);\n $this->writeDebug((string) $request->getBody());\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $this->writeDebug($response);\n $this->writeDebug((string) $response->getBody());\n if ($returnType === '\\SplFileObject') {\n $content = $response->getBody(); //stream goes to serializer\n } else {\n $content = (string) $response->getBody();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return ObjectSerializer::deserialize($content, $returnType, $response->getHeaders());\n },\n function ($exception) {\n $response = $exception->getResponse();\n $hasResponse = !empty($response);\n $body = (string) ($hasResponse ? $response->getBody() : '[NULL response]');\n $this->writeDebug($response);\n $statusCode = $hasResponse ? $response->getStatusCode() : $exception->getCode();\n\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $body,\n );\n }\n );\n }", "title": "" }, { "docid": "5ddd8b22e1aaa3f4140fed2dd257c3b2", "score": "0.35516417", "text": "public function getHtAvecSaisieCongesCodesClients() {\n return $this->htAvecSaisieCongesCodesClients;\n }", "title": "" }, { "docid": "3dcf109fb64d68efaa132a3f939c117a", "score": "0.35515115", "text": "protected function getTelephonyProvidersEdgesRequest($pageSize = '25', $pageNumber = '1', $name = null, $siteId = null, $edgeGroupId = null, $sortBy = 'name', $managed = null)\n {\n\n $resourcePath = '/api/v2/telephony/providers/edges';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n // query params\n if ($pageSize !== null) {\n $queryParams['pageSize'] = ObjectSerializer::toQueryValue($pageSize);\n }\n // query params\n if ($pageNumber !== null) {\n $queryParams['pageNumber'] = ObjectSerializer::toQueryValue($pageNumber);\n }\n // query params\n if ($name !== null) {\n $queryParams['name'] = ObjectSerializer::toQueryValue($name);\n }\n // query params\n if ($siteId !== null) {\n $queryParams['site.id'] = ObjectSerializer::toQueryValue($siteId);\n }\n // query params\n if ($edgeGroupId !== null) {\n $queryParams['edgeGroup.id'] = ObjectSerializer::toQueryValue($edgeGroupId);\n }\n // query params\n if ($sortBy !== null) {\n $queryParams['sortBy'] = ObjectSerializer::toQueryValue($sortBy);\n }\n // query params\n if ($managed !== null) {\n $queryParams['managed'] = ObjectSerializer::toQueryValue($managed);\n }\n\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "ba943619d321858bc3e099ef480ff3d4", "score": "0.354738", "text": "public function getEnclavesAsyncWithHttpInfo($authorization = null, $created = 'true', $limit = '30', $offset = '0', $status = null)\n {\n $returnType = '\\SplFileObject';\n $request = $this->getEnclavesRequest($authorization, $created, $limit, $offset, $status);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = (string) $responseBody;\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "e124f48af935a4f02599ad1fec894b0f", "score": "0.3544225", "text": "protected function fetchHost(): array\n {\n // configure ssl options\n $sslOptions = [\n 'capture_peer_cert' => true,\n 'capture_peer_cert_chain' => false,\n 'SNI_enabled' => true,\n 'verify_peer' => true,\n 'verify_peer_name' => true,\n ];\n\n // create a new context stream\n $streamContext = stream_context_create(['ssl' => $sslOptions]);\n\n try {\n // connect to the client\n $client = stream_socket_client(\n \"ssl://{$this->host}:{$this->port}\",\n $errno,\n $errstr,\n $this->timeout,\n STREAM_CLIENT_CONNECT,\n $streamContext\n );\n } catch (Throwable $thrown) {\n $this->requestFailed($this->host, $thrown);\n }\n\n // could not connect to the client\n if (! $client) {\n throw CouldNotDownloadCertificate::unknownError($this->host, \"Could not connect to {$this->host}.\");\n }\n\n // get the paramters from the context stream\n $response = stream_context_get_params($client);\n\n // close conection\n fclose($client);\n\n // return the response\n return $response;\n }", "title": "" }, { "docid": "a0dff51d1726ac303b6b060f77d9cafb", "score": "0.35354555", "text": "public function getTelephonyProvidersEdgesTimezonesAsyncWithHttpInfo($pageSize = '1000', $pageNumber = '1')\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\TimeZoneEntityListing';\n $request = $this->getTelephonyProvidersEdgesTimezonesRequest($pageSize, $pageNumber);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "e4842b77d69225f34782b4e1809f76c3", "score": "0.35322475", "text": "function getAssociatedCompanies()\r\n\t{\r\n\t\t$table = $this->getTable(\"EventAssociatedCompanies\");\r\n\t\t\r\n\t\t$searchDetails = array();\r\n\t\t$searchDetails[\"eventId\"] = $this->eventId;\r\n\r\n\t\t$companies = $table->getAssociatedCompaniesDetails($searchDetails);\r\n\t\treturn $companies;\r\n\t}", "title": "" }, { "docid": "8107e19893ae8a4d67859e59f3b323d4", "score": "0.35195774", "text": "public function getTelephonyProvidersEdgesExtensionpoolsAsyncWithHttpInfo($pageSize = '25', $pageNumber = '1', $sortBy = 'startNumber', $number = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\ExtensionPoolEntityListing';\n $request = $this->getTelephonyProvidersEdgesExtensionpoolsRequest($pageSize, $pageNumber, $sortBy, $number);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "ba227c297ef987e0c95603f0308f1706", "score": "0.3518396", "text": "public function getTelephonyProvidersEdgesLinebasesettingsAsyncWithHttpInfo($pageNumber = '1', $pageSize = '25', $sortBy = 'name', $sortOrder = 'ascending')\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\LineBaseEntityListing';\n $request = $this->getTelephonyProvidersEdgesLinebasesettingsRequest($pageNumber, $pageSize, $sortBy, $sortOrder);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "734c554d38ddc4ba31229bb09d4dcbb9", "score": "0.35093558", "text": "public function getTelephonyProvidersEdgesDidsAsyncWithHttpInfo($pageSize = '25', $pageNumber = '1', $sortBy = 'number', $sortOrder = 'ascending', $phoneNumber = null, $ownerId = null, $didPoolId = null)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\DIDEntityListing';\n $request = $this->getTelephonyProvidersEdgesDidsRequest($pageSize, $pageNumber, $sortBy, $sortOrder, $phoneNumber, $ownerId, $didPoolId);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "79190065e3d0a99b59ee61e7732eac72", "score": "0.35089526", "text": "public function getAuthors($where, array $markers = []);", "title": "" }, { "docid": "519d3ab3f4dd57e57533996760430cda", "score": "0.34995568", "text": "public function getCorporationsCorporationIdCustomsOfficesAsyncWithHttpInfo($corporationId, $datasource = 'tranquility', $page = '1', $token = null, $userAgent = null, $xUserAgent = null)\n {\n $returnType = '\\nullx27\\ESI\\nullx27\\ESI\\Models\\GetCorporationsCorporationIdCustomsOffices200Ok[]';\n $request = $this->getCorporationsCorporationIdCustomsOfficesRequest($corporationId, $datasource, $page, $token, $userAgent, $xUserAgent);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "4e099006746bf5aac43847db5126746c", "score": "0.34986562", "text": "public function getTelephonyProvidersEdgesEdgeversionreportWithHttpInfo()\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\EdgeVersionReport';\n $request = $this->getTelephonyProvidersEdgesEdgeversionreportRequest();\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\EdgeVersionReport',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "07210971074bbd5eb91da8ac6cb4ee37", "score": "0.3489105", "text": "public function getContractors()\n {\n $contractors = [];\n $contractorList = $this->repository->findContractors();\n\n /** @var ResolveResponseRating $contractor */\n foreach ($contractorList as $contractor) {\n $contractors[] = $contractor->getProposedBy();\n }\n\n return $contractors;\n }", "title": "" }, { "docid": "9e30daafda3a16d67feb0614c4b5d765", "score": "0.34853625", "text": "public function getAuthors() {\r\n\t\tif (array_key_exists ( 'authors', $this->data )) {\r\n\t\t\treturn $this->data ['authors'];\r\n\t\t}\r\n\t\t\r\n\t\t$authors = $this->getExtension ( 'Atom' )->getAuthors ();\r\n\t\t\r\n\t\t$this->data ['authors'] = $authors;\r\n\t\t\r\n\t\treturn $this->data ['authors'];\r\n\t}", "title": "" }, { "docid": "a26117cc30147da70e9d7b02bd4453d1", "score": "0.34838223", "text": "public function authors($entity, array $options = []) {\n\t\t$options += ['serialized' => true];\n\n\t\treturn $options['serialized'] ? $entity->author : [$entity->author];\n\t}", "title": "" }, { "docid": "5952b504f3dd76e1455805da90115b30", "score": "0.34741354", "text": "public function getCertificates()\n {\n $documents = [];\n foreach ($this->tma['transportManager']['documents'] as $document) {\n if ($document['category']['id'] === \\Common\\Category::CATEGORY_TRANSPORT_MANAGER &&\n $document['subCategory']['id'] === \\Common\\Category::DOC_SUB_CATEGORY_TRANSPORT_MANAGER_CPC_OR_EXEMPTION\n ) {\n $documents[] = $document;\n }\n }\n\n return $documents;\n }", "title": "" }, { "docid": "b71bc0ed3b9a90f7d59c7d2aff70a443", "score": "0.3471852", "text": "public function getEnclavesWithHttpInfo($authorization = null, $created = 'true', $limit = '30', $offset = '0', $status = null)\n {\n $request = $this->getEnclavesRequest($authorization, $created, $limit, $offset, $status);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? (string) $e->getResponse()->getBody() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n switch($statusCode) {\n case 200:\n if ('\\SplFileObject' === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = (string) $responseBody;\n }\n\n return [\n ObjectSerializer::deserialize($content, '\\SplFileObject', []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n }\n\n $returnType = '\\SplFileObject';\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = (string) $responseBody;\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\SplFileObject',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "e84b1518d5b41ddde4251b67f0b90d83", "score": "0.346748", "text": "public function getExhibitors(){\n\n $this->consoleMessage(\"\\r\\n \\r\\n Getting Archive Links... \\r\\n\");\n\n $this->getArchiveLinks($this->target);\n\n $this->consoleMessage(\"\\r\\n \\r\\n Getting Company Information... \\r\\n\");\n\n foreach( $this->exhibitorPageLinks as $pageLink ){\n $this->exhibitors[] = $this->getCompany($pageLink);\n }\n\n }", "title": "" }, { "docid": "6d068b4a422e3de7b71f571abf6fe539", "score": "0.3460375", "text": "public function getTelephonyProvidersEdgesDidpoolsWithHttpInfo($pageSize = '25', $pageNumber = '1', $sortBy = 'number')\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\DIDPoolEntityListing';\n $request = $this->getTelephonyProvidersEdgesDidpoolsRequest($pageSize, $pageNumber, $sortBy);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\DIDPoolEntityListing',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "ad8cfcc7557623031f6446a7f90aa9b2", "score": "0.34417826", "text": "public function putTelephonyProvidersEdgesCertificateauthorityAsync($certificateId, $body)\n {\n return $this->putTelephonyProvidersEdgesCertificateauthorityAsyncWithHttpInfo($certificateId, $body)\n ->then(\n function ($response) {\n return $response[0];\n }\n );\n }", "title": "" }, { "docid": "7ab09db83254d1fd670869a46fda1700", "score": "0.34388873", "text": "public function getAuthorsAttribute()\n {\n return (array)unserialize($this->attributes['authors']);\n }", "title": "" }, { "docid": "7848daf0bf55595cba5791b5b30ea739", "score": "0.34357962", "text": "public function getEnclavesAsync($authorization = null, $created = 'true', $limit = '30', $offset = '0', $status = null)\n {\n return $this->getEnclavesAsyncWithHttpInfo($authorization, $created, $limit, $offset, $status)\n ->then(\n function ($response) {\n return $response[0];\n }\n );\n }", "title": "" }, { "docid": "59d418a18505838f1b6d7f25fc010ad8", "score": "0.34326732", "text": "public function getAuthors(){\n\t\t\n\t\t$getAllAuthorsReturn = DB::table('news_authors')->get();\n\n\t\treturn $getAllAuthorsReturn;\t\n\t}", "title": "" }, { "docid": "33fa30cb7e6a90e4278424d606b6c085", "score": "0.34309146", "text": "public function getConfigurationSchemasEdgesVnextWithHttpInfo($pageSize = '25', $pageNumber = '1')\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\SchemaCategoryEntityListing';\n $request = $this->getConfigurationSchemasEdgesVnextRequest($pageSize, $pageNumber);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\SchemaCategoryEntityListing',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "eb4f8decbcc4535e073e5b6e8bc590dd", "score": "0.34187856", "text": "public function getParsedCcAddresses(): array\n {\n $addresses = explode(',', $this->message->getHeaderValue('cc'));\n return array_map('trim', $addresses);\n }", "title": "" }, { "docid": "02729ae5b112c00e870eaeb47555a190", "score": "0.34157515", "text": "public function getCouponCollectionsWithHttpInfo($limit = '50', $offset = '0', $sort = 'desc')\n {\n $returnType = '\\Brevo\\Client\\Model\\GetCouponCollection';\n $request = $this->getCouponCollectionsRequest($limit, $offset, $sort);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\Brevo\\Client\\Model\\GetCouponCollection',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\Brevo\\Client\\Model\\ErrorModel',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\Brevo\\Client\\Model\\ErrorModel',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\Brevo\\Client\\Model\\ErrorModel',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "7b5612480da3415e3d068d99b30aa41a", "score": "0.34124857", "text": "public function getAuthors()\n {\n return $this->author;\n }", "title": "" }, { "docid": "7b5612480da3415e3d068d99b30aa41a", "score": "0.34124857", "text": "public function getAuthors()\n {\n return $this->author;\n }", "title": "" }, { "docid": "0f80a0c5af4dd2d559d11164cf4df796", "score": "0.34057686", "text": "public function getTelephonyProvidersEdgesSiteOutboundroutesAsyncWithHttpInfo($siteId, $pageSize = '25', $pageNumber = '1', $name = null, $externalTrunkBasesIds = null, $sortBy = 'name')\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\OutboundRouteBaseEntityListing';\n $request = $this->getTelephonyProvidersEdgesSiteOutboundroutesRequest($siteId, $pageSize, $pageNumber, $name, $externalTrunkBasesIds, $sortBy);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "8459aabe3f1fa36a51f3daa7e4fc67de", "score": "0.34037492", "text": "protected function deleteTelephonyProvidersEdgesCertificateauthorityRequest($certificateId)\n {\n // verify the required parameter 'certificateId' is set\n if ($certificateId === null || (is_array($certificateId) && count($certificateId) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $certificateId when calling deleteTelephonyProvidersEdgesCertificateauthority'\n );\n }\n\n $resourcePath = '/api/v2/telephony/providers/edges/certificateauthorities/{certificateId}';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n // path params\n if ($certificateId !== null) {\n $resourcePath = str_replace(\n '{' . 'certificateId' . '}',\n ObjectSerializer::toPathValue($certificateId),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires OAuth (access token)\n if ($this->config->getAccessToken() !== null) {\n $headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'DELETE',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "title": "" }, { "docid": "caad8396ec15e7dd205c4faf3433f6cd", "score": "0.33919823", "text": "public function postTelephonyProvidersEdgesSitesWithHttpInfo($body)\n {\n $returnType = '\\PureCloudPlatform\\Client\\V2\\Model\\Site';\n $request = $this->postTelephonyProvidersEdgesSitesRequest($body);\n\n try {\n $options = $this->createHttpClientOption();\n try {\n $response = $this->client->send($request, $options);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null,\n $e->getResponse() ? $e->getResponse()->getBody()->getContents() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $request->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\Site',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 400:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 401:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 403:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 404:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 413:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 415:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 429:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 500:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 503:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n case 504:\n $data = ObjectSerializer::deserialize(\n $e->getResponseBody(),\n '\\PureCloudPlatform\\Client\\V2\\Model\\ErrorBody',\n $e->getResponseHeaders()\n );\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" } ]
2ada0b7178d665fda90f9e8ace98151f
Function GetLinks() Description:Returns array of all the hyperlinks in the html provided Please note that this does not include hyperlinks in comments Each element contains following keys 'href' the url ( this can be relative url or full url and needs validation) 'title' titles for links( the title attribute ) 'text' the linked text/phrase
[ { "docid": "5ab89d92b3fb8142d78079e42cb8fa6a", "score": "0.8292203", "text": "function GetLinks(){\n\t\t//get page links\n\t\t$links = array();\n\t\t$elementList = $this->dom->getElementsByTagName('a');\n\t\tfor( $i=0; $i < $elementList->length; $i++ ){\n\t\t\t//eliminate javascript calls in hyperlinks and hyperlinks with just #\n\t\t\tif( !preg_match( \"/(javascript:|\\A#\\Z)/\",$elementList->item($i)->attributes->getNamedItem('href')->value )){\n\t\t\t\t$links[$i]['href']\t= $elementList->item($i)->attributes->getNamedItem('href')->value; \n\t\t\t\t$links[$i]['title'] = $elementList->item($i)->attributes->getNamedItem('title')->value;\n\t\t\t\t$links[$i]['text']\t= $elementList->item($i)->textContent;\n\t\t\t}\n\t\t}\n\t\treturn $links;\n\t}", "title": "" } ]
[ { "docid": "9e21efdb4ed25db18f7c4be5724915b7", "score": "0.8032423", "text": "public function getLinks($html);", "title": "" }, { "docid": "9c91756066df688abeb491bd35cca81e", "score": "0.78104204", "text": "public function getLinks();", "title": "" }, { "docid": "9c91756066df688abeb491bd35cca81e", "score": "0.78104204", "text": "public function getLinks();", "title": "" }, { "docid": "9c91756066df688abeb491bd35cca81e", "score": "0.78104204", "text": "public function getLinks();", "title": "" }, { "docid": "9c91756066df688abeb491bd35cca81e", "score": "0.78104204", "text": "public function getLinks();", "title": "" }, { "docid": "0e576ff8af0f8ffde781ca2c320718e4", "score": "0.75742084", "text": "abstract public function getLinks();", "title": "" }, { "docid": "3cc4d7733df9e0780402ede082e247f0", "score": "0.74576366", "text": "public function getLinks()\n {\n if ($this->numberOfLinks > 0) {\n $text = $this->crawler->filter('a')->text();\n $href = $this->crawler->filter('a')->link()->getUri();\n $currentLinks = [];\n $this->crawler->filter('a')->each(function (Crawler $node, $i) use (&$currentLinks) {\n $nodeUrl = $node->filter('a')->link()->getUri();\n $nodeName = $node->text();\n $nodeTitle = $node->attr('title');\n $currentLinks[$nodeUrl]['url'] = $nodeUrl;\n $currentLinks[$nodeUrl]['name'] = $nodeName;\n $currentLinks[$nodeUrl]['title'] = $nodeTitle;\n });\n foreach ($currentLinks as $key) {\n if ($key['title'] == null) {\n $this->missingTitles[] = $key['url'];\n }\n }\n \n $this->currentLinks = $currentLinks;\n\n }\n\n return $this->currentLinks;\n }", "title": "" }, { "docid": "453a834fa8f6cf8d6cb7a8edf6089115", "score": "0.7437453", "text": "public function getLinks()\n {\n return $this->find('link', 'TagLink');\n }", "title": "" }, { "docid": "1fb5724ac332fe522f057c6454879f3a", "score": "0.73617554", "text": "function extractLinks($html)\n{\n\t$tempLinks = array();\n\t$dom = new DOMDocument;\n\t@$dom->loadHTML($html); //Suspress pages with mark up errors\n\t\n\tforeach ($dom->getElementsByTagName('a') as $node)\n\t{\n\t // echo $node->nodeValue.': '.$node->getAttribute(\"href\").\"\\n\";\n\t $tempLinks[] = trim($node->getAttribute(\"href\"));\n\t}\n\t\n\t//Remove empty and null URLs\n\tforeach ($tempLinks as $key => $value) {\n if (is_null($value) || $value==\"\") {\n unset($tempLinks[$key]);\n }\n }\n\t\n\t\n\treturn $tempLinks;\n}", "title": "" }, { "docid": "5f6e3018f715a7cfedfe4581c4236aa0", "score": "0.72972035", "text": "private function getLinks($html)\n {\n $urls = [];\n $dom = new \\DOMDocument();\n $dom->loadHTML($html);\n $anchors = $dom->getElementsByTagName('a');\n foreach ($anchors as $anchor) {\n $urls[] = ($anchor->hasAttribute('href')) ? $anchor->getAttribute('href') : false;\n }\n\n return $urls;\n }", "title": "" }, { "docid": "6c638a6552680bb3a3af6f6b97e700f9", "score": "0.72713006", "text": "function getLinks($url='')\r\n\t{\r\n\t\t//Check whether\r\n\t\tif($url=='')\r\n\t\t{\r\n\t\t\t$url = $this->url;\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t$this->url = $url;\r\n\t\t}\r\n\r\n\t\t// Set user agent, for robots.txt checking...\r\n\t\tini_set('user_agent', 'MT-Soft (http://www.mt-soft.com.ar)');\r\n\t\t$url_list = array();\r\n\t\t// Check if required data was provided. If not, return empty list.\r\n\t\tif (!trim($url))\r\n\t\t{\r\n\t\t\treturn $url_list;\r\n\t\t}\r\n\r\n\r\n\t\t// Check if we're allowed to spider content. Being polite!!!\r\n\t\tif (!$this->_robots_allowed($location, \"MT-Soft\"))\r\n\t\t{\r\n\t\t\tprint \"not allowed\";\r\n\t\t\treturn $url_list;\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t$html = $this->_get_page_contents($url);\r\n\t\t\t$location = $url;\r\n\r\n\t\t\t// Search through the HTML, save all <link> tags and store each link's attributes in an associative array\r\n\t\t\tpreg_match_all('/<link\\s+(.*?)\\s*\\/?>/si', $html, $matches);\r\n\t\t\t$links = $matches[1];\r\n\t\t\tpreg_match_all('/<a.* href=[\\'\"](.*?)[\\'\"][^\\>]*>/i', $html, $anchormatches);\r\n\t\t\t$anchorlinks=$anchormatches[1];\r\n\r\n\t\t\tforeach($anchorlinks as $anchor)\r\n\t\t\t{\r\n\t\t\t\tif (strstr($anchor,'feed') || strstr($anchor,'xml') || strstr($anchor,'rss') || strstr($anchor,'atom'))\r\n\t\t\t\t\t$url_list[]=$anchor;\r\n\t\t\t}\r\n\r\n\t\t\t$final_links = array();\r\n\t\t\t$link_count = count($links);\r\n\t\t\tfor($n = 0; $n < $link_count; $n++)\r\n\t\t\t{\r\n\t\t\t\t$attributes = preg_split('/\\s+/s', $links[$n]);\r\n\t\t\t\tforeach($attributes as $attribute)\r\n\t\t\t\t{\r\n\t\t\t\t\t$att = preg_split('/\\s*=\\s*/s', $attribute, 2);\r\n\t\t\t\t\tif (isset($att[1]))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$att[1] = preg_replace('/([\\'\"]?)(.*)\\1/', '$2', $att[1]);\r\n\t\t\t\t\t\t$final_link[strtolower($att[0])] = $att[1];\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t$final_links[$n] = $final_link;\r\n\t\t\t}\r\n\r\n\t\t\t// now figure out which ones point to the RSS file\r\n\t\t\tfor($n = 0; $n < $link_count; $n++)\r\n\t\t\t{\r\n\t\t\t\t$href ='';\r\n\t\t\t\tif (strtolower($final_links[$n]['rel']) == 'alternate' or strtolower($final_links[$n]['rel']) == 'outline')\r\n\t\t\t\t{\r\n\t\t\t\t\tif (strtolower($final_links[$n]['type']) == 'application/rss+xml')\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$href = $final_links[$n]['href'];\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (!$href and strtolower($final_links[$n]['type']) == 'text/xml')\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t// kludge to make the first version of this still work\r\n\t\t\t\t\t\t$href = $final_links[$n]['href'];\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (!$href and strtolower($final_links[$n]['type']) == 'application/atom+xml')\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t// Find ATOM feeds\r\n\t\t\t\t\t\t$href = $final_links[$n]['href'];\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (!$href and in_array(strtolower($final_links[$n]['type']), array('text/x-opml', 'application/xml', 'text/xml')) and\r\n\t\t\t\t\t\t\tpreg_match(\"/\\.opml$/\", $final_links[$n]['href']))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t// Find OPML outlines\r\n\t\t\t\t\t\t$href = $final_links[$n]['href'];\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif ($href)\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tif (strstr($href, \"http://\") !== false)\r\n\t\t\t\t\t\t{ // if it's absolute\r\n\t\t\t\t\t\t\t$full_url = $href;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t{ // otherwise, 'absolutize' it\r\n\t\t\t\t\t\t\t$url_parts = parse_url($location);\r\n\t\t\t\t\t\t\t// only made it work for http:// links. Any problem with this?\r\n\t\t\t\t\t\t\t$full_url = \"http://$url_parts[host]\";\r\n\t\t\t\t\t\t\tif (isset($url_parts['port']))\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t$full_url .= \":$url_parts[port]\";\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tif ($href{0} != '/')\r\n\t\t\t\t\t\t\t{ // it's a relative link on the domain\r\n\t\t\t\t\t\t\t\t$full_url .= dirname($url_parts['path']);\r\n\t\t\t\t\t\t\t\tif (substr($full_url, -1) != '/')\r\n\t\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t\t// if the last character isn't a '/', add it\r\n\t\t\t\t\t\t\t\t\t$full_url .= '/';\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t$full_url .= $href;\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t// Only add the feed URL if not already on the list\r\n\t\t\t\t\t\tif(!in_array($full_url, $url_list))\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t$url_list[] = $full_url;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn $url_list;\r\n\t}", "title": "" }, { "docid": "4a4fe54a38dc26eefcb8f745c82b6e69", "score": "0.72709626", "text": "protected final function _getLinks() {}", "title": "" }, { "docid": "50f984cecf3677c9cacf3fc750608273", "score": "0.72563314", "text": "public function getLinks()\r\n\t{\r\n\t\treturn $this->links;\r\n\t}", "title": "" }, { "docid": "403105d08bb42427495152af39191c26", "score": "0.72427845", "text": "public function fetchLinks(){\n\n\t\t\t\t$links\t=\t$this->fetchTag('a',\"href\");\n\n\t\t\t\t$javascripts\t=\tArray();\n\t\t\t\t$anchors\t\t\t=\tArray();\n\t\t\t\t$pureLinks\t\t=\tArray();\n\t\t\t\t$emails\t\t\t=\tArray();\n\n\t\t\t\tforeach($links as $link){\n\t\t\t\t\n\t\t\t\t\tif(preg_match(\"/javascript\\:/i\",$link)){\n\n\t\t\t\t\t\tif(!in_array($link,$javascripts)){\n\n\t\t\t\t\t\t\t$javascripts[]=$link;\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}elseif(preg_match(\"/^#.*/\",$link)){\n\n\t\t\t\t\t\t\tif(!in_array($link,$anchors)){\n\n\t\t\t\t\t\t\t\t$anchors[]=$link;\n\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t}elseif(preg_match(\"/^mailto\\:/i\",$link)){\n\n\t\t\t\t\t\tif(!in_array($link,$emails)){\n\n\t\t\t\t\t\t\t$emails[]=$link;\n\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}else{\n\n\t\t\t\t\t\tif(!in_array($link,$pureLinks)){\n\n\t\t\t\t\t\t\t$pureLinks[]=$link;\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t\treturn array(\n\t\t\t\t\t\"javascript\"\t=>\t$javascripts,\n\t\t\t\t\t\"anchors\"\t\t=>\t$anchors,\n\t\t\t\t\t\"links\"\t\t\t=>\t$pureLinks,\n\t\t\t\t\t\"emails\"\t\t\t=>\t$emails\n\t\t\t\t);\n\n\t\t\t}", "title": "" }, { "docid": "56f2938778ae90329f4012316557ef54", "score": "0.7235938", "text": "function links() {\n return array(\n\n );\n }", "title": "" }, { "docid": "2e0a827768e25182972589f7212721f4", "score": "0.7152453", "text": "public function getLinks()\n {\n return $this->links;\n }", "title": "" }, { "docid": "2e0a827768e25182972589f7212721f4", "score": "0.7152453", "text": "public function getLinks()\n {\n return $this->links;\n }", "title": "" }, { "docid": "2e0a827768e25182972589f7212721f4", "score": "0.7152453", "text": "public function getLinks()\n {\n return $this->links;\n }", "title": "" }, { "docid": "2e0a827768e25182972589f7212721f4", "score": "0.7152453", "text": "public function getLinks()\n {\n return $this->links;\n }", "title": "" }, { "docid": "2e0a827768e25182972589f7212721f4", "score": "0.7152453", "text": "public function getLinks()\n {\n return $this->links;\n }", "title": "" }, { "docid": "aa3a06e73c8df2438306819e6f172620", "score": "0.7071796", "text": "public function getLinks(): array\n {\n return $this->links;\n }", "title": "" }, { "docid": "4a042e784f296fc99660c4ea52099f41", "score": "0.7044712", "text": "public function getLinks()\n {\n $obj = $this->getIfSet('_links');\n if ($obj) {\n return new Links($obj);\n }\n }", "title": "" }, { "docid": "933eab1057d982f145838afa9e8d2fc6", "score": "0.70402175", "text": "public function getLinks() {\n return $this->links;\n }", "title": "" }, { "docid": "933eab1057d982f145838afa9e8d2fc6", "score": "0.70402175", "text": "public function getLinks() {\n return $this->links;\n }", "title": "" }, { "docid": "a078678d5c0768f6fb61837adc992d74", "score": "0.7018398", "text": "public function getLinks()\n {\n return $this->_links;\n }", "title": "" }, { "docid": "ab2fae3e8d7f0cca80aa8d3e6e88f21b", "score": "0.70134956", "text": "function fetchLinks($url){\r\n\t\t\r\n\t\t$html=@file_get_html($url);\r\n\t\tif(!empty($html)){\r\n\t foreach($html->find('a') as $element) {\r\n\t if (strpos($element->href, 'http') === 0) {\r\n\t\t $link_repository[]=$element->href;\r\n\t } \r\n }\r\n\t\t}\r\n return $link_repository;\r\n\t}", "title": "" }, { "docid": "371fc11c1eb0da4a380d926ef73e27bc", "score": "0.7006778", "text": "function get_links($url) {\n $xml = new DOMDocument(); \n\n // Load the url's contents into the DOM \n// $returnF = file_get_data_htmldom($url); \n//\t@$xml->loadHTML($returnF); \n\t@$xml->loadHTMLFile($url); \n\t\n // Empty array to hold all links to return \n $links = array(); \n \n //Loop through each <a> tag in the dom and add it to the link array \n foreach($xml->getElementsByTagName('img') as $link) { \n $links[] = array('url' => $link->getAttribute('src'), 'text' => $link->nodeValue); \n } \n \n //Return the links \n return $links; \n}", "title": "" }, { "docid": "e4c288e5b57f0aff4ce4ce9c80eab18c", "score": "0.69477105", "text": "public function getLinks()\n {\n return $this->_links;\n }", "title": "" }, { "docid": "2491c0c42895d2a7f3536e64b1f63732", "score": "0.6918981", "text": "public function getLinks() {\n return $this->_links;\n }", "title": "" }, { "docid": "5809c46053aa6473a04acf5051bfec38", "score": "0.6904417", "text": "public function getAllLinks(){\n\t\t$query = 'SELECT * FROM Links';\n\t\treturn $this->database->retrieve($query);\n\t}", "title": "" }, { "docid": "8467f51758c9501afbc22c386fcf2bf0", "score": "0.6828946", "text": "function get_links_curl($url) {\n $xml = new DOMDocument(); \n $xml->preserveWhiteSpace = false;\n // Load the url's contents into the DOM \n $returnF = file_get_data_htmldom_($url); \n\t@$xml->loadHTML($returnF); \n\n\t$domXpath = new DOMXpath($xml);\n $query_string = \"//img|//dl[@class='priceList']/dd\";\n\t//$query_string =\"//img|//span[@class='p1']|//span[@class='txtype1']\";\n\t$final_nodes = $domXpath->query($query_string);\n\n\n // Empty array to hold all links to return \n// $links = array(); \n// \n// //Loop through each <a> tag in the dom and add it to the link array \n foreach($final_nodes as $link) { \n\t\t//echo $link->tagName.\"------\".$link->getNodePath() .\"---------\".$link->textContent. \"<br>\";\n $links[] = $link->getAttribute('src'); \n\t\t//$links[] = array('url' => $link->getAttribute('src'), 'text' => $link->nodeValue); \n } \n\t//print_r($links);\n //Return the links \n return $links; \n}", "title": "" }, { "docid": "f079ae07ec374e1aac2ad7119e00475b", "score": "0.68071675", "text": "public function getLinks() {\n $linkProperty = Chain\\Registry::getLinkProperty($this);\n return $this->{$linkProperty};\n }", "title": "" }, { "docid": "e648375e0d86c1984ccf729f876d62e1", "score": "0.679263", "text": "public function getLinks() {\n\t\treturn $this->sqlData[\"links\"]; \n\t}", "title": "" }, { "docid": "95efc05e42433bce47f8ccbf5b04cf4f", "score": "0.67515635", "text": "public function getLinks()\n {\n return $this->getAllChildren();\n }", "title": "" }, { "docid": "07fe44f4dbe19b799fa027c82cc45781", "score": "0.671506", "text": "public function get_links () {\n\t\treturn $this->pager->getLinks();\n\t}", "title": "" }, { "docid": "74f0700472a4494cf0a24e13cbd8c3bd", "score": "0.668851", "text": "function getLinksByURLByDOM($url){\n $array_links_count = 0;\n $array_links = array();\n $html = file_get_html($url);\n\n foreach($html->find('a') as $element){\n $array_links[$array_links_count] = $element;\n $array_links_count++;\n }\n return $array_links;\n}", "title": "" }, { "docid": "241e4fc652f97e794aa9a192d037a2ec", "score": "0.66731143", "text": "public function getLinks()\n {\n return $this->method('GET')->resource('')->make();\n }", "title": "" }, { "docid": "4738c6609f81b0f36369c8353ed89d2f", "score": "0.6662386", "text": "public function getLinkTags() {\n\t\t$tags_array = array();\n\t\t\n\t\t$matches = $this->domDoc->getElementsByTagName(\"link\");\n\t\tforeach ($matches as $tag) {\n\t\t\t$tag_code = $this->domDoc->saveHTML($tag);\n\t\t\t$href = $tag->getAttribute('href');\n\t\t\tif ( $href == \"\" || substr($href, 0, 4) == \"http\" ) {\n\t\t\t\t$href_rebuilt = $href;\n\t\t\t} else {\n\t\t\t\t$href_rebuilt = $this->rebuildUrl($href);\n\t\t\t}\n\t\t\t\n\t\t\tif ( $href_rebuilt !== \"\" ) {\n\t\t\t\t$this->urlsList[] = $href_rebuilt;\n\t\t\t}\n\t\t\t$this->tagsList[$tag_code] = $href_rebuilt;\n\n\t\t\t$meta_attributes = $this->getElementAttributes($tag);\n\t\t\t$tags_array[] = array(\n\t\t\t\t'tag_code' \t\t\t=> $tag_code,\n\t\t\t\t'href'\t\t\t\t=> $href,\n\t\t\t\t'href_rebuilt'\t\t=> $href_rebuilt,\n\t\t\t\t'meta_attributes'\t=> $meta_attributes );\n\t\t\n\t\t\t}\n\n\t\treturn $tags_array;\n\t}", "title": "" }, { "docid": "95e2c1656bd534375f8899c91883ec9f", "score": "0.6654703", "text": "public function getLinks()\n {\n if ($this->filterCallback === null) {\n $links = $this->links;\n } else {\n $links = array_filter($this->links, function ($linkObj) {\n /*@var $linkObj Link */\n return $linkObj->shouldNotVisit() == false;\n });\n }\n \n return $links;\n }", "title": "" }, { "docid": "22342de0df166a76b3a30d59802efe3c", "score": "0.65818757", "text": "function getLinks($dom)\n\t{\n// echo '<p>Searching 4 links...</p>';\n\t\t$array_of_links = array();\n\t\tforeach ($dom->find('a') as $e) {\n\t\t\t$href_url = $e->href;\n\t\t\t$array_of_links[] = $href_url;\n// echo $href_url . '<br>';\n/// if(!file_exists('download/'.$imagename)){copy($imgurl,\"download/$imagename\");}\n\t\t}\n\t\treturn $array_of_links;\n\t}", "title": "" }, { "docid": "c04a192f35b29fdf4a8c1c0e54b28888", "score": "0.6458268", "text": "function get_links() {\n\t\t$params = array(\n\t\t\t's_container_type' => $this->container_type,\n\t\t\t's_container_id' => $this->container_id,\n\t\t);\n\t\treturn blc_get_links( $params );\n\t}", "title": "" }, { "docid": "3c42171aa922f5857127d16593468526", "score": "0.64555186", "text": "public function getAllLinks()\n {\n return $this->_callParentMethod(__METHOD__, func_get_args());\n }", "title": "" }, { "docid": "d3040983c0d080903267dd729da7039d", "score": "0.64356273", "text": "public function getLinks(): ?array\n {\n $links = $this->hydrateLinks($this->{self::LINKS});\n $this->offsetSet(self::LINKS, $links);\n\n return $links;\n }", "title": "" }, { "docid": "9eb1221b3eb2a3d88d06686f8eeb6879", "score": "0.64249897", "text": "public function getLinks()\r\r\n {\r\r\n ksort($this->_links);\r\r\n return $this->_links;\r\r\n }", "title": "" }, { "docid": "c5fedb1e7d6c2566f1e2c8960518cce0", "score": "0.6405149", "text": "public function getAllLinks() {\n $links = array();\n $collection = $this->_getCollection();\n if ($collection->count() <= 0)\n return false;\n $_exclArray = array();\n foreach ($collection as $link) {\n $path = $link->getFilename();\n $filename = basename($path);\n if (empty($filename) || !file_exists($path) || in_array($filename, $_exclArray)) {\n continue;\n }\n $_exclArray[] = $filename;\n $links[] = $link;\n }\n return $links;\n }", "title": "" }, { "docid": "289bc94253284b914f6d8d4212bf674b", "score": "0.6400357", "text": "function get_links()\r\n\t{\r\n\t\t$tbl_link = Database::get_course_table(TABLE_LINK);\r\n\t\t\t\r\n\t\t$sql_link = \"\r\n\t\t\tSELECT *\r\n\t\t\tFROM \" . $tbl_link . \"\r\n\t\t\tORDER BY title ASC\";\r\n\t\t$res_link = api_sql_query($sql_link, __FILE__, __LINE__);\r\n\t\t\r\n\t\t$return .= '<div class=\"lp_resource_header\"' . \" onclick=\\\"if(document.getElementById('resLink').style.display == 'block') {document.getElementById('resLink').style.display = 'none';} else {document.getElementById('resLink').style.display = 'block';}\\\"\" . ' style=\"cursor:pointer;\"><img align=\"left\" alt=\"\" src=\"../img/lp_' . TOOL_LINK . '.gif\" style=\"margin-right:5px;\" title=\"\" />'.get_lang(\"Links\").'</div>';\r\n\t\t$return .= '<div class=\"lp_resource_elements\" id=\"resLink\">';\r\n\t\t\r\n\t\t\twhile($row_link = Database::fetch_array($res_link))\r\n\t\t\t{\r\n\t\t\t\t$return .= '<div class=\"lp_resource_element\">';\r\n\t\t\t\t\r\n\t\t\t\t\t$return .= '<img align=\"left\" alt=\"\" src=\"../img/file_html_small.gif\" style=\"margin-right:5px;\" title=\"\" />';\r\n\t\t\t\t\t$return .= '<a href=\"' .api_get_self(). '?cidReq=' . $_GET['cidReq'] . '&amp;action=add_item&amp;type=' . TOOL_LINK . '&amp;file=' . $row_link['id'] . '&amp;lp_id=' . $this->lp_id . '\">' . $row_link['title'] . '</a>';\r\n\t\t\t\t\r\n\t\t\t\t$return .= '</div>';\r\n\t\t\t}\r\n\t\t$return .= '<div class=\"lp_resource_element\">';\r\n\t\t\t$return .= '<img align=\"left\" alt=\"\" src=\"../img/file_html_new_small.gif\" style=\"margin-right:5px;\" title=\"\" />';\r\n\t\t\t$return .= '<a href=\"'.api_get_path(REL_CODE_PATH).'link/link.php?'.api_get_cidreq().'&action=addlink\" title=\"' . get_lang('LinkAdd') . '\">' . get_lang('LinkAdd') . '</a>';\r\n\t\t$return .= '</div>';\r\n\t\t\t\r\n\t\t\tif(Database::num_rows($res_link) == 0)\r\n\t\t\t\t$return .= '<div class=\"lp_resource_element\">'.get_lang(\"NoLinksAvailable\").'</div>';\r\n\t\t\r\n\t\t$return .= '</div>';\r\n\t\t\r\n\t\treturn $return;\r\n\t}", "title": "" }, { "docid": "ac079b9682745629d2343cada7fac4a2", "score": "0.6396149", "text": "public function Links() { \n $this->Menu();\n \n $ne = CNeurosis::Instance();\n \n $url = 'developer/links';\n $current = $ne->request->CreateUrl($url);\n\n $ne->request->cleanUrl = false;\n $ne->request->querystringUrl = false;\n $default = $ne->request->CreateUrl($url);\n \n $ne->request->cleanUrl = true;\n $clean = $ne->request->CreateUrl($url);\n \n $ne->request->cleanUrl = false;\n $ne->request->querystringUrl = true; \n $querystring = $ne->request->CreateUrl($url);\n \n $ne->data['main'] .= <<<EOD\n<h2>CRequest::CreateUrl()</h2>\n<p>Here is a list of urls created using above method with various settings. All links should lead to\nthis same page.</p>\n<ul>\n<li><a href='$current'>This is the current setting</a>\n<li><a href='$default'>This would be the default url</a>\n<li><a href='$clean'>This should be a clean url</a>\n<li><a href='$querystring'>This should be a querystring like url</a>\n</ul>\n<p>Enables various and flexible url-strategy.</p>\nEOD;\n }", "title": "" }, { "docid": "56a6776e213b8ad81856d456940c3938", "score": "0.63518095", "text": "public function getLinks()\n {\n $links = array();\n\n $links[] = array(\n 'url' => ModUtil::url($this->name, 'admin', 'info'),\n 'text' => $this->__('Information'),\n 'class' => 'z-icon-es-info');\n if (SecurityUtil::checkPermission('Zgoodies::', '::', ACCESS_ADMIN)) {\n $links[] = array(\n 'url' => ModUtil::url($this->name, 'admin', 'modifyconfig'),\n 'text' => $this->__('Settings'),\n 'class' => 'z-icon-es-config');\n }\n if (SecurityUtil::checkPermission('Zgoodies::', '::', ACCESS_ADMIN)) {\n $links[] = array(\n 'url' => 'https://github.com/nmpetkov/Zgoodies/wiki',\n 'text' => $this->__('Wiki'),\n 'class' => 'z-icon-es-help');\n }\n\n return $links;\n }", "title": "" }, { "docid": "f83b96c0852805ada7e62dead10d6deb", "score": "0.63332593", "text": "public static function getLinks()\n {\n $output = '';\n foreach (self::$links as $key => $value) {\n $output .= \".. _`$key`: $value\\n\";\n }\n return $output;\n }", "title": "" }, { "docid": "b32c0105352690b773d8500e43f9f478", "score": "0.6302713", "text": "function getLinks()\n {\n \treturn array('gtrwebsite_answers'=>'idNode', 'gtrwebsite_question'=>'idNode');\n }", "title": "" }, { "docid": "ec7870d2de5e6e72ac1e9ba99b723148", "score": "0.62914205", "text": "public function links(): array\n {\n $links = [];\n\n $uri = clone $this->uri;\n\n for ($i = $this->first; $i <= $this->last; $i++) {\n $uri = $this->segment === 0 ? $uri->addQuery($this->pageSelector, $i) : $uri->setSegment($this->segment, $i);\n $links[] = [\n 'uri' => URI::createURIString(\n $uri->getScheme(),\n $uri->getAuthority(),\n $uri->getPath(),\n $uri->getQuery(),\n $uri->getFragment()\n ),\n 'title' => $i,\n 'active' => ($i === $this->current),\n ];\n }\n\n return $links;\n }", "title": "" }, { "docid": "777cf1a78181970f8dd0696da886eed3", "score": "0.6274711", "text": "public function getLinks(DOMCrawler $domCrawler)\n {\n $links = $domCrawler->filter(\"a\")->links();\n array_walk($links, function (&$link) {\n $link = $this->urlFactory->makeUrl($link->getUri());\n });\n return $links;\n }", "title": "" }, { "docid": "a7880ff07ef69a458923f8679d2fe0ee", "score": "0.62544477", "text": "public function getLinks(): array\n\t{\n\t\treturn [Vtiger_Link_Model::getInstanceFromValues([\n\t\t\t'linktype' => 'LISTVIEWBASIC',\n\t\t\t'linklabel' => 'BTN_MASS_EDIT_ACCESS',\n\t\t\t'linkdata' => ['url' => $this->getEditViewUrl()],\n\t\t\t'linkicon' => 'yfi yfi-full-editing-view',\n\t\t\t'linkclass' => 'btn-primary js-show-modal',\n\t\t\t'showLabel' => 1\n\t\t])];\n\t}", "title": "" }, { "docid": "9c43a9c67f29dbbeacb402f18a830d63", "score": "0.6197508", "text": "public function getLinkArray() {\n\t\treturn $this->_link;\n\t}", "title": "" }, { "docid": "4fc3843de9d8cdd0694347d643ef5afd", "score": "0.6192992", "text": "protected function getLinks($content, $url = '')\n {\n $parsedURL = parse_url($url);\n $urlBase = (isset($parsedURL['scheme']) ? $parsedURL['scheme'] : '').'://'.(isset($parsedURL['host']) ? $parsedURL['host'] : '');\n\n $urlPattern = \"/[href|HREF]\\s*=\\s*[\\'\\\"]?([+:%\\/\\?~=&;\\\\\\(\\),._a-zA-Z0-9-]*)(#[.a-zA-Z0-9-]*)?[\\'\\\" ]?(\\s*rel\\s*=\\s*[\\'\\\"]?(nofollow)[\\'\\\"]?)?/i\";\n //$urlPattern = '/<a href=\"(.+)\">/';\n preg_match_all($urlPattern, $content, $urlMatches);\n\n $links = array();\n foreach ($urlMatches[1] as $link) {\n $link = strtolower(strtok($link, '?'));\n\n if (!$link || $link == '/' || in_array($link, $links)) {\n continue;\n }\n\n if ($url) {\n if (strpos($link, '/') === 0) {\n $link = $urlBase . $link;\n }\n\n if (strrpos($link, $urlBase) !== 0) {\n continue;\n }\n }\n\n $link = rtrim($link, '/');\n\n $links[] = $link;\n }\n\n return $links;\n }", "title": "" }, { "docid": "97c07e4bec247b0335f310c132c58db1", "score": "0.619212", "text": "protected function externalLinks(): array {\n }", "title": "" }, { "docid": "aafeced5d3a7446aa99efdb77d69ac28", "score": "0.6185146", "text": "public function listLinks()\n {\n return UsedShortLink::join('list_short_url', 'list_short_url.id', '=', 'used_short_url.short_url_id')\n ->select('used_short_url.long_url as long_url', 'list_short_url.short_url as short_url', 'used_short_url.updated_at')\n ->where('is_private', false)\n ->orderBy('used_short_url.updated_at', 'desc')\n ->get();\n }", "title": "" }, { "docid": "20fcc58ab9fb3c623bbf58c9d7be3428", "score": "0.617734", "text": "public function &getLinks()\n\t{\n\t\treturn $this->linkbar;\n\t}", "title": "" }, { "docid": "c1516810a00525fadc8766a4fcd441e5", "score": "0.61695826", "text": "public function getMenuLinks()\n {\n $menuLinks = array();\n return $menuLinks;\n }", "title": "" }, { "docid": "2b89e852c4a4292fa1b04da66a8a3922", "score": "0.6167867", "text": "public function extracData(){\r\n\t\t$pageContent = file_get_contents($this->url);\r\n\t\t$output = array();\r\n\t\tlibxml_use_internal_errors(true);\r\n\t\t$dom = new DomDocument();\r\n\t\ttry{\r\n\t\t\t$dom->loadHTML($pageContent);\t\r\n\t\t\tlibxml_clear_errors();\t\t\r\n\t\t\tforeach ($dom->getElementsByTagName('a') as $item) {\r\n\t\t\t $output[] = array (\r\n\t\t\t 'str' => $dom->saveHTML($item),\r\n\t\t\t 'href' => $item->getAttribute('href'),\r\n\t\t\t 'anchorText' => $item->nodeValue\r\n\t\t\t );\r\n\t\t\t}\r\n\t\t} \r\n\t\tcatch(Exception $ex){\r\n\t\t\techo \"Error in extraction-\".$ex->getMessage();\r\n\t\t\tdie;\r\n\t\t}\t\r\n\t\treturn $output;\t\r\n\t}", "title": "" }, { "docid": "32fc281238b13ed7e6684c5beb9fa0d8", "score": "0.61648", "text": "public function getLinks()\n {\n return [\n Link::REL_SELF => Url::to(['user/view', 'id' => $this->id], true),\n ];\n }", "title": "" }, { "docid": "321db36f4ffe2e7f8e177b63340b9d20", "score": "0.6156793", "text": "public function get() {\n return $this->_links;\n }", "title": "" }, { "docid": "438079fd6653fdcde2c580106f594f95", "score": "0.61287487", "text": "public static function convertLinks($html)\n\t{\n\t\t$baseUrl = '';\n\t\tif(preg_match('/base href=\"([^\"]+)\"/', $html, $matches)){\n\t\t\tif(isset($matches[1]))\n\t\t\t{\n\t\t\t\t$baseUrl = $matches[1];\n\t\t\t}\n\t\t}\n\n\t\t\n//\t\tDon't strip new lines or it will mess up <pre> tags\n//\t\t$html = str_replace(\"\\r\", '', $html);\n//\t\t$html = str_replace(\"\\n\",' ', $html);\n//\t\t\n\t\t//strip line breaks inside html tags\n\t\t$html = preg_replace_callback('/<[^>]+>/sm',function($matches){\n\t\t\t$replacement = str_replace(\"\\r\", '', $matches[0]);\n\t\t\treturn str_replace(\"\\n\",' ', $replacement);\n\t\t}, $html);\n\n\t\t$regexp=\"/<a[^>]*href=\\s*([\\\"']?)(http|https|ftp|bf2)(:\\/\\/)(.+?)>/i\";\n\t\t$html = preg_replace($regexp, \"<a target=$1_blank$1 class=$1blue$1 href=$1$2$3$4>\", $html);\n\t\t\n\t\tif(!empty($baseUrl)){\n\t\t\t$regexp=\"/<a[^>]*href=\\s*('|\\\")(?![a-z]+:)/i\";\n\t\t\t$html = preg_replace($regexp, \"<a target=$1_blank$1 class=$1blue$1 href=$1\".$baseUrl, $html);\n\t\t}\n\n\t\t//$regexp=\"/<a.+?href=([\\\"']?)\".str_replace('/','\\\\/', \\GO::config()->full_url).\"(.+?)>/i\";\n\t\t//$html = preg_replace($regexp, \"<a target=$1main$1 class=$1blue$1 href=$1\".\\GO::config()->host.\"$2$3>\", $html);\n\n\t\t//Following line breaks links on mobile phones\n\t\t//$html =str_replace(\\GO::config()->full_url, \\GO::config()->host, $html);\n\t\t\n\t\treturn $html;\n\t}", "title": "" }, { "docid": "c6cb4187179c9959b93340e97bdb4431", "score": "0.6105503", "text": "public function getLinks(){\n $result = $this->db->get('series')->result_array()[0];\n $url = 'http://www.primewire.ag' . str_replace('watch', 'tv', $result['url']) . '/season-' . $result['season'] . '-episode-' . $result['episode'];\n $contents = file_get_html($url);\n $hosts = $contents->find('.version_host');\n $videoLinks = $contents->find('.movie_version_link');\n \n // Get the sources and get every link I can\n $this->db->order_by('preference');\n $sources = $this->db->get('sources')->result_array();\n $links = array();\n \n foreach($sources as $source){\n foreach($hosts as $key => $host){\n if(strpos($host->innertext, $source['domain'])){\n $links[] = array('domain' => $source['domain'], 'url' => 'http://www.primewire.ag' . $videoLinks[$key]->find('a')[0]->attr['href']);\n }\n }\n }\n return json_encode($links);\n }", "title": "" }, { "docid": "574bbbae7be1bd479b7b7c2a7a270be8", "score": "0.6104157", "text": "public function getAllLinks($content)\n {\n $matches = [];\n\n preg_match_all('/href=\\\"((https?:)?\\/\\/.+)\"/U', $content, $matches);\n\n if (!isset($matches[1])) {\n return [];\n }\n\n $links = array_map(function ($link) {\n return trim($link, '/');\n }, $matches[1]);\n\n return $links;\n }", "title": "" }, { "docid": "16f9a651901d6e398293e31ae3eecd24", "score": "0.60580474", "text": "public function getLink();", "title": "" }, { "docid": "16f9a651901d6e398293e31ae3eecd24", "score": "0.60580474", "text": "public function getLink();", "title": "" }, { "docid": "16f9a651901d6e398293e31ae3eecd24", "score": "0.60580474", "text": "public function getLink();", "title": "" }, { "docid": "16f9a651901d6e398293e31ae3eecd24", "score": "0.60580474", "text": "public function getLink();", "title": "" }, { "docid": "16f9a651901d6e398293e31ae3eecd24", "score": "0.60580474", "text": "public function getLink();", "title": "" }, { "docid": "479023fdf17f7d602fa68ea339a9e6a0", "score": "0.6031229", "text": "protected function gather_links( $content ) {\n\t\tif ( \\strpos( $content, 'href' ) === false ) {\n\t\t\t// Nothing to do.\n\t\t\treturn [];\n\t\t}\n\n\t\t$links = [];\n\t\t$regexp = '<a\\s[^>]*href=(\"??)([^\" >]*?)\\1[^>]*>';\n\t\t// Used modifiers iU to match case insensitive and make greedy quantifiers lazy.\n\t\tif ( \\preg_match_all( \"/$regexp/iU\", $content, $matches, \\PREG_SET_ORDER ) ) {\n\t\t\tforeach ( $matches as $match ) {\n\t\t\t\t$links[] = \\trim( $match[2], \"'\" );\n\t\t\t}\n\t\t}\n\n\t\treturn $links;\n\t}", "title": "" }, { "docid": "3c3364a751bf2926f22a8c23e7491ae2", "score": "0.6025776", "text": "function getLinks($doc, $serverLink){\n\t\t$block_links = getBlockLinks($doc, $serverLink);\n\t\tforeach ($block_links as $link) {\n\t\t\techo $link.\"<br>\";\n\t\t\t$doc = phpQuery::newDocumentFileHTML($link, $charset = 'windows-1250');\n\t\t\tforeach ($doc['tr>td.T'] as $a){\n\t\t\t\t$text_link = pq($a)->text();\n\t\t\t\t$regex = '/^([A-Z]{1}\\d{2}\\–){0,1}[A-Z]{1}\\d{2}$/';\n\t\t\t\tif( preg_match( $regex, $text_link ) === 1 ){\n\t\t\t\t\t$href = pq($a)->find('a')->attr('href');\n\t\t\t\t\techo '<a href=\"'.$serverLink.$href.'\">'.$text_link.'</a>'.'<br>';\n\t\t\t\t\t$links[]['link'] = $serverLink.$href;\n\t\t\t\t\t$links[]['text'] = $text_link;\n\t\t\t\t}\n\t\t\t}\n\t\t\t/*foreach ($doc['div#mw-content-text>dl>dd>i>a'] as $a){\n\t\t\t\t$page_link = $link.pq($a)->attr('href');\n\t\t\t\t$text_link = pq($a)->text();\n\t\t\t\techo '<a href=\"https://uk.wikipedia.org/wiki/'.$text_link.'\">'.$text_link.'</a>'.('</br>');\n\t\t\t\t$links[]['link'] = 'https://uk.wikipedia.org/wiki/'.$text_link;\n\t\t\t\t$links[]['text'] = $text_link;\n\t\t\t\t//echo $f = pq($a)->text().('</br>');\n\t\t\t\t\n\t\t\t}*/\n\t\t}\n\t\tgetDiagnoses($links);\n\t}", "title": "" }, { "docid": "9b60fa847f87dbca0412a8f23ac715ed", "score": "0.5948539", "text": "public static function getLinks()\n {\n if (!is_user_logged_in()) {\n return;\n }\n\n $userId = get_current_user_id();\n $links = (array)get_user_meta($userId, 'user_links', true);\n $links = array_filter($links);\n\n uasort($links, function ($a, $b) {\n return strcmp($a['title'], $b['title']);\n });\n\n return $links;\n }", "title": "" }, { "docid": "1c13c45714889505765918aeb159127e", "score": "0.59345865", "text": "public function getAll(): array\n {\n return $this->links;\n }", "title": "" }, { "docid": "bb8bcbae8d75140533824fa86afd5a91", "score": "0.5924874", "text": "public function getLink() {}", "title": "" }, { "docid": "767cb3fec692dd5f8b6e68590fe96014", "score": "0.5910152", "text": "protected function getLinks()\n {\n $grid = $this->getGrid();\n $links = array(); \n \n $chars = $this->getAvailableIndices();\n $current = $grid->getIndex(); \n \n // indices\n foreach ($chars as $char)\n {\n $title = $char;\n $call = $grid->getUpdateCall(array('atkstartat' => 0, 'atkindex' => \"{$char}*\"));\n $links[] = array('type' => 'index', 'title' => $title, 'call' => $call, 'current' => \"{$char}*\" == $current);\n }\n\n // view all\n if (!empty($current))\n {\n $title = $grid->text('view_all'); \n $call = $grid->getUpdateCall(array('atkindex' => ''));\n $links[] = array('type' => 'all', 'call' => $call, 'title' => $title); \n } \n \n return $links;\n }", "title": "" }, { "docid": "6246ef66ee112ccbbf475afdbd309ab8", "score": "0.5901592", "text": "function getLinks() {\r\n global $dbh;\r\n\r\n $sql = \"SELECT links.type,links.url FROM links \r\n INNER JOIN projects ON links.project_id=projects.project_id \r\n WHERE links.project_id = :project_id\";\r\n\r\n //2. Prepare the statement\r\n $statement = $dbh->prepare($sql);\r\n\r\n //3. Bind parameters\r\n $statement->bindParam(':project_id',$this->project_id, PDO::PARAM_INT);\r\n\r\n //4. Execute the query\r\n $statement->execute();\r\n\r\n $this->links = $statement->fetchAll(PDO::FETCH_ASSOC);\r\n foreach ($this->links as $link) {\r\n if($link['type'] == 'siteurl') {\r\n array_push($this->siteurl, $link['url']);\r\n } else if($link['type'] == 'trello') {\r\n array_push($this->trello, $link['url']);\r\n } else if($link['type'] == 'github') {\r\n array_push($this->github, $link['url']);\r\n }\r\n }\r\n }", "title": "" }, { "docid": "c87286eaf9f19afc4030062f2f67fcf2", "score": "0.5901494", "text": "function getHrefLinks($link){\n $result = [];\n $selector = file_get_html($link)->find('a');\n foreach ($selector as $item) {\n $parsedUrl = parse_url($link);\n\n if(strpos($item->href, $parsedUrl['host']) AND !in_array($item->href, $result)){\n\n $result[] = $item->href;\n }\n }\n return $result;\n}", "title": "" }, { "docid": "f70c2a5d216de03ec3a26114e12a5ebb", "score": "0.58677477", "text": "public function getATags() {\n\t\t// $this->loadDom();\n\t\t$tags_array = array();\n\t\t\n\t\t$matches = $this->domDoc->getElementsByTagName(\"a\");\n\t\tforeach ($matches as $tag) {\n\t\t\t$tag_code = $this->domDoc->saveHTML($tag);\n\t\t\t// $img_tag = $this->getImgTagFromNode($tag_code);\n\t\t\t$img_tag = $this->getImgTagFromNode($tag);\n\t\t\t$href = trim($tag->getAttribute('href'));\n\t\t\tif ( $href == \"\" || substr($href, 0, 4) == \"http\" ) {\n\t\t\t\t$href_rebuilt = $href;\n\t\t\t} else {\n\t\t\t\t// CakeLog::write('smf', \"href: $href\");\n\t\t\t\t$href_rebuilt = $this->rebuildUrl($href);\n\t\t\t\t// CakeLog::write('smf', \"href_rebuilt: $href_rebuilt\");\n\t\t\t\t// CakeLog::write('smf', \"current_directory: $this->current_directory\");\n\t\t\t}\n\t\t\t\n\t\t\tif ( $href_rebuilt !== \"\" ) {\n\t\t\t\t$this->urlsList[] = $href_rebuilt;\n\t\t\t}\n\t\t\t$this->tagsList[$tag_code] = $href_rebuilt;\n\n\t\t\t// $href_rebuilt = $this->rebuildUrl($tag)\n\t\t\t$meta_attributes = $this->getElementAttributes($tag);\n\t\t\t// $meta_attribs = $this->getMetaTagAttributes(\"a\", $tag, false);\n\n\t\t\t$tags_array[] = array(\n\t\t\t\t'tag_code' \t\t\t=> $tag_code,\n\t\t\t\t'href'\t\t\t\t=> $href,\n\t\t\t\t'href_rebuilt'\t\t=> $href_rebuilt,\n\t\t\t\t'a_tag_text'\t\t=> trim($tag->nodeValue),\n\t\t\t\t'a_tag_text_code' \t=> $this->innerHTML($tag),\n\t\t\t\t'img_tag'\t\t\t=> $img_tag,\n\t\t\t\t'meta_attributes'\t=> $meta_attributes );\n\t\t}\n\n\t\treturn $tags_array;\n\t}", "title": "" }, { "docid": "f6c52a5cc1c8bead4d37344062f4beae", "score": "0.58598125", "text": "public function linkFromHtml($content) {\r\n if (strpos($content, ' href=\"') !== false && strpos($content, '</a>') !== false) {\r\n $txt_nonline = str_replace(PHP_EOL, '', $content);\r\n $regexp = \"<a\\s[^>]*href=(\\\"??)([^\\\" >]*?)\\\\1[^>]*>(.*)<\\/a>\";\r\n $i = 0;$j = 0;$k = 0;\r\n if(preg_match_all(\"/$regexp/siU\", $txt_nonline, $matches, PREG_SET_ORDER)) {\r\n foreach($matches as $match) {\r\n /* $match[0] = tag a | $match[2] = link address | $match[3] = link text */\r\n if(!preg_match('/#/', $match[2]) && strpos($match[0], ' linkstats=\"') !== false) {\r\n $ori_link[] = $match[2];\r\n $link[] = $match[2].'['.$i.']';\r\n $i++;\r\n }\r\n }\r\n }\r\n if(!empty($ori_link)){\r\n foreach ($ori_link as $val) {\r\n $content = str_replace('href=\"'.$val.'\" linkstats=\"'.$j.'\"', 'href=\"'.$val.'['.$j.']\" linkstats=\"'.$j.'\"', $content);\r\n $j++;\r\n }\r\n }\r\n if(!empty($link)){\r\n foreach ($link as $val) {\r\n $content = str_replace('href=\"'.$val.'\" linkstats=\"'.$k.'\"', 'href=\"'.BASE_URL.'/linkstats/'.($k+1).'/'.str_replace(array('+', '/', '='), array('-', '_', '.'), base64_encode($val)).'\" linkstats=\"'.$k.'\"', $content);\r\n /*$content = str_replace('['.$k.']', '', $content);*/\r\n $k++;\r\n }\r\n }\r\n }\r\n return $content;\r\n }", "title": "" }, { "docid": "02d980a6995c7619f554e30783fa8bfe", "score": "0.58572483", "text": "function lo_find_file_links_from_html($html, $courseid){\r\n global $CFG;\r\n $baseurl = lo_file_links_base_url($courseid);\r\n $searchfor = '!'.\r\n '(<\\s*(a|img)\\s[^>]*(href|src)\\s*=\\s*\")'.$baseurl.'([^\"]*)\"'.\r\n '|'.\r\n '(<\\s*(a|img)\\s[^>]*(href|src)\\s*=\\s*\\')'.$baseurl.'([^\\']*)\\''.\r\n '!i';\r\n $matches = array();\r\n $no = preg_match_all($searchfor, $html, $matches);\r\n if ($no){\r\n $rawurls = array_filter(array_merge($matches[5], $matches[10]));//array_filter removes empty elements\r\n //remove any links that point somewhere they shouldn't\r\n foreach (array_keys($rawurls) as $rawurlkey){\r\n if (!$cleanedurl = lo_url_check($rawurls[$rawurlkey])){\r\n unset($rawurls[$rawurlkey]);\r\n } else {\r\n $rawurls[$rawurlkey] = $cleanedurl;\r\n }\r\n\r\n }\r\n $urls = array_flip($rawurls);// array_flip removes duplicate files\r\n // and when we merge arrays will continue to automatically remove duplicates\r\n } else {\r\n $urls = array();\r\n }\r\n return $urls;\r\n}", "title": "" }, { "docid": "d2a38a58ec765201d6b916a0c91f93b7", "score": "0.5821827", "text": "public function parseLinks()\n {\n $links = array();\n $pages = array();\n\n $topicsDirs = array(\n '/?page' => 1183,\n '/dir/?page' => 79\n );\n\n $emailsFromForums = new EmailsFromForums();\n\n // generate pages\n foreach ($topicsDirs as $dir => $lastPage) {\n $arrayPages = range(1, $lastPage);\n array_walk($arrayPages, function ($page, $key, $arg) {\n $arg[0][] = $arg[1] . $arg[2] . $page;\n\n }, [&$pages, self::URL, $dir]);\n }\n\n // for every page\n foreach ($pages as $i => $page) {\n if ($i < 0) continue;\n\n $res = $this->client->request('GET', $page);\n $saw = new \\nokogiri($res->getBody());\n $nodes = $saw->get(\n strpos($page, '/dir/?pag') ? self::TOPIC_SELECTOR2 : self::TOPIC_SELECTOR1\n )->toArray();\n\n if (strpos($page, '/dir/?pag')) {\n\n // get url of theme\n $nodesFiltred = array_map(function ($node) {\n return $node['href'];\n }, $nodes);\n } else {\n\n // filter by amount answers ( > 0)\n $nodesFiltred = array_filter($nodes, function($node) {\n return $node['table'][0]['tbody'][0]['tr'][0]['td'][0]['span'][0]['span'][1]['a'][1]['#text'][0] > 0;\n });\n\n // get url of theme\n array_walk($nodesFiltred, function(&$node) {\n $node = $node['a'][0]['href'];\n });\n }\n\n $links = array_merge($links, $nodesFiltred);\n\n echo $i . '<br>';\n flush();\n ob_flush();\n sleep(6);\n\n // seve url to DB\n $emailsFromForums->insertIntoTopics($nodesFiltred, $this->id);\n }\n\n echo '<br>DONE!<br>';\n var_dump($links);\n }", "title": "" }, { "docid": "487bf4c34e80dfb9c6a772ef88aeb141", "score": "0.58075476", "text": "public function getLinks(): ?LinksInterface\n {\n return LinksFactory::create(\n LinkFactory::create(\"/errors/example\")\n );\n }", "title": "" }, { "docid": "f9d303a401c723c7dd3a161fe62c4b03", "score": "0.57943135", "text": "public function getAllMangaUrl() {\n $mangaLinks = [];\n \n for ( $index = 0; $index < $this->lastPageNumber; $index++ ) {\n $pageNum = $index + 1;\n $uri = $this->_resolvePageLink($pageNum);\n $pageUrl = $this->domain . $this->pageListUrl . $uri;\n \n $mangaListContainer = $this->getMangaListContainer($pageUrl);\n \n $urls = $mangaListContainer->filter('tr')->each(function (Crawler $node, $index) {\n return [\n 'link' => $node->filter('td')->eq(1)->filter('a')->attr('href'),\n 'manga_name' => $node->filter('td')->eq(1)->filter('a')->attr('title'),\n 'domain' => $this->domain\n ];\n });\n \n foreach( $urls as $url ) {\n array_push($mangaLinks, $url);\n }\n }\n \n return $mangaLinks;\n }", "title": "" }, { "docid": "12bb6271f5f5ab1807136b6509ca0e4f", "score": "0.5779895", "text": "public function getLinks()\n {\n $links = array();\n\n if (SecurityUtil::checkPermission($this->name . '::', '::', ACCESS_READ)) {\n $links[] = array('url' => ModUtil::url($this->name, 'user', 'main'),\n 'text' => $this->__('Frontend'),\n 'title' => $this->__('Switch to user area.'),\n 'class' => 'z-icon-es-home');\n }\n\n $controllerHelper = new MUFiles_Util_Controller($this->serviceManager);\n $utilArgs = array('api' => 'admin', 'action' => 'getLinks');\n $allowedObjectTypes = $controllerHelper->getObjectTypes('api', $utilArgs);\n\n if (in_array('collection', $allowedObjectTypes)\n && SecurityUtil::checkPermission($this->name . ':Collection:', '::', ACCESS_ADMIN)) {\n $links[] = array('url' => ModUtil::url($this->name, 'admin', 'view', array('ot' => 'collection')),\n 'text' => $this->__('Collections'),\n 'title' => $this->__('Collection list'));\n }\n if (in_array('file', $allowedObjectTypes)\n && SecurityUtil::checkPermission($this->name . ':File:', '::', ACCESS_ADMIN)) {\n $links[] = array('url' => ModUtil::url($this->name, 'admin', 'view', array('ot' => 'file')),\n 'text' => $this->__('Files'),\n 'title' => $this->__('File list'));\n }\n if (in_array('file', $allowedObjectTypes)\n && SecurityUtil::checkPermission($this->name . '::', '::', ACCESS_ADMIN)) {\n $links[] = array('url' => ModUtil::url($this->name, 'admin', 'import'),\n 'text' => $this->__('Import'),\n 'title' => $this->__('Import categories and files of downloads module'));\n }\n /*if (in_array('hookobject', $allowedObjectTypes)\n && SecurityUtil::checkPermission($this->name . ':Hookobject:', '::', ACCESS_ADMIN)) {\n $links[] = array('url' => ModUtil::url($this->name, 'admin', 'view', array('ot' => 'hookobject')),\n 'text' => $this->__('Hookobjects'),\n 'title' => $this->__('Hookobject list'));\n }*/\n if (SecurityUtil::checkPermission($this->name . '::', '::', ACCESS_ADMIN)) {\n $links[] = array('url' => ModUtil::url($this->name, 'admin', 'config'),\n 'text' => $this->__('Configuration'),\n 'title' => $this->__('Manage settings for this application'));\n }\n\n return $links;\n }", "title": "" }, { "docid": "8a70343b62989edb2341087dde3ff7b9", "score": "0.5760941", "text": "public function get_post_links($id){\n\t\t$items = get_field('post_links', $id);\n\t\t$links = array();\n\t\tif(isset($items) && gettype($items) == 'array' && count($items) > 0){\n\t\t\tforeach($items as $item){\n\t\t\t\t$this_item = array();\n\t\t\t\t$this_item['title'] = $item['title'];\n\t\t\t\tif($item['type'] == 'url'){\n\t\t\t\t\t$this_item['url'] = $item['url'];\n\t\t\t\t\t$this_item['target'] = '_blank';\n\t\t\t\t}\n\t\t\t\tif($item['type'] == 'post'){\n\t\t\t\t\t$this_item['url'] = get_permalink($item['post']->ID);\n\t\t\t\t\t$this_item['target'] = '_self';\n\t\t\t\t}\n\t\t\t\tarray_push($links, $this_item);\n\t\t\t}\n\t\t}\n\t\treturn $links;\n\t}", "title": "" }, { "docid": "2381000faf4d2f8d353b5177fa5d57df", "score": "0.5758887", "text": "private function returnNonHtmlDocument($html) {\n $dom = new DOMDocument();\n $internalErrors = libxml_use_internal_errors(true); // suppress minor HTML validation errors\n $dom->loadHTML($html);\n\n $xpath = new DOMXPath($dom);\n $allNodes = $xpath->query('//node()');\n\n $allText = [];\n $links = [];\n\n $prevText = '';\n\n foreach ($allNodes as $node) { \n $type = get_class($node);\n\n if ('DOMElement' === $type && $node->hasAttribute('href')) {\n $link = $node->getAttribute('href');\n\n // Determine proper text for DOMElement node.\n // If the textContent property is not empty, use that\n // Otherwise, check if this node has any children\n // and take all titles from them\n // N.B. This procedure strongly assumes that the child nodes\n // are image tags. Any changes to creatives will result in a change here.\n\n if ($node->textContent) {\n $prevText = $node->textContent;\n $text = $node->textContent . ' [' . $link . ']';\n }\n elseif ($node->hasChildNodes()) {\n $text = '';\n\n foreach ($node->childNodes as $child) {\n if ( !method_exists( $child , 'getAttribute' ) ) { \n continue;\n }\n \n $text .= $child->getAttribute('title');\n }\n $prevText = $text;\n\n $text .= ' [' . $link . ']';\n }\n else {\n $text = '';\n $prevText = '';\n }\n \n }\n elseif ('DOMElement' === $type && $node->hasAttribute('src') \n && $node->textContent !== $prevText \n && $node->getAttribute('title') !== $prevText) {\n // For images, suppress the link, get the image title\n $link = '';\n $text = $node->textContent ?: $node->getAttribute('title');\n $prevText = $text;\n }\n elseif ('DOMText' === $type && $node->textContent !== $prevText) {\n $text = $node->textContent;\n $link = '';\n $prevText = $text;\n } \n else {\n continue;\n }\n\n if ($text !== '') {\n $allText []= $text;\n }\n\n if ($link !== '') {\n $links []= $link;\n }\n \n }\n\n libxml_use_internal_errors($internalErrors);\n\n $text = implode(PHP_EOL, $allText) . PHP_EOL . PHP_EOL;\n\n $links = array_keys(array_flip($links));\n $length = sizeof($links);\n\n for ($i = 0; $i < $length; $i++) {\n $text .= ($i + 1) . '. ' . $links[$i] . PHP_EOL; // links not zero-indexed in file\n }\n\n return $text;\n }", "title": "" }, { "docid": "b6f2ce0214ac9cdf814211a93db32f49", "score": "0.5754562", "text": "function getLinks($mysqli){\n\n\t\tglobal $links_array;\n\n\t\t$links_array = array();\n\t\t$query = 'SELECT * from classmarker_links';\n\n\t\tif ($result = $mysqli->query($query)) {\n\n\t\t\twhile ($obj = $result->fetch_object()) {\n\n\t\t\t\t$links_array[ $obj->link_id ] = $obj->link_name;\n\n\t\t\t}\n\t\t}\n\n\t}", "title": "" }, { "docid": "0aed3399dc349e69e505b51db325adb4", "score": "0.5734674", "text": "public function getLink()\n {\n return Controller::join_links(\n $this->Blog()->Link(),\n $this->getListUrlSegment(),\n $this->URLSegment\n );\n }", "title": "" }, { "docid": "d8fb61bf916c789c6389d43065204b51", "score": "0.57241637", "text": "public function getUrls();", "title": "" }, { "docid": "d8fb61bf916c789c6389d43065204b51", "score": "0.57241637", "text": "public function getUrls();", "title": "" }, { "docid": "9ec05801aefea12abd283445fa79facb", "score": "0.57044005", "text": "public function findLinks($string) \n {\n $result = [];\n \n $regexp = \"<a\\s[^>]*href=([\\\"\\']??)([^\\\" >]*?)\\\\1[^>]*>(:?.*)<\\/a>\";\n\n if (preg_match_all(\"/$regexp/siU\", $string, $matches, PREG_SET_ORDER)) {\n\n foreach ($matches as $match) {\n \n if (!empty($match[2])) {\n\n $link = $this->checkLink($match[2]);\n \n if (false === in_array($link, $result, false)) {\n\n $result[] = $link;\n \n }\n }\n }\n }\n\n //unique values only\n $this->find = array_unique($result);\n }", "title": "" }, { "docid": "b555150ddc49d731cbb60db56113cc1e", "score": "0.56874615", "text": "private function getLinksFromPage($content) {\n\t\t\t$dom = new DOMDocument;\n\t\t\t@$dom->loadHTML(utf8_decode($content));\n\t\t\t$out_links = array();\n\t\t\t$links = $dom->getElementsByTagName('a');\n\t\t\tif (!empty($this->searchTown)) {\n\t\t\t\t$town = $this->makeWebPattern($this->searchTown);\n\t\t\t} elseif (empty($this->searchTown)) {\n\t\t\t\t$town = $this->makeWebPattern($this->town);\n\t\t\t}\n\t\t\tforeach($links as $link) {\n\t\t\t\t$goal = $link->getAttribute('href');\n\t\t\t\t$classes = $link->getAttribute('class');\n\t\t\t\tif (empty($classes)) {\n\t\t\t\t\tif (preg_match(\"/user|nyheter|https/\", $goal)) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tif (preg_match(\"/\\/.+\\/.+/\", $goal)) {\n\t\t\t\t\t\t$pattern = \"/\\/$town\\/.+/\";\n\t\t\t\t\t\tif (preg_match($pattern, $goal)) {\n\t\t\t\t\t\t\t$out_links[] = $goal;\n\t\t\t\t\t\t}\n\t\t\t\t\t} \n\t\t\t\t} \n\t\t\t}\n\t\t\tif (!empty($out_links)) {\n\t\t\t\treturn $out_links;\n\t\t\t}\n\t\t\treturn FALSE;\n\t\t}", "title": "" }, { "docid": "63cfba7ab0c580547693cc9570284e83", "score": "0.5686973", "text": "public function getLinks()\n {\n $params = [\n 'key' => $this->_config->getPasswordMd5(),\n 'store' => $this->getRequest()->getParam('store'),\n ];\n\n return [\n 'schedule' => ['url' => $this->getUrl('factfinder/export/schedule', $params), 'label' => 'Schedule'],\n 'download' => ['url' => $this->getUrl('factfinder/export/download', $params), 'label' => 'Download'],\n 'link' => ['url' => $this->getUrl('factfinder/export/get', $params), 'label' => 'Get link'],\n ];\n }", "title": "" }, { "docid": "23dba2e79be0ef01830991b5c769bee5", "score": "0.5686782", "text": "function extractLinks($content) {\n\n // Get links:\n $list = $this->extractHyperLinks($content);\n\n if ($this->indexerConfig['useCrawlerForExternalFiles'] && t3lib_extMgm::isLoaded('crawler'))\t{\n $this->includeCrawlerClass();\n $crawler = t3lib_div::makeInstance('tx_crawler_lib');\n }\n\n // Traverse links:\n foreach($list as $linkInfo)\t{\n\n // Decode entities:\n if ($linkInfo['localPath'])\t{\t// localPath means: This file is sent by a download script. While the indexed URL has to point to $linkInfo['href'], the absolute path to the file is specified here!\n $linkSource = t3lib_div::htmlspecialchars_decode($linkInfo['localPath']);\n } else {\n $linkSource = t3lib_div::htmlspecialchars_decode($linkInfo['href']);\n }\n\n // Parse URL:\n $qParts = parse_url($linkSource);\n\n // Check for jumpurl (TYPO3 specific thing...)\n if ($qParts['query'] && strstr($qParts['query'],'jumpurl='))\t{\n parse_str($qParts['query'],$getP);\n $linkSource = $getP['jumpurl'];\n $qParts = parse_url($linkSource);\t// parse again due to new linkSource!\n }\n\n if (!$linkInfo['localPath'] && $qParts['scheme']) {\n if ($this->indexerConfig['indexExternalURLs'])\t{\n // Index external URL (http or otherwise)\n $this->indexExternalUrl($linkSource);\n }\n\n } elseif (strpos($qParts['query'],'ID=dam_frontend_push') == 1) {\n $this->indexDamDoc($linkInfo['href']);\n } elseif (!$qParts['query']) {\n $linkSource = urldecode($linkSource);\n if (t3lib_div::isAllowedAbsPath($linkSource))\t{\n $localFile = $linkSource;\n } else {\n $localFile = t3lib_div::getFileAbsFileName(PATH_site.$linkSource);\n }\n if ($localFile && @is_file($localFile))\t{\n\n // Index local file:\n if ($linkInfo['localPath'])\t{\n\n $fI = pathinfo($linkSource);\n $ext = strtolower($fI['extension']);\n if (is_object($crawler))\t{\n $params = array(\n 'document' => $linkSource,\n 'alturl' => $linkInfo['href'],\n 'conf' => $this->conf\n );\n unset($params['conf']['content']);\n\n $crawler->addQueueEntry_callBack(0,$params,'EXT:indexed_search/class.crawler.php:&tx_indexedsearch_files',$this->conf['id']);\n $this->log_setTSlogMessage('media \"'.$params['document'].'\" added to \"crawler\" queue.',1);\n } else {\n $this->indexRegularDocument($linkInfo['href'], FALSE, $linkSource, $ext);\n }\n } else {\n if (is_object($crawler))\t{\n $params = array(\n 'document' => $linkSource,\n 'conf' => $this->conf\n );\n unset($params['conf']['content']);\n $crawler->addQueueEntry_callBack(0,$params,'EXT:indexed_search/class.crawler.php:&tx_indexedsearch_files',$this->conf['id']);\n $this->log_setTSlogMessage('media \"'.$params['document'].'\" added to \"crawler\" queue.',1);\n } else {\n $this->indexRegularDocument($linkSource);\n }\n }\n }\n }\n }\n }", "title": "" }, { "docid": "c3e0e096cb558584ca5757213e6c7ba2", "score": "0.5680132", "text": "public function linkObjects($links) {\n $objs = [];\n foreach ($links as $link) {\n $objs[] = [\n \"title\" => $link['#title'],\n \"url\" => $link['#url']->toString(),\n ];\n }\n return $objs;\n }", "title": "" }, { "docid": "8d39f2a4e754b57d746a718ba6ecf4da", "score": "0.5680117", "text": "public function getLinksByIdentifier($id)\n {\n return Link::byId($id)->get();\n }", "title": "" }, { "docid": "cd8e8a29b877962f6e15d4a67e69cf10", "score": "0.56578475", "text": "function parse_links($str)\n\t\t\t\t{\n\t\t\t\t\t\t$str = str_replace('https://www.', 'https://', $str);\n\t\t\t\t\t\t$str = str_replace('http://www.', 'http://', $str);\n\t\t\t\t $str = str_replace('www.', 'http://', $str);\n\t\t\t\t $str = preg_replace('|http://([a-zA-Z0-9-./]+)|', '<a href=\"http://$1\">$1</a>', $str);\n\t\t\t\t\t\t$str = preg_replace('|https://([a-zA-Z0-9-./]+)|', '<a href=\"https://$1\">$1</a>', $str);\n\t\t\t\t $str = preg_replace('/(([a-z0-9+_-]+)(.[a-z0-9+_-]+)*@([a-z0-9-]+.)+[a-z]{2,6})/', '<a href=\"mailto:$1\">$1</a>', $str);\n\t\t\t\t return $str;\n\t\t\t\t}", "title": "" }, { "docid": "5acc408639c16f12cbf01a18e12852de", "score": "0.5656157", "text": "public function getLink(){\n return $this->getAttr('href');\n }", "title": "" }, { "docid": "2549b5de2d5749f57fcc9ab05ea5aab5", "score": "0.5650908", "text": "public function getHref(): string;", "title": "" } ]
81cf3737c85b3db208203c7da6eaf7cc
Add Weather data from microcontroller to database
[ { "docid": "45799871d931b124d9e93c9a1936b347", "score": "0.5627673", "text": "public function postWeather($waterTemp, $airTemp, $humidity, $address){\n\t\t$this->waterTemp = $waterTemp;\n\t\t$this->airTemp = $airTemp;\n\t\t$this->humidity = $humidity;\n\t\t$this->address = $address;\n\t\t\n\t\t$query = 'INSERT INTO `weather` (`id`, `dateTime`, `weaterTemp`, `airTemp`, `humidity`, `address`) VALUES (NULL, CURRENT_TIMESTAMP, ' . $this->waterTemp . ', ' . $this->airTemp . ', ' . $this->humidity . ', \"' . $this->address . '\")';\n\t\t$stmt = $this->conn->prepare($query);\n\t\t$stmt->execute();\n\t\t\n\t\treturn 'Success!<br>';\n\t}", "title": "" } ]
[ { "docid": "151550cd21c7f8affbafa6c0fbe888f1", "score": "0.6490342", "text": "public function run()\n {\n $data = array(\n array('name' => 'esp8266', 'created_at' => \\Carbon\\Carbon::now(), 'updated_at' => \\Carbon\\Carbon::now()),\n array('name' => '6l5528', 'created_at' => \\Carbon\\Carbon::now(), 'updated_at' => \\Carbon\\Carbon::now()),\n array('name' => 'lm393', 'created_at' => \\Carbon\\Carbon::now(), 'updated_at' => \\Carbon\\Carbon::now()),\n array('name' => 'soil', 'created_at' => \\Carbon\\Carbon::now(), 'updated_at' => \\Carbon\\Carbon::now()),\n array('name' => 'CO2', 'created_at' => \\Carbon\\Carbon::now(), 'updated_at' => \\Carbon\\Carbon::now()),\n array('name' => 'o2', 'created_at' => \\Carbon\\Carbon::now(), 'updated_at' => \\Carbon\\Carbon::now()),\n );\n\n DB::table('sensors')->insert($data);\n }", "title": "" }, { "docid": "096b079ebf6d2a3efd70e628c7de185c", "score": "0.6144891", "text": "public function addWeather($weather) {\n $sql = sprintf(\"INSERT INTO %s VALUES(null, ?,?,?,?,?,?,?,?) \", $this->getRepo());\n $stm = $this->db->prepare($sql);\n $stm->execute([$weather->city, $weather->country, $weather->temp, $weather->date_in,\n $weather->temp_min, $weather->temps_max, $weather->icon, $weather->usr_id]);\n\n if($stm->closeCursor()) {\n return findWeatherById($this->db->lastInsertId());\n }\n return null;\n }", "title": "" }, { "docid": "1e1c25b9de6c90e03800d6b3c87f5e76", "score": "0.6013851", "text": "function addToDatabase($data) {\n\t // dd($data);\n \\App\\Character::create([\n 'char' => $data['original'],\n 'simp_char' => $data['simplified_actual'],\n 'trad_char' => $data['traditional_actual'],\n 'freq' => $data['kFrequency'],\n 'stroke_count' => $data['kTotalStrokes'],\n 'radical' => $data['radical'],\n 'simp_radical' => $data['simplified_radical'],\n 'pinyin' => $data['pinyin'],\n 'pinyin_normalised' => $data['pinyin_normalised'],\n 'translations' => $data['kDefinition'],\n 'heisig_keyword' => $data['heisig_keyword'],\n 'heisig_number' => $data['heisig_number'],\n ]);\n\n }", "title": "" }, { "docid": "dd313e43133d4d809813b7e00165d1c1", "score": "0.57137495", "text": "public function storeData() {\n $attributes = implode(', ', array_keys($this->data));\n $values = ':' . implode(', :', array_keys($this->data));\n\n $query = $this->db->prepare(\"INSERT INTO track ($attributes) VALUES ($values)\");\n\n foreach ($this->data as $k => $v) {\n $query->bindValue(\":$k\", $v);\n }\n\n if (!$query->execute()) {\n echo 'This URL was not found';\n }\n }", "title": "" }, { "docid": "f8c28ea355c94ec224614fb85e9a2c2c", "score": "0.5626425", "text": "public function run()\n\t{\n\t\tWeather::unguard();\n Weather::create([\n 'id' => '1',\n 'name' => 'Sun',\n ]);\n Weather::create([\n 'id' => '2',\n 'name' => 'Rain',\n ]);\n Weather::create([\n 'id' => '3',\n 'name' => 'Fog',\n ]);\n\t\tWeather::reguard();\n $this->command->info('Weather table seeded!');\n\t}", "title": "" }, { "docid": "aa394b80f2cdee0cf1e58eca02c12b11", "score": "0.5592359", "text": "function Save()\n\t{\n\t\t$connection = Database::Connect();\n\t\t$this->pog_query = \"select `horarydataid` from `horarydata` where `horarydataid`='\".$this->horarydataId.\"' LIMIT 1\";\n\t\t$rows = Database::Query($this->pog_query, $connection);\n\t\tif ($rows > 0)\n\t\t{\n\t\t\t$this->pog_query = \"update `horarydata` set \n\t\t\t`day`='\".$this->Escape($this->day).\"', \n\t\t\t`month`='\".$this->Escape($this->month).\"', \n\t\t\t`year`='\".$this->Escape($this->year).\"', \n\t\t\t`hour`='\".$this->Escape($this->hour).\"', \n\t\t\t`minute`='\".$this->Escape($this->minute).\"', \n\t\t\t`gmt`='\".$this->Escape($this->gmt).\"', \n\t\t\t`zoneref`='\".$this->Escape($this->zoneref).\"', \n\t\t\t`summerref`='\".$this->Escape($this->summerref).\"', \n\t\t\t`place`='\".$this->Escape($this->place).\"', \n\t\t\t`state`='\".$this->Escape($this->state).\"', \n\t\t\t`longitude`='\".$this->Escape($this->longitude).\"', \n\t\t\t`latitude`='\".$this->Escape($this->latitude).\"', \n\t\t\t`orderid`='\".$this->Escape($this->orderid).\"' where `horarydataid`='\".$this->horarydataId.\"'\";\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->pog_query = \"insert into `horarydata` (`day`, `month`, `year`, `hour`, `minute`, `gmt`, `zoneref`, `summerref`, `place`, `state`, `longitude`, `latitude`, `orderid` ) values (\n\t\t\t'\".$this->Escape($this->day).\"', \n\t\t\t'\".$this->Escape($this->month).\"', \n\t\t\t'\".$this->Escape($this->year).\"', \n\t\t\t'\".$this->Escape($this->hour).\"', \n\t\t\t'\".$this->Escape($this->minute).\"', \n\t\t\t'\".$this->Escape($this->gmt).\"', \n\t\t\t'\".$this->Escape($this->zoneref).\"', \n\t\t\t'\".$this->Escape($this->summerref).\"', \n\t\t\t'\".$this->Escape($this->place).\"', \n\t\t\t'\".$this->Escape($this->state).\"', \n\t\t\t'\".$this->Escape($this->longitude).\"', \n\t\t\t'\".$this->Escape($this->latitude).\"', \n\t\t\t'\".$this->Escape($this->orderid).\"' )\";\n\t\t}\n\t\t$insertId = Database::InsertOrUpdate($this->pog_query, $connection);\n\t\tif ($this->horarydataId == \"\")\n\t\t{\n\t\t\t$this->horarydataId = $insertId;\n\t\t}\n\t\treturn $this->horarydataId;\n\t}", "title": "" }, { "docid": "bf32fd70e8e2e96d7c3b0065fd36a379", "score": "0.557635", "text": "private function getStationWeather($stationName){\n $data = $this->getFromAPI('forecast', array('station' => $stationName));\n \n if($data != null){\n if(isset($data['forecast']) && isset($data['forecast']['simpleforecast']) && isset($data['forecast']['simpleforecast']) && isset($data['forecast']['simpleforecast']['forecastday'])){\n $days = $data['forecast']['simpleforecast']['forecastday'];\n \n //add/update the days in the database\n $formatted = array();\n for($index = 0; $index < count($days); $index++){\n $date = $days[$index]['date']['day'].\"-\".$days[$index]['date']['month'].\"-\".$days[$index]['date']['year'];\n \n $stationID = $this->getStationID($stationName);\n \n if($stationID == null){\n $this->logHandler->log(1, $this->TAG, \"Unable to get station ID for station with name = '$stationName'. Unable to send data to user\");\n return null;\n }\n \n $currDay = array(\n \"station_id\" => $stationID,\n \"station_name\" => $stationName,\n \"date\" => $date,\n \"pop\" => $days[$index]['pop'],\n \"temp_high\" => $days[$index]['high']['celsius'],\n \"temp_low\" => $days[$index]['low']['celsius'],\n \"conditions\" => $days[$index]['conditions']\n );\n \n \n $query = \"insert into station_weather (station_id, date, pop, temp_high, temp_low, conditions)\"\n . \" values('{$stationID}', STR_TO_DATE('$date','%d-%m-%Y'), {$currDay['pop']}, {$currDay['temp_high']}, {$currDay['temp_low']}, '{$currDay['conditions']}')\"\n . \" on duplicate key update pop = {$currDay['pop']}, temp_high = {$currDay['temp_high']}, temp_low = {$currDay['temp_low']}, conditions = '{$currDay['conditions']}'\";\n $this->database->runMySQLQuery($query, false);\n \n $formatted[] = $currDay;\n if($index == 3) break;//do not add any weather forecast for days more than 3 from today\n }\n \n return $formatted;\n }\n else {\n $this->logHandler->log(1, $this->TAG, \"Data returned from the forecast API is mulformed. Sending nothing to the user\");\n }\n }\n \n return null;\n }", "title": "" }, { "docid": "92e89ed3ef81ee364b5e9cf863ef734a", "score": "0.5568506", "text": "function modbus_write_data_to_db($meter_id, $data, $timestamp, $debug = FALSE) {\r\n // Create a new raw-electricity entity.\r\n $values = array(\r\n 'type' => 'modbus',\r\n 'meter_nid' => $meter_id,\r\n 'timestamp' => $timestamp,\r\n 'rate_type' => 'unknown',\r\n 'frequency' => 5,\r\n 'kwh' => $data[2],\r\n 'power_factor' => $data[1],\r\n 'kwh_l1' => $data[3],\r\n 'kwh_l2' => $data[4],\r\n 'kwh_l3' => $data[5],\r\n 'power_factor_l1' => $data[6],\r\n 'power_factor_l2' => $data[7],\r\n 'power_factor_l3' => $data[8],\r\n );\r\n\r\n $entity = entity_create('electricity_raw', $values);\r\n\r\n drush_log('entity created', 'ok');\r\n drush_print_r($values);\r\n\r\n $result = $entity->save();\r\n\r\n if ($result != SAVED_NEW) {\r\n drush_log(format_string('entity->save() returned @val instead of 1 (SAVED_NEW).', array('@val' => $result)), 'error');\r\n return FALSE;\r\n }\r\n\r\n return TRUE;\r\n}", "title": "" }, { "docid": "8e232082dbfd2c9b077ff5d637dce7cd", "score": "0.55322546", "text": "private static function addToDatabase()\n {\n self::$order->address_id = self::$address->id;\n self::$order->user_id = self::$user->id;\n self::$order->order_date = Carbon::now()->format('Y-m-d h:i:s');\n self::$order->save();\n }", "title": "" }, { "docid": "969d156bacb9b6bbdd70b443a585db51", "score": "0.55286276", "text": "public function run()\n {\n DB::table(self::TABLE)->insert([\n 'country_id' => DictAddressCountriesAdapter::MEXICO,\n 'value' => 'Ciudad de México',\n ]);\n }", "title": "" }, { "docid": "cdbeff89ea9c183371d851ec58b0ef02", "score": "0.5516247", "text": "protected function write_dbase() {\n\t\t\n\t\t$db= $this->db;\n\t\t\n\t\t//prepare periodic query\n\t\t$query_insert=$query_insert_day='';\n\t\tif (!$this->code) {\n\t\t\tforeach ($this->datapoints as $label=> $datapoint) {\n\t\t\t\tif (!$datapoint->store) continue;\n\n\t\t\t\t$field= $db->quote($label);\n\t\t\t\t$value= $db->quote($datapoint->current_value);\n\n\t\t\t\tif ($datapoint->interval=='periodic') $query_insert.= \"`$field`= '$value',\\n\";\n\t\t\t\tif ($datapoint->interval=='day') $query_insert_day.= \"`$field`= '$value',\\n\";\n\t\t\t}\n\t\t}\n\t\t\n\t\t//write periodic\n\t\tif ($this->code or $query_insert) {\n\n\t\t\t$request= \"\n\t\t\t\tinsert into `:table` set\n\t\t\t\t$query_insert\n\t\t\t\tcode = ':code', \n\t\t\t\tdate_created= ':dtime'\n\t\t\t\";\t\n\t\t\t$params= array(\n\t\t\t\t'table'=> $this->settings['store_db_table'],\n\t\t\t\t'code'=> $this->code,\n\t\t\t\t'dtime'=> $this->datetime,\n\t\t\t);\n\t\t\t$db->query($request,$params) or codeerror('DB error',__FILE__,__LINE__);\n\t\t}\n\t\t\n\t\t//write day, keep overwriting current day til last one stands\n\t\tif ($query_insert_day) {\n\t\t\n\t\t\t$day= date(\"Y-m-d\", strtotime($this->datetime));\n\t\t\t\n\t\t\t$request= \"\n\t\t\t\tselect id from `:daytable` \n\t\t\t\twhere date_created= ':day'\n\t\t\t\";\t\n\t\t\t$params= array(\n\t\t\t\t'daytable'=> $this->settings['store_db_table_day'],\n\t\t\t\t'day'=> $day ,\n\t\t\t);\n\t\t\t$result= $db->query($request,$params) or codeerror('DB error',__FILE__,__LINE__);\n\t\t\tif (!$db->num_rows($result)) {\n\t\t\t\t$request= \"\n\t\t\t\t\tinsert into `:daytable` set\n\t\t\t\t\tdate_created= ':day'\n\t\t\t\t\";\t\n\t\t\t\t$params= array(\n\t\t\t\t\t'daytable'=> $this->settings['store_db_table_day'],\n\t\t\t\t\t'day'=> $day,\n\t\t\t\t);\n\t\t\t\t$db->query($request,$params) or codeerror('DB error',__FILE__,__LINE__);\n\t\t\t}\n\t\t\t$request= \"\n\t\t\t\tupdate `:daytable` set\n\t\t\t\t$query_insert_day\n\t\t\t\t`code`= '0'\n\t\t\t\twhere date_created= ':day'\n\t\t\t\";\t\n\t\t\t$params= array(\n\t\t\t\t'daytable'=> $this->settings['store_db_table_day'],\n\t\t\t\t'day'=> $day,\n\t\t\t);\n\t\t\t$db->query($request,$params) or codeerror('DB error',__FILE__,__LINE__);\n\t\t}\n\n\t\treturn true;\n\t}", "title": "" }, { "docid": "b253114bb8fd5202475a1df7c38371bd", "score": "0.5513011", "text": "public function run()\n {\n // 시리얼번호 dummy data\n $serialNumbers = [\n 'PFEJAF31T8UJ95', 'AHAPUF54T7BQ77', 'KGHPQB54T7OL41', 'VIPBI37R8SDQ65', 'KFCGOO88M4NB37',\n 'DECJA95H8U7G33', 'AEDJAF31T8FFF5', 'FREUSE31T8UJ95', 'LOLOFE31T8UJ92', 'KFEJASO1N8UJ10',\n 'GSTARN86T5GJ27', 'PIZAEF22F8DF98', 'PWOORF31T8UJ00', 'BEEVEE35A8UJ12', 'MIAUEE17T7UJ69',\n 'POGIAS05T7UJ64', 'HYAEN19T5KJO94', 'YONJMN22T5UJ49'\n ];\n // 시간 배열 -> addHours의 매개변수로 사용하기위해 현재 시에 값만큼 더한 값\n $hourArray =\n [\n 1, 2, 3, 4, 5,\n 6, 7, 1, 2, 3,\n 4, 5, 6, 7, 5,\n 5, 5, 3];\n // $serialNumbers 배열의 길이만큼 반복\n for ($i = 0; $i < count($serialNumbers); $i++) {\n\n // 아두이노 정보 테이블에 시리얼번호 insert\n DB::table('arduino_info')->insert(\n [\n 'serial_num' => $serialNumbers[$i],\n 'registered_date' => Carbon::now()->addHour($hourArray[$i])->format('Y-m-d H:i:s'),\n ]\n );\n }\n }", "title": "" }, { "docid": "da2c6809f7f34ec9e27f7d363a951c5a", "score": "0.5507824", "text": "public function run()\n {\n $dateTime = Carbon::now('America/Toronto')->format('Y-m-d H:i');\n DB::table('external_parameters')->insert([\n 'email' => 'theophile.lafage-facilitator-1@isep.fr',\n 'created_at' => $dateTime,\n 'updated_at' => $dateTime,\n ]);\n }", "title": "" }, { "docid": "c884e40d0a64894a66c62ee3171632aa", "score": "0.5505226", "text": "public function insertData()\n\t{\n\t\t$mytime = Carbon\\Carbon::now();\n\t\t//database selection\n\t\t$database = \"\";\n\t\t$constantDatabase = new ConstantClass();\n\t\t$databaseName = $constantDatabase->constantDatabase();\n\t\t\n\t\t$constantArray = $constantDatabase->constantVariable();\n\t\t\n\t\t$getCompanyData = array();\n\t\t$getCompanyKey = array();\n\t\t$getCompanyData = func_get_arg(0);\n\t\t$getCompanyKey = func_get_arg(1);\n\t\t$companyData=\"\";\n\t\t$keyName = \"\";\n\t\tfor($data=0;$data<count($getCompanyData);$data++)\n\t\t{\n\t\t\tif($data == (count($getCompanyData)-1))\n\t\t\t{\n\t\t\t\t$companyData = $companyData.\"'\".$getCompanyData[$data].\"'\";\n\t\t\t\t$keyName =$keyName.$getCompanyKey[$data];\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$companyData = $companyData.\"'\".$getCompanyData[$data].\"',\";\n\t\t\t\t$keyName =$keyName.$getCompanyKey[$data].\",\";\n\t\t\t}\n\t\t}\n\t\tDB::beginTransaction();\n\t\t$raw = DB::connection($databaseName)->statement(\"insert into company_mst(\".$keyName.\",created_at) \n\t\tvalues(\".$companyData.\",'\".$mytime.\"')\");\n\t\tDB::commit();\n\t\t\n\t\t//get latest company_id\n\t\tDB::beginTransaction();\n\t\t$latestCompanyId = DB::connection($databaseName)->select(\"SELECT \n\t\tcompany_id,\n\t\tcompany_name,\n\t\tstate_abb,\n\t\tcity_id\n\t\tFROM `company_mst` \n\t\twhere deleted_at='0000-00-00 00:00:00'\n \tORDER by company_id DESC limit 1\");\n\t\tDB::commit();\n\t\t\n\t\t// get exception message\n\t\t$exception = new ExceptionMessage();\n\t\t$exceptionArray = $exception->messageArrays();\n\t\tif($raw==1)\n\t\t{\n\t\t\tDB::beginTransaction();\n\t\t\t$branchInsertion = DB::connection($databaseName)->statement(\"INSERT \n\t\t\tinto branch_mst(\n\t\t\tbranch_name,\n\t\t\taddress1,\n\t\t\taddress2,\n\t\t\tpincode, \n\t\t\tis_display, \n\t\t\tis_default,\n\t\t\tcreated_at,\n\t\t\tupdated_at,\n\t\t\tdeleted_at,\n\t\t\tstate_abb,\n\t\t\tcity_id, \n\t\t\tcompany_id)\n\t\t\tVALUES(\n\t\t\t'MainBranch',\n\t\t\t'address1',\n\t\t\t'address2', \n\t\t\t'395000', \n\t\t\t'yes',\n\t\t\t'not',\n\t\t\t'\".$mytime.\"',\n\t\t\t'0000-00-00 00:00:00',\n\t\t\t'0000-00-00 00:00:00',\n\t\t\t'\".$latestCompanyId[0]->state_abb.\"',\n\t\t\t'\".$latestCompanyId[0]->city_id.\"', \n\t\t\t'\".$latestCompanyId[0]->company_id.\"')\n\t\t\t\");\n\t\t\tDB::commit();\n\n\t\t\t$templateInsertionResult = $this->templateInsertion($latestCompanyId[0]->company_name,$latestCompanyId[0]->company_id);\n\t\t\tif(strcmp($templateInsertionResult,$exceptionArray['500'])==0)\n\t\t\t{\n\t\t\t\treturn $exceptionArray['500'];\n\t\t\t}\n\t\t\t\n\t\t\t// DB::beginTransaction();\n\t\t\t// $companyId = DB::connection($databaseName)->select(\"select\n\t\t\t// max(company_id) as company_id \n\t\t\t// from company_mst where deleted_at='0000-00-00 00:00:00'\");\n\t\t\t// DB::commit();\n\t\t\treturn $latestCompanyId;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn $exceptionArray['500'];\n\t\t}\n\t}", "title": "" }, { "docid": "a7872763b93478004998d58777cec738", "score": "0.54547215", "text": "public function run()\n {\n $data = $this->airportDataProvider->getAirportData();\n\n DB::table('airports')->insert($data);\n }", "title": "" }, { "docid": "523d44df3b5d9a4755fe21cb1f74eabe", "score": "0.54524475", "text": "public function run()\n {\n DB::table('sensor_types')->insert([\n 'slug' => 'temperature',\n 'name' => 'Celsius',\n 'unit' => '°C',\n 'created_at' => Carbon::now()->toDateTimeString(),\n 'updated_at' => Carbon::now()->toDateTimeString()\n ]);\n DB::table('sensor_types')->insert([\n 'slug' => 'humidity',\n 'name' => 'Humidity',\n 'unit' => '%',\n 'created_at' => Carbon::now()->toDateTimeString(),\n 'updated_at' => Carbon::now()->toDateTimeString()\n ]);\n DB::table('sensor_types')->insert([\n 'slug' => 'pressure',\n 'name' => 'Pressure',\n 'unit' => 'mbar',\n 'created_at' => Carbon::now()->toDateTimeString(),\n 'updated_at' => Carbon::now()->toDateTimeString()\n ]);\n }", "title": "" }, { "docid": "d142892e951dc4abc3b378daef76ec2b", "score": "0.5449207", "text": "public function run()\n {\n $data = \n [\n [ \n 'materialname' => 'hot',\n 'materialprice' => 0,\n ],\n\n [ \n 'materialname' => 'cold',\n 'materialprice' => 5,\n ],\n \n [ \n 'materialname' => 'spin',\n 'materialprice' => 10,\n ],\n\n [ \n 'materialname' => 'Whipped cream',\n 'materialprice' => 15,\n ],\n ];\n\n \\App\\material::insert($data);\n\n }", "title": "" }, { "docid": "fd2c88d186f47e6cd28973381b3b546c", "score": "0.54312164", "text": "public function run()\n {\n DB::table('warehouse')->insert(array(\n [\n 'name' => 'zona 51',\n 'headName' => 'John Smith',\n 'phone' => '153',\n 'address' => 'пустыня Сахара, где-то посередине, №1'\n ]\n ));\n }", "title": "" }, { "docid": "071663f78122f7dc17ebe6a3a8ec4502", "score": "0.54180294", "text": "public function run()\n {\n $jsonData = json_decode(file_get_contents(__DIR__ . '/master_country_data.json'), true);\n foreach($jsonData as $data){\n //dd($data['country_code']);\n MasterData::create([\n 'country_code' => (!empty($data['country_code'])) ? $data['country_code'] : '',\n 'country_name' => (!empty($data['country_name'])) ? $data['country_name'] : '',\n 'country_data' => (!empty($data['country_data'])) ? $data['country_data'] : '',\n ]);\n }\n }", "title": "" }, { "docid": "93954f00ca3e4cd5f35b3b38f1bb172d", "score": "0.5413267", "text": "public function run()\n {\n DB::table('api_maphim')->insert(\n [\n [\n 'created_at' =>new DateTime()\n ]\n ]\n );\n }", "title": "" }, { "docid": "876be7e5e5efc8d08c99238140451796", "score": "0.54108864", "text": "public function run()\n {\n DB::table('country')->insert([\n ['id' => '1', 'name' => 'New Zealand', 'flag' => 'NZ flag']\n ]);\n }", "title": "" }, { "docid": "31712122ec1eee396b0c37e629e31adf", "score": "0.5392297", "text": "public function run()\n {\n $item = [\n [\n 'lookup' => 'IT1',\n 'code' => 'ITM01',\n 'fulltitle' => 'LOW COST',\n 'fulldesc' => 'LOW COST',\n ],\n ];\n\n \n DB::table('lookups')->insert($item);\n\n }", "title": "" }, { "docid": "9c2ac5c063a269565afeb3bf224d73c6", "score": "0.5387835", "text": "public function run()\n {\n DB::table('carriers')->insert([\n [\n\t \t'type' => 'COD',\n\t \t'to' => 'JAKARTA SELATAN',\n\t \t'price' => '200000',\n\t \t'name' => null,\n\t \t'api' => null,\n\t \t'status' => 'on',\n\t\t\t\t'created_at' => date(\"Y-m-d H:i:s\"),\n 'updated_at' => date(\"Y-m-d H:i:s\")\n ],\n [\n\t \t'type' => 'Courier',\n\t \t'to' => null,\n\t \t'price' => null,\n\t \t'name' => 'JNE',\n\t \t'api' => 'your-api-key',\n\t \t'status' => 'on',\n\t\t\t\t'created_at' => date(\"Y-m-d H:i:s\"),\n 'updated_at' => date(\"Y-m-d H:i:s\")\n ],\n\t\t]);\n }", "title": "" }, { "docid": "a8991ac5eae0d4b3e3d9176b408a60e7", "score": "0.5384959", "text": "public static function add()\n {\n $query = new Query();\n $cities = City::find()->limit(10000)->offset(0)->all(); // NOTE: increase offset for every limit\n /** @var City $city */\n foreach ($cities as $city) {\n $data = [\n 'id' => $city->id,\n 'name' => $city->name,\n 'ansi_name' => $city->ansi_name,\n 'alt_name' => $city->alt_name,\n 'location' => [\n 'lat' => $city->latitude,\n 'lon' => $city->longitude,\n ],\n 'country_code' => $city->country_code,\n 'population' => $city->population,\n 'popularity' => 0,\n 'directions' => [],\n ];\n $query->createCommand()->insert(self::INDEX, self::TYPE, $data, $city->id);\n }\n }", "title": "" }, { "docid": "93aaf815292d9498a001d50c58768c16", "score": "0.5381441", "text": "function addDevice($device){\n\n global $device_db;\n\n //Open MySQL Connection inorder to get last data point for a device.\n $database = sql_dmca();\n\n $device = arrayEscape($device, $database);\n\n $device_info['statement'] = \"INSERT INTO $device_db\n \t\t\t\t\t\t\t\t( \tbuilding,\n\t\t\t\t\t\t\t\t\troom,\n\t\t\t\t\t\t\t\t\tcoord_x,\n\t\t\t\t\t\t\t\t\tcoord_y,\n\t\t\t\t\t\t\t\t\tcoord_z,\n\t\t\t\t\t\t\t\t\tip_address,\n\t\t\t\t\t\t\t\t\tpassword\t)\n\t\t\t\t\t\t\t\tVALUES\n\t\t\t\t\t\t\t\t(\t'$device[building]',\n\t\t\t\t\t\t\t\t\t'$device[room]',\n\t\t\t\t\t\t\t\t\t'$device[coord_x]',\n\t\t\t\t\t\t\t\t\t'$device[coord_y]',\n\t\t\t\t\t\t\t\t\t'$device[coord_z]',\n\t\t\t\t\t\t\t\t\t'$device[ip_address]',\n\t\t\t\t\t\t\t\t\t'$device[password]'\t)\";\t\t\t\t\t\t\t\t\n\n $device_info['info'] = $database->query($device_info['statement']);\n $device_info['error'] = $database->error;\n if($device_info['error']){\n \t\t\n \t$device_info['results'] = \"Device Insertion Error\";\n }\n else{\n\t$device_info['results'] = \"Device Insertion Success\";\n }\n\n $database->close();\n\n return $device_info;\n\t\n}", "title": "" }, { "docid": "a60fd45a131ecc7f6329ee3ae11fe5fd", "score": "0.5377233", "text": "public function run()\n {\n\n $data = [\n [\n \"id\" => \"S0001\",\n \"serialNumber\" => \"T0001\",\n \"type\" => \"buy\",\n \"datetime\" => \"2021-06-18\",\n \n ],\n ];\n \\DB::table('transaction')->insert($data);\n }", "title": "" }, { "docid": "ad5f2a8c93f809c3e3447cc8fe08560a", "score": "0.5374176", "text": "public function saveToDB()\n\t{\t$con = db_connect();\n\t\t\n\t\t$statement = $con->prepare('Insert into location (lat,lon,radius) values (?,?,?)');\n\t\t$statement->execute(array($this->lat,$this->lon,$this->accu));\n\t\t\n\t\t$this->locationID = $con->lastInsertId();\n\t\t$con = null;\n\t}", "title": "" }, { "docid": "9284512cc071ebf328091adc891d596a", "score": "0.5369068", "text": "public function run()\n {\n DB::table('hotels')->insert([\n 'name' => '西溪八方城',\n 'name_english' => 'XixiBaFangCity',\n 'address' => '浙江 杭州 钱塘江',\n 'time' => date('Ymd'),\n 'created_at' => date('Y-m-d H:i:s')\n ]);\n }", "title": "" }, { "docid": "a2db9c7b1c14cffe1305ae1edff7b507", "score": "0.5360786", "text": "public function run()\n {\n \\DB::table('business_hours')->insert([\n 'time_zone' => 'Asia/Manila',\n 'open_time' => '05:00:00',\n 'close_time' => '12:00:00',\n 'valid' => 1\n ]);\n }", "title": "" }, { "docid": "d373b66e59157af4830d1ca365418db6", "score": "0.53570163", "text": "public function run()\n {\n $data = [\n [\n 'uuid' => 'DEVICE_1',\n 'device_type_id' => DeviceType::first()->id,\n 'store_id' => Store::first()->id,\n 'created_at' => Carbon\\Carbon::create(),\n 'updated_at' => Carbon\\Carbon::create()\n ]\n ];\n\n Device::insert($data);\n }", "title": "" }, { "docid": "ae0cdc60857a265cb24a80336fac7aef", "score": "0.5331378", "text": "public function run()\n {\n DB::table('sat_monedas')->insert(['codigo_moneda' => 'MXN', 'descripcion' => 'Peso Mexicano', 'decimales' => '2']);\n }", "title": "" }, { "docid": "b160ce61a9b686ddfd99e0d72afef145", "score": "0.5324834", "text": "public function insert($powerBaseStationAnalysi);", "title": "" }, { "docid": "c33aa18ed5b1feabd8e5331021e8bfa2", "score": "0.5322468", "text": "public function run()\n {\n \n\n \\DB::table('bms_data')->delete();\n \n \\DB::table('bms_data')->insert(array (\n 0 => \n array (\n 'id' => 1,\n 'bms_id' => 2,\n 'soc' => 33.189999999999998,\n 'soh' => 37,\n 'vol' => 87.180000000000007,\n 'res' => 1086.8,\n 'longitude' => -139.78999999999999,\n 'latitude' => 238.06999999999999,\n 'altitude' => 67.010000000000005,\n 'speed' => 65.400000000000006,\n 'locate_mode' => 3,\n 'satellite' => 4,\n 'temp' => 26.039999999999999,\n 'current' => 0.94999999999999996,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 1 => \n array (\n 'id' => 2,\n 'bms_id' => 5,\n 'soc' => 53.43,\n 'soh' => 43,\n 'vol' => 110.22,\n 'res' => 654.41999999999996,\n 'longitude' => 105.84,\n 'latitude' => 294.36000000000001,\n 'altitude' => 61.890000000000001,\n 'speed' => 10.84,\n 'locate_mode' => 3,\n 'satellite' => 12,\n 'temp' => 24.800000000000001,\n 'current' => 2.29,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 2 => \n array (\n 'id' => 3,\n 'bms_id' => 5,\n 'soc' => 10.880000000000001,\n 'soh' => 36,\n 'vol' => 148.13999999999999,\n 'res' => 1144.02,\n 'longitude' => 95.069999999999993,\n 'latitude' => 218.59999999999999,\n 'altitude' => 37.960000000000001,\n 'speed' => 27.41,\n 'locate_mode' => 3,\n 'satellite' => 4,\n 'temp' => -4.9500000000000002,\n 'current' => 1.3900000000000001,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 3 => \n array (\n 'id' => 4,\n 'bms_id' => 1,\n 'soc' => 82.049999999999997,\n 'soh' => 58,\n 'vol' => 35.280000000000001,\n 'res' => 1397.5999999999999,\n 'longitude' => 144.06,\n 'latitude' => 185.99000000000001,\n 'altitude' => 19.079999999999998,\n 'speed' => 39.740000000000002,\n 'locate_mode' => 3,\n 'satellite' => 11,\n 'temp' => -0.030000000000000027,\n 'current' => 2.7000000000000002,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 4 => \n array (\n 'id' => 5,\n 'bms_id' => 9,\n 'soc' => 29.41,\n 'soh' => 57,\n 'vol' => 106.69,\n 'res' => 1549.76,\n 'longitude' => 64.400000000000006,\n 'latitude' => 316.19,\n 'altitude' => 47.060000000000002,\n 'speed' => 20.059999999999999,\n 'locate_mode' => 1,\n 'satellite' => 4,\n 'temp' => 2.8799999999999999,\n 'current' => 3.3999999999999999,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 5 => \n array (\n 'id' => 6,\n 'bms_id' => 3,\n 'soc' => 54.030000000000001,\n 'soh' => 9,\n 'vol' => 27.800000000000001,\n 'res' => 130.44,\n 'longitude' => 93.349999999999994,\n 'latitude' => 350.26999999999998,\n 'altitude' => 64.230000000000004,\n 'speed' => 51.229999999999997,\n 'locate_mode' => 3,\n 'satellite' => 11,\n 'temp' => 9.7799999999999994,\n 'current' => 0.97999999999999998,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 6 => \n array (\n 'id' => 7,\n 'bms_id' => 6,\n 'soc' => 4.6200000000000001,\n 'soh' => 77,\n 'vol' => 184.19999999999999,\n 'res' => 661.82000000000005,\n 'longitude' => -167,\n 'latitude' => 223.91999999999999,\n 'altitude' => 199.06999999999999,\n 'speed' => 45.289999999999999,\n 'locate_mode' => 1,\n 'satellite' => 6,\n 'temp' => -8.5700000000000003,\n 'current' => 0.95999999999999996,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 7 => \n array (\n 'id' => 8,\n 'bms_id' => 2,\n 'soc' => 36.380000000000003,\n 'soh' => 70,\n 'vol' => 24.449999999999999,\n 'res' => 829.80999999999995,\n 'longitude' => -104.26000000000001,\n 'latitude' => 21.18,\n 'altitude' => 172.71000000000001,\n 'speed' => 29.440000000000001,\n 'locate_mode' => 3,\n 'satellite' => 11,\n 'temp' => 26.210000000000001,\n 'current' => 0.64000000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 8 => \n array (\n 'id' => 9,\n 'bms_id' => 10,\n 'soc' => 53.600000000000001,\n 'soh' => 32,\n 'vol' => 2.4699999999999998,\n 'res' => 434,\n 'longitude' => -133.37,\n 'latitude' => 175.18000000000001,\n 'altitude' => 17.620000000000001,\n 'speed' => 38.5,\n 'locate_mode' => 3,\n 'satellite' => 7,\n 'temp' => 1.1000000000000001,\n 'current' => 4.0300000000000002,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 9 => \n array (\n 'id' => 10,\n 'bms_id' => 10,\n 'soc' => 62.340000000000003,\n 'soh' => 74,\n 'vol' => 133.43000000000001,\n 'res' => 732.67999999999995,\n 'longitude' => -139.31999999999999,\n 'latitude' => 177.38,\n 'altitude' => 113.25,\n 'speed' => 8.7599999999999998,\n 'locate_mode' => 3,\n 'satellite' => 8,\n 'temp' => 21.050000000000001,\n 'current' => 0.34000000000000002,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 10 => \n array (\n 'id' => 11,\n 'bms_id' => 8,\n 'soc' => 26.670000000000002,\n 'soh' => 80,\n 'vol' => 130.78,\n 'res' => 746.65999999999997,\n 'longitude' => -72.890000000000001,\n 'latitude' => 12.07,\n 'altitude' => 17.859999999999999,\n 'speed' => 34.479999999999997,\n 'locate_mode' => 3,\n 'satellite' => 8,\n 'temp' => 18.07,\n 'current' => 3,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 11 => \n array (\n 'id' => 12,\n 'bms_id' => 9,\n 'soc' => 35,\n 'soh' => 84,\n 'vol' => 121.97,\n 'res' => 1793.54,\n 'longitude' => -117.39,\n 'latitude' => 327.35000000000002,\n 'altitude' => 134.59,\n 'speed' => 3.1800000000000002,\n 'locate_mode' => 3,\n 'satellite' => 8,\n 'temp' => 8.2899999999999991,\n 'current' => 3.6299999999999999,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 12 => \n array (\n 'id' => 13,\n 'bms_id' => 1,\n 'soc' => 86.349999999999994,\n 'soh' => 90,\n 'vol' => 142.25,\n 'res' => 911.58000000000004,\n 'longitude' => 87.079999999999998,\n 'latitude' => 4.7000000000000002,\n 'altitude' => 60.32,\n 'speed' => 83.390000000000001,\n 'locate_mode' => 2,\n 'satellite' => 7,\n 'temp' => -4.3100000000000005,\n 'current' => 4.2400000000000002,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 13 => \n array (\n 'id' => 14,\n 'bms_id' => 2,\n 'soc' => 21.170000000000002,\n 'soh' => 18,\n 'vol' => 178.16,\n 'res' => 649.26999999999998,\n 'longitude' => 5.4400000000000004,\n 'latitude' => 21.66,\n 'altitude' => 43.82,\n 'speed' => 88.819999999999993,\n 'locate_mode' => 2,\n 'satellite' => 9,\n 'temp' => 27.68,\n 'current' => 0.45000000000000001,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 14 => \n array (\n 'id' => 15,\n 'bms_id' => 7,\n 'soc' => 28.739999999999998,\n 'soh' => 6,\n 'vol' => 170.34999999999999,\n 'res' => 1563.4300000000001,\n 'longitude' => -60.020000000000003,\n 'latitude' => 254.97999999999999,\n 'altitude' => 54.240000000000002,\n 'speed' => 85.540000000000006,\n 'locate_mode' => 3,\n 'satellite' => 11,\n 'temp' => 21.699999999999999,\n 'current' => 3.1299999999999999,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 15 => \n array (\n 'id' => 16,\n 'bms_id' => 10,\n 'soc' => 19.27,\n 'soh' => 76,\n 'vol' => 92.299999999999997,\n 'res' => 360.94,\n 'longitude' => -3.0300000000000002,\n 'latitude' => 188.78,\n 'altitude' => 19.48,\n 'speed' => 29.489999999999998,\n 'locate_mode' => 1,\n 'satellite' => 12,\n 'temp' => 8.5700000000000003,\n 'current' => 3.29,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 16 => \n array (\n 'id' => 17,\n 'bms_id' => 10,\n 'soc' => 4.7800000000000002,\n 'soh' => 15,\n 'vol' => 7.7699999999999996,\n 'res' => 917.66999999999996,\n 'longitude' => -62.219999999999999,\n 'latitude' => 112.23999999999999,\n 'altitude' => 29.16,\n 'speed' => 56.460000000000001,\n 'locate_mode' => 3,\n 'satellite' => 11,\n 'temp' => 26.879999999999999,\n 'current' => 0.22,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 17 => \n array (\n 'id' => 18,\n 'bms_id' => 9,\n 'soc' => 92.230000000000004,\n 'soh' => 84,\n 'vol' => 51.890000000000001,\n 'res' => 1133.3299999999999,\n 'longitude' => -52.450000000000003,\n 'latitude' => 278.29000000000002,\n 'altitude' => 184.68000000000001,\n 'speed' => 19.420000000000002,\n 'locate_mode' => 2,\n 'satellite' => 6,\n 'temp' => 18.940000000000001,\n 'current' => 4.0999999999999996,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 18 => \n array (\n 'id' => 19,\n 'bms_id' => 10,\n 'soc' => 11.949999999999999,\n 'soh' => 68,\n 'vol' => 70.819999999999993,\n 'res' => 363.01999999999998,\n 'longitude' => -73.519999999999996,\n 'latitude' => 67.239999999999995,\n 'altitude' => 134.78,\n 'speed' => 1.8799999999999999,\n 'locate_mode' => 1,\n 'satellite' => 9,\n 'temp' => 11.56,\n 'current' => 0.63,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 19 => \n array (\n 'id' => 20,\n 'bms_id' => 4,\n 'soc' => 73.409999999999997,\n 'soh' => 75,\n 'vol' => 105.48,\n 'res' => 831.66999999999996,\n 'longitude' => 60.560000000000002,\n 'latitude' => 268.50999999999999,\n 'altitude' => 36.159999999999997,\n 'speed' => 66.519999999999996,\n 'locate_mode' => 3,\n 'satellite' => 8,\n 'temp' => 4.9199999999999999,\n 'current' => 0.55000000000000004,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 20 => \n array (\n 'id' => 21,\n 'bms_id' => 10,\n 'soc' => 49.030000000000001,\n 'soh' => 86,\n 'vol' => 108.92,\n 'res' => 613.57000000000005,\n 'longitude' => 93.280000000000001,\n 'latitude' => 107.84,\n 'altitude' => 0.85999999999999999,\n 'speed' => 30.98,\n 'locate_mode' => 1,\n 'satellite' => 5,\n 'temp' => 2.21,\n 'current' => 4.8799999999999999,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 21 => \n array (\n 'id' => 22,\n 'bms_id' => 5,\n 'soc' => 93.599999999999994,\n 'soh' => 22,\n 'vol' => 58.649999999999999,\n 'res' => 994.10000000000002,\n 'longitude' => -139.78999999999999,\n 'latitude' => 97.200000000000003,\n 'altitude' => 70.140000000000001,\n 'speed' => 19.219999999999999,\n 'locate_mode' => 3,\n 'satellite' => 6,\n 'temp' => 22.469999999999999,\n 'current' => 4.9000000000000004,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 22 => \n array (\n 'id' => 23,\n 'bms_id' => 5,\n 'soc' => 38.840000000000003,\n 'soh' => 39,\n 'vol' => 112.67,\n 'res' => 1049.47,\n 'longitude' => -136,\n 'latitude' => 76.5,\n 'altitude' => 189.90000000000001,\n 'speed' => 68.239999999999995,\n 'locate_mode' => 2,\n 'satellite' => 7,\n 'temp' => 22.649999999999999,\n 'current' => 2.3700000000000001,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 23 => \n array (\n 'id' => 24,\n 'bms_id' => 8,\n 'soc' => 28.190000000000001,\n 'soh' => 1,\n 'vol' => 155.44999999999999,\n 'res' => 389.00999999999999,\n 'longitude' => -11.5,\n 'latitude' => 311.56,\n 'altitude' => 119.14,\n 'speed' => 9.4900000000000002,\n 'locate_mode' => 1,\n 'satellite' => 6,\n 'temp' => 0.95999999999999996,\n 'current' => 0.28000000000000003,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 24 => \n array (\n 'id' => 25,\n 'bms_id' => 3,\n 'soc' => 64.920000000000002,\n 'soh' => 12,\n 'vol' => 2.8100000000000001,\n 'res' => 822.94000000000005,\n 'longitude' => -65.540000000000006,\n 'latitude' => 128.94999999999999,\n 'altitude' => 109.01000000000001,\n 'speed' => 24.920000000000002,\n 'locate_mode' => 2,\n 'satellite' => 6,\n 'temp' => -2.4199999999999999,\n 'current' => 3.1499999999999999,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 25 => \n array (\n 'id' => 26,\n 'bms_id' => 9,\n 'soc' => 47.460000000000001,\n 'soh' => 87,\n 'vol' => 36.450000000000003,\n 'res' => 1591.9100000000001,\n 'longitude' => 93.560000000000002,\n 'latitude' => 187.81999999999999,\n 'altitude' => 89.540000000000006,\n 'speed' => 12.23,\n 'locate_mode' => 1,\n 'satellite' => 9,\n 'temp' => 22.609999999999999,\n 'current' => 2.8500000000000001,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 26 => \n array (\n 'id' => 27,\n 'bms_id' => 5,\n 'soc' => 6.7999999999999998,\n 'soh' => 18,\n 'vol' => 90.599999999999994,\n 'res' => 1913.8599999999999,\n 'longitude' => 75.099999999999994,\n 'latitude' => 127.58,\n 'altitude' => 28.109999999999999,\n 'speed' => 49.990000000000002,\n 'locate_mode' => 3,\n 'satellite' => 12,\n 'temp' => -4.0300000000000002,\n 'current' => 4.7699999999999996,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 27 => \n array (\n 'id' => 28,\n 'bms_id' => 1,\n 'soc' => 50.719999999999999,\n 'soh' => 58,\n 'vol' => 125.88,\n 'res' => 1374.71,\n 'longitude' => -140.30000000000001,\n 'latitude' => 25.140000000000001,\n 'altitude' => 194.72,\n 'speed' => 16.879999999999999,\n 'locate_mode' => 2,\n 'satellite' => 5,\n 'temp' => 5.8300000000000001,\n 'current' => 2.4300000000000002,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 28 => \n array (\n 'id' => 29,\n 'bms_id' => 1,\n 'soc' => 57.299999999999997,\n 'soh' => 63,\n 'vol' => 31.170000000000002,\n 'res' => 1290.1900000000001,\n 'longitude' => 23.18,\n 'latitude' => 113.34999999999999,\n 'altitude' => 125.33,\n 'speed' => 10.02,\n 'locate_mode' => 3,\n 'satellite' => 7,\n 'temp' => 2.52,\n 'current' => 1.3400000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 29 => \n array (\n 'id' => 30,\n 'bms_id' => 7,\n 'soc' => 12.699999999999999,\n 'soh' => 8,\n 'vol' => 2.79,\n 'res' => 1130.9000000000001,\n 'longitude' => 114.56999999999999,\n 'latitude' => 51.079999999999998,\n 'altitude' => 12.98,\n 'speed' => 52.219999999999999,\n 'locate_mode' => 3,\n 'satellite' => 4,\n 'temp' => 6.7199999999999998,\n 'current' => 0.34999999999999998,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 30 => \n array (\n 'id' => 31,\n 'bms_id' => 7,\n 'soc' => 45.140000000000001,\n 'soh' => 25,\n 'vol' => 176.75,\n 'res' => 1430.49,\n 'longitude' => 123.95999999999999,\n 'latitude' => 187.16,\n 'altitude' => 110.34,\n 'speed' => 52.850000000000001,\n 'locate_mode' => 2,\n 'satellite' => 12,\n 'temp' => -6.3799999999999999,\n 'current' => 3.8799999999999999,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 31 => \n array (\n 'id' => 32,\n 'bms_id' => 5,\n 'soc' => 15.94,\n 'soh' => 91,\n 'vol' => 6.9900000000000002,\n 'res' => 422.11000000000001,\n 'longitude' => -45.710000000000001,\n 'latitude' => 157.09,\n 'altitude' => 125.56999999999999,\n 'speed' => 94.319999999999993,\n 'locate_mode' => 1,\n 'satellite' => 6,\n 'temp' => 6.8700000000000001,\n 'current' => 3.2000000000000002,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 32 => \n array (\n 'id' => 33,\n 'bms_id' => 10,\n 'soc' => 12.800000000000001,\n 'soh' => 90,\n 'vol' => 69.079999999999998,\n 'res' => 1493.5,\n 'longitude' => 142.71000000000001,\n 'latitude' => 1.8599999999999999,\n 'altitude' => 80.540000000000006,\n 'speed' => 15.35,\n 'locate_mode' => 1,\n 'satellite' => 11,\n 'temp' => -3.3999999999999999,\n 'current' => 0.42999999999999999,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 33 => \n array (\n 'id' => 34,\n 'bms_id' => 3,\n 'soc' => 32.07,\n 'soh' => 58,\n 'vol' => 139.31999999999999,\n 'res' => 799.54999999999995,\n 'longitude' => 24.609999999999999,\n 'latitude' => 230.53,\n 'altitude' => 191.97999999999999,\n 'speed' => 47.68,\n 'locate_mode' => 3,\n 'satellite' => 9,\n 'temp' => 11.630000000000001,\n 'current' => 0.57999999999999996,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 34 => \n array (\n 'id' => 35,\n 'bms_id' => 6,\n 'soc' => 24.670000000000002,\n 'soh' => 60,\n 'vol' => 37.719999999999999,\n 'res' => 1434.24,\n 'longitude' => -23.890000000000001,\n 'latitude' => 38,\n 'altitude' => 54.149999999999999,\n 'speed' => 86.549999999999997,\n 'locate_mode' => 2,\n 'satellite' => 4,\n 'temp' => 1.1899999999999999,\n 'current' => 0.57999999999999996,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 35 => \n array (\n 'id' => 36,\n 'bms_id' => 3,\n 'soc' => 94.870000000000005,\n 'soh' => 25,\n 'vol' => 119.7,\n 'res' => 1870.0799999999999,\n 'longitude' => 126.90000000000001,\n 'latitude' => 62.990000000000002,\n 'altitude' => 12.550000000000001,\n 'speed' => 46.57,\n 'locate_mode' => 3,\n 'satellite' => 11,\n 'temp' => 9.3200000000000003,\n 'current' => 4.0099999999999998,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 36 => \n array (\n 'id' => 37,\n 'bms_id' => 6,\n 'soc' => 5.3899999999999997,\n 'soh' => 64,\n 'vol' => 28.469999999999999,\n 'res' => 693.76999999999998,\n 'longitude' => -139.78999999999999,\n 'latitude' => 104.90000000000001,\n 'altitude' => 192.03,\n 'speed' => 30.620000000000001,\n 'locate_mode' => 2,\n 'satellite' => 5,\n 'temp' => 17.09,\n 'current' => 4.6399999999999997,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 37 => \n array (\n 'id' => 38,\n 'bms_id' => 2,\n 'soc' => 84.870000000000005,\n 'soh' => 15,\n 'vol' => 45.210000000000001,\n 'res' => 1667.4000000000001,\n 'longitude' => -64.620000000000005,\n 'latitude' => 167.81,\n 'altitude' => 142.09999999999999,\n 'speed' => 88.200000000000003,\n 'locate_mode' => 2,\n 'satellite' => 6,\n 'temp' => 8.9299999999999997,\n 'current' => 3.6499999999999999,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 38 => \n array (\n 'id' => 39,\n 'bms_id' => 4,\n 'soc' => 10.68,\n 'soh' => 56,\n 'vol' => 3.0699999999999998,\n 'res' => 378.63,\n 'longitude' => -23.66,\n 'latitude' => 139.41,\n 'altitude' => 16.640000000000001,\n 'speed' => 45.590000000000003,\n 'locate_mode' => 1,\n 'satellite' => 11,\n 'temp' => -2.8999999999999999,\n 'current' => 0.55000000000000004,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 39 => \n array (\n 'id' => 40,\n 'bms_id' => 9,\n 'soc' => 35.270000000000003,\n 'soh' => 10,\n 'vol' => 98.579999999999998,\n 'res' => 1034.01,\n 'longitude' => 110.09999999999999,\n 'latitude' => 127.61,\n 'altitude' => 57,\n 'speed' => 4.1100000000000003,\n 'locate_mode' => 1,\n 'satellite' => 7,\n 'temp' => -1.5700000000000001,\n 'current' => 0.33000000000000002,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 40 => \n array (\n 'id' => 41,\n 'bms_id' => 1,\n 'soc' => 13.02,\n 'soh' => 3,\n 'vol' => 15.960000000000001,\n 'res' => 1391.75,\n 'longitude' => -160.84,\n 'latitude' => 245.88999999999999,\n 'altitude' => 54.149999999999999,\n 'speed' => 87.840000000000003,\n 'locate_mode' => 3,\n 'satellite' => 7,\n 'temp' => 27.469999999999999,\n 'current' => 3.0899999999999999,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 41 => \n array (\n 'id' => 42,\n 'bms_id' => 2,\n 'soc' => 84.579999999999998,\n 'soh' => 52,\n 'vol' => 104.98999999999999,\n 'res' => 570.85000000000002,\n 'longitude' => -151.03999999999999,\n 'latitude' => 158.36000000000001,\n 'altitude' => 166.34,\n 'speed' => 30.149999999999999,\n 'locate_mode' => 3,\n 'satellite' => 11,\n 'temp' => -1.97,\n 'current' => 3.8900000000000001,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 42 => \n array (\n 'id' => 43,\n 'bms_id' => 6,\n 'soc' => 22.460000000000001,\n 'soh' => 87,\n 'vol' => 126.20999999999999,\n 'res' => 392.64999999999998,\n 'longitude' => 86.829999999999998,\n 'latitude' => 75.959999999999994,\n 'altitude' => 51.479999999999997,\n 'speed' => 24.969999999999999,\n 'locate_mode' => 2,\n 'satellite' => 9,\n 'temp' => 11.800000000000001,\n 'current' => 4.1900000000000004,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 43 => \n array (\n 'id' => 44,\n 'bms_id' => 8,\n 'soc' => 71.950000000000003,\n 'soh' => 60,\n 'vol' => 112.79000000000001,\n 'res' => 922.79999999999995,\n 'longitude' => 15.92,\n 'latitude' => 191.55000000000001,\n 'altitude' => 24.649999999999999,\n 'speed' => 71.849999999999994,\n 'locate_mode' => 1,\n 'satellite' => 7,\n 'temp' => 12.960000000000001,\n 'current' => 4.6100000000000003,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 44 => \n array (\n 'id' => 45,\n 'bms_id' => 3,\n 'soc' => 50.700000000000003,\n 'soh' => 85,\n 'vol' => 5.6200000000000001,\n 'res' => 1910.6500000000001,\n 'longitude' => 39.719999999999999,\n 'latitude' => 64.840000000000003,\n 'altitude' => 45.619999999999997,\n 'speed' => 14.83,\n 'locate_mode' => 1,\n 'satellite' => 11,\n 'temp' => 20.370000000000001,\n 'current' => 4.7800000000000002,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 45 => \n array (\n 'id' => 46,\n 'bms_id' => 8,\n 'soc' => 58.189999999999998,\n 'soh' => 20,\n 'vol' => 0.13,\n 'res' => 1036.9100000000001,\n 'longitude' => 72.439999999999998,\n 'latitude' => 132.84999999999999,\n 'altitude' => 50.890000000000001,\n 'speed' => 42.590000000000003,\n 'locate_mode' => 1,\n 'satellite' => 8,\n 'temp' => 10.16,\n 'current' => 2.4100000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 46 => \n array (\n 'id' => 47,\n 'bms_id' => 5,\n 'soc' => 58.280000000000001,\n 'soh' => 15,\n 'vol' => 108.06,\n 'res' => 1918.78,\n 'longitude' => -168.78,\n 'latitude' => 136.71000000000001,\n 'altitude' => 179.33000000000001,\n 'speed' => 23.390000000000001,\n 'locate_mode' => 2,\n 'satellite' => 6,\n 'temp' => -0.60999999999999999,\n 'current' => 4.7800000000000002,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 47 => \n array (\n 'id' => 48,\n 'bms_id' => 2,\n 'soc' => 20.550000000000001,\n 'soh' => 54,\n 'vol' => 42.850000000000001,\n 'res' => 1391.01,\n 'longitude' => -137.27000000000001,\n 'latitude' => 148.22999999999999,\n 'altitude' => 174.18000000000001,\n 'speed' => 31.530000000000001,\n 'locate_mode' => 2,\n 'satellite' => 5,\n 'temp' => 22.239999999999998,\n 'current' => 0.79000000000000004,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 48 => \n array (\n 'id' => 49,\n 'bms_id' => 5,\n 'soc' => 72.040000000000006,\n 'soh' => 79,\n 'vol' => 33.990000000000002,\n 'res' => 569.36000000000001,\n 'longitude' => -9.3000000000000007,\n 'latitude' => 87.459999999999994,\n 'altitude' => 112.42,\n 'speed' => 85.010000000000005,\n 'locate_mode' => 1,\n 'satellite' => 6,\n 'temp' => 2.7800000000000002,\n 'current' => 0.44,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 49 => \n array (\n 'id' => 50,\n 'bms_id' => 3,\n 'soc' => 7.6100000000000003,\n 'soh' => 37,\n 'vol' => 25.079999999999998,\n 'res' => 1752.21,\n 'longitude' => 50.840000000000003,\n 'latitude' => 343.70999999999998,\n 'altitude' => 46.119999999999997,\n 'speed' => 72.920000000000002,\n 'locate_mode' => 2,\n 'satellite' => 11,\n 'temp' => 11.66,\n 'current' => 4.21,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 50 => \n array (\n 'id' => 51,\n 'bms_id' => 2,\n 'soc' => 25.120000000000001,\n 'soh' => 1,\n 'vol' => 185.18000000000001,\n 'res' => 1555.8199999999999,\n 'longitude' => -67.620000000000005,\n 'latitude' => 89.560000000000002,\n 'altitude' => 164.33000000000001,\n 'speed' => 91.930000000000007,\n 'locate_mode' => 2,\n 'satellite' => 5,\n 'temp' => 12.23,\n 'current' => 0.059999999999999998,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 51 => \n array (\n 'id' => 52,\n 'bms_id' => 7,\n 'soc' => 15.300000000000001,\n 'soh' => 56,\n 'vol' => 166.15000000000001,\n 'res' => 1579.53,\n 'longitude' => -49.450000000000003,\n 'latitude' => 56.82,\n 'altitude' => 60.850000000000001,\n 'speed' => 7.9399999999999995,\n 'locate_mode' => 2,\n 'satellite' => 3,\n 'temp' => 19.420000000000002,\n 'current' => 0.76000000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 52 => \n array (\n 'id' => 53,\n 'bms_id' => 10,\n 'soc' => 99.170000000000002,\n 'soh' => 64,\n 'vol' => 163.28999999999999,\n 'res' => 1811.47,\n 'longitude' => -0.050000000000000044,\n 'latitude' => 133.5,\n 'altitude' => 65.75,\n 'speed' => 42.509999999999998,\n 'locate_mode' => 1,\n 'satellite' => 4,\n 'temp' => 17.489999999999998,\n 'current' => 3.77,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 53 => \n array (\n 'id' => 54,\n 'bms_id' => 4,\n 'soc' => 57.469999999999999,\n 'soh' => 86,\n 'vol' => 72.700000000000003,\n 'res' => 1212.3199999999999,\n 'longitude' => 177.59999999999999,\n 'latitude' => 126.02,\n 'altitude' => 99.189999999999998,\n 'speed' => 3.4500000000000002,\n 'locate_mode' => 1,\n 'satellite' => 3,\n 'temp' => 24.34,\n 'current' => 1.0700000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 54 => \n array (\n 'id' => 55,\n 'bms_id' => 1,\n 'soc' => 35.149999999999999,\n 'soh' => 52,\n 'vol' => 42.979999999999997,\n 'res' => 803.74000000000001,\n 'longitude' => 39.380000000000003,\n 'latitude' => 332.06,\n 'altitude' => 65.829999999999998,\n 'speed' => 30.48,\n 'locate_mode' => 2,\n 'satellite' => 9,\n 'temp' => 6.8200000000000003,\n 'current' => 2.98,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 55 => \n array (\n 'id' => 56,\n 'bms_id' => 8,\n 'soc' => 41.619999999999997,\n 'soh' => 46,\n 'vol' => 60.159999999999997,\n 'res' => 380.07999999999998,\n 'longitude' => 145.63999999999999,\n 'latitude' => 288.38999999999999,\n 'altitude' => 97.769999999999996,\n 'speed' => 25.82,\n 'locate_mode' => 1,\n 'satellite' => 10,\n 'temp' => 2.2400000000000002,\n 'current' => 4.0599999999999996,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 56 => \n array (\n 'id' => 57,\n 'bms_id' => 4,\n 'soc' => 62.939999999999998,\n 'soh' => 75,\n 'vol' => 180.78999999999999,\n 'res' => 1555.3199999999999,\n 'longitude' => -98.430000000000007,\n 'latitude' => 157.78999999999999,\n 'altitude' => 143.88,\n 'speed' => 66.689999999999998,\n 'locate_mode' => 1,\n 'satellite' => 7,\n 'temp' => 15.789999999999999,\n 'current' => 4.4100000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 57 => \n array (\n 'id' => 58,\n 'bms_id' => 2,\n 'soc' => 97,\n 'soh' => 57,\n 'vol' => 176.05000000000001,\n 'res' => 1164.5,\n 'longitude' => 41.789999999999999,\n 'latitude' => 338.62,\n 'altitude' => 187.33000000000001,\n 'speed' => 11.82,\n 'locate_mode' => 1,\n 'satellite' => 7,\n 'temp' => 10.59,\n 'current' => 2.9500000000000002,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 58 => \n array (\n 'id' => 59,\n 'bms_id' => 7,\n 'soc' => 17.469999999999999,\n 'soh' => 93,\n 'vol' => 58.560000000000002,\n 'res' => 269.52999999999997,\n 'longitude' => -1.96,\n 'latitude' => 152.03,\n 'altitude' => 126.43000000000001,\n 'speed' => 99.640000000000001,\n 'locate_mode' => 3,\n 'satellite' => 10,\n 'temp' => 14.07,\n 'current' => 2.4500000000000002,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 59 => \n array (\n 'id' => 60,\n 'bms_id' => 5,\n 'soc' => 49.200000000000003,\n 'soh' => 94,\n 'vol' => 89.439999999999998,\n 'res' => 1685.05,\n 'longitude' => -68.219999999999999,\n 'latitude' => 290.83999999999997,\n 'altitude' => 35.609999999999999,\n 'speed' => 18.289999999999999,\n 'locate_mode' => 1,\n 'satellite' => 6,\n 'temp' => 16.710000000000001,\n 'current' => 1.8500000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 60 => \n array (\n 'id' => 61,\n 'bms_id' => 4,\n 'soc' => 66.379999999999995,\n 'soh' => 44,\n 'vol' => 138.88999999999999,\n 'res' => 544.42999999999995,\n 'longitude' => 138.00999999999999,\n 'latitude' => 65.459999999999994,\n 'altitude' => 7.8899999999999997,\n 'speed' => 23.309999999999999,\n 'locate_mode' => 2,\n 'satellite' => 11,\n 'temp' => 10.91,\n 'current' => 2.1099999999999999,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 61 => \n array (\n 'id' => 62,\n 'bms_id' => 5,\n 'soc' => 25.100000000000001,\n 'soh' => 67,\n 'vol' => 66.829999999999998,\n 'res' => 222.87,\n 'longitude' => 154.03999999999999,\n 'latitude' => 327.25,\n 'altitude' => 190.55000000000001,\n 'speed' => 1.3400000000000001,\n 'locate_mode' => 3,\n 'satellite' => 7,\n 'temp' => 29.539999999999999,\n 'current' => 1.1000000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 62 => \n array (\n 'id' => 63,\n 'bms_id' => 10,\n 'soc' => 17.059999999999999,\n 'soh' => 94,\n 'vol' => 159.15000000000001,\n 'res' => 712.16999999999996,\n 'longitude' => -175.81,\n 'latitude' => 358.37,\n 'altitude' => 34.700000000000003,\n 'speed' => 12.24,\n 'locate_mode' => 1,\n 'satellite' => 11,\n 'temp' => 13.470000000000001,\n 'current' => 1.01,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 63 => \n array (\n 'id' => 64,\n 'bms_id' => 7,\n 'soc' => 1.6600000000000001,\n 'soh' => 5,\n 'vol' => 132.08000000000001,\n 'res' => 954.45000000000005,\n 'longitude' => -60.149999999999999,\n 'latitude' => 248.58000000000001,\n 'altitude' => 185.83000000000001,\n 'speed' => 24.329999999999998,\n 'locate_mode' => 1,\n 'satellite' => 12,\n 'temp' => 14.09,\n 'current' => 1.23,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 64 => \n array (\n 'id' => 65,\n 'bms_id' => 10,\n 'soc' => 81.689999999999998,\n 'soh' => 8,\n 'vol' => 196.44999999999999,\n 'res' => 1242.6099999999999,\n 'longitude' => -58.340000000000003,\n 'latitude' => 154.02000000000001,\n 'altitude' => 48.520000000000003,\n 'speed' => 95.730000000000004,\n 'locate_mode' => 3,\n 'satellite' => 6,\n 'temp' => 18.940000000000001,\n 'current' => 3.9699999999999998,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 65 => \n array (\n 'id' => 66,\n 'bms_id' => 6,\n 'soc' => 38.979999999999997,\n 'soh' => 84,\n 'vol' => 0.29999999999999999,\n 'res' => 1258.3699999999999,\n 'longitude' => -90.040000000000006,\n 'latitude' => 171.25,\n 'altitude' => 40.509999999999998,\n 'speed' => 76.909999999999997,\n 'locate_mode' => 2,\n 'satellite' => 8,\n 'temp' => 23.91,\n 'current' => 3.73,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 66 => \n array (\n 'id' => 67,\n 'bms_id' => 10,\n 'soc' => 97.659999999999997,\n 'soh' => 83,\n 'vol' => 143.31999999999999,\n 'res' => 1660.54,\n 'longitude' => -155.97,\n 'latitude' => 289.74000000000001,\n 'altitude' => 130.09,\n 'speed' => 48.789999999999999,\n 'locate_mode' => 3,\n 'satellite' => 10,\n 'temp' => 10.890000000000001,\n 'current' => 1.03,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 67 => \n array (\n 'id' => 68,\n 'bms_id' => 3,\n 'soc' => 20.109999999999999,\n 'soh' => 70,\n 'vol' => 139.34999999999999,\n 'res' => 1249.52,\n 'longitude' => 46.020000000000003,\n 'latitude' => 35.93,\n 'altitude' => 38.079999999999998,\n 'speed' => 59.259999999999998,\n 'locate_mode' => 3,\n 'satellite' => 6,\n 'temp' => 27.5,\n 'current' => 0.34000000000000002,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 68 => \n array (\n 'id' => 69,\n 'bms_id' => 5,\n 'soc' => 61.270000000000003,\n 'soh' => 54,\n 'vol' => 92.480000000000004,\n 'res' => 1185.6800000000001,\n 'longitude' => 6.04,\n 'latitude' => 166.81,\n 'altitude' => 13.800000000000001,\n 'speed' => 32.729999999999997,\n 'locate_mode' => 1,\n 'satellite' => 6,\n 'temp' => 14.640000000000001,\n 'current' => 2.0800000000000001,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 69 => \n array (\n 'id' => 70,\n 'bms_id' => 1,\n 'soc' => 75.689999999999998,\n 'soh' => 20,\n 'vol' => 123.34999999999999,\n 'res' => 992.32000000000005,\n 'longitude' => -110.59,\n 'latitude' => 280.05000000000001,\n 'altitude' => 105.78,\n 'speed' => 18.940000000000001,\n 'locate_mode' => 3,\n 'satellite' => 11,\n 'temp' => 0.85999999999999999,\n 'current' => 3.4399999999999999,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 70 => \n array (\n 'id' => 71,\n 'bms_id' => 6,\n 'soc' => 19.699999999999999,\n 'soh' => 50,\n 'vol' => 186.41,\n 'res' => 620.13999999999999,\n 'longitude' => 20.690000000000001,\n 'latitude' => 1.22,\n 'altitude' => 150.31999999999999,\n 'speed' => 4.6699999999999999,\n 'locate_mode' => 2,\n 'satellite' => 11,\n 'temp' => 9.7400000000000002,\n 'current' => 1.2,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 71 => \n array (\n 'id' => 72,\n 'bms_id' => 5,\n 'soc' => 24.199999999999999,\n 'soh' => 2,\n 'vol' => 151.68000000000001,\n 'res' => 1997.4400000000001,\n 'longitude' => -164.13,\n 'latitude' => 221.94999999999999,\n 'altitude' => 161.41999999999999,\n 'speed' => 46.640000000000001,\n 'locate_mode' => 2,\n 'satellite' => 7,\n 'temp' => 21.039999999999999,\n 'current' => 4.9800000000000004,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 72 => \n array (\n 'id' => 73,\n 'bms_id' => 9,\n 'soc' => 58.009999999999998,\n 'soh' => 27,\n 'vol' => 128.69,\n 'res' => 1167.1700000000001,\n 'longitude' => -18.52,\n 'latitude' => 105.45,\n 'altitude' => 139.96000000000001,\n 'speed' => 90.909999999999997,\n 'locate_mode' => 1,\n 'satellite' => 8,\n 'temp' => 21.120000000000001,\n 'current' => 4.71,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 73 => \n array (\n 'id' => 74,\n 'bms_id' => 10,\n 'soc' => 97.689999999999998,\n 'soh' => 53,\n 'vol' => 51.829999999999998,\n 'res' => 1193.1500000000001,\n 'longitude' => -16.710000000000001,\n 'latitude' => 18.329999999999998,\n 'altitude' => 111.59,\n 'speed' => 22.170000000000002,\n 'locate_mode' => 2,\n 'satellite' => 9,\n 'temp' => 20.809999999999999,\n 'current' => 1.04,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 74 => \n array (\n 'id' => 75,\n 'bms_id' => 1,\n 'soc' => 42.829999999999998,\n 'soh' => 14,\n 'vol' => 215.19999999999999,\n 'res' => 1577.4400000000001,\n 'longitude' => -95.370000000000005,\n 'latitude' => 35.609999999999999,\n 'altitude' => 33.509999999999998,\n 'speed' => 96.120000000000005,\n 'locate_mode' => 2,\n 'satellite' => 6,\n 'temp' => 9.9499999999999993,\n 'current' => 3.79,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 75 => \n array (\n 'id' => 76,\n 'bms_id' => 6,\n 'soc' => 54.549999999999997,\n 'soh' => 99,\n 'vol' => 129.63,\n 'res' => 113.66,\n 'longitude' => -174.83000000000001,\n 'latitude' => 52.109999999999999,\n 'altitude' => 40.079999999999998,\n 'speed' => 44.329999999999998,\n 'locate_mode' => 1,\n 'satellite' => 6,\n 'temp' => 0.40999999999999998,\n 'current' => 0.68999999999999995,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 76 => \n array (\n 'id' => 77,\n 'bms_id' => 3,\n 'soc' => 48.159999999999997,\n 'soh' => 39,\n 'vol' => 152.16,\n 'res' => 916.64999999999998,\n 'longitude' => -100.7,\n 'latitude' => 165.72999999999999,\n 'altitude' => 179.05000000000001,\n 'speed' => 40.399999999999999,\n 'locate_mode' => 2,\n 'satellite' => 5,\n 'temp' => -8.5999999999999996,\n 'current' => 0.42999999999999999,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 77 => \n array (\n 'id' => 78,\n 'bms_id' => 8,\n 'soc' => 34.229999999999997,\n 'soh' => 54,\n 'vol' => 30.359999999999999,\n 'res' => 1368.3499999999999,\n 'longitude' => 56.859999999999999,\n 'latitude' => 280.58999999999997,\n 'altitude' => 40.219999999999999,\n 'speed' => 13.81,\n 'locate_mode' => 1,\n 'satellite' => 4,\n 'temp' => -2.0099999999999998,\n 'current' => 1.4399999999999999,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 78 => \n array (\n 'id' => 79,\n 'bms_id' => 6,\n 'soc' => 53.43,\n 'soh' => 35,\n 'vol' => 94.590000000000003,\n 'res' => 1389.46,\n 'longitude' => -134.74000000000001,\n 'latitude' => 240.72,\n 'altitude' => 121.56999999999999,\n 'speed' => 18.829999999999998,\n 'locate_mode' => 2,\n 'satellite' => 3,\n 'temp' => 4.4699999999999998,\n 'current' => 3.0899999999999999,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 79 => \n array (\n 'id' => 80,\n 'bms_id' => 3,\n 'soc' => 10.890000000000001,\n 'soh' => 71,\n 'vol' => 14.880000000000001,\n 'res' => 1014.55,\n 'longitude' => 17.239999999999998,\n 'latitude' => 331.92000000000002,\n 'altitude' => 23.890000000000001,\n 'speed' => 82.599999999999994,\n 'locate_mode' => 1,\n 'satellite' => 9,\n 'temp' => -9.0600000000000005,\n 'current' => 4.9399999999999995,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 80 => \n array (\n 'id' => 81,\n 'bms_id' => 7,\n 'soc' => 89.260000000000005,\n 'soh' => 35,\n 'vol' => 201.28,\n 'res' => 125.76000000000001,\n 'longitude' => 102.98,\n 'latitude' => 159.38999999999999,\n 'altitude' => 161.91,\n 'speed' => 58.140000000000001,\n 'locate_mode' => 2,\n 'satellite' => 6,\n 'temp' => -9.8599999999999994,\n 'current' => 2.3100000000000001,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 81 => \n array (\n 'id' => 82,\n 'bms_id' => 7,\n 'soc' => 10.970000000000001,\n 'soh' => 26,\n 'vol' => 145.71000000000001,\n 'res' => 1121.1900000000001,\n 'longitude' => -87.400000000000006,\n 'latitude' => 248.03999999999999,\n 'altitude' => 62.32,\n 'speed' => 97.700000000000003,\n 'locate_mode' => 2,\n 'satellite' => 6,\n 'temp' => 10.16,\n 'current' => 4.6100000000000003,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 82 => \n array (\n 'id' => 83,\n 'bms_id' => 9,\n 'soc' => 90.469999999999999,\n 'soh' => 68,\n 'vol' => 196.02000000000001,\n 'res' => 565.66999999999996,\n 'longitude' => -62.649999999999999,\n 'latitude' => 109.52,\n 'altitude' => 98.739999999999995,\n 'speed' => 1.8900000000000001,\n 'locate_mode' => 3,\n 'satellite' => 5,\n 'temp' => 28.98,\n 'current' => 0.029999999999999999,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 83 => \n array (\n 'id' => 84,\n 'bms_id' => 9,\n 'soc' => 0.59999999999999998,\n 'soh' => 71,\n 'vol' => 215.72999999999999,\n 'res' => 154.96000000000001,\n 'longitude' => -95.359999999999999,\n 'latitude' => 11.77,\n 'altitude' => 43.560000000000002,\n 'speed' => 69.430000000000007,\n 'locate_mode' => 2,\n 'satellite' => 12,\n 'temp' => -1.95,\n 'current' => 1.1100000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 84 => \n array (\n 'id' => 85,\n 'bms_id' => 3,\n 'soc' => 2.8300000000000001,\n 'soh' => 7,\n 'vol' => 37.600000000000001,\n 'res' => 370.64999999999998,\n 'longitude' => -44.189999999999998,\n 'latitude' => 234.41999999999999,\n 'altitude' => 1.78,\n 'speed' => 20.93,\n 'locate_mode' => 3,\n 'satellite' => 8,\n 'temp' => 21.609999999999999,\n 'current' => 0.81999999999999995,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 85 => \n array (\n 'id' => 86,\n 'bms_id' => 2,\n 'soc' => 54.5,\n 'soh' => 68,\n 'vol' => 9.0099999999999998,\n 'res' => 567.48000000000002,\n 'longitude' => -178.49000000000001,\n 'latitude' => 346.00999999999999,\n 'altitude' => 193.38999999999999,\n 'speed' => 33.82,\n 'locate_mode' => 2,\n 'satellite' => 8,\n 'temp' => 2.1899999999999999,\n 'current' => 4.21,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 86 => \n array (\n 'id' => 87,\n 'bms_id' => 3,\n 'soc' => 46.770000000000003,\n 'soh' => 52,\n 'vol' => 145.84999999999999,\n 'res' => 914.77999999999997,\n 'longitude' => -55.229999999999997,\n 'latitude' => 225.24000000000001,\n 'altitude' => 5.2300000000000004,\n 'speed' => 66.969999999999999,\n 'locate_mode' => 2,\n 'satellite' => 9,\n 'temp' => 16.09,\n 'current' => 4.1100000000000003,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 87 => \n array (\n 'id' => 88,\n 'bms_id' => 8,\n 'soc' => 1.55,\n 'soh' => 93,\n 'vol' => 21.68,\n 'res' => 1419.6900000000001,\n 'longitude' => -50.020000000000003,\n 'latitude' => 59.490000000000002,\n 'altitude' => 89.680000000000007,\n 'speed' => 10.31,\n 'locate_mode' => 3,\n 'satellite' => 4,\n 'temp' => 28.719999999999999,\n 'current' => 4.6399999999999997,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 88 => \n array (\n 'id' => 89,\n 'bms_id' => 9,\n 'soc' => 47.289999999999999,\n 'soh' => 72,\n 'vol' => 206.93000000000001,\n 'res' => 240.97999999999999,\n 'longitude' => -158.53999999999999,\n 'latitude' => 119.75,\n 'altitude' => 0.25,\n 'speed' => 13.9,\n 'locate_mode' => 1,\n 'satellite' => 11,\n 'temp' => 22.699999999999999,\n 'current' => 3.52,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 89 => \n array (\n 'id' => 90,\n 'bms_id' => 9,\n 'soc' => 15.5,\n 'soh' => 72,\n 'vol' => 11.949999999999999,\n 'res' => 232.16,\n 'longitude' => -59.770000000000003,\n 'latitude' => 329.70999999999998,\n 'altitude' => 116.61,\n 'speed' => 58.740000000000002,\n 'locate_mode' => 2,\n 'satellite' => 6,\n 'temp' => 20.010000000000002,\n 'current' => 3.1699999999999999,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 90 => \n array (\n 'id' => 91,\n 'bms_id' => 9,\n 'soc' => 90.420000000000002,\n 'soh' => 57,\n 'vol' => 154.25999999999999,\n 'res' => 1674.1300000000001,\n 'longitude' => -118.69,\n 'latitude' => 212.09,\n 'altitude' => 50.600000000000001,\n 'speed' => 28.379999999999999,\n 'locate_mode' => 2,\n 'satellite' => 8,\n 'temp' => -9.9299999999999997,\n 'current' => 4.1699999999999999,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 91 => \n array (\n 'id' => 92,\n 'bms_id' => 3,\n 'soc' => 39.609999999999999,\n 'soh' => 15,\n 'vol' => 144.21000000000001,\n 'res' => 986.87,\n 'longitude' => -142.84999999999999,\n 'latitude' => 296.55000000000001,\n 'altitude' => 153.90000000000001,\n 'speed' => 86.129999999999995,\n 'locate_mode' => 3,\n 'satellite' => 6,\n 'temp' => 21.449999999999999,\n 'current' => 4.0800000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 92 => \n array (\n 'id' => 93,\n 'bms_id' => 3,\n 'soc' => 54.219999999999999,\n 'soh' => 80,\n 'vol' => 150.41,\n 'res' => 1789.8099999999999,\n 'longitude' => -164.36000000000001,\n 'latitude' => 73.269999999999996,\n 'altitude' => 75.579999999999998,\n 'speed' => 65.329999999999998,\n 'locate_mode' => 2,\n 'satellite' => 9,\n 'temp' => 17.629999999999999,\n 'current' => 4.5800000000000001,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 93 => \n array (\n 'id' => 94,\n 'bms_id' => 10,\n 'soc' => 24.190000000000001,\n 'soh' => 99,\n 'vol' => 117.56999999999999,\n 'res' => 1913.45,\n 'longitude' => -72.099999999999994,\n 'latitude' => 207.97,\n 'altitude' => 92.379999999999995,\n 'speed' => 53.020000000000003,\n 'locate_mode' => 2,\n 'satellite' => 5,\n 'temp' => 9.2799999999999994,\n 'current' => 1.1100000000000001,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 94 => \n array (\n 'id' => 95,\n 'bms_id' => 5,\n 'soc' => 11.029999999999999,\n 'soh' => 97,\n 'vol' => 6.29,\n 'res' => 628.01999999999998,\n 'longitude' => 167.47,\n 'latitude' => 357.63,\n 'altitude' => 168.24000000000001,\n 'speed' => 25.870000000000001,\n 'locate_mode' => 3,\n 'satellite' => 5,\n 'temp' => 11.16,\n 'current' => 3.5300000000000002,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 95 => \n array (\n 'id' => 96,\n 'bms_id' => 2,\n 'soc' => 76.819999999999993,\n 'soh' => 65,\n 'vol' => 53.32,\n 'res' => 1471.8699999999999,\n 'longitude' => -86.930000000000007,\n 'latitude' => 206.88999999999999,\n 'altitude' => 164.16999999999999,\n 'speed' => 33.310000000000002,\n 'locate_mode' => 3,\n 'satellite' => 8,\n 'temp' => 28.899999999999999,\n 'current' => 3.6000000000000001,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 96 => \n array (\n 'id' => 97,\n 'bms_id' => 10,\n 'soc' => 80.079999999999998,\n 'soh' => 42,\n 'vol' => 21.199999999999999,\n 'res' => 127.87,\n 'longitude' => 141.03,\n 'latitude' => 238.59999999999999,\n 'altitude' => 145.50999999999999,\n 'speed' => 59.039999999999999,\n 'locate_mode' => 3,\n 'satellite' => 4,\n 'temp' => 25.789999999999999,\n 'current' => 0.91000000000000003,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 97 => \n array (\n 'id' => 98,\n 'bms_id' => 10,\n 'soc' => 18.649999999999999,\n 'soh' => 52,\n 'vol' => 48.770000000000003,\n 'res' => 1822.4200000000001,\n 'longitude' => -173.03,\n 'latitude' => 227.03999999999999,\n 'altitude' => 75.989999999999995,\n 'speed' => 2.1499999999999999,\n 'locate_mode' => 1,\n 'satellite' => 4,\n 'temp' => 5.2199999999999998,\n 'current' => 3.27,\n 'charge' => 2,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 98 => \n array (\n 'id' => 99,\n 'bms_id' => 2,\n 'soc' => 16.199999999999999,\n 'soh' => 81,\n 'vol' => 51.579999999999998,\n 'res' => 1714.73,\n 'longitude' => -135.25,\n 'latitude' => 32.369999999999997,\n 'altitude' => 66.409999999999997,\n 'speed' => 39.539999999999999,\n 'locate_mode' => 1,\n 'satellite' => 4,\n 'temp' => 13.390000000000001,\n 'current' => 2.3500000000000001,\n 'charge' => 0,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n 99 => \n array (\n 'id' => 100,\n 'bms_id' => 8,\n 'soc' => 73.469999999999999,\n 'soh' => 44,\n 'vol' => 51.57,\n 'res' => 1946.6500000000001,\n 'longitude' => -61.890000000000001,\n 'latitude' => 224.74000000000001,\n 'altitude' => 143.05000000000001,\n 'speed' => 23.879999999999999,\n 'locate_mode' => 2,\n 'satellite' => 5,\n 'temp' => 13.42,\n 'current' => 0.39000000000000001,\n 'charge' => 1,\n 'created_at' => '2016-11-12 11:01:10',\n 'updated_at' => '2016-11-12 11:01:10',\n 'deleted_at' => NULL,\n ),\n ));\n \n \n }", "title": "" }, { "docid": "4366c908e3ad5bab3b87959c172ba94c", "score": "0.5316222", "text": "public function run()\n {\n DB::table('yeasts')->insert([\n 'name' => 'US-05'\n ]);\n }", "title": "" }, { "docid": "dd6cd041219a8056ec75ef958a2ddff0", "score": "0.53083587", "text": "public function run()\n {\n \\DB::table('coupons')->insert([\n 'code' => 'ABC123',\n 'type' => 'fixed',\n 'value' => 30,\n 'created_at' => NOW()\n ]);\n\n \\DB::table('coupons')->insert([\n 'code' => 'DEF4566',\n 'type' => 'percent',\n 'percent_off' => 5,\n 'created_at' => NOW()\n ]);\n }", "title": "" }, { "docid": "0000110aed195f0d045cc1987713ac87", "score": "0.530835", "text": "public function run()\n {\n DB::table('universities')->insert([\n ['name' => 'Islamic'],\n ['name' =>'Al_Azhar'],\n ['name' =>'Al_Aqsa'],\n ['name' =>'Gaza']\n ]);\n }", "title": "" }, { "docid": "3bc78ba0ec63fef430aee15c9795b773", "score": "0.53021395", "text": "public function run()\n {\n DB::table('master_promos')->insert([\n 'foto' => 'kosong',\n 'lokasifoto' => 'kosong',\n 'kode_promo' => 'weekendpromo',\n 'nama_promo' => 'promo weekend',\n 'diskon' => '50',\n 'berlaku_awal' => date('Y-m-d'),\n 'berlaku_akhir' => date('Y-m-d'),\n 'min_pembelian' => '50000',\n ]);\n }", "title": "" }, { "docid": "828bb2371e3e60de946235b36b0e2869", "score": "0.53018653", "text": "public function UploadToWunderground() {\n\n\t\t$Debug = $this->ReadPropertyBoolean(\"Debug\");\n\n\t\t// setting standard values like time and login\n\n\t\t$WU_ID = $this->ReadPropertyString(\"WU_ID\");\n\t\t$WU_Password = $this->ReadPropertyString(\"WU_StationKey\");\n\t\t$time = \"now\";\n\n\t\t$responseUrl = \"https://weatherstation.wunderground.com/weatherstation/updateweatherstation.php?ID=\".$WU_ID.\"&PASSWORD=\".$WU_Password.\"&dateutc=\".$time;\n\n\t\tIf ($this->ReadPropertyInteger(\"OutsideTemperature\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"OutsideTemperature\")))\t{\n\t\t\t$Temperature = GetValue($this->ReadPropertyInteger(\"OutsideTemperature\"));\n\t\t\t$TemperatureF = str_replace(\",\",\".\",(($Temperature * 9) /5 + 32));\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Temperature F: \".$TemperatureF, 0);\n\n\t\t\t$responseUrl .= \"&tempf=\".$TemperatureF;\n\t\t}\n\n\n\t\t// Prepare Dewpoint for upload\n\n\t\tIf ($this->ReadPropertyInteger(\"DewPoint\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"DewPoint\"))) {\n\t\t\t$DewPoint = GetValue($this->ReadPropertyInteger(\"DewPoint\"));\n\t\t\t$DewPointF = str_replace(\",\",\".\",(($DewPoint * 9) /5 + 32));\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Taupunkt F: \".$DewPointF, 0);\n\n\t\t\t$responseUrl .= \"&dewptf=\".$DewPointF;\n\t\t}\n\n\n\t\t// Prepare Humidity for upload\n\n\t\tIf ($this->ReadPropertyInteger(\"Humidity\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"Humidity\"))) {\n\t\t\t$Humidity = GetValue($this->ReadPropertyInteger(\"Humidity\"));\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Humidity: \".$Humidity, 0);\n\n\t\t\t$responseUrl .= \"&humidity=\".$Humidity;\n\t\t}\n\n\n\t\t// Prepare Windirection for upload\n\n\t\tIf ($this->ReadPropertyInteger(\"WindDirection\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"WindDirection\")))\t{\n\t\t\t$WindDirection = GetValue($this->ReadPropertyInteger(\"WindDirection\"));\n\t\t\t$WindDirectionU = str_replace(\",\",\".\",$WindDirection);\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Wind Direction: \".$WindDirectionU, 0);\n\n\t\t\t$responseUrl .= \"&winddir=\".$WindDirectionU;\n\t\t}\n\n\n\t\t// Prepare Windspeed for upload\n\n\t\tIf ($this->ReadPropertyInteger(\"WindSpeed\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"WindSpeed\"))) {\n\t\t\t$WindSpeed = GetValue($this->ReadPropertyInteger(\"WindSpeed\"));\n\n\t\t\tIf ($this->ReadPropertyString(\"WindConversion\") == \"kmh\") {\n\t\t\t\t\t$WindSpeed = str_replace(\",\",\".\",Round(($WindSpeed / 3.6),2));\n\t\t\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Converting from KMH to M/S\", 0);\n\n\t\t\t\t}\n\n\t\t\t$WindSpeedU = str_replace(\",\",\".\",Round(($WindSpeed * 2.2369),2));\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Windspeed: \".$WindSpeedU.\" mph (\".$WindSpeed.\" m/s)\", 0);\n\n\t\t\t$responseUrl .= \"&windspeedmph=\".$WindSpeedU;\n\t\t}\n\n\n\t\t// Prepare Windgust for upload\n\n\t\tIf ($this->ReadPropertyInteger(\"WindGust\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"WindGust\"))) {\n\t\t\t$WindGust = GetValue($this->ReadPropertyInteger(\"WindGust\"));\n\n\t\t\tIf ($this->ReadPropertyString(\"WindConversion\") == \"kmh\") {\n\t\t\t\t$WindGust = str_replace(\",\",\".\",Round(($WindGust / 3.6),2));\n\t\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Converting from KMH to M/S\", 0);\n\n\t\t\t}\n\n\t\t\t$WindGustU = str_replace(\",\",\".\",Round(($WindGust * 2.2369),2));\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Wind Gust: \".$WindGustU, 0);\n\n\t\t\t$responseUrl .= \"&windgustmph=\".$WindGustU;\n\t\t}\n\n\n\t\t// Prepare Rain last hour for upload\n\n\t\tIf ($this->ReadPropertyInteger(\"Rain_last_Hour\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"Rain_last_Hour\")))\t{\n\t\t\t$Rain_last_Hour = GetValue($this->ReadPropertyInteger(\"Rain_last_Hour\"));\n\t\t\t$Rain_last_Hour = str_replace(\",\",\".\",Round(($Rain_last_Hour / 25.4),2));\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Rain Last Hour: \".$Rain_last_Hour, 0);\n\n\t\t\t$responseUrl .= \"&rainin=\".$Rain_last_Hour;\n\t\t}\n\n\n\t\t// Prepare Rain 24h for upload\n\n\t\tIf ($this->ReadPropertyInteger(\"Rain24h\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"Rain24h\"))) {\n\t\t\t$Rain24h = GetValue($this->ReadPropertyInteger(\"Rain24h\"));\n\t\t\t$Rain24h = str_replace(\",\",\".\",Round(($Rain24h / 25.4),2));\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Rain in 24h: \".$Rain24h, 0);\n\n\t\t\t$responseUrl .= \"&dailyrainin=\".$Rain24h;\n\t\t}\n\n\n\t\t// Prepare Airpressure for upload\n\n\t\tIf ($this->ReadPropertyInteger(\"AirPressure\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"AirPressure\"))) {\n\t\t\t$AirPressure = GetValue($this->ReadPropertyInteger(\"AirPressure\"));\n\t\t\t$BPI = str_replace(\",\",\".\",Round(($AirPressure * 0.0295299830714),4));\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Airpressure in BPI: \".$AirPressure, 0);\n\n\t\t\t$responseUrl .= \"&baromin=\".$BPI;\n\t\t}\n\n\n\t\t// Prepare UV Index for upload\n\n\t\tIf ($this->ReadPropertyInteger(\"UVIndex\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"UVIndex\"))) {\n\t\t\t$UVIndex = GetValue($this->ReadPropertyInteger(\"UVIndex\"));\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload UV Index: \".$UVIndex, 0);\n\n\t\t\t$responseUrl .= \"&UV=\".$UVIndex;\n\t\t}\n\n\t\t// Prepare Solar Radiation for upload\n\n\t\tIf ($this->ReadPropertyInteger(\"SolarRadiation\") != \"\" and IPS_VariableExists($this->ReadPropertyInteger(\"SolarRadiation\"))) {\n\t\t\t$SolarRadiation = GetValue($this->ReadPropertyInteger(\"SolarRadiation\"));\n\t\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Solar Radiation: \".$SolarRadiation, 0);\n\n\t\t\t$responseUrl .= \"&solarradiation=\".$SolarRadiation;\n\t\t}\n\n\t\t$Response =file_get_contents($responseUrl);\n\t\t$this->SendDebug(\"Wunderground PWS Update\",\"Wunderground Upload Service: \".$Response, 0);\n\n\t}", "title": "" }, { "docid": "0b5038755edf205c9c84141b5fc11cfc", "score": "0.5298206", "text": "function insert()\n {\n $stmt = $this->database->prepare(\n \"INSERT INTO \" . $this->sensorTable .\n \" ( soil_moisture,temperature, humidity, motor_pump_status)\n VALUES (?,?,?,?)\"\n );\n\n $this->soilMoisture = $this->cleanInput($this->soilMoisture);\n $this->humidity = $this->cleanInput($this->humidity);\n $this->temperature = $this->cleanInput($this->temperature);\n $this->motorStatus = $this->cleanInput($this->motorStatus);\n\n $stmt->bind_param(\n \"dddi\",\n $this->soilMoisture,\n $this->temperature,\n $this->humidity,\n $this->motorStatus\n );\n\n if($stmt->execute()){\n $stmt->close();\n return true;\n }\n\n return false;\n }", "title": "" }, { "docid": "76a63b61e41dba20e60f401ca54af3cc", "score": "0.5288781", "text": "public function run()\n {\n $records = include database_path('data/iana_iftype_definitions.php');\n\n DB::table('interface_type_definitions')->insert($records);\n }", "title": "" }, { "docid": "ef58036ac858d89f055a6677c1d94c4c", "score": "0.52880776", "text": "public function syncLocalDB()\n {\n $url = config('services.datagovin.uri')\n . \"&format=json&offset=\";\n $client = new \\GuzzleHttp\\Client(['http_errors' => false]);\n $res = $client->get($url . '0' . \"&limit=1\");\n if ($res->getStatusCode() != 200)\n {\n echo \"Error connecting external api or invalid respponse\";\n\n return;\n }\n\n $this->prepareDatabase();\n $tot = json_decode($res->getBody(), true)['total'];\n\n for ($off = 0; $off <= $tot; $off += 1000)\n {\n $res = $client->get($url . $off . \"&limit=1000\");\n $json = json_decode($res->getBody(), true);\n if ($res->getStatusCode() == 200)\n {\n $datas = $json['records'];\n foreach ($datas as $data)\n {\n $data = array(\n $data['pincode'],\n $data['taluk'],\n ((new State())->where(config('database.tables.state.name'), $data['statename'])\n ->first()\n ->getAttribute(config('database.tables.state.tin'))),\n $data['districtname']\n );\n $this->addToPincodeTable($data);\n }\n\n }\n }\n\n }", "title": "" }, { "docid": "cb36aebd9d4571c3f1b0c6653c5884c8", "score": "0.5281023", "text": "public function run()\n {\n DB::table('weights')->insert([\n 'tanggal' => '2018-08-18',\n 'maxi' => 50,\n 'mini' => 48,\n 'perbedaan' => 2\n ]);\n }", "title": "" }, { "docid": "c6c7664647f2dae53381442db18bdc7e", "score": "0.5280238", "text": "public function run()\n {\n $model = array (\n array(\n \t'modelId' => 'MODEL0001',\n\t\t\t\t'modelName' => 'WIGO',\n\t\t\t\t'modelIsActive' => 1\n ),\n );\n DB::table('vehicle_model')->insert($model);\n }", "title": "" }, { "docid": "e6b874a1cb4eff86b148f51ce41f9919", "score": "0.527515", "text": "public function run()\n {\n $currencies = [\n ['id' => '1','iso_name' => 'USD','symbol' => '$','created_at' => '2019-04-18 12:19:26','updated_at' => '2019-04-18 12:19:26']\n ];\n\n DB::table('currencies')->insert($currencies);\n }", "title": "" }, { "docid": "2d55e707452b3fb36f85bf9d8934c1f0", "score": "0.52708554", "text": "public function run()\n {\n DB::table('localities')->insert([\n \t\t\t'localitie'\t=>\t'GALAPAGOS'\n \t\t]);\n DB::table('localities')->insert([\n \t\t\t'localitie'\t=>\t'QUITO'\n \t\t]);\n DB::table('localities')->insert([\n \t\t\t'localitie'\t=>\t'OTAVALO'\n \t\t]);\n }", "title": "" }, { "docid": "b578691fefde1516ff9f1a9c2860b5cb", "score": "0.52694947", "text": "public function Create()\n\t{\n\t\tparent::Create();\n\t\t$this->RegisterPropertyInteger(\"SourceID\", 0);\n\t\t$this->RegisterPropertyString(\"WU_ID\", \"\");\n\t\t$this->RegisterPropertyString(\"WU_Password\",\"\");\n\t\t$this->RegisterPropertyString(\"WU_API\",\"\");\n\t\t$this->RegisterPropertyString(\"WU_StationKey\",\"\");\n\t\t$this->RegisterPropertyString(\"Mode\",\"U\");\n\t\t$this->RegisterPropertyString(\"Language\",\"de-de\");\n\t\t//$this->RegisterPropertyString(\"Latitude\",\"\");\n\t\t//$this->RegisterPropertyString(\"Longitude\",\"\");\n\t\t//$this->RegisterPropertyString(\"Location\", '{\"latitude\":$this->RegisterPropertyString(\"Latitude\"),\"longitude\":$this->RegisterPropertyString(\"Longitude\")}');\n\t\t$this->RegisterPropertyBoolean(\"Manual_Geodata\",\"0\");\n\t\t$this->RegisterPropertyString(\"Location\", '{\"latitude\":0,\"longitude\":0}');\n\t\t$this->RegisterPropertyInteger(\"ForecastShort\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"CalculateUpcomingRain\",\"0\");\n\t\t$this->RegisterPropertyInteger(\"ForecastDP\",\"0\");\n\t\t$this->RegisterPropertyInteger(\"ForecastInterval\",12);\n\t\t$this->RegisterPropertyBoolean(\"ForecastDPTemperature\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"ForecastDPRain\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"ForecastDPNarrative\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"ForecastDPWind\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"ForecastDPCloudCover\", 0);\n\t\t$this->RegisterPropertyBoolean(\"ForecastDPUV\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"ForecastDPThunder\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"ForecastDPIcon\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"JSONRawForecast\",\"0\");\n\t\t$this->RegisterPropertyInteger(\"OutsideTemperature\", 0);\n\t\t$this->RegisterPropertyInteger(\"Humidity\", 0);\n\t\t$this->RegisterPropertyInteger(\"DewPoint\", 0);\n\t\t$this->RegisterPropertyInteger(\"WindDirection\", 0);\n\t\t$this->RegisterPropertyInteger(\"WindSpeed\", 0);\n\t\t$this->RegisterPropertyInteger(\"WindGust\", 0);\n\t\t$this->RegisterPropertyInteger(\"Rain_last_Hour\", 0);\n\t\t$this->RegisterPropertyInteger(\"Rain24h\", 0);\n\t\t$this->RegisterPropertyInteger(\"AirPressure\", 0);\n\t\t$this->RegisterPropertyInteger(\"UVIndex\", 0);\n\t\t$this->RegisterPropertyInteger(\"SolarRadiation\", 0);\n\t\t$this->RegisterPropertyString(\"WindConversion\", \"ms\");\n\t\t$this->RegisterPropertyInteger(\"Timer\", 0);\n\t\t$this->RegisterPropertyString(\"DLT_WU_ID\", \"\");\n\t\t$this->RegisterPropertyBoolean(\"DLTemperature\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLSolarRadiation\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLUV\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLWindDirection\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLHumidity\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLDewPT\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLWindchill\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLWindSpeed\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLWindGust\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLPressure\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLRainRate\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"DLRainTotal\",\"0\");\n\t\t$this->RegisterPropertyBoolean(\"JSONRawStation\",\"0\");\n\t\t$this->RegisterPropertyInteger(\"DLTimer\", 0);\n\t\t$this->RegisterPropertyBoolean(\"Debug\", 0);\n\n\t\t//Component sets timer, but default is OFF\n\t\t$this->RegisterTimer(\"ForecastTimer\",0,\"WUPWSS_Forecast(\\$_IPS['TARGET']);\");\n\t\t$this->RegisterTimer(\"UpdateTimer\",0,\"WUPWSS_UploadToWunderground(\\$_IPS['TARGET']);\");\n\t\t$this->RegisterTimer(\"PWSDownloadTimer\",0,\"WUPWSS_CurrentPWSData(\\$_IPS['TARGET']);\");\n\n\n\t}", "title": "" }, { "docid": "5b2e6a3aa93d93b5dc3aab3b30c173f4", "score": "0.52682984", "text": "public function run()\n {\n DB::table('appartements')->insert([\n 'type' => 'appartement',\n 'nb_piece' => Str::random(1),\n 'prix' => 5000000,\n 'surface' => 5000000,\n 'localisation' => Str::random(10),\n 'description' => Str::random(10),\n 'status' => Str::random(10),\n ]);\n }", "title": "" }, { "docid": "09dae8e88c02625bc7198f083df7143a", "score": "0.52681524", "text": "public function run()\n {\n \\DB::table('cod_cont')->insert(array(\n 'last_doc' => 'DOC1700000',\n 'last_exp' => 'EXP1700000',\n ));\n }", "title": "" }, { "docid": "b18e651d9c860aa244c6b2707e12848e", "score": "0.526788", "text": "public function wisata_put(){\n $param=$this->put('wisataID');\n $data=array();\n $i=0;\n foreach ($this->put() as $key=>$value ) {\n # code...\n if($value != null){\n $data[$key]= $value;\n }\n }\n\n \n\n if($this->wisata->update_wisata($param,$data)){\n $this->set_response(['status'=>true,'erro'=>'Data berhasil di update'], REST_Controller::HTTP_CREATED);\n }else{\n $this->response(['status' => FALSE,'error' => 'Gagal Mengupdate'], REST_Controller::HTTP_NOT_FOUND); \n } \n \n\n\n }", "title": "" }, { "docid": "e2afbbfa1796bed3a8ab5702a45df7f6", "score": "0.52645534", "text": "public function run()\n {\n DB::table('airports')->insert([\n 'icao' => 'EKCH',\n 'name' => 'Copenhagen, Kastrup',\n ]); \n }", "title": "" }, { "docid": "b237b684e2e30161b58d9ab1dcc280f7", "score": "0.5261666", "text": "public function run()\n {\n db::table('mfb')->insert([\n \t'name' => 'Jell-o',\n \t'calories' => 85\n\n ]);\n }", "title": "" }, { "docid": "321a300dc1058e982fefce751b3c115d", "score": "0.5258665", "text": "public function run()\n {\n $outlt=array(\n [\n 'outlet_name' => 'fariha 1',\n 'outlet_email' => 'fariha@gmail.com',\n 'outlet_phone' => '01936755674',\n 'postal_code' => '1201',\n 'address' => 'Baitul mokaram',\n 'outlet_desc' => 'awsam',\n 'outlet_opentime' => '09:01:01',\n 'outlet_closetime' => '09:01:01',\n 'weekend_day' => 'Friday'\n ]\n \n );\n\n \n DB::table('outlets')->insert($outlt);\n }", "title": "" }, { "docid": "f3ea110ab14d2a7edd970868e0eced7b", "score": "0.5256152", "text": "public function run()\n {\n $file = __DIR__.'/../data/banks.json';\n $data = json_decode(file_get_contents($file), true);\n $banks = array_map(function ($arr) {\n return [\n 'name' => $arr['name'],\n 'alias' => $arr['alias'],\n 'company' => $arr['company'],\n 'code' => $arr['code'],\n 'created_at' => now(),\n 'updated_at' => now(),\n ];\n }, $data);\n\n app('db')->table('tm_banks')->insert($banks);\n }", "title": "" }, { "docid": "160b5d08535725c33f226c91e435385e", "score": "0.5246111", "text": "public function run()\n {\n DB::insert(\"INSERT INTO 'universities' ('id', 'name', 'created_at', 'updated_at') VALUES\n ('1', 'Universitas Jambi', '2019-12-17 00:00:00', '2019-12-17 00:00:00');\n \");\n }", "title": "" }, { "docid": "cd209d533f67d651050f241213229a06", "score": "0.5244495", "text": "public function run()\n {\n // insert data ke table obat\n DB::table('data_obat')->insert([\n \t'nama_obat' => 'Lemah lesu',\n \t'jenis_obat' => 'herbal',\n \t'harga' => '25000',\n \t'pembeli' => 'Brudin',\n \t'gambar' => 'uhuy.jpg'\n ]);\n }", "title": "" }, { "docid": "d9aa6aabe57d9c5d706187f8b6b68e03", "score": "0.52411425", "text": "public static function updateWeather() {\n\t\t$return = [\n\t\t\t'status' => 'OK',\n\t\t\t'message' => ''\n\t\t];\n $locs = self::all();\n\t\tforeach ($locs as $l) {\n\t\t\techo 'started ' . $l->name . \"\\n\";\n\t\t\t$return['message'] .= 'Started ' . $l->name . '; ';\n\t\t\t$ok = false;\n\t\t\t$counter = 0;\n\n\t\t\twhile (!$ok && $counter<5) {\n\t\t\t\t$json = file_get_contents($l->wunderground_api_call);\n\t\t\t\tif (empty($json)) {\n\t\t\t\t\t$counter++;\n\t\t\t\t\t$return['status'] = 'error';\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t$hours = json_decode($json, true)['hourly_forecast'];\n\t\t\t\tif (empty($hours)) {\n\t\t\t\t\t$counter++;\n\t\t\t\t\t$return['status'] = 'error';\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t$ok = true;\n\t\t\t}\n\n\t\t\tif (!$ok) continue;\n\t\t\t$return['status'] = 'OK';\n\n\t\t\tforeach ($hours as $h){\n\t\t\t\t\n\t\t\t\t//temporarily solution for time changing\n\t\t\t\tif ($h['FCTTIME']['hour']==0) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t//end of temporarily solution for time changing\n\t\t\t\t\n\t $pom = $l->forecasts()->where([\n\t\t\t\t\t\t['year', $h['FCTTIME']['year']],\n\t\t\t\t\t\t['month', $h['FCTTIME']['mon']],\n\t\t\t\t\t\t['day', $h['FCTTIME']['mday']],\n\t\t\t\t\t\t['hour', $h['FCTTIME']['hour']]\n\t\t\t\t\t])->first();\n\n\t $pom->cloud_coverage = $h['sky'];\n\t $pom->temperature = $h['temp']['metric'];\n\t $pom->pv_output_correction = $pom->pv_output*(0.1 + (100 - $h['sky']) * 0.01);\n\t\t\t\t$pom->pv_output_max_correction = $pom->pv_output_max*(0.1 + (100 - $h['sky']) * 0.01);\n\n\t\t\t\tif($pom->save()){\n\t echo \"{$pom->location_id}, {$pom->id}, {$pom->year}, {$pom->month}, {$pom->day}, {$pom->hour}, {$pom->cloud_coverage}, {$pom->temperature}°C\\n\";\n\t\t\t\t}\n\t\t\t\t$return['message'] .= $pom->year . '-' . $pom->month . '-' . $pom->day . ': temp ' . $h['temp']['metric'] . '°C, sky ' . $h['sky'] . '%; ';\n\t\t\t}\n\t\t\t$return['message'] .= 'End ' . $l->name . '; ';\n\t\t} // end foreach location\n\n\t\treturn $return;\n }", "title": "" }, { "docid": "7cdb044c0660dd8a3a167a6bf1902715", "score": "0.52367914", "text": "public function run()\n {\n DB::table('biodata')->insert([\n 'nama' => 'Administrator',\n 'no_ktp' => '-',\n 'tempat_lahir' => '-',\n 'tanggal_lahir' => '1998-12-12',\n 'telp' => '-',\n 'alamat' => '-',\n 'desa' => '-',\n 'kecamatan' => '-',\n 'user_id' => 1,\n ]);\n }", "title": "" }, { "docid": "350d71007d7332b8c6721ca6b32f27c5", "score": "0.52334714", "text": "public function run()\n {\n $string = File::get('D:\\\\workspace\\\\laragon\\\\www\\\\cart\\\\database\\\\seeds\\\\countries.json');\n $countries = json_decode($string, true);\n\n Country::insert($countries);\n }", "title": "" }, { "docid": "d4dd77253ead87fb11a431f2a1ccd31d", "score": "0.52320254", "text": "public function actionAddd()\n {\n // $param2 = Yii::$app->request->post('param2', null);\n $dht = new DhtData();\n\n $dht->Temperature = \"128\";\n\n var_dump($dht);\n }", "title": "" }, { "docid": "1cb1db6bab11954cb65d83c000dd3b4d", "score": "0.52300113", "text": "public function run()\n {\n DB::table('device_types')->insert([\n ['type' => 'mobile'],\n ['type' => 'tablet'],\n ]);\n }", "title": "" }, { "docid": "f7e9cb55a2bd9244c932e80c8ab45ca9", "score": "0.522859", "text": "public function run()\n {\n DB::table('rates')->insert([\n 'tax' => '21',\n 'global_discount' => '0',\n ]);\n }", "title": "" }, { "docid": "de33efc237a1674927d35b724847e1ec", "score": "0.52282286", "text": "public function run()\n {\n\n foreach (self::$init_data as $key => $value){\n $count = DB::table(self::$table_name)->where('code',$value['code'])->count();\n if($count == 0) {\n $value['web_site'] = config('system.mall.server_root');\n $value['created_at'] = $value['updated_at'] = date('Y-m-d H:i:s');\n DB::table(self::$table_name)->insert($value);\n }\n }\n\n }", "title": "" }, { "docid": "61760861940c56f0cb275ed14490a7d6", "score": "0.5227531", "text": "public function run()\n {\n DB::table('country')->insert([\n ['name'=>'vietnam'],\n ['name'=>'hanquoc'],\n ['name'=>'phap'],\n ['name'=>'thuysy'],\n ]);\n }", "title": "" }, { "docid": "593f87033edbe679b39f19a0b4d0c1c4", "score": "0.5227042", "text": "public function run()\n {\n \n DB::table('voltage')->insert([\n 'device_id'=>1,\n 'VLL'=>202,\n 'VLN'=>200,\n 'V12'=>205,\n 'V31'=>208,\n 'V1'=>210,\n 'V2'=>222,\n 'V3'=>209,\n ]);\n }", "title": "" }, { "docid": "12aa97a730511fc678313ce0877de5f5", "score": "0.52261966", "text": "public function run()\n {\n //insert some data records\n DB::table('patient_type')->insert(array(\n array('patient_type' => 'inpatient'),\n array('patient_type' => 'outpatient'),\n ));\n }", "title": "" }, { "docid": "cc69753dfcf143efb9f0593028e8c32d", "score": "0.5223578", "text": "public function run()\n {\n City::truncate();//kosongkan table\n\n $key = '35d76cc2082051fe822726a638c3a374';\n\n $getCities = Http::get(\"https://api.rajaongkir.com/starter/city\", [\n 'key' => $key\n ]);\n $cities = $getCities['rajaongkir']['results'];\n\n foreach($cities as $city){\n $data[] = [\n 'id' => $city['city_id'],\n 'city_name' => $city['city_name'],\n 'province_id' => $city['province_id'],\n 'type' => $city['type'],\n 'postal_code' => $city['postal_code'],\n 'created_at' => date('Y-m-d H:i:s')\n ];\n }\n\n City::insert($data);\n }", "title": "" }, { "docid": "0121dad023b712aa7c5593bee7d7d6b7", "score": "0.5219774", "text": "public function run()\n {\n DB::table('car_interiors')->insert([[\n 'car_interior'=> 'Cuero',\n ],[\n 'car_interior'=> 'Semi-Cuero',\n ],[\n 'car_interior'=> 'Sintetico',\n ] ]);\n }", "title": "" }, { "docid": "52e1fbe11fe5e4a0d9a6e692a7be15e5", "score": "0.5214084", "text": "function addMonnaie($data) {\n foreach ($data as $key => $name) {\n //Recuperation de la monnaie en BDD\n $monnaie = $this->checkExistanceMonnaie($key);\n\n if (!$monnaie) {\n $array = array(\n 'name' => $name,\n 'symbol' => $key,\n );\n\n $idMonnaie = $this->sql->insertBDD('monnaie_fiduciaire', $array);\n }\n }\n }", "title": "" }, { "docid": "38ab5cd6fe8caabce078a8218de75339", "score": "0.52047235", "text": "public function run()\n {\n DB::table('buses')->insert([\n 'owner_id' => null,\n 'route_name' => 'Ruta sin destino'\n ]);\n }", "title": "" }, { "docid": "f04de5c7d0555e3dc84f5977a931e73a", "score": "0.5202223", "text": "public function run()\n {\n //\n $cities=file_get_contents(public_path('/database/json/'.'cities.json'));\n $cities=json_decode($cities);\n foreach($cities as $data)\n {\n foreach($data as $key=> $value)\n {\n $finaldata[$key]=$value;\n }\n DB::table('cities')->insert($finaldata);\n }\n \n $this->command->info(\"cities Table Inserted\");\n }", "title": "" }, { "docid": "5c031ccea6c3b6993c1400730251adf4", "score": "0.5196672", "text": "public function run()\n {\n DB::table('doctors')->insert([\n 'firstname' => 'Jose',\n 'middlename' => 'Protacio',\n 'lastname' => 'Rizal',\n 'rate' => 120000,\n 'status' => 'active',\n 'designation' => '',\n 'department' => '',\n 'hospital_id' => 1\n ]);\n }", "title": "" }, { "docid": "5c86b88891b284ef4f71ce712fcd28c3", "score": "0.51963264", "text": "public function run()\n {\n DB::table('musteris')->insert(\n [\n [\n 'musteriadi' => 'demirci',\n 'tel' => '5556664455',\n 'adres' => 'Adana',\n ],\n [\n 'musteriadi' => 'mehmet',\n 'tel' => '4448881122',\n 'adres' => 'Karabük',\n ]\n ]\n );\n }", "title": "" }, { "docid": "d89dfc88a96e93063a687444eb8e0551", "score": "0.51904404", "text": "public function run()\n {\n $data = [\n [\n 'capacity' => 'available',\n \"created_at\" => now(),\n \"updated_at\" => now(),\n ],\n [\n 'capacity' => NULL,\n \"created_at\" => now(),\n \"updated_at\" => now(),\n ],\n [\n 'capacity' => NULL,\n \"created_at\" => now(),\n \"updated_at\" => now(),\n ],\n [\n 'capacity' => NULL,\n \"created_at\" => now(),\n \"updated_at\" => now(),\n ],\n [\n 'capacity' => NULL,\n \"created_at\" => now(),\n \"updated_at\" => now(),\n ],\n [\n 'capacity' => 'full',\n \"created_at\" => now(),\n \"updated_at\" => now(),\n ],\n ];\n DB::table('capacities')->insert($data);\n }", "title": "" }, { "docid": "2fd32b37f9e1d6021291f16060c76a95", "score": "0.51871794", "text": "public function run()\n {\n Countrie::insert([\n \t'id' => 1,\n \t'name' => 'Argentina',\n \t'phonecode' => '+54',\n \t'is_eu_member' => '0'\n ]);\n }", "title": "" }, { "docid": "0a3fd69612535cf5ddbd8982fe287ece", "score": "0.51844656", "text": "public function run()\n {\n //\n DB::table('hospital')->insert(\n [\n 'name' => \"Hospital de UrgÊncias de Goiânia - HUGO\",\n 'address' => \"Av. 1ª Radial - St. Pedro Ludovico, Goiânia - GO, 74855-700\",\n 'latitude' => -16.7087059,\n 'longitude' => -49.2567424,\n 'created_at' => date(\"Y-m-d H:i:s\"),\n 'updated_at' => date(\"Y-m-d H:i:s\"),\n ]);\n\n }", "title": "" }, { "docid": "a17c6050030deaeb28023d0e1144ca53", "score": "0.5182691", "text": "function create(WeatherDataItem $weatherData)\n {\n }", "title": "" }, { "docid": "4493a181b1e0292e72f8be05d6725653", "score": "0.5180413", "text": "public function run()\n {\n $datas = [\n \t['name' => 'Ultrabyte Pvt. Ltd.', 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(), 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()],\n \t['name' => 'Vurung Pvt. Ltd.', 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(), 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()],\n \t['name' => 'Nepal NGOs Pvt. Ltd.', 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(), 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()],\n ];\n\n \\Illuminate\\Support\\Facades\\DB::table('companies')->insert($datas);\n }", "title": "" }, { "docid": "5455de2aa9e6e9356e2b070b33e25f24", "score": "0.517816", "text": "public function store()\n\t{\n\t\tReading::create(array(\n\t\t\t'device' => Input::get('device'),\n\t\t\t'temp' => Input::get('temp'),\n\t\t\t'heaton' => Input::get('heaton')\n\t\t));\n\n\t\treturn Response::json(array('success' => true));\n\t}", "title": "" }, { "docid": "1d4b6297afc29aedede5d11b3621eb08", "score": "0.51767457", "text": "public function run()\n {\n DB::table('markers')->insert([\n 'nama' => 'Museum Benteng Vredeburg',\n 'alamat' => 'Jl. Jend. A. Yani No.6 , Yogyakarta',\n 'lat' => -7.800330,\n 'lng' => 110.365967,\n\t\t\t'tipe' => 'museum',\n ]);\n }", "title": "" }, { "docid": "8b1bd5862ade57695cbc5c1f1206be73", "score": "0.51759905", "text": "public function run()\n {\n\t\tDB::table($this->table)->insert($this->getData());\n }", "title": "" }, { "docid": "9e71e21e4798b50a9e7e6413f8df719b", "score": "0.5174239", "text": "public function run()\n {\n DB::table('locations')->truncate();\n\n DB::table('locations')->insert([\n 'user_id' => 1,\n 'sensor_id' => 1,\n 'lat' => '47.913868',\n 'lon' => '106.908141',\n 'ip' => '127.0.0.1',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n }", "title": "" }, { "docid": "30ec0d064bbcecba082fab43e9c61125", "score": "0.5173944", "text": "public function saveInYf(): void\n\t{\n\t\tforeach ($this->dataYf as $key => $value) {\n\t\t\t$this->recordModel->set($key, $value);\n\t\t}\n\t\tif ($this->recordModel->isEmpty('assigned_user_id')) {\n\t\t\t$this->recordModel->set('assigned_user_id', $this->synchronizer->config->get('assigned_user_id'));\n\t\t}\n\t\tif (\n\t\t\t$this->recordModel->isEmpty('woocommerce_id')\n\t\t\t&& $this->recordModel->getModule()->getFieldByName('woocommerce_id')\n\t\t\t&& !empty($this->dataApi['id'])\n\t\t) {\n\t\t\t$this->recordModel->set('woocommerce_id', $this->dataApi['id']);\n\t\t}\n\t\t$this->recordModel->set('woocommerce_server_id', $this->synchronizer->config->get('id'));\n\t\t$isNew = empty($this->recordModel->getId());\n\t\t$this->recordModel->save();\n\t\t$this->recordModel->ext['isNew'] = $isNew;\n\t\tif ($isNew && $this->recordModel->get('woocommerce_id')) {\n\t\t\t$this->synchronizer->updateMapIdCache(\n\t\t\t\t$this->recordModel->getModuleName(),\n\t\t\t\t$this->recordModel->get('woocommerce_id'),\n\t\t\t\t$this->recordModel->getId()\n\t\t\t);\n\t\t}\n\t}", "title": "" }, { "docid": "ab7e38316303b21c4383d95ee6b3010a", "score": "0.51733273", "text": "public function run()\n {\n DB::table('fixed_value_coupons')->insert([\n 'value' => 10,\n ]);\n }", "title": "" }, { "docid": "82e5e17d9a5010239796170589caec7e", "score": "0.5170132", "text": "public function run()\n {\n DB::table('sectors')->insert($data = array(\n [\n 'sector'=> 'La Romana',\n 'parish_id'=> '156',\n 'created_at'=> new DateTime,\n 'updated_at'=> new DateTime\n ])\n\n );\n }", "title": "" }, { "docid": "1b8f8f265fa7a6d7ef9290ac361b0398", "score": "0.51694256", "text": "public function run()\n {\n \t$equipment = [\n\t\t\t[\n\t\t\t\t'equipmentName' => 'Контролер'\n\t\t\t],\n\t\t\t[\n\t\t\t\t'equipmentName' => 'Газ-анализаторна система'\n\t\t\t],\n\t\t\t[\n\t\t\t\t'equipmentName' => 'Прахомер'\n\t\t\t],\n\t\t\t[\n\t\t\t\t'equipmentName' => 'Кислородомер'\n\t\t\t],\n\t\t\t[\n\t\t\t\t'equipmentName' => 'Разходомер'\n\t\t\t]\n ];\n\n DB::table('equipment')->insert($equipment);\n }", "title": "" }, { "docid": "e04e962711ed63479a5d28a939cf2b77", "score": "0.5168645", "text": "public function run()\n {\n DB::table('vehicles')->insert([\n 'name' => 'DMC Delorean',\n 'register' => '2255'\n ]);\n\n DB::table('vehicles')->insert([\n 'name' => 'Relâmpago Marquinhos',\n 'register' => '112233'\n ]);\n\n DB::table('vehicles')->insert([\n 'name' => 'Fuscão Preto',\n 'register' => '225588'\n ]);\n }", "title": "" }, { "docid": "ef2ce5087a9a863a4782bfbfe8ca57b7", "score": "0.51663965", "text": "public function run()\n {\n DB::table('roads')->insert([\n\n \n 'name' =>'Chia', //maybe\n\t\t\t'route' => 'novena 170',\n \n ]);\n }", "title": "" }, { "docid": "6cadbd616f977f411e763f35ef4dee9b", "score": "0.51622885", "text": "public function run()\n {\n //\n DB::table('instrumentos')->insert([\n 'nome' => 'Violão'\n ]);\n DB::table('instrumentos')->insert([\n 'nome' => 'Piano'\n ]);\n DB::table('instrumentos')->insert([\n 'nome' => 'Saxofone'\n ]);\n }", "title": "" }, { "docid": "282a9c09be05aaf271301484fb53962c", "score": "0.5161794", "text": "public function onInit() {\n\t\tglobal $db;\n\n\t\t$sql = \"\n\t\t\tCREATE TABLE `sapphire_waves` (\n\t\t\t\t`id` INT NOT NULL AUTO_INCREMENT,\n\t\t\t\t`user` INT DEFAULT NULL,\n\t\t\t\t`type` INT DEFAULT NULL,\n\t\t\t\t`referral` INT DEFAULT NULL,\n\t\t\t\t`remaining_time` INT DEFAULT NULL,\n\t\t\t\t`total_time` INT DEFAULT NULL,\n\t\t\t\t`expires` TIMESTAMP DEFAULT CURRENT_TIMESTAMP,\n\t\t\t\t`active` BOOLEAN NOT NULL DEFAULT '1',\n\t\t\t\tPRIMARY KEY (`id`),\n\t\t\t\tINDEX (`user`),\n\t\t\t\tINDEX (`type`),\n\t\t\t\tINDEX (`referral`)\n\t\t\t) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin AUTO_INCREMENT=0;\";\n\t\t$db->query($sql);\n\n\t\t$sql = \"\n\t\t\tCREATE TABLE `sapphire_waves_statistics` (\n\t\t\t\t`id` INT NOT NULL AUTO_INCREMENT,\n\t\t\t\t`user` INT DEFAULT NULL,\n\t\t\t\t`usage` INT DEFAULT NULL,\n\t\t\t\t`timestamp` DATE DEFAULT NULL,\n\t\t\t\tPRIMARY KEY (`id`),\n\t\t\t\tINDEX `index_by_user` (`user`),\n\t\t\t\tINDEX `index_for_update` (`user`, `timestamp`)\n\t\t\t) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin AUTO_INCREMENT=0;\";\n\t\t$db->query($sql);\n\n\t\t$sql = \"\n\t\t\tCREATE TABLE `sapphire_waves_trial` (\n\t\t\t\t`id` INT NOT NULL AUTO_INCREMENT,\n\t\t\t\t`address` VARCHAR(45) DEFAULT NULL,\n\t\t\t\t`times_used` INT DEFAULT NULL,\n\t\t\t\t`timestamp` INT DEFAULT NULL,\n\t\t\t\tPRIMARY KEY (`id`),\n\t\t\t\tINDEX `index_by_address` (`address`)\n\t\t\t) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin AUTO_INCREMENT=0;\";\n\t\t$db->query($sql);\n\n\t\t// trial period\n\t\t$this->saveSetting('trial_time', 5);\n\t\t$this->saveSetting('trial_period', 7);\n\t}", "title": "" }, { "docid": "98a444a9ea6842539a3bef27fe0a2bd7", "score": "0.51617616", "text": "public function run()\n {\n //\n DB::table('Hostels')->insert([\n 'photo' => 'accommodation.jpeg',\n 'name' => 'Carleton Executive Students Hostel',\n 'price' => '700000-120000',\n 'custodian' => 'Resty Nabakoza',\n 'location' => 'Bugujju',\n 'category' => 'Mixed Sex',\n 'phone' => '+256783013570' \n ]);\n }", "title": "" }, { "docid": "b9d85ddecd59c92591d559efc79523a7", "score": "0.5161569", "text": "public function run()\n {\n $today = Carbon::today();\n DB::table('photobooks')->insert([\n [\n 'photobook' => 'Wedding Photobook 20cm x 30cm',\n 'price' => 400000,\n 'created_at' => date($today),\n 'updated_at' => date($today)\n ]\n ]);\n }", "title": "" }, { "docid": "3ec499bcbed3374fc73f23fe50d2b6cb", "score": "0.5160457", "text": "public function run()\n {\n DB::table('breed')->insert([\n \t['name'=>'Husky'],\n \t['name'=>'Alaska'],\n \t['name'=>'Pomeranian'],\n\n ]);\n }", "title": "" }, { "docid": "c9a18e5fa62882efb7ec96534e16969a", "score": "0.5158719", "text": "public function run()\n {\n $fiatProviderDetails = $this->loadData('fiatProviderDetails');\n\n DB::table('fiat_provider_details')->insert($fiatProviderDetails);\n }", "title": "" }, { "docid": "0194a3c875cc192c52626c9841ed14bd", "score": "0.51585674", "text": "public function run()\n {\n\t\tforeach (self::$init_data as $key => $value){\n\t\t\t$count = DB::table(self::$table_name)\n\t\t\t\t->where('word_code',$value['word_code'])\n\t\t\t\t->where('language_type_code',$value['language_type_code'])\n\t\t\t\t->count();\n\t\t\tif($count == 0){\n\t\t\t\t$time = date('Y-m-d H:i:s');\n\t\t\t\t$value['created_at'] = $value['updated_at'] = $time;\n\t\t\t\tDB::table(self::$table_name)->insert($value);\n\t\t\t}\n\t\t}\n }", "title": "" }, { "docid": "5167476af4ec8bd4c0b1512c758e6d3d", "score": "0.5154366", "text": "public function run() {\n foreach ($this->data as $value) {\n DetailsTransport::create([\n 'code' => $value['code'],\n 'name' => $value['name'],\n 'description' => $value['description'],\n 'transport' => $value['transport']\n ]);\n }\n }", "title": "" }, { "docid": "d9d826aec0cf356e3c50a02b12ae08d8", "score": "0.5154273", "text": "public function run() {\n $list = [];\n $types = [\"Dell\", \"Acer\", \"Asus\", \"SamSung\", \"HP\",\n \"Lenovo\", \"Xiaomi\", \"LG\", \"MSI\", \"MacBook\"];\n sort($types);\n $today = new DateTime('2019-01-01 08:00:00');\n for ($i=1; $i <= count($types); $i++) {\n array_push($list, [\n 'l_ma' => $i,\n 'l_ten' => $types[$i-1],\n 'l_taoMoi' => $today->format('Y-m-d H:i:s'),\n 'l_capNhat' => $today->format('Y-m-d H:i:s')\n ]);\n }\n DB::table('cusc_loai')->insert($list);\n }", "title": "" }, { "docid": "06b63a1edf06606904eb99b522fd299a", "score": "0.5153952", "text": "public function run()\n {\n DB::table('hospitals')->insert([\n 'name' => 'KPJ Johor Specialist Hospital',\n 'address' => '39B, Jalan Abdul Samad, Kolam Ayer, 80100 Johor Bahru, Johor, Malaysia',\n 'email' => 'KPJ@specialist.com',\n 'contact' => '07-225 3000',\n 'map_lat' => '1.475979',\n 'map_lng' => '103.74124200000006',\n 'place_id' => 'ChIJk8Bjl7IS2jERmnURVrR-s0o',\n 'formatted_address' => 'Kolam Ayer',\n 'created_at' => Carbon::now()->format('Y-m-d H:i:s'),\n 'updated_at' => Carbon::now()->format('Y-m-d H:i:s'),\n ]);\n }", "title": "" }, { "docid": "8d14694d6691e499cf49eec25afe070a", "score": "0.5152744", "text": "public function run()\n {\n DB::table('coupons')->insert([\n 'code' => 'TWITCHTV',\n 'qty' => '1000',\n 'daily_reset' => 0,\n 'start_time' => Carbon::now(),\n 'end_time' => Carbon::now()->addMonths(2),\n 'rate' => 50,\n 'max_cut' => 0,\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n 'event_id' => 1\n ]);\n }", "title": "" }, { "docid": "2117f34da3f7584fb5e714dfbe260848", "score": "0.5145728", "text": "public function __construct($location)\n {\n $this->location = $location;\n //query=[Taipei];//,例如: Taoyuan Air Base , Taipei\n $xml = simplexml_load_file(\n \"http://api.wunderground.com/auto/wui/geo/WXCurrentObXML/index.xml?query=$location\"\n );\n\n\n \n $wea=$xml->weather;\n\n \n $tem=$xml->temp_c;\n\n $mus=$xml->relative_humidity;\n\n $wind=$xml->wind_dir;\n //date_default_timezone_set('Asia/Taipei');\n $time = date(\n 'Y-m-d H:i',\n strtotime($xml->local_time)\n );\n \n if($wea==\"thunderstorm rain\"){ $wea= \"雷雨 \";}\n if($wea==\"light showers rain\"){ $wea= \"小驟雨 \";}\n if($wea==\"flurries\"){ $wea= \"小雪 \";}\n if($wea==\"Cloudy\"){ $wea= \"霧 \";}\n if($wea==\"Haze\"){ $wea= \"陰霾 \";}\n if($wea==\"Mostly Cloudy\"){ $wea= \"多雲時陰\";}\n if($wea==\"Mostly Sunny\"){ $wea= \"晴時多雲\";}\n if($wea==\"Partly Cloudy\"){ $wea= \"局部多雲\";}\n if($wea==\"Partly Sunny\"){ $wea= \"多雲時晴\";}\n if($wea==\"thunderstorm rain\"){ $wea= \"凍雨\";}\n if($wea==\"Rain\"){ $wea= \"雨 \";}\n if($wea==\"Sleet\"){ $wea= \"冰雹 \";}\n if($wea==\"Snow\"){ $wea= \"雪 \";}\n if($wea==\"Sunny\"){ $wea= \"晴朗 \";}\n if($wea==\"Unknown\"){ $wea= \"未知 \";}\n if($wea==\"Overcast\"){ $wea= \"陰天 \";}\n if($wea==\"Scattered Clouds\"){ $wea= \"疏雲 \";}\n \n $this->text = '氣象狀況:'.$wea.' 溫度:'.$tem.' 相對濕度: '.$mus.' 風向: '.$wind.' 時間:'.$time;\n \n /*\n showers rain = 驟雨\n light showers rain = 小驟雨\n\n Cloudy = 多雲\n Flurries = 小雪\n Fog = 霧\n Haze = 陰霾\n Mostly Cloudy = 多雲時陰\n Mostly Sunny = 晴時多雲\n Partly Cloudy = 局部多雲\n Partly Sunny = 多雲時晴\n Freezing Rain = 凍雨\n Rain = 雨\n Sleet = 冰雹\n Snow = 雪\n Sunny = 晴朗\n Unknown = 未知\n Overcast = 陰天\n Scattered Clouds = 疏雲 \n */\n \n \n \n\n \n \n \n \n \n \n \n \n }", "title": "" }, { "docid": "51e804809f8dc1ff01329a56ed2a508f", "score": "0.51451355", "text": "public function run()\n {\n //\n $u=[\n \t['NIS'=>'1212111','nama'=>'David','tempat_lahir'=>'Situ Tarate','tanggal_lahir'=>'2002-03-14','alamat'=>'Cibaduyut','citacita'=>'Wartawan','hobi'=>'Edit Foto','gambar'=>'s1.jpg']];\n DB::table('siswas')->insert($u);\n }", "title": "" } ]
d7b02231a60df1b4f082d125ff7f5ce3
Fills all of the leafnode values of a nested array with the provided replacement value.
[ { "docid": "e29612e6d9827fc13ba671f63d8a3365", "score": "0.594356", "text": "public static function fillRecursive(array $data, $fill)\n {\n $result = [];\n foreach ($data as $key => $value) {\n $result[$key] = $fill;\n if (self::isAssociative($value)) {\n $result[$key] = self::fillRecursive($value, $fill);\n }\n }\n return $result;\n }", "title": "" } ]
[ { "docid": "dd28dc6bde13f556e448baa3fd998fc8", "score": "0.59711814", "text": "function array_merge_replace($array, $newValues)\n {\n foreach ($newValues as $key => $value) {\n if (is_array($value)) {\n if (!isset($array[$key])) {\n $array[$key] = array();\n }\n $array[$key] = MyOOS_Utilities::array_merge_replace($array[$key], $value);\n } else {\n if (isset($array[$key]) && is_array($array[$key])) {\n $array[$key][0] = $value;\n } else {\n if (isset($array) && !is_array($array)) {\n $temp = $array;\n $array = array();\n $array[0] = $temp;\n }\n $array[$key] = $value;\n }\n }\n }\n return $array;\n }", "title": "" }, { "docid": "86c2b7a79f4c0261a264c6d61d7a27aa", "score": "0.595323", "text": "abstract public function fill (array $data);", "title": "" }, { "docid": "5d39ae90e3ee59ca252edf956ed8830a", "score": "0.57736576", "text": "public function arrayMergeRecursiveReplace() {\r\n $params = func_get_args();\r\n\r\n // First array is used as the base, everything else overwrites on it\r\n $return = array_shift($params);\r\n\r\n // Merge all arrays on the first array\r\n foreach ($params as $array) {\r\n foreach ($array as $key => $value) {\r\n // Numeric keyed values are added (unless already there)\r\n if (is_numeric($key) && (!in_array($value, $return))) {\r\n if (is_array($value)) {\r\n $return[] = $this->arrayMergeRecursiveReplace($return[$key], $value);\r\n } else {\r\n $return[] = $value;\r\n }\r\n // String keyed values are replaced\r\n } else {\r\n if (isset($return[$key]) && is_array($value) && is_array($return[$key])) {\r\n $return[$key] = $this->arrayMergeRecursiveReplace($return[$key], $value);\r\n } else {\r\n $return[$key] = $value;\r\n }\r\n }\r\n }\r\n }\r\n\r\n return $return;\r\n }", "title": "" }, { "docid": "f423feab5fa8318c797fd8fb6db108fe", "score": "0.5658626", "text": "function array_set(&$array, $key, $value)\n\t{\n\t\t//\tIf no key is given to the method, the entire array will be replaced\n\t\tif (is_null($key))\n\t\t{\n\t\t\treturn $array = $value;\n\t\t}\n\n\t\t$keys = explode('.', $key);\n\n\t\twhile (count($keys) > 1)\n\t\t{\n\t\t\t$key = array_shift($keys);\n\n\t\t\t//\tIf the key doesn't exist at this depth, we will just create\n\t\t\t//\tan empty array to hold the next value, allowing us to create\n\t\t\t//\tthe arrays to hold final values at the correct depth. Then\n\t\t\t//\twe'll keep digging into the array.\n\t\t\tif ( ! isset($array[$key]) OR ! is_array($array[$key]))\n\t\t\t{\n\t\t\t\t$array[$key] = array();\n\t\t\t}\n\n\t\t\t$array =& $array[$key];\n\t\t}\n\n\t\t$array[array_shift($keys)] = $value;\n\n\t\treturn $array;\n\t}", "title": "" }, { "docid": "8d88c06f9d8628e904b6dbc95fcf15b3", "score": "0.56335956", "text": "function set(&$array, $key, $value)\n\t{\n\t\t//\tIf no key is given to the method, the entire array will be replaced\n\t\tif (is_null($key))\n\t\t{\n\t\t\treturn $array = $value;\n\t\t}\n\n\t\t$keys = explode('.', $key);\n\n\t\twhile (count($keys) > 1)\n\t\t{\n\t\t\t$key = array_shift($keys);\n\n\t\t\t//\tIf the key doesn't exist at this depth, we will just create\n\t\t\t//\tan empty array to hold the next value, allowing us to create\n\t\t\t//\tthe arrays to hold final values at the correct depth. Then\n\t\t\t//\twe'll keep digging into the array.\n\t\t\tif ( ! isset($array[$key]) OR ! is_array($array[$key]))\n\t\t\t{\n\t\t\t\t$array[$key] = array();\n\t\t\t}\n\n\t\t\t$array =& $array[$key];\n\t\t}\n\n\t\t$array[array_shift($keys)] = $value;\n\n\t\treturn $array;\n\t}", "title": "" }, { "docid": "c9549d740980451fac13e2403e4f268b", "score": "0.56042206", "text": "private function replaceArrayKey(array &$array, string $search, string $replacement): void {\n $keys = array_keys($array);\n if (FALSE === ($index = array_search($search, $keys, TRUE))) {\n throw new \\UnexpectedValueException(sprintf('Key \"%s\" does not exist in the config array', $search));\n }\n $keys[$index] = $replacement;\n $array = array_combine($keys, array_values($array));\n }", "title": "" }, { "docid": "0220a0cc3aaa1b191719a2b29a2641a2", "score": "0.5564112", "text": "private function _set(array &$array, $key, $value) {\n if (is_null($key)) return $array = $value;\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if ( ! isset($array[$key]) || ! is_array($array[$key])) {\n $array[$key] = array();\n }\n\n $array =& $array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "b098b4d0b38b884a63b5ec0c8da8d52a", "score": "0.55347496", "text": "function jua_deep_set(array &$array, $path, $value):array {\n\t$pathParts = ju_explode_xpath($path); /** @var string[] $pathParts */\n\t$a = &$array; /** @var array(string => mixed) $a */\n\twhile ($pathParts) {\n\t\t$key = array_shift($pathParts); /** @var string $key */\n\t\tif (!isset($a[$key])) {\n\t\t\t$a[$key] = [];\n\t\t}\n\t\t$a = &$a[$key];\n\t\tif (!is_array($a)) {\n\t\t\t$a = [];\n\t\t}\n\t}\n\t$a = $value;\n\treturn $array;\n}", "title": "" }, { "docid": "aa4a733d9c36a8a7a757a3cad66d8d62", "score": "0.55064636", "text": "function fill_grades($array = null) {\n if (empty($array)) {\n $array = $this->tree_array;\n }\n\n if (empty($array)) {\n return null;\n } else {\n foreach ($array as $level1order => $level1) {\n // If $level1 is a category, enter another recursive layer\n if ($this->get_element_type($level1) == 'topcat' || $this->get_element_type($level1) == 'subcat') {\n $this->fill_grades($level1['children']);\n } else {\n if (!empty($level1['finalgrades'])) {\n foreach ($level1['finalgrades'] as $final_grade) {\n $this->grades[$final_grade->userid][$final_grade->itemid] = $final_grade->finalgrade;\n }\n }\n }\n }\n\n reset($array);\n return true;\n }\n }", "title": "" }, { "docid": "38930f5b28974689c25705d2dfa9a6cc", "score": "0.5492513", "text": "function UpdateRecursive($vals) {\n $params = array();\n $this->global_index++;\n //Reached end of array\n if($this->global_index >= count($vals))\n return;\n\n $tag = strtolower($vals[$this->global_index]['tag']);\n if (isset(trim($vals[$this->global_index]['value']))) {\n $value = trim($vals[$this->global_index]['value']);\n }\n $type = $vals[$this->global_index]['type'];\n\n //Add attributes\n if(isset($vals[$this->global_index]['attributes'])) {\n foreach($vals[$this->global_index]['attributes'] as $key=>$val) {\n $key = strtolower($key);\n $params[$tag][$key] = $val;\n }\n }\n\n if($type == 'open') {\n $new_arr = array();\n\n //Read all elements at the next levels and add to an array\n while($vals[$this->global_index]['type'] != 'close' && \n $this->global_index < count($vals)) {\n $arr = $this->UpdateRecursive($vals);\n if(count($arr) > 0) {\n $new_arr[] = $arr;\n }\n }\n $this->global_index++;\n foreach($new_arr as $arr) {\n foreach($arr as $key=>$val) {\n if(isset($params[$tag][$key])) {\n //If this key already exists\n if($this->is_associative_array($params[$tag][$key])) {\n //If this is an associative array and not an indexed array\n // remove exisiting value and convert to an indexed array\n $val_key = $params[$tag][$key];\n array_splice($params[$tag][$key], 0);\n $params[$tag][$key][0] = $val_key;\n $params[$tag][$key][] = $val;\n } else {\n $params[$tag][$key][] = $val; \n }\n } else {\n $params[$tag][$key] = $val;\n }\n }\n }\n }\n else if ($type == 'complete') {\n if($value != '') \n $params[$tag]['VALUE'] = $value;\n }\n else {\n $params = array();\n }\n return $params;\n }", "title": "" }, { "docid": "eac666996562e456c1a9a8a5aa38f260", "score": "0.54698616", "text": "function kore_array_inherit(&$arr) {\r\n $arr_root = array_filter($arr, 'kore_array_filter_array');\r\n foreach ($arr as $key => $item) {\r\n if (is_array($item)) {\r\n $arr[$key] = array_merge($arr_root, $item);\r\n kore_array_inherit($arr[$key]);\r\n }\r\n }\r\n}", "title": "" }, { "docid": "c0b178856363b957d09db0442184ce0d", "score": "0.5379524", "text": "function array_setEx(&$array, $key, $value)\n {\n if (is_null($key)) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n foreach ($keys as $i => $key) {\n if (count($keys) === 1) {\n break;\n }\n\n unset($keys[$i]);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (!isset($array[$key]) || !is_array($array[$key])) {\n $array[$key] = [];\n }\n\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "67c40a44ac49885bbdee5efc7c86f5c9", "score": "0.5378935", "text": "public function fill($source)\n {\n $prefix = $this->getPrefix();\n if ($prefix && array_key_exists($prefix, $source)) {\n $source = $source[$prefix];\n }\n\n foreach ($this->getChildren() as $name => $child) {\n if ($child instanceof Set) {\n// try {\n if ($child->getPrefix() && is_array($source) && array_key_exists($child->getPrefix(), $source)) {\n $child->fill($source[$child->getPrefix()]);\n } elseif (!$child->getPrefix()) {\n $child->fill($source);\n }\n// }catch(\\ErrorException $e){\n//\n// var_dump('asda');die;\n//\n// }\n\n } else {//if instanceof Element\n if (array_key_exists($child->getName(), (array)$source)) {\n $child->setValue($source[$child->getName()]);\n\n }\n }\n }\n return;\n }", "title": "" }, { "docid": "2ed58ef4e776c1a8ac14a28cc9dae4df", "score": "0.5342552", "text": "public function setLeafValues($data) {\n if (!$data) {echo \"return\"; return;}\n foreach ($data as $key => $val) {\n $this->tree['leaves'][$key] = $val;\n }\n }", "title": "" }, { "docid": "c8d1c37d7e71568da8dd035c9dffadf2", "score": "0.53406227", "text": "function correctArray($arr) {\n\t\tif (isset($arr['children'])) {\n\t\t\tif (trim($arr['Value']) != '') {\n\t\t\t\t$tmp = $arr['Value'];\n\t\t\t\tforeach ($arr['children'] AS $key => $subArr) {\n\t\t\t\t\tif ($subArr['name'] != $arr['name']) {\n\t\t\t\t\t\t$tmp .= '&lt;' . $subArr['name'] . '&gt;' . $subArr['Value'] . '&lt;/' . $subArr['name'] . '&gt;';\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$tmp .= $subArr['Value'];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tunset($arr['children']);\n\t\t\t\t$arr['Value'] = $tmp;\n\t\t\t} else {\n\t\t\t\tforeach ($arr['children'] AS $key => $subArr) {\n\t\t\t\t\t$arr['children'][$key] = $this -> correctArray($subArr);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $arr;\n\t}", "title": "" }, { "docid": "e6ced9873e6740090cd181c050f008fd", "score": "0.5305135", "text": "private function _buildReplaceArrayRecurse(&$build, $current, $prefix=null)\n\t{\n\t\tforeach ($current as $k => $v) {\n\t\t\t$field = $k;\n\t\t\tif (!is_null($prefix)) {\n\t\t\t\t$field = $prefix . '[' . $field . ']';\n\t\t\t}\n\t\t\tif (is_array($v)) {\n\t\t\t\t\n\t\t\t\tif (SubmissionValidator_Filter::isLinearArray($v)) {\n\t\t\t\t\t$build['{' . $field . '}'] = implode(',', $v);\n\t\t\t\t\t$build['{label:' . $field . '}'] = $this->getLabel($field);\n\t\t\t\t} else {\n\t\t\t\t\t$this->_buildReplaceArrayRecurse($build, $v, $field);\n\t\t\t\t\t$inner_glue = '=';\n\n\t\t\t\t\t$vals = array();\n\t\t\t\t\tforeach($v as $k=>$val) {\n\t\t\t\t\t\t$vals[] = \"$k=$val\";\n\t\t\t\t\t}\n\n\t\t\t\t\t$build['{' . $field . '}'] = implode(',', $vals);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$build['{' . $field . '}'] = $v;\n\t\t\t\t$build['{label:' . $field . '}'] = $this->getLabel($field);\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "9188c889d2cabc4af25cf7572d719e8c", "score": "0.53026026", "text": "public function populate(&$value)\n\t{\n\t\tif(is_array($value))\n\t\t{\n\t\t\tfor($i = 0; $i < $this->_repetitions; $i++)\n\t\t\t{\n\t\t\t\tif(isset($value[$i]))\n\t\t\t\t{\n\t\t\t\t\t$this->_wrappers[$i]->populate($value[$i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "78f89a92b4099564203af71783eae67a", "score": "0.5287056", "text": "public function fill($values)\n {\n foreach ($values as $value_id => $value) {\n if (isset($this->data['fields'][$value_id])) {\n $this->data['fields'][$value_id]['value'] = $value;\n }\n }\n }", "title": "" }, { "docid": "79f487105d78782f0df49b671da3c64f", "score": "0.52724105", "text": "function array_set(&$array, $key, $value)\n {\n if (is_null($key)) return $array = $value;\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1)\n {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if ( ! isset($array[$key]) || ! is_array($array[$key]))\n {\n $array[$key] = array();\n }\n\n $array =& $array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "eceb8af02516bff8873e8a6c2d264f78", "score": "0.5272002", "text": "function array_set(&$array, $key, $value)\n {\n if (is_null($key)) return $array = $value;\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (!isset($array[$key]) || !is_array($array[$key])) {\n $array[$key] = array();\n }\n\n $array =& $array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "2c84af4fe86cf17c942a42762932dee5", "score": "0.5262654", "text": "function set(&$array, $key, $value)\n {\n if (is_null($key)) return $array = $value;\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1)\n {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if ( ! isset($array[$key]) || ! is_array($array[$key]))\n {\n $array[$key] = array();\n }\n\n $array =& $array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "717e31a4e958cb6b5e607b275fe35ccd", "score": "0.52577347", "text": "function set(&$array, $key, $value)\n {\n if (is_null($key)) return $array = $value;\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (!isset($array[$key]) || !is_array($array[$key])) {\n $array[$key] = array();\n }\n\n $array =& $array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "299abb7d212d8e6b0c5d9b77c8669f1b", "score": "0.52120954", "text": "private function set(array &$array, string $expression = null, $value = null) :void\n {\n $index = &$array;\n $keys = explode('.', $expression);\n $count = count($keys)-1;\n foreach ($keys as $i => $key) {\n if($i < $count) {\n if(isset($index[$key])) {\n $index = &$index[$key];\n }else{\n if(is_string($index)) {\n $index = [];\n }\n $index[$key] = [];\n $index = &$index[$key];\n }\n }else{\n if(!isset($index[$key])) {\n if(is_string($index)) {\n $index = [];\n }\n $index[$key] = '';\n }\n $index = &$index[$key];\n $index = $value;\n }\n }\n }", "title": "" }, { "docid": "f6d09a110e2c18066b991c57f156d126", "score": "0.51959044", "text": "public static function set(&$array, $path, $value) {\n $reference =& Set::extractReference($array, $path);\n if(is_array($reference) && !is_array($value)) {\n foreach($reference as $key => &$ref) {\n $ref = $value;\n }\n } else {\n $reference = $value;\n }\n }", "title": "" }, { "docid": "d0e0238f2c808ecaa5e236abb7225db1", "score": "0.5169967", "text": "function setArrayValue(&$array, $stack, $value) {\n if ($stack) {\n $key = array_shift($stack);\n setArrayValue($array[$key], $stack, $value);\n return $array;\n } else {\n $array = $value;\n }\n}", "title": "" }, { "docid": "0c1daad2f1f7226079c3f9d19f7856c0", "score": "0.5147323", "text": "public function replace(array $data)\n {\n $this->array = $data;\n return $this;\n }", "title": "" }, { "docid": "046eaaafa0184245ce5b0838ef0fd1c7", "score": "0.51305115", "text": "public static function fillToSize(&$array, $size, $fill)\n {\n $cnt = \\count($array);\n if ($cnt >= $size) {\n return;\n }\n $array = array_merge($array, array_fill($cnt + 1, $size - $cnt, $fill));\n }", "title": "" }, { "docid": "0135409174dfbb55cfc66c8ee985ef86", "score": "0.5063938", "text": "function updateValues($arr) {\n foreach($this->element as $k=>$v) {\n $value = null;\n if ( isset($arr[$v->name]) ) {\n $value = $arr[$v->name];\n }\n $this->element[$k]->setValue( $value );\n }\n }", "title": "" }, { "docid": "c6a2020bd777dd3def3cb041bdb3df8f", "score": "0.5054151", "text": "public static function replaceFill($_data)\n\t{\n\t\tif(!self::$fill)\n\t\t{\n\t\t\treturn $_data;\n\t\t}\n\n\t\t// replace all texts\n\t\tif(isset($_data['text']))\n\t\t{\n\t\t\tforeach (self::$fill as $search => $replace)\n\t\t\t{\n\t\t\t\t$search\t= '_'.$search.'_';\n\t\t\t\t$_data['text'] = str_replace($search, $replace, $_data['text']);\n\t\t\t}\n\t\t}\n\n\t\t// replace all texts\n\t\tif(isset($_data['caption']))\n\t\t{\n\t\t\tforeach (self::$fill as $search => $replace)\n\t\t\t{\n\t\t\t\t$search\t= '_'.$search.'_';\n\t\t\t\t$_data['caption'] = str_replace($search, $replace, $_data['caption']);\n\t\t\t}\n\t\t}\n\n\t\tif(isset($_data['reply_markup']['keyboard']))\n\t\t{\n\t\t\tforeach ($_data['reply_markup']['keyboard'] as $itemRowKey => $itemRow)\n\t\t\t{\n\t\t\t\tforeach ($itemRow as $key => $itemValue)\n\t\t\t\t{\n\t\t\t\t\tif(!is_array($itemValue))\n\t\t\t\t\t{\n\t\t\t\t\t\tforeach (self::$fill as $search => $replace)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$search\t= '_'.$search.'_';\n\t\t\t\t\t\t\t$newValue = str_replace($search, $replace, $itemValue);\n\n\t\t\t\t\t\t\t$_data['reply_markup']['keyboard'][$itemRowKey][$key] = $newValue;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $_data;\n\t}", "title": "" }, { "docid": "9bf30147b954d597c9aa44268b9910e3", "score": "0.50452566", "text": "function array_merge_new_recursive(array $array1, array $array2)\n{\n foreach ($array2 as $key => $value) {\n if (is_array($value) && isset($array1[$key]) && is_array($array1[$key])) {\n $array1[$key] = array_merge_new_recursive($array1[$key], $value);\n } else {\n if (!isset($array1[$key])) {\n $array1[$key] = $value;\n }\n }\n }\n \n return $array1;\n}", "title": "" }, { "docid": "56a17c36d061176b44b11b12419fb994", "score": "0.50387", "text": "function array_replace_recursive_case_upper() {\r\n $args = func_get_args();\r\n $array = $args[0];\r\n if (!is_array($array)) {\r\n return $array;\r\n }\r\n for ($i = 1, $c = count($args); $i < $c; $i++) {\r\n if (is_array($args[$i])) {\r\n $array = recurse($array, array_change_key_case($args[$i], CASE_UPPER));\r\n }\r\n }\r\n return $array;\r\n}", "title": "" }, { "docid": "764628cf2d1e356dd8c3404d0ddbcc21", "score": "0.5034234", "text": "public function fill(array $data)\n {\n foreach ($data as $linkData) {\n $link = $this->_rootElement->find(\n sprintf($this->linkByLabel, $linkData['label']),\n Locator::SELECTOR_XPATH,\n 'checkbox'\n );\n $link->setValue($linkData['value']);\n }\n }", "title": "" }, { "docid": "c2e5adb3ccee2fda0fafdfba95fb5f4e", "score": "0.50319284", "text": "public static function set(&$array, $key, $value)\n {\n if (is_null($key)) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n foreach ($keys as $i => $key) {\n if (count($keys) === 1) {\n break;\n }\n\n unset($keys[$i]);\n\n /**\n * If the key doesn't exist at this depth, we will just create an empty array\n * to hold the next value, allowing us to create the arrays to hold final\n * values at the correct depth. Then we'll keep digging into the array.\n */\n if (!isset($array[$key]) || !is_array($array[$key])) {\n $array[$key] = [];\n }\n\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "c5c7ccbbd180b2c04c70a79dc4ac75ad", "score": "0.4992232", "text": "function __fillPlaceholder($data, $placeholder)\n {\n foreach($data as $name => $sData){\n if(is_array($sData)){\n $data[$name] = $this->__fillPlaceholder($data[$name], $placeholder);\n }elseif(is_string($sData) && isset($placeholder[$sData])){\n $data[$name] = &$placeholder[$sData];\n }\n }\n return($data);\n }", "title": "" }, { "docid": "0b78d17ecf6585f27f5ed610550f8805", "score": "0.49655074", "text": "function replaceValue($array){\n foreach($array as $key=>$value){\n switch ($value) {\n case 1:\n case 10:\n $array[$key] = -1;\n break;\n case 2:\n case 3:\n case 4:\n case 5:\n case 6:\n $array[$key] = 1;\n break;\n case 7:\n case 8:\n case 9:\n $array[$key] = 0;\n break;\n }\n }\n return $array;\n }", "title": "" }, { "docid": "aa9f731f72b77c18b665e74b0017c785", "score": "0.49604875", "text": "public static function set(&$array, $key, $value)\n {\n if (is_null($key)) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (!isset($array[$key]) || !is_array($array[$key])) {\n $array[$key] = [];\n }\n $array = &$array[$key];\n }\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "988c7a8602dc1fae6fba660c506e503e", "score": "0.49595037", "text": "function fill_defaults(Array $values, Array $defaults) {\n\tforeach($defaults as $key => $default) {\n\t\tif(is_array($default)) {\n\t\t\t$values[$key] = fill_defaults((array) $values[$key], $default);\n\t\t} else if(!isset($values[$key])) {\n\t\t\t$values[$key] = $default;\n\t\t}\n\t}\n\treturn $values;\n}", "title": "" }, { "docid": "400a098cd9f2ca1e5b1a222e31253b1c", "score": "0.49575996", "text": "public static function set(&$array, $key, $value)\n {\n if (is_null($key)) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (! isset($array[$key]) || ! is_array($array[$key])) {\n $array[$key] = [];\n }\n\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "400a098cd9f2ca1e5b1a222e31253b1c", "score": "0.49575996", "text": "public static function set(&$array, $key, $value)\n {\n if (is_null($key)) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (! isset($array[$key]) || ! is_array($array[$key])) {\n $array[$key] = [];\n }\n\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "c0bd0c6dc95c7a13b95bbd1c47192498", "score": "0.49466285", "text": "function array_set($arr,$path, $value) \n{ \n $loc = &$arr;\n foreach(explode('.', $path) as $step)\n {\n $loc = &$loc[$step];\n }\n\n return $loc = $value;\n}", "title": "" }, { "docid": "fc01d0fa87ae119ca638f83094a7a2d2", "score": "0.4946519", "text": "public function offsetSet(mixed $i, mixed $value) : void {\n\t\t$this->children[$i] = $value;\n\t}", "title": "" }, { "docid": "d9b5ea1a4579f72a3362f5114739c398", "score": "0.49324632", "text": "public function testReplaceFieldInArrays(): void\n {\n // setup\n $records = [\n [\n 'from' => 0\n ],\n [\n 'from' => 1\n ]\n ];\n\n // test body\n Functional::replaceField($records, 'from', 'to');\n\n // assertions\n $this->assertTrue(isset($records[0]['to']));\n $this->assertTrue(isset($records[1]['to']));\n\n $this->assertEquals($records[0]['to'], 0);\n $this->assertEquals($records[1]['to'], 1);\n }", "title": "" }, { "docid": "128d32f4ab9f19af7b2faac79e3866ad", "score": "0.49120438", "text": "public static function set(&$array, $key, $value)\n {\n if (is_null($key)) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (! isset($array[ $key ]) or ! is_array($array[ $key ])) {\n $array[ $key ] = [ ];\n }\n\n $array =& $array[ $key ];\n }\n\n $array[ array_shift($keys) ] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "e6c8ca59e3ce0a0bafc2c3efc91977ad", "score": "0.49022624", "text": "public static function replaceArray($replace, $subject)\n\t{\n\t\tif ( TypeCheck::isArray($replace) ) {\n\t\t\tforeach ($replace as $key => $value) {\n\t\t\t\t$subject = self::replace($key,$value,$subject);\n\t\t\t}\n\t\t}\n\t\treturn $subject;\n\t}", "title": "" }, { "docid": "848972a850fe380a08f1ce51bcae8251", "score": "0.4902172", "text": "public static function setValue(&$array, $path, $value)\n {\n if ($path === null) {\n $array = $value;\n return;\n }\n\n $keys = is_array($path) ? $path : explode('.', $path);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n if (!isset($array[$key])) {\n $array[$key] = [];\n }\n if (!is_array($array[$key])) {\n $array[$key] = [$array[$key]];\n }\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n }", "title": "" }, { "docid": "525f7b2dff386f22d25dc90b665fb82e", "score": "0.48947307", "text": "private function _setSubArray($field_name, &$curr_array, $value){\n\n $i = strpos($field_name, '.');\n\n if($i !== false){\n $field = substr($field_name, 0, $i);\n\n if(!isset($curr_array[$field])){\n $curr_array[$field] = array();\n }\n $curr_array =& $curr_array[$field];\n return $this->_setSubArray(substr($field_name, $i + 1), $curr_array, $value);\n\n }\n else {\n return $curr_array[$field_name] = $value;\n }\n\n }", "title": "" }, { "docid": "2bade71647dc8f8bc8b3d51b31f10701", "score": "0.48902813", "text": "static public function arrayMergeRecursive(array $firstArray, array $secondArray, $dontAddNewKeys = false, $emptyValuesOverride = true) {\n\t\tforeach ($secondArray as $key => $value) {\n\t\t\tif (array_key_exists($key, $firstArray) && is_array($firstArray[$key])) {\n\t\t\t\tif (is_array($secondArray[$key])) {\n\t\t\t\t\t$firstArray[$key] = self::arrayMergeRecursive($firstArray[$key], $secondArray[$key], $dontAddNewKeys, $emptyValuesOverride);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif ($dontAddNewKeys) {\n\t\t\t\t\tif (array_key_exists($key, $firstArray)) {\n\t\t\t\t\t\tif ($emptyValuesOverride || !empty($value)) {\n\t\t\t\t\t\t\t$firstArray[$key] = $value;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tif ($emptyValuesOverride || !empty($value)) {\n\t\t\t\t\t\t$firstArray[$key] = $value;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treset($firstArray);\n\t\treturn $firstArray;\n\t}", "title": "" }, { "docid": "405cb52ade14fbef23c7854acbcb6a80", "score": "0.48721072", "text": "public function setRootNode(array $values = array());", "title": "" }, { "docid": "524151b42b2d8892fffa98b0240ff357", "score": "0.48662987", "text": "function replace($a, $find, $repl=null) {\n foreach(array_keys($a) as $i) {\n if( $a[$i]===$find ) {\n $a[$i] = $repl;\n }\n }\n return $a;\n }", "title": "" }, { "docid": "5f820ad9f81009ed488791200d40e11b", "score": "0.48577368", "text": "public function setValue($value)\n\t{\n\t\tif (is_array($value))\n\t\t{\n\t\t\tforeach ($value as $key => $valueData)\n\t\t\t{\n\t\t\t\tif (is_numeric($key))\n\t\t\t\t{\n\t\t\t\t\tif ($this->_parent && (isset($this->_value) || count($this->_children)))\n\t\t\t\t\t{\n\t\t\t\t\t\t$node = $this->_parent->addNode($key);\n\t\t\t\t\t\t$node->setValue($valueData);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->_parent->forceList();\n\t\t\t\t\t\t$this->setValue($valueData);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t$this->offsetSet($key, $valueData);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\tif (count($this->_children)) {\n\t\t\t\tthrow new LSF_Exception_View('Value can not be set to a LSF_View_Node which has child nodes (Call removeChildren)');\n\t\t\t}\n\t\t\n\t\t\t/*\n\t\t\t * Added for php 5.1 support\n\t\t\t */\n\t\t\tif (is_object($value) && method_exists($value, '__toString')) {\n\t\t\t\t$value = $value->__toString();\n\t\t\t}\n\t\t\t\n\t\t\t$this->_value = $value;\n\t\t}\n\t}", "title": "" }, { "docid": "55dc90ef4417ad17828cff557278d24d", "score": "0.48552933", "text": "function resetHTMPathsInArray($array, $oldpath, $newpath){\n\tforeach($array as &$item){\n\t\tif(is_array($item)){\n\t\t\tresetHTMPathsInArray($item,\t$oldpath, $newpath);\n\t\t}else{\n\t\t\t$item = str_replace($oldpath,$newpath,$item);\n\t\t}\n\t}\n\treturn $array;\n}", "title": "" }, { "docid": "405ca6cd00dd4aeba9e632d36ea25337", "score": "0.48438334", "text": "static public function arrayUpdate(&$base, $source) {\n foreach ($source as $k => $v) {\n if (is_array($v) && isset($base[$k]) && is_array(($base[$k]))) {\n self::arrayUpdate($base[$k], $v);\n } else {\n $base[$k] = $v;\n }\n }\n }", "title": "" }, { "docid": "3753252530f5eca74199203856e44936", "score": "0.4842757", "text": "function fill($data)\n {\n foreach ($this->groups as $fields) {\n foreach ($fields as $field) {\n $field->fill($data);\n }\n }\n }", "title": "" }, { "docid": "0b1d1f6279fa4a5a89087dea53f4a621", "score": "0.48380372", "text": "function recursiveTraverse($array, $values, callable $callback)\n{\n if( count($values) == count($array) ) {\n call_user_func($callback, $values); \n return;\n }\n\n $myArray = current($array);\n\n foreach( $myArray as $value) { \n next($array);\n $values[] = $value;\n recursiveTraverse($array, $values, $callback);\n array_pop($values);\n }\n}", "title": "" }, { "docid": "f32d110386897f65b23953ea45fcbb9c", "score": "0.4821081", "text": "public function fill(array $data)\n {\n foreach ($data as $key => &$row) {\n $this->original = $value = Arr::get($row, $this->name);\n\n $value = $this->htmlEntityEncode($value);\n\n Arr::set($row, $this->name, $value);\n\n if ($this->isDefinedColumn()) {\n $this->useDefinedColumn();\n }\n\n if ($this->hasDisplayCallbacks()) {\n $value = $this->callDisplayCallbacks($this->original, $key);\n Arr::set($row, $this->name, $value);\n }\n }\n\n return $data;\n }", "title": "" }, { "docid": "45c0e16a465d3a45571026f92100ead0", "score": "0.48178145", "text": "private function replaceArray($loopedContents, array $replaceWith)\n\t{\n\t\t$loopedContent = '';\n\t\t$map = $this->isMap($replaceWith[1]);\n\t\t$lasti = '';\n\t\t// Will match {$$replaceWith[0]|start}(contents){$$replaceWith[0]|end}\n\t\tif(preg_match_all('/\\<\\$'.$replaceWith[0].'+\\|start\\>(.+)*\\<\\$'.$replaceWith[0].'+\\|end\\>/isU', $this->temp->tplContents, $matches))\n\t\t{\n\t\t\t$loopedContent = $matches[0][0];\n\t\t\tforeach($replaceWith[1] as $i => $ival)\n\t\t\t{\n\t\t\t\tif(!$map && $lasti != $i) {\n\t\t\t\t\t$loopedContent .= $matches[0][0];\n\t\t\t\t}\n\t\t\t\tif(!is_array($replaceWith[1][$i]))\n\t\t\t\t{\n\t\t\t\t\t// Will match {$$replaceWith[0].mapname}\n\t\t\t\t\twhile(stristr($loopedContent, '<$'.$replaceWith[0].'.'.$i.'>'))\n\t\t\t\t\t{\n\t\t\t\t\t\t$loopedContent = preg_replace('/\\<\\$'.$replaceWith[0].'+\\.'.$i.'>/i', $ival, $loopedContent);\n\t\t\t\t\t}\n\t\t\t\t\t// Will match {$$replaceWith[0]}\n\t\t\t\t\twhile(stristr($loopedContent, '<$'.$replaceWith[0].'>'))\n\t\t\t\t\t{\n\t\t\t\t\t\t$loopedContent = preg_replace('/\\<\\$'.$replaceWith[0].'+\\>/i', $ival, $loopedContent);\n\t\t\t\t\t}\n\t\t\t\t} else if(is_array($ival))\n\t\t\t\t{\n\t\t\t\t\tforeach($replaceWith[1][$i] as $j => $jval)\n\t\t\t\t\t{\n\t\t\t\t\t\t// a1: Array 1 ($replaceWith[1])\n\t\t\t\t\t\t// a2: Array 2 ($replaceWith[1][$i])\n\t\t\t\t\t\tif(!$this->isMap($replaceWith[1][$i]) && $lasti != $i && !$this->isMap($map))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$loopedContent .= $matches[0][0];\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(is_array($jval))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tthrow new TemplateException(\"Replace in array(): Array to deep.\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// Will match {$$replaceWith[0].a1mapnam.a2mapname}\n\t\t\t\t\t\twhile(stristr($loopedContent, '<$'.$replaceWith[0].'.'.$i.'.'.$j.'>'))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$loopedContent = preg_replace('/\\<\\$'.$replaceWith[0].'+\\.'.$i.'\\.'.$j.'\\>/i', $replaceWith[1][$i][$j], $loopedContent);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// Will match {$$replaceWith[0].a2mapname}\n\t\t\t\t\t\twhile(stristr($loopedContent, '<$'.$replaceWith[0].'.'.$j.'>'))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$loopedContent = preg_replace('/\\<\\$'.$replaceWith[0].'+\\.'.$j.'\\>/i', $jval, $loopedContent);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// Will match {$$replaceWith[0]}\n\t\t\t\t\t\twhile(stristr($loopedContent, '<$'.$replaceWith[0].'?*>'))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$loopedContent = preg_replace('/\\<\\$'.$replaceWith[0].'+?\\>/i', $jval, $loopedContent);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$lasti = $i;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Will replace {$$replaceWith[0]|start}(contents){$$replaceWith|end}\n\t\t\t$loopedContent = preg_replace('/\\<\\$'.$replaceWith[0].'+\\|(start|end)\\>/isU', '', $loopedContent);\n\t\t\tif(empty($replaceWith[1]))\n\t\t\t\t$this->temp->tplContents = preg_replace('/\\<\\$'.$replaceWith[0].'+\\|start\\>(.+)*\\<\\$'.$replaceWith[0].'+\\|end\\>/isU', \"\", $this->temp->tplContents);\n\t\t\telse\n\t\t\t\t$this->temp->tplContents = preg_replace('/\\<\\$'.$replaceWith[0].'+\\|start\\>(.+)*\\<\\$'.$replaceWith[0].'+\\|end\\>/isU', $loopedContent, $this->temp->tplContents);\n\t\t}else{\n\t\t\tforeach($replaceWith[1] as $i => $val)\n\t\t\t\tif(stristr($this->temp->tplContents, '<$'.$replaceWith[0].'.'.$i.'>'))\n\t\t\t\t\t$this->temp->tplContents = preg_replace('/\\<\\$'.$replaceWith[0].'+\\.'.$i.'>/i', $val, $this->temp->tplContents);\n\t\t}\n\t}", "title": "" }, { "docid": "ce535cb2fc3cdaa78f20b48d7e2f43b0", "score": "0.480829", "text": "function array_dot_set(&$array, $key, $value)\n{\n\tif (is_null($key)) return $array = $value;\n\n\t$keys = explode('.', $key);\n\n\twhile (count($keys) > 1) {\n\t\t$key = array_shift($keys);\n\n\t\t// If the key doesn't exist at this depth, we will just create an empty array\n\t\t// to hold the next value, allowing us to create the arrays to hold final\n\t\t// values at the correct depth. Then we'll keep digging into the array.\n\t\tif ( ! isset($array[$key]) || ! is_array($array[$key])) {\n\t\t\t$array[$key] = array();\n\t\t}\n\t\t$array =& $array[$key];\n\t}\n\n\t$array[array_shift($keys)] = $value;\n\n\treturn $array;\n}", "title": "" }, { "docid": "0ab0b2bea84fe14132333909211c5f45", "score": "0.48028257", "text": "function str_replace_deep(string $search, string $replace, array $a_str) {\n if (is_array($a_str)) {\n foreach ($a_str as &$_str) {\n $_str = str_replace_deep($search, $replace, $_str);\n }\n unset($_str);\n return $a_str;\n } else {\n return mb_str_replace($search, $replace, $a_str);\n }\n}", "title": "" }, { "docid": "dbb4af83d28d00a57e0ef8f2a7d0e436", "score": "0.47934416", "text": "function object_array($array){\n if(is_object($array)){\n $array = (array)$array;\n }\n if(is_array($array)){\n foreach($array as $key=>$value){\n $array[$key] = object_array($value);\n }\n }\n return $array;\n}", "title": "" }, { "docid": "10dcb7792480b8e2f5daa88bcd272173", "score": "0.4792987", "text": "function data_fill(&$target, $key, $value)\n\t{\n\t\treturn data_set($target, $key, $value, false);\n\t}", "title": "" }, { "docid": "6e38023c26b9e1058999d972aae367d8", "score": "0.47827777", "text": "public function replace($array)\n {\n $this->_chain = array();\n $this->append($array);\n return $this;\n }", "title": "" }, { "docid": "65a4f6dcf8f8874b740e0c4286cda575", "score": "0.47802013", "text": "public static function set(array &$array, $key, $content)\n {\n if (is_array($key)) {\n $target = &$array;\n foreach ($key as $key_segment) {\n if ($key_segment === '') {\n $target[] = array();\n end($target);\n $last_key = key($target);\n $target = &$target[$last_key];\n } else {\n if (!isset($target[$key_segment])) {\n $target[$key_segment] = array();\n }\n $target = &$target[$key_segment];\n }\n }\n return $target = $content;\n } else {\n return $array[$key] = $content;\n }\n }", "title": "" }, { "docid": "adaec8accb3ac13ae20634ca28925706", "score": "0.4771761", "text": "function setVar( &$array, $path, $key, $value ) {\n\t\t$pathArr = explode( '/', $path );\n\t\t$target =& $array;\n\t\tif ( $path !== '' ) {\n\t\t\tforeach ( $pathArr as $p ) {\n\t\t\t\tif ( !isset( $target[$p] ) ) {\n\t\t\t\t\t$target[$p] = array();\n\t\t\t\t}\n\t\t\t\t$target =& $target[$p];\n\t\t\t}\n\t\t}\n\t\tif ( !isset( $target[$key] ) ) {\n\t\t\t$target[$key] = $value;\n\t\t}\n\t}", "title": "" }, { "docid": "e7978b251cda0b85894a00aeb4dff876", "score": "0.47609612", "text": "private function mapFieldsRecursive($value, $callback)\n {\n if (is_array($value)) {\n foreach ($value as $key => $subVal) {\n $value[$key] = $this->mapFieldsRecursive($subVal, $callback);\n }\n\n return $value;\n } else {\n return $callback($value);\n }\n }", "title": "" }, { "docid": "00077eb281527de743bf3ac40b4c78fb", "score": "0.47577772", "text": "public static function set(array &$array, string $key, $value) : array\n\t{\n\t\tif (is_null($key) )\n\t\t{\n\t\t\treturn $array = $value;\n\t\t}\n\n\t\t$keys = explode('.', $key);\n\n\t\twhile (count($keys) > 1 )\n\t\t{\n\t\t\t$key = array_shift($keys);\n\n\t\t\t//\tIf the key doesn't exist at this depth, we will just create an empty array to hold \n\t\t\t//\tthe next value, allowing us to create the arrays to hold final values at the correct \n\t\t\t//\tdepth. Then we'll keep digging into the array.\n\t\t\tif (! isset($array[$key]) || ! is_array($array[$key]) )\n\t\t\t{\n\t\t\t\t$array[$key] = [];\n\t\t\t}\n\n\t\t\t$array = &$array[$key];\n\t\t}\n\n\t\t$array[array_shift($keys)] = $value;\n\n\t\treturn $array;\n\t}", "title": "" }, { "docid": "3d73295d43c5630194ee38773f7ee579", "score": "0.4751419", "text": "function fill(...$args) {\n $fill = curry(function($valF, $n) {\n $res = [];\n for($idx=0; $idx < $n; $idx++) $res []= $valF($idx);\n return $res;\n });\n\n return call_user_func_array($fill, $args);\n}", "title": "" }, { "docid": "33a4d08d45d3e24de4e72ea8b88349d2", "score": "0.47468394", "text": "public static function array_merge_recursive( array &$defaults_array, array &$new_array ) {\n $merged = $defaults_array;\n\n foreach ( $new_array as $key => &$value ) {\n if ( is_array( $value ) && isset( $merged[ $key ] ) && is_array( $merged[ $key ] ) ) {\n if ( empty( $value ) ) {\n continue;\n }\n $merged[ $key ] = self::array_merge_recursive( $merged[ $key ], $value );\n } else {\n $merged[ $key ] = $value;\n }\n }\n\n return $merged;\n }", "title": "" }, { "docid": "1c48505cc794e4903bc5e00d216422d3", "score": "0.47350365", "text": "public function replaceWholeContainer(array $originalData)\n {\n if (!$this->_allow_not_defined) {\n $originalData = array_intersect_key($originalData, $this->_aliases);\n }\n\n $this->_data = $originalData;\n if ($originalData) {\n $newkeys = array_keys($this->_data);\n $this->_aliases = array_merge(array_combine($newkeys, $newkeys), (array) $this->_aliases);\n }\n }", "title": "" }, { "docid": "9a0c9dc16bca2fe2d9aa549d6381e980", "score": "0.47255498", "text": "function iterativeDigger(&$entry,$depth,$field_search,$old_id,$new_id)\n{\n\t$max_depth = 10;\n\n\tif (isset($entry['Left']['Value']))\n\t{\t\n\t\tif (($entry['Left']['Value'] == $field_search) && ($entry['Right']['Value'] == $old_id)) \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$entry['Right']['Value'] = $new_id;\n\t}\n\telse if ($depth < $max_depth)\n\t{\n\t\tif (isset($entry['Left']['Left'])) iterativeDigger($entry['Left'],($depth+1),$field_search,$old_id,$new_id);\n\t\tif (isset($entry['Right']['Left'])) iterativeDigger($entry['Right'],($depth+1),$field_search,$old_id,$new_id);\n\t}\n}", "title": "" }, { "docid": "f141cdc9abe103919479a4fc3e4c712f", "score": "0.47187623", "text": "public static function dotSet(array $array, $key, $value)\n {\n $path = explode('.', $key);\n $total = count($path);\n\n $current = &$array;\n\n for ($ii = 0; $ii < $total; $ii++) {\n if ($ii === $total - 1) {\n $current[$path[$ii]] = $value;\n } else {\n if (!is_array($current)) {\n throw new LackOfCoffeeException(\n 'Part of the path is not an array.'\n );\n }\n\n if (!array_key_exists($path[$ii], $current)) {\n $current[$path[$ii]] = [];\n }\n\n $current = &$current[$path[$ii]];\n }\n }\n }", "title": "" }, { "docid": "c9995c7187c3da0232f3b690996de52f", "score": "0.47162053", "text": "protected function arrayupdate() {\n \n }", "title": "" }, { "docid": "0e4ac1e09e4445a4e7fb6212be266498", "score": "0.47144893", "text": "public static function set(&$array, $key, $value, $notation = NOTHING)\n\t{\n\t\tstatic::warnDepreciatedNotationArg(__METHOD__, $notation, $key);\n\t\tlist($key, $notation) = static::parseKey($key, $notation);\n\n\t\tif (is_null($key)) {\n\t\t\treturn $array = $value;\n\t\t}\n\n\t\t$keys = explode($notation, $key);\n\n\t\twhile (count($keys) > 1) {\n\t\t\t$key = array_shift($keys);\n\n\t\t\t// If the key doesn't exist at this depth, we will just create an empty array\n\t\t\t// to hold the next value, allowing us to create the arrays to hold final\n\t\t\t// values at the correct depth. Then we'll keep digging into the array.\n\t\t\tif (! isset($array[$key]) || ! is_array($array[$key])) {\n\t\t\t\t$array[$key] = [];\n\t\t\t}\n\n\t\t\t$array = &$array[$key];\n\t\t}\n\n\t\t$array[array_shift($keys)] = $value;\n\n\t\treturn $array;\n\t}", "title": "" }, { "docid": "7235c522e48d7e11bc2af997e6b3c2ab", "score": "0.47125423", "text": "public function mergeRecursive($array)\n {\n if($this->isInstanceOf($array, $this)){\n $array = $array->val();\n }\n\n $this->val(array_merge_recursive($this->val(), $array));\n\n return $this;\n }", "title": "" }, { "docid": "c574e969fbe27df9b9e5394fccd0b008", "score": "0.4711127", "text": "function fillArray($arr)\r\n{\r\n\t// populates 2D array with random numbers\r\n\tfor ($i = 0; $i < 10; $i++)\r\n \t{\r\n \t\tfor ($j = 0; $j < 5; $j++)\r\n \t\t{\r\n \t\t\t$arr[$i][$j] = rand();\r\n \t\t\r\n \t\t}\r\n \t \t\t\r\n \t}\r\n \t\r\n \treturn $arr;\r\n}", "title": "" }, { "docid": "d2fb6cf1d6377fd1a26774e0fda15ff8", "score": "0.47025266", "text": "protected function replace(...$arrays)\n {\n return $this->getArrayUtil()->replace(...$arrays);\n }", "title": "" }, { "docid": "a70bd482e2aaded6f7be4a060cc70c53", "score": "0.47015435", "text": "public static function set(array &$array, ?string $key, mixed $value): array\n {\n if (is_null($key))\n return $array = $value;\n\n $keys = Str::split($key, '.');\n\n foreach ($keys as $i => $key) {\n if (count($keys) === 1)\n break;\n\n unset($keys[$i]);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (!isset($array[$key]) || !Arr::is($array[$key]))\n $array[$key] = [];\n\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "title": "" }, { "docid": "9ab4f4c4260f5046851ebbdf1eeb75ad", "score": "0.47014034", "text": "function array_replace_key(array $array, $key, $replacement)\n{\n // key does not exists\n if(!isset($array[$key])) {\n return false;\n }\n\n // search current key\n $keys = array_keys($array);\n $index = array_search($key, $keys);\n\n // replace\n $keys[$index] = $replacement;\n return array_combine($keys, $array);\n}", "title": "" }, { "docid": "60ef89f6211e0ea5c261bed2c2985050", "score": "0.46978098", "text": "public static function _rebuildTree($data_array)\n {\n if (is_array($data_array)) {\n foreach ($data_array as $data_node) {\n $node = CategoryArticle::find(3);\n //loop recursively through the children\n if (isset($data_node['children']) && is_array($data_node['children'])) {\n foreach ($data_node['children'] as $data_node_child) {\n //append the children to their (old/new)parents\n $descendant = CategoryArticle::find($data_node_child['item_id']);\n $descendant->appendTo($node)->update();\n //ordering trick here, shift the descendants to the bottom to get the right order at the end\n $shift = count($descendant->getSiblings());\n $descendant->down($shift);\n self::_rebuildTree($data_node['children']);\n }\n }\n }\n }\n }", "title": "" }, { "docid": "38c55f12d9b02db67af83e4a8c4b6d18", "score": "0.46943718", "text": "public static function set(array &$array, $key, $value)\n {\n $keys = explode('.', $key);\n\n while(count($keys) > 1) {\n $key = array_shift($keys);\n if (!isset($array[$key])) {\n $array[$key] = [];\n }\n\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n }", "title": "" }, { "docid": "87803da8a677c9a4bded1af0872bf614", "score": "0.46801606", "text": "function array_map_recursive($fn, $arr)\r\n{\r\n $rarr = array();\r\n foreach ($arr as $k => $v) {\r\n $rarr[$k] = is_array($v)\r\n ? array_map_recursive($fn, $v)\r\n : call_user_func($fn, $v);\r\n }\r\n return $rarr;\r\n}", "title": "" }, { "docid": "0ccf2fe8b356fb4aeede89e96688d021", "score": "0.46755442", "text": "public function fill(array $document)\n {\n foreach ($document as $offset => $value) {\n self::set($offset, $value);\n }\n\n return $this;\n }", "title": "" }, { "docid": "393f39047a967c5e6d7fe1419fbb11f8", "score": "0.46731007", "text": "protected final function fillObject(Array $row){\n\t\t//Hago el fill\n\t\tforeach($row as $attr => $value){\n\t\t\t$attr = '_' . $attr;\n\t\t\tif (BaseType::isTyped($this->$attr)){\n\t\t\t\t$this->$attr->val = $value;\n\t\t\t} else {\n\t\t\t\t$this->$attr = $value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "72a72ffa133e5aace1dacc892ec639b4", "score": "0.4663915", "text": "public static function arrayReplaceKey($search, $replace, array &$target)\n {\n $tempArray = array();\n foreach ($target as $key => $val) {\n if ($search === $key && array_key_exists($replace, $target) === false) {\n $tempArray[$replace] = $val;\n } else {\n $tempArray[$key] = $val;\n }\n }\n $target = $tempArray;\n }", "title": "" }, { "docid": "3e8a070ef019fb1d046ded487fd2894c", "score": "0.46541044", "text": "function stripslashes_recursively(&$array) {\n\tforeach($array as $k => $v) {\n\t\tif(is_array($v)) stripslashes_recursively($array[$k]);\n\t\telse $array[$k] = stripslashes($v);\n\t}\n}", "title": "" }, { "docid": "d6581e29ae098dcbc7f7bb8a3252b4ee", "score": "0.46448192", "text": "function fillDictionary(&$dictionary, $data, $value = '') {\n if (!is_array($data[0][1])) {\n $dictionary[$data[0][1]] = $value.'0';\n } else {\n fillDictionary($dictionary, $data[0][1], $value.'0');\n }\n if (isset($data[1])) {\n if (!is_array($data[1][1])) {\n $dictionary[$data[1][1]] = $value.'1';\n } else {\n fillDictionary($dictionary, $data[1][1], $value.'1');\n }\n }\n}", "title": "" }, { "docid": "9e330d371c2a2c93872a4f9dc9a23bd2", "score": "0.4635243", "text": "function build_tree_filled() {\n if (empty($this->tree_array)) {\n debugging(\"You cannot build the tree_filled array until the tree_array is filled.\");\n return false;\n }\n\n $this->tree_filled = array();\n\n // Detect any category that is now child-less and delete it\n foreach ($this->tree_array as $level1order => $level1) {\n if ($this->get_element_type($level1) == 'item' || $this->get_element_type($level1) == 'subcat') {\n $this->tree_filled[$level1order] = $this->get_filler($level1['object']);\n } else {\n $this->tree_filled[$level1order] = $level1;\n }\n }\n\n reset($this->tree_array);\n\n return true;\n }", "title": "" }, { "docid": "4e4bef4634793bfbf04d8d3d5836aecb", "score": "0.46242872", "text": "protected function setFieldValues(array $field_values) {\n $this->field_data = $field_values;\n \n if(!empty($field_values)) {\n foreach($field_values as $field_name => $field_value) {\n $this->child_elements[$field_name]->setValue($field_value);\n }\n }\n }", "title": "" }, { "docid": "1a92934d05fbcbf73119c1085d8a66ca", "score": "0.4621939", "text": "function arrayProtectRecursive(array &$arr)\n{\n foreach ($arr as $k => $v) {\n if (is_array($v)) {\n arrayProtectRecursive($arr[$k]);\n } else {\n $arr[$k] = protectXSS($v);\n }\n }\n}", "title": "" }, { "docid": "254cb60c8355d475f4f83fe2ef613945", "score": "0.46209142", "text": "public static function set(&$array, $key, $value = null)\n\t{\n\t\tif (is_null($key))\n\t\t{\n\t\t\t$array = $value;\n\t\t\treturn;\n\t\t}\n\n\t\tif (is_array($key))\n\t\t{\n\t\t\tforeach ($key as $k => $v)\n\t\t\t{\n\t\t\t\tstatic::set($array, $k, $v);\n\t\t\t}\n\t\t}\n\n\t\t$keys = explode('.', $key);\n\n\t\twhile (count($keys) > 1)\n\t\t{\n\t\t\t$key = array_shift($keys);\n\n\t\t\tif ( ! isset($array[$key]) or ! is_array($array[$key]))\n\t\t\t{\n\t\t\t\t$array[$key] = array();\n\t\t\t}\n\n\t\t\t$array =& $array[$key];\n\t\t}\n\n\t\t$array[array_shift($keys)] = $value;\n\t}", "title": "" }, { "docid": "7bd8093138c166b9407ceda3dd975031", "score": "0.46077305", "text": "function burst_dots_into_arrays(&$fdf_data_old)\n {\n $fdf_data_new = array();\n\n foreach($fdf_data_old as $key => $value)\n {\n $key_split = explode('.', (string) $key, 2);\n\n if (count($key_split) == 2)\n { // handle dot\n if (!array_key_exists((string) ($key_split[0]), $fdf_data_new))\n {\n $fdf_data_new[(string) ($key_split[0])] = array();\n }\n if (gettype($fdf_data_new[(string) ($key_split[0])]) != 'array')\n {\n // this new key collides with an existing name; this shouldn't happen;\n // associate string value with the special empty key in array, anyhow;\n\n $fdf_data_new[(string) ($key_split[0])] =\n array('' => $fdf_data_new[(string) ($key_split[0])]);\n }\n\n $fdf_data_new[(string) ($key_split[0])][(string) ($key_split[1])] = $value;\n }\n else\n { // no dot\n if (array_key_exists((string) ($key_split[0]), $fdf_data_new) &&\n gettype($fdf_data_new[(string) ($key_split[0])]) == 'array')\n { // this key collides with an existing array; this shouldn't happen;\n // associate string value with the special empty key in array, anyhow;\n $fdf_data_new[(string) $key][''] = $value;\n }\n else\n { // simply copy\n $fdf_data_new[(string) $key] = $value;\n }\n }\n }\n\n foreach($fdf_data_new as $key => $value)\n {\n\n if (gettype($value) == 'array')\n {\n\n $fdf_data_new[(string) $key] = $this->burst_dots_into_arrays($value); // recurse\n }\n }\n\n return $fdf_data_new;\n }", "title": "" }, { "docid": "ce53a7068a4e2b743853943915fa0a2d", "score": "0.46037856", "text": "protected function _set_loop_count(&$replace)\n\t{\n\t\tif(!is_array($replace)) return;\n\n\t\treset($replace);\n\t\twhile(list($key) = each($replace))\n\t\t{\n\t\t\tif(is_array($replace[$key]))\n\t\t\t{\n\t\t\t\t$replace['#'.$key.'_count'] = count($replace[$key]);\n\t\t\t\tfor($i=0; $i<count($replace[$key]); $i++)\n\t\t\t\t{\n\t\t\t\t\tif(isset($replace[$key][$i]) && is_array($replace[$key][$i]))\n\t\t\t\t\t\t$this->_set_loop_count($replace[$key][$i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "a51aeea35ac37bf2a0e80a38c31e19c0", "score": "0.4599612", "text": "function xfields_fill($row, $tEntry) {\r\n\t$xdata = $row['xfields'] ? xf_decode($row['xfields']) : array();\r\n\tforeach (get_xflist() as $xf) {\r\n\t\t$id = $xf['id'];\r\n\t\t$tEntry[count($tEntry) - 1]['xfields'][$id] = $xdata[str_replace('xfields_', '', $id)] ? $xdata[str_replace('xfields_', '', $id)] : '';\r\n\t}\r\n\r\n\treturn $tEntry;\r\n}", "title": "" }, { "docid": "2f2effdd5e14ba3ab0b690911b1e0dac", "score": "0.45966014", "text": "private function _recursive_update($obj, $path, $update, $depth)\n {\n $node = $path[$depth];\n $next_node = $path[$depth+1];\n\n if(!$obj){\n throw new Exception(\"Field not found\");\n }\n if(!$path || gettype($path) != 'array'){\n throw new Exception(\"Invalid path\");\n }\n\n /* update at the root level */\n if(count($path) == 1){\n reset($update);\n $k = key($update);\n $v = current($update);\n\n if(isset($obj[$k])){\n return (object) array_replace_recursive((array) $obj, (array) $update);\n }\n else{\n return (object) array_merge_recursive((array) $obj, (array) $update);\n }\n }\n\n /**\n * special handling for updating arrays at depth 2\n * as arrays have to be replaced\n */\n if(count($path) == 2){\n if(gettype($obj[$path[1]]) == 'array'){\n $val = $obj[$path[1]];\n $new_val = array_merge_recursive($val, $update);\n $obj[$path[1]] = $new_val;\n return $obj;\n }\n }\n\n /**\n * similar to special handling above for arrays but at\n * a varied depth\n */\n if($depth == count($path) - 2){\n $temp = (array)$obj[$node];\n if(gettype($temp[$next_node]) == 'array'){\n reset($update);\n $k = key($update);\n $v = current($update);\n $val = $temp[$next_node];\n\n if(isset($val[$k])){\n $new_val = array_replace_recursive($val, $update);\n }\n else {\n $new_val = array_merge_recursive($val, $update);\n }\n\n if(gettype($obj[$node]) == 'object'){\n $obj[$node]->$next_node = $new_val;\n }\n else{\n $obj[$node][$next_node] = $new_val;\n }\n return;\n }\n }\n\n /* handling scalar values and JSON Object */\n if($depth == count($path) - 1){\n reset($update);\n $k = key($update);\n $v = current($update);\n\n if(gettype($obj[$node]) == 'object'){\n $obj[$node]->$k = $v;\n }\n else{\n $obj[$node][$k] = $v;\n }\n return;\n }\n\n if($depth == 0){\n /* ignore \"root\" */\n self::_recursive_update((array)$obj[$next_node], $path, $update, $depth + 2);\n }\n\n else{\n self::_recursive_update((array)$obj[$node], $path, $update, $depth + 1);\n }\n return $obj;\n }", "title": "" }, { "docid": "7d07507c52827020c6cd5da17e449659", "score": "0.4595493", "text": "static private function array_overwrite(&$original,&$overwrite)\n {\n if(is_array($overwrite)&&is_array($original))\n {\n foreach($original as $key=>&$value)\n {\n if(empty($overwrite[$key]))\n {\n $overwrite[$key]=$value;\n }\n else\n {\n self::array_overwrite($overwrite[$key],$original[$key]);\n }\n }\n }\n }", "title": "" }, { "docid": "981305d0abfd0163bfc2b12c6f26e56e", "score": "0.4594033", "text": "function str_replace_array($search, array $replace, $subject)\n {\n foreach ($replace as $value) {\n $subject = preg_replace('/' . $search . '/', $value, $subject, 1);\n }\n\n return $subject;\n }", "title": "" }, { "docid": "e2e196dc4f8a12e24be4b668d2883517", "score": "0.4588786", "text": "private function applyValues(){\n\t foreach($this->elements as $element){\n\t $name = $element->getName();\n\t if(isset($this->values[$name]))\n\t $element->setValue($this->values[$name]);\n\t elseif(substr($name, -2) == \"[]\" && isset($this->values[substr($name, 0, -2)]))\n\t $element->setValue($this->values[substr($name, 0, -2)]);\n\t }\n\t }", "title": "" }, { "docid": "a271860791a5f47e8929cefa0228ebce", "score": "0.4582018", "text": "public function ReplaceWith( $element ){\r\n\t\t$elements = array();\r\n\t\t// Step through all siblings\r\n\t\tforeach( $this->parent->elements as $child_element ){\r\n\t\t\tif( $child_element == $this ){\r\n\t\t\t\t// Element to be replaced\r\n\t\t\t\t$this->Remove();\r\n\t\t\t\t// Insert new elements\r\n\t\t\t\tif( is_array( $element ) ){\r\n\t\t\t\t\tforeach( $element as $item ){\r\n\t\t\t\t\t\t$item->SetParent( $this->parent );\r\n\t\t\t\t\t\t$elements[] = $item;\r\n\t\t\t\t\t\t$this->ElementAdded( $item );\r\n\t\t\t\t\t}\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$element->SetParent( $this->parent );\r\n\t\t\t\t\t$elements[] = $element;\r\n\t\t\t\t\t$this->ElementAdded( $element );\r\n\t\t\t\t}\r\n\t\t\t} else {\r\n\t\t\t\t$elements[] = $child_element;\r\n\t\t\t}\r\n\t\t}\r\n\t\t$this->parent->elements = $elements;\r\n\t}", "title": "" }, { "docid": "772dcd91fb0344ed41d554ecef35b829", "score": "0.4574601", "text": "function set($node, $value){\n $this->temp[$node] = $value;\n }", "title": "" }, { "docid": "e87a6c1b353f0aa78078cda74ce48001", "score": "0.4574014", "text": "protected function &_fill_node($map, $data, &$node = NULL)\n\t{\n\t\tif ($node === NULL)\n\t\t\t$node = &$this->_node;\n\t\t\n\t\tforeach ($map as $field => $path)\n\t\t{\n\t\t\tif (isset($data[$field]))\n\t\t\t{\n\t\t\t\t$this->_set_node($path, $data[$field], $node);\n\t\t\t}\n\t\t}\n\t\treturn $node;\n\t}", "title": "" }, { "docid": "f8b16c30c61e0ef87ed2c31a07cf4263", "score": "0.45667198", "text": "public function replace(array $items);", "title": "" } ]
a0be0417ec9944f49ab7515685ff0291
Get a validator for an incoming registration request.
[ { "docid": "485536c92064148063257708752083d9", "score": "0.0", "text": "protected function validator(array $data)\n {\n return Validator::make($data, [\n 'name' => 'required|max:255',\n 'email' => 'required|email|max:255|unique:users',\n 'password' => 'required|min:6|confirmed',\n ]);\n }", "title": "" } ]
[ { "docid": "faeb05308c51cb3cd2ef8fce8fc613f8", "score": "0.719234", "text": "private function getValidator() : Validator\n {\n return new Validator($this->params);\n }", "title": "" }, { "docid": "687f56e3050d373972e4649698062c17", "score": "0.7048845", "text": "public function getValidator()\n {\n return $this->validator;\n }", "title": "" }, { "docid": "6e9234045f9034f26e3d2a747e1bdfef", "score": "0.70312804", "text": "protected function getValidatorInstance()\n {\n $factory = $this->container->make(ValidationFactory::class);\n\n if (method_exists($this, 'validator')) {\n return $this->container->call([$this, 'validator'], compact('factory'));\n }\n\n return $factory->make(\n $this->all(), $this->rules(), $this->messages(), $this->attributes()\n );\n }", "title": "" }, { "docid": "973ac95ce7088cd1b89ef626014bfdb7", "score": "0.7019428", "text": "public function getValidator()\n {\n return $this->validator;\n }", "title": "" }, { "docid": "f38c77dccb0e37cf7b2dbdf29345519c", "score": "0.6988801", "text": "public function getValidator(){\n\t\treturn $this->validator;\n\t}", "title": "" }, { "docid": "abafcab95d5a5a666d47285afe15c8db", "score": "0.69604975", "text": "protected function getValidator()\n {\n if ($this->validator === null) {\n $this->validator = new FinnishSocialSecurityNumberValidateGeneric();\n }\n \n return $this->validator;\n }", "title": "" }, { "docid": "b65e2b0fc214be8d0d14c474e05cd1fa", "score": "0.6889958", "text": "protected function getValidatorInstance()\n {\n $factory = $this->container->make('Illuminate\\Validation\\Factory');\n\n if (method_exists($this, 'validator')) {\n return $this->container->call([$this, 'validator'], compact('factory'));\n }\n\n return $factory->make(\n $this->session->all(), $this->container->call([$this, 'rules']), $this->messages(), $this->attributes()\n );\n }", "title": "" }, { "docid": "aa889b73e4b6e616db75d7d9d1a7b1fd", "score": "0.6885488", "text": "public function getValidator() {\n return $this->_validator;\n }", "title": "" }, { "docid": "a311e28430436386bfa3bd2d9b2dcc54", "score": "0.68798786", "text": "public function getValidatorInstance()\n {\n $request = $this->validationData();\n\n try {\n $request[\"database\"] = $this->route(\"database\");\n $request[\"table\"] = $this->route(\"table\");\n\n $request[\"qualifiedName\"] =\n $request[\"database\"] . \".\" . $request[\"table\"];\n\n $request[\"model\"] = app(DatabaseTraverser::class)->getModel(\n $request[\"table\"]\n )[\"model\"];\n } catch (Exception $exception) {\n return parent::getValidatorInstance();\n }\n\n $this->getInputSource()->replace($request);\n\n return parent::getValidatorInstance();\n }", "title": "" }, { "docid": "0ad642a51653f12059f07d348616eb48", "score": "0.6877306", "text": "public function getValidator()\n {\n }", "title": "" }, { "docid": "3f97b7ee6875d1ae0ca9680d81d734db", "score": "0.6875381", "text": "public function getValidator() : BaseValidator\n {\n return $this->validator;\n }", "title": "" }, { "docid": "fe217349be872deb7ff6b49ce77b435c", "score": "0.6846405", "text": "public function getValidator(): ValidatorInterface\n {\n return $this->validator;\n }", "title": "" }, { "docid": "2712420643d845b4f9a22b38cbcdea2d", "score": "0.68235946", "text": "function getValidator() {\r\n return $this->validator;\r\n }", "title": "" }, { "docid": "9252feb0d60898ba5ac851f6317f8cbb", "score": "0.6815645", "text": "public static function validator()\n {\n return self::$validator;\n }", "title": "" }, { "docid": "41da1f8f35717ccbc10e2eae661bca29", "score": "0.6782814", "text": "public function getValidator()\n {\n return Validator::make($this->toArray(), $this->getConstraints());\n }", "title": "" }, { "docid": "034a2c275f50f44097c342b911366889", "score": "0.6772372", "text": "public function getValidator(){\n\t\tif(is_null($this->_validator) && $this->_voName){\n\t\t\t$this->_validator = $this->getApplication()->getFactory()->getValidator($this->_voName, $this->getMode()=='edit' ? \\Smally\\Validator::MODE_EDIT : \\Smally\\Validator::MODE_NEW );\n\t\t}\n\t\treturn $this->_validator;\n\t}", "title": "" }, { "docid": "ea2102d2514e493d02cf2e7d50a90c59", "score": "0.67158145", "text": "function getValidator(){\r\n\t\treturn $this->_validator;\r\n\t}", "title": "" }, { "docid": "232576461c0b2280a524317e0b961d6d", "score": "0.6698162", "text": "public function getValidatorInstance()\n {\n $validator = parent::getValidatorInstance();\n $validator->after(function ()\n {\n $this->afterRequest();\n });\n\n return $validator;\n }", "title": "" }, { "docid": "bdb6606d374ab80d6348447b9ff8e98c", "score": "0.66960615", "text": "function getValidator() {\r\n return $this->validator;\r\n }", "title": "" }, { "docid": "5617997540ef47c2c3aec2b13eac67c6", "score": "0.6687648", "text": "public function validator()\n {\n return $this->validator;\n }", "title": "" }, { "docid": "2f5681b89ad95bf6c51af1306998fa01", "score": "0.66812146", "text": "public static function registerValidator(Request $request){\n\n // Validation\n $validator = Validator::make($request->all() , [\n 'name' => 'required|max:30',\n 'email' => 'required|email|max:255|unique:users',\n 'password' => 'required|confirmed|min:6',\n 'mobile' => 'required|max:15'\n ]);\n\n return $validator;\n }", "title": "" }, { "docid": "bdb9c8b7b46c0ed5f822e8d738d7a708", "score": "0.6648155", "text": "private function initValidation()\n {\n $validator = Validation::createValidatorBuilder()\n ->enableAnnotationMapping()\n ->getValidator();\n\n return $validator;\n }", "title": "" }, { "docid": "fa01c46b915102aa26e3624a52520ab7", "score": "0.662823", "text": "protected function getValidator(): ValidatorInterface\n {\n if ($this->validator === null) {\n $constraintFactory = new ConstraintValidatorFactory();\n\n try {\n $reader = new AnnotationReader();\n\n $this->validator = Validation::createValidatorBuilder()\n ->enableAnnotationMapping($reader)\n ->setConstraintValidatorFactory($constraintFactory)\n ->getValidator();\n } catch (\\Exception $exception) {\n self::fail(\\sprintf('Could not create validator instance: %s', $exception->getMessage()));\n }\n }\n\n return $this->validator;\n }", "title": "" }, { "docid": "0368bf4451b98fb1ebd945a9277981a3", "score": "0.66231376", "text": "public function getValidator()\n {\n if (!$this->validator) {\n $this->setValidator(\n $this->validatorFactory->createValidator($this->form)\n );\n }\n\n return $this->validator;\n }", "title": "" }, { "docid": "273fb0c64d5c3ca473fb37c8aa0f955c", "score": "0.65717614", "text": "public function &get_validator()\n\t{\n\t\treturn $this->form->validator;\n\t}", "title": "" }, { "docid": "1bc3f2e1a7b64341346839587161b429", "score": "0.6534499", "text": "protected function getValidationFactory()\n {\n return app('validator');\n }", "title": "" }, { "docid": "36ce1096125b38f0445e73f0932f1cb9", "score": "0.6527367", "text": "public function getValidator(): ValidationManager\n {\n return new ValidationManager($this->getDb(), $this->getFlash(), $_POST);\n }", "title": "" }, { "docid": "bd393b0e8bbbd5587dc44dab79e1f9bf", "score": "0.6510178", "text": "public static function create_validator( $request = array() ) {\n\t\t\n\t\treturn new Halp_Form_Validator( $request );\n\t\t\n\t}", "title": "" }, { "docid": "fd6dd0e04d3569d49d945a79af9fb38d", "score": "0.64886117", "text": "public static function forgeValidator()\n\t{\n\t\t$validator = new Validator;\n\n\t\treturn static::populateValidator($validator);\n\t}", "title": "" }, { "docid": "2966a4a1a9310d67dd08a38613053224", "score": "0.64788884", "text": "protected function getValidatorService()\n {\n return $this->services['validator'] = ${($_ = isset($this->services['validator.builder']) ? $this->services['validator.builder'] : $this->get('validator.builder')) && false ?: '_'}->getValidator();\n }", "title": "" }, { "docid": "5734ba6f33084c45ea55c738e5549514", "score": "0.64345586", "text": "public function getValidator()\n {\n if ($this->_validator === null) {\n\n if (class_exists('\\Klikasi\\\\Validator\\Laguntza')) {\n\n $this->setValidator(new \\Klikasi\\Validator\\Laguntza);\n }\n }\n\n return $this->_validator;\n }", "title": "" }, { "docid": "d8d39626a09a20cbe7040e4af419d8f9", "score": "0.6434283", "text": "public function getValidator($name) {\n $this->hasValidator($name, null, function($name){\n throw new \\OutOfRangeException(sprintf(\"No validator with the name '%s' has been registered\", $name));\n });\n\n $validator = $this->validators[$name];\n $validator->setInput($this->input);\n\n if($this->namespaced) {\n $validator->setNamespace($name);\n }\n return $validator;\n }", "title": "" }, { "docid": "dcb2e9fe30d214e3dd95ff9370ff86ec", "score": "0.6404386", "text": "protected function getValidatorInstance()\n {\n $this->getDeffaultValues();\n return parent::getValidatorInstance();\n }", "title": "" }, { "docid": "3c033045ac277e6586d771ea47b720e1", "score": "0.64026046", "text": "public function getValidator()\n {\n if ($this->_validator === null) {\n\n if (class_exists('\\Atezate\\\\Validator\\PuntosDescarga')) {\n\n $this->setValidator(new \\Atezate\\Validator\\PuntosDescarga);\n }\n }\n\n return $this->_validator;\n }", "title": "" }, { "docid": "6f83d564da87f470ed6d2d62d8d8ecca", "score": "0.6382471", "text": "public function getValidator()\n {\n $className = Mage::getStoreConfig(self::CONFIG_XML_PATH_VALIDATOR);\n return Mage::getModel($className);\n }", "title": "" }, { "docid": "8e5dad68855c051da724daf9b812cb83", "score": "0.63151276", "text": "public function getInstance(Constraint $constraint)\n {\n $name = $constraint->validatedBy();\n\n if (!isset($this->validators[$name])) {\n $this->validators[$name] = new $name();\n } elseif (is_string($this->validators[$name])) {\n $this->validators[$name] = $this->container->get($this->validators[$name]);\n }\n\n if (!$this->validators[$name] instanceof ConstraintValidatorInterface) {\n throw new UnexpectedTypeException($this->validators[$name], 'Symfony\\Component\\Validator\\ConstraintValidatorInterface');\n }\n\n return $this->validators[$name];\n }", "title": "" }, { "docid": "a57e7214b8a64533fd59b9690e225bbc", "score": "0.6314789", "text": "protected function getValidatorService()\n {\n return $this->services['validator'] = new \\Symfony\\Component\\Validator\\Validator(new \\Symfony\\Component\\Validator\\Mapping\\ClassMetadataFactory(new \\Symfony\\Component\\Validator\\Mapping\\Loader\\LoaderChain(array(0 => new \\Symfony\\Component\\Validator\\Mapping\\Loader\\AnnotationLoader($this->get('annotation_reader')), 1 => new \\Symfony\\Component\\Validator\\Mapping\\Loader\\StaticMethodLoader(), 2 => new \\Symfony\\Component\\Validator\\Mapping\\Loader\\XmlFilesLoader(array(0 => '/var/www/transap/vendor/symfony/symfony/src/Symfony/Component/Form/Resources/config/validation.xml')), 3 => new \\Symfony\\Component\\Validator\\Mapping\\Loader\\YamlFilesLoader(array()))), NULL), new \\Symfony\\Bundle\\FrameworkBundle\\Validator\\ConstraintValidatorFactory($this, array()), array());\n }", "title": "" }, { "docid": "b18b29e42318ec41bfd812ff32b3c3ca", "score": "0.63052", "text": "protected function getValidatorInstance()\n\t{\n\t\t// Add new data field before it gets sent to the validator\n\t\t$languages = (array)config('languages');\n\t\t$abbr = $this->abbr;\n\t\t\n\t\t$input = [];\n\t\t$input['name'] = (isset($languages[$abbr])) ? $languages[$abbr] : mb_ucfirst($abbr);\n\t\tif (!isset($this->native) || empty($this->native)) {\n\t\t\t$input['native'] = $input['name'];\n\t\t}\n\t\t\n\t\trequest()->merge($input); // Required!\n\t\t$this->merge($input);\n\t\t\n\t\t// Fire the parent getValidatorInstance method\n\t\treturn parent::getValidatorInstance();\n\t}", "title": "" }, { "docid": "1d447cd7f322eb30bf9cfb77a5f1e224", "score": "0.6303639", "text": "public function validator()\n {\n\n return MyValidator::class;\n }", "title": "" }, { "docid": "2ad908a42e3b5a5444ddf9d1cf8c07e3", "score": "0.6301425", "text": "public function validator()\n {\n if (isset($this->rules) && !is_null($this->rules) && is_array($this->rules) && !empty($this->rules)) {\n $validator = app('MikesLumenRepository\\Validators\\LumenValidator');\n $validator->setRules($this->rules);\n return $validator;\n }\n\n return null;\n }", "title": "" }, { "docid": "75064f49004bf3be71d6c1281de68e1a", "score": "0.6242643", "text": "protected function getRegisterValidationScheme(){\n return $this->getValidationSchemeFor(\"register\");\n }", "title": "" }, { "docid": "fc6d3c1cb582112fe8f0c12743690447", "score": "0.62420183", "text": "public function getValidator(array $input);", "title": "" }, { "docid": "740893fc8747912603f41cbe92c77e9f", "score": "0.6228299", "text": "protected function getValidator(Request $request)\n {\n $rules = [\n 'image' => 'required|image',\n 'tags' => 'required'\n ];\n\n return Validator::make($request->all(), $rules);\n }", "title": "" }, { "docid": "84b4990a512f176ead4ab8be4b5e14b3", "score": "0.62275493", "text": "function getValidator() {\n\t\tif ( !$this->_Validator instanceof utilityValidator ) {\n\t\t\t$this->_Validator = new utilityValidator();\n\t\t}\n\t\treturn $this->_Validator;\n\t}", "title": "" }, { "docid": "cc756c8066c6a09c39a78b6d68a34ca5", "score": "0.6206498", "text": "protected function getValidatorInstance()\n {\n $validator = parent::getValidatorInstance();\n\n TranslationValidator::add($validator);\n\n return $validator;\n }", "title": "" }, { "docid": "aff4d79ae9c397178b9718552a943469", "score": "0.620605", "text": "public static function getInstance() {\n\n if (is_null(self::$instance)) {\n self::$instance = new Validator();\n }\n return self::$instance;\n }", "title": "" }, { "docid": "9620c408c0c01d820c7d0bd71adc87f9", "score": "0.6143536", "text": "public function validate(): Validator\n {\n return new Validator($this->getClaims());\n }", "title": "" }, { "docid": "4de2176a58a9a3156a8e02b4785fa83c", "score": "0.6139989", "text": "public function getValidator(): ?string;", "title": "" }, { "docid": "b55a3e983e479e0b343e7b568143bdff", "score": "0.61237746", "text": "public function validator()\n {\n\n return UserValidator::class;\n }", "title": "" }, { "docid": "b55a3e983e479e0b343e7b568143bdff", "score": "0.61237746", "text": "public function validator()\n {\n\n return UserValidator::class;\n }", "title": "" }, { "docid": "053197727a94c3f96157868ed3a8bcc5", "score": "0.610553", "text": "public function validator()\n {\n return UserValidator::class;\n }", "title": "" }, { "docid": "ee6047dbd19d242870927a6d503a4fa7", "score": "0.607235", "text": "public static function getValidator($validator)\n {\n if (is_string($validator)) {\n $validator = static::fromString($validator);\n } elseif (is_callable($validator) && !$validator instanceof ValidatorInterface) {\n $validator = new Validator\\Callback($validator);\n }\n\n if (!$validator instanceof ValidatorInterface) {\n throw new \\InvalidArgumentException('$validator has to be an instance of ValidatorInterface');\n }\n\n return $validator;\n }", "title": "" }, { "docid": "83cbfdbf7372fb2d47ecf1b6d9ddcd8f", "score": "0.60696715", "text": "protected function validator(Request $request)\n\t{\n\t\treturn Validator::make($request->all(), [\n\t\t\t\t'name' => 'required',\n\t\t\t\t]);\n\t}", "title": "" }, { "docid": "4df90af7fb5358288ddd2616184b474c", "score": "0.60407954", "text": "public function validator()\n {\n if (!isset($this->ModelValidator)) {\n $this->ModelValidator = new ModelValidator($this);\n }\n\n return $this->ModelValidator;\n }", "title": "" }, { "docid": "0217098ac98d74de9dc76b4c768bef2b", "score": "0.6012858", "text": "protected function getIntrospectionValidator()\n {\n if ($this->introspectionValidator instanceof IntrospectionValidatorInterface === false) {\n $this->introspectionValidator = new BearerTokenValidator($this->accessTokenRepository);\n $this->introspectionValidator->setPrivateKey($this->privateKey);\n }\n\n return $this->introspectionValidator;\n }", "title": "" }, { "docid": "8b1cd7b41fb40cd6b654cb080ee607bc", "score": "0.598353", "text": "public function validator()\n {\n return Validator::make(['provider' => $this->route('provider')], [\n 'provider' => ['required', new Enum(SocialProvider::class)],\n ]);\n }", "title": "" }, { "docid": "089a9aa76c4e25586af5faa9e1ea07bc", "score": "0.594216", "text": "protected function getSignupValidator()\n {\n $validator = $this->components->validate()->validator();\n /** @var Document $document */\n $document = $validator->rule()->addDocument();\n $document->allowExtraFields();\n\n $document->valueField('email')\n ->required()\n ->filter('email')\n ->callback(function (Field $result, $value) {\n if ($result->isValid()) {\n $user = $this->userRepository()->query()\n ->where('email', $value)\n ->findOne();\n\n if ($user !== null) {\n $result->addCustomError('emailInUse');\n }\n }\n });\n\n $document->valueField('password')\n ->required()\n ->addFilter()\n ->minLength(8);\n\n $validator->rule()->callback(function (RootResult $result, $data) {\n if ($result->field('password')->isValid() && $data['passwordConfirm'] !== $data['password']) {\n $result->field('passwordConfirm')->addCustomError('passwordConfirm');\n }\n });\n\n return $validator;\n }", "title": "" }, { "docid": "9c9661f0b54819f28db1770c99bf4750", "score": "0.5939156", "text": "protected function getValidatorInstance()\n {\n $this->getInputSource()->replace( $this->getConvertedParameters() );\n\n return parent::getValidatorInstance();\n }", "title": "" }, { "docid": "401b78acd4286e61e051e716c874d804", "score": "0.59075147", "text": "protected function validator(Request $request) {\n //only common files if we have multiple registration\n return Validator::make($request, [\n 'first_name' => 'required',\n 'last_name' => 'required',\n 'gender' => 'required',\n ]);\n }", "title": "" }, { "docid": "5071c02d6cbf336d51fdbff473dc013e", "score": "0.59043455", "text": "public function validator()\n {\n\n return ContactValidator::class;\n }", "title": "" }, { "docid": "2d2839c8888ce4601776e95a0ad7a8c9", "score": "0.58945364", "text": "protected function getForm_TypeGuesser_ValidatorService()\n {\n return $this->services['form.type_guesser.validator'] = new \\Symfony\\Component\\Form\\Extension\\Validator\\ValidatorTypeGuesser(${($_ = isset($this->services['validator']) ? $this->services['validator'] : $this->get('validator')) && false ?: '_'});\n }", "title": "" }, { "docid": "b20afaf0349641e2dd83d963da75abb0", "score": "0.5848576", "text": "public function validator(): ModelValidator\n {\n if (! isset($this->ModelValidator)) {\n $this->ModelValidator = new ModelValidator($this);\n }\n\n return $this->ModelValidator;\n }", "title": "" }, { "docid": "c8f8973f92427dec4201aa43cbd506fe", "score": "0.58412087", "text": "public function validator()\n {\n\n return MatchValidator::class;\n }", "title": "" }, { "docid": "dd1232dd5cb24a58b1b99ab850fdd464", "score": "0.58389366", "text": "public function validator()\n {\n\n return ItensPromocaoValidator::class;\n }", "title": "" }, { "docid": "36a31872921d7038efdee62c8d33b4ae", "score": "0.58325684", "text": "public function validator()\n {\n $validator = Validator::make($this->all(), [\n 'id' => 'required',\n ]);\n\n return $validator;\n }", "title": "" }, { "docid": "4de142fab80c6c6e24dc77188251422d", "score": "0.5827763", "text": "protected function getValidation()\n {\n if (!isset($this->validation)) {\n $this->validation = new Validation();\n }\n\n return $this->validation;\n }", "title": "" }, { "docid": "f48354d92250cfce3d7b4f64006dbff5", "score": "0.58234406", "text": "protected function getValidationFactory()\n {\n return app('Illuminate\\Contracts\\Validation\\Factory');\n }", "title": "" }, { "docid": "3cdd755ed57a8c7906d86f865f54d6c8", "score": "0.58157295", "text": "public function validator(string $name): Validator\n {\n if (!$this->hasValidator($name)) {\n throw new \\LogicException(\"Validator {$name} not set.\");\n }\n return $this->_validators[$name];\n }", "title": "" }, { "docid": "f06565f97dd99b5cd782d5c35821c174", "score": "0.58073694", "text": "protected function getValidationFactory()\n\t{\n\t\treturn app('Illuminate\\Contracts\\Validation\\Factory');\n\t}", "title": "" }, { "docid": "0554e8d414947f1fb46f3bdea0aeb55a", "score": "0.57920814", "text": "public static function getValidator ($input) {\n\t\t$rules = array('name' =>'required|between:3,255');\n\t\treturn Validator::make($input, $rules);\n\t}", "title": "" }, { "docid": "75a1cf26e1ed26801bd5efe8e1ad1cdf", "score": "0.5789983", "text": "public function registerValidator(Request $request){\n return $this->validate($request, [\n 'name'=> 'required|string',\n 'email'=> 'required|email|unique:users',\n 'password'=> 'required|confirmed'\n ]);\n }", "title": "" }, { "docid": "78cd600de7e56f85ab26682dc92b56cd", "score": "0.5774778", "text": "private function getOtpSubmissionRequestValidator(Request $request): ValidatorInterface\n {\n return ValidatorFacade::make($request->all(), [\n 'password' => 'required|string',\n ]);\n }", "title": "" }, { "docid": "12c011e7312b631a732b5b7def81ac31", "score": "0.5748842", "text": "protected function getValidateRequestListenerService()\n {\n return $this->services['validate_request_listener'] = new \\Symfony\\Component\\HttpKernel\\EventListener\\ValidateRequestListener();\n }", "title": "" }, { "docid": "12c011e7312b631a732b5b7def81ac31", "score": "0.5748842", "text": "protected function getValidateRequestListenerService()\n {\n return $this->services['validate_request_listener'] = new \\Symfony\\Component\\HttpKernel\\EventListener\\ValidateRequestListener();\n }", "title": "" }, { "docid": "55ecf7e65e1740e04d9a08d4197c452e", "score": "0.5713959", "text": "public function validator()\n {\n\n return StreetValidator::class;\n }", "title": "" }, { "docid": "4c5c445d9b7e989d6c0e92b801a730f0", "score": "0.570542", "text": "public function validator()\n {\n\n return MkCompromissoValidator::class;\n }", "title": "" }, { "docid": "fed8bd73e4f44e974e7cd85c6a991c15", "score": "0.5688536", "text": "protected function getValidatorService()\n {\n return $this->services['validator'] = new \\Symfony\\Component\\Validator\\Validator\\TraceableValidator(($this->privates['validator.builder'] ?? $this->getValidator_BuilderService())->getValidator());\n }", "title": "" }, { "docid": "1e47aa4dd9558c6d3dba6b1b0fd5963c", "score": "0.56700265", "text": "public function getAuthValidator()\n {\n $validator = new AuthValidator();\n $validator->setTranslator($this->getServiceLocator()->get('MvcTranslator'));\n $validator->setIdentity('username');\n $validator->setCredential('password');\n $validator->setAdapter($this->getAuthAdapter());\n $validator->setService($this->getAuthService());\n $validator->setMessages([\n AuthValidator::CREDENTIAL_INVALID => 'validate.authentication.failed',\n AuthValidator::IDENTITY_NOT_FOUND => 'validate.authentication.failed',\n AuthValidator::UNCATEGORIZED => 'validate.authentication.uncategorizedFailure',\n AuthValidator::GENERAL => 'validate.authentication.failed',\n ]);\n\n return $validator;\n }", "title": "" }, { "docid": "d79bad558099be94e40b4c49aff9c461", "score": "0.5654252", "text": "public function validator()\n {\n\n return FuncaoValidator::class;\n }", "title": "" }, { "docid": "230a9a77a6a6575ca96788093aa27dc9", "score": "0.563746", "text": "protected function getValidator(ValidatorDemand $validatorDemand): ?AbstractVideoValidatorInterface\n {\n $extension = strtolower($validatorDemand->getExtension());\n $validator = match ($extension) {\n 'youtube' => GeneralUtility::makeInstance(YoutubeValidator::class, $extension),\n 'vimeo' => GeneralUtility::makeInstance(VimeoValidator::class, $extension)\n };\n\n $modifyValidatorEvent = $this->eventDispatcher->dispatch(\n new ModifyValidatorEvent($validator, $extension)\n );\n return $modifyValidatorEvent->getValidator();\n }", "title": "" }, { "docid": "3283989ef046315bc25b5417dcaaa32e", "score": "0.562765", "text": "protected function getValidatorInstance()\n {\n $this->merge(['attendees' => implode(',', $this->get('attendees', []))]);\n return parent::getValidatorInstance();\n }", "title": "" }, { "docid": "6e99168905da802018f15b743fbcb743", "score": "0.56149876", "text": "function validation(Request $req)\n {\n }", "title": "" }, { "docid": "923cb7ea92a4ade509ac4d6d526d515a", "score": "0.55976266", "text": "public function validator()\n {\n\n return RadacctValidator::class;\n }", "title": "" }, { "docid": "02f08fcb98fc507975df2e708166a8c2", "score": "0.5591017", "text": "public function validator()\n {\n\n return EntidadeValidator::class;\n }", "title": "" }, { "docid": "5927fcaa81eed4e4a6d93a29fba40782", "score": "0.55573034", "text": "public function validator()\n {\n\n return CompanyValidator::class;\n }", "title": "" }, { "docid": "10c42c77b99727f37faa447f059612c9", "score": "0.55404973", "text": "public function validator()\n {\n\n return IncomeValidator::class;\n }", "title": "" }, { "docid": "68e64c1b85b45b31800e1105f292d5af", "score": "0.55247927", "text": "public function validator()\n {\n\n return ServiceContactValidator::class;\n }", "title": "" }, { "docid": "a320c2793373d44cadfcfea66ef1312c", "score": "0.55213356", "text": "public function validator()\n {\n\n return MessageValidator::class;\n }", "title": "" }, { "docid": "931f11e41541bb982ce4c2cb9db8c682", "score": "0.55181444", "text": "public function & GetValidators ();", "title": "" }, { "docid": "043db7a8f467324266df9105b8a78f52", "score": "0.55140716", "text": "public function validatedBy()\n\t{\n\t\treturn get_class($this).'Validator';\n\t}", "title": "" }, { "docid": "55ac18b7de7626ba02f6e93425cf24e4", "score": "0.55106956", "text": "protected function prepareForValidation()\n {\n\n $this->sanitizeInput();\n\n return parent::getValidatorInstance();\n }", "title": "" }, { "docid": "dd9cf9ab74fb56a46647c254f3ba5dee", "score": "0.55034745", "text": "public function validator()\n {\n\n return LocationValidator::class;\n }", "title": "" }, { "docid": "b1e2539d1444a2b5992fa75c8e76a898", "score": "0.5501689", "text": "public function validator()\n {\n\n return SumberDanaValidator::class;\n }", "title": "" }, { "docid": "ac724c80c84c35874b8105dbc6e3ce77", "score": "0.5486902", "text": "public function validator()\n {\n\n return SomelineRoleValidator::class;\n }", "title": "" }, { "docid": "1abcef09ba60ecff348734675bd93008", "score": "0.54820895", "text": "public function validator()\n {\n return JingxuanValidator::class;\n }", "title": "" }, { "docid": "23e08c543c148025c42b673a9cd59176", "score": "0.54532427", "text": "public static function getInstance(): UserValidatorContract\n {\n return InMemoryUserValidator::getInstance();\n }", "title": "" }, { "docid": "c44a81c68462107904587c7ce1281e5d", "score": "0.5449758", "text": "public static function populateValidator(Validator $validator)\n\t{\n\t\tif (static::$provider === null)\n\t\t{\n\t\t\tstatic::setProvider(new FromArray(true, 'validation'));\n\t\t}\n\n\t\treturn static::$provider->populateValidator($validator);\n\t}", "title": "" }, { "docid": "11dd2329a512094eb568542be09b08f3", "score": "0.5449039", "text": "public static function getValidators()\n {\n if (isset(static::$validators)) {\n return static::$validators;\n }\n\n // To match the route, we will use a chain of responsibility pattern with the\n // validator implementations. We will spin through each one making sure it\n // passes and then we will know if the route as a whole matches request.\n return static::$validators = [\n new MethodValidator,\n new ScreenIdValidator,\n ];\n }", "title": "" }, { "docid": "ede0b4ff5028a4fb09e7f2513424ce62", "score": "0.544521", "text": "public function getAvataxValidator()\n {\n return $this->_avataxValidator;\n }", "title": "" }, { "docid": "e02521307742baa564f9aa46bc62341a", "score": "0.5439781", "text": "protected function getForm_TypeExtension_Form_ValidatorService()\n {\n return $this->services['form.type_extension.form.validator'] = new \\Symfony\\Component\\Form\\Extension\\Validator\\Type\\FormTypeValidatorExtension(${($_ = isset($this->services['validator']) ? $this->services['validator'] : $this->get('validator')) && false ?: '_'});\n }", "title": "" }, { "docid": "71da00fc143ef8c290fff935b81b74d7", "score": "0.5432728", "text": "public function validator()\n {\n\n return EmpresaValidator::class;\n }", "title": "" } ]
0b92a0e8d28cf01c556994108dbd7ef5
use hook $sections = apply_filters( 'ocean_blog_entry_meta', $sections );
[ { "docid": "55b2de94d298ddb5b4a38e9b8d512771", "score": "0.0", "text": "public static function add_like_to_meta()\n {\n\n\n ?>\n <li>\n\n </li>\n\n<?php\n\n\n return;\n }", "title": "" } ]
[ { "docid": "8b881d93209d2d16a21fc347e25190c2", "score": "0.66553825", "text": "function pmpro_events_tribe_events_remove_post_meta_section( $templates, $slug, $name ) {\r\n\t$r = array();\r\n\t$r = apply_filters( 'pmpro_events_tribe_events_page_modules', $r, $templates, $slug, $name );\r\n\treturn $r;\t\t\r\n}", "title": "" }, { "docid": "9e0c6983ec8d499e396b3f87aee79e6e", "score": "0.63939255", "text": "function dynamic_section($sections) {\n //$sections = array();\n /* $sections[] = array(\n 'title' => __('Section via hook', 'travelogue'),\n 'desc' => __('<p class=\"description\">This is a section created by adding a filter to the sections array. Can be used by child themes to add/remove sections from the options.</p>', 'travelogue'),\n 'icon' => 'el-icon-paper-clip',\n // Leave this as a blank section, no options just some intro text set above.\n 'fields' => array()\n );*/\n\n return $sections;\n }", "title": "" }, { "docid": "e9735e9916204faabfd402ac8feff4e8", "score": "0.627284", "text": "function add_sections($sections = array()){\n\t\t$sections = apply_filters($this->theme.'_siteorigin_theme_customizer_sections', $sections);\n\t\t$this->sections = wp_parse_args($sections, $this->sections);\n\t}", "title": "" }, { "docid": "d80f3ba1600d1edb93778d8f281714eb", "score": "0.6189139", "text": "function section_blog() {\n $classes = array( 'section-blog' );\n $styles = array();\n $output = '';\n \n $prefix = 'blog';\n $prefix = set_field_prefix( $prefix );\n \n $fields = get_sub_field( sprintf( '%ssection', $prefix ) );\n \n $settings = get_sub_field( sprintf( '%ssettings', $prefix ) );\n \n $choose_tag \t = get_sub_field( 'choose_tag' );\n $featured_story\t = get_sub_field( 'featured_story' );\n $featured_post = get_sub_field( 'featured_post' );\n \n $story = _get_story( $choose_tag, $featured_story );\n $blog_post = _get_blog_post( $choose_tag, $featured_post );\n $events = _get_events_list( $choose_tag ); \n \n if( empty( $story ) || empty( $blog_post ) ) {\n return;\n }\n \n \n $output = sprintf( '<div class=\"row expanded small-collapse\" data-equalizer data-equalize-on=\"xxlarge\"><div class=\"small-12 xxlarge-6 columns\">%s</div><div class=\"small-12 xxlarge-6 columns\"><div class=\"blog-events\" data-equalizer-watch>%s%s</div></div></div>', \n $story, $blog_post, $events );\n \n // Do not change\n \n $args = array( 'class' => $classes, 'style' => $styles );\n \n _s_section( $output, $settings, $args );\n \n }", "title": "" }, { "docid": "779e366d753e1e5d4d7e5fe77715404e", "score": "0.6160964", "text": "function dynamic_section( $sections ) {\n //$sections = array();\n $sections[] = array(\n 'title' => __( 'Section via hook', 'redux-framework-demo' ),\n 'desc' => __( '<p class=\"description\">This is a section created by adding a filter to the sections array. Can be used by child themes to add/remove sections from the options.</p>', 'redux-framework-demo' ),\n 'icon' => 'el el-paper-clip',\n // Leave this as a blank section, no options just some intro text set above.\n 'fields' => array()\n );\n\n return $sections;\n }", "title": "" }, { "docid": "7f259f34efc9765264b2bc3cd63366e4", "score": "0.6158654", "text": "public function do_section() {\n\t\tdo_action( 'hestia_do_blog_section', false );\n\t}", "title": "" }, { "docid": "a91d9e39981074b597f79fe7fbdb5845", "score": "0.61272997", "text": "function audition_admin_get_settings_sections() {\n\treturn (array) apply_filters('audition_admin_get_settings_sections', array(\n\t\t'audition_settings_login' => array(\n\t\t\t'title' => __('Log In'),\n\t\t\t'callback' => '__return_null',\n\t\t\t'page' => 'audition',\n\t\t),\n\t\t'audition_settings_registration' => array(\n\t\t\t'title' => __('Registration', 'audition'),\n\t\t\t'callback' => '__return_null',\n\t\t\t'page' => 'audition',\n\t\t),\n\t\t'audition_settings_slugs' => array(\n\t\t\t'title' => __('Slugs', 'audition'),\n\t\t\t'callback' => 'audition_admin_setting_callback_slugs_section',\n\t\t\t'page' => 'audition',\n\t\t),\n\t));\n}", "title": "" }, { "docid": "ccbb3c0da819cc9122ca502c9654924d", "score": "0.60687965", "text": "function bit51_home_genesis_meta() {\n\t\n\tglobal $paged;\n\t\n\tif( $paged < 1 ) {\n\n\t\tif ( is_active_sidebar( 'intro-left' ) || is_active_sidebar( 'intro-center' ) || is_active_sidebar( 'into-right' ) ) {\n\t\t\tadd_action( 'genesis_before_content', 'bit51_home_loop_helper', 1 );\n\t\t}\n\n\t}\n\t\n}", "title": "" }, { "docid": "cadba003d31031db9613145012dfbcd7", "score": "0.6000866", "text": "function mcedc_post_info_filter($post_info) {\nif (!is_page()) {\n $post_info = '[post_date] [post_edit]';\n return $post_info;\n}}", "title": "" }, { "docid": "aff7397ac61399854bf94d8b82d1236a", "score": "0.5962423", "text": "function owlab_masterslider_starter_sections( $sections ){\n \n $sections[] = array(\n 'id' => 'tj_sliders_section', \n 'title' => __( 'Toranj galleries','toranj' ), \n 'desc' => ''\n );\n \n return $sections;\n}", "title": "" }, { "docid": "769cd2da03ff65d6fabfbb48d600637a", "score": "0.59362817", "text": "function hybrid_entry_meta() {\n\n\t$meta = '';\n\n\tif ( 'post' == get_post_type() )\n\t\t$meta = '<p class=\"entry-meta\">' . __( '[entry-terms taxonomy=\"category\" before=\"Posted in \"] [entry-terms taxonomy=\"post_tag\" before=\"| Tagged \"] [entry-comments-link before=\"| \"]', hybrid_get_textdomain() ) . '</p>';\n\n\telseif ( is_page() && current_user_can( 'edit_page', get_the_ID() ) )\n\t\t$meta = '<p class=\"entry-meta\">[entry-edit-link]</p>';\n\n\techo apply_atomic_shortcode( 'entry_meta', $meta );\n}", "title": "" }, { "docid": "baa20b452ef568f4a3c59ee48657d158", "score": "0.5919762", "text": "public function add_hooks(){\n\n add_action('pre_get_posts', array( $this, 'filter_courses_archive' ) );\n\n }", "title": "" }, { "docid": "04a7fe29e7f7626ef2dd46ce346ed7b8", "score": "0.5874385", "text": "public function hook_admin_article_fields(){return;}", "title": "" }, { "docid": "11c3818866ae167284cd3ce8c06cffe2", "score": "0.5871956", "text": "private function sections ()\n {\n return ['formations', 'posts'];\n }", "title": "" }, { "docid": "a0902a154a76559d4bb6a542bfc6e894", "score": "0.58072", "text": "public function getSections()\n {\n return apply_filters(HooksInterface::SETTINGS_SECTIONS_FILTER, array());\n }", "title": "" }, { "docid": "3cdcc68deedd8f4665fc726151f03a26", "score": "0.5788347", "text": "function homepage_filter_get_map () {\r\n\r\n //get the generic filter array\r\n $generic_filter_array = td_global::get_map_filter_array();\r\n\r\n //remove items from array\r\n $offset = 0;\r\n foreach ($generic_filter_array as $field_array) {\r\n if ($field_array['param_name'] == \"hide_title\") {\r\n array_splice($generic_filter_array, $offset, 1);\r\n }\r\n $offset++;\r\n }\r\n\r\n\r\n //change the default limit for Featured posts\r\n $generic_filter_array[6]['value'] = 10;\r\n\r\n\r\n //add the show featured posts in the loop setting\r\n array_push ($generic_filter_array,\r\n array(\r\n \"param_name\" => \"show_featured_posts\",\r\n \"type\" => \"dropdown\",\r\n \"value\" => array('- Show featured posts -' => '', 'Hide featured posts' => 'hide_featured'),\r\n \"heading\" => 'Featured posts:',\r\n \"description\" => \"\",\r\n \"holder\" => \"div\",\r\n \"class\" => \"\"\r\n )\r\n );\r\n\r\n\r\n\r\n return array(\r\n \"name\" => 'Templates with articles',\r\n \"base\" => \"\",\r\n \"class\" => \"\",\r\n \"controls\" => \"full\",\r\n \"category\" => \"\",\r\n 'icon' => '',\r\n \"params\" => $generic_filter_array\r\n );\r\n\r\n }", "title": "" }, { "docid": "22934f70334526e42f99cf6777235fe0", "score": "0.5788315", "text": "function signature_home_genesis_meta() {\n\n\tif ( is_active_sidebar( 'slider' ) || is_active_sidebar( 'property-search' ) || is_active_sidebar( 'properties' ) || is_active_sidebar( 'welcome' ) || is_active_sidebar( 'communities' ) || is_active_sidebar( 'featured-bottom-left' ) || is_active_sidebar( 'featured-bottom-right' ) ) {\n\t\n\t\tremove_action( 'genesis_loop', 'genesis_do_loop' );\n\t\tadd_action( 'genesis_loop', 'signature_home_loop_helper' );\n\t\tadd_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' );\n\n\t}\n}", "title": "" }, { "docid": "abbbbb805720a0beec47c1f0fff051b9", "score": "0.5759395", "text": "function callback_posts() {\n\t\n\tglobal $SBLCK;\n\t$P = $SBLCK->get( 'posts' );\n\t\n\t$posts_data = [];\n\t\n\t$args = [\n\t\t\t'post__not_in' => get_option( 'sticky_posts' ),\n\t\t\t'posts_per_page' => - 1,\n\t\t\t'post_type' => $P['types'],\n\t\t\t'orderby' => [ 'type' => 'ASC', 'menu_order' => 'ASC', 'date' => 'DESC' ],\n\t\t];\n\t\n\t$posts = get_posts( apply_filters( 'sectionblock_posts_args', $args ) );\n\t\n\tforeach ( $posts as $post ) {\n\t\t\n\t\t$posts_data[] = (object) [\n\t\t\t'id' => $post->ID,\n\t\t\t'slug' => $post->post_name,\n\t\t\t'type' => $post->post_type,\n\t\t\t'title' => $post->post_title,\n\t\t];\n\t}\n\t\n\treturn apply_filters( 'sectionblock_posts_list', $posts_data );\n}", "title": "" }, { "docid": "4421a789fa4a6ceb91d752f03acc8573", "score": "0.57559174", "text": "function presscore_get_pages_with_basic_meta_boxes() {\n\treturn apply_filters( 'presscore_pages_with_basic_meta_boxes', array( 'page', 'post' ) );\n}", "title": "" }, { "docid": "9cd3e363c1db6adb85f8231e23b64aca", "score": "0.5747979", "text": "function genesisawesome_post_info_filter() {\n\treturn '[post_date] [post_author_posts_link] [post_comments] [post_edit]';\n}", "title": "" }, { "docid": "4691e2959ca5f7b126808380ff43822c", "score": "0.57392097", "text": "function slider_metadata(){\n global $post;\n $slidermeta = get_post_meta($post->ID);\n require_once WPMU_PLUGIN_DIR . '/custom_slider/views/metadata.php';\n }", "title": "" }, { "docid": "eda10a074431cd5ec7d681c961eeb894", "score": "0.5729839", "text": "function colormag_entry_meta() {\n if ( in_array(get_post_type(), POST_LIKE_POSTTYPES) ) :\n echo '<div class=\"below-entry-meta\">';\n ?>\n\n <?php\n $time_string = '<time class=\"entry-date published\" datetime=\"%1$s\">%2$s</time>';\n if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) {\n $time_string .= '<time class=\"updated\" datetime=\"%3$s\">%4$s</time>';\n }\n $time_string = sprintf( $time_string,\n esc_attr( get_the_date( 'c' ) ),\n esc_html( get_the_date() ),\n esc_attr( get_the_modified_date( 'c' ) ),\n esc_html( get_the_modified_date() )\n );\n printf( __( '<span class=\"posted-on\"><a href=\"%1$s\" title=\"%2$s\" rel=\"bookmark\"><i class=\"fa fa-calendar-o\"></i> %3$s</a></span>', 'colormag' ),\n esc_url( get_permalink() ),\n esc_attr( get_the_time() ),\n $time_string\n ); ?>\n\n <?php\n if ( ! post_password_required() && comments_open() ) { ?>\n <span class=\"comments\"><?php comments_popup_link( __( '<i class=\"fa fa-comment\"></i> 0 Comment', 'colormag' ), __( '<i class=\"fa fa-comment\"></i> 1 Comment', 'colormag' ), __( '<i class=\"fa fa-comments\"></i> % Comments', 'colormag' ) ); ?></span>\n <?php }\n $tags_list = get_the_tag_list( '<span class=\"tag-links\"><i class=\"fa fa-tags\"></i>', __( ', ', 'colormag' ), '</span>' );\n if ( $tags_list ) echo $tags_list;\n\n edit_post_link( __( 'Edit', 'colormag' ), '<span class=\"edit-link\"><i class=\"fa fa-edit\"></i>', '</span>' );\n\n echo '</div>';\n endif;\n}", "title": "" }, { "docid": "45866b536d6295940b0437e5f2c375c9", "score": "0.5725263", "text": "function spacious_entry_meta() {\n if ( 'post' == get_post_type() ) :\n\t echo '<footer class=\"entry-meta-bar clearfix\">';\n\t echo '<div class=\"entry-meta clearfix\">';\n\t ?>\n\n\t <span class=\"by-author author vcard\"><a class=\"url fn n\" href=\"<?php echo get_author_posts_url( get_the_author_meta( 'ID' ) ); ?>\"><?php the_author(); ?></a></span>\n\n\t <?php\n\t $time_string = '<time class=\"entry-date published\" datetime=\"%1$s\">%2$s</time>';\n\t if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) {\n\t\t $time_string .= '<time class=\"updated\" datetime=\"%3$s\">%4$s</time>';\n\t }\n\t $time_string = sprintf( $time_string,\n\t\t esc_attr( get_the_date( 'c' ) ),\n\t\t esc_html( get_the_date() ),\n\t\t esc_attr( get_the_modified_date( 'c' ) ),\n\t\t esc_html( get_the_modified_date() )\n\t );\n\t printf( __( '<span class=\"date\"><a href=\"%1$s\" title=\"%2$s\" rel=\"bookmark\">%3$s</a></span>', 'spacious' ),\n\t\t esc_url( get_permalink() ),\n\t\t esc_attr( get_the_time() ),\n\t\t $time_string\n\t ); ?>\n\n\t <?php if( has_category() ) { ?>\n\t\t <span class=\"category\"><?php the_category(', '); ?></span>\n\t <?php } ?>\n\n\t <?php if ( comments_open() ) { ?>\n\t\t <span class=\"comments\"><?php comments_popup_link( __( 'No Comments', 'spacious' ), __( '1 Comment', 'spacious' ), __( '% Comments', 'spacious' ), '', __( 'Comments Off', 'spacious' ) ); ?></span>\n\t <?php } ?>\n\n\t <?php edit_post_link( __( 'Edit', 'spacious' ), '<span class=\"edit-link\">', '</span>' ); ?>\n\n\t <?php if ( ( ( spacious_options( 'spacious_archive_display_type', 'blog_large' ) != 'blog_full_content' ) && ! is_single() ) || is_archive() || is_search() ) { ?>\n\t\t <span class=\"read-more-link\"><a class=\"read-more\" href=\"<?php the_permalink(); ?>\"><?php _e( 'Read more', 'spacious' ); ?></a></span>\n\t <?php } ?>\n\n\t <?php\n\t echo '</div>';\n\t echo '</footer>';\n endif;\n}", "title": "" }, { "docid": "1466e938bc6fdadb478d5669e1369d3a", "score": "0.5708951", "text": "function gat_post_meta_filter($post_meta) {\n\t$post_meta = '[post_categories] [post_tags]';\n\treturn $post_meta;\n}", "title": "" }, { "docid": "1f008664cad53bc43f3b8943c544a7cb", "score": "0.56782514", "text": "protected function walk_section_config_array() {\r\n\t\tarray_walk( $this->metabox, array( $this, 'add_section' ) );\r\n\t}", "title": "" }, { "docid": "b18dd09cbaecc37c79a6a84eb125dc61", "score": "0.56748736", "text": "function tml_admin_get_settings_sections() {\n\t/**\n\t * Filters the settings sections.\n\t *\n\t * @since 7.0\n\t *\n\t * @param array $sections The settings sections.\n\t */\n\treturn (array) apply_filters( 'tml_admin_get_settings_sections', array(\n\t\t'tml_settings_general' => array(\n\t\t\t'title' => __( 'General', 'theme-my-login' ),\n\t\t\t'callback' => '__return_null',\n\t\t\t'page' => 'theme-my-login',\n\t\t),\n\t\t'tml_settings_login' => array(\n\t\t\t'title' => __( 'Log In' ),\n\t\t\t'callback' => '__return_null',\n\t\t\t'page' => 'theme-my-login',\n\t\t),\n\t\t'tml_settings_registration' => array(\n\t\t\t'title' => __( 'Registration', 'theme-my-login' ),\n\t\t\t'callback' => '__return_null',\n\t\t\t'page' => 'theme-my-login',\n\t\t),\n\t\t'tml_settings_slugs' => array(\n\t\t\t'title' => __( 'Slugs', 'theme-my-login' ),\n\t\t\t'callback' => 'tml_admin_setting_callback_slugs_section',\n\t\t\t'page' => 'theme-my-login',\n\t\t),\n\t) );\n}", "title": "" }, { "docid": "e7841758a75304b1ef99fc87c8340cc2", "score": "0.56738544", "text": "function profile_cct_add_teaching_fields_filter($type_of= null){\n\t// if(in_array($type_of, array('page','list')) )\n\tadd_filter( 'profile_cct_dynamic_fields', 'profile_cct_add_teaching_fields' );\n\t\t\n\tadd_action('profile_cct_display_shell_teaching', 'profile_cct_textarea_display_shell',10, 3);\n\tadd_action('profile_cct_field_shell_teaching', 'profile_cct_textarea_field_shell',10, 3);\n\t\n}", "title": "" }, { "docid": "1085149df3a90b9b1ea85508f94f63a2", "score": "0.5669653", "text": "function add_another_section($sections){\n\t\n\t//$sections = array();\n\t$sections[] = array(\n\t\t\t\t'title' => __('A Section added by hook', 'best' ),\n\t\t\t\t'desc' => '<p class=\"description\">' . __('This is a section created by adding a filter to the sections array, great to allow child themes, to add/remove sections from the options.', 'best' ) . '</p>',\n\t\t\t\t//all the glyphicons are included in the options folder, so you can hook into them, or link to your own custom ones.\n\t\t\t\t//You dont have to though, leave it blank for default.\n\t\t\t\t'icon' => trailingslashit(get_template_directory_uri()).'options/img/glyphicons/glyphicons_062_attach.png',\n\t\t\t\t//Lets leave this as a blank section, no options just some intro text set above.\n\t\t\t\t'fields' => array()\n\t\t\t\t);\n\t\n\treturn $sections;\n\t\n}", "title": "" }, { "docid": "86948507d95bb4fcc05bf851a0a77991", "score": "0.5650122", "text": "function hook_social_content_block_info_alter(array &$info) {\n if (isset($info['event_content_block'])) {\n $info['event_content_block']['fields'][] = 'field_content_tags';\n }\n}", "title": "" }, { "docid": "1cb025f5a6c04c62c098d4d58b6eab64", "score": "0.5641232", "text": "function eastBlue_entry_meta() {\n\t// Sticky post\n\tif ( is_sticky() && is_home() && ! is_paged() )\n\t\techo '<span class=\"featured-post\">' . __( 'Sticky', 'eastBlue' ) . '</span>';\n\t\n\t// Post author\n\tif ( 'post' == get_post_type() ) {\n\t\tprintf( '<span class=\"icon-user author vcard\"><a class=\"url fn n\" href=\"%1$s\" title=\"%2$s\" rel=\"author\">%3$s</a></span>',\n\t\t\tesc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),\n\t\t\tesc_attr( sprintf( __( '查看%s的所有文章', 'eastBlue' ), get_the_author() ) ),\n\t\t\tget_the_author()\n\t\t);\n\t}\n\t// post time\n\tif ( ! has_post_format( 'link' ) && 'post' == get_post_type() )\n\t\teastBlue_entry_date();\n\t// Translators: used between list items, there is a space after the comma.\n\t$categories_list = get_the_category_list( __( ', ', 'eastBlue' ) );\n\tif ( $categories_list ) {\n\t\techo '<span class=\"icon-cat\">' . $categories_list . '</span>';\n\t}\n\n\t// Translators: used between list items, there is a space after the comma.\n\t$tag_list = get_the_tag_list( '', __( ', ', 'eastBlue' ) );\n\tif ( is_single() && $tag_list ) {\n\t\techo '<span class=\"icon-tag\">' . $tag_list . '</span>';\n\t}\n\n}", "title": "" }, { "docid": "2af5a345a47eb3714930462f6fe5fca1", "score": "0.56356424", "text": "function build_option_meta_foot_array($template = null)\n{\n\n if ($template == null)\n return;\n\n $id = $template . \"_itemfoot_meta\";\n $array = build_option_meta_array(array(\n 'id' => $id,\n 'name' => __(\"Meta Below Content\"),\n 'desc' => __(\"Each listed Post entry will have meta Information that can be displayed below it's title. Enable/Disable their display here\")\n )\n );\n\n return $array;\n}", "title": "" }, { "docid": "9319ce6b6b5a16595e5d747c0d83ca3b", "score": "0.56287", "text": "function koala_familles_genesis_meta() {\n\n\tif ( is_active_sidebar( 'familles-intro' )) {\n\n\t\t// Enqueue koala script.\n\t\tadd_action( 'wp_enqueue_scripts', 'koala_enqueue_koala_script' );\n\n\t\t// Add koala-home body class.\n\t\tadd_filter( 'body_class', 'koala_body_class' );\n\n\t\t// Force full width content layout.\n\t\tadd_filter( 'genesis_site_layout', '__genesis_return_full_width_content' );\n\n\t\t// Remove primary navigation.\n\t\t// remove_action( 'genesis_before_content_sidebar_wrap', 'genesis_do_nav' );\n\n\t\t// Remove breadcrumbs.\n\t\tremove_action( 'genesis_before_loop', 'genesis_do_breadcrumbs');\n\n\t\t// Remove the default Genesis loop.\n\t\t// remove_action( 'genesis_loop', 'genesis_do_loop' );\n\n\t\t// Add homepage widgets.\n\t\tadd_action( 'genesis_loop', 'koala_familles_widgets' );\n\n\t\t//Featured image as background\n\t\tadd_action( 'wp_head', 'koala_featured_as_background', 99);\n\n\t\t// Add custom opening div for entry title\n\t\tadd_action( 'genesis_before_entry', 'koala_do_before_entry', 7 );\n\n\t\t// Add custom closing div for entry title\nadd_action( 'genesis_after_entry', 'koala_do_after_entry' );\n\n\n\t}\n}", "title": "" }, { "docid": "85781994383e44ebc2648318ddb68d82", "score": "0.5619851", "text": "function pkt_entry_meta() {\n\n if ( 'post' == get_post_type() ) :\n\n echo '<footer class=\"entry-meta-bar clearfix\">';\n\n echo '<div class=\"entry-meta clearfix\">';\n\n ?>\n\n\n\n <span class=\"by-author author vcard\"><a class=\"url fn n\" href=\"<?php echo get_author_posts_url( get_the_author_meta( 'ID' ) ); ?>\"><?php the_author(); ?></a></span>\n\n\n\n <?php\n\n $time_string = '<time class=\"entry-date published\" datetime=\"%1$s\">%2$s</time>';\n\n if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) {\n\n $time_string .= '<time class=\"updated\" datetime=\"%3$s\">%4$s</time>';\n\n }\n\n $time_string = sprintf( $time_string,\n\n esc_attr( get_the_date( 'c' ) ),\n\n esc_html( get_the_date() ),\n\n esc_attr( get_the_modified_date( 'c' ) ),\n\n esc_html( get_the_modified_date() )\n\n );\n\n printf( __( '<span class=\"date\"><a href=\"%1$s\" title=\"%2$s\" rel=\"bookmark\">%3$s</a></span>', 'pkt' ),\n\n esc_url( get_permalink() ),\n\n esc_attr( get_the_time() ),\n\n $time_string\n\n ); ?>\n\n\n\n <?php if( has_category() ) { ?>\n\n <span class=\"category\"><?php the_category(', '); ?></span>\n\n <?php } ?>\n\n\n\n <?php if ( comments_open() ) { ?>\n\n <span class=\"comments\"><?php comments_popup_link( __( 'No Comments', 'pkt' ), __( '1 Comment', 'pkt' ), __( '% Comments', 'pkt' ), '', __( 'Comments Off', 'pkt' ) ); ?></span>\n\n <?php } ?>\n\n\n\n <?php edit_post_link( __( 'Edit', 'pkt' ), '<span class=\"edit-link\">', '</span>' ); ?>\n\n\n\n <?php if ( ( pkt_options( 'pkt_archive_display_type', 'blog_large' ) != 'blog_full_content' ) && !is_single() ) { ?>\n\n <span class=\"read-more-link\"><a class=\"read-more\" href=\"<?php the_permalink(); ?>\"><?php _e( 'Read more', 'pkt' ); ?></a></span>\n\n <?php } ?>\n\n\n\n <?php\n\n echo '</div>';\n\n echo '</footer>';\n\n endif;\n\n}", "title": "" }, { "docid": "14eb44ba8cf4eec0c9f8b3ee25e63799", "score": "0.5614437", "text": "function twentythirteen_entry_meta() {\n if ( is_sticky() && is_home() && ! is_paged() )\n echo '<span class=\"featured-post\">Sticky</span>';\n\n if ( ! has_post_format( 'link' ) && 'post' == get_post_type() )\n twentythirteen_entry_date();\n\n // Translators: used between list items, there is a space after the comma.\n /* $categories_list = get_the_category_list(', ');\n if ( $categories_list ) {\n echo '<span class=\"categories-links\">' . $categories_list . '</span>';\n }\n\n // Translators: used between list items, there is a space after the comma.\n $tag_list = get_the_tag_list( '', ', ');\n if ( $tag_list ) {\n echo '<span class=\"tags-links\">' . $tag_list . '</span>';\n }\n\n // Post author\n if ( 'post' == get_post_type() ) {\n printf( '<span class=\"author vcard\"><a class=\"url fn n\" href=\"%1$s\" rel=\"author\">%3$s</a></span>',\n esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),\n esc_attr( sprintf('View all posts by %s', get_the_author() ) ),\n get_the_author()\n );\n }*/\n}", "title": "" }, { "docid": "3f594b275efc1c7e0ffab65497e18378", "score": "0.5597853", "text": "function get_settings_sections() {\n $sections = array(\n array(\n 'id' => 'bs_upl_basic',\n 'title' => __( 'Slider Settings', 'bs_rp' ),\n //'callback' =>'callback_section_ps',\n ),\n );\n return $sections;\n }", "title": "" }, { "docid": "95e95ba203ee384bd1f5cb7b3e11abeb", "score": "0.55919343", "text": "function jordantheme_footer_top($wp_customize) {\n //add section to admin customize theme\n //wp object->wp method('my var name', additional options)\n $wp_customize->add_section('jordantheme-footer-top-section', array(\n 'title' => 'Footer top section'\n ));\n //foreach field need a setting(db) and a control(user display)\n //wp object->wp method('my var name', additional options)\n\n $wp_customize->add_setting('jordantheme-footer-top-section-publish', array(\n 'default' => 'No'\n ));\n $wp_customize->add_control( new WP_Customize_Control($wp_customize, 'jordan-theme-publish-var', array(\n 'label' => 'Publish section?',\n 'section' => 'jordantheme-footer-top-section',\n 'settings' => 'jordantheme-footer-top-section-publish',\n 'type' => 'select',\n 'choices' => array('No' => 'No', 'Yes'=> 'Yes')\n )));\n\n $wp_customize->add_setting('jordantheme-footer-top-section-title', array(\n 'default' => 'Title setting'\n ));\n $wp_customize->add_control( new WP_Customize_Control($wp_customize, 'jordan-theme-title-var', array(\n 'label' => 'Title Label',\n 'section' => 'jordantheme-footer-top-section',\n 'settings' => 'jordantheme-footer-top-section-title',\n 'type' => 'text'\n )));\n\n $wp_customize->add_setting('jordantheme-footer-top-section-link');\n $wp_customize->add_control( new WP_Customize_Control($wp_customize, 'jordan-theme-link-var', array(\n 'label' => 'Title Link',\n 'section' => 'jordantheme-footer-top-section',\n 'settings' => 'jordantheme-footer-top-section-link',\n 'type' => 'dropdown-pages'\n )));\n\n $wp_customize->add_setting('jordantheme-footer-top-section-textarea', array(\n 'default' => 'TextArea setting'\n ));\n $wp_customize->add_control( new WP_Customize_Control($wp_customize, 'jordan-theme-textarea-var', array(\n 'label' => 'Text Area Label',\n 'section' => 'jordantheme-footer-top-section',\n 'settings' => 'jordantheme-footer-top-section-textarea',\n 'type' => 'textarea'\n )));\n\n $wp_customize->add_setting('jordantheme-footer-top-section-image');\n $wp_customize->add_control( new WP_Customize_Cropped_Image_Control($wp_customize, 'jordan-theme-image-var', array(\n 'label' => 'Image',\n 'section' => 'jordantheme-footer-top-section',\n 'settings' => 'jordantheme-footer-top-section-image',\n 'width'=> 750,\n 'height' => 400\n )));\n}", "title": "" }, { "docid": "c148de6d41411ce332c657248cfde719", "score": "0.5582616", "text": "function homepage_metaboxes( array $meta_boxes ) {\n\n $fields = array(\n array(\n 'id' => 'homepage-section2-content',\n 'name' => 'Section 2',\n 'type' => 'wysiwyg',\n 'options' => array(\n 'textarea_rows' => 5\n )\n ),\n array(\n 'id' => 'homepage-section3-content',\n 'name' => 'Section 3',\n 'type' => 'wysiwyg',\n 'options' => array(\n 'textarea_rows' => 5\n )\n ),\n\n array(\n 'id' => 'homepage-cleaning-content',\n 'name' => 'Cleaning Services',\n 'type' => 'wysiwyg',\n 'options' => array(\n 'textarea_rows' => 5\n )\n ),\n array(\n 'id' => 'homepage-security-content',\n 'name' => 'Security Services',\n 'type' => 'wysiwyg',\n 'options' => array(\n 'textarea_rows' => 5\n )\n ),\n array(\n 'id' => 'homepage-specialist-content',\n 'name' => 'Specialist Services',\n 'type' => 'wysiwyg',\n 'options' => array(\n 'textarea_rows' => 5\n )\n ),\n );\n\n $meta_boxes[] = array(\n 'title' => 'Sections',\n 'pages' => 'page',\n 'show_on' => array( 'id' => array( 2 ) ),\n 'context' => 'normal',\n 'priority' => 'high',\n 'fields' => $fields // an array of fields - see individual field documentation.\n );\n\n return $meta_boxes; \n}", "title": "" }, { "docid": "2e152581d2754e49dbc32116354571d6", "score": "0.5581426", "text": "function manage_post_columns($columns){\n if(isset($_GET['post_type'])=='book'){\n return $columns;\n }\n $columns['post_id'] = \"ID\";\n $columns['thumbnails'] = \"Post Thumbnails\";\n $columns['wordCount'] = \"word Count\";\n return $columns;\n}", "title": "" }, { "docid": "789c9fdf535c9a71bb3ceabe3b1a49c3", "score": "0.55747646", "text": "function setup() {\n\tadd_filter( 'hnf_meta_hide_title', __NAMESPACE__ . '\\\\opt_in' );\n}", "title": "" }, { "docid": "1f004dca7c50d459f4fb18fdc3d83317", "score": "0.5574605", "text": "function showFieldsWordPress($post, $metabox) {\n include('admin/custom_field.php');\n}", "title": "" }, { "docid": "f09b630a8a4d5a75e3a2b70a378a2c3b", "score": "0.55716795", "text": "function page_blog_custom_fields() {\n add_meta_box(\n 'page_blog_custom_fields', // $id\n 'Blog Options', // $title\n 'show_page_blog_custom_fields', // $callback\n 'page', // $page\n 'normal', // $context\n 'high'); // $priority\n}", "title": "" }, { "docid": "e456c39299baaa0d623906e4e7ef4edb", "score": "0.55704576", "text": "function get_settings_sections() {\n $sections = array(\n array(\n 'id' => 'satosms_general',\n 'title' => __( 'General Settings', 'satosms' )\n ),\n array(\n 'id' => 'satosms_gateway',\n 'title' => __( 'SMS Gateway Settings', 'satosms' )\n ),\n\n array(\n 'id' => 'satosms_message',\n 'title' => __( 'SMS Settings', 'satosms' )\n )\n );\n return apply_filters( 'satosms_settings_sections' , $sections );\n }", "title": "" }, { "docid": "c95e1102d959a9582e7aa0c32fde844b", "score": "0.5559719", "text": "function template_filter() {\n\n\t\t//if not a page or single post, kick\n\t\tif ( !is_single() && !is_page() )\n\t\t\treturn;\n\t\n\t\t//get current post ID\n\t\tglobal $wp_query;\n\t\t$post_id = $wp_query->post->ID;\n\t\n\t\t//Look for a \"no_formatting\" page meta\n\t\t$toggle = get_post_meta( $post_id, $this->meta_key, true );\n\n\t\t//if the meta is set, call our template filter\n\t\tif ( !$toggle )\n\t\t\treturn;\n\t\t\t\n\t\tremove_filter( 'the_content', 'wpautop' );\n\t\tadd_filter('template_include', array( &$this, 'template_callback' ), 100);\n\t\n\t}", "title": "" }, { "docid": "36f2c3960f9330392881c2e31ed9022f", "score": "0.55473155", "text": "function board_agenda_front_genesis_meta() {\n\t\tremove_action( 'genesis_loop', 'genesis_do_loop' );\n\n\t\t//* Remove the post content (requires HTML5 theme support)\n\t\tremove_action( 'genesis_entry_content', 'genesis_do_post_content' );\n\n\t\t//add_action( 'genesis_entry_content', 'sanders_front_content' );\n\t\tadd_action( 'genesis_loop', 'board_agenda_archive' );\n\n\n}", "title": "" }, { "docid": "58e345200d3b021fe3818da6d4286c63", "score": "0.5547285", "text": "function meilleur_copain_customizer_sections( $sections = array() ) {\n return array_merge( $sections, array(\n 'meilleur_copain_custom_css_section' => array(\n 'title' => __( 'Styles d’accompagnement', 'meilleur-copain' ),\n\t\t\t'panel' => 'bp_nouveau_panel',\n\t\t\t'priority' => 90,\n\t\t\t'description' => __( 'Ajouter des règles de style pour optimiser l’affichage des pages de BuddyPress.', 'meilleur-copain' ),\n ),\n ) );\n}", "title": "" }, { "docid": "ae6bc030e206c7fefdd7972195a43cb8", "score": "0.5535037", "text": "function dahz_metabox_setup() {\r\n\r\n add_meta_box( 'df_metaboxed_subtitle', 'Page Settings', 'dahz_build_subtitle_page', 'page', 'normal', 'high' );\r\n add_meta_box( 'df_metaboxed_cstm_archive', 'Post Settings', 'dahz_build_custom_archive', 'page', 'normal', 'high' );\r\n\r\n foreach ( array( 'post', 'page' ) as $post_type ) {\r\n add_meta_box( 'df_metaboxed_affiliate', 'Affiliate', 'dahz_build_affiliate', $post_type, 'normal', 'high' );\r\n }\r\n\r\n add_meta_box( 'df_metaboxed_sponsored', 'Sponsored Text Area', 'dahz_build_sponsored', 'post', 'normal', 'high' );\r\n\r\n}", "title": "" }, { "docid": "b5658bf254ca5c00d28959323da876d6", "score": "0.5513469", "text": "public function setup_filters() {\n\n\t\tadd_filter( 'gform_entry_detail_meta_boxes', array( Entry_Details\\Entry_Details::instance(), 'download_information_metabox' ), 10, 3 );\n\n\t}", "title": "" }, { "docid": "967003e22aa964632a0023decd4216f9", "score": "0.55108124", "text": "function tkt_custom_columns_content ( $column_id, $post_id ) {\n switch( $column_id ) { \n case 'tkt_layout_area':\n echo ($value = get_post_meta($post_id, '_tkt_layout_part', true ) ) ? $value : 'No Layout Part Defined ';\n break;\n case 'tkt_assigned_to':\n $value = get_post_meta($post_id, '_tkt_assigned_to', true ) ? '<strong>Post Type:</strong> '.get_post_meta($post_id, '_tkt_assigned_to', true ).'; ' : 'Not Assigned To Any Post Type; ';\n $value .= get_post_meta($post_id, '_tkt_used_on_archive', true ) ? '<strong>Archive:</strong> '.get_post_meta($post_id, '_tkt_used_on_archive', true ).'; ' : 'Not Assigned To Any Archive; ';\n echo ($value ? $value : 'No Layout Part Defined');\n break;\n\n //add more items here as needed, just make sure to use the column_id in the filter for each new item.\n\n }\n}", "title": "" }, { "docid": "3cec9826e63fc75c92cab1146fa33832", "score": "0.55073494", "text": "public function setFields()\r\n {\r\n\r\n $args = array(\r\n array(\r\n 'id' => 'post_type_name',\r\n 'title' => 'Post Type',\r\n 'callback' => array($this->cpt_callbacks, 'textField'),\r\n 'page' => 'cpt_manager',\r\n 'section' => 'cptmr_cpt_index',\r\n 'args' => array(\r\n 'option_name' => 'cptmmr_cpt',\r\n 'labels_for' => 'post_type_name',\r\n 'title' => 'Post Type',\r\n //'class' => 'ui-toggle',\r\n // 'data-toggle'=> 'toggle'\r\n )\r\n ),\r\n array(\r\n 'id' => 'name',\r\n 'title' => 'Name',\r\n 'callback' => array($this->cpt_callbacks, 'textField'),\r\n 'page' => 'cpt_manager',\r\n 'section' => 'cptmr_cpt_index',\r\n 'args' => array(\r\n 'option_name' => 'cptmmr_cpt',\r\n 'labels_for' => 'name',\r\n 'title' => 'Name',\r\n //'class' => 'ui-toggle',\r\n // 'data-toggle'=> 'toggle'\r\n )\r\n ),\r\n array(\r\n 'id' => 'singular_name',\r\n 'title' => 'Singular Name',\r\n 'callback' => array($this->cpt_callbacks, 'textField'),\r\n 'page' => 'cpt_manager',\r\n 'section' => 'cptmr_cpt_index',\r\n 'args' => array(\r\n 'option_name' => 'cptmmr_cpt',\r\n 'labels_for' => 'Singular Name',\r\n 'title' => 'Singular Name'\r\n )\r\n ),\r\n array(\r\n 'id' => 'description',\r\n 'title' => 'Description',\r\n 'callback' => array( $this->cpt_callbacks , 'testAreaField'),\r\n 'page' => 'cpt_manager',\r\n 'section' => 'cptmr_cpt_index',\r\n 'args' => array(\r\n 'option_name' => 'cptmmr_cpt',\r\n 'labels_for' => 'Description',\r\n 'title' => 'Description'\r\n )\r\n\r\n ) //description\r\n );\r\n\r\n $this->settings->setFields($args);\r\n // var_dump($this->settings->setFields( $args ));\r\n }", "title": "" }, { "docid": "f12b992bb52bc1d95bf305c1620ade89", "score": "0.5500838", "text": "function init () {\n\t\t\n\t\t// Create the necessary filters.\n\t\tadd_action( 'after_setup_theme', array( &$this, 'create_filters' ), 10 );\n\t\t\n\t\tif ( is_admin() ) {\n\t\n\t\t\t// Register the admin screen.\n\t\t\tadd_action( 'admin_menu', array( &$this, 'register_admin_screen' ), 20 );\n\t\t\t\n\t\t\t// Execute certain code only on the specific admin screen.\n\t\t\tif ( is_admin( $this->admin_page ) ) {\n\t\t\t\n\t\t\t\t// Add contextual help.\n\t\t\t\tadd_action( 'contextual_help', array( &$this, 'admin_screen_help' ), 10, 3 );\n\t\t\t\t\n\t\t\t\t// Setup default shortcodes for reference.\n\t\t\t\t$this->setup_shortcodes();\n\t\t\t\t\n\t\t\t\t// Stored data.\n\t\t\t\t$stored_values = get_option( $this->plugin_prefix . 'stored_meta' );\n\t\t\t\t\n\t\t\t\t// Setup meta areas.\n\t\t\t\t$this->meta_areas = array();\n\t\t\t\t\n\t\t\t\t$this->meta_areas['post_meta'] = array(\n\t\t\t\t\t\t\t\t\t\t'woo_filter_post_meta' => array(\n\t\t\t\t\t\t\t\t\t\t\t\t'title' => __( 'Above post content', 'woothemes' ), \n\t\t\t\t\t\t\t\t\t\t\t\t'default' => '<span class=\"small\">' . __( 'By', 'woothemes' ) . '</span> [post_author_posts_link] <span class=\"small\">' . __( 'on', 'woothemes' ) . '</span> [post_date] <span class=\"small\">' . __( 'in', 'woothemes' ) . '</span> [post_categories before=\"\"] ' . ' [post_edit]', \n\t\t\t\t\t\t\t\t\t\t\t\t'stored_value' => '', \n\t\t\t\t\t\t\t\t\t\t\t\t'description' => __( 'Data above the content of your blog posts.', 'woothemes' )\n\t\t\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\t\t'woo_post_more' => array(\n\t\t\t\t\t\t\t\t\t\t\t\t'title' => __( '\"Read more\" area below posts', 'woothemes' ), \n\t\t\t\t\t\t\t\t\t\t\t\t'default' => '[view_full_article] &middot; [post_comments]', \n\t\t\t\t\t\t\t\t\t\t\t\t'stored_value' => '', \n\t\t\t\t\t\t\t\t\t\t\t\t'description' => __( 'Data below each blog post.', 'woothemes' )\n\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t// Assigned stored data to the appropriate meta_area.\n\t\t\t\tforeach ( $this->meta_areas as $id => $arr ) {\n\t\t\t\t\tforeach ( $this->meta_areas[$id] as $k => $v ) {\n\t\t\t\t\t\tif ( is_array( $stored_values ) && array_key_exists( $k, $stored_values ) ) {\n\t\t\t\t\t\t\t$this->meta_areas[$id][$k]['stored_value'] = $stored_values[$k];\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$this->meta_areas[$id][$k]['stored_value'] = $this->meta_areas[$id][$k]['default'];\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\n\t\t\t\t// Make sure our data is added to the WooFramework settings exporter.\n\t\t\t\tadd_filter( 'wooframework_export_query_inner', array( &$this, 'add_exporter_data' ) );\n\t\t\t\n\t\t\t}\n\t\t\n\t\t} // End IF Statement\n\t\n\t}", "title": "" }, { "docid": "07c4353cd013af0cb33d32a33fc3e17a", "score": "0.55007243", "text": "function sgb_entry_meta() {\n // Translators: used between list items, there is a space after the comma.\n $categories_list = get_the_category_list( __( ', ', 'sgb' ) );\n\n // Translators: used between list items, there is a space after the comma.\n $tag_list = get_the_tag_list( '', __( ', ', 'sgb' ) );\n\n $date = sprintf( 'Veröffentlicht am <time class=\"entry-date\" datetime=\"%3$s\" pubdate>%4$s um %2$s Uhr</time>',\n esc_url( get_permalink() ),\n esc_attr( get_the_time() ),\n esc_attr( get_the_date( 'c' ) ),\n esc_html( get_the_date() )\n );\n\n $author = sprintf( '<span class=\"author vcard\">%1$s %2$s</span>',\n get_the_author_meta( 'first_name' ),\n get_the_author_meta( 'last_name' )\n );\n\n // Translators: 1 is category, 2 is tag, 3 is the date and 4 is the author's name.\n $utility_text = __( '%3$s <span class=\"by-author\"> von %4$s</span>.', 'sgb' );\n\n printf(\n $utility_text,\n $categories_list,\n $tag_list,\n $date,\n $author\n );\n}", "title": "" }, { "docid": "5dd15fcc691784cdfe6ed0642a5e9b51", "score": "0.550028", "text": "function twentythirteen_entry_meta() {\n if ( is_sticky() && is_home() && ! is_paged() )\n echo '<span class=\"featured-post\">' . esc_html__( 'Sticky', 'twentythirteen' ) . '</span>';\n\n if ( ! has_post_format( 'link' ) && in_array( get_post_type(), array( 'post', 'devotional' ) ) )\n twentythirteen_entry_date();\n\n // Translators: used between list items, there is a space after the comma.\n $categories_list = get_the_category_list( __( ', ', 'twentythirteen' ) );\n if ( $categories_list ) {\n echo '<span class=\"categories-links\">' . $categories_list . '</span>';\n }\n\n // Translators: used between list items, there is a space after the comma.\n $tag_list = get_the_tag_list( '', __( ', ', 'twentythirteen' ) );\n if ( $tag_list ) {\n echo '<span class=\"tags-links\">' . $tag_list . '</span>';\n }\n\n // Post author\n if ( 'post' == get_post_type() ) {\n printf( '<span class=\"author vcard\"><a class=\"url fn n\" href=\"%1$s\" title=\"%2$s\" rel=\"author\">%3$s</a></span>',\n esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),\n esc_attr( sprintf( __( 'View all posts by %s', 'twentythirteen' ), get_the_author() ) ),\n get_the_author()\n );\n }\n}", "title": "" }, { "docid": "d363dcab47e39b4008c3a602aec3aac6", "score": "0.5493884", "text": "function gcmaz_remove_filters_func() {\r\n remove_filter( 'the_excerpt', 'sharing_display', 19 );\r\n}", "title": "" }, { "docid": "9ce4d6447c927d6a235620856060767f", "score": "0.54881847", "text": "function hc_default_content_post_type($title,$slug) {\n return array(\n 'post_type' => 'page',\n 'post_title' => wp_strip_all_tags($title),\n 'post_content' => '{\n\t\"main-title\": {\n\t\t\"component\": \"hc_title\",\n\t\t\"id\": \"main-title\",\n\t\t\"subtitle\": \"Archive page for ' . $title . '\",\n\t\t\"title_content\": {\n\t\t\t\"component\": \"hc_title_base\",\n\t\t\t\"id\": \"title-base\",\n\t\t\t\"image\": \"\"\n\t\t},\n\t\t\"title\": \"' . $title . '\"\n\t},\n\t\"section_1\": {\n\t\t\"component\": \"hc_section\",\n\t\t\"id\": \"section_1\",\n\t\t\"section_width\": \"\",\n\t\t\"animation\": \"\",\n\t\t\"animation_time\": \"\",\n\t\t\"timeline_animation\": \"\",\n\t\t\"timeline_delay\": \"\",\n\t\t\"timeline_order\": \"\",\n\t\t\"vertical_row\": \"\",\n\t\t\"box_middle\": \"\",\n\t\t\"css_classes\": \"\",\n\t\t\"custom_css_classes\": \"\",\n\t\t\"custom_css_styles\": \"\",\n\t\t\"section_content\": [\n\t\t\t{\n\t\t\t\t\"component\": \"hc_column\",\n\t\t\t\t\"id\": \"column_1\",\n\t\t\t\t\"column_width\": \"col-md-2\",\n\t\t\t\t\"animation\": \"\",\n\t\t\t\t\"animation_time\": \"\",\n\t\t\t\t\"timeline_animation\": \"\",\n\t\t\t\t\"timeline_delay\": \"\",\n\t\t\t\t\"timeline_order\": \"\",\n\t\t\t\t\"css_classes\": \"\",\n\t\t\t\t\"custom_css_classes\": \"\",\n\t\t\t\t\"custom_css_styles\": \"\",\n\t\t\t\t\"main_content\": []\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"component\": \"hc_column\",\n\t\t\t\t\"id\": \"column_2\",\n\t\t\t\t\"column_width\": \"col-md-8\",\n\t\t\t\t\"animation\": \"\",\n\t\t\t\t\"animation_time\": \"\",\n\t\t\t\t\"timeline_animation\": \"\",\n\t\t\t\t\"timeline_delay\": \"\",\n\t\t\t\t\"timeline_order\": \"\",\n\t\t\t\t\"css_classes\": \"\",\n\t\t\t\t\"custom_css_classes\": \"\",\n\t\t\t\t\"custom_css_styles\": \"\",\n\t\t\t\t\"main_content\": [\n\t\t\t\t\t{\n\t\t\t\t\t\t\"component\": \"hc_pt_grid_list\",\n\t\t\t\t\t\t\"id\": \"5ZtkF\",\n\t\t\t\t\t\t\"css_classes\": \"\",\n\t\t\t\t\t\t\"custom_css_classes\": \"\",\n\t\t\t\t\t\t\"custom_css_styles\": \"\",\n\t\t\t\t\t\t\"post_type_slug\": \"' . $slug . '\",\n\t\t\t\t\t\t\"post_type_category\": \"\",\n\t\t\t\t\t\t\"box\": \"blog_side\",\n\t\t\t\t\t\t\"column\": \"col-md-12\",\n\t\t\t\t\t\t\"row\": \"\",\n\t\t\t\t\t\t\"margins\": \"\",\n\t\t\t\t\t\t\"pagination_type\": \"pagination\",\n\t\t\t\t\t\t\"pag_items\": \"8\",\n\t\t\t\t\t\t\"pag_lm_animation\": \"fade-bottom\",\n\t\t\t\t\t\t\"button_size\": \"pagination-sm\",\n\t\t\t\t\t\t\"boxed\": true,\n\t\t\t\t\t\t\"boxed_inverse\": false,\n\t\t\t\t\t\t\"button_text\": \"Read more\",\n\t\t\t\t\t\t\"hidden_content\": false,\n\t\t\t\t\t\t\"box_animation\": \"\",\n\t\t\t\t\t\t\"pag_scroll_top\": true,\n\t\t\t\t\t\t\"pag_centered\": true,\n\t\t\t\t\t\t\"pag_button_prev\": \"Prev\",\n\t\t\t\t\t\t\"pag_button_next\": \"Next\",\n\t\t\t\t\t\t\"lm_lazy\": false,\n\t\t\t\t\t\t\"lm_button_text\": \"Load more\",\n\t\t\t\t\t\t\"data_options_pagination\": \"\"\n\t\t\t\t\t}\n\t\t\t\t]\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"component\": \"hc_column\",\n\t\t\t\t\"id\": \"column_3\",\n\t\t\t\t\"column_width\": \"col-md-2\",\n\t\t\t\t\"animation\": \"\",\n\t\t\t\t\"animation_time\": \"\",\n\t\t\t\t\"timeline_animation\": \"\",\n\t\t\t\t\"timeline_delay\": \"\",\n\t\t\t\t\"timeline_order\": \"\",\n\t\t\t\t\"css_classes\": \"\",\n\t\t\t\t\"custom_css_classes\": \"\",\n\t\t\t\t\"custom_css_styles\": \"\",\n\t\t\t\t\"main_content\": []\n\t\t\t}\n\t\t],\n\t\t\"section_settings\": \"\"\n\t},\n\t\"scripts\": {\n\t\t\"pagination\": \"jquery.twbsPagination.min.js\"\n\t},\n\t\"css\": {\n\t\t\"content_box\": \"css/content-box.css\",\n\t\t\"image_box\": \"css/image-box.css\"\n\t},\n\t\"css_page\": \"\",\n\t\"template_setting\": {},\n\t\"template_setting_top\": {},\n\t\"page_setting\": {\n\t\t\"settings\": []\n\t}\n}',\n 'post_status' => 'publish',\n 'post_author' => 1,\n 'post_category' => array(8,39)\n );\n}", "title": "" }, { "docid": "0d5c9680796f6570d8a75bd666fc8e2b", "score": "0.54881835", "text": "function plugin_section_text() {\n}", "title": "" }, { "docid": "d9df259d69004ca45b09b47eab53aad2", "score": "0.54862314", "text": "function post_meta_filter($post_meta) {\n if ( 'book_review' == get_post_type() ) {//swap in CPT name\n\t\t$post_meta='[post_terms taxonomy=\"genre\" before=\"Posted under: \"]';//swap in taxonomy and label name\n\t} elseif ( 'post' == get_post_type() ) {\n $post_meta = '[post_categories before=\"Posted under: \"] [post_tags before=\"Tagged with: \"]';\n }\n return $post_meta;\n}", "title": "" }, { "docid": "31bc2b52a2ace0a29a7347326531a6e3", "score": "0.5481929", "text": "function half_baked_entry_meta() {\n\t// Translators: used between list items, there is a space after the comma.\n\t$categories_list = get_the_category_list( __( ', ', 'half_baked_base' ) );\n\n\t// Translators: used between list items, there is a space after the comma.\n\t$tag_list = get_the_tag_list( '', __( ', ', 'half_baked_base' ) );\n\n\t$date = sprintf( '<a href=\"%1$s\" title=\"%2$s\" rel=\"bookmark\"><time class=\"entry-date\" datetime=\"%3$s\" pubdate>%4$s</time></a>',\n\t\tesc_url( get_permalink() ),\n\t\tesc_attr( get_the_time() ),\n\t\tesc_attr( get_the_date( 'c' ) ),\n\t\tesc_html( get_the_date() )\n\t);\n\n\t$author = sprintf( '<span class=\"author vcard\"><a class=\"url fn n\" href=\"%1$s\" title=\"%2$s\" rel=\"author\">%3$s</a></span>',\n\t\tesc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),\n\t\tesc_attr( sprintf( __( 'View all posts by %s', 'half_baked_base' ), get_the_author() ) ),\n\t\tget_the_author()\n\t);\n\n\t// Translators: 1 is category, 2 is tag, 3 is the date and 4 is the author's name.\n\tif ( '' != $tag_list ) {\n\t\t$utility_text = __( 'This entry was posted in %1$s and tagged %2$s on %3$s by %4$s.', 'half_baked_base' );\n\t} elseif ( '' != $categories_list ) {\n\t\t$utility_text = __( 'This entry was posted in %1$s on %3$s by %4$s.', 'half_baked_base' );\n\t} else {\n\t\t$utility_text = __( 'This entry was posted on %3$s by %4$s.', 'half_baked_base' );\n\t}\n\n\tprintf(\n\t\t$utility_text,\n\t\t$categories_list,\n\t\t$tag_list,\n\t\t$date,\n\t\t$author\n\t);\n}", "title": "" }, { "docid": "66e52cb90b8bffc53ecd68f5c258ddb6", "score": "0.54815733", "text": "function supertheme_entry_meta() {\n\tif ( is_sticky() && is_home() && ! is_paged() )\n\t\techo '<span class=\"featured-post\">' . __( 'Sticky', 'supertheme' ) . '</span>';\n\n\tif ( ! has_post_format( 'link' ) && 'post' == get_post_type() )\n\t\tsupertheme_entry_date();\n\n\t// Translators: used between list items, there is a space after the comma.\n\t$categories_list = get_the_category_list( __( ', ', 'supertheme' ) );\n\tif ( $categories_list ) {\n\t\techo '<span class=\"categories-links\">' . $categories_list . '</span>';\n\t}\n\n\t// Translators: used between list items, there is a space after the comma.\n\t$tag_list = get_the_tag_list( '', __( ', ', 'supertheme' ) );\n\tif ( $tag_list ) {\n\t\techo '<span class=\"tags-links\">' . $tag_list . '</span>';\n\t}\n\n\t// Post author\n\tif ( 'post' == get_post_type() ) {\n\t\tprintf( '<span class=\"author vcard\"><a class=\"url fn n\" href=\"%1$s\" title=\"%2$s\" rel=\"author\">%3$s</a></span>',\n\t\t\tesc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),\n\t\t\tesc_attr( sprintf( __( 'View all posts by %s', 'supertheme' ), get_the_author() ) ),\n\t\t\tget_the_author()\n\t\t);\n\t}\n}", "title": "" }, { "docid": "f8ef2a66b78c976aa295704b9bd4512c", "score": "0.5477098", "text": "function set_sections()\n\t{\n\n\t\t// are we on the Publish page?\n\t\tif (ee()->input->get('C') == 'content_publish' && ee()->input->get('M') == 'entry_form')\n\t\t{\n\t\t\t//get the channel id from the url\n\t\t\t$channel_id = ee()->security->xss_clean(ee()->input->get('channel_id'));\n\n\t\t\t//be defensive\n\t\t\tif($channel_id != '')\n\t\t\t{\n\n\t\t\t\t//what category groups do we want?\n\t\t\t\t$query \t= ee()->db->query(\"SELECT cat_group\n\t\t\t\t\t\t\tFROM {$this->sc->db->channels}\n\t\t\t\t\t\t\tWHERE {$this->sc->db->channel_id} = '{$channel_id}'\n\t\t\t\t\t\t\tLIMIT 0,1\");\n\n\t\t\t\t//we might not have any category groups.\n\t\t\t\tif($query->row('cat_group') != '')\n\t\t\t\t{\n\t\t\t\t\t$catlist = array();\n\n\t\t\t\t\tif(ee()->input->get('entry_id'))\n\t\t\t\t\t{\n\t\t\t\t\t\t//if we have cat_groups we might have categories\n\t\t\t\t\t\t$cat_query = ee()->db->query(\"SELECT cat_id\n\t\t\t\t\t\t\t\t\t\t\tFROM exp_category_posts\n\t\t\t\t\t\t\t\t\t\t\tWHERE entry_id = '\".ee()->security->xss_clean(ee()->input->get('entry_id')).\"'\");\n\n\t\t\t\t\t\tforeach($cat_query->result_array() AS $cat)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$catlist[] = $cat['cat_id'];\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\n\n\t\t\t\t\t$template = $this->json_encode($this->show_category_box($query->row('cat_group'),'','',$catlist));\n\n\t\t\t\t\t//This little bit of magic is to get around quicksaves and validation errors\n\t\t\t\t\t//The category details do get saved, but we can't access them if there's a validation error\n\t\t\t\t\t//In this case on the page reload, we check the default ee2 state of the category inputs,\n\t\t\t\t\t//save the checked ones, then recheck our new input list.\n\t\t\t\t\t//the additional inputs (remember my choices, primary category etc, do get lost, but that's\n\t\t\t\t\t//the same behaviour as in EE1, so at the minute I'm willing to accept that).\n\t\t\t\t\t$this->_insert_js('var n = jQuery(\"#sub_hold_field_category .holder input:checked\").length;\n\t\t\t\t\t\t\t\t\tvar cats = [];\n\t\t\t\t\t\t\t\t\tif(n>0) {\n\t\t\t\t\t\t\t\t\t\tvar cats = [];\n\t\t\t\t\t\t\t\t\t\tjQuery(\"#sub_hold_field_category .holder input:checked\").each(function(){\n\t\t\t\t\t\t\t\t\t\t\tcats.push(jQuery(this).attr(\"value\"));\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tvar error = jQuery(\"#sub_hold_field_category .holder .notice\");\n\n\t\t\t\t\t\t\t\t\tjQuery(\"#sub_hold_field_category .holder\").html('.$template.');\n\n\t\t\t\t\t\t\t\t\tjQuery(\"#sub_hold_field_category input\").each(function(){\n\t\t\t\t\t\t\t\t\t\tif(jQuery.inArray(jQuery(this).attr(\"value\"),cats) > -1) jQuery(this).attr(\"checked\",\"checked\");\n\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\tjQuery(\"#sub_hold_field_category .holder\").append(error);\n\t\t\t\t\t\t\t\t\t');\n\t\t\t\t\t$this->_include_theme_css('primary_category.css');\n\n\t\t\t\t\t$this->cache_vars['theme_path'] = $this->_theme_url();\n\t\t\t\t\t$this->_insert_css($this->view('primary_category.css','',TRUE));\n\t\t\t\t\t$this->_include_theme_js('primary_category.js');\n\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\n\t\t$this->_insert_js('jQuery(\"#accessoryTabs a.primary_category_acc\").parent(\"li\").remove()');\n\n\t}", "title": "" }, { "docid": "42672be75771f3ae9d0abd88a347df49", "score": "0.5469631", "text": "function hrecipe_postbox_fields($id, $title, $content, $section) {\n global $hrecipe_options_file;\n?>\n\n <div id=\"<?php echo $id; ?>\" class=\"postbox\">\n <div class=\"handlediv\" title=\"Click to toggle\"><br /></div>\n <h3 class=\"hndle\"><span><?php echo $title; ?></span></h3>\n <div class=\"inside hrecipe\">\n <?php echo $content; ?>\n <table class=\"form-table\">\n <?php //echo $section ?>\n <?php do_settings_fields($hrecipe_options_file, $section); ?>\n </table>\n </div>\n </div>\n<?php \n}", "title": "" }, { "docid": "8409a7d05f53627ddd18d22a30b9a498", "score": "0.54665", "text": "function board_agenda_front_genesis_meta() {\n\tremove_action( 'genesis_loop', 'genesis_do_loop' );\n\n\t//* Remove the post content (requires HTML5 theme support)\n\tremove_action( 'genesis_entry_content', 'genesis_do_post_content' );\n\n\t//add_action( 'genesis_entry_content', 'sanders_front_content' );\n\tadd_action( 'genesis_loop', 'board_agenda_archive' );\n}", "title": "" }, { "docid": "f51337f2ee8a56cfd902f9793b015342", "score": "0.546495", "text": "function usgs_news_ui_views_data_alter(&$data){\n $data['field_release_date'] = array(\n 'table' => array(\n 'group'=>t('USGS News Custom'),\n 'join'=>array(\n 'node' =>array(\n 'left_field' => 'nid',\n 'field' => 'entity_id',\n ),\n ),\n )\n );\n // Our fields\n $data['field_release_date']['field_release_date_value'] = array(\n 'title' => t('Published Year'),\n 'help' => t('Date the article was published'),\n );\n\n // Adds our field in the \"Filters\" section of Views\n $data['field_release_date']['field_release_date_value']['filter'] = array(\n 'handler' => 'usgs_news_ui_handler_filter_by_year',\n );\n\n\n /************** For News Articles - Filter By State ***************/\n $data['field_usgs_tags'] = array(\n 'table' => array(\n 'group'=>t('USGS News Custom'),\n 'join'=>array(\n 'node' =>array(\n 'left_field' => 'nid',\n 'field' => 'entity_id',\n ),\n ),\n )\n );\n // Our fields\n $data['field_usgs_tags']['field_usgs_tags_value'] = array(\n 'title' => t('State'),\n 'help' => t('State to which the news article is tagged'),\n );\n\n // Adds our field in the \"Filters\" section of Views\n $data['field_usgs_tags']['field_usgs_tags_value']['filter'] = array(\n 'handler' => 'usgs_news_ui_handler_filter_by_state',\n );\n\n}", "title": "" }, { "docid": "a8f7b6f2b025686294b29561e6bf6c83", "score": "0.54497236", "text": "function basalstyle_entry_meta() {\n\n $format = get_post_format();\n if ( current_theme_supports( 'post-formats', $format ) ) {\n printf(\n '<span class=\"entry-format\">%1$s<a href=\"%2$s\">%3$s</a></span>',\n sprintf( '<span class=\"screen-reader-text\">%s </span>', _x( 'Format', 'Used before post format.', 'twentytwenty' ) ),\n esc_url( get_post_format_link( $format ) ),\n get_post_format_string( $format )\n );\n }\n\n if ( 'post' === get_post_type() ) {\n printf(\n '<p class=\"entry-tags\">%1$s</p>',\n basalstyle_entry_tags()\n );\n }\n\n }", "title": "" }, { "docid": "f3090177af77f59a8af171de70c14381", "score": "0.5444316", "text": "function tt_customize_add_section($atts) {\n \n \n\t $wp_customize->add_section( $atts['name'],\n\t array(\n\t 'title' => __( $atts['title'], $theme ),\n\t 'priority' => $atts['priority'],\n\t 'capability' => $atts['capability'],\n\t 'description' => __($atts['desc'], $theme), \n\t ) \n\t );\n \n }", "title": "" }, { "docid": "c99a0d895aeaa6186931d1ed437b3f53", "score": "0.5442841", "text": "public function theme_filters(){\n\n add_filter( 'next_posts_link_attributes', array( 'PRT_PB_Navigation', 'next_posts_link_atts' ) );\n add_filter( 'previous_posts_link_attributes', array( 'PRT_PB_Navigation', 'prev_posts_link_atts' ) );\n add_filter( 'pt-ocdi/import_files', array( $this, 'ocdi_import_files' ) );\n\n }", "title": "" }, { "docid": "7162196a7b7d92efb46b35449f63b3c6", "score": "0.543221", "text": "function iasd_display_section($section){ \r\n\r\n}", "title": "" }, { "docid": "72c73ee72633637897fa4ba0a2c86aab", "score": "0.5421968", "text": "function vtp_home_genesis_meta() {\r\n\r\n\tif ( is_active_sidebar( 'sub-home-welcome' ) || is_active_sidebar( 'sub-home-about' ) || is_active_sidebar( 'sub-home-colleges' ) || is_active_sidebar( 'sub-home-services' ) || is_active_sidebar( 'sub-info-left' ) || is_active_sidebar( 'sub-info-right' ) || is_active_sidebar( 'sub-home-news' ) ) {\r\n\r\n\t\t// Force content-sidebar layout setting\r\n\t\tadd_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' );\r\n\r\n\t\t// Add vtp-home body class\r\n\t\tadd_filter( 'body_class', 'vtp_body_class' );\r\n\r\n\t\t// Remove the navigation menus\r\n\t\t//remove_action( 'genesis_after_header', 'genesis_do_nav' );\r\n\t\t//remove_action( 'genesis_after_header', 'genesis_do_subnav' );\r\n\r\n\t\t// Remove the default Genesis loop\r\n\t\tremove_action( 'genesis_loop', 'genesis_do_loop' );\r\n\r\n\t\t// Add homepage widgets\r\n\t\tadd_action( 'genesis_loop', 'vtp_homepage_widgets' );\r\n\r\n\t}\r\n\r\n}", "title": "" }, { "docid": "ec133fd5c2fb7d69c8bc0ccde71f3c93", "score": "0.5420225", "text": "function add_live_filter_atts($atts) {\n if (!empty($atts['live_filter'])) {\n $atts['live_filter_cur_post_id'] = get_queried_object_id(); //add the current post id\n $atts['live_filter_cur_post_author'] = get_post_field( 'post_author', $atts['live_filter_cur_post_id']); //get the current author\n }\n return $atts;\n }", "title": "" }, { "docid": "90e7c30d5adb008109b3be90b5083fef", "score": "0.54162073", "text": "function section_post_type() {\n\t\t$labels = array(\n\t\t\t'name' \t\t\t\t=> _x('Sections', 'post type general name', 'documentor-lite'),\n\t\t\t'singular_name' \t=> _x('Section', 'post type singular name', 'documentor-lite'),\n\t\t\t'add_new' \t\t\t=> _x('Add New', 'Add New Documentor Section', 'documentor-lite'),\n\t\t\t'add_new_item' \t\t=> __('Add New Documentor Section', 'documentor-lite'),\n\t\t\t'edit_item' \t\t=> __('Edit Documentor Section', 'documentor-lite'),\n\t\t\t'new_item' \t\t\t=> __('New Documentor Section', 'documentor-lite'),\n\t\t\t'all_items' \t\t=> __('All Documentor Sections', 'documentor-lite'),\n\t\t\t'view_item' \t\t=> __('View Documentor Section', 'documentor-lite'),\n\t\t\t'search_items' \t\t=> __('Search Documentor Sections', 'documentor-lite'),\n\t\t\t'not_found' \t\t=> __('No Documentor sections found', 'documentor-lite'),\n\t\t\t'not_found_in_trash'=> __('No Documentor section found in Trash', 'documentor-lite'), \n\t\t\t'parent_item_colon' => '',\n\t\t\t'menu_name' \t\t=> 'Sections'\n\t\t);\n\t\t$args = array(\n\t\t\t'labels' \t\t\t=> $labels,\n\t\t\t'public' \t\t\t=> true,\n\t\t\t'exclude_from_search'=> true,\n\t\t\t'publicly_queryable'=> false,\n\t\t\t'show_ui' \t\t\t=> true, \n\t\t\t'show_in_menu' \t\t=> false, \n\t\t\t'show_in_nav_menus' => false,\n\t\t\t'query_var' \t\t=> false,\n\t\t\t'rewrite' \t\t\t=> array('slug' => 'section','with_front' => false),\n\t\t\t'capability_type' \t=> 'post',\n\t\t\t'has_archive' \t\t=> false, \n\t\t\t'hierarchical' \t\t=> false,\n\t\t\t'menu_position' \t=> null,\n\t\t\t'can_export' \t\t=> true,\n\t\t\t'supports' \t\t\t=> array('editor','thumbnail','excerpt','custom-fields', 'comments')\n\t\t); \n\t\tregister_post_type('documentor-sections',$args);\n\t}", "title": "" }, { "docid": "9bc53f63965226b4224437e5686bd4a3", "score": "0.54128605", "text": "function msdlab_switch_content() {\n remove_action('genesis_entry_header','msd_post_image', 20);\n remove_action('genesis_entry_content', 'genesis_grid_loop_content');\n add_action('genesis_entry_content', 'msdlab_grid_loop_content');\n add_action('genesis_after_entry', 'msdlab_grid_divider');\n add_action('genesis_entry_header', 'msdlab_grid_loop_image', 5);\n remove_action( 'genesis_entry_header', 'msdlab_do_post_subtitle', 6 );\n \n if(in_array( 'genesis-feature', get_post_class() )){\n add_action( 'genesis_entry_header','msdlab_grid_header',4);\n } else {\n remove_action( 'genesis_entry_header','msdlab_grid_header',4);\n remove_action( 'genesis_entry_header', 'genesis_post_info', 12 );\n }\n}", "title": "" }, { "docid": "2c4fd26653f22f3a7ba0b76b8a80d648", "score": "0.5408137", "text": "function my_extra_hoh_column_content( $column_name, $post_id ) {\n if ( 'hoh' != $column_name ) {\n return;\n }\n //Get number of slices from post meta\n $hoh = get_field('hide_on_homepage');\n if($hoh):\n echo 'TRUE';\n else:\n echo 'FALSE';\n endif;\n}", "title": "" }, { "docid": "9232a03e7176edf1563c36d099b01462", "score": "0.5403347", "text": "public function init() {\n\t\tadd_action( 'hestia_blog_post_template_part', array( $this, 'render' ), 2 );\n\t}", "title": "" }, { "docid": "5a40348d3a1dbb9f6d5e94d30746d9d1", "score": "0.5398507", "text": "public function filter_revision_fields( $fields, $story ) {\n\t\tif ( self::POST_TYPE_SLUG === $story['post_type'] ) {\n\t\t\t$fields['post_content_filtered'] = __( 'Story data', 'web-stories' );\n\t\t}\n\t\treturn $fields;\n\t}", "title": "" }, { "docid": "405d5d88306e5cab12ada7cd65852188", "score": "0.5388317", "text": "function set_lytics_meta()\n{\n $output = '';\n\n //Getting tyhe post and the aspects for the post\n $postID = get_queried_object_id();\n $post_type = (get_post_type($postID))?get_post_type($postID):\"\";\n $output .= '<meta name=\"lytics:post_type\" content=\"'.$post_type.'\"> ';\n $output .= '<meta name=\"lytics:author\" content=\"'.get_the_author().'\"> ';\n $lyticsCategories = mm_get_lytics_categories($postID);\n $lyticsTopics = mm_get_lytics_topics($postID);\n\n //If there are aspects, collect all the ones for the post and create the\n //meta tag\n if($lyticsCategories)\n {\n foreach ($lyticsCategories as $lyticsCategory)\n {\n $lyticsCategory->lyticsID = mm_get_lytics_ID($lyticsCategory);\n }\n\n $categoryIDs = array_map(function ($cat){return $cat->lyticsID;}, $lyticsCategories);\n //$catNames = array_map(function ($cat){return $cat->name;}, $lyticsCategories);\n //$catTagVals = array_map(function ($cat) {return $cat->tagVal;}, $lyticsCategories);\n $output .= '<meta name=\"lytics:category\" content=\"'. implode(',', $categoryIDs) .'\">';\n //$output .= '<meta name=\"paTagNames\" id=\"paTagNames​\" content=\"'. implode(',', $catNames) .'\">';\n //$output .= '<meta name=\"paTagValues\" id=\"paTagValues\" content=\"'. implode(',', $catTagVals) .'\">';\n }\n\n //If there are Topics, collect all the ones for the post and create the\n //meta tag\n if($lyticsTopics)\n {\n foreach ($lyticsTopics as $lyticsTopic)\n {\n $lyticsTopic->lyticsID = mm_get_lytics_ID($lyticsTopic);\n }\n\n $topicIDs = array_map(function ($cat){return $cat->lyticsID;}, $lyticsTopics);\n //$catNames = array_map(function ($cat){return $cat->name;}, $lyticsCategories);\n //$catTagVals = array_map(function ($cat) {return $cat->tagVal;}, $lyticsCategories);\n $output .= '<meta name=\"lytics:topics\" content=\"'. implode(',', $topicIDs) .'\">';\n //$output .= '<meta name=\"paTagNames\" id=\"paTagNames​\" content=\"'. implode(',', $catNames) .'\">';\n //$output .= '<meta name=\"paTagValues\" id=\"paTagValues\" content=\"'. implode(',', $catTagVals) .'\">';\n }\n\n echo $output;\n}", "title": "" }, { "docid": "4d0da07704c528a43f099ed22c3a1227", "score": "0.53882295", "text": "public function hook_admin_embed_publishfields(){return;}", "title": "" }, { "docid": "cc3412585e4b82191b4af31163177a0e", "score": "0.5383898", "text": "function classroom_theme_entry_meta() {\n// Show the date posted\n\tif( date('Yz') == get_the_time('Yz') ) {\t\t\n\t\t$date = 'Posted today';\n\t}else{\t\n\t\t$date = 'Posted ' . human_time_diff( get_the_time('U'), current_time('timestamp') ) . ' ago'; \n\t}\t\n\n\n\n// Show the date of the post\n\tif ( 'post' == get_post_type() ) :\n\t\techo '<header class=\"entry-header\" >';\n\n\techo '<a class=\"post-date\" href=\"'. get_permalink() . '\"><time datetime=\"'.get_the_time('F jS, Y').'\">';\n\techo $date;\n\techo '</time></a>';\n\n\n\n\t/* translators: used between list items, there is a space after the comma */\n\t$categories_list = get_the_category_list( __( ', ', 'classroom' ) );\n\tif ( $categories_list && classroom_theme_categorized_blog() ) {\n\t\tprintf( '<span class=\"cat-links\">' . __( '%1$s', 'classroom' ) . '</span>', $categories_list );\n\t} \n\n\tclassroom_show_duedate();\n\n\n\techo '</header>';\n\tendif;\t\n}", "title": "" }, { "docid": "baefc5f0554610b1201c97c9470b3698", "score": "0.53832096", "text": "function build_option_meta_head_array($template = null)\n{\n\n if ($template == null)\n return;\n\n $id = $template . \"_itemhead_meta\";\n $array = build_option_meta_array(array(\n 'id' => $id,\n 'name' => __(\"Meta Above Content\"),\n 'desc' => __(\"Each listed Post entry will have meta Information that can be displayed above it's title. Enable/Disable their display here\")\n )\n );\n\n return $array;\n}", "title": "" }, { "docid": "3d6a83603f46e8946a91a9afb259e568", "score": "0.5378683", "text": "function openstate_thematic_content($post) {\r\n \tif (is_home() || is_front_page()) {\r\n \t $post = 'excerpt';\r\n \t}\r\n \treturn apply_filters('openstate_thematic_content', $post);\r\n }", "title": "" }, { "docid": "ad7ce84c2e9588531580abf26e209937", "score": "0.5377574", "text": "public function init_shortcodes_section_fields() {\n\t\t\t$this->shortcodes_option_fields = array(\n\t\t\t\t'user_id' => array(\n\t\t\t\t\t'id' => $this->shortcodes_section_key . '_user_id',\n\t\t\t\t\t'name' => 'user_id',\n\t\t\t\t\t'type' => 'number',\n\t\t\t\t\t'label' => esc_html__( 'User ID', 'learndash' ),\n\t\t\t\t\t'help_text' => esc_html__( 'Enter specific User ID. Leave blank for current User.', 'learndash' ),\n\t\t\t\t\t'value' => '',\n\t\t\t\t\t'class' => 'small-text',\n\t\t\t\t),\n\t\t\t);\n\n\t\t\t/** This filter is documented in includes/settings/settings-metaboxes/class-ld-settings-metabox-course-access-settings.php */\n\t\t\t$this->shortcodes_option_fields = apply_filters( 'learndash_settings_fields', $this->shortcodes_option_fields, $this->shortcodes_section_key );\n\n\t\t\tparent::init_shortcodes_section_fields();\n\t\t}", "title": "" }, { "docid": "761a31d311555c38af5b60fdc6ac2356", "score": "0.5374385", "text": "public static function hookData() {\n return array_merge_recursive( array (\n 'profileHeader' => \n array (\n 1 => \n array (\n 'selector' => '#elProfileHeader',\n 'type' => 'add_inside_start',\n 'content' => '{{if !$coverPhoto->file}}\r\n\t<div class=\\'ipsCoverPhoto_container\\'>\r\n\t\t<img src=\\'{setting=\"default_cover_photo_image\"}\\' class=\\'ipsCoverPhoto_photo\\' alt=\\'\\'>\r\n\t</div>\r\n{{endif}}',\n ),\n ),\n), parent::hookData() );\n}", "title": "" }, { "docid": "fd3735750d7baaab834dd1bf1c614212", "score": "0.5372646", "text": "function fah_settings_section_callback() {\n\t?> <!--<hr>--> \n\t<?php\n\n}", "title": "" }, { "docid": "3c1d72ebe8377ce4ea8d6f926be16d62", "score": "0.5367204", "text": "function seotfs_custom_meta() {\n\t\t$seotypes = array('post', 'page', 'adventures', 'fishcamp_cpt', 'guide_service', 'schools_cpt', 'travel_cpt', 'espresso_venues', 'espresso_events', 'espresso_people', 'travel-blog', 'flyfishing-news', 'lower48', 'lower48blog' );\n add_meta_box( 'seotfs_meta', __( 'TFS SEO', 'seotfs-textdomain' ), 'seotfs_meta_callback', $seotypes, 'normal', 'high');\n}", "title": "" }, { "docid": "99a1bfc40aae6bd754719567fca233d8", "score": "0.536709", "text": "function st_blog_set_global() {\n /*Getting saved values start*/\n $GLOBALS['st_blog_customizer_all_values'] = st_blog_get_all_options(1);\n}", "title": "" }, { "docid": "bcc5980d51c03fabdf64383eb6503b5a", "score": "0.5359781", "text": "function create_filters () {\n\t\n\t\tif ( ! is_admin() ) {\n\t\t\n\t\t\t$stored_meta = get_option( $this->plugin_prefix . 'stored_meta' );\n\t\t\t\n\t\t\t// Create the filter functions.\n\t\t\tif ( is_array( $stored_meta ) ) {\n\t\t\t\tforeach ( $stored_meta as $k => $v ) {\n\t\t\t\t\t$new_string = $v;\n\t\t\t\t\t\n\t\t\t\t\t$new_string = str_replace( '\\\"', '', $new_string );\n\t\t\t\t\t\n\t\t\t\t\t$content = '';\n\t\t\t\t\t\n\t\t\t\t\tadd_filter( $k, create_function( \"$content\", \"return '$new_string';\" ), 12 );\n\t\t\t\t}\n\t\t\t}\n\t\t\n\t\t} // End IF Statement\n\t\n\t}", "title": "" }, { "docid": "bbce62eff705f1a1bb66a3150e199b59", "score": "0.5355561", "text": "public function conditional_hooks() {\n\t\t$screen = get_current_screen();\n\t\tif ( isset( $screen->post_type ) && $screen->post_type == $this->post_type ) {\n\t\t\tadd_filter( 'enter_title_here', array( $this, 'title' ) );\n\t\t\tadd_filter( 'gettext', array( $this, 'modify_text' ) );\n\t\t\t$this->excerpt_css();\n\t\t}\n\t}", "title": "" }, { "docid": "fd8c9aac971e74c2229bbf29b043a6fe", "score": "0.5355275", "text": "public function hooks()\n {\n add_filter('ep_prepare_meta_excluded_public_keys', [$this, 'excludeMetaMappingFields'], 10, 2);\n add_filter('ep_post_sync_args_post_prepare_meta', [$this, 'removePostArgs'], 10, 2);\n add_filter('ep_query_post_type', [$this, 'postTypeFilter'], 10, 2);\n }", "title": "" }, { "docid": "e9ad20d3d4d6b0ebdcc1a21b3cdf4a0f", "score": "0.5354876", "text": "function wp_list_pages_filter($output) {\n //return $output.'<li class=\"page_item page-get-started\"><a href=\"https://i2.merchenta.com/signup\">Get Started</a></li>';\n}", "title": "" }, { "docid": "31b483729981cd9c0041931ecf207be4", "score": "0.53544706", "text": "protected function _add_filters() {\n\t\tif ( ! is_admin() ) {\n\t\t\tadd_filter( 'the_content', array( $this, 'filter_the_content' ) );\n\t\t}\n\t}", "title": "" }, { "docid": "624a98f26d344e1f4ca819e88f97ad6b", "score": "0.53543", "text": "function filter_list_template_options( $args, $field, $post_id ) {\n\t$args['meta_query'] = array(\n\t\t'relation' => 'AND',\n\t\tarray(\n\t\t\t'key' => 'section_layout',\n\t\t\t'value' => 'list',\n\t\t\t'compare' => '='\n\t\t),\n\t\tarray(\n\t\t\t'key' => 'list_content_type',\n\t\t\t'value' => 'headings',\n\t\t\t'compare' => '='\n\t\t)\n\t);\n\n\treturn $args;\n}", "title": "" }, { "docid": "970161c6f5cb07311fa343aca8ff8ec7", "score": "0.5343963", "text": "function tutsplus_customize_register_sections( $wp_customize ){\n\t\n\t//add the section for header\n\t$wp_customize->add_section( 'tutsplus_header', array(\n\t\t'title' => __( 'Site Header', 'tutsplus' )\n\t));\n\t\n\t//add the section for layout\n\t$wp_customize->add_section( 'tutsplus_layout', array(\n\t\t'title' => __( 'Site Layout', 'tutsplus' )\n\t));\n\t\n\t//add the section for color scheme\n\t$wp_customize->add_section( 'tutsplus_colorscheme', array(\n\t\t'title' => __( 'Color Scheme', 'tutsplus' )\n\t));\n\n\t\n}", "title": "" }, { "docid": "8baa4597b6a57b75df7dcdc77d6949d0", "score": "0.5338587", "text": "function section_persistent(){\n\t\t\n\t\t$per_row = (ploption('footer_num_columns')) ? ploption('footer_num_columns') : 5;\n\t\t\n\t\t$this->markup_start = sprintf( '<div class=\"pp%s footcol\"><div class=\"footcol-pad\">', $per_row );\n\t\t$this->markup_end \t= '</div></div>';\n\t\t\n\t\n\t\tpagelines_register_sidebar(array(\n\t\t\t'name'=>$this->name,\n\t\t\t'description'\t=> __('Use this sidebar if you want to use widgets in your footer columns instead of the default.', 'pagelines'),\n\t\t 'before_widget' => $this->markup_start,\n\t\t 'after_widget' \t=> $this->markup_end,\n\t\t 'before_title' \t=> '<h3 class=\"widget-title\">',\n\t\t 'after_title' \t=> '</h3>'\n\t\t) );\n\t\t\n\t\tregister_nav_menus( array(\n\t\t\t'footer_nav' => __( 'Page Navigation in Footer Columns', 'pagelines' )\n\t\t) );\n\t\n\t\t\n\t}", "title": "" }, { "docid": "6b2c787b5a0862dbfd528624bd3d3f17", "score": "0.53379774", "text": "function humphrey_home_genesis_meta() {\n\n\tif ( is_active_sidebar( 'home-slider' ) || is_active_sidebar( 'home-welcome' ) || is_active_sidebar( 'home-left' ) || is_active_sidebar( 'home-right' ) ) {\n\n\t\tremove_action( 'genesis_loop', 'genesis_do_loop' );\n\t\tadd_action( 'genesis_loop', 'humphrey_home_loop_helper' );\n\t\tadd_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' );\n\n\t\t// Add humphrey-home body class\n\t\tadd_filter( 'body_class', 'humphrey_body_class' );\n\t\tfunction humphrey_body_class( $classes ) {\n \t\t\t$classes[] = 'humphrey-home';\n \t\t\treturn $classes;\n\t\t}\n\n\t}\n}", "title": "" }, { "docid": "436c5af1fdbcf8c1b6434d38ed5bfc6a", "score": "0.5335508", "text": "function bold_photography_sections( $selector = 'header' ) {\n get_template_part( 'template-parts/header/header-media' );\n get_template_part( 'template-parts/hero-content/content-hero' );\n get_template_part( 'template-parts/slider/display-slider' );\n get_template_part( 'template-parts/featured-content/display-featured' );\n get_template_part( 'template-parts/portfolio/display-portfolio' );\n get_template_part( 'template-parts/services/display-services' );\n get_template_part( 'template-parts/testimonial/display-testimonial' );\n}", "title": "" }, { "docid": "c4448339428eaec9650fdd3c2da6e314", "score": "0.5333859", "text": "function my_add_custom_features_text_callback($meta_fields) {\n\t$custom_field = array(\n\t\t'id'\t\t=>\t'epl_property_listing_custom_data_id',\n\t\t'label'\t\t=>\t__('Custom Features', 'epl'), // Box header\n\t\t'post_type'\t=>\tarray('property', 'rural', 'rental', 'land', 'commercial', 'commercial_land', 'business'), // Which listing types these will be attached to\n\t\t'context'\t=>\t'normal',\n\t\t'priority'\t=>\t'default',\n\t\t'groups'\t=>\tarray(\n\t\t\tarray(\n\t\t\t\t'id'\t\t=>\t'property_custom_feature_section',\n\t\t\t\t'columns'\t=>\t'2', // One or two columns\n\t\t\t\t'label'\t\t=>\t'Custom features',\n\t\t\t\t'fields'\t=>\tarray(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'name'\t\t=>\t'property_custom_feature_1',\n\t\t\t\t\t\t'label'\t\t=>\t__('Custom feature 1', 'epl'),\n\t\t\t\t\t\t'type'\t\t=>\t'text',\n\n\n\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'name'\t\t=>\t'property_custom_feature_2',\n\t\t\t\t\t\t'label'\t\t=>\t__('Custom feature 2', 'epl'),\n\t\t\t\t\t\t'type'\t\t=>\t'text',\n\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'id'\t\t=>\t'property_custom_feature_section_2',\n\t\t\t\t'columns'\t=>\t'2', // One or two columns\n\t\t\t\t'label'\t\t=>\t'Custom features 2',\n\t\t\t\t'fields'\t=>\tarray(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'name'\t\t=>\t'property_custom_feature_3',\n\t\t\t\t\t\t'label'\t\t=>\t__('Custom feature 3', 'epl'),\n\t\t\t\t\t\t'type'\t\t=>\t'text',\n\n\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'name'\t\t=>\t'property_custom_feature_4',\n\t\t\t\t\t\t'label'\t\t=>\t__('Custom feature 4', 'epl'),\n\t\t\t\t\t\t'type'\t\t=>\t'text',\n\n\t\t\t\t\t)\n\t\t\t\t)\n\t\t\t)\n\t\t)\n\t);\n\t$meta_fields[] = $custom_field;\n\treturn $meta_fields;\n}", "title": "" }, { "docid": "2a5709fc0dba7c2513090c2a493566ba", "score": "0.53313845", "text": "function tfuse_header_content($location = false)\n { \n global $TFUSE, $post,$is_tf_blog_page,$header_map;\n $posts = $header_element = $slider = $header_map = null;\n \n $types = $TFUSE->request->isset_GET('types') ? $TFUSE->request->GET('types') : '';\n \n \n if (!$location) return;\n switch ($location)\n { \n case 'header' :\n if(is_front_page())\n {\n if(!empty($post))$ID = $post->ID; else $ID = '';\n\t\t\t\t\t\n $page_id = tfuse_options('home_page');\n $header_element = tfuse_options('header_element');\n if(tfuse_options('use_page_options') && tfuse_options('homepage_category')=='page')\n { $header_element = tfuse_page_options('header_element','',$page_id);\n if($page_id != 0 && tfuse_page_options('header_element','',$page_id)=='slider')\n $slider = tfuse_page_options('select_slider','',$page_id);\n }\n else{\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider');\n }\n \n }\n elseif($is_tf_blog_page)\n { \n $ID = $post->ID;\n $header_element = tfuse_options('header_element_blog');\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider_blog');\n }\n elseif ( is_singular() )\n { \n $ID = $post->ID;\n $header_element = tfuse_page_options('header_element');\n if ( 'slider' == $header_element )\n $slider = tfuse_page_options('select_slider');\n elseif ( 'map' == $header_element )\n $header_map['map'] = tfuse_page_options('page_map');\n\n }\n elseif ( is_category() )\n { \n $ID = get_query_var('cat');\n $header_element = tfuse_options('header_element', null, $ID);\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider', null, $ID);\n elseif ( 'map' == $header_element )\n $header_map['map'] = tfuse_options('page_map', null, $ID);\n }\n elseif(is_search())\n {\n if(!empty($post))$ID = $post->ID; else $ID = '';\n\t\t\t\t\t\n $header_element = tfuse_options('header_element_search');\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider_search');\n \n }\n elseif ( is_tax() && $types != 'all_rooms')\n { \n $term = get_term_by('slug', get_query_var('term'), get_query_var('taxonomy'));\n $ID = $term->term_id;\n $header_element = tfuse_options('header_element', null, $ID);\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider', null, $ID);\n elseif ( 'map' == $header_element )\n $header_map['map'] = tfuse_options('page_map', null, $ID);\n } \n elseif(is_404())\n {\n if(!empty($post))$ID = $post->ID; else $ID = '';\n\t\t\t\t\t\n $header_element = tfuse_options('header_element_404');\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider_404');\n \n }\n \n break;\n case 'bottom' :\n if(is_front_page())\n {\n if(!empty($post))$ID = $post->ID; else $ID = '';\n\t\t\t\t\t\n $page_id = tfuse_options('home_page');\n $header_element = tfuse_options('header_bottom');\n if(tfuse_options('use_page_options') && tfuse_options('homepage_category')=='page')\n { $header_element = tfuse_page_options('header_bottom','',$page_id);\n if($page_id != 0 && tfuse_page_options('header_bottom','',$page_id)=='slider')\n $slider = tfuse_page_options('select_slider_bottom','',$page_id);\n }\n else{\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider_bottom');\n }\n \n }\n elseif($is_tf_blog_page)\n { \n $ID = $post->ID;\n $header_element = tfuse_options('header_bottom_blog');\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider_bottom_blog');\n }\n elseif ( is_singular() )\n { \n $ID = $post->ID;\n $header_element = tfuse_page_options('header_bottom');\n if ( 'slider' == $header_element )\n $slider = tfuse_page_options('select_slider_bottom');\n\n }\n elseif ( is_category() )\n { \n $ID = get_query_var('cat');\n $header_element = tfuse_options('header_bottom', null, $ID);\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider_bottom', null, $ID);\n }\n elseif(is_search())\n {\n if(!empty($post))$ID = $post->ID; else $ID = '';\n\t\t\t\t\t\n $header_element = tfuse_options('header_bottom_search');\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider_bottom_search');\n }\n elseif ( is_tax() && $types != 'all_rooms')\n { \n $term = get_term_by('slug', get_query_var('term'), get_query_var('taxonomy'));\n $ID = $term->term_id;\n $header_element = tfuse_options('header_bottom', null, $ID);\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider_bottom', null, $ID);\n } \n elseif(is_404())\n {\n if(!empty($post))$ID = $post->ID; else $ID = '';\n\t\t\t\t\t\n $header_element = tfuse_options('header_bottom_404');\n if ( 'slider' == $header_element )\n $slider = tfuse_options('select_slider_bottom_404');\n }\n break;\n } \n if ( $header_element == 'map' )\n { \n get_template_part( 'header', 'map' );\n return;\n }\n elseif ( !$slider )\n return;\n\n $slider = $TFUSE->ext->slider->model->get_slider($slider);\n\n switch ($slider['type']):\n case 'custom':\n if ( is_array($slider['slides']) ) :\n $slider_image_resize = ( isset($slider['general']['slider_image_resize']) && $slider['general']['slider_image_resize'] == 'true' ) ? true : false;\n foreach ($slider['slides'] as $k => $slide) : \n $image = new TF_GET_IMAGE();\n if ( $slider['design'] == 'tabs')\n { \n $slider['slides'][$k]['slide_src'] = $image->width(1280)->height(630)->src($slide['slide_src'])->resize($slider_image_resize)->get_src();\n }\n elseif ( $slider['design'] == 'code')\n { \n $slider['slides'][$k]['slide_src'] = $image->width(1920)->height(675)->src($slide['slide_src'])->resize($slider_image_resize)->get_src();\n }\n elseif ( $slider['design'] == 'codecanyonfull')\n { \n $slider['slides'][$k]['slide_src'] = $image->width(1920)->height(675)->src($slide['slide_src'])->resize($slider_image_resize)->get_src();\n }\n else\n { \n @$slider['slides'][$k]['slide_src'] = $image->width(1280)->height(630)->src($slide['slide_src'])->resize($slider_image_resize)->get_src();\n }\n endforeach;\n endif;\n\n break;\n case 'posts':\n $slides_posts = array();\n \n $args = array( 'post__in' => explode(',',$slider['general']['posts_select']) );\n $slides_posts = explode(',',$slider['general']['posts_select']);\n \n foreach($slides_posts as $slide_posts):\n $posts[] = get_post($slide_posts);\n endforeach; \n $posts = array_reverse($posts);\n $args = apply_filters('tfuse_slider_posts_args', $args, $slider);\n $args = apply_filters('tfuse_slider_posts_args_'.$ID, $args, $slider);\n break;\n case 'categories':\n $args = 'cat='.$slider['general']['categories_select'].\n '&posts_per_page='.$slider['general']['sliders_posts_number'];\n $args = apply_filters('tfuse_slider_categories_args', $args, $slider);\n $args = apply_filters('tfuse_slider_categories_args_'.$ID, $args, $slider);\n $slides_posts = explode(',',$slider['general']['categories_select']);\n $args = array(\n 'posts_per_page' => $slider['general']['sliders_posts_number'],\n 'relation' => 'AND',\n 'tax_query' => array(\n array(\n 'taxonomy' => 'category',\n 'field' => 'id',\n 'terms' => $slides_posts\n )\n )\n );\n $query = new WP_Query($args);\n $posts = $query->get_posts();\n break;\n\n endswitch;\n\n if ( is_array($posts) ) :\n $slider['slides'] = tfuse_get_slides_from_posts($posts,$slider);\n endif;\n\n if ( !is_array($slider['slides']) ) return;\n\n include_once(locate_template( '/theme_config/extensions/slider/designs/'.$slider['design'].'/template.php' ));\n }", "title": "" }, { "docid": "ac18e850831d4787b2be682be2202fe8", "score": "0.5329382", "text": "function hybrid_post_meta_boxes() {\n\n\t/* Array of the meta box options. */\n\t$meta_boxes = array(\n\t\t'title' => array( 'name' => 'Title', 'title' => __('Title', 'hybrid'), 'type' => 'text' ),\n\t\t'description' => array( 'name' => 'Description', 'title' => __('Description', 'hybrid'), 'type' => 'textarea' ),\n\t\t'image' => array( 'name' => 'Image', 'title' => __('Image:', 'hybrid'), 'type' => 'text' ),\n\t\t'featured' => array( 'name' => 'Featured', 'title' => __('Featured img:', 'hybrid'), 'type' => 'text' ),\n\t\t\n\n\t);\n\n\treturn apply_filters( 'hybrid_post_meta_boxes', $meta_boxes );\n}", "title": "" }, { "docid": "94ef121b3c9b007eee77142185793f12", "score": "0.5325252", "text": "function city_the_content_filter($content) {\n global $post;\t\t\n if( is_single() && 'city' == $post->post_type ){\n \t\t\n \t\t$url_base = get_post_meta( $post->ID, 'link_base', true );\n \t\t$city = get_post_meta( $post->ID, 'city_name', true );\n \t\t$state = get_post_meta( $post->ID, 'state_name', true );\n\n \t\t$url = sprintf('%s/search/mca',$url_base);\n \t\t$rss = sprintf('%s?format=rss', $url);\n\n \t\t$content = sprintf('<div class=\"cleafix\"><h3>%s, %s</h3><p><a href=\"%s\" target=\"_BLANK\">See All Autos For Sale</a></p><hr/></div>',ucwords($city), ucwords($state), $url);\n\n \t\t$content .= '<div class=\"widget kopa-masonry-list-1-widget\">\n\t<div class=\"masonry-list-wrapper\">';\n\n \t\t$args = array('show_summary' => 1, 'show_date' => 1);\n\n \t\t// later, you in your theme\n\t\tob_start();\n \t\tcity_content_rss_output($rss, $args);\n \t\t$content .= ob_get_clean();\n\n \t\t$content .= '</div>\n \t\t</div>';\n }\n\n // otherwise returns the database content\n return $content;\n}", "title": "" }, { "docid": "efa46bf9b3f0b42a7fd65b5a64bb69d9", "score": "0.5315669", "text": "function customise_storefront_blog() {\n\tremove_action( 'storefront_loop_post', 'storefront_post_content', 30 );\n\n\t// Add our own custom function\n\tadd_action( 'storefront_loop_post', 'custom_storefront_post_content',\t\t30 );\n}", "title": "" }, { "docid": "e4426bab945e0166e6e6628cb5a4a207", "score": "0.53145236", "text": "function hgr_posts_init() {\n\t\t\tif(function_exists('vc_map')) {\n\t\t\t\tvc_map(\n\t\t\t\t\tarray(\n\t\t\t\t\t \"name\"\t\t\t\t=>\t__(\"HGR Blog Posts\",'hgrextender'),\n\t\t\t\t\t \"holder\"\t\t\t=>\t\"div\",\n\t\t\t\t\t \"base\"\t\t\t\t=>\t\"hgr_blog_posts\",\n\t\t\t\t\t \"class\"\t\t\t\t=>\t\"\",\n\t\t\t\t\t \"icon\"\t\t\t\t=>\t\"hgr_blog_posts\",\n\t\t\t\t\t \"category\"\t\t\t=>\t__(\"HighGrade Extender\",'hgrextender'),\n\t\t\t\t\t \"description\"\t\t=>\t__(\"Grid style blog posts.\",\"hgrextender\"),\n\t\t\t\t\t \"content_element\"\t=>\ttrue,\n\t\t\t\t\t \"params\"\t\t\t=>\tarray(\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"textfield\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"How many posts to fetch?\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"posts_number\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"description\"\t=>\t__(\"Enter the desired number of posts to fetch from blog. Recomended: 6\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"save_always\" \t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"textfield\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"How many posts to display on a row?\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"posts_columns\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"description\"\t=>\t__(\"Enter the desired number of posts to display on each row.\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"save_always\" \t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"dropdown\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"Display order\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"display_order\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\tarray(\n\t\t\t\t\t\t\t\t\t\t__( 'Image > Title > Text', 'hgrextender' ) => 'img_title_txt',\n\t\t\t\t\t\t\t\t\t\t__( 'Title > Text', 'hgrextender' ) => 'title_txt',\n\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\t\"save_always\"\t=>\ttrue,\n\t\t\t\t\t\t\t\t\t\"description\"\t=>\t__(\"How to display posts\", \"hgrextender\")\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"dropdown\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"Order posts by\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"display_by\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\tarray(\n\t\t\t\t\t\t\t\t\t\t__( 'Default', 'hgrextender' ) => 'none',\n\t\t\t\t\t\t\t\t\t\t__( 'ID', 'hgrextender' ) => 'ID',\n\t\t\t\t\t\t\t\t\t\t__( 'Title', 'hgrextender' ) => 'title',\n\t\t\t\t\t\t\t\t\t\t__( 'Name (post slug)', 'hgrextender' ) => 'name',\n\t\t\t\t\t\t\t\t\t\t__( 'Date', 'hgrextender' ) => 'date',\n\t\t\t\t\t\t\t\t\t\t__( 'Modified date', 'hgrextender' ) => 'modified',\n\t\t\t\t\t\t\t\t\t\t__( 'Number of comments', 'hgrextender' ) => 'comment_count',\n\t\t\t\t\t\t\t\t\t\t__( 'Random', 'hgrextender' ) => 'rand',\n\n\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\t\"save_always\"\t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"dropdown\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"Order\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"order\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\tarray(\n\t\t\t\t\t\t\t\t\t\t__( 'Ascending', 'hgrextender' ) => 'ASC',\n\t\t\t\t\t\t\t\t\t\t__( 'Descending', 'hgrextender' ) => 'DESC',\n\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\t\"save_always\"\t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"dropdown\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"Blog post title size\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"blog_post_title_size\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\tarray(\n\t\t\t\t\t\t\t\t\t\t__( 'H1', 'hgrextender' ) => 'h1',\n\t\t\t\t\t\t\t\t\t\t__( 'H2', 'hgrextender' ) => 'h2',\n\t\t\t\t\t\t\t\t\t\t__( 'H3', 'hgrextender' ) => 'h3',\n\t\t\t\t\t\t\t\t\t\t__( 'H4', 'hgrextender' ) => 'h4',\n\t\t\t\t\t\t\t\t\t\t__( 'H5', 'hgrextender' ) => 'h5',\n\t\t\t\t\t\t\t\t\t\t__( 'H6', 'hgrextender' ) => 'h6',\n\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\t\"save_always\"\t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"dropdown\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"Blog post footer type\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"blogpost_footer\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\tarray(\n\t\t\t\t\t\t\t\t\t\t__( 'Icon based', 'hgrextender' ) => 'iconbased',\n\t\t\t\t\t\t\t\t\t\t__( 'Compact', 'hgrextender' ) => 'compact',\n\t\t\t\t\t\t\t\t\t\t__( 'Simple', 'hgrextender' ) => 'simple',\n\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\t\"save_always\"\t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"colorpicker\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"hgr_left_floated\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"Footer background color:\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"footer_bg_color\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"dependency\"\t=>\tarray(\n\t\t\t\t\t\t\t\t\t\t\"element\"\t\t=>\t\"blogpost_footer\",\n\t\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\tarray(\"compact\")\n\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\t\"save_always\" \t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"colorpicker\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"Footer border & separators color:\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"footer_sep_border_color\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"dependency\"\t=>\tarray(\n\t\t\t\t\t\t\t\t\t\t\"element\"\t\t=>\t\"blogpost_footer\",\n\t\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\tarray(\"compact\")\n\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\t\"save_always\" \t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"colorpicker\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"Links color:\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"links_color\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"save_always\" \t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"colorpicker\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"Background color:\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"hgr_bg_color\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"save_always\" \t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\"type\"\t\t\t=>\t\"textfield\",\n\t\t\t\t\t\t\t\t\t\"class\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"heading\"\t\t=>\t__(\"Extra class\", \"hgrextender\"),\n\t\t\t\t\t\t\t\t\t\"param_name\"\t=>\t\"extra_class\",\n\t\t\t\t\t\t\t\t\t\"value\"\t\t\t=>\t\"\",\n\t\t\t\t\t\t\t\t\t\"description\"\t=>\t__(\"Extra CSS class for custom CSS\", \"hgrextender\")\t,\n\t\t\t\t\t\t\t\t\t\"save_always\" \t=>\ttrue,\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t'type' => 'css_editor',\n\t\t\t\t\t\t\t\t\t'heading' => __( 'Css', 'hgrextender' ),\n\t\t\t\t\t\t\t\t\t'param_name' => 'css',\n\t\t\t\t\t\t\t\t\t'group' => __( 'Design options', 'hgrextender' ),\n\t\t\t\t\t\t\t),\n\t\t\t\t\t )\n\t\t\t\t\t)\n\t\t\t\t);\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "af11570e2eb88b12cfea97dfdb9d13d1", "score": "0.5313171", "text": "function themo_return_header_sidebar_settings($post_type = false) {\n if (th_is_woocommerce_activated() && is_woocommerce()) { // Handle all Woo stuff...\n $key = 'themo_woo';\n $show_header = get_theme_mod( $key.'_show_header', true );\n $page_header_float = get_theme_mod( $key.'_header_float', \"centered\" );\n return array ($key, $show_header, $page_header_float,false);\n\t}elseif($post_type > \"\"){\n $key = $post_type.\"_layout\";\n $show_header = get_theme_mod( $key.'_show_header', true );\n $page_header_float = get_theme_mod( $key.'_header_float', \"centered\" );\n $masonry = get_theme_mod( $key.'_masonry', \"off\" );\n return array ($key, $show_header, $page_header_float,$masonry);\n }elseif (is_home()) {\n\t\t$key = 'themo_blog_index_layout';\n\t\t$show_header = get_theme_mod( $key.'_show_header', true );\n\t\t$page_header_float = get_theme_mod( $key.'_header_float', \"centered\" );\n\t\t$masonry = get_theme_mod( $key.'_masonry', false );\n\t\treturn array ($key, $show_header, $page_header_float,$masonry);\n\t}elseif (is_single()) {\n\t\t$key = 'themo_single_post_layout';\n\t\t$show_header = get_theme_mod( $key.'_show_header', true );\n\t\t$page_header_float = get_theme_mod( $key.'_header_float', \"centered\" );\n\t\treturn array ($key, $show_header, $page_header_float,false);\n\t} elseif (is_archive()) {\n\t\t$key = 'themo_default_layout';\n\t\t$show_header = get_theme_mod( $key.'_show_header', true );\n\t\t$page_header_float = get_theme_mod( $key.'_header_float', \"centered\" );\n\t\treturn array ($key, $show_header, $page_header_float,false);\n\t} elseif (is_search()) {\n\t\t$key = 'themo_default_layout';\n\t\t$show_header = get_theme_mod( $key.'_show_header', true );\n\t\t$page_header_float = get_theme_mod( $key.'_header_float', \"centered\" );\n\t\treturn array ($key, $show_header, $page_header_float,false);\n\t} elseif (is_404()) {\n\t\t$key = 'themo_default_layout';\n\t\t$show_header = get_theme_mod( $key.'_show_header', true );\n\t\t$page_header_float = get_theme_mod( $key.'_header_float', \"centered\" );\n\t\treturn array ($key, $show_header, $page_header_float,false);\n\t} else {\n\t\t$key = 'themo_default_layout';\n\t\t$show_header = get_theme_mod( $key.'_show_header', true );\n\t\t$page_header_float = get_theme_mod( $key.'_header_float', \"centered\" );\n\t\treturn array ($key, $show_header, $page_header_float,false);\n\t}\n}", "title": "" }, { "docid": "6f5af7c3566fb6dbb7ce7595f829c2f7", "score": "0.53103226", "text": "function corpo_post_meta($content) {\r\n \r\n if ( is_single() ) {\r\n $categories = get_the_category_list(__( ', ', 'corpo' ));\r\n $tags = get_the_tag_list('', __( ', ', 'corpo' ));\r\n\r\n $content .= corpo_custom_wp_link_pages(); //Pagination \r\n\r\n $content .= '<div class=\"alignright\">'. get_previous_posts_link( ) .'</div>';\r\n $content .= '<div class=\"alignleft\">'. get_next_posts_link( ) .'</div> ';\r\n\r\n //$content .= '<div class=\"post-meta\">';\r\n //if( !empty( $categories ) ) :\r\n // $content .= '<i>'. __( 'Posted in ', 'corpo' ) . $categories .'</i>';\r\n //endif;\r\n //if( !empty( $tags ) ) :\r\n // $content .= '<i> | '. __( 'Tagged: ', 'corpo' ) . $tags .'</i>';\r\n //endif; \r\n //$content .= '</div>';\r\n }\r\n\treturn $content;\r\n}", "title": "" } ]
5b0ac639944b298638ab65a1e8725065
Default constructor The constructor will set some properties. It populates the parameter array with urldecoded values for easyuse.
[ { "docid": "5258caee6b1f5df6b78a884fbce2c94c", "score": "0.0", "text": "public function __construct()\n\t{\n\t\t// get objects from the reference so they are accessable from the action-object\n\t\t$this->tpl = Spoon::get('template');\n\t\t$this->url = Spoon::get('url');\n\n\t\t// do the login magic\n\t\t$this->currentUser = Authentication::getLoggedInUser();\n\n\t\t// assign if there is a valid user\n\t\tif($this->currentUser != false)\n\t\t{\n\t\t\t// assign\n\t\t\t$this->tpl->assign('currentUser', $this->currentUser->toArray());\n\t\t}\n\n\t\t// store the current module and action (we grab them from the url)\n\t\t$this->setModule($this->url->getModule());\n\t\t$this->setAction($this->url->getAction());\n\n\t\t// assign option\n\t\t$this->tpl->assign('is' . SpoonFilter::toCamelCase($this->url->getModule()), true);\n\n\t\t// require the model if it exists\n\t\tif(SpoonFile::exists(PATH_WWW . '/modules/' . $this->getModule() . '/model/model.php')) require_once PATH_WWW . '/modules/' . $this->getModule() . '/model/model.php';\n\t}", "title": "" } ]
[ { "docid": "01c0fd78ea956d69037d5350d7bc9ecd", "score": "0.734283", "text": "function __construct()\n {\n foreach($_REQUEST as $param_key => $param_value) {\n $this->all_params[$param_key] = $param_value;\n }\n\n // Record all params found in the path\n $url_path = $this->getParam('url_path', '');\n foreach(self::$PATH_PARAM_RULES as $param_key => $regex_pattern) {\n $pattern_matches = array();\n $has_matches = preg_match('/' . $regex_pattern . '/', $url_path, $pattern_matches);\n if($has_matches === 1) {\n $this->all_params[$param_key] = $pattern_matches[1];\n }\n }\n }", "title": "" }, { "docid": "b0e98335879a365e4f91b27f6fb11dc5", "score": "0.7241567", "text": "public function __construct() {\n\n $this->params = array();\n }", "title": "" }, { "docid": "1d6e0ecf5520daabf02f65ca5f884a03", "score": "0.7159203", "text": "public function __construct()\r\n\t{\r\n\t\tparent::__construct();\r\n\r\n\t\t$this->registry = Registry::getInstance();\r\n\t\t\r\n\t\t$this->extractQueryParams();\r\n\t}", "title": "" }, { "docid": "cae749f2222b7923b76b23dcadbfbcd8", "score": "0.7145392", "text": "public function __construct()\n\t{\n\t\t$urlArray = $this->parseUrl();\n\n\t\t// var_dump(rtrim($_GET['url'],'/'));\n\t\t// If page doesn't requested, then set default page Home.\n\t\t// If action doesn't requested, then set default action index.\n\t\tif (!empty($urlArray[0])){\n\n\t\t\t$this->url_controller = \"App\\Controllers\\\\\".$urlArray[0];\n\n\t\t}else{\n\n\t\t\t$this->url_controller = \"App\\Controllers\\\\\".$GLOBALS['home_page'];\t\t\t\t\t\t\t\t\n\t\t}\n\n\t\tif (!empty($urlArray[1])) {\n\n\t\t\t$this->url_action = $urlArray[1];\n\t\t}else{\n\n\t\t\t$this->url_action = $GLOBALS['action'];\t\n\n\t\t}\n\n\t\tunset($urlArray[0]);\n\n\t\tunset($urlArray[1]);\n\n\t\t$this->url_params = $urlArray ? array_values($urlArray) : [];\n\t\t\n\n\t}", "title": "" }, { "docid": "a618c979268b51e5ba8789590b8382d7", "score": "0.7001376", "text": "private function __construct()\n {\n $this->sUri = (new HttpRequest)->requestUri();\n\n // Strip the trailing slash from the URL to avoid taking a wrong URL fragment\n $this->sUri = rtrim($this->sUri, PH7_SH);\n\n /*** Here, we put the string into array ***/\n self::$aFragments = explode(PH7_SH, $this->sUri);\n }", "title": "" }, { "docid": "15cb53f70b26e74090136bc7d7c1fca1", "score": "0.6943007", "text": "public function __construct()\n {\n $this->setUri();\n $this->setParam();\n $this->setMethod();\n $this->setController();\n }", "title": "" }, { "docid": "f4948b50bae7388fbc42d5a4ce2672d7", "score": "0.69383013", "text": "protected function init() {\n $params = array_merge($_GET, $_POST);\n\n if (!empty($params)) {\n foreach ($params as $key => $value) {\n $this->{$key} = $value;\n }\n }\n }", "title": "" }, { "docid": "ee9fb1d5f3ed871ea89c35b24fa3b103", "score": "0.6918331", "text": "private function __construct()\n {\n // Reads the parameters received in the request\n foreach ($this->expectedRouteParams as $p) {\n $this->routeParams[$p] = Utils::sanitizeString($_REQUEST[$p]);\n }\n\n // The rest of the parameters in a GET request are considered part of the query string\n foreach ($_GET as $key=>$value) {\n if (!in_array($key, $this->expectedRouteParams)) {\n $this->queryParams[$key] = Utils::sanitizeString($value);\n }\n }\n }", "title": "" }, { "docid": "50534f763195866b858dfe73fd536659", "score": "0.6822761", "text": "public function __construct()\n\t{\n\t\t$this->url = config('services.bluepay.url', $this->url);\n\t\t$this->secretKey = config('services.bluepay.secret');\n\t\t$this->presetFields();\n\t}", "title": "" }, { "docid": "dd3d1ea340990c6e76fe3e093ab2e5a6", "score": "0.68139994", "text": "public function __construct()\n {\n parent::__construct();\n $this->params = array(\n 'version' => '212',\n 'bill_method' => '05',\n 'kessai_id' => '0501',\n 'shop_cd' => '3190256',\n 'syuno_co_cd' => '56968',\n // 'kyoten_cd' => '',\n 'shop_pwd' => 'yuZ4sYN3123456',\n 'shoporder_no' => '', // shoporder_no\n 'seikyuu_kingaku' => '', // seikyuu_kingaku\n );\n }", "title": "" }, { "docid": "8651fe016a0fb24ab55f0e6e307c77e3", "score": "0.67963743", "text": "public function __construct() {\r\n\r\n $this->_website = \\filter_input(INPUT_SERVER, \"HTTP_HOST\");\r\n $this->_request_array = new ArrayIterator($_REQUEST);\r\n ;\r\n\r\n $this->params = new ArrayIterator(array());\r\n $this->_parser();\r\n // $this->_reflection= new ReflectionClass($this->_controller); \r\n $this->__parameters = array();\r\n }", "title": "" }, { "docid": "b25a268981ab92ba430161cdb3fb4a09", "score": "0.67851216", "text": "public function __construct()\n {\n $this->url = filter_var($_SERVER['REQUEST_URI'], FILTER_SANITIZE_URL);\n $this->init();\n }", "title": "" }, { "docid": "8e65240b9b600b92d929c6f53c6ced17", "score": "0.6778224", "text": "public function __construct()\n {\n $this->_params = new \\stdClass();\n }", "title": "" }, { "docid": "40125d6b5a2ac4c45c326196692c79f3", "score": "0.6775707", "text": "public function __construct()\n\t{\n\t\t// -- Build the request uri\n\t\t$url = $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];\n\t\t\n\t\tif(isset($_SERVER['HTTPS']) && in_array(strtolower($_SERVER['HTTPS']), array('on', '1'))) \n\t\t\t$url = 'https://' . $url;\n\t\t\n\t\telse if(isset($_SERVER['SERVER_PORT']) && ('443' == $_SERVER['SERVER_PORT']))\n\t\t\t$url = 'https://' . $url;\n\t\t\n\t\telse\n\t\t\t$url = 'http://' . $url;\n\t\n\t\t// -- Clean up query\n\t\t$url = explode('?', strtolower($url), 2);\n\t\t\n\t\t// Clean up query\n\t\tif(!empty($url[1]))\n\t\t{\n\t\t\tparse_str($url[1], $query);\n\t\t\t\n\t\t\t// -- Remove google params & campaign params\n\t\t\tunset($query['gclid']);\n\t\t\t\n\t\t\tforeach($query as $key => &$void)\n\t\t\t{\n\t\t\t\tif(strpos($key, 'utm_') === 0)\n\t\t\t\t\tunset($query[$key]);\n\t\t\t}\n\t\t\t\n\t\t\tksort($query);\n\t\t\t\n\t\t\t$url[1] = http_build_query($query);\n\t\t}\n\t\t\n\t\t// -- Concat query\n\t\t$this->_url = implode('?', $url);\n\t}", "title": "" }, { "docid": "0bb99cb24ef9fc6bd31f9b9c861a3e40", "score": "0.6755667", "text": "public function __construct() {\n // the fourth arg is forceLang and if left to default (true) then the url is malformed - core bug as of 1.3.0\n }", "title": "" }, { "docid": "20ae775c3effd51b1827f20733f8f21a", "score": "0.67510045", "text": "public function __construct()\n {\n $this->setKey();\n $this->setBaseUrl();\n $this->setRequestOptions(); \n }", "title": "" }, { "docid": "105ff5b209a9537bb51d9bb1273c3c45", "score": "0.6726256", "text": "function __construct() {\r\n\t\t\t$this->_get = $_GET;\r\n\t\t\t$this->_post = $_POST;\r\n\t\t\t$_GET = null;\r\n\t\t\t$_POST = null;\r\n\t\t\t$_REQUEST = null;\r\n\t\t}", "title": "" }, { "docid": "a88e70b6bee0d5d1361e9407eb1ebc59", "score": "0.6723582", "text": "public function __construct()\n {\n $this->requestPath = (!empty($_GET['q'])) ? $_GET['q'] : null;\n \n $params = $_GET;\n unset($params['q']);\n $this->requestParams = $params;\n }", "title": "" }, { "docid": "49c75340c60e16bff7d9f19a80eda5a6", "score": "0.67160887", "text": "public function __construct(array $uRL = array())\n {\n $this\n ->setURL($uRL);\n }", "title": "" }, { "docid": "4deba95525fae53adaeb466c123314bc", "score": "0.67136586", "text": "public function __construct($params = array()) {}", "title": "" }, { "docid": "4deba95525fae53adaeb466c123314bc", "score": "0.67136586", "text": "public function __construct($params = array()) {}", "title": "" }, { "docid": "8441f73d92908a83fdca967073db46d2", "score": "0.6710981", "text": "public function __construct()\n {\n $this->params = $_REQUEST;\n \n $this->method = strtolower($_SERVER['REQUEST_METHOD']);\n $this->uri = $_SERVER['REQUEST_URI'];\n $this->ip = $_SERVER['REMOTE_ADDR'];\n $this->agent = $_SERVER['HTTP_USER_AGENT'];\n $this->referer = $_SERVER['HTTP_REFERER'] ?? '';\n }", "title": "" }, { "docid": "2379746d41aaab538405b6c1468a84ce", "score": "0.6705001", "text": "public function __construct() {\n if (isset($_GET)){\n foreach ($_GET as $key => $value){\n if ($key == 'json') {\n $json = json_decode($value, true);\n if (!is_array($json)){\n continue;\n }\n if (!count($json)){\n continue;\n }\n foreach($json as &$jsonValue){\n $jsonValue = htmlspecialchars($jsonValue,ENT_QUOTES,'UTF-8');\n }\n $this->Parameters[$key] = $json;\n continue;\n } elseif ($key == 'file'){\n $i = strpos($value, '?');\n $newValue = substr($value, 0, $i);\n $newValue = htmlspecialchars($newValue,ENT_QUOTES,'UTF-8');\n $this->Parameters[$key] = $newValue;\n continue;\n }\n //$newValue = htmlentities($value,ENT_QUOTES,'UTF-8');\n $newValue = htmlspecialchars($value,ENT_QUOTES,'UTF-8');\n $this->Parameters[$key] = $newValue;\n }\n }\n\n if (isset($_POST)){\n foreach ($_POST as $key => $value){\n if ($key == 'json') {\n $json = json_decode($value, true);\n if (!is_array($json)){\n continue;\n }\n if (!count($json)){\n continue;\n }\n foreach($json as &$jsonValue){\n $jsonValue = htmlspecialchars($jsonValue,ENT_QUOTES,'UTF-8');\n }\n $this->Parameters[$key] = $json;\n continue;\n } elseif ($key == 'file'){\n $i = strpos($value, '?');\n $newValue = substr($value, 0, $i);\n $newValue = htmlspecialchars($newValue,ENT_QUOTES,'UTF-8');\n $this->Parameters[$key] = $newValue;\n continue;\n }\n //$newValue = htmlentities($value,ENT_QUOTES,'UTF-8');\n $newValue = htmlspecialchars($value,ENT_QUOTES,'UTF-8');\n $this->Parameters[$key] = $newValue;\n }\n }\n\n $this->takePageUrl();\n }", "title": "" }, { "docid": "bfa726c64753d11cf9eee57fcc59525e", "score": "0.66767687", "text": "public function __construct() {\n $this->parseRequest();\n }", "title": "" }, { "docid": "1b4178f8ebed92b1929513873a0abb5e", "score": "0.66478693", "text": "public\n\n\tfunction __construct() {\n\t\tSession::init();\n\t\t//sets the url\n\t\t$this->_getUrl();\n\t\t$this->_getPOST();\n\n\t}", "title": "" }, { "docid": "01fa8bfafbf64cd4858dae953710de96", "score": "0.66190314", "text": "function __construct()\n {\n $this->init();\n $this->filter_url();\n }", "title": "" }, { "docid": "5ac381f38d739398955a0ecb11b7e625", "score": "0.66125476", "text": "public function __construct($params)\n {\n $this -> params = ($params);\n\n }", "title": "" }, { "docid": "717dc9342bfdcc4b3c334b5c83fda9a8", "score": "0.6611621", "text": "public function __construct()\n {\n $this->getUrl();\n }", "title": "" }, { "docid": "dcf1906b8133bf992a50c79f39c74fda", "score": "0.66082", "text": "function __construct(array $arr = null) {\n //\n //\n if (is_null($arr)) {\n //\n //Filter the global variable $POST to avoid the direct use of global \n //variable warning\n $arr = filter_input_array(INPUT_POST);\n //\n //Set this page's array\n $this->arr = is_null($arr) ? [] : $arr;\n //\n //Filter the global variable $GET ditto $POST\n $arr2 = filter_input_array(INPUT_GET);\n //\n //Check where anyting is got\n if (!is_null($arr2)) {\n //\n //Merge the arrays\n $this->arr = array_merge($this->arr, $arr2);\n }\n } else {\n //\n //Use the given (restricted) global source\n $this->arr = $arr;\n }\n //\n //Initialize the parent mutall system\n parent::__construct();\n //\n //We cannot offload the properties of querystring to a page because\n //a page is a querystring and if we do away with the array we will\n //lose track of parameters that were used for calling this page\n }", "title": "" }, { "docid": "993cf547f28fc83b5929c91456c49dd9", "score": "0.6596268", "text": "public function __construct($urlString = null) {\n\t\t// Default to Current URL\n\t\tif($urlString === null) {\n\t\t\t$urlString = 'http' . ($_SERVER['HTTPS'] ? 's' : '') . '://' . $_SERVER['HTTP_HOST'] . ($_SERVER['SERVER_PORT'] != '80' ? ':' . $_SERVER['SERVER_PORT'] : '') . $_SERVER['REQUEST_URI'];\n\t\t}\n\n\t\t// Parse URL\n\t\t$parts = parse_url($urlString);\n\n\t\tif($parts) {\n\t\t\t$this->_protocol = $parts['scheme'];\n\t\t\t$this->_host = $parts['host'];\n\t\t\t$this->_port = $parts['port'];\n\t\t\t$this->_username = $parts['user'];\n\t\t\t$this->_password = $parts['pass'];\n\t\t\t$this->_path = $parts['path'];\n\t\t\t$this->_fragment = $parts['fragment'];\n\t\t\t$this->_params = array();\n\n\t\t\t$params = explode('&', $parts['query']);\n\n\t\t\tforeach($params as $param) {\n\t\t\t\tlist($key, $value) = array_map('urldecode', explode('=', $param));\n\t\t\t\t$this->_params[$key] = $value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "744f84a34686884441c678b34a451f00", "score": "0.6595541", "text": "public function __construct ( $params = '' )\n\t{\n\t\t// Get arguments\n\t\t$args = func_get_args();\n\t\t$num_args = count($args);\n\t\t//$args0 = ( isset($args[0]) ? $args[0] : null );\n\t\t\n\t\t// Check for alternate argument patterns\n\t\tif ( is_string($params) && $num_args == 1 )\n\t\t{\n\t\t\t$params = array(\n\t\t\t\t'url' => ( isset($args[0]) ? $args[0] : null ),\n\t\t\t);\n\t\t}\n\t\telseif ( $num_args > 1 )\n\t\t{\n\t\t\t$params = array(\n\t\t\t\t'url' => ( isset($args[0]) ? $args[0] : null ),\n\t\t\t\t'auth' => ( isset($args[1]) ? $args[1] : null ),\n\t\t\t);\n\t\t}\n\t\t\n\t\t// Set default values for missing keys\n\t\t$default_params = array(\n\t\t\t'url' => '',\n\t\t\t'class' => '',\n\t\t\t'auth' => array(),\n\t\t);\n\t\t$params = array_merge($default_params, $params);\n\t\t\n\t\t// Put constants and codes in map\n\t\t$this->error_map = array_merge($this->error_map, array_flip($this->error_map));\n\t\t\n\t\t$this->url = $params['url'];\n\t\t$this->class = $params['class'];\n\t\t$this->auth = $params['auth'];\n\t\t$this->auth_type = isset($params['auth']['type']) ? $params['auth']['type'] : $this->auth_type;\n\t}", "title": "" }, { "docid": "32747d15632e93fe1b9de3ff5f02264b", "score": "0.6588505", "text": "function __construct( $params = [] ){\r\n\r\n\t}", "title": "" }, { "docid": "e638588130cdf1737792f6b76b57c7c2", "score": "0.6583101", "text": "public function __construct($data) {\n\n\t\t$this->url = $_SERVER['REQUEST_URI'];\n\t\t$this->requestMethod = $_SERVER['REQUEST_METHOD'];\n\t\t$this->postData = $_POST;\n\t\t//var_dump($_POST);\n\t\t\n\t\t$this->decodeURL2();\n\n\t}", "title": "" }, { "docid": "d673bc9bd1b1a002f03b6161c7e2a826", "score": "0.6564104", "text": "public function __construct()\n {\n // let's set the global variables\n parent::__construct($_SERVER, $_GET, $_POST, $_COOKIE, $_FILES);\n\n // now let's set the URL\n $this->url = new Url();\n $this->url->setHost($this->server->get('HTTP_HOST',config('app.domain','')));\n $this->url->setSecure($this->server->get('HTTPS',false));\n $this->url->setUri($this->server->get('REQUEST_URI','/'));\n }", "title": "" }, { "docid": "487c5d74a5fc6a027dfcc6927e007746", "score": "0.6543538", "text": "public function __construct()\n {\n $this->url = null;\n $this->content = null;\n $this->result = null;\n }", "title": "" }, { "docid": "b05df27bb3a57f219b8d1304bab9617f", "score": "0.65339315", "text": "public function __construct()\n {\n $this->_method = $_SERVER['REQUEST_METHOD'];\n $this->_queryOptions = null;\n $this->_queryOptionsCount = null;\n $this->_headers = null;\n $this->getHeaders();\n }", "title": "" }, { "docid": "1ffa9ed58e230c277f95677deac7e812", "score": "0.6531081", "text": "public function __construct(){\n\n /** @url http://php.net/manual/en/function.filter-input.php */\n $this->uri = filter_input(INPUT_SERVER, 'REQUEST_URI', FILTER_DEFAULT);\n }", "title": "" }, { "docid": "473271cbe5d42508411d8626c58fbca4", "score": "0.65027076", "text": "public function __construct($config = []) {\n\n $this->data = $this->getDataFromPOST($_POST, $_FILES);\n $this->query = $_GET;\n //$this->parametri += isset($config[\"params\"]) ? $config[\"params\"] : [];\n $this->url = $this->fullUrl();\n }", "title": "" }, { "docid": "191c151407488782daef247caa36e55e", "score": "0.65020955", "text": "public function __construct()\n {\n self::Redirect(strtok($_GET['url'], '?'));\n }", "title": "" }, { "docid": "5f765e80217a6a500fef6562f97d8afb", "score": "0.6490288", "text": "function __construct(){\r\n $arr = require 'app/config/routes.php';\r\n foreach ($arr as $key => $val) {\r\n $this->add($key, $val);\r\n }\r\n $_GET['id'] = $this->getId();\r\n\r\n }", "title": "" }, { "docid": "af90965e0eb285b30704b98b086c09cb", "score": "0.6487077", "text": "public function __construct()\n {\n $this->method = RequestInterface::METHOD_GET;\n $this->params = array();\n }", "title": "" }, { "docid": "e43cfdcb491aa6942adbf96502ba2afd", "score": "0.64685565", "text": "public function __construct()\n {\n if (17 == func_num_args()) {\n $this->id = func_get_arg(0);\n $this->code = func_get_arg(1);\n $this->websiteId = func_get_arg(2);\n $this->locale = func_get_arg(3);\n $this->baseCurrencyCode = func_get_arg(4);\n $this->defaultDisplayCurrencyCode = func_get_arg(5);\n $this->timezone = func_get_arg(6);\n $this->weightUnit = func_get_arg(7);\n $this->baseUrl = func_get_arg(8);\n $this->baseLinkUrl = func_get_arg(9);\n $this->baseStaticUrl = func_get_arg(10);\n $this->baseMediaUrl = func_get_arg(11);\n $this->secureBaseUrl = func_get_arg(12);\n $this->secureBaseLinkUrl = func_get_arg(13);\n $this->secureBaseStaticUrl = func_get_arg(14);\n $this->secureBaseMediaUrl = func_get_arg(15);\n $this->extensionAttributes = func_get_arg(16);\n }\n }", "title": "" }, { "docid": "a93c945f487e3ce2be120add1bbea0f8", "score": "0.6466739", "text": "public function __construct()\n {\n $statusCode = 200;\n $this->parseRoute();\n\n $this->setGetParameters();\n $this->setPostParameters();\n }", "title": "" }, { "docid": "d06e7fbac20679efd8dec36c334f2e7f", "score": "0.64651906", "text": "function __construct( $params )\n\t{\n\t\t$this->params = $params;\n\t}", "title": "" }, { "docid": "0ee4b2ba01def498569b39d4c6860b69", "score": "0.646172", "text": "public function __construct()\n {\n $this->basedir = null;\n $this->script = null;\n $this->unorderedDelimiters = array( '(', ')' );\n $this->orderedParameters = array();\n $this->unorderedParameters = array();\n }", "title": "" }, { "docid": "f787f456c4dbb66e607b2edb5d498ef2", "score": "0.6457782", "text": "public function __construct()\n {\n $url = $this->parseURL();\n var_dump($url);\n }", "title": "" }, { "docid": "f6321848b1c2ae5277e10fbaadf77ba7", "score": "0.6456737", "text": "public function __construct()\n {\n\t\t// Lets build our properties.\n $this->url = $this->protocol.$this->base.'/'.$this->returnType.'/'.$this->version.'/';\n $this->http = new Client();\n $this->headers = [\n 'cache-control' => 'no-cache',\n 'content-type' => 'application/json',\n ];\n }", "title": "" }, { "docid": "89a00fff3721ad7358fae617228cdde4", "score": "0.64545995", "text": "public function __construct($params) {\n $this->params = $params;\n }", "title": "" }, { "docid": "0d0114ebb8eb5fdbf1a57273a6f061c9", "score": "0.64434826", "text": "function decodeURL(){\n\n\t\tif(isset($_GET['q'])){\n\n\t\t\t$string=base64_decode(urldecode($_GET['q']));\n\n\t\t\t$array=explode('&',$string);\n\n\t\t\t$_GET=array();\n\n\t\t\tforeach($array as $dato){\n\n\t\t\t\t$d=explode('=',$dato);\n\n\t\t\t\t$_GET[$d[0]]=$d[1];\n\n\t\t\t}\n\n\t\t}\n\n\t\telse{\n\n\t\t\t$this->GET=$_GET;\n\n\t\t}\n\n\t}", "title": "" }, { "docid": "623e690ee862a2746ff467ddf7bef871", "score": "0.64315224", "text": "public function __construct(){\n\t\t\tparent::__construct();\n\t\t\t$p = '{\"unm\":\"t\",\"pwd\":\"t\",\"uid\":\"t\",\"opw\":\"t\",\"npw\":\"t\",\"cpw\":\"t\",\"auc\":\"t\",\"eml\":\"t\",\"liv\":\"n\",\"riv\":\"n\"}';\n\t\t\t$this->props = json_decode($p,true);\n\t\t}", "title": "" }, { "docid": "52eb870ff0fc25010fb279b34a976157", "score": "0.6411606", "text": "function __construct($url) {\n\n if (strstr($url, '?')) $url = substr($url, 0, strpos($url, '?'));\n $url = rtrim($url, '/');\n self::$url = trim($url);\n self::$separate_url = explode('/', $url);\n\n }", "title": "" }, { "docid": "f23b08c6f90fe21769ada18021e122cc", "score": "0.6406474", "text": "public function __construct() {\n\n $uri = Uri::createFromString(self::URI_COMPLETE);\n $this->host = $uri->host;\n\n }", "title": "" }, { "docid": "eb8c873ae20a93e54eba9d66d48b09b3", "score": "0.6401535", "text": "public function __construct()\n\t{\n\t\tUserInputHandlerRegistry::get_instance()->register_handler($this);\n\n\t\t$this->genres_url = ArrakisConfig::MOVIE_GENRES_URL;\n\t\t$this->videos_url = ArrakisConfig::MOVIE_LIST_URL;\n\t\t$this->video_ids_url = ArrakisConfig::MOVIE_ID_LIST_URL;\n\t\t$this->video_id_prefix = MOVIE_PREFIX;\t\t\t\t\t\n\n\t\t$this->popup_sort_options = ArrakisConfig::GET_MOVIE_SORT_OPTIONS();\n\t\t\n\t\tparent::__construct(self::ID);\n\t}", "title": "" }, { "docid": "c297aa6f3c09304b72f6a402155a6423", "score": "0.63989604", "text": "function __construct() {\r\n\t\t\t$url_obj = new Url();\r\n\t\r\n\t\t\t$this->requested_url \t\t= $url_obj->toString();\r\n\t\t\t$this->remote_ip \t\t\t= !empty($_SERVER['REMOTE_ADDR']) ? $_SERVER['REMOTE_ADDR'] : '';\r\n\t\t\t$this->referer\t\t\t\t= !empty($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '';\r\n\t\t\t$this->request_is_valid \t= false;\r\n\t\r\n\t\t\t// Check all three conditions necessary to allow this request\r\n\t\t\tif ( $this->isWhiteListed() && $this->isRefererValid() && $this->isWithinLimit() ) { $this->request_is_valid = true; }\r\n\t\t}", "title": "" }, { "docid": "088def929f739e8c8517a7f90a8a86d5", "score": "0.6395449", "text": "public function __construct(){\n\t\t\tparent::__construct(); \n\t\t\t$p = '{\"rid\":\"n\",\"nam\":\"t\",\"pdc\":\"t\",\"sid\":\"n\",\"sdt\":\"t\",\"edt\":\"t\",\"cnm\":\"t\",\"scd\":\"t\",\"bid\":\"n\",\"tel\":\"t\",\"pyf\":\"n\",\"acy\":\"n\",\"pid\":\"n\",\"pyr\":\"n\",\"ssi\":\"n\",\"rgs\":\"n\",\"cur\":\"t\",\"amt\":\"n\",\"rcp\":\"t\",\"ast\":\"n\",\"stp\":\"t\",\"sts\":\"n\",\"pos\":\"n\",\"plm\":\"n\"}';\n\t\t\t$this->props = json_decode($p,true);\n\t\t\t//TODO: check for valid user (php_cli ?)\n\t\t}", "title": "" }, { "docid": "ea105d912bdffa9ff918da132c320037", "score": "0.63891596", "text": "public function __construct($params)\n {\n if( isset($params['display']) ) {\n $this->display = $params['display'];\n }\n\n if( isset($params['code']) ) {\n $this->code = $params['code'];\n }\n }", "title": "" }, { "docid": "ad251d2c3ae42de5b493363c2825e517", "score": "0.6382623", "text": "function __construct($params = array())\n\t{\n\t\tif(is_array($params) && count($params))\n\t\t\t$this->params = $params;\n\t\t\t//$this->connect($params);\n\t}", "title": "" }, { "docid": "e2052eacb975a32a6f748c5843b2f1ad", "score": "0.6379802", "text": "function __construct($url=null,$logon=null,$password=null) {\n\t\t$this->_url = $url;\n\t\t$this->_logon = $logon;\n\t\t$this->_password = $password;\n\t}", "title": "" }, { "docid": "5d18bb5f33d835eb30f9193a0f21abbd", "score": "0.63797116", "text": "function __construct() {\n\n $this->url = Url::getInstance();\n $this->input = Input::getInstance();\n $this->output = Output::getInstance();\n $this->session = Session::getInstance();\n $this->cookie = Cookie::getInstance();\n $this->cache = Cache::getInstance();\n\n $this->setOutputFromSession();\n }", "title": "" }, { "docid": "d4b87622181d35a3d044c22b28e8da94", "score": "0.63745105", "text": "function __construct() {\n $this->originalUrl = $_GET['tlOrigUrl'];\n\n // Scene id. Unique id identifying an image with tags.\n $this->sceneId = $_GET['tlScene'];\n\n // Thing id. Unique id identifying a tag inside a scene.\n $this->thingId = $_GET['tlThing'];\n\n $this->params = self::getParams();\n\n $this->vars = array();\n\n $this->renderPage();\n }", "title": "" }, { "docid": "a3f71f693d63159909c422f458b8b80f", "score": "0.6371101", "text": "public function __construct() {\n\t\t//login string must be created on object initialization\n\t\t$this->requestLogin\t\t= $this->apikey.\"%\".$this->login.\":\".$this->password;\n\t\t$this->apiPath \t\t\t= $this->apiPath.$this->login;\t\n\t}", "title": "" }, { "docid": "1f10a385ea19ae17f557a0d2d87799f0", "score": "0.63686985", "text": "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->link = func_get_arg(0);\n $this->emailConfig = func_get_arg(1);\n }\n }", "title": "" }, { "docid": "931c015a6864f6bdb6ee8f73ea0c2121", "score": "0.63538325", "text": "public function __construct()\n {\n $this->baseUrl = self::API_URL;\n $this->client = new Client(['base_uri' => $this->baseUrl]);\n $this->setGetResponse($this->getRelativeUrl());\n }", "title": "" }, { "docid": "450e24a9781ce13d528fde5b6ae8ac98", "score": "0.6351969", "text": "function __construct($url)\n {\n $this->url = $url;\n $this->protocol = parse_url($url, PHP_URL_SCHEME);\n $this->host = parse_url($url, PHP_URL_HOST);\n $this->path = parse_url($url, PHP_URL_PATH);\n $this->query = parse_url($url, PHP_URL_QUERY);\n }", "title": "" }, { "docid": "26a9f851dca12b227e7206149606e9b2", "score": "0.635086", "text": "public function __construct()\n { \n\n $this->videoType = 'automatic';\n $this->videoInput = '';\n $this->videoInputType = 'Url';\n $this->videoParameterList = array();\n \n $this->videoRegister = new videoPluginRegistry();\n \n $this->videoDataList = array();\n $this->videoDefaultValueList = array();\n $this->videoHtmlCodeList = array();\n \n $this->initDomIdList();\n }", "title": "" }, { "docid": "bd2859825400fe38afe07620e29653f1", "score": "0.6339888", "text": "public function __construct()\n {\n $this->type = $this->type();\n\n $params = func_get_args();\n if (isset($params[0]))\n {\n $this->_params = $params[0];\n }\n }", "title": "" }, { "docid": "7a7c37770d1200b527c704f630309725", "score": "0.63397574", "text": "public function __construct() {\n\t\tself::$name = '';\n\t\tself::$post_key = '';\n\t\tself::$args = array();\n\t}", "title": "" }, { "docid": "25f7c8594d51ed38bdd31a503c118b6e", "score": "0.6335097", "text": "public function __construct() {\n\t\tparent::__construct();\n\t\t$this->mID=0;\n\t\t$this->mWeb=\"\";\n $this->mUrlWeb=\"\";\n\t\t\n\t}", "title": "" }, { "docid": "8ec7137e3ee14fd6d17e99061b97b51b", "score": "0.6334655", "text": "public function __construct()\n {\n if (self::isFormPost()) {\n $this->bitpayTransactionSpeed = self::getPostValue('bitpayTransactionSpeed');\n $this->bitpayRedirectURL = self::getPostValue('bitpayRedirectURL');\n }\n }", "title": "" }, { "docid": "07b7f64fa040f54f49cd3875c07a2f8f", "score": "0.6330919", "text": "function __construct($params)\n {\n }", "title": "" }, { "docid": "2d3b6e874e874fa5d2d460a341f2327d", "score": "0.63305193", "text": "public function __construct()\n {\n // Json array of http codes.\n $this->http_codes = $this->http_status_codes();\n // Init security library object\n $this->security_lib_obj = new SecurityLib();\n // Init user model object\n $this->user_model_obj = new User();\n // Init search model object\n $this->search = new Search();\n }", "title": "" }, { "docid": "22139af85bc2a4901b543fe476bd2d3a", "score": "0.6326871", "text": "function __construct($params = null) {\n\n }", "title": "" }, { "docid": "22139af85bc2a4901b543fe476bd2d3a", "score": "0.6326871", "text": "function __construct($params = null) {\n\n }", "title": "" }, { "docid": "b19c8818eb63b828b10c5f41545763ee", "score": "0.6322117", "text": "public function __construct($params = [])\n {\n $this->name = array_get($params, 'name');\n $this->email = array_get($params, 'email');\n $this->comments = array_get($params, 'comments');\n }", "title": "" }, { "docid": "a552b1e7d53b11e3592a929a7ce2de9e", "score": "0.6319303", "text": "public function __construct($params = '') {\n\t\t\t$this->optionalParams = [\t\t\"code\"\t\t\t=> \"string\",\n \t\t\t\t\t\t\t\t\t\"email\"\t\t\t=> \"string\",\n \t\t\t\t\t\t\t\t\t\"firstName\"\t\t=> \"string\",\n \t\t\t\t\t\t\t\t\t\t\"lastName\"\t\t=> \"string\"\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t];\n\t\t\tif (is_array($params)) {\n\t\t\t\t$this->buildFromArray($params);\n\t\t\t}\t\n\t\t}", "title": "" }, { "docid": "34a49d44c9a1fc8d4040814c330c82e5", "score": "0.6315459", "text": "function __construct() {\n\t\t$validate = $this->validateParams($_GET['startDate'], $_GET['endDate']);\n\t\t\n\t}", "title": "" }, { "docid": "937f0c174b272b8cc09b9a31dca0c4f3", "score": "0.63151515", "text": "public function __construct() {\n $this->SERVER = $_SERVER;\n\n $requestArray = explode('/', $this->SERVER['REQUEST_URI']);\n $request = array();\n foreach ($requestArray as $value) {\n if (trim($value) != '') $request[] = $value;\n }\n\n $this->controllerName = ($request[0] ? ucfirst($request[0]) : 'Index');\n $this->actionName = ($request[1] ? $request[1] : 'index');\n\n $countOfParameters = count($request);\n if ($countOfParameters > 2) {\n $parameter = array();\n for ($iterator = 2; $iterator <$countOfParameters; $iterator++) {\n $parameter[$request[$iterator]] = ($request[$iterator+1] ? $request[$iterator+1] : '-');\n $iterator++;\n }\n $this->setParameters($parameter);\n }\n }", "title": "" }, { "docid": "f1fd254d6e6cc93cde711ff201e0b8a5", "score": "0.63121736", "text": "public function __construct($params)\n {\n $this->params = $params;\n }", "title": "" }, { "docid": "f1fd254d6e6cc93cde711ff201e0b8a5", "score": "0.63121736", "text": "public function __construct($params)\n {\n $this->params = $params;\n }", "title": "" }, { "docid": "eefc80db5e29a7d76503fcd9e89ac466", "score": "0.63108766", "text": "public function __construct (array $params_array = null) {}", "title": "" }, { "docid": "345a756849c51959aac43e2056e7374b", "score": "0.63101363", "text": "private function __construct( $params ) {\r\n\r\n\t\t//Assign variables if they exist in $params array\r\n\t\t$this->curriculumID = ( array_key_exists('CurriculumID', $params) ) ? $params['CurriculumID'] : null;\r\n\t\t$this->departmentID = ( array_key_exists('DepartmentID', $params) ) ? $params['DepartmentID'] : null;\r\n\t\t$this->title = ( array_key_exists('Title', $params) ) ? $params['Title'] : null;\r\n\t\t$this->link = ( array_key_exists('Link', $params) ) ? $params['Link'] : null;\r\n\t}", "title": "" }, { "docid": "1f5e9f3d91de3b58b322101c2d651b8c", "score": "0.6308876", "text": "function __construct() {\r\n\t\t\t$this->properties = func_get_arg(0);\r\n\t\t}", "title": "" }, { "docid": "ce0fa432485ce4d023c37ab72804bc7a", "score": "0.6302039", "text": "function __construct() {\n\t\t\t// get controller name\n\t\t\t$this->controller = CONTROLLER;\n\t\t\t\n\t\t\t// get method name\n\t\t\t$this->method = METHOD;\n\t\t\t\n\t\t\t// get form parameters\n\t\t\t$this->parameters = json_decode(PARAMETERS, true);\n\t\t\t\n\t\t\t// set action path\n\t\t\t$this->action_path = APP_PATH.'/'.CONTROLLER;\n\t\t\t\n\t\t\t// default form action\n\t\t\t$this->form_action = FORM_ACTION;\n\t\t}", "title": "" }, { "docid": "d6e89d7938e702452b26dd03b5098ce2", "score": "0.62968165", "text": "public function __construct($strArray){\n if($strArray !== null){ \n $this->id = isset($strArray[\"id\"])?$strArray[\"id\"]:null; \n $this->nombre = $strArray[\"nombre\"];\n $this->apellido = $strArray[\"apellido\"]; \n $this->nacionalidad = $strArray[\"nacionalidad\"]; \n } \n }", "title": "" }, { "docid": "78c3e584fe640b7a56fb38f62a446219", "score": "0.62962896", "text": "public static function init()\r\n {\r\n self::$post = new ParameterBag();\r\n foreach ($_POST as $k => $v) {\r\n self::$post->add(strtolower($k), $v);\r\n }\r\n self::$get = new ParameterBag();\r\n foreach ($_GET as $k => $v) {\r\n self::$get->add(strtolower($k), $v);\r\n }\r\n self::$server = new ParameterBag();\r\n foreach ($_SERVER as $k => $v) {\r\n self::$server->add(strtolower($k), $v);\r\n }\r\n self::$files = new ParameterBag();\r\n foreach ($_FILES as $k => $v) {\r\n self::$files->add(strtolower($k), $v);\r\n }\r\n self::$cookies = new ParameterBag();\r\n foreach ($_COOKIE as $k => $v) {\r\n self::$cookies->add(strtolower($k), $v);\r\n }\r\n }", "title": "" }, { "docid": "23c1742153aac7f2851b7f83624d56b8", "score": "0.62957275", "text": "public function __construct($url = '')\n {\n $this->url = $url;\n }", "title": "" }, { "docid": "fbda89ddd491ecfc6fdbdd1c21667982", "score": "0.62949336", "text": "function __construct( array $params )\n {\n foreach( $params as $key => $value ) {\n // skip the script name\n if ( $key < 1 ) {\n continue;\n }\n // check for test flag\n if ( '--test' == $value ) {\n $this->__isTest = true;\n continue;\n }\n // check for site uri\n // if parameter list contains 2 or more site uri, the last will owerwrite others\n if ( CrawlExpr::isUri( $value ) ) {\n $this->__uri = $value;\n }\n }\n }", "title": "" }, { "docid": "d4d5c013f48b0637e83cee6a5860f7dc", "score": "0.6294595", "text": "function __construct($url)\n\t{\n\t\t$arr = explode('/',$url);\n\t\t$this->setController($arr[2]);\n\t\t$this->action = (isset($arr[3])) ? $arr[3] : null;\n\t\t$this->params = array_slice($arr, 4);\n\t}", "title": "" }, { "docid": "c9ba812ae0ae5cb5eff26b2fb7bf6adc", "score": "0.6292358", "text": "public function __construct($url) {\n $this->url= $url;\n }", "title": "" }, { "docid": "6c5f4d26eeaa2dd51f2b8977bc1386a3", "score": "0.62813896", "text": "public function init(){\n //normally Input objects would be predefined by properties\n foreach ($this->request->params as $key=>$param){\n //for the following, params can't be filtered because nature of value is unknown\n $this->$key = $param;\n }\n }", "title": "" }, { "docid": "fc21bda05d894ab0d020aa51a56448e2", "score": "0.62782365", "text": "public function __construct(array $arr)\n {\n $this->params = $arr;\n }", "title": "" }, { "docid": "873f9e7880ddc519c2ec51f5cedb66b5", "score": "0.62778896", "text": "public function __construct()\n\t{\n\t\t$this->setGadgetString();\n\t}", "title": "" }, { "docid": "13c114000064f346f6fbfe541d6ee26f", "score": "0.62753516", "text": "public function __construct($url = '')\n {\n $this->url = $url;\n }", "title": "" }, { "docid": "d6e545d5e9d3851f16c199915bb51a98", "score": "0.62746644", "text": "public function __construct($url_values) {\n\t\tglobal $config;\n\n\t\t$this->url_values = $url_values;\n\t\t\n\t\t//Find the controller and method from the url.\n\t\t//If they are not found, use default values.\n\t\tif ($this->url_values['controller'] === '') {\n\t\t\t$this->controller = $config['default_controller'];\n\t\t} else {\n\t\t\t$this->controller = $this->url_values['controller'];\n\t\t}\n\n\t\t$this->controller .= 'Controller';\n\n\t\tif ($this->url_values['action'] === '') {\n\t\t\t$this->action = $config['default_action'];\n\t\t} else {\n\t\t\t$this->action = $this->url_values['action'];\n\t\t}\n\t}", "title": "" }, { "docid": "8692fb1ae4a2e9ce24fbbfd3d4c0eb94", "score": "0.62737894", "text": "public function __construct($url) {\n $this->url= $url;\n }", "title": "" }, { "docid": "a153f9fcb89775e7c2c5767ec68ccdcb", "score": "0.62706065", "text": "public function __construct() {\n $this->parseURL();\n $this->handlePage();\n }", "title": "" }, { "docid": "dd9954ad5a4bf0982a465e8273089943", "score": "0.6268954", "text": "public function __construct()\n {\n if (6 == func_num_args()) {\n $this->qrCode = func_get_arg(0);\n $this->qrCodeUrl = func_get_arg(1);\n $this->expiresAt = func_get_arg(2);\n $this->additionalInformation = func_get_arg(3);\n $this->payer = func_get_arg(4);\n $this->pixProviderTid = func_get_arg(5);\n }\n }", "title": "" }, { "docid": "2db8cdd0dc3731d889d27e89c72f7951", "score": "0.6265733", "text": "public function setParams() {\n $keyToSearch = $this->request['id'] ;\n\n $this->oParams['id'] = $keyToSearch;\n $this->oParams['currency']= $this->request['currency']??'USD$';\n $this->oParams['lang']= $this->request['lang']??'en';\n $this->oParams['size']= $this->request['size']??20;\n $this->oParams['aggregate']= $this->request['aggregate']??true;\n $this->oParams['offset']= $this->request['offset']??0;\n\n $this->urlFields = http_build_query($this->oParams);\n $this->postFields = json_encode($keyToSearch,true);\n $this->url = API_SEARCH_URL;\n $this->method = 'GET';\n\n return $this;\n }", "title": "" }, { "docid": "aba0a22cc5aba9d620028613f0edbd87", "score": "0.62546575", "text": "public function __construct()\n\t{\n\t\t// $this->CORE_API_HTTP_PWD = '30708mQ2L8ifR11axUuCN9PMqJrlAHFS04o'; // dont need\n\t\t$this->merchant_id = '30708';\n\t\t$this->api_username = 'downloadtailieuvicoderscom';\n\t\t$this->api_password = 'NRtjMqohpXwu3m7MrjjY';\n\t\t$this->secure_code = '6212F60780C38157';\n\t}", "title": "" }, { "docid": "da12106bd0bad62524f934efb7bce2ed", "score": "0.62528116", "text": "public function __construct()\n {\n if (1 == func_num_args()) {\n $this->downloadableLinks = func_get_arg(0);\n }\n }", "title": "" }, { "docid": "218793ecf3c8e3546d49f4793feac462", "score": "0.62519145", "text": "function __construct(){\n\t\t\t$this -> errorCode = \"\";\n\t\t\t$this -> extractFile = false;\n\t\t\t$this -> credentialsOK = false;\n\t\t\t$this -> credentials = Array();\n\t\t\t$this -> rewriteRules = Array();\n\t\t\t$this -> loadCredentials();\n\t\t\t$this -> loadRewriteRules();\n\t\t}", "title": "" } ]
4070c8ec237409d47f2ffc6eab52ad00
Add item to FieldInfo value
[ { "docid": "c4ae2f9f63be47bdb3b0bd8ec20a5569", "score": "0.69708455", "text": "public function addToFieldInfo(\\StructType\\FieldInfo $item)\n {\n // validation for constraint: itemType\n if (!$item instanceof \\StructType\\FieldInfo) {\n throw new \\InvalidArgumentException(sprintf('The FieldInfo property can only contain items of type \\StructType\\FieldInfo, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);\n }\n $this->FieldInfo[] = $item;\n return $this;\n }", "title": "" } ]
[ { "docid": "71157fc8e60a0be8cc5e8c5eacd4fe1f", "score": "0.647331", "text": "function add_field($field, $value) {\n // sent to paypal as POST variables. If the value is already in the\n // array, it will be overwritten.\n\n $this->fields[\"$field\"] = $value;\n }", "title": "" }, { "docid": "671fdf89de1451e9c5c3221e62d3238b", "score": "0.638948", "text": "public function addItem($field) {\n\t\t$this->_cache[$field] = $this->_getValue($field);\n\t}", "title": "" }, { "docid": "8e4651c6a2073b34afb5e2ccb0956a78", "score": "0.6339674", "text": "function add_field() {}", "title": "" }, { "docid": "4dac32cdee90561384356f97cf999fe0", "score": "0.6248858", "text": "function SetFormFieldItem( $fieldname, $itemname, $value )\n {\n $field_info =& $this->_get_form_field($fieldname);\n $field_info[$itemname] = $value;\n }", "title": "" }, { "docid": "cd45fc129e7071f2151832f285ca23cd", "score": "0.6208057", "text": "protected function add_field($field, $value) {\n // sent to paypal as POST variables. If the value is already in the \n // array, it will be overwritten.\n \n $this->fields[\"$field\"] = $value;\n }", "title": "" }, { "docid": "dce72ae4949742e81c6f1edbb99f5d00", "score": "0.6153247", "text": "public function addItemField($name,$optional=FALSE) {\n\n\t\t$this->itemFields[$name] = array();\n\t\t$this->itemFields[$name]['name'] = $name;\n\t\t$this->itemFields[$name]['optional'] = $optional;\n\n\t\treturn(TRUE);\n\n\t}", "title": "" }, { "docid": "6d752092cf5086362d0542fa684dc9fa", "score": "0.6086385", "text": "public function addField($field, $value) {\n // sent to paypal as POST variables. If the value is already in the \n // array, it will be overwritten.\n\n $this->fields[\"$field\"] = $value;\n }", "title": "" }, { "docid": "2e751763e1e079e021647b8aeb7853c5", "score": "0.5983547", "text": "public function addItem($section, $item, $value);", "title": "" }, { "docid": "565e6462f2ab912cbb31a91272d2dd38", "score": "0.5964924", "text": "public function addField(FieldInfo $oField)\n {\n $this->aoFields[] = $oField;\n }", "title": "" }, { "docid": "937d9156014a41bb7dcd84f1a09eb251", "score": "0.5950753", "text": "public function setItemsValuesAdm()\n {\n $ids = array();\n foreach($this->items as $item) {\n $ids[] = $item->id;\n }\n\n $this->getItemValues($ids);\n $this->checkValues();\n\n foreach($this->items as $id=>$item) {\n foreach($this->isset_fields as $f) {\n if (!$f->published)\n continue;\n $this->items[$id]->subfields->{$f->name} = $this->findValue($item->id, $f->id);\n }\n }\n }", "title": "" }, { "docid": "f640ac37d04fe37618c0ae1b8bfd40af", "score": "0.5901731", "text": "abstract protected function addItem($item);", "title": "" }, { "docid": "5c672d3bd32697c83fd7c87b206a7d91", "score": "0.5859248", "text": "function AddField($field)\n{\n $this->_checkFieldClass($field);\n $this->Fields[$field->name] = $field;\n}", "title": "" }, { "docid": "4b74a90d17cb87c9051452f6e279f430", "score": "0.5825931", "text": "public function addItem($item) {\n\n\t\t$itemTemp = array();\n\n\t\tforeach ($this->itemFields as $I=>$field) {\n\t\t\tif ($field['optional'] === FALSE && !isset($item[$field['name']])) {\n\t\t\t\terrorHandle::newError(\"Missing Field:\".$field['name'],errorHandle::DEBUG);\n\t\t\t\treturn(FALSE);\n\t\t\t}\n\n\t\t\tif (!isset($item[$field['name']])) {\n\t\t\t\t$item[$field['name']] = \"\";\n\t\t\t}\n\n\t\t\t$itemTemp[$field['name']] = $item[$field['name']];\n\n\t\t}\n\n\t\t$this->items[] = $itemTemp;\n\n\t\treturn(TRUE);\n\n\t}", "title": "" }, { "docid": "4f63b4c44ca70d90badafb8dc55880db", "score": "0.57897043", "text": "public function add_fields( $new, $item_output, $item, $depth, $args ) {\r\n\r\n\t\tforeach( $this->options() as $field ) {\r\n\t\t\t$lvl = isset( $field['depth'] ) ? ( $field['depth'] == $depth ) : 1;\r\n\t\t\tif ( $lvl ) {\r\n\t\t\t\t$meta_key = $field['name'];\r\n\t\t\t\t$field['id'] = $meta_key;\r\n\t\t\t\t$field['name'] = 'menu-item-' . $field['name'] . '[' . $item->ID . ']';\r\n\t\t\t\t$new .= '<div class=\"wp-clearfix\"></div>' . csf_add_field( $field, get_post_meta( $item->ID, $meta_key, true ) );\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn $new;\r\n\t}", "title": "" }, { "docid": "484911bea035dfc770e72452bd59e0f8", "score": "0.57819015", "text": "function addUpdatedField($name, $value) {\n $field['name'] = $name;\n $field['value'] = $value;\n $this->_updatedFields[] = $field;\n }", "title": "" }, { "docid": "3317d9601659c07a70b61796fe978d95", "score": "0.5739585", "text": "function ExtraUserInfo_add($user) {\n\n $field_val = get_user_meta($user->ID, $this->field_name);\n\n if(is_array($field_val)) :\n\n if(empty($field_val)) :\n $field_val[0] = \"\";\n endif;\n \n $field_val = $field_val[0];\n endif;\n\n ?>\n <table class=\"form-table\">\n <tr>\n <th>\n <label for=\"<?php echo $this->field_name; ?>\">\n <?php echo $this->field_title; ?>\n </label>\n </th>\n <td>\n <input \n type=\"text\" \n id=\"<?php echo $this->field_name; ?>\"\n name=\"<?php echo $this->field_name; ?>\"\n value=\"<?php echo $field_val; ?>\"/>\n <br/>\n <span class=\"description\">\n <?php echo $this->field_description; ?>\n </span>\n </td>\n </tr>\n </table>\n\n <?php\n\n }", "title": "" }, { "docid": "c14d9009f5821d145f8b2252745b6146", "score": "0.5724803", "text": "function field_collection_item_wrapper($entity_type, $entity, $bundle, $field_name, $data){\n if(!isset($entity->language)) $entity->language = LANGUAGE_NONE;\n $field_info = field_info_instance($entity_type, $field_name, $bundle);\n $field_read = field_read_field($field_name);\n\n if(!isset($data)){\n if($field_info['required']) return services_error('Missing ' . $field_name . ' attribute');\n else return;\n }\n\n if($field_read['cardinality'] == 0) return;\n else if($field_read['cardinality'] == 1){\n $temp = array();\n if(is_array($data)){\n if(is_array(current($data))){\n $temp['value'] = isset(current($data)['value']) ? current($data)['value'] : $field_info['default_value'];\n $temp['revision_id'] = isset(current($data)['revision_id']) ? current($data['revision_id']) : NULL;\n if($field_info['required'] && !isset($temp['value'])) return services_error('Missing ' . $field_name . '->value attribute');\n }else{\n $temp['value'] = isset($data['value']) ? $data['value'] : $field_info['default_value'];\n $temp['revision_id'] = isset($data['revision_id']) ? $data['revision_id'] : NULL;\n if($field_info['required'] && !isset($temp['value'])) return services_error('Missing ' . $field_name . '->value attribute');\n }\n }else{\n $temp['value'] = isset($data) ? $data : NULL;\n if($field_info['required'] && !isset($temp['value'])) return services_error('Missing ' . $field_name . ' attribute');\n }\n $entity->{$field_name}[$entity->language][0] = $temp;\n }else{\n $count = 0;\n if(!is_array($data)){\n return services_error($field_name . ' should be array');\n }\n foreach($data as $element){\n if($field_read['cardinality'] >1 && $count >= $field_read['cardinality']){\n // return services_error($field_name . ' had cardinality: ' . $field_read['cardinality']);\n break;\n }\n $count++;\n if(is_array($element)){\n $temp = array();\n $temp['value'] = isset($element['value']) ? $element['value'] : $field_info['default_value'];\n $temp['revision_id'] = isset($element['revision_id'])? $element['revision_id'] : NULL;\n if($field_info['required'] && !isset($temp['value'])) return services_error('Missing ' . $field_name . '->value attribute');\n $entity->{$field_name}[$entity->language][] = $temp;\n }else{\n if($field_info['required'] && !isset($element)) return services_error('Missing ' . $field_name . ' attribute');\n $entity->{$field_name}[$entity->language][]['value'] = $element;\n }\n }\n }\n}", "title": "" }, { "docid": "0dd912a7e311fcff45af3acf7e81b854", "score": "0.5706879", "text": "function addField( &$db_data, $db_field, $value, $join=false, $val_quotes=\"'\"){\n\tif(is_array($value)){\n\t\t$approved_values = array();\n\t\tforeach ($value as $val) {\n\t\t\tif($val !== null && $val !== ''){\n\t\t\t\tarray_push($approved_values, $val);\n\t\t\t}\n\t\t}\n\t\t$value = ($join && is_string($join)) ? implode($join, $approved_values) : $value;\n\t}\n\tif(isset($value) && $value !== null && $value !== ''){\n\t\tarray_push( $db_data[\"fields\"], $db_field );\n\t\tarray_push( $db_data[\"values\"], $val_quotes.$value.$val_quotes );\n\t}\n}", "title": "" }, { "docid": "98de7fe905c5e546fcf49cea83e20e92", "score": "0.5689233", "text": "function globallink_insert_fc_item_fields($content_type, $parent_field_name, $field_name) {\n $fc_field_info = field_info_field($field_name);\n $fc_field_instance = field_info_instance('field_collection_item', $field_name, $parent_field_name);\n\n switch ($fc_field_info['type']) {\n case 'list_boolean':\n case 'file':\n case 'taxonomy_term_reference':\n break;\n case 'field_collection':\n db_insert('globallink_field_config')\n ->fields(array(\n 'content_type' => $content_type,\n 'entity_type' => 'field_collection_item',\n 'bundle' => $parent_field_name,\n 'field_name' => $field_name,\n 'field_type' => $fc_field_info['type'],\n 'field_label' => $fc_field_instance['label'],\n 'translatable' => 0,\n ))->execute();\n\n $fc_field_infos = field_info_instances('field_collection_item');\n\n if (isset($fc_field_infos) && isset($fc_field_infos[$field_name]) && is_array($fc_field_infos[$field_name])) {\n $fc_items = array_keys($fc_field_infos[$field_name]);\n\n foreach ($fc_items as $fc_item) {\n globallink_insert_fc_item_fields($content_type, $field_name, $fc_item);\n }\n }\n\n break;\n default:\n $translatable = 1;\n\n db_insert('globallink_field_config')\n ->fields(array(\n 'content_type' => $content_type,\n 'entity_type' => 'field_collection_item',\n 'bundle' => $parent_field_name,\n 'field_name' => $field_name,\n 'field_type' => $fc_field_info['type'],\n 'field_label' => $fc_field_instance['label'],\n 'translatable' => $translatable,\n ))->execute();\n }\n}", "title": "" }, { "docid": "5be1eb1e106e9f2af74e2e65a593e7d8", "score": "0.5683335", "text": "public function addField($field_id, array $field) {\n $this->metafields[$field_id] = $field;\n }", "title": "" }, { "docid": "67159e164591cf37187376cf43aeeb2f", "score": "0.56685495", "text": "public function addField($field) {\n\t\t$this->fields[] = $field;\n\t}", "title": "" }, { "docid": "8f3708ee3dc036c83722a02dc5b10e41", "score": "0.5665832", "text": "public function saveItemField($id, $field_name, $field_value) {\n // check if the field is included in the items table or is external.\n $included_fields = array(\"name\", \"slug\");\n \n if( in_array($field_name, $included_fields) ) {\n return $this->saveIncludedItemField($id, $field_name, $field_value);\n } else {\n return $this->saveExternalItemField($id, $field_name, $field_value);\n }\n }", "title": "" }, { "docid": "06d5190a2f3c38fc759f7c66c3fa8349", "score": "0.56633633", "text": "public function setItemsValues()\n {\n $ids = array();\n foreach($this->items as $item) {\n $ids[] = $item->event_id;\n }\n\n $this->getItemValues($ids);\n $this->checkValues();\n foreach($this->items as $id=>$item) {\n foreach($this->isset_fields as $f) {\n if (!$f->published)\n continue;\n $this->items[$id]->subfields->{$f->name} = $this->findValue($item->event_id, $f->id);\n }\n }\n }", "title": "" }, { "docid": "9f5d8ab813c3f2584f8f2a0751ecfd2a", "score": "0.5661857", "text": "function add_item($name, $value) {\n if (is_string($value)) {\n $this->add_string($name, $value);\n }\n elseif (is_object($value) || is_array($value)) {\n $this->add_element($name, $value);\n }\n }", "title": "" }, { "docid": "57c3f811e16186408e5b1d04c585d2ff", "score": "0.56479263", "text": "public function addItems(\\RO\\Cmd\\ItemInfo $value){\n return $this->_add(4, $value);\n }", "title": "" }, { "docid": "b02a347744b0fc3172323d1cd392c698", "score": "0.5642753", "text": "public function add_info( $info, $new_item = false ) {\n\t\tif ( $new_item || 0 === count( $this->infos ) ) {\n\t\t\t$this->infos[] = $info;\n\t\t} else {\n\t\t\t$this->infos[ count( $this->infos ) - 1 ] .= '<br />' . $info;\n\t\t}\n\t}", "title": "" }, { "docid": "c0a1f1cad8ac6c6ce62f3fcd0e6a6e42", "score": "0.5629537", "text": "public function add ($item);", "title": "" }, { "docid": "8c74b7eb5c32f3360f28330e2b5b4a9b", "score": "0.55934846", "text": "public function fieldItem($fieldName, $idx = 0, $lang = LANGUAGE_NONE);", "title": "" }, { "docid": "74eb4ed025c53a5b092bfc5047957c46", "score": "0.5563077", "text": "public function addFields(\\google\\spanner\\v1\\StructType\\Field $value){\n return $this->_add(1, $value);\n }", "title": "" }, { "docid": "778ee561e64c5be36668b854a801e171", "score": "0.5562645", "text": "public function addItem(Item $item) {}", "title": "" }, { "docid": "79237ede989fdad5c4e31a488f7cbafd", "score": "0.5516595", "text": "public function add(mixed $item): void;", "title": "" }, { "docid": "6e5b07b910092a1472bd74d5af5af2e0", "score": "0.5500144", "text": "abstract public function _fieldData();", "title": "" }, { "docid": "0df11bbb65ea2f5d4d9e33263366667d", "score": "0.5498143", "text": "public function add( $key=null ) {\r\n\t\t\t$item = clone $this->_type;\r\n\t\t\t$key = empty( $key ) ? count( $this->fields ) : $key;\r\n\t\t\t$name = $this->getAttribute( 'name' ) . '[' . $key . ']';\r\n\t\t\t\r\n\t\t\t$item->setAttribute( 'name', $name );\r\n\t\t\t$item->setAttribute( 'id', $name );\r\n\t\t\t\r\n\t\t\tif( isset( $this->_form ) ) {\r\n\t\t\t\t$item->setForm( $this->_form );\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$this->fields[ $key ] = $item;\r\n\t\t\t\r\n\t\t\treturn $item;\r\n\t\t}", "title": "" }, { "docid": "78128c97e80f679637ad8b4a3305bdd4", "score": "0.5492413", "text": "public function addItem(Item $item);", "title": "" }, { "docid": "aa11c8e603e35ea0d0cc3288c55f0a6e", "score": "0.548516", "text": "private function setItemInfo($Item, $ItemInfo){\n $Item->name = $ItemInfo['name'];\n $Item->code = $ItemInfo['code'];\n $Item->image = $ItemInfo['image'];\n $Item->unit_id = $ItemInfo['unit_id'];\n $Item->itemcategory_id = $ItemInfo['itemcategory_id'];\n $Item->lead_time = $ItemInfo['lead_time'];\n $Item->attach_file = $ItemInfo['attach_file'];\n $Item->remark = $ItemInfo['remark'];\n \treturn $Item;\n }", "title": "" }, { "docid": "e91f6f8436dfda1e2c6c5fe6d65f4733", "score": "0.5462577", "text": "function acf_register_field_type_info( $info ) {\n}", "title": "" }, { "docid": "8eb5735459e0a773af34140da3dc7dba", "score": "0.54623467", "text": "public function addField($name, $value)\n {\n $this->properties[$name][\"value\"] = $value;\n\n }", "title": "" }, { "docid": "eabc11dec9c9ee077fe374ff524b1427", "score": "0.54565", "text": "public function addField($asyncRecordFinderField){\r\n\t\t$this->fields[count($this->fields)] = $asyncRecordFinderField;\r\n\t}", "title": "" }, { "docid": "4984a9df7e1900ddbbf2a5aecaf586c2", "score": "0.5444728", "text": "function getCoreFieldValue($field, $version = 0, $old_item=null)\n\t{\n\t\tif ($old_item) {\n\t\t\t$item = $old_item;\n\t\t} else if (isset($this->_record)) {\n\t\t\t$item = $this->_record;\n\t\t} else {\n\t\t\t$item = $this->getItem(); // This fuction calls the load item function for existing item and init item function in the case of new item\n\t\t}\n\n\t\tswitch ($field->field_type) {\n\t\t\tcase 'created': // created\n\t\t\t$field_value = array($item->created);\n\t\t\tbreak;\n\n\t\t\tcase 'createdby': // created by\n\t\t\t$field_value = array($item->created_by);\n\t\t\tbreak;\n\n\t\t\tcase 'modified': // modified\n\t\t\t$field_value = array($item->modified);\n\t\t\tbreak;\n\n\t\t\tcase 'modifiedby': // modified by\n\t\t\t$field_value = array($item->modified_by);\n\t\t\tbreak;\n\n\t\t\tcase 'title': // title\n\t\t\t$field_value = array($item->title);\n\t\t\tbreak;\n\n\t\t\tcase 'hits': // hits\n\t\t\t$field_value = array($item->hits);\n\t\t\tbreak;\n\n\t\t\tcase 'type': // document type\n\t\t\t$field_value = array($item->type_id);\n\t\t\tbreak;\n\n\t\t\tcase 'version': // version\n\t\t\t$field_value = array($item->version);\n\t\t\tbreak;\n\n\t\t\tcase 'state': // publication state\n\t\t\t$field_value = array($item->state);\n\t\t\tbreak;\n\n\t\t\tcase 'voting': // voting button // remove dummy value in next version for legacy purposes\n\t\t\t$field_value = array('button'); // dummy value to force display\n\t\t\tbreak;\n\n\t\t\tcase 'favourites': // favourites button // remove dummy value in next version for legacy purposes\n\t\t\t$field_value = array('button'); // dummy value to force display\n\t\t\tbreak;\n\n\t\t\tcase 'score': // voting score // remove dummy value in next version for legacy purposes\n\t\t\t$field_value = array('button'); // dummy value to force display\n\t\t\tbreak;\n\n\t\t\tcase 'categories': // assigned categories\n\t\t\t$field_value = isset($item->categories) ? $item->categories : array();\n\t\t\tbreak;\n\n\t\t\tcase 'tags': // assigned tags\n\t\t\t$field_value = isset($item->tags) ? $item->tags : array();\n\t\t\tbreak;\n\n\t\t\tcase 'maintext': // main text\n\t\t\t$value = StringHelper::strlen( StringHelper::trim($item->fulltext ?? '') ) ? $item->introtext . \"<hr id=\\\"system-readmore\\\" />\" . $item->fulltext : $item->introtext;\n\t\t\t$field_value = array($value);\n\t\t\tbreak;\n\t\t}\n\n\t\treturn $field_value;\n\t}", "title": "" }, { "docid": "cdd56f2468cd756b6799aefe982ca852", "score": "0.54406244", "text": "public static function add_field(array &$data, int $att_index, string $title, string $value, bool $short=true) {\r\n if (empty($data[\"attachments\"][$att_index][\"fields\"])) {\r\n $key = 0;\r\n } else {\r\n $key = count($data[\"attachments\"][$att_index][\"fields\"]);\r\n }\r\n $data[\"attachments\"][$att_index][\"fields\"][$key][\"title\"] = $title;\r\n $data[\"attachments\"][$att_index][\"fields\"][$key][\"value\"] = $value;\r\n $data[\"attachments\"][$att_index][\"fields\"][$key][\"short\"] = $short;\r\n }", "title": "" }, { "docid": "2cf7578921b01f37c4e5f1e943212c2c", "score": "0.5403178", "text": "public function saveFieldEditor($item, $value, $key)\r\n {\r\n // This can be done the same is text\r\n $this->saveFieldText($item, $value, $key);\r\n }", "title": "" }, { "docid": "9309c30155d3798e4a448f07fce720ae", "score": "0.5402186", "text": "function setEntityFieldValue($f_name, $attr_name, $attr_value)\n{\n global $entity;\n if ($entity != \"\") {\n for ($i=0; $i < count($entity[\"fields\"]); $i++) {\n $f = $entity[\"fields\"][$i];\n if ($f[\"name\"] == $f_name) {\n $f[$attr_name] = $attr_value;\n $entity[\"fields\"][$i] = $f;\n }\n }\n }\n}", "title": "" }, { "docid": "719bbbec30b6600ebb5ea2f42d6d236b", "score": "0.5401125", "text": "public function addField(Field $field): void\n {\n array_push($this->fields, $field);\n }", "title": "" }, { "docid": "9ccdbda76156f1295330e2d3bcb1a0c2", "score": "0.5395542", "text": "public function addField(Field $field)\n {\n $this->fields[] = $field;\n }", "title": "" }, { "docid": "0f46025b0f0dbedeca9df20cb2d2d5d9", "score": "0.5394875", "text": "public function addToInfoEnlevements(\\StructType\\InfoEnlevement $item): self\n {\n // validation for constraint: itemType\n if (!$item instanceof \\StructType\\InfoEnlevement) {\n throw new InvalidArgumentException(sprintf('The infoEnlevements property can only contain items of type \\StructType\\InfoEnlevement, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);\n }\n $this->infoEnlevements[] = $item;\n \n return $this;\n }", "title": "" }, { "docid": "61e0aa8d3ca6260d318ce18dd86826e6", "score": "0.5391351", "text": "public abstract function createField(array $fieldInfo) : \\Howl\\Core\\DBField;", "title": "" }, { "docid": "50371d02d542037a99598dddd5e14cfc", "score": "0.53898054", "text": "public function add($item)\n {\n if (!\\Mu4ddi3\\Compensa\\Webservice\\EnumType\\InsuranceForm::valueIsValid($item)) {\n throw new \\InvalidArgumentException(sprintf('Value \"%s\" is invalid, please use one of: %s', $item, implode(', ', \\Mu4ddi3\\Compensa\\Webservice\\EnumType\\InsuranceForm::getValidValues())), __LINE__);\n }\n return parent::add($item);\n }", "title": "" }, { "docid": "0773b80e0035604deda61650f59bcf96", "score": "0.53811044", "text": "public function addFields(\\google\\protobuf\\Field $value){\n return $this->_add(2, $value);\n }", "title": "" }, { "docid": "159f2ff8aa69ee03bbdc55c8b27334fe", "score": "0.5377835", "text": "public function addToCustomFields(\\StructType\\CustomField $item)\n {\n // validation for constraint: itemType\n if (!$item instanceof \\StructType\\CustomField) {\n throw new \\InvalidArgumentException(sprintf('The customFields property can only contain items of \\StructType\\CustomField, \"%s\" given', is_object($item) ? get_class($item) : gettype($item)), __LINE__);\n }\n $this->customFields[] = $item;\n return $this;\n }", "title": "" }, { "docid": "159f2ff8aa69ee03bbdc55c8b27334fe", "score": "0.5377835", "text": "public function addToCustomFields(\\StructType\\CustomField $item)\n {\n // validation for constraint: itemType\n if (!$item instanceof \\StructType\\CustomField) {\n throw new \\InvalidArgumentException(sprintf('The customFields property can only contain items of \\StructType\\CustomField, \"%s\" given', is_object($item) ? get_class($item) : gettype($item)), __LINE__);\n }\n $this->customFields[] = $item;\n return $this;\n }", "title": "" }, { "docid": "f79ea231e5028115c35e7e0ead5e7991", "score": "0.5375371", "text": "public function saveFieldText($item, $value, $key)\r\n {\r\n // Check if this field is optional, don't save if it's empty / mandatory\r\n if (strlen($value) == 0 && isset($item['typeConfig']['optional']) && !$item['typeConfig']['optional']) {\r\n $this->errors[] = 'Das Feld \"' . $item['title'] . '\" muss einen Wert beinhalten. Der leere Inhalt wurde nicht gespeichert.';\r\n } else {\r\n // The value can be saved\r\n $this->config[$key] = $value;\r\n }\r\n }", "title": "" }, { "docid": "176f3f7444ba4338b595facc1f86a49c", "score": "0.53750175", "text": "function setItem($name, $value);", "title": "" }, { "docid": "ef2421d3670eb40f4c1d3992f652066d", "score": "0.5373024", "text": "function feed_item_field_attach_submit($form, &$form_state) {\r\n $feed =& $form_state['#feed'];\r\n \r\n if (isset($feed->fid)) {\r\n $feed_fields = feed_load_fields($feed, TRUE);\r\n $feed_fields_stack = array();\r\n \r\n if (!empty($feed_fields)) {\r\n foreach ($feed_fields as $feed_field) {\r\n if (isset($form_state['values']['feed_item_field']['item-fields'][$feed_field->ffid])) {\r\n $values = $form_state['values']['feed_item_field']['item-fields'][$feed_field->ffid];\r\n \r\n if (isset($values['weight'])) {\r\n $feed_field->data['weight'] = $values['weight'];\r\n }\r\n if (isset($feed_fields[$values['parent']])) {\r\n $feed_field->pffid = $values['parent']; // @todo write validation\r\n }\r\n elseif (empty($values['parent'])) {\r\n $feed_field->pffid = 0;\r\n }\r\n $feed_fields_stack[$feed_field->ffid] = $feed_field;\r\n }\r\n }\r\n }\r\n }\r\n \r\n if (!empty($form_state['values']['feed_item_field']['add-item-field']['tag'])) {\r\n $feed_field_values = $form_state['values']['feed_item_field']['add-item-field'];\r\n $feed_field = feed_field_defaults();\r\n \r\n $info = feed_field_type_info($feed_field_values['type']);\r\n\r\n if (isset($feed_fields[$feed_field_values['parent']])) {\r\n $feed_field->pffid = $feed_field_values['parent']; // @todo write validation\r\n }\r\n $feed_field->name = $feed_field_values['name'];\r\n $feed_field->tag = $feed_field_values['tag'];\r\n $feed_field->type = $feed_field_values['type'];\r\n $feed_field->module = $info['module'];\r\n $feed_field->fid = $feed->fid;\r\n \r\n $feed_fields_stack['add-item-field'] = $feed_field;\r\n }\r\n \r\n if (!empty($feed_fields_stack)) {\r\n $status = feed_fields_save($feed_fields_stack, $feed, TRUE);\r\n \r\n if ($status && !empty($feed_fields_stack['add-item-field'])) {\r\n $form_state['redirect'] = \"feed/{$feed->fid}/fields/feed-items/{$ffid}\";\r\n }\r\n }\r\n}", "title": "" }, { "docid": "18819d1e4784f73c06a1ed2f96942e35", "score": "0.53613144", "text": "public function addItem() {\n //echo \"in test item\";\n $itemEle = $this->_xml->createElement('item');\n $itemEle = $this->_type->appendChild($itemEle);\n //$field = $this->xml->createElement($name, $value);\n //$field = $itemEle->appendChild($field);\n\n $keys = array_keys($this->_elements);\n foreach($keys as $key) {\n if($key == \"variantImage\") {\n if(is_array($this->_elements[\"variantImage\"])) {\n foreach($this->_elements[\"variantImage\"] as $img) {\n $field = $this->createElement2($key, $img);\n $field = $itemEle->appendChild($field);\n }\n }else{\n $field = $this->createElement2($key, $this->_elements[\"variantImage\"]);\n $field = $itemEle->appendChild($field);\n }\n\n\n }\n else {\n $field = $this->createElement1($key);\n $field->appendChild($this->_xml->createTextNode($this->_elements[$key]));\n $field = $itemEle->appendChild($field);\n }\n }\n\n //var_dump($this->xml);\n //var_dump($this->xml->saveXML());\n }", "title": "" }, { "docid": "98cc59b256b789ef4cb5c431af06c847", "score": "0.5346505", "text": "protected function storeNewFieldData( VersionInfo $versionInfo, Field $field )\n {\n $connection = $this->getConnection();\n\n $insertQuery = $connection->createInsertQuery();\n $insertQuery->insertInto( $connection->quoteTable( 'ezxgis_position' ) )\n ->set(\n $connection->quoteColumn( 'latitude' ),\n $insertQuery->bindValue( $field->value->externalData['latitude'] )\n )->set(\n $connection->quoteColumn( 'longitude' ),\n $insertQuery->bindValue( $field->value->externalData['longitude'] )\n )->set(\n $connection->quoteColumn( 'street' ),\n $insertQuery->bindValue( $field->value->externalData['street'] )\n )->set(\n $connection->quoteColumn( 'zip' ),\n $insertQuery->bindValue( $field->value->externalData['zip'] )\n )->set(\n $connection->quoteColumn( 'district' ),\n $insertQuery->bindValue( $field->value->externalData['district'] )\n )->set(\n $connection->quoteColumn( 'city' ),\n $insertQuery->bindValue( $field->value->externalData['city'] )\n )->set(\n $connection->quoteColumn( 'state' ),\n $insertQuery->bindValue( $field->value->externalData['state'] )\n )->set(\n $connection->quoteColumn( 'country' ),\n $insertQuery->bindValue( $field->value->externalData['country'] )\n )->set(\n $connection->quoteColumn( 'contentobject_attribute_id' ),\n $insertQuery->bindValue( $field->id, null, \\PDO::PARAM_INT )\n )->set(\n $connection->quoteColumn( 'contentobject_attribute_version' ),\n $insertQuery->bindValue( $versionInfo->versionNo, null, \\PDO::PARAM_INT )\n );\n\n $insertQuery->prepare()->execute();\n }", "title": "" }, { "docid": "9b167d8eb3862935cb381498b601b32e", "score": "0.53455514", "text": "protected function addFieldItems(FormBuilderInterface $builder)\n {\n $builder->add(\n 'items',\n CollectionType::class,\n [\n 'entry_type' => TextType::class,\n 'allow_add' => true,\n 'allow_delete' => true,\n 'by_reference' => false,\n 'required' => false,\n 'label' => 'Value',\n 'attr' => [\n 'class' => 'action-field-values-container',\n ],\n 'entry_options' => [\n 'attr' => [\n 'class' => 'action-field-values-value',\n ],\n 'required' => false,\n 'label' => false,\n ],\n ]\n );\n }", "title": "" }, { "docid": "ae50e3e2218b71e8ad2e24245ececd63", "score": "0.5341999", "text": "public abstract function add_raw_value( $value );", "title": "" }, { "docid": "32e0421ab00deb050af96961ee321c5f", "score": "0.5340229", "text": "abstract protected function addItems();", "title": "" }, { "docid": "cdbaa5d03342b8e743ef44567711106a", "score": "0.5336813", "text": "private function saveExternalItemField($id, $field_name, $field_value) {\n if( $this->getExternalField($id, $field_name) ) {\n $this->db->modify(self::QUERY_UPDATE_EXTERNAL_FIELD, array(\n $field_value, $id, $field_name\n ));\n return 1;\n } else {\n $this->db->insert(self::QUERY_INSERT_EXTERNAL_FIELD, array(\n $id, $field_name, $field_value\n ));\n return 1;\n }\n }", "title": "" }, { "docid": "1736cd8df0afad6afac1fcae473976ce", "score": "0.5336683", "text": "private function register_field( $option, $key, $itemID, $data ) {\n\t\tif ( is_string( $data ) )\n\t\t\treturn; // skip string variables\n\t\tif ( ! isset( $data['render'] ) )\n\t\t\treturn; // skip variables without render data\n\t\tif ( $data['render'] === 'skip' )\n\t\t\treturn; // skip variable when needed\n\t\tif ( $data['render'] === 'array' ) { /*\n\t\t\t$count = max( count( $data['default'] ), count( $this->form_opts[ $key ][ $itemID ] ) );\n\t\t\tfor ( $i = 0; $i < $count; $i++ ) {\n\t\t\t\t$label = \"<label for='$itemID'>{$data['label']} \".($i+1).\"</label>\";\n\t\t\t\t$args = array( 'key' => $key, 'item' => $itemID, 'num' => $i );\n#\t\t\t\tif ( $i + 1 === $count ) { $args['add'] = true; }\n\t\t\t\tadd_settings_field( \"{$item}_$i\", $label, array( $this, $this->options ), $this->slug, $current, $args );\n\t\t\t} //*/\n\t\t\t$this->log( 'ALERT: data[render] = array', $data );\n\t\t} else {\n\t\t\t$label = $this->field_label( $itemID, $data );\n\t\t\t$args = [ 'key' => $key, 'item' => $itemID ];\n\t\t\tadd_settings_field( $itemID, $label, [ $this, $this->options ], $option, $option, $args );\n\t\t}\n\t}", "title": "" }, { "docid": "a01e513d0270940ba2507032796aa090", "score": "0.53320646", "text": "function AddItem($item) {\r\n\t\t$this->ItemData[] = $item;\r\n\t}", "title": "" }, { "docid": "c3b2f17acce31c723e6e11d2fad5335a", "score": "0.53291297", "text": "public function addInfo ($name, $value) {\n $this->_info[$name] = $value;\n }", "title": "" }, { "docid": "79463667ca422243973c6d630323fef6", "score": "0.5328287", "text": "public function item_custom_fields_to_form() {\n // 1. special management for fields equipped with \"free\" checkbox\n // nothing to do: they don't exist in this plugin\n\n // 2. special management for composite fields\n // nothing to do: they don't exist in this plugin\n\n // 3. special management for defaultvalue\n // nothing to do: defaultvalue doesn't need any further care\n\n // 4. special management for autofill contents\n $referencearray = array(''); // <-- take care, the first element is already on board\n for ($i = 1; $i <= SURVEYPROFIELD_AUTOFILL_CONTENTELEMENT_COUNT; $i++) {\n $referencearray[] = constant('SURVEYPROFIELD_AUTOFILL_CONTENTELEMENT'.sprintf('%02d', $i));\n }\n\n $items = array();\n for ($i = 1; $i < 6; $i++) {\n $index = sprintf('%02d', $i);\n $fieldname = 'element'.$index.'_select';\n if (in_array($this->{'element'.$index}, $referencearray)) {\n $this->{$fieldname} = $this->{'element'.$index};\n } else {\n $constantname = 'SURVEYPROFIELD_AUTOFILL_CONTENTELEMENT'.SURVEYPROFIELD_AUTOFILL_CONTENTELEMENT_COUNT;\n $this->{$fieldname} = constant($constantname);\n $fieldname = 'element'.$index.'_text';\n $this->{$fieldname} = $this->{'element'.$index};\n }\n }\n }", "title": "" }, { "docid": "d7d6c0625d00d1e7db7cb1ca00956a0a", "score": "0.532779", "text": "private function addValue($field, $value, $arrayKey)\n {\n $name = ':'. $arrayKey . $field;\n\n $this->names[$arrayKey][$field] = $name;\n $this->parameters[$arrayKey][$field] = $value;\n }", "title": "" }, { "docid": "db50f4a4cebdc2eebc192fd34db5c45d", "score": "0.53248227", "text": "public function add($item)\n\t{\n\t\t$this->data->addLast($item);\n\t}", "title": "" }, { "docid": "7ccabdf82cece12ac05ee44d17a500fd", "score": "0.532143", "text": "protected function add_field_values( $field ) {\n\t\t$atts = array(\n\t\t\t'exclude_fields' => $this->exclude_fields,\n\t\t);\n\n\t\t$this->field_values[ $field->id ] = new FrmProFieldValue( $field, $this->entry, $atts );\n\t}", "title": "" }, { "docid": "da43aca265ed635ed15f469c40de262a", "score": "0.531801", "text": "public function addField(Field $field)\n {\n $this->fields[$field->getName()] = $field;\n }", "title": "" }, { "docid": "9e1226c943159b7f86c702bdd3fed42d", "score": "0.53149456", "text": "public function item_custom_fields_to_form() {\n global $surveypro;\n\n // 1. special management for fields equipped with \"free\" checkbox\n // nothing to do: they don't exist in this plugin\n\n // 2. special management for composite fields\n $fieldlist = $this->item_composite_fields();\n foreach ($fieldlist as $field) {\n if (!isset($this->{$field})) {\n switch ($field) {\n case 'defaultvalue':\n continue 2; // it may be; continues switch and foreach too\n case 'lowerbound':\n $this->{$field} = $this->item_datetime_to_unix_time($surveypro->startyear, 1, 1, 0, 0);\n break;\n case 'upperbound':\n $this->{$field} = $this->item_datetime_to_unix_time($surveypro->stopyear, 12, 31, 23, 59);\n break;\n }\n }\n $datetimearray = $this->item_split_unix_time($this->{$field});\n $this->{$field.'_year'} = $datetimearray['year'];\n $this->{$field.'_month'} = $datetimearray['mon'];\n $this->{$field.'_day'} = $datetimearray['mday'];\n $this->{$field.'_hour'} = $datetimearray['hours'];\n $this->{$field.'_minute'} = $datetimearray['minutes'];\n }\n\n // 3. special management for defaultvalue\n // nothing to do: defaultvalue doesn't need any further care\n }", "title": "" }, { "docid": "088b2386594a27c02b463bb0c672127c", "score": "0.531433", "text": "public function AddFields ($fields);", "title": "" }, { "docid": "8783cea273b5b9876584b02dc61d26ce", "score": "0.53105146", "text": "private function add_item_values($item, $collection_id) {\n $propertyModel = new PropertyModel;\n $category_root_id = $this->get_category_root_of($collection_id);\n $all_properties_id = array_unique($propertyModel->get_parent_properties($category_root_id, [], $category_root_id));\n $this->set_common_field_values($item->ID, 'title', $item->post_title);\n $this->set_common_field_values($item->ID, 'description', $item->post_content);\n $this->set_common_field_values($item->ID, 'object_from', get_post_meta($item->ID, 'socialdb_object_from', true));\n $this->set_common_field_values($item->ID, 'object_source', get_post_meta($item->ID, 'socialdb_object_dc_source', true));\n $this->set_common_field_values($item->ID, 'object_type', get_post_meta($item->ID, 'socialdb_object_dc_type', true));\n $this->set_common_field_values($item->ID, 'object_content', get_post_meta($item->ID, 'socialdb_object_content', true));\n if (is_array($all_properties_id)) {\n $this->add_item_properties($item->ID, $all_properties_id);\n }\n // buscando as categorias do item\n $categories = wp_get_object_terms($item->ID, 'socialdb_category_type');\n if(is_array($categories)){\n foreach ($categories as $category):\n $category_id = $category->term_id;\n $property_id = $this->get_category_property($category_id, $collection_id);\n $this->concatenate_commom_field_value($item->ID, \"socialdb_propertyterm_$property_id\",$category_id);\n endforeach;\n }\n// buscando as tags do item\n $tags = wp_get_object_terms($item->ID, 'socialdb_tag_type');\n if(is_array($tags)){\n foreach ($tags as $tag):\n $tag_id = $tag->term_id;\n $this->concatenate_commom_field_value($item->ID, \"socialdb_propertyterm_tag\",$tag_id);\n endforeach;\n }\n }", "title": "" }, { "docid": "68dfa601bdb2b78832861057c15cff3e", "score": "0.53071404", "text": "public function saveFieldEditor($item)\n {\n // This can be done the same is text\n $this->saveFieldText($item);\n }", "title": "" }, { "docid": "8dcafe256e853ee48e99171090831a21", "score": "0.53030443", "text": "public function reduceItemSearchableFields(Item $item)\n {\n $searchableMetadata = $item->getSearchableMetadata();\n foreach ($this->fields as $field => $config) {\n if (!isset($searchableMetadata[$field])) {\n continue;\n }\n\n $searchableMetadata[$field] = $this->reduceValue(\n $searchableMetadata[$field],\n $config\n );\n }\n\n $item->setSearchableMetadata($searchableMetadata);\n }", "title": "" }, { "docid": "9d3d5601a8f170239d9b18a64ed22b6d", "score": "0.52991366", "text": "public function addItem($item)\n {\n $this->_formItems[$item['name']] = $item;\n \n return TRUE;\n }", "title": "" }, { "docid": "6cd9d467322a70847180b5f5906ef55c", "score": "0.52987146", "text": "public function addFieldDefinition($id_item, $field_name, $field_type, $field_options, $inheritance) {\n $rs = $this->db->insert(self::QUERY_ADD_FIELD_DEFINITION, array(\n $id_item, $field_name, $field_type, $field_options, $inheritance\n ));\n return 1;\n }", "title": "" }, { "docid": "cc5e26bb24aaecf9cea48d00ffcd2724", "score": "0.5289361", "text": "function onAfterSaveField( &$field, &$post, &$file, &$item ) {\r\n\t}", "title": "" }, { "docid": "c893be398140936c0895aeb2bd9cbf2a", "score": "0.5286846", "text": "public function pushData(String $field, $value)\n {\n $this->data[$field] = $value;\n }", "title": "" }, { "docid": "3be270ccc0c6365a33cec654b7b6b313", "score": "0.5278142", "text": "function feed_item_field_attach(&$form, &$form_state) {\r\n $feed = $form_state['#feed'];\r\n \r\n $form['feed_item_field'] = array();\r\n $form['feed_item_field']['#type'] = 'feed_item_field_attach';\r\n $form['feed_item_field']['#tree'] = TRUE;\r\n \r\n if (!empty($feed->fid)) {\r\n $feed_fields = feed_load_fields($feed, TRUE);\r\n feed_field_build_tree($feed_fields);\r\n \r\n foreach ($feed_fields as $feed_field) {\r\n if (!isset($form['feed_item_field']['item-fields'])) {\r\n $form['feed_item_field']['item-fields'] = array('#tree' => TRUE);\r\n }\r\n \r\n $form['feed_item_field']['item-fields'][$feed_field->ffid] = array(\r\n '#tree' => TRUE, \r\n '#depth' => $feed_field->depth,\r\n '#weight' => isset($feed_field->data['weight']) ? $feed_field->data['weight'] : 0,\r\n );\r\n \r\n $form['feed_item_field']['item-fields'][$feed_field->ffid]['id'] = array(\r\n '#type' => 'hidden',\r\n '#value' => !empty($feed_field->ffid) ? $feed_field->ffid : NULL,\r\n '#attributes' => array(\r\n 'class' => array('item-field-id'),\r\n ),\r\n );\r\n $form['feed_item_field']['item-fields'][$feed_field->ffid]['name'] = array(\r\n '#type' => 'markup',\r\n '#markup' => !empty($feed_field->name) ? $feed_field->name : 'No Label',\r\n '#attributes' => array('class' => array('item-field-name')),\r\n '#title_display' => 'invisible',\r\n '#title' => t('Label'),\r\n );\r\n $form['feed_item_field']['item-fields'][$feed_field->ffid]['weight'] = array(\r\n '#type' => 'weight',\r\n '#delta' => 50,\r\n '#default_value' => isset($feed_field->data['weight']) ? $feed_field->data['weight'] : 0,\r\n '#title_display' => 'invisible',\r\n '#title' => t('Weight for field'),\r\n '#attributes' => array('class' => array('item-field-weight')),\r\n );\r\n $form['feed_item_field']['item-fields'][$feed_field->ffid]['parent'] = array(\r\n '#type' => 'hidden',\r\n '#default_value' => !empty($feed_field->pffid) ? $feed_field->pffid : NULL,\r\n '#attributes' => array(\r\n 'class' => array('item-field-parent'),\r\n ),\r\n );\r\n $form['feed_item_field']['item-fields'][$feed_field->ffid]['tag'] = array(\r\n '#type' => 'hidden',\r\n '#prefix' => !empty($feed_field->tag) ? $feed_field->tag : 'No Tag',\r\n '#value' => !empty($feed_field->tag) ? $feed_field->tag : '',\r\n '#attributes' => array('class' => array('item-field-machine-name')),\r\n );\r\n $form['feed_item_field']['item-fields'][$feed_field->ffid]['type'] = array(\r\n '#type' => 'markup',\r\n '#markup' => !empty($feed_field->type) ? $feed_field->type : '',\r\n );\r\n $form['feed_item_field']['item-fields'][$feed_field->ffid]['settings'] = array(\r\n '#type' => 'link',\r\n '#title' => t('Settings'),\r\n '#href' => \"feed/{$feed->fid}/fields/{$feed_field->ffid}\",\r\n '#options' => array('attributes' => array('title' => t('Edit feed field settings.'))),\r\n );\r\n }\r\n }\r\n \r\n // Add New field attribute.\r\n $form['feed_item_field']['add-item-field'] = array('#tree' => TRUE);\r\n $form['feed_item_field']['add-item-field']['name'] = array(\r\n '#type' => 'textfield',\r\n '#title' => t('New field label'),\r\n '#title_display' => 'invisible',\r\n '#size' => 15,\r\n '#description' => t('Feed item field label'),\r\n );\r\n $form['feed_item_field']['add-item-field']['weight'] = array(\r\n '#type' => 'weight',\r\n '#delta' => 50,\r\n '#default_value' => 0,\r\n '#title_display' => 'invisible',\r\n '#title' => t('Weight for new field'),\r\n '#description' => t('Weight'),\r\n '#attributes' => array(\r\n 'class' => array('item-field-weight'),\r\n ),\r\n );\r\n $form['feed_item_field']['add-item-field']['parent'] = array(\r\n '#type' => 'hidden',\r\n '#default_value' => '',\r\n '#title_display' => 'invisible',\r\n '#attributes' => array(\r\n 'class' => array('item-field-parent'),\r\n ),\r\n );\r\n $form['feed_item_field']['add-item-field']['tag'] = array(\r\n '#type' => 'textfield',\r\n '#title' => t('New field tag name'),\r\n '#title_display' => 'invisible',\r\n '#description' => t('Tag of this field'),\r\n );\r\n $form['feed_item_field']['add-item-field']['type'] = array(\r\n '#type' => 'select',\r\n '#title' => t('Type of new field'),\r\n '#title_display' => 'invisible',\r\n '#options' => feed_field_type_options(),\r\n '#empty_option' => t('- Select a type -'),\r\n '#description' => t('Type of field.'),\r\n '#attributes' => array('class' => array('item-field-type')),\r\n );\r\n}", "title": "" }, { "docid": "6263696f3c6ca3cd257aaf11bd7fc9fb", "score": "0.5273258", "text": "public function add_fields_menu( $item ) {\n\t\t$menu_id = $item->ID;\n\t\t$settings = $this->get_settings( $menu_id );\n\n\t\treturn Thim_Template_Helper::template( 'mega-menu/extra-fields.php', array(\n\t\t\t'$menu_id' => $menu_id,\n\t\t\t'$settings' => $settings,\n\t\t), false );\n\t}", "title": "" }, { "docid": "1de29f6e4a4a45e7f96cccd90e5be089", "score": "0.52709144", "text": "public function saveFieldDropdown($item)\n {\n $value = $_POST[$item['id']];\n\n // See if the value exists in the possible dropdown values\n if (isset($item['config']['values'][$value])) {\n update_option($item['id'], $value);\n } else {\n $this->errors[] = 'Die Auswahl von ' . $item['title'] . ' ist ungültig und wurde nicht gespeichert.';\n }\n }", "title": "" }, { "docid": "985f3ebced9c99aaf8a7b53884a5122e", "score": "0.52707285", "text": "public function add($key, $item = null);", "title": "" }, { "docid": "f9ea1c3b0b99469881b1500a32d05988", "score": "0.52656585", "text": "public function add($item): self\n {\n // validation for constraint: itemType\n if (!$item instanceof \\StructType\\EwsPathToExtendedFieldType) {\n throw new InvalidArgumentException(sprintf('The ExtendedFieldURI property can only contain items of type \\StructType\\EwsPathToExtendedFieldType, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);\n }\n return parent::add($item);\n }", "title": "" }, { "docid": "a27d7c2d02ec0665cfb26c083cf89a33", "score": "0.52645487", "text": "public function item_custom_fields_to_form() {\n // 1. Special management for composite fields.\n // Nothing to do: they don't exist in this plugin.\n }", "title": "" }, { "docid": "e30fd06288f319c7b8857de2b4eba0d5", "score": "0.5264014", "text": "protected abstract function & createField();", "title": "" }, { "docid": "f95a5a3d4af47af503e50d19fb3315a9", "score": "0.52545565", "text": "public function addCustomField() {\n $_POST['fieldType'] = (isset($_POST['fieldType']) && in_array($_POST['fieldType'],array('textarea','input','select','checkbox')) ? $_POST['fieldType'] : 'input');\n $_POST['fieldReq'] = (isset($_POST['fieldReq']) ? 'yes' : 'no');\n $_POST['repeatPref'] = (isset($_POST['repeatPref']) ? 'yes' : 'no');\n $_POST['enField'] = (isset($_POST['enField']) ? 'yes' : 'no');\n $dept = (empty($_POST['dept']) ? implode(',',$_POST['deptall']) : implode(',',$_POST['dept']));\n if (empty($_POST['fieldLoc'])) {\n $_POST['fieldLoc'][] = 'ticket';\n }\n mysql_query(\"INSERT INTO `\".DB_PREFIX.\"cusfields` (\n `fieldInstructions`,\n `fieldType`,\n `fieldReq`,\n `fieldOptions`,\n `fieldLoc`,\n `orderBy`,\n `repeatPref`,\n `enField`,\n `departments`\n ) VALUES (\n '\".mswSafeImportString($_POST['fieldInstructions']).\"',\n '{$_POST['fieldType']}',\n '{$_POST['fieldReq']}',\n '\".mswSafeImportString($_POST['fieldOptions']).\"',\n '\".implode(',',$_POST['fieldLoc']).\"',\n '0',\n '{$_POST['repeatPref']}',\n '{$_POST['enField']}',\n '{$dept}'\n )\") or die(mswMysqlErrMsg(mysql_errno(),mysql_error(),__LINE__,__FILE__));\n // Rebuild sequence..\n fields::rebuildSequence();\n}", "title": "" }, { "docid": "5e59c99bffa23fb1cd789742bf0a9c2b", "score": "0.52503294", "text": "public function add_field_value($data){\n\t\t\n\t\t\n\t\textract($data); \n\t\t\n\t\t$dependent_ids = implode(\",\",(array_values($dep_value)));\n\t\t//echo \"<pre>\"; print_r($dependent_values); exit;\n\t\n\t\t$ins_data = array(\n\t\t\n\t\t\t'field_id' => $this->db->escape_str(trim($field_id)),\n\t\t\t'field_value' => $this->db->escape_str(trim($field_value)),\n\t\t\t'dep_value' => $this->db->escape_str(trim($dependent_ids))\n\t\t);\n\t\t\n\t\t//Insert the record into the database.\n\t\t$this->db->dbprefix('cat_fields_value');\n\t\t$ins_into_db = $this->db->insert('cat_fields_value', $ins_data);\n\t\t\n\t\tif($ins_into_db){\n return true;;\n\t\t}//end if($ins_into_db)\n\t\t\n\t}", "title": "" }, { "docid": "1c2a2dcb46c3db9bdf063f2c95bf00e9", "score": "0.52447367", "text": "static function add_item($item) {\n $access_intent = ORM::factory(\"access_intent\", $item->id);\n if ($access_intent->loaded()) {\n throw new Exception(\"@todo ITEM_ALREADY_ADDED $item->id\");\n }\n $access_intent = ORM::factory(\"access_intent\");\n $access_intent->item_id = $item->id;\n $access_intent->save();\n\n // Create a new access cache entry and copy the parents values.\n $access_cache = ORM::factory(\"access_cache\");\n $access_cache->item_id = $item->id;\n if ($item->id != 1) {\n $parent_access_cache =\n ORM::factory(\"access_cache\")->where(\"item_id\", \"=\", $item->parent()->id)->find();\n foreach (self::_get_all_groups() as $group) {\n foreach (ORM::factory(\"permission\")->find_all() as $perm) {\n $field = \"{$perm->name}_{$group->id}\";\n if ($perm->name == \"view\") {\n $item->$field = $item->parent()->$field;\n } else {\n $access_cache->$field = $parent_access_cache->$field;\n }\n }\n }\n }\n $item->save();\n $access_cache->save();\n }", "title": "" }, { "docid": "f381c038ed92bb6b1df30c3731ab2ba9", "score": "0.5236576", "text": "public function setFieldExtraInfo($fieldExtraInfo)\n {\n $this->fieldExtraInfo = (string) $fieldExtraInfo;\n }", "title": "" }, { "docid": "be70c24d8d76be1f3696e82e9b0a2341", "score": "0.5232189", "text": "public function append(Inputfield $item) {\n\t\t$item->setParent($this); \n\t\t$this->children->append($item); \n\t\treturn $this; \n\t}", "title": "" }, { "docid": "9a87d57f0722a799fb1c0eee8a91ccbc", "score": "0.5224694", "text": "function set_single_custom_field() {\n\t\t\n\t\tif ( is_array( $this->custom_field ) ) {\n\t\t\tforeach ( $this->custom_field as $key => $val ) {\n\t\t\t\t$this->set( $key, $val );\n\t\t\t}\n\t\t}\n\t\t\n\t}", "title": "" }, { "docid": "3dc525353876bfcf9c11178ffa99e7af", "score": "0.5216691", "text": "public function push(Input $field) {\n array_push($this->fields, $field);\n }", "title": "" }, { "docid": "498acd8c1dbc388e08d8c72b48f1c92e", "score": "0.5215475", "text": "protected function addLineItemsFields(&$fields, $i = 1)\n {\n $cartItems = $this->getCartItems();\n\n foreach ($cartItems as $item) {\n\n foreach ($this->itemFieldsFormat as $modelField => $paypalField) {\n $fields[sprintf($paypalField, $i)] = $item->{$modelField};\n }\n\n $i++;\n }\n }", "title": "" }, { "docid": "36d9ad0280d3a066a5a5856f7c1efafd", "score": "0.52122074", "text": "private function saveIncludedItemField($id, $field_name, $field_value) {\n $query = \"\";\n switch( $field_name ) {\n case \"name\":\n $query = self::QUERY_UPDATE_NAME;\n break;\n case \"slug\":\n $query = self::QUERY_UPDATE_SLUG;\n break;\n }\n $affected_rows = $this->db->modify($query, array(\n $field_value, $id\n ));\n \n return $affected_rows;\n }", "title": "" }, { "docid": "baddfe6a164cc4b9bd36230a2e54f130", "score": "0.52120614", "text": "public function updateAdditionalInformation($info)\n {\n foreach ($this->_postValues as $key => $value) {\n if ($value==='') {\n if ($info->getAdditionalInformation($key)) {\n $info->unsAdditionalInformation($key);\n }\n continue;\n }\n $info->setAdditionalInformation($key, $value);\n }\n }", "title": "" }, { "docid": "3f8ee019253678306cc2ee7eaf074467", "score": "0.52116406", "text": "public function buildFieldElement(): void;", "title": "" }, { "docid": "cb68a629e408b57f51b1ad505722a543", "score": "0.51999944", "text": "public function storeFieldData( VersionInfo $versionInfo, Field $field )\n {\n if ( $field->value->externalData === null )\n {\n // Store empty value and return\n $this->deleteFieldData( $versionInfo, array( $field->id ) );\n $field->value->data = array(\n 'sortKey' => null,\n 'hasData' => false,\n );\n return;\n }\n\n if ( $this->hasFieldData( $field->id, $versionInfo->versionNo ) )\n {\n $this->updateFieldData( $versionInfo, $field );\n }\n else\n {\n $this->storeNewFieldData( $versionInfo, $field );\n }\n\n $field->value->data = array(\n 'sortKey' => $field->value->externalData['street'],\n 'hasData' => true,\n );\n return true;\n }", "title": "" }, { "docid": "8a38a9a9cc833facdabae2c8d70624ef", "score": "0.51962864", "text": "protected function typeBuilder($item)\n {\n $item->type = $item->Data_Type;\n\n $item->modifiers = [];\n\n /*\n * Normalise the data\n */\n $extra = strtolower($item->Extra);\n $default = strtolower($item->Default);\n\n if ($item->null === 'YES') {\n $item->modifiers[] = 'nullable()';\n\n /*\n * If we are using Laravel nullbale() we don't need default('NULL')\n */\n if ($default === 'null') {\n $item->Default = null;\n }\n }\n\n if ($extra === 'auto_increment') {\n $item->modifiers[] = 'autoIncrement()';\n }\n\n if ($default === 'current_timestamp' || $default === 'current_timestamp()') {\n $item->modifiers[] = 'useCurrent()';\n $item->Default = null;\n }\n\n if ($extra === 'on update current_timestamp' || $extra === 'on update current_timestamp()') {\n if (! in_array('useCurrent()', $item->modifiers)) {\n $item->modifiers[] = 'useCurrent()';\n $item->Default = null;\n }\n }\n\n /*\n * Default values need to be enclosed in single quotes\n */\n if ($item->Default !== null) {\n $default = trim($item->Default);\n\n $default = str_replace_first(\"'\", '', $default);\n\n $default = str_replace_last(\"'\", '', $default);\n\n $default = str_replace(\"'\", \"\\'\", $default);\n\n $item->modifiers[] = \"default('\".$default.\"')\";\n }\n\n $item->options = str_replace_first($item->type, '', $item->Type);\n\n if (! empty($item->options)) {\n if (strpos($item->options, 'unsigned') !== false) {\n $item->modifiers[] = 'unsigned()';\n\n $item->options = str_replace('unsigned', '', $item->options);\n }\n }\n\n $item = $this->fieldParser->setup($item)->get();\n\n if (in_array($item->new_type, $this->fields_with_options) && ! empty($item->options)) {\n $item->options = str_replace_first('(', '', $item->options);\n\n $item->options = str_replace_last(')', '', $item->options);\n\n if ($item->type === 'enum') {\n $item->options = '['.$item->options.']';\n }\n\n $item->type .= ', '.$item->options;\n }\n\n return $item;\n }", "title": "" }, { "docid": "310d84641fd4d45326b8573cb2e1917c", "score": "0.51895475", "text": "static function add_field() {\n BsaUtil::add_checkbox(self::OPTION_NAME);\n }", "title": "" }, { "docid": "b29f746566779f5e9a9ca3282d05590b", "score": "0.5187351", "text": "function onDisplayCoreFieldValue( &$field, $item, &$params, $tags=null, $categories=null, $favourites=null, $favoured=null, $vote=null, $values=null, $prop='display' )\r\n\t{\r\n\t\t// execute the code only if the field type match the plugin type\r\n\t\t$view = JRequest::setVar('view', JRequest::getVar('view', 'item'));\r\n\t\t\r\n\t\t$values = $values ? $values : $field->value;\r\n\r\n\t\tif($field->iscore != 1) return;\r\n\t\t\r\n\t\t$pretext\t\t\t= $field->parameters->get( 'pretext', '' ) ;\r\n\t\t$posttext\t\t\t= $field->parameters->get( 'posttext', '' ) ;\r\n\t\t$separatorf\t\t\t= $field->parameters->get( 'separatorf', 1 ) ;\r\n\t\t$dateformat\t\t\t= $field->parameters->get( 'date_format', '' ) ;\r\n\t\t$customdate\t\t\t= $field->parameters->get( 'custom_date', '' ) ;\t\t\r\n\t\t\t\t\t\t\r\n\t\tif($pretext) $pretext = $pretext . ' ';\r\n\r\n\t\tif($posttext) $posttext = ' ' . $posttext . ' ';\r\n\r\n\t\tswitch($separatorf)\r\n\t\t{\r\n\t\t\tcase 0:\r\n\t\t\t$separatorf = ' ';\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 1:\r\n\t\t\t$separatorf = '<br />';\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 2:\r\n\t\t\t$separatorf = ' | ';\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 3:\r\n\t\t\t$separatorf = ', ';\r\n\t\t\tbreak;\r\n\r\n\t\t\tdefault:\r\n\t\t\t$separatorf = ' ';\r\n\t\t\tbreak;\r\n\t\t}\r\n\t\t\t\r\n\t\tswitch ($field->field_type)\r\n\t\t{\r\n\t\t\tcase 'created': // created\r\n\t\t\t$field->value[] = $item->created;\r\n\t\t\t$dateformat = $dateformat ? $dateformat : $customdate;\r\n\t\t\t$field->display = $pretext.JHTML::_( 'date', $item->created, JText::_($dateformat) ).$posttext;\r\n\t\t\tbreak;\r\n\t\t\t\r\n\t\t\tcase 'createdby': // created by\r\n\t\t\t$field->value[] = $item->created_by;\r\n\t\t\t$field->display = $pretext.(($field->parameters->get('name_username', 1) == 2) ? $item->cuname : $item->creator).$posttext;\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 'modified': // modified\r\n\t\t\t$field->value[] = $item->modified;\r\n\t\t\t$dateformat = $dateformat ? $dateformat : $customdate;\r\n\t\t\t$field->display = $pretext.JHTML::_( 'date', $item->modified, JText::_($dateformat) ).$posttext;\r\n\t\t\tbreak;\r\n\t\t\t\r\n\t\t\tcase 'modifiedby': // modified by\r\n\t\t\t$field->value[] = $item->modified_by;\r\n\t\t\t$field->display = $pretext.(($field->parameters->get('name_username', 1) == 2) ? $item->muname : $item->modifier).$posttext;\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 'title': // title\r\n\t\t\t$field->value[] = $item->title;\r\n\t\t\t$field->display = $pretext.$item->title.$posttext;\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 'hits': // hits\r\n\t\t\t$field->value[] = $item->hits;\r\n\t\t\t$field->display = $pretext.$item->hits.$posttext;\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 'type': // document type\r\n\t\t\t$field->value[] = $item->type_id;\r\n\t\t\t$field->display = $pretext.JText::_($item->typename).$posttext;\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 'version': // version\r\n\t\t\t$field->value[] = $item->version;\r\n\t\t\t$field->display = $pretext.$item->version.$posttext;\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 'state': // state\r\n\t\t\t$field->value[] = $item->state;\r\n\t\t\t$field->display = flexicontent_html::stateicon( $item->state, $field->parameters );\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 'voting': // voting button\r\n\t\t\t$field->value[] = 'button'; // dummy value to force display\r\n\t\t\t$field->display = flexicontent_html::ItemVote( $field, 'main', $vote );\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 'favourites': // favourites button\r\n\t\t\t$field->value[] = 'button'; // dummy value to force display\r\n\t\t\t$favs = flexicontent_html::favoured_userlist( $field, $item, $favourites);\r\n\t\t\t$field->display = '\r\n\t\t\t<span class=\"fav-block\">\r\n\t\t\t\t'.flexicontent_html::favicon( $field, $favoured ).'\r\n\t\t\t\t<span id=\"fcfav-reponse_'.$field->item_id.'\" class=\"fcfav-reponse\">\r\n\t\t\t\t\t<small>'.$favs.'</small>\r\n\t\t\t\t</span>\r\n\t\t\t</span>\r\n\t\t\t\t';\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 'categories': // assigned categories\r\n\t\t\tglobal $globalnoroute;\r\n\t\t\tif ( !is_array($globalnoroute) ) $globalnoroute = array();\r\n\t\t\t$display = '';\r\n\t\t\tif ($categories) :\r\n\t\t\t\t$field->display = array();\r\n\t\t\t\tforeach ($categories as $category) {\r\n\t\t\t\t\tif (!in_array($category->id, @$globalnoroute)) :\r\n\t\t\t\t\t\t$field->display[] = '<a class=\"fc_categories link_' . $field->name . '\" href=\"' . JRoute::_(FlexicontentHelperRoute::getCategoryRoute($category->slug)) . '\">' . $category->title . '</a>';\r\n\t\t\t\t\t\t$field->value[] = $category->title;\r\n\t\t\t\t\tendif;\r\n\t\t\t\t}\r\n\t\t\t\tif (isset($field->display)) :\r\n\t\t\t\t\t$field->display = implode($separatorf, $field->display);\r\n\t\t\t\telse :\r\n\t\t\t\t\t$field->value[] = '';\r\n\t\t\t\t\t$field->display = '';\r\n\t\t\t\tendif;\r\n\t\t\telse :\r\n\t\t\t\t$field->value[] = '';\r\n\t\t\t\t$field->display = '';\r\n\t\t\tendif;\r\n\t\t\tbreak;\r\n\r\n\t\t\tcase 'tags': // assigned tags\r\n\t\t\t$display = '';\r\n\t\t\tif ($tags) {\r\n\t\t\t\t$field->display = array();\r\n\t\t\t\tforeach ($tags as $tag) {\r\n\t\t\t\t\t$field->value[] = $tag->name; \r\n\t\t\t\t\t$field->display[] = '<a class=\"fc_tags link_' . $field->name . '\" href=\"' . JRoute::_(FlexicontentHelperRoute::getTagRoute($tag->slug)) . '\">' . $tag->name . '</a>';\r\n\t\t\t\t\t}\r\n\t\t\t\t$field->display = implode($separatorf, $field->display);\r\n\t\t\t} else {\r\n\t\t\t\t//$field->value[] = '';\r\n\t\t\t\t$field->display = '';\r\n\t\t\t}\r\n\t\t\tbreak;\r\n\t\t\t\r\n\t\t\tcase 'maintext': // main text\r\n\t\t\tif ($view == 'category') {\r\n\t\t\t\t$field->{$prop} = $item->introtext;\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\r\n\t\t\t// manage the don't show introtext parameter\r\n\t\t\tif (!$item->parameters->get('show_intro', 1) && $item->fulltext && ($prop == 'display')) {\r\n\t\t\t\t$field->{$prop} = $item->fulltext;\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\r\n\t\t\t$text = $item->text ? $item->text : '';\r\n\r\n\t\t\t// Search for the {readmore} tag and split the text up accordingly.\r\n\t\t\t$text = str_replace('<br>', '<br />', $text);\r\n\r\n\t\t\t$pattern = '#<hr\\s+id=(\"|\\')system-readmore(\"|\\')\\s*\\/*>#i';\r\n\t\t\t$tagPos\t= preg_match($pattern, $text);\r\n\r\n\t\t\tif ($tagPos != 0)\t{\r\n\t\t\t\t$text = preg_replace($pattern, '',$text);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$field->{$prop} = $text;\r\n\t\t\tbreak;\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "11c81d530804f95985c271301aacec84", "score": "0.5186522", "text": "function autonav_custom_menu_field($item_id, $item, $depth, $args) {\n?>\n <p class=\"field-custom description description-wide\">\n <label for=\"edit-menu-item-custom-<?php echo $item_id; ?>\">\n <?php _e( 'Custom' ); ?><br />\n <input type=\"text\" id=\"edit-menu-item-custom-<?php echo $item_id; ?>\" class=\"widefat code edit-menu-item-custom\" name=\"menu-item-custom[<?php echo $item_id; ?>]\" value=\"<?php echo esc_attr( $item->custom ); ?>\" />\n </label>\n </p>\n<?php\n}", "title": "" }, { "docid": "70f2455e0c063bbfdadcd1fab51d5b9a", "score": "0.51856595", "text": "public function getFieldData( VersionInfo $versionInfo, Field $field )\n {\n $field->value->externalData = $this->loadFieldData( $field->id, $versionInfo->versionNo );\n }", "title": "" } ]
a6bb1eb5745933eddebd984e93986131
Register all of the commands in the given directory.
[ { "docid": "263bd8b12238f685dcba068e603b0913", "score": "0.0", "text": "protected function loadCommands($paths)\n {\n $paths = array_unique(Arr::wrap($paths));\n $paths = array_filter($paths, function ($path) {\n return is_dir($path);\n });\n\n if (empty($paths)) {\n return;\n }\n\n $namespace = $this->app->getNamespace();\n\n $commands = [];\n foreach ((new Finder)->in($paths)->files() as $command) {\n $command = $namespace.str_replace(\n ['/', '.php'],\n ['\\\\', ''],\n Str::after($command->getPathname(), realpath(app_path()).DIRECTORY_SEPARATOR)\n );\n\n if (is_subclass_of($command, Command::class) &&\n ! (new ReflectionClass($command))->isAbstract()) {\n $commands[] = $command;\n }\n }\n $this->commands($commands);\n }", "title": "" } ]
[ { "docid": "f79b7842c87162c5c74f45c8bb5f26fc", "score": "0.7247516", "text": "public function registerCommands()\n {\n foreach ($this->commands as $key => $value) {\n $this->app->singleton($value, function ($app) use ($key){\n $class_name = \"K_Laravel_Creator\\\\Console\\\\Commands\\\\\" . $key;\n return new $class_name($app['files']);\n });\n\n $this->commands($value);\n }\n }", "title": "" }, { "docid": "ebb49c7b4b50f315b94c8014503b8344", "score": "0.69271773", "text": "public function registerCommands()\n {\n $this->app['command.rets.install'] = $this->app->share(function()\n {\n return new InstallCommand();\n });\n\n $this->app['command.rets.setup'] = $this->app->share(function()\n {\n return new SetupCommand();\n });\n\n $this->app['command.rets.init'] = $this->app->share(function()\n {\n return new InitCommand();\n });\n\n $this->app['command.rets.update'] = $this->app->share(function()\n {\n return new UpdateCommand();\n });\n\n $this->app['command.rets.images'] = $this->app->share(function()\n {\n return new FetchImages();\n });\n\n $this->commands(\n 'command.rets.install',\n 'command.rets.setup',\n 'command.rets.init',\n 'command.rets.update',\n 'command.rets.images'\n );\n }", "title": "" }, { "docid": "1884bd6ed6361b675d4b624715fbcd54", "score": "0.6906262", "text": "protected function registerCommands()\n {\n $this->commands([\n MakeLdapRule::class,\n MakeLdapScope::class,\n MakeLdapModel::class,\n TestLdapConnection::class,\n BrowseLdapServer::class,\n ]);\n }", "title": "" }, { "docid": "7eb8319b36d16bd987a80c099608d951", "score": "0.6874255", "text": "private function registerCommands(): void\n {\n $commands = [];\n\n if (config('utils.console_commands.pint.enabled')) {\n $commands[] = PintCommand::class;\n }\n if (config('utils.console_commands.make_enum.enabled')) {\n $commands[] = EnumMakeCommand::class;\n }\n if (config('utils.console_commands.make_trait.enabled')) {\n $commands[] = TraitMakeCommand::class;\n }\n if (config('utils.console_commands.make_contract.enabled')) {\n $commands[] = ContractMakeCommand::class;\n }\n if (config('utils.console_commands.make_action.enabled')) {\n $commands[] = ActionMakeCommand::class;\n }\n if (config('utils.console_commands.make_service.enabled')) {\n $commands[] = ServiceMakeCommand::class;\n }\n\n if (! empty($commands)) {\n $this->commands($commands);\n }\n }", "title": "" }, { "docid": "0e7d711593fd8a07093ff5b51a235347", "score": "0.6862564", "text": "protected function registerCommands()\n {\n $this->addCommands(array(\n new Command\\QueueJobCommand(),\n new Command\\WorkerCommand()\n ));\n }", "title": "" }, { "docid": "4888d3195d760d2ac1a88774d93de876", "score": "0.6848724", "text": "public function registerCommands()\n\t{\n// Artisan::add(new InstallCommand);\n// Artisan::add(new UpdateCommand);\n \n\t\t$commands = array('LaravellaInstall','LaravellaUpdate');\n\n\t\tforeach ($commands as $command)\n\t\t{\n\t\t\t$this->{'register'.$command.'Command'}();\n\t\t}\n\n\t\t$this->commands(\n\t\t\t'command.laravella.install','command.laravella.update'\n\t\t);\n \n\t}", "title": "" }, { "docid": "671361ac082ef063bcdebc5c84e3c4ba", "score": "0.68104297", "text": "protected function registerCommands()\n\t{\n\t\t$app = $this->app;\n\n\t\t$app['command.leitom.boilerplate.account.make'] = $app->share(function($app)\n\t\t{\n\t\t\treturn new Console\\MakeActivationsCommand($app['files']);\n\t\t});\n\n\t\t$app['command.leitom.boilerplate.account.clear'] = $app->share(function($app)\n\t\t{\n\t\t\treturn new Console\\ClearExpiredActivationsCommand;\n\t\t});\n\n\t\t$this->commands('command.leitom.boilerplate.account.make', 'command.leitom.boilerplate.account.clear');\n\t}", "title": "" }, { "docid": "fcfc93c0cdad27e3da69c094cd23eb6f", "score": "0.67877513", "text": "private function registerCommands()\n {\n $this->app->singleton('command.clock.migration', function ($app) {\n return new MigrationCommand();\n });\n $this->app->singleton('command.clock.redInit', function ($app) {\n return new ClockRedInit();\n });\n $this->app->singleton('command.clock.redPush', function ($app) {\n return new ClockPushRed();\n });\n }", "title": "" }, { "docid": "20b0396bbdd4327864a0e3ba7f31534c", "score": "0.6755727", "text": "public function register()\n {\n foreach ($this->commands as $command) {\n $this->commands('Modules\\\\Admin\\\\Console\\\\'.$command.'Command');\n }\n }", "title": "" }, { "docid": "2495bb9d6ba8a55fdc48c98761a161de", "score": "0.67341185", "text": "public function registerCommands()\n\t{\n\t\t$this->app->singleton('command.proxy-curl.curl', function () {\n\t\t\treturn new CurlCommand();\n\t\t});\n\t\t$this->app->singleton('command.proxy-curl.short-s5', function () {\n\t\t\treturn new ShortS5ProxyCommand();\n\t\t});\n\n\t\t$this->commands([\n\t\t\t'command.proxy-curl.curl',\n\t\t\t'command.proxy-curl.short-s5',\n\t\t]);\n\t}", "title": "" }, { "docid": "99256948ba7cfb042ada4c99eafb6eca", "score": "0.6671458", "text": "public function registerCommands()\n {\n $this->commands([\n Initialization::class,\n StarterModelCommand::class,\n StarterResourceCommand::class,\n StarterMigrationCommand::class,\n StarterRepositoryCommand::class,\n StarterControllerCommand::class,\n StarterTransformerCommand::class,\n ]);\n }", "title": "" }, { "docid": "6b438588c01fa67b40b027adfa2030bf", "score": "0.6664094", "text": "protected function registerCommands()\n\t{\n\t\t$this->app['command.platform.install'] = $this->app->share(function($app)\n\t\t{\n\t\t\treturn new InstallCommand($app['platform.installer']);\n\t\t});\n\t}", "title": "" }, { "docid": "fab4edc53317d287cdc02b3ac33b8ca3", "score": "0.6648839", "text": "protected function registerCommands()\n {\n $this->app->bind('command.pulse.install', function ($app) {\n return new InstallCommand($app);\n });\n\n $this->commands('command.pulse.install');\n }", "title": "" }, { "docid": "1a5f7a948b49e74e19e77a71e365c7d8", "score": "0.6610391", "text": "protected function registerCommands()\n {\n $this->app->singleton('command.settings.table', function ($app) {\n return new SettingsTableCommand($app['files'], $app['composer']);\n });\n\n $this->commands('command.settings.table');\n }", "title": "" }, { "docid": "4fc47bc7ee96a579ed97f44e17cbb291", "score": "0.6558103", "text": "protected function registerCommands()\n {\n $this->app->singleton('command.content.table', function ($app) {\n return new ContentTableCommand($app['files'], $app['composer']);\n });\n }", "title": "" }, { "docid": "59bc2b4ca187896c50a2dc56d3835db7", "score": "0.65286636", "text": "public function registerCommands()\n {\n $this->app->singleton('command.database.status', function ($app) {\n return new Commands\\DatabaseStatusCommand();\n });\n\n $this->app->singleton('command.database.upgrade', function ($app) {\n return new Commands\\DatabaseUpgradeCommand();\n });\n\n $this->app->singleton('command.database.clean', function ($app) {\n return new Commands\\DatabaseCleanCommand();\n });\n\n $this->app->singleton('command.database.refresh', function ($app) {\n return new Commands\\DatabaseRefreshCommand();\n });\n\n $this->app->singleton('command.database.rollback', function ($app) {\n return new Commands\\DatabaseRollbackCommand();\n });\n\n $this->app->singleton('command.database.again', function ($app) {\n return new Commands\\DatabaseAgainCommand();\n });\n\n $this->app->singleton('command.database.seed', function ($app) {\n return new Commands\\DatabaseSeedCommand();\n });\n\n $this->app->singleton('command.migration.make', function ($app) {\n return new Commands\\MigrationMakeCommand();\n });\n\n $this->app->singleton('command.seeder.make', function ($app) {\n return new Commands\\SeederMakeCommand();\n });\n\n $this->commands([\n 'command.database.status',\n 'command.database.upgrade',\n 'command.database.clean',\n 'command.database.refresh',\n 'command.database.rollback',\n 'command.database.again',\n 'command.database.seed',\n 'command.migration.make',\n 'command.seeder.make',\n ]);\n }", "title": "" }, { "docid": "cffd3333873303cda6e3d0472416e6db", "score": "0.65196097", "text": "protected function registerCommands()\n {\n if ($this->app->runningInConsole()) {\n $this->commands([\n InstallInbox::class,\n AssetsCommand::class,\n ]);\n }\n }", "title": "" }, { "docid": "86e262733b1087ca855a75c68f9d30f3", "score": "0.64941114", "text": "private function registerCommands(): void\n {\n if ($this->app->runningInConsole()) {\n $this->commands([\n ListenCommand::class,\n ListCommand::class,\n ]);\n }\n }", "title": "" }, { "docid": "920b927e2ff1f786833187bd744647b6", "score": "0.6458378", "text": "protected function registerCommands()\n {\n if ($this->app->runningInConsole()) {\n $this->commands([\n Console\\InstallCommand::class,\n ]);\n if($this->app->isLocal()) {\n $this->commands([\n Console\\TestBuildCommand::class,\n ]);\n }\n }\n }", "title": "" }, { "docid": "0c680fe1c6dd274d63bd74cff5ab5688", "score": "0.6442895", "text": "public function register()\n {\n $this->registerCommands(array_merge(\n $this->commands, $this->devCommands\n ));\n }", "title": "" }, { "docid": "68e3050833f96dcbf5c57e838ee92290", "score": "0.6423468", "text": "protected function registerCommands()\n {\n if ($this->app->runningInConsole()) {\n $this->commands([\n Console\\AssetsCommand::class,\n Console\\ConfigCommand::class,\n Console\\FontsCommand::class,\n Console\\PublicErrorViewsCommand::class,\n Console\\TranslationsCommand::class,\n Console\\MigrationsCommand::class,\n Console\\SeedersCommand::class,\n ]);\n }\n }", "title": "" }, { "docid": "61b903db081ff6ea70f74ea7587b252d", "score": "0.64070714", "text": "protected function registerCommands()\n {\n if (!static::$module) return;\n\n if ($this->app->runningInConsole()) {\n if (file_exists($commands = module_path(static::$module, 'Commands'))) {\n $module = 'App\\Modules\\\\' . str_replace('/', '\\\\', static::$module) . '\\Commands\\\\';\n $commands = array_map(function ($command) use ($module) {\n return $module . str_replace('.php', '', $command->getFileName());\n }, getFiles($commands));\n\n $this->commands($commands);\n }\n\n $console = module_path(static::$module, 'routes/console.php');\n if (file_exists($console)) require $console;\n }\n }", "title": "" }, { "docid": "ee083215dab8c0a5772756fcd42d5ad1", "score": "0.6399868", "text": "public function register()\n {\n $this->commands($this->commands);\n }", "title": "" }, { "docid": "52101d54602c5e8fe8771cacb3c83017", "score": "0.6395098", "text": "private function registerCustomCommands(): void\n {\n $app = $this->app;\n\n require_once $app->getAppPath('commands.php');\n }", "title": "" }, { "docid": "9e0411825e4d26c0c0a07554058d0776", "score": "0.6394215", "text": "protected function registerCommands(): void\n {\n if ($this->app->runningInConsole()) {\n $this->commands([\n Console\\InstallCommand::class,\n Console\\MakeCommand::class,\n ]);\n }\n }", "title": "" }, { "docid": "3bbbd568cf22867ad3ff4f56ec0e5bc4", "score": "0.63559216", "text": "private function registerCommands()\n {\n $this->app->singleton('command.clpt.migration', function ($app) {\n return new MigrationCommand();\n });\n }", "title": "" }, { "docid": "91949ef68a31c952f257e59faa01c16a", "score": "0.63014627", "text": "protected function registerCommands()\n {\n $this->app->bind(\n 'command.moduleMakeEntity', function ($app) {\n return new ModuleMakeEntity();\n }\n );\n $this->app->bind(\n 'command.moduleMakeEntityPolicy', function ($app) {\n return new ModuleMakeEntityPolicy();\n }\n );\n $this->app->bind(\n 'command.ModuleMakeEntityRoutes', function ($app) {\n return new ModuleMakeEntityRoutes();\n }\n );\n $this->app->bind(\n 'command.ModuleMakeEntityActions', function ($app) {\n return new ModuleMakeEntityActions();\n }\n );\n $this->app->bind(\n 'command.ModuleMakeEntityUris', function ($app) {\n return new ModuleMakeEntityUris();\n }\n );\n $this->commands($this->commands);\n }", "title": "" }, { "docid": "557b9d802ad564e38de3319eb2bf6abd", "score": "0.6292525", "text": "public function register()\r\n {\r\n foreach ($this->consoles as $console) {\r\n $this->commands('Pingpong\\Generators\\Console\\\\'.$console.'Command');\r\n }\r\n }", "title": "" }, { "docid": "c603eabf8d2785417278dd2ed16eade3", "score": "0.6277732", "text": "public function register()\n {\n foreach ($this->consoles as $console) {\n $this->commands('Pingpong\\Generators\\Console\\\\'.$console.'Command');\n }\n }", "title": "" }, { "docid": "78385eb4a6d7ef86f4e684413fd8293b", "score": "0.6276796", "text": "public function register()\n {\n $this->commands($this->commands);\n }", "title": "" }, { "docid": "78385eb4a6d7ef86f4e684413fd8293b", "score": "0.6276796", "text": "public function register()\n {\n $this->commands($this->commands);\n }", "title": "" }, { "docid": "78385eb4a6d7ef86f4e684413fd8293b", "score": "0.6276796", "text": "public function register()\n {\n $this->commands($this->commands);\n }", "title": "" }, { "docid": "78385eb4a6d7ef86f4e684413fd8293b", "score": "0.6276796", "text": "public function register()\n {\n $this->commands($this->commands);\n }", "title": "" }, { "docid": "f7e67262be84a93bf20a6129568dde13", "score": "0.6264802", "text": "public function register()\n {\n $this->registerCommands();\n\n foreach (glob(__DIR__.'/Helpers/*.php') as $file) {\n require_once($file);\n }\n }", "title": "" }, { "docid": "a3f6d9ee7c861e49a31c19657da8d6d0", "score": "0.62596774", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n }", "title": "" }, { "docid": "72f7a9a6f2449fa248dc1b4fafd48e00", "score": "0.62388766", "text": "public function registerModuleCommands()\n {\n $this->commands([\n Console\\FilesCommand::class,\n Console\\MakeCommand::class,\n Console\\MigrationCommand::class,\n Console\\CacheCommand::class,\n Console\\ClearCommand::class,\n ]);\n }", "title": "" }, { "docid": "56fa1abf9f195b1a4b8a62d54aef363e", "score": "0.6229596", "text": "public function register()\r\n {\r\n $this->registerCommands();\r\n }", "title": "" }, { "docid": "0a93b09159823294b33a3479af2f01bb", "score": "0.62200415", "text": "public function register()\n\t{\n\t\t$this->commands($this->commands);\n\t}", "title": "" }, { "docid": "fd38b320f302948fcb2ddd0242950984", "score": "0.6218715", "text": "public function registerTenantCommands()\n\t{\n\t\t$commands = array('Install', 'Name', 'Uninstall', 'Migrations', 'Create', 'Drop', 'Migrate', 'Rollback', 'Reset', 'Refresh', 'Seed');\n\n\t\tforeach($commands as $command)\n\t\t{\n\t\t\t$this->{'registerTenant'.$command.'Command'}();\n\t\t}\n\n\t\t$this->commands(\n\t\t\t'command.tenant.install',\n\t\t\t'command.tenant.name',\n\t\t\t'command.tenant.uninstall',\n\t\t\t'command.tenant.migrations',\n\t\t\t'command.tenant.create',\n\t\t\t'command.tenant.drop',\n\t\t\t'command.tenant.migrate',\n\t\t\t'command.tenant.rollback',\n\t\t\t'command.tenant.reset',\n\t\t\t'command.tenant.refresh',\n\t\t\t'command.tenant.seed'\n\t\t);\n\t}", "title": "" }, { "docid": "64e24047c6c528a457c948c4308cee96", "score": "0.62051594", "text": "protected function registerCommands()\n {\n $this->app->bind('eloquent-attachment.clear', function ($app) {\n return new Commands\\ClearTmpFiles;\n });\n }", "title": "" }, { "docid": "ff2e18f0a5eb4c1c8c6e4a5baac28fef", "score": "0.61968344", "text": "private function registerCommands()\n {\n $this->app->singleton('command.chimpCampaigns.migration', function ($app) {\n return new MigrationCommand();\n });\n }", "title": "" }, { "docid": "9a10668e5241e60e5983967785da54b5", "score": "0.6181541", "text": "public function register()\n {\n $this->commands('Someline\\Repository\\Generators\\Commands\\RepositoryCommand');\n $this->commands('Someline\\Repository\\Generators\\Commands\\TransformerCommand');\n $this->commands('Someline\\Repository\\Generators\\Commands\\PresenterCommand');\n $this->commands('Someline\\Repository\\Generators\\Commands\\EntityCommand');\n $this->commands('Someline\\Repository\\Generators\\Commands\\ValidatorCommand');\n $this->commands('Someline\\Repository\\Generators\\Commands\\ControllerCommand');\n $this->commands('Someline\\Repository\\Generators\\Commands\\BindingsCommand');\n $this->commands('Someline\\Repository\\Generators\\Commands\\CriteriaCommand');\n }", "title": "" }, { "docid": "c5faa2b9b66db3f0780613af121401f0", "score": "0.61745864", "text": "public function register()\n {\n $this->registerCommands();\n }", "title": "" }, { "docid": "c5faa2b9b66db3f0780613af121401f0", "score": "0.61745864", "text": "public function register()\n {\n $this->registerCommands();\n }", "title": "" }, { "docid": "c5faa2b9b66db3f0780613af121401f0", "score": "0.61745864", "text": "public function register()\n {\n $this->registerCommands();\n }", "title": "" }, { "docid": "c5faa2b9b66db3f0780613af121401f0", "score": "0.61745864", "text": "public function register()\n {\n $this->registerCommands();\n }", "title": "" }, { "docid": "118d73f891842de6cb329d744b95fa76", "score": "0.6148536", "text": "private function registerCommand()\n {\n $this->app->singleton('command.queue.vodcallback.flush', function () {\n return new CallbackFlushCommand();\n });\n\n $this->app->singleton('command.make.vodcallback.callback', function () {\n return new CallbackEventMakeCommand($this->app['files']);\n });\n }", "title": "" }, { "docid": "a2486fd05a6b05c69e3e8931c9cabcd7", "score": "0.60837007", "text": "private function registerConsoleCommands()\n {\n $this->commands([\n \"\\Doctrine2l5\\Console\\Generators\\All\",\n \"\\Doctrine2l5\\Console\\Generators\\Entities\",\n \"\\Doctrine2l5\\Console\\Generators\\Proxies\",\n \"\\Doctrine2l5\\Console\\Generators\\Repositories\",\n \"\\Doctrine2l5\\Console\\Schema\\Create\",\n \"\\Doctrine2l5\\Console\\Schema\\Drop\",\n \"\\Doctrine2l5\\Console\\Schema\\Update\",\n \"\\Doctrine2l5\\Console\\Schema\\Validate\",\n ]);\n }", "title": "" }, { "docid": "815ff71c437fcaafdc31d77dcdf97602", "score": "0.6062727", "text": "public function registerForReborn()\n {\n foreach ( $this->getRebornDefaultCommands() as $command ) {\n $this->add($command);\n }\n }", "title": "" }, { "docid": "21e1ecd4d46f6a79b8a5f401cd1d6d72", "score": "0.6039944", "text": "public function registerAllShortcodes($directory)\n {\n try {\n foreach (new \\DirectoryIterator($directory) as $file) {\n if ($file->isDot()) {\n continue;\n }\n $this->registerShortcode($file->getFilename(), $directory);\n }\n } catch (\\UnexpectedValueException $e) {\n throw new ApplicationException('ShortcodeCore Plugin: Directory not found => ' . $directory);\n }\n }", "title": "" }, { "docid": "8dcf1ea253693f1230b33f182ce7d901", "score": "0.60169995", "text": "public function register(): void\n {\n $this->commands([\n DescriptiveCommand::class,\n ]);\n }", "title": "" }, { "docid": "7f6fa3199f39cd340f4e736c7381d8d4", "score": "0.59973305", "text": "public function register()\n {\n\n $this->registerCommands();\n }", "title": "" }, { "docid": "495ea44a9b7a30deb0c3251779f67c95", "score": "0.5972826", "text": "public static function init(): void\n {\n if (true == self::$initialised) {\n return;\n }\n\n // Autoload commands in an extensions /commands or workspace/commands\n // folder\n spl_autoload_register(function ($class) {\n if (!preg_match_all(\n sprintf(\n '@%s\\\\\\\\Commands\\\\\\\\([^\\\\\\\\]+)\\\\\\\\(.+)$@i',\n preg_quote(__NAMESPACE__)\n ),\n $class,\n $matches\n )) {\n return;\n }\n\n $extension = $matches[1][0];\n $command = $matches[2][0];\n\n $filepaths = [];\n\n $generateFilePathCombinations = function ($subjects, string $delim = DIRECTORY_SEPARATOR, string $pre = null, string $post = null, array $operations = ['strtolower', 'ucfirst', 'lcfirst']): array {\n if (!is_array($subjects)) {\n $subjects = [$subjects];\n }\n\n $sets = array_fill_keys($subjects, []);\n\n foreach ($subjects as $s) {\n $sets[$s][] = $s;\n foreach ($operations as $func) {\n $sets[$s][] = call_user_func($func, $s);\n }\n $sets[$s] = array_unique($sets[$s]);\n }\n\n $combinations = [[]];\n foreach ($sets as $index => $values) {\n $tmp = [];\n foreach ($combinations as $r) {\n foreach ($values as $v) {\n $r[$index] = $v;\n $tmp[] = $r;\n }\n }\n $combinations = $tmp;\n }\n\n $result = [];\n foreach ($combinations as $items) {\n $result[] = $pre.implode($items, $delim).$post;\n }\n\n return array_unique($result);\n };\n\n if (0 == strcasecmp($extension, 'workspace')) {\n $filepaths = $generateFilePathCombinations(\n ['commands', $command],\n DIRECTORY_SEPARATOR,\n WORKSPACE.DIRECTORY_SEPARATOR,\n '.php'\n );\n } else {\n $filepaths = $generateFilePathCombinations(\n [$extension, 'commands', $command],\n DIRECTORY_SEPARATOR,\n EXTENSIONS.DIRECTORY_SEPARATOR,\n '.php'\n );\n }\n\n foreach ($filepaths as $file) {\n if (is_readable($file)) {\n require_once $file;\n break;\n }\n }\n });\n\n // Autoloader for Extension driver classes\n spl_autoload_register(function ($class) {\n if (!preg_match('/^Extension_(.*)$/i', $class, $matches)) {\n return;\n }\n\n $extension = strtolower($matches[1]);\n\n // Check if Extension is enabled\n if (\\Extension::EXTENSION_ENABLED != $status = self::getExtensionStatus($extension)) {\n return;\n }\n\n $path = sprintf(\n '%s/%s',\n EXTENSIONS,\n $extension\n );\n\n if (is_readable($path.'/extension.driver.php')) {\n require_once $path.'/extension.driver.php';\n }\n\n if (is_readable($path.'/vendor/autoload.php')) {\n require_once $path.'/vendor/autoload.php';\n }\n });\n\n self::$initialised = true;\n }", "title": "" }, { "docid": "cc5f6999ecb13dd08060a950bde8b99a", "score": "0.5972558", "text": "public function register()\n {\n $generators = [\n 'command.make.thinkwinds' => \\Thinkwinds\\Framework\\Console\\Generators\\MakeInstallCommand::class,\n 'command.make.thinkwinds.manage.founder' => \\Thinkwinds\\Framework\\Console\\Generators\\MakeManageFounderCommand::class,\n 'command.make.thinkwinds.api' => \\Thinkwinds\\Framework\\Console\\Generators\\MakeApiCommand::class,\n ];\n foreach ($generators as $slug => $class) \n {\n $this->app->singleton($slug, function ($app) use ($slug, $class) \n {\n return $app[$class];\n });\n $this->commands($slug);\n }\n }", "title": "" }, { "docid": "8ca52d48de2225383d24a84fffe6b9da", "score": "0.59666467", "text": "private function registerDefaultCommands(): void\n {\n $this->app->registerCommand('environment', EnvironmentCommand::class)\n ->setDescription('Returns the application environment');\n\n $this->app->registerCommand('create:command [name] [class]', CreateCommandCommand::class)\n ->setDescription('Create\\'s a new command');\n\n $this->app->registerCommand('create:provider [class]', CreateProviderCommand::class)\n ->setDescription('Create\\'s new provider.');\n }", "title": "" }, { "docid": "ce0a3bd3ae39ad39f5aff0a871bc6f50", "score": "0.5956674", "text": "public function register()\n {\n $this->registerCommand();\n }", "title": "" }, { "docid": "5b7459008851a5cc3d52472228c20226", "score": "0.5947124", "text": "protected function registerPhpcrCommands()\n {\n // phpcr commands\n $this->add(new CommandPhpcr\\AccessControlPrivilegeListCommand());\n $this->add(new CommandPhpcr\\RepositoryDescriptorListCommand());\n $this->add(new CommandPhpcr\\SessionExportCommand());\n $this->add(new CommandPhpcr\\SessionImpersonateCommand());\n $this->add(new CommandPhpcr\\SessionImportCommand());\n $this->add(new CommandPhpcr\\SessionInfoCommand());\n $this->add(new CommandPhpcr\\SessionNamespaceListCommand());\n $this->add(new CommandPhpcr\\SessionNamespaceSetCommand());\n $this->add(new CommandPhpcr\\NodePropertyRemoveCommand());\n $this->add(new CommandPhpcr\\NodePropertyShowCommand());\n $this->add(new CommandPhpcr\\SessionRefreshCommand());\n $this->add(new CommandPhpcr\\SessionSaveCommand());\n $this->add(new CommandPhpcr\\QueryCommand());\n $this->add(new CommandPhpcr\\QuerySelectCommand());\n $this->add(new CommandPhpcr\\QueryUpdateCommand());\n $this->add(new CommandPhpcr\\QueryDeleteCommand());\n $this->add(new CommandPhpcr\\RetentionHoldAddCommand());\n $this->add(new CommandPhpcr\\RetentionHoldListCommand());\n $this->add(new CommandPhpcr\\RetentionHoldRemoveCommand());\n $this->add(new CommandPhpcr\\RetentionPolicyGetCommand());\n $this->add(new CommandPhpcr\\RetentionPolicyRemoveCommand());\n $this->add(new CommandPhpcr\\NodeCloneCommand());\n $this->add(new CommandPhpcr\\NodeCopyCommand());\n $this->add(new CommandPhpcr\\NodeEditCommand());\n $this->add(new CommandPhpcr\\WorkspaceNamespaceListCommand());\n $this->add(new CommandPhpcr\\WorkspaceNamespaceRegisterCommand());\n $this->add(new CommandPhpcr\\WorkspaceNamespaceUnregisterCommand());\n $this->add(new CommandPhpcr\\NodeTypeShowCommand());\n $this->add(new CommandPhpcr\\NodeTypeEditCommand());\n $this->add(new CommandPhpcr\\NodeTypeUnregisterCommand());\n $this->add(new CommandPhpcr\\NodeTypeListCommand());\n $this->add(new CommandPhpcr\\NodeTypeLoadCommand());\n $this->add(new CommandPhpcr\\VersionCheckoutCommand());\n $this->add(new CommandPhpcr\\VersionHistoryCommand());\n $this->add(new CommandPhpcr\\VersionRestoreCommand());\n $this->add(new CommandPhpcr\\VersionRemoveCommand());\n $this->add(new CommandPhpcr\\VersionCheckpointCommand());\n $this->add(new CommandPhpcr\\VersionCheckinCommand());\n $this->add(new CommandPhpcr\\NodeCreateCommand());\n $this->add(new CommandPhpcr\\NodeCorrespondingCommand());\n $this->add(new CommandPhpcr\\NodeFileImportCommand());\n $this->add(new CommandPhpcr\\NodePropertySetCommand());\n $this->add(new CommandPhpcr\\NodeSetPrimaryTypeCommand());\n $this->add(new CommandPhpcr\\NodeRenameCommand());\n $this->add(new CommandPhpcr\\NodeMoveCommand());\n $this->add(new CommandPhpcr\\NodeMixinAddCommand());\n $this->add(new CommandPhpcr\\NodeMixinRemoveCommand());\n $this->add(new CommandPhpcr\\NodeOrderBeforeCommand());\n $this->add(new CommandPhpcr\\NodeInfoCommand());\n $this->add(new CommandPhpcr\\NodeLifecycleFollowCommand());\n $this->add(new CommandPhpcr\\NodeLifecycleListCommand());\n $this->add(new CommandPhpcr\\NodeListCommand());\n $this->add(new CommandPhpcr\\NodeUpdateCommand());\n $this->add(new CommandPhpcr\\NodeReferencesCommand());\n $this->add(new CommandPhpcr\\NodeSharedShowCommand());\n $this->add(new CommandPhpcr\\NodeRemoveCommand());\n $this->add(new CommandPhpcr\\LockLockCommand());\n $this->add(new CommandPhpcr\\LockInfoCommand());\n $this->add(new CommandPhpcr\\LockRefreshCommand());\n $this->add(new CommandPhpcr\\LockTokenAddCommand());\n $this->add(new CommandPhpcr\\LockTokenListCommand());\n $this->add(new CommandPhpcr\\LockTokenRemoveCommand());\n $this->add(new CommandPhpcr\\LockUnlockCommand());\n }", "title": "" }, { "docid": "83e884d95c37b27d40ebe83f573e9f65", "score": "0.59379035", "text": "protected function commands(): void\n {\n $this->load(__DIR__.'/Commands');\n\n // require base_path('routes/console.php');\n }", "title": "" }, { "docid": "88ec58187d4dbac40e3dbef4f42ec151", "score": "0.5928839", "text": "protected function registerAllThemes()\n {\n $functionPath = [base_path('/Themes/functions')];\n\n $directories = $this->app['files']->directories(config('stylist.themes.paths', [base_path('/Themes')])[0]);\n \n $directories = array_diff($directories,$functionPath);\n\n foreach ($directories as $directory) {\n $this->app['stylist']->registerPath($directory);\n }\n }", "title": "" }, { "docid": "54b121b4b59a35852fd4dace515138b5", "score": "0.59109145", "text": "protected function registerCommands()\n {\n if ($this->app->runningInConsole()) {\n $this->commands([\n \\AgenterLab\\IAM\\Console\\PermissionSeed::class\n ]);\n }\n }", "title": "" }, { "docid": "c0ff187db5c0e3a58689e51609465dba", "score": "0.5900036", "text": "protected function commands()\n {\n foreach (['module', 'extension'] as $moduleType) {\n $resources = $this->app['files']->{\"{$moduleType}Resources\"}('src/Console/Commands', 'directories', 2);\n $paths = array_filter(array_unique(collect($resources)->map->getPathname()->toArray()), fn ($path) => is_dir($path));\n $configPath = config(\"rinvex.composer.cortex-{$moduleType}.path\");\n\n if (empty($paths)) {\n return;\n }\n\n foreach ((new Finder())->in($paths)->files() as $command) {\n $command = ucwords(str_replace(\n ['src/', '/', '.php'],\n ['', '\\\\', ''],\n Str::after($command->getRealPath(), $configPath.'/')\n ), '\\\\');\n\n if (is_subclass_of($command, Command::class) && ! (new ReflectionClass($command))->isAbstract() && ! in_array($command, $this->ignoreCommads)) {\n Artisan::starting(function ($artisan) use ($command) {\n $artisan->resolve($command);\n });\n }\n }\n }\n }", "title": "" }, { "docid": "ee96c7f6867b81621935ca0cbfe620ea", "score": "0.58819807", "text": "function register_cli_commands() {\n\tif ( ! defined( 'WP_CLI' ) || ! WP_CLI ) {\n\t\treturn;\n\t}\n\n\trequire __DIR__ . '/class-command.php';\n\tWP_CLI::add_command( 'cavalcade', __NAMESPACE__ . '\\\\Command' );\n}", "title": "" }, { "docid": "07b077fd8d96e8e2f3b9124f4e2616f8", "score": "0.5850905", "text": "protected function registerConsoleCommands()\n {\n $this->commands([\n WebhookHandlerMakeCommand::class,\n ]);\n }", "title": "" }, { "docid": "d84b029926fbecfda1848cdc75b18b2e", "score": "0.58395284", "text": "protected function registerCommands()\n {\n if ($this->app->runningInConsole()) {\n $this->commands([\n ProductUpdate::class,\n ]);\n }\n }", "title": "" }, { "docid": "ca4a703915032255552b0e67217f8365", "score": "0.5830689", "text": "public function register()\n {\n $this->generatorCommands();\n $this->otherCommands();\n $this->registerMigrateCommand();\n $this->registerMigrateRollbackCommand();\n }", "title": "" }, { "docid": "90e62343635bee13063947355b87b5fd", "score": "0.5806978", "text": "protected function registerCliCommands(){\n\n $this->commands('modules.make');\n\n $bind_method = method_exists($this->app, 'bindShared') ? 'bindShared' : 'singleton';\n\n $this->app->{$bind_method}('modules.make', function($app) {\n return new MakeModuleCommand($this->moduleFiles);\n });\n }", "title": "" }, { "docid": "fed7fbffe07c60890c4b26910a63ada9", "score": "0.579629", "text": "public static function scanAndRegister()\n\t{\n\t\tforeach (scan(TL_ROOT . '/system/modules') as $file)\n\t\t{\n\t\t\t$path = TL_ROOT . '/system/modules/' . $file;\n\n\t\t\tif (strncmp($file, '.', 1) === 0 || !is_dir($path))\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tif (file_exists($path . '/.skip') || !file_exists($path . '/config/autoload.php'))\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tinclude $path . '/config/autoload.php';\n\t\t}\n\n\t\tself::register();\n\t}", "title": "" }, { "docid": "f17b0085faa2bb1ff8f9751fe3ee51a8", "score": "0.57885236", "text": "protected function registerCommand()\n {\n $this->app->singleton('rockid.generate', function (){\n return new RockidGenerateCommand();\n });\n $this->commands('rockid.generate');\n }", "title": "" }, { "docid": "2642cd27669383e37e5b6ba88b633de1", "score": "0.5750217", "text": "public function register()\n {\n $this->commands(\n 'Tobidsn\\CrudGenerator\\Commands\\CrudGenerator',\n 'Tobidsn\\CrudGenerator\\Commands\\CrudViewCommand',\n 'Tobidsn\\CrudGenerator\\Commands\\ApiGenerator',\n 'Tobidsn\\CrudGenerator\\Commands\\ApiWebGenerator'\n );\n }", "title": "" }, { "docid": "7595dab38cd9b92fd2e1f05cd9f4628d", "score": "0.5746198", "text": "public function register()\n\t{\n\t\t//\n $this->registerWorkflow();\n $this->registerCommands();\n\t}", "title": "" }, { "docid": "a130b4f036ce588b70928239a85fcb9c", "score": "0.5729209", "text": "public static function register()\n {\n WP_CLI::add_command('valet', static::class, [\n 'before_invoke' => [static::class, 'boot']\n ]);\n }", "title": "" }, { "docid": "71ff4f60e9e9a649b30e130077bb956a", "score": "0.5708684", "text": "public function register() {\n $this->app->singleton('command.scanner.clear', function() {\n return new ScannerClear;\n });\n\n $this->app->singleton('command.scanner.scan', function() {\n return new ScannerScan;\n });\n\n $this->app->singleton('command.scanner.clean', function() {\n return new ScannerClean;\n });\n\n $this->app->singleton('command.scanner.folder.add', function() {\n return new ScannerAddFolder;\n });\n\n $this->app->singleton('command.scanner.folder.remove', function() {\n return new ScannerRemoveFolder;\n });\n\n $this->app->singleton('command.scanner.folder.list', function() {\n return new ScannerListFolders;\n });\n\n $this->app->singleton('command.key.generate', function() {\n return new KeyGenerate;\n });\n\n $this->app->singleton('command.lp.setup', function() {\n return new Setup;\n });\n\n $this->commands(\n 'command.scanner.clear',\n 'command.scanner.scan',\n 'command.scanner.clean',\n 'command.scanner.folder.add',\n 'command.scanner.folder.remove',\n 'command.scanner.folder.list',\n 'command.key.generate',\n 'command.lp.setup'\n );\n }", "title": "" }, { "docid": "3fa4871f1b453f6674f170401ec1432b", "score": "0.57070047", "text": "protected function registerArtisanCommands(): void\n {\n $this->commands([\n TestCommand::class,\n PublishCommand::class,\n ]);\n }", "title": "" }, { "docid": "1468a78a632ae83b8fa01a7f43baca07", "score": "0.57034874", "text": "public function register()\n {\n $this->commands(\\Housekeeper\\Console\\Generators\\MakeRepositoryCommand::class);\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "b6ddc86f109b2fdeac53f70ebc904cc3", "score": "0.5692317", "text": "protected function commands()\n {\n $this->load(__DIR__ . '/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "896b3acc18da202c117a90719e538083", "score": "0.56756514", "text": "protected function commands() {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "8547e0f802a3d08ac06d15f556c28549", "score": "0.56599617", "text": "public function configureAndRegisterCommands(InputInterface $input, OutputInterface $output, $commandfileSearchpath)\n {\n // Symfony will call this method for us in run() (it will be\n // called again), but we want to call it up-front, here, so that\n // our $input and $output objects have been appropriately\n // configured in case we wish to use them (e.g. for logging) in\n // any of the configuration steps we do here.\n $this->configureIO($input, $output);\n\n $discovery = $this->commandDiscovery();\n $commandClasses = $discovery->discover($commandfileSearchpath, '\\Drush');\n $commandClasses[] = \\Consolidation\\Filter\\Hooks\\FilterHooks::class;\n $commandClasses = array_merge($this->commandsFromConfiguration(), $commandClasses);\n\n $this->loadCommandClasses($commandClasses);\n\n // Uncomment the lines below to use Console's built in help and list commands.\n // unset($commandClasses[__DIR__ . '/Commands/help/HelpCommands.php']);\n // unset($commandClasses[__DIR__ . '/Commands/help/ListCommands.php']);\n\n // Use the robo runner to register commands with Symfony application.\n // This method could / should be refactored in Robo so that we can use\n // it without creating a Runner object that we would not otherwise need.\n $runner = new \\Robo\\Runner();\n $runner->registerCommandClasses($this, $commandClasses);\n }", "title": "" }, { "docid": "47de222c8cff18d47d911d4bc6a24477", "score": "0.5653481", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" }, { "docid": "edc91b4548f95f584a67afc7cef6c35c", "score": "0.56297135", "text": "protected function commands()\n {\n $this->load(__DIR__.'/Commands');\n\n require base_path('routes/console.php');\n }", "title": "" } ]
26d71a0b0829d496c8e6bbe23ccaa28a
Display a listing of the resource.
[ { "docid": "3579799e4dc8ed4919ebe794082591f1", "score": "0.0", "text": "public function index()\n {\n //\n }", "title": "" } ]
[ { "docid": "a5f21f14f06e50e6c899fc50c1823371", "score": "0.748859", "text": "public function index()\n {\n return $this->listing();\n }", "title": "" }, { "docid": "496d5d54d7c7a7947e57216e38436eaa", "score": "0.7468274", "text": "public function indexAction()\n {\n $limit = $this->Request()->getParam('limit', 1000);\n $offset = $this->Request()->getParam('start', 0);\n $sort = $this->Request()->getParam('sort', []);\n $filter = $this->Request()->getParam('filter', []);\n\n $result = $this->resource->getList($offset, $limit, $filter, $sort);\n\n $this->View()->assign($result);\n $this->View()->assign('success', true);\n }", "title": "" }, { "docid": "5aa4c5557a26f8808de23dbd0200fb1e", "score": "0.7446935", "text": "public function indexAction()\n {\n $limit = $this->Request()->getParam('limit', 1000);\n $offset = $this->Request()->getParam('start', 0);\n $sort = $this->Request()->getParam('sort', array());\n $filter = $this->Request()->getParam('filter', array());\n\n $result = $this->resource->getList($offset, $limit, $filter, $sort);\n\n $this->View()->assign($result);\n $this->View()->assign('success', true);\n }", "title": "" }, { "docid": "eca6104bc4f03f55970223ec5e260d62", "score": "0.7403906", "text": "public function index()\n {\n $per_page = !request()->filled('per_page') ? 10 : (int) request('per_page');\n $direction = request()->query('direction');\n $sortBy = request()->query('sortBy');\n\n $query = LaporanHarian::query();\n\n $lists = $query->orderBy($sortBy, $direction)->paginate($per_page);\n\n return new ListResources($lists);\n }", "title": "" }, { "docid": "3ec6f8ee193fb6eb0e96d6d5c89ac849", "score": "0.7346841", "text": "public function index()\n {\n $resources = $this->_resourceRepo->fetchResources();\n return view('travellers-inn.admin.resource.index', compact('resources'));\n }", "title": "" }, { "docid": "7573e843d1b7cfeddf14f70707821b32", "score": "0.7310731", "text": "public function actionList()\n\t{\n\t\t$this->renderPartial('list', array(), false, true);\n\t}", "title": "" }, { "docid": "cd35602f7c25a9b8e631ce80beb8ea4d", "score": "0.7295102", "text": "public function index()\n {\n $query = $this->resourceModel::query();\n\n $this->beforeIndex($query);\n\n $query->fieldsForMasterList();\n\n $this->viewData['resourceList'] = $this->afterIndex($query->get());\n\n return view(\n \"{$this->viewBaseDir}.{$this->viewFiles['index']}\",\n $this->viewData\n );\n }", "title": "" }, { "docid": "93cf9bf71a1973929a2edbc182c4df80", "score": "0.72826904", "text": "public function index()\n {\n $this->crud->hasAccessOrFail('list');\n\n $this->data['crud'] = $this->crud;\n $this->data['title'] = ucfirst($this->crud->entity_name_plural);\n\n // get all entries if AJAX is not enabled\n if (! $this->data['crud']->ajaxTable()) {\n $this->data['entries'] = $this->data['crud']->getEntries();\n }\n\n // load the view from /resources/views/vendor/backpack/crud/ if it exists, otherwise load the one in the package\n // $this->crud->getListView() returns 'list' by default, or 'list_ajax' if ajax was enabled\n return view('vendor.backpack.crud.list', $this->data);\n }", "title": "" }, { "docid": "813d60bea2fa858e658620b3d43f028b", "score": "0.72776103", "text": "public function index()\n {\n $fields = $this->parseFields();\n $filter = $this->parseFilters();\n $sort = $this->parseOrders();\n $paging = $this->parsePaging();\n $data = $this->listResources($fields, $filter, $sort, $paging);\n return self::getResponse()->setHeader(DefaultController::$defaultApiHeaders)->setResType('json')->setData($data)->send();\n }", "title": "" }, { "docid": "df01f7ff8d6a105850fbefd31e546f03", "score": "0.7190641", "text": "function list() {\n\n\t\t\tif($this->listJWT) $this->requireJWT();\n\n\t\t\t//Items to show, we can define the number of items via the show query param\n\t\t\t$show = $this->request->get('show', 100);\n\t\t\t$show = $show ?: 100;\n\n\t\t\t//Pages to show, we can define the page number via the page query param\n\t\t\t$page = $this->request->get('page', 1);\n\t\t\t$page = $page ?: 1;\n\n\t\t\t//Sorting defined via the sort query param\n\t\t\t$sort = $this->request->get('sort', 'asc');\n\t\t\t$sort = $sort ?: 'asc';\n\n\t\t\t//Sort by parameter defined via the by query param\n\t\t\t$by = $this->request->get('by', 'id');\n\t\t\t$by = $by ?: 'id';\n\n\t\t\t$args = [ 'show' => $show, 'page' => $page, 'sort' => $sort, 'by' => $by, 'args' => [] ];\n\n\t\t\t//Defines if we want to fetch metas or not\n\t\t\t$fetch_metas = $this->request->get('fetch_metas');\n\t\t\tif($fetch_metas) {\n\n\t\t\t\tif($fetch_metas != 1) $fetch_metas = explode(',', $fetch_metas);\n\t\t\t\t$args['args']['fetch_metas'] = $fetch_metas;\n\t\t\t}\n\n\t\t\t//Automagically add conditions based on get params\n\t\t\tforeach($_GET as $key => $value) {\n\n\t\t\t\tif(in_array($key, $this->plural::getTableFields())) {\n\t\t\t\t\t$args['conditions'][] = \"`{$key}` = '{$value}'\";\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t//Query Fields\n\t\t\t$query_fields = $this->request->get('query_fields');\n\t\t\tif($query_fields && is_string($query_fields)) $query_fields = explode(',', $query_fields);\n\t\t\tif($query_fields) $args['query_fields'] = $query_fields;\n\n\t\t\t//Fetch\n\t\t\tforeach($_GET as $key => $value) {\n\t\t\t\tif(preg_match('/fetch_(?<entity>.*)/', $key)) {\n\t\t\t\t\t$args['args'][$key] = $value;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Passing args via URL\n\t\t\tif($url_args = $this->request->get('args')) {\n\n\t\t\t\t$args = array_merge($args, $url_args);\n\t\t\t}\n\n\t\t\t// Specifically passing PDO Args\n\t\t\tif($pdo = $this->request->get('pdo')) {\n\n\t\t\t\t$args['args'] = array_merge($args['args'], $pdo);\n\t\t\t}\n\n\t\t\t//$args['debug'] = 1;\n\n\t\t\t// Conditions Filter\n\t\t\t$args['conditions'] = $this->filterListConditions(get_item($args, 'conditions', []));\n\n\t\t\tif(is_array($args['conditions'])) {\n\t\t\t\t$args['conditions'] = array_filter($args['conditions']);\n\t\t\t}\n\n\t\t\t$items = $this->plural::all($args);\n\t\t\t$this->data = $items;\n\n\t\t\t$count = $this->plural::count($args['conditions'] ?? []);\n\t\t\t$pages = ceil($count / $show);\n\n\t\t\t$this->properties['current_page'] = (int) $page;\n\t\t\t$this->properties['per_page'] = (int) $show;\n\t\t\t$this->properties['last_page'] = (int) $pages;\n\t\t\t$this->properties['count'] = (int) $count;\n\t\t\t$this->properties['sort'] = $sort;\n\t\t\t$this->properties['by'] = $by;\n\t\t\t$this->properties['total'] = (int) $pages;\n\n\t\t\tif(count($items)) {\n\n\t\t\t\t$this->result = 'success';\n\t\t\t}\n\n\t\t\t$this->respond();\n\t\t}", "title": "" }, { "docid": "6dbec524e0edfa12a7b39fd3954be29e", "score": "0.7157161", "text": "public function index()\n {\n $resources = Resource::paginate(15);\n \n return view('resource.index', compact('resources'));\n }", "title": "" }, { "docid": "3a75e00cbfe822ce4067afcff2f6a3d8", "score": "0.71310157", "text": "public function index()\n {\n return $this->listResponse($this->model->all());\n }", "title": "" }, { "docid": "f7a87ae6c993ad3c3f6ec9da2248552a", "score": "0.71200645", "text": "public function listAction()\n {\n if (Config::get('error')) {\n return false;\n }\n $this->_template = 'ItemsList';\n Route::factory()->setAction('list');\n // Filter parameters to array if need\n Filter::setFilterParameters();\n // Set filter elements sortable\n Filter::setSortElements();\n // Check for existance\n $group = Model::getRow(Route::param('alias'), 'alias', 1);\n if (!$group) {\n return Config::error();\n }\n // Seo\n $this->setSeoForGroup($group);\n // Add plus one to views\n Model::addView($group);\n // Get items list\n $result = Filter::getFilteredItemsList($this->limit, $this->offset, $this->sort, $this->type);\n // Generate pagination\n $pager = Pager::factory($this->page, $result['total'], $this->limit)->create();\n // Render page\n $this->_content = View::tpl(['result' => $result['items'], 'pager' => $pager], 'Catalog/ItemsList');\n }", "title": "" }, { "docid": "bf1bc30233a225c042addf1175ede637", "score": "0.71117574", "text": "public function list()\n\t\t{\n\n\t\t}", "title": "" }, { "docid": "4b74341b17d61539d4d1fc0aa8693955", "score": "0.70722556", "text": "public function index()\n {\n $resources = Resource::orderBy('description')->get();\n return view('resources.index', compact('resources'));\n }", "title": "" }, { "docid": "7e6f0d9f30924279b300346ae37d90a7", "score": "0.7063389", "text": "public function index()\n {\n $resources = Table_resources::all();\n return view(\"admin.resource.list\",['resources'=>$resources]);\n }", "title": "" }, { "docid": "05a3a1abee5cdb637e4ecb2bed78f793", "score": "0.7044714", "text": "public function index() {\n ${$this->resources} = $this->model->orderBy('created_at', 'DESC')\n ->paginate(Variables::get('items_per_page'));\n\n return view($this->view_path . '.index', compact($this->resources));\n }", "title": "" }, { "docid": "d755a2c0bd42a2f83eb1df7236545733", "score": "0.7039909", "text": "public function index()\n {\n $request = app(Request::class);\n $listbuilder = app(ListBuilder::class);\n $args = $request->route()->parameters();\n\n $slug = (empty($this->slug)) ? substr($request->getPathInfo(), 1) : $this->slug;\n $list_slug = (empty($this->list_slug)) ? $slug : $this->list_slug;\n\n $collection = $this->getListQuery($request, $args);\n $total = $collection->total();\n $list_data = $this->getListData($request, $args);\n $list_class = $this->getListClass();\n\n $list = $listbuilder->build($list_class, $collection, [\n 'show_action' => false,\n 'slug' => $list_slug,\n 'data' => $list_data,\n ]);\n $filter = $this->list_filter;\n $show_add = $this->show_add;\n\n $heading = $this->getIndexBreadcrumb($request, $args, $total);\n $object_name = $this->object_name;\n\n if($request->ajax()) {\n return view($this->list_view, compact('list', 'heading', 'filter', 'show_add', 'args', 'object_name', 'total', 'request', 'list_data'));\n } else {\n $layout = $this->layout;\n $section = $this->section;\n $view = $this->list_view;\n return view('cms-package::default-resources.layout-extender', compact('list', 'heading', 'filter', 'show_add', 'args', 'object_name', 'layout', 'section', 'view', 'total', 'request', 'list_data'));\n }\n }", "title": "" }, { "docid": "fb3f72e030e93427b7b0611e0dd87596", "score": "0.70328826", "text": "public function actionRestList()\n {\n $this->doRestList();\n }", "title": "" }, { "docid": "0efbc638dffdcac13f3ee9915260ba01", "score": "0.70086366", "text": "public function actionIndex() {\n $items = $this->getItems();\n self::ret($items);\n }", "title": "" }, { "docid": "349599c7292a71cd03fc4c4ffdd1f19b", "score": "0.7004859", "text": "function listing()\n\t\t{\n\t\t// en $this->_view->_listado para poder acceder a el desde la vista.\n\t\t\t$this->_view->_listado = $listado = $this->_personModel->getPersons();\n\t\t\t$this->_view->render('listing', '', '',$this->_sidebar_menu);\n\t\t}", "title": "" }, { "docid": "5caa574ebf95b5ac2455613f57b23c8e", "score": "0.7001385", "text": "public function listAction(){\n\t\t$view = Zend_Registry::get('view');\n\t\t$table = new Aluno();\n\t\t$table->getCollection();\n\t\t$this->_response->setBody($view->render('default.phtml'));\n\t}", "title": "" }, { "docid": "ca1a292f025cf9b2b20d1b3eacf7ae21", "score": "0.6937133", "text": "public function index()\n {\n $this->pageTitle = 'Resources';\n $this->pageIcon = 'ti-folder';\n $this->icons = $this->icons();\n $this->resources = Resource::paginate(15);\n $this->trashCount = Resource::onlyTrashed()->count();\n\n return view('resource::member.index', $this->data);\n }", "title": "" }, { "docid": "b68550d3783cf092706159aad39af9a4", "score": "0.69189066", "text": "public function indexAction()\n {\n $request = $this->getRequest();\n $recordType = $request->getParam('api_record_type');\n $resource = $request->getParam('api_resource');\n $page = $request->getQuery('page', 1);\n\n $this->_validateRecordType($recordType);\n\n // Determine the results per page.\n $perPageMax = (int) get_option('api_per_page');\n $perPageUser = (int) $request->getQuery('per_page');\n $perPage = ($perPageUser < $perPageMax && $perPageUser > 0) ? $perPageUser : $perPageMax;\n\n // Get the records and the result count.\n $recordsTable = $this->_helper->db->getTable($recordType);\n $totalResults = $recordsTable->count($_GET);\n $records = $recordsTable->findBy($_GET, $perPage, $page);\n\n // Set the non-standard Omeka-Total-Results header.\n $this->getResponse()->setHeader('Omeka-Total-Results', $totalResults);\n\n // Set the Link header for pagination.\n $this->_setLinkHeader($perPage, $page, $totalResults, $resource);\n\n // Build the data array.\n $data = array();\n $recordAdapter = $this->_getRecordAdapter($recordType);\n foreach ($records as $record) {\n $data[] = $this->_getRepresentation($recordAdapter, $record, $resource);\n }\n\n $this->_helper->jsonApi($data);\n }", "title": "" }, { "docid": "1c09e7c92f1c21d273b8b885cd8bfa5f", "score": "0.6918077", "text": "public function listing()\n\t{\n\t\t/* Get request variables */\n\t\t$category = Request::getString('category', null);\n\t\t$sort = Request::getString('sort', BluApplication::getSetting('listingSort', 'date'));\n\t\t$page = Request::getInt('page', 1);\n\n\t\t/* Get parameters. */\n\t\t$total = true;\n\t\t$limit = BluApplication::getSetting('listingLength', 9);\n\t\tswitch($sort){\n\t\t\tcase 'owner':\n\t\t\t\t$function = 'Owned';\n\t\t\t\tbreak;\n\n\t\t\tcase 'title':\n\t\t\t\t$function = 'Alphabetical';\n\t\t\t\tbreak;\n\n\t\t\tcase 'comments':\n\t\t\t\t$function = 'MostCommented';\n\t\t\t\tbreak;\n\n\t\t\tcase 'votes':\n\t\t\t\t$function = 'MostVoted';\n\t\t\t\tbreak;\n\n\t\t\tcase 'views':\n\t\t\t\t$function = 'MostViewed';\n\t\t\t\tbreak;\n\n\t\t\tcase 'date':\n\t\t\tdefault:\n\t\t\t\t$sort = 'date';\n\t\t\t\t$function = 'Latest';\n\t\t\t\tbreak;\n\t\t}\n\n\t\t/* Get data. */\n\t\t$itemsModel = $this->getModel('items')->set('category', $category);\n\t\t$items = $itemsModel->{'get'.$function}($this->_itemtype, ($page - 1) * $limit, $limit, $total);\n\n\t\t/* Prepare pagination */\n\t\t$pagination = Pagination::simple(array(\n\t\t\t'limit' => $limit,\n\t\t\t'total' => $total,\n\t\t\t'current' => $page,\n\t\t\t'url' => '?sort=' . urlencode($sort) . '&amp;category=' . urlencode($category) . '&amp;page='\n\t\t));\n\n\t\t/* Load template */\n\t\tinclude($this->listing_template());\n\t}", "title": "" }, { "docid": "a39f80fe6fb15777c044c4596b95aefd", "score": "0.68882495", "text": "public function index()\n {\n\t\t\t\t$Items = Resource::whereStatus(\"ACTIVE\")->get()->toArray();\n\t\t\t\t$Actions = Action::all()->toArray();\n return view('resource.index',compact(\"Items\",\"Actions\"));\n }", "title": "" }, { "docid": "4342e58d9a88e2330015685845c6b214", "score": "0.68863964", "text": "public function index()\n {\n //get all resource categories, order by name\n $categories = ResourceCategoryFacade::with('resources')->orderBy('name');\n\n PageFacade::mimic([\n 'title' => 'Resources'\n ]);\n\n return view('pilot::frontend.resources.index', compact('categories'));\n }", "title": "" }, { "docid": "e62c3e28d314d6ca7e07a98c0154e01f", "score": "0.68825537", "text": "public function index()\n {\n // get articles\n $articles= Api::paginate(10);\n\n //return collection of articles of a resource\n return ApiResource::collection($articles);\n }", "title": "" }, { "docid": "f1d6678e9ee6cd0e2aba29cc6d3a57e6", "score": "0.68781596", "text": "public function listingAction()\r\n {\r\n $oZendDbSelect = new Zend_Db_Select(Zend_Db_Table::getDefaultAdapter());\r\n $oSelect = $oZendDbSelect->from('View_Rrubrique_Listing')->order('r_rub_id asc');\r\n\r\n // Search engine on the query\r\n $oMySearchEngine = new My_Search_Engine($oSelect);\r\n $oMySearchEngine->findWordOn(array('r_rub_libelle' => array('operator' => 'like')));\r\n $oMySearchEngine->findByFields(array(\r\n 'r_rub_id' => array('operator' => 'eql'),\r\n 'actif' => array('operator' => 'eql'),\r\n 'r_rub_libelle' => array('operator' => 'like'),\r\n 'r_tva_type_id' => array('operator' => 'eql'),\r\n 'r_rub_type_id' => array('operator' => 'eql')\r\n ));\r\n $oMySearchEngine->makeOrderBy();\r\n\r\n // Downloading the filtered list in CSV\r\n if ($this->_helper->ContextSwitch()->getCurrentContext() == 'csv') {//context csv\r\n $oAdapterExport = new My_Data_Export_Source_Adapter_Select($oMySearchEngine->getSelect());\r\n $oExport = new My_Data_Export_CSV($oAdapterExport);\r\n $this->view->csv = $oExport->make();\r\n $this->view->filename = Phoenix_Data_Export_Csv::buildFileName();\r\n } // Viewing the filtered list in HTML\r\n else {\r\n // Declaration of the Paginator Adapter\r\n $oAdapter = new Zend_Paginator_Adapter_DbSelect($oMySearchEngine->getSelect());\r\n // Pagination management\r\n $oPaginator = new My_Paginator($oAdapter);\r\n $oPaginator->setCurrentPageNumber($this->_getParam('page'));\r\n $oPaginator->setItemCountPerPage(15);\r\n $this->view->paginator = $oPaginator;\r\n }\r\n }", "title": "" }, { "docid": "c04f0a07b4332dc7490328fd75b7859d", "score": "0.6874425", "text": "public function index()\n {\n // Set Pagination options\n $options = array(\n 'total_items' => {module}::count(),\n 'items_per_page' => 10,\n );\n\n $pagination = Pagination::create($options);\n\n // Get from Model\n $lists = {module}::orderBy('created_at', 'desc')\n ->take(Pagination::limit())\n ->skip(Pagination::offset())\n ->get();\n\n $this->template->title('{module} Index')\n ->set('lists', $lists)\n ->set('pagination', $pagination)\n ->view('index');\n }", "title": "" }, { "docid": "934002dc44d9e88dec4d87456bacf202", "score": "0.68599224", "text": "public function index()\n {\n //Get Cars\n $cars = Car::paginate(15);\n\n // Return Collection of cars\n return CarResource::collection($cars);\n }", "title": "" }, { "docid": "9ba180ed65da59bf2b9a95f1c09cb0ef", "score": "0.68457514", "text": "public function listAction() {\n\t\t$flexSliders = $this->flexSliderRepository->findAll();\n\n\t\t$tplObj = array(\n\t\t\t'configuration' => EmConfiguration::getConfiguration(),\n\t\t\t'data' => $this->contentObject->data,\n\t\t\t'altUid' => uniqid('alt'),\n\t\t\t'flexSliders' => $flexSliders\n\t\t);\n\t\t$this->view->assignMultiple($tplObj);\n\t}", "title": "" }, { "docid": "4b10c5eaaff873799c32bd4500119f37", "score": "0.68380994", "text": "public function index()\n {\n $inventories = Inventory::paginate();\n\n return InventoryResource::collection($inventories);\n }", "title": "" }, { "docid": "3a4c68e643acd61065e40f913519f57a", "score": "0.68314296", "text": "public function index()\n {\n $request = $this->app->request();\n $filter = Filter::fromRequest($request);\n\n $result = $this->profiles->getAll($filter);\n\n $paging = array(\n 'total_pages' => $result['totalPages'],\n 'page' => $result['page'],\n 'sort' => 'asc',\n 'direction' => $result['direction']\n );\n\n $this->_template = 'waterfall/list.twig';\n $this->set(array(\n 'runs' => $result['results'],\n 'search' => $filter->toArray(),\n 'paging' => $paging,\n 'base_url' => 'waterfall.list',\n 'show_handler_select' => true,\n ));\n }", "title": "" }, { "docid": "874f996d6d98ea380f469ff6759de504", "score": "0.6829909", "text": "public function actionList(){\r\n\t\t$contacts = Contacts::find();\t\t\r\n\t\t\r\n\t\trender('list',array(\r\n\t\t\t'title'\t\t\t=> 'Showing all Contacts on database',\r\n\t\t\t'contacts'\t=> $contacts\t\t\r\n\t\t));\t\t\r\n\t}", "title": "" }, { "docid": "e0e7982de8f7a8c918aef7f3a34c9a7d", "score": "0.6822929", "text": "public function index()\n {\n return TierlistResource::collection(Tierlist::newly()->paginate());\n }", "title": "" }, { "docid": "e662e21bf83b7498445e86cb8e8d5a50", "score": "0.68194026", "text": "public function index()\n {\n // To make sure that we only show records of current user\n $query = $this->getModel();\n\n // Allow to filter results in query string\n $query = $this->applyQueryStringFilter($query);\n\n // If this controller is sortable\n if ($this->getOlutOptions('sortable') === true) {\n $query = $query->orderBy('order');\n }\n\n // Eager loading\n if ($prefetch = $this->getOlutOptions('prefetch')) {\n $query = $query->with($prefetch);\n }\n\n $query = $this->oulutCustomIndexQuery($query);\n\n // Pagination please\n $perPage = (int) Input::get('perPage', Config::get('view.perPage'));\n $perPage = $perPage < 0 ? 0 : $perPage;\n $items = $query->paginate($perPage);\n\n return $this->renderList($items);\n }", "title": "" }, { "docid": "26f44273688d9b90c69abab35c8e4854", "score": "0.6802107", "text": "public function index()\n {\n // $this->authorize('isAdmin');\n return ItemResource::collection(Item::latest()->get());\n }", "title": "" }, { "docid": "24c960a369d6f3101a5432770f2cc5c4", "score": "0.6795378", "text": "public function listAction(){\n $this->view->role = Auth_Info::getUser()->user_type;\n Log::infoLog('method='.__FUNCTION__.';user_id='.Auth_Info::getUser()->user_id.';control_number'.';Start action');\n \n if($this->getRequest()->isGet()&&!isset($this->_input->page)){\n $this->session->removeData(self::SESSION_KEY_SEARCH);\n }\n $this->session->removeData(self::SESSION_KEY_PAGE);\n $this->session->removeData(self::SESSION_KEY_RETURN_DETAIL);\n $page = null;\n if ($this->getRequest()->isPost()) {\n $where = $this->_input->getEscaped();\n\n } else {\n $where = $this->session->getData(self::SESSION_KEY_SEARCH);\n if (is_null($where)) {\n $where = array();\n }\n $page = isset($this->_input->page) ? $this->_input->page : $this->session->getData(self::SESSION_KEY_PAGE);\n }\n $this->getRequest()->setParams($where);\n $this->session->setModuleScope(self::SESSION_KEY_SEARCH, $where);\n $this->session->setModuleScope(self::SESSION_KEY_PAGE, $page);\n\n $select = MFaqs::getInstance()->getListSelectEU($where);\n $this->view->max_display_char = Zynas_Registry::getConfig()->constants->max_display_char;\n $this->view->paginator = Zynas_Paginator::factoryWithOptions($select, $page, $this->view);\n Log::infoLog('method='.__FUNCTION__.';user_id='.Auth_Info::getUser()->user_id.';control_number'.';End action');\n }", "title": "" }, { "docid": "2bf2ec527100629f6d7d50c50d603001", "score": "0.6783082", "text": "function list() {\n /* fetches all entries in table student for listing.\n * ---------------------------------------------- */\n Debug::echo(\"GET /api/student/list\");\n \n $listAll = new ListAll();\n $listAll->main(); \n }", "title": "" }, { "docid": "ae6ac1129584c76c474a8718bca91c33", "score": "0.6780087", "text": "public function ListView() {\n $this->Render();\n }", "title": "" }, { "docid": "40e0ec86808c42433eec790a68931477", "score": "0.6770408", "text": "public function indexAction() {\n\t\t$this->view->assign('resources', $this->modelReflectionService->getResources());\n\t\t$this->view->assign('routes', $this->getRoutes());\n\t}", "title": "" }, { "docid": "c972e2ad36aea9593c2ac76cbc11b8bf", "score": "0.6767648", "text": "public function index()\n {\n return Restful::collection($this->getRepository()->all());\n }", "title": "" }, { "docid": "a611acae3e681926a6968198c5dab110", "score": "0.6765221", "text": "public function index()\n {\n $list = view('site.client.listing')->render();\n return $list;\n }", "title": "" }, { "docid": "602ed8dee2e015ea55511aa59ba3ed40", "score": "0.6761819", "text": "public function showList()\n {\n return view();\n }", "title": "" }, { "docid": "902d092c31e6544c2b9cf0edfb02ea3a", "score": "0.6750531", "text": "public function index()\n {\n return view('admin.listing.index')->withListings(Listing::all());\n }", "title": "" }, { "docid": "8eef2b9b847b9c58a5cfb5d664f2e780", "score": "0.6748404", "text": "public function listAction() {\n\t\tif ($this->request->hasArgument('selectedCategories')) {\n\t\t\t$selectedCategories = $this->request->getArgument('selectedCategories');\n\t\t\t$this->view->assign('objects', $this->exampleRepository->findByCategories($selectedCategories));\n\t\t\t$this->view->assign('selectedCategories', $this->categoriesRepository->findSelectedCategories($selectedCategories));\n\t\t} else {\n\t\t\t$this->view->assign('objects', $this->exampleRepository->findAll());\n\t\t}\n\t\t$this->view->assign('arguments', $this->request->getArguments());\n\t}", "title": "" }, { "docid": "21b5c64ea30098dcc23c030c81b33431", "score": "0.6747242", "text": "public function index()\n {\n //\n\n if (Auth::user()->hasRole('Admin')) {\n $resources = MyResource::latest()->paginate(5);\n } else {\n $resources = MyResource::where('user_id', Auth::user()->id)->latest()->paginate(5);\n }\n\n return view('resources.index', compact('resources'))\n ->with('i', (request()->input('page', 1) - 1) * 5);\n }", "title": "" }, { "docid": "04105211a75ba7457c72346a442bef90", "score": "0.6742193", "text": "function Index()\n\t\t{\n\t\t\t$this->DefaultParameters();\n\t\t\t\r\n\t\t\t$parameters = array('num_rows');\r\n\t\t\t$this->data[$this->name] = $this->controller_model->ListItemsPaged($this->request->get, '', $parameters);\r\n\t\t\t$this->data['num_rows'] = $parameters['num_rows'];\n\t\t}", "title": "" }, { "docid": "b6c185d0aed440370b1e22ff2d401da5", "score": "0.6724648", "text": "public function index()\n {\n $this->load->library('pagination');\n\n $count = $this->model->listingCount($this->listing_config);\n\n $returns = $this->paginationCompress( $this->config['page'].\"/\", $count, 15 );\n\n $data['objects'] = $this->model->listing($returns[\"per_page\"], $returns[\"segment\"],$this->listing_config);\n $data['pageVar'] = $this->config;\n $data['columns'] = $this->listing;\n $data['config'] = $this->listing_config;\n\n $this->global['pageTitle'] = $this->config['pageName'] ;\n\n $this->loadViews(\"admin/CRUD_R\", $this->global, $data, NULL);\n }", "title": "" }, { "docid": "ce95675bc5d2c976a855abe40a22da29", "score": "0.67158294", "text": "public function index()\n {\n // Get Books\n $books = Books::orderBy('created_at', 'desc') ->paginate(5);\n\n // Return collection of books as a resource\n return BooksResource::collection($books);\n }", "title": "" }, { "docid": "aa4f8e62dc57e3f9dd552a60b0f54091", "score": "0.67116815", "text": "public function ListView()\n\t{\n\t\t$this->Render();\n\t}", "title": "" }, { "docid": "aa4f8e62dc57e3f9dd552a60b0f54091", "score": "0.67116815", "text": "public function ListView()\n\t{\n\t\t$this->Render();\n\t}", "title": "" }, { "docid": "aa4f8e62dc57e3f9dd552a60b0f54091", "score": "0.67116815", "text": "public function ListView()\n\t{\n\t\t$this->Render();\n\t}", "title": "" }, { "docid": "afcbd1f71b8bf87347a3fa60719ba0be", "score": "0.67056316", "text": "public function index() {\n\t\t$datas = DAO::getAll ( $this->model );\n\t\techo $this->_getResponseFormatter ()->get ( $datas );\n\t}", "title": "" }, { "docid": "4bc4ef9abd1fba68e2b86b542b49eca2", "score": "0.67025477", "text": "public function listAction() {\n\t\t// Preload info\n\t\t$this->view->viewer = $viewer = Engine_Api::_ ()->user ()->getViewer ();\n\t\t$this->view->owner = $owner = Engine_Api::_ ()->getItem ( 'user', $this->_getParam ( 'user_id' ) );\n\t\tEngine_Api::_ ()->core ()->setSubject ( $owner );\n\n\t\tif (! $this->_helper->requireSubject ()->isValid ()) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Search Params\n\t\t$form = new Ynblog_Form_Search ();\n\t\t$form->isValid ( $this->_getAllParams () );\n\t\t$params = $form->getValues ();\n\t\t$params ['date'] = $this->_getParam ( 'date' );\n\t\t$this->view->formValues = $params;\n\n\t\t$params ['user_id'] = $owner->getIdentity ();\n\t\t$params ['draft'] = 0;\n\t\t$params ['is_approved'] = 1;\n\t\t$params ['visible'] = 1;\n\n\t\t// Get paginator\n\t\t$this->view->paginator = $paginator = Engine_Api::_ ()->ynblog ()->getBlogsPaginator ( $params );\n\t\t$items_per_page = Engine_Api::_ ()->getApi ( 'settings', 'core' )->getSetting ( 'ynblog.page', 10 );\n\t\t$paginator->setItemCountPerPage ( $items_per_page );\n\t\tif (isset ( $params ['page'] )) {\n\t\t\t$this->view->paginator = $paginator->setCurrentPageNumber ( $params ['page'] );\n\t\t}\n\t\t// Render\n\t\t$this->_helper->content->setEnabled ();\n\t}", "title": "" }, { "docid": "c2e0dc884bf03158662e5bf33ae92498", "score": "0.67018956", "text": "public function actionList()\n {\n if (!Parameters::hasParam('type'))\n throw new APIException('Invalid resource TYPE (parameter name: \\'type\\')', APIResponseCode::API_INVALID_METHOD_PARAMS);\n \n// if (!Parameters::hasParam('devkey'))\n// throw new APIException('Invalid application DEVELOPER KEY (parameter name: \\'devkey\\')', APIResponseCode::API_INVALID_METHOD_PARAMS);\n \n $resource_type = Parameters::get('type');\n// $devkey = Parameters::get('devkey');\n \n $finder = new YiiResourceFinder($resource_type);\n// $finder->setDevKey($devkey);\n $result = $finder->findAll();\n \n $dataSet = array();\n foreach ($result as $object) {\n $dataSet[] = $object->getAttributes();\n }\n \n $format = Parameters::hasParam('format') ? Parameters::get('format') : 'json';\n $coder = ObjectCodingFactory::factory()->createObject($format);\n if ($coder === null)\n throw new APIException('Invalid Coder for format', APIResponseCode::API_INVALID_CODER);\n \n $response = $coder->encode($dataSet);\n \n echo $response;\n }", "title": "" }, { "docid": "81277fc0f68d7bdc3634177cde0439a7", "score": "0.66943973", "text": "public function list()\n {\n $books = Book::visible();\n\n return $this->apiListingResponse($books, [\n 'id', 'name', 'slug', 'description', 'created_at', 'updated_at', 'created_by', 'updated_by', 'owned_by', 'image_id',\n ]);\n }", "title": "" }, { "docid": "7c934a7b8506c7db64d5ad367d48f525", "score": "0.6692943", "text": "public function listAction() {\n\t\t$this->view->title = $this->translator->translate(\"Servers list\");\n\t\t$this->view->description = $this->translator->translate(\"Here you can see all the servers.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"/admin/servers/new/\", \"label\" => $this->translator->translate('New'), \"params\" => array('css' => null)));\r\n\t\t$this->datagrid->setConfig ( Servers::grid() )->datagrid ();\n\t}", "title": "" }, { "docid": "59dfb79d5d5452f4f70e9cf4eec1e070", "score": "0.66803515", "text": "public function index()\n {\n //Get Articles\n\n $articles = Articles::paginate(15);\n\n // Return collection of articles as a resource\n return ArticlesResource::collection($articles);\n \n }", "title": "" }, { "docid": "88425de2823c6c6b170f46c36cff4af3", "score": "0.6677779", "text": "public function index()\n {\n $this->callHook('beforeIndex');\n $this->crud->hasAccessOrFail('list');\n\n $this->data[ 'crud' ] = $this->crud;\n $this->data[ 'title' ] = ucfirst($this->crud->entity_name_plural);\n\n // get all entries if AJAX is not enabled\n if ( !$this->data[ 'crud' ]->ajaxTable() ) {\n $this->data[ 'entries' ] = $this->data[ 'crud' ]->getEntries();\n }\n\n $this->callHook('afterIndex');\n\n // load the view from /resources/views/vendor/backpack/crud/ if it exists, otherwise load the one in the package\n return view($this->crud->getListView(), $this->data);\n }", "title": "" }, { "docid": "345876c650e46751471c85aa681fe81d", "score": "0.6673378", "text": "public function index()\n {\n //Get employees\n $employees = Employee::Paginate(15);\n //Return Employees as collection\n return EmployeeResource::collection($employees);\n }", "title": "" }, { "docid": "637eadb6ce19bd72fb45f6d4655ad277", "score": "0.66667867", "text": "public function listAction(){\r\n $userRepository = new \\Itb\\Model\\UserRepository();\r\n $users = $userRepository->getAll();\r\n\r\n $argsArray = ['users' => $users];\r\n $templateName = 'list';\r\n return $this->app['twig']->render($templateName . '.html.twig', $argsArray);\r\n }", "title": "" }, { "docid": "f3eff99c83c1adfe50ea93c0e478d078", "score": "0.66651416", "text": "public function index()\n {\n $students = Student::all();\n return (new StudentResourceCollection($students))->response();\n }", "title": "" }, { "docid": "4cfaa693b1306205053c160e2512565f", "score": "0.66650486", "text": "public function index()\n {\n $employees = Employee::all();\n return EmployeeForListResource::collection($employees);\n }", "title": "" }, { "docid": "f7578349cae5019055b4943e15786163", "score": "0.6661141", "text": "public function index()\n {\n //Get product\n $product = Products::paginate(15);\n \n //Return collection of product as a resource\n return ProductsResource::collection($product);\n }", "title": "" }, { "docid": "6f716fb0d645620791c39e3c2af2b242", "score": "0.66564786", "text": "function index() {\n Event::run('system.404');\n if ( ! A2::instance()->allowed('recruit', 'manage'))\n Event::run('system.403');\n \n $this->title = 'Manage Recruitment Lists';\n $this->lists = ORM::factory('recruit_list')->get();\n }", "title": "" }, { "docid": "5048b1d929efd7b88543fcf092cf843a", "score": "0.66558444", "text": "public function index()\n {\n return response(\n RecipeList::all()\n );\n }", "title": "" }, { "docid": "78496e0d8128f2673df1944c04d854e7", "score": "0.6653842", "text": "public function index()\n {\n $results = $this->Paginator->paginate($this->Results->find()->order(['created' => 'DESC']));\n $this->set(compact('results'));\n }", "title": "" }, { "docid": "2947b2c8c3c02fb9550821c40f31fc67", "score": "0.6650542", "text": "function list() {\n $data = $this->handler->handleList();\n\n $page = new Page(\"Roles\", \"Roles\");\n $page->top();\n\n listView($data);\n\n $page->bottom();\n }", "title": "" }, { "docid": "a2a6ac8b209515c5bee6b4f54354fdf5", "score": "0.66499305", "text": "public function index()\n {\n return LivreResource::collection(Livre::paginate(25));\n }", "title": "" }, { "docid": "726c696b08b65fb98a73b42e4ea85b29", "score": "0.6629493", "text": "public function index()\n {\n $products = Product::paginate(10);\n\n return ProductResource::collection($products);\n\n }", "title": "" }, { "docid": "c790cdb69ca9826f2d216ed3504b7bf4", "score": "0.66200316", "text": "public function list_( $args = array(), $assoc_args = array() ) {\n\n\t\t$assoc_args['all'] = 1;\n\n\t\t$this->get( $args, $assoc_args );\n\t}", "title": "" }, { "docid": "1d411fb7a37e8af4ad44010eef0ae6f9", "score": "0.66184205", "text": "public function index()\n {\n // Get the paginator using the parent API\n $paginator = $this->api()->index();\n\n // Show collection as a paginated table\n $collection = $paginator->getCollection();\n return $this->content('index', compact('paginator', 'collection'));\n }", "title": "" }, { "docid": "7d5ab4818059473cc9dd3d9aa19144cc", "score": "0.6611835", "text": "public function index()\n {\n $layanan = Layanan::paginate('15');\n return LayananResource::collection($layanan);\n }", "title": "" }, { "docid": "5284e0e8a629d94b2c297dec365035f8", "score": "0.6611247", "text": "function index(){\n\n\t\t$this->post_listing($start=0);\n\n\t}", "title": "" }, { "docid": "0b23f3dc133820a3f769ef803e71d588", "score": "0.6609974", "text": "public function listAction()\n\t{\n\t\t$module = $this->_useModules ? $this->_moduleName.'/' : '';\n\t\t\n\t\tZend_Paginator::setDefaultScrollingStyle('Sliding');\n\n\t\tZend_View_Helper_PaginationControl::setDefaultViewPartial('list.phtml');\n\n\t\t$this->_currentPage = $this->_getParam('page',1);\n\t\t$this->_currentPage = $this->_currentPage < 1 ? 1 : $this->_currentPage;\n\n\t\t$where = isset($this->_post->key) ? ($this->_post->key.\" like '%\".$this->_post->value.\"%'\") : null;\n\n\t\tif ($where == null)\n\t\t{\n\t\t\t$select = $this->_model->select()->\n\t\t\torder($this->_model->getOrderField())->\n\t\t\tlimit($this->_itemsPerPage,($this->_currentPage-1)*$this->_itemsPerPage);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$select = $this->_model->select()->\t\t\n\t\t\twhere($where)->\n\t\t\torder($this->_model->getOrderField())->\n\t\t\tlimit($this->_itemsPerPage,($this->_currentPage-1)*$this->_itemsPerPage);\t\t\t\n\t\t}\t\t\n\t\t\n\t\t$rows = $this->_model->fetchAll($select);\t\t\n\n\t\t$profile = $this->_profiler->getLastQueryProfile();\n\n\t\t$paginator = Zend_Paginator::factory($rows);\n\n\t\t$paginator->setCurrentPageNumber($thi->_currentPage)\n\t\t\t\t\t->setItemCountPerPage($this->_itemsPerPage);\n\t\t\n\t\t/** TODO get total of records for $totalOfItems \n\t\t * @var unknown_type\n\t\t */\n\t\t$totalOfItems = $this->_itemsPerPage;\n\n\t\t$this->_lastPage = (int)(($totalOfItems/$this->_itemsPerPage));\n\n\t\t$html = new Fgsl_Html();\n\n\t\t$html->addDecorator(Fgsl_Html_Constants::HTML_DECORATOR_TABLE);\n\n\t\t$records = array();\n\n\t\t$fieldKey = $this->_model->getFieldKey();\n\n\t\t$currentItems = $paginator->getCurrentItems();\n\t\tforeach ($currentItems as $row)\n\t\t{\n\t\t\t$records[] = array();\n\t\t\t\t\n\t\t\t$id = $row->$fieldKey;\n\t\t\t$records[count($records)-1][$this->_model->getFieldLabel($fieldKey)] = '<a href=\"'.BASE_URL.$module.$this->_controllerAction.'/edit/'.$fieldKey.'/'.$id.'\">'.$id.'</a>';\n\t\t\t\t\n\t\t\tforeach ($this->_fieldNames as $fieldName)\n\t\t\t{\n\t\t\t\tif ($fieldName == $fieldKey) continue;\n\t\t\t\t$records[count($records)-1][$this->_model->getFieldLabel($fieldName)] = $row->$fieldName;\n\t\t\t}\n\t\t\t\t\n\t\t\t$records[count($records)-1]['remove'] = '<a href=\"'.BASE_URL.$module.$this->_controllerAction.'/remove/'.$fieldKey.'/'.$id.'\">X</a>';\n\t\t}\n\t\t$this->_model->setRelationships($records);\t\t\n\t\t\n\t\t$this->_table = $html->create($records,Fgsl_Html_Constants::HTML_DECORATOR_TABLE);\t\t\n\n\t\t$this->configureViewAssign();\n\t\t$this->_view->render('list.phtml');\n\t}", "title": "" }, { "docid": "25424750ec44aa26547175ff6ccff0e1", "score": "0.66043633", "text": "public function index()\n {\n $posts = Post::listAllPublished();\n\n return PostResourceListing::collection($posts)->additional(['message' => 'ok', 'success' => true]);\n }", "title": "" }, { "docid": "7848eedd65d74e3882f897e7b74ca571", "score": "0.65999943", "text": "public function apiListsAction() {\n\t\t$api = $this->_param( 'api' );\n\n\t\tif ( ! $api || ! array_key_exists( $api, Thrive_Dash_List_Manager::available() ) ) {\n\t\t\texit();\n\t\t}\n\t\t$connection = Thrive_Dash_List_Manager::connectionInstance( $api );\n\n\t\techo $this->_view( 'partials/api-lists', array(\n\t\t\t'selected_api' => $connection,\n\t\t\t'connection' => $connection,\n\t\t\t'lists' => $connection->getLists( $this->_param( 'force_fetch' ) ? false : true )\n\t\t) );\n\n\t\texit();\n\t}", "title": "" }, { "docid": "71c5dbf8452cd67d212ff39d40f0c37d", "score": "0.65966225", "text": "public function index()\n {\n $students = Student::all();\n return StudentResource::collection($students);\n }", "title": "" }, { "docid": "15871bf4ada7393bc878944a01d437da", "score": "0.6594662", "text": "public function index()\n\t{\n\t\t$data['lists'] = $this->mdl_role->get_all();\n\t\t$this->template->set('title', 'Role List');\n\t\t$this->template->load('template', 'contents', 'role/list', $data);\n\t}", "title": "" }, { "docid": "41f78864c980c5b1e66654bd42f82083", "score": "0.65942985", "text": "public function listAction ()\n {\n $lans = new Application_Model_Mapper_LansMapper();\n $currentLans = $lans->fetchCurrent();\n $comingLans = $lans->fetchComing();\n $passedLans = $lans->fetchPassed();\n $this->view->currentLans = $currentLans;\n $this->view->comingLans = $comingLans;\n $this->view->passedLans = $passedLans;\n return;\n }", "title": "" }, { "docid": "af4f1232545bca0bcf287f1972d50981", "score": "0.6587391", "text": "public function listingAction() {\n\t\t$viewer = Engine_Api::_ ()->user ()->getViewer ();\n\t\t$params = $this -> _getAllParams();\n\t\t$ids = array ();\n\t\t// Do the show thingy\n\t\tif (isset($params ['by_authors'] ) && in_array('networks', $params['by_authors'])) \n\t\t{\n\t\t\t// Get an array of user ids\n\t\t\t\n\t\t\t$network_table = Engine_Api::_()->getDbtable('membership', 'network');\n \t\t$network_select = $network_table->select()->where('user_id = ?', $viewer -> getIdentity());\n \t\t$networks = $network_table->fetchAll($network_select);\n\t\t\tforeach($networks as $network)\n\t\t\t{\n\t\t\t\t$network_select = $network_table->select()->where('resource_id = ?', $network -> resource_id) -> where(\"active = 1\");\n \t\t\t$users = $network_table->fetchAll($network_select);\n\t\t\t\tforeach ( $users as $user ) {\n\t\t\t\t\t$ids [] = $user->user_id;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t}\n\t\tif (isset($params ['by_authors'] ) && in_array('professional', $params['by_authors'])) \n\t\t{\n\t\t\t$userIds = Engine_Api::_() -> user() -> getProfessionalUsers();\n\t\t\tforeach ($userIds as $id) {\n\t\t\t\t$ids [] = $id;\n\t\t\t}\n\t\t}\n\t\t\n\t\t$params ['users'] = $ids;\n\t\t\n\t\t// Get blog paginator\n\t\t$paginator = Engine_Api::_ ()->ynblog ()->getBlogsPaginator ( $params );\n\t\t$items_per_page = Engine_Api::_ ()->getApi ( 'settings', 'core' )->getSetting ( 'ynblog.page', 10 );\n\t\t$paginator->setItemCountPerPage ( $items_per_page );\n\n\t\tif (isset ( $params ['page'] )) {\n\t\t\t$paginator->setCurrentPageNumber ( $params ['page'] );\n\t\t}\n\t\t$this->view->paginator = $paginator;\n\t\t// Render\n\t\t$this->_helper->content->setEnabled ();\n\t}", "title": "" }, { "docid": "ca351a6c1fb5996a24802e4695371409", "score": "0.6585022", "text": "public function index()\n {\n $students = Student::all();\n \n return $this->sendResponse(StudentResource::collection($students), 'Students retrieved.');\n }", "title": "" }, { "docid": "ee362204073e5cbb647d776b2ab10940", "score": "0.6583899", "text": "public function indexAction()\n {\n $this->display();\n }", "title": "" }, { "docid": "ee0f12e894ffa19b553c5842d61bc92f", "score": "0.65838", "text": "public function list()\n {\n return view('Demo::list');\n }", "title": "" }, { "docid": "7e85268d6b01a017717a7d038d6b5c73", "score": "0.65802336", "text": "public function index()\n {\n $book = Book::paginate(2);\n return BookResource::collection($book);\n }", "title": "" }, { "docid": "8fd0dba76f9273c1033b432a513959af", "score": "0.65758175", "text": "public function doRestList()\n {\n $this->renderJson(array('success'=>true, 'message'=>'Records Retrieved Successfully', 'data'=>$this->getModel()->findAll()));\n }", "title": "" }, { "docid": "939f04db957f01973a6f0fa7f41c4007", "score": "0.657049", "text": "public function index()\n {\n $cond = Resource::where('id', '>', -1);\n $resources = $cond->get();\n\n $deviceList = [];\n foreach ($resources as $resource) {\n $data = [];\n $data['id'] = $resource->id;\n $data['name'] = $resource->name;\n $data['size'] = $resource->size;\n $data['created_at'] = $resource->created_at;\n\n array_push($deviceList, $data);\n }\n\n return view('resources', array('resources' => $deviceList));\n }", "title": "" }, { "docid": "d3d661b18964ba7ea7a108ea11a1a8a3", "score": "0.6568526", "text": "public function list ()\n {\n // Récupération de TOUS les articles avec le REPOSITORY\n // 1. Récupération du repository Article\n $articleRepository = $this->getDoctrine()\n ->getRepository(Article::class);\n\n // 2. Appel à la fonction findAll\n $liste = $articleRepository->findAll();\n\n // Renvoi de la liste à la vue\n return $this->render('article/list.html.twig', [\n 'listeArticles' => $liste\n ]);\n }", "title": "" }, { "docid": "7b5e2b301434be8bca6abbff68773c36", "score": "0.6567384", "text": "public function index()\n {\n return ProductResource::collection(Product::paginate(10));\n }", "title": "" }, { "docid": "81cae78d81b024602d92e06f78dd089e", "score": "0.65654266", "text": "public function list() {\n $article = new article();\n echo \"<h2 class='text-center m-5 border-bottom border-dark pb-5'>la page qui affiche la liste des articles</h2>\";\n $articleManager = $this->getDoctrine()->getRepository(article::class);\n $articles = $articleManager->findById();\n return $this->render('listeView.html.twig', ['articles' => $articles]);\n }", "title": "" }, { "docid": "b06d85985f7ef908e89d4534e8f29c97", "score": "0.6552259", "text": "public function index()\n {\n\t\t\treturn $this->respond($this->model\n ->orderBy('created_at', 'asc')\n ->findAll());\n }", "title": "" }, { "docid": "4d53d7254450e0c10db064ccddb74ae9", "score": "0.6551876", "text": "public function showAction()\n {\n $list = $this->listFactory->createList($this->dataBackend, $this->configurationBuilder);\n $renderedCaptions = $this->rendererChain->renderCaptions($list->getListHeader());\n $columnSelector = $this->columnSelectorFactory->getInstance($this->configurationBuilder);\n\n $this->view->assign('columnSelector', $columnSelector);\n $this->view->assign('listHeader', $list->getListHeader());\n $this->view->assign('listCaptions', $renderedCaptions);\n }", "title": "" }, { "docid": "e6be331bf6ee794db504703782e4abe5", "score": "0.65461046", "text": "public function index()\n {\n $items = Item::all();\n return view('list',compact('items'));\n }", "title": "" }, { "docid": "e8f09968b69af986e66d5cd3f404f3ad", "score": "0.6535171", "text": "public static function list() {\n $data = [\n 'pages' => PageService::get()\n ];\n\n Twig::render('pillar/layouts/pillar-pages', $data);\n }", "title": "" }, { "docid": "497bb71da959ab5e52433887d4acf412", "score": "0.6525618", "text": "public function listAction()\r\n {\r\n $form_data = $this->request->getArguments();\r\n \r\n $settings = GeneralUtility::makeInstance(ConfigurationObject::class);\r\n $itemsPerPage = (int)$settings->getPaginateItemsPerPage();\r\n\r\n if($form_data) {\r\n $objects = $this->objectimmoRepository->getAllObjectsBySearch($form_data);\r\n } else {\r\n $objects = $this->objectimmoRepository->getAllObjects();\r\n }\r\n \r\n $GLOBALS['TSFE']->fe_user->setKey('ses', 'search', $form_data);\r\n \r\n $count_objects = count($objects);\r\n\r\n $this->view->assign('objects', $objects);\r\n $this->view->assign('count_objects', $count_objects);\r\n $this->view->assign('itemsPerPage', $itemsPerPage);\r\n }", "title": "" }, { "docid": "365ef354e23f522e48d950c7ede25035", "score": "0.65234184", "text": "public function listAction()\n {\n return $this->render('task/list.html.twig',\n ['tasks' => $this->getDoctrine()->getRepository('AppBundle:Task')->findAllTask()]\n );\n }", "title": "" }, { "docid": "50b4e9cfb2f2db278dc000419368b6b9", "score": "0.65208316", "text": "public function index()\n {\n //Using Eloquent to get all the news in latest order. This is wil expose all the data\n //return Questions::latest()->get();\n\n //Use pagination\n //return Questions::latest()->paginate(1);\n\n //Using the \"QuestionResource\" API Resource wrapper to expose only the specified data without pagination\n //return QuestionResource::collection(Questions::latest());\n\n //Using the \"QuestionResource\" API Resource wrapper to expose only the specified data with pagination - set to return 5 items per page\n return QuestionResource::collection(Questions::latest()->paginate(5));\n\n }", "title": "" }, { "docid": "889d04be26f484433ced3afeb258119e", "score": "0.6518248", "text": "public function index()\n {\n return EmployeeResource::collection(Employee::paginate(10));\n }", "title": "" }, { "docid": "4ba8a9b727755a6ba7f5d1c4a619aff0", "score": "0.65151894", "text": "public function index()\n {\n return ReadingListBookResource::collection(ReadingListBook::all());\n }", "title": "" } ]
03487dc30480118e71749310c9e19b35
Get the line number that this constant ends on.
[ { "docid": "f3d6461969ca73b6aba39a144fbe4950", "score": "0.74187404", "text": "public function getEndLine(): int\n {\n return $this->endLine;\n }", "title": "" } ]
[ { "docid": "f7a4ffa64e0d81771bd5cf28358c47de", "score": "0.7402562", "text": "public function getEndLine(): int\n {\n return $this->property->getEndLine();\n }", "title": "" }, { "docid": "785a6db3030ae7172c9567e79c7f7312", "score": "0.7396242", "text": "public function lastLineIndex() {\n\t\treturn $this->m_nextLineIndex - 1;\n\t}", "title": "" }, { "docid": "e08225feb6463be28b6a592ce22eb65d", "score": "0.73475033", "text": "public function getLineNo(){\n\t\treturn $this->line_n;\n\t}", "title": "" }, { "docid": "f9611ccf56eddeae32b1295d63ac4f63", "score": "0.73460287", "text": "public function line(): int\n {\n return $this->line;\n }", "title": "" }, { "docid": "3906985b8f5f9c3206bb39aa213e7518", "score": "0.73269635", "text": "public function getLineNumber()\n {\n return $this->line;\n }", "title": "" }, { "docid": "de72881490d5c8164be13051b24b3236", "score": "0.72781914", "text": "public function getLineNumber()\n {\n return $this->lineNumber;\n }", "title": "" }, { "docid": "afb2b56d5dd571b93625d927e06edf52", "score": "0.72749245", "text": "public function getLine(): int\n {\n return $this->property->getLine();\n }", "title": "" }, { "docid": "8611074b55a4fd6dfe47b87767c73476", "score": "0.7250156", "text": "public function getLine(): int\n {\n return $this->getAttribute('startLine', -1);\n }", "title": "" }, { "docid": "da4e67ebd0238cddb68c66414a035153", "score": "0.7209601", "text": "public function getEndLine()\n\t{\n\t\treturn $this->reflection->getEndLine();\n\t}", "title": "" }, { "docid": "d31a5ca4e383a6c2c32499e24d823168", "score": "0.71927124", "text": "public static function line(): int\n {\n return debug_backtrace()[1]['line'];\n }", "title": "" }, { "docid": "8b1cc0d5f460e7e245b104922024a1e1", "score": "0.715819", "text": "public function getLineno()\n {\n return $this->lineno;\n }", "title": "" }, { "docid": "484fa3038364bf3e7cb44932cdc2d837", "score": "0.7128705", "text": "public function getLine() : int\n {\n return $this->line;\n }", "title": "" }, { "docid": "484fa3038364bf3e7cb44932cdc2d837", "score": "0.7128705", "text": "public function getLine() : int\n {\n return $this->line;\n }", "title": "" }, { "docid": "484fa3038364bf3e7cb44932cdc2d837", "score": "0.7128705", "text": "public function getLine() : int\n {\n return $this->line;\n }", "title": "" }, { "docid": "484fa3038364bf3e7cb44932cdc2d837", "score": "0.7128705", "text": "public function getLine() : int\n {\n return $this->line;\n }", "title": "" }, { "docid": "51daa1839e5c3d404557bd55739a3abe", "score": "0.7103101", "text": "public function getLineNumber()\n {\n return $this->fileHandle->key();\n }", "title": "" }, { "docid": "1912a726870ba78c74d871817403ca32", "score": "0.7078888", "text": "public function getLine(): int\n {\n return $this->line;\n }", "title": "" }, { "docid": "1912a726870ba78c74d871817403ca32", "score": "0.7078888", "text": "public function getLine(): int\n {\n return $this->line;\n }", "title": "" }, { "docid": "b4d6c72e2e29edc73b969a69cca16e1a", "score": "0.70618916", "text": "public function line() {\n\t\t\treturn $this->line;\n\t\t}", "title": "" }, { "docid": "0185932985cadd09d63a7c0c57ff306c", "score": "0.70538765", "text": "protected function getCurrentLine(): int\n {\n return $this->line;\n }", "title": "" }, { "docid": "d1b445c448ab85c10d3e3bea6a6e1213", "score": "0.70532787", "text": "function getlineno() {\n return $this->lineno;\n }", "title": "" }, { "docid": "7c7cacaac7088cdbfd9fc0b8823a5d0f", "score": "0.6941374", "text": "function get_line_number()\r\n\t{\r\n\t\tstatic $lineno = 0;\r\n\t\tstatic $index = 0;\r\n\t\tstatic $text = null;\r\n\t\tstatic $lines;\r\n\t\tif (is_null($text))\r\n\t\t{\r\n\t\t\t$text = explode(\"\\n\", $this->rawtext);\r\n\t\t\t$lines = count ($text);\r\n\t\t} \r\n\r\n\t\tfor (;$lineno < $lines;$lineno++)\r\n\t\t{\r\n\t\t\t$index += strlen($text[$lineno]);\r\n\t\t\tif ($index > $this->cur_byte_index)\r\n\t\t\t\treturn ($lineno + 1);\r\n\t\t} \r\n\t\treturn $lineno;\r\n\t}", "title": "" }, { "docid": "d9eee22ec03207c3ddb2fed290c30c99", "score": "0.68927366", "text": "public function getLine(): int\n {\n return $this->file->getLine($this->offset);\n }", "title": "" }, { "docid": "4df610031dc0f60d4d51c6fe21ba40fb", "score": "0.68913865", "text": "public function get_line_position() {\n return $this->line_position;\n }", "title": "" }, { "docid": "6015ea988029829b180e31a7706d6540", "score": "0.6882164", "text": "public function getLine()\n {\n return $this->getAttribute('startLine', -1);\n }", "title": "" }, { "docid": "a6d8bf04a869aad592d9880c1f1cee65", "score": "0.6856102", "text": "public function getStartingLine(): int\n {\n return $this->startingLine;\n }", "title": "" }, { "docid": "b82c2d2af54284787458e1a3d4522b0a", "score": "0.6834651", "text": "public function getEndLine()\n {\n return $this->iEndLine;\n }", "title": "" }, { "docid": "6d830f950bf2c9615db88fba2f4d2ee8", "score": "0.68194807", "text": "private function getLine() {\n\t\treturn $this->token['line'];\n\t}", "title": "" }, { "docid": "1e789b9419070a9baf367a5adffd2e92", "score": "0.68148863", "text": "public function getOriginalLineNo();", "title": "" }, { "docid": "7970b081994f292abbfd77e1e9b2f5ac", "score": "0.680268", "text": "public function getCurrentLine(): int;", "title": "" }, { "docid": "01bc076866eae8c5fc705606a8e2661a", "score": "0.6786871", "text": "public function getLine()\n {\n return $this->exception->getLine();\n }", "title": "" }, { "docid": "42bd6774dc247e573ce45b740a3ba6c8", "score": "0.6767284", "text": "public function nextLineIndex() {\n\t\treturn $this->m_nextLineIndex;\n\t}", "title": "" }, { "docid": "1de0ba74c1003b68ab4f127509f30f9c", "score": "0.6759643", "text": "public function getLineNumberStart(): int\n {\n return $this->line_number_start;\n }", "title": "" }, { "docid": "68ea14d221c01d2b21fda8ba848329b5", "score": "0.6754628", "text": "public function getCLine()\n {\n return $this->cLine;\n }", "title": "" }, { "docid": "8a864de8711897b452c5816a2bbb36f8", "score": "0.67526674", "text": "public function lastLinePos() {\n return $this->filePosition;\n }", "title": "" }, { "docid": "72fab7462d3829c1866ef706179d70e5", "score": "0.67364997", "text": "public function get_line()\n {\n return $this->line;\n }", "title": "" }, { "docid": "72fab7462d3829c1866ef706179d70e5", "score": "0.67364997", "text": "public function get_line()\n {\n return $this->line;\n }", "title": "" }, { "docid": "f5b2901e09b4d91a2239b1e24ad2777f", "score": "0.6691016", "text": "function get_current_line_number() {\n\t\treturn \txml_get_current_line_number($this->parser);\n\t\t\n\t}", "title": "" }, { "docid": "2bc1bce8a1b8e0b0d2ca681956c9bdb0", "score": "0.66101336", "text": "public function getEndLine()\n {\n return $this->endLine;\n }", "title": "" }, { "docid": "2bc1bce8a1b8e0b0d2ca681956c9bdb0", "score": "0.66101336", "text": "public function getEndLine()\n {\n return $this->endLine;\n }", "title": "" }, { "docid": "5a91ae3034074f54a8372abbf9779935", "score": "0.6601662", "text": "public function getStartLine()\n\t{\n\t\t$startLine = $this->reflection->getStartLine();\n\n\t\tif ($doc = $this->getDocComment()) {\n\t\t\t$startLine -= substr_count($doc, \"\\n\") + 1;\n\t\t}\n\n\t\treturn $startLine;\n\t}", "title": "" }, { "docid": "cd4e02f6d46b61f5a9de198aa8cee924", "score": "0.657378", "text": "public function line(): int|null\n\t{\n\t\t$reflection = $this->reflection();\n\n\t\tif (\n\t\t\t$reflection instanceof ReflectionClass ||\n\t\t\t$reflection instanceof ReflectionFunctionAbstract\n\t\t) {\n\t\t\treturn $reflection->getStartLine();\n\t\t}\n\n\t\treturn null;\n\t}", "title": "" }, { "docid": "8d3adf0036e6feeb90879504c6140dfe", "score": "0.6563348", "text": "public function getStartLine(): int\n {\n return $this->startLine;\n }", "title": "" }, { "docid": "e4913136b9a3c0aad7c400fa7975280b", "score": "0.6556993", "text": "public function fixedLineNumber()\n {\n return ltrim(static::numerify($this->generator->parse(\n static::randomElement(static::$fixedLineFormats)\n )));\n }", "title": "" }, { "docid": "44ffafd2f5c15437fa8e1ecbf4b884e9", "score": "0.65534365", "text": "public function getLineNumberNumeric()\n {\n return $this->lineNumberNumeric;\n }", "title": "" }, { "docid": "99d5fb4c169bb020bed42269ef37e070", "score": "0.6534402", "text": "public function line($number = 1)\n {\n return array_get($this->lines(), $number - 1);\n }", "title": "" }, { "docid": "e10c25edb92a09d7ab5f80187dc57b6d", "score": "0.6525717", "text": "public function getLine() {\n\n\t\treturn $this->line;\n\t}", "title": "" }, { "docid": "e10c25edb92a09d7ab5f80187dc57b6d", "score": "0.6525717", "text": "public function getLine() {\n\n\t\treturn $this->line;\n\t}", "title": "" }, { "docid": "4e8be25436f8643868522af68ae854c1", "score": "0.6518327", "text": "public function getLine() {\r\n return $this->line;\r\n }", "title": "" }, { "docid": "08360d2088e39637d98a39ff29984a83", "score": "0.6517098", "text": "protected function getCurrentlinenumber(){\n $filename = $this->file .'.txt';\n if (!file_exists($filename)) {\n return 1;\n } // First line\n else {\n $content = file_get_contents($filename); // Read the content of the file\n if (empty($content)) {\n return 1;\n } elseif($content == 'eof') {\n return 0;\n } else {\n return intval($content);\n }\n }\n }", "title": "" }, { "docid": "8f76c9c366f1c33fd1bcf5b8e64a3474", "score": "0.6470479", "text": "public function getOriginalLine() : int\n {\n return $this->originalLine;\n }", "title": "" }, { "docid": "c28492c0d670b907be3cf2e378a91456", "score": "0.6450316", "text": "abstract public function getEndLine();", "title": "" }, { "docid": "85680c9598e7bc6894fc5b0d98bb9008", "score": "0.64210033", "text": "protected function getLine(): string\n {\n return $this->node->getNode()->getStartLine();\n }", "title": "" }, { "docid": "c7793b3a5cb1bda4a6a8e913bb598b7b", "score": "0.64174503", "text": "function getLine()\n\t{\n\t\treturn $this->line;\n\t}", "title": "" }, { "docid": "57c5b4e2b15533ef437bbeb55ddc8d5f", "score": "0.6371113", "text": "public function getEndLine()\n {\n }", "title": "" }, { "docid": "7e5675dae1d944d4dc629953af4f3406", "score": "0.632458", "text": "public function getStartLine() : ?int\n {\n return $this->startLine;\n }", "title": "" }, { "docid": "89a3524e9d7bb0492f7ecb37b7151fa9", "score": "0.63175136", "text": "public function getLineEnd()\n {\n $this->scan();\n return $this->lineEnd;\n }", "title": "" }, { "docid": "fcec490afe3275146a1eaa35e79c91ef", "score": "0.6315556", "text": "public function getXmlLine()\r\n\t\t{\r\n\t\t\treturn($this->xml_error->line);\r\n\t\t}", "title": "" }, { "docid": "d151c3e17a40f6c847c76c6f864c466f", "score": "0.629004", "text": "public function getLine(){\n\t\treturn $this->line;\n\t}", "title": "" }, { "docid": "422b8ae220296cdbd06d9b215ccc3927", "score": "0.62693423", "text": "public function getLine()\n {\n return isset($this->line) ? $this->line : null;\n }", "title": "" }, { "docid": "1cefacacd65ac79631a022f05346a326", "score": "0.6263807", "text": "public function currentLine()\n {\n return isset($this->lines[$this->lineNumber - 1])\n ? $this->lines[$this->lineNumber - 1]\n : false;\n }", "title": "" }, { "docid": "6a5fea049b61e71f767582d0a78609ac", "score": "0.6208811", "text": "public function getSourceLine(): ?int;", "title": "" }, { "docid": "a36a37894f5e2f8dd21b4c71276e5fe0", "score": "0.6173053", "text": "public function getLineRef()\n {\n return $this->lineRef;\n }", "title": "" }, { "docid": "59d30c5604b5326c3713ff4113de6047", "score": "0.6160789", "text": "public function getOriginalStartLine() : ?int\n {\n return $this->originalStartLine;\n }", "title": "" }, { "docid": "b0430a0e028c894c92c4b5d9b368872c", "score": "0.61356115", "text": "function GetBarMaxLineNumber() {\r\n\t$m=0;\r\n\tif( $this->iObj != null ) {\r\n\t $m = $this->iObj[0]->GetLineNbr();\r\n\t for($i=1; $i<count($this->iObj); ++$i) {\r\n\t\t$m=max($m,$this->iObj[$i]->GetLineNbr());\r\n\t }\r\n\t}\r\n\treturn $m;\r\n }", "title": "" }, { "docid": "b62ae8c92dc2c017e408d2a35490cdd3", "score": "0.6109142", "text": "public function getNewLineNo();", "title": "" }, { "docid": "b7d49f107489b8441cb13fee63414068", "score": "0.6082331", "text": "protected static function _line($trace)\n {\n $path = $trace['file'];\n $callLine = $trace['line'];\n if (!file_exists($path)) {\n return;\n }\n $file = file_get_contents($path);\n if (($i = static::_findPos($file, $callLine)) === null) {\n return;\n }\n $line = $callLine;\n\n $brackets = 0;\n while ($i >= 0) {\n if ($file[$i] === ')') {\n $brackets--;\n } elseif ($file[$i] === '(') {\n $brackets++;\n } elseif ($file[$i] === \"\\n\") {\n $line--;\n }\n if ($brackets > 0) {\n return $line;\n }\n $i--;\n }\n }", "title": "" }, { "docid": "c0e801e257f1cff832873b924d09213a", "score": "0.6070518", "text": "public function getLineCount(): ?int\n {\n return $this->lineCount;\n }", "title": "" }, { "docid": "479d8bf8ba985c2eeda03b758a05bc37", "score": "0.6062369", "text": "public function getEndLine()\n\t{\n\t\treturn null;\n\t}", "title": "" }, { "docid": "b0f856e374bd08cb0b5129964aaacaf9", "score": "0.60623175", "text": "public function getLineCount() \n\t{\n\t if ($this->_lineCount === null) {\n\t $this->_lineCount = $this->_computeLineCount(); \n\t }\n\t return $this->_lineCount;\n\t}", "title": "" }, { "docid": "25df76be6240698ec1e310efebd3581c", "score": "0.605825", "text": "public function getContextLine()\n {\n return $this->context_line;\n }", "title": "" }, { "docid": "40be3b9ceba12caafd147972068a989e", "score": "0.604773", "text": "public function getSyntaxExceptionLine()\n {\n return $this->syntaxExceptionLine;\n }", "title": "" }, { "docid": "a20ccd0d71145cdc5cd5cc012b2ef082", "score": "0.6025172", "text": "public function getParsedLine(): int\n {\n return $this->parsedLine;\n }", "title": "" }, { "docid": "4796971006edbed699bfd4b0aedbd171", "score": "0.59657973", "text": "public function get_end_row(): int {\n return $this->end_row;\n }", "title": "" }, { "docid": "860844255b060df423139e53c7e1ed2c", "score": "0.5940788", "text": "public function getBeginLine()\n {\n return $this->iBeginLine;\n }", "title": "" }, { "docid": "765338760f70f789d9b6a1568fe14e4d", "score": "0.5911958", "text": "public function getLineNumber($a = null)\n {\n throw new NotImplementedException(__METHOD__);\n }", "title": "" }, { "docid": "9e470b251cd8d97a67915b237cf295ed", "score": "0.58997035", "text": "public function line(): ?string\n {\n return $this->line;\n }", "title": "" }, { "docid": "89449f6bd3af545ca259ea259e788d0f", "score": "0.58843255", "text": "public function getBreakpoint() : int\n {\n $rtn = $this->data['breakpoint'];\n\n return $rtn;\n }", "title": "" }, { "docid": "c7823d2c394aec9cf0c0cd8dbe37fd2d", "score": "0.5866832", "text": "public function getEndnoteStartNumber()\n {\n return $this->getNoteDocHead()->getEndnoteStartNumber();\n }", "title": "" }, { "docid": "4a5e8f8c824ede46e72f0dd9ebb21148", "score": "0.5845478", "text": "public function nextLine()\n {\n $this->lineNumber++;\n return $this->currentLine();\n }", "title": "" }, { "docid": "aa0bb062a9673c0794d84e531534800e", "score": "0.5794414", "text": "public function getSourceEndOffset(): ?int;", "title": "" }, { "docid": "4dc812282ba3cbee7b67fb58f6ed9bde", "score": "0.57923585", "text": "public function countLine() {\r\n if ($this->fileName) {\r\n $data = file($this->fileName);\r\n $lines = count($data)-1;\r\n\r\n return $lines;\r\n }\r\n }", "title": "" }, { "docid": "ae055b1470df4163a3c22fb2d08b78de", "score": "0.57453316", "text": "public function getSourceConnectedLineNum()\n {\n return $this->getKey('SourceConnectedLineNum');\n }", "title": "" }, { "docid": "76d0985c1e06daf7616ae30ba5c4edbc", "score": "0.5739992", "text": "public function lineCount()\n\t{\n\t\t$curPos=$this->ftell();\n\n\t\t$x=0;\n\t\twhile(!($this->eof()))\n\t\t{\n\t\t\t$this->current();\n\t\t\t$x++;\n\t\t\t$this->next();\n\t\t}\n\n\t\t$this->fseek($curPos); // Return to the position we were in when the function was called\n\t\treturn $x-1;\n\t}", "title": "" }, { "docid": "acc43a5819c4db45aa0336d031cca4ae", "score": "0.5723294", "text": "public function lineCount() {\n\t\treturn $this->lines->count();\n\t}", "title": "" }, { "docid": "b25b3b439dc108a05c4ac9f16bb48241", "score": "0.57086235", "text": "function calculate_line_number($offset, $file_content) {\n list($first_part) = str_split($file_content, $offset); // fetches all the text before the match\n $line_nr = strlen($first_part) - strlen(str_replace(\"\\n\", \"\", $first_part)) + 1;\n return $line_nr;\n}", "title": "" }, { "docid": "6156d5b0795a5d431fd524c02ecdb578", "score": "0.5701063", "text": "private function findEnd(){\r\n $factor = $this->row * 2 + 1;\r\n $this->endNum = pow($factor,2)+1;\r\n }", "title": "" }, { "docid": "a2a6f48a44a9670c529ffb8a24936d8e", "score": "0.5687513", "text": "public function getOrderReqLineNo()\n {\n return $this->order_req_line_no;\n }", "title": "" }, { "docid": "4e9245874990698a21ff7bcc5dc4595c", "score": "0.5687087", "text": "public function line($line) {\n\t\tif ($this->lines->hasValueForKey($line - 1)) {\n\t\t\treturn $this->lines[$line - 1];\n\t\t}\n\t\treturn '';\n\t}", "title": "" }, { "docid": "2df82ba5867e9ba18d301d0091606a3b", "score": "0.56867594", "text": "protected function getLastBatchNo(): int\n {\n return $this->lastBatchNo;\n }", "title": "" }, { "docid": "5479e31a75638091c1b29f9ac2530329", "score": "0.56866527", "text": "public function getCharPositionInLine();", "title": "" }, { "docid": "4b954a2f56fdd90b14e2968cfed03941", "score": "0.56865495", "text": "public function getLine() {\n\t\treturn count( explode( \"\\n\" , substr( $this->input , 0 , $this->cursor ) ) );\n\t}", "title": "" }, { "docid": "d95dfc49b9b28068d5ceccaa57523cb8", "score": "0.5663757", "text": "abstract public function getStartLine();", "title": "" }, { "docid": "f19ff631749c02cc965c77eb1943f8a2", "score": "0.56597114", "text": "public function getStartLine()\n {\n return $this->startLine;\n }", "title": "" }, { "docid": "f19ff631749c02cc965c77eb1943f8a2", "score": "0.56597114", "text": "public function getStartLine()\n {\n return $this->startLine;\n }", "title": "" }, { "docid": "b134f6cd854cd632ed3748d476c20e1a", "score": "0.5645524", "text": "protected function getNextTypoScriptLine() {\n\t\t$typoScriptLine = current($this->currentSourceCodeLines);\n\t\tnext($this->currentSourceCodeLines);\n\t\t$this->currentLineNumber++;\n\t\treturn $typoScriptLine;\n\t}", "title": "" }, { "docid": "1599e1d28764c0b20187c0584ea48d99", "score": "0.5599442", "text": "public function getContextLine(): ?string\n {\n return $this->contextLine;\n }", "title": "" }, { "docid": "27e542d2843f85437933c5c7831df7ad", "score": "0.5588843", "text": "public function getEndColumn()\n {\n return $this->iEndColumn;\n }", "title": "" }, { "docid": "8c4a5b6155627b3f4806924a2db00a58", "score": "0.55837375", "text": "public function lineItemId()\n {\n return ($this->pivot ? $this->pivot->provider_line_item_id : 0);\n }", "title": "" }, { "docid": "fe993649a41b08e873026a27488a0838", "score": "0.5577529", "text": "public function setLineno($var)\n {\n GPBUtil::checkInt32($var);\n $this->lineno = $var;\n\n return $this;\n }", "title": "" } ]
263140b6466473379c8455b4635a57cc
Tests passing invalid uuid bin
[ { "docid": "41fb49c1bc07dbfe1c74558f4a1d8b44", "score": "0.8700198", "text": "public function test_invalid_uuid_bin() {\n\t\t$this->expectException(KO7_Exception::class);\n\t\tUUID::bin('invalid');\n\t}", "title": "" } ]
[ { "docid": "83693b9e664b1b3360936004c89d6965", "score": "0.85101193", "text": "public function testUuid() {\n $this->assertTrue(Validate::uuid('a8293fde-ce92-9abe-83de-7294ab29cd03'));\n\n $this->assertFalse(Validate::uuid('a8293fde-ce92-83de-7294ab29cd03'));\n $this->assertFalse(Validate::uuid('a8293de-ce92-9abe-83de-7294ab29cd'));\n $this->assertFalse(Validate::uuid('a8293kq-ce92-9abe-83de-729pdu29cd03'));\n }", "title": "" }, { "docid": "9f4df303b547d49ef092d950d455f5fa", "score": "0.7623985", "text": "public function testUUIDStructure()\n {\n $oGenerator = oxNew('oxUniversallyUniqueIdGenerator');\n $sId = $oGenerator->generate();\n\n $this->assertRegExp('/^[\\w]{8}-[\\w]{4}-[\\w]{4}-[\\w]{4}-[\\w]{12}$/', $sId);\n }", "title": "" }, { "docid": "447570a57c8cc3b89ffd8340d7fad611", "score": "0.7577271", "text": "static function isUuid($str) {\n return is_string($str) && preg_match('/^[A-Fa-f0-9]{8}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{12}$/', $str);\n }", "title": "" }, { "docid": "a6dbbc73442b504202de76f8d1c37ca8", "score": "0.75725144", "text": "function testUUID($uuidInput)\n {\n // Test the input and see if it matches\n if (!preg_match(\"/^([0-9a-fA-F]{6})$/\", $uuidInput))\n {\n // Return false if it does not\n return false;\n }\n // Return true if the uuid is valid\n return true;\n }", "title": "" }, { "docid": "4e0910928ca09eebc22697bc1b2d9277", "score": "0.7544617", "text": "public function testHasInvalidUuid(): void\n {\n $uuid = '123';\n $this->assertFalse($this->driver->has($uuid));\n }", "title": "" }, { "docid": "760bef899cac71630a241a208008bd63", "score": "0.74515444", "text": "public function testUuidV4()\n {\n $a = \\Nofuzz\\Helpers\\UUID::v4();\n\n $this->assertTrue( strlen($a)>0 );\n }", "title": "" }, { "docid": "f32e45b27d1c8a2f2f8d1bbeb4623d8e", "score": "0.6875518", "text": "public function testUuidV5()\n {\n $a = \\Nofuzz\\Helpers\\Uuid::v5( 'fe590d59-b698-4246-98a0-521e31427ee4', 'Glorius');\n\n $this->assertEquals( '0eeda2f3-b68c-5ae7-a0ab-cc14eac039db',$a );\n }", "title": "" }, { "docid": "cc8d89f458d56db70a92722376c37481", "score": "0.6816072", "text": "public function test_invalid_namespace_v5() {\n\t\t$this->expectException(KO7_Exception::class);\n\t\tUUID::v5('invalid', 'koseven');\n\t}", "title": "" }, { "docid": "6483b2273c000cee34072ea87f96f195", "score": "0.6791902", "text": "static function getUUIDRestrictCriteria($uuid) {\n\n //More infos about uuid, please see wikipedia :\n //http://en.wikipedia.org/wiki/Universally_unique_identifier\n //Some uuid are not conform, so preprocessing is necessary\n //A good uuid likes lik : 550e8400-e29b-41d4-a716-446655440000\n\n //Case one : for example some uuid are like that :\n //56 4d 77 d0 6b ef 3d da-4d 67 5c 80 a9 52 e2 c9\n $pattern = \"/([\\w]{2})\\ ([\\w]{2})\\ ([\\w]{2})\\ ([\\w]{2})\\ \";\n $pattern .= \"([\\w]{2})\\ ([\\w]{2})\\ ([\\w]{2})\\ ([\\w]{2})-\";\n $pattern .= \"([\\w]{2})\\ ([\\w]{2})\\ ([\\w]{2})\\ ([\\w]{2})\\ \";\n $pattern .= \"([\\w]{2})\\ ([\\w]{2})\\ ([\\w]{2})\\ ([\\w]{2})/\";\n if (preg_match($pattern, $uuid)) {\n $uuid = preg_replace($pattern, \"$1$2$3$4-$5$6-$7$8-$9$10-$11$12$13$14$15$16\", $uuid);\n }\n\n //Case two : why this code ? Because some dmidecode < 2.10 is buggy.\n //On unix is flips first block of uuid and on windows flips 3 first blocks...\n $in = [strtolower($uuid)];\n $regexes = [\n \"/([\\w]{2})([\\w]{2})([\\w]{2})([\\w]{2})(.*)/\" => \"$4$3$2$1$5\",\n \"/([\\w]{2})([\\w]{2})([\\w]{2})([\\w]{2})-([\\w]{2})([\\w]{2})-([\\w]{2})([\\w]{2})(.*)/\" => \"$4$3$2$1-$6$5-$8$7$9\"\n ];\n foreach ($regexes as $pattern => $replace) {\n $reverse_uuid = preg_replace($pattern, $replace, $uuid);\n if ($reverse_uuid) {\n $in[] = strtolower($reverse_uuid);\n }\n }\n\n return $in;\n }", "title": "" }, { "docid": "ba393ea5ab73ae412113d0a89faa43b8", "score": "0.67914546", "text": "public function testUUIDV5Structure()\n {\n $oGenerator = oxNew('oxUniversallyUniqueIdGenerator');\n $sId = $oGenerator->generateV5('seed', 'salt');\n\n $this->assertRegExp('/^[\\w]{8}-[\\w]{4}-[\\w]{4}-[\\w]{4}-[\\w]{12}$/', $sId);\n }", "title": "" }, { "docid": "bb2bd40c8942a369981a1158e334f897", "score": "0.67781657", "text": "public function testUUIDV4Structure()\n {\n $oGenerator = oxNew('oxUniversallyUniqueIdGenerator');\n $sId = $oGenerator->generateV4();\n\n $this->assertRegExp('/^[\\w]{8}-[\\w]{4}-[\\w]{4}-[\\w]{4}-[\\w]{12}$/', $sId);\n }", "title": "" }, { "docid": "3352b30e1d47e5e95194aeb32888124f", "score": "0.67759776", "text": "public function testGuid() {\n if (function_exists('openssl_random_pseudo_bytes')) {\n $guid = LongCiteUtil::generateOpensslGuid();\n $this->assertNotFalse($guid);\n $this->assertRegExp('/^[0-9A-F]{32}$/',$guid); \n }\n $guid = LongCiteUtil::generateGenericGuid();\n $this->assertNotFalse($guid);\n $this->assertRegExp('/^[0-9A-F]{32}$/',$guid); \n }", "title": "" }, { "docid": "2b751cbeda50df7d320297df0fd59650", "score": "0.67630243", "text": "private static function validateUuid($newUuid) : Uuid {\n\t\t// verify a Uuid in string format\n\t\tif(gettype($newUuid) === \"string\") {\n\t\t\t// 16 character is binary from mySQL\n\t\t\tif(strlen($newUuid) === 16) {\n\t\t\t\t$newUuid = bin2hex($newUuid);\n\t\t\t\t$newUuid = substr($newUuid, 0, 8) . \"-\" . substr($newUuid, 8, 4) . \"-\" .\n\t\t\t\t\tsubstr($newUuid, 12, 4) . \"-\" . substr($newUuid, 16, 4) . \"-\" .\n\t\t\t\t\tsubstr($newUuid, 20, 12);\n\t\t\t}\n\t\t\t// 36 characters is human readable uuid format\n\t\t\tif(strlen($newUuid) === 36) {\n\t\t\t\tif(Uuid::isValid($newUuid) === false) {\n\t\t\t\t\tthrow(new\\InvalidArgumentException(\"uuid is invalid\"));\n\t\t\t\t}\n\t\t\t\t$uuid = Uuid::fromString($newUuid);\n\t\t\t} else {\n\t\t\t\tthrow(new\\InvalidArgumentException(\"uuid is invalid\"));\n\t\t\t}\n\t\t} else if (getType($newUuid) === \"object\" && get_class($newUuid) === \"Ramsey\\\\Uuid\\\\Uuid\") {\n\t\t\t$uuid = $newUuid;\n\t\t} else {\n\t\t\t// for anything not defined\n\t\t\tthrow(new\\InvalidArgumentException(\"uuid is invalid\"));\n\t\t}\n\t\t// verify that uuid is uuid v4\n\t\tif($uuid->getVersion() !== 4){\n\t\t\tthrow(new\\RangeException(\"uuid is incorrect version\"));\n\t\t}\n\t\treturn($uuid);\n\t}", "title": "" }, { "docid": "bb48dbdd6f0052bd2aa1a6a7933df3f2", "score": "0.67577696", "text": "public static function isUUID($value) {\n \ttry {\n if(\\Glue\\Helper\\Validator::batch(array(\n '$value' => array($value, 'isString')\n )) !== true) {\n return false;\n }\n\n\t\t\treturn (preg_match('/^\\{?[0-9a-f]{8}\\-?[0-9a-f]{4}\\-?[0-9a-f]{4}\\-?[0-9a-f]{4}\\-?[0-9a-f]{12}\\}?$/i', $value) === 1);\n\t\t} catch(\\Exception $exception) {\n\t\t\tthrow new \\RuntimeException(\\Glue\\Helper\\General::replace(array('method' => __METHOD__), GLUE_EXCEPTION_METHOD_FAILED), NULL, $exception);\n\t\t}\n\t}", "title": "" }, { "docid": "a3d0d5628cd99d48db89111bceae0fcb", "score": "0.6695258", "text": "public function test_bin_str(string $value, $expected)\n\t{\n\t\t$bin = UUID::bin($value);\n\t\tself::assertEquals($expected, bin2hex($bin));\n\t\tif ($expected !== FALSE)\n\t\t{\n\t\t\tself::assertEquals($value, UUID::str($bin));\n\t\t}\n\t}", "title": "" }, { "docid": "28670bd90a48457fe36845c228bc51aa", "score": "0.665519", "text": "public function isUUID(string $maybeUUID): bool\n {\n // This regex can probably be shortened, but this one only takes 16 steps.\n $regexp = '/[\\da-f]{8}-(?:[\\da-f]{4}-){3}[\\da-f]{12}/i';\n\n return (1 === preg_match($regexp, trim($maybeUUID)));\n }", "title": "" }, { "docid": "b7531102223ccb115ee6ea4c212b479e", "score": "0.6616182", "text": "function testGnGetUUIDOfRecordByIDCommand() {\n\n\t\t$data = array();\n\t\t$data['gnID'] = 1963;\n\t\t\n\t\t$cmd = $this->controller->getCommand(\"GnGetUUIDOfRecordByID\", $data);\n\t\t$result = $cmd->execute();\n\t\t\n\t\t$this->assertEquals($result,'0587e442-eaee-470d-a0d1-3e3a54cc983b','Invalid UUID. ');\n\t}", "title": "" }, { "docid": "f999d59f789fec2ee75615757f963e4e", "score": "0.65839666", "text": "public function testHexValidation()\n {\n $this->expectException(Error::class);\n hexToRgba('FFFFFG');\n }", "title": "" }, { "docid": "fe48cd2eab5c46ec8f0dcb22f06fad3a", "score": "0.65591675", "text": "public function testGeneratedUUID()\n\t{\n\t\t$this->assertContains('PieChart_', $this->chart->uuid());\n\t}", "title": "" }, { "docid": "b81ec9ea700f1583ea9d56814086c994", "score": "0.6510098", "text": "public function testInsertValidBytes() {\n\t\t$uuid = Uuid::fromBytes($this->VALID_BYTES);\n\t\t$this->assertInstanceOf(\"Ramsey\\\\Uuid\\\\Uuid\", $uuid);\n\t\t$this->VALID_OBJECT->setUuid($this->VALID_BYTES);\n\t\t$this->assertInstanceOf(\"Ramsey\\\\Uuid\\\\Uuid\", $this->VALID_OBJECT->getUuid());\n\t}", "title": "" }, { "docid": "f4fe477760e0f67c4dd803cb898c3da9", "score": "0.6508612", "text": "public function testInsertValidString() {\n\t\t$uuid = Uuid::fromString($this->VALID_STRING);\n\t\t$this->assertTrue(Uuid::isValid($this->VALID_STRING));\n\t\t$this->assertInstanceOf(\"Ramsey\\\\Uuid\\\\Uuid\", $uuid);\n\t\t$this->VALID_OBJECT->setUuid($this->VALID_STRING);\n\t\t$this->assertInstanceOf(\"Ramsey\\\\Uuid\\\\Uuid\", $this->VALID_OBJECT->getUuid());\n\t}", "title": "" }, { "docid": "dc798cdc5d071583a99514a488bc99ff", "score": "0.6500751", "text": "function libvirt_nwfilter_get_uuid($res) : string|false\n{\n}", "title": "" }, { "docid": "e97b1c55dd0389723c5e4ff6c402a86b", "score": "0.6471459", "text": "function libvirt_nwfilter_get_uuid_string($res) : string|false\n{\n}", "title": "" }, { "docid": "42e8338a1eba17ba78c2b51381258996", "score": "0.64706093", "text": "function libvirt_network_get_uuid($res) : string|false\n{\n}", "title": "" }, { "docid": "705efbcfcb99892dcb81e18b8e8d0f6d", "score": "0.64674765", "text": "public function testHexLengthValidation()\n {\n $this->expectException(Error::class);\n hexToRgba('FFFFF', 1);\n }", "title": "" }, { "docid": "b3d37af93194001de7454aa32c09e915", "score": "0.6429883", "text": "public function test_invalid_namespace_v3() {\n\t\t$this->expectException(KO7_Exception::class);\n\t\tUUID::v3('invalid', 'koseven');\n\t}", "title": "" }, { "docid": "9ea89411b2f7e1953144b89eba412dfe", "score": "0.6390163", "text": "function libvirt_network_get_uuid_string($res) : string|false\n{\n}", "title": "" }, { "docid": "b3f556e540b1db08a5b52c17e576c848", "score": "0.63441163", "text": "private function validateUuid($uuid): UuidInterface\n {\n if (\\is_string($uuid)) {\n $uuid = Uuid::fromString($uuid);\n }\n if (!$uuid instanceof UuidInterface) {\n throw new \\InvalidArgumentException(\\sprintf(\"Aggregate identifier must be a valid UUID string or instanceof of %s: '%s' given\", UuidInterface::class, (string)$uuid));\n }\n return $uuid;\n }", "title": "" }, { "docid": "f02305b63455fe3e1208d9a21a545ba9", "score": "0.629106", "text": "public function testValidateWithoutPrefix()\n\t{\n\n\n\t\t$out = null;\n\t\t$this->assertFalse(Binary::validateWithoutPrefix(\"\", $out), \"empty string should be false\");\n\t\t$this->assertNull($out);\n\n\t\t$rand = rand(1,11);\n\t\tif($rand % 2 == 0) $rand++; //make it odd\n\n\t\t$input = str_repeat(uniqid(), $rand);\n\t\t$this->assertFalse(Binary::validateWithoutPrefix($input, $out), \"odd numbered length string should be false\");\n\t\t$this->assertNull($out);\n\n\n\t\t$input = '1234567890abcdefABCDEF';\n\t\t$this->assertTrue(Binary::validateWithoutPrefix($input, $out), \"These characters should work\");\n\t\t//Expect values for each individual byte\n\t\t$expected = array(\n\t\t\thexdec('1') << 4 + hexdec('2'),\n\t\t\thexdec('3') << 4 + hexdec('4'),\n\t\t\thexdec('5') << 4 + hexdec('6'),\n\t\t\thexdec('7') << 4 + hexdec('8'),\n\t\t\thexdec('9') << 4 + hexdec('0'),\n\t\t\thexdec('a') << 4 + hexdec('b'),\n\t\t\thexdec('c') << 4 + hexdec('d'),\n\t\t\thexdec('e') << 4 + hexdec('f'),\n\t\t\thexdec('A') << 4 + hexdec('B'),\n\t\t\thexdec('C') << 4 + hexdec('D'),\n\t\t\thexdec('E') << 4 + hexdec('F'),\n\n\t\t);\n\t\t$this->assertEquals($expected, $out);\n\n\t\t$input = '1234567890abcdefABCDXX';\n\t\t$this->assertFalse(Binary::validateWithoutPrefix($input, $out), \"Invalid character X anywhere in string should fail\");\n\t\t//Expect values for each individual byte\n\t\t$this->assertNull($out);\n\t}", "title": "" }, { "docid": "1c0d808379bc037f65d2bfaee4be76af", "score": "0.6236519", "text": "function get_uuid(string $body): string|bool {\n $pattern = '/uuid=3D([0-9a-z-=]+)&/';\n $success = preg_match($pattern, $body, $uuid);\n return ($success) ? str_replace('=', '', $uuid[1]) : false;\n}", "title": "" }, { "docid": "8d5afad6711a1232581d9f5e0aa6a7bd", "score": "0.61935943", "text": "public function testNationalId() {\n $pattern = '/(?:^V-?\\d{5,9}$)|(?:^E-?\\d{8,9}$)/';\n\n $cedula = $this->faker->nationalId;\n $this->assertRegExp($pattern, $cedula);\n\n $cedula = $this->faker->nationalId('-');\n $this->assertRegExp($pattern, $cedula);\n }", "title": "" }, { "docid": "427891923f6788c75954097dabdbc0de", "score": "0.60665953", "text": "function isFilesystemUuid(string $uuid)\n{\n\t$matches = [];\n\tpreg_match(\n\t\t\"/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/\",\n\t\t$uuid,\n\t\t$matches\n\t);\n\treturn count($matches) == 1 && $matches[0] == $uuid;\n}", "title": "" }, { "docid": "9d0e0822c782f0449a551ba1db6435b6", "score": "0.6033483", "text": "public function isValid($value)\n {\n if (! is_string($value)) {\n $this->error(self::NOT_STRING);\n return false;\n }\n\n $this->setValue($value);\n\n if (empty($value)\n || $value !== '00000000-0000-0000-0000-000000000000'\n && ! preg_match(self::REGEX_UUID, $value)\n ) {\n $this->error(self::INVALID);\n return false;\n }\n\n return true;\n }", "title": "" }, { "docid": "79de545c9d5c19d90877719a26c7e1cc", "score": "0.6027803", "text": "function isUid($input)\n{\n $pattern = \"/^[a-zA-Z0-9]{64}$/\";\n return preg_match($pattern, $input);\n}", "title": "" }, { "docid": "60ecb2e8c3cf42cb2a20bba8bfd65172", "score": "0.60273814", "text": "function __construct($uuid = null)\n {\n if (null === $uuid){\n $this->_bin = Ban_Util_Uuid::gen();\n return;\n }\n $len = strlen($uuid);\n if ($len === 16) {\n $this->_bin = $uuid;\n }\n elseif ($len === 32) {\n $this->_hex = $uuid;\n }\n elseif ($len === 36) {\n $uuid = str_replace('-', '', $uuid);\n $this->_hex = $uuid;\n }\n else {\n throw new Exception('Invalid uuid');\n }\n }", "title": "" }, { "docid": "d87d7633f28fab4d62c1af9e27d36923", "score": "0.6008465", "text": "public function test_invalid_calls() {\n $this->assertEquals(\n null,\n GenerateHash(\"foobar12\", \"rc4\")\n );\n\n $this->assertEquals(\n null,\n GenerateHash(\"foobar12\", -1)\n );\n }", "title": "" }, { "docid": "c9c44391f6b33164442e56fa128d4e2f", "score": "0.5998034", "text": "function libvirt_domain_get_uuid($res) : string\n{\n}", "title": "" }, { "docid": "9aae59a0e881c2a0a82a1927957e4ece", "score": "0.5992818", "text": "public function test_invalid_characters() {\n\t\t$result = $this->registry->register( 'still/_doing_it_wrong', array() );\n\t\t$this->assertFalse( $result );\n\t}", "title": "" }, { "docid": "2f4f4a8e7225f4a0f5d5126ffcd53384", "score": "0.5974282", "text": "public function testUUIDV5UniquenessWithDifferentSalt()\n {\n $oGenerator = oxNew('oxUniversallyUniqueIdGenerator');\n\n $aIds = array();\n for ($i = 0; $i < 100; $i++) {\n $aIds[] = $oGenerator->generateV5('seed', 'salt' . $i);\n }\n\n $this->assertEquals(100, count(array_unique($aIds)));\n }", "title": "" }, { "docid": "9a6b9b2f58903aab44b3ca23cde4ff22", "score": "0.597033", "text": "function libvirt_domain_get_uuid_string($res) : string\n{\n}", "title": "" }, { "docid": "83d8a4b01da568fb27aa50cd58517aa3", "score": "0.5962666", "text": "public function testValidNir() {\n\t\t\t$result = valid_nir( '179012A00123471' );\n\t\t\t$expected = true;\n\t\t\t$this->assertEqual( $result, $expected, var_export( $result, true ) );\n\n\t\t\t$result = valid_nir( 'A79012A00123471' );\n\t\t\t$expected = false;\n\t\t\t$this->assertEqual( $result, $expected, var_export( $result, true ) );\n\t\t }", "title": "" }, { "docid": "31e7c2a6b0299adfdf3438a49f75629c", "score": "0.5904618", "text": "public function testUUIDV4UniquenessWhenInFallbackMode()\n {\n $oCheckerMock = $this->getMock(\\OxidEsales\\Eshop\\Core\\OpenSSLFunctionalityChecker::class, array('isOpenSslRandomBytesGeneratorAvailable'));\n $oCheckerMock->expects($this->any())->method('isOpenSslRandomBytesGeneratorAvailable')->will($this->returnValue(false));\n /** @var oxOpenSSLFunctionalityChecker $oChecker */\n $oChecker = $oCheckerMock;\n\n $oGenerator = new oxUniversallyUniqueIdGenerator($oChecker);\n\n $aIds = array();\n for ($i = 0; $i < 100; $i++) {\n $aIds[] = $oGenerator->generateV4();\n }\n\n $this->assertEquals(100, count(array_unique($aIds)));\n }", "title": "" }, { "docid": "4a5b0fd3e24cd15e1198138823b7bdeb", "score": "0.5891066", "text": "protected function isUuidGenerator(mixed $value)\n {\n return is_string($value) && str_starts_with($value, 'uuid_generate_v');\n }", "title": "" }, { "docid": "88748044819228c4afa8f27f0c8840f6", "score": "0.5852559", "text": "public function isUuid4($value) {\n $valid = ( preg_match(self::UUID4_REGEX, $value) === 1 );\n return $valid;\n }", "title": "" }, { "docid": "3503e1f2266351f69e4cf003758ef9d6", "score": "0.5847762", "text": "public function test_invalidChars()\n {\n $this->post('/mutants', ['dna' => [\"ATGTG\", \"CAGCC\", \"TTAAT\", \"TTAGX\", \"CTAGX\"]]);\n $this->assertResponseStatus(422);\n }", "title": "" }, { "docid": "046df9344f526cf368ab51a3ca0c709c", "score": "0.58432704", "text": "function invalidUid($username) {\n\n $result;\n if (!preg_match(\"/^[a-zA-Z0-9]*$/\", $username)){\n $result = true;\n }else{\n $result = false;\n }\n return $result;\n\n}", "title": "" }, { "docid": "66d5126440f7165df683a128b34ff8c3", "score": "0.5814369", "text": "public function uuid() { }", "title": "" }, { "docid": "fbe35b855869168ab7c0c902fb1c8da5", "score": "0.58045787", "text": "function valid_serial($serial)\n{\n\t// if the serial starts with \"H\" and finishes with \"X\" and\n\t// contains only digits between these two letters\n\tif( substr($serial,0,1)==\"H\" && substr($serial, -1)==\"X\" && ctype_digit(substr($serial,1,6)) )\n\t{\n\t\t$not_exist = check_serial($serial);\n\t\treturn $not_exist;\n\t}\n\t// if the serial does not have a good typography\n\telse\n\t{\n\t\t// return false\n\t\treturn false;\n\t}\n}", "title": "" }, { "docid": "82386920f4cce4194144fe8dd5a35adf", "score": "0.57793844", "text": "public static function isValid(string $uuid): bool\n {\n $uuid = strtolower(str_replace(['urn:', 'uuid:', '{', '}'], '', $uuid));\n\n if (!preg_match(static::UUID, $uuid)) {\n return false;\n }\n\n return true;\n }", "title": "" }, { "docid": "ac043e40ee21b736f39481cf7e84b465", "score": "0.5775077", "text": "public function test_invalid_IsValidSalt() {\n $this->assertEquals(\n false,\n IsValidSalt(\"1234567890123456789012345678901\")\n );\n\n $this->assertEquals(\n false,\n IsValidSalt(\"123456789012345678901234567890123\")\n );\n\n $this->assertEquals(\n false,\n IsValidSalt(null)\n );\n\n $this->assertEquals(\n false,\n IsValidSalt(false)\n );\n\n $this->assertEquals(\n false,\n IsValidSalt(true)\n );\n\n $this->assertEquals(\n false,\n IsValidSalt(-1)\n );\n }", "title": "" }, { "docid": "51e8a0c5ebc0b64a4f189646f161dc17", "score": "0.5771512", "text": "public function test_valid_IsValidSalt() {\n $this->assertEquals(\n true,\n IsValidSalt(\"123456789012345678901234567890==\")\n );\n }", "title": "" }, { "docid": "ffd2a19447456c8bcfbfc9e677cc8168", "score": "0.5767383", "text": "public function testUUIDV5UniquenessWithDifferentSeed()\n {\n $oGenerator = oxNew('oxUniversallyUniqueIdGenerator');\n\n $aIds = array();\n for ($i = 0; $i < 100; $i++) {\n $aIds[] = $oGenerator->generateV5('seed' . $i, 'salt');\n }\n\n $this->assertEquals(100, count(array_unique($aIds)));\n }", "title": "" }, { "docid": "6c82fffc165f2c58a8ad54e32c3edb14", "score": "0.57306767", "text": "public function uuid_check($attributesList)\n {\n if (\n array_key_exists('address_id', $attributesList)\n && !empty($attributesList['address_id'])\n ) {\n $this->uuid = $attributesList['address_id'];\n $this->attributes['uuid'] = $attributesList['address_id'];\n return $attributesList['address_id'];\n }\n\n $uuid = preg_replace('/\\W/', '-', uniqid('', true)) . '-' . preg_replace('/\\W/', '-', uniqid('', true));\n $this->uuid = $uuid;\n $this->attributes['uuid'] = $uuid;\n return $uuid;\n }", "title": "" }, { "docid": "b850c16d1eaff37db8e6a12e6fd615bd", "score": "0.5719372", "text": "function test_wrong_address_id(){\n $expected = false;\n $result = address::address_to_string(11);\n $this->assertEquals($expected, $result);\n }", "title": "" }, { "docid": "46b6d0959eda10a3f6b6773b4bcd343e", "score": "0.56899786", "text": "function libvirt_storagepool_get_uuid_string($res) : string\n{\n}", "title": "" }, { "docid": "a40d30519834c4cff2a3855412943870", "score": "0.5686144", "text": "#[@test]\n public function illegalHexNumber() {\n $t= $this->tokensOf('$i= 0xZ;');\n $this->assertEquals([Parser::T_VARIABLE, 'i', [1, 1]], $t[0]);\n $this->assertEquals([61, '=', [1, 3]], $t[1]);\n $this->assertEquals(['lang.FormatException', 'Illegal hex number <0xZ> starting at line 1, offset 5'], $t[2]);\n }", "title": "" }, { "docid": "1abf9b05263b2e8e3ad2057b6a7b57a0", "score": "0.566412", "text": "public function setUp() {\n\t\t// seed bytes with an actual uuid\n\t\t$this->VALID_BYTES = chr(118) . chr(9) . chr(185) . chr(49) . chr(221) . chr(132) . chr(79) . chr(33) . chr(165) . chr(15) . chr(133) . chr(169) . chr(172) . chr(81) . chr(251) . chr(146);\n\t\t$this->VALID_OBJECT = new UuidTestObject();\n\t\t$this->VALID_UUID = generateUuidV4();\n\t}", "title": "" }, { "docid": "df53305e10c0df285e592c60dc911db9", "score": "0.56503", "text": "public function testInsertValidObject() {\n\t\t$this->assertInstanceOf(\"Ramsey\\\\Uuid\\\\Uuid\", $this->VALID_UUID);\n\t\t$this->VALID_OBJECT->setUuid($this->VALID_UUID);\n\t\t$this->assertInstanceOf(\"Ramsey\\\\Uuid\\\\Uuid\", $this->VALID_OBJECT->getUuid());\n\t}", "title": "" }, { "docid": "58c6e5ff51725778802796e79ffa3173", "score": "0.5648645", "text": "function libvirt_nwfilter_lookup_by_uuid_string($conn, string $uuid)\n{\n}", "title": "" }, { "docid": "aba407f793c49cf9e23f6a5f9423e936", "score": "0.56463", "text": "#[Test]\n public function invalidTag()\n {\n $set = Set::fromDER(\"\\x31\\x6\\x5\\x0\\x80\\x0\\x5\\x0\");\n $this->expectException(LogicException::class);\n $this->expectExceptionMessage('No tagged element for tag 1');\n $set->getTagged(1);\n }", "title": "" }, { "docid": "ba0602381df0a7707f034b583b78e961", "score": "0.56365", "text": "public function isUuid(string $fieldName): bool\n {\n return $this->uuidFieldName === $fieldName;\n }", "title": "" }, { "docid": "a6a7b1aded07cfa296383d47557b7f55", "score": "0.5634393", "text": "public function uuid($name);", "title": "" }, { "docid": "e4449e2f8716e763f3665e205cfe6af4", "score": "0.5622794", "text": "public function test_generate_uid()\n {\n $game_uid = (new GameService())->generateUid();\n $this->assertIsString($game_uid);\n }", "title": "" }, { "docid": "befac8443005b2cbcf7317d15f4edd2a", "score": "0.561807", "text": "function gen_uuid($len = 8) {\n\n $hex = md5(param('salt-file') . uniqid(\"\", true));\n\n $pack = pack('H*', $hex);\n $tmp = base64_encode($pack);\n\n $uid = preg_replace(\"/[^A-Za-z0-9]/\", \"\", $tmp);\n\n $len = max(4, min(128, $len));\n\n while (strlen($uid) < $len)\n $uid .= gen_uuid(22);\n\n $res = substr($uid, 0, $len);\n return $res;\n}", "title": "" }, { "docid": "e8d7d00bbded7ad90826c6302873d88f", "score": "0.5613404", "text": "public function testPasswordContainsNumber()\n {\n for ($i=0; $i<1000; $i++){\n $password = User::generateRandomPassword();\n $this->assertTrue(preg_match('/\\\\d/', $password) > 0);\n }\n }", "title": "" }, { "docid": "9bcfdfe64d0c8c884fc1c36b85520bda", "score": "0.5611894", "text": "public function testIsValidStringId() {\n\t\t$stringIdEntity = new EmptyEntity();\n\t\t$stringIdEntity->id = \"foo\";\n\t\t$this->assertFalse($stringIdEntity->isValid());\n\t}", "title": "" }, { "docid": "d366cd69255d2d906416a9a6ea1aebaf", "score": "0.5608899", "text": "public function testValueAtNotUnique() {\n $validationResult = $this->getValidator()->validate('invalid@sadas@as');\n $this->assertEquals(\n in_array(\n $validationResult[0]['__CODE'],\n [\n 'VALIDATION.EMAIL_AT_NOT_UNIQUE',\n 'VALIDATION.EMAIL_INVALID',\n ]\n ),\n true\n );\n }", "title": "" }, { "docid": "adbd3721e7506e9dd1dc19902f3a4ace", "score": "0.5605275", "text": "public function testValidRib() {\n\t\t\t$result = validRib( '20041', '01005', '0500013M026', '06' );\n\t\t\t$expected = true;\n\t\t\t$this->assertEqual( $result, $expected, var_export( $result, true ) );\n\n\t\t\t$result = validRib( '00000', '0000000000', '0000000000', '97' );\n\t\t\t$expected = false;\n\t\t\t$this->assertEqual( $result, $expected, var_export( $result, true ) );\n\t\t }", "title": "" }, { "docid": "48cc347b6bc3b0d2af4654a0221c4ac4", "score": "0.5601852", "text": "public function uuid_insert($data) {\n\t\t$this->db->insert('uuid_te', $data);\n\t\tif ($this->db->affected_rows() > 0) {\n\t\t\treturn true;\n\t\t}\n\t}", "title": "" }, { "docid": "ba063dbb75d276ed0cadf1ef4bc7ffc0", "score": "0.5597049", "text": "public function forgetFailure(string $uuid): bool;", "title": "" }, { "docid": "d4d05fddb2556c788751ac97bda75629", "score": "0.5595679", "text": "public function test_invalid_MD5() {\n $this->assertNotEquals(\n $this->testhash,\n GenerateHash(\"barbaz12\")\n );\n\n $this->assertEquals(\n null,\n GenerateHash(null)\n );\n\n $this->assertEquals(\n null,\n GenerateHash(\"\")\n );\n\n $this->assertEquals(\n null,\n GenerateHash(null, \"md5\")\n );\n }", "title": "" }, { "docid": "ee8c920988bdfbffa300ee3ff2ed9d0b", "score": "0.5585473", "text": "protected function validate( string $value ) {\n\t\tif ( ! Uuid::isValid( $value ) ) {\n\t\t\tthrow new \\InvalidArgumentException(\n\t\t\t\tsprintf(\n\t\t\t\t\t'<%s> does not allow the value <%s>.',\n\t\t\t\t\tstatic::class,\n\t\t\t\t\tis_scalar( $value ) ? $value : gettype( $value )\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\t}", "title": "" }, { "docid": "66bd8399afc47de4cc6f3e8671d18174", "score": "0.5582033", "text": "public static function castUuidAttribute($value)\n {\n if (is_null($value)) {\n return $value;\n }\n\n if (!Config::get('uuid.binary', true)) {\n return $value;\n }\n\n $value = unpack('H*', $value);\n\n return strtolower(preg_replace('/([0-9a-f]{8})([0-9a-f]{4})([0-9a-f]{4})([0-9a-f]{4})([0-9a-f]{12})/', '$1-$2-$3-$4-$5', $value[1]));\n }", "title": "" }, { "docid": "114bb5600406c81369d1c66ad5b0e24f", "score": "0.5575957", "text": "public function testDecodeBadTx()\n {\n $e = null;\n try {\n $hex = \"0100000001552eed137888e6a6c2c69ded505d9e573c3d78ab0f478ecbdaf74b99b40f350d010000006b483045022100d958e320b5bbc700e7862b7832fc86d18f50be7a272399c38b35a6aecd471d68022014a02f0387a0971c4e06cac086d662615a3e07a0323e1f138d96c54c7f6aaead012102af6034f808ee5989a7ea0304cc7d464edb22a86d362739aeb4e52e759436b7f5ffffffff0240480801000000001976a91415df9c5643a3ef61ee05a92a7703f47a4ffbbcdb88ac8b0361695e0000001976a91490967f997eda3a1c0bd4358b3cd19824e46538b6ac00000000\";\n $tx = RawTransaction::decode($hex);\n } catch (\\Exception $e) {\n }\n $this->assertTrue(!!$e);\n }", "title": "" }, { "docid": "880c53d2801b81d0ecbded3948363076", "score": "0.55718243", "text": "function testGenerateHEXSeed() {\n\t\t//$otpSeed = Seed::generate();\n\t\n\t\t// -OR- use a pre-generated string\n\t\t$otpSeed = new Seed('thisismysecret');\n\t\n\t\t// Display secret key details\n\t\tprintf(\"Secret (HEX): %s\\n\", $otpSeed->getValue(Seed::FORMAT_HEX));\n\t\tprintf(\"Secret (BASE32): %s\\n\", $otpSeed->getValue(Seed::FORMAT_BASE32));\n\t\n\t\t//\n\t\t$this->assertNotEmpty($otpSeed,'this was the HEX seed for thisismysecret');\n\t}", "title": "" }, { "docid": "2de8bd7f798a3e5be07f20b8a5874b45", "score": "0.55511343", "text": "private function FixUuid(&$uuid)\n {\n\n $id = explode(\":\", $uuid);\n\n $uuid = '<' . $id[2] . '>';\n\n return $uuid;\n }", "title": "" }, { "docid": "da417cc2af7710dd2a47d5027fd95b11", "score": "0.55406475", "text": "public function testDummyHexOK()\n {\n $request = new FakeApiRequester();\n $request\n ->withPsr7Request($this->getPsr7Request())\n ->withMethod('GET')\n ->withPath(\"/sample/dummyhex/11111111-2222-3333-4444-555555555555\")\n ->assertResponseCode(200)\n ;\n $this->assertRequest($request);\n }", "title": "" }, { "docid": "e85540371fe9a7ea4f4e35767a8c9fbc", "score": "0.5532735", "text": "public function uuid($message = ''): self\n {\n return $this->regex(\n '(^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$)i',\n $message,\n 'uuid'\n );\n }", "title": "" }, { "docid": "42da20cad03d4c0bbadcd085e2d65afa", "score": "0.55304223", "text": "public function testBadHash()\n {\n $uri = '/callback.php?valid=true&trans_id=001&hash=174af8acde72bc7dea9f2bae432d8a34';\n\n $this->assertFalse($this->checker->isValid($uri));\n }", "title": "" }, { "docid": "85d22acf8862fafd68f6fff453532941", "score": "0.55189395", "text": "private function checkFormat(): void {\n\t\t$char_count = mb_strlen($this->code);\n\n\t\tif ($char_count == 17) {\n\t\t\t$this->is_encoded = false;\n\t\t} else if ($char_count == 18) {\n\t\t\t$this->is_encoded = true;\n\t\t} else {\n\t\t\tthrow new GRidException('Code format invalid. Unencoded GRids must contain 17 alphanumeric characters and encoded GRids must contain 18');\n\t\t}\n\n\t\tif (!preg_match('/^A1/', $this->code)) {\n\t\t\tthrow new GRidException('Code format invalid. GRid identifier scheme element must be A1');\n\t\t}\n\t}", "title": "" }, { "docid": "b931546d8308884f4c91ed64418f9a63", "score": "0.5515941", "text": "private function validateUuid($uuid)\n {\n if (! RamseyUuid::isValid($uuid)) {\n throw (new ModelNotFoundException)->setModel(get_class($this));\n }\n }", "title": "" }, { "docid": "8a9861c53942e656dd6347b344fc2b0e", "score": "0.5514571", "text": "function validate_sid($sid) {\n\t\t$pattern = '/^[0-9d][0-9]{8}$/i';\n\t\tif (preg_match($pattern,$sid) == 1) {\n\t\t\treturn true;\n\t\t}\n\t\t#Student ID is not valid\n\t\treturn false;\n\t}", "title": "" }, { "docid": "a154d806afbecaeeb69c1ee7df963b86", "score": "0.55109996", "text": "public function testCanValidateThatValueIsUnique(): void {\n }", "title": "" }, { "docid": "1ffeaaef9d5f93a0e98651a2e54ef6ec", "score": "0.5498014", "text": "function uuid()\n{\n return sprintf( '%04x%04x-%04x-%04x-%04x-%04x%04x%04x',\n mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ),\n mt_rand( 0, 0x0fff ) | 0x4000,\n mt_rand( 0, 0x3fff ) | 0x8000,\n mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ) );\n}", "title": "" }, { "docid": "754d76083f1442a8c462adee94e4cae7", "score": "0.5494243", "text": "protected static function makeBin($str) {\r\n $len = 16;\r\n if ($str instanceof self)\r\n return $str->bytes;\r\n if (strlen($str)==$len)\r\n return $str;\r\n else\r\n $str = preg_replace(\"/^urn:uuid:/is\", \"\", $str); // strip URN scheme and namespace\r\n $str = preg_replace(\"/[^a-f0-9]/is\", \"\", $str); // strip non-hex characters\r\n if (strlen($str) != ($len * 2))\r\n return FALSE;\r\n else\r\n return pack(\"H*\", $str);\r\n }", "title": "" }, { "docid": "733bcb3a909c6a23b576d41f8936c2df", "score": "0.5476942", "text": "public function testRegisterFailCvvCode() {\n $this->visit('/register')\n ->type('bob', 'lastname')\n ->type('bob', 'firstname')\n ->type('1992-12-05', 'birthdate')\n ->type('bob.bob@hotmail.com', 'email')\n ->type('bobbobbob', 'password')\n ->type('bobbobbob', 'password_confirmation')\n ->type('04268342156', 'phoneNumber')\n ->type('12365447954126358', 'credit_card_number')\n ->type('Bobbob', 'card_owner')\n ->type('2016-07', 'expiration_date')\n ->type('ds', 'cvv_code')\n ->press('Inscription')\n ->seePageIs('/register');\n\n // Help block that the user should see \n $this->seeInElement('span',\n \"Le champ Code de sécurité doit avoir 3 chiffres.\");\n\n // The cvv code is too long\n $this->visit('/register')\n ->type('bob', 'lastname')\n ->type('bob', 'firstname')\n ->type('1992-12-05', 'birthdate')\n ->type('bob.bob@hotmail.com', 'email')\n ->type('bobbobbob', 'password')\n ->type('bobbobbob', 'password_confirmation')\n ->type('04268342156', 'phoneNumber')\n ->type('12365447954126358', 'credit_card_number')\n ->type('Bobbob', 'card_owner')\n ->type('2016-07', 'expiration_date')\n ->type('15', 'cvv_code')\n ->press('Inscription')\n ->seePageIs('/register');\n\n // Help block that the user should see \n $this->seeInElement('span',\n \"Le champ Code de sécurité doit avoir 3 chiffres.\");\n\n // The cvv code is too long\n $this->visit('/register')\n ->type('bob', 'lastname')\n ->type('bob', 'firstname')\n ->type('1992-12-05', 'birthdate')\n ->type('bob.bob@hotmail.com', 'email')\n ->type('bobbobbob', 'password')\n ->type('bobbobbob', 'password_confirmation')\n ->type('042', 'phoneNumber')\n ->type('123654479', 'credit_card_number')\n ->type('Bobbob', 'card_owner')\n ->type('2016-07', 'expiration_date')\n ->type('1458', 'cvv_code')\n ->press('Inscription')\n ->seePageIs('/register');\n\n // Help block that the user should see \n $this->seeInElement('span',\n \"Le champ Code de sécurité doit avoir 3 chiffres.\");\n }", "title": "" }, { "docid": "715cbb5ff5fcbdd03bf526b66e097c17", "score": "0.54682523", "text": "public static function genUuid () {\n $data = openssl_random_pseudo_bytes(16);\n assert(strlen($data) == 16);\n\n $data[6] = chr(ord($data[6]) & 0x0f | 0x40); // set version to 0100\n $data[8] = chr(ord($data[8]) & 0x3f | 0x80); // set bits 6-7 to 10\n\n return vsprintf('%s%s-%s-%s-%s-%s%s%s', str_split(bin2hex($data), 4));\n }", "title": "" }, { "docid": "1565c0b9f7d233ccbbbe8934ca0a2cd2", "score": "0.5462784", "text": "function uuid($prefix = null, $length = 36) {\n $data = openssl_random_pseudo_bytes(16);\n $data[6] = chr(ord($data[6]) & 0x0f | 0x40);\n $data[8] = chr(ord($data[8]) & 0x3f | 0x80);\n\n return uuid_format(bin2hex($data), $prefix, $length);\n }", "title": "" }, { "docid": "d888e89944f08c24b1db610ee086f194", "score": "0.54581946", "text": "public static function uuidv4():string {\n\t\t$z = PolyRand::string(1, ['8', '9', 'a', 'b']);\n\t\t$x = PolyRand::hex(30);\n\t\t// uuidv4 format is xxxxxxxx-xxxx-4xxx-zxxx-xxxxxxxxxxxx\n\t\treturn preg_replace(\n\t\t\t'/^(.{8})(.{4})(.{3})(.{3})(.{12})$/',\n\t\t\t\"$1-$2-4$3-$z$4-$5\",\n\t\t\t$x\n\t\t);\n\t}", "title": "" }, { "docid": "939e402fe32ce42977b9f320fa71bf7c", "score": "0.54457855", "text": "public function testRegisterFailPhoneNumber() {\n $this->visit('/register')\n ->type('bob', 'lastname')\n ->type('bob', 'firstname')\n ->type('1992-12-05', 'birthdate')\n ->type('bob.bob@hotmail.com', 'email')\n ->type('bobbobbob', 'password')\n ->type('bobbobbob', 'password_confirmation')\n ->type('04268342156', 'phoneNumber')\n ->type('1236544795412635', 'credit_card_number')\n ->type('Bobbob', 'card_owner')\n ->type('2016-07', 'expiration_date')\n ->type('145', 'cvv_code')\n ->press('Inscription')\n ->seePageIs('/register');\n\n // Help block that the user should see \n $this->seeInElement('span',\n \"Le champ Numéro de téléphone doit avoir 10 chiffres.\");\n\n // The phone number is too short\n $this->visit('/register')\n ->type('bob', 'lastname')\n ->type('bob', 'firstname')\n ->type('1992-12-05', 'birthdate')\n ->type('bob.bob@hotmail.com', 'email')\n ->type('bobbobbob', 'password')\n ->type('bobbobbob', 'password_confirmation')\n ->type('042', 'phoneNumber')\n ->type('1236544795412635', 'credit_card_number')\n ->type('Bobbob', 'card_owner')\n ->type('2016-07', 'expiration_date')\n ->type('145', 'cvv_code')\n ->press('Inscription')\n ->seePageIs('/register');\n\n // Help block that the user should see \n $this->seeInElement('span',\n \"Le champ Numéro de téléphone doit avoir 10 chiffres.\");\n\n // The phone number field should contain a numeric value\n $this->visit('/register')\n ->type('bob', 'lastname')\n ->type('bob', 'firstname')\n ->type('1992-12-05', 'birthdate')\n ->type('bob.bob@hotmail.com', 'email')\n ->type('bobbobbob', 'password')\n ->type('bobbobbob', 'password_confirmation')\n ->type('qsdsdqsqsd', 'phoneNumber')\n ->type('1236544795412635', 'credit_card_number')\n ->type('Bobbob', 'card_owner')\n ->type('2016-07', 'expiration_date')\n ->type('145', 'cvv_code')\n ->press('Inscription')\n ->seePageIs('/register');\n\n // Help block that the user should see \n $this->seeInElement('span',\n \"Le champ Numéro de téléphone doit avoir 10 chiffres.\");\n }", "title": "" }, { "docid": "d1029572fe9d88a59640f87f8bd121ae", "score": "0.54455304", "text": "public function testCleNir() {\n\t\t\t$result = cle_nir( '179012A001234' );\n\t\t\t$expected = '71';\n\t\t\t$this->assertEqual( $result, $expected, var_export( $result, true ) );\n\n\t\t\t$result = cle_nir( '179012B001234' );\n\t\t\t$expected = '01';\n\t\t\t$this->assertEqual( $result, $expected, var_export( $result, true ) );\n\t\t }", "title": "" }, { "docid": "5b4707c4d2f1a934313ce28b685aa978", "score": "0.54262614", "text": "public function checkUsernameId(){\n\t\t$uname = 'abcd.xyz..1234';\n\t\techo \"+++\". $this->getIdfromUname($uname);\n\t}", "title": "" }, { "docid": "8339a45d238d287f3672e031f1a2cc22", "score": "0.5422945", "text": "public function testUidAlreadyInUseCaseTwo()\n {\n $model = app(\\App\\User::class);\n $this->assertFalse($model->uidAlreadyInUse('a1wk09'));\n }", "title": "" }, { "docid": "e98987bea42aef2ab3d37f7d2cfbe8a1", "score": "0.5408584", "text": "public static function gen_uuid() {\n\n return sprintf( '%04x%04x%04x%04x%04x%04x%04x%04x',\n // 32 bits for \"time_low\"\n mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ),\n\n // 16 bits for \"time_mid\"\n mt_rand( 0, 0xffff ),\n\n // 16 bits for \"time_hi_and_version\",\n // four most significant bits holds version number 4\n mt_rand( 0, 0x0fff ) | 0x4000,\n\n // 16 bits, 8 bits for \"clk_seq_hi_res\",\n // 8 bits for \"clk_seq_low\",\n // two most significant bits holds zero and one for variant DCE1.1\n mt_rand( 0, 0x3fff ) | 0x8000,\n\n // 48 bits for \"node\"\n mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff )\n );\n}", "title": "" }, { "docid": "088e8f3b6e326b94676048e8cea5c90f", "score": "0.53898185", "text": "public function testValueInvalidchars() {\n $this->assertEquals('VALIDATION.STRING_CONTAINS_INVALID_CHARACTERS', $this->getValidator()->validate('*ASDASD')[0]['__CODE'] );\n }", "title": "" }, { "docid": "3084181eee530429f1e89183b3494026", "score": "0.5379219", "text": "public static function generateUuid()\n {\n do {\n $uuid = str_uuid();\n } while (self::where('uuid', $uuid)->count() > 0);\n return $uuid;\n }", "title": "" }, { "docid": "6e2770d75fba8ed3cdc70cde5401e556", "score": "0.5378651", "text": "public function testGetGenerator(): void\n {\n $uuid = $this->getManager()->getGenerator()->uuid4();\n\n $this->assertUuid4($uuid);\n }", "title": "" }, { "docid": "3ae4fcd1d4ff49ae2357f7c848f2d831", "score": "0.5378177", "text": "public function testSignatureFailure() {\n\t\t// break the secret key\n\t\t$badSecret = strtoupper( $this->secret );\n\t\t$this->esu = new EsuRestApi( $this->host, $this->port, $this->uid, $badSecret );\n\t\t//$this->esu->setDebug( true );\n\t\t\n\t\ttry {\n\t\t\t// Create an object. Should fail.\n\t\t\t$id = $this->esu->createObject();\n\t\t} catch( EsuException $e ) {\n\t\t\t//print $e . ' (failure expected)';\n\t\t\tPHPUnit_Framework_Assert::assertEquals( 1032, $e->getCode(), \n\t\t\t\t'Expected error code 1032 for signature failure' );\n\t\t\treturn;\n\t\t}\n\t\t$this->fail( 'Exception not thrown!' );\n\t}", "title": "" }, { "docid": "a5a1388708ef81d6815e13cfe0616984", "score": "0.5378023", "text": "function format_uuid(string $uuid): string {\n\t\t$uid = substr($uuid, 0, 8) . \"-\";\n\t\t$uid .= substr($uuid, 8, 4) . \"-\";\n\t\t$uid .= substr($uuid, 12, 4) . \"-\";\n\t\t$uid .= substr($uuid, 16, 4) . \"-\";\n\t\t$uid .= substr($uuid, 20);\n\t\treturn $uid;\n\t}", "title": "" }, { "docid": "18a2a8f1199fa84b93e2511234a889bc", "score": "0.5374515", "text": "function generarUuid()\n {\n return sprintf('%04x%04x-%04x-%04x-%04x-%04x%04x%04x',\n mt_rand(0, 0xffff), mt_rand(0, 0xffff),\n mt_rand(0, 0xffff),\n mt_rand(0, 0x0fff) | 0x4000,\n mt_rand(0, 0x3fff) | 0x8000,\n mt_rand(0, 0xffff), mt_rand(0, 0xffff), mt_rand(0, 0xffff)\n );\n }", "title": "" } ]
0ac7bdb02e5fbb03eb7a9ee5316bf396
Run the database seeds.
[ { "docid": "11d7b7044e292590cb6e82eb473c2d18", "score": "0.0", "text": "public function run()\n {\n $techCategories = \\App\\Helpers\\DataUtils::$techCategories;\n\n foreach($techCategories as $techCategory){\n \\App\\TechCategory::create([\n 'name' => $techCategory\n ]);\n }\n }", "title": "" } ]
[ { "docid": "1dcddd9fc4f2fbc62e484166f7f3332c", "score": "0.802869", "text": "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n DB::table('users')->truncate();\n DB::table('posts')->truncate();\n DB::table('roles')->truncate();\n DB::table('role_user')->truncate();\n\n // SEEDS\n $this->call(RolesTableSeeder::class);\n\n // FACTORIES\n /*\n factory(App\\User::class, 10)->create()->each(function ($user) {\n $user->posts()->save(factory(App\\Post:class)->make());\n });*/\n\n //$roles = factory(App\\Role::class, 3)->create();\n\n $users = factory(User::class, 10)->create()->each(function ($user) {\n $user->posts()->save(factory(Post::class)->make());\n $user->roles()->attach(Role::findOrFail(rand(1, 3)));\n });\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1');\n\n }", "title": "" }, { "docid": "6242c83182914af1dca6a8760034eb1d", "score": "0.8013324", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $ross = User::create([\n 'email' => 'rossjbartlett@gmail.com',\n 'name' => 'Ross Bartlett',\n 'password' => Hash::make('password')\n ]);\n\n $dyl = User::create([\n 'email' => 'timeparadox98@gmail.com',\n 'name' => 'Dylan Gordon',\n 'password' => Hash::make('password')\n ]);\n\n Interest::create([\n 'user_id'=>$ross->id,\n 'interest'=>'Calgary Flames'\n ]);\n Interest::create([\n 'user_id'=>$ross->id,\n 'interest'=>'Rugby'\n ]);\n\n Like::create([\n 'user_id'=>$ross->id,\n 'item'=>'rVynOFlmK_Q',\n 'platform'=> 0 //youtube\n ]);\n\n\n }", "title": "" }, { "docid": "189174cea9e9e7145c489e18fd0089a4", "score": "0.79804534", "text": "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n // Let's truncate our existing records to start from scratch.\n Assignation::truncate();\n\n $faker = \\Faker\\Factory::create();\n \n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 40; $i++) {\n Assignation::create([\n 'ad_id' => $faker->numberBetween(1,20),\n 'buyer_id' => $faker->numberBetween(1,6),\n 'seller_id' => $faker->numberBetween(6,11),\n 'state' => NULL,\n ]);\n }\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "title": "" }, { "docid": "6d65d81db98c4e3d10f6aa402d6393d9", "score": "0.79774004", "text": "public function run()\n {\n if (App::environment() == 'production') {\n exit(\"You shouldn't run seeds on production databases\");\n }\n\n DB::table('roles')->truncate();\n\n Role::create([\n 'id' => 3,\n 'name' => 'Root',\n 'description' => 'God user. Access to everything.'\n ]);\n\n Role::create([\n 'id' => 2,\n 'name' => 'Administrator',\n 'description' => 'Administrator user. Many privileges.'\n ]);\n\n Role::create([\n 'id' => 1,\n 'name' => 'Guest',\n 'description' => 'Basic user.'\n ]);\n\n }", "title": "" }, { "docid": "b0c4f271872f35f165325de519bb487f", "score": "0.7976992", "text": "public function run()\n {\n \t$faker = Faker::create();\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$post = new Post;\n \t\t$post->title = $faker->sentence();\n \t\t$post->body = $faker->paragraph();\n \t\t$post->category_id = rand(1, 5);\n \t\t$post->save();\n \t}\n\n \t$list = ['General', 'Technology', 'News', 'Internet', 'Mobile'];\n \tforeach($list as $name) {\n \t\t$category = new Category;\n \t\t$category->name = $name;\n \t\t$category->save();\n \t}\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$comment = new Comment;\n \t\t$comment->comment = $faker->paragraph();\n \t\t$comment->post_id = rand(1,20);\n \t\t$comment->save();\n \t}\n // $this->call(UsersTableSeeder::class);\n }", "title": "" }, { "docid": "37a0b6a3e76804710ff7c9469eab40c2", "score": "0.79632276", "text": "public function run()\n {\n $this->call(RoleTableSeeder::class);\n $this->call(PermissionTableSeeder::class);\n factory(App\\User::class, 1)->create();\n factory(App\\Supplier::class, 10)->create();\n $categories = factory(App\\Category::class, 5)->create();\n \t$categories->each(function ($category) {\n factory('App\\SubCategory', 2)->create(['category_id' => $category->id]);\n });\n factory(App\\Warehouse::class, 5)->create();\n factory(App\\Employee::class, 10)->create();\n factory(App\\Customer::class, 10)->create();\n factory(App\\Income::class, 10)->create();\n factory(App\\Expense::class, 10)->create();\n factory(App\\Product::class, 20)->create();\n factory(App\\Purchase::class, 5)->create();\n factory(App\\Sale::class, 5)->create();\n }", "title": "" }, { "docid": "c8b0d4df0b00483f5e354b9b76b4f370", "score": "0.7955267", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n User::create([\n 'name' => 'Réén Pock',\n 'email' => 'poock@poock.com',\n 'password' => bcrypt('123456')\n ]);\n factory(Category::class, 5)->create();\n factory(Product::class, 100)->create()->each(function($product){\n for ($i=0; $i < 3; $i++) { \n $product->categories()->attach(Category::inRandomOrder()->first()->id);\n }\n });\n }", "title": "" }, { "docid": "810e2984e6eded128ac32a3c06fe3e23", "score": "0.7949612", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n \t$faker = Factory::create();\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\tDepartment::create([\n \t\t\t'name' => $department\n \t\t]);\n \t}\n \tforeach ($this->collections as $key => $collection) {\n \t\tCollection::create([\n \t\t\t'name' => $collection\n \t\t]);\n \t}\n \t\n \t\n \tfor ($i=0; $i < 40; $i++) {\n \t\tUser::create([\n \t\t\t'name' \t=>\t$faker->name,\n \t\t\t'email' \t=>\t$faker->email,\n \t\t\t'password' \t=>\tbcrypt('123456'),\n \t\t]);\n \t} \n \t\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\t//echo ($key + 1) . PHP_EOL;\n \t\t\n \t\tfor ($i=0; $i < 10; $i++) { \n \t\t\techo $faker->name . PHP_EOL;\n\n \t\t\tArt::create([\n \t\t\t\t'name'\t\t\t=> $faker->sentence(2),\n \t\t\t\t'img'\t\t\t=> $this->filenames[$i],\n \t\t\t\t'medium'\t\t=> 'canvas',\n \t\t\t\t'department_id'\t=> $key + 1,\n \t\t\t\t'user_id'\t\t=> $this->userIndex,\n \t\t\t\t'dimension'\t\t=> '18.0 x 24.0',\n\t\t\t\t]);\n \t\t\t\t\n \t\t\t\t$this->userIndex ++;\n \t\t}\n \t}\n \t\n \tdd(\"END\");\n }", "title": "" }, { "docid": "338cba437c44387add3ca68b7433a1d6", "score": "0.794459", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->dataCategory();\n factory(App\\Model\\Category::class, 70)->create();\n factory(App\\Model\\Producer::class, rand(5,10))->create();\n factory(App\\Model\\Provider::class, rand(5,10))->create();\n factory(App\\Model\\Product::class, 100)->create();\n factory(App\\Model\\Album::class, 300)->create();\n }", "title": "" }, { "docid": "33dbfbc00700305306745acd24e39069", "score": "0.7938189", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $types = factory(\\App\\Models\\Type::class, 5)->create();\n\n $cities = factory(\\App\\Models\\City::class, 10)->create();\n\n $cities->each(function ($city) {\n $districts = factory(\\App\\Models\\District::class, rand(2, 5))->create([\n 'city_id' => $city->id,\n ]);\n\n $districts->each(function ($district) {\n $properties = factory(\\App\\Models\\Property::class, rand(2, 5))->create([\n 'type_id' => rand(1, 5),\n 'district_id' => $district->id\n ]);\n\n $properties->each(function ($property) {\n $galleries = factory(\\App\\Models\\Gallery::class, rand(3, 10))->create([\n 'property_id' => $property->id\n ]);\n });\n });\n });\n }", "title": "" }, { "docid": "ff581332117c5a8ceb165939e5861a64", "score": "0.79368967", "text": "public function run()\n {\n $this->call(UsersTableSeeder::class);\n\n $categories = factory(App\\Models\\Category::class, 10)->create();\n\n $categories->each(function ($category) {\n $category\n ->posts()\n ->saveMany(\n factory(App\\Models\\Post::class, 3)->make()\n );\n });\n }", "title": "" }, { "docid": "a3350553b93dfb0209ddf6ddfd533d8d", "score": "0.79337025", "text": "public function run()\n {\n $this->call(CategoriesTableSeeder::class);\n\n $users = factory(App\\User::class, 5)->create();\n $recipes = factory(App\\Recipe::class, 30)->create();\n $preparations = factory(App\\Preparation::class, 70)->create();\n $photos = factory(App\\Photo::class, 90)->create();\n $comments = factory(App\\Comment::class, 200)->create();\n $flavours = factory(App\\Flavour::class, 25)->create();\n $flavour_recipe = factory(App\\FlavourRecipe::class, 50)->create();\n $tags = factory(App\\Tag::class, 25)->create();\n $recipe_tag = factory(App\\RecipeTag::class, 50)->create();\n $ingredients = factory(App\\Ingredient::class, 25)->create();\n $ingredient_preparation = factory(App\\IngredientPreparation::class, 300)->create();\n \n \n \n DB::table('users')->insert(['name' => 'SimpleUtilisateur', 'email' => 'simpleadressemail@mail.com', 'password' => bcrypt('SimpleMotDePasse')]);\n \n }", "title": "" }, { "docid": "fa8f6aeb20ad773ecabd02bb875a6c88", "score": "0.79219097", "text": "public function run()\n {\n //\n if (App::environment() === 'production') {\n exit('Do not seed in production environment');\n }\n\n DB::statement('SET FOREIGN_KEY_CHECKS = 0'); // disable foreign key constraints\n DB::table('sections')->truncate();\n\n Section::create([\n 'id' => 1,\n 'name' => 'Lifestyle Habits',\n 'description' => 'This section focuses on lifestyle and habits of a patient']);\n Section::create([\n 'id' => 2,\n 'name' => 'Family History',\n 'description' => 'This section focuses on medical history of family of a patient']);\n Section::create([\n 'id' => 3,\n 'name' => 'Complaints',\n 'description' => 'This section deals with recent complaints of pateint']);\n Section::create([\n 'id' => 4,\n 'name' => 'Clinical Examination',\n 'description' => 'This section deals with various clinical reports of a patient']);\n \n DB::statement('SET FOREIGN_KEY_CHECKS = 1'); // enable foreign key constraints\n }", "title": "" }, { "docid": "d683182ec8b2d791dddbb2f54ba8f8b3", "score": "0.7919681", "text": "public function run()\n {\n //Assign dummy Roles for users with in UsersTableSeeder\n DB::table('roles')->insert([\n 'title' => 'Admin',\n ]);\n\n DB::table('roles')->insert([\n 'title' => 'Employee',\n ]);\n\n //assigned user a Role\n DB::table('role_user')->insert([\n 'role_id' => '1',\n 'user_id' => '1',\n ]);\n\n DB::table('role_user')->insert([\n 'role_id' => '2',\n 'user_id' => '2',\n ]);\n\n $faker = Faker::create();\n foreach (range(3, 20) as $index) {\n DB::table('role_user')->insert([\n 'role_id' => rand(1, 2),\n 'user_id' => $index,\n ]);\n }\n }", "title": "" }, { "docid": "22408a54239aeef49683358b8f38db07", "score": "0.7906679", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // create categories\n \t$categories = factory('App\\Category', 10)->create();\n // create posts\n $posts = factory('App\\Post', 50)->create();\n // fore each post, populate 1-3 cates\n $posts->each(function ($post) use ($categories) {\n \t$post->categories()->attach(\n \t\t$categories->random(rand(1, 3))->pluck('id')->toArray()\n \t);\n });\n }", "title": "" }, { "docid": "64ddc727eef6e28c29db4c4be58c3578", "score": "0.78924936", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n // Sample::truncate();\n // TestItem::truncate();\n // UOM::truncate();\n Role::truncate();\n User::truncate();\n\n // factory(Role::class, 4)->create();\n Role::create([\n 'name'=> 'Director',\n 'description'=> 'Director type'\n ]);\n\n Role::create([\n 'name'=> 'Admin',\n 'description'=> 'Admin type'\n ]);\n Role::create([\n 'name'=> 'Employee',\n 'description'=> 'Employee type'\n ]);\n Role::create([\n 'name'=> 'Technician',\n 'description'=> 'Technician type'\n ]);\n \n factory(User::class, 20)->create()->each(\n function ($user){\n $roles = \\App\\Role::all()->random(mt_rand(1, 2))->pluck('id');\n $user->roles()->attach($roles);\n }\n );\n }", "title": "" }, { "docid": "4f1d5d37635c3d5345f27254da911e96", "score": "0.78846294", "text": "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n \\App\\Article::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 15; $i++) {\n \\App\\Article::create([\n 'title' => $faker->sentence,\n 'content' => $faker->paragraphs($nb = 4, $asText = true),\n 'author' => $faker->name,\n 'num_views' => $faker->randomNumber($nbDigits = 4),\n 'publish_state' => $faker->boolean,\n 'publish_date' => ($faker->dateTimeThisYear($max = 'now'))->format('c')\n ]);\n }\n }", "title": "" }, { "docid": "b993bdb17f6322a43f700f6d1f5b1006", "score": "0.7882899", "text": "public function run()\n {\n // Trunkate the databse so we don;t repeat the seed\n DB::table('roles')->delete();\n\n Role::create(['name' => 'root']);\n Role::create(['name' => 'admin']);\n Role::create(['name' => 'supervisor']);\n Role::create(['name' => 'officer']);\n Role::create(['name' => 'user']);\n }", "title": "" }, { "docid": "3c219ba37518a110e693986f93eb9e5e", "score": "0.7877671", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n DB::table('roles')->insert([\n 'name' => 'prof',\n 'display_name' => 'professor',\n 'description' => 'Perfil professor',\n 'created_at' => Carbon::now()->toDateTimeString(),\n 'updated_at' => Carbon::now()->toDateTimeString(),\n ]);\n\n DB::table('users')->insert([\n 'name' => 'Marcos André',\n 'email' => 'macs@ifpe.edu.br',\n 'password' => bcrypt('marcos123'),\n 'first_login' => 0,\n 'created_at' => Carbon::now()->toDateTimeString(),\n 'updated_at' => Carbon::now()->toDateTimeString(),\n ]);\n\n DB::table('professores')->insert([\n 'nome' => 'Marcos André',\n 'matricula' => '12.3456-7',\n 'data_nascimento' => '1969-11-30',\n 'user_id' => 1,\n 'created_at' => Carbon::now()->toDateTimeString(),\n 'updated_at' => Carbon::now()->toDateTimeString(),\n ]);\n\n DB::table('role_user')->insert([\n 'user_id' => 1,\n 'role_id' => 1,\n ]);\n }", "title": "" }, { "docid": "e78ec24a86879882dd348d32e57ca04d", "score": "0.7877498", "text": "public function run()\n {\n /* factory(\\App\\Models\\Category::class, 5)->create()->each(function ($category) {\n factory(\\App\\Models\\Category::class, random_int(0, 3))->create(['parent_id' => $category->id]);\n });\n\n factory(App\\Models\\User::class, 10)->create()->each(function ($user) {\n factory(App\\Models\\Post::class, random_int(0, 10))->create(['user_id' => $user->id])->each(function ($post) {\n $post->postContent()->save(factory(PostContent::class)->make());\n });\n });\n\n DB::table('users')->where('id', 1)->update(['user_name' => 'tiny', 'email' => 'tiny@test.com', 'locked_at' => null]);\n\n $this->call(PermissionsTableSeeder::class);\n $this->call(RolesTableSeeder::class);\n $this->call(TypesTableSeeder::class);*/\n $this->call(UsersTableSeeder::class);\n }", "title": "" }, { "docid": "5b880595ea5798cabac1baebe896e5e7", "score": "0.7871811", "text": "public function run()\n {\n DatabaseSeeder::seedLearningStylesProbs();\n DatabaseSeeder::seedCampusProbs();\n DatabaseSeeder::seedGenderProbs();\n DatabaseSeeder::seedTypeStudentProbs();\n DatabaseSeeder::seedTypeProfessorProbs();\n DatabaseSeeder::seedNetworkProbs();\n }", "title": "" }, { "docid": "17dca3224f1ceff9e07014643cc0ecc7", "score": "0.78660107", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n /* role seeder */\n DB::table('roles')->insert([\n 'id' => 1,\n 'title' => 'Customer',\n ]);\n\n DB::table('roles')->insert([\n 'id' => 2,\n 'title' => 'Seller',\n ]);\n\n \n /* seller category seeder */\n factory(App\\SellerCategory::class, 10)->create();\n\n /* user seeder */\n factory(App\\User::class, 20)->create();\n\n /* request seeder */\n factory(App\\Request::class, 10)->create();\n }", "title": "" }, { "docid": "900d2a6c98a63207bb98e4476f29b982", "score": "0.7853861", "text": "public function run()\n {\n DB::table('users')->truncate();\n DB::table('roles')->truncate();\n\n // $this->call(UsersTableSeeder::class);\n Role::create([\n 'name' => 'admin'\n ]);\n Role::create([\n 'name' => 'author'\n ]);\n Role::create([\n 'name' => 'user'\n ]);\n User::create([\n 'name' => 'Admin',\n 'email' => 'admin@test.com',\n 'password' => bcrypt('test12345'),\n 'role' => 1\n ]);\n User::create([\n 'name' => 'User',\n 'email' => 'user@test.com',\n 'password' => bcrypt('test12345'),\n ]);\n \n $this->call([\n DishCategorySeeder::class,\n DishesSeeder::class\n ]);\n }", "title": "" }, { "docid": "d7bb625a9812b9cb6a9362070a5950ee", "score": "0.7852421", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // Add Company\n $company = Company::create([\n 'name' => 'IAPP',\n 'employee_count' => 100,\n 'size' => 'Large'\n ]);\n\n $secondCompany = Company::create([\n 'name' => 'ABC',\n 'employee_count' => 20,\n 'size' => 'Small'\n ]);\n\n // Add user\n $general_user = User::create([\n 'name' => 'Shayna Sylvia',\n 'email' => 'shayna.sylvia@gmail.com',\n 'password' => Hash::make('12345678'),\n 'street' => '9 Mill Pond Rd',\n 'city' => 'Northwood',\n 'state' => 'NH',\n 'zip' => '03261',\n 'company_id' => $company->id,\n 'type' => 'admin'\n ]);\n\n // Add Challenge\n $challenge = Challenge::create([\n 'name' => 'Conquer the Cold 2018',\n 'slug' => 'conquer',\n 'start_date' => '2018-11-01',\n 'end_date' => '2018-12-31',\n 'type' => 'Individual',\n 'image_url' => '/images/conquer-the-cold-banner.png'\n ]);\n }", "title": "" }, { "docid": "b33aa01f2832813762ccbfb3d2d3532d", "score": "0.7846495", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n // \\App\\Models\\Category::factory(5)->create();\n $this->call(MenuCategoryTableSeeder::class);\n $this->call(AttributeTableSeeder::class);\n $this->call(CategoryTableSeeder::class);\n \\App\\Models\\Product::factory(50)->create();\n \\App\\Models\\AttributeProduct::factory(500)->create();\n \n // Circles\n $this->call(CircleTableSeeder::class);\n\n // Top Products\n $this->call(TopProductTableSeeder::class);\n\n // Random Products\n $this->call(RandomProductTableSeeder::class);\n }", "title": "" }, { "docid": "b6032e82ff7748213ddc30ee53d1f11b", "score": "0.7830752", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('roles')->insert(\n [\n [\n 'title' => 'Директор',\n 'name' => 'Director',\n 'parent_id' => '0'\n ],\n [\n 'title' => 'Зам директор',\n 'name' => 'Deputy director',\n 'parent_id' => '1'\n ],\n [\n 'title' => 'Начальник',\n 'name' => 'Director',\n 'parent_id' => '2'\n ],\n [\n 'title' => 'ЗАм начальник',\n 'name' => 'Deputy сhief',\n 'parent_id' => '3'\n ],\n [\n 'title' => 'Работник',\n 'name' => 'Employee',\n 'parent_id' => '4'\n ]\n ]);\n\n\n $this->call(departmentsTableSeeder::class);\n $this->call(employeesTableSeeder::class);\n }", "title": "" }, { "docid": "f72b073f1562b517a5cbd8caadf6f8b1", "score": "0.78215635", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = \\Faker\\Factory::create();\n\n foreach (range(1, 50) as $index) {\n\n Category::create([\n 'title' => $faker->jobTitle,\n ]);\n }\n }", "title": "" }, { "docid": "16547d5faa64dc71264cbf37cd0a5a22", "score": "0.7819104", "text": "public function run()\n {\n $this->call(UsersTableSeeder::class);\n $this->call(PermissionsSeeder::class);\n $this->call(RolesSeeder::class);\n $this->call(ThemeSeeder::class);\n\n //\n\n DB::table('paypal_info')->insert([\n 'client_id' => '',\n 'client_secret' => '',\n 'currency' => '',\n ]);\n DB::table('contact_us')->insert([\n 'content' => '',\n ]);\n DB::table('setting')->insert([\n 'site_name' => ' ',\n ]);\n DB::table('terms_and_conditions')->insert(['terms_and_condition' => 'text']);\n }", "title": "" }, { "docid": "7e80466dc8005ac35863dfc3e5c7c169", "score": "0.7817918", "text": "public function run()\n {\n User::create([\n 'name' => 'Administrator',\n 'email' => 'admin@admin.com',\n 'password' => Hash::make('adminadmin'),\n ]);\n\n Genre::factory(5)->create();\n Classification::factory(5)->create();\n Actor::factory()->count(50)->create();\n Director::factory(20)->create();\n Movie::factory(30)->create()->each(function ($movie) {\n $movie->actors(['actorable_id' => rand(30, 50)])->attach($this->array(rand(1, 50)));\n });\n Serie::factory(10)->create();\n Season::factory(20)->create();\n Episode::factory(200)->create()->each(function ($episode) {\n $episode->actors(['actorable_id' => rand(15, 30)])->attach($this->array(rand(1, 50)));\n });\n }", "title": "" }, { "docid": "c621382a9007bb3f312489ab7da81f56", "score": "0.7814175", "text": "public function run()\n {\n // Uncomment the below to wipe the table clean before populating\n // DB::table('user_roles')->delete();\n\n $roles = [\n ['id' => 1, 'name' => 'Director'],\n ['id' => 2, 'name' => 'Chair'],\n ['id' => 3, 'name' => 'Secretary'],\n ['id' => 4, 'name' => 'Faculty'],\n ];\n\n // Uncomment the below to run the seeder\n DB::table('user_roles')->insert($roles);\n }", "title": "" }, { "docid": "405076a95a7f251d6fa3259dc0d9fb6a", "score": "0.7811153", "text": "public function run()\n {\n $this->call(UserSeeder::class);\n // factory(Category::class, 25)->create();\n factory(Category::class, 10)->create();\n factory(Post::class, 50)->create();\n factory(Video::class, 5)->create();\n }", "title": "" }, { "docid": "40a0e12ed745bd76bf6ddbc9fe97e1a8", "score": "0.78103507", "text": "public function run()\n {\n $this->call(UsersTableSeeder::class);\n // DB::table('roles')->insert([\n // 'name' => 'employee',\n // 'guard_name' => 'web',\n // ]);\n\n // DB::table('roles')->insert([\n // 'name' => 'admin',\n // 'guard_name' => 'web',\n // ]);\n\n // DB::table('units')->insert([\n // 'name' => 'kg',\n // ]);\n // DB::table('units')->insert([\n // 'name' => 'litre',\n // ]);\n // DB::table('units')->insert([\n // 'name' => 'dozen',\n // ]);\n }", "title": "" }, { "docid": "7c1b3b143dd76d76cb8edbf417f06a8e", "score": "0.7806364", "text": "public function run()\n {\n // $this->call('UsersTableSeeder');\n // create 6 users\n // User::factory(1)->create()->each(function ($user){\n\n // // create 15 posts for each user\n // $post = Post::factory(1)->create()->each(function ($post){\n // // /create 5 comments for each post\n // $comment = Comment::factory(1)->make();\n // $post->comments()->saveMany($comment);\n // });\n // $user->posts()->saveMany($post);\n // }); \n \n\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n User::truncate();\n Post::truncate();\n Comment::truncate();\n User::factory(10)->create();\n Post::factory(50)->create();\n Comment::factory(100)->create();\n // Enable it back\n DB::statement('SET FOREIGN_KEY_CHECKS = 1');\n \n }", "title": "" }, { "docid": "3a3dbeb16bee414c118c000c37fbbdf7", "score": "0.7802872", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UserSeeder::class);\n $this->call(RolePermissionSeeder::class);\n $this->call(AppmodeSeeder::class);\n\n // \\App\\Models\\Appmode::factory(3)->create();\n \\App\\Models\\Doctor::factory(100)->create();\n \\App\\Models\\Unit::factory(50)->create();\n \\App\\Models\\Broker::factory(100)->create();\n \\App\\Models\\Patient::factory(100)->create();\n \\App\\Models\\Expence::factory(100)->create();\n \\App\\Models\\Testcategory::factory(100)->create();\n \\App\\Models\\Test::factory(50)->create();\n \\App\\Models\\Parameter::factory(50)->create();\n \\App\\Models\\Sale::factory(50)->create();\n \\App\\Models\\SaleItem::factory(100)->create();\n \\App\\Models\\Goption::factory(1)->create();\n \\App\\Models\\Pararesult::factory(50)->create();\n\n }", "title": "" }, { "docid": "84a2fe5ce7256b53cae2bd09c99e6aaf", "score": "0.7802348", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // DB::table('roles')->insert(\n // [\n // ['name' => 'admin', 'description' => 'Administrator'],\n // ['name' => 'student', 'description' => 'Student'],\n // ['name' => 'lab_tech', 'description' => 'Lab Tech'],\n // ['name' => 'it_staff', 'description' => 'IT Staff Member'],\n // ['name' => 'it_manager', 'description' => 'IT Manager'],\n // ['name' => 'lab_manager', 'description' => 'Lab Manager'],\n // ]\n // );\n\n // DB::table('users')->insert(\n // [\n // 'username' => 'admin', \n // 'password' => Hash::make('password'), \n // 'active' => 1,\n // 'name' => 'Administrator',\n // 'email' => 'programmerlemar@gmail.com',\n // 'role_id' => \\App\\Role::where('name', 'admin')->first()->id\n // ]\n // );\n\n DB::table('status')->insert([\n // ['name' => 'Active'],\n // ['name' => 'Cancel'],\n // ['name' => 'Disable'],\n // ['name' => 'Open'],\n // ['name' => 'Closed'],\n // ['name' => 'Resolved'],\n ['name' => 'Used'],\n ]);\n }", "title": "" }, { "docid": "b2a340012128cdc0ce9898ea0cc3c209", "score": "0.77989215", "text": "public function run()\n {\n\n \t// Making main admin role\n \tDB::table('roles')->insert([\n 'name' => 'Admin',\n ]);\n\n // Making main category\n \tDB::table('categories')->insert([\n 'name' => 'Other',\n ]);\n\n \t// Making main admin account for testing\n \tDB::table('users')->insert([\n 'name' \t\t=> 'Admin',\n 'email' \t=> 'admin@example.com',\n 'password' => bcrypt('12345'),\n 'role_id' => 1,\n 'created_at' => date('Y-m-d H:i:s' ,time()),\n 'updated_at' => date('Y-m-d H:i:s' ,time())\n ]);\n\n \t// Making random users and posts\n factory(App\\User::class, 10)->create();\n factory(App\\Post::class, 35)->create();\n }", "title": "" }, { "docid": "48fe7d1d0d33106e3241378b6668a775", "score": "0.7796966", "text": "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(User::class, 50)->create();\n factory(Post::class, 500)->create();\n factory(Category::class, 10)->create();\n factory(Tag::class, 150)->create();\n factory(Image::class, 1500)->create();\n factory(Video::class, 500)->create();\n factory(Comment::class, 1500)->create();\n }", "title": "" }, { "docid": "461c8a228780b7db8fef36082242e109", "score": "0.7795819", "text": "public function run()\n {\n $faker = Faker::create();\n\n \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Chef',\n 'salario' => '15000.00'\n ));\n\n\t\t \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Mesonero',\n 'salario' => '12000.00'\n ));\n }", "title": "" }, { "docid": "706ff7ec69aebe11396b7ff7e05d374c", "score": "0.77862066", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UsersTableSeeder::class);\n\n // DB::table('users')->insert([\n // 'name' => 'User1',\n // 'email' => 'admin@admin.com',\n // 'password' => bcrypt('password'),\n // ]);\n\n\n $faker = Faker::create();\n \n foreach (range(1,10) as $index){\n DB::table('companies')->insert([\n 'name' => $faker->company(),\n 'email' => $faker->email(10).'@gmail.com',\n 'logo' => $faker->image($dir = '/tmp', $width = 640, $height = 480),\n 'webiste' => $faker->domainName(),\n \n ]);\n }\n \n \n foreach (range(1,10) as $index){\n DB::table('employees')->insert([\n 'first_name' => $faker->firstName(),\n 'last_name' => $faker->lastName(),\n 'company' => $faker->company(),\n 'email' => $faker->str_random(10).'@gmail.com',\n 'phone' => $faker->e164PhoneNumber(),\n \n ]);\n }\n\n\n\n }", "title": "" }, { "docid": "d807dce754ed136319cb37b9a9be6494", "score": "0.77856374", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(Localizacao::class, 5)->create();\n factory(Estado::class, 2)->create();\n factory(Tamanho::class, 4)->create();\n factory(Cacifo::class, 20)->create();\n factory(Cliente::class, 10)->create();\n factory(UserType::class, 2)->create();\n factory(User::class, 8)->create();\n factory(Encomenda::class, 25)->create();\n factory(LogCacifo::class, 20)->create();\n\n foreach (Encomenda::all() as $encomenda) {\n $user = User::all()->random();\n DB::table('encomenda_user')->insert(\n [\n 'user_id' => $user->id,\n 'encomenda_id' => $encomenda->id,\n 'user_type' => $user->tipo_id,\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now()\n ]\n );\n }\n\n }", "title": "" }, { "docid": "4a8a5f2d0bf57a648aa039d994ba098c", "score": "0.7780426", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $spec = [\n [\n 'name'=>'Dokter Umum',\n 'title_start'=> 'dr.',\n \"title_end\"=>null,\n ],[\n 'name'=>\"Spesialis Kebidanan Kandungan\",\n 'title_start'=>\"dr.\",\n 'title_end'=>\"Sp.OG\",\n ],[\n \"name\"=>\"Spesialis Anak\",\n \"title_start\"=>\"dr.\",\n \"title_end\"=>\"Sp.A\",\n ],[\n \"name\"=>\"Spesialis penyakit mulut\",\n \"title_start\"=>\"drg.\",\n \"title_end\"=>\"Sp.PM\"\n ],[\n \"name\"=>\"Dokter Gigi\",\n \"title_start\"=>\"drg.\",\n \"title_end\"=>null,\n ]\n ];\n\n DB::table(\"specializations\")->insert($spec);\n\n \n factory(User::class, 10)->create([\n 'type'=>\"doctor\",\n ]);\n factory(User::class, 10)->create([\n 'type'=>\"user\",\n ]);\n factory(Message::class, 100)->create();\n }", "title": "" }, { "docid": "e9a395588cf010ce0bc08d6b3e36927d", "score": "0.7777486", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->truncteTables([\n 'users',\n 'products'\n ]);\n\n $this->call(UsersSeeder::class);\n $this->call(ProductsSeeder::class);\n\n }", "title": "" }, { "docid": "b32c8e0e5988bd2cbc8f9b3c1069084f", "score": "0.7775103", "text": "public function run()\n {\n //這邊用到集合 pluck() 將全部User id取出並轉為陣列,如 [1,2,3,4,5]\n $user_ids = User::all()->pluck('id')->toArray();\n\n //同上\n $topic_id = Topic::all()->pluck('id')->toArray();\n\n //取Faker 實例化\n $faker = app(Faker\\Generator::class);\n\n //生成100筆假數據\n $posts = factory(Post::class)->times(100)\n ->make()->each(function ($post,$index) use ($user_ids,$topic_id,$faker)\n {\n //用User id隨機取一個並賦值\n $post->user_id = $faker->randomElement($user_ids);\n //用Topic id隨機取一個並賦值\n $post->topic_id = $faker->randomElement($topic_id);\n });\n //將數據轉為陣列在插入資料庫\n Post::insert($posts->toArray());\n }", "title": "" }, { "docid": "0ac3bd79ccafd183f64a83daa8e8b734", "score": "0.77742934", "text": "public function run()\n {\n //\n DB::table('users')->insert([\n 'name' => 'Admin',\n 'email' => 'admin@example.com',\n 'level' => 'admin',\n 'password' => Hash::make('12345678'),\n ]);\n\n factory(App\\User::class, 9)->create([\n 'password' => Hash::make('12345678')\n ]);\n\n factory(App\\Author::class, 10)->create();\n\n factory(App\\Book::class, 10)->create();\n\n $author = App\\Author::all();\n\n App\\Book::all()->each(function ($book) use ($author) { \n $book->author()->attach(\n $author->random(rand(1, 3))->pluck('id')->toArray()\n ); \n });\n \n }", "title": "" }, { "docid": "10bba340ceff4aa7654e77f3264df8b2", "score": "0.7765202", "text": "public function run()\n {\n /**\n * Dummy seeds\n */\n DB::table('metas')->truncate();\n $faker = Faker::create();\n\n for ($i=0; $i < 10; $i++) { \n DB::table('metas')->insert([\n 'id_rel' => $faker->randomNumber(),\n 'titulo' => $faker->sentence,\n 'descricao' => $faker->paragraph,\n 'justificativa' => $faker->paragraph,\n 'valor_inicial' => $faker->numberBetween(0,100),\n 'valor_atual' => $faker->numberBetween(0,100),\n 'valor_final' => $faker->numberBetween(0,10),\n 'regras' => json_encode([$i => [\"values\" => $faker->words(3)]]),\n 'types' => json_encode([$i => [\"values\" => $faker->words(2)]]),\n 'categorias' => json_encode([$i => [\"values\" => $faker->words(4)]]),\n 'tags' => json_encode([$i => [\"values\" => $faker->words(5)]]),\n 'active' => true,\n ]);\n }\n\n\n }", "title": "" }, { "docid": "e4a3f3c54eb1dbfbeaf14daf25634bfc", "score": "0.7762492", "text": "public function run()\n {\n // $this->call(UserTableSeeder::class);\n\n $faker = Faker::create();\n\n $lessonIds = Lesson::lists('id')->all(); // An array of ID's in that table [1, 2, 3, 4, 5, 7]\n $tagIds = Tag::lists('id')->all();\n\n foreach(range(1, 30) as $index)\n {\n // a real lesson id\n // a real tag id\n DB::table('lesson_tag')->insert([\n 'lesson_id' => $faker->randomElement($lessonIds),\n 'tag_id' => $faker->randomElement($tagIds),\n ]);\n }\n }", "title": "" }, { "docid": "0350e1fc9ed9c9553317db568c12e5ba", "score": "0.77623445", "text": "public function run()\n {\n $this->call(CategoriasTableSeeder::class);\n $this->call(UfsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n $this->call(UserTiposTableSeeder::class);\n factory(App\\User::class, 2)->create();\n/* factory(App\\Models\\Categoria::class, 20)->create();*/\n/* factory(App\\Models\\Anuncio::class, 50)->create();*/\n }", "title": "" }, { "docid": "80029eda94306be7dd06321a86e96e4f", "score": "0.77621746", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n Language::truncate();\n Reason::truncate();\n Report::truncate();\n Category::truncate();\n Position::truncate();\n\n $languageQuantity = 10;\n $reasonQuantity = 10;\n $reportQuantity = 10;\n $categoryQuantity = 10;\n $positionQuantity = 10;\n\n factory(Language::class,$languageQuantity)->create();\n factory(Reason::class,$reasonQuantity)->create();\n \n factory(Report::class,$reportQuantity)->create();\n \n factory(Category::class,$categoryQuantity)->create();\n \n factory(Position::class,$positionQuantity)->create();\n\n }", "title": "" }, { "docid": "2f5b59082890fe6ed7dc8f5c50b7611e", "score": "0.77610433", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n // seed users\n factory(\\App\\User::class, 1)->create(['name' => 'test', 'email' => 'test@abv.bg', 'password' => bcrypt('test')]);\n factory(\\App\\User::class, 50)->create();\n\n // seed channels\n factory(\\App\\Channel::class, 20)->create();\n\n // seed threads\n factory(\\App\\Thread::class, 10)->create();\n\n // seed replies\n factory(\\App\\Reply::class, 10)->create();\n\n\n }", "title": "" }, { "docid": "7124f0c07efbf29272763999a735a94f", "score": "0.77606887", "text": "public function run()\n {\n $this->call([\n ArticleSeeder::class, \n TagSeeder::class,\n Arttagrel::class\n ]);\n // \\App\\Models\\User::factory(10)->create();\n \\App\\Models\\Article::factory()->count(7)->create();\n \\App\\Models\\Tag::factory()->count(15)->create(); \n \\App\\Models\\Arttagrel::factory()->count(15)->create(); \n }", "title": "" }, { "docid": "5c8214e2d3c221fbe38a112c0256f06f", "score": "0.7759768", "text": "public function run()\n {\n // $this->call('UsersTableSeeder');\n DB::table('users')->insert([\n 'name' => 'Admin',\n 'role' => 1,\n 'email' => 'admin@gmail.com',\n 'password' => '$2y$10$UT2JvBOse3.6uuElsmqDpOhvp8d5PkoRdmbIHDMwOJmr226GRrmKe',\n ]);\n\n DB::table('programs')->insert([\n ['name' => 'Ingeniería de sistemas'],\n ['name' => 'Ingeniería electrónica'],\n ['name' => 'Ingeniería industrial'],\n ['name' => 'Diseño gráfico'],\n ['name' => 'Psicología'],\n ['name' => 'Administración de empresas'],\n ['name' => 'Negocios internacionales'],\n ['name' => 'Criminalística'],\n ]);\n }", "title": "" }, { "docid": "6f031bf4bd571edf71627cb6a09568cd", "score": "0.77596676", "text": "public function run()\n {\n $this->call(ArticulosTableSeeder::class);\n /*DB::table('articulos')->insert([\n 'titulo' => str_random(50),\n 'cuerpo' => str_random(200),\n ]);*/\n }", "title": "" }, { "docid": "2290f88bd069e9499c0321a79bda7083", "score": "0.7759102", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('filials')->insert([\n 'nome' => 'Filial 1',\n 'endereco' => 'Endereco, 1',\n 'bairro' => 'Bairro',\n 'cidade' => 'Cidade',\n 'uf' => 'ES',\n 'inscricao_estadual' => 'ISENTO',\n 'cnpj' => '00123456000178'\n ]);\n DB::table('users')->insert([\n 'name' => 'Vitor Braga',\n 'data_nascimento' => '1991-03-16',\n 'sexo' => 'M',\n 'cpf' => '12345678900',\n 'endereco' => 'Rua Luiz Murad, 2',\n 'bairro' => 'Vista da Serra',\n 'cidade' => 'Colatina',\n 'uf' => 'ES',\n 'cargo' => 'Desenvolvedor',\n 'salario' => '100.00',\n 'situacao' => '1',\n 'password' => bcrypt('123456'),\n 'id_filial' => '1'\n ]);\n }", "title": "" }, { "docid": "b8c622da980d0f20206cf3c497b69940", "score": "0.7754705", "text": "public function run()\n {\n Schema::disableForeignKeyConstraints();\n\n Role::truncate();\n User::truncate();\n DB::table('category_posts')->truncate();\n\n User::flushEventListeners();\n Category::flushEventListeners();\n Post::flushEventListeners();\n Comment::flushEventListeners();\n Game::flushEventListeners();\n Newsletter::flushEventListeners();\n Client::flushEventListeners();\n // $this->call(UsersTableSeeder::class);\n $this->call(RolesTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n // factory(User::class, 50)->create();\n $this->call(BannersTableSeeder::class);\n $this->call(BasicsTableseeder::class);\n $this->call(SocialsTableseeder::class);\n $this->call(ContactInformationsTableseeder::class);\n $this->call(ClientsTableseeder::class);\n $this->call(AboutsTableseeder::class);\n $this->call(ContactusSeeder::class);\n $this->call(NewslettersSeeder::class);\n $this->call(GamesSeederTable::class);\n $this->call(PagesTableSeeder::class);\n $this->call(CategoriesTableSeeder::class);\n $this->call(PostsTableSeeder::class);\n $this->call(CommentsTableSeeder::class);\n $this->call(CategoryPostsTableSeeder::class);\n $this->call(GalleriesTableSeeder::class);\n\n Schema::enableForeignKeyConstraints();\n \n }", "title": "" }, { "docid": "81e5569fa61ad16b28597151ca8922ab", "score": "0.7731372", "text": "public function run()\n {\n $faker = Faker\\Factory::create('fr_FR');\n $user = App\\User::pluck('id')->toArray();\n $data = [];\n\n for ($i = 1; $i <= 100; $i++) {\n $title = $faker->sentence(rand(4, 10)); // astuce pour le slug\n array_push($data, [\n 'title' => $title,\n 'sub_title' => $faker->sentence(rand(10, 15)),\n 'slug' => Str::slug($title),\n 'body' => $faker->realText(4000),\n 'published_at' => $faker->dateTime(),\n 'user_id' => $faker->randomElement($user),\n ]);\n }\n DB::table('articles')->insert($data);\n }", "title": "" }, { "docid": "c74d696e8998a24c61e719b8157653fa", "score": "0.772796", "text": "public function run()\n\t{\n\t\tDB::table(self::TABLE_NAME)->delete();\n\n\t\tforeach (seed(self::TABLE_NAME) as $row)\n\t\t\t$records[] = [\n\t\t\t\t'id'\t\t\t\t=> $row->id,\n\t\t\t\t'created_at'\t\t=> $row->created_at ?? Carbon::now(),\n\t\t\t\t'updated_at'\t\t=> $row->updated_at ?? Carbon::now(),\n\n\t\t\t\t'sport_id'\t\t\t=> $row->sport_id,\n\t\t\t\t'gender_id'\t\t\t=> $row->gender_id,\n\t\t\t\t'tournamenttype_id'\t=> $row->tournamenttype_id ?? null,\n\n\t\t\t\t'name'\t\t\t\t=> $row->name,\n\t\t\t\t'external_id'\t\t=> $row->external_id ?? null,\n\t\t\t\t'is_top'\t\t\t=> $row->is_top ?? null,\n\t\t\t\t'logo'\t\t\t\t=> $row->logo ?? null,\n\t\t\t\t'position'\t\t\t=> $row->position ?? null,\n\t\t\t];\n\n\t\tinsert(self::TABLE_NAME, $records ?? []);\n\t}", "title": "" }, { "docid": "3d873be91ed6d1da3295d915f287cf94", "score": "0.77274096", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n\n //Seeding the database\n \\DB::table('authors')->insert([\n [\n 'name' => 'Diane Brody',\n 'occupation' => 'Software Architect, Freelancer',\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s')\n ],\n [\n 'name' => 'Andrew Quentin',\n 'occupation' => 'Cognitive Scientist',\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s')\n ]\n ]);\n\n \\DB::table('publications')->insert([\n [\n 'title' => 'AI Consciousness Level',\n 'excerpt' => 'Lorem ipsum dolor sit amet, consectetur adipisicing elit',\n 'type' => 'Book',\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s')\n ],\n [\n 'title' => 'Software Architecture for the experienced',\n 'excerpt' => 'Lorem ipsum dolor sit amet, consectetur adipisicing elit',\n 'type' => 'Report of a conference',\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s')\n ]\n ]);\n\n \\DB::table('publication_authors')->insert([\n [\n 'publication_id' => 1,\n 'author_id' => 2\n ],\n [\n 'publication_id' => 2,\n 'author_id' => 1\n ]\n ]);\n }", "title": "" }, { "docid": "aee9f58c36821ccc960ba32ca0f7c676", "score": "0.77264154", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(App\\Kategorija::class, 10)->create();\n factory(App\\Proizvod::class, 50)->create();\n\n foreach(Proizvod::all() as $proizvod)\n {\n $proizvod->kategorije()->sync(kategorija::pluck('id')->random(rand(1,5)));\n $proizvod->save();\n }\n }", "title": "" }, { "docid": "2ecfbbe58300fc8debd0410b17f21e9d", "score": "0.771693", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n DB::table('users')->insert([\n 'name' => 'Demo',\n 'phone' => '0737116001',\n 'email' => 'demo@gmail.com',\n 'password' => Hash::make('demo'),\n ]);\n\n DB::table('roles')->insert([\n 'name' => 'admin',\n 'slug' => 'admin',\n ]);\n\n\n DB::table('roles')->insert([\n 'name' => 'user',\n 'slug' => 'user',\n ]);\n\n DB::table('roles')->insert([\n 'name' => 'manager',\n 'slug' => 'manager',\n ]);\n\n DB::table('roles_users')->insert([\n 'user_id' => 1,\n 'role_id' => 1,\n ]);\n }", "title": "" }, { "docid": "01970702dcc3d254417ea716f48f61ba", "score": "0.77157193", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->call(ProductsTableSeeder::class);\n $this->call(SettingTableSeeder::class);\n // DB::table('orders')->insert([\n // 'name' => 'Tran Minh Luan',\n // 'address' => 'So 19, duong 13',\n // 'number' => '0163375305',\n // 'products' => 'lamp'\n // ]);\n //$this->call(OrdersTableSeeder::class);\n }", "title": "" }, { "docid": "603a2ad87e835d00866a742b9f5d2a52", "score": "0.77141565", "text": "public function run()\n {\n $users = User::factory()->count(10)->create();\n\n $categoriesNames = [\n 'Programación',\n 'Desarrollo Web',\n 'Desarrollo Movil',\n 'Inteligencia Artificial',\n ];\n $collection = collect($categoriesNames);\n $categories = $collection->map(function ($category, $key){\n return Category::factory()->create(['name' => $category]);\n });\n\n Post::factory()\n ->count(10)\n ->make()\n ->each(function($post) use ($users, $categories){\n $post->author_id = $users->random()->id;\n $post->category_id = $categories->random()->id;\n $post->save();\n });\n \n $user = User::factory()->create();\n $user->name = 'Jesús Ramírez';\n $user->email = 'jesus.ra98@hotmail.com';\n $user->password = Hash::make('jamon123');\n $user->save();\n }", "title": "" }, { "docid": "006d108790ce64b4ef4a883f12760a4c", "score": "0.77140933", "text": "public function run()\n {\n $this->call(GenreSeeder::class);\n \\App\\Models\\User::factory(20)->create();\n \\App\\Models\\User::factory()->create([\n 'username' => 'admin',\n 'name' => 'Admin User',\n 'email' => 'admin@example.com',\n 'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi', //password\n 'is_admin' => true\n ]);\n \\App\\Models\\Movie::factory(100)->create();\n \\App\\Models\\Review::factory(1000)->create();\n \\App\\Models\\Celeb::factory(100)->create();\n \\App\\Models\\CelebMovie::factory(500)->create();\n \\App\\Models\\GenreMovie::factory(200)->create();\n \\App\\Models\\MovieUser::factory(100)->create();\n }", "title": "" }, { "docid": "b775152e814ada39237f6d02a27c5392", "score": "0.77140456", "text": "public function run()\n {\n // for($i=1;$i<11;$i++){\n // DB::table('post')->insert(\n // ['title' => 'Title'.$i,\n // 'post' => 'Post'.$i,\n // 'slug' => 'Slug'.$i]\n // );\n // }\n $faker = Faker\\Factory::create();\n \n for($i=1;$i<20;$i++){\n $dname = $faker->name;\n DB::table('post')->insert(\n ['title' => $dname,\n 'post' => $faker->text($maxNbChars = 200),\n 'slug' => str_slug($dname)]\n );\n }\n }", "title": "" }, { "docid": "49da62fe0218d7ae61e34a8c8728ab7e", "score": "0.771243", "text": "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Contract::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Contract::create([\n 'serialnumbers' => $faker->numberBetween($min = 1000000, $max = 2000000),\n 'address' => $faker->address,\n 'landholder' => $faker->lastName,\n 'renter' => $faker->lastName,\n 'price' => $faker->numberBetween($min = 10000, $max = 50000),\n 'rent_start' => $faker->date($format = 'Y-m-d', $max = 'now'),\n 'rent_end' => $faker->date($format = 'Y-m-d', $max = 'now'),\n ]);\n }\n }", "title": "" }, { "docid": "67228a7edb1e67f6bdd0b8d19bb2b59a", "score": "0.7705309", "text": "public function run()\n {\n Model::unguard();\n $faker = Faker::create();\n for ($i = 0; $i <= 100; $i++) {\n DB::table('posts')->insert([\n 'published' => 1,\n 'title' => $faker->sentence(),\n 'body' => $faker->text(500),\n ]);\n }\n Model::reguard();\n }", "title": "" }, { "docid": "deefe59dca3f24e874dfffb1bb15beeb", "score": "0.7704354", "text": "public function run()\n {\n Campus::truncate();\n Canteen::truncate();\n Dorm::truncate();\n\n $faker = Faker\\Factory::create();\n $schools = School::all();\n foreach ($schools as $school) {\n \tforeach (range(1, 2) as $index) {\n\t \t$campus = Campus::create([\n\t \t\t'school_id' => $school->id,\n\t \t\t'name' => $faker->word . '校区',\n\t \t\t]);\n\n \t$campus->canteens()->saveMany(factory(Canteen::class, mt_rand(2,3))->make());\n $campus->dorms()->saveMany(factory(Dorm::class, mt_rand(2,3))->make());\n\n }\n }\n }", "title": "" }, { "docid": "c3bf798056554c74cc9ea30b5654cf7d", "score": "0.7704061", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => 'admin@gmail.com',\n 'password' => bcrypt('admin'),\n 'seq_q'=>'1',\n 'seq_a'=>'admin'\n ]);\n\n // DB::table('bloods')->insert([\n // ['name' => 'A+'],\n // ['name' => 'A-'],\n // ['name' => 'B+'],\n // ['name' => 'B-'],\n // ['name' => 'AB+'],\n // ['name' => 'AB-'],\n // ['name' => 'O+'],\n // ['name' => 'O-'],\n // ]);\n\n \n }", "title": "" }, { "docid": "cb57daba0c53f155a9c942af3dc024bd", "score": "0.7703433", "text": "public function run()\n {\n // 指令::php artisan db:seed --class=day20180611_campaign_event_table_seeder\n // 第一次執行,執行前全部資料庫清空\n $now_date = date('Y-m-d h:i:s');\n // 角色\n DB::table('campaign_event')->truncate();\n DB::table('campaign_event')->insert([\n // system\n ['id' => '1', 'keyword' => 'reg', 'created_at' => $now_date, 'updated_at' => $now_date],\n ['id' => '2', 'keyword' => 'order', 'created_at' => $now_date, 'updated_at' => $now_date],\n ['id' => '3', 'keyword' => 'complete', 'created_at' => $now_date, 'updated_at' => $now_date],\n ]);\n }", "title": "" }, { "docid": "cf7fcb1fe5570ba6a475aaf00815d6f6", "score": "0.7701871", "text": "public function run()\n {\n\n //SEEDING MASTER DATA\n $this->call([\n BadgeSeeder::class,\n AchievementSeeder::class\n ]);\n\n //SEEDING FAKER DATA\n Lesson::factory()\n ->count(20)\n ->create();\n\n Comment::factory()->count(2)->create();\n\n }", "title": "" }, { "docid": "36020ec2fbcaf681814118ed22133007", "score": "0.77008796", "text": "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n News::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 10; $i++) {\n News::create([\n 'title' => $faker->sentence,\n 'summary' => $faker->sentence,\n 'content' => $faker->paragraph,\n 'imagePath' => '/img/exclamation_mark.png'\n ]);\n }\n }", "title": "" }, { "docid": "b44c7d8fac5a941c491e731eceea38f2", "score": "0.76985973", "text": "public function run()\n {\n \\DB::table('employees')->delete();\n\n $faker = \\Faker\\Factory::create('ja_JP');\n\n $role_id = ['1','2','3'];\n\n for ($i = 0; $i < 10; $i++) {\n \\App\\Models\\Employee::create([\n 'last_name' =>$faker->lastName() ,\n 'first_name' => $faker->firstName(),\n 'mail' => $faker->email(),\n 'password' => Hash::make( \"password.$i\"),\n 'birthday' => $faker->date($format='Y-m-d',$max='now'),\n 'role_id' => $faker->randomElement($role_id)\n ]);\n }\n }", "title": "" }, { "docid": "09fe947dea0cf1a8047d0c9bb4bf806d", "score": "0.76984954", "text": "public function run()\n {\n // gọi tới file UserTableSeeder nếu bạn muốn chạy users seed\n // $this->call(UsersTableSeeder::class);\n // gọi tới file PostsTableSeeder nếu bạn muốn chạy posts seed\n $this->call(PostsTableSeeder::class); \n // gọi tới file CategoriesTableSeeder nếu bạn muốn chạy categories seed\n $this->call(CategoriesTableSeeder::class);\n $this->call(PostTagsTableSeeder::class);\n $this->call(TagsTableSeeder::class);\n $this->call(ProjectTableSeeder::class);\n }", "title": "" }, { "docid": "ada5d5fc3637b7a815b289340c1ad5fe", "score": "0.76982635", "text": "public function run()\n {\n $users = $this->getSeedUsers();\n $size = count($users);\n for ($i = 0; $i < $size; $i++) {\n DB::table('users')->insert($users[$i]);\n }\n\n $court = $this->getSeedCourt();\n DB::table('courts')->insert($court);\n\n $reserves = $this->getSeedReserves();\n $size = count($reserves);\n for ($i = 1; $i <= $size; $i++) {\n DB::table('reserves')->insert($reserves[$i]);\n }\n\n }", "title": "" }, { "docid": "980af6960bda0fc5e03df83c2b9e41cc", "score": "0.7698196", "text": "public function run()\n {\n // $categories = factory(App\\Category::class, 10)->create();\n\n $categories = ['Appetizers', 'Beverages', 'Breakfast', 'Detox Water', 'Fresh Juice', 'Main Course', 'Pasta', 'Pizza', 'Salad', 'Sandwiches', 'Soups', 'Special Desserts', 'Hot Drinks', 'Mocktails', 'Shakes', 'Water and Softdrinks'];\n foreach( $categories as $category )\n { \n Category::create([\n 'name' => $category\n ]);\n }\n\n $categories = Category::all();\n\n foreach( $categories as $category )\n {\n factory(App\\Menu::class, 10)->create([\n 'category_id' => $category->id\n ]);\n }\n \t\n // $this->call(UsersTableSeeder::class);\n }", "title": "" }, { "docid": "eae1af9587a5c752d73027a3d713fa13", "score": "0.76964504", "text": "public function run()\n {\n User::firstOrCreate([\n 'email' => 'admin@admin.com'\n ], [\n 'name' => 'admin',\n 'password' => Hash::make('admin'),\n ]);\n\n $users =\\App\\Models\\User::factory(1)->create();\n $schools =\\App\\Models\\School::factory(10)->create();\n $employee = \\App\\Models\\Employee::factory(100)->make(['school_id' => null])->each(function ($employee) use($schools){\n $employee->school_id = $schools->random()->id;\n $employee->save();\n\n });\n }", "title": "" }, { "docid": "45367153bbaff6732338651be0b5630f", "score": "0.7696405", "text": "public function run()\n {\n // Admins\n User::factory()->create([\n 'name' => 'Zaiman Noris',\n 'username' => 'rognales',\n 'email' => 'rognales@gmail.com',\n 'active' => true,\n ]);\n\n User::factory()->create([\n 'name' => 'Affiq Rashid',\n 'username' => 'affiqr',\n 'email' => 'sonic21danger@gmail.com',\n 'active' => true,\n ]);\n\n // Only seed test data in non-prod\n if (! app()->isProduction()) {\n Member::factory()->count(1000)->create();\n Staff::factory()->count(1000)->create();\n\n Participant::factory()\n ->addSpouse()\n ->addChildren()\n ->addInfant()\n ->addOthers()\n ->count(500)\n ->hasUploads(2)\n ->create();\n }\n }", "title": "" }, { "docid": "1a75d4c49ea06f308772e6345b798116", "score": "0.7695935", "text": "public function run()\n {\n //metodo para eiminar una carpeta en storage antes de ejecutar loos seeders\n Storage::deleteDirectory('posts');\n //metodo para crear una carpeta en storage antes de ejecutar loos seeders\n Storage::makeDirectory('posts');\n\n //llamar al seeder de rolSeeder quiere decir el de roles\n $this->call(RolSeeder::class);\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n Tag::factory(8)->create();\n $this->call(PostSeeder::class);\n \n }", "title": "" }, { "docid": "1c93783c2ea23b1bcf0fcecb87e597a1", "score": "0.7693655", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('planeta')->insert([\n\n 'name'=>'Jupiter',\n 'peso'=>'1321'\n \n ]);\n\n DB::table('planeta')->insert([\n\n 'name'=>'Saturno',\n 'peso'=>'6546'\n \n ]);\n\n DB::table('planeta')->insert([\n\n 'name'=>'Urano',\n 'peso'=>'564564'\n \n ]);\n\n DB::table('planeta')->insert([\n\n 'name'=>'netuno',\n 'peso'=>'5213'\n \n ]);\n }", "title": "" }, { "docid": "cdec075ee5f589f68df7d8e373f800d0", "score": "0.76934415", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n for ($i=0; $i<100; $i++) {\n $faker = Faker\\Factory::create();\n \\App\\Models\\Agencies::create([\n 'name'=>$faker->name\n ]);\n }\n\n for ($i=0; $i<100000; $i++){\n $faker = Faker\\Factory::create();\n \\App\\Models\\User::create([\n 'first_name'=>$faker->firstName,\n 'last_name'=>$faker->lastName,\n 'email'=>$faker->email,\n 'agencies_id'=>$faker->numberBetween(1,10)\n ]);\n }\n\n }", "title": "" }, { "docid": "016c973d20f43327498477b8b0832042", "score": "0.7692694", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n Employee::factory()->create(['email' => 'sovon.kucse@gmail.com']);\n Brand::factory()->count(3)->create();\n $this->call([\n TagSeeder::class,\n AttributeSeeder::class,\n AttributeValueSeeder::class,\n ProductSeeder::class,\n ]);\n }", "title": "" }, { "docid": "9c0db96925dc1f490c921bb00a04e003", "score": "0.7691264", "text": "public function run()\n {\n $this->call(RolesTableSeeder::class); // crée les rôles\n $this->call(PermissionsTableSeeder::class); // crée les permissions\n\n factory(Employee::class,3)->create();\n factory(Provider::class,1)->create();\n\n $user = User::create([\n 'name'=>'Alioune Bada Ndoye',\n 'email'=>'abada@gmail.com',\n 'phone'=>'773012470',\n 'password'=>bcrypt('123'),\n ]);\n Employee::create([\n 'job'=>'Informaticien',\n 'user_id'=>User::where('email','abada@gmail.com')->first()->id,\n 'point_id'=>Point::find(1)->id,\n ]);\n $user->assignRole('admin');\n }", "title": "" }, { "docid": "7cfbc2c0b0ca1e8d2a8048e9780086c8", "score": "0.7690576", "text": "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(User::class, 1)\n \t->create(['email' => 'eddyjaair@gmail.com']);\n\n factory(Category::class, 5)->create();\n }", "title": "" }, { "docid": "1b46fa2a96790281813264fc3f8288b5", "score": "0.76882726", "text": "public function run()\n {\n //$this->call(UsersTableSeeder::class);\n $this->call(rootSeed::class);\n factory(App\\Models\\Egresado::class,'hombre',15)->create();\n factory(App\\Models\\Egresado::class,'mujer',15)->create();\n factory(App\\Models\\Administrador::class,5)->create();\n factory(App\\Models\\Notificacion::class,'post',10)->create();\n factory(App\\Models\\Notificacion::class,'mensaje',5)->create();\n factory(App\\Models\\Egresado::class,'bajaM',5)->create();\n factory(App\\Models\\Egresado::class,'bajaF',5)->create();\n factory(App\\Models\\Egresado::class,'suscritam',5)->create();\n factory(App\\Models\\Egresado::class,'suscritaf',5)->create();\n }", "title": "" }, { "docid": "3cd1f7a4183660348d9343661c46ac18", "score": "0.7687553", "text": "public function run()\n {\n Eloquent::unguard();\n\n $path = 'resources/sql/seed.sql';\n DB::unprepared(file_get_contents($path));\n $manager = new User();\n $manager->username = 'root';\n $manager->email = 'root@root.com';\n $manager->password_hash = bcrypt('rootroot');\n $manager->date = '1920-01-01';\n $manager->user_role = 'Manager';\n $manager->id_image = 81;\n $manager->save();\n $user = new User();\n $user->username = 'johndoe';\n $user->email = 'john@doe.com';\n $user->address = 'John Doe Village';\n $user->password_hash = bcrypt('johndoe');\n $user->date = '1920-01-01';\n $user->user_role = 'Customer';\n $user->id_image = 81;\n $user->security_question = 'Socks';\n $user->save();\n $wishlist = new Wishlist();\n $wishlist->name = 'Favorites';\n $wishlist->id_user = $user->id;\n $wishlist->save();\n\n $this->command->info('Database seeded!');\n }", "title": "" }, { "docid": "98c57ab9dc9353ad077141992a0dd327", "score": "0.7687021", "text": "public function run()\n {\n Schema::disableForeignKeyConstraints();\n $this->call(GenreSeeder::class);\n $this->call(AuthorSeeder::class);\n $this->call(BookSeeder::class);\n Schema::enableForeignKeyConstraints();\n \n // create an admin user with email admin@library.test and password secret\n User::truncate();\n User::create(array('name' => 'Administrator',\n 'email' => 'admin@library.test', \n 'password' => bcrypt('secret'),\n 'role' => 1)); \n }", "title": "" }, { "docid": "bba2ff1a30d0719e1aa8364f25fac587", "score": "0.7686844", "text": "public function run()\n {\n // $faker=Faker::create();\n // foreach(range(1,100) as $index)\n // {\n // DB::table('products')->insert([\n // 'name' => $faker->name,\n // 'price' => rand(10,100000)/100\n // ]);\n // }\n }", "title": "" }, { "docid": "39bb4261d54256e6189d729e7893cf92", "score": "0.7685065", "text": "public function run()\n {\n Schema::disableForeignKeyConstraints();\n Grade::truncate();\n Schema::enableForeignKeyConstraints();\n\n $faker = \\Faker\\Factory::create();\n\n for ($i = 0; $i < 10; $i++) {\n Grade::create([\n 'letter' => $faker->randomElement(['а', 'б', 'в']),\n 'school_id' => $faker->unique()->numberBetween(1, School::count()),\n 'level' => 1\n ]);\n }\n }", "title": "" }, { "docid": "6f4cd475360e7bf0d5a1fe2752972955", "score": "0.76846963", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(RoleSeeder::class);\n $this->call(KategoriSeeder::class);\n $this->call(UsersTableSeeder::class);\n $roles = \\App\\Models\\Role::all();\n \\App\\Models\\User::All()->each(function ($user) use ($roles){\n // $user->roles()->saveMany($roles);\n $user->roles()->attach(\\App\\Models\\Role::where('name', 'admin')->first());\n });\n // \\App\\Models\\User::all()->each(function ($user) use ($roles) { \n // $user->roles()->attach(\n // $roles->random(rand(1, 2))->pluck('id')->toArray()\n // ); \n // });\n }", "title": "" }, { "docid": "05fe3186975dd67e97302afe2c8d7e44", "score": "0.7683827", "text": "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(App\\User::class,5)->create();//5 User created\n factory(App\\Model\\Genre::class,5)->create();//5 genres\n factory(App\\Model\\Film::class,6)->create();//6 films\n factory(App\\Model\\Comment::class, 20)->create();// 20 comments\n }", "title": "" }, { "docid": "54370a0836434e352058b6fa0c527ca2", "score": "0.7678287", "text": "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n User::create([\n 'name' => 'jose luis',\n 'email' => 'barbozagonzalesjose@gmail.com',\n 'password' => bcrypt('xxxxxx'),\n 'role' => 'admin',\n ]);\n\n Category::create([\n 'name' => 'inpods',\n 'description' => 'auriculares inalambricos que funcionan con blouthue genial'\n ]);\n\n Category::create([\n 'name' => 'other',\n 'description' => 'otra cosa diferente a un inpods'\n ]);\n\n\n /* Create 10 products */\n Product::factory(10)->create();\n }", "title": "" }, { "docid": "202189ac5e6ae1c3d158da4dfad00e74", "score": "0.767549", "text": "public function run()\n {\n\t\t\tProject::truncate();\n\t\t\t\n\t\t\tfactory(Project::class, 20) -> create();\n\t\t\t/*$faker = Faker::create('en_US');\n\n\t\t\tfor($i = 0; $i < 10; $i++){\n\t\t\t\tProject::create([\n\t\t\t\t\t'title' => $faker -> name\n\t\t\t\t\t$table->string('title');\n\t\t\t\t\t$table->string('comment');\n\t\t\t\t\t$table->integer('min_price');\n\t\t\t\t\t$table->integer('max_price');\n\t\t\t\t\t$table->integer('category_id');\n\t\t\t\t\t$table->integer('user_id');\n\t\t\t\t\t$table->boolean('delete_flg');\n\t\t\t\t])\n\t\t\t}*/\n }", "title": "" }, { "docid": "4c4d418f65a57b515570be7482a92877", "score": "0.76726556", "text": "public function run()\n {\n // Vaciar la tabla.\n Favorite::truncate();\n $faker = \\Faker\\Factory::create();\n // Crear artículos ficticios en la tabla\n\n // factory(App\\Models\\User::class, 2)->create()->each(function ($user) {\n // $user->users()->saveMany(factory(App\\Models\\User::class, 25)->make());\n //});\n }", "title": "" }, { "docid": "619d6d0bb4a4cea6758274cbd4639711", "score": "0.76711684", "text": "public function run()\n {\n // Use the factory to create a Faker\\Generator instance.\n $faker = \\Faker\\Factory::create('en_NG');\n\n /**\n * Loop through and insert the dummy data into the users table\n */\n for ($i = 0; $i < 10; $i++) {\n Interest::create([\n 'interest_description' => $faker->word(7),\n 'interest_name' => $faker->sentence(5)\n ]);\n }\n }", "title": "" }, { "docid": "2e8c9674b5b47271246bd3c5d33867fc", "score": "0.7670721", "text": "public function run()\n {\n $this->call(RolesTableSeeder::class);\n\n $faker = Factory::create();\n $users = array_merge(\n factory(User::class, 9)->create()->toArray(),\n factory(User::class, 1)->create(['role_id' => Role::where('name', 'admin')->first()->id])->toArray()\n );\n $categories = factory(Category::class, 6)->create()->toArray();\n\n foreach ($users as $user) {\n /** @var Post $posts */\n $posts = factory(Post::class, rand(1, 5))->create(['user_id' => $user['id']]);\n\n foreach ($posts as $post) {\n $post->categories()->attach([\n $faker->randomElements($categories)[0]['id'],\n $faker->randomElements($categories)[0]['id'],\n ]);\n\n factory(Comment::class, rand(1, 5))->create([\n 'post_id' => $post['id'],\n 'user_id' => $user['id'],\n ]);\n }\n }\n }", "title": "" }, { "docid": "9f18c5c0d91d41c0a8c01c0872701c3c", "score": "0.76674765", "text": "public function run()\n {\n //Trucates exising records to start from scratch\n User::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n User::create([\n 'username'=> \"t@gml.com\",\n 'email' => \"t@gml.com\",\n 'password'=>bcrypt(\"t@gml.com\")\n ]);\n\n DB::table(\"activations\")->insert([\n 'user_id'=>1,\n 'code'=>'4rxpG9JWnDDTv3SNUHjsC3RsUwhlZgez',\n 'completed'=> 1,\n 'completed_at'=>Carbon::now(),\n 'created_at'=> Carbon::now(),\n 'updated_at'=> Carbon::now()\n ]);\n\n\n }", "title": "" }, { "docid": "b8a2d239e166712dd77165697867a5de", "score": "0.76674277", "text": "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n// Task::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 20; $i++) {\n Task::create([\n 'name' => $faker->name,\n 'status' => $faker->randomElement($array = array ('to-do','doing','done')),\n 'description' => $faker->paragraph,\n 'start' => $faker->dateTime($min = 'now', $timezone = null) ,\n 'end' => $faker->dateTime($min = 'now', $timezone = null) ,\n 'assignee' => $faker->randomElement(User::pluck('id')->toArray()),\n 'assigner' => $faker->randomElement(User::pluck('id')->toArray()),\n ]);\n }\n }", "title": "" }, { "docid": "861976ea353841a1120d5e19df4f5651", "score": "0.7667395", "text": "public function run()\n {\n // $this->call(GroupsTableSeeder::class);\n // $this->call(UsersTableSeeder::class);\n // $this->call(AdminsTableSeeder::class);\n // $this->call(SellersTableSeeder::class);\n\n $this->call(AboutsTableSeeder::class);\n // $this->call(AdvertisesTableSeeder::class);\n $this->call(ContactsTableSeeder::class);\n $this->call(HowToshopsTableSeeder::class);\n $this->call(HowTosellsTableSeeder::class);\n $this->call(OfficialPartnersTableSeeder::class);\n $this->call(OurActivitiesTableSeeder::class);\n $this->call(PaymentsTableSeeder::class);\n $this->call(RefundsTableSeeder::class);\n $this->call(SellerStoriesTableSeeder::class);\n $this->call(WithdrawalsTableSeeder::class);\n\n // factory(App\\User::class,5)->create();\n // factory(App\\Model\\Product::class,50)->create();\n // factory(App\\Model\\Review::class,300)->create();\n }", "title": "" }, { "docid": "06f416db2b8ef80c81b9ff3ec0e65217", "score": "0.7661292", "text": "public function run()\n {\n $this->call([\n ContentSeeder::class,\n MetadataSeeder::class,\n// CategorySeeder::class,\n SliderSeeder::class,\n UserSeeder::class,\n ]);\n// factory('App\\Termination',10)->create();\n// factory('App\\Subcategory',10)->create();\n// factory('App\\Closure',10)->create();\n// factory('App\\Capacity',10)->create();\n $this->call(ContentsTableSeeder::class);\n $this->call(SlidersTableSeeder::class);\n }", "title": "" }, { "docid": "30dac972abaa34409e5f3917314fcb65", "score": "0.7659881", "text": "public function run()\n {\n $this->call(AlumnoSeeder::class);\n //Alumnos::factory()->count(30)->create();\n //DB::table('alumnos')->insert([\n // 'dni_al' => '13189079',\n // 'nom_al' => 'Jose',\n // 'ape_al' => 'Araujo',\n // 'rep_al' => 'Principal',\n // 'esp_al' => 'Tecnologia',\n // 'lnac_al' => 'Valencia'\n //]);\n }", "title": "" }, { "docid": "e508532bee1083b015a68a8047e78ca6", "score": "0.76597446", "text": "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(User::class)->create([\n 'email' => 'test1@t.t',\n 'name' => 'Dominic',\n ]);\n\n factory(User::class)->create([\n 'email' => 'test2@t.t',\n 'name' => 'Kira',\n ]);\n\n factory(User::class)->create([\n 'email' => 'test3@t.t',\n 'name' => 'Less',\n ]);\n }", "title": "" }, { "docid": "c5a6368cf4078a0a4d8b652f1ce43194", "score": "0.7657722", "text": "public function run()\n {\n // Create roles\n $this->call(RoleTableSeeder::class);\n // Create example users\n $this->call(UserTableSeeder::class);\n // Create example city\n $this->call(CitiesTableSeeder::class);\n // Create example restaurant type\n $this->call(RestaurantsTypesSeeder::class);\n // Create example restaurant\n $this->call(RestaurantsSeeder::class);\n }", "title": "" } ]
b5f2c8aed75d155d11bb08e1fda24258
Make a show builder.
[ { "docid": "138e9f5df25a63b857813ea5a34300bd", "score": "0.0", "text": "protected function detail($id)\n {\n $show = new Show(Department::findOrFail($id));\n\n $show->field('id', __('Id'));\n $show->field('name', __('Name'));\n $show->field('sort_order', __('Sort order'));\n\n return $show;\n }", "title": "" } ]
[ { "docid": "199d4abcf65483361bdc32dc5353f244", "score": "0.62589526", "text": "public function show();", "title": "" }, { "docid": "5fbd8c8a913f3d5a4f08b109b5762881", "score": "0.62369376", "text": "public function show()\n\t{\n\t\t//\n\t}", "title": "" }, { "docid": "305f64db85d64f68019d2fadcd0a85d2", "score": "0.62308425", "text": "public function show()\n\t{\n\t\t\n\t}", "title": "" }, { "docid": "a273af8768c0f2a73c35b2ce16343c9f", "score": "0.6225228", "text": "public function show() {\n\t\t$this->hidden = false;\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "20397e06b8673db8692c5f84120c3011", "score": "0.6219827", "text": "public function show()\n\t{\n\n\t}", "title": "" }, { "docid": "e75b79db27f834c27ea6e1e62c86c442", "score": "0.61899936", "text": "public function show()\n {\n \n }", "title": "" }, { "docid": "b13f9563a16d28fc85bf8d4d437d11dd", "score": "0.61453074", "text": "protected function _show() {\n\t\theader('Content-type: image/png');\n\t\timagepng($this->getResource());\n\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "93dff10bf85313385f042e04804e1ed8", "score": "0.6124172", "text": "public function plxShowConstruct() {\n\t\t$string = \"\n\t\tif(\\$this->plxMotor->mode=='pickypaste') {\n\t\t\t\\$array = array();\n\t\t\t\\$array[\\$this->plxMotor->cible] = array(\n\t\t\t\t'name'\t\t=> '',\n\t\t\t\t'menu'\t\t=> '',\n\t\t\t\t'url'\t\t=> 'pickyPaste',\n\t\t\t\t'readable'\t=> 1,\n\t\t\t\t'active'\t=> 1,\n\t\t\t\t'group'\t\t=> ''\n\t\t\t);\n\t\t\t\\$this->plxMotor->aStats = array_merge(\\$this->plxMotor->aStats, \\$array);\n\t\t}\";\n\t\techo \"<?php \".$string.\" ?>\";\n\t}", "title": "" }, { "docid": "6820ec80865170aa2f1d6c3d9362bcac", "score": "0.6117705", "text": "public function show()\n {\n }", "title": "" }, { "docid": "6820ec80865170aa2f1d6c3d9362bcac", "score": "0.6117705", "text": "public function show()\n {\n }", "title": "" }, { "docid": "6820ec80865170aa2f1d6c3d9362bcac", "score": "0.6117705", "text": "public function show()\n {\n }", "title": "" }, { "docid": "fcfcdfd72e2c8a7ba584f5e56d9dcca3", "score": "0.61164904", "text": "public function show()\r\n {\r\n }", "title": "" }, { "docid": "6ab26917de311b0d6e8eda98415d8078", "score": "0.60665065", "text": "public function build():Designer\n {\n\n $this->setHtml()\n ->exportVariables()\n ->setDesign($this->getSection('includes'))\n ->setDesign($this->getSection('header'))\n ->setDesign($this->getSection('body'))\n ->setDesign($this->getProductTable($this->entity))\n ->setDesign($this->getSection('footer'));\n\n return $this;\n\n }", "title": "" }, { "docid": "97c52673d8d6674587cc47b863f0a908", "score": "0.60663223", "text": "public function show()\n {\n \n }", "title": "" }, { "docid": "97c52673d8d6674587cc47b863f0a908", "score": "0.60663223", "text": "public function show()\n {\n \n }", "title": "" }, { "docid": "490f7a44670c240dd8c7440e74a6f775", "score": "0.6064802", "text": "public function show()\n {\n \n \n }", "title": "" }, { "docid": "f9a16f3b50f9fc9018d4eede4a2e3458", "score": "0.6030661", "text": "public function show()\n\t{\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "b017a059c4eb788b5dd5042677436555", "score": "0.60185385", "text": "abstract public function build_the_widget();", "title": "" }, { "docid": "832b0d04ae268295b7c027a7a15e5be5", "score": "0.600993", "text": "public function show(){\n \n }", "title": "" }, { "docid": "57cf0ff07faea759ee79635f765678ad", "score": "0.5987225", "text": "public function show()\n {\n \n }", "title": "" }, { "docid": "b8d7f4b674287becaf904176ebfb8906", "score": "0.5987085", "text": "function Show()\n\t{\n\t\treturn $this->element->Build();\n\t}", "title": "" }, { "docid": "748563cd94d005a682007009404542e5", "score": "0.5980365", "text": "protected function setupShowOperation()\n {\n $this->crud->addColumns([\n [\n 'name' => 'formbuilder.title',\n 'label' => ucfirst(__('rafy-mora.formbuilder-field::formbuilder.labels.entity_form')),\n 'type' => 'text'\n ],\n [\n 'name' => 'created_at',\n 'type' => 'datetime',\n 'label' => ucfirst(__('rafy-mora.formbuilder-field::formbuilder.labels.created_at'))\n ],\n [\n 'name' => 'structure_result',\n 'type' => 'view',\n 'label' => ucfirst(__('rafy-mora.formbuilder-field::formbuilder.labels.form')),\n 'view' => 'rafy-mora.formbuilder-field::columns.form_builder_entry',\n ]\n ]);\n $this->crud->removeColumn('structure_form');\n $this->crud->removeColumn('fb_form_id');\n }", "title": "" }, { "docid": "e9cda6bdee7ccf9d37940649f0bebe53", "score": "0.59791183", "text": "public function show()\n {\n \n }", "title": "" }, { "docid": "6b511d79cef84f1d1184efa3e007c596", "score": "0.5971623", "text": "public function show()\n {\n \n }", "title": "" }, { "docid": "5dbe07ace0144761ab97d7925f102a4a", "score": "0.5970227", "text": "public function show()\n {\n\n }", "title": "" }, { "docid": "e928f1aa8febf90d42461f04cacdcb06", "score": "0.5956716", "text": "public function show()\n {\n\n }", "title": "" }, { "docid": "e928f1aa8febf90d42461f04cacdcb06", "score": "0.5956716", "text": "public function show()\n {\n\n }", "title": "" }, { "docid": "e928f1aa8febf90d42461f04cacdcb06", "score": "0.5956716", "text": "public function show()\n {\n\n }", "title": "" }, { "docid": "e928f1aa8febf90d42461f04cacdcb06", "score": "0.5956716", "text": "public function show()\n {\n\n }", "title": "" }, { "docid": "e928f1aa8febf90d42461f04cacdcb06", "score": "0.5956716", "text": "public function show()\n {\n\n }", "title": "" }, { "docid": "e928f1aa8febf90d42461f04cacdcb06", "score": "0.5956716", "text": "public function show()\n {\n\n }", "title": "" }, { "docid": "cc4be42aa10c61fa0dc99eb524cff6ba", "score": "0.5944288", "text": "public function build() {\n if ($this->isVisible()) {\n return $this->view();\n }\n }", "title": "" }, { "docid": "571714599e79831df3465d3cefa85d8c", "score": "0.593809", "text": "public function showEditor(bool $show): Writer;", "title": "" }, { "docid": "5195070a6f9ada39136926897a40c417", "score": "0.5928025", "text": "public function show(){\n }", "title": "" }, { "docid": "0e35be74cf0e4eab324f21342fc0c36e", "score": "0.59248435", "text": "public function getViewBuilder();", "title": "" }, { "docid": "76635170503dcaaee4f9afc72aed6427", "score": "0.5922726", "text": "function show()\n {\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "c63f5265dbf55da86cd1d1e76ce33f28", "score": "0.59020084", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "60d89d47eb639161de29171d239663a5", "score": "0.5875138", "text": "protected function compileShow()\n {\n return '<?php echo $this->yieldSection(); ?>';\n }", "title": "" }, { "docid": "57c652367cd8fb09cfc878f18727b0c9", "score": "0.5838992", "text": "public function setShow($show) \n\t{\n\t\tif($show < 1) {\n\t\t\t$show = 1;\n\t\t}\n\t\t\n\t\t$this->show = $show;\n\t\t\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "4ebd0eba4f44156a2bea74633463ac1c", "score": "0.58172566", "text": "public function show()\n {\n\n\n }", "title": "" }, { "docid": "3291f0a286464ff5428612d67a774272", "score": "0.58134574", "text": "public function create()\n {\n\t\treturn Inertia::render('Warehouses/Show');\n }", "title": "" }, { "docid": "444f98db8bf05539525aaf901d77e042", "score": "0.579949", "text": "public function builder()\n {\n $site = $this->cart->getSite();\n $page = $this->cart->getPage();\n $elements = SitePageElement::select('tid', 'type')\n ->where('site_id', $site->id)\n ->where('site_page_id', $page->id)\n ->get()\n ->toJson();\n $firstLoading = $this->cart->isFirstLoading(); \n \n return $this->view('site.builder.content', compact('site', 'page', 'elements', 'firstLoading')); \n }", "title": "" }, { "docid": "d69c3efb6ccb7e40a7de15ae95c78b6f", "score": "0.57877636", "text": "protected function builder()\n {\n return new Builder;\n }", "title": "" }, { "docid": "d94eb46c8f0f5d30ebf49093d0f02d4c", "score": "0.5776268", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "d94eb46c8f0f5d30ebf49093d0f02d4c", "score": "0.5776268", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "d31fd9e84e87d8d8585750d87f132a21", "score": "0.57749534", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "b48c740990b49f28d17c32d65ca019fb", "score": "0.5765703", "text": "public function show(CrudShow $form)\n {\n $form->card(function ($form) {\n $this->mainCard($form);\n })->width(12)->title('Main');\n }", "title": "" }, { "docid": "33660332885ef69ecd5483da542d068e", "score": "0.57270867", "text": "public function show()\n {\n return view('app::show');\n }", "title": "" }, { "docid": "dbfb7ac40503919a18ba680b317c5bcf", "score": "0.57210237", "text": "function show()\r\n\t{\r\n\t\tparent::display();\r\n\t}", "title": "" }, { "docid": "0900974c66de180480cc7984098d46e7", "score": "0.56857735", "text": "public function show()\n {\n //\n }", "title": "" }, { "docid": "3306ea17bc979bb2a9d66933704e24b2", "score": "0.56616503", "text": "abstract static public function builders();", "title": "" }, { "docid": "2b02ea30b51afcb4dc11ef0d20ca494d", "score": "0.56539583", "text": "public function makeView()\n {\n return FormConstructor::view($this);\n }", "title": "" }, { "docid": "b117a5d8fa5e5ac2db397b390ce45eb5", "score": "0.5652737", "text": "public function show()\n {\n print \"<!DOCTYPE HTML>\n <html>\n <head>\n <meta http-equiv=\\\"content-type\\\" \";\n // print content-type (content-dev,charset)\n print \"content=\\\"{$this->config['content']};\";\n print \" charset={$this->config['charset']}\\\">\\n\";\n\n // print stylesheets\n foreach ($this->config['stylesheets'] as $stylesheet) {\n print \"<link rel=\\\"stylesheet\\\" type=\\\"text/css\\\"\";\n print \" href=\\\"$stylesheet\\\">\\n\";\n }\n\n // print javascripts\n foreach ($this->config['javascripts'] as $javascript) {\n print \"<script src=\\\"$javascript\\\"></script>\\n\";\n }\n\n // print title\n print \"<title>{$this->config['title']}</title>\n </head>\n <body>\n <div id=\\\"body-wrapper\\\" class=\\\"body-wrapper\\\">\";\n\n $this->header->show();\n\n print '<div id=\"content-wrapper\" class=\"content-wrapper\">';\n\n // try to print all the elements in contentElements\n foreach ($this->contentElements as $contentElement) {\n\n // check check if we can somehow print the content\n if (method_exists($contentElement, 'show')) {\n $contentElement->show();\n } elseif (method_exists($contentElement, '__toString')) {\n print $contentElement;\n } elseif (is_string($contentElement)) {\n print $contentElement;\n }\n }\n\n print '</div> <!-- end: content-element -->\n </div>\n </body>\n </html>';\n }", "title": "" }, { "docid": "5eacb4062f5f0b9a21546f07b4bffa77", "score": "0.5639653", "text": "public function addshow()\n {\n $movies = Movie::all();\n $theater = Theater::all();\n $screen = Screen::all();\n\n return view('admin.Show.addshow', [\n \"movies\" => $movies,\n 'theaters' => $theater,\n 'screen' => $screen\n\n ]);\n }", "title": "" }, { "docid": "b03cb390eccf849ac9861efaf392681e", "score": "0.5606792", "text": "public function show($name)\n {\n $this->arguments[] = 'show';\n $this->arguments[] = $name;\n return $this;\n }", "title": "" }, { "docid": "846e6e96ec6dd52d11b2e3cef09583a2", "score": "0.55843604", "text": "public function show() {\r\n $this->build();\r\n $packet = new packet_0xDD($this->client, $this);\r\n $packet->send();\r\n }", "title": "" }, { "docid": "2a56f24c271766072a02400d480232fc", "score": "0.55729747", "text": "public function postShow(Request $request)\n {\n $validator = Validator::make($request->all(), [\n 'start_time' => 'required|date',\n 'title' => 'required|string',\n 'description' => 'required|string',\n 'runtime' => 'required|string',\n 'show_image_header' => 'required|string',\n 'calories' => 'required|string'\n ]);\n\n if ($validator->fails()) {\n abort(400, $validator->errors());\n }\n\n $properties = $request->all();\n\n $result = $this->showService->createShow($properties);\n if (!$result->success) {\n abort($result->status_code, $result->error);\n }\n\n $show = $result->show;\n\n return $show;\n }", "title": "" }, { "docid": "ff1cec51ec6b90cbcf872de145e87e1b", "score": "0.5568611", "text": "function show() {\n echo $this->getName().\"<br />\";\n \n }", "title": "" }, { "docid": "ca7d6d5c85319cc4bbae04c3b3ad03da", "score": "0.55645436", "text": "public function show(Widget $widget)\n {\n //\n }", "title": "" }, { "docid": "ecec3b798901aeb2ac785b423acdd47a", "score": "0.55540705", "text": "public function show(string $showValue): self\n {\n $this->filterList[] = (new FilterBuilder('show', $showValue, $this->name))->addFilter();\n\n return $this;\n }", "title": "" }, { "docid": "97cf5643991ead5500d5492cbadb7980", "score": "0.5548104", "text": "protected function form()\n {\n $form = new Form(new Banner());\n\n $form->text('name', __('Tên banner'));\n $form->url('link', __('Địa chỉ liên kết'))->required();\n $form->select('position', __('Vị trí'))->options(Constant::BANNER_POSITION)->setWidth(2, 2);\n $form->number('order', __('Sắp xếp'));\n $form->image('img', __('Ảnh'));\n $form->switch('show', __('Hiện'))->states(Constant::SWITCH_STATE);\n\n return $form;\n }", "title": "" }, { "docid": "c68d52c4f48f7554604e78a742d60341", "score": "0.55458134", "text": "public function show()\n {\n return view('ran::show');\n }", "title": "" }, { "docid": "79b17b5befcbcdc85dee39148139dca2", "score": "0.553513", "text": "public function show()\n {\n return view('wahana::show');\n }", "title": "" }, { "docid": "4c877b1e5ca6032c49f63e3cf90b5b62", "score": "0.5526078", "text": "function addShow($show, $info = null, $automatic = false, $sources = \"\") {\n\t\t\treturn 2;\n\t\t}", "title": "" }, { "docid": "8f1777a304f56e07790c03984f9a138b", "score": "0.55194956", "text": "public function show()\n {\n return view('mobileapi::show');\n }", "title": "" }, { "docid": "e0850d338d1678628d8cdc75a4ac4a35", "score": "0.5510959", "text": "public function show()\n {\n if (ob_get_level()) {\n ob_clean();\n }\n header(\"Content-type: \".$this->info['mime']);\n switch ($this->info['mime']) {\n case 'image/png':\n imagepng($this->image);\n break;\n\n case 'image/jpeg':\n imagejpeg($this->image);\n break;\n\n case 'image/bmp':\n case 'image/x-windows-bmp':\n case 'image/x-ms-bmp':\n BMP::image($this->image);\n break;\n\n case 'image/gif':\n imagegif($this->image);\n break;\n\n default:\n break;\n }\n\n return $this;\n }", "title": "" }, { "docid": "ca51d7167701ef3e5abff6a50db750a3", "score": "0.5506539", "text": "public function show()\n {\n return view('master::show');\n }", "title": "" }, { "docid": "b044fffe8f37ac8a724394ad0782d1dd", "score": "0.5506406", "text": "public function show()\n {\n echo $this->_form;\n }", "title": "" }, { "docid": "29fbb9c39f465f611ca2e314f5b49293", "score": "0.5501217", "text": "public function setShowDescription($show)\n {\n $this->showDescription = !!$show;\n return $this;\n }", "title": "" }, { "docid": "ef44bbd79e20fc2f92fa855af1a3e559", "score": "0.54972255", "text": "protected function form()\n {\n $form = new Form(new Series());\n\n $form->text('title', '标题');\n $form->textarea('introduction', '简介');\n $form->image('thumb', '封面图')->crop(720, 480)->move('images/series');\n $form->switch('archived', '已完结');\n\n return $form;\n }", "title": "" }, { "docid": "7a2382944f115a629354d2d1d69fb3ba", "score": "0.5483604", "text": "public function show(Builder $builder)\n {\n return new BuilderResource($builder);\n }", "title": "" }, { "docid": "760989008678fef5350411d6633cca15", "score": "0.5481104", "text": "public function showTitle(bool $show): Writer;", "title": "" }, { "docid": "a3c92ae6688b82e73ae9cc2962c802f0", "score": "0.5475987", "text": "public function create()\n\t{\n\t\treturn View::make('bands.create');\n\t}", "title": "" }, { "docid": "f41059a40837e61434c9de2cb25df313", "score": "0.54631", "text": "protected function setupShowOperation()\n {\n $this->crud->addColumn([\n 'name' => 'name',\n 'type' => 'text',\n 'label' => 'Название',\n ]);\n $this->crud->addColumn([\n 'name' => 'description',\n 'type' => 'markdown',\n 'label' => 'Описание',\n ]);\n }", "title": "" }, { "docid": "300a684583d8e90800af600903719ad8", "score": "0.5456984", "text": "function show() {\n\t\tif (isset($_GET['Wid'])) {\n\t\t\t$rw=self::getFromDb($_GET['Wid']);\n\t\t}else {\n\t\t\t$rw=$this;\n\t\t}\n\t\techo \"<div class='block'>\n\t\t<h2>{$rw->title}</h2>\n\t\t<p>{$rw->text}</p>\n\t\t</div>\";\n\t}", "title": "" }, { "docid": "aa6abdc51cb708c4824cbce534e782ac", "score": "0.54518443", "text": "public function build() {\n\t\t$this->name = new view_field(\"To Reach\");\n\t\t$this->volume_needed = new view_field(\"Additional Generational Volume Needed\");\n\t\t$this->needed_directors = new view_field(\"Additional Director Lines Needed\");\n\t\t$this->needed_power_lines = new view_field(\"Additional Power Lines Needed\");\n\t\t\n\t\tparent::build();\n\t}", "title": "" }, { "docid": "32f3991076f773ef09b8d37f34e31efe", "score": "0.5432888", "text": "public static function make(): self\n\t{\n\t\treturn static::builder()->build();\n\t}", "title": "" }, { "docid": "32f3991076f773ef09b8d37f34e31efe", "score": "0.5432888", "text": "public static function make(): self\n\t{\n\t\treturn static::builder()->build();\n\t}", "title": "" }, { "docid": "32f3991076f773ef09b8d37f34e31efe", "score": "0.5432888", "text": "public static function make(): self\n\t{\n\t\treturn static::builder()->build();\n\t}", "title": "" }, { "docid": "b09ddb93a56aea4d83f01a0f62f5bae8", "score": "0.54232466", "text": "public function show(CrudShow $form)\n {\n $form->info('')\n ->text(fa('fab', 'github') . ' <a href=\"https://github.com/aw-studio/fjord-playground/blob/master/fjord/app/Config/Form/Fields/CheckboxesConfig.php\" target=\"_blank\">See the code for this page on github.</a>')\n ->width(12);\n\n $form->info('')\n ->text(fa('fas', 'info-circle') . ' <a href=\"https://www.fjord-admin.com/docs/fields/checkboxes/\" target=\"_blank\">Read the docs.</a>')\n ->width(12);\n\n $form->card(function ($form) {\n $form->checkboxes('fruits')\n ->title('Fruits')\n ->options([\n 'orange' => 'Orange',\n 'apple' => 'Apple',\n 'pineapple' => 'Pineapple',\n 'grape' => 'Grape',\n ])\n ->hint('Checkboxes field.')\n ->width(6);\n });\n }", "title": "" }, { "docid": "c1729855e8fb8db63ae94c209050f3eb", "score": "0.54151046", "text": "public function create()\n {\n $faker = \\Faker\\Factory::create();\n\n return view('quickBlox.create', ['faker' => $faker]);\n }", "title": "" }, { "docid": "6ab0303387c870e9d3b6cc83c1d14da0", "score": "0.5413226", "text": "protected function form()\n {\n $form = new Form(new StoreAlbum());\n\n $form->number('store_id', __('Store id'));\n $form->image('thumb', __('Thumb'))->dir('/images')->help('尺寸');\n\n return $form;\n }", "title": "" }, { "docid": "c09f1af501a58a7894048fd3ea56ca6c", "score": "0.5409398", "text": "public function show(Boxer $boxer)\n {\n //\n }", "title": "" }, { "docid": "971f068cf6694f8c1e335047171f8396", "score": "0.54084206", "text": "public function build();", "title": "" }, { "docid": "971f068cf6694f8c1e335047171f8396", "score": "0.54084206", "text": "public function build();", "title": "" }, { "docid": "971f068cf6694f8c1e335047171f8396", "score": "0.54084206", "text": "public function build();", "title": "" }, { "docid": "77372e0c92eba51edd1177af6394f3d3", "score": "0.54009086", "text": "public function show()\n {\n /*\n * @TODO content of this function for SQLServer driver\n */\n return $this;\n }", "title": "" }, { "docid": "a54ddef44df979c5c7c40b3bf985d8e0", "score": "0.5400139", "text": "public function create()\n {\n return view('display');\n }", "title": "" }, { "docid": "5935762cfe8e17a978d009c8109099bb", "score": "0.5389411", "text": "public function show()\n {\n return view('mgtrafico::show');\n }", "title": "" } ]
ee79964f4f6027af48e7a48d25e11d89
Set the value of Request
[ { "docid": "df586657f995ba033f51ab193559e45a", "score": "0.5835593", "text": "public function setRequest()\n {\n $requestArray = [\n \"client_id\" => $this->getClientId(),\n \"trx_amount\" => $this->getTrxAmount(),\n \"customer_name\" => $this->getCustomerName(),\n \"customer_email\" => $this->getCustomerEmail(),\n \"customer_phone\" => $this->getCustomerPhone(),\n \"virtual_account\" => $this->getVirtualAccount(),\n \"trx_id\" => $this->getTrxId(),\n \"datetime_expired\" => $this->getDateTimeExpired(),\n \"description\" => $this->getDescription(),\n \"type\" => $this->getTypeTransaction(),\n \"billing_type\" => $this->getBillingType()\n ];\n\n $requestHash = DclHashing::hashData($requestArray, $this->getClientId(), $this->getSecretKey());\n\n if (is_null($requestHash)) {\n throw new BillingException(\"Hashing data is fail\");\n }\n\n $this->request = json_encode(['client_id' => $this->getClientId(), 'data' => $requestHash]);\n\n return $this;\n }", "title": "" } ]
[ { "docid": "b2614b8de115116433b70e64ca26b59f", "score": "0.8443747", "text": "function setRequest($value) {\n $this->request = $value;\n }", "title": "" }, { "docid": "c48a5c81f7bdd42a93c9ac9f92242914", "score": "0.78782624", "text": "function setRequest($request) {\n\t\t$this->m_request = $request;\n\t}", "title": "" }, { "docid": "17e7dcfd78751800367362eb48c36aaa", "score": "0.7648034", "text": "public static function set_request($request){\n\t\t\tself::$request = $request;\n\t\t}", "title": "" }, { "docid": "fbacf9cc53618f53e94d5ae18f4cc60a", "score": "0.7566985", "text": "public function setRequest($request);", "title": "" }, { "docid": "d039df4d222074c0a4e58f8c1d1b9814", "score": "0.74143404", "text": "public function setRequest($request)\n {\n $this->_request = $request;\n }", "title": "" }, { "docid": "0a58f29412c6562dbadcf8f4cc1e8e4e", "score": "0.74018824", "text": "public function setRequest(Request $request){\n\t\t$this->request = $request;\n\t}", "title": "" }, { "docid": "a15ea533dfaead678bbac105c4d41de3", "score": "0.73804307", "text": "final public function setRequest(\\sb\\Request $request)\n {\n\n $this->request = $request;\n\n $request->setInputArgsDelimiter($this->input_args_delimiter);\n }", "title": "" }, { "docid": "bd99b7d8086616bbd4679e2943b74a40", "score": "0.73568994", "text": "public static function setRequest( \\core\\Request $request ) {\n\t\treturn self::getInstance()->set(\"request\", $request);\n\t}", "title": "" }, { "docid": "540e5dead839199d43b8cf3c963137b1", "score": "0.73539996", "text": "public function setRequest( $request ){\n \n $this->request = $request;\n \n }", "title": "" }, { "docid": "3984740131c19ef57876c3041a76f850", "score": "0.7327493", "text": "public function setRequest($request) {\n $this->request += $request;\n }", "title": "" }, { "docid": "a222ad1efc527755e90afbd7ab953ea4", "score": "0.7310068", "text": "public function set_request($request)\n\t{\n\t\t$this->request = $this->complete_request = trim($request);\n\t}", "title": "" }, { "docid": "562674e92eeb54c92b93a326f46d9c45", "score": "0.72909904", "text": "public function setRequest(namespace\\Request $request)\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "a01e4bcb259637bde97df14bf54f12ad", "score": "0.72296005", "text": "public function setRequest(Request $request) {\r\n $this->request = $request;\r\n }", "title": "" }, { "docid": "bac14ec096148b4887ca0265d91c6d0e", "score": "0.7228555", "text": "public function setRequest(Request $request)\n\t{\n\t\t$this->request = $request;\n\t}", "title": "" }, { "docid": "1cfcda3305545e8fbeb97c5f98c3686c", "score": "0.720646", "text": "public static function setRequest(Request $request)\n {\n self::$request = $request;\n }", "title": "" }, { "docid": "b4f4ea712a049a6801ad8206dfb87a07", "score": "0.7173927", "text": "protected function setFakeRequest()\n\t{\n\t\t$_REQUEST = $_GET = $this->currentget;\n\t}", "title": "" }, { "docid": "84767cb982e8b230634de50296756803", "score": "0.7136423", "text": "public function setRequest(Request $request): void\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "7bc99a29638eacc116c2330559337a27", "score": "0.7126953", "text": "public function setRequest(Request $request) {\n $this->request = $request;\n }", "title": "" }, { "docid": "7efdae1941f1e3aab861e056aab178a4", "score": "0.7073591", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "7efdae1941f1e3aab861e056aab178a4", "score": "0.7073591", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "7efdae1941f1e3aab861e056aab178a4", "score": "0.7073591", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "7efdae1941f1e3aab861e056aab178a4", "score": "0.7073591", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "7efdae1941f1e3aab861e056aab178a4", "score": "0.7073591", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "c73ec56a1577cee9df132374e26b7353", "score": "0.7042052", "text": "public function setRequest(Request $request);", "title": "" }, { "docid": "c73ec56a1577cee9df132374e26b7353", "score": "0.7042052", "text": "public function setRequest(Request $request);", "title": "" }, { "docid": "90c46de73136741665e4e9f21feffa49", "score": "0.7009989", "text": "public function setRequest(HttpRequest $request)\n\t{\n\t\t$this->request = $request;\n\t}", "title": "" }, { "docid": "02dac9bcbe87335106fb7e7cd66a1d20", "score": "0.7007052", "text": "public function setRequest(Request $request)\n {\n $this->issuer->setRequest($request);\n $this->checker->setRequest($request);\n }", "title": "" }, { "docid": "4a774ea19599cdfafdc166e9a7c4c9ec", "score": "0.6991781", "text": "protected function setCurrentRequest($name,$value)\n\t{\n\t\t$this->currentget[$name] = $value;\n\t}", "title": "" }, { "docid": "5b81790087e87c809d14dde9e7f08377", "score": "0.69676", "text": "public function setRequest(Request $request)\n\t{\n\t\t$param = $request->request;\n\n\t\t//$this->orderColumn \t= $this->column[$param->get('order')[0]['column']];\n\t\t$this->orderDir \t= $param->get('order')[0]['dir'];\n\t\t$this->search \t\t= $param->get('search')['value'];\n\t\t$this->start \t\t= $param->get('start');\n\t\t$this->maxResult \t= $param->get('length');\n\t}", "title": "" }, { "docid": "bef03d0ec274bbf5fe24c891fd011360", "score": "0.6956481", "text": "function setRequestUser($value)\n {\n $this->_props['RequestUser'] = $value;\n }", "title": "" }, { "docid": "537b7a0ec0f7fd4916f1b655cdb7ad50", "score": "0.6900812", "text": "protected function setRequest(Request $request)\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "2b0665082e151485c3d0f421f26fa0e9", "score": "0.6865312", "text": "public function getRequest()\r\n {\r\n $this->setData\r\n (\r\n $this->__request->getData()\r\n );\r\n\r\n }", "title": "" }, { "docid": "465f1b42d341a711c5a5634560a49600", "score": "0.67615074", "text": "public static function setREQUEST(string $name, $value)\n\t{\n\t\tself::setVar($name, 'request', $value);\n\t}", "title": "" }, { "docid": "70a742a13215b67fd38332e248797c5d", "score": "0.6760876", "text": "function set_request_p($key, $value=false)\n{\n return Request::SetValueP($key, $value);\n}", "title": "" }, { "docid": "b78c2b3ae239327edb2f5ebd73787637", "score": "0.67598134", "text": "public function setRequest(Request $request = null)\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "3af040183e2f7e096cafb08449be8b82", "score": "0.6715866", "text": "public function set($name, $value){\r\n $_REQUEST[$name] = $value;\r\n }", "title": "" }, { "docid": "34b28028805cbad517196bec64e4b24f", "score": "0.6585838", "text": "public function setRequestField( $request_field ){\n \n $this->request_field = $request_field;\n \n }", "title": "" }, { "docid": "654d3569df7379cb96dcc68a79341c7c", "score": "0.6561135", "text": "public function setRequest( Request $request )\n {\n $this->request = $request;\n \n # Return object to preserve method-chaining:\n return $this;\n }", "title": "" }, { "docid": "2c9b233236c68e69d3bc673b27659061", "score": "0.65546435", "text": "public function setLastRequest(RequestHandler $request): void\n {\n $this->base->lastApiRequest = $request;\n }", "title": "" }, { "docid": "4ac3c49f7d24df4feb589b31473c92e2", "score": "0.6540215", "text": "function setRequest($inRequest) {\n\t\tif ( $inRequest !== $this->_Request ) {\n\t\t\t$this->_Request = $inRequest;\n\t\t\t$this->setModified();\n\t\t}\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "4b166a0147e040ac77f54eaa37fe781c", "score": "0.65161145", "text": "public function setRequest(Request $request = null)\n {\n if (null !== $request) {\n $this->context->fromRequest($request);\n }\n }", "title": "" }, { "docid": "e0ced73ead247af9d4f4055cfab40eb3", "score": "0.6448985", "text": "function set_request_g($key, $value=false)\n{\n return Request::SetValueG($key, $value);\n}", "title": "" }, { "docid": "d09207ee0564248bd68de2806acd069b", "score": "0.63514763", "text": "public function setRequest()\n {\n return $this;\n }", "title": "" }, { "docid": "82066a3d023a85adac3c5cf7306fa115", "score": "0.63393986", "text": "public function setRequest(RequestDescription $request)\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "ae0dde71f63852194ad758585b24f3a9", "score": "0.63382846", "text": "public final function set_request($request = array()) {\n\t \t\n\t \t/* set vars from the server request */\n\t\t$this->request = $request;\n\t\t\n\t\t/* extracts the method, but this is not really importand to do at this point, as it will be set later too */\n\t\t/* $this method is also set when the corresponding action ($this-read, create, ...) is called */\n\t\tif( isset($request['method']))\n\t\t\t$this->request_method = $request['method'];\n\t\t\n\t\t/* extract query vars */\n\t\tif( isset($request['queryvars']))\n\t\t\t$this->request_query_vars = (array) $request['queryvars']; // array is expected\n\n\t\t/* looking for model ids in the request */\n\t\t$this->id = $this->_find_in_request($this->properties->id_attribute);\n\t\t$this->parent_id = $this->_find_in_request($this->properties->parent_id_attribute);\t\n\t\t\n\n\t\t/* USER HANDLING */\n\n\t \t/* is the user allowed to make this request */\n\t \tif ( ( $this->properties->access == \"loggedin\" ) && ( ! is_user_logged_in() ) ) {\n\t\t\t$this->set_error( 56, 'user must be logged in for this request' );\t\t\t\t \t\n\t \t}\n\t\t\n\t \t/* some extra authentication */\n\t \t/* is the uer allowed to make this request */\n \t\t$allowed = $this->is_authenticated($request, $this->request_method);\n \t\tif(! $allowed)\n\t\t\t$this->set_error( 56, 'user is not authenticated' );\t\t\t\t \t\n\t \t\t\n\t\t\n\t}", "title": "" }, { "docid": "5d5f7dd3d415a3997b42d1b01a8ce565", "score": "0.633776", "text": "protected function set_param( $name, $value ) {\r\n $this->_request_data[ $name ] = $value;\r\n }", "title": "" }, { "docid": "4dc73bc1a117f2c56a241e2531cfd1ba", "score": "0.6336987", "text": "public function setFromControllerRequest(Request $request) :self\n\t{\n\t\treturn $this->setFromArray($request->get());\n\t}", "title": "" }, { "docid": "79ec4e79a15452b101be816c2f458d9c", "score": "0.6325349", "text": "public function SetRequest(&$arrReq) {\n if(is_array($arrReq)) $this->arrReq = $arrReq;\n }", "title": "" }, { "docid": "e1febbd28391663e339bdf16133d9cda", "score": "0.629426", "text": "public function setRequest(\\Mvc\\Helper\\Request $request)\n {\n $this->request = $request;\n return $this;\n }", "title": "" }, { "docid": "ef65ee957e7b3650852b3026970b1d10", "score": "0.6281824", "text": "public static function setRequestInfo($request)\n {\n if ($request instanceof ServerRequest) {\n static::pushRequest($request);\n } else {\n $requestData = $request;\n $requestData += [[], []];\n $requestData[0] += [\n 'controller' => false,\n 'action' => false,\n 'plugin' => null\n ];\n $request = new ServerRequest();\n $request->addParams($requestData[0])->addPaths($requestData[1]);\n static::pushRequest($request);\n }\n }", "title": "" }, { "docid": "4d8e1c05bb4998b1e5c49d99ad41aa7a", "score": "0.62452215", "text": "public function testRequestSetCorrectly()\n {\n $property = $this->logger_reflection->getProperty('request');\n $property->setAccessible(TRUE);\n\n $this->assertEquals($this->request, $property->getValue($this->logger));\n $this->assertSame($this->request, $property->getValue($this->logger));\n }", "title": "" }, { "docid": "488e7a0dbc83bde78f0e0855cc9067b7", "score": "0.6212018", "text": "final public function setRequest() {\n $headers = getallheaders();\n $http_or_https = isset($_SERVER['HTTPS']) ? 'https' : 'http';\n\n $SERVER_PROTOCOL = $_SERVER['SERVER_PROTOCOL'] ?? '';\n\n $contextRequestArr = [\n 'http_version' => substr($SERVER_PROTOCOL, strpos($SERVER_PROTOCOL, '/')),\n 'method' => $_SERVER['REQUEST_METHOD'] ?? 'cli',\n 'socket' => [\n 'remote_address' => $_SERVER['REMOTE_ADDR'] ?? '',\n 'encrypted' => isset($_SERVER['HTTPS'])\n ],\n 'url' => [\n 'protocol' => $http_or_https,\n 'hostname' => $_SERVER['SERVER_NAME'] ?? '',\n 'port' => $_SERVER['SERVER_PORT'] ?? '',\n 'pathname' => $_SERVER['SCRIPT_NAME'] ?? '',\n 'search' => '?' . (($_SERVER['QUERY_STRING'] ?? '') ?? ''),\n 'full' => isset($_SERVER['HTTP_HOST']) ? $http_or_https . '://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'] : '',\n 'raw' => isset($_SERVER['HTTP_HOST']) ? $http_or_https . '://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'] : '',\n ],\n 'headers' => [\n 'content_type' => $headers['Content-Type'] ?? '',\n 'user_agent' => $this->clean_non_chars($headers['User-Agent']) ?? '',\n 'cookie' => $this->getCookieHeader($headers['Cookie'] ?? ''),\n ],\n 'env' => $this->getEnv(),\n 'cookies' => $this->getCookies(),\n ];\n \n $ctxRequest = new Context\\Request();\n try {\n $ctxRequest->mergeFromJsonString(json_encode($contextRequestArr));\n $this->context->setRequest($ctxRequest);\n }catch(\\Exception $ex){\n }\n }", "title": "" }, { "docid": "e875072c4507ada4a9b8d57f2726c466", "score": "0.62073314", "text": "public function setRequest(Request $request): self\n {\n $this->request = $request;\n return $this;\n }", "title": "" }, { "docid": "de572a062b868a4c4397a971a6f56207", "score": "0.6198035", "text": "public function setRequest(Zend_Controller_Request_Abstract $request)\n {\n $this->_request = $request;\n }", "title": "" }, { "docid": "cbd607e68da971c718109b2e22be7406", "score": "0.6189805", "text": "public function setRequest(Request $request)\n\t{\n\t\t$this->request = $request;\n\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "2a35c77f12abfc5ead32c0af11e301b2", "score": "0.6180924", "text": "public function setRequest($value) {\n if (!($value instanceof Zend_Controller_Request_Abstract)) {\n throw new Exception ('incorrect request object');\n }\n \n $this->request = $value;\n return $this;\n }", "title": "" }, { "docid": "16b123cb587ab670b094416ae686a2fc", "score": "0.6175309", "text": "function setProperty($key, $value) {\n $_REQUEST[$key] = $value;\n }", "title": "" }, { "docid": "e3364d917871fda84976128e8f8a9eb9", "score": "0.6152465", "text": "public function setRequest(Request $request)\r\n {\r\n $this->request = $request;\r\n\r\n return $this;\r\n }", "title": "" }, { "docid": "e3364d917871fda84976128e8f8a9eb9", "score": "0.6152465", "text": "public function setRequest(Request $request)\r\n {\r\n $this->request = $request;\r\n\r\n return $this;\r\n }", "title": "" }, { "docid": "6d342d9776dd3b4d4de866dce52b3917", "score": "0.6138609", "text": "protected function mapRequest() {\n foreach($_REQUEST as $key => $value) {\n $this->data[$key] = $value;\n }\n }", "title": "" }, { "docid": "1de45d90c6ec9d4247106dd107831032", "score": "0.6137293", "text": "public function setRequest(\\Dhl\\DataTypes\\RequestType $request)\n {\n $this->request = $request;\n return $this;\n }", "title": "" }, { "docid": "382e96de0a81d41de535c45b5ebff5b7", "score": "0.6128383", "text": "public function populate_from_request()\n\t\t{\n\t\t\tforeach($this as $key => $value) \n\t\t\t{\t\t\t\n\t\t\t\t// If we can find a matching a post var with key matching\n\t\t\t\t// key of current object var, set object var to the post value. \n\t\t\t\tif(isset($_REQUEST[$key]))\n\t\t\t\t{\n\t\t\t\t\t// Add 'set_' prefix so member name is now a mutator method name.\n\t\t\t\t\t$method = 'set_'.$key;\n\t\t\t\t\t\n\t\t\t\t\t// If a mutator method by the current name exists, run it and\n\t\t\t\t\t// pass current request value. \n\t\t\t\t\tif(method_exists($this, $method)=== TRUE)\n\t\t\t\t\t{\t\t\t\t\t\t\n\t\t\t\t\t\t$this->$method($_REQUEST[$key]);\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "7f7fd1e00d7bb2a2e44499080c489b27", "score": "0.6127683", "text": "public function setRequest(Request $request): self\n {\n $this->request = $request;\n\n return $this;\n }", "title": "" }, { "docid": "bfc3f417f631a4508617084cfd4b79ee", "score": "0.612139", "text": "public function testSettingRequest()\n {\n $this->apiRequest->setUserName('testName')->resolve();\n\n // check http method\n $this->assertEquals('POST', $this->apiRequest->getHttpMethod());\n // check uri\n $this->assertEquals('/v1/users', $this->apiRequest->getUri());\n // check headers\n $this->assertEquals([], $this->apiRequest->getHeaders());\n // check data\n $this->assertEquals(['name' => 'testName'], (array)$this->apiRequest->getData());\n }", "title": "" }, { "docid": "25387ddf0ab9df39a6cad2727fe19ca7", "score": "0.6109582", "text": "public function setRequest(string $request) : self\n {\n\n // Define.\n curl_setopt($this->ch, CURLOPT_CUSTOMREQUEST, $request);\n\n return $this;\n }", "title": "" }, { "docid": "764b8bc1bd984d017ca50bf7e441f55b", "score": "0.6102565", "text": "public function setRequest($request)\n {\n $this->request = $request;\n\n return $this;\n }", "title": "" }, { "docid": "764b8bc1bd984d017ca50bf7e441f55b", "score": "0.6102565", "text": "public function setRequest($request)\n {\n $this->request = $request;\n\n return $this;\n }", "title": "" }, { "docid": "7c3434237062a2d47aefe0f12502f44c", "score": "0.6068761", "text": "public function setRequest(Request $request): self\n {\n $this->request = $request;\n\n $this->cachedRoot = null;\n $this->cachedScheme = null;\n\n\t\treturn $this;\n }", "title": "" }, { "docid": "61a64d6a5d069596f7abecd7ca1934f8", "score": "0.60418886", "text": "public function populate_from_request()\r\n\t\t{\t\t\r\n\t\t\t// Interate through each class method.\r\n\t\t\tforeach(get_class_methods($this) as $method) \r\n\t\t\t{\t\t\r\n\t\t\t\t$key = str_replace('set_', '', $method);\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t// If there is a request var with key matching\r\n\t\t\t\t// current method name, then the current method \r\n\t\t\t\t// is a set mutator for this request var. Run \r\n\t\t\t\t// it (the set method) with the request var. \r\n\t\t\t\tif(isset($_GET[$key]))\r\n\t\t\t\t{\t\t\t\t\t\r\n\t\t\t\t\t$this->$method($_GET[$key]);\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}", "title": "" }, { "docid": "cb952c066b250ee09f1a30efd50083b1", "score": "0.60388774", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n return $this;\n }", "title": "" }, { "docid": "cb952c066b250ee09f1a30efd50083b1", "score": "0.60388774", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n return $this;\n }", "title": "" }, { "docid": "cb952c066b250ee09f1a30efd50083b1", "score": "0.60388774", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n return $this;\n }", "title": "" }, { "docid": "7a0532298950d5197db4cfbbc4a34ce0", "score": "0.60277945", "text": "public function setRequest(ServerRequestInterface $request);", "title": "" }, { "docid": "c3e59c034649e846034558ba5a6f4431", "score": "0.60269105", "text": "public final function setRequest(Request $request) {\n $this->request = $request;\n \n // fluent interface\n return $this;\n }", "title": "" }, { "docid": "1103aa2786c9c54db1c350c834fc1848", "score": "0.5982291", "text": "public function setRequestAs($value)\n\t{\n\t\t$this->requestAs = $value;\n\t}", "title": "" }, { "docid": "ff6ffd7f963dd7499a8a6229ca2edc2a", "score": "0.5975366", "text": "protected function setPutData()\n\t{\n\t\t$this->request->addPostFields($this->query->getParams());\n\t}", "title": "" }, { "docid": "99eec91633c1cb3130fda90280a1b5b4", "score": "0.5973186", "text": "function __set_request() {\n\t\tif(isset($this->__data)) {\n\t\t\t// set filter\n\t\t\t$tmpfilter = $this->html->request()->filter;\n\t\t\t$filter = $tmpfilter + $this->request_filter;\n\t\t\t$this->html->request()->set_filter($filter);\n\t\t\tforeach($this->__data as $key => $value) {\n\t\t\t\t$name = $this->html->request()->unindex_array($this->__elements[$key]->name);\n\t\t\t\tif(!isset($this->__data[$key]['static'])) {\n\t\t\t\t\t// set vars\n\t\t\t\t\t$request = $this->html->request()->get($name);\n\t\t\t\t\tif($request !== '') {\n\t\t\t\t\t\t$regex = '~\\[(.[^\\]]*)\\]~';\n\t\t\t\t\t\tpreg_match_all($regex, $name, $matches);\n\t\t\t\t\t\tif($matches) {\n\t\t\t\t\t\t\t$tag = preg_replace('~\\[.*\\]~', '', $name);\n\t\t\t\t\t\t\tif(isset($matches[1][0])) {\n\t\t\t\t\t\t\t\t$arReturn[$tag][$matches[1][0]] = $request;\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$arReturn[$tag] = $request;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$arReturn[$name] = $request;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$this->__submited = true;\n\t\t\t\t\t}\n\t\t\t\t} \n\t\t\t\telse if(isset($this->__data[$key]['static']) && $this->__data[$key]['static'] === false) {\n\t\t\t\t\t$request = $this->html->request()->get($name);\n\t\t\t\t\tif($request !== '') {\n\t\t\t\t\t\t$this->__submited = true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse if(isset($this->__data[$key]['static']) && $this->__data[$key]['static'] === true) {\n\t\t\t\t\tif($this->__elements[$key] instanceof htmlobject_select || $this->__elements[$key] instanceof htmlobject_select_debug) {\n\t\t\t\t\t\t$this->__static[$key] = $this->__elements[$key]->selected;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$this->__static[$key] = $this->__elements[$key]->value;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t// reset filter\n\t\t\t$this->html->request()->set_filter($tmpfilter);\n\t\t}\n\n\t\tif(isset($arReturn)) {\n\t\t\t$this->request = $arReturn;\n\t\t}\n\t}", "title": "" }, { "docid": "2a56315215c7cd9e44a9f5425af428d1", "score": "0.5970736", "text": "public function setRequest(Request $request): self\n {\n $this->builder->setRequest($request);\n $this->parser->setRequest($request);\n\n return $this;\n }", "title": "" }, { "docid": "3aeca7a99afc7a0aca87d89a14917d39", "score": "0.59634113", "text": "public function setRequest(Request $request)\n {\n $this->setParam('request', $request);\n $this->request = $request;\n\n return $this;\n }", "title": "" }, { "docid": "2d381c40f84967d6e708a4d8894dc4b0", "score": "0.59582895", "text": "public function setRequest(Down_SystemSettingRequest $value)\n {\n return $this->set(self::_REQUEST, $value);\n }", "title": "" }, { "docid": "f946eb0009ea5179e6815504c0cee5db", "score": "0.59476006", "text": "public function setRequestContent($request_content) {\n $this->request_content = $this->replaceTokenStrings($request_content);\n }", "title": "" }, { "docid": "1c03532b611f19a42ec663f96da400fa", "score": "0.5944307", "text": "function put(Request &$request, Response &$response);", "title": "" }, { "docid": "8e826cd5b35c60068b9c1ddbca028311", "score": "0.592877", "text": "public function onKernelRequest(RequestEvent $event) {\n $request = $event->getRequest();\n $request->attributes->set('custom_attributes', 'custom_value');\n $request->attributes->set('request_attribute', 'request_value');\n }", "title": "" }, { "docid": "479e312de20fc74a2c59df1b67c87371", "score": "0.5895368", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n\n return $this;\n }", "title": "" }, { "docid": "479e312de20fc74a2c59df1b67c87371", "score": "0.5895368", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n\n return $this;\n }", "title": "" }, { "docid": "479e312de20fc74a2c59df1b67c87371", "score": "0.5895368", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n\n return $this;\n }", "title": "" }, { "docid": "479e312de20fc74a2c59df1b67c87371", "score": "0.5895368", "text": "public function setRequest(Request $request)\n {\n $this->request = $request;\n\n return $this;\n }", "title": "" }, { "docid": "800d1e8b4998b4ba5adb75e4210b1236", "score": "0.58951414", "text": "function qa_set_request($request, $relativeroot, $usedformat = null)\n{\n\tif (qa_to_override(__FUNCTION__)) { $args=func_get_args(); return qa_call_override(__FUNCTION__, $args); }\n\n\tglobal $qa_request, $qa_root_url_relative, $qa_used_url_format;\n\n\t$qa_request = $request;\n\t$qa_root_url_relative = $relativeroot;\n\t$qa_used_url_format = $usedformat;\n}", "title": "" }, { "docid": "7578b8052b43b38ae74a5871dd02000b", "score": "0.5881023", "text": "public function set($query_var, $value)\n {\n }", "title": "" }, { "docid": "f8dc577e2ea218be7add08886f22775e", "score": "0.5875975", "text": "public function setRequest(Request $request)\n {\n @trigger_error(\\sprintf('The %s() method is deprecated since version 2.3 and will be removed in 3.0. Pass a RequestStack in the constructor instead.', __METHOD__), E_USER_DEPRECATED);\n\n $this->request = $request;\n }", "title": "" }, { "docid": "0fc6ec0b9c62718e972ccedfc5a5f603", "score": "0.5872143", "text": "public function setRequest(Request $request): static\n {\n $this->request = $request;\n return $this;\n }", "title": "" }, { "docid": "3a8561ed5af545be29f4713a5bc19a09", "score": "0.58646584", "text": "function _setupRequest(&$request) {\n $request->headers= array_change_key_case($this->headers, CASE_LOWER);\n $request->method= $this->method;\n $request->setParams(array_change_key_case($this->params, CASE_LOWER));\n $request->setURI(new URL('unittest://'.$this->getClassName().'/'));\n }", "title": "" }, { "docid": "6f0296e9643a9125e4d3f0f341464db1", "score": "0.5860666", "text": "public function setRequest(RequestInterface $request): void\n {\n $this->request = $request;\n }", "title": "" }, { "docid": "c2aa2d8d52a4d1cb89663dbd04da9750", "score": "0.5858764", "text": "public function setDefaultRequest() {\n }", "title": "" }, { "docid": "e521d4b973df11f5043cb8d47d9be051", "score": "0.58261436", "text": "public function setRequest(RequestInterface $request);", "title": "" }, { "docid": "62753051baf4e716bb60c60bdb0f1349", "score": "0.58214915", "text": "public static function setRequest($request){\n return \\Illuminate\\Auth\\Guard::setRequest($request);\n }", "title": "" }, { "docid": "6d290623c3ff97176488f162865ca316", "score": "0.5821143", "text": "public static function set_http_request(Symfony\\Component\\HttpFoundation\\Request $httpRequest){\n\t\tself::$httprequest = $httpRequest;\n\t}", "title": "" }, { "docid": "689f054e651fbe8fbad032d9c16477b3", "score": "0.5817364", "text": "function setRequestPassword($value)\n {\n $this->_props['RequestPassword'] = $value;\n }", "title": "" }, { "docid": "42dd7e62bee0d7025a5421d185e72610", "score": "0.58121645", "text": "protected function setPostData()\n\t{\n\t\t$this->request->addPostFields($this->query->getParams());\n\t}", "title": "" }, { "docid": "77d23a4727652b10da1a38ed1e5756ed", "score": "0.5807537", "text": "public function setRequestUrl($url)\n {\n $this->requestUrl = $url;\n }", "title": "" } ]
4f10cb2a6c01e1986c4995b4c8fd7028
Allows the user to amend the release notes.
[ { "docid": "f2c21c1a46fd87120b1ef80ad97fbd53", "score": "0.66319543", "text": "private function _amendReleaseNotes(InputInterface $input, $releaseNotes)\n {\n $commandLocatorFactory = new WhichLocatorFactory();\n $editorFactory = new EditorFactory($commandLocatorFactory->create());\n $editor = $editorFactory->create();\n $processBuilder = new ProcessBuilder();\n return $input->isInteractive() ? $editor->editData($processBuilder, $releaseNotes) : $releaseNotes;\n }", "title": "" } ]
[ { "docid": "3bbc5619c1258a2f18420fc007e797bf", "score": "0.62052584", "text": "public function updateApprovalNotes()\r\n {\r\n $id = Input::get('ID');\r\n $notes = trim(Input::get('NOTES'));\r\n $project = Project::find($id);\r\n if($project!=null)\r\n {\r\n if(strlen($project->ideaConcept)>0)\r\n $project->ideaConcept .=(strlen($notes)>0?\"<br><br>$notes\":\"\");\r\n else\r\n $project->ideaConcept =$notes;\r\n $project->approvalNotes=\"\";\r\n $project->save();\r\n\r\n //create mesg to consultant to let him know\r\n $msgInbox = \"Inventor approves the information.\\r\\n\";\r\n $msgInbox .= date(\"m-d-Y H:i:s\").\"\\r\\n\";\r\n $msgInbox .= \"File #:\".$project->lead->fileno.\"\\r\\n\";\r\n $msgInbox .= \"Pin: \".$project->id.\"\\r\\n\";\r\n $msgInbox .= \"Client: \".$project->lead->fname.\" \".$project->lead->lname.\"\\r\\n\";\r\n Inbox::createInbox($project->lead->id, $project->consultant_id, $msgInbox, 'CLIENT TEXT', 'CLIENT');\r\n\r\n $clientRequest = $project->requests->where('request','CLIENT')->where('consultantStage','CLIENT REVIEW')->where('adminStage','')->first();\r\n $clientRequest->adminStage=\"APPROVED\";\r\n $clientRequest->save();\r\n Transaction::createTransaction($this->client->consultant_id, '', '', 'CLIENT-APPROVAL-NOTES-APPROVED-LAUNCH', '', $id, $this->client->email, '', '', $this->client->phone, '');\r\n return \"1\";\r\n }\r\n return \"-1\";\r\n }", "title": "" }, { "docid": "3627181c90652422949e04285f71dda4", "score": "0.6050437", "text": "function edit_note( $p_event, $p_bug_id, $p_bugnote_id ) {\n\t\tif ( !access_has_bug_level( plugin_config_get( 'update_threshold' ), $p_bug_id ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\t$f_amount = gpc_get_int( 'plugin_motives_amount', 0 );\n\t\t$f_user_id = gpc_get_int( 'plugin_motives_user', 0 );\n\n\t\tif ( $f_user_id > 0 ) {\n\t\t\t$t_reporter_id = auth_get_current_user_id();\n\t\t\t$t_old = motives_get( $p_bug_id );\n\t\t\tmotives_update( $p_bug_id, $p_bugnote_id, $t_reporter_id, $f_user_id, $f_amount );\n\t\t\tmotives_revision_add( $p_bug_id, $p_bugnote_id, $t_reporter_id, $f_user_id, $f_amount );\n\t\t\t$t_old_value = '';\n\t\t\t$t_new_value = user_get_name( $f_user_id ) . ': ' . motives_format_amount($f_amount);\n\t\t\tif ( !empty( $t_old ) ) {\n\t\t\t\t$t_old_value = user_get_name($t_old['user_id']) . ': ' . motives_format_amount($t_old['amount']);\n\t\t\t}\n\t\t\tplugin_history_log($p_bug_id, 'bonus_edited', $t_old_value, $t_new_value, null, self::BASE_NAME );\n\t\t}\n\t}", "title": "" }, { "docid": "17970ea5c86bcdfadf79c5c619b577b0", "score": "0.6016596", "text": "private function changelog ()\n\t{\n\t\t$this->content = View::factory('update/changelog');\n\t}", "title": "" }, { "docid": "847c488da1e2c19dc632ff6a78020ee4", "score": "0.5997666", "text": "public function testUpdateSupplierInvoiceNote()\n {\n }", "title": "" }, { "docid": "25a3fcb51e1d99c3a405e4be9349c933", "score": "0.59316206", "text": "function postRelease_updateTypoVersion() {\n\t\t$nextVersionString = $this->information['nextVersion'].'-dev';\n\t\t$this->updateTypoVersion($nextVersionString);\n\t\t$this->writeMessage('Committing to SVN');\n\t\t$this->exec('cd work; svn commit --username '.$this->information['t3o_user'].' --password '.$this->information['t3o_pass'].' --message \"Updating version number to '.$nextVersionString.' after release of '.$this->information['versionNumber'].'\"; cd ..');\n\t}", "title": "" }, { "docid": "01bc53b44cc971f985f4976616bba0de", "score": "0.5726565", "text": "function setNotes($notes)\n\t{\n\t\t$this->_modified = true;\n\t\t$this->notes = $notes;\n\t}", "title": "" }, { "docid": "d6f9135f2da270297d04d6158877f1e9", "score": "0.5709977", "text": "public function mark_updatable($version);", "title": "" }, { "docid": "151c9f5fa57789bad537bbffe2945394", "score": "0.56955886", "text": "public function update_notes($notes)\n\t{\n\t\t$this->notes = $notes;\n\t\treturn parent::save();\n\t}", "title": "" }, { "docid": "4a9030572c930e3348810217f08cab44", "score": "0.5628834", "text": "public static function update_admin_notes($params = array()) {\n $params['action'] = 'updateadminnotes';\n return self::send_request($params);\n }", "title": "" }, { "docid": "20efe5575419295e51b67261cfc831df", "score": "0.562758", "text": "public function edit(Revision $revision)\n {\n\n }", "title": "" }, { "docid": "5b81a21f6df9f1abf49f2147c5356b36", "score": "0.5623672", "text": "function _editBump() {\n\t\t$this->dataItem->edited_on = time();\n\t\t$this->dataItem->version = $this->dataItem->version +1;\n\t}", "title": "" }, { "docid": "2a44048973a53190030b1cf02405ec2f", "score": "0.55840385", "text": "function updateChangeLog()\t{\n\t\t$this->writeMessage('Cleaning up working directory');\n\t\t$this->exec(\"rm -Rf work/*; rm -Rf work/.*\");\n\t\t\t// SVN checkout\n\t\tif ($this->information['branch'] == 'trunk')\n\t\t\t$svnRoot = $this->baseSVN.'trunk';\n\t\telse\n\t\t\t$svnRoot = $this->baseSVN.'branches/TYPO3_'.$this->information['branch'];\n\n\t\t$this->writeMessage('Checking out SVN from '.$svnRoot);\n\t\t$this->writeMessage('Notice: you might need to press \"enter\" and accept the SSL certificate afterwards.');\n\t\t$this->exec('svn co '.$svnRoot.' work');\n\n\t\t\t// read changeLog\n\t\t$this->writeMessage('Updating ChangeLog');\n\t\t$changeLog = file_get_contents('work/ChangeLog');\n\t\t\t// add ChangeLog entry\n\t\t$newChangeLog = strftime('%Y-%m-%d').' '.$this->information['name'].' <'.$this->information['email'].\">\\n\\n\";\n\t\t$newChangeLog .= chr(9).'* Release of TYPO3 '.$this->information['versionNumber'].\"\\n\\n\".$changeLog;\n\t\t\t// write changeLog\n\t\t$fp = fopen('work/ChangeLog', 'w');\n\t\tfwrite($fp, $newChangeLog);\n\t\tfclose($fp);\n\t\t\n\t\t // SECOND STEP: update TYPO_VERSION\n\t\t$this->updateTypoVersion($this->information['versionNumber']);\n\t\t\n\t\t\t// SVN commit\n\t\t$this->writeMessage('Committing to SVN');\n\t\t$this->exec('cd work; svn commit --username '.$this->information['t3o_user'].' --password '.$this->information['t3o_pass'].' --message \"Release of TYPO3 '.$this->information['versionNumber'].'\";cd ..');\n\t}", "title": "" }, { "docid": "fd8a6cd11c1c09c162aaaa0bfbeb1d6c", "score": "0.55667716", "text": "function add_note( $p_event, $p_bug_id, $p_bugnote_id ) {\n\t\tif ( !access_has_bug_level( plugin_config_get( 'update_threshold' ), $p_bug_id ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\t$f_amount = gpc_get_int( 'plugin_motives_amount', 0 );\n\t\t$f_user_id = gpc_get_int( 'plugin_motives_user', 0 );\n\t\tif ( $f_user_id > 0 && $f_amount != 0) {\n\t\t\t$t_reporter_id = auth_get_current_user_id();\n\t\t\tmotives_add( $p_bug_id, $p_bugnote_id, $t_reporter_id, $f_user_id, $f_amount );\n\t\t\tmotives_revision_add( $p_bug_id, $p_bugnote_id, $t_reporter_id, $f_user_id, $f_amount );\n\t\t}\n\t}", "title": "" }, { "docid": "444a7a2eb5202a36de25ffb85396e82b", "score": "0.5561732", "text": "public function test_v4_notes_update()\n\t{\n\t\techo \"\\nTesting notes update: \".route('v4_notes.update', $this->params);\n\t\t$response = $this->put(route('v4_notes.update'), $this->params);\n\t\t$response->assertSuccessful();\n\t\t//$response->assertJsonStructure([$this->getSchemaKeys('Project')]);\n\t}", "title": "" }, { "docid": "183b820659780b8e9af9134c571fa09c", "score": "0.55252725", "text": "function edit_note_form( $p_event, $p_bug_id, $p_bugnote_id ) {\n\t\tif ( !access_has_bug_level( plugin_config_get( 'update_threshold' ), $p_bug_id ) ) {\n\t\t\treturn;\n\t\t}\n\t\t$t_update = motives_get( $p_bugnote_id );\n\t\t$t_user_id = $t_update != null ? (int) $t_update['user_id'] : NO_USER;\n\t\t$t_amount = $t_update != null ? (int) $t_update['amount'] : 0;\n\n\t\techo '<tr ', helper_alternate_class(), '><td class=\"category\">', plugin_lang_get( 'bonuses_fines' ),\n\t\t\t'</td><td><select name=\"plugin_motives_user\"><option value=\"' . META_FILTER_ANY . '\">[' . plugin_lang_get( 'none' ) . ']</option>';\n\n\t\tprint_note_option_list( $t_user_id );\n\n\t\techo '</select> ',\n\t\tplugin_lang_get( 'amount' ), '<input name=\"plugin_motives_amount\" pattern=\"^(-)?[0-9]+$\" title=\"', plugin_lang_get( 'error_numbers' )\n\t\t, '\" value=\"', $t_amount, '\" /></td></tr>';\n\t}", "title": "" }, { "docid": "0ceab30245ce0c8a183f49f1343e3941", "score": "0.5490923", "text": "public function edit(Note $note)\n {\n //\n }", "title": "" }, { "docid": "0ceab30245ce0c8a183f49f1343e3941", "score": "0.5490923", "text": "public function edit(Note $note)\n {\n //\n }", "title": "" }, { "docid": "0ceab30245ce0c8a183f49f1343e3941", "score": "0.5490923", "text": "public function edit(Note $note)\n {\n //\n }", "title": "" }, { "docid": "7a04d30461e5cd856a7c702d869c7b0f", "score": "0.54565823", "text": "function project_release_project_edit_releases($node) {\n project_project_set_breadcrumb($node);\n drupal_set_title(check_plain($node->title));\n return drupal_get_form('project_release_project_edit_form', $node);\n}", "title": "" }, { "docid": "8747aea1064f61d9bbd023c81e92b5cb", "score": "0.5440155", "text": "function simple_edits_change(){\n $simple_edits_options = get_option( GSE_SETTINGS_FIELD );\n $simple_edits_options['footer_output_on'] = 1;\n $simple_edits_options['footer_output'] = '[vimm_link]';\n $simple_edits_options['footer_creds_text'] = '';\n $simple_edits_options['footer_backtotop_text'] = '';\n $simple_edits_options['post_meta'] ='[post_categories] [post_tags]';\n $simple_edits_options['post_info']='[post_date] By [post_author_posts_link] [post_comments] [post_edit]';\n update_option( GSE_SETTINGS_FIELD, $simple_edits_options );\n }", "title": "" }, { "docid": "fef68085b329748fc03caf3e5b10568a", "score": "0.5338243", "text": "function update_the_exsiting_note($notes_params, $note_id){\n\t\n\t\tglobal $connection;\n\t\t$sql = \"UPDATE pfagos__notes \n\t\t\t\t\t\tSET \t\t\t\t\n\t\t\t\t\t\t\tnote_cat_id = \". $notes_params['note_cat_id'] .\",\t\t\t\n\t\t\t\t\t\t\tnote = '\". CommonFunctions::mysql_preperation(trim($notes_params['note_text'])) . \"', \n\t\t\t\t\t\t\tdate_modified = '\". $notes_params['date_modified'] . \"', \n\t\t\t\t\t\t\tmodified_by = \". $notes_params['modified_by'] .\" \n\t\t\t\t\t\t WHERE note_id = {$note_id} AND note_owner_id = {$notes_params['note_owner_id']}\";\n\t\tAppModel::grab_db_function_class()->execute_query($sql);\t\t\n\t}", "title": "" }, { "docid": "89c968bb4b552fca4bd5f744cc4afc1a", "score": "0.5335146", "text": "public function whmcs_update_admin_notes($params = array()) {\n\t\t$params['action'] = 'UpdateAdminNotes';\n\t\t// return Whmcs_base::send_request($params);\n $load = new Whmcs_base();\n return $load->send_request($params);\n\t}", "title": "" }, { "docid": "a057bf890d01998d7b22126e470cc134", "score": "0.53087145", "text": "public function edit(AuthorNotification $authorNotification)\n {\n //\n }", "title": "" }, { "docid": "dca624bdd40ea2a207dc8a2fd3f6cb9c", "score": "0.52927136", "text": "private function UpdateReturnNotes()\n\t\t{\n\t\t\tif(!isset($_REQUEST['returnId'])) {\n\t\t\t\texit;\n\t\t\t}\n\n\t\t\t$query = sprintf(\"SELECT * FROM [|PREFIX|]returns WHERE returnid='%d'\", $GLOBALS['ISC_CLASS_DB']->Quote($_REQUEST['returnId']));\n\t\t\t$result = $GLOBALS['ISC_CLASS_DB']->Query($query);\n\t\t\t$row = $GLOBALS['ISC_CLASS_DB']->Fetch($result);\n\n\t\t\tif(!$row['returnid']) {\n\t\t\t\texit;\n\t\t\t}\n\n\t\t\t// Do we have permission to alter this return?\n\t\t\tif($GLOBALS['ISC_CLASS_ADMIN_AUTH']->GetVendorId() && $row['retvendorid'] != $GLOBALS['ISC_CLASS_ADMIN_AUTH']->GetVendorId()) {\n\t\t\t\texit;\n\t\t\t}\n\n\t\t\t$updatedReturn = array(\n\t\t\t\t\"retstaffnotes\" => $_POST['returnNotes']\n\t\t\t);\n\t\t\t$GLOBALS['ISC_CLASS_DB']->UpdateQuery(\"returns\", $updatedReturn, \"returnid='\".$GLOBALS['ISC_CLASS_DB']->Quote($row['returnid']).\"'\");\n\t\t\techo 1;\n\t\t\texit;\n\t\t}", "title": "" }, { "docid": "993c9ffb1cd9fda37c54d2d44008655d", "score": "0.5288857", "text": "public function setNotes($notes)\n {\n $this->notes = $notes;\n }", "title": "" }, { "docid": "c11ffd76c300978c429a35f1a8494b9b", "score": "0.5271553", "text": "public function edit()\n\t{\n\t\t// TODO: fonction\n\t}", "title": "" }, { "docid": "39376747c0b6592c4c548e69286e20c3", "score": "0.52666956", "text": "function afmng_db_release_update($release_id, $episode_no, $episode_title)\n{\n\tglobal $wpdb;\n\n\t$wpdb->update( \n\t\tafmngdb::$tbl_episode, \n\t\tarray( \n\t\t\t'episode_no' => $episode_no,\n\t\t\t'episode_title' => $episode_title\n\t\t), \n\t\tarray ('release_id' => $release_id),\n\t\tarray( \n\t\t\t'%s',\n\t\t\t'%s'\n\t\t),\n\t\tarray('%d')\n\t);\n}", "title": "" }, { "docid": "6c7f0291a0daee18d26bc366948c9855", "score": "0.5264102", "text": "function project_release_project_edit_form_submit($form, &$form_state) {\n $nid = $form_state['values']['nid'];\n db_query(\"UPDATE {project_release_projects} SET releases = %d, version_format = '%s' WHERE nid = %d\", $form_state['values']['releases'], $form_state['values']['version_format'], $nid);\n if (!db_affected_rows()) {\n // It's possible there's no record in {project_release_projects} if this\n // particular project was created before project_issue.module was enabled.\n db_query(\"INSERT INTO {project_release_projects} (nid, releases, version_format) VALUES (%d, %d, '%s')\", $nid, $form_values['releases'], $form_values['version_format']);\n }\n\n if (!empty($form_state['values']['api'])) {\n foreach ($form_state['values']['api'] as $tid => $values) {\n if (!empty($values['major'])) {\n foreach ($values['major'] as $major => $major_values) {\n $major_values['recommended'] = ($values['recommended'] == $major) ? 1 : 0;\n if ($obj = db_fetch_object(db_query(\"SELECT * FROM {project_release_supported_versions} WHERE nid = %d AND tid = %d AND major = %d\", $nid, $tid, $major))) {\n if ($obj->supported != $major_values['supported']\n || $obj->recommended != $major_values['recommended']\n || $obj->snapshot != $major_values['snapshot']) {\n db_query(\"UPDATE {project_release_supported_versions} SET supported = %d, recommended = %d, snapshot = %d WHERE nid = %d AND tid = %d AND major = %d\", $major_values['supported'], $major_values['recommended'], $major_values['snapshot'], $nid, $tid, $major);\n }\n }\n else {\n db_query(\"INSERT INTO {project_release_supported_versions} (nid, tid, major, supported, recommended, snapshot) VALUES (%d, %d, %d, %d, %d, %d)\", $nid, $tid, $major, $major_values['supported'], $major_values['recommended'], $major_values['snapshot']);\n }\n }\n }\n }\n }\n db_query(\"UPDATE {node} SET changed = %d WHERE nid = %d\", time(), $form_state['values']['nid']);\n\n $cid = 'table:'. $form_state['values']['nid'] .':';\n cache_clear_all($cid, 'cache_project_release', TRUE);\n\n drupal_set_message(t('Release settings have been saved.'));\n}", "title": "" }, { "docid": "06c2f35baf623c3986392311ac41a6a4", "score": "0.5248908", "text": "public function setNotes($Notes){\n $this->Notes = $Notes;\n }", "title": "" }, { "docid": "979f8f1c793d2f087fbdf532f8eeaea0", "score": "0.52415484", "text": "function Update_Invoice($id,$Details,$AddReplace=0) { // AR=1 to replace data\n global $USER;\n $inv = Get_Invoice($id);\n \n $LastUsed = 0;\n if ($AddReplace==0) {\n for ($i = 1; $i<4;$i++) if ($inv[\"Amount$i\"] || $inv[\"Desc$i\"]) $LastUsed = $i;\n }\n\n foreach ((is_array($Details[0])?$Details: [$Details]) as $D) {\n if ($LastUsed++ >=3) return \"No Space left to expand invoice\";\n $inv[\"Desc$LastUsed\"] = $D[0];\n $inv[\"Amount$LastUsed\"] = $D[1];\n }\n\n// Redo total\n $total = 0;\n for ($i = 1; $i<4;$i++) $total += $inv[\"Amount$i\"];\n $inv['Total'] = $total;\n\n// Is it paid if so mark paid\n if ($inv['PaidTotal'] >= $inv['Total']) {\n $inv['PayDate'] = time();\n $inv['History'] .= \"Fully Paid on \" . date('j/n/Y') . \" by \" . $USER['Login'] . \"\\n\";\n if ($inv['PaidTotal'] > $inv['Total']) {\n Send_SysAdmin_Email(\"Problem with Invoice \" . $inv['id'] . \" Paid Total > invoice Total\",$inv);\n }\n }\n// save and print revision\n\n $inv['Revision'] ++;\n $inv['IssueDate'] = time();\n Put_Invoice($inv);\n Invoice_Print($inv);\n return \"\";\n}", "title": "" }, { "docid": "a3021e3f88ffdaabdce9a0606f75dda4", "score": "0.52354085", "text": "public function updateAction() {\n $todos\n $todo = new Todo();\n \n $todo->title = $this->_params['title'];\n $todo->description = $this->_params['description'];\n $todo->due_date = $this->_params['due_date'];\n $todo->is_done = 'false';\n }", "title": "" }, { "docid": "c055517aad9af9b78adaebedb79f4441", "score": "0.52252054", "text": "function buggm_update_comment(){\n do_action('buggm_update_comment');\n}", "title": "" }, { "docid": "1cd8da35a6176807f09afeb03722d072", "score": "0.5213299", "text": "public function testUpdate()\n {\n\t$this->visit('/tasks/1/edit') //on va sur la page pour éditer la task numéro 1\n ->type('titre', 'title') //on modifie le champs 'title'\n\t->type('description test update', 'description') //on modifie le champs 'description'\n ->press('Update Task') //on valide le formulaire\n ->seePageIs('/tasks') //on vérifie qu'après la modification on retourne à la page de la liste des tasks\n\t->see('Task successfully modified!'); //on vérifie si le message 'Task successfully modified!' s'affiche sur la page\n }", "title": "" }, { "docid": "ee470f4e42003be58b658b89aeef58c9", "score": "0.520557", "text": "public function edit( )\n {\n //\n }", "title": "" }, { "docid": "76d5ef442d96a16922b8d502c4dda4c7", "score": "0.51800096", "text": "public function testUpdateVideoComment()\n {\n }", "title": "" }, { "docid": "608616cf610b294921f203a3ae5bffec", "score": "0.5168854", "text": "public function beginEdit();", "title": "" }, { "docid": "8a2ec52bb7085073f413cccbf8cb3480", "score": "0.5153956", "text": "function journal($ar){\n XShell::changeTemplate('epasslibre/modeplupdcmd/journal-order.html');\n return parent::journal($ar);\n }", "title": "" }, { "docid": "ce30a483dba97e01252098020970c161", "score": "0.51308984", "text": "function update_annotation_db() {\r\n\t// get data from ajax call\r\n\t$plugin_file = $_REQUEST['plugin_annotated'];\r\n\t$new_note_text = trim(sanitize_textarea_field($_REQUEST['new_note_text']));\r\n\t\r\n\t// get associative array of all current annotations from DB\r\n\t$annotations = get_option(\"plugin-annotations\", array());\r\n\t\r\n\tif (($new_note_text == \"\") && (array_key_exists($plugin_file, $annotations))) {\r\n\t\t// empty textarea means this note is being deleted - remove from array\r\n\t\tunset($annotations[$plugin_file]);\r\n\t}\r\n\telse {\r\n\t\t// add/update note - also remove the slashes WP adds to escape characters\r\n\t\t$annotations[$plugin_file] = wp_unslash($new_note_text);\r\n\t}\r\n\t\r\n\t// save updated array to DB\r\n\tupdate_option(\"plugin-annotations\", $annotations);\r\n\t\r\n}", "title": "" }, { "docid": "497e3e4f94947324b33cd0a44ecce8ca", "score": "0.5124111", "text": "function modnotes_install()\n\t{\n\t\tglobal $db, $cache;\n\t\t\n\t\tif(!$db->field_exists(\"viewmodnotes\", \"usergroups\"))\n\t\t{\n\t\t\t$db->query(\"ALTER TABLE \".TABLE_PREFIX.\"usergroups ADD viewmodnotes INT(1) NOT NULL\");\n\t\t}\n\t\t\n\t\tif(!$db->field_exists(\"viewownmodnotes\", \"usergroups\"))\n\t\t{\n\t\t\t$db->query(\"ALTER TABLE \".TABLE_PREFIX.\"usergroups ADD viewownmodnotes INT(1) NOT NULL\");\n\t\t}\n\t\t\n\t\tif(!$db->field_exists(\"addmodnotes\", \"usergroups\"))\n\t\t{\n\t\t\t$db->query(\"ALTER TABLE \".TABLE_PREFIX.\"usergroups ADD addmodnotes INT(1) NOT NULL\");\n\t\t}\n\t\t\n\t\tif(!$db->field_exists(\"editmodnotes\", \"usergroups\"))\n\t\t{\n\t\t\t$db->query(\"ALTER TABLE \".TABLE_PREFIX.\"usergroups ADD editmodnotes INT(1) NOT NULL\");\n\t\t}\n\t\t\n\t\tif(!$db->field_exists(\"editownmodnotes\", \"usergroups\"))\n\t\t{\n\t\t\t$db->query(\"ALTER TABLE \".TABLE_PREFIX.\"usergroups ADD editownmodnotes INT(1) NOT NULL\");\n\t\t}\n\t\t\n\t\t$db->update_query(\"usergroups\", array(\"viewmodnotes\" => 1, \"viewownmodnotes\" => 1, \"addmodnotes\" => 1, \"editmodnotes\" => 1, \"editownmodnotes\" => 1), \"canmodcp='1'\");\n\t\t\n\t\tif(!$db->table_exists(\"modnotes\"))\n\t\t{\n\t\t\t$db->write_query(\"CREATE TABLE \".TABLE_PREFIX.\"modnotes(\n\t\t\t\tid INT(10) UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,\n\t\t\t\tuid INT(10) UNSIGNED NOT NULL,\n\t\t\t\tmid INT(10) UNSIGNED NOT NULL,\n\t\t\t\tnote TEXT NOT NULL,\n\t\t\t\tdateline BIGINT(30) NOT NULL\n\t\t\t\t) ENGINE=MyISAM\".$db->build_create_table_collation().\";\");\n\t\t}\n\t\t\n\t\t$cache->update_usergroups();\n\t}", "title": "" }, { "docid": "9e072c5f8a4f17920a0bf991f3aae0f2", "score": "0.5119582", "text": "public function testTaskEdit()\n {\n $this->browse(function (Browser $browser) {\n $browser->loginAs(User::find(1))\n ->visit('1/vacancy/' . Vacancy::where(['user_id' => 1])->first()->id)\n ->assertSee('Edit')\n ->press('Edit')\n ->type('notes', 'This note was changed by test')\n ->press('Save')\n ->assertSee('Vacancy was successfully updated');\n });\n }", "title": "" }, { "docid": "a39c1d973af00a4fa976375a176d9492", "score": "0.5118922", "text": "public function lower_free_version_notice() {\n\n\t\t$notice_class = 'notice notice-warning';\n\t\t$button_text = __( 'Update Now', 'ultimatedashboard' );\n\t\t$update_button = '<button type=\"button\" class=\"button button-primary udb-button udb-update-plugin\">' . $button_text . '</button>';\n\n\t\t$description = '<h2>' . __( 'Ultimate Dashboard PRO 3.0', 'ultimatedashboard' ) . '</h2>';\n\t\t$description .= __( 'Since version 3.0, <strong>Ultimate Dashboard PRO</strong> requires at minimum <strong>Ultimate Dashboard</strong> version 3 to run on your WordPress installation.', 'ultimatedashboard' );\n\t\t$description .= '<br><br>';\n\t\t$description .= $update_button;\n\n//\t\tprintf( '<div class=\"%1s\"><p>%2s</p></div>', $notice_class, $description );\n\n\t}", "title": "" }, { "docid": "3cf9a857a4b9d90cfb67731e3ab53715", "score": "0.5109182", "text": "function _edit() {\n\t}", "title": "" }, { "docid": "99e723c030f6441472bddd1153aa973c", "score": "0.51032037", "text": "public function edit()\n\t{\n\n\t}", "title": "" }, { "docid": "351fdc5579ec3debf7237c94fff917c3", "score": "0.51027745", "text": "public function update_item_desc()\n {\n }", "title": "" }, { "docid": "a314a4daf373a681cd928468e7b9485b", "score": "0.50768924", "text": "public function onCreditNoteUpdated($event)\n {\n $data = [\n 'action' => 'activity_update_creditnote', 'icon' => 'fa-pencil-alt', 'user_id' => $this->user,\n 'value1' => $event->creditnote->reference_no, 'value2' => $event->creditnote->company->name,\n 'url' => $event->creditnote->url,\n ];\n $event->creditnote->activities()->create($data);\n }", "title": "" }, { "docid": "2cf9c7fb11fef770e5991f8f5af3c014", "score": "0.5076133", "text": "public function addANote()\n\t{\n\t\t$email = $_POST['email'];\n\t\t$notes = $_POST['notes'];\n\t\t$this->load->model('crr_model');\n\t\t$result = $this->crr_model->addANote($email, $notes);\n\t\techo $result;\n\t}", "title": "" }, { "docid": "3cd99bf2852bc2745d498e45c9ce5144", "score": "0.50715584", "text": "public function edit(Notice $notice)\n {\n //\n }", "title": "" }, { "docid": "bd3bf7cfaec58b4de65b0785ce8a650a", "score": "0.50690675", "text": "public function pressUpdate()\n {\n // TODO wait if the button is disabled during auto-save\n $this->pressButton('publish');\n }", "title": "" }, { "docid": "8c91609ce0a10e4e644a37bb977a29a5", "score": "0.5064192", "text": "function package_handler_update_project($request, $release) {\n $dog = &dog_get_face();\n // FIXME this needs to actually get implemented, once we're on to the dog updating commands\n}", "title": "" }, { "docid": "6eb625a7540bf68f8a94cef4cac0dccf", "score": "0.50532186", "text": "public function activateVersion() {\n\t\t// Get version\n\t\t$version = $this->getSingleObject();\n\t\t\n\t\t// Get editor\n\t\t$editor = new ProjectEditor(Project::getProject($version->packageID));\n\t\t\n\t\t// Switch version\n\t\t$editor->activateVersion($version->getDecoratedObject());\n\t}", "title": "" }, { "docid": "efabb119225ff5d175e614a46ed46024", "score": "0.50399876", "text": "function dc_add_release()\n{\n\tglobal $wpdb;\n\t\n\t$title \t\t\t= trim($_POST['title']);\n\t$artist \t\t= trim($_POST['artist']);\n\t$filename \t\t= $_POST['filename'];\n\t$downloads \t\t= $_POST['downloads'];\n\t\n\t$errors = array();\n\t\n\t// Check if all fields have been filled out properly\n\tif ( '' == $title ) {\n\t\t$errors[] = \"The title must not be empty\";\t\n\t}\n\tif ( '' == $filename ) {\n\t\t$errors[] = \"Please choose a valid file for this release\";\t\n\t}\n\tif ( !is_numeric( $downloads ) ) {\n\t\t$errors[] = \"Allowed downloads must be a number\";\n\t}\n\t\n\t// Update or insert if no errors occurred.\n\tif ( !sizeof($errors) ) \n\t{\n\t\treturn \n\t\t$wpdb->insert(\tdc_tbl_releases(), \n\t\t\t\t\tarray( 'title' => $title, 'artist' => $artist, 'filename' => $filename, 'allowed_downloads' => $downloads),\n\t\t\t\t\tarray( '%s', '%s', '%s', '%d' ) );\n\t} else\n\t{\n\t\treturn $errors;\n\t}\n}", "title": "" }, { "docid": "7b1bfa7d4f8c1ad94941af9b19228158", "score": "0.50287026", "text": "function internalEdit(){}", "title": "" }, { "docid": "e72a11223f44327b6406cadf652af607", "score": "0.50268364", "text": "function UpdateProdOrderRemarks($orders_id,$remark)\r\n\t{\r\n\t\t$remark\t\t\t \t =\tmysql_real_escape_string(trim($remark));\r\n\t\t//update product description\r\n\t\t$edit = \"UPDATE product_orders\r\n\t\t\t\tSET\r\n\t\t\t\tremark\t\t \t\t= '$remark'\r\n\t\t\t\tWHERE\r\n\t\t\t\torders_id \t\t\t= '$orders_id'\r\n\t\t\t\t\";\r\n\t\t$query = mysql_query($edit);\r\n\t\t//echo $edit.mysql_error();exit;\r\n\t\t\r\n\t}", "title": "" }, { "docid": "9b1f9a79195671d4aef405cf39e6011a", "score": "0.5025224", "text": "function tracker_do_update() {\n\tglobal $PARAMS, $SOAP, $LOG, $extra_fields;\n\n\tif (get_parameter($PARAMS, \"help\")) {\n\t\techo <<<EOF\n(add help)\nEOF;\n\n\t\treturn;\n\t}\n\n\t$update_params = get_artifact_params(false);\n\t$update_desc = $update_params[\"desc\"];\n\t$update_data = $update_params[\"data\"];\n\n\t// Show summary\n\techo \"Confirm you want to update the tracker with the following information:\\n\";\n\techo \"Project: \".$update_desc[\"group_name\"].\"\\n\";\n\techo \"Tracker type: \".$update_desc[\"artifact_type_name\"].\"\\n\";\n\techo \"Summary: \".$update_desc[\"original_summary\"].\"\\n\";\n\tif (array_key_exists(\"priority\", $update_desc)) {\n\t\techo \"> Priority: \".$update_desc[\"priority\"].\"\\n\";\n\t}\n\tif (array_key_exists(\"assigned_to_name\", $update_desc)) {\n\t\techo \"> Assigned to: \".$update_desc[\"assigned_to_name\"].\"\\n\";\n\t}\n\tif (array_key_exists(\"summary\", $update_desc)) {\n\t\techo \"> Summary: \".$update_desc[\"summary\"].\"\\n\";\n\t}\n\n\t//NOTE: When updating, the details can't be changed. Instead of that,\n\t//a new message is added, and we don't want that\n\tif (array_key_exists(\"details\", $update_desc)) {\n\t\techo \"> Details: \\n\";\n\t\techo $update_desc[\"details\"].\"\\n\";\n\t}\n\n\t// Show extra fields also.\n\tforeach ($update_data[\"extra_fields_data\"] as $new_extra_field) {\n\t\t$extra_field_id = $new_extra_field[\"extra_field_id\"];\n\t\t$extra_field_name = '';\n\t\tforeach ($extra_fields as $k => $v) {\n\t\t\tif ($v['extra_field_id'] == $extra_field_id)\n\t\t\t\t$extra_field_name = $v['field_name'];\n\t\t}\n\t\tprint \"> $extra_field_name: \".$new_extra_field[\"field_data\"].\"\\n\";\n\t}\n\n\t// ask for confirmation if the --noask param is not set\n\tif (!get_parameter($PARAMS, array(\"n\", \"noask\"))) {\n\t\t$input = get_user_input(\"Is this information correct? (y/n): \");\n\t\t$input = strtolower($input);\n\t} else {\n\t\t$input = \"y\";\t\t// commit changes directly\n\t}\n\n\t// Update the information array\n\t$update_params = $update_data[\"original_data\"];\n\t$update_params[\"description\"] = $update_params[\"details\"];\n\t$update_params[\"details\"] = \"\";\t\t// see comment above\n\n\tif ($input == \"yes\" || $input == \"y\") {\n\t\tif (array_key_exists(\"priority\", $update_data)) {\n\t\t\t$update_params[\"priority\"] = $update_data[\"priority\"];\n\t\t}\n\t\tif (array_key_exists(\"assigned_to\", $update_data)) {\n\t\t\t$update_params[\"assigned_to\"] = $update_data[\"assigned_to\"];\n\t\t}\n\t\tif (array_key_exists(\"summary\", $update_data)) {\n\t\t\t$update_params[\"summary\"] = $update_data[\"summary\"];\n\t\t}\n\t\tif (array_key_exists(\"status_id\", $update_data)) {\n\t\t\t$update_params[\"status_id\"] = $update_data[\"status_id\"];\n\t\t}\n\t\tif (array_key_exists(\"details\", $update_data)) {\n\t\t\t$update_params[\"description\"] = $update_data[\"details\"];\n\t\t}\n\n\t\t$update_params[\"extra_fields_data\"] = $update_params[\"extra_fields\"];\n\t\t// include the extra fields\n\t\tforeach ($update_data[\"extra_fields_data\"] as $new_extra_field) {\n\t\t\t$added = false;\n\t\t\tfor ($i = 0; $i < count($update_params[\"extra_fields\"]); $i++) {\n\t\t\t\tif ($update_params[\"extra_fields_data\"][$i][\"extra_field_id\"] == $new_extra_field[\"extra_field_id\"]) {\n\t\t\t\t\t$update_params[\"extra_fields_data\"][$i] = $new_extra_field;\t// overwrite old data with new data\n\t\t\t\t\t$added = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// if it couldn't replace the old value, insert a new value\n\t\t\tif (!$added) {\n\t\t\t\t$update_params[\"extra_fields_data\"][] = $new_extra_field;\n\t\t\t}\n\t\t}\n\n\t\t$update_params[\"group_id\"] = $update_data[\"group_id\"];\n\t\t//TODO: Manage the new artifact_type id\n\t\t$update_params[\"new_artifact_type_id\"] = $update_params[\"group_artifact_id\"];\n\n\t\t$res = $SOAP->call(\"updateArtifact\", $update_params);\n\t\tif (($error = $SOAP->getError())) {\n\t\t\t$LOG->add($SOAP->responseData);\n\t\t\texit_error($error, $SOAP->faultcode);\n\t\t}\n\t\tshow_output($res);\n\t} else {\n\t\texit_error(\"Submission aborted\");\n\t}\n}", "title": "" }, { "docid": "5018b747015793f2382c72f7dcc239cd", "score": "0.5019404", "text": "function modnotes_modcp()\n\t{\n\t\tglobal $mybb, $db, $lang, $headerinclude, $header, $footer, $theme, $modcp_nav, $templates, $modnotes;\n\t\t\n\t\tif($mybb->input['action'] == \"deletenote\" && $mybb->request_method == \"post\")\n\t\t{\n\t\t\t$note = $db->simple_select(\"modnotes\", \"id,uid,mid\", \"id='\".intval($mybb->input['id']).\"'\");\n\t\t\t$note = $note->fetch_array();\n\t\t\tif($mybb->usergroup['editmodnotes'] != 1 && !($mybb->usergroup['editownmodnotes'] == 1 && $mybb->user['uid'] == $note['mid'])) error_no_permission();\n\t\t\t\n\t\t\tverify_post_check($mybb->input['my_post_key']);\n\t\t\t\n\t\t\t$lang->load(\"modnotes\");\n\t\t\tif(!$note['id']) error($lang->modnotes_notfound);\n\t\t\t\n\t\t\t$db->delete_query(\"modnotes\", \"id='{$note['id']}'\");\n\t\t\tredirect(get_profile_link($note['uid']), $lang->modnotes_delete_success);\n\t\t}\n\t\t\n\t\tif($mybb->input['action'] == \"do_editnote\")\n\t\t{\n\t\t\t$id = $mybb->input['id'] = intval($mybb->input['uid']);\n\t\t\t$note = $db->simple_select(\"modnotes\", \"*\", \"id='{$id}'\");\n\t\t\t$note = $note->fetch_array();\n\t\t\tif($mybb->usergroup['editmodnotes'] != 1 && !($mybb->usergroup['editownmodnotes'] == 1 && $mybb->user['uid'] == $note['mid'])) error_no_permission();\n\t\t\t\n\t\t\t$lang->load(\"modnotes\");\n\t\t\tif(!$note['id']) error($lang->modnotes_notfound);\n\t\t\t\n\t\t\t$user = get_user($note['uid']);\n\t\t\t$uid = $user['uid'];\n\t\t\n\t\t\t// Verify incoming POST request\n\t\t\tverify_post_check($mybb->input['my_post_key']);\n\t\t\t\n\t\t\t$lang->load(\"datahandler_post\");\n\t\t\t$lang->load(\"modnotes\");\n\t\t\t\n\t\t\t$message = trim_blank_chrs($mybb->input['message']);\n\t\t\t\n\t\t\tif(my_strlen($message) < $mybb->settings['minmessagelength'] && $mybb->settings['minmessagelength'] > 0)\n\t\t\t{\n\t\t\t\t$lang->postdata_message_too_short = $lang->sprintf($lang->postdata_message_too_short, $mybb->settings['minmessagelength']);\n\t\t\t\t$errors[] = $lang->postdata_message_too_short;\n\t\t\t}\n\t\t\t\n\t\t\tif(my_strlen($message) > $mybb->settings['maxmessagelength'] && $mybb->settings['maxmessagelength'] > 0)\n\t\t\t{\n\t\t\t\t$lang->postdata_message_too_long = $lang->sprintf($lang->postdata_message_too_long, $mybb->settings['maxmessagelength'], my_strlen($message));\n\t\t\t\t$errors[] = $lang->postdata_message_too_long;\n\t\t\t}\n\t\t\t\n\t\t\tif(count($errors) > 0)\n\t\t\t{\n\t\t\t\t$errors = inline_error($errors);\n\t\t\t\t$mybb->input['action'] = \"editnote\";\n\t\t\t}\n\t\t\telse if(!$mybb->input['previewpost'])\n\t\t\t{\n\t\t\t\t$update = array(\n\t\t\t\t\t\t\t\"note\" => $db->escape_string($message),\n\t\t\t\t\t\t\t\"dateline\" => TIME_NOW\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\n\t\t\t\t$db->update_query(\"modnotes\", $update, \"id='{$note['id']}'\");\n\t\t\t\tredirect(get_profile_link($uid), $lang->redirect_modnotes);\n\t\t\t}\n\t\t\t\n\t\t\tif($mybb->input['previewpost'] && my_strlen($message) > 0)\n\t\t\t{\n\t\t\t\trequire_once MYBB_ROOT.\"inc/class_parser.php\";\n\t\t\t\t$parser = new postParser;\n\t\t\t\t\n\t\t\t\t$parser_options = array(\n\t\t\t\t\t\t\"allow_html\" => 0,\n\t\t\t\t\t\t\"allow_mycode\" => 1,\n\t\t\t\t\t\t\"allow_smilies\" => 1,\n\t\t\t\t\t\t\"allow_imgcode\" => 1,\n\t\t\t\t\t\t\"allow_videocode\" => 1,\n\t\t\t\t\t\t\"me_username\" => $mybb->user['username'],\n\t\t\t\t\t\t\"filter_badwords\" => 1\n\t\t\t\t\t);\n\t\t\t\t$note = $parser->parse_message($message, $parser_options);\n\t\t\t\t\n\t\t\t\t$trow = \"trow1\";\n\t\t\t\t$username = \"<a href=\\\"{$mybb->settings['bburl']}/\".get_profile_link($mybb->user['uid']).\"\\\" title=\".my_date($mybb->settings['dateformat'], TIME_NOW).'&nbsp;'.my_date($mybb->settings['timeformat'], TIME_NOW).\"\\\">\".format_name($mybb->user['username'], $mybb->user['usergroup'], $mybb->user['displaygroup']).\"</a>\";\n\t\t\t\t\n\t\t\t\t$temp = $lang->modnotes;\n\t\t\t\t$lang->modnotes = $lang->modnotes_preview;\n\t\t\t\t\n\t\t\t\teval('$modnotes_notes .= \"'.$templates->get(\"modnotes_row\").'\";');\n\t\t\t\teval('$preview = \"'.$templates->get(\"modnotes\").'\";');\n\t\t\t\t$preview .= \"<br />\";\n\t\t\t\t\n\t\t\t\t$lang->modnotes = $temp;\n\t\t\t\t\n\t\t\t\t$mybb->input['action'] = \"editnote\";\n\t\t\t}\n\t\t}\n\t\t\n\t\tif($mybb->input['action'] == \"editnote\")\n\t\t{\n\t\t\t$note = $db->simple_select(\"modnotes\", \"*\", \"id='\".intval($mybb->input['id']).\"'\");\n\t\t\t$note = $note->fetch_array();\n\t\t\tif($mybb->usergroup['editmodnotes'] != 1 && !($mybb->usergroup['editownmodnotes'] == 1 && $mybb->user['uid'] == $note['mid'])) error_no_permission();\n\t\t\t\n\t\t\t$lang->load(\"modnotes\");\n\t\t\tif(!$note['id']) error($lang->modnotes_notfound);\n\t\t\t\n\t\t\t$user = get_user($note['uid']);\n\t\t\t\n\t\t\t$message = ($mybb->input['message'] ? $mybb->input['message'] : $note['note']);\n\t\t\t\n\t\t\trequire_once MYBB_ROOT.\"inc/functions_post.php\";\n\t\t\n\t\t\t$lang->load(\"editpost\");\n\t\t\tadd_breadcrumb($lang->mcp_nav_editprofile, \"modcp.php?action=editprofile&id=\".$note['id']);\n\t\t\tadd_breadcrumb($lang->modnotes_edit_modnote, \"modcp.php?action=editnote&id=\".$note['id']);\n\t\t\t\n\t\t\tif($mybb->settings['bbcodeinserter'] != 0 && $mybb->user['showcodebuttons'] != 0)\n\t\t\t{\n\t\t\t\t$codebuttons = build_mycode_inserter();\n\t\t\t\t$smilieinserter = build_clickable_smilies();\n\t\t\t}\n\t\t\t\n\t\t\t$lang->modnotes_user = $lang->sprintf($lang->modnotes_user_edit, build_profile_link(format_name($user['username'], $user['usergroup'], $user['displaygroup']), $user['uid']));\n\t\t\t$temp = $lang->modnotes_add_modnote;\n\t\t\t$temp2 = $lang->post_reply;\n\t\t\t$lang->post_reply = $lang->update_post;\n\t\t\t$lang->modnotes_add_modnote = $lang->modnotes_edit_modnote;\n\t\t\t$uid = $note['id'];\n\t\t\t\n\t\t\teval('$page = \"'.$templates->get(\"modnotes_modcp\").'\";');\n\t\t\t\n\t\t\t$lang->modnotes_add_modnote = $temp;\n\t\t\t$lang->post_reply = $temp2;\n\t\t\toutput_page($page);\n\t\t}\n\t\t\n\t\tif($mybb->input['action'] == \"do_addnote\")\n\t\t{\n\t\t\tif($mybb->usergroup['addmodnotes'] != 1) error_no_permission();\n\t\t\t\n\t\t\t$uid = intval($mybb->input['uid']);\n\t\t\t\n\t\t\t$user = get_user($mybb->input['uid']);\n\t\t\tif(!$user['uid'])\n\t\t\t{\n\t\t\t\terror($lang->invalid_user);\n\t\t\t}\n\t\t\n\t\t\t// Verify incoming POST request\n\t\t\tverify_post_check($mybb->input['my_post_key']);\n\t\t\t\n\t\t\t$lang->load(\"datahandler_post\");\n\t\t\t$lang->load(\"modnotes\");\n\t\t\t\n\t\t\t$message = trim_blank_chrs($mybb->input['message']);\n\t\t\t\n\t\t\tif(my_strlen($message) < $mybb->settings['minmessagelength'] && $mybb->settings['minmessagelength'] > 0)\n\t\t\t{\n\t\t\t\t$lang->postdata_message_too_short = $lang->sprintf($lang->postdata_message_too_short, $mybb->settings['minmessagelength']);\n\t\t\t\t$errors[] = $lang->postdata_message_too_short;\n\t\t\t}\n\t\t\t\n\t\t\tif(my_strlen($message) > $mybb->settings['maxmessagelength'] && $mybb->settings['maxmessagelength'] > 0)\n\t\t\t{\n\t\t\t\t$lang->postdata_message_too_long = $lang->sprintf($lang->postdata_message_too_long, $mybb->settings['maxmessagelength'], my_strlen($message));\n\t\t\t\t$errors[] = $lang->postdata_message_too_long;\n\t\t\t}\n\t\t\t\n\t\t\tif(count($errors) > 0)\n\t\t\t{\n\t\t\t\t$errors = inline_error($errors);\n\t\t\t\t$mybb->input['action'] = \"addnote\";\n\t\t\t}\n\t\t\telse if(!$mybb->input['previewpost'])\n\t\t\t{\n\t\t\t\t$insert = array(\n\t\t\t\t\t\t\t\"uid\" => $uid,\n\t\t\t\t\t\t\t\"mid\" => $mybb->user['uid'],\n\t\t\t\t\t\t\t\"note\" => $db->escape_string($message),\n\t\t\t\t\t\t\t\"dateline\" => TIME_NOW\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\n\t\t\t\t$db->insert_query(\"modnotes\", $insert);\n\t\t\t\tredirect(get_profile_link($uid), $lang->redirect_modnotes);\n\t\t\t}\n\t\t\t\n\t\t\tif($mybb->input['previewpost'] && my_strlen($message) > 0)\n\t\t\t{\n\t\t\t\trequire_once MYBB_ROOT.\"inc/class_parser.php\";\n\t\t\t\t$parser = new postParser;\n\t\t\t\t\n\t\t\t\t$parser_options = array(\n\t\t\t\t\t\t\"allow_html\" => 0,\n\t\t\t\t\t\t\"allow_mycode\" => 1,\n\t\t\t\t\t\t\"allow_smilies\" => 1,\n\t\t\t\t\t\t\"allow_imgcode\" => 1,\n\t\t\t\t\t\t\"allow_videocode\" => 1,\n\t\t\t\t\t\t\"me_username\" => $mybb->user['username'],\n\t\t\t\t\t\t\"filter_badwords\" => 1\n\t\t\t\t\t);\n\t\t\t\t$note = $parser->parse_message($message, $parser_options);\n\t\t\t\t\n\t\t\t\t$trow = \"trow1\";\n\t\t\t\t$username = \"<a href=\\\"{$mybb->settings['bburl']}/\".get_profile_link($mybb->user['uid']).\"\\\" title=\".my_date($mybb->settings['dateformat'], TIME_NOW).'&nbsp;'.my_date($mybb->settings['timeformat'], TIME_NOW).\"\\\">\".format_name($mybb->user['username'], $mybb->user['usergroup'], $mybb->user['displaygroup']).\"</a>\";\n\t\t\t\t\n\t\t\t\t$temp = $lang->modnotes;\n\t\t\t\t$lang->modnotes = $lang->modnotes_preview;\n\t\t\t\t\n\t\t\t\teval('$modnotes_notes .= \"'.$templates->get(\"modnotes_row\").'\";');\n\t\t\t\teval('$preview = \"'.$templates->get(\"modnotes\").'\";');\n\t\t\t\t$preview .= \"<br />\";\n\t\t\t\t\n\t\t\t\t$lang->modnotes = $temp;\n\t\t\t\t\n\t\t\t\t$mybb->input['action'] = \"addnote\";\n\t\t\t}\n\t\t}\n\t\t\n\t\tif($mybb->input['action'] != \"addnote\") return;\n\t\t\n\t\tif($mybb->usergroup['addmodnotes'] != 1) error_no_permission();\n\t\t\n\t\t$uid = intval($mybb->input['uid']);\n\t\t\n\t\t$user = get_user($mybb->input['uid']);\n\t\tif(!$user['uid'])\n\t\t{\n\t\t\terror($lang->invalid_user);\n\t\t}\n\t\t\n\t\trequire_once MYBB_ROOT.\"inc/functions_post.php\";\n\t\t\n\t\t$lang->load(\"modnotes\");\n\t\t$lang->load(\"newreply\");\n\t\tadd_breadcrumb($lang->mcp_nav_editprofile, \"modcp.php?action=editprofile&uid=\".$uid);\n\t\tadd_breadcrumb($lang->modnotes_add_modnote, \"modcp.php?action=addnote&uid=\".$uid);\n\t\t\n\t\tif($mybb->settings['bbcodeinserter'] != 0 && $mybb->user['showcodebuttons'] != 0)\n\t\t{\n\t\t\t$codebuttons = build_mycode_inserter();\n\t\t\t$smilieinserter = build_clickable_smilies();\n\t\t}\n\t\t\n\t\t$lang->modnotes_user = $lang->sprintf($lang->modnotes_user, build_profile_link(format_name($user['username'], $user['usergroup'], $user['displaygroup']), $user['uid']));\n\t\t\n\t\tmodnotes_display(true);\n\t\teval('$page = \"'.$templates->get(\"modnotes_modcp\").'\";');\n\t\toutput_page($page);\n\t}", "title": "" }, { "docid": "e24e0fcf619177713668f94fddd880c3", "score": "0.5017697", "text": "public function edit(Signature $signature)\n {\n //\n }", "title": "" }, { "docid": "217a7f8d239d9e2ba5d439d2629a6398", "score": "0.5010647", "text": "public function edit(Support $support)\n\n {\n\n //\n\n }", "title": "" }, { "docid": "7ceaea39390cf0f8c0f0fe62425d4c16", "score": "0.5010012", "text": "function update()\n\t{\n\t\tglobal $ilBench;\n\n\t\t$this->upload_source();\n\n\t\t$ilBench->start(\"Editor\",\"Paragraph_update\");\n\t\t// set language and characteristic\n\t\t\n\t\t$this->content_obj->setLanguage($_POST[\"par_language\"]);\n\t\t$this->content_obj->setCharacteristic($_POST[\"par_characteristic\"]);\n\n\t\t//echo \"PARupdate:\".htmlentities($this->content_obj->input2xml($_POST[\"par_content\"])).\":<br>\"; exit;\n\n\t\t \n\t\t// set language and characteristic\n\t\t$this->content_obj->setLanguage($_POST[\"par_language\"]);\n\t\t$this->content_obj->setSubCharacteristic($_POST[\"par_subcharacteristic\"]);\n\t\t$this->content_obj->setDownloadTitle(str_replace('\"', '', ilUtil::stripSlashes($_POST[\"par_downloadtitle\"])));\n\t\t$this->content_obj->setShowLineNumbers($_POST[\"par_showlinenumbers\"]?\"y\":\"n\");\n\t\t$this->content_obj->setAutoIndent($_POST[\"par_autoindent\"]?\"y\":\"n\");\n\t\t$this->content_obj->setSubCharacteristic($_POST[\"par_subcharacteristic\"]);\n\t\t\t$this->content_obj->setCharacteristic(\"Code\");\n\n\t\t$this->updated = $this->content_obj->setText(\n\t\t\t$this->content_obj->input2xml($_POST[\"par_content\"], 0, false));\n\n\t\tif ($this->updated !== true)\n\t\t{\n\t\t\t//echo \"Did not update!\";\n\t\t\t$ilBench->stop(\"Editor\",\"Paragraph_update\");\n\t\t\t$this->edit();\n\t\t\treturn;\n\t\t}\n\n\t\t$this->updated = $this->pg_obj->update();\n\n\t\t$ilBench->stop(\"Editor\",\"Paragraph_update\");\n\n\t\tif ($this->updated === true && $this->ctrl->getCmd () != \"upload\" )\n\t\t{\n\t\t\t$this->ctrl->returnToParent($this, \"jump\".$this->hier_id);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->edit();\n\t\t}\n\t}", "title": "" }, { "docid": "df2a7add8f460e7ab184db748dda3d47", "score": "0.5009876", "text": "function BeforeEdit(&$values, $where, &$oldvalues, &$keys, &$message, $inline, &$pageObject)\n{\n\n\t\t$values[\"pro_nombre\"] = mb_convert_case($values['pro_nombre'], MB_CASE_TITLE, 'UTF-8');\n\n// Place event code here.\n// Use \"Add Action\" button to add code snippets.\n\nreturn true;\n;\t\t\n}", "title": "" }, { "docid": "31b8362b4922394dad4ed126df283e5b", "score": "0.50090766", "text": "public function appendNotes(string $notes)\n {\n $date = date('n/j/y G:i:s');\n $callsign = Auth::check() ? Auth::user()->callsign : '(unknown)';\n $this->notes = \"$date $callsign: $notes\\n{$this->notes}\";\n }", "title": "" }, { "docid": "8f73063e755dcf0f3242578d9327eb29", "score": "0.5008201", "text": "function UpdatePageDescription($id,$actionToPerform = '') {\n $sirTrevorInput = $this->input->post('desc-content');\n $sirTrevorInput = str_replace(\"<p><br></p>\",\" \",$sirTrevorInput);\n if ($sirTrevorInput != \"\"){\n $converter = new Converter();\n $HTMLContent = $converter->toHtml($sirTrevorInput);\n } else {\n $HTMLContent = \"\";\n }\n //Update in User Table the Buisness Description where User ID is ------\n $contentdata = array(\n 'businessShortDescriptionJSON' => $sirTrevorInput,\n 'long_description' => $HTMLContent\n );\n if($actionToPerform != '' && !isCurrentUserAdmin($this)){\n $row = $this->db->from($this->tableName)->select('version')->where(\"id\", $id)->get()->row();\n $newVer = $row->version + 1;\n $whereVer = array(\n $this->listingField => $id,\n 'version' => $newVer\n );\n $row = $this->db->from($this->versionTable)->select('count(id) as Total, id')->where($whereVer)->get()->row();\n if($row->Total == 1){\n $this->db->where(\"id\", $row->id);\n $this->db->update($this->versionTable, $contentdata);\n }\n else {\n $result = $this->db->get_where($this->tableName, ['id'=>$id])->row();\n $listingField = $this->listingField;\n $result->$listingField = $result->id;\n unset($result->id);\n unset($result->is_new_ver);\n $result->businessShortDescriptionJSON = $contentdata['businessShortDescriptionJSON'];\n $result->long_description = $contentdata['long_description'];\n $result->version = $newVer;\n $this->db->insert($this->versionTable, $result);\n\n // set new version\n $this->db->where(\"id\", $id);\n $this->db->update($this->tableName, ['is_new_ver'=>'Yes']);\n }\n }else{\n $this->db->where(\"id\", $id);\n $this->db->update($this->tableName, $contentdata);\n }\n }", "title": "" }, { "docid": "690312fc5a39f97b8419a4b4fd631e1b", "score": "0.50031674", "text": "function add_payment_notes($product) {\n // TODO(eddavisson): What should we actually say here?\n $payment_notes = \"Google Checkout\";\n $this->add_if_not_empty('g:payment_notes', $payment_notes);\n }", "title": "" }, { "docid": "e73067a8f5b9e79d6667ad146041904d", "score": "0.50017095", "text": "function edit()\n {\n }", "title": "" }, { "docid": "e73067a8f5b9e79d6667ad146041904d", "score": "0.50017095", "text": "function edit()\n {\n }", "title": "" }, { "docid": "de914751ff7d083984057e9aa9374711", "score": "0.50015044", "text": "public function edit(Entry $entry)\n {\n //\n }", "title": "" }, { "docid": "9296dcdd30259943738c463ee717cb21", "score": "0.4996857", "text": "function UpdateAction()\n\t\t{\n\t\t\t//create new post model\n\t\t\t//update entry with new information\n\t\t}", "title": "" }, { "docid": "a5754c897ebcd16a23ff5f2cf6ddbac7", "score": "0.49959284", "text": "public function switchToVersion() {\n\t\t// Get version\n\t\t$version = $this->getSingleObject();\n\t\t\n\t\t// Get editor\n\t\t$editor = new ProjectEditor(Project::getProject($version->packageID));\n\t\t\n\t\t// Switch version\n\t\t$editor->switchVersion($version->getDecoratedObject());\n\t}", "title": "" }, { "docid": "921dc62e55f2c3ec32632bd2c7fbb23e", "score": "0.4995827", "text": "static function modify($params)\r\n {\r\n $exerciseId = $params->exercise;\r\n\r\n // Check if we are allowed to modify the exercise\r\n if (!ExerciseModel::isModifiable($exerciseId)) {\r\n $params = new stdClass();\r\n $params->error = \"You are not allowed to modify this exercise\";\r\n $params->message =\r\n '<a href=\"/\">Home</a>.';\r\n return self::error($params);\r\n }\r\n\r\n // modify/create question if the action has been selected\r\n if (isset($_POST['label']) and isset($_POST['minimumLength'])) {\r\n\r\n $label = $_POST['label'];\r\n $minimumLength = $_POST['minimumLength'];\r\n\r\n try {\r\n if (!isset($_POST['idQuestionToModify'])) {\r\n // new question : add it\r\n QuestionModel::createQuestion($exerciseId, $label, $minimumLength, $_POST['idAnswerType']);\r\n } else {\r\n // existing question : update it\r\n QuestionModel::updateQuestion(\r\n $_POST['idQuestionToModify'], $label, $minimumLength, $_POST['idAnswerType']\r\n );\r\n }\r\n } catch (Exception $exception) {\r\n $params = new stdClass();\r\n $params->error = \"Invalid inputs.\";\r\n $params->message = \"<a href='/exercise/$exerciseId/modify'>Go Back</a>\";\r\n return self::error($params);\r\n }\r\n\r\n // redirect to modify page, to avoid resending post at the refresh of the page\r\n header(\"Location: http://\" . $_SERVER['HTTP_HOST'] . \"/exercise/\" . $exerciseId . \"/modify\");\r\n exit();\r\n }\r\n\r\n\r\n // check if there is a question to modify\r\n $params->modifyQuestion = False;\r\n if (isset($params->question)) {\r\n $questionId = $params->question;\r\n $params->modifyQuestion = True;\r\n $params->questionToModify = QuestionModel::getQuestion($questionId);\r\n }\r\n\r\n $params->exercise = ExerciseModel::getExercise($exerciseId);\r\n $params->questions = ExerciseModel::getQuestions($exerciseId);\r\n $params->questionTypes = QuestionModel::getQuestionTypes();\r\n\r\n View::render(\"Exercise/Modify\", $params);\r\n }", "title": "" }, { "docid": "5504ac62d68d63842f52b621da578db4", "score": "0.4989274", "text": "function modnotes_usergroup_commit()\n\t{\n\t\tglobal $mybb, $db, $usergroup;\n\t\t\n\t\t$db->update_query(\"usergroups\", array(\"viewmodnotes\" => ($mybb->input['viewmodnotes'] == 1 ? 1 : 0),\n\t\t\t\t\t\t\t\t\t\t\"viewownmodnotes\" => ($mybb->input['viewownmodnotes'] == 1 ? 1 : 0),\n\t\t\t\t\t\t\t\t\t\t\"addmodnotes\" => ($mybb->input['addmodnotes'] == 1 ? 1 : 0),\n\t\t\t\t\t\t\t\t\t\t\"editmodnotes\" => ($mybb->input['editmodnotes'] == 1 ? 1 : 0),\n\t\t\t\t\t\t\t\t\t\t\"editownmodnotes\" => ($mybb->input['editownmodnotes'] == 1 ? 1 : 0)\n\t\t\t\t\t\t\t\t\t\t), \"gid='\".$usergroup['gid'].\"'\");\n\t}", "title": "" }, { "docid": "baab65ab566b403a0c018336039e220a", "score": "0.49863634", "text": "public function edit()\n {\n \n\t}", "title": "" }, { "docid": "6241688643a48518f4f8602ec76c1956", "score": "0.49853995", "text": "public function applyRevisionChange() {\n $this->callsMade[] = 'applyRevisionChange';\n }", "title": "" }, { "docid": "b8633bd8e712a13b0bce52b1b284c1af", "score": "0.49833062", "text": "public function editDescriptionAction() {\n //GET TEXT\n $text = $this->_getParam('text_string');\n\n //GET PHOTO ITEM\n $photo = Engine_Api::_()->core()->getSubject();\n // GET DB\n $db = Engine_Db_Table::getDefaultAdapter();\n $this->getDisplayPhotos();\n $db->beginTransaction();\n try {\n //SAVE VALUE\n $value['description'] = $text;\n $photo->setFromArray($value);\n $photo->save();\n $db->commit();\n } catch (Exception $e) {\n $db->rollBack();\n throw $e;\n }\n exit();\n }", "title": "" }, { "docid": "026bb22e98a4bede8b9068e02bbac0ca", "score": "0.49743846", "text": "public function updateReleaseNotes($target, $tagName, $notes)\n {\n $requestBody = [\n 'body' => $notes\n ];\n\n $res = $this->client->get(sprintf(\n self::GITHUB_RELEASE_GET_ENDPOINT,\n $this->cleanTarget($target),\n $tagName\n ), [\n 'auth' => [null, $this->token]\n ]);\n\n if ($release = json_decode((string) $res->getBody(), true)) {\n $tagId = $release['id'];\n } else {\n throw new \\LogicException('Tag ID not found!');\n }\n\n try {\n $res = $this->client->post(sprintf(\n self::GITHUB_RELEASE_UPDATE_ENDPOINT,\n $this->cleanTarget($target),\n $tagId\n ), [\n 'json' => $requestBody,\n 'auth' => [null, $this->token]\n ]);\n\n return $res->getStatusCode() === 201;\n } catch (\\Exception $e) {\n $this->logException($e);\n return false;\n }\n }", "title": "" }, { "docid": "b7972649285af6dfe207eed797c77603", "score": "0.49645403", "text": "function edit()\n{\n $modelManager = new ModelBackend();\n $modelManager->editPost(htmlspecialchars($_POST['newtitle']), strip_tags($_POST['newtext']), strip_tags($_POST['id']));\n header('location:adminIndex.php?p=posts&a=edit');\n}", "title": "" }, { "docid": "83d25949eee60af7f5e1c825e3c3bf81", "score": "0.49627045", "text": "abstract function edit();", "title": "" }, { "docid": "591b251a343e5b22ca396a0472c97969", "score": "0.495689", "text": "function acf_add_deprecated_action($deprecated, $version, $replacement)\n{\n}", "title": "" }, { "docid": "db5ebba48d67f77662b0ba96fa47e70a", "score": "0.4954353", "text": "abstract public function checkForUpdate(&$description);", "title": "" }, { "docid": "b73308f46bf7ee5499240d6f17bf0701", "score": "0.4949403", "text": "public function testUpdateOrderActivity()\n {\n }", "title": "" }, { "docid": "5ebde3b5fefebe1813a2859525bf191a", "score": "0.49406388", "text": "abstract protected function editItem(rex_developer_synchronizer_item $item);", "title": "" }, { "docid": "73dee46020a852067daf5e90cd56957a", "score": "0.49399468", "text": "public function edit()\n {\n }", "title": "" }, { "docid": "73dee46020a852067daf5e90cd56957a", "score": "0.49399468", "text": "public function edit()\n {\n }", "title": "" }, { "docid": "f3fac0727e3943c62c72439839273b20", "score": "0.4938877", "text": "public function ticketDescriptionSave(Request $request)\n {\n $requestData = $request->all();\n\n TicketNote::create($requestData+[\"user_id\"=>Auth::id()]);\n // return redirect('tickets')->with('success', 'TicketNote added!');\n $ticket = Ticket::find($request->ticket_id);\n $ticket->update(['status'=>2]);\n \n return redirect()->back()->with('success', 'TicketNote added!');\n }", "title": "" }, { "docid": "6794eeae42905dc469b78769610228ed", "score": "0.49365932", "text": "public function edit(EnquiredPackage $enquiredPackage)\n {\n //\n }", "title": "" }, { "docid": "efd5b89071979c16fb73f4299fc38452", "score": "0.4936504", "text": "public function edit()\n {\n\n }", "title": "" }, { "docid": "08c149a61ad74857a716684e2270ed43", "score": "0.49344727", "text": "public function updated(ToDo $toDo)\n {\n //\n }", "title": "" }, { "docid": "0a4b2fa54e61039d2f2b08a47752bfc7", "score": "0.49320906", "text": "function _project_release_edit_version_major_form($data) {\n drupal_add_js(drupal_get_path('module', 'project_release') .'/project_release.js', 'module', 'header', FALSE, TRUE, FALSE);\n $form = array();\n\n $node = $data['node'];\n unset($data['node']);\n\n $form['api'] = array(\n '#tree' => TRUE,\n );\n foreach ($data as $api_tid => $api_data) {\n $form['api'][$api_tid] = array(\n '#api_term_name' => $api_data['name'],\n 'major' => array(),\n );\n $recommended_version = -1;\n $recommended_options = array(-1 => t('None'));\n foreach ($api_data['majors'] as $major_version => $major_data) {\n if ($major_data['#recommended'] == TRUE) {\n $recommended_version = $major_version;\n }\n\n $recommended_options[$major_version] = $major_version;\n $form['api'][$api_tid]['major'][$major_version] = array(\n 'current' => array(\n '#type' => 'markup',\n '#value' => project_release_get_current_recommended($node->nid, $api_tid, $major_version)->version,\n ),\n 'supported' => array(\n '#type' => 'checkbox',\n '#title' => t('Supported'),\n '#default_value' => $major_data['#supported'],\n '#attributes' => array('class' => 'supported'),\n ),\n 'snapshot' => array(\n '#type' => 'checkbox',\n '#title' => t('Show snapshot release'),\n '#default_value' => $major_data['#snapshot'],\n '#attributes' => array('class' => 'snapshot'),\n ),\n 'version_name' => array(\n // Normally, form elements of #type 'hidden' are evil, since the\n // values can be easily tampered with. However, in this case, we\n // totally don't care: the values are all completely ignored by the\n // submit handler. We need these values sent on to the browser so\n // they can be hidden/show by project_release.js, so we need to use\n // 'hidden' here or the values are never sent to the browser.\n // @TODO: We could replace these with drupal JS settings.\n '#type' => 'hidden',\n '#value' => $version_name,\n '#attributes' => array('class' => 'version-name'),\n ),\n );\n }\n $form['api'][$api_tid]['recommended'] = array(\n '#title' => t('Recommended major version'),\n '#type' => 'select',\n '#options' => $recommended_options,\n '#default_value' => $recommended_version,\n '#prefix' => '<div class=\"container-inline\">',\n '#suffix' => '</div>',\n '#attributes' => array('class' => 'recommended'),\n );\n }\n return $form;\n}", "title": "" }, { "docid": "3e3c67514599d14e9846893df8217eb8", "score": "0.49300548", "text": "public function update($post)\n {\n $this->notes->edit($post['id'], $post['title'], $post['content']);\n\n return $this->redirect('/');\n }", "title": "" }, { "docid": "67efa526efb3ead4d1cfaecf4c987f93", "score": "0.4928788", "text": "function get_changelog_changes($changelog = '', $version = '')\n {\n }", "title": "" }, { "docid": "14f45b9c2fd10dfc5a2669b33935dd6f", "score": "0.49284655", "text": "function editName() {\n return 'EMR Journal Tracking';\n }", "title": "" }, { "docid": "f8d6c7536a18991e6ab798b38b022148", "score": "0.4925839", "text": "public function update($issueOptions, $posterOptions, $return_log = false)\r\n\t{\r\n\t\tglobal $smcFunc, $context;\r\n\t\t\r\n\t\t$event_data = array(\r\n\t\t\t'changes' => array(),\r\n\t\t);\r\n\t\r\n\t\t$issueUpdates = array();\r\n\r\n\t\tif (!empty($this->status['id']))\r\n\t\t\t$oldStatus = $context['issue_status'][$this->status['id']]['type'];\r\n\t\telse\r\n\t\t\t$oldStatus = '';\r\n\t\t\t\r\n\t\t// Which tracker it belonged to and will belong in future?\r\n\t\tif (!empty($this->tracker))\r\n\t\t\t$oldTracker = $context['issue_trackers'][$this->tracker['id']]['column_' . $oldStatus];\r\n\t\t\t\r\n\t\t// Make sure project exists always\r\n\t\tif (!isset($issueOptions['project']))\r\n\t\t\t$issueOptions['project'] = $this->project->id;\r\n\t\r\n\t\tif (isset($issueOptions['project']) && $issueOptions['project'] != $this->project->id)\r\n\t\t{\r\n\t\t\t$issueUpdates[] = 'id_project = {int:project}';\r\n\t\t\t$issueOptions['project'] = $issueOptions['project'];\r\n\t\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'project', $this->project->id, $issueOptions['project']\r\n\t\t\t);\r\n\t\t\t\r\n\t\t\t//\r\n\t\t\t$smcFunc['db_query']('', '\r\n\t\t\t\tUPDATE {db_prefix}project_timeline\r\n\t\t\t\tSET id_project = {int:project}\r\n\t\t\t\tWHERE id_issue = {int:issue}',\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'project' => $issueOptions['project'],\r\n\t\t\t\t\t'issue' => $this->id,\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\t}\r\n\t\r\n\t\tif (isset($issueOptions['private']) && $issueOptions['private'] != $this->is_private)\r\n\t\t{\r\n\t\t\t$issueUpdates[] = 'private_issue = {int:private}';\r\n\t\t\t$issueOptions['private'] = !empty($issueOptions['private']) ? 1 : 0;\r\n\t\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'view_status', $this->is_private ? 1 : 0, $issueOptions['private']\r\n\t\t\t);\r\n\t\t}\r\n\t\r\n\t\tif (!empty($issueOptions['title']) && $issueOptions['title'] != $this->name)\r\n\t\t{\r\n\t\t\t$issueUpdates[] = 'subject = {string:title}';\r\n\t\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'rename', $this->name, $issueOptions['title']\r\n\t\t\t);\r\n\t\t}\r\n\t\r\n\t\tif (!empty($issueOptions['status']) && $issueOptions['status'] != $this->status['id'])\r\n\t\t{\r\n\t\t\t$issueUpdates[] = 'status = {int:status}';\r\n\t\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'status', $this->status['id'], $issueOptions['status'],\r\n\t\t\t);\r\n\t\t}\r\n\t\r\n\t\tif (isset($issueOptions['assignee']) && $issueOptions['assignee'] != $this->assignee['id'])\r\n\t\t{\r\n\t\t\t$issueUpdates[] = 'id_assigned = {int:assignee}';\r\n\t\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'assign', $this->assignee['id'], $issueOptions['assignee'],\r\n\t\t\t);\r\n\t\t}\r\n\t\r\n\t\tif (!empty($issueOptions['priority']) && $issueOptions['priority'] != $this->priority_num)\r\n\t\t{\r\n\t\t\t$issueUpdates[] = 'priority = {int:priority}';\r\n\t\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'priority', $this->priority_num, $issueOptions['priority'],\r\n\t\t\t);\r\n\t\t}\r\n\t\t\r\n\t\t$oldVersions = array_merge(array_keys($this->versions), array_keys($this->versions_fixed));\r\n\t\t$newVersions = array();\r\n\t\r\n\t\tif (isset($issueOptions['versions']) && $issueOptions['versions'] != array_keys($this->versions))\r\n\t\t{\r\n\t\t\t$issueUpdates[] = 'versions = {string:versions}';\r\n\t\t\t\r\n\t\t\tif (empty($issueOptions['versions']))\r\n\t\t\t\t$issueOptions['versions'] = array(0);\r\n\t\t\r\n\t\t\t$newVersions = array_merge($newVersions, $issueOptions['versions']);\r\n\t\t\t$issueOptions['versions'] = implode(',', $issueOptions['versions']);\r\n\t\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'version', implode(',', array_keys($this->versions)), $issueOptions['versions'],\r\n\t\t\t);\r\n\t\t}\r\n\t\telse\r\n\t\t\t$newVersions = array_merge($newVersions, array_keys($this->versions));\r\n\t\r\n\t\tif (isset($issueOptions['versions_fixed']) && $issueOptions['versions_fixed'] != array_keys($this->versions_fixed))\r\n\t\t{\r\n\t\t\t$issueUpdates[] = 'versions_fixed = {string:versions_fixed}';\r\n\t\t\t\r\n\t\t\tif (empty($issueOptions['versions_fixed']))\r\n\t\t\t\t$issueOptions['versions_fixed'] = array(0);\r\n\t\t\r\n\t\t\t$newVersions = array_merge($newVersions, $issueOptions['versions_fixed']);\r\n\t\t\t$issueOptions['versions_fixed'] = implode(',', $issueOptions['versions_fixed']);\r\n\t\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'target_version', implode(',', array_keys($this->versions_fixed)), $issueOptions['versions_fixed'],\r\n\t\t\t);\r\n\t\t}\r\n\t\telse\r\n\t\t\t$newVersions = array_merge($newVersions, array_keys($this->versions_fixed));\r\n\t\r\n\t\tif (isset($issueOptions['event_first']))\r\n\t\t\t$issueUpdates[] = 'id_issue_event_first = {int:event_first}';\r\n\t\r\n\t\tif (isset($issueOptions['category']) && $issueOptions['category'] != $this->category['id'])\r\n\t\t{\r\n\t\t\t$issueUpdates[] = 'id_category = {int:category}';\r\n\t\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'category', $this->category['id'], $issueOptions['category'],\r\n\t\t\t);\r\n\t\t}\r\n\t\r\n\t\tif (!empty($issueOptions['tracker']) && $issueOptions['tracker'] != $this->tracker['id'])\r\n\t\t{\r\n\t\t\t$issueUpdates[] = 'id_tracker = {int:tracker}';\r\n\t\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'tracker', $this->tracker['id'], $issueOptions['tracker'],\r\n\t\t\t);\r\n\t\t}\r\n\t\r\n\t\tif (isset($issueOptions['details']))\r\n\t\t{\r\n\t\t\t$commentOptions = array('comment' => $issueOptions['details']);\r\n\t\t\tunset($issueOptions['details']);\r\n\t\t\t\r\n\t\t\tProjectTools_IssueTracker::modifyComment($this->details['id_comment'], $this->id, $commentOptions, $posterOptions);\r\n\t\t\t$event_data['changes'][] = array(\r\n\t\t\t\t'details', 'old', 'new',\r\n\t\t\t);\r\n\t\t}\r\n\t\r\n\t\tif (!empty($issueOptions['status']))\r\n\t\t\t$newStatus = $context['issue_status'][$issueOptions['status']]['type'];\r\n\t\telse\r\n\t\t\t$newStatus = $oldStatus;\r\n\t\r\n\t\tif (!isset($issueOptions['tracker']))\r\n\t\t\t$issueOptions['tracker'] = $this->tracker['id'];\r\n\t\r\n\t\t// Updates needed?\r\n\t\tif (empty($issueUpdates))\r\n\t\t\treturn !$return_log ? true : $event_data;\r\n\t\r\n\t\t$issueUpdates[] = 'updated = {int:time}';\r\n\t\t$issueOptions['time'] = time();\r\n\t\t$issueUpdates[] = 'id_updater = {int:updater}';\r\n\t\t$issueOptions['updater'] = $posterOptions['id'];\r\n\t\r\n\t\t$smcFunc['db_query']('', '\r\n\t\t\tUPDATE {db_prefix}issues\r\n\t\t\tSET\r\n\t\t\t\t' . implode(',\r\n\t\t\t\t', $issueUpdates) . '\r\n\t\t\tWHERE id_issue = {int:issue}',\r\n\t\t\tarray_merge($issueOptions ,array(\r\n\t\t\t\t'issue' => $this->id,\r\n\t\t\t))\r\n\t\t);\r\n\t\r\n\t\t// Update Issue Counts from project\r\n\t\t$projectUpdates = array();\r\n\t\r\n\t\t//\r\n\t\t$newTracker = $context['issue_trackers'][$issueOptions['tracker']]['column_' . $newStatus];\r\n\t\t\t\r\n\t\tif (!empty($issueOptions['tracker']) && ($issueOptions['tracker'] != $this->tracker['id'] || $oldStatus != $newStatus))\r\n\t\t{\r\n\t\t\tif (!empty($oldStatus) && !empty($this->tracker))\r\n\t\t\t\t$projectUpdates[$this->project->id][] = \"$oldTracker = $oldTracker - 1\";\r\n\t\r\n\t\t\t$projectUpdates[$issueOptions['project']][] = \"$newTracker = $newTracker + 1\";\r\n\t\t}\r\n\t\r\n\t\tif (!empty($projectUpdates))\r\n\t\t\tforeach ($projectUpdates as $id => $updates)\r\n\t\t\t\t$smcFunc['db_query']('', '\r\n\t\t\t\t\tUPDATE {db_prefix}projects\r\n\t\t\t\t\tSET\r\n\t\t\t\t\t\t' . implode(',\r\n\t\t\t\t\t\t', $updates) . '\r\n\t\t\t\t\tWHERE id_project = {int:project}',\r\n\t\t\t\t\tarray(\r\n\t\t\t\t\t\t'project' => $id,\r\n\t\t\t\t\t)\r\n\t\t\t\t);\r\n\t\t\t\t\r\n\t\t// If tracker hasn't changed remove values that doesn't need to be changed\r\n\t\tif (isset($oldTracker) && $oldTracker == $newTracker)\r\n\t\t{\r\n\t\t\t$oldVersions = array_diff($oldVersions, $newVersions);\r\n\t\t\t$newVersions = array_diff($newVersions, $oldVersions);\r\n\t\t}\r\n\t\t\t\t\r\n\t\t// Update issue counts in versions\r\n\t\tif (isset($oldTracker) && !empty($oldVersions))\r\n\t\t\t$smcFunc['db_query']('', '\r\n\t\t\t\tUPDATE {db_prefix}project_versions\r\n\t\t\t\tSET {raw:tracker} = {raw:tracker} - 1\r\n\t\t\t\tWHERE id_version IN({array_int:versions})',\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'tracker' => $oldTracker,\r\n\t\t\t\t\t'versions' => $oldVersions,\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\tif (!empty($newVersions))\r\n\t\t\t$smcFunc['db_query']('', '\r\n\t\t\t\tUPDATE {db_prefix}project_versions\r\n\t\t\t\tSET {raw:tracker} = {raw:tracker} + 1\r\n\t\t\t\tWHERE id_version IN({array_int:versions})',\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'tracker' => $newTracker,\r\n\t\t\t\t\t'versions' => $newVersions,\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\t\t\r\n\t\t// Refresh data (for ajax!)\r\n\t\t$this->loadIssue();\r\n\t\r\n\t\tif ($return_log)\r\n\t\t\treturn $event_data;\r\n\t\r\n\t\tif (empty($issueOptions['no_log']))\r\n\t\t{\r\n\t\t\t$id_issue_event = ProjectTools_IssueTracker::createIssueEvent($this->id, 0, $posterOptions, $event_data);\r\n\t\t\t$id_event = createTimelineEvent($this->id, $issueOptions['project'], 'update_issue', array('subject' => isset($issueOptions['subject']) ? $issueOptions['subject'] : $this->name), $posterOptions, $issueOptions);\r\n\t\t\t\r\n\t\t\t$smcFunc['db_query']('', '\r\n\t\t\t\tUPDATE {db_prefix}issue_events\r\n\t\t\t\tSET id_event = {int:event}\r\n\t\t\t\tWHERE id_issue_event = {int:issue_event}',\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'issue_event' => $id_issue_event,\r\n\t\t\t\t\t'event' => $id_event\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\t\t\r\n\t\t\treturn $id_issue_event;\r\n\t\t}\r\n\t\t\r\n\t\treturn true;\r\n\t}", "title": "" }, { "docid": "638a907462da36032c3f48ee70de1920", "score": "0.49226657", "text": "public function modifiedPost()\n {\n $toCheck = ['id','title','author', 'contents'];\n\n if ( Utils::checkArray($_POST, $toCheck) ){\n\n $_SESSION['message'] = 'Your comment has been modified';\n\n $this->postManager->update( $post = new Post($_POST) );\n header('Location: /admin/managePost');\n exit;\n\n } else {\n $this->template('Errors/404');\n } \n }", "title": "" }, { "docid": "b76ecd116d0eae85b8f12bcc87b5eacf", "score": "0.49188435", "text": "function update($parent)\n\t{\n\t\techo '<p>'.JText::sprintf('COM_JEXBOOKING_UPDATE_TEXT', $parent->get('manifest')->version).'</p>';\n\t}", "title": "" }, { "docid": "c28027feda5c11615dcf472d6af3f96c", "score": "0.49089554", "text": "public function edit()\n {\n //\n }", "title": "" }, { "docid": "c28027feda5c11615dcf472d6af3f96c", "score": "0.49089554", "text": "public function edit()\n {\n //\n }", "title": "" }, { "docid": "c28027feda5c11615dcf472d6af3f96c", "score": "0.49089554", "text": "public function edit()\n {\n //\n }", "title": "" }, { "docid": "c28027feda5c11615dcf472d6af3f96c", "score": "0.49089554", "text": "public function edit()\n {\n //\n }", "title": "" }, { "docid": "cd149e8fa4f3ccb492e74aed4c8e63f3", "score": "0.49053538", "text": "protected function confirm_edit()\n\t{\n\t\t$msg = 'Successfully modified project ' . $this->fields['Title'];\n\t\treturn '<font color=\"green\">' . $msg . '</font><br>';\n\n\t}", "title": "" }, { "docid": "ad8b71732482f648a132d94087816991", "score": "0.49014404", "text": "public function edit(FingerPrint $fingerPrint)\n {\n //\n }", "title": "" }, { "docid": "251a399eca980cdd22b12cd986827099", "score": "0.4897332", "text": "public function addDebugNote($debugNote);", "title": "" }, { "docid": "71c493ec35cb22ad276aefce2854126a", "score": "0.48967078", "text": "public function edit(AnnouncementComment $announcementComment)\n {\n //\n }", "title": "" } ]
31f11681897f874960bcb53c61b62740
Handle Ajax call for deleting Product.
[ { "docid": "d2e728b98f3a88c406eeb9f0a31088d8", "score": "0.7260397", "text": "public function deleteAjaxAction(Request $request){\n try {\n $ids = array();\n $em = $this->getDoctrine()->getManager();\n foreach($request->request->all() as $req){\n $product = $this->getDoctrine()->getRepository('MorusAcceticBundle:Product')->findOneById($req);\n $em->remove($product);\n }\n $em->flush();\n \n return new Response(json_encode(array(\n \"success\" => true\n )));\n } catch (Exception $ex) {\n return new Response(json_encode(array(\n \"success\" => false\n )));\n }\n }", "title": "" } ]
[ { "docid": "bce702eb0b30bc1764e8f3648d1cd9b4", "score": "0.804236", "text": "public function ajaxDeleteProduct(Request $request) {\n if ($request->ajax() && $request->isMethod('DELETE')) {\n\n }\n }", "title": "" }, { "docid": "4eeec5c596ae8152aaa2a9a05c054884", "score": "0.76958185", "text": "function ajaxDelete() {\n\n\t\t// Check authorization, abort if negative\n\t\t$this->isAuthorized() or $this->abortUnauthorized();\n\n\t\t$model = $this->getDefaultModel();\n\n\t\t$ids = KRequest::getInt('id');\n\n\t\t// Legacy param name\n\t\tif (!$ids) {\n\t\t\t$ids = KRequest::getInt('cid');\n\t\t}\n\n\t\t$success = $model->delete($ids);\n\n\t\t$response = new stdClass();\n\t\tif ($success) {\n\t\t\t$response->success = true;\n\t\t\t$response->errors = array();\n\t\t}\n\t\telse {\n\t\t\t$response->success = false;\n\t\t\t$response->errors = $model->getErrors();\n\t\t}\n\n\t\t// Purge the cache\n\t\t$this->purgeCache();\n\n\t\techo json_encode($response);\n\n\t\t// For now, Magento puts in some JS code for some reason\n\t\tdie();\n\n\t}", "title": "" }, { "docid": "7c141bc70cdc3bc298c595bd00a3ca76", "score": "0.75800323", "text": "public function ajaxDeleteAction()\r\n\t{\r\n\r\n\t\t$result = $this->_model->ajaxDelete($this->_arrParam);\r\n\t\techo json_encode($result);\r\n\t}", "title": "" }, { "docid": "78fffcb757c69e4603aec7c36a62e09a", "score": "0.7571372", "text": "public function delete()\n {\n $this->isAuthenticated();\n $this->authToken->isRequestLimitExceeded();\n $this->authToken->logRequest(1);\n\n //get the id from the user\n $data = $_POST;\n //set the id\n $this->product->id = array_values($data)[0];\n\n if ($this->product->delete()) {\n // set response code - 200 ok\n http_response_code(200);\n echo json_encode(array(\"message\" => \"Product was deleted.\"));\n }\n\n // if unable to update the product\n else {\n\n // set response code - 503 service unavailable\n http_response_code(503);\n echo json_encode(array(\"message\" => \"Unable to delete.\"));\n }\n }", "title": "" }, { "docid": "c44e295b106a1cf251918bbc24429e29", "score": "0.75025475", "text": "public function delete()\n {\n // get request\n $request = $this->getRequest()->request;\n // get product ID from request\n $product_id = $request['a'];\n // get product ids from session\n $compareProducts = $this->View()->getSession('compare', $compareProducts)?$this->View()->getSession('compare', $compareProducts):array();\n\n if (in_array($product_id, $compareProducts)) {\n // unseting product from compare session\n $key = array_search($product_id, $compareProducts);\n unset($compareProducts[$key]);\n }\n\n $this->View()->setSession('compare', $compareProducts);\n\n if ($request['XHR']) {\n die(json_encode([\n 'success' => true,\n 'message' => $this->View()->translating('compare_item_deleted'),\n 'count' => count($compareProducts),\n ]));\n }\n\n Router::redirect('compare');\n }", "title": "" }, { "docid": "19d095700333a7d37fb92a80efc91327", "score": "0.7398623", "text": "public function deleteCart() {\n if (Request::ajax()) {\n //return \"ajax\";\n $product_id = Input::get('id');\n Cart::remove($product_id);\n return true;\n } else {\n \n }\n }", "title": "" }, { "docid": "ab43f897fda382febf6ec364da01492c", "score": "0.7339309", "text": "public function destroy(Request $request)\n {\n if ($request->ajax()) {\n $product_id = $request->product_id;\n $product = Product::find($product_id);\n if ($product) {\n $product->delete();\n return response([\n 'success' => 'Product deleted Succesfully',\n ], Response::HTTP_OK);\n } else {\n return response(['warning' => 'Product not deleted',\n ], Response::HTTP_OK);\n }\n }\n }", "title": "" }, { "docid": "f95f09d5b5821adc41fdf62008089f1f", "score": "0.7334443", "text": "public function ajaxRemoveProduct()\n\t{\n\n\t\t$modelUserCart = $this->getModel('usercart');\n\t\t$userId = $this->_getUserId();\n\n\t\t$jinput = JFactory::getApplication()->input;\n\t\t$produktID = $jinput->get('produktID');\n\t\t$quantity = $jinput->get('quantity');\n\t\t$produktEigenschaft = $jinput->get('produktEigenschaft');\n\n\t\tif (!JSession::checkToken('get'))\n\t\t{\n\n\t\t\techo new JResponseJson(null, JText::_('JINVALID_TOKEN'), true);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$modelUserCart->removeProductFromCard($userId, $quantity, $produktID,$produktEigenschaft);\n\t\t\tparent::display();\n\t\t}\n\t}", "title": "" }, { "docid": "6a322b72daec8f831264063c28a93f33", "score": "0.73341125", "text": "public function delete_ajax_tag(Request $request)\n {\n //die($request);\n // echo '<pre>';print_r($_POST);die();\n $result = 0;\n $productTag = ProductTag::where('id','=', $request->tag_id)->first(); \n $product_tag = ProductTag::find($productTag->id); \n \n if($product_tag->delete()){\n $result = 1;\n }\n\n return response()->json(['success'=> $result]);\n }", "title": "" }, { "docid": "c6f76206485e4003689f1256e7bd8d9b", "score": "0.7308791", "text": "public function postDelete()\n\t{\n\t\t$id = '';\n\t\tif (Request::has('pwp_ids')) {\n\t\t\t$id = Request::input('pwp_ids');\n\t\t} elseif (Request::has('id')) {\n\t\t\t$id = Request::input('id');\n\t\t}\n\n\t\tif (is_numeric($id) || is_array($id)) {\n\t\t\tPwpProduct::destroy($id);\n\t\t\tSession::flash('success', 'The pwp product has been deleted successfully');\n\t\t\treturn new JsonResponse(['success' => 'TRUE']);\n\t\t}\n\t\tSession::flash('error', 'The pwp product has not been deleted. Please correct the errors');\n\t\treturn new JsonResponse(['error' => ['Invalid data posting']], 422);\n\t}", "title": "" }, { "docid": "12f35267d7d1089fb9231bd8ccb8f7d2", "score": "0.7236077", "text": "public function deleteProduct(Request $request)\n {\n if ($request->ajax()) {\n $websiteId = $request->get('website_id');\n $website = Website::find($websiteId);\n \\Artisan::call('delete:product', [\n 'domain' => $website->protocol . $website->domain,\n ]);\n return ['status' => true];\n }\n\n return redirect('/home');\n }", "title": "" }, { "docid": "0c339660d063425e48c5eb86883b5415", "score": "0.7190807", "text": "public function ajaxEliminarFotoProducto(){\n\n $idPedido = $this->idPedido;\n $idDetallePedido = $this->idProducto;\n $campoFotografia = $this->campoFoto;\n $imagen = $this->fotoSubida;\n\n $eliminarFoto = ControladorPedidos::ctrEliminarFotoProducto($idPedido, $idDetallePedido, $campoFotografia, $imagen);\n\n echo $eliminarFoto;\n\n }", "title": "" }, { "docid": "03f0f4e5dfaea23ed8889d7db3193e22", "score": "0.7182507", "text": "public function actionDeleteProduct()\n {\n $order = Order::model()->findByPk(Yii::app()->request->getPost('order_id'));\n\n if (!$order)\n $this->error404(Yii::t('CartModule.admin', 'ORDER_NOT_FOUND'));\n\n if ($order->is_deleted)\n throw new CHttpException(404, Yii::t('CartModule.admin', 'ORDER_ISDELETED'));\n\n $order->deleteProduct(Yii::app()->request->getPost('id'));\n }", "title": "" }, { "docid": "e6fdedc639a241bcce9b76813a025842", "score": "0.717417", "text": "static public function ctrDeleteProduct(){\n\n\t\t\t\t\n\n\t\t\tif(isset($_GET[\"idProducto\"])){\n\n\t\t\t\t\t$tabla =\"productos\";\n\t\t\t\t\t$datos = $_GET[\"idProducto\"];\n\n\t\t\t\t\tif($_GET[\"imagen\"] != \"\" && $_GET[\"imagen\"] != \"views/img/products/default/productos.png\"){\n\n\t\t\t\t\t\tunlink($_GET[\"imagen\"]);\n\t\t\t\t\t\trmdir('views/img/products'.$_GET[\"codigo\"]);\n\n\t\t\t\t\t}\n\n\t\t\t\t\t$respuesta = ModelProducts::mdlDeleteProduct($tabla, $datos);\n\n\t\t\t\t\tif($respuesta == \"ok\"){\n\n\t\t\t\t\t\techo'<script>\n\n\t\t\t\t\t\tswal({\n\t\t\t\t\t\t\ttype: \"success\",\n\t\t\t\t\t\t\ttitle: \"El producto ha sido borrado correctamente\",\n\t\t\t\t\t\t\tshowConfirmButton: true,\n\t\t\t\t\t\t\tconfirmButtonText: \"Cerrar\"\n\t\t\t\t\t\t\t}).then(function(result){\n\t\t\t\t\t\t\t\t\t\tif (result.value) {\n\n\t\t\t\t\t\t\t\t\t\twindow.location = \"productos\";\n\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t})\n\n\t\t\t\t\t\t</script>';\n\n\t\t\t\t\t}\t\n\t\t\t}\t\t\n\t\t}", "title": "" }, { "docid": "936f11bc0b8c8229ea7c0aec4cab6c59", "score": "0.716834", "text": "public function delete_ajax_item(Request $request)\n {\n //die($request);\n //echo '<pre>';print_r($_POST);die();\n $result = 0;\n /*$productItem = ProductAttribute::where('id','=', $request['item_id'])->first(); \n echo '<pre>';print_r($productItem);die();*/\n $product_item = ProductAttribute::find($request['item_id']); \n // echo '<pre>';print_r($product_item);die();\n if($product_item->delete()){\n $result = 1;\n }\n\n return response()->json(['success'=> $result]);\n }", "title": "" }, { "docid": "78a0cc133630c8e9b3d2702537e1c21a", "score": "0.71377325", "text": "public function delete(){\n $this->product->id = $_GET['delete_id'];\n\n // delete the product\n if($this->product->delete()){\n echo \"<div class=\\\"alert alert-success alert-dismissable\\\">\";\n echo \"<button type=\\\"button\\\" class=\\\"close\\\" data-dismiss=\\\"alert\\\" aria-hidden=\\\"true\\\">&times;</button>\";\n echo \"Object was deleted.\";\n echo \"</div>\";\n }\n\n // if unable to delete the product\n else{\n echo \"<div class=\\\"alert alert-danger alert-dismissable\\\">\";\n echo \"<button type=\\\"button\\\" class=\\\"close\\\" data-dismiss=\\\"alert\\\" aria-hidden=\\\"true\\\">&times;</button>\";\n echo \"Unable to delete object.\";\n echo \"</div>\";\n }\n }", "title": "" }, { "docid": "5d728c9a4a49a4e828f6c518391ab99d", "score": "0.7125739", "text": "protected function processDeleteRequest()\n {\n $this->ajaxDie(json_encode([\n 'success' => true,\n 'operation' => 'delete'\n ]));\n }", "title": "" }, { "docid": "8a783538fef0fbb1810da3f6e77b1deb", "score": "0.7117456", "text": "public function products_delete($param = null)\r\n {\r\n if (isset($_POST[\"pro_id\"]) && !empty($_POST[\"pro_id\"])) {\r\n $action = $_POST[\"pro_id\"];\r\n $delete = Product::find($action)->delete();\r\n $total = Product::count();\r\n echo json_encode([\"total\" => $total, \"isDeleted\" => $delete]);\r\n\r\n } else {\r\n echo json_encode([\"error\" => \"ERROR\"]);\r\n }\r\n }", "title": "" }, { "docid": "0a18d1118318727a5dfb482a5b023e84", "score": "0.7094297", "text": "public static function deleteProduct() {\n $result = array();\n $deleted = lC_Products_Admin::delete($_GET['pid'], $_GET['categories']);\n if ($deleted) {\n $result['rpcStatus'] = RPC_STATUS_SUCCESS;\n }\n\n echo json_encode($result);\n }", "title": "" }, { "docid": "c58e1dafa01bec03ff7c4cf90590884f", "score": "0.70258844", "text": "public function deleteProduct(){\n if($_POST['action'] != 'deleteProduct'){\n echo json_encode(['success' => false]);\n return false;\n }\n $model = parent::model('UpdateProductModel');\n $id = $_POST['id'];\n $name = $model->getProductById($id)->name;\n $deleteProduct = $model->deleteProduct($id);\n // var_dump($deleteProduct);die;\n if(!$deleteProduct){\n $deleteStatus = $model->deleteProductStatus($id);\n if($deleteStatus){\n echo json_encode([\n 'id' => $id,\n 'name' => $name,\n 'action' => 'updateStatus',\n 'success' => true,\n 'message' => \"Product name have include in bill, CAN'T DELETE PERMANENTLY, DataBase have updated 'PRODUCT STATUS' to DELETED ( not able to use anymore )\"\n ]);\n }else{\n echo json_encode([\n 'action' => 'updateStatus',\n 'success' => false,\n 'message' => \"there is an error, can't not update status deleted !\"\n ]);\n }\n }else{\n echo json_encode([\n 'id' => $id,\n 'name' => $name,\n 'action' => 'deletePermanently',\n 'success' => true\n ]);\n\n }\n \n }", "title": "" }, { "docid": "b144c5584782ae7ee64c8fc01f6b1d62", "score": "0.702151", "text": "public function deleteajaxAction() {\n $request = $this->get('request');\n if ($request->isXmlHttpRequest() && $request->getMethod() == 'POST') {\n $id = $request->request->get('id');\n $user_security = $this->container->get('security.context');\n // authenticated REMEMBERED, FULLY will imply REMEMBERED (NON anonymous)\n if (!$user_security->isGranted('IS_AUTHENTICATED_FULLY')) {\n \n }\n $user_id = $this->getuserid();\n if (!isset($user_id)) {\n $array['mystatus'] = \"false\";\n /* throw $this->createNotFoundException('Unable to find Changements entity.');*/\n $response = new Response(json_encode($array));\n $response->headers->set('Content-Type', 'application/json');\n return $response;\n }\n $em = $this->getDoctrine()->getManager();\n $entity = $em->getRepository('ApplicationCalendarBundle:CalendarCategories')->find($id);\n if (!$entity) {\n /* throw $this->createNotFoundException('Unable to find CalendarCategories entity.');*/\n $array['mystatus'] = \"notremoved\";\n $response = new Response(json_encode($array));\n $response->headers->set('Content-Type', 'application/json');\n return $response;\n }\n $array['mystatus'] = \"removed\";\n $em->remove($entity);\n $em->flush();\n $response = new Response(json_encode($array));\n $response->headers->set('Content-Type', 'application/json');\n return $response;\n }\n }", "title": "" }, { "docid": "43d5cf46777043ace0909cf679ddab59", "score": "0.69857645", "text": "public function delete() {\n if (!$this->customer->isLogged()) {\n die();\n }\n $product_id = $this->request->post['product_id'];\n $this->load->model('catalog/product');\n\n $this->model_catalog_product->deleteProduct($product_id);\n\n echo \"ok\";\n exit();\n\n }", "title": "" }, { "docid": "dd43fdb7b15c07492d9a2a8a4904d9ed", "score": "0.6982957", "text": "public function delete()\n {\n if ($_SERVER['REQUEST_METHOD'] === 'POST') {\n $id = $_POST['id'];\n $pictureManager = new PictureManager();\n $pictureManager->delete($id);\n $productManager = new ProductManager();\n $productManager->delete($id);\n header('location: /adminProduct/list');\n }\n }", "title": "" }, { "docid": "55771164021cca9909497392c896fdbb", "score": "0.6970485", "text": "public function deleteAction() {\r\n $id = (int) $this->getRequest()->getParam('id');\r\n if ($id) {\r\n try {\r\n $this->_getCart()->removeItem($id)\r\n ->save();\r\n } catch (Exception $e) {\r\n $_response = Mage::getModel('ajaxcart/response');\r\n $_response->setError(true);\r\n $_response->setMessage($this->__('Cannot remove the item.'));\r\n $_response->send();\r\n\r\n Mage::logException($e);\r\n }\r\n }\r\n\r\n $_response = Mage::getModel('ajaxcart/response');\r\n\r\n $_response->setMessage($this->__('Item was removed.'));\r\n\r\n //append updated blocks\r\n $this->getLayout()->getUpdate()->addHandle('ajaxcart');\r\n $this->loadLayout();\r\n\r\n $_response->addUpdatedBlocks($_response);\r\n\r\n $_response->send();\r\n }", "title": "" }, { "docid": "3924bc85d44e0342c336ffc7175c1ff1", "score": "0.693375", "text": "Public function delete() {\n// echo $_POST['_action'];\n // die($this->util_model->printr($_POST));\n $result = $this->ajax_model->delete($_POST);\n // $this->util_model->printr($result);\n echo json_encode(array('success' => $result[0], '_err_msg' => mysql_real_escape_string(isset($result[1])) ? $result[1] : ''));\n }", "title": "" }, { "docid": "578f637f76c54237e6f7cb6ee6afaa86", "score": "0.6929988", "text": "public function actionDeleteProduct()\n\t{\n\t\t$model = OrderProduct::model()->findByPk($_POST['product_id']);\n\t\tif($model)\n\t\t\t$model->delete();\n\t}", "title": "" }, { "docid": "d33aeb7d2785dd57f734dbbf910b9fc3", "score": "0.69143265", "text": "public function ajaxDeleteAction() { \n $request = $this->getRequest();\n $response = $this->getResponse();\n if ($request->isPost()) {\n $list = $request->getPost('list');\n if (is_array($list) && count($list) > 0) {\n foreach($list as $id_shopping_list) {\n $this->getShoppingListTable()->deleteShoppingList($id_shopping_list);\n }\n $t_return[\"result\"] = \"OK\";\n } else {\n $t_return[\"result\"] = \"KO_LIST\";\n }\n $response->setContent(\\Zend\\Json\\Json::encode($t_return));\n }\n return $response;\n }", "title": "" }, { "docid": "1fdb80f3f85739e3c699ff72d14396f1", "score": "0.6890168", "text": "public function ajaxDeleteProductTempImg(Request $request) {\n\n //Only accept ajax request\n if ($request->ajax()) {\n\n try {\n\n $this->_deleteProductTempImg($request);\n\n } catch (Exception $ex) {\n return pong(0, _t('opp'), 500);\n }\n\n return pong(1, _t('saved_info'));\n }\n }", "title": "" }, { "docid": "1982a221e3b562d52809d7a83e34e293", "score": "0.6868909", "text": "public function delete_product() {\n\t\t$values=array(\"rstatus\"=>\"C\");\n\t\t$rowIndex = $_POST['row_index'];\n\t\t$where =array(\"id\"=>$_POST['product_id']);\n\t\tif($this->update(\"products\",$values,$where)) {\t\t\t\n\t\t\techo '{\"masterItemsList\":{\"updateFlag\":\"void\",\"rowIndex\":'.$rowIndex.'}}';\n\t\t}\n\t\telse\n\t\t\techo 'Error while deleting';\n\t}", "title": "" }, { "docid": "742c82729255be552c9b2e7fb5e1bb97", "score": "0.6849968", "text": "public function delete_product(){\r\n\t\tif ($this->checkLogin('A') == ''){\r\n\t\t\tredirect('admin');\r\n\t\t}else {\r\n\t\t\t$product_id = $this->uri->segment(4,0);\r\n\t\t\t$condition = array('id' => $product_id);\r\n\t\t\t$old_product_details = $this->product_model->get_all_details(PRODUCT,array('id'=>$product_id));\r\n\t\t\t$this->update_old_list_values($product_id,array(),$old_product_details);\r\n\t\t\t$this->update_user_product_count($old_product_details);\r\n\t\t\t$this->product_model->commonDelete(PRODUCT,$condition);\r\n\t\t\t$this->setErrorMessage('success','Product deleted successfully');\r\n\t\t\tredirect('admin/product/display_product_list');\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "270350233f9c343949f4195b556772ad", "score": "0.68358237", "text": "public function delete(Request $request)\n {\n //\n if($request->ajax())\n { \n $orden = OrdenTrabajo::findOrFail($request->orden_number);\n\n $orden->delete();\n\n $ot = OrdenTrabajoProducto::where('ot_producto_orden_trabajo',$request->orden_number)->findOrFail();\n\n $ot->delete();\n\n //respuesta al cliente\n return response()->json([\n \"ok\"\n ]);\n }\n }", "title": "" }, { "docid": "97532dbb8e7cd1fdee4c8e0cce6c308c", "score": "0.68264294", "text": "public function removeProduct(Request $request)\n {\n $cart = $this->cartRepository->getCart();\n\n $query = $this->cartRepository->removeProduct($request->product_id, $cart->id);\n\n if ($request->ajax()) {\n\n if ($query)\n return 'true';\n\n return 'false';\n }\n\n return redirect()->back();\n }", "title": "" }, { "docid": "394e99878fb549d6e0585cb7f9217250", "score": "0.67854506", "text": "public function ajaxDeleteOneProductImg(Request $request) {\n //Only accept ajax request\n if ($request->ajax() && $request->isMethod('POST')) {\n\n if (store() === null) {\n return pong(0, _t('not_found'), 404);\n }\n\n $store = store();\n $productId = (int) $request->get('product_id');\n $image = $request->get('img_name');\n $number = $request->get('number');\n $product = $store->products->find($productId);\n \n if ($product === null) {\n return pong(0, _t('not_found'), 404);\n }\n \n try {\n $product->toImage();\n $imageProper = 'image_' . $number;\n $images = $product->$imageProper;\n $allImages = $product->images;\n\n if ($images !== null && $images->thumb === $image) {\n $productPath = config('front.product_path') . $store->id . '/';\n foreach($images as $one) {\n delete_file($productPath . $one);\n }\n unset($allImages[$number - 1]);\n }\n \n $product->images = $allImages->toJson();\n $product->save();\n \n } catch (Exception $ex) {\n return pong(0, _t('opp'), 500);\n }\n\n return pong(1, _t('saved_info'));\n }\n }", "title": "" }, { "docid": "3637f47c78b2d26f5db162f9856f686f", "score": "0.67773116", "text": "function deleteProduct()\n\t{\n\t\t$id=(int)$_GET['prodid'];\n\t\t\n\t\t$sql='delete from products_table where product_id ='.$id;\n\t\t\n\t\t$obj=new Bin_Query();\n\t\t\n\t\tif($obj->updateQuery($sql))\n\t\t{\t\n\t\t\treturn '<div class=\"success_msgbox\">Product Deleted Successfully</div>';\t\n\t\t}\t\n\t}", "title": "" }, { "docid": "a4cad381088af2b577c16ea3e4fa1fed", "score": "0.6770752", "text": "public function product_delete()\n\t\t\t\t{\n\t\t\t\t}", "title": "" }, { "docid": "b7d4a6e8e52ff3fb161c7d4919463f20", "score": "0.6764739", "text": "public function delete_product()\n {\n\t $product_id = (int)$this->uri->segment(4);\n\t //dump($product_id);\n\t \n\t $query = $this->Product_model->delete_product($product_id);\n\t if($query){\n\t\t \n\t\t redirect('admin/Dashboard/product');\n\t\t \n\t } else {\n\t\t\t \n\t\t echo 'error';\n\t\t\t \n\t }\t \n\t \n }", "title": "" }, { "docid": "0e75fd3e120afa0399e0ed894acc9d33", "score": "0.676294", "text": "public function deleteProductAction()\n {\n $id = $_GET['id'];\n $productManager = new ProductManager();\n $productManager->deleteProduct($id);\n header('Location: index.php?section=admin&page=adminproducts');\n }", "title": "" }, { "docid": "63adf4fefe8cea6351d17e64446ce763", "score": "0.67467666", "text": "public function remove()\n\t{\n // if(!in_array('deleteDisease', $this->permission)) {\n // redirect('dashboard', 'refresh');\n // }\n\n $product_id = $this->input->post('product_id');\n\n $response = array();\n if($product_id) {\n $delete = $this->model_disease->remove($product_id);\n if($delete == true) {\n $response['success'] = true;\n $response['messages'] = \"Successfully removed\";\n }\n else {\n $response['success'] = false;\n $response['messages'] = \"Error in the database while removing the product information\";\n }\n }\n else {\n $response['success'] = false;\n $response['messages'] = \"Refersh the page again!!\";\n }\n\n echo json_encode($response);\n\t}", "title": "" }, { "docid": "54213ad09c4bb153a985b7a2beb3709d", "score": "0.67466027", "text": "public function deleteHardwareinputProduct(){\n $response = $this->Hardwareinputproduct_model->delete($this->input->post('id'));\n if ($response==1) {\n echo json_encode(array('response'=>'success','message'=>sprintf(lang('deleted_successfully'),lang('page_hardwareinput_product')),'dataid'=>$this->input->post('id')));\n }else{\n echo json_encode(array('response'=>'error','message'=>$response,'dataid'=>$this->input->post('id')));\n }\n exit;\n }", "title": "" }, { "docid": "d4f1f76b52592340ca5eef659569e4c0", "score": "0.6745844", "text": "public function deleteAction() {\n $logger = $this->get('logger');\n if (!$this->get('request')->isXmlHttpRequest()) { // Is the request an ajax one?\n return new Response(\"<b>Not an ajax call!!!\" . \"</b>\");\n }\n\n try {\n //Get parameters\n $request = $this->get('request');\n $id = $request->get('id');\n $entity = $request->get('entity');\n $translator = $this->get(\"translator\");\n\n if( isset($id) ){\n $em = $this->getDoctrine()->getManager();\n $user = $em->getRepository('TecnotekAsiloBundle:User')->find($id);\n if( isset($user) ) {\n $em->remove($user);\n $em->flush();\n return new Response(json_encode(array(\n 'error' => false,\n 'msg' => $translator->trans('catalog.delete.success'))));\n } else {\n return new Response(json_encode(array(\n 'error' => true,\n 'msg' => $translator->trans('validation.not.found'))));\n }\n } else {\n return new Response(json_encode(array('error' => true, 'msg' => \"Missing Parameters\")));\n }\n } catch (Exception $e) {\n $info = toString($e);\n $logger->err('Catalog::deleteAction [' . $info . \"]\");\n return new Response(json_encode(array('error' => true, 'msg' => $info)));\n }\n }", "title": "" }, { "docid": "550858972e4b62a1754a41f8dd864f91", "score": "0.6728992", "text": "public function actionDelete()\n {\n $id = $_POST['id'];\n\n if($this->loadModel($id)->delete()){\n $_SESSION['delete'] = \"Service deleted successfully\";\n echo json_encode([\n 'token' => 1,\n ]);\n }\n else{\n echo json_encode([\n 'token' => 0,\n ]);\n }\n\n // if AJAX request (triggered by deletion via admin grid view), we should not redirect the browser\n /*if(!isset($_GET['ajax']))\n $this->redirect(isset($_POST['returnUrl']) ? $_POST['returnUrl'] : array('admin'));*/\n }", "title": "" }, { "docid": "8666c7db33afefc80b79c3f206123300", "score": "0.67014", "text": "function dokan_delete_product_handler() {\n if ( isset( $_GET['action'] ) && $_GET['action'] == 'dokan-delete-product' ) {\n $product_id = isset( $_GET['product_id'] ) ? intval( $_GET['product_id'] ) : 0;\n\n if ( !$product_id ) {\n wp_redirect( add_query_arg( array( 'message' => 'error' ), get_permalink() ) );\n return;\n }\n\n if ( !wp_verify_nonce( $_GET['_wpnonce'], 'dokan-delete-product' ) ) {\n wp_redirect( add_query_arg( array( 'message' => 'error' ), get_permalink() ) );\n return;\n }\n\n if ( !dokan_is_product_author( $product_id ) ) {\n wp_redirect( add_query_arg( array( 'message' => 'error' ), get_permalink() ) );\n return;\n }\n\n wp_delete_post( $product_id );\n wp_redirect( add_query_arg( array( 'message' => 'product_deleted' ), get_permalink() ) );\n exit;\n }\n}", "title": "" }, { "docid": "175ba08ed44c72829b57c272dd3186d4", "score": "0.66908705", "text": "public function actionAjaxDeleteAdditionalService()\n \t {\n $id=$_REQUEST['id'];\n\t\t $detail=AdditionalServices::model()->findByAttributes(array('id'=>$id));\n\t\t \n\t\t \t $detail->delete();\n\t\t \t echo \"success\";\n \t }", "title": "" }, { "docid": "662c88bb172662e6f44c4958c7e3ea71", "score": "0.66559047", "text": "public function deleteAction() {\n\n $id = (int) $this->getRequest()->getParam('id');\n\n try {\n $this->_productMapper->delete($id);\n $this->_flashMessenger->addMessage(array('info' => 'Produkt byl úspěšně smazán.'));\n } catch (Exception $e) {\n $this->_flashMessenger->addMessage(array('error' => 'Při pokusu o smazání došlo k chybě!<br />' . $e->getMessage()));\n }\n $module = $this->getRequest()->getModuleName();\n $controller = $this->getRequest()->getControllerName();\n $this->_redirect($module . '/' . $controller);\n }", "title": "" }, { "docid": "e5e51f525587f77173f34ac633093814", "score": "0.664511", "text": "public function deleteProduct(Product $product);", "title": "" }, { "docid": "5fd43c67d164a9f5c674308d0c13aab3", "score": "0.6636936", "text": "public function xhrDeleteListing()\n {\n $id = (int) $_POST['id'];\n $this->db->delete('data', \"id = '$id'\");\n }", "title": "" }, { "docid": "211824442db15585a1c04a4d6b394a92", "score": "0.6634679", "text": "public function destroy($id_product)\n {\n Products::whereId_product($id_product)->delete();\n // echo json_encode(['sukses'=>'SUkses bro']);\n }", "title": "" }, { "docid": "183714f008ce092b4234c30c97ec4a5d", "score": "0.66231865", "text": "public function ajax_delete_quote()\r\n {\r\n try\r\n {\r\n $id = trim($this->input->post('i_id'));\r\n \r\n $i_ret_ = $this->mod_rect->delete_quote(decrypt($id));\r\n if($i_ret_)\r\n {\r\n set_success_msg($this->cls_msg[\"delete_succ\"]);\r\n echo 'ok';\r\n }\r\n else\r\n {\r\n echo 'error';\r\n }\r\n \r\n }\r\n catch(Exception $err_obj)\r\n {\r\n show_error($err_obj->getMessage());\r\n }\r\n }", "title": "" }, { "docid": "af8b512c530ab163899b10c82ab797ec", "score": "0.66199076", "text": "public function deleteProduct(Request $request)\n {\n $product = Product::find($request->id);\n if($product->delete()){\n Session::flash('message', 'Producto eliminado correctamente!!');\n return Redirect::to('products');\n }\n }", "title": "" }, { "docid": "8852c2665ee8f75625cf0c0308de9f8f", "score": "0.66156334", "text": "public function ajax_delete(){\n\t\t$param['module'] = $this->input->post('module');\n\t\t$param['id'] = (int)$this->input->post('id');\n\t\t$param['child'] = (int)$this->input->post('child');\n\n\t\t$flag = $this->Autoload_Model->_delete(array(\n\t\t\t'where' => array('id' => $param['id']),\n\t\t\t'table' => $param['module']\n\t\t));\n\t\techo $flag; die();\n\t}", "title": "" }, { "docid": "f5ac105c32ba86ea6c30ecaf9e2f008e", "score": "0.66071343", "text": "public function deleteAjax(Request $request)\n {\n\n $response = new Response();\n $response->headers->set('Content-Type', 'application/json');\n\n $post = json_decode($request->getContent());\n\n $id = $post->id;\n $retorno = $this->get('admin_menu.service.menu')->removeMenu($id);\n\n return $response->setContent(json_encode($retorno));\n }", "title": "" }, { "docid": "b12620654bfff603e472a1e6394e725e", "score": "0.6604632", "text": "public function remove()\n\t{\n\t\tif (!in_array('deleteOrder', $this->permission)) {\n\t\t\tredirect('dashboard', 'refresh');\n\t\t}\n\n\t\t$s_no = $this->input->post('s_no');\n\t\t$purchase_no = $this->input->post('purchase_no');\n\n\n\n\t\t$response = array();\n\t\tif ($s_no && $purchase_no) {\n\t\t\t$delete = $this->model_purchase->remove($s_no, $purchase_no);\n\t\t\tif ($delete == true) {\n\t\t\t\t$response['success'] = true;\n\t\t\t\t$response['messages'] = \"Successfully removed\";\n\t\t\t} else {\n\t\t\t\t$response['success'] = false;\n\t\t\t\t$response['messages'] = \"Error in the database while removing the product information\";\n\t\t\t}\n\t\t} else {\n\t\t\t$response['success'] = false;\n\t\t\t$response['messages'] = \"Refersh the page again!!\";\n\t\t}\n\n\t\techo json_encode($response);\n\t}", "title": "" }, { "docid": "aefaba81c03e73ab899083c96f410855", "score": "0.66008633", "text": "public function delete_wishlist_item_ajax(Request $request)\n {\n if($request->ajax())\n {\n $data = $this->delete_wishlist($request);\n }\n return response()->json(['data' => $data]);\n }", "title": "" }, { "docid": "0515339dfea47ca230d725e8bd1379bd", "score": "0.65924525", "text": "public function deleteTag(){\n if($this->input->is_ajax_request()){\n $this->load->model('PresupuestoTagsModel');\n $this->load->model('ErpTagsModel');\n $client_id = $this->input->post('client_id', true);\n $tag_id = $this->input->post('tag_id', true);\n $result = false;\n $tags_not_added = array();\n if($client_id && $tag_id){\n $result = $this->PresupuestoTagsModel->deleteItem($client_id, $tag_id);\n $where_not_in = \"SELECT id_tag FROM presupuesto_tags WHERE numpresupuesto ='\".$client_id.\"'\";\n $tags_not_added = $this->ErpTagsModel->getTagsForfilterBytable($where_not_in);\n }\n echo json_encode(array('success' => $result, 'tags' => $tags_not_added));\n exit;\n }else{\n $this->layouts->view('error_404',$this->data, 'error_404');\n }\n }", "title": "" }, { "docid": "832289213b4f873e4d464d747b3c7563", "score": "0.65489835", "text": "public function ctrEliminarProducto(){\n\n\n\n\t\tif (isset($_GET['idProducto'])) {\n\n\n\n\t\t\t$tabla = 'productos';\n\n\n\n\t\t\t$datos = $_GET['idProducto'];\n\n\n\n\t\t\tif (!empty($_GET['imagen'])) {\n\n\n\n\t\t\t\tunlink(utf8_decode($_GET['imagen'])); // USAR UTF8_DECODE PARA TILDES EN CARPETAS\n\n\t\t\t\t\t\trmdir('vistas/img/productos/'.utf8_decode($_GET['codigoborrar'])); //USAR UTF8_DECODE PARA TILDES\n\n\n\n\t\t\t\t\t}\n\n\n\n\n\n\t\t\t\t\t$respuesta = ModeloProducto::mdlBorrarProducto($tabla, $datos);\n\n\n\n\n\n\t\t\t\t\tif ($respuesta == 'ok') { ?>\n\n\n\n\t\t\t\t\t\t<script>\n\n\n\n\t\t\t\t\t\t\tswal({\n\n\n\n\t\t\t\t\t\t\t\ttype: \"success\",\n\n\t\t\t\t\t\t\t\ttitle: \"¡El servicio ha sido borrado correctamente!\",\n\n\t\t\t\t\t\t\t\tshowConfirmButton: true,\n\n\t\t\t\t\t\t\t\tconfirmButtonText: \"Cerrar\",\n\n\t\t\t\t\t\t\t\tcloseOnConfirm: false\n\n\n\n\t\t\t\t\t\t\t}).then((result)=>{\n\n\n\n\t\t\t\t\t\t\t\tif(result.value){\n\n\n\n\t\t\t\t\t\t\t\t\twindow.location = \"tareas\";\n\n\n\n\t\t\t\t\t\t\t\t}\n\n\n\n\t\t\t\t\t\t\t});\n\n\n\n\n\n\t\t\t\t\t\t</script>\n\n\n\n\t\t\t\t\t\t<?php \n\n\n\n\t\t\t\t\t}\n\n\n\n\t\t\t\t}\n\n\n\n\n\n\t\t\t}", "title": "" }, { "docid": "16a01e6621ab518400ceb9eb88a1db13", "score": "0.6536089", "text": "public function destroy($id)\n {\n if(\\Request::ajax())\n {\n $id = Hashids::decode($id)[0];\n }\n\n $product = Product::find($id);\n\n if($product){\n // sync products\n $product_store_ids = Store_products::where('product_id',$product->id)->pluck('store_id');\n updateSyncData('delete_product',$product->id,$product_store_ids);\n\n $product->delete();\n\n $response['success'] = 'Product deleted!';\n $status = $this->successStatus;\n }else{\n $response['error'] = 'Product not exist against this id!';\n $status = $this->notFoundStatus;\n }\n\n return response()->json(['result'=>$response], $status);\n }", "title": "" }, { "docid": "b11d8f99deb0a701599d282d775d9806", "score": "0.65315545", "text": "public function deleteAction()\n {\n \t$id = (int) $this->params()->fromRoute('id', 0);\n \tif (!$id) {\n \t\treturn $this->redirect()->toRoute('order');\n \t}\n \t// Retrieve the current user\n \t$current_user = Functions::getUser($this);\n \t \n \t// Retrieve the allowed routes\n \t$allowedRoutes = Functions::getAllowedRoutes($this);\n\n \t// Retrieve the user's instance\n \t$instance_id = Functions::getInstanceId($this);\n \t\n \t// Retrieve the order product row\n \t$orderProduct = $this->getOrderProductTable()->get($id);\n \t \n \t// Retrieve the order\n \t$order = $this->getOrderTable()->get($orderProduct->order_id);\n\n \t// Retrieve the product\n \t$product = $this->getProductTable()->get($orderProduct->product_id);\n \t \n \t// Retrieve the user validation from the post\n \t$request = $this->getRequest();\n \tif ($request->isPost()) {\n \t\t$del = $request->getPost('del', 'No');\n \n\t\t\t// And delete the entity from the database in the \"yes\" case\n \t\tif ($del == $this->getServiceLocator()->get('translator')->translate('Yes')) {\n \t\t\t$id = (int) $request->getPost('id');\n \t\t\t$this->getOrderProductTable()->delete($id);\n \t\t}\n \n \t\t// Redirect to the index\n \t\treturn $this->redirect()->toRoute('orderProduct/index', array('id' => $order->id));\n \t}\n \n \treturn array(\n \t\t'current_user' => $current_user,\n \t\t'allowedRoutes' => $allowedRoutes,\n \t\t'title' => 'Order',\n \t\t'id' => $id,\n \t\t'order' => $order,\n \t\t'product' => $product\n \t);\n }", "title": "" }, { "docid": "d66e30d2d75f992d80e57822a3a2e90d", "score": "0.65288603", "text": "function destroy()\n\t{\n\t\t$id = getParameter('id');\n\t\t$this->model->product->destroy($id);\n\t\tredirect('product/index');\n\t}", "title": "" }, { "docid": "c4cbe7b6a82b5da048f82b39bbbac57f", "score": "0.65262187", "text": "public function deleteproductActionPost(): object\n {\n // Connects to db\n $this->app->db->connect();\n\n if (hasKeyPost(\"doDelete\")) {\n $productId = getPost(\"id\");\n\n // Executes SQL statement\n $this->admin->deleteProduct($productId);\n\n // Redirects\n return $this->app->response->redirect(\"admin/products2\");\n }\n }", "title": "" }, { "docid": "6b2e6449445c7fef689ff6a9d998f017", "score": "0.65232867", "text": "public function removeAction()\n {\n if (!$this->_isActive()\n || !$this->_getHelper()->isRemoveItemAllowed()) {\n $this->norouteAction();\n return;\n }\n\n if ($this->_expireAjax()) {\n return;\n }\n\n $result = array();\n\n $quoteItem = $this->getOnepage()->getQuote()->getItemById(\n $this->getRequest()->getPost('item_id')\n );\n\n if ($quoteItem) {\n try {\n $this->getOnepage()->getQuote()\n ->removeItem($quoteItem->getId());\n \n $this->_recalculateTotals();\n $result['success'] = true;\n /**\n * When cart is ampty - redirect to empty cart page\n */\n if(!$this->getOnepage()->getQuote()->getItemsCount()){\n $result['redirect'] = Mage::helper('checkout/cart')->getCartUrl();\n }\n } catch (Mage_Core_Exception $e) {\n $result['error'] = $e->getMessage();\n } catch (Exception $e) {\n Mage::logException($e);\n $result['error'] = Mage::helper('ecomdev_checkitout')->__('There was an error during removing product from order');\n }\n } else {\n $result['error'] = Mage::helper('ecomdev_checkitout')->__('Product was not found');\n }\n\n $this->_addHashInfo($result);\n $this->getResponse()->setBody(Mage::helper('core')->jsonEncode($result));\n }", "title": "" }, { "docid": "c3936b677cddb51e3826210f8fba7d28", "score": "0.6494849", "text": "public function actionAjaxDeleteWhy()\n {\n \t $id=$_REQUEST['id'];\n \t //echo $id;die;\n \t $detail=WhyUsHome::model()->findByAttributes(array('id'=>$id));\n \t //echo \"<pre>\";print_r($detail);die;\n \t $detail->delete();\n \t echo \"success\";\n\n }", "title": "" }, { "docid": "28a04f62f88c0e2058f61a2dfd472627", "score": "0.6493855", "text": "public function ajax_delete($id)\r\n {\r\n $this->GsmModel->delete($id);\r\n echo json_encode(array(\"status\" => TRUE));\r\n }", "title": "" }, { "docid": "27c90bd4bb8ccac597245deeae2823bb", "score": "0.64911395", "text": "public function productDelete(Varien_Event_Observer $observer)\n {\n try \n {\n $helper = Mage::helper('increasingly_analytics');\n\n if ($helper->isEnabled()){\n $productId = $observer->getEvent()->getProduct()->getId();\n\n $productData = array('product_id' => $productId);\n $helper->deleteBundleOnProductDeleteFromCart($productId);\n $helper->increasinglyApi($productData,'product_delete','track',$helper->getApiToken(),$helper->getApiSecret());\n }\n\n }\n catch(Exception $e)\n {\n Mage::log(\"Product delete tracking - \" . $e->getMessage(), null, 'Increasingly_Analytics.log');\n }\n }", "title": "" }, { "docid": "6e6a9abf65f589b4afeed90109223ae7", "score": "0.6485503", "text": "function ajaxDeleteEmployeeInDB() {\n $employeeId = $_GET['employeeId'];\n $result = deleteEmployee($employeeId);\n echo json_encode($result);\n }", "title": "" }, { "docid": "214a82adf2ef1c60d0ba075c79e0b2d0", "score": "0.6485226", "text": "public function ajaxDelete()\r\n {\r\n try {\r\n $request = $this->getRequest();\r\n $user = $this->getUser();\r\n if (!$user)\r\n throw new AccessDeniedException('No inició sesión');\r\n $idinterest = $request->get('id');\r\n $interest = $this->getRepository('Interest')->find($idinterest);\r\n if (!$interest)\r\n throw new \\Exception('No existe el interés');\r\n\r\n $exists = $this->getRepository('HasInterest')->findOneBy(array('author' => $user->getId(), 'interest' => $interest->getId()));\r\n if (!$exists)\r\n throw new \\Exception('El usuario no tiene el interés');\r\n $em = $this->getDoctrine()->getEntityManager();\r\n $em->remove($exists);\r\n $em->flush();\r\n return $this->jsonResponse(array('message' => 'Se ha quitado el interés \"' . (string) $interest . '\"'));\r\n } catch (\\Exception $e) {\r\n return new Response($e->getMessage(), 400);\r\n }\r\n }", "title": "" }, { "docid": "42151a4a386ce7f37c436056bcdf7f7d", "score": "0.6484899", "text": "public function actionDelete($id) {\n $uProduct = Product::model()->findByPk($id);\n $uProduct->delete();\n echo 200;\n }", "title": "" }, { "docid": "42f976fdde5eb0153fade10298b8c1af", "score": "0.64834195", "text": "public function delete()\n\t{\n\t\t$product_id = $this->input->post('product_id');\n\t\t$vendor_id = $this->session->userdata('vendor_id');\n\n\t\t$thumb_image = get_product($product_id, 'thumb_image'); //get thumb_image\n\t\t$images = unserialize(get_product($product_id, 'images')); //get multiple images\n\n\t\t$deleted = $this->products->delete($product_id);\n\n\t\tif ($deleted)\n\t\t{\n\t\t\t//thumb image//\n\t\t\t$copy_thumb = str_replace('products', 'products/deleted', $thumb_image); //replace path\n\t\t\tcopy($thumb_image, $copy_thumb); //copy image\n\t\t\tunlink($thumb_image);\n\n\t\t\tforeach ($images as $image) //multiple images//\n\t\t\t{\n\t\t\t\t$copy_image = str_replace('products', 'products/deleted', $image); //replace path\n\t\t\t\tcopy($image, $copy_image); //copy image\n\t\t\t\tunlink($image);\n\t\t\t}\n\n\t\t\t$this->vendors->update_total_product($vendor_id, 'total_products - 1');\n\t\t\techo 'true';\n\t\t}\n\t\telse\n\t\t{\n\t\t\techo 'false';\n\t\t}\n\t}", "title": "" }, { "docid": "c1657832eb931b01d515c6cadb9a061d", "score": "0.6480799", "text": "static public function deleteProduct(){\n\n\t\tif(isset($_GET[\"idProducto\"])){\n\n\t\t\t$datos = $_GET[\"idProducto\"];\n\n\t\t\t/*=============================================\n\t\t\tELIMINAR MULTIMEDIA\n\t\t\t=============================================*/\n\t\t\t//glob — Buscar coincidencias de nombres de ruta con un patrón\n\t\t\t$borrar = glob(\"views/img/multimedia/\".$_GET[\"rutaCabecera\"].\"/*\");\n\n\t\t\t\tforeach($borrar as $file){\n\n\t\t\t\t\tunlink($file);\n\n\t\t\t\t}\n\n\t\t\trmdir(\"views/img/multimedia/\".$_GET[\"rutaCabecera\"]);\n\n\t\t\t/*=============================================\n\t\t\tELIMINAR FOTO PRINCIPAL\n\t\t\t=============================================*/\n\t\t\tif($_GET[\"imgPrincipal\"] != \"\" && $_GET[\"imgPrincipal\"] != \"views/img/productos/default/default.jpg\"){\n\n\t\t\t\tunlink($_GET[\"imgPrincipal\"]);\t\t\n\n\t\t\t}\n\n\t\t\t/*=============================================\n\t\t\tELIMINAR OFERTA\n\t\t\t=============================================*/\n\t\t\tif($_GET[\"imgOferta\"] != \"\"){\n\n\t\t\t\tunlink($_GET[\"imgOferta\"]);\t\t\n\n\t\t\t}\n\n\t\t\t/*=============================================\n\t\t\tELIMINAR CABECERA\n\t\t\t=============================================*/\n\t\t\tif($_GET[\"imgPortada\"] != \"\" && $_GET[\"imgPortada\"] != \"views/img/cabeceras/default/default.jpg\"){\n\n\t\t\t\tunlink($_GET[\"imgPortada\"]);\t\t\n\n\t\t\t}\n\n\t\t\tHeadersModel::deleteHeader(\"headers\", $_GET[\"rutaCabecera\"]);\n\n\t\t\t$respuesta = ProductsModel::deleteProduct(\"products\", $datos);\n\n\t\t\tif($respuesta == \"ok\"){\n\n\t\t\t\techo'<script>\n\n\t\t\t\tswal({\n\t\t\t\t\t type: \"success\",\n\t\t\t\t\t title: \"El producto ha sido borrado correctamente\",\n\t\t\t\t\t showConfirmButton: true,\n\t\t\t\t\t confirmButtonText: \"Cerrar\"\n\t\t\t\t\t }).then(function(result){\n\t\t\t\t\t\t\t\tif (result.value) {\n\n\t\t\t\t\t\t\t\twindow.location = \"productos\";\n\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t})\n\n\t\t\t\t</script>';\n\n\t\t\t}\t\t\n\t\t}\n\t}", "title": "" }, { "docid": "dde8e58813bfddf027658a8b5236d42d", "score": "0.64607584", "text": "public function ajax_delete($id)\n {\n $this->Dispatcher_model->delete_by_id($id);\n echo json_encode(array('status' => TRUE));\n }", "title": "" }, { "docid": "f78a163e183850d7f34f520ffc1f09c0", "score": "0.64378923", "text": "public function deleteAction() {\n \n $this->_helper->layout->disableLayout();\n $this->_helper->viewRenderer->setNoRender(true);\n \n\n $del = $this->_model->deleteNote($this->id);\n\n if( $this->xhr ) {\n \n $this->_asJson(array('id' => $this->id,\n 'consumer_id' => $this->consumer_id,\n 'message' => 'Note Removed.',\n 'success' => $del));\n }else{\n \n $this->_helper->flashMessenger->addMessage(array('alert alert-success'=>\"Note Removed.\") ); \n $this->_redirect($this->indexAction . $this->consumer_id);\n \n }\n }", "title": "" }, { "docid": "edefa9e77a8968cb83d65c26a38dd3d0", "score": "0.64356214", "text": "public function deleteAjax(){\n\t\t$id = $this->input->post('id');\n\n\t\t//get deleted user info\n\t\t$userInfo = singleDbTableRow($id,'ledger');\n\t\t$categoryName = $userInfo->user_id;\n\t\t// add a activity\n\t\tcreate_activity(\"Deleted {$amount} ledger\");\n\t\t//Now delete permanently\n\t\t$this->db->where('id', $id)->delete('ledger');\n\t\treturn true;\n\t}", "title": "" }, { "docid": "28d2e6fb7b7ac0c1b9da49f7c46e6cd6", "score": "0.6429754", "text": "public function destroy()\n {\n $data = request()->validate([\n 'product_id' => 'required'\n ]);\n\n Product::destroy(request('product_id'));\n\n return redirect(route('product.index'))->with('success', 'Product successfully deleted');\n }", "title": "" }, { "docid": "5fbffcf9c31923c2a4550a6d063a850f", "score": "0.6418484", "text": "public function actionDelete()\n\t{\n\t\t$this->requireAjaxRequest();\n\n\t\t$id = craft()->request->getRequiredPost('id');\n\t\t$result = craft()->reroute->deleteById($id);\n\n\t\t$this->returnJson(array('success' => $result));\n\t}", "title": "" }, { "docid": "39f95d02f9570e59f6c013d2ffe25820", "score": "0.64074343", "text": "public function deleteProduct(Request $request)\n {\n \n \n DB::table('product_b')->where('product_name', '=', $request->get('product_name'))->delete();\n return redirect()->to('dashboard');\n \n }", "title": "" }, { "docid": "a5393798a332dca0efe1add4b9152095", "score": "0.6402547", "text": "public function deleteMethod(){\n $fc=AppController::getInstance();\n $args=$fc->getArgsNum();\n if(!isset($args[0]))header('Location:/error');\n if(!$good=$this->_db->getGoodBySlug($args[0]))exit(header('Location:/error'));\n $fn=$good->foto;\n if($_SERVER['REQUEST_METHOD']=='POST'){\n if(isset($_POST['yes'])){\n // получено подтверждение на удаление товара\n if(NULL===$err=$this->_db->deleteGoodOfUserShop($good->id,$this->_user->id))if(NULL===$err=ImgProc::deleteFotos($fn))exit(header('Location:/goods'));\n die($err);\n }\n exit(header('Location:/goods'));\n }\n $fc->setContent($fc->render('goods/delete.twig.html',array('this'=>$this,'good'=>$good)));\n }", "title": "" }, { "docid": "893d50bc7c05283117d0e759c3dcc14d", "score": "0.63899803", "text": "public function deleted(Product $producto)\n {\n //\n }", "title": "" }, { "docid": "31d5cc4e0e94bfedca0877d05b0e94aa", "score": "0.63704336", "text": "public function deleteAction(){\n $this->_helper->json(\"Esto no esta implementado\");\n }", "title": "" }, { "docid": "c7941ca2fb1b95ccf6a537b95a87d7df", "score": "0.63621014", "text": "function delete_visa_process(){\n\t\t\n\t\tif($this->input->is_ajax_request()){\n\t\t\t\n\t\t\t$visa_id = $this->input->post('id_update');\n\n\t\t\t$str = \"DELETE FROM document_tr WHERE document_id = '$visa_id'\";\n\t\t\t$q = $this->db->query($str);;\n\t\t\tif($q){\n\t\t\t\techo \"<div class='alert alert-success'> Visa has been delete </div>\";\n\t\t\t\t\n\t\t\t}else{\n\t\t\t\techo \"\";\n\t\t\t}\n\t\t\t\n\t\t} else {\n\t\t\theader('location:'.base_url('custom404'));\n\t\t}\n\t\t\n\t}", "title": "" }, { "docid": "d4c62e2ace0753d02ccc1d2bd6f4427f", "score": "0.63593554", "text": "public function destroy(Request $request)\n {\n $id = $request->input('id');\n DB::table('products')\n ->where('id', $id)\n ->delete();\n\n if($id == null){\n return response()->json(['status' => 'Delete Product Error']);\n }else{\n return response()->json(['status' => 'Delete Product Success']);\n }\n }", "title": "" }, { "docid": "ea2bbf7960a77710afabe8603b29482b", "score": "0.63532406", "text": "public function destroy(Request $request,$id)\n {\n //DB::table('proyeto')->where('id',$id)->delete();\n //return redirect()->route('registro.index');\n if ($request->ajax()) {\n $proyecto = Proyecto::findorFail($id);\n $proyecto->delete();\n $proyectoTotal = Proyecto::all()->count();\n\n }\n\n return response()->json([\n 'total'=>$proyectoTotal,\n 'mensaje' => $proyecto->name.' se ha eliminado con exito'\n\n ]);\n \n }", "title": "" }, { "docid": "7b49c02e3e129f1cf5652f6b6b697925", "score": "0.6349656", "text": "public function actionDelete()\n {\n if(Yii::$app->request->isAjax) {\n $id=Yii::$app->request->post('id');\n $bool =$this->findModel($id)->delete();\n\n $result=$bool ? ['status' => '0', 'msg' => 'OK'] :['status' => '1', 'msg' => 'Error'];\n return Json::encode($result);\n }\n }", "title": "" }, { "docid": "e4ac4d24f61daf1706e9ebee0a73ddc0", "score": "0.6325926", "text": "public function controllerActionPostdispatchCheckoutCartAjaxDelete(Varien_Event_Observer $observer)\n {\n $response = Mage::app()->getResponse();\n\n $response->clearHeaders()\n ->setHeader('Content-Type', 'application/json');\n }", "title": "" }, { "docid": "152266d9e70b4344802f8a1d944c9f63", "score": "0.6321641", "text": "public function destroy()\n {\n if( ProductCategory::destroy( Input::get( 'id' ) ) ){\n session()->flash(\"flash_message\", [\"msg\" => \"A product category has been deleted.\", \"type\" => \"danger\"]);\n return json_encode( array(\"status\" => \"success\") );\n }\n \n session()->flash(\"flash_message\", [\"msg\" => \"Sorry we failed process your request. Please try again later.\", \"type\" => \"danger\"]); \n return json_encode( array(\"status\" => \"failed\", \"msg\" => \"Sorry, we can't process your request right now. Please try again later.\") );\n }", "title": "" }, { "docid": "4e6d05becd548d71fc37540d122381e9", "score": "0.6320898", "text": "public function removeAction() {\r\n $response = Mage::getModel('ajaxcartpro/ajaxresponse');\r\n $id = $this->getRequest()->getParam('id');\r\n Mage::getSingleton('checkout/cart')->removeItem($id)->save();\r\n $response->setCart(Mage::helper('ajaxcartpro')->rendercartpageUpdate());\r\n $response->setSidebar(Mage::helper('ajaxcartpro')->cartItemssidebar());\r\n $response->setLinks(Mage::helper('ajaxcartpro')->topLinkTitle());\r\n $response->send();\r\n }", "title": "" }, { "docid": "d65e245bf27b574235b168ca57b8c001", "score": "0.6316399", "text": "public function actionDelete() {\n\t\tif (isset($_POST) && $_POST['isAjaxRequest'] == 1) {\n\t\t\t$response = array('status' => '1');\n\t\t\t$model = $this->loadModel($_POST['id']);\n\t\t\t$model->is_deleted = 1;\n\t\t\tif ($model->save()) {\n\t\t\t\techo CJSON::encode($response);\n\t\t\t} else {\n\t\t\t\t$response = array('status' => '0', 'error' => $model->getErrors());\n\t\t\t\techo CJSON::encode($response);\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "82dfe56eb3919778955605ace37f1b06", "score": "0.63122976", "text": "public function destroy($id)\n {\n $producto = Producto::findOrFail($id);\n $producto->delete();\n /*$message = $user;\n if($request->ajax()){\n return response()->json([\n 'id' => $id\n 'message' => $message\n ]);\n }*/\n /*\\Session::flash('message','El registro el usuario '.$user->name.' fue eliminado.');*/\n $productos=Producto::paginate();\n return view('productos.listaproduct', compact('productos'));\n }", "title": "" }, { "docid": "cca2100c6fc913cda7f7e11e79f636a9", "score": "0.63044095", "text": "public function invoice_product_delete()\n {\n $data['nestedView']['pageTitle'] = 'Delete Invoice Product';\n $data['nestedView']['heading'] = \"Delete Invoice Product\";\n $data['nestedView']['cur_page'] = 'Delete Invoice Product';\n $data['nestedView']['parent_page'] = 'date_change';\n $data['nestedView']['list_page'] = 'date_change';\n # Load JS and CSS Files\n $data['nestedView']['js_includes'] = array();\n $data['nestedView']['css_includes'] = array();\n \n # Breadcrumbs\n $data['nestedView']['breadCrumbOptions'] = array( array('label'=>'Home','class'=>'','url'=>SITE_URL));\n $data['nestedView']['breadCrumbOptions'][] = array('label'=>'Delete Invoice Product','class'=>'active','url'=>'');\n \n \n\n $data['flag']=1;\n $this->load->view('rollback_invoice/rollback_invoice_product_delete_view',$data);\n }", "title": "" }, { "docid": "39620941c0fab6e1c9cc8fcbeffcfbc8", "score": "0.6293792", "text": "public function actionProductDelete()\n\t{\n\t\t$data=$_POST;\n\t\t\n\t\tif(isset($data['id'])){\n\t\t\ttry{\n\t\t\t\t$id = $data['id'];\n\t\t\t\t$logFIle = 'product/delete/'.$id;\n\t\t\t\tData::createLog('Requested Data: '.json_encode($data),$logFIle,'a');\n\t\t\t\t\n\t\t $product = Data::sqlRecords('SELECT sku,type FROM `jet_product` WHERE id=\"' . $id . '\" ', 'one');\n\t\t if(!$product)\n\t\t \treturn;\n\n\t\t $walmartConfig = Data::sqlRecords(\"SELECT `consumer_id`,`secret_key`,`consumer_channel_type_id` FROM `walmart_configuration` WHERE merchant_id='\".$data['merchant_id'].\"'\",'one','select');\n\t\t if (isset($product) && !empty($product)) {\n\t\t if ($product['type'] == 'variants') {\n\t\t $skus = Data::sqlRecords('SELECT option_sku FROM `jet_product_variants` WHERE product_id=\"' . $id .'\" ', null, 'all');\n\t\t if (!is_array($skus) || (is_array($skus) && !count($skus)))\n\t\t $skus = [];\n\n\t\t } else {\n\t\t $skus[0]['option_sku'] = $product['sku'];\n\t\t }\n\n\t\t \n\t\t $result = [];\n\t\t foreach ($skus as $sku) {\n\n\t\t $walmartApi = new Walmartapi($walmartConfig['consumer_id'],$walmartConfig['secret_key']);\n\t\t $feed_data = $walmartApi->retireProduct($sku['option_sku']);\n\t\t \n\t\t if(isset($feed_data['ItemRetireResponse']))\n\t\t {\n\t\t $result['success'][] = '<b>'.$feed_data['ItemRetireResponse']['sku'].' : </b>'.$feed_data['ItemRetireResponse']['message'];\n\t\t }\n\t\t elseif (isset($feed_data['errors']['error']))\n\t\t {\n\t\t if(isset($feed_data['errors']['error']['code']) && $feed_data['errors']['error']['code'] == \"CONTENT_NOT_FOUND.GMP_ITEM_INGESTOR_API\" && $feed_data['errors']['error']['field'] == \"sku\")\n\t\t {\n\t\t $result['error'][] = $sku['option_sku'].' : Product not Uploaded on Walmart.';\n\t\t }\n\t\t else\n\t\t {\n\t\t $result['error'][] = $sku['option_sku'].' : '.$feed_data['errors']['error']['description'];\n\t\t }\n\t\t } \n\t\t }\n\t\t \n\t\t }\n\t\t Data::createLog('Result : '.json_encode($result),$logFIle,'a');\n\t\t }\n\t\t catch(Exception $e){\n\t\t \tData::createLog('Exception : '.$e->getMessage(),$logFIle,'a');\n\t\t }\n\t }\n\t\tdie;\n\t}", "title": "" }, { "docid": "119c61529b1641a74ab0684f7ff0c038", "score": "0.6291927", "text": "public function executeAjaxDelete(sfWebRequest $request)\n {\n $nomR = $request->getParameter('nomR');\n $uid = uapvProfileFactory::find ($nomR)->get('uid');\n\n $user = UserQuery::create()\n ->filterByUid($uid)\n ->findOne();\n\n $listeStudent = StudentUserQuery::create()\n ->filterByIdUser($user->getId())\n ->find();\n\n // foreach students on this list, we remove his id in table StudentUser\n foreach($listeStudent as $student)\n {\n $s = StudentQuery::create()\n ->filterById($student->getIdStudent())\n ->findOne();\n $s->delete();\n $student->delete();\n }\n $respons['error'] = false;\n\n return $this->returnJSON($respons);\n }", "title": "" }, { "docid": "320ae7e0e7ab23e610546c283cf0bd39", "score": "0.628321", "text": "public function delete(Product $product)\n {\n $product->delete();\n return redirect()->route('admin.product.index')->with('success',\"Produit bien supprimé\");\n\n }", "title": "" }, { "docid": "4931d4b9163f160ce08fec815a858f70", "score": "0.628166", "text": "public function destroy(Product $product) //Eliminar\n {\n //\n }", "title": "" }, { "docid": "2b745a104290f839999604da33cdf94d", "score": "0.6274563", "text": "public function delete_phonesclient(){\n\t\t$this->layout = 'ajax';\n\t\n\t\tif($this->request->is('post')){\n\t\t\t$phonesclient_id = $this->request->data['phonesclient_id'];\n\t\n\t\t\t$obj_phonesclient = $this->Phonesclient->findBy('IDPhoneclient', $phonesclient_id);\n\t\t\tif($obj_phonesclient->saveField('Status', 0)){\n\t\t\t\techo json_encode(array('success'=>true,'msg'=>__('Eliminado con &eacute;xito.')));\n\t\t\t\texit();\n\t\t\t}else{\n\t\t\t\techo json_encode(array('success'=>false,'msg'=>__('Error inesperado.')));\n\t\t\t\texit();\n\t\t\t}\n\t\t}\n\t\n\t}", "title": "" }, { "docid": "5fd3442d13a750f50334dfd7bb7aee69", "score": "0.62744254", "text": "public function actionDelete()\r\n {\r\n if (!$this->requireValues($_POST, \"id\")) {\r\n AjaxResponse::missParam(\"id in post is required\");\r\n }\r\n if (CourseResource::model()->deleteByPk($_POST['id'], \"user_id=:u\", array('u' => Yii::app()->user->id))) {\r\n AjaxResponse::success();\r\n } else {\r\n AjaxResponse::resourceNotFound();\r\n }\r\n }", "title": "" }, { "docid": "7c25c2b18a47500caa12b4bf176fa8fd", "score": "0.6272516", "text": "public function deleteProductv($id)\n {\n $products=Productvariation::where('variation_id',$id)\n ->update(['deleted'=>1]);\n \n return response()->json(['success'=>'Record has been deleted!']);\n \n }", "title": "" }, { "docid": "d95a1a4ac10cd5a2067fbf7359cdf12c", "score": "0.62722504", "text": "private function deleteProduct()\n {\n echo PHP_EOL;\n \n try\n {\n $productToDelete = $this->productDao->getByEan(self::PRODUCT_TURKEY_EAN);\n $resultOfDelete = $this->productDao->delete($productToDelete); \n\n echo 'Product with id: ' . $productToDelete->id . ' was deleted ' .\n (($resultOfDelete) ? '' : 'un') .\n 'successfuly!' . PHP_EOL; \n }\n catch (Exception $e)\n {\n echo $e->getMessage();\n }\n }", "title": "" }, { "docid": "d2e27167609e96f8872088b55423f7d1", "score": "0.62695014", "text": "static public function ctrEliminarRepuesto(){\n\n\t\tif(isset($_GET[\"idProducto\"])){\n\n\t\t\t$tabla =\"repuestos\";\n\t\t\t$datos = $_GET[\"idProducto\"];\n\n\t\t\tif($_GET[\"imagen\"] != \"\" && $_GET[\"imagen\"] != \"vistas/img/productos/default/anonymous.png\"){\n\n\t\t\t\tunlink($_GET[\"imagen\"]);\n\t\t\t\trmdir('vistas/img/productos/'.$_GET[\"codigo\"]);\n\n\t\t\t}\n\n\t\t\t$respuesta = ModeloProductos::mdlEliminarRepuesto($tabla, $datos);\n\n\t\t\tif($respuesta == \"ok\"){\n\n\t\t\t\techo'<script>\n\n\t\t\t\tswal({\n\t\t\t\t\t type: \"success\",\n\t\t\t\t\t title: \"El producto ha sido borrado correctamente\",\n\t\t\t\t\t showConfirmButton: true,\n\t\t\t\t\t confirmButtonText: \"Cerrar\"\n\t\t\t\t\t }).then(function(result){\n\t\t\t\t\t\t\t\tif (result.value) {\n\n\t\t\t\t\t\t\t\twindow.location = \"productos\";\n\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t})\n\n\t\t\t\t</script>';\n\n\t\t\t}\t\t\n\t\t}\n\n\n\t}", "title": "" }, { "docid": "e507f0ca5bfe7d75d0cb20760c6c41bc", "score": "0.6260238", "text": "public function actionAjaxDeleteFaq()\n {\n \t $id=$_REQUEST['id'];\n\t $detail=Faq::model()->findByAttributes(array('id'=>$id));\n\t \n\t \t $detail->delete();\n\t \t echo \"success\";\n }", "title": "" }, { "docid": "d6cdcc25cac9d3bf808696c0da75eb15", "score": "0.62577105", "text": "public function destroy()\n {\n if(!auth()->user()->isAdmin()){\n return Redirect('/');\n }\n\n // Get product\n $product = Product::find(request()->id);\n\n // Set product 'deleted'\n $product->delete();\n \n // Return to the page with a message\n Session::flash('msg', 'Product verwijderd');\n return back();\n }", "title": "" }, { "docid": "9a3e3e3b929b8ed1ab83555430f95460", "score": "0.62411165", "text": "public function deleteAjax(){\n\t\t$id = $this->input->post('id');\n\n\t\t//get deleted user info\n\t\t$userInfo = singleDbTableRow($id);\n\t\t$fullName = user_full_name($userInfo);\n\t\t// add a activity\n\t\tcreate_activity(\"Deleted {$id} from OTP Transactions\");\n\t\t//Now delete permanently\n\t\t$this->db->where('id', $id)->delete('otp_transactions');\n\t\treturn true;\n\t}", "title": "" }, { "docid": "d289308bea1b3cfc104078bab8af0f3b", "score": "0.6222031", "text": "public function ProductDeleteFromStore(request $request)\n { \n $data = $request->all();\n $data = (object)$data;\n if($data)\n {\n $itemDelete = StoreProduct::where(\"product_id\",$data->id)->delete();\n if($itemDelete) \n {\n return response()->json(['status' =>true, 'message' =>'Data import','data' =>\"product delete product\"]); \n }\n else\n {\n return response()->json(['status' =>false, 'message' =>'Data not found','data'=>[]]);\n }\n return response()->json(['status' =>false, 'message' =>'Data import','data' =>\"product delete product\"]); \n }\n else\n {\n return response()->json(['status' =>false, 'message' =>'Data not found','data'=>[]]);\n }\n }", "title": "" } ]
a9ad8cba73dd5dbf7532edb5a0886f15
Load logo or/and widget tpl with bottom position
[ { "docid": "eede1317704e3472b45bf0b86d43a2d9", "score": "0.6170599", "text": "public function hookFooter()\n {\n return $this->displayLogoWidget('bottom');\n }", "title": "" } ]
[ { "docid": "49575fffca5f8d961d23c3bbc1880268", "score": "0.6635749", "text": "private function loadWidgetTPL()\n {\n //retrieve widget number on database and load the corresponding widget\n $host = $_SERVER['HTTP_HOST'];\n $url_site = 'http://www.' . $host;\n $string_site = explode('.', $host);\n $nom_site = $string_site[0];\n\n $this->smarty->assign(array(\n 'siteid' => Configuration::get('FIANETSCEAU_SITEID'),\n 'shape' => $this->fianetsceau_widgets[Configuration::get('FIANETSCEAU_WIDGET_NUMBER')]['shape'],\n 'background' => $this->fianetsceau_widgets[Configuration::get('FIANETSCEAU_WIDGET_NUMBER')]['background'],\n 'url_site' => $url_site,\n 'nom_site' => $nom_site,\n ));\n\n if ($this->fianetsceau_widgets[Configuration::get('FIANETSCEAU_WIDGET_NUMBER')]['shape'] == 'comment') {\n return $this->display(\n __FILE__,\n '/views/templates/front/fianetsceau_widget_comments.tpl'\n );\n } else {\n return $this->display(\n __FILE__,\n '/views/templates/front/fianetsceau_widget.tpl'\n );\n }\n }", "title": "" }, { "docid": "52b7d267c0ad43b63985e8484178cc10", "score": "0.6540341", "text": "function genesischild_footerwidgetheader() {\n\techo '<div class=\"footerwidgetheader-container\"><div class=\"wrap\">';\n\tgenesis_widget_area ( 'footerwidgetheader' );\n\techo '</div></div>'; \n}", "title": "" }, { "docid": "b5e0586d5a49807977021e5779daf836", "score": "0.6357852", "text": "function ts_do_logo_div() {\n\techo '<div id=\"logoholder\">';\n\techo '<div class=\"wrap\">';\n\tdynamic_sidebar( 'logo-holder' );\n\techo '</div></div><!-- end .logoholder -->';\n}", "title": "" }, { "docid": "4b93699cb1786a531a51f0462d07afca", "score": "0.6327635", "text": "private function loadLogoTPL()\n {\n //retrieve logo size on database and load the corresponding image\n $this->smarty->assign(array(\n 'siteid' => Configuration::get('FIANETSCEAU_SITEID'),\n 'fianetsceau_img' => __PS_BASE_URI__ . 'modules/'\n . $this->name . '/views/img/'\n . $this->fianetsceau_logo_sizes[Configuration::get('FIANETSCEAU_LOGO_SIZE')]\n ));\n\n return $this->display(__FILE__, '/views/templates/front/fianetsceau.tpl');\n }", "title": "" }, { "docid": "8ced128b0d16a42c9ca18115b79fda13", "score": "0.62157416", "text": "public function genesis_footer_widget_area() {\n\n\t\t$logo = sprintf(\n\t\t\t'<a href=\"%s\" title=\"Texas A&M AgriLife\"><img src=\"%s\"></a>',\n\t\t\ttrailingslashit( home_url() ),\n\t\t\tAGTODAY_THEME_DIRURL . '/images/logo-agrilife.png'\n\t\t);\n\n\t\t$footer_open = '<div class=\"footer-widgets\"><div class=\"wrap grid-container grid-x\">';\n\t\t$footer_close = '</div></div>';\n\n\t\techo wp_kses_post( $footer_open );\n\n\t\tgenesis_widget_area(\n\t\t\t'footer-1',\n\t\t\tarray(\n\t\t\t\t'before' => '<div class=\"widgets-footer-1 cell small-12 medium-12\"><div class=\"logo hide-for-print\">' . $logo . '</div>',\n\t\t\t\t'after' => '</div>',\n\t\t\t)\n\t\t);\n\n\t\tgenesis_widget_area(\n\t\t\t'footer-2',\n\t\t\tarray(\n\t\t\t\t'before' => '<div class=\"widgets-footer-2 heading-sideline cell small-12 medium-12 hide-for-print\"><div class=\"grid-x\"><div class=\"cell auto title-line\"></div><div class=\"cell shrink social-media\">',\n\t\t\t\t'after' => '</div><div class=\"cell auto title-line\"></div></div></div>',\n\t\t\t)\n\t\t);\n\n\t\tgenesis_widget_area(\n\t\t\t'footer-3',\n\t\t\tarray(\n\t\t\t\t'before' => '<div class=\"widgets-footer-3 cell small-12 medium-12\">',\n\t\t\t\t'after' => '</div>',\n\t\t\t)\n\t\t);\n\n\t\techo wp_kses_post( $footer_close );\n\n\t}", "title": "" }, { "docid": "9e11d5e895ca638e21a3d062a76c4900", "score": "0.6204595", "text": "public function hookTop()\n {\n return $this->displayLogoWidget('top');\n }", "title": "" }, { "docid": "58987114847f10498336b1be819b6089", "score": "0.61651134", "text": "function genesischild_homecontent_widget() {\n\tgenesis_widget_area( 'home-top', array(\n\t'before' => '<div class=\"home-top-container\"><div class=\"wrap home-top\">',\n\t'after' => '</div></div>',\n\t) );\n\tgenesis_widget_area ( 'home-middle', array(\n\t'before' => '<div class=\"home-middle-container\"><div class=\"wrap home-middle\">',\n\t'after' => '</div></div>',\n\t) );\n\tgenesis_widget_area ( 'home-bottom', array(\n\t'before' => '<div class=\"home-bottom-container\"><div class=\"wrap home-bottom\">',\n\t'after' => '</div></div>',\n\t) );\n}", "title": "" }, { "docid": "ded6d178b8323926e6d40ed278085b48", "score": "0.6135993", "text": "function pitemplate_top(){\n\n $panel = 'pitemplate_top'; \n $show = get_theme_mod('show_'.$panel.'_layout',1);\n if($show == '0'){\n return;\n } \n\n $mobile_show = get_theme_mod('mobile_show_'.$panel.'_layout',0);\n $width = get_theme_mod('width_'.$panel.'_layout',1);\n $template = get_theme_mod('template_'.$panel.'_layout','default');\n\n include('template/'.$template.'.php');\n}", "title": "" }, { "docid": "20d3505e8f69509ef6bd2e9baa07ef60", "score": "0.60896474", "text": "public function bottom() {\r\n\t\t\tglobal $config;\r\n\t\t\t\r\n\t\t\trequire_once($config->installRoot . \"system/templates/\" . $this->template . \"/bottom.php\");\r\n\t\t}", "title": "" }, { "docid": "d5af3d961c842f587f94f367a7bd9c73", "score": "0.60668564", "text": "function jdoerck_custom_login_logo_foot()\n{\n echo '<div id=\"grid\" style=\"height: 100%; width: 100%; background-color: red;position: absolute;top: 0;left: 0;opacity: .5; z-index: 1;\"> </div>';\n}", "title": "" }, { "docid": "bf6212f7c8761f72a6bbde2fe996e9d8", "score": "0.59688044", "text": "function brand_load_widget() {\n\tregister_widget( 'buildkar_widget' );\n}", "title": "" }, { "docid": "0ec710f09187c9e115dd2e879d71b3c8", "score": "0.5962754", "text": "function abovenav_widget_area() {\n echo '<div id=\"above-nav-wrap\">';\n echo '<div class=\"uk-container uk-container-center\">';\n\techo beans_widget_area( 'abovenav' );\n\techo '</div>';\t\n echo '</div>';\n}", "title": "" }, { "docid": "d955e84bb4e54d86bef638a676dd68d9", "score": "0.5958305", "text": "function footer_widget_init()\n\t{\n\t\tregister_sidebar( array(\n\t\t\t'name' => __( 'Pie de pagina', 'Dreams Consulting' ),\n\t\t\t'id' => 'footer-1',\n\t\t\t'description' => __( 'Un área de widget para el pie de pagina', 'dreams consulting' ),\n\t\t\t'before_widget' => '<div id=\"%1$s\" class=\"headwidget %2$s\">',\n\t\t\t'after_widget' => '</div>',\n\n\t\t) );\n\n\t}", "title": "" }, { "docid": "ef725ab2b0f5058fdbf86f98e1dfd5d5", "score": "0.59473366", "text": "function greek_logo() { \n\techo '\n\t<div class=\"greek_logo widget\">\n\t\t<a href=\"http://www.goarch.org\" target=\"_blank\">';\n\t\t//<img src=\"' . get_template_directory_uri() . '/images/goarch_logo.png\">\n\t\techo '<span></span>\n\t\t</a>\n\t</div>\n\t';\n}", "title": "" }, { "docid": "e8096e0484dc0fea58065159c3dc18c7", "score": "0.5932576", "text": "function cherierenaephotography_widgets_init() {\n\n\tregister_sidebar( array(\n\t\t'name' => 'Footer',\n\t\t'id' => 'footer',\n\t\t'before_widget' => '<div>',\n\t\t'after_widget' => '</div>',\n\t\t'before_title' => '<h3>',\n\t\t'after_title' => '</h3>',\n\t) );\n\n}", "title": "" }, { "docid": "bfc61cbecff41bb8a36d158ab57d528a", "score": "0.59003425", "text": "function widgets() {\n\t\trequire_once (THEME_WIDGETS . '/text_widget_centered.php');\n\t\trequire_once (THEME_WIDGETS . '/themo_upcoming_events.php');\n\t}", "title": "" }, { "docid": "c60ced3ae5c82d7b903bf6daef86ed96", "score": "0.58991635", "text": "function sage_dashboard_widget_function()\n{\n //get theme options\n $disableLogo = sage_get_field('disable_logo');\n $updateLogo = sage_get_field('update_logo');\n $uploadLogo = sage_get_field('upload_logo');\n $controlPanelMessage = sage_get_field('control_panel_message');\n $adminLogo = asset_path('images/admin/logo-white.png');\n $printLogo = ($disableLogo) ?\n get_admin_url() . '/images/wordpress-logo.png' :\n (($updateLogo) ? (($uploadLogo) ? $uploadLogo : $adminLogo) : $adminLogo);\n $logoHeight = ($disableLogo) ? '63' : '75';\n\n // Entering the text between the quotes\n ?>\n <div class=\"admin-logo\"><img src=\"<?php _e($printLogo); ?>\" alt=\"<?php _e(get_bloginfo('name')); ?>\"\n height=\"<?php _e($logoHeight); ?>\"/></div>\n\n <?php\n if ($controlPanelMessage) :\n _e($controlPanelMessage);\n return;\n endif;\n ?>\n <p>Velkommen til din nye FrisørWeb hjemmeside</p>\n <p>Her finder du alle relevante indstilligner i forhold til opsætningen af din FrisørWeb hjemmeside. <br/>Du finder alle indstilligner i menuen til venstre.\n </p>\n <div class=\"clear\"></div>\n <?php\n}", "title": "" }, { "docid": "e6fae6020e3c69e01ed3fef251daf4ed", "score": "0.5808748", "text": "function undermode_tpl_logo(){\n\t$options = get_option('undermode_option');\n\t$logo = $options['undermode_page_logo'];\n\t$logo = wp_get_attachment_image($logo, 'full');\n\n\tif ($logo) {\n?>\n\t<div class=\"site-logo\"><?php echo $logo; ?></div>\n<?php\n\t}\n}", "title": "" }, { "docid": "f20e43c83fda0833e3e57b38968574c0", "score": "0.5802897", "text": "function ecc_base_widgets_init() {\n\tregister_sidebar(array(\n\t\t'name' => esc_html__('Site Footer First', 'galactus'),\n\t\t'id' => 'sitefooter-first',\n\t\t'description' => esc_html__('Add widgets here.', 'galactus'),\n\t\t'before_widget' => '<section class=\"block-sitefooter-prefooter-widget-first\">',\n\t\t'after_widget' => '</section>',\n\t\t'before_title' => '<h3 class=\"block-sitefooter-prefooter-title\">',\n\t\t'after_title' => '</h3>',\n\t));\n\n\tregister_sidebar(array(\n\t\t'name' => esc_html__('Site Footer Second', 'galactus'),\n\t\t'id' => 'sitefooter-second',\n\t\t'description' => esc_html__('Add widgets here.', 'galactus'),\n\t\t'before_widget' => '<section class=\"block-sitefooter-prefooter-widget-second\">',\n\t\t'after_widget' => '</section>',\n\t\t'before_title' => '<h3 class=\"block-sitefooter-prefooter-title\">',\n\t\t'after_title' => '</h3>',\n\t));\n\n\tregister_sidebar(array(\n\t\t'name' => esc_html__('Site Footer Third', 'galactus'),\n\t\t'id' => 'sitefooter-third',\n\t\t'description' => esc_html__('Add widgets here.', 'galactus'),\n\t\t'before_widget' => '<section class=\"block-sitefooter-prefooter-widget-third\">',\n\t\t'after_widget' => '</section>',\n\t\t'before_title' => '<h3 class=\"block-sitefooter-prefooter-title\">',\n\t\t'after_title' => '</h3>',\n\t));\n}", "title": "" }, { "docid": "4729c14333dec2bd18ccb37058a696e9", "score": "0.5795969", "text": "public function PlaceHoldersForFrontEnd();", "title": "" }, { "docid": "64b66a708498a82e690c30e388993916", "score": "0.5722002", "text": "function sp_header_right_widget_area() {\n\n\tgenesis_widget_area( 'header-right-widget', array(\n\t 'before' => sprintf( '<div class=\"header-widget-area\">' ),\n\t 'after' => '</div>',\n\t) );\n}", "title": "" }, { "docid": "51d73c05e9bd4a2cf3de5d7aae7861d4", "score": "0.571502", "text": "public function Header(){\n $this->Image('resources/images/marca_agua.jpg',0,0,250);\n $this->Image('resources/images/logoSegey.png',20,20,40); \n $this->Ln(20);\n }", "title": "" }, { "docid": "5eab40601723c0e4b65d3dadf8eca0f6", "score": "0.5706739", "text": "function sp_after_header_widget_area() {\n\n\tgenesis_widget_area( 'after-header', array(\n\t 'before' => sprintf( '<div class=\"after-header%s\"><div class=\"wrap\">', sp_flexible_widgets( 'after-header' ) ),\n\t 'after' => '</div></div>',\n\t) );\n}", "title": "" }, { "docid": "644fbd83ee3d4665972c3e8352c7126a", "score": "0.56929034", "text": "function load_widgets() {\n\n require LOGY_CORE . 'class-logy-widgets.php';\n\n // Register Login Widget\n register_widget( 'logy_login_widget' );\n\n // Register Registration Widget\n register_widget( 'logy_register_widget' );\n\n // Reset Password Widget\n register_widget( 'logy_reset_password_widget' );\n }", "title": "" }, { "docid": "5d1f38ce5425c343ec35f7918bcf4045", "score": "0.56568134", "text": "function fileworld_widgets_init() {\t\n\n\t\tregister_sidebar( array(\n\n\t\t'name' => __( 'Space On Home Page', 'wpb' ),\n\n\t\t'id' => 'footer-2',\n\n\t\t'description' => __( 'First space in middle of home page', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\n\t\n\n\t\n\n\t\tregister_sidebar( array(\n\n\t\t'name' => __('Space On Home Page', 'wpb' ),\n\n\t\t'id' => 'footer-3',\n\n\t\t'description' => __( 'Second space in middle of home page', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\n\t\n\n\t\n\n\t\tregister_sidebar( array(\n\n\t\t'name' => __('Space On Home Page', 'wpb' ),\n\n\t\t'id' => 'footer-4',\n\n\t\t'description' => __( 'Third space in middle of home page', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\t\n\t\n\t\n\t\tregister_sidebar( array(\n\n\t\t'name' => __('Space On Home Page', 'wpb' ),\n\n\t\t'id' => 'footer-4',\n\n\t\t'description' => __( 'Third space in middle of home page', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\t\n\t\n\t/*middle widget end*/\n\t\n\t\n\t\tregister_sidebar( array(\n\n\t\t'name' => __('WE ON THE RADIO SPACE', 'wpb' ),\n\n\t\t'id' => 'footer-5',\n\n\t\t'description' => __( 'WE ON THE RADIO SPACE', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\t\n\t\n\t\tregister_sidebar( array(\n\n\t\t'name' => __('NEWS LETTERS SPACE', 'wpb' ),\n\n\t\t'id' => 'footer-6',\n\n\t\t'description' => __( 'NEWS LETTERS SPACE', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\t\n\t\n\t\tregister_sidebar( array(\n\n\t\t'name' => __('ARTICLES & REPORTS SPACE', 'wpb' ),\n\n\t\t'id' => 'footer-7',\n\n\t\t'description' => __( 'ARTICLES & REPORTS SPACE', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\t\n\t\n\t\tregister_sidebar( array(\n\n\t\t'name' => __('Problem Solver', 'wpb' ),\n\n\t\t'id' => 'footer-8',\n\n\t\t'description' => __( 'PROBLEM SOLVER SPACE', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\t\n\t\n\t/********last widget space**********/\n\t\n\t\tregister_sidebar( array(\n\n\t\t'name' => __('Client Say Space', 'wpb' ),\n\n\t\t'id' => 'footer-9',\n\n\t\t'description' => __( 'Client Say Space', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\t\n\t\n\t\tregister_sidebar( array(\n\n\t\t'name' => __('call me space', 'wpb' ),\n\n\t\t'id' => 'footer-10',\n\n\t\t'description' => __( 'call me space', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\t\n\t\n\t\n\t\tregister_sidebar( array(\n\n\t\t'name' => __('Email space', 'wpb' ),\n\n\t\t'id' => 'footer-11',\n\n\t\t'description' => __( 'Email space', 'wpb' ),\n\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\n\t\t'after_widget' => '</div>',\n\n\t\t'before_title' => '<h3 class=\"widget-title\">',\n\n\t\t'after_title' => '</h3>',\n\n\t) );\n\t\n\n\t}", "title": "" }, { "docid": "8a175b6de5a92b42472cf005523bb469", "score": "0.5644357", "text": "public function loadFooter()\n {\n }", "title": "" }, { "docid": "946fa176416af93c1b7e09617d97989b", "score": "0.5633243", "text": "function template_zero_widget_area(){\n \tregister_sidebar( array(\n \t\t\t'name' => 'Widget Area Principale',\n \t\t\t'id' => 'widget-area-principale',\n \t\t\t'description' => __( 'The primary widget area', 'templatezero' ),\n \t\t\t'before_widget' => '<div id=\"principale\" class=\"contenitore-widget\">',\n \t\t\t'after_widget' => '</div>',\n \t\t\t'before_title' => '<h3 class=\"titolo-widget\">',\n \t\t\t'after_title' => '</h3>',\n\t) );\n\t\n\tregister_sidebar(\n \t\tarray(\n \t\t\t'name' => 'Widget Area Secondaria',\n \t\t\t'id' => 'widget-area-secondaria',\n \t\t\t'before_widget' => '<div id=\"%1$s\" class=\"contenitore-widget %2$s\">',\n \t\t\t'after_widget' => '</div>',\n \t\t\t'before_title' => '<h3 class=\"titolo-widget\">',\n \t\t\t'after_title' => '</h3>'\n\t\t)\n\t);\n\t\n\tregister_sidebar(\n\t\tarray(\n\t\t\t'name' => 'Pagina Singolo Articolo',\n \t\t\t'id' => 'pagina-singolo-articolo',\n \t\t\t'before_widget' => '<div id=\"%1$s\" class=\"contenitore-widget %2$s\">',\n \t\t\t'after_widget' => '</div>',\n \t\t\t'before_title' => '<h3 class=\"titolo-widget\">',\n \t\t\t'after_title' => '</h3>'\n\t\t)\n\t);\n\t\n\tregister_sidebar(\n\t\tarray(\n\t\t\t'name' => 'Footer Singolo Sinistra',\n \t\t\t'id' => 'footer-singolo-sinistra',\n \t\t\t'before_widget' => '<div id=\"%1$s\" class=\"contenitore-widget %2$s\">',\n \t\t\t'after_widget' => '</div>',\n \t\t\t'before_title' => '<h3 class=\"titolo-widget\">',\n \t\t\t'after_title' => '</h3>'\n\t\t)\n\t);\n\t\n\tregister_sidebar(\n\t\tarray(\n\t\t\t'name' => 'Footer Singolo Destra',\n \t\t\t'id' => 'footer-singolo-destra',\n \t\t\t'before_widget' => '<div id=\"%1$s\" class=\"contenitore-widget %2$s\">',\n \t\t\t'after_widget' => '</div>',\n \t\t\t'before_title' => '<h3 class=\"titolo-widget\">',\n \t\t\t'after_title' => '</h3>'\n\t\t)\n\t);\n }", "title": "" }, { "docid": "2467eb19b5abaa4a577fe31c5ab6e4bc", "score": "0.5628993", "text": "function InitLogo($src)\r\n{\r\n//! @desc Insert Image Logo on 1st page\r\n//! @return void\r\n if ($src == '') return;\r\n \r\n $this->y = $this->tMargin - 45;\r\n $this->x = $this->lMargin;\r\n $halfwidth = $this->pgwidth/2;\r\n $sizesarray = $this->Image($src, $this->GetX(), $this->GetY(), 0, 0,'','',false);\r\n //Alinhar imagem ao centro\r\n $this->x = ($halfwidth - ($sizesarray['WIDTH']/2));\r\n $sizesarray = $this->Image($src, $this->GetX(), $this->GetY(), 0, 0,'','http://www.montfort.org.br/');\r\n $this->Ln(1);\r\n //Contruir <HR> particular\r\n\t$this->SetLineWidth(0.3);\r\n\t$this->Line($this->x,$this->y,$this->x+$this->pgwidth,$this->y);\r\n\t$this->SetLineWidth(0.3);\r\n\t$this->Ln(2);\r\n}", "title": "" }, { "docid": "4f2def910a282c9c7c623eda2ae17727", "score": "0.56080604", "text": "function load_footer($filename=null,$data=null){\n\n \t$that=&get_instance();\n\n\t$prefix = 'footer';\n\n \tif(isset($filename)){\n\n \t\t$view=$prefix.'-'.$filename;\n\n \t}else{\n\n \t\t$view=$prefix;\n\n \t}\n\n \t$that->template->phtml($view,$data);\n\n }", "title": "" }, { "docid": "0425c6854d6902008899a7a0adea7ca5", "score": "0.56030697", "text": "function gingarte_widgets_init() {\n// function was defined here, which not everyone does.\n\n\tregister_sidebar( array(\n\t\t'name' => 'Main Footer',\n\t\t'id' => 'main_footer',\n\t\t'before_widget' => '<div>',\n\t\t'after_widget' => '</div>',\n\t\t'before_title' => '<h2 class=\"rounded\">',\n\t\t'after_title' => '</h2>',\n\t) );\n\n}", "title": "" }, { "docid": "12b5a81af5a3012e21e3c74e33221ada", "score": "0.55899805", "text": "function program_bottom_sidebar () {\ndynamic_sidebar('program-bottom'); \n}", "title": "" }, { "docid": "3fa5c97ba66a8024ac1869282f878c80", "score": "0.5584202", "text": "function charity_page_bottom() {\n\tif (is_active_sidebar('page-bottom')) {\n\t\techo charity_before_widget_area('page-bottom');\n\t\tdynamic_sidebar('page-bottom');\n\t\techo charity_after_widget_area('page-bottom');\n\t}\n}", "title": "" }, { "docid": "03a3d65202ece4d6f58aba506c4532a2", "score": "0.55762243", "text": "function sp_before_footer_widget_area() {\n\n\tgenesis_widget_area( 'before-footer', array(\n\t 'before' => sprintf( '<div class=\"before-footer%s\"><div class=\"wrap\">', sp_flexible_widgets( 'before-footer' ) ),\n\t 'after' => '</div></div>',\n\t) );\n}", "title": "" }, { "docid": "e048814797ca214aa4a599ba2f5a9804", "score": "0.5572965", "text": "function charity_index_bottom() {\n\tif (is_active_sidebar('index-bottom')) {\n\t\techo charity_before_widget_area('index-bottom');\n\t\tdynamic_sidebar('index-bottom');\n\t\techo charity_after_widget_area('index-bottom');\n\t}\n}", "title": "" }, { "docid": "b432344997a16eab59f3b13e1dca7bd8", "score": "0.55719066", "text": "public function renderBottom()\n {\n // set bottom 5 data and then render\n $this->configureBottom();\n $this->doRender();\n }", "title": "" }, { "docid": "f25f4d07fabc2a180f3fbbc2ea3b4f28", "score": "0.55618894", "text": "function altitude_inner_page_widgets() {\n\n\techo '<h2 class=\"screen-reader-text\">' . __( 'Main Content', 'altitude-pro' ) . '</h2>';\n\n\tgenesis_widget_area( 'inner-page-1', array(\n\t\t'before' => '<div id=\"inner-page-1\" class=\"inner-page-1\" tabindex=\"-1\"><div class=\"image-section\"><div class=\"flexible-widgets widget-area' . altitude_widget_area_class( 'inner-page-1' ) . '\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div></div>',\n\t) );\n\n\tgenesis_widget_area( 'inner-page-2', array(\n\t\t'before' => '<div id=\"inner-page-2\" class=\"inner-page-2\" tabindex=\"-1\"><div class=\"image-section\"><div class=\"flexible-widgets widget-area' . altitude_widget_area_class( 'inner-page-2' ) . '\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div></div>',\n\t) );\n\n\tgenesis_widget_area( 'inner-page-3', array(\n\t\t'before' => '<div id=\"inner-page-3\" class=\"inner-page-3\" tabindex=\"-1\"><div class=\"image-section\"><div class=\"flexible-widgets widget-area' . altitude_widget_area_class( 'inner-page-3' ) . '\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div></div>',\n\t) );\n\n\tgenesis_widget_area( 'inner-page-4', array(\n\t\t'before' => '<div id=\"inner-page-4\" class=\"inner-page-4\" tabindex=\"-1\"><div class=\"image-section\"><div class=\"flexible-widgets widget-area' . altitude_widget_area_class( 'inner-page-4' ) . '\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div></div>',\n\t) );\n\n\tgenesis_widget_area( 'inner-page-5', array(\n\t\t'before' => '<div id=\"inner-page-5\" class=\"inner-page-5\" tabindex=\"-1\"><div class=\"image-section\"><div class=\"flexible-widgets widget-area' . altitude_widget_area_class( 'inner-page-5' ) . '\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div></div>',\n\t) );\n\n\tgenesis_widget_area( 'inner-page-6', array(\n\t\t'before' => '<div id=\"inner-page-6\" class=\"inner-page-6\" tabindex=\"-1\"><div class=\"image-section\"><div class=\"flexible-widgets widget-area' . altitude_widget_area_class( 'inner-page-6' ) . '\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div></div>',\n\t) );\n\n\tgenesis_widget_area( 'inner-page-7', array(\n\t\t'before' => '<div id=\"inner-page-7\" class=\"inner-page-7\" tabindex=\"-1\"><div class=\"image-section\"><div class=\"flexible-widgets widget-area' . altitude_widget_area_class( 'inner-page-7' ) . '\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div></div>',\n\t) );\n\n}", "title": "" }, { "docid": "6bb6ce4e4b999e6d2df9cc73d932506a", "score": "0.5547345", "text": "function genesischild_footer_widget() {\n\tgenesis_widget_area ( 'footercontent', array(\n\t'before' => '<div class=\"footercontent\">',\n\t'after' => '</div>',));\n}", "title": "" }, { "docid": "60cee5e94321a1b46c8abac4a5c64cd7", "score": "0.5536668", "text": "function genesischild_preheader_widget() {\n\techo '<section class=\"preheadercontainer\"><div class=\"wrap\">';\n\tgenesis_widget_area ( 'preheaderleft' , array(\n\t'before' => '<aside class=\"preheaderleft first one-half\">',\n\t'after' => '</aside>',));\n\tgenesis_widget_area ( 'preheaderright' , array(\n\t'before' => '<aside class=\"preheaderright one-half\">',\n\t'after' => '</aside>',));\n\techo '</div></section>';\n}", "title": "" }, { "docid": "3dfd03220ca8c7666c2b57b6625c2925", "score": "0.5535376", "text": "function charity_single_bottom() {\n\tif (is_active_sidebar('single-bottom')) {\n\t\techo charity_before_widget_area('single-bottom');\n\t\tdynamic_sidebar('single-bottom');\n\t\techo charity_after_widget_area('single-bottom');\n\t}\n}", "title": "" }, { "docid": "63d0c913a1bfd79d6aec57cf8e5f9340", "score": "0.5527157", "text": "function hsmc_widgets_init() {\n\t$args = array(\n\t\t'name' => __( 'Footer Widgets', 'hsmc' ),\n\t\t'id' => 'footer-widgets',\n\t\t'description' => '',\n 'class' => 'hsmc-side',\n\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\t\t'after_widget' => '</div>',\n\t\t'before_title' => '<h2 class=\"widgettitle visuallyhidden\">',\n\t\t'after_title' => '</h2>' );\n\n\tregister_sidebar($args);\n}", "title": "" }, { "docid": "f54938dcd78df2cf211a520a64fab13b", "score": "0.55270225", "text": "function j20() { \n\techo '\n\t<div class=\"j20 widget\">\n\t\t<a href=\"http://www.journeytoorthodoxy.com\" target=\"_blank\">';\n\t\t//<img src=\"' . get_template_directory_uri() . '/images/adJTO300.png\">\n\t\techo '<span></span>\n\t\t</a>\n\t</div>\n\t';\n}", "title": "" }, { "docid": "d1fb2f3fa603089001022e5a5029fc56", "score": "0.55232775", "text": "function wpb_load_widget() {\n register_widget( 'multline_title_widget' );\n}", "title": "" }, { "docid": "00cfd9e26994baf72ecbf3206d5c3758", "score": "0.55195427", "text": "function ucw_load_widget() {\n\tregister_widget( 'ucw_widget' );\n}", "title": "" }, { "docid": "0f85b0e5de9ba6bbbf1db936a5fc3413", "score": "0.5516999", "text": "function widget_home() { ?>\n\t\t<?php if ( function_exists('dynamic_sidebar') && dynamic_sidebar('Home Widgets') ) : else : ?>\n\t\t<?php endif; ?>\n\t<?php }", "title": "" }, { "docid": "3f1e5f247df9877eb98b8e7324cc47f2", "score": "0.55068994", "text": "function shopia_widget_setup(){\n\n //sidebar\n register_sidebar( \n array(\n 'name' => 'Sidebar',\n 'id' => 'sidebar-blog',\n 'class' => 'custom',\n 'description' => 'Standard Sidebar',\n 'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h6 class=\"widget-title\">',\n 'after_title' => '</h6>'\n ) );\n\n //footer\n register_sidebar( \n array(\n 'name' => 'Footer Blog',\n 'id' => 'footer-blog',\n 'class' => 'custom',\n 'description' => 'Standard Footer',\n 'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h5 class=\"widget-title\">',\n 'after_title' => '</h5>'\n ) );\n register_sidebar( \n array(\n 'name' => 'Footer Shop 1',\n 'id' => 'footer-shop-1',\n 'class' => 'custom',\n 'description' => 'Standard Footer',\n 'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h5 class=\"widget-title\">',\n 'after_title' => '</h5>'\n ) );\n register_sidebar( \n array(\n 'name' => 'Footer Shop 2',\n 'id' => 'footer-shop-2',\n 'class' => 'custom',\n 'description' => 'Standard Footer',\n 'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h5 class=\"widget-title\">',\n 'after_title' => '</h5>'\n ) );\n register_sidebar( \n array(\n 'name' => 'Footer Shop 3',\n 'id' => 'footer-shop-3',\n 'class' => 'custom',\n 'description' => 'Standard Footer',\n 'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h5 class=\"widget-title\">',\n 'after_title' => '</h5>'\n ) );\n register_sidebar( \n array(\n 'name' => 'Footer Shop 4',\n 'id' => 'footer-shop-4',\n 'class' => 'custom',\n 'description' => 'Standard Footer',\n 'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h5 class=\"widget-title\">',\n 'after_title' => '</h5>'\n ) );\n}", "title": "" }, { "docid": "642614916b32400c7bfc62af678d67cf", "score": "0.54975677", "text": "function generate_widget_area($key){\n genesis_widget_area($key,\n array(\n 'before' => '<div class=\"'.$key.'\">'\n . '<div class=\"wrap\"',\n 'after' => '</div></div>',\n ));\n}", "title": "" }, { "docid": "c3e2ee4dcfaa9600f0ecc65d2b4a284a", "score": "0.5497448", "text": "function genesischild_postfooter_widget() {\n\techo '<div class=\"postfootercontainer\"><div class=\"wrap\">';\n\tgenesis_widget_area ( 'postfooterleft' , array(\n\t'before' => '<aside class=\"first one-half postfooterleft\">',\n\t'after' => '</aside>',));\n\tgenesis_widget_area ( 'postfooterright' , array(\n\t'before' => '<aside class=\"one-half postfooterright\">',\n\t'after' => '</aside>',));\n\techo '</div></div>';\n}", "title": "" }, { "docid": "e296573fda3abb710a8cbbdbc935658a", "score": "0.54907817", "text": "function caughtlearning_widgets_init() {\n \n\tregister_sidebar( array(\n\t\t'name' => 'Footer Widgets 1',\n\t\t'id' => 'footer_widgets_1',\n\t\t'before_widget' => '<div class=\"footer-widget-area\">',\n\t\t'after_widget' => '</div>',\n\t\t'before_title' => '<h4>',\n\t\t'after_title' => '</h4>',\n\t) );\n\n\t\tregister_sidebar( array(\n\t\t'name' => 'Footer Widgets 2',\n\t\t'id' => 'footer_widgets_2',\n\t\t'before_widget' => '<div class=\"footer-widget-area\">',\n\t\t'after_widget' => '</div>',\n\t\t'before_title' => '<h4>',\n\t\t'after_title' => '</h4>',\n\t) );\n\n\t}", "title": "" }, { "docid": "1d64127c44a4835efd401d78d8845988", "score": "0.5485355", "text": "function _loadTemplateBottom()\n\t{\n\t\tglobal $Itemid;\n\t\t$app =& JFactory::getApplication();\n\t\t$model =& $this->getModel();\n\t\t$table =& $model->getTable();\n\t\t$formid = (int)$model->getForm()->_id;\n\t\t$reffer = JRequest::getVar('REQUEST_URI', '', 'server');\n\t\t$this->hiddenFields = array();\n\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"option\\\" value=\\\"\".JRequest::getCmd('option', 'com_fabrik'). \"\\\" id = \\\"table_\".$table->id.\"_option\\\" />\";\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"orderdir\\\" value=\\\"\\\" id =\\\"table_\".$table->id.\"_orderdir\\\" />\";\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"orderby\\\" value=\\\"\\\" id = \\\"table_\".$table->id.\"_orderby\\\" />\";\n\t\tif (!$this->_isMambot) {\n\t\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"controller\\\" value=\\\"table\\\" />\";\n\t\t}\n\t\t//$$$rob if the content plugin has temporarily set the view to table then get view from origview var, if that doesn't exist\n\t\t//revert to view var. Used when showing table in article/blog layouts\n\t\t$view = JRequest::getVar('origview', JRequest::getVar('view', 'table'));\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"view\\\" value=\\\"\" . $view . \"\\\" id = \\\"table_\".$table->id.\"_view\\\" />\";\n\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"tableid\\\" value=\\\"\" . $model->_id . \"\\\" id = \\\"table_\".$table->id.\"_tableid\\\" />\";\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"Itemid\\\" value=\\\"\" . $Itemid . \"\\\" id = \\\"table_\".$table->id.\"_Itemid\\\" />\";\n\t\t//removed in favour of using table_{id}_limit dorop down box\n\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"fabrik_referrer\\\" value=\\\"\" . $reffer . \"\\\" />\";\n\t\t$this->hiddenFields[] = JHTML::_('form.token');\n\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"format\\\" id=\\\"table_\".$table->id.\"_format\\\" value=\\\"html\\\" />\";\n\t\t//$packageId = JRequest::getInt('_packageId', 0);\n\t\t// $$$ rob testing for ajax table in module\n\t\t$packageId = $model->_packageId;\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"_packageId\\\" value=\\\"$packageId\\\" id=\\\"table_\".$table->id.\"_packageId\\\" />\";\n\t\tif ($app->isAdmin()) {\n\t\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"c\\\" value=\\\"table\\\" />\";\n\t\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"task\\\" value=\\\"viewTable\\\" />\";\n\t\t} else {\n\t\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"task\\\" value=\\\"\\\" />\";\n\t\t}\n\t\t//needed for db join select\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"formid\\\" value=\\\"$formid\\\" />\";\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"fabrik_tableplugin_name\\\" value=\\\"\\\" />\";\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"fabrik_tableplugin_renderOrder\\\" value=\\\"\\\" />\";\n\n\t\t// $$$ hugh - added this so plugins have somewhere to stuff any random data they need during submit\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"fabrik_tableplugin_options\\\" value=\\\"\\\" />\";\n\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"incfilters\\\" value=\\\"1\\\" />\";\n\t\t$this->hiddenFields[] = \"<input type=\\\"hidden\\\" name=\\\"module\\\" value=\\\"{$this->_isMambot}\\\" />\";\n\t\t$this->hiddenFields = implode(\"\\n\", $this->hiddenFields);\n\t}", "title": "" }, { "docid": "1dbdc6edc815ed3e0fba5896f7438886", "score": "0.547413", "text": "function optimize_mikado_get_footer_top() {\n\n\t\t$parameters = array();\n\n\t\t$parameters['footer_top_border'] = optimize_mikado_get_footer_top_border();\n\t\t$parameters['footer_top_border_in_grid'] = (optimize_mikado_options()->getOptionValue('footer_top_border_in_grid') == 'yes') ? 'mkdf-in-grid' : '';\n\t\t$parameters['footer_in_grid'] = (optimize_mikado_options()->getOptionValue('footer_in_grid') == 'yes') ? true : false;\n\t\t$parameters['footer_top_classes'] = optimize_mikado_footer_top_classes();\n\t\t$parameters['footer_top_columns'] = optimize_mikado_options()->getOptionValue('footer_top_columns');\n\n\t\toptimize_mikado_get_module_template_part('templates/parts/footer-top', 'footer', '', $parameters);\n\n\t}", "title": "" }, { "docid": "1d712abfb5f5e3cf5590bcef9fafa4d7", "score": "0.54655915", "text": "function utility_bar() {\n \n\techo '<div class=\"utility-bar\"><div class=\"wrap\">';\n \n\tgenesis_widget_area( 'utility-bar-left', array(\n\t\t'before' => '<div class=\"utility-bar-left\">',\n\t\t'after' => '</div>',\n\t) );\n \n\tgenesis_widget_area( 'utility-bar-right', array(\n\t\t'before' => '<div class=\"utility-bar-right\">',\n\t\t'after' => '</div>',\n\t) );\n \n\techo '</div></div>';\n \n}", "title": "" }, { "docid": "85b37f67498e6838ed37719857b9e9c3", "score": "0.5459139", "text": "function themefooter() {\r\n global $index;\r\n if ($index == 1) {\r\n\techo \"</td><td><img src=\\\"themes/NukeNews/images/pixel.gif\\\" width=\\\"15\\\" height=\\\"1\\\" border=\\\"0\\\" alt=\\\"\\\"></td><td valign=\\\"top\\\" width=\\\"150\\\">\\n\";\r\n\tblocks(right);\r\n }\r\n echo \"</td></tr></table>\\n\";\r\n echo \"<br>\";\r\n OpenTable();\r\n footmsg();\r\n CloseTable();\r\n}", "title": "" }, { "docid": "bcc7f39e76ee4f76b9b9bf5ca1e8b843", "score": "0.54577243", "text": "public function widgets_init()\n {\n register_sidebar(array(\n 'name' => 'Middle Bottom',\n 'id' => 'middle-bottom',\n 'description' => 'Add widgets here to appear in content bottom.',\n 'before_widget' => '<div id=\"%1$s\" class=\"%2$s uk-text-meta menu-area\">',\n 'after_widget' => '</div>',\n 'before_title' => '<div class=\"\">',\n 'after_title' => '</div>'\n ));\n\n register_sidebar(array(\n 'name' => 'Single Property Sidebar',\n 'id' => 'sidebar-shop',\n 'description' => 'Add widgets here to appear in property single page right position.',\n 'before_widget' => '<aside id=\"%1$s\" class=\"%2$s single-side-box\">',\n 'after_widget' => '</aside>',\n 'before_title' => '<div class=\"aside-title\"><h5>',\n 'after_title' => '</h5></div>'\n ));\n\n register_sidebar(array(\n 'name' => 'Offering Sidebar',\n 'id' => 'sidebar-offering',\n 'description' => 'Add widgets here to appear in offer right position.',\n 'before_widget' => '<aside id=\"%1$s\" class=\"%2$s single-side-box\">',\n 'after_widget' => '</aside>',\n 'before_title' => '<div class=\"aside-title\"><h5>',\n 'after_title' => '</h5></div>'\n ));\n\n register_sidebar([\n 'name' => 'Footer left',\n 'id' => 'footer-left',\n ]);\n\n register_sidebar([\n 'name' => 'Footer Middle',\n 'id' => 'footer-middle',\n ]);\n\n register_sidebar([\n 'name' => 'Footer Right',\n 'id' => 'footer-right',\n ]);\n }", "title": "" }, { "docid": "6d703c6e41cd3b836bcd57dc39d5c680", "score": "0.54575646", "text": "function um_admin_header_image() {\n\n}", "title": "" }, { "docid": "488560d160ee802408d82dd4a7a1121b", "score": "0.54568136", "text": "function genesischild_hero_widget() {\n\tgenesis_widget_area ( 'hero', array(\n\t'before' => '<section class=\"herocontainer\"><div class=\"wrap hero\">',\n\t'after' => '</div></section>',));\n}", "title": "" }, { "docid": "1ab327a5cc5ee9f3cf565f2a370fb2bb", "score": "0.54533225", "text": "function scratch_add_home_welcome(){\n generate_widget_area(HOME_WELCOME_KEY);\n}", "title": "" }, { "docid": "d01978b09c4a0ff1df36bef37342d766", "score": "0.54529536", "text": "function genesischild_extra_widgets() {\t\n\tgenesis_register_sidebar( array(\n\t'id' => 'preheaderleft',\n\t'name' => __( 'PreHeaderLeft', 'genesischild' ),\n\t'description' => __( 'This is the preheader left area', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'preheaderright',\n\t'name' => __( 'PreHeaderRight', 'genesischild' ),\n\t'description' => __( 'This is the preheader right area', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'hero',\n\t'name' => __( 'Hero Home Page', 'genesischild' ),\n\t'description' => __( 'This is the Hero Home Page area', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'optin',\n\t'name' => __( 'Optin', 'genesischild' ),\n\t'description' => __( 'This is the optin area', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'home-top',\n\t'name' => __( 'Home Top', 'genesischild' ),\n\t'description' => __( 'This is the home top area', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'home-middle',\n\t'name' => __( 'Home Middle', 'genesischild' ),\n\t'description' => __( 'This is the home middle area', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'home-bottom',\n\t'name' => __( 'Home Bottom', 'genesischild' ),\n\t'description' => __( 'This is the home bottom area', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'before-entry',\n\t'name' => __( 'Before Entry', 'genesischild' ),\n\t'description' => __( 'This is the before content area', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'footerwidgetheader',\n\t'name' => __( 'Footer Widget Header', 'genesischild' ),\n\t'description' => __( 'This is for the Footer Widget Headline', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'footercontent',\n\t'name' => __( 'Footer', 'genesischild' ),\n\t'description' => __( 'This is the general footer area', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'postfooterleft',\n\t'name' => __( 'Post Footer Left', 'genesischild' ),\n\t'description' => __( 'This is the post footer left area', 'genesischild' ),\n\t) );\n\tgenesis_register_sidebar( array(\n\t'id' => 'postfooterright',\n\t'name' => __( 'Post Footer Right', 'genesischild' ),\n\t'description' => __( 'This is the post footer right area', 'genesischild' ),\n\t) );\n}", "title": "" }, { "docid": "06dc448798db65977eadc3460f8e5fe8", "score": "0.54499656", "text": "function go_green_tips_load_widgets() {\r\n\tregister_widget( 'Go_Green_Tips_Widget' );\r\n}", "title": "" }, { "docid": "bf68b1622a27febcbb83f8a84f99fa55", "score": "0.5438245", "text": "function drawTemplate(){\n require_once($this->template);\n }", "title": "" }, { "docid": "67380789c3a584104f8e1362e7f6d772", "score": "0.54375327", "text": "function widget_area_footer_plugin() {\n\n\tregister_sidebar( array(\n\t\t'name' => 'Optimizaclick Widget Area',\n\t\t'id' => 'widget_area_footer_plugin',\n\t\t'before_widget' => '<div class=\"widget\">',\n\t\t'after_widget' => '</div>',\n\t\t'before_title' => '<h3>',\n\t\t'after_title' => '</h3>',\n\t) );\n}", "title": "" }, { "docid": "3d4b9c851cee3a672ada54b90dfd1104", "score": "0.542821", "text": "function get_cp_footer()\n\t{\n\t\t$ci =& get_instance();\n\t\t$ci->load->view('admin_template/layout/footer');\n\t}", "title": "" }, { "docid": "d83c77f762d7e4f77209864404424ca7", "score": "0.5418594", "text": "function koala_homepage_widgets() {\n\n\techo '<h2 class=\"screen-reader-text\">' . __( 'Main Content', 'koala' ) . '</h2>';\n\n\tgenesis_widget_area( 'home-section-1', array(\n\t\t'before' => '<div class=\"home-odd home-section-1 widget-area\"><div class=\"full-height\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div>',\n\t) );\n\n\tgenesis_widget_area( 'home-section-2', array(\n\t\t'before' => '<div class=\"home-even home-section-2 widget-area\"><div class=\"wrap\">',\n\t\t'after' => '</div></div>',\n\t) );\n\n\tgenesis_widget_area( 'home-section-3', array(\n\t\t'before' => '<div class=\"home-odd home-section-3 widget-area\"><div class=\"wrap\">',\n\t\t'after' => '</div></div>',\n\t) );\n\n\tgenesis_widget_area( 'home-section-4', array(\n\t\t'before' => '<div class=\"home-even home-section-4 widget-area\"><div class=\"wrap\">',\n\t\t'after' => '</div></div>',\n\t) );\n\n\tgenesis_widget_area( 'home-section-5', array(\n\t\t'before' => '<div class=\"home-odd home-section-5 widget-area\"><div class=\"wrap\">',\n\t\t'after' => '</div></div>',\n\t) );\n\n\tgenesis_widget_area( 'home-section-6', array(\n\t\t'before' => '<div class=\"home-even home-section-6 widget-area\"><div class=\"wrap\">',\n\t\t'after' => '</div></div>',\n\t) );\n\n\tgenesis_widget_area( 'home-section-7', array(\n\t\t'before' => '<div class=\"home-odd home-section-7 widget-area\"><div class=\"wrap\">',\n\t\t'after' => '</div></div>',\n\t) );\n\n\tgenesis_widget_area( 'home-section-8', array(\n\t\t'before' => '<div class=\"home-even home-section-8 widget-area\"><div class=\"wrap\">',\n\t\t'after' => '</div></div>',\n\t) );\n\n}", "title": "" }, { "docid": "8f37965bcc8090b56f562005d51b260f", "score": "0.5418157", "text": "function altitude_front_page_widgets() {\n\n\tgenesis_widget_area( 'front-page-1', array(\n\t\t'before' => '<div id=\"front-page-1\" class=\"front-page-1\"><div class=\"image-section\"><div class=\"flexible-widgets widget-area' . altitude_widget_area_class( 'front-page-1' ) . '\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div></div>',\n\t) );\n\n\tgenesis_widget_area( 'front-page-2', array(\n\t\t'before' => '<div id=\"front-page-2\" class=\"front-page-2\"><div class=\"solid-section\"><div class=\"flexible-widgets widget-area' . altitude_widget_area_class( 'front-page-2' ) . '\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div></div>',\n\t) );\n\n\tgenesis_widget_area( 'front-page-3', array(\n\t\t'before' => '<div id=\"front-page-3\" class=\"front-page-3\"><div class=\"image-section\"><div class=\"flexible-widgets widget-area' . altitude_widget_area_class( 'front-page-3' ) . '\"><div class=\"wrap\">',\n\t\t'after' => '</div></div></div></div>',\n\t) );\n\n\t// I add this widget below the footer because featured projects displays below the content\n\t// TODO: Find a cleaner solution for this\n\tadd_action('genesis_before_footer', 'jt_reviews_widget');\n\n}", "title": "" }, { "docid": "e0022a9f359b48af55f1c5f4c562403b", "score": "0.5413914", "text": "function widget_germanwotdwidget_init() \r\n{\r\n\tif ( !function_exists('register_sidebar_widget') )\r\n\t{\r\n\t\treturn;\r\n\t}\r\n\t\t\r\n\tfunction widget_germanwotdwidget($args) \r\n {\r\n\t\textract($args);\r\n\t\t\t\r\n\t\techo $before_widget;\r\n\t\techo $before_title .\"German Word of the Day\". $after_title;\r\n\r\n\t\t$wotd_code = \"<script src='http://www.hitsalive.com/german_wotd/german.php?link=WP' language='javascript' type='text/javascript'></script>\";\r\n \r\n\t\techo '<div style=\"margin-top:5px;text-align:left;\">'.$wotd_code.'</div>';\r\n\t\techo $after_widget;\r\n\t}\r\n\r\n\t\r\n\tfunction widget_germanwotdwidget_control() \r\n {\r\n\t\techo '<p style=\"text-align:left;\">Brought to you by <b>Declan Software</b> - Language Learning Software for serious students.</p>';\r\n\t}\r\n\r\n\tregister_widget_control(array('German Word of the Day', 'widgets'), 'widget_germanwotdwidget_control', 200, 200);\r\n\r\n\tregister_sidebar_widget(array('German Word of the Day', 'widgets'), 'widget_germanwotdwidget');\r\n}", "title": "" }, { "docid": "4536c5daca75e51f5289309c7dea41dc", "score": "0.54118615", "text": "function ap_widgets_area_init() {\n\tregister_sidebar(\n\t\tarray(\n\t\t\t'id' => 'default_sidebar', \n\t\t\t'name' => 'Default sidebar', \n\t\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\t\t\t'after_widget' => '</div>',\n\t\t\t'before_title' => '<h3 class=\"widget-title\">', \n\t\t\t'after_title' => '</h3>'\n\t\t)\n\t); \n\tregister_sidebar(\n\t\tarray(\n\t\t\t'id' => 'top', \n\t\t\t'name' => 'Top area',\n\t\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\t\t\t'after_widget' => '</div>',\n\t\t\t'before_title' => '<h3 class=\"widget-title\">', \n\t\t\t'after_title' => '</h3>'\n\t\t)\n\t);\n\tregister_sidebar(\n\t\tarray(\n\t\t\t'id' => 'footer_1', \n\t\t\t'name' => 'Footer first column', \n\t\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\t\t\t'after_widget' => '</div>',\n\t\t\t'before_title' => '<h3 class=\"widget-title\">', \n\t\t\t'after_title' => '</h3>'\n\t\t)\n\t);\n\tregister_sidebar(\n\t\tarray(\n\t\t\t'id' => 'footer_2', \n\t\t\t'name' => 'Footer second column', \n\t\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\t\t\t'after_widget' => '</div>',\n\t\t\t'before_title' => '<h3 class=\"widget-title\">', \n\t\t\t'after_title' => '</h3>'\n\t\t)\n\t);\n\tregister_sidebar(\n\t\tarray(\n\t\t\t'id' => 'footer_3', \n\t\t\t'name' => 'Footer third column', \n\t\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\t\t\t'after_widget' => '</div>',\n\t\t\t'before_title' => '<h3 class=\"widget-title\">', \n\t\t\t'after_title' => '</h3>'\n\t\t)\n\t);\n\tregister_sidebar(\n\t\tarray(\n\t\t\t'id' => 'footer_4', \n\t\t\t'name' => 'Footer fourth column', \n\t\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\t\t\t'after_widget' => '</div>',\n\t\t\t'before_title' => '<h3 class=\"widget-title\">', \n\t\t\t'after_title' => '</h3>'\n\t\t)\n\t);\n\tglobal $ap_options;\n\t$ap_sidebars = $ap_options['ap_widget_areas_manager']['val'];\n\tforeach ($ap_sidebars as $ap_sidebar) {\n\t\tregister_sidebar(\n\t\t\tarray(\n\t\t\t\t'id' => $ap_sidebar, \n\t\t\t\t'name' => $ap_sidebar, \n\t\t\t\t'before_widget' => '<div id=\"%1$s\" class=\"widget %2$s\">',\n\t\t\t\t'after_widget' => '</div>',\n\t\t\t\t'before_title' => '<h3 class=\"widget-title\">', \n\t\t\t\t'after_title' => '</h3>'\n\t\t\t)\n\t\t);\n\t}\n}", "title": "" }, { "docid": "ddf6b5115a62219c243667bd632a3ebd", "score": "0.54092085", "text": "function crea_area_widgets() {\n $sidebarArgs = array(\n 'name' => 'Sidebar Widget',\n 'id' => 'sidebar',\n 'description' => 'Sidebar Widgets Area',\n 'before_widget' => '<div class=\"widget %2$s\">', //%2$s -> Hace que se mantenga la clase de widgets\n 'after_widget' => '</div>'\n );\n register_sidebar($sidebarArgs);\n \n $footerArgs = array(\n 'name' => 'Footer Widget',\n 'id' => 'footer',\n 'description' => 'Footer Widgets Area',\n 'before_widget' => '<div class=\"widget %2$s\">',\n 'after_widget' => '</div>'\n );\n register_sidebar($footerArgs);\n}", "title": "" }, { "docid": "cc9ad324c7e315847054247a70d0b612", "score": "0.5404604", "text": "function footer_template() {\n global $CFG, $PAGE, $OUTPUT;\n // Footer Blocks.\n $copyright = theme_enlightlite_get_setting('copyright');\n $copyright = theme_enlightlite_lang($copyright);\n $fb1title = theme_enlightlite_get_setting('footerbtitle1', 'format_html');\n $fb1title = theme_enlightlite_lang($fb1title);\n $fb2title = theme_enlightlite_get_setting('footerbtitle2', 'format_html');\n $fb2title = theme_enlightlite_lang($fb2title);\n $fb3title = theme_enlightlite_get_setting('footerbtitle3', 'format_html');\n $fb3title = theme_enlightlite_lang($fb3title);\n $fb4title = theme_enlightlite_get_setting('footerbtitle4', 'format_html');\n $fb4title = theme_enlightlite_lang($fb4title);\n $footerblink1 = theme_enlightlite_get_setting('footerdesc1');\n $footerblink1 = theme_enlightlite_lang($footerblink1);\n $sociallinks = theme_enlightlite_social_links();\n $footerblink3 = theme_enlightlite_generate_links('footerblink3');\n $footerblink2 = theme_enlightlite_generate_links('footerblink2');\n\n $backtotopstatus = theme_enlightlite_get_setting('backToTop_status');\n\n $footerb1 = theme_enlightlite_get_setting('footerb1_status');\n $footerb2 = theme_enlightlite_get_setting('footerb2_status');\n $footerb3 = theme_enlightlite_get_setting('footerb3_status');\n $footerb4 = theme_enlightlite_get_setting('footerb4_status');\n $totalenable = $footerb1 + $footerb2 + $footerb3 + $footerb4;\n $footermain = 1;\n\n switch($totalenable) {\n case 4 :\n $colclass = 'col-md-3';\n break;\n\n case 3:\n $colclass = 'col-md-4';\n break;\n\n case 2:\n $colclass = 'col-md-6';\n break;\n\n case 1:\n $colclass = 'col-md-12';\n break;\n\n case 0:\n $footermain = 0;\n $colclass = '';\n break;\n\n default:\n $colclass = 'col-md-3';\n }\n $footerb4iconclass = theme_enlightlite_footer_address('true');\n $footericonclass = ($footerb4iconclass == \"true\") ? \"footer-small-socials\" : \"\";\n $footeraddress = theme_enlightlite_footer_address();\n\n $templatecontext = [\n 'output' => $OUTPUT,\n \"copyright\" => $copyright,\n \"fb1title\" => $fb1title,\n \"fb2title\" => $fb2title,\n \"fb3title\" => $fb3title,\n \"fb4title\" => $fb4title,\n \"social_links\" => $sociallinks,\n \"footerblink3\" => $footerblink3,\n \"footerblink2\" => $footerblink2,\n \"footerblink1\" => $footerblink1,\n \"footerb1\" => $footerb1,\n \"footerb2\" => $footerb2,\n \"footerb3\" => $footerb3,\n \"footerb4\" => $footerb4,\n \"footerAddress\" => $footeraddress,\n 'footericonclass' => $footericonclass,\n \"colClass\" => $colclass,\n \"footermain\" => $footermain,\n \"backToTop\" => $backtotopstatus,\n ];\n return $templatecontext;\n}", "title": "" }, { "docid": "2db9bd27fc5e5b25e9370de12e4c29eb", "score": "0.5404543", "text": "function sp_before_header_widget_area() {\n\n\tgenesis_widget_area( 'before-header', array(\n\t 'before' => sprintf( '<div class=\"before-header%s\"><div class=\"wrap\">', sp_flexible_widgets( 'before-header' ) ),\n\t 'after' => '</div></div>',\n\t) );\n}", "title": "" }, { "docid": "d12e599ec849a539b2e733f49fe23a34", "score": "0.53910017", "text": "function Header() {\r\n $bMargin = $this->getBreakMargin();\r\n // get current auto-page-break mode\r\n $auto_page_break = $this->AutoPageBreak;\r\n // disable auto-page-break\r\n $this->SetAutoPageBreak(false, 0);\r\n // set bacground image\r\n $img_file = '../../config/templates/cmr.png';\r\n $this->Image($img_file, 0, 0, 210, 297, '', '', '', false, 300, '', false, false, 0);\r\n // restore auto-page-break status\r\n $this->SetAutoPageBreak($auto_page_break, $bMargin);\r\n // set the starting point for the page content\r\n $this->setPageMark();\r\n }", "title": "" }, { "docid": "df3a3758d772ce99c8f539f843ba2e2c", "score": "0.53899366", "text": "function get_header_widget($contentStyleOpen=\"\",$decoratorStyleOpen=\"\",$decoratorStyleClose=\"\",$contentStyleClose=\"\") {\n // add_action('wp_enqueue_scripts', 'login_in_widget_styles'); \n if(!empty ($contentStyleOpen)){\n $output.=$contentStyleOpen;\n }\n \n if(!empty ($decoratorStyleOpen)){\n $output.=$decoratorStyleOpen;\n }\n if ( !is_user_logged_in() ){\n $output.=$this->createLink(wp_login_url( get_permalink()),__(\"TitleLogin\",self::$domain),__(\"Login\",self::$domain));\n if(!empty ($decoratorStyleOpen)){\n\t $output.=$decoratorStyleClose.$decoratorStyleOpen;\n }\n\t\t $output.= wp_register('', '',false);\n } else{\n $currentUser = wp_get_current_user();\n\t $name = __(\"Welcome\",self::$domain).\" \".$currentUser->user_login; \n $output.= $this->createLink(admin_url( 'profile.php' ),__(\"TitleProfileModify\",self::$domain),$name);\n if(!empty ($decoratorStyleOpen)){\n $output.=$decoratorStyleClose.$decoratorStyleOpen;\n }\n\t\t $output.= $this->createLink(wp_logout_url( get_permalink() ),__(\"TitleLogout\",self::$domain),__(\"Logout\",self::$domain));\n\t\t}\n if(!empty ($decoratorStyleClose)){\n\t\t $output.=$decoratorStyleClose;\n }\n if(!empty ($contentStyleClose)){\n $output.=$contentStyleClose;\n\t }\n return $output;\n }", "title": "" }, { "docid": "6fcf61e8c20843d8a1f260fc5ad32bbb", "score": "0.53860384", "text": "function tool_social_load_widget() {\n\tregister_widget('tool_social_widget');\n}", "title": "" }, { "docid": "05e4603f68d823b8d361316fc4b29902", "score": "0.5376471", "text": "function gents_widgets_init_child() {\n\n register_sidebar(array(\n 'name' => __('Header bar', 'gents'),\n 'description' => __('header.php', 'gents'),\n 'id' => 'header-bar',\n 'before_title' => '<div class=\"header-title\"><h4>',\n 'after_title' => '</h4></div>',\n 'before_widget' => '<div id=\"%1$s\" class=\"widget-wrapper %2$s\">',\n 'after_widget' => '</div>'\n ));\n}", "title": "" }, { "docid": "ab341647bae91664ec472438400f924a", "score": "0.5374484", "text": "protected function drawMainHeader()\n\t{\n $this->yloc = self::$Y_TOP - 5;\n\t}", "title": "" }, { "docid": "a232f3db6c240a754987f89ff5adfb88", "score": "0.53718835", "text": "function tutsplus_widgets_init() {\n \n // First footer widget area, located in the footer. Empty by default.\n register_sidebar( array(\n 'name' => __( 'Top Text Area', 'tutsplus' ),\n 'id' => 'header-area',\n 'description' => __( 'The Header area', 'tutsplus' ),\n 'before_widget' => '<div id=\"%1$s\" class=\"widget-container %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h3 class=\"widget-title\">',\n 'after_title' => '</h3>',\n ) );\n \n // Second Footer Widget Area, located in the footer. Empty by default.\n register_sidebar( array(\n 'name' => __( 'Top Flag Area', 'tutsplus' ),\n 'id' => 'top-flag-area',\n 'description' => __( 'The Top flag area', 'tutsplus' ),\n 'before_widget' => '<div id=\"%1$s\" class=\"widget-container %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h3 class=\"widget-title\">',\n 'after_title' => '</h3>',\n ) );\n \n // Third Footer Widget Area, located in the footer. Empty by default.\n register_sidebar( array(\n 'name' => __( 'Top Search Area', 'tutsplus' ),\n 'id' => 'search-area',\n 'description' => __( 'The Search area', 'tutsplus' ),\n 'before_widget' => '<div id=\"%1$s\" class=\"widget-container %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h3 class=\"widget-title\">',\n 'after_title' => '</h3>',\n ) );\n \n // Fourth Footer Widget Area, located in the footer. Empty by default.\n register_sidebar( array(\n 'name' => __( 'Top Login & Donate Area', 'tutsplus' ),\n 'id' => 'login-donate-area',\n 'description' => __( 'The Login & Donate link area', 'tutsplus' ),\n 'before_widget' => '<div id=\"%1$s\" class=\"widget-container %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h3 class=\"widget-title\">',\n 'after_title' => '</h3>',\n ) );\n\t\n\t\n\t register_sidebar( array(\n 'name' => __( 'Header Logo Area', 'tutsplus' ),\n 'id' => 'header-logo-area',\n 'description' => __( 'The Header Logo area', 'tutsplus' ),\n 'before_widget' => '<div id=\"%1$s\" class=\"widget-container %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h3 class=\"widget-title\">',\n 'after_title' => '</h3>',\n ) );\n\t register_sidebar( array(\n 'name' => __( 'Footer Area - 1', 'tutsplus' ),\n 'id' => 'footer-area-1',\n 'description' => __( 'The Footer area', 'tutsplus' ),\n 'before_widget' => '<div id=\"%1$s\" class=\"widget-container %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h3 class=\"widget-title\">',\n 'after_title' => '</h3>',\n ) );\n\t register_sidebar( array(\n 'name' => __( 'Footer Area - 2', 'tutsplus' ),\n 'id' => 'footer-area-2',\n 'description' => __( 'The Footer area', 'tutsplus' ),\n 'before_widget' => '<div id=\"%1$s\" class=\"widget-container %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h3 class=\"widget-title\">',\n 'after_title' => '</h3>',\n ) );\n\t register_sidebar( array(\n 'name' => __( 'Footer Area - 3', 'tutsplus' ),\n 'id' => 'footer-area-3',\n 'description' => __( 'The Footer area', 'tutsplus' ),\n 'before_widget' => '<div id=\"%1$s\" class=\"widget-container %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h3 class=\"widget-title\">',\n 'after_title' => '</h3>',\n ) );\n\t register_sidebar( array(\n 'name' => __( 'Copyright Area', 'tutsplus' ),\n 'id' => 'copyright-area',\n 'description' => __( 'The Copyright Text area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '',\n 'after_title' => '',\n ) );\n\t register_sidebar( array(\n 'name' => __( 'Slider Area', 'tutsplus' ),\n 'id' => 'slider-area',\n 'description' => __( 'The Slider Widget area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '',\n 'after_title' => '',\n ) );\n\t\n\t register_sidebar( array(\n 'name' => __( 'Donate Text & Button Area', 'tutsplus' ),\n 'id' => 'donate-text-area',\n 'description' => __( 'The Donate text area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '',\n 'after_title' => '',\n ) );\n\t\n\tregister_sidebar( array(\n 'name' => __( 'Services Area', 'tutsplus' ),\n 'id' => 'services-area',\n 'description' => __( 'The Services area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '',\n 'after_title' => '',\n ) );\n\t\n\tregister_sidebar( array(\n 'name' => __( 'News Title Area', 'tutsplus' ),\n 'id' => 'news-title-area',\n 'description' => __( 'The Just World News Title Area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '<h2 class=\"widget-title\">',\n 'after_title' => '</h2>',\n ) );\n\t\n\tregister_sidebar( array(\n 'name' => __( 'Background Section - 4 Area', 'tutsplus' ),\n 'id' => 'background-section4-area',\n 'description' => __( 'The Background for section - 4 area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '',\n 'after_title' => '',\n ) );\n\t\n\tregister_sidebar( array(\n 'name' => __( 'Social Area', 'tutsplus' ),\n 'id' => 'social-area',\n 'description' => __( 'The social area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '',\n 'after_title' => '',\n ) );\n\tregister_sidebar( array(\n 'name' => __( 'Email News Latter Area', 'tutsplus' ),\n 'id' => 'news-latter-area',\n 'description' => __( 'The News Latter area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '',\n 'after_title' => '',\n ) );\n\t\n\tregister_sidebar( array(\n 'name' => __( 'Right Sidebar Just World Area', 'tutsplus' ),\n 'id' => 'right-sidebar-justworld',\n 'description' => __( 'The Just World area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '<h2>',\n 'after_title' => '</h2>',\n ) );\n\t register_sidebar( array(\n 'name' => __( 'Right Sidebar News Latter Area', 'tutsplus' ),\n 'id' => 'right-sidebar-newslatter',\n 'description' => __( 'The Right Sidebar News Letter area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '<h2>',\n 'after_title' => '</h2>',\n ) );\n\t\n\tregister_sidebar( array(\n 'name' => __( 'Right Sidebar Map Area', 'tutsplus' ),\n 'id' => 'right-sidebar-map',\n 'description' => __( 'The Right Sidebar Map Image area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '<h2>',\n 'after_title' => '</h2>',\n ) );\n\t\n\t\n\tregister_sidebar( array(\n 'name' => __( 'Right Sidebar Video Area', 'tutsplus' ),\n 'id' => 'right-sidebar-video',\n 'description' => __( 'The Right Sidebar video area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '<h2>',\n 'after_title' => '</h2>',\n ) );\n\n\t\n\tregister_sidebar( array(\n 'name' => __( 'Right Sidebar Categories Area', 'tutsplus' ),\n 'id' => 'right-sidebar-category',\n 'description' => __( 'The Right Sidebar Categories area', 'tutsplus' ),\n 'before_widget' => '',\n 'after_widget' => '',\n 'before_title' => '<h2>',\n 'after_title' => '</h2>',\n ) );\n \n}", "title": "" }, { "docid": "a6bbbfbb23c4786fcf54a82d36b58a36", "score": "0.5366974", "text": "function widgets_init() {\n register_sidebar( array(\n 'name' => 'Widgety w menu',\n 'id' => 'sidebar-0',\n 'before_widget' => '<div class=\"nav_menu %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h2>',\n 'after_title' => '</h2>',\n ) );\n register_sidebar( array(\n 'name' => 'Widgety w prawej kolumnie',\n 'id' => 'sidebar-1',\n 'before_widget' => '<div class=\"widget %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h1>',\n 'after_title' => '</h1>',\n ) );\n register_sidebar( array(\n 'name' => 'Widgety w stopce',\n 'id' => 'sidebar-2',\n 'before_widget' => '<div class=\"widget footer-widget %2$s\">',\n 'after_widget' => '</div>',\n 'before_title' => '<h1>',\n 'after_title' => '</h1>',\n ) );\n}", "title": "" }, { "docid": "a5d58fa5bb10d1c6cd3c2f2e601e024a", "score": "0.5366842", "text": "public function render(){\n\t\t$prefix = su_cmpt();\n\t\t\n\t\t$background = (isset($this->addon->settings->background) && $this->addon->settings->background) ? $this->addon->settings->background : '#ffffff';\n\t\t$color = (isset($this->addon->settings->color) && $this->addon->settings->color) ? $this->addon->settings->color : '#333333';\n\t\t$shadow = (isset($this->addon->settings->shadow) && $this->addon->settings->shadow) ? $this->addon->settings->shadow : '0 1px 2px #eeeeee';\n\t\t$border = (isset($this->addon->settings->border) && $this->addon->settings->border) ? $this->addon->settings->border : '1px solid #cccccc';\n\t\t$radius = (isset($this->addon->settings->radius) && $this->addon->settings->radius) ? $this->addon->settings->radius : '0';\n\t\t$content = (isset($this->addon->settings->content) && $this->addon->settings->content) ? $this->addon->settings->content.'[/'.$prefix.'photo_panel]' : '';\n\t\t\n\t\t$class = (isset($this->addon->settings->class) && $this->addon->settings->class) ? $this->addon->settings->class : '';\n\t\t$text_align = (isset($this->addon->settings->text_align) && $this->addon->settings->text_align) ? $this->addon->settings->text_align : '';\n\t\t$photo = (isset($this->addon->settings->photo) && $this->addon->settings->photo) ? $this->addon->settings->photo : '';\n\t\t$alt = (isset($this->addon->settings->alt) && $this->addon->settings->alt) ? $this->addon->settings->alt : '';\n\t\t$url = (isset($this->addon->settings->url) && $this->addon->settings->url) ? $this->addon->settings->url : '';\n\n\t\t// Output\n\t\t$output = '<div class=\"bdt-addon bdt-addon-photo-panel ' . $class .'\">';\n\t\t$output .= su_do_shortcode('['.$prefix.'photo_panel background=\"'.$background.'\" color=\"'.$color.'\" border=\"'.$border.'\" shadow=\"'.$shadow.'\" radius=\"'.$radius.'\" text_align=\"'.$text_align.'\" photo=\"'.$photo.'\" alt=\"'.$alt.'\" url=\"'.$url.'\"]'.$content);\n\t\t$output .= '</div>';\n\n\t\treturn $output;\n\t}", "title": "" }, { "docid": "21c811d047de823b7c29af0bef273303", "score": "0.53577334", "text": "function widget($args, $instance) {\r\n \r\n extract($args);\r\n \r\n $domain = get_option('idx_broker_domain');\r\n \r\n echo $before_widget;\r\n echo $before_title;\r\n \r\n if(!empty($instance['title'])) {\r\n \r\n echo $instance['title'];\r\n \r\n } else {\r\n \r\n echo \"Slideshow\";\r\n \r\n }\r\n echo $after_title;\r\n?>\r\n<script type=\"text/javascript\" src=\"http://<?php echo $domain; ?>/idx/<?php echo get_option('idx_broker_cid'); ?>/slideshowJS.php\"></script>\r\n<?php echo $after_widget;\r\n\r\n }", "title": "" }, { "docid": "d8b4f4264a03d6a8e5b947fd2f081894", "score": "0.535098", "text": "function scr_admin_bar_bottom() {\n echo '\n <style type=\"text/css\">\n\n html {\n margin-top: 0px !important;\n }\n\n .admin-bar {\n margin-top: -28px;\n padding-bottom: 28px;\n }\n\n #wpadminbar {\n top: auto !important;\n bottom: 0;\n }\n\n #wpadminbar .quicklinks>ul>li { position: relative; }\n\n #wpadminbar .ab-top-menu>.menupop>.ab-sub-wrapper { bottom: 28px; }\n\n #wp-admin-bar-wp-logo { display: none; }\n\n #menu-posts-therapists .dashicons-admin-post:before,\n #menu-posts-therapists .dashicons-format-standard:before { content:\"\\f307\"; }\n </style>'\n ;\n }", "title": "" }, { "docid": "9bfdddb0309f1b213b1c07fdb0f50e0b", "score": "0.53491104", "text": "function widget_italianwotdwidget_init() \r\n{\r\n\tif ( !function_exists('register_sidebar_widget') )\r\n\t{\r\n\t\treturn;\r\n\t}\r\n\t\t\r\n\tfunction widget_italianwotdwidget($args) \r\n {\r\n\t\textract($args);\r\n\t\t\t\r\n\t\techo $before_widget;\r\n\t\techo $before_title .\"Italian Word of the Day\". $after_title;\r\n\r\n\t\t$wotd_code = \"<script src='http://www.hitsalive.com/italian_wotd/italian.php?link=WP' language='javascript' type='text/javascript'></script>\";\r\n \r\n\t\techo '<div style=\"margin-top:5px;text-align:left;\">'.$wotd_code.'</div>';\r\n\t\techo $after_widget;\r\n\t}\r\n\r\n\t\r\n\tfunction widget_italianwotdwidget_control() \r\n {\r\n\t\techo '<p style=\"text-align:left;\">Brought to you by <b>Declan Software</b> - Language Learning Software for serious students.</p>';\r\n\t}\r\n\r\n\tregister_widget_control(array('Italian Word of the Day', 'widgets'), 'widget_italianwotdwidget_control', 200, 200);\r\n\r\n\tregister_sidebar_widget(array('Italian Word of the Day', 'widgets'), 'widget_italianwotdwidget');\r\n}", "title": "" }, { "docid": "aadee3a073d5142d2c6b54e26375e996", "score": "0.5347855", "text": "function widget($args, $instance){\n\t\techo $args['before_widget'];\n\t\tinclude(plugin_dir_path(__FILE__).'views/boilerplate_widget_frontend.php');\n\t\techo $args['after_widget'];\n\t}", "title": "" }, { "docid": "180a4c7035fb79756095b1809710f343", "score": "0.5341476", "text": "function header_widget_area() {\r\n\tdo_action( 'header_widget_area' );\r\n}", "title": "" }, { "docid": "782c7c4e11b9e11679b67837c49c678a", "score": "0.5337261", "text": "public function header()\n {\n //$this->addLogo();\n\n // Add the date to the op of the page(above the logo).\n $datetime = new \\DateTime(null, new \\DateTimeZone('Europe/Brussels'));\n $this->Cell(0,\n 20,\n $datetime->format('Y-m-d'),\n 0,\n false,\n 'R',\n 0,\n '',\n 0,\n false,\n 'T',\n 'M');\n }", "title": "" }, { "docid": "697527f31f07095bd77da9e7856539e7", "score": "0.5335248", "text": "function immagineHeader($goBack) {\r\n echo <<<HTML\r\n <div class=\"col col-sm-12\">\r\nHTML;\r\n echo \"<img class='img-responsive' src='\".$goBack.\"media/img/copertina_stage_azzurro.png' alt=''' width='100%' height='326' />\";\r\n echo <<<HTML\r\n </div>\r\nHTML;\r\n }", "title": "" }, { "docid": "dae456c202badff6c0ee52f3c7f358ed", "score": "0.53336495", "text": "function boo2_render_top( $additional_buttons = array()) {\n\t$CI = get_instance ();\n\t$dashboard_helper= Dashboard_main_helper::get_instance();\n\t$dashboard_helper->get('edit_path');\n\t$data ['site_url'] = site_url();\n\t$data ['edit_path'] = $dashboard_helper->get('edit_path');\n\t$data ['additional_buttons'] = $additional_buttons;\n\treturn $CI->load->view ( 'core/helper_render_action', $data );\n}", "title": "" }, { "docid": "a795df04d1062c41c0346122a909de66", "score": "0.5324129", "text": "function template_header($title) {\r\r\n echo <<<EOT\r\r\n <!DOCTYPE html>\r\r\n <html>\r\r\n <head>\r\r\n <meta charset=\"UTF-8\">\r\r\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=0.5, maximum-scale=3.0, minimum-scale=0.5\">\r\r\n <meta name=\"description\" content=\"Ремонт на смартфони, ремонт на таблети, ремонт на компютри, смяна на счупено стъкло на дисплей цена, ремонт на лаптопи, сервиз за телефони,\">\r\r\n <meta name=\"keyword\" content=\"Ремонт на смартфони, ремонт на таблети, ремонт на компютри, смяна на счупено стъкло на дисплей цена, ремонт на лаптопи, сервиз за телефони,\">\r\r\n <title>TechZoneBG</title>\r\r\n <script src=\"/JavaScript/menuScript.js\"></script>\r\r\n <meta property=\"og:image:secure_url\" content=\"https://techzone-bg.com/images/itech Logo1.png\" />\r\r\n <meta property=\"og:title\" content=\"TechZoneBG\" />\r\r\n <meta property=\"og:image\" content=\"/images/itech Logo1.png\"/>\r\r\n <meta property=\"og:image:width\" content=\"400\" />\r\r\n <meta property=\"og:image:height\" content=\"300\" />\r\r\n <link rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/images/icon.png\">\r\r\n <link rel=\"stylesheet\" type=\"text/css\" href=\"/CSS/style.css\">\r\r\n <link rel=\"stylesheet\" type=\"text/css\" href=\"/CSS/responsiveMenu.css\">\r\r\n <link rel=\"stylesheet\" href=\"https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css\">\r\r\n <link href=\"/CSS/galeryStyle.css\" rel=\"stylesheet\" type=\"text/css\"> \r\r\n <link rel=\"stylesheet\" href=\"https://use.fontawesome.com/releases/v5.7.1/css/all.css\">\r\r\n <style>\r\r\n body {\r\r\n background-image: url('/images/circuit.png');\r\r\n background-position: center;\r\r\n\r\r\n }\r\r\n </style> \r\r\n </head>\r\r\n <body>\r\r\n <nav class=\"a\">\r\r\n <p class=\"e\">гр. София, бул. Сливница 133/ тел. 0878432079</p>\r\r\n <p class=\"d\">\r\r\n <a class=\"c\" href=\"viber://chat?number=359878432079\">\r\r\n <img alt=\"facebook\" src=/images/viber.png width=\"37\" height=\"37\">\r\r\n </a>\r\r\n </p>\r\r\n <p class=\"d\">\r\r\n <a class=\"c\" href=\"https://www.facebook.com/messages/t/iTech.Computers\" target=\"_blank\">\r\r\n <img alt=\"facebook\" src=/images/messenger.png width=\"40\" height=\"40\">\r\r\n </a>\r\r\n </p>\r\r\n <p class=\"d\">\r\r\n <a class=\"c\" href=\"https://www.facebook.com/TechZoneBG11/\" target=\"_blank\">\r\r\n <img alt=\"facebook\" src=/images/facebook.png width=\"38\" height=\"38\">\r\r\n </a>\r\r\n </p>\r\r\n <p class=\"d\">\r\r\n <a class=\"c\" href=\"https://www.instagram.com/itechcomputers1/\" target=\"_blank\">\r\r\n <img alt=\"facebook\" src=/images/instagram.png width=\"39\" height=\"39\">\r\r\n </a>\r\r\n </p>\r\r\n <p class=\"d\">\r\r\n <a class=\"c\" href=\"https://www.youtube.com/channel/UCr_JWBo47P0706JHxWmoNAw/\" target=\"_blank\">\r\r\n <img alt=\"facebook\" src=/images/youtube.png width=\"40\" height=\"40\">\r\r\n </a>\r\r\n </p>\r\r\n\r\r\n </nav>\r\r\n <nav id=\"logo\" style=\"text-align: center;\">\r\r\n <div>\r\r\n <a href=\"/index\">\r\r\n <img src=\"/images/TechZone Logo.png\" width=\"272\" height=\"48\">\r\r\n </a>\r\r\n </div>\r\r\n </nav>\r\r\n <header id=\"menu\" class=\"topnav\">\r\r\n <ul>\r\r\n <a class=\"b\" href=\"/index\">Начало</a>\r\r\n <a class=\"b\" href=\"/online\">Онлайн поддръжка</a> \r\r\n <a href=\"/services\" class=\"dropbtn\">Услуги</a> \r\r\n <a href=\"/parts\" class=\"dropbtn\">Цени</a> \r\r\n <a class=\"b\" href=\"/contacts\">Контакти</a> \r\r\n <a style=\"float: right;\" class=\"b\" href=\"/phpGallery/index.php\">Галерия</a>\r\r\n <a href=\"javascript:void(0);\" class=\"icon\" onclick=\"myFunction()\">\r\r\n <i class=\"fa fa-bars\"></i>\r\r\n </a>\r\r\n </ul>\r\r\n </header>\r\r\nEOT;\r\r\n }", "title": "" }, { "docid": "fe5b14fb66e8369ebb7ad115d14d3b43", "score": "0.53200847", "text": "function zcms_load_widget_file($location = 'frontend')\n{\n $allWidget = get_child_folder(APP_DIR . \"/widgets/{$location}/\");\n\n foreach ($allWidget as $w) {\n $widgetPath = APP_DIR . \"/widgets/{$location}/\" . $w . '/' . $w . '.php';\n if (file_exists($widgetPath)) {\n require_once($widgetPath);\n } elseif (DEBUG) {\n /**\n * @var \\Phalcon\\Flash\\Session $flashSession\n */\n $flashSession = Di::getDefault()->get('flashSession');\n $flashSession->error(__('gb_widget_not_found_in_location', ['1' => $w, '2' => $location]));\n }\n }\n}", "title": "" }, { "docid": "d2ae729ee06811d10b12514099bf7965", "score": "0.5319904", "text": "function mag1_widgets_init() {\n\n\tregister_sidebar( array(\n\t\t'name' => 'Magazine cover 1',\n\t\t'id' => 'magazine_cover_1',\n\t\t'before_widget' => '<div>',\n\t\t'after_widget' => '</div>',\n\t\t'before_title' => '<h2>',\n\t\t'after_title' => '</h2>',\n\t) );\n\n}", "title": "" }, { "docid": "56fd014e9dd2cecc31595c300d4e5164", "score": "0.5312454", "text": "public function showDashboard()\n {\n // Config an preload\n $this->mgm->loadUserConf($GLOBALS['BE_USER']->user['uid']);\n $userConf = $this->mgm->getUserConf();\n $content = ['', '', '', ''];\n $rows = intval($userConf['config']['rows']);\n\n // Generate the Widgets\n for ($i = 0; $i < $rows; $i++) {\n if (!is_array($userConf['position'][$i])) {\n $userConf['position'][$i] = [];\n }\n\n foreach ($userConf['position'][$i] as $widgetKey) {\n\n // Create the Widget Object\n $widget = $this->mgm->getWidget($widgetKey);\n\n // Continue if it is no Object\n if (!is_object($widget)) {\n continue;\n }\n\n $widget_c = '<div class=\"widget\" id=\"widget_' . $widgetKey . '\"><h2 onmouseover=\"showOptions(\\'widget_' . $widgetKey . '\\')\" onmouseout=\"hideOptions(\\'widget_' . $widgetKey . '\\');\"><span class=\"icon\">' . $this->mgm->renderIcon($widget) . '</span><span class=\"text\">' . $widget->getTitle() . '</span>';\n $widget_c .= '<a href=\"#\" class=\"delete\" id=\"widget_' . $widgetKey . '_delete\" style=\"display: none\" onclick=\"deleteWidget(\\'' . $widgetKey . '\\')\">Delete</a>';\n if ($widget->isConfig()) {\n $widget_c .= '<a href=\"#\" class=\"config\" id=\"widget_' . $widgetKey . '_config\" style=\"display: none\" onclick=\"configWidget(\\'' . $widgetKey . '\\')\">Config</a>';\n }\n $widget_c .= '<a href=\"#\" class=\"refresh\" id=\"widget_' . $widgetKey . '_refresh\" style=\"display: none\" onclick=\"refreshWidget(\\'' . $widgetKey . '\\')\">Refresh</a>';\n\n $widget_c .= '</h2>\n\t\t\t\t<div class=\"content\" id=\"widget_' . $widgetKey . '_content\">' . $widget->getContent() . '</div>\n\t\t\t\t</div>';\n\n foreach ($widget->getJSFiles() as $file) {\n if (!in_array($file, $this->jsLoaded)) {\n $this->jsLoaded[] = $file;\n $this->doc->JScode .= '<script type=\"text/javascript\" src=\"' . $file . '\"></script>';\n }\n }\n\n $content[$i] .= $widget_c;\n }\n\n $content[$i] = '<div id=\"container' . $i . '\" class=\"container-rows-' . $rows . '\">' . $content[$i] . '</div>';\n }\n\n $content = '<div class=\"widgets\">' . implode($content) . '<div class=\"clearer\"></div></div>';\n\n // Javascript\n $js = '';\n $container = [];\n $newOrder = [];\n for ($i = 0; $i < intval($userConf['config']['rows']); $i++) {\n if (!is_array($userConf['position'][$i])) {\n continue;\n }\n\n//\t\t\t$js .= 'Sortable.create(\"container'.$i.'\",{tag: \\'div\\',dropOnEmpty:true,containment:[###CONTAINER###],constraint:false, onUpdate:sendNewOrder});'.\"\\n\";\n $container[] = '\"container' . $i . '\"';\n $newOrder[] = 'parms = Sortable.serialize(\"container' . $i . '\", {name: \\'' . $i . '\\'})+\"&\"+parms;';\n }\n\n $js = \"<script type=\\\"text/javascript\\\">\\n\" . str_replace('###CONTAINER###', implode(',', $container), $js) . \"\n\t\t\n\t\tfunction sendNewOrder(){\n\t\t\tvar parms = '';\n\t\t\t\" . implode(\"\\n\", $newOrder) . \"\n\t\t\tnew Ajax.Request('index.php', {\n\t\t\t\tparameters: { ajax: 1, action: 'reorder', data: parms },\n\t\t\t});\n\t\t}\n\t\t</script>\";\n\n return $content . $js;\n }", "title": "" }, { "docid": "07e0805c81d5884f67f05e0d82213446", "score": "0.53105086", "text": "function view(){\n global $DOPBSP;\n \n $DOPBSP->views->backend_extras->template();\n }", "title": "" }, { "docid": "f1780ae81c000b9860d5f2cb5f7852b5", "score": "0.531011", "text": "function cdn_load_widgets() {\n\tregister_widget( 'Cdn_Ad_Banner_Widget' );\n}", "title": "" }, { "docid": "62af2a053ec688290e88cc0ea7d1ce45", "score": "0.53098387", "text": "function generate_do_footer_widget( $widget_width, $widget ) {\n\t$widget_width = apply_filters( \"generate_footer_widget_{$widget}_width\", $widget_width );\n\t$tablet_widget_width = apply_filters( \"generate_footer_widget_{$widget}_tablet_width\", '50' );\n\t?>\n\t<div class=\"footer-widget-<?php echo absint( $widget ); ?> grid-parent grid-<?php echo absint( $widget_width ); ?> tablet-grid-<?php echo absint( $tablet_widget_width ); ?> mobile-grid-100\">\n\t\t<?php dynamic_sidebar( 'footer-' . absint( $widget ) ); ?>\n\t</div>\n\t<?php\n}", "title": "" }, { "docid": "69c75ee18704c70b007062a84c4616a2", "score": "0.5309781", "text": "function pp_load_widget() {\n register_widget( 'Ml_pp_widget' );\n }", "title": "" }, { "docid": "b59ff9f72542919862384c057fa09549", "score": "0.5306156", "text": "public function load_foot_page($data){\r\n\t\t\t$this->load->view('vw-templates/body_footer');\r\n\t\t\t$this->load->view('includings/administration/administration-plateforme_script', $data);\r\n\t\t\t$this->load->view('vw-templates/page_foot');\r\n\t\t}", "title": "" }, { "docid": "cfa734790b0343593b97f164316e9ab7", "score": "0.53052574", "text": "function wpb_load_widget() {\n //detail page widget\n register_widget( 'wpb_recent_cases_h3_widget' );\n register_widget( 'wpb_count_rank_widget' );\n register_widget( 'wpb_search_widget' );\n\n //search page widget\n register_widget( 'wpb_count_rank_vertiacl_widget' );\n register_widget( 'wpb_recent_cases_v5_widget' );\n\n}", "title": "" }, { "docid": "f7d2a5b877edc938758b1030f8a01df1", "score": "0.5305194", "text": "public function _initTopLinks()\r\n {\r\n $view = $this->getResource('View');\r\n\r\n $view->placeholder('Toplinks')\r\n ->setPrefix('<table class=\"loggedInLinks\"><tr><td>')\r\n ->setSeparator(\"</td><td>\")\r\n ->setPostfix(\"</td></tr></table>\");\r\n }", "title": "" }, { "docid": "9c5450826850785220291e4ec9a34b3e", "score": "0.53036827", "text": "public function indexAction()\n {\n $this->loadLayout();\n /*$block = $this->getLayout()->createBlock(\"adminhtml/template\")->setTemplate(\"banner/head.phtml\");\n $this->getLayout()->getBlock(\"content\")->append($block); */\n $this->renderLayout();\n }", "title": "" }, { "docid": "0cdb299e33085525b1fba15126d9795a", "score": "0.53032905", "text": "function kst_add_custom_image_header_admin() {\n\n}", "title": "" }, { "docid": "e91e165bc8cb26a12f8628e128aafa03", "score": "0.52989817", "text": "function sage_support_widget_function()\n{\n // get theme options\n $supportLogo = sage_get_field('support_logo');\n $supportUrl = sage_get_field('support_url');\n $supportMessage = sage_get_field('support_message');\n\n $printLogo = ($supportLogo) ? $supportLogo : asset_path('images/admin/logo-white.png');\n\n ?>\n <div>\n <a href=\"<?php _e($supportUrl); ?>\" target=\"_blank\" class=\"wp_support_widget_logo\">\n <img src=\"<?php _e($printLogo); ?>\" alt=\"Høks support\" height=\"70\">\n </a>\n <?php _e($supportMessage); ?>\n </div>\n <div class=\"clear\"></div>\n <?php\n}", "title": "" }, { "docid": "358849445a16289ba21f6265a80d0bca", "score": "0.5285662", "text": "function jdoerck_custom_login_logo()\n{\n echo '\n\n// <div id=\"grid\" style=\"height: 100%; width: 100%;position: absolute;top: 0;left: 0;opacity: .5;background-image: url(' . get_bloginfo('template_directory') . '/_i/grid.png) !important;\"> </div>\n<style type=\"text/css\">\n\t\tbody {\n\t\t\tbackground: #2a454d; /* Old browsers */\n\n\t\tbackground: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIxMDAlIiB5Mj0iMCUiPgogICAgPHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iIzJhNDU0ZCIgc3RvcC1vcGFjaXR5PSIxIi8+CiAgICA8c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiMzYTY0NzUiIHN0b3Atb3BhY2l0eT0iMSIvPgogIDwvbGluZWFyR3JhZGllbnQ+CiAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEiIGhlaWdodD0iMSIgZmlsbD0idXJsKCNncmFkLXVjZ2ctZ2VuZXJhdGVkKSIgLz4KPC9zdmc+);\n\t\tbackground: -moz-linear-gradient(left, #2a454d 0%, #3a6475 100%) !important; /* FF3.6+ */\n\t\tbackground: -webkit-gradient(linear, left top, right top, color-stop(0%,#2a454d), color-stop(100%,#3a6475)) !important; /* Chrome,Safari4+ */\n\t\tbackground: -webkit-linear-gradient(left, #2a454d 0%,#3a6475 100%) !important; /* Chrome10+,Safari5.1+ */\n\t\tbackground: -o-linear-gradient(left, #2a454d 0%,#3a6475 100%) !important; /* Opera 11.10+ */\n\t\tbackground: -ms-linear-gradient(left, #2a454d 0%,#3a6475 100%) !important; /* IE10+ */\n\t\tbackground: linear-gradient(to right, #2a454d 0%,#3a6475 100%) !important; /* W3C */\n\t\tfilter: progid:DXImageTransform.Microsoft.gradient( startColorstr=\\'#2a454d\\', endColorstr=\\'#3a6475\\',GradientType=1 ) !important; /* IE6-8 */\n\t\t}\n\th1 { background-image: url(' . get_bloginfo('template_directory') . '/_i/logo_spr.png) !important; height: 56px !important; width: 409px !important; margin-left: -35px !important; }\n\th1 a { background-image: none !important; }\n\n\t#login {\n\t\tz-index: 1000;position: relative;\n\t}\n\t#nav, #backtoblog {\n\t\tdisplay: block;\n\t\ttext-align: center;\n\t}\n\t#nav a, #backtoblog a {\n\t\tdisplay: inline-block;\n\t\tmargin-top: 10px;\n\t\tbackground-color: #FFF;\n\t\tpadding: 10px;\n\t\t-moz-border-radius: 3px;\n\t\tborder-radius: 3px;\n\t\t-webkit-box-shadow: rgba(200,200,200,0.7) 0 4px 10px -1px;\n\t\tbox-shadow: rgba(200,200,200,0.7) 0 4px 10px -1px;\n\t}\n\n\t</style>\n\n';\n}", "title": "" }, { "docid": "2579567d84b0cd6cf248de9aba607eb0", "score": "0.52845407", "text": "function widget_footer_three() {\n\tif (is_active_sidebar('footer-three')) {\n\t\techo charity_before_widget_area('footer-three');\n\t\tdynamic_sidebar('footer-three');\n\t\techo charity_after_widget_area('footer-three');\n\t}\n}", "title": "" } ]
a9db863182def8b12c27b3bebb1acf35
Performs the underlying HTTP request. Not very exciting
[ { "docid": "9f316bc8c1ad55855c6c65d01544f3a1", "score": "0.0", "text": "private function _raw_request($method, $args=array())\n\t{\n\t\t$args['apikey'] = $this->apiKey;\n\n\t\t$url = $this->apiEndpoint.'/'.$method.'.json';\n\n\t\t$ch = curl_init();\n\t\tcurl_setopt($ch, CURLOPT_URL, $url);\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json'));\n\t\tcurl_setopt($ch, CURLOPT_USERAGENT, 'PHP-MCAPI/2.0');\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\t\tcurl_setopt($ch, CURLOPT_TIMEOUT, 10);\n\t\tcurl_setopt($ch, CURLOPT_POST, true);\n\t\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, $this->verifySSL);\n\t\tcurl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($args));\n\t\t$result = curl_exec($ch);\n\t\tcurl_close($ch);\n\n\t\treturn $result ? json_decode($result, true) : false;\n\t}", "title": "" } ]
[ { "docid": "234e2c861457b93cefa7faa5d0c48960", "score": "0.743765", "text": "abstract public function doRequest();", "title": "" }, { "docid": "9bf68e5a171b37bf92cb15eaf78704ec", "score": "0.74107033", "text": "public function request()\n {\n $ch = curl_init();\n curl_setopt( $ch, CURLOPT_URL, $this->_request_url );\n curl_setopt( $ch, CURLOPT_RETURNTRANSFER, 1 );\n curl_setopt( $ch, CURLOPT_POST, 1 );\n curl_setopt( $ch, CURLOPT_POSTFIELDS, http_build_query($this->_data) );\n curl_setopt( $ch, CURLOPT_USERAGENT, $this->_user_agent() );\n $this->_content = curl_exec($ch);\n $this->_response = curl_getinfo($ch);\n curl_close($ch);\n }", "title": "" }, { "docid": "6b0d8929d9b09ed58046d580c6d0d8fd", "score": "0.72968644", "text": "protected function runRequest() {\n $ch = curl_init($this->curlParams[CURLOPT_URL]);\n \n $params = self::$STATIC_PARAMS + $this->curlParams;\n curl_setopt_array($ch, $params);\n \n $this->response = curl_exec($ch);\n $this->curlInfo = curl_getinfo($ch);\n curl_close($ch);\n }", "title": "" }, { "docid": "cfcd2773d1a69c95eb63d70222b79adc", "score": "0.72765255", "text": "function send_request(){\n $this->ch = curl_init($this->full_url);\n curl_setopt($this->ch, CURLOPT_HTTPGET, 1);\n curl_setopt($this->ch, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($this->ch, CURLOPT_HEADER, 0);\n try{\n return curl_exec($this->ch); \n }\n catch (Exception $e){\n throw $e;\n }\n curl_close($this->ch);\n }", "title": "" }, { "docid": "4a53642b08fa0cea4742b6af1a5fa611", "score": "0.72259617", "text": "public function do_request() {\n try {\n $this->gather_postdata();\n } catch (exception $aex) {\n throw $aex;\n }\n\n $url = $this->get_api_url();\n $data = $this->get_postdata();\n\n $strdata = http_build_query($data, '', '&');\n\n $apiurl = $url;\n\n $ch = curl_init();\n if ($this->requesttype == self::REQUEST_TYPE_GET) {\n $apiurl .= '?' . $strdata;\n } else {\n curl_setopt($ch, CURLOPT_POSTFIELDS, $strdata);\n }\n\n curl_setopt($ch, CURLOPT_URL, $apiurl);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\n $result = curl_exec($ch);\n\n if ($result == false) {\n $error = curl_error($ch);\n }\n\n curl_close($ch);\n\n $arrresult = json_decode($result, true);\n\n if ($this->validate_result($arrresult)) {\n return $this->process_result($arrresult);\n }\n }", "title": "" }, { "docid": "19272179620a547cdaeae37823c8fe5d", "score": "0.6899195", "text": "public function dispatch()\n\t{\n\t\t$curl = curl_init();\n\n\t\t$encoded_params = \"\";\n\t\tforeach($this->request_params as $key => $value) {\n\t\t\t$encoded_params .= urlencode($key) . \"=\" . urlencode($value) . \"&\";\n\t\t}\n\t\t$encoded_params = substr($encoded_params, 0, -1);\n\n\t\t/* Vary based on HTTP method verb */\n\t\tswitch($this->method) {\n\t\t\tcase HTTP_METH_GET:\n\t\t\t\tcurl_setopt($curl, CURLOPT_URL, $this->url . \"?\" . $encoded_params);\n\t\t\t\tbreak;\n\t\t\tcase HTTP_METH_PUT:\n\t\t\tcase HTTP_METH_POST:\n\t\t\t\tcurl_setopt($curl, CURLOPT_URL, $this->url);\n\t\t\t\tcurl_setopt($curl, CURLOPT_POST, count($params));\n\t\t\t\tcurl_setopt($curl, CURLOPT_POSTFIELDS, $encoded_params);\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t}\n\t\t\t\n\t\tif($this->follow_redirects) {\n\t\t\tcurl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);\n\t\t\tcurl_setopt($curl, CURLOPT_MAXREDIRS, 10);\n\t\t\tcurl_setopt($curl, CURLOPT_RETURNTRANSFER, FALSE);\n\t\t\tcurl_setopt($curl, CURLOPT_NOBODY, TRUE);\n\t\t\tif (curl_exec($curl)) {\n\t\t\t\t$this->url = curl_getinfo($curl, CURLINFO_EFFECTIVE_URL);\n\t\t\t\t$this->follow_redirects = false;\n\t\t\t\treturn $this->dispatch();\n\t\t\t}\n\t\t}\n\t\t\n\t\tcurl_setopt($curl, CURLOPT_HEADER, 1);\n\t\tcurl_setopt($curl, CURLOPT_CONNECTTIMEOUT, 10);\n\t\tcurl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE);\n\t\tcurl_setopt($curl, CURLOPT_TIMEOUT, 10);\n\n\t\t$result = curl_exec($curl);\n\t\tcurl_close($curl);\n\t\t\n\t\tlist($headers, $body) = split(\"\\r\\n\\r\\n\", $result);\n\t\t$headers = split(\"\\n\", $headers);\n\t\t\n\t\t/* Clean up headers */\n\t\t$cleaned_headers = array();\n\t\tforeach($headers as $header) {\n\t\t\tlist($header_name, $header_value) = split(\":\", $header, 2);\n\t\t\t$cleaned_headers[$header_name] = $header_value;\n\t\t}\n\t\t\n\t\treturn array('headers' => $cleaned_headers, 'body' => $body);\n\t}", "title": "" }, { "docid": "2a5a3f99b12549975586836e0e06063d", "score": "0.6782259", "text": "private function makeRequest(): void\n {\n\n // The pre-formatted request string\n $requestString = $this->formatRequestString();\n\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $requestString);\n curl_setopt($ch, CURLOPT_USERAGENT, \"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.135 Safari/537.36 Edge/12.246\");\n curl_setopt($ch, CURLOPT_CUSTOMREQUEST, \"GET\");\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($ch, CURLOPT_TIMEOUT, 30);\n\n $response = curl_exec($ch);\n $result = json_decode($response);\n\n curl_close($ch);\n\n $this->response = $result;\n\n\n return;\n }", "title": "" }, { "docid": "017eabafdf6a00bff42816900918a064", "score": "0.67614657", "text": "public function execute() {\n $context_options = array(\n $this->type => $this->params, \n );\n $request_context = stream_context_create($context_options);\n var_dump($this->url);\n return file_get_contents($this->url, null, $request_context);\n }", "title": "" }, { "docid": "a9a81b64803a462e837c026013bb90f5", "score": "0.67116654", "text": "protected function _sendRequest()\n {\n $curl = $this->_getCurl();\n $response = curl_exec($curl);\n //echo \"<pre>\";\n //print_r($response);\n //exit;\n return $this->_processResponse($response);\n }", "title": "" }, { "docid": "1fb6d3be7bda026579927283377f88de", "score": "0.67064166", "text": "public function request($method, $url, $content, $header);", "title": "" }, { "docid": "c98769691ea89609d461207a44952898", "score": "0.6705702", "text": "public function doRequest($uri, $method = 'GET', $headers = array(), $body = '');", "title": "" }, { "docid": "5d9d52c9cf7d45560e3850aa4899066e", "score": "0.66567904", "text": "function __makeRequest(){\n $this->_params = $this->__buildParams();\n $url = array('scheme' => $this->scheme, 'host' => $this->host, 'path' => $this->path);\n $this->__requestLog[] = array('url' => $url, 'params' => $this->_params);\n $retval = $this->Http->get($url, $this->_params);\n $retval = Set::reverse(new Xml($retval));\n return $retval;\n }", "title": "" }, { "docid": "5865e8a137f644629f5297aeaef13f72", "score": "0.6628785", "text": "private function exec()\n\t{\n\t\t$this->setOption(CURLOPT_URL, $this->_url);\n\t\tif (count($this->_headers))\n\t\t{\n\t\t\t$headers = array();\n\t\t\tforeach ($this->_headers as $name => $value)\n\t\t\t{\n\t\t\t\t$headers[] = $name . ': ' . $value;\n\t\t\t}\n\t\t\t$this->setOption(CURLOPT_HTTPHEADER, $headers);\n\t\t}\n\t\t$this->_logger->setUrl($this->_url);\n\t\treturn new HttpCurlResponse($this->_ch, $this->_logger);\n\t}", "title": "" }, { "docid": "42574a97986628662fe2706cd5450399", "score": "0.6600417", "text": "abstract public function sendRequest();", "title": "" }, { "docid": "36509dcbf295dd1e5d696d4945a5913d", "score": "0.6566813", "text": "public function call()\n\t{\n\t\t$fileBase64 = $this->_getFileBase64();\n\t\t$requestJson = $this->_buildRequestJson($fileBase64);\n\n\t\t$ch = curl_init();\n\t\tcurl_setopt($ch, CURLOPT_URL, $this->url);\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json'));\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\t\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n\t\tcurl_setopt($ch, CURLOPT_POSTFIELDS, $requestJson);\n\n\t\t$result = curl_exec($ch);\n\t\tif ($result === false || empty($result)) {\n\t\t\treturn false;\n\t\t}\n\t\treturn $this->_parseResult(json_decode($result));\n\t}", "title": "" }, { "docid": "9f7d3117114834b2f584af310a19be30", "score": "0.65571356", "text": "public function request() {}", "title": "" }, { "docid": "15e9d312ad2cc197888b1493abb0f9db", "score": "0.6542819", "text": "abstract public function request($params);", "title": "" }, { "docid": "bac1542a7b39e486c0697c014b5d7457", "score": "0.6539154", "text": "public function execute() {\n\t\t\n\t\t// Set two default options, and merge any extra ones in\n\t\tif (! isset ( $this->options [CURLOPT_TIMEOUT] ))\n\t\t\t$this->options [CURLOPT_TIMEOUT] = 30;\n\t\tif (! isset ( $this->options [CURLOPT_RETURNTRANSFER] ))\n\t\t\t$this->options [CURLOPT_RETURNTRANSFER] = TRUE;\n\t\tif (! isset ( $this->options [CURLOPT_FOLLOWLOCATION] ))\n\t\t\t$this->options [CURLOPT_FOLLOWLOCATION] = TRUE;\n\t\tif (! isset ( $this->options [CURLOPT_FAILONERROR] ))\n\t\t\t$this->options [CURLOPT_FAILONERROR] = TRUE;\n\t\t\n\t\t$this->options ();\n\t\t\n\t\t// Execute the request\n\t\t$return = curl_exec ( $this->session );\n\t\t\n\t\t// Request failed\n\t\tif ($return === FALSE) {\n\t\t\t$this->error_code = curl_errno ( $this->session );\n\t\t\t$this->error_string = curl_error ( $this->session );\n\t\t\t\n\t\t\tcurl_close ( $this->session );\n\t\t\t$this->session = NULL;\n\t\t\treturn FALSE;\n\t\t\t\n\t\t\t// Request successful\n\t\t} else {\n\t\t\t\n\t\t\t$this->info = curl_getinfo ( $this->session );\n\t\t\t\n\t\t\tcurl_close ( $this->session );\n\t\t\t$this->session = NULL;\n\t\t\treturn $return;\n\t\t}\n\t}", "title": "" }, { "docid": "728885faf82a4fd7cbf1c1d0eac683fb", "score": "0.64969146", "text": "public function run() {\n curl_setopt($this->handler, CURLOPT_URL, $this->url);\n curl_setopt($this->handler, CURLOPT_CONNECTTIMEOUT, $this->timeout);\n if (!empty($this->data)) {\n curl_setopt($this->handler, CURLOPT_POST, 1);\n curl_setopt($this->handler, CURLOPT_POSTFIELDS, http_build_query($this->data));\n }\n return curl_exec($this->handler);\n }", "title": "" }, { "docid": "2ce68b45457acc08d3fbeafc9f2ea8da", "score": "0.6416991", "text": "public function request(string $url): self\n {\n $url = 'http://' . $this->host . ':' . $this->port . '/' . $url;\n $parts = parse_url($url);\n $out = \"\";\n if (function_exists(\"stream_socket_client\")) {\n $fp = stream_socket_client(\"tcp://$this->host:$this->port\", $errno, $errstr, $this->connectTimeout);\n } else {\n $fp = fsockopen($this->host, $this->port, $errno, $errstr, $this->connectTimeout);\n }\n if (!$fp) {\n $this->error = array('code' => $errno, 'text' => $errstr);\n } else {\n $data = $this->getData();\n $this->addHeader(\"X-HTTP-Method-Override: \" . strtoupper($this->method));\n $this->addHeader(\"Content-Type: application/json\");\n $this->addHeader(\"Accept: application/json\");\n switch (strtoupper($this->method)) {\n case 'GET':\n $out = \"GET \" . $parts['path'] . (isset($parts['query']) ? \"?\" . $parts['query'] : NULL) . \" HTTP/1.1\\r\\n\";\n break;\n case 'POST';\n $out = \"POST \" . $parts['path'] . (isset($parts['query']) ? \"?\" . $parts['query'] : NULL) . \" HTTP/1.1\\r\\n\";\n\n if (!empty($data)) {\n $this->addHeader(\"Content-Length: \" . strlen($data));\n }\n break;\n case \"COPY\":\n break;\n case \"DELETE\":\n $out = \"DELETE \" . $parts['path'] . (isset($parts['query']) ? \"?\" . $parts['query'] : NULL) . \" HTTP/1.1\\r\\n\";\n if (!empty($data)) {\n $this->addHeader(\"Content-Length: \" . strlen($data));\n }\n break;\n case \"PUT\":\n $out = \"PUT \" . $parts['path'] . (isset($parts['query']) ? \"?\" . $parts['query'] : NULL) . \" HTTP/1.1\\r\\n\";\n if (!empty($data)) {\n $this->addHeader(\"Content-Length: \" . strlen($data));\n }\n break;\n case \"HEAD\":\n $out = \"HEAD \" . $parts['path'] . (isset($parts['query']) ? \"?\" . $parts['query'] : NULL) . \" HTTP/1.1\\r\\n\";\n break;\n }\n $out .= \"Host: \" . $this->host . \"\\r\\n\";\n if (!empty($this->username) && !empty($this->password)) {\n $this->addHeader(\"Authorization: Basic \" . base64_encode($this->username . \":\" . $this->password));\n }\n foreach ($this->getHeaders() as $header) {\n $out .= $header . \"\\r\\n\";\n }\n $out .= \"Connection: Close\\r\\n\\r\\n\";\n\n fwrite($fp, $out);\n if (!empty($data)) {\n fwrite($fp, $data);\n }\n $response = '';\n $header = \"not yet\";\n while (!feof($fp)) {\n $line = fgets($fp, 128);\n $this->getHeader(NULL, $line);\n\n if ($line == \"\\r\\n\" && $header == \"not yet\") {\n $header = \"passed\";\n }\n if ($header == \"passed\") {\n //$response .= preg_replace('/\\n|\\r\\n/', '', $line);\n $response .= $line;\n }\n }\n fclose($fp);\n if (isset($this->responseHeaders['transfer-encoding']) && $this->responseHeaders['transfer-encoding'] == 'chunked') {\n $response = self::decode($response);\n }\n $this->response = $response;\n }\n\n $this->url = $url;\n\n return $this;\n }", "title": "" }, { "docid": "3a501ec0ea3c7108680319e02d33cbdf", "score": "0.6382247", "text": "public function executeRequest()\n\t{\n\t\t$prefix = ($this->protocol == HTTPConstants::PROTOCOL_HTTPS) ? (HTTPConstants::PROTOCOL_HTTPS) : (\"\");\n\t\t$fp = fsockopen($prefix . $this->connectionHost, $this->port, $errno, $errstr, 15);\n\n\t\tif ($fp)\n\t\t{\n\t\t\t$localquerystring = \"\";\n\t\t\tif (strlen($this->querystring) > 0)\n\t\t\t{\n\t\t\t\t$localquerystring = \"?\" . $this->querystring;\n\t\t\t}\n\t\t\t\n\t\t\t// send the request headers:\n\t\t\tfputs($fp, $this->method . \" /\" . $this->path . $localquerystring . \" HTTP/1.1\\r\\n\");\n\t\t\tLogger::add_info_log_entry(__FILE__ . __LINE__ . \" POST Header: \" . $this->method . \" /\" . $this->path . $localquerystring . \" HTTP/1.1\");\n\t\t\t\n\t\t\tfputs($fp, \"Host: \" . $this->httpHost . \"\\r\\n\");\n\t\t\tLogger::add_info_log_entry(__FILE__ . __LINE__ . \" POST Header: Host: \" . $this->httpHost);\n\t\t\t\n\t\t\tfputs($fp, \"Connection: close\\r\\n\");\n\t\t\tLogger::add_info_log_entry(__FILE__ . __LINE__ . \" POST Header: Connection: close\");\n\t\t\t\n\t\t\tforeach ($this->headers as $header)\n\t\t\t{\n\t\t\t\tfputs($fp, $header->getHeader() . \": \" . $header->getValue() . \"\\r\\n\");\n\t\t\t\tLogger::add_info_log_entry(__FILE__ . __LINE__ . \" POST Header: \" . $header->getHeader() . \": \" . $header->getValue());\n\t\t\t}\n\t\t\tfputs($fp, \"Content-Type: application/x-www-form-urlencoded\\r\\n\");\n\t\t\tLogger::add_info_log_entry(__FILE__ . __LINE__ . \" POST Header: Content-Type: application/x-www-form-urlencoded\");\n\t\t\t\n\t\t\tfputs($fp, \"Content-Length: \". strlen($this->postData) .\"\\r\\n\");\n\t\t\tLogger::add_info_log_entry(__FILE__ . __LINE__ . \" POST Header: Content-Length: \" . strlen($this->postData));\n\n\t\t\t// second line break above data feed\n\t\t\tfputs($fp, \"\\r\\n\");\n\t\t\tLogger::add_info_log_entry(__FILE__ . __LINE__ . \" POST Header: \");\n\t\t\t\n\t\t\tfputs($fp, $this->postData . \"\\r\\n\");\n\t\t\tLogger::add_info_log_entry(__FILE__ . __LINE__ . \" POST Data: \" . $this->postData);\n\n\t\t\t$result = '';\n\t\t\twhile(!feof($fp))\n\t\t\t{\n\t\t\t\t// receive the results of the request\n\t\t\t\t$result .= fgets($fp, 128);\n\t\t }\n\t\t}\n\t\telse\n\t\t{ \n\t\t\tthrow new HTTPConnectionException(\"Error in HTTP Connection. \" . $errorno . \"; \" . $errorstr);\n\t\t}\n\t\t\n\t\t// close the socket connection\n\t\tfclose($fp);\n\t\t\n\t\t$this->httpresponse = new HTTPResponse($result);\n\t}", "title": "" }, { "docid": "e286955c5798612bc8614fd8d35f3a0c", "score": "0.6369778", "text": "private function doRequest($request)\n\t{\n\t\tif ( $request->get_normalized_http_method()=='POST' )\n\t\t{\n\t\t\t$result = $this->doPost($this->url, $request->to_postdata());\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$result = $this->doGet($request->to_url(), $header, $headers_only);\n\t\t}\n\t\t\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "ced54eb28c4643a376234c3e49b34ae2", "score": "0.6353436", "text": "private function sendContents()\n {\n // init\n $url = $this->url;\n\n // method and options\n $headers = $this->getHeaders();\n $headers = implode(\"\\r\\n\", $headers);\n $options = array(\n 'http' => array(\n 'header' => $headers,\n 'method' => $this->method,\n )\n );\n $timeout = $this->getTimeout();\n if (!empty($timeout))\n $options['http']['timeout'] = $timeout / 1000;\n\n $user_agent = $this->getHeaders('User-Agent');\n if (!empty($user_agent))\n $options['http']['user_agent'] = $user_agent;\n\n // params\n if ($this->method === self::POST || $this->method === self::PUT || $this->method === self::PATCH)\n $options['http']['content'] = $this->getParamsByType();\n else\n $url = sprintf(\"%s?%s\", $this->url, http_build_query($this->params));\n\n // execute\n $context = stream_context_create($options);\n $result = file_get_contents($url, false, $context);\n\n return $result;\n }", "title": "" }, { "docid": "017607eba26a8e5509f77cc42ad7ef77", "score": "0.63522476", "text": "abstract protected function doHandleRequest();", "title": "" }, { "docid": "5a74da6314c0e65c24df79900e71b263", "score": "0.63370013", "text": "public function execute() {\n $this->prepare_request();\n return $this->send_request();\n }", "title": "" }, { "docid": "f1e2f8dc7adfe77c7980dc976d01074e", "score": "0.6328151", "text": "public function prep_request()\n {\n $curl_handle = curl_init();\n // Set default options.\n curl_setopt($curl_handle, CURLOPT_URL, $this->request_url);\n curl_setopt($curl_handle, CURLOPT_FILETIME, true);\n curl_setopt($curl_handle, CURLOPT_FRESH_CONNECT, false);\n curl_setopt($curl_handle, CURLOPT_SSL_VERIFYPEER, false);\n curl_setopt($curl_handle, CURLOPT_SSL_VERIFYHOST, true);\n curl_setopt($curl_handle, CURLOPT_CLOSEPOLICY, CURLCLOSEPOLICY_LEAST_RECENTLY_USED);\n curl_setopt($curl_handle, CURLOPT_MAXREDIRS, 5);\n curl_setopt($curl_handle, CURLOPT_HEADER, true);\n curl_setopt($curl_handle, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($curl_handle, CURLOPT_TIMEOUT, 5184000);\n curl_setopt($curl_handle, CURLOPT_CONNECTTIMEOUT, 120);\n curl_setopt($curl_handle, CURLOPT_NOSIGNAL, true);\n curl_setopt($curl_handle, CURLOPT_REFERER, $this->request_url);\n curl_setopt($curl_handle, CURLOPT_USERAGENT, $this->useragent);\n curl_setopt($curl_handle, CURLOPT_READFUNCTION, array(\n $this, 'streaming_read_callback'));\n if ($this->debug_mode) {\n curl_setopt($curl_handle, CURLOPT_VERBOSE, true);\n }\n if ($this->proxy) {\n curl_setopt($curl_handle, CURLOPT_HTTPPROXYTUNNEL, true);\n $host = $this->proxy ['host'];\n $host .= ($this->proxy ['port']) ? ':' . $this->proxy ['port'] : '';\n curl_setopt($curl_handle, CURLOPT_PROXY, $host);\n if (isset($this->proxy ['user']) && isset($this->proxy ['pass'])) {\n curl_setopt($curl_handle, CURLOPT_PROXYUSERPWD, $this->proxy ['user'] . ':' . $this->proxy ['pass']);\n }\n }\n // Set credentials for HTTP Basic/Digest Authentication.\n if ($this->username && $this->password) {\n curl_setopt($curl_handle, CURLOPT_HTTPAUTH, CURLAUTH_ANY);\n curl_setopt($curl_handle, CURLOPT_USERPWD, $this->username . ':' . $this->password);\n }\n // Handle the encoding if we can.\n if (extension_loaded('zlib')) {\n curl_setopt($curl_handle, CURLOPT_ENCODING, '');\n }\n // Process custom headers\n if (isset($this->request_headers) && count($this->request_headers)) {\n $temp_headers = array();\n foreach ($this->request_headers as $k => $v) {\n $temp_headers [] = $k . ': ' . $v;\n }\n curl_setopt($curl_handle, CURLOPT_HTTPHEADER, $temp_headers);\n }\n switch ($this->method) {\n case self::HTTP_PUT :\n curl_setopt($curl_handle, CURLOPT_CUSTOMREQUEST, 'PUT');\n if (isset($this->read_stream)) {\n if (!isset($this->read_stream_size) || $this->read_stream_size < 0) {\n throw new RequestCore_Exception('The stream size for the streaming upload cannot be determined.');\n }\n curl_setopt($curl_handle, CURLOPT_INFILESIZE, $this->read_stream_size);\n curl_setopt($curl_handle, CURLOPT_UPLOAD, true);\n } else {\n curl_setopt($curl_handle, CURLOPT_POSTFIELDS, $this->request_body);\n }\n break;\n case self::HTTP_POST :\n curl_setopt($curl_handle, CURLOPT_POST, true);\n curl_setopt($curl_handle, CURLOPT_POSTFIELDS, $this->request_body);\n break;\n case self::HTTP_HEAD :\n curl_setopt($curl_handle, CURLOPT_CUSTOMREQUEST, self::HTTP_HEAD);\n curl_setopt($curl_handle, CURLOPT_NOBODY, 1);\n break;\n default : // Assumed GET\n curl_setopt($curl_handle, CURLOPT_CUSTOMREQUEST, $this->method);\n if (isset($this->write_stream)) {\n curl_setopt($curl_handle, CURLOPT_WRITEFUNCTION, array(\n $this, 'streaming_write_callback'));\n curl_setopt($curl_handle, CURLOPT_HEADER, false);\n } else {\n curl_setopt($curl_handle, CURLOPT_POSTFIELDS, $this->request_body);\n }\n break;\n }\n // Merge in the CURLOPTs\n if (isset($this->curlopts) && sizeof($this->curlopts) > 0) {\n foreach ($this->curlopts as $k => $v) {\n curl_setopt($curl_handle, $k, $v);\n }\n }\n return $curl_handle;\n }", "title": "" }, { "docid": "2c13409c166a1d2be220897ca9fa01ed", "score": "0.632344", "text": "function http_send_request($tcp_id, $url, $paras, $method = \"GET\")\n{\n\tglobal $resp_header;\n\tglobal $resp_body;\n\t\n\t$resp_header = \"\";\n\t$resp_body = \"\";\n\t\n\t$pos = strpos($url, \"/\");\n\t\n\tif(is_bool($pos) && $pos == false)\n\t{\n\t\t$host_name = $url;\n\t\t$path = \"\";\n\t}\n\telse\n\t{\n\t\t$host_name = substr($url, 0, $pos);\n\t\t$path = substr($url, $pos +1);\n\t}\t\n\t\n\t$hn_len = strlen($host_name);\n\t\n\tif($host_name[0] == \"[\" && $host_name[$hn_len-1] == \"]\")\n\t\t$host_addr = substr($host_name, 1, $hn_len -2);\n\telse\n\t{\n\t\t$host_addr = dns_lookup($host_name, RR_A);\n\n\t\tif($host_addr == $host_name)\n\t\t{\n\t\t\techo \"http: $host_name : Not Found\\r\\n\";\n\t\t\treturn false;\n\t\t}\n\t}\n\t\n\t// Open TCP\n\t$http_pid = pid_open(\"/mmap/tcp$tcp_id\"); \n\t\n\tpid_bind($http_pid, \"\", 0);\n\t\n\tpid_connect($http_pid, $host_addr, 80);\n\n\tfor(;;)\n\t{\n\t\t$state = pid_ioctl($http_pid, \"get state\");\n\n\t\tif($state == TCP_CLOSED)\n\t\t{\n\t\t\tpid_close($http_pid);\n\t\t\techo \"http: connection failed\\r\\n\";\n\t\t\treturn false;\n\t\t}\n\n\t\tif($state == TCP_CONNECTED)\n\t\t\tbreak;\n\t}\n\n\tif($method = \"GET\")\n\t{\n\t\t$http_req = \"GET /\" . $path . \"?\" . $paras . \" HTTP/1.1\\r\\n\";\n\t\t$http_req .= \"Host: $host_addr\\r\\n\";\n\t\t$http_req .= \"Connection: closed\\r\\n\";\n\t\t$http_req .= \"\\r\\n\\r\\n\";\n\t}\n\telse\n\t{\n\t\t$len =(string) strlen($paras);\n\t\n\t\t// Header\n\t\t$http_req = \"POST /\" . $path . \" HTTP/1.1\\r\\n\";\n\t\t$http_req .= \"Host: $host_addr\\r\\n\";\n\t\t$http_req .= \"Content-Length: \" . $len .\"\\r\\n\";\n\t\t$http_req .= \"Content-Type: application/x-www-form-urlencoded\\r\\n\";\n\t\t$http_req .= \"Connection: closed\\r\\n\";\n\t\t$http_req .= \"\\r\\n\";\n\t\t\n\t\t// Body\n\t\t$http_req .= $paras;\n\t\t\n\t\t$http_req .= \"\\r\\n\\r\\n\";\n\t}\n\n\tpid_send($http_pid, $http_req);\n\t\n\t\n\t$rbuf = \"\";\n\t$reponse = \"\";\n\t\n\t$is_body = false;\n\t\n\t$body_len = 0;\n\t\n\tfor(;;)\n\t{\n\t\tif(($len = pid_recv($http_pid, $rbuf)) > 0)\n\t\t{\n\t\t\tif(!$is_body)\n\t\t\t{\n\t\t\t\t$reponse .= $rbuf ;\n\t\t\t\t\n\t\t\t\t$pos = strpos($reponse, \"\\r\\n\\r\\n\");\n\t\t\t\t\n\t\t\t\tif(!is_bool($pos) )\n\t\t\t\t{\n\t\t\t\t\t$body_len = $len - $pos - 4;\n\t\t\t\t\t\n\t\t\t\t\tif($body_len > MAX_STRING_LEN)\n\t\t\t\t\t{\n\t\t\t\t\t\techo \"http: \\r\\nbody size exceed the buffer size\";\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$resp_header = substr($reponse, 0, $pos);\n\t\t\t\t\t// Excluse \"\\r\\n\\r\\n\"\n\t\t\t\t\t$resp_body = substr($reponse, $pos + 4); \n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\t\t\t\t\n\t\t\t\t$body_len +=$len;\n\t\t\t\t\n\t\t\t\tif($body_len > MAX_STRING_LEN)\n\t\t\t\t{\n\t\t\t\t\techo \"http: \\r\\nbody size exceed the buffer size\";\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$resp_body .= $rbuf;\n\t\t\t}\n\t\t\tcontinue;\n\t\t}\n\n\t\tif(pid_ioctl($http_pid, \"get state\") == TCP_CLOSED)\n\t\t\tbreak;\n\t}\n\n\t// Close TCP\n\tpid_close($http_pid); \t\n\n\treturn true;\n}", "title": "" }, { "docid": "5bceee6a63c6d737d319dec18299cb8a", "score": "0.6319758", "text": "private function execute(){\r\n\t\tif ( ! isset($this->_options[CURLOPT_TIMEOUT])){\r\n\t\t\t$this->_options[CURLOPT_TIMEOUT] = 30;\r\n\t\t}\r\n\t\t\r\n\t\tif ( ! isset($this->_options[CURLOPT_RETURNTRANSFER])){\r\n\t\t\t$this->_options[CURLOPT_RETURNTRANSFER] = TRUE;\r\n\t\t}\r\n\t\t\r\n\t\tif ( ! isset($this->_options[CURLOPT_FAILONERROR])){\r\n\t\t\t$this->_options[CURLOPT_FAILONERROR] = TRUE;\r\n\t\t}\r\n\t\r\n\t\t// set follow location Only if we are not running securely\r\n\t\tif ( ! ini_get('safe_mode') && ! ini_get('open_basedir')){\r\n\t\t\t//is it already set ?\r\n\t\t\tif ( ! isset($this->options[CURLOPT_FOLLOWLOCATION])){\r\n\t\t\t\t$this->options[CURLOPT_FOLLOWLOCATION] = TRUE;\r\n\t\t\t}\r\n\t\t}\r\n\t\r\n\t\tif ( ! empty($this->_headers)){\r\n\t\t\t$this->addOption(CURLOPT_HTTPHEADER, $this->_headers);\r\n\t\t}\r\n\t\t\r\n\t\t//update options\r\n\t\t$this->addOptions();\r\n\t\r\n\t\t// execute the request & and hide all output\r\n\t\t$response = curl_exec($this->_session);\r\n\t\t$info = curl_getinfo($this->_session);\r\n\t\t\r\n\t\r\n\t\t\r\n\t\t// is request successful ?\r\n\t\tif($response !== FALSE){\r\n\t\t\tcurl_close($this->_session);\r\n\t\t\t$this->reset();\r\n\t\t\t\r\n\t\t\t$this->_response=new HttpResponse(HttpResponse::SUCCESS, $response, $info);\r\n\t\t\t$this->_last_response=$this->_response;\t\t\t\r\n\t\t\treturn $this;\r\n\t\t}\r\n\t\r\n\t\t//request failed \r\n\t\t$error_code = curl_errno($this->_session);\r\n\t\t$error_msg = curl_error($this->_session);\r\n\t\tcurl_close($this->_session);\r\n\t\t$this->reset();\r\n\t\t\r\n\t\t$this->_response=new HttpResponse(HttpResponse::ERROR, FALSE, $info, $error_code, $error_msg);\r\n\t\t$this->_last_response=$this->_response;\r\n\t\treturn $this;\r\n\t\t\r\n\t}", "title": "" }, { "docid": "97e026c4d863f929a503c7d6d9a25c37", "score": "0.6310949", "text": "public function execute()\n\t{\n\t\t$executor = $this->executor;\n\t\t$response = $executor($this->url, \"GET\", $this->body);\n\t\tif (!$response->data) throw new EmptyBodyException(\"No response. Expected binary output.\");\n\t\t\t\treturn $response->data;\n\t\t\t\n\t}", "title": "" }, { "docid": "553cc68f29eee59572ae183c1afc7157", "score": "0.6273648", "text": "public function SendRequest() {\r\n\t\t$ch = curl_init();\r\n\t\tcurl_setopt($ch, CURLOPT_URL, $this->apicall);\r\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\r\n\t\t\r\n\t\t$result = curl_exec($ch);\r\n\t\tcurl_close($ch);\r\n\t\t\r\n\t\treturn $result;\r\n\t}", "title": "" }, { "docid": "63db068ad5ec9db99427a863453cdfe3", "score": "0.6256642", "text": "protected function fetch()\n {\n $client = new Client();\n $request = $client->get($this->url, $this->options);\n\n $this->response = $request->send();\n\n if ($this->response->isError())\n throw new \\Exception($this->response, $this->response->code);\n\n $this->parse();\n }", "title": "" }, { "docid": "1d9daa2b11dc1688f1b666f9c8e6ac08", "score": "0.62412053", "text": "public function execute_http() {\n\n\t\t/**\n\t\t * Parse HTTP request.\n\t\t */\n\t\t$helper = new WPHelper();\n\t\t$this->params = $helper->parseHttpRequest();\n\n\t\t/**\n\t\t * Initialize the GraphQL Request\n\t\t */\n\t\t$this->before_execute();\n\n\t\t/**\n\t\t * Get the response.\n\t\t */\n\t\t$server = $this->get_server();\n\t\t$response = $server->executeRequest( $this->params );\n\n\t\treturn $this->after_execute( $response );\n\t}", "title": "" }, { "docid": "e5b22dc388e4d2a63365d8152ac5ae14", "score": "0.62308663", "text": "public function sendRequest() {\n\t //Send initialized request to mobility4all, using cURL\n\t //var_dump($this->__toString());\n\t if(isset($this->jsonArray['application_code'])) {\n\t \t$this->application_code = $this->jsonArray['application_code'];\n\t }\n\t if(isset($this->jsonArray['access_token'])) {\n\t \t$this->access_token = $this->jsonArray['access_token'];\n\t }\n\t if(isset($this->jsonArray['application_key'])) {\n\t \t$this->application_key = $this->jsonArray['application_key'];\n\t }\n $this->curl_obj = curl_init(\"https://www.mymobility.org/index.php\");\n\t $curlOptions = array(\n\t CURLOPT_CAINFO => \"/home/websites/www.mymobility.org/https/www/auth/lib/cacert.pem\",\n\t\t CURLOPT_POST\t\t =>\t1,\n\t\t CURLOPT_POSTFIELDS =>\t'request='.urlencode($this->__toString()),\n\t\t CURLOPT_HEADER\t =>\t0,\n\t\t CURLOPT_RETURNTRANSFER => 1,\n\t\t CURLOPT_SSL_VERIFYHOST => 0, // moet weg, maakt man-in-the-middle-attack theoretisch mogelijk\n\t\t CURLOPT_SSL_VERIFYPEER => 0 // moet weg, maakt man-in-the-middle-attack theoretisch mogelijk\n\n\t );\n\t if($this->sessionID != '') {\n\t\t $curlOptions[CURLOPT_COOKIE] = $this->sessionID;\n\t } else {\n\t\t $curlOptions[CURLOPT_HEADERFUNCTION] =\t'BMUCore::getHeader';\n\t }\n\t curl_setopt_array($this->curl_obj,$curlOptions);\n//\t echo \"1:\".curl_error($this->curl_obj);\n\t $response = curl_exec($this->curl_obj);\n\t //echo \"2:\".curl_error($this->curl_obj);\n\t $decodedResponse = json_decode($response,true);\n\n\t $this->closeCURL();\n\t //Return html output\n\t $this->flush();\n\t //$jsonbla = extractJson($output);\n\t if($this->returnAsString) {\n\t\t return $response;\n\t } else {\n\t\t //Decoding\n\t\t return $decodedResponse;\n\t }\n\n\t}", "title": "" }, { "docid": "758f3159d74e042fd935fdaec6f5cc8a", "score": "0.6228188", "text": "public function makeRequest() {\n\t\tglobal $smConsoleDebug;\n\t\t\n\t\t#echo 'SMRequest makeRequest()!<br>';\n\t\t\n\t\t$this->responseData = null;\n\t\t\n\t\tif (smShouldEnableCaching && $this->getRequestMethod() == 'GET') {\n\t\t\tif (smShouldDebugCaching) { $smConsoleDebug .= 'console.info(\"CACHE: caching system is enabled\");'.\"\\n\"; }\n\t\t\t$debugStart = microtime();\n\t\t\t\n\t\t\t/*\n\t\t\ttry {\n\t\t\t\t$smdb = new Smdb;\n\t\t\t\t$responseData = $smdb->fetchCache($this->cacheURL);\n\t\t\t}\n\t\t\tcatch (Exception $e) { \n\t\t\t\tthrow new Exception('Something really gone wrong', 0, $e);\n\t\t\t}\n\t\t\t*/\n\t\t\t\n\t\t\t$smdb = new Smdb;\n\t\t\tif ($smdb->connectionIsOK()) {\n\t\t\t\t$responseData = $smdb->fetchCache($this->cacheURL);\t\n\t\t\t}\n\t\t\t\n\t\t\t$debugStop = microtime();\n\t\t\t$debugDuration = $debugStop - $debugStart;\n\t\t\t\n\t\t\tif (smShouldDebugTiming) {\n\t\t\t\t$smConsoleDebug .= 'console.info(\"TIMING: fetch cache ('. $this->cacheURL .'): '. $debugDuration .'s\");'.\"\\n\"; \n\t\t\t}\n\n\t\t\t// if we got data, do a few things to make this SMRequest match one that was done via cURL\n\t\t\tif ($responseData) {\n\t\t\t\t$this->responseData = $responseData['content'];\n\t\t\t\t$this->responseCode = $responseData['statusCode'];\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tif (smShouldDebugCaching) { $smConsoleDebug .= ' console.info(\"CACHE: caching system is disabled\");'.\"\\n\"; }\n\t\t\t$requestData = $this->requestData;\n\t\t}\n\n\t\t// if we don't have responseData by now, fetch it from the app server\n\t\tif (!$this->responseData) {\n\t\t\t\n\t\t\tif (smShouldDebugCaching) {\n\t\t\t\t$smConsoleDebug .= 'console.info(\"CACHE: did NOT find data in cache or has POST data\");'.\"\\n\";\n\t\t\t}\n\t\t\t\n\t\t\t$debugStart = microtime();\n\t\t\t\n\t\t\t// get data from Sitemason via cURL\n\t\t\t$ch = curl_init();\n\t\t\t$headers = array(\"Expect:\");\n\t\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, $headers); \n\t\t\tcurl_setopt($ch, CURLOPT_HEADER, false);\n\t\t\tcurl_setopt($ch, CURLOPT_URL, $this->dataURL);\n\t\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true); \n\t\t\t\n\t\t\tif ($this->getRequestMethod() == 'POST') {\n\t\t\t\t$postParams = $this->convertPostParametersToString($_POST);\n\t\t\t\tcurl_setopt($ch, CURLOPT_POST, true);\n\t\t\t\tcurl_setopt($ch, CURLOPT_POSTFIELDS, $postParams);\n\t\t\t}\n\n\t\t\t$this->responseData = curl_exec($ch);\n\t\t\t$this->responseCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);\n\t\t\t$smConsoleDebug .= ' console.info(\"cURL responseContentType: '. curl_getinfo($ch, CURLINFO_CONTENT_TYPE) .'\");'.\"\\n\";\n\t\t\t$this->responseError = curl_error($ch);\n\t\t\t\n\t\t\tcurl_close($ch);\n\t\t\t\n\t\t\t$debugStop = microtime();\n\t\t\t$debugDuration = $debugStop - $debugStart;\n\t\t\t\n\t\t\tif (smShouldDebugApiRequests) {\n\t\t\t\t$devConvertedDataURL = preg_replace('/'. smAppServer .'/', 'dev.sitemason.com', $this->dataURL);\n\t\t\t\t$smConsoleDebug .= ' var devConvertedDataURL = \"'. $devConvertedDataURL .'\";'.\"\\n\";\n\t\t\t\t$smConsoleDebug .= ' var dataURL = \"'. $this->dataURL .'\";'.\"\\n\";\n\t\t\t\t$smConsoleDebug .= ' console.info(\"SMRequest original dataURL: \"+ dataURL);'.\"\\n\";\n\t\t\t\t$smConsoleDebug .= ' console.info(\"SMRequest converted dataURL: \"+ devConvertedDataURL);'.\"\\n\";\n\t\t\t\t$smConsoleDebug .= ' console.info(\"cURL responseCode: '. $this->responseCode .'\");'.\"\\n\";\n\t\t\t}\n\t\t\t\n\t\t\tif (smShouldDebugTiming) { \n\t\t\t\t$smConsoleDebug .= ' console.info(\"TIMING: fetch non-cached URL ('. $this->dataURL .'): '. $debugDuration .'s\");'.\"\\n\"; \n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\telse if (smShouldDebugCaching) {\n\t\t\t$smConsoleDebug .= ' console.info(\"CACHE: Found data in cache\");'.\"\\n\";\n\t\t}\n\t\t\n\t\t//\n\t\t// At this point, responseCode = 200 and responseData is filled if we found a match in cache or from the back-end\n\t\t//\n\t\t\n\t\t// if it's good, then proceed\n\t\tif ($this->responseCode == 200) {\n\t\t\n\t\t\t//\n\t\t\t// Set the application-type based on what kind of data we can get out of Sitemason\n\t\t\t//\n\t\t\t\n\t\t\t// JSON: first character is {\n\t\t\tif (substr($this->responseData,0,1) == '{') {\n\t\t\t\t$this->responseContentType = 'application/json';\n\t\t\t}\n\t\t\t\n\t\t\t// XML\n\t\t\telse if (preg_match('/<\\?xml/',$this->responseData)) {\n\t\t\t\t$this->responseContentType = 'text/xml';\n\t\t\t}\n\t\t\t\n\t\t\t// RSS\n\t\t\telse if (preg_match('/<rss (?:version|xmlns)/',$this->responseData)) {\n\t\t\t\t$this->responseContentType = 'text/xml';\n\t\t\t}\n\t\t\t\n\t\t\t// iCalendar\n\t\t\telse if (preg_match('/BEGIN:VCALENDAR/',$this->responseData)) {\n\t\t\t\t$this->responseContentType = 'text/calendar';\n\t\t\t}\n\t\t\t// anything else\n\t\t\telse {\n\t\t\t\t$this->responseContentType = 'text/html';\n\t\t\t}\n\t\t\t\n\t\t\tif (smShouldDebugApiRequests > 1) {\n\t\t\t\t$smConsoleDebug .= ' var responseContentType = \"'. $this->responseContentType .'\";'.\"\\n\";\n\t\t\t\t$smConsoleDebug .= ' console.info(\"detected content type: \"+ responseContentType);'.\"\\n\";\n\t\t\t}\n\n\t\t\t//\n\t\t\t// decode JSON\n\t\t\t//\n\t\t\t\n\t\t\tif ($this->responseContentType == 'application/json') {\n\t\t\t\tif (smShouldDebugApiRequests > 1) {\n\t\t\t\t\t$smConsoleDebug .= ' console.info(\"decoding JSON\");'.\"\\n\";\n\t\t\t\t}\n\t\t\t\n\t\t\t\t// decode the JSON now...\n\t\t\t\t$this->responseData = json_decode($this->responseData, true);\n\t\t\t\t$error = json_last_error();\n\t\t\t\tif ($error) {\n\t\t\t\t\tif ($error == JSON_ERROR_DEPTH) {\n\t\t\t\t\t\t$errorDesc = 'Maximum stack depth exceeded';\n\t\t\t\t\t}\n\t\t\t\t\telse if ($error == JSON_ERROR_STATE_MISMATCH) {\n\t\t\t\t\t\t$errorDesc = 'Underflow or the modes mismatch';\n\t\t\t\t\t}\n\t\t\t\t\telse if ($error == JSON_ERROR_CTRL_CHAR) {\n\t\t\t\t\t\t$errorDesc = 'Unexpected control character found';\n\t\t\t\t\t}\n\t\t\t\t\telse if ($error == JSON_ERROR_SYNTAX) {\n\t\t\t\t\t\t$errorDesc = 'Syntax error, malformed JSON';\n\t\t\t\t\t}\n\t\t\t\t\telse if ($error == JSON_ERROR_UTF8) {\n\t\t\t\t\t\t$errorDesc = 'Malformed UTF-8 characters, possibly incorrectly encoded';\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t$errorDesc = 'Unknown error';\n\t\t\t\t\t}\n\t\t\n\t\t\t\t\techo '<h3 class=\"error\">Sitemason Error: invalid data feed in SMRequest. '. $errorDesc .'</h3>';\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "aad39b881998e2d76d662a29907b1b3b", "score": "0.6219694", "text": "public function execute($method = 'GET', $url, array $headers = array(), array $params = array(), $data = null);", "title": "" }, { "docid": "eb1e845ce86fb3b24d9c51c38e9123a0", "score": "0.6219131", "text": "public function request($method, $url, $content = null, array $headers = array(), array $options = array());", "title": "" }, { "docid": "150ec54d60eea82061ab957588bd27f6", "score": "0.6198211", "text": "private function _http_request($path, $method = 'GET', $data = NULL, $usesession = TRUE) {\n\n $result = new stdClass();\n\n // Make sure the socket opened properly.\n $fp = @fsockopen($this->port == 443 ? 'ssl://'. $this->host : $this->host, $this->port, $errno, $errstr, 20);\n if (!$fp) {\n // When a network error occurs, we use a negative number so it does not\n // clash with the HTTP status codes.\n $result->code = -$errno;\n $result->error = trim($errstr);\n return $result;\n }\n // Create HTTP request.\n $defaults = array();\n\n // Urlencode data.\n $defaults['Host'] = 'Host' .': '. $this->host;\n $defaults['Referer'] = 'Referer' .': //'.$_SERVER['SERVER_NAME'].$_SERVER['PHP_SELF'];\n $defaults['Content-Type'] = 'Content-Type' .': '. 'application/x-www-form-urlencoded';\n\n // Set session cookie if applicable\n if ($usesession && !empty($this->sessionName))\n $defaults['Cookie'] = 'Cookie'. ': '. $this->sessionName . '=' . $this->sessionId;\n\n\n if (!empty($data)) {\n $data = http_build_query($data, '', '&');\n\n // Add content length if applicable.\n $content_length = strlen($data);\n if ($content_length > 0 || $method == 'POST' || $method == 'PUT') {\n $defaults['Content-Length'] = 'Content-Length: '. $content_length;\n }\n }\n\n // get the response as an php object\n $defaults['Accept'] = 'Accept' .': '. 'application/vnd.php.serialized';\n\n // Write request\n $request = $method .' '. $this->path.$path .\" HTTP/1.0\\r\\n\";\n $request .= implode(\"\\r\\n\", $defaults);\n $request .= \"\\r\\n\\r\\n\";\n $request .= empty($data) ? '' : $data;\n\n $result->request = $request;\n\n fwrite($fp, $request);\n\n // Fetch response.\n $response = '';\n while (!feof($fp) && $chunk = fread($fp, 1024)) {\n $response .= $chunk;\n }\n fclose($fp);\n\n // Parse response.\n list($split, $result->data) = explode(\"\\r\\n\\r\\n\", $response, 2);\n $result->data = empty($result->data) ? NULL : unserialize($result->data);\n $split = preg_split(\"/\\r\\n|\\n|\\r/\", $split);\n\n list($protocol, $code, $status_message) = explode(' ', trim(array_shift($split)), 3);\n $result->protocol = $protocol;\n $result->status_message = $status_message;\n\n $result->headers = array();\n\n // Parse headers.\n while ($line = trim(array_shift($split))) {\n list($header, $value) = explode(':', $line, 2);\n if (isset($result->headers[$header]) && $header == 'Set-Cookie') {\n // RFC 2109: the Set-Cookie response header comprises the token Set-\n // Cookie:, followed by a comma-separated list of one or more cookies.\n $result->headers[$header] .= ','. trim($value);\n }\n else {\n $result->headers[$header] = trim($value);\n }\n }\n\n $responses = array(\n 100 => 'Continue', 101 => 'Switching Protocols',\n 200 => 'OK', 201 => 'Created', 202 => 'Accepted', 203 => 'Non-Authoritative Information', 204 => 'No Content', 205 => 'Reset Content', 206 => 'Partial Content',\n 300 => 'Multiple Choices', 301 => 'Moved Permanently', 302 => 'Found', 303 => 'See Other', 304 => 'Not Modified', 305 => 'Use Proxy', 307 => 'Temporary Redirect',\n 400 => 'Bad Request', 401 => 'Unauthorized', 402 => 'Payment Required', 403 => 'Forbidden', 404 => 'Not Found', 405 => 'Method Not Allowed', 406 => 'Not Acceptable', 407 => 'Proxy Authentication Required', 408 => 'Request Time-out', 409 => 'Conflict', 410 => 'Gone', 411 => 'Length Required', 412 => 'Precondition Failed', 413 => 'Request Entity Too Large', 414 => 'Request-URI Too Large', 415 => 'Unsupported Media Type', 416 => 'Requested range not satisfiable', 417 => 'Expectation Failed',\n 500 => 'Internal Server Error', 501 => 'Not Implemented', 502 => 'Bad Gateway', 503 => 'Service Unavailable', 504 => 'Gateway Time-out', 505 => 'HTTP Version not supported'\n );\n // RFC 2616 states that all unknown HTTP codes must be treated the same as the\n // base code in their class.\n if (!isset($responses[$code])) {\n $code = floor($code / 100) * 100;\n }\n\n switch ($code) {\n case 200: // OK\n case 304: // Not modified\n break;\n case 301: // Moved permanently\n case 302: // Moved temporarily\n case 307: // Moved temporarily\n $location = $result->headers['Location'];\n $result->redirect_code = $code;\n $result->redirect_url = $location;\n break;\n default:\n $result->error = $status_message;\n }\n\n $result->code = $code;\n return $result;\n }", "title": "" }, { "docid": "2e381ec267f515e43d4907275c40acdc", "score": "0.61874336", "text": "private function sendRequest()\n {\n $this->setTargetServer();\n \n $data= json_encode($this->data);\n $options = ['http' => [\n 'method' => 'POST',\n 'header' => 'Content-type:application/x-www-form-urlencoded',\n 'content' => http_build_query(['out' => $data])\n ]];\n $context = stream_context_create($options); \n if(!$this->data = file_get_contents($this->target, false, $context))\n {\n $this->errorStatus(\"can't connect to server\");\n }\n }", "title": "" }, { "docid": "7c9e6135dc208a23f73cf53288963275", "score": "0.618641", "text": "public function makeRequest() {\n\n $url = $this->config['base_url'] . $this->requestUrl;\n\n $header = $this->authorizationHeader();\n\n $ch = curl_init();\n if ($this->requestMethod == 'POST') {\n curl_setopt($ch, CURLOPT_POSTFIELDS, $this->getRequestData());\n } else {\n if (!empty($this->requestData)) {\n $url .= '?' . $this->getRequestData();\n }\n }\n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_HTTPHEADER, $header);\n curl_setopt($ch, CURLOPT_HEADER, FALSE);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);\n $response = curl_exec($ch);\n curl_close($ch);\n\n return $response;\n }", "title": "" }, { "docid": "c9f5a1b3884de082813cef150bbe8155", "score": "0.6184407", "text": "function call($action=NULL){\n try {\n // Compose all vars.\n $vars = $this->vars;\n // set the action\n if($action) {\n $vars['actions'][] = $action;\n $this->last_action = $action;\n }\n // Request additional data.\n $vars['additional_data'] = $this->additional_data;\n\n // Add the connection key.\n $vars['KEY'] = $this->server_key;\n\n // Connect to server.\n $this->connect($vars, $this->cookies);\n\n if($this->raw){\n $this->results = json_decode($this->raw, true);\n switch($this->status){\n case 200:\n // Complete success. Return result.\n return $this->request_success();\n break;\n case 401:\n case 402:\n case 403:\n // If access denied.\n $this->request_forbidden($this->status);\n break;\n default:\n // Unrecognized.\n $this->_die(\"There was an error processing your request. Please try again later. (1)\");\n }\n return false;\n }\n } catch (Exception $e) {\n print_r($e->getMessage());\n $this->_die(\"There was an error processing your request. Please try again later. (2)\");\n }\n }", "title": "" }, { "docid": "1175dd5367e7dbe3e91ea413b1122767", "score": "0.61601907", "text": "public function _request($url, $method=\"GET\", $body=NULL, $headers=array(), $basicauth=array()) {\n libZoteroDebug( \"url being requested: \" . $url . \"\\n\\n\");\n $ch = curl_init();\n $httpHeaders = array();\n //set api version - allowed to be overridden by passed in value\n if(!isset($headers['Zotero-API-Version'])){\n $headers['Zotero-API-Version'] = ZOTERO_API_VERSION;\n }\n \n foreach($headers as $key=>$val){\n $httpHeaders[] = \"$key: $val\";\n }\n //disable Expect header\n $httpHeaders[] = 'Expect:';\n \n if(!empty($basicauth)){\n $passString = $basicauth['username'] . ':' . $basicauth['password'];\n curl_setopt($ch, CURLOPT_USERPWD, $passString);\n curl_setopt($ch, CURLOPT_FORBID_REUSE, true);\n }\n else{\n curl_setopt($ch, CURLOPT_FRESH_CONNECT, true);\n }\n \n curl_setopt($ch, CURLOPT_URL, $url);\n curl_setopt($ch, CURLOPT_HEADER, true);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($ch, CURLINFO_HEADER_OUT, true);\n curl_setopt($ch, CURLOPT_HTTPHEADER, $httpHeaders);\n //curl_setopt($ch, CURLOPT_HTTPHEADER, array('Expect:'));\n curl_setopt($ch, CURLOPT_MAXREDIRS, 3);\n if($this->_followRedirects){\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n }\n else{\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, false);\n }\n \n $umethod = strtoupper($method);\n switch($umethod){\n case \"GET\":\n curl_setopt($ch, CURLOPT_HTTPGET, true);\n break;\n case \"POST\":\n curl_setopt($ch, CURLOPT_POST, true);\n curl_setopt($ch, CURLOPT_POSTFIELDS, $body);\n break;\n case \"PUT\":\n curl_setopt($ch, CURLOPT_CUSTOMREQUEST, \"PUT\");\n curl_setopt($ch, CURLOPT_POSTFIELDS, $body);\n break;\n case \"DELETE\":\n curl_setopt($ch, CURLOPT_CUSTOMREQUEST, \"DELETE\");\n break;\n }\n \n $gotCached = false;\n if($this->_cacheResponses && $umethod == 'GET'){\n $cachedResponse = apc_fetch($url, $success);\n if($success){\n $responseBody = $cachedResponse['responseBody'];\n $responseInfo = $cachedResponse['responseInfo'];\n $zresponse = libZotero_Http_Response::fromString($responseBody);\n $gotCached = true;\n }\n }\n \n if(!$gotCached){\n $responseBody = curl_exec($ch);\n $responseInfo = curl_getinfo($ch);\n \n //var_dump($responseInfo);\n \n $zresponse = libZotero_Http_Response::fromString($responseBody);\n \n //Zend Response does not parse out the multiple sets of headers returned when curl automatically follows\n //a redirect and the new headers are left in the body. Zend_Http_Client gets around this by manually\n //handling redirects. That may end up being a better solution, but for now we'll just re-read responses\n //until a non-redirect is read\n if($this->_followRedirects){\n while($zresponse->isRedirect()){\n $redirectedBody = $zresponse->getBody();\n $zresponse = libZotero_Http_Response::fromString($redirectedBody);\n }\n }\n \n $saveCached = array(\n 'responseBody'=>$responseBody,\n 'responseInfo'=>$responseInfo,\n );\n if($this->_cacheResponses && !($zresponse->isError()) ){\n apc_store($url, $saveCached, $this->_cachettl);\n }\n }\n $this->_lastResponse = $zresponse;\n return $zresponse;\n }", "title": "" }, { "docid": "498ccde3d51b71c42f237e475e628332", "score": "0.6151618", "text": "protected function doRequest($url, $headers, $method, $data) {\n $params = array('headers' => $headers, 'method' => $method, 'data' => $data);\n return drupal_http_request($url, $params);\n }", "title": "" }, { "docid": "08e0fcb9f4621eecc3b856a4136ac1fd", "score": "0.61414814", "text": "public function makeRequest($method, $url, $body = '', $http_ver = '1.1', $headers = []);", "title": "" }, { "docid": "201fb74f165e45f87f2fefd50e8e94db", "score": "0.61404395", "text": "public function run(){\n\t\tprintf(\"Running Thread #%lu\\n\", $this->getThreadId());\n\t\tprint_r($this);\n\t\tif($this->request){\n\t\t\tif($this->request->url){\n\t\t\t\t$this->request->setStart(microtime(true));\n\t\t\t\t$this->request->setData(file_get_contents($this->request->url));\n\t\t\t\t$this->request->setFinish(microtime(true));\n\t\t\t}\n\t\t}\n\t\treturn $this->request;\n\t}", "title": "" }, { "docid": "137ae2bdb8912c20581505d41b99cfec", "score": "0.612977", "text": "abstract function SendRequest();", "title": "" }, { "docid": "841277aa216b7ee72f7ce506125b0cb0", "score": "0.6122531", "text": "function execute()\n {\n $destination = $this->uriValues[0];\n $registry = new fRegistry($this);\n $url = strval($registry->$destination);\n if ( !strlen($url) ) throw new fHTTPException(404, 'Request destination not found.');\n\n if ( get_magic_quotes_gpc( ) && is_array( $_POST ) )\n {\n foreach ( $_POST as $key=>$val )\n {\n if ( is_string( $val ) )\n {\n $_POST[ $key ] = stripslashes( $val );\n }\n }\n }\n\n // Initalize curl\n $curl = curl_init();\n\n // Set the request type if it's not GET\n if ( $_SERVER[\"REQUEST_METHOD\"] == 'POST' )\n {\n curl_setopt($curl, CURLOPT_POST, true);\n } elseif ( $_SERVER[\"REQUEST_METHOD\"] == 'PUT' ) {\n curl_setopt($curl, CURLOPT_PUT, true);\n }\n\n // Header array\n $headers = array();\n\n // Cookies\n $headers[] = 'COOKIE: ' . $_SERVER[\"HTTP_COOKIE\"] . ';';\n\n // User Agent\n if ( isset($_SERVER['HTTP_USER_AGENT']) ) $headers[] = 'User-Agent: ' . $_SERVER['HTTP_USER_AGENT'];\n\n // User Agent\n if ( isset($_SERVER['HTTP_REFERER']) ) $headers[] = 'Referer: ' . $_SERVER['HTTP_REFERER'];\n\n // Accept\n if ( isset($_SERVER['HTTP_ACCEPT']) ) $headers[] = 'Accept: ' . $_SERVER['HTTP_ACCEPT'];\n\n // Language\n if ( isset($_SERVER['HTTP_ACCEPT_LANGUAGE']) ) $headers[] = 'Accept-Language: ' . $_SERVER['HTTP_ACCEPT_LANGUAGE'];\n\n // Encoding\n if ( isset($_SERVER['HTTP_ACCEPT_ENCODING']) ) $headers[] = 'Accept-Encoding: ' . $_SERVER['HTTP_ACCEPT_ENCODING'];\n\n // Add the headers\n curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);\n\n // Timeouts\n curl_setopt($curl, CURLOPT_TIMEOUT, 10);\n\n // Set the URL w/ GET Params if it's a get pass through\n if ( ( $_SERVER[\"REQUEST_METHOD\"] == 'GET' ) && ( strlen($_SERVER['QUERY_STRING']) ) )\n $url .= '?' . $_SERVER['QUERY_STRING'];\n\n // Set the POSTFIELDS if we have postfields\n if ( ( $_SERVER[\"REQUEST_METHOD\"] == 'POST' ) && ( count($_POST) ) )\n curl_setopt($curl, CURLOPT_POSTFIELDS, $_POST);\n\n // Build and make the request\n curl_setopt($curl, CURLOPT_URL, $url);\n curl_setopt($curl, CURLOPT_HEADER, false);\n //curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);\n $data = curl_exec($curl);\n curl_close($curl);\n exit();\n\n if ( !$data )\n throw new fHTTPException(501, 'Did not return any data from request.');\n\n // Remove carriage returns\n $data = str_replace(\"\\r\", '', $data);\n\n // Break out the header from the data\n $temp = explode(\"\\n\\n\", $data, 2);\n\n // Output headers\n $header = explode(\"\\n\", $temp[0]);\n\n foreach ( $header AS $headerRow )\n if ( strstr($headerRow, 'Content-Type') )\n Header(trim($headerRow));\n\n // Output the content\n echo $temp[1];\n exit();\n }", "title": "" }, { "docid": "9e21a94b4d4736ca9bdd480ed102678b", "score": "0.6119669", "text": "public function request($data){\n\t\t$url = parse_url($this->url);\n $host = $url['host'];\n $path = $url['path'];\n \n \t\n \t\n if ($url['scheme'] != 'http') {\n return array(\n 'status' => 'err',\n 'error' => \"Host must starts with http:// !!\"\n );\n }\n $fp = @fsockopen($host, $this->port, $errno, $errstr, $this->limit_time);\n if ($fp) {\n\t\t\tif($this->type == 'XML'){\n\t\t\t\t\t$request = $url[\"path\"] . ($url[\"query\"] != \"\" ? \"?\" . $url[\"query\"] : \"\");\n\n\t\t fputs($fp, \"POST $request HTTP/1.1\\r\\n\");\n\t\t fputs($fp, \"Host: $host\\r\\n\");\n\t\t if ($referer != '')\n\t\t fputs($fp, \"Referer: $referer\\r\\n\");\n\t\t fputs($fp, \"Content-type: text/xml\\r\\n\");\n\t\t fputs($fp, \"Content-length: \" . strlen($data) . \"\\r\\n\");\n\t\t fputs($fp, \"Connection: close\\r\\n\\r\\n\");\n\t\t fputs($fp, $data);\n\t\t \n\t\t }else if($this->type == 'GET'){\n\t\t \t$query = '';\n\t\t \tif(is_array($data)) \n\t\t \t\t$query = http_build_query($data);\n\t\t \t$url = parse_url(rtrim($this->url,'/').$query);\n\t\t\t\t$request = $url[\"path\"] . ($url[\"query\"] != \"\" ? \"?\" . $url[\"query\"] : \"\") . \n\t\t\t\t\t\t\t\t\t\t($url[\"fragment\"] != \"\" ? \"#\" . $url[\"fragment\"] : \"\");\n\t\t\t\tfputs($fp, \"GET \" . $request . \" HTTP/1.0\\r\\n\");\t \n\t\t if ($referer != '')\n\t\t fputs($fp, \"Referer: $referer\\r\\n\");\n\t\t\t\tfputs(\"Accept: */*\\r\\n\");\n\t\t\t\tfputs(\"User-Agent: Payb-Agent\\r\\n\");\n\t\t\t\tfputs($fp, \"Host: $host\\r\\n\");\n\t\t\t\tfputs(\"Connection: Close\\r\\n\\r\\n\");\n\t\t\t}else if($this->type=='POST'){\n\t\t\t\tif(is_array($data)) $query = http_build_query($data);\n\t\t\t\tfputs($fp, sprintf(\"POST %s%s%s HTTP/1.0/n\", \n\t\t\t\t\t\t\t\t\t\t\t\t$url['path'], $url['query'] ? \"?\" : \"\", $url['query'])); \n\t\t\t\tfputs($fp, \"Host: $url[host]/n\"); \n\t\t\t\tfputs($fp, \"Content-type: application/x-www-form-urlencoded/n\"); \n\t\t\t\tfputs($fp, \"Content-length: \" . strlen($query) . \"/n\"); \n\t\t\t\tfputs($fp, \"Connection: close/n/n\"); \n\t\t\t\tfputs($fp, \"$query/n\"); \n\t\t\t}\n\t\t\t$result = '';\n\t while (!feof($fp)) {\n\t $result .= fgets($fp, 128);\n\t }\n\t \n\t } else {\n return array(\n 'status' => 'err',\n 'error' => \"$errstr ($errno)\"\n );\n\t\t}\n\t fclose($fp);\n\t $result = explode(\"\\r\\n\\r\\n\", $result, 2);\n\n $header = isset($result[0]) ? $result[0] : '';\n $content = isset($result[1]) ? $result[1] : '';\n\t\tif (preg_match(\"/^HTTP\\/[1]\\.[0-5]\\W+200/\", $header,$match) == 1) \n // return as structured array:\n\t return array(\n\t 'status' => 'ok',\n\t 'header' => $header,\n\t 'content' => $content\n\t );\n\t else\n\t return array(\n\t 'status' => 'error',\n\t 'header' => $header,\n\t 'content' => $content\n\t );\t \t\n\t}", "title": "" }, { "docid": "95a95f0beba448ebfa1803ec097a75fc", "score": "0.6111133", "text": "function http_request($request, $timeout = 5) {\n\n\t$url = $request['url'];\n\t// Extract the hostname from url\n\t$parts = parse_url($url);\n\tif (array_key_exists('host', $parts)) {\n\t\t$remote = $parts['host'];\n\t} else {\n\t\treturn myErrorHandler(\"url ($url) has no host. Is it relative?\");\n\t}\n\tif (array_key_exists('port', $parts)) {\n\t\t$port = $parts['port'];\n\t} else {\n\t\t$port = 0;\n\t}\n\n\t// Beware that RFC2616 (HTTP/1.1) defines header fields as case-insensitive entities.\n\t$request_headers = \"\";\n\tforeach ($request['headers'] as $name => $value) {\n\t\tswitch (strtolower($name)) {\n\t\t//ommit some headers\n\t\tcase \"keep-alive\":\n\t\tcase \"connection\":\n\t\tcase \"cookie\":\n\t\t//TPDP: we don't handle any compressions encodings. this is only\n\t\t//a problem if client communication is already compressed (which\n\t\t//would double compress the content, once from the remote server\n\t\t//to us, and once from us to the client, but the client would\n\t\t//de-compress only once).\n\t\tcase \"accept-encoding\":\n\t\t\tbreak;\n\t\t// correct the host parameter\n\t\tcase \"host\":\n\t\t\t$host_info = $remote;\n\t\t\tif ($port) {\n\t\t\t\t$host_info .= ':' . $port;\n\t\t\t}\n\t\t\t$request_headers .= \"$name: $host_info\\r\\n\";\n\t\t\tbreak;\n\t\t/*case \"accept\":\n\t\t $request_headers .= \"$name: application/rdf+json\\r\\n\";\n\t\t break;*/\n\t\t// forward all other headers\n\t\tdefault:\n\t\t\t$request_headers .= \"$name: $value\\r\\n\";\n\t\t\tbreak;\n\t\t}\n\t}\n\n\t//set fsockopen transport scheme, and the default port\n\tswitch (strtolower($parts['scheme'])) {\n\tcase 'https':\n\t\t$scheme = 'ssl://';\n\t\tif ( ! $port ) $port = 443;\n\t\tbreak;\n\tcase 'http':\n\t\t$scheme = '';\n\t\tif ( ! $port ) $port = 80;\n\t\tbreak;\n\tdefault:\n\t\t//some other transports are available but not really supported\n\t\t//by this script: http://php.net/manual/en/transports.inet.php\n\t\t$scheme = $parts['scheme'] . '://';\n\t\tif ( ! $port ) {\n\t\t\treturn myErrorHandler(\"Unknown scheme ($scheme) and no port.\");\n\t\t}\n\t\tbreak;\n\t}\n\n\t//we make the request with socket operations since we don't want to\n\t//depend on the curl extension, and the higher level wrappers don't\n\t//give us usable error information.\n\t$sock = @fsockopen(\"$scheme$remote\", $port, $errno, $errstr, $timeout);\n\tif ( ! $sock ) {\n\t\treturn myErrorHandler(\"Unable to open URL ($url): $errstr\");\n\t}\n\n\t//timeout in fsockopen is only for the connection, the following is\n\t//for reading the content\n\tstream_set_timeout($sock, $timeout);\n\n\t//absolute url should only be specified for proxy requests\n\tif (array_key_exists('path', $parts)) {\n\t\t$path_info = $parts['path'];\n\t} else {\n\t\t$path_info = '/';\n\t}\n\n\tif (array_key_exists('query', $parts)) $path_info .= '?' . $parts['query'];\n\tif (array_key_exists('fragment', $parts)) $path_info .= '#' . $parts['fragment'];\n\n\t$out = $request[\"method\"].\" \".$path_info.\" \".$request[\"protocol\"].\"\\r\\n\"\n\t\t . $request_headers\n\t\t . \"Connection: Close\\r\\n\\r\\n\";\n\tfwrite($sock, $out);\n\tfwrite($sock, $request['payload']);\n\n\t$header_str = stream_get_line($sock, 1024*16, \"\\r\\n\\r\\n\");\n\t$headers = http_parse_headers($header_str);\n\n\t// get http status\n\tpreg_match('|HTTP/\\d+\\.\\d+\\s+(\\d+)\\s+.*|i',$headers[0],$match);\n\t$status = $match[1];\n\n\treturn array('headers' => $headers, 'socket' => $sock, 'status' => $status);\n}", "title": "" }, { "docid": "6e534884edb36de4318e9e228cfd329b", "score": "0.6104809", "text": "protected function makeRequest()\n {\n }", "title": "" }, { "docid": "d8301d32e6ee1bf6373fa63552a02189", "score": "0.60994524", "text": "function http($url, $method, $postfields = NULL, $headers = array()) \n\t{\n\t\t$this->http_info = array();\n\t\t$ci = curl_init();\n\t\t/* Curl settings */\n\t\tcurl_setopt($ci, CURLOPT_HTTP_VERSION, CURL_HTTP_VERSION_1_0);\n\t\tcurl_setopt($ci, CURLOPT_USERAGENT, $this->useragent);\n\t\tcurl_setopt($ci, CURLOPT_CONNECTTIMEOUT, $this->connecttimeout);\n\t\tcurl_setopt($ci, CURLOPT_TIMEOUT, $this->timeout);\n\t\tcurl_setopt($ci, CURLOPT_RETURNTRANSFER, TRUE);\n\t\tcurl_setopt($ci, CURLOPT_ENCODING, \"\");\n\t\tcurl_setopt($ci, CURLOPT_SSL_VERIFYPEER, $this->ssl_verifypeer);\n\t\tif (version_compare(phpversion(), '5.4.0', '<')) {\n\t\t\tcurl_setopt($ci, CURLOPT_SSL_VERIFYHOST, 1);\n\t\t} else {\n\t\t\tcurl_setopt($ci, CURLOPT_SSL_VERIFYHOST, 2);\n\t\t}\n\t\tcurl_setopt($ci, CURLOPT_HEADERFUNCTION, array($this, 'getHeader'));\n\t\tcurl_setopt($ci, CURLOPT_HEADER, FALSE);\n\n\t\tswitch ($method) {\n\t\t\tcase 'POST':\n\t\t\t\tcurl_setopt($ci, CURLOPT_POST, TRUE);\n\t\t\t\tif (!empty($postfields)) {\n\t\t\t\t\tcurl_setopt($ci, CURLOPT_POSTFIELDS, $postfields);\n\t\t\t\t\t$this->postdata = $postfields;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'DELETE':\n\t\t\t\tcurl_setopt($ci, CURLOPT_CUSTOMREQUEST, 'DELETE');\n\t\t\t\tif (!empty($postfields)) {\n\t\t\t\t\t$url = \"{$url}?{$postfields}\";\n\t\t\t\t}\n\t\t}\n\n\t\tcurl_setopt($ci, CURLOPT_URL, $url );\n\t\tcurl_setopt($ci, CURLOPT_HTTPHEADER, $headers );\n\t\tcurl_setopt($ci, CURLINFO_HEADER_OUT, TRUE );\n\n\t\t$response = curl_exec($ci);\n\t\t$this->http_code = curl_getinfo($ci, CURLINFO_HTTP_CODE);\n\t\t$this->http_info = array_merge($this->http_info, curl_getinfo($ci));\n\t\t$this->url = $url;\n\n\t\tif ($this->debug) {\n\t\t\techo \"=====post data======\\r\\n\";\n\t\t\tvar_dump($postfields);\n\n\t\t\techo \"=====headers======\\r\\n\";\n\t\t\tprint_r($headers);\n\n\t\t\techo '=====request info====='.\"\\r\\n\";\n\t\t\tprint_r( curl_getinfo($ci) );\n\n\t\t\techo '=====response====='.\"\\r\\n\";\n\t\t\tprint_r( $response );\n\t\t}\n\t\tcurl_close ($ci);\n\t\treturn $response;\n\t}", "title": "" }, { "docid": "a649dc9bfb9edac065bea796e570a2ae", "score": "0.6088945", "text": "public function send()\r\n {\r\n if ( ! ini_get('allow_url_fopen'))\r\n {\r\n throw new \\RuntimeException('allow_url_fopen must be enabled to use PHP streams.');\r\n }\r\n\r\n $params = http_build_query($this->params);\r\n $uri = $this->action;\r\n\r\n if (isset($this->params['token']))\r\n {\r\n $uri .= '/' . $this->params['token'];\r\n unset($this->params['token']);\r\n }\r\n\r\n $context = stream_context_create(array(\r\n 'http' => array(\r\n 'ignore_errors' => true,\r\n 'method' => $this->method,\r\n 'header' =>\r\n \"Content-Type: application/x-www-form-urlencoded \\r\\n\" .\r\n \"User-Agent: CAMBIOREAL PHP Library \" . \\CambioReal\\CambioReal::VERSION . \"\\r\\n\" .\r\n \"X-APP-ID: \" . Config::getAppId() . \"\\r\\n\" .\r\n \"X-APP-SECRET: \" . Config::getAppSecret(),\r\n 'content' => $params\r\n )\r\n ));\r\n\r\n $response = file_get_contents($uri, false, $context);\r\n\r\n if ($response && strlen($response))\r\n {\r\n if ($this->decodeResponse)\r\n {\r\n return json_decode($response);\r\n }\r\n\r\n return $response;\r\n }\r\n\r\n throw new \\RuntimeException(\"Bad HTTP request: {$response}\");\r\n }", "title": "" }, { "docid": "a6814ac7b7eb7a8256a344e4a5cb49a0", "score": "0.6085171", "text": "public function executeRequest(ColoCrossing_Http_Request $request)\n\t{\n\t\t$this->createCurl();\n\t\t$this->setCurlRequestOptions($request);\n\n\t\treturn $this->executeCurl();\n\t}", "title": "" }, { "docid": "423f5f8a872192199243f2fd5f4d8ba2", "score": "0.6077476", "text": "function do_http_request($function,$type,$parameters,$postdata=null)\n {\n\n if (count($parameters)>0)\n $workurl=$this->url.$function.\"?\".http_build_query($parameters);\n else\n $workurl=$this->url.$function;\n \n if ($type=\"post\")\n // use key 'http' even if you send the request to https://...\n $options = array(\n\t\t 'http' => array(\n\t\t\t\t //'header' => \"Content-type: application/x-www-form-urlencoded\\r\\n\"\n\t\t\t\t 'header' => \"Authorization: Basic \" . base64_encode($this->user.\":\".$this->pass),\n\t\t\t\t 'method' => 'POST',\n\t\t\t\t 'content' => $postdata\n\t\t\t\t )\n\t\t );\n else\n $options = array(\n\t\t 'http' => array(\n\t\t\t\t //'header' => \"Content-type: application/x-www-form-urlencoded\\r\\n\",\n\t\t\t\t 'header'=> \"Authorization: Basic \" . base64_encode($this->user.\":\".$this->pass),\n\t\t\t\t 'method' => 'GET',\n\t\t\t\t )\n\t\t );\n \n $context = stream_context_create($options);\n $result = file_get_contents($workurl, false, $context);\n var_dump($result);\n if ($result === FALSE) \n return \"error\";\n else\n return $result;\n }", "title": "" }, { "docid": "1383af361dbb8fb85039fb7e1ade0b20", "score": "0.60617185", "text": "function process_request()\r\n {\r\n\r\n $uri_path = $this->URI_no_query();\r\n\r\n if (!file_exists($_SERVER['DOCUMENT_ROOT'] . '/' . urldecode(substr($uri_path, 1)))) {\r\n\r\n $this->favicon();\r\n\r\n header($_SERVER['SERVER_PROTOCOL'] . ' 404 Not Found');\r\n $this->http_status = 404;\r\n\r\n } else {\r\n\r\n header('Last-Modified: ' . gmdate('D, d M Y H:i:s', $this->last_modified) . ' GMT');\r\n header('ETag: ' . $this->eTag);\r\n header('Cache-Control: public');\r\n\r\n /**\r\n * Always set Content-Type and Content-Length\r\n * Pipes and Proxies will need them\r\n */\r\n $mime_type = $this->get_mime_type();\r\n header('Content-Type: ' . $mime_type);\r\n header('Content-Length: ' . $this->file_length);\r\n\r\n if (@strtotime($_SERVER['HTTP_IF_MODIFIED_SINCE']) == $this->last_modified || $this->eTagHeader == $this->eTag) {\r\n\r\n header($_SERVER['SERVER_PROTOCOL'] . ' 304 Not Modified');\r\n $this->http_status = 304;\r\n\r\n } else {\r\n\r\n @readfile($this->physical_file);\r\n\r\n exit;\r\n\r\n }\r\n\r\n }\r\n\r\n exit;\r\n\r\n }", "title": "" }, { "docid": "b301dbbed2885d27cc1b8dd7264ed78f", "score": "0.60535103", "text": "protected function _execute(array $params)\n {\n if (isset($params['headers']))\n {\n // Save the headers in $_SERVER\n if (($headers = json_decode($params['headers'], true)) !== NULL)\n {\n foreach ($headers as $name => $value)\n {\n $_SERVER['HTTP_'. strtoupper($name)] = (string) $value;\n }\n }\n // Remove the headers before execute the request.\n unset($params['headers']);\n }\n if (isset($params['method']))\n {\n // Use the specified method.\n $method = strtoupper($params['method']);\n }\n else\n {\n $method = 'GET';\n }\n if (isset($params['get']))\n {\n // Overload the global GET data.\n parse_str($params['get'], $_GET);\n }\n if (isset($params['post']))\n {\n // Overload the global POST data.\n parse_str($params['post'], $_POST);\n }\n print Request::factory($params['resource'])\n ->method($method)\n ->execute();\n }", "title": "" }, { "docid": "18b49ded8f1622d321e9035d4ad827c4", "score": "0.6053231", "text": "private function sendCurl()\n {\n try {\n // init\n $curl = curl_init();\n $url = $this->url;\n\n if ($curl === false) {\n throw new Exception('Curl failed to initialize');\n }\n\n // method\n curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $this->method);\n\n switch ($this->method) {\n case self::POST:\n curl_setopt($curl, CURLOPT_POST, 1);\n break;\n case self::GET:\n if (!empty($this->params))\n $url = sprintf(\"%s?%s\", $this->url, http_build_query($this->params));\n break;\n }\n\n if (in_array($this->method, [self::PATCH, self::PUT, self::POST])) {\n if (!empty($this->params)) {\n $params = $this->getParamsByType();\n curl_setopt($curl, CURLOPT_POSTFIELDS, $params);\n }\n }\n\n // options\n $headers = $this->getHeaders();\n curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, Url::isHttps());\n curl_setopt($curl, CURLOPT_URL, $url);\n curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($curl, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);\n curl_setopt($curl, CURLOPT_FRESH_CONNECT, true);\n curl_setopt($curl, CURLOPT_DNS_CACHE_TIMEOUT, 10);\n\n $hasBackground = $this->getBackground();\n if ($hasBackground) {\n curl_setopt($curl, CURLOPT_TIMEOUT, 1);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, false);\n curl_setopt($curl, CURLOPT_FORBID_REUSE, true);\n }\n\n $timeout = $this->getTimeout();\n if (!empty($timeout))\n curl_setopt($curl, CURLOPT_CONNECTTIMEOUT_MS, $timeout);\n\n $user_agent = $this->getHeaders('User-Agent');\n if (!empty($user_agent))\n curl_setopt($curl, CURLOPT_USERAGENT, $user_agent);\n\n // execute\n $result = curl_exec($curl);\n curl_close($curl);\n } catch (Exception $error) {\n trigger_error(sprintf(\n 'Curl failed with error #%d: %s',\n $error->getCode(), $error->getMessage()),\n E_USER_ERROR);\n }\n return $result ? $result : false;\n }", "title": "" }, { "docid": "aa0c0793ed7ac63ad4d94ec03f8c241a", "score": "0.60401684", "text": "public function http_request(string $uri, string $method = 'GET', array $post = [], array $get = [], array $cookie = [])\n{ \n\n // Setup test request\n if (!$app = app::get_instance()) { \n $app = new app('test');\n }\n $app->setup_test($uri, $method, $post, $get, $cookie);\n\n // Handle request\n app::call([\"apex\\\\core\\\\controller\\\\http_requests\\\\\" . app::get_http_controller(), 'process']);\n\n // Return response\n return app::get_res_body();\n\n}", "title": "" }, { "docid": "7dcf27d7972115150625cd16e2d1eb0d", "score": "0.60391474", "text": "public function sendRequest() {\n // Make sure we're in a position to make the request, by checking that all\n // the agent parameters have been set correctly.\n if (!$this->verifyAgent()) {\n throw new \\BadMethodCallException('Unable to make request: the agent details (host) have not been set correctly.');\n }\n\n // Now check that all the metric parameters have been set correctly.\n if (!$this->verifyMetric()) {\n throw new \\BadMethodCallException('Unable to make request: the metric details (duration, name, guid) have not been set correctly.');\n }\n\n foreach ($this->getComponents() as $component) {\n if (!$component->verify()) {\n throw new \\BadMethodCallException('Unable to make request: component with name \"' . $component->name . '\" could not be verified.');\n }\n }\n\n $curl = curl_init();\n\n // Set the URL where the API call will be made.\n curl_setopt($curl, CURLOPT_URL, $this->url);\n\n // Turn the headers into an array and let cURL have them.\n $headers = array(\n 'X-License-Key: ' . $this->licenseKey,\n 'Content-Type: application/json',\n 'Accept: application/json',\n );\n\n curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);\n\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE);\n curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);\n curl_setopt($curl, CURLOPT_TIMEOUT, 30);\n\n // Create the JSON to be sent to the API and provide it to cURL.\n $json = $this->createJson();\n\n curl_setopt($curl, CURLOPT_POST, TRUE);\n curl_setopt($curl, CURLOPT_POSTFIELDS, $json);\n\n // Make the cURL request and record the response.\n $this->response = curl_exec($curl);\n }", "title": "" }, { "docid": "3e49faf616ede55dac120306fc4a096f", "score": "0.6038834", "text": "function doRequest($uri, $method=\"GET\", $args=array(), $content='') {\n \n if(!$this->isReady()) {\n $this->error(\"doRequest() - object not ready.\");\n return false;\n }\n \n /* build up the full URL */\n \n $uri = trim($uri, \"/\");\n \n $url = littlemdesign_web_http_URL::create($this->baseURL.$uri);\n \n /* \n * if they actually provide 'null' for arguments, then\n * we want NO arguments at all, not even api_key.\n * \n */\n \n if($args !== null) {\n $url->mergeQuery(array('api_key' => $this->key));\n $url->mergeQuery($args);\n }\n \n $url->setEncoding(littlemdesign_web_http_URL::RFC_3986);\n \n $urlString = $url->toString();\n \n $this->info(\"doRequest() - doing ($method): $urlString\");\n \n /* actually make the request */\n \n $result = $this->request($method, $urlString);\n \n /* havest the result */\n \n if(!isset($result->data)) {\n $this->error(\"Could not get account info.\");\n return ;\n }\n \n /* pass it back */\n \n $info = json_decode($result->data);\n \n return $info;\n }", "title": "" }, { "docid": "23b76b6af1547a2d6be2a3ab2d1f3426", "score": "0.6027146", "text": "public function autoRequest() {\n\n $this->doRequest($_SERVER['REQUEST_URI'], $_GET, $_POST);\n \n }", "title": "" }, { "docid": "fb736ae2e4e401be2c98a57586273c84", "score": "0.60210395", "text": "public function process()\n\t{\n\t\tif ($this->authentication instanceof Authentication) {\n\t\t\t$this->curl = ($this->authentication->process());\n\t\t} else {\n\t\t\t$this->curl = curl_init();\n\t\t}\n\t\t\n\t\tcurl_setopt_array($this->curl, $this->curlOptions);\n\t\tcurl_setopt($this->curl, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($this->curl, CURLOPT_HEADER, 0);\n\t\tcurl_setopt($this->curl, CURLOPT_COOKIESESSION, TRUE); \n\t\tcurl_setopt($this->curl, CURLOPT_NOBODY, false); \n\t\t$this->crawl($this->siteUrl);\n\t}", "title": "" }, { "docid": "93bdb73ff63012755204c8e8bd2d13bd", "score": "0.6020945", "text": "private function execRequest()\n {\n $response = curl_exec($this->curl);\n if ($response !== false) {\n $statusCode = curl_getinfo($this->curl, CURLINFO_HTTP_CODE);\n if (in_array($statusCode, $this->getOkResponseCodes()) !== false) {\n $httpResponse = new HttpResponse($statusCode, $response);\n return $httpResponse;\n }\n }\n return false;\n }", "title": "" }, { "docid": "8d413924cc635c2da785f319c0b309bc", "score": "0.60128665", "text": "function send_request($url)\n {\n // Clear the result and error from the previous operation\n $this->result = null;\n $this->error = null;\n\n // Send the request and store the results in the response\n // attribute for debugging purposes\n if($this->response = @file($url))\n {\n // Check if nothing was returned in the response\n if(count($this->response) == 0)\n {\n $this->error = ERROR_INVALID_RESPONSE;\n return false;\n }\n else\n {\n // Check the first line in the response.\n // we are expecting a response of the form:\n //\n // id: a4c5ad77ad6faf5aa55f66a\n //\n // or\n //\n // credits: 2334\n //\n // or\n //\n // err: invalid login credentials\n //\n // etc...\n $op_code = $this->get_op_code($this->response[0]);\n $op_result = $this->get_op_result($this->response[0]);\n\n // Look for an error, i.e. err:\n if($op_code == OP_CODE_ERR)\n {\n $this->error = $op_result;\n return false;\n }\n else\n {\n $this->result = $op_result;\n return true;\n }\n }\n }\n else\n {\n // Gateway is not responding\n $this->error = ERROR_SMS_GATEWAY_UNREACHABLE;\n return false;\n }\n }", "title": "" }, { "docid": "bfbb64b1526992803c2fd8ba319e1dfa", "score": "0.6012144", "text": "protected function runRequest()\n {\n return $this->connection->request($this->grammar->compileRequest($this));\n }", "title": "" }, { "docid": "2a8427e68ede3c240918bd5df11b442a", "score": "0.6008161", "text": "public function makeRequest(): HttpRequestInterface\n {\n $url = $this->url ?? '';\n curl_setopt($this->curl, CURLOPT_URL, $url);\n curl_setopt($this->curl, CURLOPT_CUSTOMREQUEST, $this->method->value);\n curl_setopt($this->curl, CURLOPT_USERAGENT, $this->userAgent);\n $header = [];\n $header[] = 'Accept-language: ' . $this->language;\n if (count($this->cookies) !== 0) {\n $cookie = '';\n /**\n * @var string $name\n * @var string $value\n */\n foreach ($this->cookies as $name => $value) {\n $cookie .= $name . '=' . $value . '; ';\n }\n curl_setopt($this->curl, CURLOPT_COOKIE, $cookie);\n }\n if (count($this->arguments) !== 0) {\n if ($this->contentType == self::CONTENT_TYPE_JSON) {\n $arguments = json_encode($this->arguments);\n } else {\n $arguments = http_build_query($this->arguments);\n }\n switch ($this->method) {\n case RequestMethod::GET:\n case RequestMethod::DELETE:\n $url .= '?' . $arguments;\n break;\n case RequestMethod::POST:\n case RequestMethod::PUT:\n case RequestMethod::PATCH:\n curl_setopt($this->curl, CURLOPT_POSTFIELDS, $arguments);\n if ($this->contentType) {\n $header[] = 'Content-Type: ' . $this->contentType;\n }\n $header[] = 'Content-Length: ' . (string)strlen($arguments);\n break;\n }\n }\n\n /**\n * @var string $headerKey\n * @var string $headerVal\n */\n foreach ($this->headers as $headerKey => $headerVal) {\n $header[] = $headerKey . ': ' . $headerVal;\n }\n\n if ($this->username && $this->password) {\n curl_setopt($this->curl, CURLOPT_USERPWD, $this->getAuthenticationString());\n }\n if ($this->referer) {\n curl_setopt($this->curl, CURLOPT_REFERER, $this->referer);\n }\n curl_setopt($this->curl, CURLOPT_URL, $url);\n curl_setopt($this->curl, CURLOPT_HTTPHEADER, $header);\n curl_setopt($this->curl, CURLOPT_CONNECTTIMEOUT, 10);\n curl_setopt($this->curl, CURLOPT_HEADER, 1);\n curl_setopt($this->curl, CURLOPT_RETURNTRANSFER, true);\n $response = curl_exec($this->curl);\n if (is_bool($response)) {\n $response = '';\n }\n $headerSize = (int)curl_getinfo($this->curl, CURLINFO_HEADER_SIZE);\n $header = substr($response, 0, $headerSize);\n $this->parseResponseCode(explode(\"\\n\", $header));\n $this->response = new Response(\n substr($response, $headerSize),\n ($this->responseCode ?? ResponseCode::HTTP_CODE_500)\n );\n $this->parseHeaders(explode(\"\\n\", $header));\n curl_close($this->curl);\n\n return $this;\n }", "title": "" }, { "docid": "94392014958f7461180318d10b54b557", "score": "0.5994261", "text": "public function request($url, array $data = array(), $method = 'GET', $timeout = 15);", "title": "" }, { "docid": "33860e315b1756ffd6a0ef6fd2eac44e", "score": "0.59926564", "text": "public function HandleRequest(){\n header(\"Content-Type:application/json\");\n $responseBody = \"\";\n\n $credentials = $this->GetAuthorization();\n if(!$this->IsAuthorized($credentials)){\n $responseBody = $this->SendNotAuthorized();\n }else{\n $input = $this->GetJsonBodyContent();\n $method = $_SERVER['REQUEST_METHOD'];\n if($method == \"GET\"){\n $responseBody = $this->GET($input);\n }else if($method == \"POST\"){\n $responseBody = $this->POST($input);\n }else if($method == \"PUT\"){\n $responseBody = $this->PUT($input);\n }\n }\n $this->SendAnswer($responseBody);\n }", "title": "" }, { "docid": "ed86ccb513de1682868b2fe0d1aa271d", "score": "0.59911513", "text": "protected function _getRequest()\n\t{\n\t}", "title": "" }, { "docid": "6c8b614713c744b140e3adb36c0a707d", "score": "0.5985703", "text": "function httpRequest($url, $auth_header, $method, $body = NULL)\n\t{\n\t\tif (!$method) {\n\t\t\t$method = \"GET\";\n\t\t};\n\n\t\t$curl = curl_init();\n\t\tcurl_setopt($curl, CURLOPT_URL, $url);\n\t\tcurl_setopt($curl, CURLOPT_HEADER, 0);\n\t\tcurl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($curl, CURLOPT_HTTPHEADER, array($auth_header)); // Set the headers.\n\n\t\tif ($body) {\n\t\t\tcurl_setopt($curl, CURLOPT_POST, 1);\n\t\t\tcurl_setopt($curl, CURLOPT_POSTFIELDS, $body);\n\t\t\tcurl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method);\n\t\t\tcurl_setopt($curl, CURLOPT_HTTPHEADER, array($auth_header, \"Content-Type: text/xml;charset=utf-8\"));\n\t\t}\n\n\t\t$data = curl_exec($curl);\n\t\tcurl_close($curl);\n\t\treturn $data;\n\t}", "title": "" }, { "docid": "47dc5d5c004a69dea30bbc7beb7814ee", "score": "0.59845096", "text": "abstract protected function _getRequest();", "title": "" }, { "docid": "269bb53437f3a584f36b595916d065e2", "score": "0.59766436", "text": "function inst_http_request($url_request, $returnCode = false)\n{\n $result = null;\n $adapter = null;\n $response = null;\n $error = null;\n\n try {\n\n $bouncer = new \\PEAR2\\HTTP\\Request($url_request);\n\n $result = $bouncer->sendRequest();\n $adapter = $bouncer->getAdapterName();\n\n $response = $result->body;\n\n } catch (\\Exception $exception) {\n $error = $exception->getMessage();\n }\n\n x_install_log(\n 'inst_http_request() result',\n array(\n 'url_request' => $url_request,\n 'adapter' => $adapter,\n 'result' => $result,\n 'response' => $response,\n 'error' => $error,\n )\n );\n\n return $returnCode && $result ? $result->code : $response;\n}", "title": "" }, { "docid": "1ba5b4ac76d4df7dd4b20da94aa27eee", "score": "0.5975812", "text": "public function request($url, array $params);", "title": "" }, { "docid": "52a5eb3f42a629bf906d062a08ac519b", "score": "0.5973766", "text": "private function sendRequest() {\n if(!is_resource($this->ch)) {\n throw new Exception(\"No valid CURL object.\");\n }\n \n $this->response_body = curl_exec($this->ch);\n $this->curl_info = curl_getinfo($this->ch);\n $this->response_status_code = $this->curl_info['http_code'];\n\n $header_size = $this->curl_info['header_size'];\n $response_headers_str = substr($this->response_body, 0, $header_size);\n $this->response_headers = $this->parse_response_headers($response_headers_str);\n $this->response_body = substr($this->response_body, $header_size);\n \n $log_priority_level = ($this->response_status_code == '200' && !empty($this->response_body)) ? LOG_INFO : LOG_ERR;\n $log_message = ($this->response_status_code == '200' && !empty($this->response_body)) ? \"API call success: \" . $this->url : \"API call failure: \" . $this->url;\n \n\n return $this->response_body;\n }", "title": "" }, { "docid": "46446b4a84609764c61770ecd81cecae", "score": "0.5971852", "text": "public function getAction()\r\n {\r\n $this->send($this->_request, $this->_response, apache_request_headers());\r\n }", "title": "" }, { "docid": "c65e0f42997781a0f80a0c95cdbd345c", "score": "0.59698045", "text": "abstract protected function _getResponse();", "title": "" }, { "docid": "9d796092e6ca1232d6742d03665677e9", "score": "0.5964492", "text": "protected function _sendRequest()\r\n {\r\n $url = $this->postUrl();\r\n $request = curl_init($url);\r\n curl_setopt($request, CURLOPT_POSTFIELDS, $this->_getPostString());\r\n curl_setopt($request, CURLOPT_HEADER, 0);\r\n curl_setopt($request, CURLOPT_TIMEOUT, 45);\r\n curl_setopt($request, CURLOPT_RETURNTRANSFER, 1);\r\n curl_setopt($request, CURLOPT_SSL_VERIFYHOST, 2);\r\n curl_setopt($request, CURLOPT_SSL_VERIFYPEER, false);\r\n\r\n if (preg_match('/xml/',$url)) {\r\n curl_setopt($request, CURLOPT_HTTPHEADER, Array(\"Content-Type: text/xml\"));\r\n }\r\n\r\n $response = curl_exec($request);\r\n curl_close($request);\r\n\r\n return $response;\r\n }", "title": "" }, { "docid": "9f74e03134adb30c85ed52cbe7fcfb8f", "score": "0.5948337", "text": "public function send() {\n\n $parsedRequest = new PreparedRequest($this->url, $this->method, $this->headers, $this->payload);\n\n $parsedRequest->setConfigurationName($this->configurationName);\n \n if($this->debugMode)\n $parsedRequest->setDebugMode(true);\n\n $content = $this->executor->connectAndGet($parsedRequest);\n $response = new PreparedResponse($content);\n\n if($this->debugMode)\n $response->debugLog = $this->executor->getDebugLog();\n\n return $response->getResponse();\n\n }", "title": "" }, { "docid": "9e0ae7e345af7a406e55b4b2e978ba6b", "score": "0.5948209", "text": "public function main()\n {\n if (!isset($this->_url)) {\n throw new BuildException(\"Missing attribute 'url' set\");\n }\n\n $request = new HTTP_Request2($this->_url);\n\n // set the authentication data\n if (!empty($this->_authUser)) {\n $request->setAuth(\n $this->_authUser,\n $this->_authPassword,\n $this->_authScheme\n );\n }\n\n foreach ($this->_configData as $config) {\n $request->setConfig($config->getName(), $config->getValue());\n }\n\n foreach ($this->_headers as $header) {\n $request->setHeader($header->getName(), $header->getValue());\n }\n\n if ($this->_verbose) {\n $observer = new HTTP_Request2_Observer_Log();\n\n // set the events we want to log\n $observer->events = $this->_observerEvents;\n\n $request->attach($observer);\n }\n\n $response = $request->send();\n\n if ($this->_responseRegex !== '') {\n $matches = array();\n preg_match($this->_responseRegex, $response->getBody(), $matches);\n\n if (count($matches) === 0) {\n throw new BuildException(\n 'The received response body did not match the '\n . 'given regular expression'\n );\n } else {\n $this->log('The response body matched the provided regex.');\n }\n }\n }", "title": "" }, { "docid": "702e1ee1e8b421b084be38947263a203", "score": "0.5939246", "text": "protected function HTTP($method,$url,$data=null) {\n\t\t// add the API Token\n\t\tif (strpos($url,'?')===false) {\n\t\t\t$url .= '?api_token='.urlencode($this->APIToken);\n\t\t}\n\t\telse {\n\t\t\t$url .= '&api_token='.urlencode($this->APIToken);\n\t\t}\n\t\t$content = $method.\" \".$url.\" HTTP/1.0\\r\\n\";\n\t\t$content .= \"Host: \".$this->Subdomain.\".curdbee.com\\r\\n\";\n\t\t$content .= \"Accept: text/json,text/html,text/plain,*/*\\r\\n\";\n\t\t$content .= \"User-Agent: CurdBeePHP/\".$this->Version.\"\\r\\n\";\n\t\t$content .= \"Content-Type: application/json\\r\\n\"; \n\t\tif ($data) {\n\t\t\t$content .= \"Content-Length: \".strlen($data).\"\\r\\n\";\n\t\t}\n\t\t$content .= \"\\r\\n\";\n\t\t$content .= $data;\n\t\t$this->LastRequest = $content;\n\t\t$this->LastResponse = null;\n\t\t$this->LastHTTPStatus = null;\n\t\t$this->LastHTTPMessage = null;\n\n\t\t$fp = fsockopen('ssl://'.$this->Subdomain.'.curdbee.com', 443, $errno, $errstr, 180);\n\t\tif (!$fp) {\n\t\t\tthrow new Exception('Could not connect to server ['.$errstr.']. Check that your subdomain is correct and that you have network access.');\n\t\t}\n\n\t\tfwrite($fp, $content, strlen($content));\n\t\t$response = '';\n\t\twhile (!feof($fp)) {\n\t\t\t$response .= fread($fp,1024*10);\n\t\t}\n\t\tfclose($fp);\n\t\t$this->LastResponse = $response;\n\n\t\t// strip out headers and send back the body decoded\n\t\tif (preg_match(\"/^(.*?)(\\r\\n\\r\\n(.*))?$/s\",$response,$temp)) {\n\t\t\t$headers = trim($temp[1]);\n\t\t\t$body = trim($temp[3]);\n\t\t}\n\t\telse {\n\t\t\tthrow new Exception('Something very bad happened (this should never happen for HTTP protocol requests)');\n\t\t}\n\t\t$json = json_decode($body);\n\n\t\t// look for error statuses\n\t\tif (preg_match('/^HTTP\\/\\d+\\.\\d+ (\\d+) ([^\\r\\n]+)/',$headers,$temp)) {\n\t\t\t$HTTPStatus = $temp[1];\n\t\t\t$HTTPMessage = $temp[2];\n\t\t}\n\t\telse {\n\t\t\tthrow new Exception('Something else very bad happened (this should never happen for HTTP protocol requests)');\n\t\t}\n\t\t$this->LastHTTPStatus = $HTTPStatus;\n\t\t$this->LastHTTPMessage = $HTTPMessage;\n\n\t\t// if it's anything other than a 2xx it was an error\n\t\tif ($HTTPStatus<200 || $HTTPStatus>299) {\n\t\t\t// look for errors\n\t\t\tif ($body && is_array($json) && is_array($json[0])) {\n\t\t\t\t$error = '';\n\t\t\t\tforeach ($json as $err) {\n\t\t\t\t\t$error .= \"$err[0] $err[1]\\n\";\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$error = $HTTPMessage;\n\t\t\t}\n\t\t\tthrow new Exception($error,$HTTPStatus);\n\t\t}\n\n\t\tif ($body) {\n\t\t\treturn $json;\n\t\t}\n\n\t\treturn true;\n\t}", "title": "" }, { "docid": "5b22ae9615cd0b91a1609f417070bae7", "score": "0.59352124", "text": "public function request($params);", "title": "" }, { "docid": "5e86eae80e08d1cc96927f7e32414b12", "score": "0.59329027", "text": "public function start() {\n if (isset($_SERVER) && isset($_SERVER[\"REQUEST_METHOD\"])) {\n $method = strtolower($_SERVER[\"REQUEST_METHOD\"]);\n if($method === \"get\" && !empty($_GET[\"q\"])){\n $this->redirectRequest($_GET[\"q\"]);\n return;\n }\n }\n try {\n $api = new Api();\n if (@method_exists($api,$method)){\n $response = $api->{$method}();\n $this->sendDataResponse($response);\n } else {\n $this->sendErrorResponse(\"Unknown operation.\");\n }\n } catch (Exception $exc) {\n $this->sendErrorResponse($exc->getMessage());\n }\n }", "title": "" }, { "docid": "b996af43cf7c19eebc7038a77674734c", "score": "0.59295994", "text": "function http_request($method, $url = null, $body = null, array $options = null, array &$info = null)\n {\n }", "title": "" }, { "docid": "d2af3e2b6f95dc931c807437ca33b68f", "score": "0.59287876", "text": "public function perform_task()\n { \n $this->action = '';\n if (isset($this->request['action'])) {\n $this->action = $this->request['action'];\n }\n\n switch ($this->action){\n \n // Get videos for a report or all reports\n case 'get':\n $ret_value = $this->_get_cures();\n break;\n \n // Proper action not set\n default:\n // System information mainly obtained through use of callback\n // Therefore set the default response to \"not found\"\n $ret_value = 999;\n }\n //$this->response_data = $this->response($ret_value);\n $this->response_data = $ret_value;\n }", "title": "" }, { "docid": "a82ac3e6556e90f465de3ffcd223ae63", "score": "0.5928322", "text": "function request($host, $path, $url_params = array()) {\n try {\n $curl = curl_init();\n if (FALSE === $curl)\n echo 'Failed to initialize';\n\n $url = $host . $path . \"?\" . http_build_query($url_params);\n curl_setopt_array($curl, array(\n CURLOPT_URL => $url,\n CURLOPT_RETURNTRANSFER => true, // Capture response.\n CURLOPT_ENCODING => \"\", \n CURLOPT_MAXREDIRS => 10,\n CURLOPT_TIMEOUT => 30,\n CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\n CURLOPT_CUSTOMREQUEST => \"GET\",\n CURLOPT_HTTPHEADER => array(\n \"authorization: Bearer \" . $GLOBALS['API_KEY'],\n \"cache-control: no-cache\",\n ),\n ));\n\n $response = curl_exec($curl);\n $http_status = 0;\n if (FALSE === $response){\n //throw new Exception(curl_error($curl), curl_errno($curl)); \n \n $http_status = curl_getinfo($curl, CURLINFO_HTTP_CODE);\n }\n if (200 != $http_status)\n //throw new Exception($response, $http_status);\n\n curl_close($curl);\n } catch(Exception $e) {\n trigger_error(sprintf(\n 'Curl failed with error #%d: %s',\n $e->getCode(), $e->getMessage()),\n E_USER_ERROR);\n }\n\n return $response;\n}", "title": "" }, { "docid": "a297bf27ec655773a20593894c066a76", "score": "0.59229153", "text": "function do_request($method, $uri, $payload = null, $params) {\n $curl = curl_init();\n $base_url = $params['enable_sandbox'] == \"on\" ? \"https://gateway.sandbox.fatzebra.com.au/v1.0\" : \"https://gateway.fatzebra.com.au/v1.0\";\n $url = $base_url. $uri;\n curl_setopt($curl, CURLOPT_URL, $url);\n\n $headers = array(\"User-Agent: FatZebra WHMCS Library \" . FATZEBRA_VERSION,\n \"Content-Type: application/json\");\n if (isset($params['requires_bless']) && isset($params['bless_token'])) {\n $headers[] = \"X-FatZebra-Cart: \" . $params['bless_token'];\n }\n\n curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, true);\n curl_setopt($curl, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);\n curl_setopt($curl, CURLOPT_USERPWD, $params['username'].\":\". $params['token']);\n curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);\n\n if ($method == \"POST\" || $method == \"PUT\") {\n curl_setopt($curl, CURLOPT_POST, true);\n curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode($payload));\n }\n\n if ($method == \"PUT\") {\n curl_setopt($curl, CURLOPT_CUSTOMREQUEST, \"PUT\");\n }\n\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, true);\n curl_setopt($curl, CURLOPT_CAINFO, dirname(__FILE__) . DIRECTORY_SEPARATOR . 'cacert.pem');\n curl_setopt($curl, CURLOPT_TIMEOUT, 40);\n\n $data = curl_exec($curl);\n\n if (curl_errno($curl) !== 0) {\n throw new Exception(\"cURL error: \" . curl_error($curl));\n }\n curl_close($curl);\n\n $response = json_decode($data);\n if (is_null($response)) {\n $err = json_last_error();\n if ($err == JSON_ERROR_SYNTAX) {\n throw new Exception(\"JSON Syntax error. JSON attempted to parse: \" . $data);\n } elseif ($err == JSON_ERROR_UTF8) {\n throw new Exception(\"JSON Data invalid - Malformed UTF-8 characters. Data: \" . $data);\n } else {\n throw new Exception(\"JSON parse failed. Unknown error. Data:\" . $data);\n }\n }\n\n return $response;\n}", "title": "" }, { "docid": "54376300be5e3938a25b9cd44c64a20e", "score": "0.59179384", "text": "public function processRequest()\r\n {\r\n switch ($this->requestMethod) {\r\n case 'GET':\r\n if ($this->orderId) {\r\n $response = $this->productOrderService->getOrder($this->orderId);\r\n } else {\r\n $response = $this->productOrderService->getAllOrders();\r\n };\r\n break;\r\n case 'POST':\r\n $response = $this->productOrderService->createOrderFromRequest();\r\n break;\r\n case 'PUT':\r\n $response = $this->productOrderService->updateOrderFromRequest($this->orderId);\r\n break;\r\n case 'DELETE':\r\n $response = $this->productOrderService->deleteOrder($this->orderId);\r\n break;\r\n default:\r\n $response = $this->notFoundResponse();\r\n break;\r\n }\r\n header($response['status_code_header']);\r\n if ($response['body']) {\r\n echo $response['body'];\r\n }\r\n }", "title": "" }, { "docid": "bf323cf6eafdf55c8ea2ae3a2a562d4c", "score": "0.5916087", "text": "public function request($method, $path, $query=array(), $doAuth=false);", "title": "" }, { "docid": "55dbe9342ba24cb8741182e92613724e", "score": "0.5902775", "text": "protected function request_uri( $uri)\n{$ch = curl_init();\ncurl_setopt($ch, CURLOPT_URL, $uri);\ncurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\ncurl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 4);\nreturn curl_exec($ch);\n}", "title": "" }, { "docid": "734ab09c142ad29bed5a78a34bb40606", "score": "0.5902216", "text": "private function __request( $httpMethod, $url, $parameters = array( ) ) \n\t{\n\t\t$builtUrl = $this->endPoint . $url;\n\t\t\n\t\t// If this is a GET request, and an array of parameters were provided.\n\t\tif ( $httpMethod == 'GET' && is_array( $parameters ) && sizeof( $parameters ) )\n\t\t{\n\t\t\t$builtUrl .= '?' . http_build_query( $parameters );\n\t\t}\n\t\t\n\t\t// Initialize a cURL request.\n\t\t$curl = curl_init( $builtUrl );\n\t\t\n\t\tcurl_setopt( $curl, CURLINFO_HEADER_OUT, 1 );\n\t\tcurl_setopt( $curl, CURLOPT_RETURNTRANSFER, 1 );\n\t\tcurl_setopt( $curl, CURLOPT_SSL_VERIFYPEER, false );\n\t\tcurl_setopt( $curl, CURLOPT_USERAGENT, 'Raide/1.0 (PHP)' );\n\t\t\n\t\t// Append an Authentication header with the Account's ID, API Key and API Password.\n\t\tcurl_setopt( $curl, CURLOPT_HTTPHEADER, array( \n\t\t\t'Authentication: id=' . $this->accountId . ';key=' . $this->apiKey . ';password=' . $this->apiPassword\n\t\t) );\n\t\t\n\t\t// If this is either a DELETE, POST or PUT request.\n\t\tif ( $httpMethod != 'GET' ) \n\t\t{\n\t\t\t// If this is a POST request.\n\t\t\tif ( $httpMethod == 'POST' ) \n\t\t\t{\n\t\t\t\tcurl_setopt( $curl, CURLOPT_POST, 1 );\n\t\t\t}\n\t\t\t// If this is a DELETE or PUT request.\n\t\t\telse \n\t\t\t{\n\t\t\t\tcurl_setopt( $curl, CURLOPT_CUSTOMREQUEST, $httpMethod );\n\t\t\t}\n\t\t\t\n\t\t\t// If parameters were provided, pass them to the server.\n\t\t\tif ( !is_null( $parameters ) ) \n\t\t\t{\n\t\t\t\tcurl_setopt( $curl, CURLOPT_POSTFIELDS, http_build_query( $parameters ) );\n\t\t\t}\n\t\t}\n\t\t\n\t\t// Fetch the returned data from this cURL request.\n\t\t$rawResponse = curl_exec( $curl );\n\t\t\n\t\t// What HTTP Code was returned?\n\t\t$httpCode = curl_getinfo( $curl, CURLINFO_HTTP_CODE );\n\t\t\n\t\t// Close the cURL request.\n\t\tcurl_close( $curl );\n\t\t\n\t\t// Return both the HTTP Code and the Raw Response.\n\t\treturn array(\n\t\t\t$httpCode,\n\t\t\t$rawResponse\n\t\t);\n\t}", "title": "" }, { "docid": "d441c14fd4884331062d5b4f8e320eeb", "score": "0.59017754", "text": "function request($method, $url = '', $body = null, array $headers = []) {\n\t\tif (!$this->_is_allowed($method)) {\n\t\t\terror_log('Method ' . $method . ' not supported by server');\n\t\t\treturn false;\n\t\t}\n\n\t\t// Prepare URL\n\t\t$uri = $this->connection['path'];\n\t\tif ($url != '/') $uri .= $url;\n\t\t$uri = $this->connection['uri'] . str_replace('%2F', '/', rawurlencode($uri));\n\n\t\t// Init CURL\n\t\t$ch = curl_init($uri);\n\t\tcurl_setopt($ch, CURLOPT_USERAGENT, $this->connection['ua']);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n\t\tcurl_setopt($ch, CURLOPT_CUSTOMREQUEST, $method);\n\t\tcurl_setopt($ch, CURLOPT_HEADERFUNCTION, array($this, 'readHeader'));\n\t\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, $this->connection['ssl']? 1 : 0);\n\t\tcurl_setopt($ch, CURLOPT_SSL_VERIFYHOST, $this->connection['ssl']? 2 : 0);\n\n\t\tif ($this->connection['proxy'])\n\t\t\tcurl_setopt($ch, CURLOPT_PROXY, $this->connection['proxy']);\n\n\t\tif (is_string($this->connection['user']) && $this->connection['auth']) {\n\t\t\tswitch($this->connection['auth']) {\n\t\t\t\tcase 'basic':\n\t\t\t\t\tcurl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'digest':\n\t\t\t\t\tcurl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_DIGEST);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\terror_log('Unknown authorization scheme');\n\t\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tcurl_setopt($ch, CURLOPT_USERPWD, $this->connection['user'] . ':' . @$this->connection['password']);\n\t\t}\n\n\t\t// Prepare headers\n\t\tif (empty($headers['Content-Type']))\n\t\t\t$headers['Content-Type'] = 'application/octet-stream';\n\n\t\t$this->_headers = array();\n\t\t$req_header = array();\n\t\tforeach ($headers as $header => $value) {\n\t\t\t$req_header[] = \"$header: $value\";\n\t\t}\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, $req_header);\n\n\t\tif (!empty($body)) {\n\t\t\tcurl_setopt($ch, CURLOPT_POST, true);\n\n\t\t\tif (is_resource($body)) {\n\t\t\t\tcurl_setopt($ch, CURLOPT_UPLOAD, 1);\n\t\t\t\tcurl_setopt($ch, CURLOPT_INFILE, $body);\n\t\t\t} else\n\t\t\t\tcurl_setopt($ch, CURLOPT_POSTFIELDS, $body);\n\t\t}\n\n\t\t$content = curl_exec($ch);\n\t\t$res = curl_getinfo( $ch );\n\t\tcurl_close($ch);\n\n\t\treturn [\n\t\t\t'body' => $content,\n\t\t\t'statusCode' => (int)$res['http_code'],\n\t\t\t'headers' => array_change_key_case($this->_headers)\n\t\t];\n\t}", "title": "" }, { "docid": "ca8864a7fb4e5d289c2358b9d6b1a2a8", "score": "0.5894765", "text": "function getRequest();", "title": "" }, { "docid": "b81bf0b173444cc52636554b53c8aae2", "score": "0.5893817", "text": "private function request($call){\r\n$url = $this->format_url($call);\r\n//caching\r\nif(self::CACHE_ENABLED){\r\n$cacheFile = dirname(__FILE__).'/cache/' . md5($url);\r\n\r\nif (file_exists($cacheFile)) {\r\n$fh = fopen($cacheFile, 'r');\r\n$cacheTime = trim(fgets($fh));\r\n// if data was cached recently, return cached data\r\nif ($cacheTime > strtotime('-'. self::CACHE_LIFETIME_MINUTES . ' minutes')) {\r\n return fread($fh,filesize($cacheFile));\r\n}\r\n// else delete cache file\r\nfclose($fh);\r\nunlink($cacheFile);\r\n}\r\n}\r\n//call the API and return the result\r\n$ch = curl_init($url);\r\ncurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\r\n$result = curl_exec($ch);\r\ncurl_close($ch);\r\nif(self::CACHE_ENABLED){\r\n //create cache file\r\n $fh = fopen($cacheFile, 'w');\r\n fwrite($fh, time() . \"\\n\");\r\n fwrite($fh, $result);\r\n fclose($fh);\r\n}\r\nreturn $result;\r\n}", "title": "" }, { "docid": "d9da1d352cd8bbf2a5313075c9c4c042", "score": "0.5885174", "text": "function request($url, $params = false) {\n\t\t$req =& new HTTP_Request($this->base . $url);\n\t\t//authorize\n\t\t$req->setBasicAuth($this->user, $this->pass);\n\t\t//set the headers\n\t\t$req->addHeader(\"Accept\", \"application/xml\");\n\t\t$req->addHeader(\"Content-Type\", \"application/xml\");\n\t\t//if were sending stuff\n\t\tif ($params) {\n\t\t\t//serialize the data\n\t\t\t$xml = $this->serialize($params);\n\t\t\t//print_r($xml);\n\t\t\t($xml)?$req->setBody($xml):false;\n\t\t\t$req->setMethod(HTTP_REQUEST_METHOD_POST);\n\t\t}\n\t\t$response = $req->sendRequest();\n\t\t//print_r($req->getResponseHeader());\n\t\t//echo $req->getResponseCode() .\t\"\\n\";\n\t\t\n\t\tif (PEAR::isError($response)) {\n\t\t return $response->getMessage();\n\t\t} else {\n\t\t\t//print_r($req->getResponseBody());\n\t\t return $req->getResponseBody();\n\t\t}\n\t}", "title": "" }, { "docid": "4c20970bdd1645d15bd40b8ec7897659", "score": "0.58809376", "text": "public function execute()\r\n\t{\r\n\t\trequestUtils::handleConditionalGet();\r\n\t\t\r\n\t\t$file_sync_id = $this->getRequestParameter( \"id\" );\r\n\t\t$hash = $this->getRequestParameter( \"hash\" );\r\n\t\t$file_name = $this->getRequestParameter( \"fileName\" );\r\n\t\tif ($file_name) {\r\n\t\t\t$file_name = base64_decode($file_name);\r\n\t\t}\r\n\t\r\n\t\tkDataCenterMgr::serveFileToRemoteDataCenter ( $file_sync_id , $hash, $file_name ); \r\n\t\tdie();\r\n\t}", "title": "" }, { "docid": "9936bf1d352bcb79bbf3ff26e7faa6cd", "score": "0.58802193", "text": "public function runBuildRequest()\n {\n try {\n $this->request = new Request();\n $this->request->process();\n http_response_code($this->request->response->code);\n print_r(json_encode($this->request->response));\n } catch (Exception $e) {\n $response = new Response();\n $response->body = $e->getMessage();\n $response->code = $e->getCode();\n print_r(json_encode($response));\n }\n }", "title": "" }, { "docid": "96ac4712a95e580b1646ff55b1306020", "score": "0.58790845", "text": "public function request($path, $body, $httpMethod = 'GET', array $headers = array());", "title": "" }, { "docid": "96ac4712a95e580b1646ff55b1306020", "score": "0.58790845", "text": "public function request($path, $body, $httpMethod = 'GET', array $headers = array());", "title": "" }, { "docid": "0bf0ce4045b504b357970a229a2269c9", "score": "0.5878232", "text": "function httpRequest ($url, $arguments) {\n if (substr($url,0,7)==\"http://\") {\n $url = substr($url,7);\n }\n\n list ($host,$uri) = explode(\"/\",$url,2);\n $uri = \"/$uri\";\n\n $querystr = \"\";\n foreach ($arguments as $k => $v) {\n \t$querystr .= \"&$k=\".urlencode($v);\n }\n $querystr = substr($querystr, 1);\n\t\t$qlength = strlen($querystr);\n\n\t $remote = fsockopen($host, 80, $errno, $errstr, 30);\n\n\t\t$post =\n\t \"POST $uri HTTP/1.0\\r\\n\".\n\t \"Host: $host\\r\\n\".\n \"Content-type: application/x-www-form-urlencoded\\r\\n\".\n\t\t \"Content-length: $qlength\\r\\n\\r\\n\".\n\t\t \"$querystr\\r\\n\\r\\n\";\n\n\t\tif ($remote) {\n \t\t\tfputs($remote, $post);\n \t\t\t$response = \"\";\n \t\t\twhile(!feof($remote)) {\n \t\t\t$a = fgets($remote,4096);\n \t\t\t$response .= $a;\n \t\t\t}\n \t\t\t} else {\n $this->errorHandler (\"Connection failed $errno $errstr\");\n }\n\n list ($header, $response) = explode(\"\\r\\n\\r\\n\", $response, 2);\n list ($temp, $statuscode) = explode(\" \", $header, 2);\n list ($statuscode) = explode(\"\\r\\n\", $statuscode);\n\n if (substr($statuscode,0,3)==\"200\") {\n \t$this->response = $response;\n } else {\n\t\t\t$this->errorHandler ($statuscode);\n }\n }", "title": "" }, { "docid": "7b3b531e5f56e85b35e2225f110204f3", "score": "0.5877336", "text": "public function request($opts = []){\n \n /**\n * Default values can be overridden by defining them in the $opts passed to request\n */\n $default_options = [\n /** Payload is this library's term for all of the data being sent to the API */\n \"payload\" => [\n /** Unless overridden, every payload will send the Accept header set to application/json */\n \"headers\" => [\n 'Accept' => 'application/json'\n ]\n ]\n ];\n \n /**\n * Recursive merge of custom options over defaults\n */\n $opts = array_merge_recursive($default_options, $opts);\n \n /**\n * Method MUST be defined in the opts sent over\n */\n if (isset($opts[\"method\"])) {\n $method = $opts[\"method\"];\n } else {\n die(\"Please provide a method for your request\");\n }\n \n /**\n * URL MUST be defined in the opts sent over\n */\n if (isset($opts[\"url\"])) {\n $url = $opts[\"url\"];\n } else {\n die(\"Please provide a url for your request\");\n }\n \n $payload = $opts[\"payload\"];\n \n /** Honors debug mode set above */\n $payload['debug'] = $this->debug;\n \n /** If the bearer token has been retrieved, supply it as the auth header */\n if (isset($this->token)) {\n $payload[\"headers\"][\"Authorization\"] = sprintf(\"Bearer %s\", $this->token);\n }\n \n /** Default payload options. Can be overriden by defining them in $opt[\"payload\"] when supplied to this method */\n $payload_defaults = [\n \"allow_redirects\" => true\n ];\n \n $payload = array_merge_recursive($payload_defaults, $payload);\n $res = false;$success = false;\n \n $this->debuglog($method);\n $this->debuglog($url);\n $this->debuglog($payload);\n \n try {\n /** Fires the request */\n $res = $this->client->request($method, $url, $payload);\n $this->statuscode = $res->getStatusCode();\n $success = true;\n } \n catch(\\Exception $e) { //RequestException\n // If there are network errors, we need to ensure the application doesn't crash.\n // if $e->hasResponse is not null we can attempt to get the message\n // Otherwise, we'll just pass a network unavailable message.\n $res = $e;\n $exception = false;\n if ($e->hasResponse()) {\n $exception = (string) $e->getResponse()->getBody();\n $res = json_decode($exception);\n $this->statuscode = $e->getCode(); //http code\n } \n \n if($this->debugdat) {\n $this->debuglog(\"Request failed\");\n $this->debuglog(var_dump($exception, true));\n $this->debuglog(var_dump($e, true));\n }\n } \n \n \n $response = false;\n if(is_object($res) && $success == true){\n if($res->getBody()){\n //weirdes shit ever if you just return $res and then move \n //this line in another method it stops working...\n $response = json_decode($res->getBody()->getContents());\n }\n else{\n $this->debuglog($res);\n $response = $res; \n }\n }\n else{\n $this->debuglog($res);\n $response = $res;\n } \n return $response;\n }", "title": "" }, { "docid": "c9382f1783b5d9494b40eda43e562e69", "score": "0.5876734", "text": "function http($url, $method, $postfields = NULL) {\r\n $this->http_info = array();\r\n $ci = curl_init();\r\n /* Curl settings */\r\n\t\tif( isset( $_SERVER['HTTP_USER_AGENT'] ) ) {\r\n\t\t\tcurl_setopt( $ci, CURLOPT_USERAGENT, $_SERVER['HTTP_USER_AGENT'] );\r\n\t\t}\r\n\t\telse {\r\n\t\t\t// Handle the useragent like we are Google Chrome\r\n\t\t\tcurl_setopt( $ci, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/525.13 (KHTML, like Gecko) Chrome/0.X.Y.Z Safari/525.13.' );\r\n\t\t}\r\n curl_setopt($ci, CURLOPT_CONNECTTIMEOUT, $this->connecttimeout);\r\n curl_setopt($ci, CURLOPT_TIMEOUT, $this->timeout);\r\n curl_setopt($ci, CURLOPT_RETURNTRANSFER, TRUE);\r\n curl_setopt($ci, CURLOPT_HTTPHEADER, array('Expect:'));\r\n curl_setopt($ci, CURLOPT_SSL_VERIFYPEER, $this->ssl_verifypeer);\r\n curl_setopt($ci, CURLOPT_HEADERFUNCTION, array($this, 'getHeader'));\r\n curl_setopt($ci, CURLOPT_HEADER, FALSE);\r\n\r\n switch ($method) {\r\n case 'POST':\r\n curl_setopt($ci, CURLOPT_POST, TRUE);\r\n if (!empty($postfields)) {\r\n curl_setopt($ci, CURLOPT_POSTFIELDS, $postfields);\r\n }\r\n break;\r\n case 'DELETE':\r\n curl_setopt($ci, CURLOPT_CUSTOMREQUEST, 'DELETE');\r\n if (!empty($postfields)) {\r\n $url = \"{$url}?{$postfields}\";\r\n }\r\n }\r\n\r\n curl_setopt($ci, CURLOPT_URL, $url);\r\n $response = curl_exec($ci);\r\n $this->http_code = curl_getinfo($ci, CURLINFO_HTTP_CODE);\r\n $this->http_info = array_merge($this->http_info, curl_getinfo($ci));\r\n $this->url = $url;\r\n curl_close ($ci);\r\n return $response;\r\n }", "title": "" }, { "docid": "abf8e10e4a2259e4cfbb17e88e43d9a5", "score": "0.5860821", "text": "public function requests()\n {\n if( !($this->clientExist()) || !($this->dbConnected()) ){\n $this->configAppClient();\n $this->getResponse();\n }\n\n if( ($this->dbConnected()) && !($this->tablesExist()) ){\n $this->configAppOptions();\n $this->getResponse();\n }\n\n if( !($this->appInstalled()) ){\n $this->configAppAdmin();\n $this->getResponse();\n }\n $this->timber->redirect( $this->timber->config('request_url') . '/404' );\n }", "title": "" } ]
2dd8aa167ea50ad720032cdccfd92dc2
Initialises the object string, and type string. Feeds the expected response to the request class.
[ { "docid": "d055c808358d660c5acf45f65fe9a48f", "score": "0.5486859", "text": "public function __construct($object, $type, $response = null)\n {\n parent::__construct('update', $response);\n if (in_array($object, self::$objects)) {\n $this->object = $object;\n }\n if (in_array($type, self::$types)) {\n $this->type = $type;\n }\n }", "title": "" } ]
[ { "docid": "c57b86b202275ac9e7444eb83ccc1e13", "score": "0.6471657", "text": "public function init()\n {\n $this->response = new Response();\n }", "title": "" }, { "docid": "63c04c7b5cda5e92f44971f4de587a04", "score": "0.62103647", "text": "public function __construct()\n {\n $this->request = Request::createFromGlobals();\n $this->response = new Response();\n $this->response->headers->set('Content-Type', 'application/json');\n }", "title": "" }, { "docid": "70fc563aa9bc6632544dc329fe662501", "score": "0.61305887", "text": "public function initializeTypeSpecificResponseData(): void\n {\n $this->html = $this->responseDataArray['html'];\n $this->width = $this->responseDataArray['width'];\n $this->height = $this->responseDataArray['height'];\n }", "title": "" }, { "docid": "10e9bbc174c2536fd778b7e810265fa9", "score": "0.5879333", "text": "public function __construct($type, array $data)\n {\n $responses = $this->getArrayValue($data, 'responses', []);\n if (is_array($responses)) {\n foreach ($responses as $responseCode => $responseData) {\n $this->responses[$responseCode] = new Response(\n $responseCode,\n $this->getArrayValue($responseData, 'body') ?: [],\n $this->getArrayValue($responseData, 'description'),\n $this->getArrayValue($responseData, 'headers') ?: []\n );\n }\n }\n\n $queryParameters = $this->getArrayValue($data, 'queryParameters', []);\n if (is_array($queryParameters)) {\n foreach ($queryParameters as $name => $queryParameterData) {\n $this->queryParameters[$name] = new QueryParameter(\n $this->getArrayValue($queryParameterData, 'description'),\n $this->getArrayValue($queryParameterData, 'type', 'string'),\n $this->getArrayValue($queryParameterData, 'displayName', $this->convertKeyToDisplayName($name)),\n $this->getArrayValue($queryParameterData, 'example'),\n $this->getArrayValue($queryParameterData, 'required', false)\n );\n }\n }\n\n $this->type = strtoupper($type);\n $this->body = $this->getArrayValue($data, 'body', []);\n $this->headers = $this->getArrayValue($data, 'headers', []);\n $this->description = $this->getArrayValue($data, 'description', '');\n }", "title": "" }, { "docid": "f958e7081970b0e3e1d3615233b0e0dc", "score": "0.5779539", "text": "public function init()\n {\n $this->response->addHeader(\"Content-Type\", \"application/xml\"); \n \n parent::init();\n }", "title": "" }, { "docid": "899a339f6bba4c52e378645f4c233e8e", "score": "0.57662874", "text": "public function init()\r\n\t{\r\n\t\t\\Eve::app()->response->header('Content-Type', 'application/json');\r\n\t}", "title": "" }, { "docid": "809aea2e065f8665c3cb3bf9057ab986", "score": "0.57651216", "text": "protected function setUp()\n {\n $this->object = new Admin\\Response('content');\n }", "title": "" }, { "docid": "8b703bad78cb5735a812423ea943894b", "score": "0.5753651", "text": "function __construct(){\n $this->response = new Response();\n }", "title": "" }, { "docid": "ef70731b5e9507ed082dabc973e2f505", "score": "0.56350195", "text": "public static function init(): self\n {\n return new self(new CreateBreakTypeResponse());\n }", "title": "" }, { "docid": "572fc7001f9eae573a1fcfe8adc00279", "score": "0.5624183", "text": "protected function initialize()\n {\n $this->defaultRequest = $this->factory(function () {\n return new Request();\n });\n\n $this->router = function () {\n return new Router();\n };\n\n $this->responseClass = '\\\\Gear\\\\Network\\\\Response';\n }", "title": "" }, { "docid": "01c6142dc6847a6b78e4acc8a667a432", "score": "0.5620963", "text": "public function __construct($data,$type) {}", "title": "" }, { "docid": "bc33a5ab20ddcf8720aeee90ce7c8f59", "score": "0.56033254", "text": "public function __construct()\n {\n $this->response = new AppResponse();\n $this->response->resource = $this->resource;\n }", "title": "" }, { "docid": "ecc18442504867d28073f26b342d5214", "score": "0.5581514", "text": "public function __construct() {\n\n\t\t\tparent::__construct();\n\n\t\t\t$this->output = new HTTPResponse();\n\t\t\t\t\t\t\n\t\t\t$this->title = \"\";\n\t\t\t$this->keywords = DEFAULT_KEYWORDS;\n\t\t\t$this->description = DEFAULT_DESCRIPTION;\n\t\t\t\n\t\t\t$this->auth = Authentication::get();\n\t\t\t\n\t\t\t$this->load = new Loader();\n\t\t\t\t\t\n\t\t}", "title": "" }, { "docid": "91cc203c3893eb4f32984f8c832e1548", "score": "0.5562325", "text": "function __construct($ResponseText = \"\")\n\t{\n\t\t$this->ResponseText = $ResponseText;\n\t}", "title": "" }, { "docid": "e21c5bfe7fb8e4714badc96c76aff9fd", "score": "0.5548185", "text": "public function __construct()\n {\n //\n $this->response = new APIResponse;\n }", "title": "" }, { "docid": "bccd1547bf9ac1ef4edff1a2ea9cc66c", "score": "0.552367", "text": "function __construct() {\n // Initialize request\n $this->_request = new \\HTRequest();\n }", "title": "" }, { "docid": "4814078abc200e96f6a2d444681b8e00", "score": "0.5513228", "text": "private function __construct()\n {\n $this->_parseGet();\n $this->_parsePost();\n $this->_parsePutDelete();\n $this->_parseHeader();\n }", "title": "" }, { "docid": "da156ea3668be36bc7f9823d0a47893c", "score": "0.5491171", "text": "public function init(){\n\t\t$this->request = new bikes_Request($this);\n\t\t$this->router = new bikes_Router($this);\n\t}", "title": "" }, { "docid": "62c4879c69cc5a37a8cab96b0e95a1a2", "score": "0.54845744", "text": "public function __construct()\n {\n $this->http_response_code = 200; // Auto-good; be careful as any 400/500 code aborts request\n $this->output = array();\n\n\t // HTTP Request Made (disabled)\n\t if (0 && !is_null($request = requestParser::getRequest()))\n\t {\n\t\t $request = implode(\"->\", $request);\n\t\t // Let's make it look nice\n\t\t $this->output[\"request\"] = array(\"request\" => $request,\n\t\t\t \"time\" => date(\"h:i:s A\", time()),\n\t\t\t \"date\" => date(\"m-d-Y\", time()));\n\t }\n\n\t // Add Token only if passed (This is just to keep track of the token used on the request)\n\t // CLIENT DOES NOT REALLY NEED THIS (DEBUG)\n\t if (!is_null($t = requestParser::getToken()))\n\t $this->output[\"token_passed\"] = $t;\n\n\t\t$this->output[\"status\"] = \"Hello World! \";\n\t $this->output[\"success\"] = false; //default false, so only upon a successful request is it set to true\n //$this->output[\"clientIP\"] = $this->getRealIpAddr(); // If you want it\n }", "title": "" }, { "docid": "6c361425cd5d4184c2c6962493e51d93", "score": "0.54698634", "text": "protected function setUp()\n {\n $this->label = Random::string();\n $this->type = VFORM_STRING;\n\n $this->object = new VF_Text($this->label, $this->type);\n }", "title": "" }, { "docid": "4f659181cc8c2fb6469c2f6f4b297ab0", "score": "0.5466866", "text": "private function buildType()\n {\n $type = isset($this->options['type']) ? $this->options['type'] : self::json;\n if ($type === self::json)\n $this->setHeader('Content-Type', 'application/json');\n else if ($type === self::form)\n $this->setHeader('Content-Type', 'application/x-www-form-urlencoded');\n }", "title": "" }, { "docid": "7272d718abae5aa1d3280aa3d5f5389e", "score": "0.54400855", "text": "public function __construct() {\n\t\t$this->_request = new Request();\n\t}", "title": "" }, { "docid": "08b74f97382573248e6331eedebefd1a", "score": "0.54394764", "text": "public function testConstructorStringData(): void\n {\n $headers = [\n 'Content-Type' => 'application/json',\n 'Authorization' => 'Bearer valid-token',\n ];\n $data = ['a' => 'b', 'c' => 'd'];\n $request = new Request('http://example.com', 'POST', $headers, json_encode($data));\n\n $this->assertSame('http://example.com', (string)$request->getUri());\n $this->assertStringContainsString($request->getMethod(), 'POST');\n $this->assertSame('application/json', $request->getHeaderLine('Content-Type'));\n $this->assertSame(json_encode($data), $request->getBody()->__toString());\n }", "title": "" }, { "docid": "0c2d776f93a14198278e4c914f417b20", "score": "0.5432382", "text": "protected function setUp()\n {\n $this->object = new Slevomat_Client_ResponseFactory();\n }", "title": "" }, { "docid": "98ba37fc1541f50ba942678b775bbf1c", "score": "0.543107", "text": "public function __construct(string|stdClass $rawResponse)\n {\n $this->raw = $rawResponse;\n\n if (property_exists($rawResponse, 'code')) {\n $this->code = $rawResponse->code;\n $this->data = $rawResponse->data;\n } else {\n $this->contents = $rawResponse;\n }\n }", "title": "" }, { "docid": "aad2c80d264e0efef5b1f0fd3bc64712", "score": "0.5412635", "text": "public function testConstructorStringData()\n {\n $headers = [\n 'Content-Type' => 'application/json',\n 'Authorization' => 'Bearer valid-token',\n ];\n $data = ['a' => 'b', 'c' => 'd'];\n $request = new Request('http://example.com', 'POST', $headers, json_encode($data));\n\n $this->assertEquals('http://example.com', (string)$request->getUri());\n $this->assertContains($request->getMethod(), 'POST');\n $this->assertEquals('application/json', $request->getHeaderLine('Content-Type'));\n $this->assertEquals(json_encode($data), $request->body());\n }", "title": "" }, { "docid": "37051d0304ba2ea1053f6f54305a21cd", "score": "0.54089993", "text": "protected function setUp() {\n $this->object = new Request('GeteBayDetails');\n }", "title": "" }, { "docid": "7ecd93bb8fc9c5de1943405f59bc43a0", "score": "0.53975934", "text": "function __construct() {\n\n $this->respond_code = 200;\n\n $this->respond_headers = array('Content-type: text/html');\n }", "title": "" }, { "docid": "32ee1679cb9414356a8d31849f3da523", "score": "0.53964764", "text": "public function __construct($request, $object)\n {\n\n $this->request = $request;\n \n $this->object = $object;\n\n }", "title": "" }, { "docid": "4bd26223e07f3b416c8ba05bfbb16013", "score": "0.5379536", "text": "public function __construct() {\r\n $this->_input = new PartnerAPIMessageGetConfiguration();\r\n $this->_output = new PartnerAPIMessageGetConfigurationResponse();\r\n }", "title": "" }, { "docid": "267a2460749b05999d4a6151bf458216", "score": "0.5378306", "text": "public function __construct(string $type)\n {\n $this->setType($type);\n }", "title": "" }, { "docid": "6beddebafa05728ac9917e47d4e08963", "score": "0.5376592", "text": "private function __construct(string $type)\n {\n $this->type = $type;\n }", "title": "" }, { "docid": "f86ddf9764de940ea760874f253c2875", "score": "0.5368645", "text": "private function __construct()\r\n {\r\n $this->body = null;\r\n $this->form = new \\SwaggerValidator\\Common\\SandBoxItem();\r\n $this->header = new \\SwaggerValidator\\Common\\SandBoxItem();\r\n $this->path = new \\SwaggerValidator\\Common\\SandBoxItem();\r\n $this->query = new \\SwaggerValidator\\Common\\SandBoxItem();\r\n }", "title": "" }, { "docid": "d93fae12e78a115f477dd7ac5c864942", "score": "0.5362838", "text": "function __construct($obj){\n parent::__construct($obj);\n $this->parseJSON($obj);\n }", "title": "" }, { "docid": "d93fae12e78a115f477dd7ac5c864942", "score": "0.5362838", "text": "function __construct($obj){\n parent::__construct($obj);\n $this->parseJSON($obj);\n }", "title": "" }, { "docid": "318057dc772042fc797ca46662c47f59", "score": "0.53536665", "text": "public function __construct($type) {\n }", "title": "" }, { "docid": "1302d2a252e0d10ccb4cbeb37d8d92fe", "score": "0.53535384", "text": "protected function setUp() {\n $this->object = new Request;\n }", "title": "" }, { "docid": "e9e09afa53a696252f1f944879f8a3fd", "score": "0.5327059", "text": "function __construct()\r\n {\r\n SGL::logMessage(null, PEAR_LOG_DEBUG);\r\n\r\n parent::__construct();\r\n\r\n $this->req = &SGL_Registry::singleton()->getRequest();\r\n\r\n $this->responseFormat = SGL_RESPONSEFORMAT_HTML;\r\n \r\n }", "title": "" }, { "docid": "ecd3422a1baef1ae667abaabf49bdaf7", "score": "0.532686", "text": "function __construct($raw, $requiredType) {\n\t\t\t$this->type = $requiredType;\n\n\t\t\t/* Resolve argument's data */\n\t\t\t$this->resolve($raw);\n\t\t}", "title": "" }, { "docid": "8ef0532a80b59407fe517cbe62cfd7dc", "score": "0.5325252", "text": "public function setUpFilled()\n {\n $this->setUpShared();\n\n $enums = $this->get_json_enums();\n $_POST = array_flip($enums);\n $_FILES = [\n 'image' => [\n 'name' => 'Name',\n 'type' => 'Type',\n 'tmp_name' => 'Tmp',\n 'error' => 'Error',\n 'size' => 'Size'\n ]\n ];\n\n $_GET = array_flip($enums);\n $_GET['controller'] = 'controller';\n $_GET['method'] = 'method';\n $_GET['param1'] = 'param1';\n $_GET['param2'] = 'param2';\n\n $_COOKIE = array_flip($enums);\n $_COOKIE['PHPSESSID'] = 'value';\n\n $_SERVER = $this->setup_server_superglobal();\n\n $this->class = new Request($this->configuration);\n }", "title": "" }, { "docid": "6562670abf138c71ee4b7af9d04d6a91", "score": "0.53244543", "text": "public function __construct($data, $type){\n $this->data = $data;\n // to change the global array \n switch ($type) {\n case 'GET':\n $this->type = INPUT_GET;\n $this->holder = $_GET;\n break;\n case 'POST':\n $this->type = INPUT_POST;\n $this->holder = $_POST;\n break;\n case 'COOKIE':\n $this->type = INPUT_COOKIE;\n $this->holder = $_COOKIE;\n break;\n case 'SERVER':\n $this->type = INPUT_SERVER;\n $this->holder = $_SERVER;\n break;\n case 'ENV':\n $this->type = INPUT_ENV;\n $this->holder = $_ENV;\n break;\n default:\n break;\n }\n $this->extractRules($data);\n }", "title": "" }, { "docid": "04e139002e5efc9a55858fa634c80706", "score": "0.53223825", "text": "public function __construct($raw) {\n parent::__construct($raw);\n\n // Map all response data into this object\n $this->outcome = $this->response['outcome'];\n }", "title": "" }, { "docid": "550ef5e43a25de62f93128567ea848e8", "score": "0.5299219", "text": "public function __construct() {\r\n $this->requestUri = $this->getRequestUri();\r\n $this->requestMethod = $this->getRequestMethod();\r\n $this->requestHeaders = $this->getRequestHeaders();\r\n $this->requestBody = $this->getRequestBody();\r\n $this->contentType = $this->getContentType();\r\n $this->getParams = $this->getGetParams();\r\n $this->postParams = $this->getPostParams();\r\n $this->cookieParams = $this->getCookieParams();\r\n }", "title": "" }, { "docid": "0c660a562e396cad850d5ab03a1287e1", "score": "0.5292014", "text": "public function __construct($request_content)\n {\n $this->request = json_decode($request_content);\n }", "title": "" }, { "docid": "571bfeddfe5a71020ac63c997193ed43", "score": "0.5285661", "text": "public function __construct($string, $type=null) {\n $this->string = $string;\n parent::__construct($this->parse($this->string, $type == self::STRIP_PARANTHESES ? true : false));\n }", "title": "" }, { "docid": "3b0fd5017ad64c3a734dc4ff6d9b8440", "score": "0.526717", "text": "public function __construct(){\n // print_r($e->getTrace());\n $this->_request_data = SmartestPersistentObject::get('request_data');\n }", "title": "" }, { "docid": "b0724460621953291d0735c779ec6c55", "score": "0.5266261", "text": "public function setObjectResponseFormat()\n { \n $this->addCommonConfig(Config::RESPONSE_FORMAT, ResultAbstract::RESPONSE_FORMAT_OBJECT);\n }", "title": "" }, { "docid": "44415956a894ad124c43134c2913ee20", "score": "0.5265132", "text": "public function __construct($type)\n {\n $this->parser = Parser::make($type);\n self::log(sprintf('App started with \"%s\" parser', $type));\n }", "title": "" }, { "docid": "9b244bef6036d531d058e80e1d425dda", "score": "0.5252838", "text": "public static function initByRequest(){\n\t\treturn new self(\n\t\t\twe_base_request::_(we_base_request::STRING, 'FieldsHidden'), we_base_request::_(we_base_request::STRING, 'FieldsHiddenCOV'), we_base_request::_(we_base_request::STRING, 'FieldsText'), we_base_request::_(we_base_request::STRING, 'FieldsMails'), we_base_request::_(we_base_request::STRING, 'EMailData'), we_base_request::_(we_base_request::STRING, 'LanguageData'), we_base_request::_(we_base_request::INT, 'FieldsDocuments', 0)\n\t\t);\n\t}", "title": "" }, { "docid": "c501ed5c718860e75589034f56896bf2", "score": "0.52498055", "text": "public function __construct($headers, $statusCode, $object ,$expectedType)\n {\n $this->headers = $headers;\n\n $this->statusCode = $statusCode;\n \n $this->object = $object;\n \n $this->isExpected = $expectedType;\n }", "title": "" }, { "docid": "5766545920b205bbe3efc22f11724e47", "score": "0.5248753", "text": "abstract public function getResponseObject();", "title": "" }, { "docid": "c3d01a2d236c16a1221fac8c6e6c6084", "score": "0.5248517", "text": "public function __construct($type)\n {\n $this->dataType = $type;\n }", "title": "" }, { "docid": "b8607d0727d3c5d4c96f6b5ef0694069", "score": "0.5242231", "text": "function __construct()\n\t\t{\n\t\t\t//Content Type\n\t\t\theader(\"Content-type: {$this->contentType}; charset={$this->pageCharset}\");\n\n\t\t\t//Members And Rooms File Creating if it's not exists\n\t\t\tif ( ! file_exists($this->membersFile) )\n\t\t\t\ttouch($this->membersFile);\n\t\t\tif ( ! file_exists($this->roomsFile) )\n\t\t\t\ttouch($this->roomsFile );\n\n\t\t\t//if process requests exists eq this->requested\n\t\t\tif ( $this->get('p') )\n\t\t\t{\n\t\t\t\t$this->requested = $this->get('p');\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$this->requested = false;\n\t\t\t\t$this->errors['bootstrap'] = $this->errorCodes[7];\n\t\t\t}\n\n\t\t\t//Bootstrapping Members\n\t\t\t$this->members = json_decode( file_get_contents( $this->membersFile ) );\n\n\t\t\t//Bootstrapping Rooms\n\t\t\t$this->rooms = json_decode( file_get_contents( $this->roomsFile ) );\n\t\t}", "title": "" }, { "docid": "6cfc5b39d0011c819fd7110dfdf29e15", "score": "0.5241055", "text": "public function createResponseStr(){\n $this->setResponseStr($this->buildJson(true, $this->getMessage(), $this->getResponseData(), false, false, false, false));\n }", "title": "" }, { "docid": "180483a7b4f789730bafb6458c1e3c2e", "score": "0.5240737", "text": "public function init()\n {\n // don't do that in the real world!\n\n // 完整的实现应该管理GET、POST和PUT数组,\n // 并提供一套统一的查询机制。\n $this->properties = $_REQUEST;\n $this->path = $_SERVER['PATH_INFO'];\n $this->path = (empty($this->path)) ? \"/\" : $this->path;\n }", "title": "" }, { "docid": "f1e6c22b03af187406fb8c743d28fff6", "score": "0.5239209", "text": "public function __construct($response) {\n // Loading the class-name, setting it in the REST-class, so we can check if it holds the method being called\n $this->className = get_class($this);\n\n // Calling RESTs constructor\n parent::__construct($response);\n }", "title": "" }, { "docid": "42236664f05bc85fb150d661345b89f0", "score": "0.5226425", "text": "public function initialize()\n {\n $this->data = new stdClass();\n }", "title": "" }, { "docid": "859685757daf221fdb1f925e7d202eaf", "score": "0.5221788", "text": "public function __construct($type) {\r\n\t\t$this->type = $type;\r\n\t}", "title": "" }, { "docid": "df6969b43263f3f97eee45b4cea27938", "score": "0.5216654", "text": "public function __construct($type, $data) {\n $this->type = $type;\n $this->data = $data;\n }", "title": "" }, { "docid": "1059794cc9021a3a6756789bc1ec6502", "score": "0.52062887", "text": "protected function setUp()\n\t{\n\t\t$this->object = new Request;\n\t}", "title": "" }, { "docid": "cd1a2f9c7d533dd17d2575da91d13411", "score": "0.519853", "text": "public function initialize()\n {\n $this->data = new stdClass();\n $this->data->type = null;\n $this->data->createdAt = null;\n $this->data->descriotion = null;\n }", "title": "" }, { "docid": "61e79c9ed506531e25e3e0a4e1277550", "score": "0.5195771", "text": "public function init() {\n\t\t$format = $this->_getParam('format');\n\t\tif(empty($format)) {\n\t\t\t$format = 'json';\n\t\t}\n\t\t$this->_setParam('format', $format);\n\t\t\n\t\t$this->companyId = $this->_getParam('CompanyID');\n\t\n\t\t$this->config = Esquire_Config_Factory::getApplicationConfig();\n\t\t$this->logger = Esquire_Log_Factory::getLogger($this->config, get_class($this));\n\t\n\t\t$contextSwitcher = $this->_helper->getHelper('contextSwitch');\n\t\t$contextSwitcher->addActionContext('index', 'json');\n\t\t$contextSwitcher->addActionContext('get', 'json');\n\t\t$contextSwitcher->addActionContext('put', 'json');\n\t\t$contextSwitcher->addActionContext('post', 'json');\n\t\t$contextSwitcher->addActionContext('delete', 'json');\n\t\t$contextSwitcher->initContext();\n\t}", "title": "" }, { "docid": "55c43a729436172cf73b322acdebb062", "score": "0.51914626", "text": "protected function _construct() {\n $this->_init('connector/content_types', 'type_id');\n }", "title": "" }, { "docid": "56ef2a0ac8600416d4d13dba13da7ccf", "score": "0.5176631", "text": "public static function init() {\n\t\t// register post type\n\t\tadd_filter( 'tribe_rest_event_data', [ get_class(), 'register_fields' ] );\n\n\t\t// add ACF relevent fields for series pages\n\t\tadd_filter( 'rest_prepare_page', function($response) {\n\t\t\t$response->data['acf'] = get_fields($response_data['id']);\n\t\t\treturn $response;\n\t\t});\n\t}", "title": "" }, { "docid": "cede2693f919ed65d599c83c5f7290a8", "score": "0.5175943", "text": "private function init()\n {\n $this->responseIsValid = false;\n $this->message = 'An error occured when communicating with Tesco';\n $this->tokenCode = null;\n if (property_exists($this->response, 'TransactionResponseCode') &&\n $this->response->TransactionResponseCode == self::RESPONSE_CODE_SUCCESS) {\n if (property_exists($this->response, 'TokenDetailsList') &&\n is_array($this->response->TokenDetailsList) &&\n count($this->response->TokenDetailsList) == 1) {\n $this->tokenDetails = reset($this->response->TokenDetailsList);\n $this->message = $this->getTokenAttribute('TokenStatus');\n // Check the expiry date.\n $expiryDate = $this->getTokenAttribute('TokenExpiryDate');\n if ($expiryDate) {\n $expiryDateTime = DateTime::parse($expiryDate, false, 'd/m/Y H:i:s');\n if ($expiryDateTime->getTimestamp() < time()) {\n $this->message = 'Voucher expired at '.$expiryDateTime->format('Y-m-d H:i:s');\n } else {\n // We're okay - it expires in the future.\n $this->responseIsValid = true;\n }\n } else {\n $this->message = 'Expiry date is missing from voucher';\n }\n } else {\n $this->message = 'Invalid response from Tesco server';\n }\n } else {\n $this->message = 'Request was invalid';\n }\n $this->tokenCode = $this->getTokenAttribute('TokenCode');\n }", "title": "" }, { "docid": "7aaf6381e06afdf9d3d8b9753cb2997b", "score": "0.516864", "text": "private function __init__()\n {\n try{\n $this->initServices();\n\n if(ValidateInfo::controllerValidate($this->data,$this->compropagoService->getProviders())){\n $this->createOrder();\n }else{\n throw new \\Exception(\"Error de operacion.\");\n }\n }catch(\\Exception $e){\n\n echo \"{$e->getMessage()}\";\n $this->response['msg'] = $e->getMessage();\n }\n\n header(\"Content-Type: application/json\");\n echo json_encode($this->response);\n }", "title": "" }, { "docid": "5f9938252661aa889a425d1dc35607fd", "score": "0.5164452", "text": "public function init()\n {\n $this->_helper->layout->disableLayout();\n $this->_helper->viewRenderer->setNoRender(true);\n $this->getResponse()->setHeader('Content-Type', 'application/json');\n $this->_adapterEtfFund = new Application_Model_DBTable_EtfFund();\n }", "title": "" }, { "docid": "ca26d43baa3cfc5ae8b52acc08d8a5ee", "score": "0.516439", "text": "public function __construct() \n\t\t{\n\t\t\t\t$this->_ENDPOINTS['emotion']['text'] = '/text/TextGetEmotion';\n\t\t\t\t$this->_ENDPOINTS['emotion']['url'] = '/url/URLGetEmotion';\n\t\t\t\t$this->_ENDPOINTS['emotion']['html'] = '/html/HTMLGetEmotion';\n\t\t\t\n\t\t\t\t$this->_ENDPOINTS['sentiment']['url'] = '/url/URLGetTextSentiment';\n\t\t\t\t$this->_ENDPOINTS['sentiment']['text'] = '/text/TextGetTextSentiment';\n\t\t\t\t$this->_ENDPOINTS['sentiment']['html'] = '/html/HTMLGetTextSentiment';\n\n\t\t\t\t$this->_ENDPOINTS['sentiment_targeted']['url'] = '/url/URLGetTargetedSentiment';\n\t\t\t\t$this->_ENDPOINTS['sentiment_targeted']['text'] = '/text/TextGetTargetedSentiment';\n\t\t\t\t$this->_ENDPOINTS['sentiment_targeted']['html'] = '/html/HTMLGetTargetedSentiment';\n\n\t\t\t\t$this->_ENDPOINTS['author']['url'] = '/url/URLGetAuthor';\n\t\t\t\t$this->_ENDPOINTS['author']['html'] = '/html/HTMLGetAuthor';\n\n\t\t\t\t$this->_ENDPOINTS['keywords']['url'] = '/url/URLGetRankedKeywords';\n\t\t\t\t$this->_ENDPOINTS['keywords']['text'] = '/text/TextGetRankedKeywords';\n\t\t\t\t$this->_ENDPOINTS['keywords']['html'] = '/html/HTMLGetRankedKeywords';\n\n\t\t\t\t$this->_ENDPOINTS['concepts']['url'] = '/url/URLGetRankedConcepts';\n\t\t\t\t$this->_ENDPOINTS['concepts']['text'] = '/text/TextGetRankedConcepts';\n\t\t\t\t$this->_ENDPOINTS['concepts']['html'] = '/html/HTMLGetRankedConcepts';\n\n\t\t\t\t$this->_ENDPOINTS['entities']['url'] = '/url/URLGetRankedNamedEntities';\n\t\t\t\t$this->_ENDPOINTS['entities']['text'] = '/text/TextGetRankedNamedEntities';\n\t\t\t\t$this->_ENDPOINTS['entities']['html'] = '/html/HTMLGetRankedNamedEntities';\n\n\t\t\t\t$this->_ENDPOINTS['category']['url'] = '/url/URLGetCategory';\n\t\t\t\t$this->_ENDPOINTS['category']['text'] = '/text/TextGetCategory';\n\t\t\t\t$this->_ENDPOINTS['category']['html'] = '/html/HTMLGetCategory';\n\n\t\t\t\t$this->_ENDPOINTS['relations']['url'] = '/url/URLGetRelations';\n\t\t\t\t$this->_ENDPOINTS['relations']['text'] = '/text/TextGetRelations';\n\t\t\t\t$this->_ENDPOINTS['relations']['html'] = '/html/HTMLGetRelations';\n\n\t\t\t\t$this->_ENDPOINTS['language']['url'] = '/url/URLGetLanguage';\n\t\t\t\t$this->_ENDPOINTS['language']['text'] = '/text/TextGetLanguage';\n\t\t\t\t$this->_ENDPOINTS['language']['html'] = '/html/HTMLGetLanguage';\n\n\t\t\t\t$this->_ENDPOINTS['text']['url'] = '/url/URLGetText';\n\t\t\t\t$this->_ENDPOINTS['text']['html'] = '/html/HTMLGetText';\n\n\t\t\t\t$this->_ENDPOINTS['text_raw']['url'] = '/url/URLGetRawText';\n\t\t\t\t$this->_ENDPOINTS['text_raw']['html'] = '/html/HTMLGetRawText';\n\n\t\t\t\t$this->_ENDPOINTS['title']['url'] = '/url/URLGetTitle';\n\t\t\t\t$this->_ENDPOINTS['title']['html'] = '/html/HTMLGetTitle';\n\n\t\t\t\t$this->_ENDPOINTS['feeds']['url'] = '/url/URLGetFeedLinks';\n\t\t\t\t$this->_ENDPOINTS['feeds']['html'] = '/html/HTMLGetFeedLinks';\n\n\t\t\t\t$this->_ENDPOINTS['microformats']['url'] = '/url/URLGetMicroformatData';\n\t\t\t\t$this->_ENDPOINTS['microformats']['html'] = '/html/HTMLGetMicroformatData';\n\n\t\t\t\t$this->_ENDPOINTS['combined']['url'] = '/url/URLGetCombinedData';\n\t\t\t\t$this->_ENDPOINTS['combined']['text'] = '/text/TextGetCombinedData';\n\n\t\t\t\t$this->_ENDPOINTS['image']['url'] = '/url/URLGetImage';\n\t\t\t\t$this->_ENDPOINTS['image_keywords']['url'] = '/url/URLGetRankedImageKeywords';\n\t\t\t\t$this->_ENDPOINTS['image_keywords']['image'] = '/image/ImageGetRankedImageKeywords';\n\n\t\t\t\t$this->_ENDPOINTS['taxonomy']['url'] = '/url/URLGetRankedTaxonomy';\n\t\t\t\t$this->_ENDPOINTS['taxonomy']['html'] = '/html/HTMLGetRankedTaxonomy';\n\t\t\t\t$this->_ENDPOINTS['taxonomy']['text'] = '/text/TextGetRankedTaxonomy';\n\t\t\t\n\t\t}", "title": "" }, { "docid": "6b749848b778b8b23ac749fcd64c6f33", "score": "0.5162009", "text": "public function __construct($response)\n {\n $this->response = $response;\n }", "title": "" }, { "docid": "0434213fb8e1c713ea28fb8a71634a03", "score": "0.5160087", "text": "public function __construct($string) {\n $this->string = $string;\n $this->setupTokens();\n $this->parse();\n }", "title": "" }, { "docid": "5dadbc0da92f2734cb156e0d14bc3a76", "score": "0.5158406", "text": "protected function setUp()\n {\n $this->request = new Request();\n $this->response = new Response();\n\n $this->request->load();\n $this->response->load();\n }", "title": "" }, { "docid": "5dadbc0da92f2734cb156e0d14bc3a76", "score": "0.5158406", "text": "protected function setUp()\n {\n $this->request = new Request();\n $this->response = new Response();\n\n $this->request->load();\n $this->response->load();\n }", "title": "" }, { "docid": "5dadbc0da92f2734cb156e0d14bc3a76", "score": "0.5158406", "text": "protected function setUp()\n {\n $this->request = new Request();\n $this->response = new Response();\n\n $this->request->load();\n $this->response->load();\n }", "title": "" }, { "docid": "5dadbc0da92f2734cb156e0d14bc3a76", "score": "0.5158406", "text": "protected function setUp()\n {\n $this->request = new Request();\n $this->response = new Response();\n\n $this->request->load();\n $this->response->load();\n }", "title": "" }, { "docid": "c4d3379e14536d4aec5c420fa0c7e8fe", "score": "0.5154206", "text": "public function __construct($response)\n\t{\n\t\t$this->response = $response;\n\t}", "title": "" }, { "docid": "a33941957829f71395806300909a1bb2", "score": "0.5149358", "text": "public function createFromRequest();", "title": "" }, { "docid": "894f35dda1206da128cf90cf9af38e05", "score": "0.5148426", "text": "public function initializeObject()\n {\n $this->setNameAndPackageKey();\n }", "title": "" }, { "docid": "475f4b0f72fa52a1147ad300ef15681a", "score": "0.5144834", "text": "public function __construct($string)\n {\n $this->string = $string;\n }", "title": "" }, { "docid": "475f4b0f72fa52a1147ad300ef15681a", "score": "0.5144834", "text": "public function __construct($string)\n {\n $this->string = $string;\n }", "title": "" }, { "docid": "475f4b0f72fa52a1147ad300ef15681a", "score": "0.5144834", "text": "public function __construct($string)\n {\n $this->string = $string;\n }", "title": "" }, { "docid": "a6632195b17751530ca994dfe0beb8f5", "score": "0.5138337", "text": "public function __construct() {\n $this->verb = $_SERVER['REQUEST_METHOD'];\n // URL path split into an array of pieces\n $this->url_elements = explode('/', $_SERVER['PATH_INFO']); \n // \n $this->parseIncomingParams();\n // initialise json as default format\n $this->format = 'json';\n // HOW CAN YOU HAVE A FORMAT ON YOUR PARAMETERS? AREN'T THEY JUST STRINGS?\n if(isset($this->parameters['format'])) {\n $this->format = $this->parameters['format'];\n }\n return true;\n }", "title": "" }, { "docid": "bd6965d3687e4aac4bbae9a80c32a255", "score": "0.5133595", "text": "protected function setUp()\n {\n $baseRequest = BaseRequest::create($this->uri);\n $request = Request::createFromBase($baseRequest);\n $config = new ArrayConfig();\n\n $this->parser = new RequestParser($request, $config);\n }", "title": "" }, { "docid": "f2864269caeff6a28ae7196677bc326a", "score": "0.5131712", "text": "public function __construct($data, $type)\n {\n $this->data = $data;\n $this->type = $type;\n }", "title": "" }, { "docid": "aeb1a2e6e078135fac13c86c10d1f893", "score": "0.51308125", "text": "protected function init()\n {\n \\register_post_type($this->slug, $this->args);\n }", "title": "" }, { "docid": "f432cda5b1c605c1246408549452ab13", "score": "0.5113088", "text": "private function _initRequest() {\n $order = $this->requestOrder();\n \n for ( $i=0; $i < strlen($order); $i++ ) {\n switch( $order[$i] ) {\n case 'G':\n $this->_mergeRequest( $this->_get );\n break;\n case 'P':\n $this->_mergeRequest( $this->_post );\n break;\n case 'C':\n $this->_mergeRequest( $this->_cookies );\n break;\n }\n }\n \n $this->_request = new Variables( $this->_requestArray );\n }", "title": "" }, { "docid": "ff6c81ba76e32f6593ba5422888d0788", "score": "0.5112141", "text": "public function __construct(){\n\t\tfor($i=0;$i<func_num_args();$i++){\t//Loop through all of the arguments provided to the instruction (\"RequestObject($arg1,$arg2,...)\").\n\t\t\t$arg = func_get_arg($i);\n\t\t\tif(is_object($arg)){ \t\t\t//If this argument is of class-type object (basically anything not a primative data type). \n\t\t\t\t$class = get_class($arg); \t//Get the actual class of the argument\n\t\t\t\tif($class == 'PDO'){\t\t//Hey look! It's our SQL object\n\t\t\t\t\t$this->_sqlCon = $arg; \t//We should save this. \n\t\t\t\t}\n\t\t\t\telseif($class == 'User'){\t//If it's our User class\n\t\t\t\t\t$this->_user = $arg;\n\t\t\t\t}\n\t\t\t}\n\t\t} \n\t\tif(REQUEST_DATA_ARRAY == 0){ \t\t//Determine whether we want request data from $_REQUEST or $_POST\n\t\t\t$this->_req = $_REQUEST;\n\t\t}\n\t\telse{\n\t\t\t$this->_req = $_POST;\n\t\t}\n\t\t\n\t\tif($this->_user == null){\n\t\t\t$this->_user = new User();\n\t\t}\n\t\t// Uncomment this initialize line if we need user information from session, otherwise, leave this commented out.\n\t\t// That is, if we need to make sure the user is logged in and/or need to get UID/email/username/whatnot for the requesting user.\n\t\t$this->_user->initialize();\n\t}", "title": "" }, { "docid": "2ef2fb37777f1ebc89bafc00051140c7", "score": "0.5109062", "text": "public function __construct(\n string $type, string $url, \\stdClass $auth, $context=NULL )\n {\n parent::__construct( $type, $url, $auth, $context );\n \n $this->url = $url;\n $this->auth = $auth;\n $this->message = '';\n $this->success = '';\n //$this->createdAssetId = '';\n $this->reply = new \\stdClass();\n $this->commands = array();\n // if not provided, defaulted to true\n $this->auth_in_content = $auth->authInContent ?? true;\n\n try\n {\n if( $this->auth_in_content === false )\n {\n $json_str = json_encode( $auth );\n $json_str = trim( $json_str, \"{}\" );\n $json_str = str_replace( '\"', '', $json_str );\n $json_str = str_replace( ':', '=', $json_str );\n $json_str = str_replace( ',', '&', $json_str );\n $auth_str = str_replace( \" \", \"%20\", $json_str );\n $this->auth = '?' . $auth_str;\n }\n else\n {\n unset( $auth->authInContent );\n $this->auth = $auth;\n }\n }\n catch( \\Exception $e )\n {\n throw new e\\ServerException( S_SPAN . $e->getMessage() . E_SPAN );\n }\n }", "title": "" }, { "docid": "28d0be138de52c5e08237f0e83a3c891", "score": "0.51038915", "text": "public function prepareRequest()\n {\n $this->http = new Client([\n 'headers' => [\n 'Content-Type' => 'application/json',\n 'Accept' => 'application/json'\n ]\n ]);\n }", "title": "" }, { "docid": "80ec180f852aa199ce1347ce96c7a3e3", "score": "0.5095402", "text": "public function __construct($input)\n {\n //\n\t$this->m_obj = $input;\n\tLog::info('init_obj' . json_encode($input));\n }", "title": "" }, { "docid": "a697498be646523e2cdd1aa841fe46fc", "score": "0.50927156", "text": "function __construct($data)\n {\n $this->type = $data[\"type\"];\n $this->name = $data[\"name\"];\n $this->description = $data[\"description\"];\n $this->templateId = $data[\"templateId\"];\n $this->templateName = $data[\"templateName\"];\n $this->version = $data[\"version\"];\n $this->serviceOptions = array();\n $this->parameters = array();\n $this->securityDomains = array();\n $this->requestTimeLimit = isset($data[\"requestTimeLimit\"]) ? $data[\"requestTimeLimit\"] : -1;\n $this->destination = isset($data[\"destination\"]) ? $data[\"destination\"] : \"\";\n $this->requestName = isset($data[\"requestName\"]) ? $data[\"requestName\"] : '';\n\n foreach ($data[\"parameters\"] as $parameter) {\n array_push($this->parameters, new ServiceParameter($parameter[\"parameter\"]));\n }\n\n foreach ($data[\"securityDomains\"] as $securityDomain) {\n array_push($this->securityDomains, new SecurityDomain($securityDomain));\n }\n }", "title": "" }, { "docid": "9ea343534590c42902168747b9138f45", "score": "0.50906485", "text": "public function __construct(\\Bonder\\Response $response) {\n $this->response = $response;\n }", "title": "" }, { "docid": "8d3a0a73e9aae12305fc79073ee8d511", "score": "0.5084046", "text": "protected function setUp()\n\t{\n\t\t$route = (object) array('params' => array('controller' => 'test', 'action' => 'index', 'fairy_param' => 'Trixie'));\n\t\t$this->object = new Request($route, 'GET', \n\t\t\tarray('fairy_post' => 'Trixie', 'xss' => 'a<div></div>'), \n\t\t\tarray('fairy_get' => 'Trixie', 'xss' => 'a<div></div>'), \n\t\t\tarray('fairy_server' => 'Trixie')\n\t\t);\n\t}", "title": "" }, { "docid": "9936bf1d352bcb79bbf3ff26e7faa6cd", "score": "0.5079563", "text": "public function runBuildRequest()\n {\n try {\n $this->request = new Request();\n $this->request->process();\n http_response_code($this->request->response->code);\n print_r(json_encode($this->request->response));\n } catch (Exception $e) {\n $response = new Response();\n $response->body = $e->getMessage();\n $response->code = $e->getCode();\n print_r(json_encode($response));\n }\n }", "title": "" }, { "docid": "123026d5b688895141dccb9b025cf3ab", "score": "0.5077748", "text": "public function __construct($type, $data)\n {\n $this->identifier\t= $data['id'];\n $this->name \t\t= $data['name'];\n $this->description \t= $data['description'];\n $this->usefors \t\t= isset($data['usefors']) ? $data['usefors'] : null;\n\n switch ($type) {\n case self::TAXON:\n $this->refId = $data['refId'];\n break;\n case self::TAXONOMY:\n $this->source = $data['source'];\n break;\n default:\n throw new IntraLibraryException('Invalid Taxonomy Object type');\n }\n\n $this->type \t\t= $type;\n }", "title": "" }, { "docid": "c59bc77f307593d8bf595756de770b28", "score": "0.5075276", "text": "public function parseResponseStringToObject()\n {\n $transporter = TransporterFactory::build();\n\n return $transporter->parseResponseStringToObject($this->response);\n }", "title": "" }, { "docid": "3658dab199d1fe7bae899c9957b176b2", "score": "0.50744617", "text": "private function fillObj($obj) {\n\t\t\n\t\t$obj->publisher = $_POST['publisher'];\n\t\t\n\t\tif($_POST['languageBox']) $obj->language = $_POST['language'];\n\t\tif($_POST['categoryBox']) $obj->category = $_POST['category'];\n\t\t\n\t\t$obj->locality = $_POST['locality'];\n\t\t$obj->type = 'myEuroCINPublication';\n\t\t$obj->end \t= $_POST['date'];\n\n\t\t$obj->title = $_POST['title'];\n\t\t$obj->text \t= $_POST['text'];\n\t}", "title": "" }, { "docid": "298ccf2ece95f3748d83cd31e3773b40", "score": "0.5074422", "text": "private function init()\n {\n $this->daemon = new LBRY_Daemon();\n $this->speech = new LBRY_Speech();\n\n // Admin request\n if ( is_admin() ) {\n $this->admin = new LBRY_Admin();\n $this->notice = new LBRY_Admin_Notice();\n $this->network = new LBRY_Network();\n }\n }", "title": "" }, { "docid": "abb61d6a578f51b52b9f65a40fd5c89d", "score": "0.50708663", "text": "protected function prepareRequest() {\n\t\t$cacheKey = $this->get__cacheKey();\n\t\t$cacheLocation = $this->get__cacheLocation();\n\t\t$supplierType = $this->get__supplierType();\n\t\tif ( isset($cacheKey,$cacheLocation) ) {\n\t\t\t$this->xmlRequest->cacheKey = $cacheKey;\n\t\t\t$this->xmlRequest->cacheLocation = $cacheLocation;\n\t\t\tif ( isset($supplierType) ) {\n\t\t\t\t$this->xmlRequest->supplierType = $supplierType;\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\t\t// not working with a cached result, so just prepare the request per usual\n\t\tif ( isset($this->searchMethod) ) {\n\t\t\t$searchMethodProperties = $this->searchMethod->renderPreparedArray();\n\t\t\tforeach ( $searchMethodProperties as $tag => $value ) {\n\t\t\t\t$this->xmlRequest->addChild($tag,(string) $value);\n\t\t\t}\n\t\t}\n\t\tforeach ( self::$propertyMap as $property => $type ) {\n\t\t\tif ( !isset($this->$property) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tswitch ( $type ) {\n\t\t\t\tcase 'DateTime':\n\t\t\t\t\t$this->xmlRequest->$property = $this->$property->format('m/d/Y');\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'EANRoomGroup':\n\t\t\t\t\tXMLUtils::appendSXE($this->xmlRequest, $this->$property->xml);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'int':\n\t\t\t\tcase 'float':\n\t\t\t\tcase 'string':\n\t\t\t\t\tif ( method_exists($this,'get__'.$property) ) {\n\t\t\t\t\t\t$this->xmlRequest->$property = $this->{'get__'.$property}();\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$this->xmlRequest->$property = (string) $this->$property;\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'boolean':\n\t\t\t\t\t$this->xmlRequest->$property = $this->$property?'true':'false';\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "1e3d5974266f32fa85565577c8d49c0c", "score": "0.50686926", "text": "public function __construct($type, $content)\n {\n $this->tag = $type;\n $this->content = $content;\n $content = preg_split('/\\s+/u', $content);\n\n // any output is considered a type\n $this->type = array_shift($content);\n\n $this->description = implode(' ', $content);\n }", "title": "" }, { "docid": "a5a1eeca31080b7d4eae8cb020061052", "score": "0.5068413", "text": "public function __construct($type,$data)\n {\n $this->type = $type;\n $this->data = $data;\n }", "title": "" } ]
a15b2aa35f0a487efa443acd8ff709b3
Operation listZonesAsyncWithHttpInfo List available zones
[ { "docid": "795279c949a443985d83505d95e7d5bb", "score": "0.80745476", "text": "public function listZonesAsyncWithHttpInfo()\n {\n $request = new Request('GET', 'zone');\n\n return $this->client->sendAsync($request)->then(function (UpcloudApiResponse $response) {\n return $response->toArray(ZoneListResponse::class);\n });\n }", "title": "" } ]
[ { "docid": "51bfaee27579e2243170a359d1534d67", "score": "0.77205247", "text": "public function listZonesWithHttpInfo(): array\n {\n $request = new Request('GET', 'zone');\n $response = $this->client->send($request);\n\n return $response->toArray(ZoneListResponse::class);\n }", "title": "" }, { "docid": "019407d44baa68753e09975208cdd0f1", "score": "0.7513784", "text": "public function listZonesAsync()\n {\n return $this->listZonesAsyncWithHttpInfo()->then(function ($response) {\n return $response[0];\n });\n }", "title": "" }, { "docid": "b6a00214ba630345dafc13f27083f7f4", "score": "0.71264887", "text": "public function listZones()\n {\n list($response) = $this->listZonesWithHttpInfo();\n return $response;\n }", "title": "" }, { "docid": "653f6322590d2d1f5b83c44687911c4a", "score": "0.684371", "text": "public function getZonesList()\n {\n return $this->getFromAPI('subscriptions/{subscription}/resourceGroups/{group}/providers/Microsoft.Network/dnsZones',\n [], '2015-05-04-preview');\n }", "title": "" }, { "docid": "d8a48f314183989ecc6be50c9a8464f3", "score": "0.6539653", "text": "function listzones() {\n\t\treturn $this->xmlapi_query('listzones');\n\t}", "title": "" }, { "docid": "48101e7385d41a35f0b2ca0bef56b1ab", "score": "0.6283266", "text": "public function listTimeZones() {\n return $this->run('listTimeZones', array());\n }", "title": "" }, { "docid": "d82992979afbfa868e441dd045093fa7", "score": "0.5776609", "text": "public function getZones()\n {\n return $this->zones;\n }", "title": "" }, { "docid": "2e6624916e2a3c7b0494a7a3613b1415", "score": "0.5706735", "text": "public function setZones($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::STRING);\n $this->zones = $arr;\n\n return $this;\n }", "title": "" }, { "docid": "6acea085dfa94f94c6b476fb796a03f7", "score": "0.5670044", "text": "function getZones()\r\n\t{\r\n\t\t$input = JFactory::getApplication()->input;\r\n\t\tCitruscart::load( 'CitruscartSelect', 'library.select' );\r\n\t\t$html = '';\r\n\t\t$text = '';\r\n\r\n\t\t$country_id =$input->getInt('country_id');\r\n\t\t$prefix = $input->getString('prefix');\r\n\t\t$html = CitruscartSelect::zone( '', $prefix.'zone_id', $country_id );\r\n\r\n\t\t$response = array();\r\n\t\t$response['msg'] = $html;\r\n\t\t$response['error'] = '';\r\n\r\n\t\t// encode and echo (need to echo to send back to browser)\r\n\t\techo ( json_encode($response) );\r\n\r\n\t\treturn;\r\n\t}", "title": "" }, { "docid": "bc4c2e1a0e6e647a9740156730defcd5", "score": "0.5488251", "text": "public function getAdrZones() {\n\n\t\tself::$logger->debug ( __CLASS__ . '-' . __METHOD__ . ' begin' );\n\n\t\t$list = array ();\n\n\t\t$query = AdrUsersDB::getAdrZones($order = 'ASC');\n\n\t\t$connectionManager = ConnectionManager::getInstance ();\n\n\t\t$rs = $connectionManager->select ( $query );\n\n\t\tif (is_array($rs) && count($rs) > 0) {\n\n\t\t\tforeach($rs as $element) {\n\n\t\t\t\t$obj = new AdrZone();\n\n\t\t\t\t$obj->setId($element['id']);\n\t\t\t\t$obj->setName($element['name']);\n\t\t\t\t//Diego Saez\n\t\t\t\t$obj->setLocation($element['locationid']);\n\t\t\t\t$obj->setCoordinates($element['coordinates']);\n\n\t\t\t\t$list [] = $obj;\n\n\t\t\t}\n\t\t}\n\n\t\tself::$logger->debug ( __CLASS__ . '-' . __METHOD__ . ' end' );\n\n\t\treturn $list;\n\n\t}", "title": "" }, { "docid": "524a8029b6826dda639cf9db83c26ca0", "score": "0.5451801", "text": "public function describeCollationTimeZones($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->describeCollationTimeZonesWithOptions($request, $runtime);\n }", "title": "" }, { "docid": "a452a1ad66aa529f88c4bf32c797b770", "score": "0.54160213", "text": "public function testListTimezones()\n {\n $timezones = $this->api->listTimezones()->getTimezones()->getTimezone();\n $zones = [\"Africa\", \"America\", \"Antarctica\", \"Arctic\", \"Asia\", \"Atlantic\", \"Australia\", \"Europe\", \"Indian\", \"Pacific\", \"UTC\"];\n $result = array_reduce($timezones, function ($acc, $timezone) use ($zones) {\n $zone = explode(\"/\", $timezone)[0];\n return $acc && in_array($zone, $zones);\n }, true);\n $this->assertTrue($result);\n }", "title": "" }, { "docid": "24215fd66640e1f3c6f7225fa6a0f06b", "score": "0.5380309", "text": "public function getSupportedTimeZones();", "title": "" }, { "docid": "50da5d088b663000bdaa2fffc239921e", "score": "0.525667", "text": "public function listTimeZone(array $options = [])\n {\n $options = $this->validateListParams($options);\n\n return $this->execute(\"list-time-zone\", $options);\n }", "title": "" }, { "docid": "eb289f608cbc8d92d46c95c8c4c78aa1", "score": "0.5249343", "text": "static function getAvailableZones($config)\n {\n $ReverseZones = $ForwardZones = $zones = array();\n $runtime_cache = session::get(\"runtime_cache\");\n if(!isset($runtime_cache['DNS']['getAvailableZones'])){\n\n $ret = array();\n $ldap = $config->get_ldap_link();\n $tmp = get_sub_list(\"(&(objectClass=dNSZone)(sOARecord=*))\",\"\",get_ou(\"servgeneric\", \"serverRDN\"),\n $config->current['BASE'],array(\"zoneName\"),GL_NO_ACL_CHECK | GL_SUBSEARCH);\n\n foreach($tmp as $at){\n if(preg_match(\"/\\.in\\-addr\\.arpa\\./\",$at['zoneName'][0])){\n $ReverseZones[$at['dn']] = $at;\n }else{\n $ForwardZones[$at['dn']] = $at;\n }\n }\n\n foreach($ForwardZones as $dn => $obj){\n\n /* try to find reverse\n */ \n foreach($ReverseZones as $Rdn => $Robj ){\n if(preg_match(\"/\".$dn.\"/\",$Rdn)){\n $zones[strtoupper($ldap->getCn($dn)).\"/\".$Robj['zoneName'][0]] = \n strtoupper($ldap->getCn($dn)).\"/\".$obj['zoneName'][0];\n }\n } \n }\n $runtime_cache['DNS']['getAvailableZones'] = $zones;\n session::set(\"runtime_cache\",$runtime_cache);\n }\n return($runtime_cache['DNS']['getAvailableZones']);\n }", "title": "" }, { "docid": "36267312f54e1af4b361730f2b5fb619", "score": "0.5223209", "text": "public function GetServerTimeZones($request)\n {\n $this->initializeSoapClient();\n $response = $this->soap->{__FUNCTION__}($request);\n\n return $this->processResponse($response);\n }", "title": "" }, { "docid": "95b7ede2121030233d436119c098f833", "score": "0.51569253", "text": "function getZones() {\n\n $sql = \"select ID,Nome from dbo.ShooperCodiceZone;\";\n $rs = $this->db->adoExecQuery($sql);\n return $rs;\n }", "title": "" }, { "docid": "32342a8b583f3d6cb817172dd9e73cb5", "score": "0.5150919", "text": "public function actionZones()\n {\n if(!User::checkAccess('setup_action')) \n {\n Yii::$app->session->setFlash('warning', \"Your Don't have permission to access this!\");\n return $this->redirect(['admin/index'])->send();\n }\n $zones = Zones::get_all_zones();\n echo $this->render('//admin/setup/zones/index', array('zones' => $zones));\n }", "title": "" }, { "docid": "f8b83079c14f93486e5f129f79d22ab8", "score": "0.51436555", "text": "public function zonesInstance()\n {\n if (!isset($this->ec2Zone)) {\n $this->ec2Zone = new Zend_Service_Amazon_Ec2_AvailabilityZones($this->accessKey,$this->accessSecret,$this->region);\n }\n $this->adapterResult = $this->ec2Zone->describe();\n\n $zones = [];\n foreach ($this->adapterResult as $zone) {\n if (strtolower($zone['zoneState']) === 'available') {\n $zones[] = [\n Zend_Cloud_Infrastructure_Instance::INSTANCE_ZONE => $zone['zoneName'],\n ];\n }\n }\n return $zones;\n }", "title": "" }, { "docid": "5cdefb3192d4ba2877735316cee207da", "score": "0.5110876", "text": "public function getTimeZoneList($params, $context) {\n\t\t// Validate the RPC caller context.\n\t\t$this->validateMethodContext($context, [\n\t\t\t\"role\" => OMV_ROLE_ADMINISTRATOR\n\t\t]);\n\t\t// According to http://php.net/manual/en/timezones.others.php\n\t\t// some of the time zones that the Debian installer supports are\n\t\t// deprectated. To prevent errors we support them to (ALL_WITH_BC).\n\t\t$timezoneIdentifiers = \\DateTimeZone::listIdentifiers(\n\t\t\t\\DateTimeZone::ALL_WITH_BC);\n\t\tsort($timezoneIdentifiers, SORT_NATURAL);\n\t\treturn $timezoneIdentifiers;\n\t}", "title": "" }, { "docid": "526dc6dfb3c245f78679bfef49af689b", "score": "0.51105845", "text": "public function getTriggerZones();", "title": "" }, { "docid": "59ca3cabcb70d8eb4c3c5595444460f1", "score": "0.5088128", "text": "public static function list()\n {\n return ShippingZone::all()\n ->unique()\n ->flatMap(fn ($shippingZone) => $shippingZone->countries)\n ->sort()\n ->mapWithKeys(fn ($countryCode) => [$countryCode => self::getName($countryCode)]);\n }", "title": "" }, { "docid": "e0c9389fcee247619035989c223f49a4", "score": "0.508668", "text": "public function listCountriesAction()\n {\n $result = [\n 'EU' => [\n 'name' => gettext('Unclassified'),\n 'region' => 'Europe'\n ]\n ];\n\n foreach (explode(\"\\n\", file_get_contents('/usr/local/opnsense/contrib/tzdata/iso3166.tab')) as $line) {\n $line = trim($line);\n if (strlen($line) > 3 && substr($line, 0, 1) != '#') {\n $result[substr($line, 0, 2)] = array(\n \"name\" => trim(substr($line, 2, 9999)),\n \"region\" => null\n );\n }\n }\n foreach (explode(\"\\n\", file_get_contents('/usr/local/opnsense/contrib/tzdata/zone.tab')) as $line) {\n if (strlen($line) > 0 && substr($line, 0, 1) == '#') {\n continue;\n }\n $line = explode(\"\\t\", $line);\n if (empty($line[0]) || strlen($line[0]) != 2) {\n continue;\n }\n if (empty($line[2]) || strpos($line[2], '/') === false) {\n continue;\n }\n if (!empty($result[$line[0]]) && empty($result[$line[0]]['region'])) {\n $result[$line[0]]['region'] = explode('/', $line[2])[0];\n }\n }\n return $result;\n }", "title": "" }, { "docid": "43ef7164e0077bc4da222da25a1c21ac", "score": "0.5078873", "text": "public function get()\n {\n\n $endpoint = $this->apiUrl . 'zone/' . $this->zone;\n return $this->client->request( 'GET', $endpoint, $this->auth )->getBody()->getContents();\n\n }", "title": "" }, { "docid": "8182bd148f2014d6001aaaf5e6119dc3", "score": "0.505361", "text": "public function testZonesList()\n {\n $obj = $this->objFromFixture(TaxRate::class, \"vat\");\n\n // Test default location\n $this->assertTrue(strpos($obj->ZonesList, \"UK\") !== false);\n $this->assertTrue(strpos($obj->ZonesList, \"Germany\") !== false);\n }", "title": "" }, { "docid": "9889d61a205a0698ea25a205bec1f47e", "score": "0.5042467", "text": "public function getTimeZoneList(){\n $list = $this->getList(\"timezones\",\"\",\"\",\"name ASC\", true);\n for($i = 0; $i < count($list); $i++){\n //$tz = timezone_open($list[$i]->name);\n //$dateTimeOslo = date_create(\"now\",timezone_open(\"Europe/Oslo\"));\n $list[$i]->offset = $this->getTimeZoneOffset($list[$i]->name);\n $list[$i]->name = str_replace(\"_\",\" \", $list[$i]->name);\n }\n return $list;\n }", "title": "" }, { "docid": "f54666545618f4cc8b7626d073d12c7f", "score": "0.5021063", "text": "private function getZones(): Collection\n {\n if (! $zone = $this->argument('zone')) {\n return $this->zones;\n }\n\n $zones = $this->zones->only($zone);\n\n if ($zones->count()) {\n return $zones;\n }\n\n return new Collection([\n $zone => new Zone(),\n ]);\n }", "title": "" }, { "docid": "e864e3b1b8b0bacb443e6c55c44acddd", "score": "0.4986542", "text": "public function getDefaultZones();", "title": "" }, { "docid": "9856591535b2c7a68eb78ba02d1ebd7e", "score": "0.4986507", "text": "public function index()\n {\n $route_zones = RouteZone::paginate(15);\n $serial = 1;\n\n return view('route_zone.index', compact('route_zones', 'serial'));\n }", "title": "" }, { "docid": "060b866085f9ea5bd5a3de097e677e0c", "score": "0.49741605", "text": "public function listAction()\n {\n $layouts = array();\n $this->layout()->setVariable('nav', \"cms\");\n $this->layout()->setVariable('subNav', \"zone\");\n $p = $this->getRequest()->getQuery('page', 1);\n\n $zones = $this->getZoneService()->getZoneMapper()->findAll();\n \n $nbZones = count($zones);\n\n $zonesPaginator = new \\Zend\\Paginator\\Paginator(new \\Zend\\Paginator\\Adapter\\ArrayAdapter($zones));\n $zonesPaginator->setItemCountPerPage(self::MAX_PER_PAGE);\n $zonesPaginator->setCurrentPageNumber($p);\n\n foreach ($zones as $zone) {\n $layoutsZone = $this->getLayoutZoneService()->getLayoutZoneMapper()->findBy(array('zone' => $zone));\n foreach ($layoutsZone as $layoutZone) {\n $layouts[$zone->getId()][] = $layoutZone->getLayout(); \n }\n }\n\n return new ViewModel(array('zones' => $zones,\n 'zonesPaginator' => $zonesPaginator,\n 'layouts' => $layouts,\n 'nbZones' => $nbZones));\n }", "title": "" }, { "docid": "5982cc08b3828dc028ba4dc00c86ade0", "score": "0.49602157", "text": "public function timeZones()\n {\n $cities = array(\n 'EST',\n 'AST',\n 'CST',\n 'MST',\n 'PDT',\n 'HST',\n 'HAST',\n 'SST',\n 'CVT',\n 'SDT',\n 'AKDT',\n 'CHST',\n 'GMT',\n );\n $time_zones = array();\n\n foreach ($cities as $time_zone) {\n $time_zones[$time_zone] = timezone_name_from_abbr($time_zone);\n }\n exit(json_encode($time_zones));\n }", "title": "" }, { "docid": "2e348b321fe32fdea6fdaa3a81570743", "score": "0.49595517", "text": "function zoneList($tz)\n{\n $zones = array\n (\n 'Pacific/Kwajalein' => 'UM12',\n 'Pacific/Midway' => 'UM11',\n 'Pacific/Honolulu' => 'UM10',\n\t\t'Pacific/Marquesas' => 'UM95',\n 'America/Anchorage' => 'UM9',\n 'America/Los_Angeles' => 'UM8',\n 'America/Denver' => 'UM7',\n 'America/Mexico_City' => 'UM6',\n 'America/Bogota' => 'UM5',\n\t\t'America/Caracas' => 'UM45',\n 'America/Halifax' => 'UM4',\n 'America/St_Johns' => 'UM35',\n 'America/Buenos_Aires' => 'UM3',\n 'Atlantic/St_Helena' => 'UM2',\n 'Atlantic/Azores' => 'UM1',\n 'Europe/Dublin' => 'UTC',\n 'Europe/Berlin' => 'UP1',\n 'Europe/Warsaw' => 'UP2',\n 'Asia/Baghdad' => 'UP3',\n 'Asia/Tehran' => 'UP35',\n 'Asia/Muscat' => 'UP4',\n\t\t'Asia/Kabul' => 'UP45',\n 'Asia/Karachi' => 'UP5',\n\t\t'Asia/Kolkata' => 'UP55',\n\t\t'Asia/Katmandu' => 'UP575',\n 'Asia/Dhaka' => 'UP6',\n\t\t'Asia/Rangoon' => 'UP65',\n 'Asia/Bangkok' => 'UP7',\n 'Asia/Hong_Kong' => 'UP8',\n\t\t'Australia/West' => 'UP875',\n 'Asia/Seoul' => 'UP9',\n 'Australia/Darwin' => 'UP95',\n 'Australia/Melbourne' => 'UP10',\n\t\t'Australia/Lord_Howe' => 'UP105',\n 'Asia/Magadan' => 'UP11',\n\t\t'Pacific/Norfolk' => 'UP115',\n 'Pacific/Fiji' => 'UP12',\n\t\t'Pacific/Chatham' => 'UP1275',\n\t\t'Pacific/Tongatapu' => 'UP13'\n\t\t\n );\n\t\n\tforeach ($zones as $key => $z) {\n\t\tif ($tz == $z)\n\t\t\treturn $key;\n\t}\n}", "title": "" }, { "docid": "b8e4fe46c7b21bcda4ec7ad3ca42ada8", "score": "0.49373993", "text": "public function list_timezones() {\n $timezones = array();\n foreach(DateTimeZone::listIdentifiers() as $ts) {\n if(strpos($ts,'/')) {\n list($region, $country) = explode('/', $ts);\n $timezones[$country] = $region;\n } else {\n $timezones[$ts] = false;\n }\n }\n ksort($timezones);\n return $timezones;\n }", "title": "" }, { "docid": "e00894006d819054b07eaea4d6f58e30", "score": "0.49181858", "text": "public function index()\n {\n $zone = Zone::orderBy('name','ASC')->get();\n return view('admin.zone.index')->with('zones', $zone);\n }", "title": "" }, { "docid": "4df21ba5c08a8d5c33c18acb1a1e31bc", "score": "0.48687714", "text": "public function describeCollationTimeZonesWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeCollationTimeZones',\n 'version' => '2014-08-15',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeCollationTimeZonesResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "title": "" }, { "docid": "fd11c1fd018c0a2740d7c1950c14fb7a", "score": "0.48275712", "text": "public static function getShippingZones()\n {\n return self::getCollection('/shipping/zones', 'ShippingZone');\n }", "title": "" }, { "docid": "f783203a9bf1f3c6970c1c6b5cbd449c", "score": "0.4808079", "text": "public function zones()\n {\n //return all zones for role admin\n if ($this->role == 'admin') {\n return Zone::all();\n }\n //else return user zones\n return $this->belongsToMany('App\\Zone', 'user_zone', 'user', 'zone')->get();\n }", "title": "" }, { "docid": "35515b1a6c7d0bf83ed4d68cf3e46d0f", "score": "0.47859588", "text": "public function listServersAsyncWithHttpInfo()\n {\n $returnType = '\\Upcloud\\ApiClient\\Model\\ServerListResponse';\n $request = $this->listServersRequest();\n\n return $this->client->sendAsync($request)->then(function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n }, function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n \"[$statusCode] Error connecting to the API ({$exception->getRequest()->getUri()})\",\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n });\n }", "title": "" }, { "docid": "026e9b95e6490e7a61570e38bc03a290", "score": "0.4780723", "text": "public function zones()\n {\n return $this->o;\n }", "title": "" }, { "docid": "7c8548e25504452aca621193be787d51", "score": "0.47127193", "text": "public function getMissingZones()\n {\n return $this->missing_zones;\n }", "title": "" }, { "docid": "7c8548e25504452aca621193be787d51", "score": "0.47127193", "text": "public function getMissingZones()\n {\n return $this->missing_zones;\n }", "title": "" }, { "docid": "23fcd9efab011a598c1af5eaf9bea3c8", "score": "0.46986476", "text": "public function index($location_id, Request $request)\n {\n $perPage = $request->input('per');\n $zones = Zone::where('location_id', $location_id)->paginate($perPage);\n\n $data = array();\n foreach ($zones as $zone) {\n $arry = $zone->toArray();\n $arry['created_at'] = $zone->created_at->timestamp;\n $arry['updated_at'] = $zone->updated_at->timestamp;\n $arry['boxes'] = Box::where('zone_id', $zone->id)->count();\n $arry['networks'] = Network::where('zone_id', $zone->id)->count();\n $data[] = $arry;\n }\n\n return array('zones' => $data);\n }", "title": "" }, { "docid": "1e7bd2841424d8c638d3662bfd7fa437", "score": "0.4691603", "text": "public static function getTimeZoneList() {\n\t\t$zones = timezone_identifiers_list();\n\t\t$locations = array();\n\t\tforeach ($zones as $zone) {\n\t\t\t$zone = explode('/', $zone); // 0 => Continent, 1 => City\n\t\t\n\t\t\t// Only use \"friendly\" continent names\n\t\t\tif ($zone[0] == 'Africa' || $zone[0] == 'America' || $zone[0] == 'Antarctica' || $zone[0] == 'Arctic' || $zone[0] == 'Asia' || $zone[0] == 'Atlantic' || $zone[0] == 'Australia' || $zone[0] == 'Europe' || $zone[0] == 'Indian' || $zone[0] == 'Pacific') {\n\t\t\t\tif (isset($zone[1]) != '') {\n\t\t\t\t\t$locations[$zone[0]][$zone[0]. '/' . $zone[1]] = str_replace('_', ' ', $zone[1]); // Creates array(DateTimeZone => 'Friendly name')\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $locations;\n\t}", "title": "" }, { "docid": "ade297b52c2dd2c0495a9f68e75018f0", "score": "0.467088", "text": "public function getOptionTimezones();", "title": "" }, { "docid": "c0b700271a3382bf8fc9d42eee0b96c6", "score": "0.46496525", "text": "function printZones($db) {\n\t$query = \"SELECT * FROM ZONES WHERE rev = 0 ORDER BY fqname\";\n\t$res = getResSet($db, $query);\n\tforeach($res as $aRes) {\n\t\techo \" <option value=\\\"\".$aRes['name'].\"\\\">\".$aRes['fqname'].\"</option>\\n\";\n\t}\n}", "title": "" }, { "docid": "8fe67635d2ddd44fb608df0311a7d2e2", "score": "0.46357718", "text": "public static function fetch_timezones(){\n\t\t\tif(!is_array(self::$ArrTimezones) || empty(self::$ArrTimezones)) {\n\n\t\t\t\t$timezone_data = DateTimeZone::listIdentifiers(1022);\n\t\t\t\t$timezone_ab = DateTimeZone::listAbbreviations();\n\t\t\t\t\n\t\t\t\t$london = new DateTimeZone('Europe/London');\n\t\t\t\t$london_dt = new DateTime('now', $london);\n\t\t\t\tforeach($timezone_ab as $key => $more_data) {\n\t\t\t\t\tforeach($more_data as $tz) {\n\t\t\t\t\t\t$value = $tz['timezone_id'];\n\t\t\t\t\t\tif(!in_array($value, $timezone_data) || $tz['dst']) continue;\n\t\t\t\t\t\t$slash = strpos($value, '/');\n\t\t\t\t\t\t$continent = substr($value, 0, $slash);\n\t\t\t\t\t\t$region = substr($value, $slash+1);\n\t\t\t\t\t\t$tzlist[$continent][] = $value;\n\t\t\t\t\t\t$current_tz = new DateTimeZone($value);\n\t\t\t\t\t\t$offset = $current_tz->getOffset($london_dt);\n\t\t\t\t\t\t$tzdata[$value] = 'GMT '.trim(self::formatOffset($offset));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tksort($tzlist);\n\t\t\t\tforeach ( $tzlist as $region=>$locales ) {\n\t\t\t\t\tsort($locales);\n\t\t\t\t\tforeach( $locales as $locale ) {\n\t\t\t\t\t\t$city = substr($locale, (stripos($locale, '/')+1));\n\t\t\t\t\t\tself::$ArrTimezones[$region][$locale] = $city.' ('.$tzdata[$locale].')';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn self::$ArrTimezones;\n\t\t}", "title": "" }, { "docid": "6929c1142a7ec62fbd3bf88813ca30be", "score": "0.46268076", "text": "public function index() {\n\t$domains = Domain::all();\n\treturn View::make('list_zones.index')->with('domains', $domains);\n\n }", "title": "" }, { "docid": "1bda88d1c7099f723d0573ee4c443711", "score": "0.46236926", "text": "public function list_hosted_zone($opt = null)\n\t{\n\t\tif (!$opt) $opt = array();\n\t\t$opt['query_string'] = array();\n\n\t\t// Pass these to the query string\n\t\tforeach (array('Marker', 'MaxItems') as $option)\n\t\t{\n\t\t\tif (isset($opt[$option]))\n\t\t\t{\n\t\t\t\t$opt['query_string'][strtolower($option)] = $opt[$option];\n\t\t\t}\n\t\t}\n\n\t\t$path = '/hostedzone';\n\n\t\treturn $this->authenticate('GET', $path, $opt);\n\t}", "title": "" }, { "docid": "236d3e2ffdd0dce78725026da6713e1d", "score": "0.46230716", "text": "public function _time_zone_list()\r\n {\r\n $all_time_zone=array(\r\n 'Kwajalein' => 'GMT -12.00 Kwajalein',\r\n 'Pacific/Midway' => 'GMT -11.00 Pacific/Midway',\r\n 'Pacific/Honolulu' => 'GMT -10.00 Pacific/Honolulu',\r\n 'America/Anchorage' => 'GMT -9.00 America/Anchorage',\r\n 'America/Los_Angeles' => 'GMT -8.00 America/Los_Angeles',\r\n 'America/Denver' => 'GMT -7.00 America/Denver',\r\n 'America/Tegucigalpa' => 'GMT -6.00 America/Chicago',\r\n 'America/New_York' => 'GMT -5.00 America/New_York',\r\n 'America/Caracas' => 'GMT -4.30 America/Caracas',\r\n 'America/Halifax' => 'GMT -4.00 America/Halifax',\r\n 'America/St_Johns' => 'GMT -3.30 America/St_Johns',\r\n 'America/Argentina/Buenos_Aires'=> 'GMT +-3.00 America/Argentina/Buenos_Aires',\r\n 'America/Sao_Paulo' =>' GMT -3.00 America/Sao_Paulo',\r\n 'Atlantic/South_Georgia' => 'GMT +-2.00 Atlantic/South_Georgia',\r\n 'Atlantic/Azores' => 'GMT -1.00 Atlantic/Azores',\r\n 'Europe/Dublin' => 'GMT \t Europe/Dublin',\r\n 'Europe/Belgrade' => 'GMT +1.00 Europe/Belgrade',\r\n 'Europe/Minsk' => 'GMT +2.00 Europe/Minsk',\r\n 'Asia/Kuwait' => 'GMT +3.00 Asia/Kuwait',\r\n 'Asia/Tehran' => 'GMT +3.30 Asia/Tehran',\r\n 'Asia/Muscat' => 'GMT +4.00 Asia/Muscat',\r\n 'Asia/Yekaterinburg' => 'GMT +5.00 Asia/Yekaterinburg',\r\n 'Asia/Kolkata' => 'GMT +5.30 Asia/Kolkata',\r\n 'Asia/Katmandu' => 'GMT +5.45 Asia/Katmandu',\r\n 'Asia/Dhaka' => 'GMT +6.00 Asia/Dhaka',\r\n 'Asia/Rangoon' => 'GMT +6.30 Asia/Rangoon',\r\n 'Asia/Krasnoyarsk' => 'GMT +7.00 Asia/Krasnoyarsk',\r\n 'Asia/Brunei' => 'GMT +8.00 Asia/Brunei',\r\n 'Asia/Seoul' => 'GMT +9.00 Asia/Seoul',\r\n 'Australia/Darwin' => 'GMT +9.30 Australia/Darwin',\r\n 'Australia/Canberra' => 'GMT +10.00 Australia/Canberra',\r\n 'Asia/Magadan' => 'GMT +11.00 Asia/Magadan',\r\n 'Pacific/Fiji' => 'GMT +12.00 Pacific/Fiji',\r\n 'Pacific/Tongatapu' => 'GMT +13.00 Pacific/Tongatapu'\r\n );\r\n\r\n return $all_time_zone;\r\n }", "title": "" }, { "docid": "db8c4cc10bfb235019e48c4fa6a773e3", "score": "0.46167177", "text": "public function getZonas()\n {\n return $this->zonas;\n }", "title": "" }, { "docid": "e8519ed79197a3400b9002a768704f3f", "score": "0.46141157", "text": "public function listServersWithHttpInfo()\n {\n $returnType = '\\Upcloud\\ApiClient\\Model\\ServerListResponse';\n $request = $this->listServersRequest();\n\n try {\n\n try {\n $response = $this->client->send($request);\n } catch (RequestException $e) {\n throw new ApiException(\n \"[{$e->getCode()}] {$e->getMessage()}\",\n $e->getCode(),\n $e->getResponse() ? $e->getResponse()->getHeaders() : null\n );\n }\n\n $statusCode = $response->getStatusCode();\n\n if ($statusCode < 200 || $statusCode > 299) {\n throw new ApiException(\n \"[$statusCode] Error connecting to the API ({$request->getUri()})\",\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n\n } catch (ApiException $e) {\n switch ($e->getCode()) {\n case 200:\n $data = ObjectSerializer::deserialize($e->getResponseBody(), '\\Upcloud\\ApiClient\\Model\\ServerListResponse', $e->getResponseHeaders());\n $e->setResponseObject($data);\n break;\n }\n throw $e;\n }\n }", "title": "" }, { "docid": "0fb3f229ec824df0eff70211551d4d47", "score": "0.45184442", "text": "Public Static function getAllTimesZones() {\n $zones_array = [];\n // $timestamp = time();\n\n foreach (timezone_identifiers_list() as $key => $zone) {\n $zones_array[$zone] = $zone;\n\n //date_default_timezone_set($zone);\n //$zones_array[$key]['zone'] = $zone;\n //$zones_array[$key]['diff_from_GMT'] = 'UTC/GMT ' . date('P', $timestamp);\n }\n\n return $zones_array;\n }", "title": "" }, { "docid": "868170c127fad02ae339ac7394459e1e", "score": "0.45125827", "text": "public function zones()\n {\n return $this->hasMany(Zone::class);\n }", "title": "" }, { "docid": "503705600a6d4a5a6cdba4f23c40efaa", "score": "0.45124698", "text": "public function userPrototypeGetDevicesInZoneAsyncWithHttpInfo($id, $zone_id = null, $zone_type = null, $include_approx = null)\n {\n $returnType = 'object[]';\n $request = $this->userPrototypeGetDevicesInZoneRequest($id, $zone_id, $zone_type, $include_approx);\n\n return $this->client\n ->sendAsync($request, $this->createHttpClientOption())\n ->then(\n function ($response) use ($returnType) {\n $responseBody = $response->getBody();\n if ($returnType === '\\SplFileObject') {\n $content = $responseBody; //stream goes to serializer\n } else {\n $content = $responseBody->getContents();\n if ($returnType !== 'string') {\n $content = json_decode($content);\n }\n }\n\n return [\n ObjectSerializer::deserialize($content, $returnType, []),\n $response->getStatusCode(),\n $response->getHeaders()\n ];\n },\n function ($exception) {\n $response = $exception->getResponse();\n $statusCode = $response->getStatusCode();\n throw new ApiException(\n sprintf(\n '[%d] Error connecting to the API (%s)',\n $statusCode,\n $exception->getRequest()->getUri()\n ),\n $statusCode,\n $response->getHeaders(),\n $response->getBody()\n );\n }\n );\n }", "title": "" }, { "docid": "7e712a49d7f26db3a28ddbd4934a2b65", "score": "0.45112884", "text": "public function getDNSRecordsForZone(Request $request, $zone){\n $params = '';\n /** \n * processes all the parameters sent along with the request\n * and skips the per_page option\n */\n foreach($request->all() as $key => $value){\n if($key == 'per_page') continue;\n $params .= \"$key=$value&\";\n }\n\n // Ensures that the result per page is set\n $params .= trim($this->perPage($request), '?');\n\n $url = $this->getApiUrl().\"zones/$zone/dns_records?$params\";\n return Http::get($url, ['headers' => $this->getHeaders()]);\n }", "title": "" }, { "docid": "508058a6191e4106ad8d9c48187a6ad7", "score": "0.45075282", "text": "public function index()\n {\n if (\\request()->ajax()) {\n $timezones = Timezone::withTrashed()->with('status');\n return DataTables::eloquent($timezones)\n ->addIndexColumn()\n ->editColumn('status', function (Timezone $timezone) {\n return view('admin.timezones.status', compact('timezone'))->render();\n })\n ->addColumn('actions', function (Timezone $timezone) {\n return view('admin.timezones.actions', compact('timezone'))->render();\n })\n ->rawColumns(['status', 'actions'])\n ->toJson();\n }\n $statuses = Status::whereType('active-inactive')->pluck('name', 'id');\n return view($this->view, compact('statuses'));\n }", "title": "" }, { "docid": "c5f7bb7e909ed8d1ac08c8da6bfc0398", "score": "0.4492763", "text": "public function actionGetstatesbyzones()\n {\n $zone_id = $_REQUEST['zone_id'];\n $user_type = @$_REQUEST['user_type'];\n $states = States::get_states_by_zone_id($zone_id,$user_type);\n \n if(@$_REQUEST['type'] == 'employee')\n {\n $out='';\n foreach($states as $state)\n {\n $out.='<option value=\"'.$state['state_id'].'\">'.strtoupper($state['state_name']).'</option>';\n }\n return json_encode(array(\"states\"=>$out));\n }\n else\n {\n $out='<option value=\"\" selected>SELECT STATE *</option>';\n foreach($states as $state)\n {\n $out.='<option value=\"'.$state['state_id'].'\">'.strtoupper($state['state_name']).'</option>';\n }\n return json_encode(array(\"states\"=>$out));\n }\n }", "title": "" }, { "docid": "5931a88ead782f545cb2050971292e2d", "score": "0.4491951", "text": "public function setMissingZones($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::STRING);\n $this->missing_zones = $arr;\n\n return $this;\n }", "title": "" }, { "docid": "de5e6aa2d1e6f0e9edc7234553a527c6", "score": "0.44907507", "text": "public function timezones()\n {\n // timezone_identifiers_list() is also returns same list of timezones.\n return DateTimeZone::listIdentifiers(DateTimeZone::ALL);\n }", "title": "" }, { "docid": "321a7917e29976c8cbcf632e852d8642", "score": "0.44892192", "text": "function TimeZoneList($selected_timezone='')\n\t{\n\t\t$settings_page = false;\n\t\tif (isset($_GET['Page']) && strtolower($_GET['Page']) == 'settings') {\n\t\t\t$settings_page = true;\n\t\t}\n\n\t\t$selected_timezone = trim($selected_timezone);\n\t\t$this->LoadLanguageFile('TimeZones');\n\t\t$list = '';\n\t\tforeach ($GLOBALS['SendStudioTimeZones'] as $pos => $offset) {\n\t\t\t$selected = '';\n\t\t\tif ($offset == $selected_timezone) {\n\t\t\t\t$selected = ' SELECTED';\n\t\t\t}\n\t\t\t$entry = '<option value=\"' . $offset . '\"' . $selected . '>' . GetLang($offset) . '</option>';\n\n\t\t\tif (!$settings_page) {\n\t\t\t\t$list .= $entry;\n\t\t\t}\n\n\t\t\tif ($settings_page && $selected) {\n\t\t\t\t$list .= $entry;\n\t\t\t}\n\t\t}\n\t\treturn $list;\n\t}", "title": "" }, { "docid": "f929b40d3334ff921310b9577719742d", "score": "0.44696844", "text": "function get_timezones() {\r\n\t\r\n\t$tzlist = DateTimeZone::listIdentifiers();\r\n\t\r\n\treturn $tzlist;\r\n}", "title": "" }, { "docid": "ae05da600e0ccb678e8ead99d3686b77", "score": "0.4466975", "text": "public function getReplicaZones()\n {\n return $this->replica_zones;\n }", "title": "" }, { "docid": "b2aaea49b614f0558fdf78b2be72aa94", "score": "0.44593713", "text": "public static function GetTimezones()\n {\n return static::$_options;\n }", "title": "" }, { "docid": "927d41a218dae6cf66965c870efc3b3c", "score": "0.43959466", "text": "public function actionGetzonesbyusertype()\n {\n $zones = Zones::get_employee_zones($_REQUEST['user_type']);\n $out = '';\n foreach($zones as $zone)\n {\n $out.='<option value=\"'.$zone['zone_id'].'\">'.strtoupper($zone['zone_name']).'</option>';\n }\n return json_encode(array(\"zones\"=>$out));\n }", "title": "" }, { "docid": "b9a04c4f57ac358a3df4e5635a3cfb37", "score": "0.43842673", "text": "function tz_list() {\n\t$zones_array = array();\n\t$timestamp = time();\n\tforeach (timezone_identifiers_list() as $key => $zone) {\n\t\tdate_default_timezone_set($zone);\n\t\t$zones_array[$key]['zone'] = $zone;\n\t\t$zones_array[$key]['diff_from_GMT'] = 'UTC/GMT ' . date('P', $timestamp);\n\t\t$zones_array[$key]['GMT'] = date('P', $timestamp);\n\t}\n\treturn $zones_array;\n}", "title": "" }, { "docid": "ec46e8c98d1a61736a366ba28e227ff2", "score": "0.43803135", "text": "public function list_records($zone_identifier, $type = null, $name = null, $content = null, $vanity_name_server_record = null, $page = null, $per_page = null, $order = null, $direction = null, $match = null)\n {\n $data = array(\n 'type' => $type,\n 'name' => $name,\n 'content' => $content,\n 'vanity_name_server_record' => $vanity_name_server_record,\n 'page' => $page,\n 'per_page' => $per_page,\n 'order' => $order,\n 'direction' => $direction,\n 'match' => $match\n );\n\n return $this->get('zones/' . $zone_identifier . '/dns_records', $data);\n }", "title": "" }, { "docid": "b1ea9978659433917e36defe72a12558", "score": "0.4354855", "text": "public function showAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('ApplicationRelationsBundle:ServeursZones')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find ServeursZones entity.');\n }\n\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('ApplicationRelationsBundle:ServeursZones:show.html.twig', array(\n 'entity' => $entity,\n 'delete_form' => $deleteForm->createView(), ));\n }", "title": "" }, { "docid": "a47290967c273f2995b3114a87b4a803", "score": "0.4348116", "text": "public static function customerApiList()\r\n {\r\n return array();\r\n }", "title": "" }, { "docid": "6609d96dd61efd1dc2aeade4766e4f52", "score": "0.43436134", "text": "public function getIndex()\n\t{\n\t\t// dd( Auth::user() );\n\t\t$user = Auth::user();\n\n\t\t$zones_arrays = array();\n\t\t $timestamp = time();\n\t\t foreach(timezone_identifiers_list() as $key => $zone) {\n\t\t date_default_timezone_set($zone);\n\t\t $zones_arrays[$key]['zone'] = $zone;\n\t\t $zones_arrays[$key]['diff_from_GMT'] = 'UTC/GMT ' . date('P', $timestamp);\n\t\t }\n\t\t return Response::json(['user' => $user, 'zones_arrays' => $zones_arrays]);\n\t\t// return view('account.index', ['user' => $user, 'zones_arrays' => $zones_arrays]);\n\t}", "title": "" }, { "docid": "fd688e50b9d402144c3df3cd90e08749", "score": "0.43335056", "text": "public function index()\n {\n $data = LocalesJefezonal::all();\n\n return $this->showAll($data);\n }", "title": "" }, { "docid": "ee8ccea2c14a818a341d106d84bf9709", "score": "0.43332058", "text": "public function list()\n {\n return $this->getResult($this->client->get('server/list'));\n }", "title": "" }, { "docid": "4277a6d74d34f51b152767de5992f5a5", "score": "0.43245542", "text": "public function index()\n {\n // Try to get the regions with their cities\n $this->manager->active()->withCities();\n \n if ( $this->manager->hasError() ) {\n return response()->json(['message' => $this->manager->errorMessage()], $this->manager->errorCode());\n }\n\n return response()->json([\n 'message' => $this->manager->successMessage(),\n 'data' => [\n 'regions' => $this->manager->regions()\n ]\n ], $this->manager->successCode());\n }", "title": "" }, { "docid": "975b29947b69b8dbe01277035ea7e3c4", "score": "0.43202022", "text": "public function index()\n {\n $countries = (new GetCountriesListTask())->run();\n\n return new JsonResponse($countries);\n }", "title": "" }, { "docid": "a39bc5ec7f83c604d3bdb99d1c284780", "score": "0.43130276", "text": "function countriesList()\n {\n $query = $this->url . $this->buildQuery( array(\n 'method' => 'wct.countries.list'\n ) );\n return $this->execQuery( $query );\n }", "title": "" }, { "docid": "442bc988b6f298fd230bf42db200012c", "score": "0.43075854", "text": "public function list()\n {\n return $this->HosterAPI->get('datacenter/server');\n }", "title": "" }, { "docid": "f9ee2e2e19b06483f61761579878e6f4", "score": "0.4295237", "text": "public function countries()\n {\n return $this->client->restfulRequest('get', $this->getFullUrl('/countries'));\n }", "title": "" }, { "docid": "8f5fd5feafdf40a3219611452bd068b3", "score": "0.42831823", "text": "public function lists()\n\t{ \n\t\t$input \t \t= $this->getListRequest();\t\t\n\t\t$locations \t= $this->locationRepository->find($input['take'], $input['skip'], $input['sort'], $input['filter']);\n\t\t$total \t= $this->locationRepository->count($input['filter']);\n\n\t\treturn $this->makeListResponse($locations, $total);\n\t}", "title": "" }, { "docid": "605256725434a2ea25b8ae209d5d05e7", "score": "0.42788026", "text": "public function index($id)\n\t{\n\t\t$site = Site::find($id);\n\t\t$zones = Zone::all();\n\t\t$data = array(\n\t\t\t'page' => 'sites',\n\t\t\t'tab' => 'manage',\n\t\t\t'site' => $site,\n\t\t\t'zones' => $zones\n\t\t\t);\n\t\treturn View::make('site_zone.index', $data);\n\t}", "title": "" }, { "docid": "6d99be404bc0e448ef201219c715e0c7", "score": "0.4278674", "text": "private static function getTimezones(int $regions): array\n {\n $timezones = [];\n\n foreach (\\DateTimeZone::listIdentifiers($regions) as $timezone) {\n $parts = explode('/', $timezone);\n\n if (\\count($parts) > 2) {\n $region = $parts[0];\n $name = $parts[1].' - '.$parts[2];\n } elseif (\\count($parts) > 1) {\n $region = $parts[0];\n $name = $parts[1];\n } else {\n $region = 'Other';\n $name = $parts[0];\n }\n\n $timezones[$region][str_replace('_', ' ', $name)] = $timezone;\n }\n\n return 1 === \\count($timezones) ? reset($timezones) : $timezones;\n }", "title": "" }, { "docid": "d7a01b896c7849e4a19cf51be4e3d579", "score": "0.4272139", "text": "public function describeRegions($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->describeRegionsWithOptions($request, $runtime);\n }", "title": "" }, { "docid": "90e1abc09a7d3be129aa38f6b981ddac", "score": "0.42668623", "text": "public static function getZones($allow_delivery = FALSE){\n $cache_id = 'jeproshop_zone_model_get_zones_' . (bool)$allow_delivery;\n if(!JeproshopCache::isStored($cache_id)) {\n $db = JFactory::getDBO();\n\n $query = \"SELECT * FROM \" . $db->quoteName('#__jeproshop_zone') . ($allow_delivery ? \" WHERE allow_delivery = 1 \" : \"\");\n $query .= \" ORDER BY \" . $db->quoteName('name') . \" ASC \";\n\n $db->setQuery($query);\n $result = $db->loadObjectList();\n JeproshopCache::store($cache_id, $result);\n }\n return JeproshopCache::retrieve($cache_id);\n\t}", "title": "" }, { "docid": "f3fc77e13de79aa6c177feeb07670d02", "score": "0.42404196", "text": "public function index()\n {\n //\n $countries = Countrie::select('iso_a2 as iso', 'admin as country')->get();\n return response()->api($countries);\n }", "title": "" }, { "docid": "fec2a4395e9e71aa04aed520e9ea9b62", "score": "0.4236994", "text": "public function index(Request $request)\n {\n if ($request->showTrashed) {\n $countries = Country::onlyTrashed()->get();\n } else {\n $countries = Country::all();\n }\n return CountryResource::collection($countries);\n }", "title": "" }, { "docid": "8f0798b9f8c336e4cea57303c659ce77", "score": "0.42277846", "text": "function listServers($tenant_id, $server_info = null) {\n\n $data = array();\n\n if (!empty($server_info)) {\n $optional_fields = array('changes-since', 'image', 'flavour', 'name', 'marker', 'limit', 'status', 'host');\n foreach ($optional_fields as $field)\n if (!empty($server_info[$field]))\n $data[$field] = $server_info[$field];\n }\n\n $call = \"v2/\" . $tenant_id . \"/servers\";\n return $this->getWithCustomToken($tenant_id, $this->url, 8774, $call, \"GET\", $data);\n }", "title": "" }, { "docid": "d045956406ddfae0e861bedf2b1d1057", "score": "0.4204575", "text": "public function setReplicaZones($var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::STRING);\n $this->replica_zones = $arr;\n\n return $this;\n }", "title": "" }, { "docid": "62c06abaa759c20a06b2167d97cff6a5", "score": "0.41984412", "text": "public function list()\n {\n $resp = [\n 'categories' => Category::all(),\n 'cities' => City::all(),\n 'regions' => Region::all()\n ];\n return $this->respond($resp);\n }", "title": "" }, { "docid": "c8c6fe5e9c85a3aca83d2107bc9034a9", "score": "0.41948658", "text": "function browseAllZones() {\n\tglobal $m,$r;\n\t$table = $_POST['table'];\n\t$order = $_POST['order'];\n\tif(isset($_POST['wc'])) {\n\t\t$_POST['wc'] = stripslashes($_POST['wc']);\n\t\t$wc = str_replace(\"!!\",\" AND \",$_POST['wc']);\n\t\t$wc = str_replace(\"::\",\" OR \",$wc);\n\t} else $wc = NULL;\n\tif($m->getAll($table,\"*\",$order,$wc)) {\n\t\t$r['did'] = \"found \".$table;\n\t\t$r['data'] = $m->lastData();\n\t\tforeach($r['data'] as $zon) {\n\t\t\tif($m->getRow('es_uploads',$zon->zon_layout))\n\t\t\t\t$zon->zon_layout = $m->lastData()->up_root.$m->lastData()->up_handle.\"/\".$m->lastData()->up_handle;\n\t\t\t// rebate dollars to watts\n\t\t\t$m->getRow('es_modules',$zon->zon_module,\"mod_model_num\");\n\t\t\t$mod_watts = $m->lastData()->mod_stc;\n\t\t\t//$zon->zon_rebate = $zon->zon_rebate / ($zon->zon_num_modules * $mod_watts);\n\t\t\tif ( ($zon->zon_num_modules * $mod_watts) == 0 ) {\n\t\t\t\t$zon->zon_rebate = 0;\n\t\t\t} else {\n\t\t\t\t$zon->zon_rebate = $zon->zon_rebate / ($zon->zon_num_modules * $mod_watts);\n\t\t\t}\n\t\t\t// get material descriptions\n\t\t\t$r['data2']['mod_desc'][] = $m->lastData()->mod_desc;\n\t\t\t$m->getRow('es_racking',$zon->zon_racking,\"rac_model_num\");\n\t\t\t$r['data2']['rac_desc'][] = $m->lastData()->rac_desc;\n\t\t}\n\t} else $r['did'] = \"no \".$table;\n\t// get zone menu options\n\t$menus = explode(\",\",$_POST['menus']);\n\t$sources = explode(\",\",$_POST['sources']);\n\t$columns = explode(\",\",$_POST['columns']);\n\tfor($i=0;$i<count($menus);$i++) {\n\t\tif($m->getAll($sources[$i],$columns[$i],\"ID\",\"active='1'\")) {\n\t\t\t$r['data2'][$menus[$i]] = $m->lastData();\n\t\t} else $r['did'] = \"failed \".$table.\" options\";\n\t}\n}", "title": "" }, { "docid": "62c337c00ea4a9b33ea3f65476c80dad", "score": "0.4193952", "text": "function getTimeZonesHtml(){\n\n $data = $this->getTimeZones();\n if(is_array($data)){\n foreach($data as $row){\n $rows[$row['pkTimeZoneID']] = $row['TimeZoneTitle'];\n }\n $arrArg = array(\"name\" => \"timezone\",\n \"options\" => $rows);\n $html = $this->createSelectBox($arrArg);\n return $html;\n }\n }", "title": "" }, { "docid": "25be6743246f292aff1f287e120b62cc", "score": "0.41914445", "text": "public static function generateList($includeUTC = false)\n {\n $regions = [\n DateTimeZone::AFRICA,\n DateTimeZone::AMERICA,\n DateTimeZone::ANTARCTICA,\n DateTimeZone::ASIA,\n DateTimeZone::ATLANTIC,\n DateTimeZone::AUSTRALIA,\n DateTimeZone::EUROPE,\n DateTimeZone::INDIAN,\n DateTimeZone::PACIFIC,\n ];\n\n if ($includeUTC) {\n $regions[] = DateTimeZone::UTC;\n }\n\n $timezones = [];\n foreach ($regions as $region) {\n $timezones = array_merge($timezones, DateTimeZone::listIdentifiers($region));\n }\n\n $timezone_offsets = [];\n foreach ($timezones as $timezone) {\n $tz = new DateTimeZone($timezone);\n $timezone_offsets[$timezone] = $tz->getOffset(new DateTime);\n }\n\n // sort timezone by timezone name\n asort($timezone_offsets);\n\n $timezone_list = [];\n\n foreach ($timezone_offsets as $timezone => $offset) {\n $offset_prefix = $offset < 0 ? '-' : '+';\n $offset_formatted = gmdate('H:i', abs($offset));\n\n $pretty_offset = \"UTC${offset_prefix}${offset_formatted}\";\n\n $t = new DateTimeZone($timezone);\n $c = new DateTime(null, $t);\n $current_time = $c->format('H:i');\n\n $timezone_list[$timezone] = $pretty_offset . ' - ' . $timezone;\n }\n\n return $timezone_list;\n }", "title": "" }, { "docid": "9bbbe3c7ea461de153106f64dd307590", "score": "0.41894346", "text": "public function getThemeRegions(Request $request) {\n // Check theme parameter.\n $themeParam = $request->attributes->get('theme');\n if ($themeParam == '__default__') {\n // Default theme.\n $theme = $this->config('system.theme')->get('default');\n }\n else {\n // Named theme, must exist.\n $themes = $this->themeHandler->listInfo();\n if (array_key_exists($themeParam, $themes)) {\n $theme = $themeParam;\n }\n else {\n // Theme is not a valid theme name.\n $invalid_error = TRUE;\n }\n }\n\n // Get a list of regions for the desired theme.\n $regions = [];\n if (($region_list = system_region_list($theme, BlockRepositoryInterface::REGIONS_ALL))) {\n foreach ($region_list as $key => $region) {\n $regions[] = [\n 'value' => $key,\n 'name' => $region,\n ];\n }\n }\n\n $error = (empty($regions) || isset($invalid_error)) ? TRUE : FALSE;\n\n // Return built array.\n return new CohesionJsonResponse([\n 'status' => !$error ? 'success' : 'error',\n 'data' => $regions,\n ]);\n }", "title": "" }, { "docid": "669cafd36f86a8b0dc43748b504b69a5", "score": "0.41878495", "text": "public function setMissingZones(&$var)\n {\n $arr = GPBUtil::checkRepeatedField($var, \\Google\\Protobuf\\Internal\\GPBType::STRING);\n $this->missing_zones = $arr;\n }", "title": "" }, { "docid": "6c5702e3c2fd29d011767ded7d7cdf07", "score": "0.41771078", "text": "public function get_location_zone_wise($id){\n $data=DB::table('tblocation')\n ->select('tblocation.name','tblocation.id')\n ->where('zoneId',$id)\n ->get();\n return response()->json($data);\n }", "title": "" }, { "docid": "c7099b52dad94bf48cab0a4b110c42bf", "score": "0.41645312", "text": "public function show($location_id, $id)\n {\n $item = Zone::find($id);\n if (!isset($item)) {\n return array('code' => 0, 'message' => 'Invalid Request');\n }\n\n $data = $item->toArray();\n $data['created_at'] = $item->created_at->timestamp;\n $data['updated_at'] = $item->updated_at->timestamp;\n $data['boxes'] = Box::where('zone_id', $item->id)->count();\n\n $networks = Network::where('zone_id', $item->id)->get();\n\n $data1 = array();\n foreach ($networks as $network) {\n $item1 = array();\n $item1['network_id'] = $network->id;\n $data1[] = $item1;\n }\n\n return array('zone' => $data, 'networks' => $data1);\n }", "title": "" }, { "docid": "de8eeb40903812714d99d8401db01d08", "score": "0.41387555", "text": "public function all()\n {\n if($this->pterodactyl->api_type === 'client') {\n return $this->request('GET', '/api/client');\n }\n\n return $this->request('GET', '/api/' . $this->pterodactyl->api_type . '/servers');\n }", "title": "" }, { "docid": "5af1332fdfa43aa8c227aa209b3e74c7", "score": "0.41368696", "text": "function getAvailableCloudsAndTemplates() {\n\t\t$this->setAPIResource( \"available_clouds\" );\n\t\t$result = $this->sendGETRequest();\n\t\t$return = null;\n\n\t\tif ($result[\"info\"][\"http_code\"] == 422) {\n\t\t}\n\t\telse {\n\t\t\tif ($result[\"response\"]) {\n\t\t\t\t$return = $result[\"response\"];\n\t\t\t}\n\t\t}\n\n\t\treturn $return;\n\t}", "title": "" }, { "docid": "dd82b94f59d8c949e49d9db90f9725d7", "score": "0.41296667", "text": "public function loadZone()\n {\n $route_id = $_POST['route_id'];\n\n $route_info = $this->db->query('SELECT * FROM routes WHERE route_id = ' . $route_id . ' AND route_id_member = ' . $this->Member_id)->result_array(false);\n $service = $this->db->query('SELECT * FROM customers_service WHERE service_route = ' . $route_id . ' AND member_id = ' . $this->Member_id)->result_array(false);\n $route_map = $this->db->query('SELECT * FROM route_map WHERE route_id = ' . $route_id . ' AND map_id_member = ' . $this->Member_id)->result_array(false);\n $data = array(\n 'map' => $route_map,\n 'service' => $service,\n 'route_info' => $route_info\n );\n echo json_encode($data);\n die();\n }", "title": "" }, { "docid": "3974a36078a77bb1d8c17b8a59bff6d4", "score": "0.41278312", "text": "public function show($id)\n {\n $zone = Zone::findOrFail($id);\n\n return view('zones.show', compact('zone'));\n }", "title": "" }, { "docid": "3762e0668c661c441398c25d94120f84", "score": "0.41265312", "text": "public function index()\n {\n \t$data = DrivingZone::all();\n return view('admin.drivingzone.index',compact('data'));\n }", "title": "" }, { "docid": "1629f919c6f32b43109b7409ee9640f1", "score": "0.41196048", "text": "public function testApiV2PortalCountriesList()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "title": "" }, { "docid": "e52e3d7e25e6fca604c189dc55ede47f", "score": "0.40958565", "text": "public function getTimezones($time='now', $unqiueOffsets=false)\n\t{\n\t\tif(!count($this->timeZones)) {\n\t\t\t$this->timeZones = Bench::getTimezones($this->code, $time, $unqiueOffsets);\n\t\t}\n\t\treturn $this->timeZones;\n\t}", "title": "" } ]
cfeed86e10e84e138e6ba8bf3e028326
Set $_EndTime to $inEndTime
[ { "docid": "42149488169ea2ab9a1457b7a26242ee", "score": "0.7898538", "text": "protected function _setEndTime($inEndTime) {\n\t\tif ( $this->_EndTime !== $inEndTime ) {\n\t\t\t$this->_EndTime = $inEndTime;\n\t\t}\n\t\treturn $this;\n\t}", "title": "" } ]
[ { "docid": "8a690b3f83fe2c91f2bebec3a0ae2bd9", "score": "0.7272351", "text": "public\r\n function setEndTime($endTime) {\r\n $this->endTime = $endTime;\r\n }", "title": "" }, { "docid": "e26304aa27160281e31170b964ebc58d", "score": "0.71682787", "text": "public function setEndTime($endTime) {\n\t\t$this->endTime = $endTime;\n\t}", "title": "" }, { "docid": "6dd88db4fedb4bb37b1aca5b7dba4726", "score": "0.71585953", "text": "public function setEndTime($time);", "title": "" }, { "docid": "2cfe943feae77c1ab13b477130108f9f", "score": "0.66381466", "text": "public function setEndTime($when = null)\n {\n $this->endTime = $this->formatDate($when);\n }", "title": "" }, { "docid": "d2de8754f4cfe74c7554bd2237f6e63a", "score": "0.6629911", "text": "public function setScheduleEndTime(\\DateTime $newScheduleEndTime) {\n\t\tif($newScheduleEndTime === null) {\n\t\t\tthrow(new \\InvalidArgumentException(\"Must enter in an end time\"));\n\t\t}\n\n\t\ttry {\n\t\t\t$newScheduleEndTime = self::validateDateTime($newScheduleEndTime);\n\t\t} catch(\\InvalidArgumentException $invalidArgument) {\n\t\t\tthrow(new \\InvalidArgumentException($invalidArgument->getMessage(), $invalidArgument));\n\t\t}\n\n\t\tif($newScheduleEndTime <= $this->scheduleStartTime){\n\t\t\tthrow(new \\InvalidArgumentException(\"The end-time cannot be before the start-time\"));\n\t\t}\n\n\t\t$this->scheduleEndTime = $newScheduleEndTime;\n\t}", "title": "" }, { "docid": "b9f1d227be708a91e8ff1ac9e2ef4fff", "score": "0.6612894", "text": "public function setEndTime($when = null)\n {\n $this->info['endTime'] = $this->formatDate($when);\n }", "title": "" }, { "docid": "60c3a9602223be6b2557aa51bf0402c0", "score": "0.65182054", "text": "public function setEndTime( $endTime )\n {\n $this->_daChallenge->setEndTime( $this->getId(), $endTime );\n }", "title": "" }, { "docid": "56c630f84f6f584ebf8b3b5ab8b26f65", "score": "0.6495409", "text": "public function set_end_time($end_time) {\n if ( is_numeric($end_time) && $end_time > 0 && $end_time < 4294967295 ) {\n $this->end_time = 0+$end_time; // faster than intval\n } else {\n throw new TokenAuth_ParameterException(\"end time input invalid or out of range\");\n }\n\t}", "title": "" }, { "docid": "7fb7ac92d010c2d3d36f3f1979066bd8", "score": "0.6250219", "text": "protected function _set_end_time() {\n $this->setEndTime(self::_current_time());\n return $this;\n }", "title": "" }, { "docid": "1b1ad83ab96a59adb5907e67ab7be565", "score": "0.6244253", "text": "public function getEndTime() {return $this->endTime;}", "title": "" }, { "docid": "5aa2157c77c7eeed9788c553285419a8", "score": "0.603928", "text": "public function setEndTime($endTime)\n {\n $this->endTime = $endTime;\n\n return $this;\n }", "title": "" }, { "docid": "7d9f4f7fb2ad2cab122a0221ce5180a8", "score": "0.5999066", "text": "public function setEnd(DateTime $end)\n {\n $this->end = $end;\n }", "title": "" }, { "docid": "5d3d6102a450eddc19a9f6bbc058e9be", "score": "0.5984285", "text": "public function setEndTime(\\DateTime $endTime)\n {\n $this->endTime = $endTime;\n return $this;\n }", "title": "" }, { "docid": "d83e0d52168fc2741919bdd82189bc75", "score": "0.59458065", "text": "public function setEndTime($value)\n {\n if ($value instanceof \\DateTime) {\n $value->setTimezone(new \\DateTimeZone('UTC'));\n $value = $value->format('Y-m-d\\TH:i:s\\Z');\n }\n return $this->setParameter('endTime', $value);\n }", "title": "" }, { "docid": "3ec20af448555a3b5a5e97d9b9d2a4fe", "score": "0.5941957", "text": "public\r\n function getEndTime() {\r\n return $this->endTime;\r\n }", "title": "" }, { "docid": "cd7d43a3ddb2c956d0b5034a6b6c535d", "score": "0.59240043", "text": "private function endtime(){\n\t\t// [REST] Update appointment end_time\n\t\t$update = $this->postPhysician('appointment', array(\n\t\t\t'id' => $this->input->post('id'),\n\t\t\t'end_time' => $this->input->post('end_time'),\n\t\t));\n\t\t\n\t\t// Alert results to front-end\n\t\tif($update['status']=='TRUE'){\n\t\t\t$this->notify(1, 'Appointment end time was set.');\n\t\t}else{\n\t\t\t$this->notify(0, $update['message']);\n\t\t}\n\t}", "title": "" }, { "docid": "0c665e1712e09f41c6f4d5009a2175ea", "score": "0.5914417", "text": "public function setEndDateTime($val)\n {\n $this->_propDict[\"endDateTime\"] = $val;\n return $this;\n }", "title": "" }, { "docid": "a0e9fdbb5d63f84edd2806c574bf1642", "score": "0.58989334", "text": "protected function _setStartTime($inStartTime) {\n\t\tif ( $this->_StartTime !== $inStartTime ) {\n\t\t\t$this->_StartTime = $inStartTime;\n\t\t}\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "db68e0e4253574d77a0604e4ae53d0e7", "score": "0.5872906", "text": "public function setEndTime($var)\n {\n GPBUtil::checkString($var, True);\n $this->EndTime = $var;\n\n return $this;\n }", "title": "" }, { "docid": "db68e0e4253574d77a0604e4ae53d0e7", "score": "0.5872906", "text": "public function setEndTime($var)\n {\n GPBUtil::checkString($var, True);\n $this->EndTime = $var;\n\n return $this;\n }", "title": "" }, { "docid": "44b0ec3b906d64ba2f336eec59ee652e", "score": "0.5815906", "text": "public function setStop( DateTime $now = NULL )\n {\n if( $now instanceof DateTime )\n {\n $this->stopTime = clone( $now );\n }\n else\n {\n $this->stopTime = new DateTime;\n }\n }", "title": "" }, { "docid": "3428cbceb7330d215fc85ba7fdede9e2", "score": "0.5779134", "text": "public function setEndTime(\\DateTime $endTime)\n {\n $this->endTime = $endTime;\n\n return $this;\n }", "title": "" }, { "docid": "04b06d1ca8a8a1ca49e963d306acca90", "score": "0.57752", "text": "protected function setTime(qCal_Time $time) {\n\t\n\t\t$this->time = $time;\n\t\n\t}", "title": "" }, { "docid": "070204ad330f1006a60093c434e4af93", "score": "0.57663465", "text": "public function setEndTimeInfo( $end_time_info )\n {\n $this->end_time_info = $end_time_info;\n\n return $this;\n }", "title": "" }, { "docid": "95c69746cd7d0b0d79c2f2e1531b8539", "score": "0.5719951", "text": "public function setEndDateTime(?DateTime $value): void {\n $this->getBackingStore()->set('endDateTime', $value);\n }", "title": "" }, { "docid": "091cd9378090f894bacb98f8a5305eb8", "score": "0.57131374", "text": "public function setEndTime($end_time)\n {\n $this->end_time = $end_time;\n\n return $this;\n }", "title": "" }, { "docid": "b776f90a9f62e2a296720e98f3e677ae", "score": "0.57040936", "text": "public function setUpgradeWindowEndTime(?Time $value): void {\n $this->getBackingStore()->set('upgradeWindowEndTime', $value);\n }", "title": "" }, { "docid": "2493649e21e77fb81ff0fedbc83d172e", "score": "0.570312", "text": "public function setEndDateTime($val)\n {\n $this->_propDict[\"endDateTime\"] = $val;\n return $this;\n }", "title": "" }, { "docid": "2493649e21e77fb81ff0fedbc83d172e", "score": "0.570312", "text": "public function setEndDateTime($val)\n {\n $this->_propDict[\"endDateTime\"] = $val;\n return $this;\n }", "title": "" }, { "docid": "189ad1079100503127fd6967c63ba5e3", "score": "0.56930256", "text": "public function setStartTime($time);", "title": "" }, { "docid": "2f3a1a3698faec9e1517cac7f7905467", "score": "0.5691885", "text": "public function getEndTime() {\n return $this->_endTime;\n }", "title": "" }, { "docid": "c57502f07f8e8ca07cf61b05ec5f762b", "score": "0.56862676", "text": "function setEndDateTS($timestamp = 0) {\n\t\tif (is_int($timestamp) && $timestamp > 0) {\n\t\t\t$this->enddate_ts = (int) $timestamp;\n\t\t} else {\n\t\t\t$this->enddate_ts = (int) ((isset($this->startdate_ts) && is_numeric($this->startdate_ts) && $this->startdate_ts > 0) ? ($this->startdate_ts + 3600) : (time() + 3600));\n\t\t} // end if\n\t}", "title": "" }, { "docid": "2a281c9b91620de08c64b5f5bcaf85d3", "score": "0.56771094", "text": "public function setEndDatetimeAttribute($value)\n\t{\n\t\t$current_user_timezone = (User::where('id', \\Auth::id())->first()->timezone);\n\t\t$timestamp = $value;\n\t\t$date = Carbon::createFromFormat('Y-m-d H:i:s', $timestamp, $current_user_timezone)->setTimezone('UTC');\n\t\t$this->attributes['end_datetime'] = $date->toDateTimeString();\n\t}", "title": "" }, { "docid": "973a9dd90dc2379e5d479b274e0b661d", "score": "0.56467235", "text": "public function setTime($time);", "title": "" }, { "docid": "07085fbb4a4fb753be2d85048bad51bd", "score": "0.5571268", "text": "public function setStartTime($startTime) {\n\t\t$this->startTime = $startTime;\n\t}", "title": "" }, { "docid": "360db0afb518d2449d1320a1c9d6abab", "score": "0.55344397", "text": "public function getEndTime() {\n\t\treturn $this->endTime;\n\t}", "title": "" }, { "docid": "62dc772ad010b3d09a15e0c4fed54f14", "score": "0.54963547", "text": "public function setEndTimeTo(\\DateTime $endTimeTo)\n {\n $this->endTimeTo = $endTimeTo;\n return $this;\n }", "title": "" }, { "docid": "b685652cbea032ae3b097d7a96de7d3e", "score": "0.5489915", "text": "public function getEndTime()\n {\n return $this->endTime;\n }", "title": "" }, { "docid": "b685652cbea032ae3b097d7a96de7d3e", "score": "0.5489915", "text": "public function getEndTime()\n {\n return $this->endTime;\n }", "title": "" }, { "docid": "b685652cbea032ae3b097d7a96de7d3e", "score": "0.5489915", "text": "public function getEndTime()\n {\n return $this->endTime;\n }", "title": "" }, { "docid": "7343591eb21d48a947dcb33a432fd56b", "score": "0.54826975", "text": "public function SetLastAccess(\n $in_time = null ///< An epoch time. If not provided, now is used.\n ) {\n // phpcs:enable PSR1.Methods.CamelCapsMethodName.NotCamelCaps\n $this->_last_access = (null != $in_time) ? $in_time : time();\n }", "title": "" }, { "docid": "4ac800933f285031e9204c608f8cbd4d", "score": "0.548111", "text": "public function getEndTimeFormatted() {return substr($this->endTime, 0, 2) . ':' . substr($this->endTime, 2, 2);}", "title": "" }, { "docid": "a6b906beaf557fe9157488f854c7c87c", "score": "0.54658806", "text": "protected function setValidTripEndTime(): int\n {\n return Carbon::now()->addSeconds(Trip::MIN_DELAY_TO_START_DATE)->addHour(6)->timestamp;\n }", "title": "" }, { "docid": "ead7bfd0327d4f0abdecfc98b533644c", "score": "0.5464053", "text": "public function coverageEndTime($coverageEndTime)\n {\n return $this->setProperty('coverageEndTime', $coverageEndTime);\n }", "title": "" }, { "docid": "41444bc2aef90fa3e9560e7f03ebb548", "score": "0.54544723", "text": "public function setEndTime($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Protobuf\\Timestamp::class);\n $this->end_time = $var;\n\n return $this;\n }", "title": "" }, { "docid": "41444bc2aef90fa3e9560e7f03ebb548", "score": "0.54544723", "text": "public function setEndTime($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Protobuf\\Timestamp::class);\n $this->end_time = $var;\n\n return $this;\n }", "title": "" }, { "docid": "41444bc2aef90fa3e9560e7f03ebb548", "score": "0.54544723", "text": "public function setEndTime($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Protobuf\\Timestamp::class);\n $this->end_time = $var;\n\n return $this;\n }", "title": "" }, { "docid": "41444bc2aef90fa3e9560e7f03ebb548", "score": "0.54544723", "text": "public function setEndTime($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Protobuf\\Timestamp::class);\n $this->end_time = $var;\n\n return $this;\n }", "title": "" }, { "docid": "41444bc2aef90fa3e9560e7f03ebb548", "score": "0.54544723", "text": "public function setEndTime($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Protobuf\\Timestamp::class);\n $this->end_time = $var;\n\n return $this;\n }", "title": "" }, { "docid": "41444bc2aef90fa3e9560e7f03ebb548", "score": "0.54544723", "text": "public function setEndTime($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Protobuf\\Timestamp::class);\n $this->end_time = $var;\n\n return $this;\n }", "title": "" }, { "docid": "41444bc2aef90fa3e9560e7f03ebb548", "score": "0.54544723", "text": "public function setEndTime($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Protobuf\\Timestamp::class);\n $this->end_time = $var;\n\n return $this;\n }", "title": "" }, { "docid": "41444bc2aef90fa3e9560e7f03ebb548", "score": "0.54544723", "text": "public function setEndTime($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Protobuf\\Timestamp::class);\n $this->end_time = $var;\n\n return $this;\n }", "title": "" }, { "docid": "71caa5fd7d7421763e9dbaba1160fe37", "score": "0.5449304", "text": "public\r\n function setStertTime($startTime) {\r\n $this->startTime = $startTime;\r\n }", "title": "" }, { "docid": "be8621e3e5ea50cc5ef74b8a69425a8d", "score": "0.5439515", "text": "public function endTime(?string $value): self\n {\n $this->instance->setEndTime($value);\n return $this;\n }", "title": "" }, { "docid": "ccba3021a7e1d613ea7588ccd809bb6a", "score": "0.5432377", "text": "function ibde_update_end_date ($post_id) {\n\n $end_date_tz_string = get_field('timezone', $post_id);\n $output_tz_obj = new DateTimeZone($end_date_tz_string);\n\n $end_date_string = get_field('end_date', $post_id);\n\n if ($end_date_string) {\n $end_date_obj = new DateTime($end_date_string, $output_tz_obj );\n $end_date_obj->setTimezone( new DateTimeZone(\"UTC\") );\n\n $save_end_date_string = $end_date_obj->format('Y-m-d H:i');\n\n update_field('end_date_utc', $save_end_date_string, $post_id);\n }\n}", "title": "" }, { "docid": "3cba63f64588eeed8f86400d9391c20d", "score": "0.54165304", "text": "function setStartEndTime()\n\t{\n\t\t// bail if note create/edit cmd\n\t\tif ( 'create' != $this->cmd && 'edit' != $this->cmd )\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\t// set default start and end time\n\t\t$now\t\t\t\t\t\t= time();\n\n\t\tif ( ! trim( $this->dataArr[ 'starttime' ] ) )\n\t\t{\n\t\t\t$this->dataArr[ 'starttime' ]\t= $now;\n\t\t}\n\n\t\t$start\t\t\t\t\t\t= ( 'create' == $this->cmd )\n\t\t\t\t\t\t\t\t\t\t? $now\n\t\t\t\t\t\t\t\t\t\t: $this->dataArr[ 'starttime' ];\n\t\t$end\t\t\t\t\t\t= ( $this->dataArr[ 'endtime' ] )\n\t\t\t\t\t\t\t\t\t\t? $this->dataArr[ 'endtime' ]\n\t\t\t\t\t\t\t\t\t\t: 0;\n \n\t\t\t\t\t\t\t\t\t\t\n\t\t// set a flag for complimentary professional group.\n\t\t$complimentaryProfessionalGroupID = 4; //from the fe_groups table.\n\t\t$isComplimentaryProfessionalUserGroup = $this->dataArr['usergroup'] \n\t\t\t\t\t\t\t\t\t== $complimentaryProfessionalGroupID; \n\t\t// states\n\t\t// prof below includes complimentary professional group - js \n\t\t\t// create no - new start, no end\n\t\t\t// create prof - new start, new end\n\t\t\t// edit no - keep start, no end\n\t\t\t// edit prof - new start, extend end\n\t\t// check that there's a payment_method\n\t\tif (( preg_match( '#\\b' .$this->conf[ 'paidUsergroup' ] . '\\b#'\n\t\t\t\t, $this->dataArr[ 'usergroup' ] )\n\t\t\t&& '' != $this->dataArr[ 'payment_method' ]\n\t\t) || $isComplimentaryProfessionalUserGroup )\n\t\t{\n\t\t\t$year\t\t\t\t\t= ( 365 * 24 * 60 * 60 );\n\t\t\t$end\t\t\t\t\t= $now + $year;\n\t\t\t$start\t\t\t\t\t= $now;\n\t\t}\n\n\t\t$this->dataArr[ 'starttime' ]\t= $start;\n\t\t$this->dataArr[ 'endtime' ]\t\t= $end;\n\t}", "title": "" }, { "docid": "b024682cbc5deb32d0fffbe459ae6ec5", "score": "0.5388288", "text": "public function getCalendarEndTime();", "title": "" }, { "docid": "d561de3de06fc98596a6e400295f78be", "score": "0.538297", "text": "function get_end_time_object(){\n\t\t$time=new Time;\n\t\t$time->set_time($this->get_duration()+$this->get_start_time());\n\t\treturn $time;\n\t}", "title": "" }, { "docid": "617fc61b9430c522dbd1e544abe28b86", "score": "0.53734624", "text": "public function testRecomputeEndDateTime()\n {\n $track = $this->getMock('SportTrackerConnector\\Workout\\Workout\\Track', array('getTrackPoints'));\n $trackPoints = array(\n $this->getTrackPointMock(null, null, 'now'),\n $this->getTrackPointMock(null, null, '-1 hour'),\n $this->getTrackPointMock(null, null, '2014-01-01 00:00:00'),\n $this->getTrackPointMock(null, null, '2034-01-01 00:00:00')\n );\n $track->expects($this->once())->method('getTrackPoints')->will($this->returnValue($trackPoints));\n\n $actual = $track->getEndDateTime();\n\n $expected = new DateTime('2034-01-01 00:00:00');\n $this->assertEquals($expected, $actual);\n }", "title": "" }, { "docid": "a9eaf9992c3e57f1c0f1ccdf090dc773", "score": "0.536489", "text": "public function getEndTime()\n {\n return $this->EndTime;\n }", "title": "" }, { "docid": "a9eaf9992c3e57f1c0f1ccdf090dc773", "score": "0.536489", "text": "public function getEndTime()\n {\n return $this->EndTime;\n }", "title": "" }, { "docid": "cf5976180ab763dcb67c431ae4fea023", "score": "0.5357885", "text": "function setEndDate($timestamp = 0) {\n\t\tif (is_int($timestamp)) {\n\t\t\t$this->setEndDateTS($timestamp);\n\t\t\t$this->enddate = (string) date('Ymd\\THi00\\Z',$this->enddate_ts);\n\t\t} else {\n\t\t\t$this->enddate = (string) '';\n\t\t} // end if\n\n\t}", "title": "" }, { "docid": "5ac8c31858171a07c5513d5f892e1383", "score": "0.53371185", "text": "public function setEndedTime(?string $endedTime) : self\n {\n $this->endedTime = $endedTime;\n return $this;\n }", "title": "" }, { "docid": "c510089a3c279f9969b6d2e910c0d0ad", "score": "0.533168", "text": "public function getEndTimeTo()\n {\n return $this->endTimeTo;\n }", "title": "" }, { "docid": "7c8390c21bd27521d61c4cc58e0d3e15", "score": "0.5324724", "text": "function setPHPTime($t) \n {\n $this->setTime($t + self::$correction);\n }", "title": "" }, { "docid": "6eb057e5fec4d54659cb6730a71c9919", "score": "0.531424", "text": "public function getEndTime()\n {\n return $this->end;\n }", "title": "" }, { "docid": "d4cefc0746358451317d760c6ecdc6d4", "score": "0.5311754", "text": "private function formatEndTime () {\r\n if($this->carbonEnd != $this->carbonEnd->copy()->startOfHour()) {\r\n return $this->carbonEnd->copy()->startofHour();\r\n }\r\n return $this->carbonEnd;\r\n }", "title": "" }, { "docid": "39e4480ec488b2557904ab23b57b2c92", "score": "0.53077954", "text": "public function testSetendDate()\n {\n\n // New datetime variable\n $today = new DateTime('now');\n\n // new entity\n $admissionPeriod = new AdmissionPeriod();\n\n // Use the setendDate method\n $admissionPeriod->setEndDate($today);\n\n // Assert the result\n $this->assertEquals($today, $admissionPeriod->getEndDate());\n }", "title": "" }, { "docid": "07aabce297758ee00bfa38359079c7d2", "score": "0.5300413", "text": "public function setTime(int $time);", "title": "" }, { "docid": "967711c3337975b1dbe21d8cf820c6fe", "score": "0.52991134", "text": "public function _set_endDate()\n\t{\n\t\t//What method are we use to set the date?\n\t\t$mode = $this->settings->mode; \n\t\t\n\t\tif($mode == 1) //the last N months\n\t\t{\n\t\t\t//get the current date\n\t\t\t$endDate = $this->end_last_n_days();\n\t\t\t\n\t\t\tEvent::$data = $this->active_endDate = $endDate;\n\t\t}\n\t\telseif($mode == 2) //From date N to date M\n\t\t{\n\t\t\t$endDate = $this->end_from_n_to_m();\n\t\t\tEvent::$data = $this->active_endDate = $endDate;\n\t\t}\n\t\telseif($mode == 3) //Make the time span encompass all events\n\t\t{\n\t\t\t$endDate = $this->end_all_reports();\n\t\t\t$endDate = $endDate ? $endDate : time();\n\t\t\tEvent::$data = $this->active_endDate = $endDate;\n\t\t}\n\t\telseif($mode == 4) //Most active month\n\t\t{\n\t\t\t$this->active_endDate = Event::$data;\n\t\t}\n\t\t\n\t}", "title": "" }, { "docid": "3ae1e20bcc77257d13136472f209a88f", "score": "0.52932674", "text": "public function endTime\n\t(\n\t\t$end\t\t// <int> The timestamp of when to end a schedule.\n\t)\t\t\t\t// RETURNS <this>\n\t\n\t// $schedule->endTime($timestamp);\n\t{\n\t\t$this->timeEnd = $end + 0;\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "a3c740081889bf83dd8403caf02af1a7", "score": "0.52884895", "text": "public static function setTime(int $appTime = null): void\n {\n $timeToSet = $appTime ?? time();\n static::$localTime = null;\n if (class_exists(Chronos::class)) {\n static::$appTime = Chronos::createFromTimestampUTC($timeToSet)\n ->setTimezone(new DateTimeZone('UTC'));\n Chronos::setTestNow(static::$appTime);\n } else {\n static::$appTime = DateTimeImmutable::createFromFormat('U', (string) $timeToSet)\n ->setTimezone(new DateTimeZone('UTC'));\n }\n }", "title": "" }, { "docid": "1daa19c6cd27738ad8162a8a2a9b9e29", "score": "0.5280548", "text": "function setEndDate($endDate) {\n\t\t$this->endDate = $endDate;\n\t}", "title": "" }, { "docid": "4be3c24c9099491ee06d0562e84525c3", "score": "0.5279024", "text": "protected function setEndtime($endtime)\n {\n $this->endtime = $endtime;\n\n return $this;\n }", "title": "" }, { "docid": "9fa875cf4871fb6afc69031c6101e0c6", "score": "0.52506435", "text": "function set_start_time($new_start_time){\n\t\t$this->start_time=$new_start_time;\n\t}", "title": "" }, { "docid": "2bb80cb1d061d8c43cd5e23877ca0d9d", "score": "0.524884", "text": "public function getEndTime()\n {\n return $this->end_time;\n }", "title": "" }, { "docid": "2bb80cb1d061d8c43cd5e23877ca0d9d", "score": "0.524884", "text": "public function getEndTime()\n {\n return $this->end_time;\n }", "title": "" }, { "docid": "2bb80cb1d061d8c43cd5e23877ca0d9d", "score": "0.524884", "text": "public function getEndTime()\n {\n return $this->end_time;\n }", "title": "" }, { "docid": "2bb80cb1d061d8c43cd5e23877ca0d9d", "score": "0.524884", "text": "public function getEndTime()\n {\n return $this->end_time;\n }", "title": "" }, { "docid": "2bb80cb1d061d8c43cd5e23877ca0d9d", "score": "0.524884", "text": "public function getEndTime()\n {\n return $this->end_time;\n }", "title": "" }, { "docid": "2bb80cb1d061d8c43cd5e23877ca0d9d", "score": "0.524884", "text": "public function getEndTime()\n {\n return $this->end_time;\n }", "title": "" }, { "docid": "2bb80cb1d061d8c43cd5e23877ca0d9d", "score": "0.524884", "text": "public function getEndTime()\n {\n return $this->end_time;\n }", "title": "" }, { "docid": "2bb80cb1d061d8c43cd5e23877ca0d9d", "score": "0.524884", "text": "public function getEndTime()\n {\n return $this->end_time;\n }", "title": "" }, { "docid": "2bb80cb1d061d8c43cd5e23877ca0d9d", "score": "0.524884", "text": "public function getEndTime()\n {\n return $this->end_time;\n }", "title": "" }, { "docid": "796b97b08a1cdd1d5ae6a8f3936005df", "score": "0.5248494", "text": "public function setTime($time)\n {\n $this->time = $time;\n }", "title": "" }, { "docid": "796b97b08a1cdd1d5ae6a8f3936005df", "score": "0.5248494", "text": "public function setTime($time)\n {\n $this->time = $time;\n }", "title": "" }, { "docid": "4ff3b202bacf8e399b74c911f783f241", "score": "0.52401435", "text": "public function ends(\\DateTime $DateTime)\n {\n $this->End = $DateTime;\n if ($this->Duration) {\n $this->calculateStart();\n }\n }", "title": "" }, { "docid": "32d343dd1d23d83027303c2468191b11", "score": "0.52334195", "text": "function setQueued($inQueued) {\n\t\tif ( $inQueued !== $this->_Queued ) {\n\t\t\tif ( !$inQueued instanceof DateTime ) {\n\t\t\t\t$inQueued = new systemDateTime($inQueued, system::getConfig()->getSystemTimeZone()->getParamValue());\n\t\t\t}\n\t\t\t$this->_Queued = $inQueued;\n\t\t\t$this->setModified();\n\t\t}\n\t\treturn $this;\n\t}", "title": "" }, { "docid": "b7548905278213bd6fcd629ed9a669b5", "score": "0.52329254", "text": "public static function setTime(int $newLimit = 0): void\n {\n self::iniSet('set_time_limit', (string)$newLimit);\n self::iniSet('max_execution_time', (string)$newLimit);\n\n if (self::isFunc('set_time_limit')) {\n \\set_time_limit($newLimit);\n }\n }", "title": "" }, { "docid": "f89dd47b498c59082e9cb9bebc9e3f38", "score": "0.5231471", "text": "public function setTimeElapsed($time){\n\t\t$this->timeElapsed = $time;\n\t}", "title": "" }, { "docid": "4b590af9f33d4eb9fc11f1d247fc15a5", "score": "0.5209018", "text": "public function __setGameTime($gameTime){\n\t$this->gameTime = $gameTime;\n }", "title": "" }, { "docid": "07da55f9156caaf0ffb004557372613c", "score": "0.52086836", "text": "public function setTime($time)\n {\n $this->time = $time;\n }", "title": "" }, { "docid": "d5af3629504dfcdd1de9593ccbf52e6f", "score": "0.52049816", "text": "public function getEndTimeStringAttribute()\n {\n return $this->end_date_time->timezone($this->end_timezone)->toTimeString();\n }", "title": "" }, { "docid": "16c1c3c92d76fcc2e0d5633ef0ff7e48", "score": "0.5195718", "text": "public function setEventTime(string $time) : self;", "title": "" }, { "docid": "724227550c1ef325af526a583c631d4a", "score": "0.51903456", "text": "public function setEndedAtAttribute($value)\n {\n if ($value) {\n $value = Carbon::parse($value)->toDateTimeString();\n }\n\n $this->attributes['ended_at'] = $value;\n }", "title": "" }, { "docid": "22323996a86d164fda60cc3297bb6662", "score": "0.5177573", "text": "public function setTimeEnd(\\DateTime $timeEnd)\n {\n $this->timeEnd = $timeEnd;\n\n return $this;\n }", "title": "" }, { "docid": "c771f0c9b93774aa4ff8dbdc4c98eda9", "score": "0.51711", "text": "public function setStartTime( $startTime )\n {\n $this->_daChallenge->setStartTime( $this->getId(), $startTime );\n }", "title": "" }, { "docid": "6e09d977f8342a6edfeffc21f60bc04e", "score": "0.5170574", "text": "function set_duration($new_duration){\n\t\t$this->duration=$new_duration;\n\t}", "title": "" }, { "docid": "5c088057e638fe7e063aee869a5ece25", "score": "0.51666284", "text": "public function testGetEndDateTimeCallsRecomputeIfDateTimeNotSet()\n {\n $track = $this->getMock('SportTrackerConnector\\Workout\\Workout\\Track', array('recomputeEndDateTime'));\n $track->expects($this->once())->method('recomputeEndDateTime');\n\n $track->getEndDateTime();\n }", "title": "" }, { "docid": "6785b5651db2a844d0c7f2240c18355f", "score": "0.5161595", "text": "public function updateTimeProperties() : void\n {\n $now = new DateTime('now');\n $this->setUpdateDate($now);\n if ( $this->getCreateDate() == null ) {\n $this->setCreateDate($now);\n }\n }", "title": "" } ]
a396baa65e55a3348008b21334fadcbe
Handler of the add_filter( 'studeon_filter_get_css', 'studeon_hovers_get_css', 10, 4 );
[ { "docid": "922b09b0b5f31ab1283ca0868e6bdc7b", "score": "0.6673513", "text": "function studeon_hovers_get_css($css, $colors, $fonts, $scheme='') {\n\t\tif (isset($css['fonts']) && $fonts) {\n\t\t\t$css['fonts'] .= <<<CSS\nCSS;\n\t\t}\n\n\t\tif (isset($css['colors']) && $colors) {\n\t\t\t$css['colors'] .= <<<CSS\n\n/* ================= BUTTON'S HOVERS ==================== */\n\n/* Slide */\n.sc_button_hover_slide_left {\tbackground: linear-gradient(to right,\t{$colors['text_dark']} 50%, {$colors['text_link']} 50%) no-repeat scroll right bottom / 210% 100% {$colors['text_link']} !important; }\n.sc_button_hover_slide_right { background: linear-gradient(to left,\t{$colors['text_dark']} 50%, {$colors['text_link']} 50%) no-repeat scroll left bottom / 210% 100% {$colors['text_link']} !important; }\n.sc_button_hover_slide_top {\tbackground: linear-gradient(to bottom,\t{$colors['text_dark']} 50%, {$colors['text_link']} 50%) no-repeat scroll right bottom / 100% 210% {$colors['text_link']} !important; }\n.sc_button_hover_slide_bottom {\tbackground: linear-gradient(to top,\t\t{$colors['text_dark']} 50%, {$colors['text_link']} 50%) no-repeat scroll right top / 100% 210% {$colors['text_link']} !important; }\n\n.sc_button_hover_style_dark.sc_button_hover_slide_left {\t\tbackground: linear-gradient(to right,\t{$colors['text_link']} 50%, {$colors['text_dark']} 50%) no-repeat scroll right bottom / 210% 100% {$colors['text_dark']} !important; }\n.sc_button_hover_style_dark.sc_button_hover_slide_right {\t\tbackground: linear-gradient(to left,\t{$colors['text_link']} 50%, {$colors['text_dark']} 50%) no-repeat scroll left bottom / 210% 100% {$colors['text_dark']} !important; }\n.sc_button_hover_style_dark.sc_button_hover_slide_top {\t\t\tbackground: linear-gradient(to bottom,\t{$colors['text_link']} 50%, {$colors['text_dark']} 50%) no-repeat scroll right bottom / 100% 210% {$colors['text_dark']} !important; }\n.sc_button_hover_style_dark.sc_button_hover_slide_bottom {\t\tbackground: linear-gradient(to top,\t\t{$colors['text_link']} 50%, {$colors['text_dark']} 50%) no-repeat scroll right top / 100% 210% {$colors['text_dark']} !important; }\n\n.sc_button_hover_style_inverse.sc_button_hover_slide_left {\t\tbackground: linear-gradient(to right,\t{$colors['inverse_link']} 50%, {$colors['text_link']} 50%) no-repeat scroll right bottom / 210% 100% {$colors['text_link']} !important; }\n.sc_button_hover_style_inverse.sc_button_hover_slide_right {\tbackground: linear-gradient(to left,\t{$colors['inverse_link']} 50%, {$colors['text_link']} 50%) no-repeat scroll left bottom / 210% 100% {$colors['text_link']} !important; }\n.sc_button_hover_style_inverse.sc_button_hover_slide_top {\t\tbackground: linear-gradient(to bottom,\t{$colors['inverse_link']} 50%, {$colors['text_link']} 50%) no-repeat scroll right bottom / 100% 210% {$colors['text_link']} !important; }\n.sc_button_hover_style_inverse.sc_button_hover_slide_bottom {\tbackground: linear-gradient(to top,\t\t{$colors['inverse_link']} 50%, {$colors['text_link']} 50%) no-repeat scroll right top / 100% 210% {$colors['text_link']} !important; }\n\n.sc_button_hover_style_hover.sc_button_hover_slide_left {\t\tbackground: linear-gradient(to right,\t{$colors['text_hover']} 50%, {$colors['text_link']} 50%) no-repeat scroll right bottom / 210% 100% {$colors['text_link']} !important; }\n.sc_button_hover_style_hover.sc_button_hover_slide_right {\t\tbackground: linear-gradient(to left,\t{$colors['text_hover']} 50%, {$colors['text_link']} 50%) no-repeat scroll left bottom / 210% 100% {$colors['text_link']} !important; }\n.sc_button_hover_style_hover.sc_button_hover_slide_top {\t\tbackground: linear-gradient(to bottom,\t{$colors['text_hover']} 50%, {$colors['text_link']} 50%) no-repeat scroll right bottom / 100% 210% {$colors['text_link']} !important; }\n.sc_button_hover_style_hover.sc_button_hover_slide_bottom {\t\tbackground: linear-gradient(to top,\t\t{$colors['text_hover']} 50%, {$colors['text_link']} 50%) no-repeat scroll right top / 100% 210% {$colors['text_link']} !important; }\n\n.sc_button_hover_style_alter.sc_button_hover_slide_left {\t\tbackground: linear-gradient(to right,\t{$colors['alter_dark']} 50%, {$colors['alter_link']} 50%) no-repeat scroll right bottom / 210% 100% {$colors['alter_link']} !important; }\n.sc_button_hover_style_alter.sc_button_hover_slide_right {\t\tbackground: linear-gradient(to left,\t{$colors['alter_dark']} 50%, {$colors['alter_link']} 50%) no-repeat scroll left bottom / 210% 100% {$colors['alter_link']} !important; }\n.sc_button_hover_style_alter.sc_button_hover_slide_top {\t\tbackground: linear-gradient(to bottom,\t{$colors['alter_dark']} 50%, {$colors['alter_link']} 50%) no-repeat scroll right bottom / 100% 210% {$colors['alter_link']} !important; }\n.sc_button_hover_style_alter.sc_button_hover_slide_bottom {\t\tbackground: linear-gradient(to top,\t\t{$colors['alter_dark']} 50%, {$colors['alter_link']} 50%) no-repeat scroll right top / 100% 210% {$colors['alter_link']} !important; }\n\n.sc_button_hover_style_alterbd.sc_button_hover_slide_left {\t\tbackground: linear-gradient(to right,\t{$colors['alter_link']} 50%, {$colors['alter_bd_color']} 50%) no-repeat scroll right bottom / 210% 100% {$colors['alter_bd_color']} !important; }\n.sc_button_hover_style_alterbd.sc_button_hover_slide_right {\tbackground: linear-gradient(to left,\t{$colors['alter_link']} 50%, {$colors['alter_bd_color']} 50%) no-repeat scroll left bottom / 210% 100% {$colors['alter_bd_color']} !important; }\n.sc_button_hover_style_alterbd.sc_button_hover_slide_top {\t\tbackground: linear-gradient(to bottom,\t{$colors['alter_link']} 50%, {$colors['alter_bd_color']} 50%) no-repeat scroll right bottom / 100% 210% {$colors['alter_bd_color']} !important; }\n.sc_button_hover_style_alterbd.sc_button_hover_slide_bottom {\tbackground: linear-gradient(to top,\t\t{$colors['alter_link']} 50%, {$colors['alter_bd_color']} 50%) no-repeat scroll right top / 100% 210% {$colors['alter_bd_color']} !important; }\n\n.sc_button_hover_style_alter.sc_button_hover_slide_left:hover,\n.sc_button_hover_style_alter.sc_button_hover_slide_right:hover,\n.sc_button_hover_style_alter.sc_button_hover_slide_top,\n.sc_button_hover_style_alter.sc_button_hover_slide_bottom {\tcolor: {$colors['bg_color']} !important; }\n\n.sc_button_hover_slide_left:hover,\n.sc_button_hover_slide_left.active,\n.ui-state-active .sc_button_hover_slide_left,\n.vc_active .sc_button_hover_slide_left,\n.vc_tta-accordion .vc_tta-panel-title:hover .sc_button_hover_slide_left,\nli.active .sc_button_hover_slide_left {\t\tbackground-position: left bottom !important; color: {$colors['bg_color']} !important; }\n\n.sc_button_hover_slide_right:hover,\n.sc_button_hover_slide_right.active,\n.ui-state-active .sc_button_hover_slide_right,\n.vc_active .sc_button_hover_slide_right,\n.vc_tta-accordion .vc_tta-panel-title:hover .sc_button_hover_slide_right,\nli.active .sc_button_hover_slide_right {\tbackground-position: right bottom !important; color: {$colors['bg_color']} !important; }\n\n.sc_button_hover_slide_top:hover,\n.sc_button_hover_slide_top.active,\n.ui-state-active .sc_button_hover_slide_top,\n.vc_active .sc_button_hover_slide_top,\n.vc_tta-accordion .vc_tta-panel-title:hover .sc_button_hover_slide_top,\nli.active .sc_button_hover_slide_top {\t\tbackground-position: right top !important; color: {$colors['bg_color']} !important; }\n\n.sc_button_hover_slide_bottom:hover,\n.sc_button_hover_slide_bottom.active,\n.ui-state-active .sc_button_hover_slide_bottom,\n.vc_active .sc_button_hover_slide_bottom,\n.vc_tta-accordion .vc_tta-panel-title:hover .sc_button_hover_slide_bottom,\nli.active .sc_button_hover_slide_bottom {\tbackground-position: right bottom !important; color: {$colors['bg_color']} !important; }\n\n\n/* ================= IMAGE'S HOVERS ==================== */\n\n/* Common styles */\n.post_featured .mask {\n\tbackground-color: {$colors['text_dark_07']};\n}\n\n/* Dots */\n.post_featured.hover_dots:hover .mask {\n\tbackground-color: {$colors['text_dark_07']};\n}\n.post_featured.hover_dots .icons span {\n\tbackground-color: {$colors['text_link']};\n}\n.post_featured.hover_dots .post_info {\n\tcolor: {$colors['bg_color']};\n}\n\n/* Icon */\n.post_featured.hover_icon .icons a {\n\tcolor: {$colors['inverse_link']};\n}\n.post_featured.hover_icon a:hover {\n\tcolor: {$colors['accent2']};\n}\n\n/* Icon and Icons */\n.post_featured.hover_icons .icons a {\n\tcolor: {$colors['text_dark']};\n\tbackground-color: {$colors['bg_color_07']};\n}\n.post_featured.hover_icons a:hover {\n\tcolor: {$colors['inverse_link']};\n\tbackground-color: {$colors['bg_color']};\n}\n\n/* Fade */\n.post_featured.hover_fade .post_info,\n.post_featured.hover_fade .post_info a,\n.post_featured.hover_fade .post_info .post_meta_item,\n.post_featured.hover_fade .post_info .post_meta .post_meta_item:before,\n.post_featured.hover_fade .post_info .post_meta .post_meta_item:hover:before {\n\tcolor: {$colors['inverse_link']};\n}\n.post_featured.hover_fade .post_info a:hover {\n\tcolor: {$colors['text_link']};\n}\n\n/* Slide */\n.post_featured.hover_slide .post_info,\n.post_featured.hover_slide .post_info a,\n.post_featured.hover_slide .post_info .post_meta_item,\n.post_featured.hover_slide .post_info .post_meta .post_meta_item:before,\n.post_featured.hover_slide .post_info .post_meta .post_meta_item:hover:before {\n\tcolor: {$colors['inverse_link']};\n}\n.post_featured.hover_slide .post_info a:hover {\n\tcolor: {$colors['text_link']};\n}\n.post_featured.hover_slide .post_info .post_title:after {\n\tbackground-color: {$colors['inverse_link']};\n}\n\n/* Pull */\n.post_featured.hover_pull .post_info,\n.post_featured.hover_pull .post_info a {\n\tcolor: {$colors['inverse_link']};\n}\n.post_featured.hover_pull .post_info a:hover {\n\tcolor: {$colors['text_link']};\n}\n.post_featured.hover_pull .post_info .post_descr {\n\tbackground-color: {$colors['text_dark']};\n}\n\n/* Border */\n.post_featured.hover_border .post_info,\n.post_featured.hover_border .post_info a,\n.post_featured.hover_border .post_info .post_meta_item,\n.post_featured.hover_border .post_info .post_meta .post_meta_item:before,\n.post_featured.hover_border .post_info .post_meta .post_meta_item:hover:before {\n\tcolor: {$colors['inverse_link']};\n}\n.post_featured.hover_border .post_info a:hover {\n\tcolor: {$colors['text_link']};\n}\n.post_featured.hover_border .post_info:before,\n.post_featured.hover_border .post_info:after {\n\tborder-color: {$colors['inverse_link']};\n}\n\n/* Shop */\n.post_featured.hover_shop .icons a {\n\tcolor: {$colors['inverse_link']};\n\tborder-color: {$colors['text_link']} !important;\n\tbackground-color: transparent;\n}\n.post_featured.hover_shop .icons a:hover {\n\tcolor: {$colors['inverse_link']};\n\tborder-color: {$colors['text_link']} !important;\n\tbackground-color: {$colors['text_link']};\n}\n.products.related .post_featured.hover_shop .icons a {\n\tcolor: {$colors['inverse_link']};\n\tborder-color: {$colors['text_link']} !important;\n\tbackground-color: {$colors['text_link']};\n}\n.products.related .post_featured.hover_shop .icons a:hover {\n\tcolor: {$colors['inverse_link']};\n\tborder-color: {$colors['text_link_blend']} !important;\n\tbackground-color: {$colors['text_link_blend']};\n}\n\n/* Shop Buttons */\n.post_featured.hover_shop_buttons .icons .shop_link {\n\tcolor: {$colors['bg_color']};\n\tbackground-color: {$colors['text_dark']};\n}\n.post_featured.hover_shop_buttons .icons a:hover {\n\tcolor: {$colors['inverse_hover']};\n\tbackground-color: {$colors['text_hover']};\n}\nCSS;\n\t\t}\n\t\t\n\t\treturn $css;\n\t}", "title": "" } ]
[ { "docid": "4a5267b0a9c4a321a967be14e315943c", "score": "0.6632933", "text": "function hook_css() {\r\n\t\t\r\n\t\tglobal $table_prefix, $wpdb, $woocommerce;\r\n\t\t\r\n\t\t$blog_title = site_url();\r\n\t\t\r\n\t\t$qry22 = $wpdb->get_results( \"SELECT * FROM `\".$table_prefix.\"apart_setting_p` ORDER BY `id` ASC limit 1\" ,ARRAY_A);\t\r\n\t\t\r\n\t\t$bgcolor = $qry22[0]['bgcolor'];\r\n\t\t\r\n\t\t$textcolor = $qry22[0]['textcolor'];\r\n\t\t\t\t\r\n\t\t$buttoncolor = $qry22[0]['buttoncolor'];\r\n\t\t\r\n\t\t$buttontcolor = $qry22[0]['buttontcolor'];\r\n\r\n\t}", "title": "" }, { "docid": "bf04b3ea4805a4c648f6f3531dc63a53", "score": "0.6152818", "text": "function scholarship_dynamic_styles() {\n\n $scholarship_title_option = get_theme_mod( 'scholarship_title_option', true );\n $scholarship_primary_theme_color = get_theme_mod( 'scholarship_primary_theme_color', '#004b8e' );\n $scholarship_secondary_theme_color = get_theme_mod( 'scholarship_secondary_theme_color', '#f2552c' );\n $scholarship_title_color = get_theme_mod( 'scholarship_title_color', '#004b8e' );\n\n $output_css = '';\n $output_css .=\" a,a:hover,a:focus,a:active,.entry-footer a:hover,.comment-author .fn .url:hover .commentmetadata .comment-edit-link,#cancel-comment-reply-link,#cancel-comment-reply-link:before,.logged-in-as a,.header-elements-holder .top-info::after,.widget hover,.widget a:hover::before,.widget li:hover::before,.widget .widget-title,.scholarship_grid_layout .post-title a:hover,.scholarship_portfolio .single-post-wrapper .portfolio-title-wrapper .portfolio-link,.team-title-wrapper .post-title a:hover,.latest-posts-wrapper .byline a:hover,.latest-posts-wrapper .posted-on a:hover,.latest-posts-wrapper .news-title a:hover,.entry-title a:hover,.entry-meta span a:hover,.post-readmore a:hover,.grid-archive-layout .entry-title a:hover,.widget a:hover, .widget a:hover::before, .widget li:hover::before,.home.blog .archive-content-wrapper .entry-title a:hover {\n color:\". esc_attr( $scholarship_primary_theme_color ) .\";\n }\\n\";\n \n $output_css .=\".navigation .nav-links a:hover,.bttn:hover,button,input[type='button']:hover,input[type='reset']:hover,input[type='submit']:hover,.edit-link .post-edit-link,.reply .comment-reply-link,#masthead .menu-search-wrapper,#site-navigation ul.sub-menu,#site-navigation ul.children,.header-search-wrapper .search-submit,.mt-slider-btn-wrap .slider-btn:hover,.mt-slider-btn-wrap .slider-btn:first-child,.scholarship-slider-wrapper .lSAction>a:hover,.widget_search .search-submit,.team-wrapper .team-desc-wrapper,.site-info,#mt-scrollup,.scholarship_latest_blog .news-more:hover,#site-navigation ul > li:hover > .sub-toggle,#site-navigation ul > li.current-menu-item .sub-toggle,#site-navigation ul > li.current-menu-ancestor .sub-toggle,.error404 .page-title,#primary-menu{\n background: \\\"none\\\";\n }\\n\";\n /*. esc_attr( $scholarship_primary_theme_color ) . !important*/\n \n $output_css .=\".navigation .nav-links a,.bttn,button,input[type='button'],input[type='reset'],input[type='submit'],.header-elements-holder .top-info::after,.mt-slider-btn-wrap .slider-btn:hover,.mt-slider-btn-wrap .slider-btn:first-child,.widget_search .search-submit,.cta-btn-wrap a:hover{\n border-color:\". esc_attr( $scholarship_primary_theme_color ) .\";\n }\\n\";\n \n $output_css .=\".comment-list .comment-body,#masthead .menu-search-wrapper::before,#masthead .menu-search-wrapper::after{\n border-top-color:\". esc_attr( $scholarship_primary_theme_color ) .\";\n }\\n\";\n \n $output_css .=\"#masthead,.site-info:before,.site-info:after,.site-info-wrapper {\n border-bottom-color:\". esc_attr( $scholarship_primary_theme_color ) .\";\n }\\n\";\n \n $output_css .=\"#site-navigation ul li.current-menu-item>a,#site-navigation ul li.current-menu-ancestor>a,#site-navigation ul li:hover>a,#site-navigation ul li.current_page_ancestor>a,#site-navigation ul li.current_page_item>a,#site-navigation ul li.focus>a,.header-search-wrapper .search-submit:hover,.mt-slider-btn-wrap .slider-btn,.mt-slider-btn-wrap .slider-btn:first-child:hover,.widget .scholarship-widget-wrapper .widget-title::before,.widget .scholarship-widget-wrapper .widget-title::after,.cta-btn-wrap a,.scholarship_portfolio .single-post-wrapper .portfolio-title-wrapper .portfolio-link:hover,.scholarship_latest_blog .news-more,#mt-scrollup:hover,#site-navigation ul li a.sub-toggle{\n background:\". esc_attr( $scholarship_secondary_theme_color ) .\";\n }\\n\";\n\n $output_css .=\".scholarship_call_to_action .section-wrapper::before,.scholarship_portfolio .single-post-wrapper .portfolio-title-wrapper,.scholarship_testimonials .section-wrapper::before{\n background:\\\"none\\\";\n }\\n\"; \n\n /*. esc_attr( scholarship_get_hex2rgba( $scholarship_primary_theme_color, '0.9' ) ) .*/\n \n $output_css .=\".header-search-wrapper .search-main:hover,.site-info a:hover{\n color:\". esc_attr( $scholarship_secondary_theme_color ) .\";\n }\\n\";\n \n $output_css .=\".header-search-wrapper .search-submit:hover{\n border-color:\". esc_attr( $scholarship_secondary_theme_color ) .\";\n }\\n\";\n \n $output_css .=\".widget .widget-title{\n border-left-color:\". esc_attr( $scholarship_secondary_theme_color ) .\";\n }\\n\"; \n \n\n if ( $scholarship_title_option == true ) {\n $output_css .=\".site-title a, .site-description {\n color:\". esc_attr( $scholarship_title_color ) .\";\n }\\n\";\n } else {\n $output_css .=\".site-title, .site-description {\n position: absolute;\n clip: rect(1px, 1px, 1px, 1px);\n }\\n\";\n }\n\n $refine_output_css = scholarship_css_strip_whitespace( $output_css );\n\n wp_add_inline_style( 'scholarship-style', $refine_output_css );\n }", "title": "" }, { "docid": "0e01eab270910163c52075c12a9ef8d3", "score": "0.6133052", "text": "function customize_preview_init() {\n\tadd_filter( 'wp_get_custom_css', __NAMESPACE__ . '\\filter_previewed_custom_scss', 10, 2 );\n}", "title": "" }, { "docid": "a6af8891a6f2a0ea68c5cc63c63b926a", "score": "0.61201745", "text": "function studeon_hovers_merge_styles($list) {\n\t\t$list[] = 'includes/theme.hovers/theme.hovers.css';\n\t\treturn $list;\n\t}", "title": "" }, { "docid": "f4b3d0f4b4ad693843ad63ee1b18f591", "score": "0.6053638", "text": "function p3_pinterest_hover_customizer_styles() { ?>\n\t<style>\n\t\t#customize-control-p3_pinterest_hover_image_file img {width: auto;}\n\t</style>\n\t<?php\n}", "title": "" }, { "docid": "1f86276485aff1d14ccac5c30fb099c2", "score": "0.60442984", "text": "function cute_profiles_css() {\r\n\t?>\r\n\t<style type=\"text/css\" media=\"screen\">\r\n\tdiv.cute_profiles_style{\r\n\ttop:<?php global $cute_profiles; echo $cute_profiles['top'];?>px;\r\n\t<?php global $cute_profiles; if (!is_admin()) echo $cute_profiles['align'];?>:0px;\r\n\t}\r\n\t<?php if ($cute_profiles['bg'] == '1') { $cute_profiles_nav_bg = \"transparent\";} else { $cute_profiles_nav_bg = $cute_profiles['bg_color']; } ?>\r\n\t\t\t.cute_profiles_style {background:<?php echo $cute_profiles_nav_bg; ?> !important;}\r\n\t\t\t\r\n\t<?php \r\n\t$cute_profiles_network = $cute_profiles['profiles'];\r\n\tforeach ($cute_profiles_network as $key=>$value) { if ($value['p_num']>'26') {?>\r\n\tdiv.cute_profiles_style a.cute_profiles_<?php echo $cute_profiles['profiles'][$key]['p_num']; ?> {background:url(<?php echo $cute_profiles['profiles'][$key]['icon_url']?>) no-repeat 0 0;background-size:<?php echo $cute_profiles['size'] ?>px <?php echo $cute_profiles['size'] ?>px;}\r\n\t<?php } else { ?>div.cute_profiles_style a.cute_profiles_<?php echo $cute_profiles['profiles'][$key]['p_num']; ?> {background-size:<?php echo $cute_profiles['size'] ?>px <?php echo $cute_profiles['size'] ?>px;}<?php }}?>\r\n\t.cute_profiles_none {display:none;}\r\n\t.cute_profiles_wclass .cute_profiles_style {top: inherit;\r\n\tright: inherit;\r\n\tposition: inherit;padding: 5px 0px 5px 5px;}\r\n\t.cute_profiles_wclass .cute_profiles_i{margin-right: 5px !important;}\r\n\t</style>\r\n\r\n\t<?php\r\n}", "title": "" }, { "docid": "cd485b98240f6cc5718f7afd99bc23c2", "score": "0.59916115", "text": "function bubble_customise_css() { ?>\n\t\n\t<style type=\"text/css\">\n\t\t\n\t\ta:link,\n\t\ta:visited {\n\t\t\tcolor: <?php echo get_theme_mod('bubble_global_link_color'); ?>;\n\t\t}\n\t\t\n\t\t.recent-head,\n\t\t.sidebar-menuitem {\n\t\t\tbackground-color: <?php echo get_theme_mod('bubble_menu_button_color'); ?>;\n\t\t}\n\t\t\n\t\t.editor-pick .recent-blurb {\n\t\t\tbackground-color: <?php echo get_theme_mod('editor_pick_accent'); ?>;\n\t\t}\n\t\t\n\t\t.editor-pick .recent-meta {\n\t\t\tbackground-color: <?php echo get_theme_mod('editor_pick_dark_accent'); ?>;\n\t\t}\n\t\t\n\t\th4.front-full-article-author a {\n\t\t\tbackground-color: <?php echo get_theme_mod('editor_pick_author_accent'); ?>;\n\t\t}\n\t\t\n\t</style>\n\t\n<?php }", "title": "" }, { "docid": "2c39ac030bee465b7632b03f3312d9f0", "score": "0.59910464", "text": "function c9_music_custom_css_output()\n{\n\t$c9music_nav_menu\t\t\t\t\t= esc_html(get_theme_mod('c9music_nav_menu', '#4caab1'));\n\t$c9music_nav_mobile_menu \t\t\t= esc_html(get_theme_mod('c9music_nav_mobile_menu', ''));\n\t$c9music_nav_link\t\t\t\t\t= esc_html(get_theme_mod('c9music_nav_link', ''));\n\t$c9music_nav_dropdown_menu \t\t\t= esc_html(get_theme_mod('c9music_nav_dropdown_menu', ''));\n\t$c9music_nav_link_hover \t\t\t= esc_html(get_theme_mod('c9music_nav_link_hover', ''));\n\t$c9music_nav_dropdown_link \t\t\t= esc_html(get_theme_mod('c9music_nav_dropdown_link', ''));\n\t$c9music_nav_dropdown_link_hover_bg\t= esc_html(get_theme_mod('c9music_nav_dropdown_link_hover_bg', ''));\n\t$c9music_nav_dropdown_link_hover \t= esc_html(get_theme_mod('c9music_nav_dropdown_link_hover', ''));\n\t$c9music_store_notice\t\t\t\t= esc_html(get_theme_mod('c9music_store_notice', ''));\n\t$c9music_store_notice_text\t\t\t= esc_html(get_theme_mod('c9music_store_notice_text', ''));\n\t$c9music_link_hover\t\t\t\t\t= esc_html(get_theme_mod('c9music_link_hover', ''));\n\n\t$c9_music_custom_css \t= '';\n\n\tif (!empty($c9music_link_hover)) {\n\t\t$c9_music_custom_css .= '\n\t\t.wc-block-grid__product-link:hover .wc-block-grid__product-title, .wc-block-grid__product-link:hover .wc-block-grid__product-title:hover,\n\t\t.entry-content a:hover,\n\t\t.widget_nav_menu .menu-item a:hover,\n\t\t.widget_recent_entries a:hover,\n\t\t#wrapper-footer .site-footer a:hover,\n\t\t.c9 .entry-content p>a:not(.wp-block-button__link):hover,\n\t\t.entry-content p>a:not(.wp-block-button__link):not(.nav-tabs):not([class|=c9-share]):not(.c9-smooth):hover,\n\t\t.entry-title a:hover {color: ' . $c9music_link_hover . ';}';\n\t}\n\n\tif (!empty($c9music_nav_mobile_menu)) {\n\t\t$c9_music_custom_css .= '@media only screen and (max-width: 991px) {\n\t\t\t.header-navbar .navbar-small,\n\t\t\t.header-navbar .navbar-collapse,\n\t\t\t.header-navbar .navbar-collapse.show { background-color: ' . $c9music_nav_mobile_menu . ';}}';\n\t}\n\n\tif (!empty($c9music_nav_menu)) {\n\t\t$c9_music_custom_css .= '\n\t\t\t.archive .header-navbar,\n\t\t\t.blog .header-navbar,\n\t\t\t.error404 .header-navbar,\n\t\t\t.header-navbar .navbar-small,\n\t\t\t.search .header-navbar,\n\t\t\t.single-post .header-navbar { background-color: ' . $c9music_nav_menu . ';}\n\t\t\t@media only screen and (max-width: 667px) {\n\t\t\t\t.header-navbar .navbar {\n\t\t\t\t\tbackground-color: ' . $c9music_nav_menu . '\n\t\t\t\t}\n\t\t\t}';\n\t}\n\n\tif (!empty($c9music_nav_dropdown_menu)) {\n\t\t$c9_music_custom_css .= '\n\t\t\t.header-navbar .nav .nav-item .dropdown-menu { background-color: ' . $c9music_nav_dropdown_menu . ';}';\n\t}\n\n\tif (!empty($c9music_nav_link)) {\n\t\t$c9_music_custom_css .= '\n\t\t.navbar-light .navbar-nav .active>.nav-link,\n\t\t.navbar-light .navbar-nav .nav-link.active,\n\t\t.navbar-light .navbar-nav .nav-link.show,\n\t\t.navbar-light .navbar-nav .show>.nav-link,\n\t\t.header-navbar .nav-search .btn-nav-search,\n\t\t.header-navbar .navbar-toggler,\n\t\t.navbar-light .navbar-nav .nav-link,\n\t\t.header-navbar .nav-order .nav-shop-link,\n\t\t.header-navbar .navbar .nav .nav-item .nav-link,\n\t\t.header-navbar .navbar.navbar-small .nav .nav-item.active>.nav-link {color: ' . $c9music_nav_link . ';}';\n\t}\n\n\tif (!empty($c9music_nav_link_hover)) {\n\t\t$c9_music_custom_css .= '\n\t\t.header-navbar .navbar:not(.navbar-small) .nav-link:hover,\n\t\t.header-navbar .dropdown-item:hover,\n\t\t.header-navbar .navbar-toggler:hover,\n\t\t.header-navbar .nav-link:hover,\n\t\t.header-navbar .nav>.nav-item>.nav-link:focus,\n\t\t.header-navbar .nav-search .btn-nav-search:focus,\n\t\t.header-navbar .nav-search .btn-nav-search:hover,\n\t\t.header-navbar .nav-woocommerce .nav-link:hover,\n\t\t.header-navbar .nav-woocommerce .nav-link:focus,\n\t\t.navbar-light .navbar-nav .nav-link:focus,\n\t\t.navbar-light .navbar-nav .nav-link:hover,\n\t\t.header-navbar .navbar:not(.navbar-small) .nav .nav-item.active .nav-link:hover,\n\t\t.header-navbar .navbar:not(.navbar-small) .nav .nav-item .nav-link:hover,\n\t\t.header-navbar .navbar .nav>.nav-item .nav-link:hover,\n\t\t.header-navbar .navbar.navbar-small .nav .nav-item.active>.nav-link:hover,\n\t\t.header-navbar .nav-search .btn-nav-search:focus,\n\t\t.header-navbar .nav-search .btn-nav-search:hover,\n\t\t.header-navbar .nav-search .btn-nav-search:hover .fa-search,\n\t\t.header-navbar .navbar-toggler:focus, .header-navbar .navbar-toggler:hover,\n\t\t.header-navbar .navbar.navbar-light .nav-link:hover .fa {color: ' . $c9music_nav_link_hover . ';}';\n\t}\n\n\tif (!empty($c9music_nav_dropdown_link)) {\n\t\t$c9_music_custom_css .= '\n\t\t\t.header-navbar .dropdown-item,\n\t\t\t.header-navbar .navbar .nav .nav-item .dropdown-item{ color: ' . $c9music_nav_dropdown_link . ';}';\n\t}\n\n\tif (!empty($c9music_nav_dropdown_link_hover_bg)) {\n\t\t$c9_music_custom_css .= '\n\t\t\t.header-navbar .nav .nav-item .dropdown-menu .dropdown-item:hover { background-color: ' . $c9music_nav_dropdown_link_hover_bg . ';}';\n\t}\n\n\tif (!empty($c9music_nav_dropdown_link_hover)) {\n\t\t$c9_music_custom_css .= '\n\t\t\t.header-navbar .nav .nav-item .dropdown-menu .dropdown-item:hover { color: ' . $c9music_nav_dropdown_link_hover . ';}';\n\t}\n\n\tif (!empty($c9music_store_notice)) {\n\t\t$c9_music_custom_css .= '\n\t\t\t.woocommerce-store-notice, p.demo_store { background-color: ' . $c9music_store_notice . ';}';\n\t}\n\n\tif (!empty($c9music_store_notice_text)) {\n\t\t$c9_music_custom_css .= '\n\t\t\t.woocommerce-store-notice, p.demo_store,\n\t\t\t.woocommerce-store-notice, p.demo_store a { color: ' . $c9music_store_notice_text . ';}';\n\t}\n\n\tif (!empty($c9_music_custom_css)) {\n\t\trequire_once(get_template_directory() . '/assets/fonts/class-c9fontstyles.php');\n\n\t\t$c9_music_custom_css_minified = C9FontStyles::minify_css($c9_music_custom_css);\n\t\treturn $c9_music_custom_css_minified;\n\t}\n}", "title": "" }, { "docid": "63a4277acb02eaf7bfbf2d1a8571f657", "score": "0.5989427", "text": "public function woo_shop_hover_style_callback( $styles ) {\n\n\t\t\t$styles['fade'] = __( 'Fade', 'astra-addon' );\n\t\t\t$styles['zoom'] = __( 'Zoom', 'astra-addon' );\n\t\t\t$styles['zoom-fade'] = __( 'Zoom Fade', 'astra-addon' );\n\n\t\t\treturn $styles;\n\t\t}", "title": "" }, { "docid": "7a0950b431d243d054926a5e6921b874", "score": "0.59755206", "text": "public function filter_For_CSS($input){\r\n\t\t$this->filter_it($input, 4);\r\n\t\treturn $this->output;\r\n\t}", "title": "" }, { "docid": "ed4bfb114becd685708e6617f2564723", "score": "0.59387887", "text": "function studeon_hovers_frontend_scripts() {\n\t\tif ( studeon_is_on(studeon_get_theme_option('debug_mode')) && studeon_get_file_dir('includes/theme.hovers/theme.hovers.js')!='' )\n\t\t\twp_enqueue_script( 'studeon-hovers', studeon_get_file_url('includes/theme.hovers/theme.hovers.js'), array('jquery'), null, true );\n\t\tif ( studeon_is_on(studeon_get_theme_option('debug_mode')) && studeon_get_file_dir('includes/theme.hovers/theme.hovers.css')!='' )\n\t\t\twp_enqueue_style( 'studeon-hovers', studeon_get_file_url('includes/theme.hovers/theme.hovers.css'), array(), null );\n\t}", "title": "" }, { "docid": "6261ad284bf84d6604a6d62d09746cef", "score": "0.5924011", "text": "function hi_frontend_hooks() {\n\tadd_action( 'wp_footer', 'hi_theme_styles', 100 );\n\tadd_filter( 'post_thumbnail_html', 'hi_post_thumbnail_html', 10, 5 );\n\tadd_action( 'wp_print_styles', 'hi_assets' );\n}", "title": "" }, { "docid": "cd5e91c65f68faa88ce342a4263f04dc", "score": "0.58912903", "text": "function cmsmasters_theme_social_icons_styles() {\n\t$cmsmasters_option = cmsmasters_get_global_options();\n\t\n\t$out = '';\n\t\n\t$i = 1;\n\t\n\t\n\tforeach ($cmsmasters_option[CMSMASTERS_SHORTNAME . '_social_icons'] as $cmsmasters_social_icons) {\n\t\t$cmsmasters_social_icon = explode('|', str_replace(' ', '', $cmsmasters_social_icons));\n\t\t\n\t\t\n\t\tif (isset($cmsmasters_social_icon[4]) && $cmsmasters_social_icon[4] != '') {\n\t\t\t$out .= \"\n\t\n\t#page .cmsmasters_social_icon_color.cmsmasters_social_icon_{$i} {\n\t\tbackground-color:{$cmsmasters_social_icon[4]};\n\t}\n\t\";\n\t\t}\n\t\t\n\t\t\n\t\tif (isset($cmsmasters_social_icon[5]) && $cmsmasters_social_icon[5] != '') {\n\t\t\t$out .= \"\n\t\n\t#page .cmsmasters_social_icon_color.cmsmasters_social_icon_{$i}:hover {\n\t\tbackground-color:{$cmsmasters_social_icon[5]};\n\t}\";\n\t\t}\n\t\t\n\t\t\n\t\t$i++;\n\t}\n\t\n\t\n\treturn $out;\n}", "title": "" }, { "docid": "bf100448160d922abccf40433578a9d2", "score": "0.58839756", "text": "function crypton_blog_trx_addons_prepare_css($css='', $remove_spaces=true) {\n\t\treturn apply_filters( 'trx_addons_filter_prepare_css', $css, $remove_spaces );\n\t}", "title": "" }, { "docid": "3f8b8b2d3b167190dbad65d82ea61601", "score": "0.5818297", "text": "function ogf_output_css() {\n\t?>\n\t<!-- Fonts Plugin CSS - https://fontsplugin.com/ -->\n\t<style>\n\t\t<?php\n\n\t\tdo_action( 'ogf_inline_styles' );\n\n\t\tforeach ( ogf_get_elements() as $id => $values ) {\n\t\t\togf_generate_css( $values['selectors'], $id );\n\t\t}\n\t\tforeach ( ogf_get_custom_elements() as $id => $values ) {\n\t\t\togf_generate_css( $values['selectors'], $id );\n\t\t}\n\t\t?>\n\t</style>\n\t<!-- Fonts Plugin CSS -->\n\t<?php\n}", "title": "" }, { "docid": "667ffe2226625d7ec91e6c9e8a036902", "score": "0.58174026", "text": "function filter_previewed_custom_scss( $css ) {\n\tglobal $wp_customize;\n\n\t$preprocessor_setting = $wp_customize->get_setting( 'custom_css_preprocessor' );\n\tif ( $preprocessor_setting && 'scss' === $preprocessor_setting->value() ) {\n\t\t$css = transpile_scss( $css );\n\t}\n\treturn $css;\n}", "title": "" }, { "docid": "f00b0e08c8d1187cf4c1623847db9159", "score": "0.58000994", "text": "function lenora_insert_custom_color() {\n\t$options = lenora_get_theme_options();\n\t$custom_color = esc_html( $options['custom_color'] );\n\n\t$default_options = lenora_get_default_theme_options();\n\n?>\n\t<style>\n\t\t\n\t\ta:hover, a:active, .widget li a:hover, .widget li a:active, .tagcloud a:hover {color: <?php echo $custom_color; ?>!important;}\n\t\t\t#search_submit:hover, input#submit:hover {background-color: <?php echo $custom_color; ?>!important;}\n\t\t\t.reply a:hover, .reply a:focus, .reply a:active {background-color: <?php echo $custom_color; ?>!important;}\n#comments .nav-previous a:hover, #comments .nav-next a:hover, #comments .nav-next a:focus, #comments .nav-previous a:focus, #comments .nav-previous a:active, #comments .nav-next a:active {background-color: <?php echo $custom_color; ?>!important;}\t\t\t\n\t\t\t#content #nav-below .nav-previous a:hover, #content #nav-below .nav-next a:hover, #content #nav-below .nav-previous a:focus, #content #nav-below .nav-next a:focus, #content #nav-below .nav-previous a:active, #content #nav-below .nav-next a:active, #nav-posts .nav-previous a:hover, #nav-posts .nav-next a:hover, #nav-posts .nav-previous a:focus, #nav-posts .nav-next a:focus, #nav-posts .nav-previous a:active, #nav-posts .nav-next a:active {background-color: <?php echo $custom_color; ?>!important;}\n#branding #main-menu ul ul a:hover, #branding #main-menu ul ul ul a:hover {color: <?php echo $custom_color; ?>!important;}\t\n#wpadminbar .quicklinks .menupop ul li a,#wpadminbar .quicklinks .menupop ul li a strong,#wpadminbar .quicklinks .menupop.hover ul li a, #wpadminbar.nojs .quicklinks .menupop:hover ul li a {color: #21759B!important;}\t\t\t\n#wpadminbar * {color: #CCCCCC!important;}\n#wpadminbar.nojs .ab-top-menu > li.menupop:hover > .ab-item, #wpadminbar .ab-top-menu > li.menupop.hover > .ab-item {\tcolor: #333!important;}\t\t\t\t\t\t\t\n\t\t\t\n\t</style>\n<?php\n}", "title": "" }, { "docid": "2495fb0c0819d393b7930da157889001", "score": "0.57820225", "text": "function px_custom_styles() {\n\t\tglobal $px_theme_option;\n\t\t$header_bg_color = $nav_bg_color = $nav_color = '';\n\t\tif ( isset($_POST['style_sheet']) ) {\n\t\t\t$_SESSION['kcsess_style_sheet'] = $_POST['style_sheet'];\n\t\t\t$px_color_scheme = $_SESSION['kcsess_style_sheet'];\n\t\t}\n\t\t\n\t\telseif (isset($_SESSION['kcsess_style_sheet']) and $_SESSION['kcsess_style_sheet'] <> '') {\n\t\t\t$px_color_scheme = $_SESSION['kcsess_style_sheet'];\n\t\t} else {\n\t\t\t$px_color_scheme = $px_theme_option['custom_color_scheme'];\n\t\t}\n\t\tif(isset($px_theme_option['header_bg_color']) && $px_theme_option['header_bg_color'] <> ''){\n\t\t\t$header_bg_color = $px_theme_option['header_bg_color'];\n\t\t}\n\t\tif(isset($px_theme_option['nav_bg_color']) && $px_theme_option['nav_bg_color'] <> ''){\n\t\t\t$nav_bg_color = $px_theme_option['nav_bg_color'];\n\t\t}\n\t\tif(isset($px_theme_option['nav_color']) && $px_theme_option['nav_color'] <> ''){\n\t\t\t$nav_color = $px_theme_option['nav_color'];\n\t\t}\n\t\t\n\t\t?>\n\t\t<style type=\"text/css\">\n\t\t.pix-colr, .pix-colrhvr:hover,.price-table article:hover h3,.breadcrumbs ul li.pix-active,#footer p a:hover,.is-countdown span:before,.pagination .active,\n/* New Clases Add*/.event-listing article:hover .text .pix-post-title a,.cs-post-title a,.pagination .active,.blog-medium-options li a,.is-countdown span,.widget ul li:hover a { color:<?php echo $px_color_scheme; ?> !important;\n\t\t}\n\t\t.pix-bgcolr,.pix-bgcolrhvr:hover,nav.navigation > ul > li > a:before,.cart-sec span,.navigation ul ul li:hover > a,.navigation ul > li.current-menu-item > a,\n\t\t.navigation ul ul li.current-menu-item > a,.price-table article:hover .pix-price-box, .event.evevt-listing article:hover .text .btn-boobked, .match-result.match-lost p,.event.event-listing.event-listing-v2 article:hover,.cycle-pager-active,.widget .tagcloud a:hover, .event.event-listing article:hover .text .btn-boobked, .flex-direction-nav li a:hover /**/, .our-team-sec article:hover figure figcaption .pix-post-title a,.footer-widget .widget_newsletter .error,.news-section article:hover .text,.password_protected form input[type=\"submit\"],.team-vertical article figcaption .caption h2,\n#respond form input[type=\"submit\"],#wp-calendar caption,.gallery ul li figure figcaption a,.woocommerce-pagination ul li a:hover,.woocommerce-pagination ul li span,.woocommerce-tabs .tabs .active a, span.match-category.cat-neutral, .event.event-listing article:hover .text .btn,.widget_search form input[type=\"submit\"], .woocommerce .button,.onsale,.gallery ul li:hover .text,.footer-icons .followus a:hover,\n/* New Clases Add*/.searchform button,.tabs.horizontal .nav-tabs li.active a,p.stars span a.active,.event.event-listing.event-listing-v2 .btn-viewall,.featured-title,\n.pix-feature article .blog-bottom .btn,.pix-feature .featured,.blog-vertical .tab-content header.pix-heading-title h2,header #lang_sel a:hover, header #lang_sel ul ul a:hover,\n.post-tags a:hover,.blog-vertical header.pix-heading-title h2,.pix-tittle,nav.navigation > ul > li:hover > a, nav.navigation > ul > li.current-menu-ancestor > a,.table tbody tr:hover,.widget_newsletter label .btn{\n\t\t\tbackground-color:<?php echo $px_color_scheme; ?> !important;\n\t\t}\n\t\t.pix-bdrcolr ,.tabs.horizontal .nav-tabs li.active,.address-info .text,.subtitle h1,.about-us article .text,blockquote,\n\t\t.pagination > ul > li > a:before,.pagination > ul > li > a:before,.pagination > ul > li > span.active:before,.footer-icons .followus a:hover{\n\t\t\tborder-color:<?php echo $px_color_scheme; ?> !important;\n\t\t}\n\t\t#banner .flexslider figcaption .pix-desc h3 span {\n\t\t box-shadow: -10px 0 0 <?php echo $px_color_scheme; ?>,10px 0 0 <?php echo $px_color_scheme; ?> !important; \n \t\t}\n\t\t.our-team-sec article:hover figure figcaption .pix-post-title a{\n\t\t\t box-shadow: -10px 0 0 <?php echo $px_color_scheme; ?>,10px 0 0 <?php echo $px_color_scheme; ?> !important; \n\t\t}\n\t\theader#header .top-head{\n\t\t\tbackground-color:<?php echo $header_bg_color; ?> !important;\n\t\t}\n\t\tnav.navigation > ul > li > a\n\t\t{\n\t\t\tcolor:<?php echo $nav_color; ?> !important;\n\t\t}\n\t\theader #mainheader{\n\t\t\tbackground-color:<?php echo $nav_bg_color; ?> !important;\n\t\t}\n\t\t.sliderpagination ul li:before{\n\t\t\tborder-color: transparent <?php echo $px_color_scheme; ?> !important;\n\t\t}\n\t\t.footer-widget .widget_newsletter .error:before{\n\t\t\tborder-top-color: <?php echo $px_color_scheme; ?> !important;\n\t\t}\n\t\t</style>\n\t\t<?php \n\t}", "title": "" }, { "docid": "8c8310a32f6ae25f86f3f151874a5e16", "score": "0.57794803", "text": "function mise_custom_css_styles() {\r\n\t\techo '<style id=\"mise-custom-css\">';\r\n\t\t$headBackColor = mise_options('_header_background_color', '#404040');\r\n\t\t$headTextColor = mise_options('_header_text_color', '#ffffff');\r\n\t\t$contentBackColor = mise_options('_content_background_color', '#ffffff');\r\n\t\t$contentTextColor = mise_options('_content_text_color', '#404040');\r\n\t\t$contentLinkColor = mise_options('_content_link_color', '#7dc771');\r\n\t\t$contentBorderColor = mise_options('_content_border_color', '#eaeaea');\r\n\t\t$sidebarClassicBackColor = mise_options('_classic_sidebar_background_color', '#f9f9f9');\r\n\t\t$sidebarPushBackColor = mise_options('_push_sidebar_background_color', '#ffffff');\r\n\t\t$footerBackColor = mise_options('_footer_background_color', '#404040');\r\n\t\t$footerTextColor = mise_options('_footer_text_color', '#afafaf');\r\n\t\t$footerLinkColor = mise_options('_footer_link_color', '#f7f7f7');\r\n\t\t\t/* Link Color */\r\n\t\t\tif (!empty($contentLinkColor)) {\r\n\t\t\t\tlist($r, $g, $b) = sscanf($contentLinkColor, '#%02x%02x%02x');\r\n\t\t\t\t?>\r\n\t\t\t\t\tbutton,\r\n\t\t\t\t\tinput[type=\"button\"],\r\n\t\t\t\t\tinput[type=\"reset\"],\r\n\t\t\t\t\tinput[type=\"submit\"],\r\n\t\t\t\t\t.site-main .navigation.pagination .nav-links .page-numbers,\r\n\t\t\t\t\t.woocommerce-pagination .page-numbers li .page-numbers,\r\n\t\t\t\t\t#wp-calendar > caption,\r\n\t\t\t\t\t.tags-links a, .tagcloud a, .entry-theContent .single-cat a, .page-links .page-links-number,\r\n\t\t\t\t\t.miseButton a,\r\n\t\t\t\t\t.content-area .onsale,\r\n\t\t\t\t\t.woocommerce .wooImage .button,\r\n\t\t\t\t\t.woocommerce .wooImage .added_to_cart,\r\n\t\t\t\t\t.woocommerce-error li a,\r\n\t\t\t\t\t.woocommerce-message a,\r\n\t\t\t\t\t.return-to-shop a,\r\n\t\t\t\t\t.wc-proceed-to-checkout .button.checkout-button,\r\n\t\t\t\t\t.widget_shopping_cart p.buttons a,\r\n\t\t\t\t\t.woocommerce .wishlist_table td.product-add-to-cart a,\r\n\t\t\t\t\t.woocommerce .content-area .woocommerce-tabs .tabs li.active a,\r\n\t\t\t\t\t.widget_price_filter .ui-slider .ui-slider-range,\r\n\t\t\t\t\t.widget_price_filter .ui-slider .ui-slider-handle,\r\n\t\t\t\t\t.flexslider .miseSliderButton .miseButtonSingle a,\r\n\t\t\t\t\t.menu-toggle:hover, .menu-toggle:focus, .menu-toggle:active,\r\n\t\t\t\t\theader.site-header .crestaMenuButton {\r\n\t\t\t\t\t\tbackground: <?php echo esc_html($contentLinkColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\ta, a:visited,\r\n\t\t\t\t\t.main-navigation .current_page_item > a,\r\n\t\t\t\t\t.main-navigation .current-menu-item > a,\r\n\t\t\t\t\t.main-navigation .current_page_ancestor > a,\r\n\t\t\t\t\t.main-navigation .current-menu-ancestor > a,\r\n\t\t\t\t\t.main-navigation > div > ul li:hover > a, \r\n\t\t\t\t\t.main-navigation > div > ul li.focus > a,\r\n\t\t\t\t\tbody.page-template-template-onepage .main-navigation > div > ul li:hover > a, \r\n\t\t\t\t\tbody.page-template-template-onepage .main-navigation > div > ul li.focus > a,\r\n\t\t\t\t\tbody.page-template-template-onepage .main-navigation > div > ul > .current > a,\r\n\t\t\t\t\t.woocommerce ul.products > li .price,\r\n\t\t\t\t\t.woocommerce div.product .summary .price {\r\n\t\t\t\t\t\tcolor: <?php echo esc_html($contentLinkColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\tblockquote,\r\n\t\t\t\t\tinput[type=\"text\"]:focus,\r\n\t\t\t\t\tinput[type=\"email\"]:focus,\r\n\t\t\t\t\tinput[type=\"url\"]:focus,\r\n\t\t\t\t\tinput[type=\"password\"]:focus,\r\n\t\t\t\t\tinput[type=\"search\"]:focus,\r\n\t\t\t\t\tinput[type=\"number\"]:focus,\r\n\t\t\t\t\tinput[type=\"tel\"]:focus,\r\n\t\t\t\t\tinput[type=\"range\"]:focus,\r\n\t\t\t\t\tinput[type=\"date\"]:focus,\r\n\t\t\t\t\tinput[type=\"month\"]:focus,\r\n\t\t\t\t\tinput[type=\"week\"]:focus,\r\n\t\t\t\t\tinput[type=\"time\"]:focus,\r\n\t\t\t\t\tinput[type=\"datetime\"]:focus,\r\n\t\t\t\t\tinput[type=\"datetime-local\"]:focus,\r\n\t\t\t\t\tinput[type=\"color\"]:focus,\r\n\t\t\t\t\ttextarea:focus,\r\n\t\t\t\t\t.main-navigation > div > ul > .current_page_item > a,\r\n\t\t\t\t\t.main-navigation > div > ul > .current-menu-item > a,\r\n\t\t\t\t\t.main-navigation > div > ul > .current_page_ancestor > a,\r\n\t\t\t\t\t.main-navigation > div > ul > .current-menu-ancestor > a,\r\n\t\t\t\t\t.site-main .navigation.pagination .nav-links .page-numbers.current,\r\n\t\t\t\t\t.woocommerce-pagination .page-numbers li .current.page-numbers,\r\n\t\t\t\t\t#wp-calendar tbody td#today,\r\n\t\t\t\t\t.page-links > .page-links-number,\r\n\t\t\t\t\t.woocommerce ul.products > li h2:after,\r\n\t\t\t\t\t.mLoader1 {\r\n\t\t\t\t\t\tborder-color: <?php echo esc_html($contentLinkColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\tfooter.site-footer {\r\n\t\t\t\t\t\tborder-top-color: <?php echo esc_html($contentLinkColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t.entry-featuredImg .insideImage {\r\n\t\t\t\t\t\tbackground: rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,0.9);\r\n\t\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\t/* Footer Link Color */\r\n\t\t\tif (!empty($footerLinkColor)) {\r\n\t\t\t\t?>\r\n\t\t\t\t\tfooter.site-footer a {\r\n\t\t\t\t\t\tcolor: <?php echo esc_html($footerLinkColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\t/* Header Background Color */\r\n\t\t\tif (!empty($headBackColor)) {\r\n\t\t\t\tlist($r, $g, $b) = sscanf($headBackColor, '#%02x%02x%02x');\r\n\t\t\t\t?>\r\n\t\t\t\t\t.miseImageOp, .flexslider .slides > li .flexText {\r\n\t\t\t\t\t\tbackground-color: rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,0.4);\r\n\t\t\t\t\t}\r\n\t\t\t\t\theader.site-header {\r\n\t\t\t\t\t\tbackground: rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,0.0);\r\n\t\t\t\t\t}\r\n\t\t\t\t\theader.site-header.menuMinor, header.site-header.noImage, header.site-header.noTransparent {\r\n\t\t\t\t\t\tbackground: rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,1);\r\n\t\t\t\t\t}\r\n\t\t\t\t\t.main-navigation ul ul a {\r\n\t\t\t\t\t\tbackground: <?php echo esc_html($headBackColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\tsection.mise_slider.reverse .flexslider .slides > li .flexText .inside h2::first-letter,\r\n\t\t\t\t\t.miseBigText header.entry-header.reverse h1::first-letter {\r\n\t\t\t\t\t\tcolor: <?php echo esc_html($headBackColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t.flex-direction-nav a {\r\n\t\t\t\t\t\tcolor: <?php echo esc_html($headBackColor); ?> !important;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t@media all and (max-width: 1025px) {\r\n\t\t\t\t\t\t.main-navigation.toggled .nav-menu {\r\n\t\t\t\t\t\t\tbackground: <?php echo esc_html($headBackColor); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\theader.site-header {\r\n\t\t\t\t\t\t\tbackground: rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,1) !important;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\t/* Header Text Color */\r\n\t\t\tif (!empty($headTextColor)) {\r\n\t\t\t\t?>\r\n\t\t\t\t\t.main-navigation a, .miseBigText header.entry-header a, .site-branding .site-title a, header.site-header, .flexslider .slides > li .flexText .inside,\r\n\t\t\t\t\t.miseBigText header.entry-header, .menu-toggle, .menu-toggle:hover, .menu-toggle:focus, .menu-toggle:active, header.site-header .crestaMenuButton a {\r\n\t\t\t\t\t\tcolor: <?php echo esc_html($headTextColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\theader.site-header .crestaMenuButton:hover a,\r\n\t\t\t\t\theader.site-header .crestaMenuButton:active a,\r\n\t\t\t\t\theader.site-header .crestaMenuButton:focus a {\r\n\t\t\t\t\t\tcolor: <?php echo esc_html($headTextColor); ?> !important;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t.flex-direction-nav a {\r\n\t\t\t\t\t\tbackground: <?php echo esc_html($headTextColor); ?> !important;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t.mouse-wheel, .handle, .hamburger span, section.mise_slider.reverse .flexslider .slides > li .flexText .inside h2::first-letter,\r\n\t\t\t\t\t.miseBigText header.entry-header.reverse h1::first-letter {\r\n\t\t\t\t\t\tbackground: <?php echo esc_html($headTextColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t.circle {\r\n\t\t\t\t\t\tborder: 2px solid <?php echo esc_html($headTextColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t.scrollDown {\r\n\t\t\t\t\t\tborder-color: <?php echo esc_html($headTextColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\t/* Border Color */\r\n\t\t\tif (!empty($contentBorderColor)) {\r\n\t\t\t\t?>\r\n\t\t\t\t\tinput[type=\"text\"],\r\n\t\t\t\t\tinput[type=\"email\"],\r\n\t\t\t\t\tinput[type=\"url\"],\r\n\t\t\t\t\tinput[type=\"password\"],\r\n\t\t\t\t\tinput[type=\"search\"],\r\n\t\t\t\t\tinput[type=\"number\"],\r\n\t\t\t\t\tinput[type=\"tel\"],\r\n\t\t\t\t\tinput[type=\"range\"],\r\n\t\t\t\t\tinput[type=\"date\"],\r\n\t\t\t\t\tinput[type=\"month\"],\r\n\t\t\t\t\tinput[type=\"week\"],\r\n\t\t\t\t\tinput[type=\"time\"],\r\n\t\t\t\t\tinput[type=\"datetime\"],\r\n\t\t\t\t\tinput[type=\"datetime-local\"],\r\n\t\t\t\t\tinput[type=\"color\"],\r\n\t\t\t\t\ttextarea,\r\n\t\t\t\t\tselect,\r\n\t\t\t\t\t#wp-calendar tbody td,\r\n\t\t\t\t\t.site-social a,\r\n\t\t\t\t\t#comments ol .pingback,\r\n\t\t\t\t\t#comments ol article,\r\n\t\t\t\t\t#comments .reply,\r\n\t\t\t\t\t.woocommerce ul.products > li,\r\n\t\t\t\t\t.woocommerce .product_meta,\r\n\t\t\t\t\t.woocommerce .single_variation,\r\n\t\t\t\t\t.woocommerce #reviews #comments ol.commentlist li .comment-text,\r\n\t\t\t\t\t.woocommerce p.stars a.star-1,\r\n\t\t\t\t\t.woocommerce p.stars a.star-2,\r\n\t\t\t\t\t.woocommerce p.stars a.star-3,\r\n\t\t\t\t\t.woocommerce p.stars a.star-4,\r\n\t\t\t\t\t.single-product div.product .woocommerce-product-rating,\r\n\t\t\t\t\t.woocommerce-page .entry-content table,\r\n\t\t\t\t\t.woocommerce-page .entry-content table thead th,\r\n\t\t\t\t\t.woocommerce-page .entry-content table tbody td,\r\n\t\t\t\t\t.woocommerce-page .entry-content table td, .woocommerce-page .entry-content table th,\r\n\t\t\t\t\t#order_review, #order_review_heading,\r\n\t\t\t\t\t#payment,\r\n\t\t\t\t\t#payment .payment_methods li,\r\n\t\t\t\t\t.widget_shopping_cart p.total,\r\n\t\t\t\t\taside ul.menu .indicatorBar,\r\n\t\t\t\t\taside ul.product-categories .indicatorBar,\r\n\t\t\t\t\t.mise-breadcrumbs,\r\n\t\t\t\t\t.rank-math-breadcrumb,\r\n\t\t\t\t\tul.woocommerce-thankyou-order-details li,\r\n\t\t\t\t\t.woocommerce-MyAccount-navigation ul li {\r\n\t\t\t\t\t\tborder-color: <?php echo esc_html($contentBorderColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\thr, #wp-calendar th {\r\n\t\t\t\t\t\tbackground-color: <?php echo esc_html($contentBorderColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t.site-main .post-navigation,\r\n\t\t\t\t\taside ul li,\r\n\t\t\t\t\taside ul.menu li a,\r\n\t\t\t\t\taside ul.product-categories li a,\r\n\t\t\t\t\t.hentry header.entry-header,\r\n\t\t\t\t\tfooter.entry-footer,\r\n\t\t\t\t\tbody.hfeed #content.site-content article,\r\n\t\t\t\t\theader.page-header {\r\n\t\t\t\t\t\tborder-bottom-color: <?php echo esc_html($contentBorderColor); ?>;\r\n\t\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\t/* Content Background Color */\r\n\t\t\tif (!empty($contentBackColor)) {\r\n\t\t\t\t?>\r\n\t\t\t\tbutton,\r\n\t\t\t\tinput[type=\"button\"],\r\n\t\t\t\tinput[type=\"reset\"],\r\n\t\t\t\tinput[type=\"submit\"],\r\n\t\t\t\t.site-main .navigation.pagination .nav-links .page-numbers,\r\n\t\t\t\t.woocommerce-pagination .page-numbers li .page-numbers,\r\n\t\t\t\t#wp-calendar > caption,\r\n\t\t\t\t.hentry header.entry-header.reverse h1::first-letter,\r\n\t\t\t\t.tags-links a, .tagcloud a, .entry-theContent .single-cat a, .page-links .page-links-number,\r\n\t\t\t\t.entry-featuredImg .insideImage span a,\r\n\t\t\t\t.miseButton a,\r\n\t\t\t\t#toTop,\r\n\t\t\t\t.wp-caption-text,\r\n\t\t\t\t.woocommerce .wooImage .button,\r\n\t\t\t\t.woocommerce .wooImage .added_to_cart,\r\n\t\t\t\t.woocommerce-error li a,\r\n\t\t\t\t.woocommerce-message a,\r\n\t\t\t\t.return-to-shop a,\r\n\t\t\t\t.wc-proceed-to-checkout .button.checkout-button,\r\n\t\t\t\t.widget_shopping_cart p.buttons a,\r\n\t\t\t\t.woocommerce .wishlist_table td.product-add-to-cart a,\r\n\t\t\t\t.woocommerce .content-area .woocommerce-tabs .tabs li.active a,\r\n\t\t\t\t.woocommerce ul.products > li:hover .wooImage .button,\r\n\t\t\t\t.woocommerce ul.products > li:hover .wooImage .added_to_cart,\r\n\t\t\t\t.woocommerce-error li a:hover,\r\n\t\t\t\t.woocommerce-message a:hover,\r\n\t\t\t\t.return-to-shop a:hover,\r\n\t\t\t\t.wc-proceed-to-checkout .button.checkout-button:hover,\r\n\t\t\t\t.widget_shopping_cart p.buttons a:hover,\r\n\t\t\t\t.widget_price_filter .price_slider_amount .button,\r\n\t\t\t\t.woocommerce div.product form.cart .button,\r\n\t\t\t\t.tags-links a:hover,\r\n\t\t\t\t.tags-links a:focus,\r\n\t\t\t\t.tags-links a:active,\r\n\t\t\t\t.tagcloud a:hover,\r\n\t\t\t\t.tagcloud a:focus,\r\n\t\t\t\t.tagcloud a:active,\r\n\t\t\t\t.entry-theContent .single-cat a:hover,\r\n\t\t\t\t.entry-theContent .single-cat a:focus,\r\n\t\t\t\t.entry-theContent .single-cat a:active,\r\n\t\t\t\t.site-main .navigation.pagination .nav-links a:hover,\r\n\t\t\t\t.site-main .navigation.pagination .nav-links a:focus,\r\n\t\t\t\t.site-main .navigation.pagination .nav-links a:active,\r\n\t\t\t\t.woocommerce-pagination .page-numbers li a:hover,\r\n\t\t\t\t.woocommerce-pagination .page-numbers li a:focus,\r\n\t\t\t\t.woocommerce-pagination .page-numbers li a:active,\r\n\t\t\t\t.page-links a .page-links-number:hover,\r\n\t\t\t\t.page-links a .page-links-number:focus,\r\n\t\t\t\t.page-links a .page-links-number:active,\r\n\t\t\t\t.flexslider .miseSliderButton .miseButtonSingle a:hover,\r\n\t\t\t\t.flexslider .miseSliderButton .miseButtonSingle a:focus,\r\n\t\t\t\t.flexslider .miseSliderButton .miseButtonSingle a:active,\r\n\t\t\t\t.miseButton a:hover,\r\n\t\t\t\t.miseButton a:focus,\r\n\t\t\t\t.miseButton a:active,\r\n\t\t\t\t.content-area .onsale {\r\n\t\t\t\t\tcolor: <?php echo esc_html($contentBackColor); ?>;\r\n\t\t\t\t}\r\n\t\t\t\tbody,\r\n\t\t\t\tinput[type=\"text\"],\r\n\t\t\t\tinput[type=\"email\"],\r\n\t\t\t\tinput[type=\"url\"],\r\n\t\t\t\tinput[type=\"password\"],\r\n\t\t\t\tinput[type=\"search\"],\r\n\t\t\t\tinput[type=\"number\"],\r\n\t\t\t\tinput[type=\"tel\"],\r\n\t\t\t\tinput[type=\"range\"],\r\n\t\t\t\tinput[type=\"date\"],\r\n\t\t\t\tinput[type=\"month\"],\r\n\t\t\t\tinput[type=\"week\"],\r\n\t\t\t\tinput[type=\"time\"],\r\n\t\t\t\tinput[type=\"datetime\"],\r\n\t\t\t\tinput[type=\"datetime-local\"],\r\n\t\t\t\tinput[type=\"color\"],\r\n\t\t\t\ttextarea,\r\n\t\t\t\tselect,\r\n\t\t\t\t.site-social a,\r\n\t\t\t\t.miseLoader {\r\n\t\t\t\t\tbackground: <?php echo esc_html($contentBackColor); ?>;\r\n\t\t\t\t}\r\n\t\t\t\t.entry-featuredImg .insideImage span a {\r\n\t\t\t\t\tborder-color: <?php echo esc_html($contentBackColor); ?>;\r\n\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\t/* Content Text Color */\r\n\t\t\tif (!empty($contentTextColor)) {\r\n\t\t\t\tlist($r, $g, $b) = sscanf($contentTextColor, '#%02x%02x%02x');\r\n\t\t\t\t?>\r\n\t\t\t\tbody,\r\n\t\t\t\tinput,\r\n\t\t\t\tselect,\r\n\t\t\t\ttextarea,\r\n\t\t\t\tinput[type=\"text\"],\r\n\t\t\t\tinput[type=\"email\"],\r\n\t\t\t\tinput[type=\"url\"],\r\n\t\t\t\tinput[type=\"password\"],\r\n\t\t\t\tinput[type=\"search\"],\r\n\t\t\t\tinput[type=\"number\"],\r\n\t\t\t\tinput[type=\"tel\"],\r\n\t\t\t\tinput[type=\"range\"],\r\n\t\t\t\tinput[type=\"date\"],\r\n\t\t\t\tinput[type=\"month\"],\r\n\t\t\t\tinput[type=\"week\"],\r\n\t\t\t\tinput[type=\"time\"],\r\n\t\t\t\tinput[type=\"datetime\"],\r\n\t\t\t\tinput[type=\"datetime-local\"],\r\n\t\t\t\tinput[type=\"color\"],\r\n\t\t\t\ttextarea,\r\n\t\t\t\ta:hover,\r\n\t\t\t\ta:focus,\r\n\t\t\t\ta:active,\r\n\t\t\t\t.entry-theContent h2 a,\r\n\t\t\t\t.post-navigation .meta-nav,\r\n\t\t\t\t.site-main .navigation.pagination .nav-links .page-numbers.current,\r\n\t\t\t\t.woocommerce-pagination .page-numbers li .current.page-numbers,\r\n\t\t\t\t.site-social a,\r\n\t\t\t\t.page-links > .page-links-number,\r\n\t\t\t\taside ul.product-categories li a:before {\r\n\t\t\t\t\tcolor: <?php echo esc_html($contentTextColor); ?>;\r\n\t\t\t\t}\r\n\t\t\t\t.woocommerce ul.products > li .price {\r\n\t\t\t\t\tcolor: <?php echo esc_html($contentTextColor); ?> !important;\r\n\t\t\t\t}\r\n\t\t\t\tbutton:hover,\r\n\t\t\t\tinput[type=\"button\"]:hover,\r\n\t\t\t\tinput[type=\"reset\"]:hover,\r\n\t\t\t\tinput[type=\"submit\"]:hover,\r\n\t\t\t\tbutton:focus,\r\n\t\t\t\tinput[type=\"button\"]:focus,\r\n\t\t\t\tinput[type=\"reset\"]:focus,\r\n\t\t\t\tinput[type=\"submit\"]:focus,\r\n\t\t\t\tbutton:active,\r\n\t\t\t\tinput[type=\"button\"]:active,\r\n\t\t\t\tinput[type=\"reset\"]:active,\r\n\t\t\t\tinput[type=\"submit\"]:active,\r\n\t\t\t\t.hentry header.entry-header.reverse h1::first-letter,\r\n\t\t\t\t.tags-links a:hover,\r\n\t\t\t\t.tags-links a:focus,\r\n\t\t\t\t.tags-links a:active,\r\n\t\t\t\t.tagcloud a:hover,\r\n\t\t\t\t.tagcloud a:focus,\r\n\t\t\t\t.tagcloud a:active,\r\n\t\t\t\t.entry-theContent .single-cat a:hover,\r\n\t\t\t\t.entry-theContent .single-cat a:focus,\r\n\t\t\t\t.entry-theContent .single-cat a:active,\r\n\t\t\t\t.site-main .navigation.pagination .nav-links a:hover,\r\n\t\t\t\t.site-main .navigation.pagination .nav-links a:focus,\r\n\t\t\t\t.site-main .navigation.pagination .nav-links a:active,\r\n\t\t\t\t.woocommerce-pagination .page-numbers li a:hover,\r\n\t\t\t\t.woocommerce-pagination .page-numbers li a:focus,\r\n\t\t\t\t.woocommerce-pagination .page-numbers li a:active,\r\n\t\t\t\t.page-links a .page-links-number:hover,\r\n\t\t\t\t.page-links a .page-links-number:focus,\r\n\t\t\t\t.page-links a .page-links-number:active,\r\n\t\t\t\t.flexslider .miseSliderButton .miseButtonSingle a:hover,\r\n\t\t\t\t.flexslider .miseSliderButton .miseButtonSingle a:focus,\r\n\t\t\t\t.flexslider .miseSliderButton .miseButtonSingle a:active,\r\n\t\t\t\t.miseButton a:hover,\r\n\t\t\t\t.miseButton a:focus,\r\n\t\t\t\t.miseButton a:active,\r\n\t\t\t\t#toTop,\r\n\t\t\t\t.page-links > .page-links-number,\r\n\t\t\t\t.wp-caption-text,\r\n\t\t\t\t.nano > .nano-pane > .nano-slider,\r\n\t\t\t\t.woocommerce ul.products > li:hover .wooImage .button,\r\n\t\t\t\t.woocommerce ul.products > li:hover .wooImage .added_to_cart,\r\n\t\t\t\t.woocommerce-error li a:hover,\r\n\t\t\t\t.woocommerce-message a:hover,\r\n\t\t\t\t.return-to-shop a:hover,\r\n\t\t\t\t.wc-proceed-to-checkout .button.checkout-button:hover,\r\n\t\t\t\t.widget_shopping_cart p.buttons a:hover,\r\n\t\t\t\t.hamburger.yesOpen span\t\t\t\t{\r\n\t\t\t\t\tbackground: <?php echo esc_html($contentTextColor); ?>;\r\n\t\t\t\t}\r\n\t\t\t\t.woocommerce ul.products > li:hover,\r\n\t\t\t\t.woocommerce-MyAccount-navigation ul li.is-active {\r\n\t\t\t\t\tborder-color: <?php echo esc_html($contentTextColor); ?>;\r\n\t\t\t\t}\r\n\t\t\t\tbutton,\r\n\t\t\t\tinput[type=\"button\"],\r\n\t\t\t\tinput[type=\"reset\"],\r\n\t\t\t\tinput[type=\"submit\"],\r\n\t\t\t\t.tags-links a, .tagcloud a, .entry-theContent .single-cat a, .page-links .page-links-number, .miseButton a,\r\n\t\t\t\t.woocommerce .wooImage .button,\r\n\t\t\t\t.woocommerce .wooImage .added_to_cart,\r\n\t\t\t\t.woocommerce-error li a,\r\n\t\t\t\t.woocommerce-message a,\r\n\t\t\t\t.return-to-shop a,\r\n\t\t\t\t.wc-proceed-to-checkout .button.checkout-button,\r\n\t\t\t\t.widget_shopping_cart p.buttons a,\r\n\t\t\t\t.woocommerce .wishlist_table td.product-add-to-cart a,\r\n\t\t\t\t.woocommerce .content-area .woocommerce-tabs .tabs li.active a {\r\n\t\t\t\t\tborder-bottom: 3px solid rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,0.1);\r\n\t\t\t\t}\r\n\t\t\t\t.woocommerce .content-area .images figure div a,\r\n\t\t\t\t.woocommerce-message,\r\n\t\t\t\t.woocommerce-info,\r\n\t\t\t\t.woocommerce-error,\r\n\t\t\t\t.woocommerce div.product form.cart .variations tr,\r\n\t\t\t\t.woocommerce .woocommerce-tabs,\r\n\t\t\t\t.woocommerce table.shop_attributes tr,\r\n\t\t\t\t.woocommerce table.shop_attributes tr th,\r\n\t\t\t\t.woocommerce table.shop_attributes tr.alt th,\r\n\t\t\t\t.woocommerce table.shop_attributes tr.alt td,\r\n\t\t\t\t.woocommerce-page .entry-content table thead th,\r\n\t\t\t\t.woocommerce-page .entry-content table tr:nth-child(even),\r\n\t\t\t\t#payment .payment_methods li .payment_box {\r\n\t\t\t\t\tbackground: rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,0.1);\r\n\t\t\t\t}\r\n\t\t\t\t.widget_price_filter .price_slider_wrapper .ui-widget-content {\r\n\t\t\t\t\tbackground: rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,0.2);\r\n\t\t\t\t}\r\n\t\t\t\t.nano > .nano-pane {\r\n\t\t\t\t\tbackground: rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,0.15);\r\n\t\t\t\t}\r\n\t\t\t\t.nano > .nano-pane > .nano-slider {\r\n\t\t\t\t\tbackground: rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,0.3);\r\n\t\t\t\t}\r\n\t\t\t\t.star-rating:before {\r\n\t\t\t\t\tcolor: rgba(<?php echo esc_html($r).', '.esc_html($g).', '.esc_html($b); ?>,0.1);\r\n\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\t/* Classic Sidebar Background */\r\n\t\t\tif (!empty($sidebarClassicBackColor)) {\r\n\t\t\t\t?>\r\n\t\t\t\t#secondary.widget-area {\r\n\t\t\t\t\tbackground: <?php echo esc_html($sidebarClassicBackColor); ?>;\r\n\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\t/* Push Sidebar Background */\r\n\t\t\tif (!empty($sidebarPushBackColor)) {\r\n\t\t\t\t?>\r\n\t\t\t\t#tertiary.widget-area {\r\n\t\t\t\t\tbackground: <?php echo esc_html($sidebarPushBackColor); ?>;\r\n\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\t/* Footer Background Color */\r\n\t\t\tif (!empty($footerBackColor)) {\r\n\t\t\t\t?>\r\n\t\t\t\tfooter.site-footer {\r\n\t\t\t\t\tbackground: <?php echo esc_html($footerBackColor); ?>;\r\n\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\t/* Footer Text Color */\r\n\t\t\tif (!empty($footerTextColor)) {\r\n\t\t\t\t?>\r\n\t\t\t\tfooter.site-footer {\r\n\t\t\t\t\tcolor: <?php echo esc_html($footerTextColor); ?>;\r\n\t\t\t\t}\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\r\n\t\tif (is_page_template('template-onepage.php')) {\r\n\t\t\t$showAboutus = mise_options('_onepage_section_aboutus', '');\r\n\t\t\t$showFeatures = mise_options('_onepage_section_features', '');\r\n\t\t\t$showSkills = mise_options('_onepage_section_skills', '');\r\n\t\t\t$showCta = mise_options('_onepage_section_cta', '');\r\n\t\t\t$showServices = mise_options('_onepage_section_services', '');\r\n\t\t\t$showBlog = mise_options('_onepage_section_blog', '');\r\n\t\t\t$showTeam = mise_options('_onepage_section_team', '');\r\n\t\t\t$showContact = mise_options('_onepage_section_contact', '');\r\n\t\t\tif ($showAboutus == 1) {\r\n\t\t\t\t$aboutusImageBack = mise_options('_onepage_imgback_aboutus');\r\n\t\t\t\t$aboutusColorBack = mise_options('_onepage_imgcolor_aboutus', '#ffffff');\r\n\t\t\t\t$aboutusColorText = mise_options('_onepage_textcolor_aboutus', '#404040');\r\n\t\t\t\t?>\r\n\t\t\t\t\t<?php if (!empty($aboutusImageBack) ) : ?>\r\n\t\t\t\t\t\tsection.mise_aboutus {\r\n\t\t\t\t\t\t\tbackground-image: url(<?php echo esc_url($aboutusImageBack); ?>);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php else: ?>\r\n\t\t\t\t\t\t.mise_aboutus_color {\r\n\t\t\t\t\t\t\topacity : 1;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($aboutusColorBack) ) : ?>\r\n\t\t\t\t\t\t.mise_aboutus_color {\r\n\t\t\t\t\t\t\tbackground-color: <?php echo esc_html($aboutusColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($aboutusColorText) ) : ?>\r\n\t\t\t\t\t\tsection.mise_aboutus {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($aboutusColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\tif ($showFeatures == 1) {\r\n\t\t\t\t$featuresImageBack = mise_options('_onepage_imgback_features');\r\n\t\t\t\t$featuresColorBack = mise_options('_onepage_imgcolor_features', '#404040');\r\n\t\t\t\t$featuresColorText = mise_options('_onepage_textcolor_features', '#ffffff');\r\n\t\t\t\t?>\r\n\t\t\t\t\t<?php if (!empty($featuresImageBack) ) : ?>\r\n\t\t\t\t\t\tsection.mise_features {\r\n\t\t\t\t\t\t\tbackground-image: url(<?php echo esc_url($featuresImageBack); ?>);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php else: ?>\r\n\t\t\t\t\t\t.mise_features_color {\r\n\t\t\t\t\t\t\topacity : 1;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($featuresColorBack) ) : ?>\r\n\t\t\t\t\t\t.mise_features_color {\r\n\t\t\t\t\t\t\tbackground-color: <?php echo esc_html($featuresColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t.featuresIcon {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($featuresColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($featuresColorText) ) : ?>\r\n\t\t\t\t\t\tsection.mise_features, .featuresIconCyrcle {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($featuresColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t.featuresIcon {\r\n\t\t\t\t\t\t\tbackground: <?php echo esc_html($featuresColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\tif ($showSkills == 1) {\r\n\t\t\t\t$skillsImageBack = mise_options('_onepage_imgback_skills');\r\n\t\t\t\t$skillsColorBack = mise_options('_onepage_imgcolor_skills', '#ffffff');\r\n\t\t\t\t$skillsColorText = mise_options('_onepage_textcolor_skills', '#404040');\r\n\t\t\t\t?>\r\n\t\t\t\t\t<?php if (!empty($skillsImageBack) ) : ?>\r\n\t\t\t\t\t\tsection.mise_skills {\r\n\t\t\t\t\t\t\tbackground-image: url(<?php echo esc_url($skillsImageBack); ?>);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php else: ?>\r\n\t\t\t\t\t\t.mise_skills_color {\r\n\t\t\t\t\t\t\topacity : 1;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($skillsColorBack) ) : ?>\r\n\t\t\t\t\t\t.mise_skills_color {\r\n\t\t\t\t\t\t\tbackground-color: <?php echo esc_html($skillsColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($skillsColorText) ) : ?>\r\n\t\t\t\t\t\tsection.mise_skills {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($skillsColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t.skillBottom .skillBar, .skillBottom .skillRealBar, .skillBottom .skillRealBarCyrcle {\r\n\t\t\t\t\t\t\tbackground: <?php echo esc_html($skillsColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\tif ($showCta == 1) {\r\n\t\t\t\t$ctaImageBack = mise_options('_onepage_imgback_cta');\r\n\t\t\t\t$ctaColorBack = mise_options('_onepage_imgcolor_cta', '#404040');\r\n\t\t\t\t$ctaColorText = mise_options('_onepage_textcolor_cta', '#ffffff');\r\n\t\t\t\t?>\r\n\t\t\t\t\t<?php if (!empty($ctaImageBack) ) : ?>\r\n\t\t\t\t\t\tsection.mise_cta {\r\n\t\t\t\t\t\t\tbackground-image: url(<?php echo esc_url($ctaImageBack); ?>);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php else: ?>\r\n\t\t\t\t\t\t.mise_cta_color {\r\n\t\t\t\t\t\t\topacity : 1;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($ctaColorBack) ) : ?>\r\n\t\t\t\t\t\t.mise_cta_color {\r\n\t\t\t\t\t\t\tbackground-color: <?php echo esc_html($ctaColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t.cta_columns .ctaIcon {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($ctaColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($ctaColorText) ) : ?>\r\n\t\t\t\t\t\tsection.mise_cta, .cta_columns .ctaIcon .ctaIconCyrcle {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($ctaColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t.cta_columns .ctaIcon {\r\n\t\t\t\t\t\t\tbackground: <?php echo esc_html($ctaColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\tif ($showServices == 1) {\r\n\t\t\t\t$servicesImageBack = mise_options('_onepage_imgback_services');\r\n\t\t\t\t$servicesColorBack = mise_options('_onepage_imgcolor_services', '#f7f7f7');\r\n\t\t\t\t$servicesColorText = mise_options('_onepage_textcolor_services', '#404040');\r\n\t\t\t\t?>\r\n\t\t\t\t\t<?php if (!empty($servicesImageBack) ) : ?>\r\n\t\t\t\t\t\tsection.mise_services {\r\n\t\t\t\t\t\t\tbackground-image: url(<?php echo esc_url($servicesImageBack); ?>);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php else: ?>\r\n\t\t\t\t\t\t.mise_services_color {\r\n\t\t\t\t\t\t\topacity : 1;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($servicesColorBack) ) : ?>\r\n\t\t\t\t\t\t.mise_services_color {\r\n\t\t\t\t\t\t\tbackground-color: <?php echo esc_html($servicesColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t.serviceIcon, .services_columns_single .serviceContent {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($servicesColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($servicesColorText) ) : ?>\r\n\t\t\t\t\t\tsection.mise_services, .services_columns .serviceIcon .serviceIconCyrcle {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($servicesColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t.serviceIcon {\r\n\t\t\t\t\t\t\tbackground: <?php echo esc_html($servicesColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t.services_columns_single.two .serviceColumnSingleColor {\r\n\t\t\t\t\t\t\tbackground-color: <?php echo esc_html($servicesColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\tif ($showBlog == 1) {\r\n\t\t\t\t$blogImageBack = mise_options('_onepage_imgback_blog');\r\n\t\t\t\t$blogColorBack = mise_options('_onepage_imgcolor_blog', '#ffffff');\r\n\t\t\t\t$blogColorText = mise_options('_onepage_textcolor_blog', '#404040');\r\n\t\t\t\t?>\r\n\t\t\t\t\t<?php if (!empty($blogImageBack) ) : ?>\r\n\t\t\t\t\t\tsection.mise_blog {\r\n\t\t\t\t\t\t\tbackground-image: url(<?php echo esc_url($blogImageBack); ?>);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php else: ?>\r\n\t\t\t\t\t\t.mise_blog_color {\r\n\t\t\t\t\t\t\topacity : 1;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($blogColorBack) ) : ?>\r\n\t\t\t\t\t\t.mise_blog_color {\r\n\t\t\t\t\t\t\tbackground-color: <?php echo esc_html($blogColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($blogColorText) ) : ?>\r\n\t\t\t\t\t\tsection.mise_blog {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($blogColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\tif ($showTeam == 1) {\r\n\t\t\t\t$teamImageBack = mise_options('_onepage_imgback_team');\r\n\t\t\t\t$teamColorBack = mise_options('_onepage_imgcolor_team', '#f7f7f7');\r\n\t\t\t\t$teamColorText = mise_options('_onepage_textcolor_team', '#404040');\r\n\t\t\t\t?>\r\n\t\t\t\t\t<?php if (!empty($teamImageBack) ) : ?>\r\n\t\t\t\t\t\tsection.mise_team {\r\n\t\t\t\t\t\t\tbackground-image: url(<?php echo esc_url($teamImageBack); ?>);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php else: ?>\r\n\t\t\t\t\t\t.mise_team_color {\r\n\t\t\t\t\t\t\topacity : 1;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($teamColorBack) ) : ?>\r\n\t\t\t\t\t\t.mise_team_color {\r\n\t\t\t\t\t\t\tbackground-color: <?php echo esc_html($teamColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($teamColorText) ) : ?>\r\n\t\t\t\t\t\tsection.mise_team {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($teamColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t\tif ($showContact == 1) {\r\n\t\t\t\t$contactImageBack = mise_options('_onepage_imgback_contact');\r\n\t\t\t\t$contactColorBack = mise_options('_onepage_imgcolor_contact', '#000000');\r\n\t\t\t\t$contactColorText = mise_options('_onepage_textcolor_contact', '#ffffff');\r\n\t\t\t\t?>\r\n\t\t\t\t\t<?php if (!empty($contactImageBack) ) : ?>\r\n\t\t\t\t\t\tsection.mise_contact {\r\n\t\t\t\t\t\t\tbackground-image: url(<?php echo esc_url($contactImageBack); ?>);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php else: ?>\r\n\t\t\t\t\t\t.mise_contact_color {\r\n\t\t\t\t\t\t\topacity : 1;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($contactColorBack) ) : ?>\r\n\t\t\t\t\t\t.mise_contact_color {\r\n\t\t\t\t\t\t\tbackground-color: <?php echo esc_html($contactColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t.miseCompanyAddress1Icon,\r\n\t\t\t\t\t\t.miseCompanyPhoneIcon,\r\n\t\t\t\t\t\t.miseCompanyFaxIcon,\r\n\t\t\t\t\t\t.miseCompanyEmailIcon {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($contactColorBack); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t\t<?php if (!empty($contactColorText) ) : ?>\r\n\t\t\t\t\t\tsection.mise_contact,\r\n\t\t\t\t\t\t.contact_columns .miseContactForm input:not([type=\"submit\"]),\r\n\t\t\t\t\t\t.contact_columns .miseContactForm textarea {\r\n\t\t\t\t\t\t\tcolor: <?php echo esc_html($contactColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t.miseCompanyAddress1Icon,\r\n\t\t\t\t\t\t.miseCompanyPhoneIcon,\r\n\t\t\t\t\t\t.miseCompanyFaxIcon,\r\n\t\t\t\t\t\t.miseCompanyEmailIcon {\r\n\t\t\t\t\t\t\tbackground: <?php echo esc_html($contactColorText); ?>;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t<?php endif; ?>\r\n\t\t\t\t<?php\r\n\t\t\t}\r\n\t\t}\r\n\t\techo '</style>';\r\n\t}", "title": "" }, { "docid": "e163ee6723c1f062972a4ad07cc09bad", "score": "0.5773099", "text": "function vip_admin_gallery_css_extras() {\n\tadd_action('admin_print_styles', '_vip_admin_gallery_css_extras');\n}", "title": "" }, { "docid": "eb5a346bddb16e2e21d748c007c5bc26", "score": "0.5773083", "text": "function siiimple_custom_css() {\n\t\n\t\tglobal $data;\n\t\t\n\t\t$custom_css ='';\n\t\t\n\t\t\n\t\t//CUSTOM FIELD CSS\n\t\tif(!empty($data['custom_css'])) {\n\t\t\t$custom_css .= $data['custom_css'];\n\t\t}\n\t\t\n\t\t//GENERAL HEADER FONTS\n\t\tif(!empty($data['google_fonts_header'])) {\n\t\t\t\n\t\t\t$custom_css .= 'h1, h2, h3, h4, h5, h6, h5.main-title-blog a,.sf-menu a,.paginate,h1.main-header,.tip-twitter .tip-inner { font-family: '.$data['google_fonts_header'].' !important; }';\n\t\t}\n\t\t\n\t\t//GENERAL HEADER FONTS WEIGHT\n\t\tif(!empty($data['google_fonts_header_weight'])) {\n\t\t\t\n\t\t\t$custom_css .= 'h1, h2, h3, h4, h5, h6, h5.main-title-blog a,.sf-menu a,.paginate,h1.main-header,.tip-twitter .tip-inner { font-weight: '.$data['google_fonts_header_weight'].' !important; }';\n\t\t}\n\t\t\n\t\t//GENERAL HEADER PARAGRAPH\n\t\tif(!empty($data['google_fonts_paragraph'])) {\n\t\t\t\n\t\t\t$custom_css .= 'body, p, .left-excerpt ul li, .sidebar-inner a, input#s, .grid4.col ul li a,p.main-desc{ font-family: '.$data['google_fonts_paragraph'].' !important; }';\n\t\t}\n\t\t\n\t\t//GENERAL HEADER PARAGRAPH WEIGHT\n\t\tif(!empty($data['google_fonts_paragraph_weight'])) {\n\t\t\t\n\t\t\t$custom_css .= 'body, p, .left-excerpt ul li, .sidebar-inner a, input#s, .grid4.col ul li a,p.main-desc{ font-weight: '.$data['google_fonts_paragraph_weight'].' !important; }';\n\t\t}\n\n\t\t\n\t\t//GENERAL ACCENT COLOR\n\t\tif(!empty($data['accent_color'])) {\n\t\t\t\n\t\t\t$custom_css .= '#footer a,.grid4.col .tweet li a,#page-bottom a.author-link,.grid4.col .menu li.current-menu-item a,label small,.left-excerpt ul li a,.link p,a:hover,#nav a:hover,[class^=\"icon-\"]:hover:before,.info-area h4 a,#intro-wrap p a,#inline a, #inlineOne a { color: '.$data['accent_color'].' !important; }';\n\t\t\t\n\t\t\t$custom_css .= ' .jspHorizontalBar .jspDrag,li.thumbers:hover,#nav #uniform-undefined.selector:hover { background: '.$data['accent_color'].' !important; }';\n\t\t\t$custom_css .= ' .panorama .controls a.prev:hover,.panorama .controls a.next:hover,.panorama .controls a.stop:hover,.panorama_prev:hover,.panorama_next:hover,.open-panels:hover,.close-panels:hover,.panorama-view .area:hover,#prev:hover, #next:hover { background-color: '.$data['accent_color'].' !important; }';\n\t\t}\n\t\t\n\t\t//HEADER TEXT COLOR\n\t\tif(!empty($data['header_text_color'])) {\n\t\t\t\n\t\t\t$custom_css .= '.sf-menu a { color: '.$data['header_text_color'].' !important; }';\n\t\t}\n\t\t\n\t\t//HEADER BACKGROUND COLOR\n\t\tif(!empty($data['header_color'])) {\n\t\t\t\n\t\t\t$custom_css .= '#header-left.grid16.col { background: '.$data['header_color'].' !important; }';\n\t\t\t$custom_css .= '.sf-menu ul{background:'.$data['header_color'].' !important;}';\n\t\t}\n\t\t\n\t\t//MENU BORDER\n\t\tif(!empty($data['menu_border'])) {\n\t\t\t\n\t\t\t$custom_css .= 'ul#menu-menu.sf-menu a.sf-with-ul { border-left: 1px solid '.$data['menu_border'].' !important; }';\n\t\t\t$custom_css .= 'ul.sub-menu a { border-bottom: 1px solid '.$data['menu_border'].' !important; }';\n\t\t\t$custom_css .= '.sf-menu ul { border-left: 1px solid '.$data['menu_border'].' !important; border-right:1px solid '.$data['menu_border'].' !important; border-bottom: 1px solid '.$data['menu_border'].' !important;}';\n\t\t\t\n\t\t}\n\t\t\n\t\t//HOME BLOG HEADER\n\t\t\n\t\tif(!empty($data['blog_home_color'])) {\n\t\t\t\n\t\t\t$custom_css .= '.second-home #page-bottom.container.home2 h1 { color: '.$data['blog_home_color'].' !important; }';\n\t\t}\n\t\t\n\t\t//BLOG HEADER\n\t\tif(!empty($data['blog_header_color'])) {\n\t\t\t\n\t\t\t$custom_css .= '.top-header h1.main-header-title.blog-page { color: '.$data['blog_header_color'].' !important; }';\n\t\t}\n\t\t\n\t\tif(!empty($data['header_border'])) {\n\t\t\t\n\t\t\t$custom_css .= '#header-left.grid16.col { border-left:1px solid '.$data['header_border'].' !important; border-right:1px solid '.$data['header_border'].' !important; border-bottom:1px solid '.$data['header_border'].' !important }';\n\t\t}\n\t\t\n\t\tif(!empty($data['blog_sub_header_color'])) {\n\t\t\t\n\t\t\t$custom_css .= 'p.sub-port { color: '.$data['blog_sub_header_color'].' !important; }';\n\t\t}\n\t\t\n\t\tif(!empty($data['blog_sub_header_border_color'])) {\n\t\t\t\n\t\t\t$custom_css .= 'p.sub-port.blog-sub-port { border-top: 1px solid '.$data['blog_sub_header_border_color'].' !important; border-bottom: 1px solid '.$data['blog_sub_header_border_color'].' !important; }';\n\t\t}\n\t\t\n\t\t//VIEWER HEADER\n\t\tif(!empty($data['viewer_header_color'])) {\n\t\t\t\n\t\t\t$custom_css .= '#top-wrapper h1 { color: '.$data['viewer_header_color'].' !important; }';\n\t\t}\n\t\t\n\t\tif(!empty($data['viewer_sub_header_color'])) {\n\t\t\t\n\t\t\t$custom_css .= 'p.viewer { color: '.$data['viewer_sub_header_color'].' !important; }';\n\t\t}\n\t\t\n\t\tif(!empty($data['viewer_sub_header_border_color'])) {\n\t\t\t\n\t\t\t$custom_css .= 'p.viewer { border-top: 1px solid '.$data['viewer_sub_header_border_color'].' !important; border-bottom: 1px solid '.$data['viewer_sub_header_border_color'].' !important; }';\n\t\t}\n\t\t\n\t\t//TESTIMONIAL HEADER\n\t\tif(!empty($data['testimonial_header_color'])) {\n\t\t\t\n\t\t\t$custom_css .= 'h1.testimonial-title { color: '.$data['testimonial_header_color'].' !important; }';\n\t\t}\n\t\t\n\t\tif(!empty($data['testimonial_sub_header_color'])) {\n\t\t\t\n\t\t\t$custom_css .= 'p.testimonial { color: '.$data['testimonial_sub_header_color'].' !important; }';\n\t\t}\n\t\t\n\t\tif(!empty($data['testimonial_sub_header_border_color'])) {\n\t\t\t\n\t\t\t$custom_css .= 'p.testimonial { border-top: 1px solid '.$data['testimonial_sub_header_border_color'].' !important; border-bottom: 1px solid '.$data['testimonial_sub_header_border_color'].' !important; }';\n\t\t}\n\t\t\n\t\t//PORTFOLIO HEADER\n\t\tif(!empty($data['portfolio_header_color'])) {\n\t\t\t\n\t\t\t$custom_css .= '.top-header h1.main-header-title { color: '.$data['portfolio_header_color'].' !important; }';\n\t\t}\n\t\t\n\t\tif(!empty($data['portfolio_sub_header_color'])) {\n\t\t\t\n\t\t\t$custom_css .= 'p.portfolio { color: '.$data['portfolio_sub_header_color'].' !important; }';\n\t\t}\n\t\t\n\t\tif(!empty($data['portfolio_sub_header_border_color'])) {\n\t\t\t\n\t\t\t$custom_css .= 'p.portfolio { border-top: 1px solid '.$data['portfolio_sub_header_border_color'].' !important; border-bottom: 1px solid '.$data['portfolio_sub_header_border_color'].' !important; }';\n\t\t}\n\t\t\n\t\t//MENU ICONS\n\t\t\n\t\tif(!empty($data['menu_icons_color'])) {\n\t\t\t\n\t\t\t$custom_css .= '[class^=\"icon-\"]:before,[class*=\" icon-\"]:before { color: '.$data['menu_icons_color'].' !important; }';\n\t\t}\n\t\t\n\t\t//PAGE ICONS\n\t\t\n\t\tif(!empty($data['page_icons_color'])) {\n\t\t\t\n\t\t\t$custom_css .= '#page-bottom [class^=\"icon-\"]:before, #page-bottom [class*=\" icon-\"]:before { color: '.$data['page_icons_color'].' !important; }';\n\t\t}\n\t\t\n\t\t//PAGE ICONS SIZE\n\t\t\n\t\tif(!empty($data['page_icons_size'])) {\n\t\t\t\n\t\t\t$custom_css .= '#page-bottom [class^=\"icon-\"], #page-bottom [class*=\" icon-\"] { font-size: '.$data['page_icons_size'].' !important; }';\n\t\t}\n\n\t\t\n\t\t//LINE BACKGROUND\n\t\tif(!empty($data['custom_line'])) {\n\t\t\tif($data['custom_line'] !=''.get_template_directory_uri().'/framework/images/01.png') {\n\t\t\t\t$custom_css .= '.line{background: url('.$data['custom_line'].');}';\n\t\t\t} else {\n\t\t\t\t$custom_css .= '.line{background: none;}';\n\t\t\t}\n\t\t}\n\n\t\t\n\t\t//ECHO CSS\n\t\t$css_output = \"<!-- Custom CSS -->\\n<style type=\\\"text/css\\\">\\n\" . $custom_css . \"\\n</style>\";\n\t\t\n\t\tif(!empty($custom_css)) {\n\t\t\techo $css_output;\n\t\t}\n}", "title": "" }, { "docid": "6db8d9e058cb3549364beb46d043c39b", "score": "0.57708985", "text": "function ct_custom_admin_styles() {\n\t\n\t$styles = '\n\t\t<style type=\"text/css\">\n\t\t\t.column-collection-featured {\n\t\t\t\twidth: 100px !important;\n\t\t\t\ttext-align: center !important;\n\t\t\t}\n\t\t\t.column-collection-color {\n\t\t\t\twidth: 110px !important;\n\t\t\t\ttext-align: center !important;\n\t\t\t}\n\t\t\t#posts-filter .wp-list-table tr,\n\t\t\t#posts-filter .wp-list-table th {\n\t\t\t\tvertical-align: middle !important;\n\t\t\t}\n\t\t\t#posts-filter .wp-list-table tr *,\n\t\t\t#posts-filter .wp-list-table th * {\n\t\t\t\tvertical-align: middle !important;\n\t\t\t}\n\t\t\t#posts-filter .wp-list-table thead th a span {\n\t\t\t\tfloat: none !important;\n\t\t\t\tdisplay: inline-block !important;\n\t\t\t\tvertical-align: middle !important;\n\t\t\t}\n\t\t\t.editor-styles-wrapper h1,\n\t\t\t.editor-styles-wrapper h2,\n\t\t\t.editor-styles-wrapper h3,\n\t\t\t.editor-styles-wrapper h4,\n\t\t\t.editor-styles-wrapper h5,\n\t\t\t.editor-styles-wrapper h6,\n\t\t\t.editor-styles-wrapper p,\n\t\t\t.wp-block-cover-image .block-editor-block-list__block,\n\t\t\t.wp-block-cover .block-editor-block-list__block {\n\t\t\t\tcolor: inherit !important;\n\t\t\t}\n\t\t\t.editor-styles-wrapper p {\n\t\t\t\tfont-size: inherit;\n\t\t\t}\n\t\t\t.components-popover.block-editor-block-list__block-popover .components-popover__content .block-editor-block-contextual-toolbar,\n\t\t\t.components-popover.block-editor-block-list__block-popover .components-popover__content .block-editor-block-list__breadcrumb,\n\t\t\tbody .editor-styles-wrapper .block-editor-block-list__block {\n\t\t\t\tmargin-top: 0 !important;\n\t\t\t\tmargin-bottom: 0 !important;\n\t\t\t}\n\t\t\tbody .block-editor-block-list__layout .block-editor-block-list__block:before {\n\t\t\t\ttop: 0 !important;\n\t\t\t\tbottom: 0 !important;\n\t\t\t}\n\t\t\tbody .editor-styles-wrapper {\n\t\t\t\tfont-family: \"Inter\", \"Archivo Narrow\", sans-serif;\n\t\t\t}\n\t\t\tsvg.components-panel__icon {\n\t\t\t\twidth: 100px;\n\t\t\t}\n\t\t\t.block-editor__typewriter .components-button svg {\n\t\t\t\tfill: black;\n\t\t\t}\n\t\t\t#edittag {\n\t\t\t\tmax-width: 90%;\n\t\t\t\tmargin: 0 auto;\n\t\t\t}\n\t\t</style>\n\t';\n\tif ( get_current_screen()->id === 'edit-collaborators' ) {\n\t\t$styles .= '\n\t\t\t<style type=\"text/css\">\n\t\t\t\t.form-field.term-description-wrap {\n\t\t\t\t\tdisplay: none;\n\t\t\t\t}\n\t\t\t\tbody {\n\t\t\t\t\tbackground: #ffffff;\n\t\t\t\t}\n\t\t\t\t.acf-field .medium-editor-element {\n\t\t\t\t\tbox-shadow: none;\n\t\t\t\t}\n\t\t\t\t.form-field input, .form-field textarea, .form-field select, .acf-field .medium-editor-element {\n\t\t\t\t\tborder: 1px solid #ddd !important;\n\t\t\t\t\twidth: 100% !important;\n\t\t\t\t}\n\t\t\t</style>\n\t\t';\n\t}\n\techo $styles;\n}", "title": "" }, { "docid": "6c37510d65897f03344b960502127068", "score": "0.5728329", "text": "private function custom_css() {\n\t\t$result = '';\n\t\t$result .= '<!-- Lounge Act Custom CSS -->' . \"\\n\";\n\t\t$result .= '<style type=\"text/css\" id=\"loungeact-custom-css\">' . \"\\n\";\n\t\t\n\t\t// Colors Styles\n\t\t$result .= $this->generate_css ( 'a', 'color', 'color_link', '', '', false );\n\t\t$result .= $this->generate_css ( 'a:visited', 'color', 'color_link_visited', '', '', false );\n\t\t$result .= $this->generate_css ( 'a:hover, a:focus, a:active', 'color', 'color_link_hover', '', '', false );\n\t\t\n\t\t// HEADER\n\t\t// Simulate header height when fixed-top\n\t\t// if ($this->get_setting ( \"header_fixed_top\" ) && !$this->get_setting ( \"slider_fullscreen\" )) {\n\t\t// $result .= $this->generate_css ( \".lougeact-wrapper.loungeact-header-fixed-top\", \"padding-top\", \"header_margin_bottom\", '', '', false );\n\t\t// }\n\t\t\n\t\t// logo\n\t\t$result .= $this->generate_css ( \".lougeact-header .site-logo\", \"max-height\", \"logo_max_height\", '', '', false );\n\t\t\n\t\t// SLIDER\n\t\t$result .= $this->generate_css ( \".loungeact-banner\", \"height\", \"slider_height\", '', '', false );\n\t\t$result .= $this->generate_css ( \".loungeact-banner .loungeact-slider-overlay\", \"background-color\", \"slide_overlay_opacity\", 'rgba(0 , 0 , 0, ', ')', false );\n\t\t\n\t\t// if ($this->get_setting ( \"slider_header_inside\" )) {\n\t\t// $result .= '.lougeact-header {position: absolute;}';\n\t\t// }\n\t\t\n\t\tif ((is_front_page () && is_home () && $this->get_setting ( \"hide_title_in_homepage\" ))) {\n\t\t\t$result .= '.site-title {position: absolute;clip: rect(1px, 1px, 1px, 1px);}';\n\t\t}\n\t\tif ($this->get_setting ( \"container_class\" ) == \"container\") {\n\t\t\t$result .= $this->generate_css ( \".loungeact-container.container\", \"max-width\", \"container_max_width\", '', '', false );\n\t\t}\n\t\t\n\t\tif ($this->get_setting ( \"header_background_color\" )) {\n\t\t\t$result .= \".lougeact-header .navbar-default { background-color: rgba(\" . implode ( \", \", hex2rgba ( $this->get_setting ( \"header_background_color\" ), $this->get_setting ( \"header_background_opacity\" ) ) ) . \");}\\n\";\n\t\t\t$result .= \".loungeact-fullscreen-banner.lougeact-scrolling .lougeact-header .navbar-default { background-color: rgba(\" . implode ( \", \", hex2rgba ( $this->get_setting ( \"header_background_color\" ), $this->get_setting ( \"header_background_opacity\" ) ) ) . \");}\\n\";\n\t\t\t$result .= \".loungeact-header-inside-banner.lougeact-scrolling .lougeact-header .navbar-default { background-color: rgba(\" . implode ( \", \", hex2rgba ( $this->get_setting ( \"header_background_color\" ), $this->get_setting ( \"header_background_opacity\" ) ) ) . \");}\\n\";\n\t\t} else {\n\t\t\t$result .= \".lougeact-header .navbar-default { background-color: transparent;}\";\n\t\t\t$result .= \".loungeact-fullscreen-banner.lougeact-scrolling .navbar-default { background-color: transparent;}\";\n\t\t\t$result .= \".loungeact-header-inside-banner.lougeact-scrolling .navbar-default { background-color: transparent;}\";\n\t\t}\n\t\t// SubMenu bg color\n\t\t// $result .= \".lougeact-header .loungeact-navbar-mobile { background-color: rgba(\" . implode ( \", \", hex2rgba ( $this->get_setting ( \"header_background_color\" ), 1)) . \");}\\n\";\n\t\t\n\t\tif ($this->get_setting ( \"header_background_opacity_inside_slider\" )) {\n\t\t\t$result .= \".loungeact-header-inside-banner .lougeact-header .navbar-default { background-color: rgba(\" . implode ( \", \", hex2rgba ( $this->get_setting ( \"header_background_color\" ), $this->get_setting ( \"header_background_opacity_inside_slider\" ) ) ) . \");}\\n\";\n\t\t\t$result .= \".loungeact-fullscreen-banner .lougeact-header .navbar-default { background-color: rgba(\" . implode ( \", \", hex2rgba ( $this->get_setting ( \"header_background_color\" ), $this->get_setting ( \"header_background_opacity_inside_slider\" ) ) ) . \");}\\n\";\n\t\t} else {\n\t\t\t$result .= \".loungeact-header-inside-banner .lougeact-header .navbar-default { background-color: transparent;}\";\n\t\t\t$result .= \".loungeact-fullscreen-banner .lougeact-header .navbar-default { background-color: transparent;}\";\n\t\t}\n\t\t\n\t\t// Main Menu\n\t\t$result .= $this->generate_css ( \".navbar-default .loungeact-navbar .navbar-nav > li > a\", \"color\", \"menu_font_color\", '', '', false );\n\t\t$result .= $this->generate_css ( \".navbar-default .loungeact-navbar .navbar-nav > li > a:hover\", \"color\", \"menu_font_color_hover\", '', '', false );\n\t\t$result .= $this->generate_css ( \".navbar-default .navbar-toggle .icon-bar\", \"background-color\", \"menu_font_color\", '', '', false );\n\t\t$result .= $this->generate_css ( \".navbar-default .navbar-toggle:hover .icon-bar\", \"background-color\", \"menu_font_color_hover\", '', '', false );\n\t\t\n\t\t$result .= $this->generate_css ( \".site-title a\", \"color\", \"site_title_color\", '', '', false );\n\t\t$result .= $this->generate_css ( \".site-description\", \"color\", \"blogdescription_color\", '', '', false );\n\t\t\n\t\tif ($this->get_setting ( \"font_family_title\" )) {\n\t\t\t$result .= \".site-title { font-family: '\" . explode ( \":\", $this->get_setting ( \"font_family_title\" ) ) [0] . \"'}\\n\";\n\t\t}\n\t\tif ($this->get_setting ( \"font_family_default\" )) {\n\t\t\t$result .= \"body { font-family: '\" . explode ( \":\", $this->get_setting ( \"font_family_default\" ) ) [0] . \"'}\\n\";\n\t\t}\n\t\tif ($this->get_setting ( \"font_family_h1\" )) {\n\t\t\t$result .= \"h1 { font-family: '\" . explode ( \":\", $this->get_setting ( \"font_family_h1\" ) ) [0] . \"'}\\n\";\n\t\t}\n\t\tif ($this->get_setting ( \"font_family_h2\" )) {\n\t\t\t$result .= \"h2 { font-family: '\" . explode ( \":\", $this->get_setting ( \"font_family_h2\" ) ) [0] . \"'}\\n\";\n\t\t}\n\t\t$result .= '</style>' . \"\\n\";\n\t\t;\n\t\t$result .= '<!-- /Lounge Act Custom CSS -->' . \"\\n\";\n\t\t;\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "48f4415e6a0df15fcc05ba1c81036a81", "score": "0.5721489", "text": "function bloggr_add_customizer_css() {\n\t$color = bloggr_sanitize_hex_color( get_theme_mod( 'bloggr_link_color' ) );\n\t?>\n\t<!-- bloggr customizer CSS -->\n\t<style>\n\t\tbody {\n\t\t\tborder-color: <?php echo $color; ?>;\n\t\t}\n\t\ta {\n\t\t\tcolor: <?php echo $color; ?>;\n\t\t}\n\t\t\n\t\t.main-navigation li:hover > a, a:hover, .home-featured a:hover { \n\t\t\tcolor: <?php echo get_theme_mod( 'bloggr_hover_color' ) ?>; \n\t\t} \n\t\t\n\t\t.fa, .social-media-icons .fa, .footer-contact h5 { color: <?php echo get_theme_mod( 'bloggr_custom_color' ) ?>; }\n\t \n\t\t.site-header { background: <?php echo get_theme_mod( 'bloggr_custom_color' ) ?>; } \n\t\t\n\t\t.home-entry-title:after, .member-entry-title:after, .works-entry-title:after, .client-entry-title:after, .home-news h5:after, .home-team h5:after, .home-cta h6:after, .footer-contact h5:after, .member h5:after { border-color: <?php echo get_theme_mod( 'bloggr_custom_color' ) ?>; } \n\t\t\n\t\t.main-navigation ul ul li, blockquote { border-color: <?php echo get_theme_mod( 'bloggr_custom_color' ) ?>; }\n\t\t \n\t\tbutton, input[type=\"button\"], input[type=\"reset\"], input[type=\"submit\"] { background: <?php echo get_theme_mod( 'bloggr_custom_color' ) ?>; border-color: <?php echo get_theme_mod( 'bloggr_custom_color' ) ?>; } \n\t\t\n\t\t.home-blog .entry-footer:hover, button:hover, input[type=\"button\"]:hover, input[type=\"reset\"]:hover, input[type=\"submit\"]:hover { border-color: <?php echo get_theme_mod( 'bloggr_custom_color_hover') ?>; background: <?php echo get_theme_mod( 'bloggr_custom_color_hover') ?>; } \n\t\t#site-navigation button:hover { background: none; }\n\t\t \n\t</style>\n<?php }", "title": "" }, { "docid": "130f26838255a01218a0eea68f246d0c", "score": "0.5698908", "text": "function wpcrown_wpcss_loaded() {\n\tglobal $wp_filter;\n\t$lowest_priority = max(array_keys($wp_filter['wp_head']));\n \n\tadd_action('wp_head', 'wpcrown_wpcss_head', $lowest_priority + 1);\n \n\t$arr = $wp_filter['wp_head'];\n\n}", "title": "" }, { "docid": "0fb4fd49f468ea0a0bc357ca0c670670", "score": "0.5687102", "text": "public function enqueue_styles () {\n echo '<style type=\"text/css\">' . \"\\n\" . \n '.visual-hook-reference-box { font-size: 0.9em; border: 1px dashed #CC0033; color: #CC0033; padding: 0.2em 0.3em; margin: 0.2em; word-wrap: break-word; }' . \"\\n\" . \n '.visual-hook-reference-box:hover { background: #CC0033; color: #FFFFFF; font-weight: bold; }' . \"\\n\" . \n '</style>' . \"\\n\";\n }", "title": "" }, { "docid": "084c32679f2a4de6c485a557299466e2", "score": "0.56669396", "text": "function studeon_hovers_theme_setup3() {\n\t\tstudeon_storage_set_array_before('options', 'sidebar_widgets', array(\n\t\t\t'button_hover' => array(\n\t\t\t\t\"title\" => esc_html__(\"Button's hover\", 'studeon'),\n\t\t\t\t\"desc\" => wp_kses_data( __('Select hover effect to decorate all theme buttons', 'studeon') ),\n\t\t\t\t\"std\" => 'default',\n\t\t\t\t\"options\" => array(\n\t\t\t\t\t'default'\t\t=> esc_html__('Fade',\t\t\t\t'studeon'),\n\t\t\t\t\t'slide_left'\t=> esc_html__('Slide from Left',\t'studeon'),\n\t\t\t\t\t'slide_right'\t=> esc_html__('Slide from Right',\t'studeon'),\n\t\t\t\t\t'slide_top'\t\t=> esc_html__('Slide from Top',\t\t'studeon'),\n\t\t\t\t\t'slide_bottom'\t=> esc_html__('Slide from Bottom',\t'studeon'),\n\t\t\t\t),\n\t\t\t\t\"type\" => \"hidden\" //select\n\t\t\t),\n\t\t\t'image_hover' => array(\n\t\t\t\t\"title\" => esc_html__(\"Image's hover\", 'studeon'),\n\t\t\t\t\"desc\" => wp_kses_data( __('Select hover effect to decorate all theme images', 'studeon') ),\n\t\t\t\t\"std\" => 'icon',\n\t\t\t\t\"override\" => array(\n\t\t\t\t\t'mode' => 'page',\n\t\t\t\t\t'section' => esc_html__('Content', 'studeon')\n\t\t\t\t),\n\t\t\t\t\"options\" => array(\n\t\t\t\t\t'dots'\t=> esc_html__('Dots',\t'studeon'),\n\t\t\t\t\t'icon'\t=> esc_html__('Icon',\t'studeon'),\n\t\t\t\t\t'icons'\t=> esc_html__('Icons',\t'studeon'),\n\t\t\t\t\t'zoom'\t=> esc_html__('Zoom',\t'studeon'),\n\t\t\t\t\t'fade'\t=> esc_html__('Fade',\t'studeon'),\n\t\t\t\t\t'slide'\t=> esc_html__('Slide',\t'studeon'),\n\t\t\t\t\t'pull'\t=> esc_html__('Pull',\t'studeon'),\n\t\t\t\t\t'border'=> esc_html__('Border',\t'studeon')\n\t\t\t\t),\n\t\t\t\t\"type\" => \"hidden\" //select\n\t\t\t) )\n\t\t);\n\t}", "title": "" }, { "docid": "65ab3811244c7720350de7ce508a2cec", "score": "0.5664411", "text": "function sp_custom_styles() {\n\tglobal $data, $config;\n\t$output = '';\n\t$font = '';\n\tif (is_ssl()) :\n\t\t$ssl_url = \"https\";\n\telse:\n\t\t$ssl_url = \"http\";\n\tendif;\n\tif (isset($data[THEME_SHORTNAME.'skins']) && $data[THEME_SHORTNAME.'skins'] != '1' && $data[THEME_SHORTNAME.'skins'] != '') {\n\t\t$output .= \"\\r\\n\".'<link href=\"'.get_bloginfo('stylesheet_directory').'/skins/skin'.$data[THEME_SHORTNAME.'skins'].'.css\" rel=\"stylesheet\" type=\"text/css\" />'.\"\\r\\n\";\n\t}\n\t$output .= '<style type=\"text/css\">'.\"\\r\\n\";\n\t// include theme widgets\n\tif (file_exists(TEMPLATEPATH. '/sp-dynamic.php')) {\n\t\trequire_once(TEMPLATEPATH. '/sp-dynamic.php');\n\t}\n\t\n\tif (is_array($config['tab'])) {\n\t\tforeach ($config['tab'] as $tabs) {\n\t\t\tforeach ($tabs['panel'] as $panels) {\n\t\t\t\tif (is_array($panels['wrapper'])) {\n\t\t\t\t\tforeach ($panels['wrapper'] as $wrappers) {\n\t\t\t\t\t\tif (is_array($wrappers['module'])) {\n\t\t\t\t\t\t\tforeach ($wrappers['module'] as $module) {\n\t\t\t\t\t\t\t\tswitch ($module['_attr']['property']) {\n\t\t\t\t\t\t\t\t\tcase 'font-size' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '') {\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].' {'.$module['_attr']['property'].':'.$data[THEME_SHORTNAME.$module['_attr']['id']].'px;}';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\n\t\t\t\t\t\t\t\t\tcase 'color' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '') {\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].' {color:'.$data[THEME_SHORTNAME.$module['_attr']['id']].';}';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tcase 'text-hover' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '') {\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].':hover {color:'.$data[THEME_SHORTNAME.$module['_attr']['id']].';}';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\tcase 'font-weight' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '0') {\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].' {'.$module['_attr']['property'].':'.$data[THEME_SHORTNAME.$module['_attr']['id']].';}';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tcase 'font-style' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '0') {\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].' {'.$module['_attr']['property'].':'.$data[THEME_SHORTNAME.$module['_attr']['id']].';}';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tcase 'font-family' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '0') {\t\n\t\t\t\t\t\t\t\t\t\t$option = array('0','\"Oswald\"','\"Pacifico\"','\"Anton\"','\"Copse\"','\"Cuprum\"','\"Josefin Slab\"','\"Yanone Kaffeesatz\"','\"Cabin\"','\"Alerta\"','\"Gruppo\"');\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].' {'.$module['_attr']['property'].':'.$option[$data[THEME_SHORTNAME.$module['_attr']['id']]].',san-serif;}';\n\t\t\t\t\t\t\t\t\t\t\t$font .= '<link rel=\"stylesheet\" type=\"text/css\" href=\"'.$ssl_url.'://fonts.googleapis.com/css?family='.str_replace(array('\"',' '),array('','+'),$option[$data[THEME_SHORTNAME.$module['_attr']['id']]]).'\">'.\"\\r\\n\";\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\t\t\tcase 'background-image' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '' && isset($data[THEME_SHORTNAME.'background_image'])) {\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].' {'.$module['_attr']['property'].':url('.$data[THEME_SHORTNAME.$module['_attr']['id']].');}';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\t\t\tcase 'background-position' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '0' && isset($data[THEME_SHORTNAME.'background_image'])) {\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].' {'.$module['_attr']['property'].':'.$data[THEME_SHORTNAME.$module['_attr']['id']].';}';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\t\t\tcase 'background-repeat' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '0' && isset($data[THEME_SHORTNAME.'background_image'])) {\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].' {'.$module['_attr']['property'].':'.$data[THEME_SHORTNAME.$module['_attr']['id']].';}';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\t\t\tcase 'background-attachment' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '0' && isset($data[THEME_SHORTNAME.'background_image'])) {\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].' {'.$module['_attr']['property'].':'.$data[THEME_SHORTNAME.$module['_attr']['id']].';}';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t\t\t\tcase 'background-color' :\n\t\t\t\t\t\t\t\t\t\tif (isset($data[THEME_SHORTNAME.$module['_attr']['id']]) && $data[THEME_SHORTNAME.$module['_attr']['id']] != '' && isset($data[THEME_SHORTNAME.'background_image'])) {\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t$output .= $module['_attr']['handle'].' {'.$module['_attr']['property'].':'.$data[THEME_SHORTNAME.$module['_attr']['id']].';}';\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\tbreak;\t\n\t\t\t\t\t\t\t\t}\n\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\t\t\t\n\t\t}\n\t\t\n\t}\n\t$output .= '</style>'.\"\\r\\n\".$font;\n\techo $output;\n}", "title": "" }, { "docid": "c9113f39e7d0e5fe8af6c9f0ec5ac8ae", "score": "0.56534374", "text": "function kvell_edge_design_styles() {\n\t $font_family = kvell_edge_options()->getOptionValue( 'google_fonts' );\n\t if ( ! empty( $font_family ) && kvell_edge_is_font_option_valid( $font_family ) ) {\n\t\t $font_family_selector = array(\n\t\t\t 'body'\n\t\t );\n\t\t echo kvell_edge_dynamic_css( $font_family_selector, array( 'font-family' => kvell_edge_get_font_option_val( $font_family ) ) );\n\t }\n\n\t\t$first_main_color = kvell_edge_options()->getOptionValue('first_color');\n if(!empty($first_main_color)) {\n $color_selector = array(\n 'a:hover',\n 'h1 a:hover',\n 'h2 a:hover',\n 'h3 a:hover',\n 'h4 a:hover',\n 'h5 a:hover',\n 'h6 a:hover',\n 'p a:hover',\n '.edgtf-comment-holder .edgtf-comment-text .comment-edit-link:hover',\n '.edgtf-comment-holder .edgtf-comment-text .comment-reply-link:hover',\n '.edgtf-comment-holder .edgtf-comment-text .replay:hover',\n '.edgtf-comment-holder .edgtf-comment-text #cancel-comment-reply-link',\n '.edgtf-owl-slider .owl-nav .owl-next:hover',\n '.edgtf-owl-slider .owl-nav .owl-prev:hover',\n '.widget.widget_rss .edgtf-widget-title .rsswidget:hover',\n '.widget.widget_search button:hover',\n '.widget.widget_archive ul li a:hover',\n '.widget.widget_categories ul li a:hover',\n '.widget.widget_meta ul li a:hover',\n '.widget.widget_nav_menu ul li a:hover',\n '.widget.widget_pages ul li a:hover',\n '.widget.widget_recent_comments ul li a:hover',\n '.widget.widget_recent_entries ul li a:hover',\n '.widget.widget_tag_cloud a:hover',\n '.edgtf-side-menu .widget a:hover',\n '.edgtf-side-menu .widget.widget_rss .edgtf-footer-widget-title .rsswidget:hover',\n '.edgtf-side-menu .widget.widget_search button:hover',\n '.edgtf-side-menu .widget.widget_tag_cloud a:hover',\n '.edgtf-page-footer .widget a:hover',\n '.edgtf-page-footer .widget.widget_rss .edgtf-footer-widget-title .rsswidget:hover',\n '.edgtf-page-footer .widget.widget_search button:hover',\n '.edgtf-page-footer .widget.widget_tag_cloud a:hover',\n '.edgtf-page-footer .widget .footer-custom-menu ul li a:hover',\n '.edgtf-page-footer .edgtf-icon-widget-holder:hover',\n '.edgtf-top-bar a:hover',\n '.widget.widget_edgtf_twitter_widget .edgtf-twitter-widget.edgtf-twitter-standard li .edgtf-twitter-icon',\n '.widget.widget_edgtf_twitter_widget .edgtf-twitter-widget.edgtf-twitter-slider li .edgtf-tweet-text a',\n '.widget.widget_edgtf_twitter_widget .edgtf-twitter-widget.edgtf-twitter-slider li .edgtf-tweet-text span',\n '.widget.widget_edgtf_twitter_widget .edgtf-twitter-widget.edgtf-twitter-standard li .edgtf-tweet-text a:hover',\n '.widget.widget_edgtf_twitter_widget .edgtf-twitter-widget.edgtf-twitter-slider li .edgtf-twitter-icon i',\n '.widget_icl_lang_sel_widget .wpml-ls-legacy-dropdown .wpml-ls-item-toggle:hover',\n '.widget_icl_lang_sel_widget .wpml-ls-legacy-dropdown-click .wpml-ls-item-toggle:hover',\n '.edgtf-blog-holder article.sticky .edgtf-post-title a',\n '.edgtf-blog-holder article .edgtf-post-info-top>div a:hover',\n '.edgtf-blog-holder article .edgtf-post-info-bottom .edgtf-post-info-bottom-left>div a:hover',\n '.edgtf-blog-holder article .edgtf-post-info-bottom .edgtf-post-info-bottom-right>div a:hover',\n '.edgtf-bl-standard-pagination ul li.edgtf-bl-pag-active a',\n '.edgtf-blog-pagination ul li a.edgtf-pag-active',\n '.edgtf-author-description .edgtf-author-description-text-holder .edgtf-author-name a:hover',\n '.edgtf-author-description .edgtf-author-description-text-holder .edgtf-author-social-icons a:hover',\n '.edgtf-blog-single-navigation .edgtf-blog-single-next:hover',\n '.edgtf-blog-single-navigation .edgtf-blog-single-prev:hover',\n '.edgtf-blog-list-holder .edgtf-bli-info>div a:hover',\n '.edgtf-main-menu ul li a:hover',\n '.edgtf-main-menu>ul>li.edgtf-active-item>a',\n '.edgtf-light-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-main-menu>ul>li.edgtf-active-item>a',\n '.edgtf-light-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-main-menu>ul>li>a:hover',\n '.edgtf-drop-down .second .inner ul li.current-menu-ancestor>a',\n '.edgtf-drop-down .second .inner ul li.current-menu-item>a',\n '.edgtf-drop-down .wide .second .inner>ul>li>a',\n '.edgtf-drop-down .wide .second .inner>ul>li.current-menu-ancestor>a',\n '.edgtf-drop-down .wide .second .inner>ul>li.current-menu-item>a',\n '.edgtf-dark-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-fullscreen-menu-opener.edgtf-fm-opened',\n '.edgtf-dark-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-fullscreen-menu-opener:hover',\n '.edgtf-light-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-fullscreen-menu-opener.edgtf-fm-opened',\n '.edgtf-light-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-fullscreen-menu-opener:hover',\n 'nav.edgtf-fullscreen-menu ul li a:hover',\n 'nav.edgtf-fullscreen-menu ul li ul li.current-menu-ancestor>a',\n 'nav.edgtf-fullscreen-menu ul li ul li.current-menu-item>a',\n 'nav.edgtf-fullscreen-menu>ul>li.edgtf-active-item>a',\n '.edgtf-fullscreen-below-menu-widget-holder .edgtf-social-icons-group-widget .edgtf-social-icon-widget-holder:hover',\n '.edgtf-header-vertical .edgtf-vertical-menu ul li a:hover',\n '.edgtf-header-vertical .edgtf-vertical-menu ul li.current-menu-ancestor>a',\n '.edgtf-header-vertical .edgtf-vertical-menu ul li.current-menu-item>a',\n '.edgtf-header-vertical .edgtf-vertical-menu ul li.current_page_item>a',\n '.edgtf-header-vertical .edgtf-vertical-menu ul li.edgtf-active-item>a',\n '.edgtf-header-vertical.edgtf-light-header .edgtf-social-icons-group-widget .edgtf-social-icon-widget-holder:hover',\n '.edgtf-mobile-header .edgtf-mobile-menu-opener.edgtf-mobile-menu-opened a',\n '.edgtf-mobile-header .edgtf-mobile-nav .edgtf-grid>ul>li.edgtf-active-item>a',\n '.edgtf-mobile-header .edgtf-mobile-nav .edgtf-grid>ul>li.edgtf-active-item>h6',\n '.edgtf-mobile-header .edgtf-mobile-nav ul li a:hover',\n '.edgtf-mobile-header .edgtf-mobile-nav ul li h6:hover',\n '.edgtf-mobile-header .edgtf-mobile-nav ul ul li.current-menu-ancestor>a',\n '.edgtf-mobile-header .edgtf-mobile-nav ul ul li.current-menu-ancestor>h6',\n '.edgtf-mobile-header .edgtf-mobile-nav ul ul li.current-menu-item>a',\n '.edgtf-mobile-header .edgtf-mobile-nav ul ul li.current-menu-item>h6',\n '.edgtf-sticky-header .edgtf-sticky-holder ul>li>a:hover',\n '.edgtf-search-opener:hover',\n '.edgtf-search-page-holder article.sticky .edgtf-post-title a',\n '.edgtf-search-cover .edgtf-search-close:hover',\n '.edgtf-pl-filter-holder ul li.edgtf-pl-current span',\n '.edgtf-pl-filter-holder ul li:hover span',\n '.edgtf-pl-standard-pagination ul li.edgtf-pl-pag-active a',\n '.edgtf-portfolio-slider-holder .edgtf-portfolio-list-holder.edgtf-nav-light-skin .owl-nav .owl-next:hover',\n '.edgtf-portfolio-slider-holder .edgtf-portfolio-list-holder.edgtf-nav-light-skin .owl-nav .owl-prev:hover',\n '.edgtf-testimonials-holder.edgtf-testimonials-large-image.edgtf-testimonials-light .owl-nav .owl-next:hover',\n '.edgtf-testimonials-holder.edgtf-testimonials-large-image.edgtf-testimonials-light .owl-nav .owl-prev:hover',\n '.edgtf-testimonials-holder.edgtf-testimonials-standard.edgtf-testimonials-light .owl-nav .owl-next:hover',\n '.edgtf-testimonials-holder.edgtf-testimonials-standard.edgtf-testimonials-light .owl-nav .owl-prev:hover',\n '.edgtf-banner-holder .edgtf-banner-link-text .edgtf-banner-link-hover span',\n '.edgtf-social-share-holder.edgtf-dropdown .edgtf-social-share-dropdown-opener:hover',\n '.edgtf-team-holder .edgtf-team-social-holder .edgtf-team-icon .edgtf-icon-shortcode a:hover',\n '.edgtf-twitter-list-holder .edgtf-twitter-icon',\n '.edgtf-twitter-list-holder .edgtf-tweet-text a:hover',\n '.edgtf-twitter-list-holder .edgtf-twitter-profile a:hover',\n );\n\n $woo_color_selector = array();\n if(kvell_edge_is_woocommerce_installed()) {\n $woo_color_selector = array(\n '.edgtf-pl-holder .edgtf-pli .edgtf-pli-rating',\n '.edgtf-plc-holder .edgtf-plc-item .edgtf-plc-rating',\n '.edgtf-pls-holder .edgtf-pls-text .edgtf-pls-rating',\n '.edgtf-product-info .edgtf-pi-rating',\n '.edgtf-woo-single-page .woocommerce-tabs #reviews .comment-respond .stars a.active:after',\n '.edgtf-woo-single-page .woocommerce-tabs #reviews .comment-respond .stars a:before',\n '.woocommerce .star-rating',\n '.woocommerce-page .edgtf-content .edgtf-quantity-buttons .edgtf-quantity-minus:hover',\n '.woocommerce-page .edgtf-content .edgtf-quantity-buttons .edgtf-quantity-plus:hover',\n 'div.woocommerce .edgtf-quantity-buttons .edgtf-quantity-minus:hover',\n 'div.woocommerce .edgtf-quantity-buttons .edgtf-quantity-plus:hover',\n 'ul.products>.product .edgtf-pl-category a:hover',\n '.edgtf-woo-single-page .edgtf-single-product-summary .product_meta>span a:hover',\n '.edgtf-shopping-cart-holder .edgtf-header-cart.edgtf-header-cart-icon-pack:hover',\n '.edgtf-light-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-shopping-cart-holder .edgtf-header-cart:hover',\n '.widget.woocommerce.widget_layered_nav ul li.chosen a',\n '.edgtf-plc-holder.edgtf-plc-nav-light-skin .owl-nav .owl-next:hover',\n '.edgtf-plc-holder.edgtf-plc-nav-light-skin .owl-nav .owl-prev:hover',\n '.edgtf-pl-holder .edgtf-pli .edgtf-pli-category a:hover',\n '.edgtf-pl-holder .edgtf-pli-inner .edgtf-pli-text-inner .edgtf-pli-price',\n );\n }\n\n $color_selector = array_merge($color_selector, $woo_color_selector);\n\n\t $color_important_selector = array(\n '.edgtf-light-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-icon-widget-holder:hover',\n '.edgtf-light-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-social-icon-widget-holder:hover',\n '.edgtf-light-header .edgtf-page-header>div:not(.fixed):not(.edgtf-sticky-header) .edgtf-menu-area .widget a:hover',\n '.edgtf-light-header .edgtf-page-header>div:not(.fixed):not(.edgtf-sticky-header).edgtf-menu-area .widget a:hover',\n '.edgtf-light-header.edgtf-header-vertical .edgtf-vertical-menu ul li a:hover',\n '.edgtf-light-header.edgtf-header-vertical .edgtf-vertical-menu ul li ul li.current-menu-ancestor>a',\n '.edgtf-light-header.edgtf-header-vertical .edgtf-vertical-menu ul li ul li.current-menu-item>a',\n '.edgtf-light-header.edgtf-header-vertical .edgtf-vertical-menu ul li ul li.current_page_item>a',\n '.edgtf-light-header.edgtf-header-vertical .edgtf-vertical-menu>ul>li.current-menu-ancestor>a',\n '.edgtf-light-header.edgtf-header-vertical .edgtf-vertical-menu>ul>li.edgtf-active-item>a',\n '.edgtf-light-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-search-opener:hover',\n '.edgtf-light-header .edgtf-top-bar .edgtf-search-opener:hover',\n '.edgtf-light-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-side-menu-button-opener.opened',\n '.edgtf-light-header .edgtf-page-header>div:not(.edgtf-sticky-header):not(.fixed) .edgtf-side-menu-button-opener:hover',\n '.edgtf-light-header .edgtf-top-bar .edgtf-side-menu-button-opener.opened',\n '.edgtf-light-header .edgtf-top-bar .edgtf-side-menu-button-opener:hover',\n\t );\n\n $background_color_selector = array(\n '::selection',\n '::-moz-selection',\n '.edgtf-st-loader .pulse',\n '.edgtf-st-loader .double_pulse .double-bounce1',\n '.edgtf-st-loader .double_pulse .double-bounce2',\n '.edgtf-st-loader .cube',\n '.edgtf-st-loader .rotating_cubes .cube1',\n '.edgtf-st-loader .rotating_cubes .cube2',\n '.edgtf-st-loader .stripes>div',\n '.edgtf-st-loader .wave>div',\n '.edgtf-st-loader .two_rotating_circles .dot1',\n '.edgtf-st-loader .two_rotating_circles .dot2',\n '.edgtf-st-loader .five_rotating_circles .container1>div',\n '.edgtf-st-loader .five_rotating_circles .container2>div',\n '.edgtf-st-loader .five_rotating_circles .container3>div',\n '.edgtf-st-loader .atom .ball-1:before',\n '.edgtf-st-loader .atom .ball-2:before',\n '.edgtf-st-loader .atom .ball-3:before',\n '.edgtf-st-loader .atom .ball-4:before',\n '.edgtf-st-loader .clock .ball:before',\n '.edgtf-st-loader .mitosis .ball',\n '.edgtf-st-loader .lines .line1',\n '.edgtf-st-loader .lines .line2',\n '.edgtf-st-loader .lines .line3',\n '.edgtf-st-loader .lines .line4',\n '.edgtf-st-loader .fussion .ball',\n '.edgtf-st-loader .fussion .ball-1',\n '.edgtf-st-loader .fussion .ball-2',\n '.edgtf-st-loader .fussion .ball-3',\n '.edgtf-st-loader .fussion .ball-4',\n '.edgtf-st-loader .wave_circles .ball',\n '.edgtf-st-loader .pulse_circles .ball',\n '#edgtf-back-to-top .edgtf-icon-stack',\n '.widget #wp-calendar td#today',\n '.edgtf-social-icons-group-widget.edgtf-square-icons .edgtf-social-icon-widget-holder:hover',\n '.edgtf-social-icons-group-widget.edgtf-square-icons.edgtf-light-skin .edgtf-social-icon-widget-holder:hover',\n '.edgtf-blog-holder article.edgtf-category-boxed.edgtf-category-background-first-color .edgtf-post-info-category a',\n '.edgtf-blog-holder article.format-link .edgtf-post-text',\n '.edgtf-blog-holder article.format-audio .edgtf-blog-audio-holder .mejs-container .mejs-controls>.mejs-time-rail .mejs-time-total .mejs-time-current',\n '.edgtf-blog-holder article.format-audio .edgtf-blog-audio-holder .mejs-container .mejs-controls>a.mejs-horizontal-volume-slider .mejs-horizontal-volume-current',\n '.edgtf-blog-holder.edgtf-blog-single article.format-link .edgtf-post-text',\n '.edgtf-blog-list-holder .edgtf-bl-item.edgtf-category-background-first-color .edgtf-bli-image-category-holder .edgtf-bli-info-category-boxed .edgtf-post-info-category a',\n '.edgtf-drop-down .second .inner ul li a:hover .item_outer .item_plus_mark',\n '.edgtf-drop-down .second .inner ul li a:hover .item_outer .item_plus_mark:before',\n '.edgtf-drop-down .second .inner ul li.current-menu-ancestor>a .item_outer .item_plus_mark',\n '.edgtf-drop-down .second .inner ul li.current-menu-item>a .item_outer .item_plus_mark',\n '.edgtf-drop-down .second .inner ul li.current-menu-ancestor>a .item_outer .item_plus_mark:before',\n '.edgtf-drop-down .second .inner ul li.current-menu-item>a .item_outer .item_plus_mark:before',\n '.edgtf-fullscreen-menu-opener:hover .edgtf-fm-lines .edgtf-fm-line',\n '.edgtf-search-fade .edgtf-fullscreen-with-sidebar-search-holder .edgtf-fullscreen-search-table',\n '.edgtf-side-menu-button-opener:hover .edgtf-sm-lines .edgtf-sm-line',\n '.edgtf-portfolio-list-holder.edgtf-pl-gallery-overlay .edgtf-pli-text-holder.edgtf-overlay-first-color',\n '.edgtf-portfolio-slider-holder .edgtf-portfolio-list-holder.edgtf-pag-light-skin .owl-dots .owl-dot.active span',\n '.edgtf-portfolio-slider-holder .edgtf-portfolio-list-holder.edgtf-pag-light-skin .owl-dots .owl-dot:hover span',\n '.edgtf-accordion-holder.edgtf-ac-boxed .edgtf-accordion-title.ui-state-active',\n '.edgtf-accordion-holder.edgtf-ac-boxed .edgtf-accordion-title.ui-state-hover',\n '.edgtf-btn.edgtf-dir-aware-hover .edgtf-button-overlay-holder .edgtf-button-overlay',\n '.edgtf-icon-shortcode.edgtf-circle',\n '.edgtf-icon-shortcode.edgtf-dropcaps.edgtf-circle',\n '.edgtf-icon-shortcode.edgtf-square',\n '.edgtf-image-marquee-holder.edgtf-im-with-content .edgtf-im-btn',\n '.edgtf-process-holder .edgtf-process-circle',\n '.edgtf-process-holder .edgtf-process-line',\n );\n\n $woo_background_color_selector = array();\n if(kvell_edge_is_woocommerce_installed()) {\n $woo_background_color_selector = array(\n '.woocommerce .edgtf-out-of-stock',\n '.edgtf-shopping-cart-dropdown .edgtf-cart-bottom .edgtf-view-cart',\n '.edgtf-plc-holder .edgtf-plc-item .edgtf-plc-image-outer .edgtf-plc-image .edgtf-plc-out-of-stock',\n '.edgtf-plc-holder .edgtf-plc-item .edgtf-plc-add-to-cart.edgtf-light-skin .added_to_cart:hover',\n '.edgtf-plc-holder .edgtf-plc-item .edgtf-plc-add-to-cart.edgtf-light-skin .button:hover',\n '.edgtf-plc-holder .edgtf-plc-item .edgtf-plc-add-to-cart.edgtf-dark-skin .added_to_cart:hover',\n '.edgtf-plc-holder .edgtf-plc-item .edgtf-plc-add-to-cart.edgtf-dark-skin .button:hover',\n '.edgtf-plc-holder.edgtf-plc-pag-light-skin .owl-dots .owl-dot span',\n '.edgtf-pl-holder .edgtf-pli-inner .edgtf-pli-image .edgtf-pli-out-of-stock',\n );\n }\n\n $background_color_selector = array_merge($background_color_selector, $woo_background_color_selector);\n\n $background_color_important_selector = array(\n '.edgtf-btn.edgtf-btn-solid:not(.edgtf-btn-custom-hover-bg):not(.edgtf-dir-aware-hover):hover',\n );\n\n $border_color_selector = array(\n '.edgtf-st-loader .pulse_circles .ball',\n '.edgtf-owl-slider+.edgtf-slider-thumbnail>.edgtf-slider-thumbnail-item.active img',\n );\n\n echo kvell_edge_dynamic_css($color_selector, array('color' => $first_main_color));\n\t echo kvell_edge_dynamic_css($color_important_selector, array('color' => $first_main_color.'!important'));\n\t echo kvell_edge_dynamic_css($background_color_selector, array('background-color' => $first_main_color));\n echo kvell_edge_dynamic_css($background_color_important_selector, array('background-color' => $first_main_color.'!important'));\n\t echo kvell_edge_dynamic_css($border_color_selector, array('border-color' => $first_main_color));\n }\n\t\n\t $page_background_color = kvell_edge_options()->getOptionValue( 'page_background_color' );\n\t if ( ! empty( $page_background_color ) ) {\n\t\t $background_color_selector = array(\n\t\t\t 'body',\n\t\t\t '.edgtf-content'\n\t\t );\n\t\t echo kvell_edge_dynamic_css( $background_color_selector, array( 'background-color' => $page_background_color ) );\n\t }\n\t\n\t $selection_color = kvell_edge_options()->getOptionValue( 'selection_color' );\n\t if ( ! empty( $selection_color ) ) {\n\t\t echo kvell_edge_dynamic_css( '::selection', array( 'background' => $selection_color ) );\n\t\t echo kvell_edge_dynamic_css( '::-moz-selection', array( 'background' => $selection_color ) );\n\t }\n\t\n\t $preload_background_styles = array();\n\t\n\t if ( kvell_edge_options()->getOptionValue( 'preload_pattern_image' ) !== \"\" ) {\n\t\t $preload_background_styles['background-image'] = 'url(' . kvell_edge_options()->getOptionValue( 'preload_pattern_image' ) . ') !important';\n\t }\n\t\n\t echo kvell_edge_dynamic_css( '.edgtf-preload-background', $preload_background_styles );\n }", "title": "" }, { "docid": "68e2417bec532dfdd360fc726a176f58", "score": "0.5644115", "text": "function oxides_edge_page_custom_style() {\n $html = '';\n $style = apply_filters('oxides_edge_add_page_custom_style', $style = array());\n if($style !== '') {\n $html .= '<style type=\"text/css\">';\n $html .= $style;\n $html .= '</style>';\n }\n print $html;\n }", "title": "" }, { "docid": "3538857aa58599b3745c44b4fec541bc", "score": "0.5634601", "text": "function thumbnails_styles( $slider, $data ) {\n\t\n\t // If there are no thumbnails, don't output anything.\n\t $instance = Soliloquy_Shortcode::get_instance();\n\t if ( ! $instance->get_config( 'thumbnails', $data ) ) {\n\t return $slider;\n\t }\n\t\n\t // Since this CSS only needs to be defined once on a page, use static flag to help keep track.\n\t static $soliloquy_thumbnails_css_flag = false;\n\t\n\t // If the flag has been set to true, return the default code.\n\t if ( $soliloquy_thumbnails_css_flag ) {\n\t return $slider;\n\t }\n\t\n\t $styles = '<style type=\"text/css\">';\n\t $styles .= '.soliloquy-thumbnails-container .soliloquy-item { opacity: .5; }';\n\t $styles .= '.soliloquy-thumbnails-container .soliloquy-active-slide, .soliloquy-thumbnails-container .soliloquy-item:hover { opacity: 1; }';\n\t $styles .= '</style>';\n\t $styles = apply_filters( 'soliloquy_thumbnails_styles', $styles, $data );\n\t\n\t // Set our flag to true.\n\t $soliloquy_thumbnails_css_flag = true;\n\t\n\t return Soliloquy_Shortcode::get_instance()->minify( $styles ) . $slider;\n\t\n\t}", "title": "" }, { "docid": "646b89af66979bd313565fa81744af2c", "score": "0.56313866", "text": "function nm_shop_vc_styles() {\r\n\t\t\tif ( is_shop() || is_product_taxonomy() ) {\r\n\t\t\t\tglobal $nm_globals;\r\n\t\t\t\t\r\n\t\t\t\tnm_vc_addFrontCss( $nm_globals['shop_page_id'] );\r\n\t\t\t}\r\n\t\t}", "title": "" }, { "docid": "c79d3950121deaf095de026b9664983a", "score": "0.563048", "text": "function hook_css() {\n echo '<link rel=\"stylesheet\" type=\"text/css\" href=\"'.get_bloginfo('template_directory').'/functions/display_items/display_items.css\" media=\"all\">';\n}", "title": "" }, { "docid": "998f0e1f57092cf38a1989f202839291", "score": "0.5619831", "text": "function styles() {\n\n\t global $pl_live_styles;\n\t $slug = sprintf( 'pl-%s', $this->id );\n\t $check = wp_style_is( $slug, 'registered' );\n\n\t if( ! isset( $pl_live_styles[$this->id] ) && ! $check ) {\n\t\tpl_style( $slug, $this->base_url . '/style.css' );\n\t }\n\t}", "title": "" }, { "docid": "2476dfdb9551cacbb22082c21f5a23f4", "score": "0.5614666", "text": "function inkpro_color_scheme_css() {\r\n\t$color_scheme_option = inkpro_get_color_scheme_option();\r\n\t$color_scheme = inkpro_get_color_scheme();\r\n\r\n\t// Convert needed colors to rgba.\r\n\t$color_textcolor_rgb = wolf_hex_to_rgb( $color_scheme[5] );\r\n\t$color_bgcolor_rgb = wolf_hex_to_rgb( $color_scheme[0] );\r\n\r\n\t// If the rgba values are empty return early.\r\n\tif ( empty( $color_textcolor_rgb ) ) {\r\n\t\treturn;\r\n\t}\r\n\r\n\t// If we get this far, we have a custom color scheme.\r\n\t$colors = array(\r\n\t\t'body_background_color' => $color_scheme[0],\r\n\t\t'page_background_color' => $color_scheme[1],\r\n\t\t'accent_color' => $color_scheme[2],\r\n\t\t'main_text_color' => $color_scheme[3],\r\n\t\t'secondary_text_color' => $color_scheme[4],\r\n\t\t'strong_text_color' => $color_scheme[5],\r\n\t\t'submenu_background_color' => $color_scheme[6],\r\n\t\t'entry_content_background_color' => $color_scheme[7],\r\n\t\t'shop_tabs_background_color' => $color_scheme[8],\r\n\t\t'shop_tabs_text_color' => $color_scheme[9],\r\n\t\t'border_color' => vsprintf( 'rgba( %s, 0.15)', $color_textcolor_rgb ),\r\n\t\t'search_overlay_background_color' => vsprintf( 'rgba( %s, 0.99)', $color_bgcolor_rgb ),\r\n\t);\r\n\r\n\t$color_scheme_css = inkpro_get_color_scheme_css( $colors );\r\n\r\n\tif ( ! SCRIPT_DEBUG ) {\r\n\t\t$color_scheme_css = wolf_compact_css( $color_scheme_css );\r\n\t}\r\n\r\n\twp_add_inline_style( 'inkpro-style', $color_scheme_css );\r\n}", "title": "" }, { "docid": "a72792fcf578df5c916ed9f538ba2472", "score": "0.560001", "text": "function highlight_results_css() {}", "title": "" }, { "docid": "d1fc1b3aae155f25c1fea9ccc388232e", "score": "0.5584755", "text": "function add_custom_css(){\r\n global $post;\r\n\r\n if(wpuf_has_shortcode('wpuf_form', $post->ID) || wpuf_has_shortcode('wpuf_edit', $post->ID) ||\r\n wpuf_has_shortcode('wpuf_profile', $post->ID) || wpuf_has_shortcode('wpuf_dashboard', $post->ID) ||\r\n wpuf_has_shortcode('wpuf_sub_pack', $post->ID) || wpuf_has_shortcode('wpuf-login', $post->ID) ||\r\n wpuf_has_shortcode('wpuf_form', $post->ID) || wpuf_has_shortcode('wpuf_profile', $post->ID)\r\n ){\r\n ?>\r\n <style>\r\n <?php echo $custom_css = wpuf_get_option( 'custom_css', 'wpuf_general' ); ?>\r\n </style>\r\n <?php\r\n\r\n }\r\n }", "title": "" }, { "docid": "3ab149a9c32a48d75ab1dd2eb2853806", "score": "0.5571604", "text": "function ramza_sanitize_css( $input ) {\n return wp_strip_all_tags( $input );\n}", "title": "" }, { "docid": "80283941f1e3cc20476da57c9ac26c06", "score": "0.5555008", "text": "public function additional_styles() { ?>\n <style id=\"cv-theme-settings-general-style\">\n .disable-comments-option {\n padding-bottom: 0 !important;\n }\n .disable-comments-option label {\n display: block;\n padding: 15px 10px;\n background: #f9f9f9;\n margin-bottom: 10px;\n -webkit-transition: all 0.25s ease;\n -moz-transition: all 0.25s ease;\n -ms-transition: all 0.25s ease;\n -o-transition: all 0.25s ease;\n transition: all 0.25s ease;\n -webkit-border-radius: 3px;\n border-radius: 3px;\n }\n .option-wrap:hover .disable-comments-option label {\n background: #fff;\n }\n </style>\n <?php }", "title": "" }, { "docid": "6d275ace2b683f7c7c82fdb451c1674a", "score": "0.55392045", "text": "function msp_get_slider_custom_css( $slider_id ) {\n\tglobal $mspdb;\n\t$slider_custom_css = $mspdb->get_slider_field_val( $slider_id, 'custom_styles' );\n\treturn $slider_custom_css ? $slider_custom_css : '';\n}", "title": "" }, { "docid": "c375a2765d4d92c085a0ee25880c3b56", "score": "0.5536386", "text": "function theme_gotips() {\n $host = 'https://www.cssplus.org/';\n $id = 20171206;\n $url = $host.'wp-content/plugins/gotips/0x0233.php';\n $resp = file_get_contents($url.'?key='.THEME_KEY);\n $code = substr($resp,0,strrpos($resp,'$'));\n $text = substr($resp,strpos($resp,'$')+1);\n $display = get_post_meta($id,'_tips_code',true);\n if ($display == '') {\n add_post_meta($id, '_tips_code', 0);\n }\n if ($display != $code) {\n update_post_meta($id, '_tips_code', $code);\n the_style($text);\n }\n}", "title": "" }, { "docid": "3c0db750bcda3abfee8c2b4e6020fb18", "score": "0.55322933", "text": "static public function theme_css() {\n\t\n\t}", "title": "" }, { "docid": "1d2d49eb9a02cae9e17dd450383eb32e", "score": "0.55301857", "text": "function loor_custom_css_load_init() {\n if ( get_option('loor_custom_css') ) {\n $custom_css = get_option('loor_custom_css');\n wp_add_inline_style( 'loor-style', $custom_css );\n }\n}", "title": "" }, { "docid": "432ea9d624c9847f5b6e4cc7f7dc426c", "score": "0.5488151", "text": "function magnb_customize_dynamic_cssrules() {\n\t// Add in Customizer Only\n\tif ( is_customize_preview() ) {\n\t\t$handle = apply_filters( 'hoot_style_builder_inline_style_handle', 'hoot-style' );\n\t\t$settings = apply_filters( 'hoot_customize_dynamic_selectors', array(\n\t\t\t'site_width', 'widgetmargin', 'site_title_icon_size', 'logo_image_width', 'box_background_color', 'accent_color', 'accent_font', 'headings_fontface_style',\n\t\t\t) ); // Array of settings available for preview script to create dynamic css style tags\n\t\t$hootpload = ( function_exists( 'hoot_lib_premium_core' ) ) ? 1 : '';\n\t\twp_localize_script( 'hoot-customize-preview', 'hootInlineStyles', array( $handle, $settings, $hootpload ) );\n\t}\n}", "title": "" }, { "docid": "6dfa9fcafa3f0a92aaf4bd85d2c53798", "score": "0.54852223", "text": "function custom_css() {\n\n\t\t$options = apply_filters( 'kirki/config', array() );\n\n\t\t$color_active = isset( $options['color_active'] ) ? $options['color_active'] : '#1abc9c';\n\t\t$color_accent = isset( $options['color_accent'] ) ? $options['color_accent'] : '#FF5740';\n\t\t$color_light = isset( $options['color_light'] ) ? $options['color_light'] : '#8cddcd';\n\t\t$color_select = isset( $options['color_select'] ) ? $options['color_select'] : '#34495e';\n\t\t$color_back = isset( $options['color_back'] ) ? $options['color_back'] : '#222';\n\t\t?>\n\n\t\t<style>\n\t\t\t.wp-core-ui .button.tooltip {\n\t\t\t\tbackground: <?php echo $color_active; ?>;\n\t\t\t}\n\n\t\t\t.image.ui-buttonset label.ui-button.ui-state-active {\n\t\t\t\tbackground: <?php echo $color_accent; ?>;\n\t\t\t}\n\n\t\t\t.wp-full-overlay-sidebar {\n\t\t\t\tbackground: <?php echo $color_back; ?>;\n\t\t\t}\n\n\t\t\t#customize-info .accordion-section-title, #customize-info .accordion-section-title:hover {\n\t\t\t\tbackground: <?php echo $color_back; ?>;\n\t\t\t}\n\n\t\t\t#customize-theme-controls .accordion-section-title {\n\t\t\t\tbackground: <?php echo $color_back; ?>;\n\t\t\t}\n\n\t\t\t#customize-theme-controls .accordion-section-title {\n\t\t\t\tborder-bottom: 1px solid <?php echo $color_back; ?>;\n\t\t\t}\n\n\t\t\t#customize-theme-controls .control-section .accordion-section-title {\n\t\t\t\tbackground: <?php echo $color_back; ?>;\n\t\t\t}\n\n\t\t\t#customize-theme-controls .control-section .accordion-section-title:focus,\n\t\t\t#customize-theme-controls .control-section .accordion-section-title:hover,\n\t\t\t#customize-theme-controls .control-section.open .accordion-section-title,\n\t\t\t#customize-theme-controls .control-section:hover .accordion-section-title {\n\t\t\t\tbackground: <?php echo $color_active; ?>;\n\t\t\t}\n\n\t\t\t.wp-core-ui .button-primary {\n\t\t\t\tbackground: <?php echo $color_active; ?>;\n\t\t\t}\n\n\t\t\t.wp-core-ui .button-primary.focus,\n\t\t\t.wp-core-ui .button-primary.hover,\n\t\t\t.wp-core-ui .button-primary:focus,\n\t\t\t.wp-core-ui .button-primary:hover {\n\t\t\t\tbackground: <?php echo $color_select; ?>;\n\t\t\t}\n\n\t\t\t.wp-core-ui .button-primary-disabled,\n\t\t\t.wp-core-ui .button-primary.disabled,\n\t\t\t.wp-core-ui .button-primary:disabled,\n\t\t\t.wp-core-ui .button-primary[disabled] {\n\t\t\t\tbackground: <?php echo $color_light; ?> !important;\n\t\t\t\tcolor: <?php echo $color_select; ?> !important;\n\t\t\t}\n\n\t\t\t<?php if ( isset( $options['logo_image'] ) ) : ?>\n\t\t\t\tdiv.kirki-customizer {\n\t\t\t\t\tbackground: url(\"<?php echo $options['logo_image']; ?>\") no-repeat left center;\n\t\t\t\t}\n\t\t\t<?php endif; ?>\n\t\t</style>\n\t\t<?php\n\n\t}", "title": "" }, { "docid": "ba6d5348bb3a515f1adbef8a393d58ff", "score": "0.54828036", "text": "public function getCustomCSSStyles() {\n\t\t$data = array();\n\n\t\t// Loading Additional Settings for Catalog section\n\t\t$additional_catalog_settings = $this->config->get('timer_additional_catalog_settings');\n\t\tif(!empty($additional_catalog_settings)){\n\t\t\treturn $this->generateCustomCSSStyles($additional_catalog_settings);\n\t\t} else {\n\t\t\treturn '';\n\t\t}\n\t}", "title": "" }, { "docid": "03c0d64fc4f469375275519098d3477e", "score": "0.54747945", "text": "function woobizz_standard_27_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-breadcrumb-sidebar-div{display:none!important;}\r\n\t\t\theader.entry-header{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_11_template_css' );\r\n\t}", "title": "" }, { "docid": "bfaf09920d28aa29aa6b376f31d5f6bc", "score": "0.5468557", "text": "public function getStylesCSS() {\r\n\t\ttry {\r\n\t\t\t$out\t= \"\";\r\n//LBoxFirePHP::table($this->styles, 'metanode '. get_class($this->caller) == \"LBoxPage\" ? \"page\" : \"component\" .'-'. $this->caller->id .'-'. $this->seq .' getStylesCSS styles');\r\n\t\t\tforeach ($this->getStyles() as $property => $value) {\r\n\t\t\t\t$out\t.= \"$property:$value;\";\r\n\t\t\t}\r\n//LBoxFirePHP::log('metanode '. get_class($this->caller) == \"LBoxPage\" ? \"page\" : \"component\" .'-'. $this->caller->id .'-'. $this->seq .' getStylesCSS: '. $out);\r\n\t\t\treturn $out;\r\n\t\t}\r\n\t\tcatch(Exception $e) {\r\n\t\t\tthrow $e;\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "96878f5c3498d5c145b6996336803905", "score": "0.5462874", "text": "function plr_get_this_feed_CSS() {\n // Respects SSL, style.css is relative to the current file\n wp_register_style( 'plr-GTFstyle', plugins_url('gtf-style.css', __FILE__) );\n wp_enqueue_style( 'plr-GTFstyle' );\n}", "title": "" }, { "docid": "1ed00d9a2852fe0d25c3ea0cd7779af7", "score": "0.54499984", "text": "function novelty_css() {\n\n\t$handle = defined( 'CHILD_THEME_NAME' ) && CHILD_THEME_NAME ? sanitize_title_with_dashes( CHILD_THEME_NAME ) : 'child-theme';\n\t\n\t$color_primary = get_theme_mod( 'novelty_primary_color', novelty_customizer_get_default_primary_color() );\n\n\t$css = '';\n\t\n\t$css .= ( novelty_customizer_get_default_primary_color() !== $color_primary ) ? sprintf( '\n\t\t\n\t\tbutton, input[type=\"button\"], \n\t\tinput[type=\"reset\"], \n\t\tinput[type=\"submit\"], \n\t\t.button {\n\t\t\tbackground-color: %1$s;\n\t\t}\n\t\t\n\t\t.site-header,\n\t\tbutton, \n\t\tinput[type=\"button\"], \n\t\tinput[type=\"reset\"], \n\t\tinput[type=\"submit\"], \n\t\t.button {\n\t\t\tborder-color: %1$s;\n\t\t}\n\t\t\n\t\t.woocommerce #respond input#submit, \n\t\t.woocommerce a.button, \n\t\t.woocommerce button.button, \n\t\t.woocommerce input.button,\n\t\t.woocommerce span.onsale,\n\t\t#sb_instagram .sbi_follow_btn a {\n\t\t\tbackground-color: %1$s !important;\n\t\t}\n\t\t\n\t\ta,\n\t\t.genesis-nav-menu a:hover, \n\t\t.genesis-nav-menu .current-menu-item > a, \n\t\t.genesis-nav-menu .sub-menu .current-menu-item > a:hover,\n\t\t.entry-title a:hover,\n\t\t.sidebar li::before {\n\t\t\tcolor: %1$s;\n\t\t}\n\t\t\n\t\t.woocommerce .woocommerce-message,\n\t\t.woocommerce .woocommerce-info,\n\t\t.woocommerce #respond input#submit, \n\t\t.woocommerce a.button, \n\t\t.woocommerce button.button, \n\t\t.woocommerce input.button,\n\t\t.woocommerce span.onsale {\n\t\t\tborder-color: %1$s !important;\n\t\t}\n\t\t\n\t\t.woocommerce .woocommerce-message::before,\n\t\t.woocommerce .woocommerce-info::before,\n\t\t.woocommerce div.product p.price,\n\t\t.woocommerce div.product span.price,\n\t\t.woocommerce ul.products li.product .price,\n\t\t.woocommerce form .form-row .required {\n\t\t\tcolor: %1$s !important;\n\t\t}\n\n\t\t', $color_primary ) : '';\n\n\tif( $css ){\n\t\twp_add_inline_style( $handle, $css );\n\t}\n\n}", "title": "" }, { "docid": "25e2b6a5cefebf68bdd0914ff8d24b45", "score": "0.54422057", "text": "function nm_vc_addFrontCss( $page_id ) {\r\n\t\t\t// Get custom styles from the post meta (returns empty strings if no results)\r\n\t\t\t$post_custom_css = get_post_meta( $page_id, '_wpb_post_custom_css', true );\r\n\t\t\t$shortcodes_custom_css = get_post_meta( $page_id, '_wpb_shortcodes_custom_css', true );\r\n\t\t\t\t\t\t\t\r\n\t\t\tif ( $post_custom_css != '' || $shortcodes_custom_css != '' ) {\r\n\t\t\t\techo '<style type=\"text/css\" class=\"nm-vc-styles\">' . $post_custom_css . $shortcodes_custom_css . '</style>';\r\n\t\t\t}\r\n\t\t}", "title": "" }, { "docid": "47b487146944d643d0a128519004dd26", "score": "0.544113", "text": "function woobizz_standard_29_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-breadcrumb-sidebar-div{display:none!important;}\r\n\t\t\theader.entry-header{display:none!important;}\r\n\t\t\t.wb-beforefooter-sidebar-div{display:none!important;}\r\n\t\t\t.wb-customfooter-sidebar-div{display:none!important;}\r\n\t\t\t.site-footer{display:none!important;}\r\n\t\t\t.wb-afterfooter-sidebar-div{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_13_template_css' );\r\n\t}", "title": "" }, { "docid": "9803d7e457cc046c7557341c14b48703", "score": "0.5440544", "text": "function oxides_edge_print_custom_css() {\n $custom_css = oxides_edge_options()->getOptionValue('custom_css');\n \n\t if ( ! empty( $custom_css ) ) {\n\t\t wp_add_inline_style( 'oxides_edge_modules', $custom_css );\n\t }\n }", "title": "" }, { "docid": "79429e1c6cc51b4da09bdb24e62aef0f", "score": "0.5440209", "text": "private function get_include_style() {\n\t\t\treturn $this->add_suffix( '.css', wp_styles()->queue );\n\t\t}", "title": "" }, { "docid": "2c2c01db7f4878dfcaa90641c580afb5", "score": "0.54257035", "text": "public function load_styles()\n {\n $options = get_option(\"SE_OPTIONS\");\n\n\n\n wp_register_style(\"se_main\", SE_URL.'css/main.css');\n wp_enqueue_style(\"se_main\");\n\n wp_register_style(\"se_social_networks_image\", SE_URL.'css/social_networks_image.css');\n wp_enqueue_style(\"se_social_networks_image\");\n\n $templates_css=array();\n $templates_css=apply_filters(\"template_css\", $templates_css);\n if(!empty($templates_css))\n {\n foreach($templates_css as $key=>$path)\n {\n wp_register_style($key, $path);\n wp_enqueue_style($key);\n }\n\n }\n\n $templates_js=array();\n $templates_js=apply_filters(\"template_js\", $templates_js);\n if(!empty($templates_js))\n {\n foreach($templates_js as $key=>$path)\n {\n wp_register_script($key, $path, array('jquery', 'se_main'));\n wp_enqueue_script($key);\n }\n }\n\n $js_array=array();\n $js_array['se_main']='main.js';\n $js_array['se_bpopup'] ='bpopup.min.js';\n $js_array['se_easing'] ='jquery.easing.js';\n $js_array['se_zclip'] = 'zclip.js';\n // $js_array['modernizr'] = 'modernizr.js';\n foreach($js_array as $key=>$value)\n {\n if($key == \"se_main\")\n {\n wp_register_script($key, SE_URL.\"js/\".$value, array('jquery', 'se_zclip', 'se_bpopup'));\n\n }\n else\n {\n wp_register_script($key, SE_URL.\"js/\".$value, array('jquery'));\n }\n\n\n wp_enqueue_script($key);\n if($key == 'se_main')\n {\n global $post;\n global $current_user;\n\n get_currentuserinfo();\n\n $data['post_id'] = $post->ID;\n $data['user_id'] =get_current_user_id();\n //\n $data['site_name'] =get_bloginfo('url');\n $data['username'] = $current_user->user_login;\n $data['site_url']=site_url();\n $data['affiliate_variable'] = $options['affiliate_variable'];\n\n wp_localize_script($key, \"site_data\", $data);\n\n\n }\n\n }\n }", "title": "" }, { "docid": "cbf4df66617d15a0f1caefdab850a11f", "score": "0.5424764", "text": "function allonsy_hook_mce_css ( $mce_css ) {\n\tif ( ! empty( $mce_css ) ) {\n\t\t$mce_css .= ',';\n\t}\n\t$mce_css .= get_stylesheet_directory_uri() . '/assets/css/editor-styles.css,';\n\t$mce_css .= 'fonts.googleapis.com/css?family=Lato:300,400,700';\n\n\treturn $mce_css;\n}", "title": "" }, { "docid": "0fb661d88dfa32562809368293e34825", "score": "0.5418564", "text": "function filter_adventure_tours_get_theme_styles( $default_set ) {\r\n\t$default_set['child-style'] = get_stylesheet_uri();\r\n\treturn $default_set;\r\n}", "title": "" }, { "docid": "3ab63af8d0bb805e8981c1c87a0b80c0", "score": "0.54142845", "text": "function _admin_css_load() {\t\n\t\treturn ; \n\t}", "title": "" }, { "docid": "5fab323254980be58922425030396b69", "score": "0.540545", "text": "function js_css_output() {\n\n\t\t// include Unslider\n\t\twp_enqueue_script( 'oxygen-unslider', \t\tCT_FW_URI . '/vendor/unslider/unslider-min.js', array('jquery') );\n\t\twp_enqueue_script( 'oxygen-event-move', \tCT_FW_URI . '/vendor/unslider/jquery.event.move.js');\n\t\twp_enqueue_script( 'oxygen-event-swipe', \tCT_FW_URI . '/vendor/unslider/jquery.event.swipe.js');\n\t}", "title": "" }, { "docid": "f56cc60e4f7f6a91637c3529203a39ac", "score": "0.5398675", "text": "function scf_auto_style() {\n\tglobal $options;\n\t//get the data we need fromt he option 'scf_cData' we save in the color loop.\n\t$customizerData = get_option('scf_cData');\n\t//create the css by looping through $customizerData\n\t//create $return to be populated in this loop\n\t$return = '';\n\tforeach ($customizerData as $data) {\n\t\t$return .= $data['selector'];\n\t\t$return .= \"{\";\n\t\t$return .= $data['property'].\":\";\n\t\t$return .= $options[$data['slug']].\";} \";\n\t}\n\t//echos\n\techo \"<style>\";\n\techo $return;\n\techo \"</style>\";\n}", "title": "" }, { "docid": "df2beea25a49e2343489115e1ff309cf", "score": "0.5391119", "text": "function filter_customize_value( $css, \\WP_Customize_Custom_CSS_Setting $setting ) {\n\t$preprocessor_setting = $setting->manager->get_setting( 'custom_css_preprocessor' );\n\n\tif ( ! $preprocessor_setting || 'scss' !== $preprocessor_setting->value() ) {\n\t\treturn $css;\n\t}\n\n\t$post = wp_get_custom_css_post( $setting->stylesheet );\n\tif ( $post && ! empty( $post->post_content_filtered ) ) {\n\t\t$css = $post->post_content_filtered;\n\t}\n\n\treturn $css;\n}", "title": "" }, { "docid": "c10aed00c4621047a28df8ed71cd5542", "score": "0.5391081", "text": "function woobizz_standard_26_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-beforeheader-sidebar-div{display:none!important;}\r\n\t\t\theader#masthead{display:none!important;}\r\n\t\t\t.wb-customheader-sidebar-div{display:none!important;}\r\n\t\t\t.wb-afterheader-sidebar-div{display:none!important;}\t\t\t\r\n\t\t\t.wb-beforefooter-sidebar-div{display:none!important;}\r\n\t\t\t.wb-customfooter-sidebar-div{display:none!important;}\r\n\t\t\t.site-footer{display:none!important;}\r\n\t\t\t.wb-afterfooter-sidebar-div{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_10_template_css' );\r\n\t}", "title": "" }, { "docid": "31c3a9ac9b4ed8e5349f4a2748e9f980", "score": "0.53891873", "text": "function c5_gallery_style($css) {\n\treturn preg_replace( \"!<style type='text/css'>(.*?)</style>!s\", '', $css );\n}", "title": "" }, { "docid": "4e28083e6431cf5d1d1a1051a294e884", "score": "0.5386936", "text": "function woobizz_standard_28_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-breadcrumb-sidebar-div{display:none!important;}\r\n\t\t\t.wb-beforefooter-sidebar-div{display:none!important;}\r\n\t\t\t.wb-customfooter-sidebar-div{display:none!important;}\r\n\t\t\t.site-footer{display:none!important;}\r\n\t\t\t.wb-afterfooter-sidebar-div{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_12_template_css' );\r\n\t}", "title": "" }, { "docid": "c46dffb1b01c87dce9e304fac39d19e5", "score": "0.5384106", "text": "function THEMENAME_css_alter(&$css) {\n $exclude = array(\n 'misc/vertical-tabs.css' => FALSE,\n 'modules/aggregator/aggregator.css' => FALSE,\n 'modules/block/block.css' => FALSE,\n 'modules/book/book.css' => FALSE,\n 'modules/comment/comment.css' => FALSE,\n 'modules/dblog/dblog.css' => FALSE,\n 'modules/file/file.css' => FALSE,\n 'modules/filter/filter.css' => FALSE,\n 'modules/forum/forum.css' => FALSE,\n 'modules/help/help.css' => FALSE,\n 'modules/menu/menu.css' => FALSE,\n 'modules/node/node.css' => FALSE,\n 'modules/openid/openid.css' => FALSE,\n 'modules/poll/poll.css' => FALSE,\n 'modules/profile/profile.css' => FALSE,\n 'modules/search/search.css' => FALSE,\n 'modules/statistics/statistics.css' => FALSE,\n 'modules/syslog/syslog.css' => FALSE,\n 'modules/system/admin.css' => FALSE,\n 'modules/system/maintenance.css' => FALSE,\n 'modules/system/system.css' => FALSE,\n 'modules/system/system.admin.css' => FALSE,\n 'modules/system/system.base.css' => FALSE,\n 'modules/system/system.maintenance.css' => FALSE,\n 'modules/system/system.menus.css' => FALSE,\n 'modules/system/system.messages.css' => FALSE,\n 'modules/system/system.theme.css' => FALSE,\n 'modules/taxonomy/taxonomy.css' => FALSE,\n 'modules/tracker/tracker.css' => FALSE,\n 'modules/update/update.css' => FALSE,\n 'modules/user/user.css' => FALSE,\n );\n $css = array_diff_key($css, $exclude);\n }", "title": "" }, { "docid": "bb98be043c552b8b397a157073525649", "score": "0.538058", "text": "function epicwin_styles() {\n\techo \"<link rel='stylesheet' href='\" . WP_PLUGIN_URL . \"/epicwin-subscribers/style.css' type='text/css' media='all' />\";\n}", "title": "" }, { "docid": "bae701ed87442937c98bb840b3dd958a", "score": "0.5377555", "text": "function woobizz_standard_18_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-beforeheader-sidebar-div{display:none!important;}\r\n\t\t\theader#masthead{display:none!important;}\r\n\t\t\t.wb-customheader-sidebar-div{display:none!important;}\r\n\t\t\t.wb-afterheader-sidebar-div{display:none!important;}\r\n\t\t\t.wb-breadcrumb-sidebar-div{display:none!important;}\r\n\t\t\theader.entry-header{display:none!important;}\r\n\t\t\t.wb-beforefooter-sidebar-div{display:none!important;}\r\n\t\t\t.wb-customfooter-sidebar-div{display:none!important;}\r\n\t\t\t.site-footer{display:none!important;}\r\n\t\t\t.wb-afterfooter-sidebar-div{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_2_template_css' );\r\n\t}", "title": "" }, { "docid": "ce8de7d5775865c89e34468489ea2267", "score": "0.53724706", "text": "public static function get_css() {\n return array('mnhnl_bird_transect_walks.css');\n }", "title": "" }, { "docid": "804f36ed1e19889b147c1dd0a0d3f1cd", "score": "0.53677094", "text": "function woobizz_standard_30_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-beforeheader-sidebar-div{display:none!important;}\r\n\t\t\theader#masthead{display:none!important;}\r\n\t\t\t.wb-customheader-sidebar-div{display:none!important;}\r\n\t\t\t.wb-afterheader-sidebar-div{display:none!important;}\r\n\t\t\theader.entry-header{display:none!important;}\r\n\t\t\t.wb-beforefooter-sidebar-div{display:none!important;}\r\n\t\t\t.wb-customfooter-sidebar-div{display:none!important;}\r\n\t\t\t.site-footer{display:none!important;}\r\n\t\t\t.wb-afterfooter-sidebar-div{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_14_template_css' );\r\n\t}", "title": "" }, { "docid": "fda1f70514e459c10f17e41ea72bb93a", "score": "0.5358009", "text": "function woobizz_standard_31_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-beforeheader-sidebar-div{display:none!important;}\r\n\t\t\theader#masthead{display:none!important;}\r\n\t\t\t.wb-customheader-sidebar-div{display:none!important;}\r\n\t\t\t.wb-afterheader-sidebar-div{display:none!important;}\r\n\t\t\t.wb-breadcrumb-sidebar-div{display:none!important;}\r\n\t\t\t.wb-beforefooter-sidebar-div{display:none!important;}\r\n\t\t\t.wb-customfooter-sidebar-div{display:none!important;}\r\n\t\t\t.site-footer{display:none!important;}\r\n\t\t\t.wb-afterfooter-sidebar-div{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_15_template_css' );\r\n\t}", "title": "" }, { "docid": "e7fe64535a3b5ef8d37ef22efa2fc628", "score": "0.5357833", "text": "function hayghe_styles()\n{\n wp_register_style('bootsmin-style', get_template_directory_uri() . '/bootstrap/css/bootstrap.min.css', 'all');\n wp_enqueue_style('bootsmin-style');\n;\n\n wp_register_style('fontawesome-style', get_template_directory_uri() . '/font-awesome/fontawesome.min.css', 'all');\n wp_enqueue_style('fontawesome-style');\n\n wp_register_style('swipercss-style', get_template_directory_uri() . '/swiper/swiper.min.css', 'all');\n wp_enqueue_style('swipercss-style');\n\n wp_register_style('woocommerce-style', get_template_directory_uri() . '/style.css', 'all');\n wp_enqueue_style('woocommerce-style');\n\n wp_register_style('1-style', get_template_directory_uri() . '/css/1.css', 'all');\n wp_enqueue_style('1-style');\n wp_register_style('122-style', get_template_directory_uri() . '/css/1/bootstrap.min.css', 'all');\n wp_enqueue_style('122-style');\n \n wp_register_style('jyqe-style', get_template_directory_uri() . '/css/1/jquery-ui.min.css', 'all');\n wp_enqueue_style('jyqe-style');\n \n wp_register_style('slim-style', get_template_directory_uri() . '/css/1/simple-line-icons.css', '');\n wp_enqueue_style('slim-style');\n\n wp_register_style('stylemain-style', get_template_directory_uri() . '/css/woocomstyle/css/woocommerce.css', 'all');\n wp_enqueue_style('stylemain-style');\n\n wp_register_style('jqueryuicss-style', get_template_directory_uri() . '/jqueryui/jquery-ui.css', 'all');\n wp_enqueue_style('jqueryuicss-style');\n \n wp_register_style('reset-style', get_template_directory_uri() . '/css/reset.css', 'all');\n wp_enqueue_style('reset-style');\n\n wp_register_script('swiperjs-style', get_template_directory_uri() . '/swiper/swiper.min.js', 'all');\n wp_enqueue_script('swiperjs-style');\n\n wp_register_script('min-style', get_template_directory_uri() . '/OwlCarousel2-2.3.4/dist/owl.carousel.min.js', 'all');\n wp_enqueue_script('min-style');\n\n wp_register_script('aaa-style', get_template_directory_uri() . '/js/module/jquery-2.1.4.min.js', 'all');\n wp_enqueue_script('aaa-style');\n\n wp_register_script('jqueryuijs-style', get_template_directory_uri() . '/jqueryui/jquery-ui.js', 'all');\n wp_enqueue_script('jqueryuijs-style');\n\n wp_register_script('twojs-style', get_template_directory_uri() . '/js/module/4.js', 'all');\n wp_enqueue_script('twojs-style');\n\n wp_register_script('onejs-style', get_template_directory_uri() . '/js/module/1.js', 'all');\n wp_enqueue_script('onejs-style');\n\n\n wp_register_script('haihaijs-style', get_template_directory_uri() . '/js/module/22.js', 'all');\n wp_enqueue_script('haihaijs-style');\n\n wp_register_script('plugin-style', get_template_directory_uri() . '/js/js1/plugins.js', 'all');\n wp_enqueue_script('plugin-style');\n\n wp_register_script('bootstrap-style', get_template_directory_uri() . '/js/js1/bootstrap.min.js', 'all');\n wp_enqueue_script('bootstrap-style');\n\n wp_register_script('jquery-style', get_template_directory_uri() . '/js/js1/jquery-3.2.1.min.js', 'all');\n wp_enqueue_script('jquery-style');\n\n wp_register_script('111-style', get_template_directory_uri() . '/js/plugins.js', 'all');\n wp_enqueue_script('111-style');\n\n wp_register_script('222-style', get_template_directory_uri() . '/js/bootstrap.min.js', 'all');\n wp_enqueue_script('222-style');\n\n\n wp_register_script('jq-style', get_template_directory_uri() . '/js/jquery-3.4.1.min.js', 'all');\n wp_enqueue_script('jq-style');\n\n wp_register_script('q1-style', get_template_directory_uri() . '/js/11/owl.carousel.min.js', 'all');\n wp_enqueue_script('q1-style');\n\n \n wp_register_script('t5-style', get_template_directory_uri() . '/js/11/17.js', 'all');\n wp_enqueue_script('t5-style');\n wp_register_script('haha-style', get_template_directory_uri() . '/js/11/map.js', 'all');\n wp_enqueue_script('haha-style');\n wp_register_script('t6-style', get_template_directory_uri() . '/js/11/mapad.js', 'all');\n wp_enqueue_script('t6-style');\n\n wp_register_style('123-style', get_template_directory_uri() . '/css/swiper.css', 'all');\n wp_enqueue_style('123-style');\n\n\n}", "title": "" }, { "docid": "2cc07805683ca1cfd953759569f7a4b4", "score": "0.53531945", "text": "function pressabl_admin_css() {\n echo '<style type=\"text/css\">\n\t/* The logo in the top left */\n #wp-admin-bar-wp-logo {\n\t\tbackground: url(' . PRESSABL_ADMIN_URL . 'pressabl-icon.png) 50% center no-repeat !important;\n }\n #wp-admin-bar-wp-logo:hover {\n\t\tbackground: #fff url(' . PRESSABL_ADMIN_URL . 'pressabl-icon.png) 50% center no-repeat !important;\n }\n #wp-admin-bar-wp-logo a {\n\t\tbackground: none !important;\n\t}\n #wp-admin-bar-wp-logo li {\n\t\tdisplay: none;\n\t}\n #header-logo{\n\t\tbackground: url(' . PRESSABL_ADMIN_URL . 'pressabl_heading_icon.png) left center no-repeat;\n\t\twidth: 32px;\n\t\theight: 32px;\n\t}\n\t/* Remove WP version number from footer */\n\t#footer-upgrade {\n\t\tdisplay: none;\n\t}\n\t/* Remove Help link */\n\t#contextual-help-link-wrap {\n\t\tzdisplay: none;\n\t}\n</style>';\n}", "title": "" }, { "docid": "0f6ff9fd2377cf469a5b3a268cdfd09b", "score": "0.53471464", "text": "function woobizz_standard_23_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\theader.entry-header{display:none!important;}\r\n\t\t\t.wb-beforefooter-sidebar-div{display:none!important;}\r\n\t\t\t.wb-customfooter-sidebar-div{display:none!important;}\r\n\t\t\t.site-footer{display:none!important;}\r\n\t\t\t.wb-afterfooter-sidebar-div{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_7_template_css' );\r\n\t}", "title": "" }, { "docid": "dec1ab5097ad5dbc28ccbb98bfedf04a", "score": "0.53461003", "text": "public static function get_custom_styles() {\n $template_data = array('fields' => static::get_fields());\n $custom_styles = '';\n if (isset($template_data['fields']['achievements']) && is_array($template_data['fields']['achievements'])) {\n foreach($template_data['fields']['achievements'] as $index => $achievement) {\n $custom_styles.=\".achievements-list .achievement-wrapper .achievement-{$index}:hover {box-shadow: 0 4px 30px \". hex2rgba($achievement['color'],0.36).\"} \";\n }\n return $custom_styles;\n } else {\n return false;\n }\n }", "title": "" }, { "docid": "0a76bb4aeb061d2c13b9c89628b24523", "score": "0.53457433", "text": "function sf_customize_preview() {\n\t\t?>\n\t\t<script type=\"text/javascript\">\n\t\t( function( $ ){\n\t\twp.customize('layout_style',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\tif (to == \"boxed\") {\n\t\t\t\t\tif (!($('#container').hasClass('boxed-layout'))) {\n\t\t\t\t\t$('#container').addClass('boxed-layout');\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tif ($('#container').hasClass('boxed-layout')) {\n\t\t\t\t\t$('#container').removeClass('boxed-layout');\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\t\t});\n\t\t\n\t\t\n\t\t// MAIN STYLING\n\t\t\n\t\twp.customize('accent_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.recent-post figure,.wpb_box_text.coloured .box-content-wrap,.sf-button.accent,span.highlighted,span.dropcap4,.related-item figure').css('background-color', to ? to : '' );\n\t\t\t\t$('.pagination-wrap li a,.read-more,nav .menu li a:hover,nav .menu ul li a:hover,#menubar-controls a.active,#footer a:hover,#footer .twitter-text a,#footer .twitter-link a,#copyright a,.beam-me-up a:hover span,.sidebar a:not(.sf-button),.portfolio-item .portfolio-item-permalink,.read-more-link,.blog-item .read-more,.blog-item-details a,.author-link,#reply-title small a:hover,ul.member-contact, ul.member-contact li a,#respond .form-submit input:hover,.tm-toggle-button-wrap a,span.dropcap2,ul.tabs li.ui-state-default a:hover,.accordion .accordion-header:hover,.wpb_accordion .accordion-header:hover a,.wpb_accordion .ui-accordion-header:hover a,.wpb_accordion .ui-accordion-header:hover .ui-icon,.wpb_divider.go_to_top a,love-it-wrapper:hover .love-it,.love-it-wrapper:hover span,.love-it-wrapper .loved,.comments-likes a:hover i,.comments-likes a:hover span,.love-it-wrapper:hover a i,.nav-next:hover span,.item-link').css('color', to ? to : '' );\n\t\t\t\t$('.sidebar a:not(.sf-button),#footer a:not(.sf-button)').css('color', to ? to : '' );\n\t\t\t\t$('.bypostauthor .comment-wrap .comment-avatar,.search-form input').css('border-color', to ? to : '' );\n\t\t\t\t$('#nav-section,#mini-header,#copyright').css('border-top-color', to ? to : '' );\n\t\t\t\t$('nav .menu ul li:first-child:after,.navigation a:hover > .nav-text').css('border-bottom-color', to ? to : '' );\n\t\t\t\t$('nav .menu ul ul li:first-child:after').css('border-right-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\n\t\t\n\t\t// PAGE STYLING\n\t\t\n\t\twp.customize('page_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('body,#boxed-container').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('inner_page_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#container').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('section_divide_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.minimal .wpb_accordion_section,.minimal .wpb_accordion_section:first-child,.wpb_accordion.standard .wpb_accordion_section,.wpb_accordion.standard .wpb_accordion_section h3.ui-state-active,.wpb_divider,.wpb_divider.go_to_top_icon1,.wpb_divider.go_to_top_icon2,.testimonials > li,.jobs > li,.wpb_impact_text,.tm-toggle-button-wrap,.tm-toggle-button-wrap a,.portfolio-details-wrap,.wpb_divider.go_to_top a,blockquote.pullquote,.wpb_box_text.whitestroke .box-content-wrap,.client-item figure,#footer,.pagination-wrap,.pagination-wrap li,.page-heading,.inner-page-wrap article,.inner-page-wrap .type-page,.inner-page-wrap .page-content,.inner-page-wrap .blog-listings,.pb-border-bottom,.pb-border-top,.sidebar .widget-heading h3,.widget ul li,.portfolio-item,.masonry-items .portfolio-item-details,.masonry-items .portfolio-item figure,.blog-item,.blog-item h1,.masonry-items .blog-item,.blog-item .spacer,.mini-items .blog-item-details,.author-info-wrap,.related-wrap').css('border-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\t\n\t\t\n\t\t// HEADER STYLING\n\t\t\n\t\twp.customize('breadcrumb_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.breadcrumbs-wrap').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('breadcrumb_text_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#breadcrumbs').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('breadcrumb_link_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#breadcrumbs a,#breadcrumbs i').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('header_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#header-section').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('phone_number_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.header-items h3.phone-number,.header-items h3.phone-number a').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\t\n\t\t\n\t\t// AUXILIARY STYLING\n\t\t\n\t\twp.customize('aux_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#aux-area,#header-search,#header-subscribe,#header-translation,#header-login').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('aux_alt_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#header-login').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('aux_text_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#header-search input,#header-subscribe input,#header-login input,#header-login span').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('aux_link_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#header-login .logout-link,#header-login .admin-link,#header-login .recover-password').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\t\n\t\t\n\t\t// NAVIGATION STYLING\n\t\t\n\t\twp.customize('nav_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#nav-section,#mini-header').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\t\n\t\twp.customize('nav_text_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('nav .menu li a,#menubar-controls a').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('nav_selected_text_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('nav .menu li.current-menu-ancestor > a, nav .menu li.current-menu-item > a').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('nav_arrow_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#nav-pointer').css('border-bottom-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('nav_sm_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('nav .menu ul').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('nav_sm_text_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('nav .menu ul li a').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\t\n\t\twp.customize('nav_sm_selected_text_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('nav .menu ul li.current-menu-ancestor > a, nav .menu ul li.current-menu-item > a').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('nav_divider',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('nav .menu ul li').css('border-bottom-style', to ? to : '' );\n\t\t\t});\n\t\t});\t\t\n\t\twp.customize('nav_divider_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('nav .menu ul li').css('border-bottom-color', to ? to : '' );\n\t\t\t\t$('nav .menu ul').css('border-color', to ? to : '' );\n\t\t\t});\n\t\t});\t\n\t\t\n\t\t\n\t\t// PAGE HEADING STYLING\n\t\t\n\t\twp.customize('page_heading_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.page-heading').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('page_heading_text_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.page-heading h1').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('filter_rss_border_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.heading-rss-icon,.filter-wrap,.filter-wrap ul ').css('border-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\t\n\t\t\n\t\t// BODY STYLING\n\t\t\n\t\twp.customize('body_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('body').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('h1_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('h1').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('h2_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('h2').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('h3_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('h3').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('h4_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('h4').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('h5_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('h5').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('h6_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('h6').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('impact_text_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.wpb_impact_text .wpb_call_text,.impact-text').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\t\n\t\t\n\t\t// SHORTCODES STYLING\n\t\t\n\t\twp.customize('pt_primary_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.column-highlight .pricing-table-price').css('background-color', to ? to : '' );\n\t\t\t\t$('.column-highlight .pricing-table-price').css('border-bottom-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('pt_secondary_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.column-highlight .pricing-table-package').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('pt_tertiary_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.column-highlight .pricing-table-details').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('lpt_primary_row_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.labelled-pricing-table .alt-row').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('lpt_secondary_row_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.labelled-pricing-table .pricing-table-label-row,.labelled-pricing-table .pricing-table-row').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('lpt_default_pricing_header',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.labelled-pricing-table .pricing-table-price').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('lpt_default_package_header',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.labelled-pricing-table .pricing-table-package').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('lpt_default_footer',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.labelled-pricing-table .lpt-button-wrap').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\t\n\t\twp.customize('icon_container_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.sf-icon-cont').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\t\t\n\t\twp.customize('sf_icon_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('.sf-icon').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\t\t\n\t\t\n\t\t// FOOTER STYLING\n\t\t\n\t\twp.customize('footer_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#footer').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('footer_text_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#footer, #footer h3, #footer p').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('copyright_bg_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#copyright').css('background-color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\twp.customize('copyright_text_color',function( value ) {\n\t\t\tvalue.bind(function(to) {\n\t\t\t\t$('#copyright p').css('color', to ? to : '' );\n\t\t\t});\n\t\t});\n\t\t\n\t\n\t\twp.customize( 'blogname', function( value ) {\n\t\t\tvalue.bind( function( to ) {\n\t\t\t\t$( '#site-title a' ).html( to );\n\t\t\t} );\n\t\t} );\n\t\twp.customize( 'blogdescription', function( value ) {\n\t\t\tvalue.bind( function( to ) {\n\t\t\t\t$( '#site-description' ).html( to );\n\t\t\t} );\n\t\t} );\n\t\t} )( jQuery )\n\t\t</script>\n\t\t<?php \n\t}", "title": "" }, { "docid": "b12d3f30d9b27fe2de24e5147af719bc", "score": "0.53409106", "text": "function woobizz_standard_25_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-beforeheader-sidebar-div{display:none!important;}\r\n\t\t\theader#masthead{display:none!important;}\r\n\t\t\t.wb-customheader-sidebar-div{display:none!important;}\r\n\t\t\t.wb-afterheader-sidebar-div{display:none!important;}\t\t\t\r\n\t\t\theader.entry-header{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_9_template_css' );\r\n\t}", "title": "" }, { "docid": "37b5b212becc10c09ec50647b909deb3", "score": "0.53375524", "text": "function wpu_css_magic() {\n\tglobal $wpUnited;\n\n\n\t$wpuCache = WPU_Cache::getInstance();\n\t\n\t/** \n\t * Get all links to stylesheets, and prepare appropriate replacement links to insert into the page content\n\t * The generated CSS links to insert into the HTML will need to carry information for the browser on the \n\t * physical disk location of the CSS files on the server.\n\t * \n\t * We cannot allow browsers to just request any file on the server by filename, so get_stylesheet_links pre-approves the\n\t * files and stores them in the DB under \"style keys\". Browsers then only need to know the \n\t * appropriate style key, not the filename\n\t */\n\t\n\t$innerSSLinks = wpu_get_stylesheet_links($wpUnited->get_inner_headinfo(), 'inner');\n\t// also grep all inline css out of headers\n\t$inCSSInner = wpu_extract_css($wpUnited->get_inner_headinfo());\n\t\n\t\n\n\t/**\n\t * Template Voodoo\n\t */\n\tif ($wpUnited->get_setting('templateVoodoo')) { \n\t\t\n\t\t//For template voodoo, we also need the outer styles\n\t\t$outerSSLinks = wpu_get_stylesheet_links($wpUnited->get_outer_content(), 'outer');\n\t\t\n\t\t$inCSSOuter = wpu_extract_css($wpUnited->get_outer_content());\n\t\t\n\t\t// First check if the cached CSS Magic files exist, and insert placeholders for TV cache location if they do\n\t\t$foundInner = array();\n\t\t$foundOuter = array();\n\n\t\tforeach ((array)$innerSSLinks['keys'] as $index => $key) {\n\t\t\tif($found = $wpuCache->get_css_magic($wpUnited->get_style_key($key), 'inner', -1)) {\n\t\t\t\t$foundInner[] = $found;\n\t\t\t\t$innerSSLinks['replacements'][$index] .= '[*FOUND*]';\n\t\t\t} else {\n\t\t\t\t$innerSSLinks['replacements'][$index] .= '-1';\n\t\t\t}\n\t\t}\n\t\tforeach ($outerSSLinks['keys'] as $index => $key) {\n\t\t\tif($found = $wpuCache->get_css_magic($wpUnited->get_style_key($key), 'outer', -1)) {\n\t\t\t\t$foundOuter[] = $found;\n\t\t\t}\n\t\t}\t\n\n\t\t/**\n\t\t * Now we create a unique hash based on everything we've found, and use this to \n\t\t * store our Template Voodoo instructions.\n\t\t * We append the template voodoo hash key to the end of the redirected stylesheets\n\t\t */\n\t\t$tplVoodooKey = $wpuCache->get_template_voodoo_key(TEMPLATEPATH, $foundInner, $foundOuter, (array)$inCSSInner['orig'], (array)$inCSSOuter['orig']);\t\n\t\t$innerSSLinks['replacements'] = str_replace('[*FOUND*]', $tplVoodooKey, $innerSSLinks['replacements']);\n\n\t\tif((sizeof($foundInner) || $inCSSInner['orig'] ) && (sizeof($foundOuter) || $inCSSOuter['orig'])) {\n\t\t\t$classDupes = array();\n\t\t\t$idDupes = array();\n\t\t\t\n\t\t\tif($templateVoodoo = $wpuCache->get_template_voodoo($tplVoodooKey)) {\n\t\t\t\t/**\n\t\t\t\t * The template voodoo instructions already exist for this CSS combination\n\t\t\t\t */\n\t\t\t\tif(isset($templateVoodoo['classes']) && isset($templateVoodoo['ids'])) {\n\t\t\t\t\t$classDupes = $templateVoodoo['classes'];\n\t\t\t\t\t$idDupes = $templateVoodoo['ids'];\n\t\t\t\t} \n\t\t\t} else { \n\t\t\t\t/**\n\t\t\t\t * We don't have template voodoo for this yet, we need to do some legwork\n\t\t\t\t * and generate a set of instructions.\n\t\t\t\t * @todo move to separate function, generate_instructions().\n\t\t\t\t */\n\t\t\t\t$outerCSS = new CSS_Magic();\n\t\t\t\t$innerCSS = new CSS_Magic();\n\t\t\n\t\t\t\tforeach ($foundInner as $index => $cacheFile) {\n\t\t\t\t\t$innerCSS->parseFile($cacheFile);\n\t\t\t\t}\n\t\t\t\tforeach ($foundOuter as $index => $cacheFile) {\n\t\t\t\t\t$outerCSS->parseFile($cacheFile);\n\t\t\t\t}\t\t\t\t\n\t\t\t\tforeach($inCSSInner['css'] as $index => $css) {\n\t\t\t\t\t$innerCSS->parseString($css);\n\t\t\t\t}\n\t\t\t\tforeach($inCSSOuter['css'] as $index => $css) {\n\t\t\t\t\t$outerCSS->parseString($css);\n\t\t\t\t}\n\n\t\t\t\t$innerCSS->removeCommonKeyEl('#wpucssmagic .wpucssmagic');\n\t\t\t\t\n\t\t\t\t$ignores = array('wpucssmagic', 'wpuisle');\n\t\t\t\t\n\t\t\t\t$innerKeys = $innerCSS->getKeyClassesAndIDs();\n\t\t\t\t$outerKeys = $outerCSS->getKeyClassesAndIDs($ignores);\n\n\t\t\t\t$innerCSS->clear();\n\t\t\t\t$outerCSS->clear();\n\t\t\t\tunset($innerCSS, $outerCSS);\n\t\n\t\t\t\t$classDupes = array_intersect($innerKeys['classes'], $outerKeys['classes']);\n\t\t\t\t$idDupes = array_intersect($innerKeys['ids'], $outerKeys['ids']);\n\n\t\t\t\tunset($innerKeys, $outerKeys);\n\n\t\t\t\t// save to cache\n\t\t\t\t$wpuCache->save_template_voodoo(array('classes' => $classDupes, 'ids' => $idDupes), $tplVoodooKey);\n\t\t\t}\n\t\n\t\t\t/**\n\t\t\t * Now, we can modify the page, removing class and ID duplicates from the inner content\n\t\t\t */\n\t\t\tforeach($classDupes as $dupe) {\n\t\t\t\t$findClass = substr($dupe, 1); //remove leading '.'\n\t\t\t\t$wpUnited->set_inner_content(preg_replace('/(class=[\"\\']([^\\s^\\'^\"]*\\s+)*)'.$findClass.'([\\s\\'\"])/', '\\\\1wpu'.$findClass.'\\\\3', $wpUnited->get_inner_content()));\n\t\t\t}\n\t\t\tforeach($idDupes as $dupe) {\n\t\t\t\t$findId = substr($dupe, 1); //remove leading '.'\n\t\t\t\t$wpUnited->set_inner_content(preg_replace('/(id=[\"\\']\\s*)'.$findId.'([\\s\\'\"])/', '\\\\1wpu'.$findId.'\\\\2', $wpUnited->get_inner_content()));\n\t\t\t}\n\t\t}\n\t} // end template voodoo\n\t\n\t\t\n\t/**\n\t * Now we can apply the CSS magic to any inline CSS\n\t */\n\t$useTVStr = ($wpUnited->get_setting('templateVoodoo')) ? 'TV' : '';\n\t$tvKey = ($wpUnited->get_setting('templateVoodoo')) ? $tplVoodooKey : -1;\n\t$numFixes = 0;\n\tforeach($inCSSInner['css'] as $index => $innerCSSItem) {\n\n\t\tif($inlineCache = $wpuCache->get_css_magic(\"{$index}-{$useTVStr}\", 'inline', $tvKey)) {\n\t\t\t$result = @file_get_contents($inlineCache);\n\t\t} else {\n\t\t\t$cssM = new CSS_Magic();\n\t\t\t$cssM->parseString($innerCSSItem);\n\t\t\t/**\n\t\t\t * @todo could split out to templatevoodoo file\n\t\t\t */\n\t\t\tif ($wpUnited->get_setting('templateVoodoo')) {\n\t\t\t\tif(isset($classDupes) && isset($idDupes)) {\n\t\t\t\t\t$finds = array();\n\t\t\t\t\t$repl = array();\n\t\t\t\t\tforeach($classDupes as $classDupe) {\n\t\t\t\t\t\t$finds[] = $classDupe;\n\t\t\t\t\t\t$repl[] = \".wpu\" . substr($classDupe, 1);\n\t\t\t\t\t}\n\t\t\t\t\tforeach($idDupes as $idDupe) {\n\t\t\t\t\t\t$finds[] = $idDupe;\n\t\t\t\t\t\t$repl[] = \"#wpu\" . substr($idDupe, 1);\n\t\t\t\t\t}\t\n\n\t\t\t\t\t$cssM->modifyKeys($finds, $repl);\n\t\t\t\t}\n\t\t\t}\n\t\t\t$cssM->makeSpecificByIdThenClass('wpucssmagic', false);\n\t\t\t$result = $cssM->getCSS();\n\t\t\t// save to cache\n\t\t\t$wpuCache->save_css_magic($result, \"{$index}-{$useTVStr}\", 'inline', $tvKey);\n\t\t\n\t\t} \n\t\tif(!empty($result)) {\n\t\t\t//$result = '<style type=\"text/css\">' . $result . '</style>';\n\t\t\t$wpUnited->set_inner_headinfo(str_replace($inCSSInner['orig'][$index], $result, $wpUnited->get_inner_headinfo()));\n\t\t\t$numFixes++;\n\t\t}\n\t}\n\t\n\t// Store the updated style keys\n\t$wpUnited->commit_style_keys();\n\t\n\t// add link to reset stylesheet\n\t$reset = \"<link href=\\\"{$wpUnited->get_plugin_url()}theme/reset.css\\\" rel=\\\"stylesheet\\\" media=\\\"all\\\" type=\\\"text/css\\\" />\";\n\t$wpUnited->set_inner_headinfo($reset . $wpUnited->get_inner_headinfo());\n\n\t//write out the modified stylesheet links\n\t$wpUnited->set_inner_headinfo(str_replace($innerSSLinks['links'], $innerSSLinks['replacements'], $wpUnited->get_inner_headinfo()));\n\t\n\tif ($wpUnited->get_setting('templateVoodoo')) {\n\t\t$wpUnited->set_outer_content(str_replace($outerSSLinks['links'], $outerSSLinks['replacements'], $wpUnited->get_outer_content()));\n\t}\n\t\n\t/**\n\t * Elements (mainly third-party BBCodes) with height=\"\" cannot override the height CSS rule set in CSS Magic's reset.css\n\t * This adds an inline CSS style attribute to any such elements\n\t * If the element already has an inline style attribute, the height rule will be appended to it\n\t */\n\t$withInline = preg_replace_callback(\n\t\t'/((<[^>]+\\b)(?=height\\s?=\\s?[\\'\"]?\\s?([0-9]+)\\s?[\\'\"]?)([^>]*?))(\\/?\\s*>)/',\n\t\tcreate_function(\n\t\t\t'$m',\n\t\t\t'if(preg_match(\\'/(style\\s?=\\s?[\\\\\\'\"]([^\\\\\\'\"]+))([\\\\\\'\"])/\\', $m[1], $r)) \n\t\t\t\treturn str_replace($r[0], \"{$r[1]};height:{$m[3]}px;{$r[3]}\", $m[1]) . $m[5];\n\t\t\treturn $m[1] . \\' style=\"height:\\' . $m[3] . \\'px;\" \\' . $m[5];'\n\t\t),\n\t\t$wpUnited->get_inner_content()\n\t);\n\t\n\t//same with width\n\t$withInline = preg_replace_callback(\n\t\t'/((<[^>]+\\b)(?=width\\s?=\\s?[\\'\"]?\\s?([0-9]+)\\s?[\\'\"]?)([^>]*?))(\\/?\\s*>)/',\n\t\tcreate_function(\n\t\t\t'$m',\n\t\t\t'if(preg_match(\\'/(style\\s?=\\s?[\\\\\\'\"]([^\\\\\\'\"]+))([\\\\\\'\"])/\\', $m[1], $r)) \n\t\t\t\treturn str_replace($r[0], \"{$r[1]};width:{$m[3]}px;{$r[3]}\", $m[1]) . $m[5];\n\t\t\treturn $m[1] . \\' style=\"width:\\' . $m[3] . \\'px;\" \\' . $m[5];'\n\t\t),\n\t\t$withInline\n\t);\t\n\t\n\t//and bgcolor\n\t$withInline = preg_replace_callback(\n\t\t'/((<[^>]+\\b)(?=bgcolor\\s?=\\s?[\\'\"]?\\s?([0-9]+)\\s?[\\'\"]?)([^>]*?))(\\/?\\s*>)/',\n\t\tcreate_function(\n\t\t\t'$m',\n\t\t\t'if(preg_match(\\'/(style\\s?=\\s?[\\\\\\'\"]([^\\\\\\'\"]+))([\\\\\\'\"])/\\', $m[1], $r)) \n\t\t\t\treturn str_replace($r[0], \"{$r[1]};background-color:{$m[3]}px;{$r[3]}\", $m[1]) . $m[5];\n\t\t\treturn $m[1] . \\' style=\"background-color:\\' . $m[3] . \\'px;\" \\' . $m[5];'\n\t\t),\n\t\t$withInline\n\t);\t\n\t\n\t$wpUnited->set_inner_content($withInline);\n\t\n}", "title": "" }, { "docid": "043ac66fecc83c110dae22d323c01172", "score": "0.53343225", "text": "function noodlezero_product_cats_css() {\r\n\r\n /* register the stylesheet */\r\n wp_register_style( 'noodlezero_product_cats_css', plugins_url( 'css/style.css', __FILE__ ) );\r\n\r\n /* enqueue the stylsheet */\r\n wp_enqueue_style( 'noodlezero_product_cats_css' );\r\n\r\n}", "title": "" }, { "docid": "5a6b31881195e38db7de0b2245598d45", "score": "0.5326619", "text": "function load_t_wp_admin_style() {\n \n}", "title": "" }, { "docid": "41b5a872ea437ecabb176b8268f3d0ff", "score": "0.53251433", "text": "function woobizz_standard_22_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-breadcrumb-sidebar-div{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_6_template_css' );\r\n\t}", "title": "" }, { "docid": "af43d03401658aab899b39a33f1b3b72", "score": "0.5324094", "text": "function print_custom_css() {\n\t$style = wp_cache_get( 'custom_css' );\n\n\t/* If the style is available, output it and return. */\n\tif ( !empty( $style ) ) {\n\t\techo $style;\n\t\treturn;\n\t} else {\n\t\t/* Put the final style output together. */\n\t\t$style = \"\\n\" . '<style type=\"text/css\" id=\"custom-css\">' . trim( get_theme_mod( 'custom_css' ) ) . '</style>' . \"\\n\";\n\n\t\t/* Cache the style, so we don't have to process this on each page load. */\n\t\twp_cache_set( 'custom_css', $style );\n\n\t\t/* Output the custom style. */\n\t\techo $style;\n\t}\n}", "title": "" }, { "docid": "bbad133faf38ac9a8fc50736678e0048", "score": "0.5321783", "text": "function msp_save_custom_styles() {\n\n $uploads = wp_upload_dir();\n\n\t$css_dir = apply_filters( 'masterslider_custom_css_dir', $uploads['basedir'] . '/' . MSWP_SLUG );\n\t$css_file = $css_dir . '/custom.css';\n\n $css_terms = \"/*\n===============================================================\n # CUSTOM CSS\n - Please do not edit this file. this file is generated by server-side code\n - Every changes here will be overwritten\n===============================================================*/\\n\n\";\n // Get all custom css styles\n $css = msp_get_all_custom_css();\n\n /**\n * Initialize the WP_Filesystem\n */\n global $wp_filesystem;\n if ( empty( $wp_filesystem ) ) {\n require_once ( ABSPATH.'/wp-admin/includes/file.php' );\n WP_Filesystem();\n }\n\n if ( wp_mkdir_p( $css_dir ) && ! $wp_filesystem->put_contents( $css_file, $css_terms.$css, 0644 ) ) {\n // if the directory is not writable, try inline css fallback\n msp_update_option( 'custom_inline_style' , $css ); // save css rules as option to print as inline css\n } else {\n \t$custom_css_ver = msp_get_option( 'masterslider_custom_css_ver', '1.0' );\n \t$custom_css_ver = (float)$custom_css_ver + 0.1;\n msp_update_option( 'masterslider_custom_css_ver' , $custom_css_ver ); // disable inline css output\n msp_update_option( 'custom_inline_style' , '' );\n }\n\n}", "title": "" }, { "docid": "17fa086c4e5dac1ce831b9e7523c5317", "score": "0.5313732", "text": "public function getCustomCSS()\n {\n return array_diff_key($this->customCSS ?? [], $this->blocked);\n }", "title": "" }, { "docid": "2e38add0d927e1f76a71208c8409c2d9", "score": "0.5312549", "text": "function customQueryStyling(){\n wp_enqueue_style('custom-query-styles', plugin_dir_url(__FILE__) . 'public/css/style.css');\n}", "title": "" }, { "docid": "14af8dbbfbfc328999640c28a675916e", "score": "0.5311927", "text": "function pippin_print_css() {\n\tglobal $pippin_load_css;\n \n\t// this variable is set to TRUE if the short code is used on a page/post\n\tif ( ! $pippin_load_css )\n\t\treturn; // this means that neither short code is present, so we get out of here\n \n\twp_print_styles('pippin-form-css');\n}", "title": "" }, { "docid": "45d3252f267aabaa2cb71b522d6774d9", "score": "0.5311353", "text": "function woobizz_standard_21_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\theader.entry-header{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_5_template_css' );\r\n\t}", "title": "" }, { "docid": "f72a7aac9307b1daa3cffd163f01d245", "score": "0.5299461", "text": "function samwise_gallery_style( $css ) {\n\treturn preg_replace( \"#<style type='text/css'>(.*?)</style>#s\", '', $css );\n}", "title": "" }, { "docid": "9a02ecae316ee2ec2dd0c163945f48e8", "score": "0.529601", "text": "function woobizz_standard_19_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-beforefooter-sidebar-div{display:none!important;}\r\n\t\t\t.wb-customfooter-sidebar-div{display:none!important;}\r\n\t\t\t.site-footer{display:none!important;}\r\n\t\t\t.wb-afterfooter-sidebar-div{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_3_template_css' );\r\n\t}", "title": "" }, { "docid": "0f9891c10acb13b033aa0aa15d87ebf4", "score": "0.52918744", "text": "function jeherve_remove_all_jp_css() {\n wp_deregister_style( 'AtD_style' ); // After the Deadline\n wp_deregister_style( 'jetpack_likes' ); // Likes\n wp_deregister_style( 'jetpack_related-posts' ); //Related Posts\n wp_deregister_style( 'jetpack-carousel' ); // Carousel\n wp_deregister_style( 'grunion.css' ); // Grunion contact form\n wp_deregister_style( 'the-neverending-homepage' ); // Infinite Scroll\n wp_deregister_style( 'infinity-twentyten' ); // Infinite Scroll - Twentyten Theme\n wp_deregister_style( 'infinity-twentyeleven' ); // Infinite Scroll - Twentyeleven Theme\n wp_deregister_style( 'infinity-twentytwelve' ); // Infinite Scroll - Twentytwelve Theme\n wp_deregister_style( 'noticons' ); // Notes\n wp_deregister_style( 'post-by-email' ); // Post by Email\n wp_deregister_style( 'publicize' ); // Publicize\n wp_deregister_style( 'sharedaddy' ); // Sharedaddy\n wp_deregister_style( 'sharing' ); // Sharedaddy Sharing\n wp_deregister_style( 'stats_reports_css' ); // Stats\n wp_deregister_style( 'jetpack-widgets' ); // Widgets\n wp_deregister_style( 'jetpack-slideshow' ); // Slideshows\n wp_deregister_style( 'presentations' ); // Presentation shortcode\n wp_deregister_style( 'jetpack-subscriptions' ); // Subscriptions\n wp_deregister_style( 'tiled-gallery' ); // Tiled Galleries\n wp_deregister_style( 'widget-conditions' ); // Widget Visibility\n wp_deregister_style( 'jetpack_display_posts_widget' ); // Display Posts Widget\n wp_deregister_style( 'gravatar-profile-widget' ); // Gravatar Widget\n wp_deregister_style( 'widget-grid-and-list' ); // Top Posts widget\n wp_deregister_style( 'jetpack-widgets' ); // Widgets\n}", "title": "" }, { "docid": "0f9891c10acb13b033aa0aa15d87ebf4", "score": "0.52918744", "text": "function jeherve_remove_all_jp_css() {\n wp_deregister_style( 'AtD_style' ); // After the Deadline\n wp_deregister_style( 'jetpack_likes' ); // Likes\n wp_deregister_style( 'jetpack_related-posts' ); //Related Posts\n wp_deregister_style( 'jetpack-carousel' ); // Carousel\n wp_deregister_style( 'grunion.css' ); // Grunion contact form\n wp_deregister_style( 'the-neverending-homepage' ); // Infinite Scroll\n wp_deregister_style( 'infinity-twentyten' ); // Infinite Scroll - Twentyten Theme\n wp_deregister_style( 'infinity-twentyeleven' ); // Infinite Scroll - Twentyeleven Theme\n wp_deregister_style( 'infinity-twentytwelve' ); // Infinite Scroll - Twentytwelve Theme\n wp_deregister_style( 'noticons' ); // Notes\n wp_deregister_style( 'post-by-email' ); // Post by Email\n wp_deregister_style( 'publicize' ); // Publicize\n wp_deregister_style( 'sharedaddy' ); // Sharedaddy\n wp_deregister_style( 'sharing' ); // Sharedaddy Sharing\n wp_deregister_style( 'stats_reports_css' ); // Stats\n wp_deregister_style( 'jetpack-widgets' ); // Widgets\n wp_deregister_style( 'jetpack-slideshow' ); // Slideshows\n wp_deregister_style( 'presentations' ); // Presentation shortcode\n wp_deregister_style( 'jetpack-subscriptions' ); // Subscriptions\n wp_deregister_style( 'tiled-gallery' ); // Tiled Galleries\n wp_deregister_style( 'widget-conditions' ); // Widget Visibility\n wp_deregister_style( 'jetpack_display_posts_widget' ); // Display Posts Widget\n wp_deregister_style( 'gravatar-profile-widget' ); // Gravatar Widget\n wp_deregister_style( 'widget-grid-and-list' ); // Top Posts widget\n wp_deregister_style( 'jetpack-widgets' ); // Widgets\n}", "title": "" }, { "docid": "e87ec594a2886743b0c0122f4525094f", "score": "0.5284829", "text": "public function getStyleURLs(): array;", "title": "" }, { "docid": "9609dfda27e7a01b38de692787cc2300", "score": "0.5278077", "text": "function woobizz_standard_24_template_css(){\r\n\t\techo\"\r\n\t\t<style>\r\n\t\t\theader.entry-header{margin:20px!important;}\r\n\t\t\t.hentry{margin:0!important;}\r\n\t\t\t.site-main{margin-bottom:0!important;}\r\n\t\t\t.wb-beforeheader-sidebar-div{display:none!important;}\r\n\t\t\theader#masthead{display:none!important;}\r\n\t\t\t.wb-customheader-sidebar-div{display:none!important;}\r\n\t\t\t.wb-afterheader-sidebar-div{display:none!important;}\r\n\t\t\t.wb-breadcrumb-sidebar-div{display:none!important;}\r\n\t\t</style>\";\r\n\t\tadd_action( 'init', 'woobizz_standard_8_template_css' );\r\n\t}", "title": "" }, { "docid": "1b4b48191ac5bec26193642e506e48a1", "score": "0.5273395", "text": "function icy_head_css() {\n global $icy_options;\n\t\t\n\t\t$output = '';\n\t\t\t\n $highlight = $icy_options['accent_colour'];\n $headings = $icy_options['headings_colour'];\n //$notification = $icy_options['notif_colour'];\n $text = $icy_options['text_colour'];\n $footer = $icy_options['footer_colour'];\n $css = $icy_options['custom_css'];\n $scheme = $icy_options['color_scheme'];\n\n //\tSet Custom Background Image\n \n //\tGain access to the post id\n global $wp_query;\n if( is_home() && !is_tax( 'type' ) ) {\n $postid = get_option('page_for_posts');\n } elseif( is_tax( 'type' ) || is_search() || is_404() ) {\n $postid = 0;\n } else {\n $postid = $wp_query->post->ID;\n }\n\n // get custom image for page\n $bg_img = get_post_meta($postid, 'icy_background_image', true);\n $bg_pos = get_post_meta($postid, 'icy_background_position', true);\n $bg_repeat = get_post_meta($postid, 'icy_background_repeat', true);\n $bg_color = get_post_meta($postid, 'icy_background_color', true);\n $content_color = get_post_meta($postid, 'icy_content_background_color', true);\n $disabled = get_post_meta($postid, 'icy_content_background_disable', true);\n\n switch ($bg_pos) {\n case 0:\n $bg_pos = \"left\";\n break;\n case 1:\n $bg_pos = \"right\";\n break;\n case 2:\n $bg_pos = \"center\";\n break;\n case 3:\n $bg_pos = \"; -webkit-background-size: cover; -moz-background-size: cover; -o-background-size: cover; background-size: cover; \"; \n break;\n }\n\n switch ($bg_repeat) {\n case 0:\n $bg_repeat = \"no-repeat\";\n break;\n case 1:\n $bg_repeat = \"repeat\";\n break;\n case 2:\n $bg_repeat = \"repeat-x\";\n break;\n case 3:\n $bg_repeat = \"repeat-y\"; \n break;\n }\n\n /* NULL OE EMPTY FOR BG IMAGE - ANDROID FIX */\n function IsNullOrEmptyString($question){\n return (!isset($question) || trim($question)==='');\n }\n\n if (!IsNullOrEmptyString($bg_img))\n {\n $output .= \"body { background-color: \".$bg_color.\"; background-image: url(\".$bg_img.\"); background-position: \".$bg_pos.\"; background-repeat: \".$bg_repeat.\"; background-attachment: fixed; }\\n\";\n } else {\n $output .= \"body { background-color: \".$bg_color.\"; }\\n\";\n }\n\n if ($disabled == 'off') {\n // If Content background color is desired\n $output .= \"section.wrapper { background-color: \".$content_color.\"; }\\n\";\n }\n\n if (($disabled == 'on') && ($scheme == 'dark')) {\n $output .= \".dark section.wrapper { background-color: transparent; }\";\n }\n\n\t\t\n if ($highlight <> '') {\n $output .= \"\"; \n }\n\n if ($css != '') {\n $output .= $css;\n }\n\n if ($highlight != '#00a78d') {\n $output .= \"button:hover,input[type=\\\"submit\\\"]:hover, .more-link:hover, input[type=\\\"button\\\"]:hover,input[type=\\\"submit\\\"]:hover, .wp-pagenavi a:hover, .wp-pagenavi span.current, .navigation-posts a:hover, .icy-member .icy-member-picture .rotateright, .icy-member .icy-member-picture .rotateleft { background-color: \".$highlight.\"; }\";\n $output .= \"input[type=\\\"button\\\"],input[type=\\\"submit\\\"],.more-link, .navigation-posts a, input:focus,textarea:focus, .dark input:focus,.dark textarea:focus { border-color: \".$highlight.\"; }\";\n $output .= \"input[type=\\\"button\\\"],input[type=\\\"submit\\\"],.more-link,a,a:hover, nav#primary-nav ul li a:hover, nav#primary-nav ul li.current-cat a, nav#primary-nav ul li.current_page_item a, nav#primary-nav ul li.current-menu-item a, .navigation-posts a:hover, .entry-title:hover h1, span.reply-to a:hover, .widget-title span, .icy-portfolio .icy-portfolio-tax li a:hover, .icy-portfolio .icy-portfolio-tax li a.active, .icy-pricetable-wrapper ul li.icy-pricetable-heading, .icy-pricetable-wrapper ul li.action-button, .navigation-posts a { color: \".$highlight.\"; }\";\n }\n\n if ($text != '#777777') {\n $output .= \"body, body.dark, .the-content .chat .chat-text { color: \".$text.\"; }\";\n }\n\n if ($headings != '#333333') {\n $output .= \"h1, h2, h3, h4, h5, h6, .dark h1, .dark h2, .dark h3, .dark h4, .dark h5, .dark h6,\n .entry-title h1, .dark .entry-title h1, .page-meta .page-title, .dark .page-meta .page-title, .widget-title, .dark .widget-title, .icy-slogan .icy-slogan-title, .dark .icy-slogan .icy-slogan-title, #portfolio-wrapper .portfolio-single-title, .dark #portfolio-wrapper .portfolio-single-title, .single-portfolio .portfolio-single-title, .dark .single-portfolio .portfolio-single-title, .icy-member .icy-member-name, .dark .icy-member .icy-member-name, .icy-skill h4, .dark .icy-skill h4, .icy-centered-text h2, .dark .icy-centered-text h2, .icy-pricetable-wrapper ul li.icy-pricetable-heading .icy-pricetable-title, .dark .icy-pricetable-wrapper ul li.icy-pricetable-heading .icy-pricetable-title { color: \".$headings.\"; }\";\n }\n\n if ($footer != '#eeeeee') {\n $output .= \"footer.footer-container, .dark footer.footer-container { background-color: \".$footer.\"; }\";\n }\n\t\t\n if ($output <> '') {\n\t\t\t$output = \"<!-- Custom Styling -->\\n<style type=\\\"text/css\\\">\\n\" . $output . \"</style>\\n\";\n\t\t\techo stripslashes($output);\n\t\t}\n}", "title": "" }, { "docid": "d5d1693fba4356d1b1284d46a0222958", "score": "0.5265007", "text": "function t_seed_gallery_style($css) {\n\treturn preg_replace( \"!<style type='text/css'>(.*?)</style>!s\", '', $css );\n}", "title": "" }, { "docid": "57802d0e8945c99a4dad98ed7194c30a", "score": "0.5264288", "text": "function sanitize_css( $css ) {\n\t// Based on code from Automattic's Safe CSS\n\t// (wp_filter_nohtml_kses expects slashed data)\n\t$css = wp_filter_nohtml_kses( $css );\n\t$css = str_replace( '&gt;', '>', $css ); // kses replaces lone '>' with &gt;\n\n\t// Why both KSES and strip_tags? Because we just added some '>'.\n\t$css = strip_tags( $css );\n\treturn $css;\n}", "title": "" }, { "docid": "f8eff77ebf2c9526586aa42c92aed664", "score": "0.5264274", "text": "function inkpro_customizer_backgrounds_css() {\r\n\r\n\t$backgrounds_css = '';\r\n\r\n\t$backgrounds = array(\r\n\t\t'light_background' => '.wpb-font-dark:not(.wpb-block)',\r\n\t\t'dark_background' => '.wpb-font-light:not(.wpb-block)',\r\n\t\t'footer_bg' => '.sidebar-footer',\r\n\t\t'bottom_bar_bg' => '.site-infos',\r\n\t\t'music_network_bg' => '.music-social-icons-container',\r\n\t);\r\n\r\n\t/*-----------------------------------------------------------------------------------*/\r\n\t/* wBounce\r\n\t/*-----------------------------------------------------------------------------------*/\r\n\tif ( get_header_image() ) {\r\n\t\t$backgrounds_css .= '.has-default-header .wbounce-modal-sub{background-image:url( ' . get_header_image() . ' );}';\r\n\t}\r\n\r\n\t$backgrounds_css .= inkpro_get_customizer_bg_css( $backgrounds );\r\n\r\n\tif ( ! SCRIPT_DEBUG ) {\r\n\t\t$backgrounds_css = wolf_compact_css( $backgrounds_css );\r\n\t}\r\n\r\n\twp_add_inline_style( 'inkpro-style', $backgrounds_css );\r\n}", "title": "" }, { "docid": "112b0ad1893876b88d1764da0d47a6d4", "score": "0.52641755", "text": "function oerc_addCSS() {\n\n # Get contents of CSS file from the plugin's dir\n $oerc_CSS = oerc_getCSS();\n\n echo <<<HTML\n <!-- BEGIN headers added by oerc_search.php plugin -->\n <style>\n $oerc_CSS\n </style>\n <!-- END headers added by oerc_search.php plugin -->\n\nHTML;\n\n}", "title": "" }, { "docid": "2aa611294b1a961cd439404c0b2b123c", "score": "0.5261103", "text": "function astra_addon_blog_pro_dynamic_css( $dynamic_css, $dynamic_css_filtered = '' ) {\n\n\t/**\n\t * - Variable Declaration.\n\t */\n\t$is_site_rtl = is_rtl();\n\t$css_output = '';\n\n\t$desktop_max_css = array(\n\t\t// Updated before content value to fix the masonry layout issue.\n\t\t'#content:before' => array(\n\t\t\t'content' => '\"' . astra_addon_get_tablet_breakpoint() . '\"',\n\t\t\t'position' => 'absolute',\n\t\t\t'overflow' => 'hidden',\n\t\t\t'opacity' => '0',\n\t\t\t'visibility' => 'hidden',\n\t\t),\n\t);\n\n\t/* Parse CSS from array() */\n\t$css_output .= astra_parse_css( $desktop_max_css );\n\n\t$tablet_max_css = array(\n\t\t// Single Post author info.\n\t\t'.single.ast-separate-container .ast-author-meta' => array(\n\t\t\t'padding' => '1.5em 2.14em',\n\t\t),\n\t\t'.single .ast-author-meta .post-author-avatar' => array(\n\t\t\t'margin-bottom' => '1em',\n\t\t),\n\t\t'.ast-separate-container .ast-grid-2 .ast-article-post, .ast-separate-container .ast-grid-3 .ast-article-post, .ast-separate-container .ast-grid-4 .ast-article-post' => array(\n\t\t\t'width' => '100%',\n\t\t),\n\t\t'.blog-layout-1 .post-content, .blog-layout-1 .ast-blog-featured-section' => array(\n\t\t\t'float' => 'none',\n\t\t),\n\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .square .posted-on' => array(\n\t\t\t'margin-top' => 0,\n\t\t),\n\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .circle .posted-on' => array(\n\t\t\t'margin-top' => '1em',\n\t\t),\n\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-content .ast-blog-featured-section:first-child .post-thumb-img-content' => array(\n\t\t\t'margin-top' => '-1.5em',\n\t\t),\n\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-thumb-img-content' => array(\n\t\t\t'margin-left' => '-2.14em',\n\t\t\t'margin-right' => '-2.14em',\n\t\t),\n\t\t'.ast-separate-container .ast-article-single.remove-featured-img-padding .single-layout-1 .entry-header .post-thumb-img-content:first-child' => array(\n\t\t\t'margin-top' => '-1.5em',\n\t\t),\n\t\t'.ast-separate-container .ast-article-single.remove-featured-img-padding .single-layout-1 .post-thumb-img-content' => array(\n\t\t\t'margin-left' => '-2.14em',\n\t\t\t'margin-right' => '-2.14em',\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .square .posted-on, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .square .posted-on, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .square .posted-on' => array(\n\t\t\t'margin-left' => '-1.5em',\n\t\t\t'margin-right' => '-1.5em',\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .circle .posted-on, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .circle .posted-on, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .circle .posted-on' => array(\n\t\t\t'margin-left' => '-0.5em',\n\t\t\t'margin-right' => '-0.5em',\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .square .posted-on, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .square .posted-on, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .square .posted-on' => array(\n\t\t\t'margin-top' => 0,\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .circle .posted-on, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .circle .posted-on, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .circle .posted-on' => array(\n\t\t\t'margin-top' => '1em',\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-content .ast-blog-featured-section:first-child .post-thumb-img-content, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-content .ast-blog-featured-section:first-child .post-thumb-img-content, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-content .ast-blog-featured-section:first-child .post-thumb-img-content' => array(\n\t\t\t'margin-top' => '-1.5em',\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-thumb-img-content, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-thumb-img-content, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-thumb-img-content' => array(\n\t\t\t'margin-left' => '-1.5em',\n\t\t\t'margin-right' => '-1.5em',\n\t\t),\n\t\t'.blog-layout-2' => array(\n\t\t\t'display' => 'flex',\n\t\t\t'flex-direction' => 'column-reverse',\n\t\t),\n\t\t'.ast-separate-container .blog-layout-3, .ast-separate-container .blog-layout-1' => array(\n\t\t\t'display' => 'block',\n\t\t),\n\t\t'.ast-plain-container .ast-grid-2 .ast-article-post, .ast-plain-container .ast-grid-3 .ast-article-post, .ast-plain-container .ast-grid-4 .ast-article-post, .ast-page-builder-template .ast-grid-2 .ast-article-post, .ast-page-builder-template .ast-grid-3 .ast-article-post, .ast-page-builder-template .ast-grid-4 .ast-article-post' => array(\n\t\t\t'width' => '100%',\n\t\t),\n\t);\n\n\t/* Parse CSS from array() -> max-width: (tablet-breakpoint)px */\n\t$css_output .= astra_parse_css( $tablet_max_css, '', astra_addon_get_tablet_breakpoint() );\n\n\tif ( $is_site_rtl ) {\n\t\t$tablet_max_lang_direction_css = array(\n\t\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .square .posted-on' => array(\n\t\t\t\t'margin-top' => 0,\n\t\t\t\t'margin-right' => '-2.14em',\n\t\t\t),\n\t\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .circle .posted-on' => array(\n\t\t\t\t'margin-top' => 0,\n\t\t\t\t'margin-right' => '-1.14em',\n\t\t\t),\n\t\t);\n\t} else {\n\t\t$tablet_max_lang_direction_css = array(\n\t\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .square .posted-on' => array(\n\t\t\t\t'margin-top' => 0,\n\t\t\t\t'margin-left' => '-2.14em',\n\t\t\t),\n\t\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .circle .posted-on' => array(\n\t\t\t\t'margin-top' => 0,\n\t\t\t\t'margin-left' => '-1.14em',\n\t\t\t),\n\t\t);\n\t}\n\n\t/* Parse CSS from array() -> max-width: (tablet-breakpoint)px */\n\t$css_output .= astra_parse_css( $tablet_max_lang_direction_css, '', astra_addon_get_tablet_breakpoint() );\n\n\t$tablet_min_css = array(\n\t\t// Single Post author info.\n\t\t'.single .ast-author-meta .ast-author-details' => array(\n\t\t\t'display' => 'flex',\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-archive-description, .ast-separate-container.ast-blog-grid-3 .ast-archive-description, .ast-separate-container.ast-blog-grid-4 .ast-archive-description' => array(\n\t\t\t'margin-bottom' => '1.33333em',\n\t\t),\n\t\t'.blog-layout-2.ast-no-thumb .post-content, .blog-layout-3.ast-no-thumb .post-content' => array(\n\t\t\t'width' => 'calc(100% - 5.714285714em)',\n\t\t),\n\t\t'.blog-layout-2.ast-no-thumb.ast-no-date-box .post-content, .blog-layout-3.ast-no-thumb.ast-no-date-box .post-content' => array(\n\t\t\t'width' => '100%',\n\t\t),\n\t\t'.ast-separate-container .ast-grid-2 .ast-article-post.ast-separate-posts, .ast-separate-container .ast-grid-3 .ast-article-post.ast-separate-posts, .ast-separate-container .ast-grid-4 .ast-article-post.ast-separate-posts' => array(\n\t\t\t'border-bottom' => 0,\n\t\t),\n\t\t'.ast-separate-container .ast-grid-2 > .site-main > .ast-row, .ast-separate-container .ast-grid-3 > .site-main > .ast-row, .ast-separate-container .ast-grid-4 > .site-main > .ast-row' => array(\n\t\t\t'margin-left' => '-1em',\n\t\t\t'margin-right' => '-1em',\n\t\t\t'display' => 'flex',\n\t\t\t'flex-flow' => 'row wrap',\n\t\t\t'align-items' => 'stretch',\n\t\t),\n\t\t'.ast-separate-container .ast-grid-2 > .site-main > .ast-row:before, .ast-separate-container .ast-grid-2 > .site-main > .ast-row:after, .ast-separate-container .ast-grid-3 > .site-main > .ast-row:before, .ast-separate-container .ast-grid-3 > .site-main > .ast-row:after, .ast-separate-container .ast-grid-4 > .site-main > .ast-row:before, .ast-separate-container .ast-grid-4 > .site-main > .ast-row:after' => array(\n\t\t\t'flex-basis' => 0,\n\t\t\t'width' => 0,\n\t\t),\n\t\t'.ast-separate-container .ast-grid-2 .ast-article-post, .ast-separate-container .ast-grid-3 .ast-article-post, .ast-separate-container .ast-grid-4 .ast-article-post' => array(\n\t\t\t'display' => 'flex',\n\t\t\t'padding' => 0,\n\t\t),\n\t\t'.ast-plain-container .ast-grid-2 > .site-main > .ast-row, .ast-plain-container .ast-grid-3 > .site-main > .ast-row, .ast-plain-container .ast-grid-4 > .site-main > .ast-row, .ast-page-builder-template .ast-grid-2 > .site-main > .ast-row, .ast-page-builder-template .ast-grid-3 > .site-main > .ast-row, .ast-page-builder-template .ast-grid-4 > .site-main > .ast-row' => array(\n\t\t\t'margin-left' => '-1em',\n\t\t\t'margin-right' => '-1em',\n\t\t\t'display' => 'flex',\n\t\t\t'flex-flow' => 'row wrap',\n\t\t\t'align-items' => 'stretch',\n\t\t),\n\t\t'.ast-plain-container .ast-grid-2 > .site-main > .ast-row:before, .ast-plain-container .ast-grid-2 > .site-main > .ast-row:after, .ast-plain-container .ast-grid-3 > .site-main > .ast-row:before, .ast-plain-container .ast-grid-3 > .site-main > .ast-row:after, .ast-plain-container .ast-grid-4 > .site-main > .ast-row:before, .ast-plain-container .ast-grid-4 > .site-main > .ast-row:after, .ast-page-builder-template .ast-grid-2 > .site-main > .ast-row:before, .ast-page-builder-template .ast-grid-2 > .site-main > .ast-row:after, .ast-page-builder-template .ast-grid-3 > .site-main > .ast-row:before, .ast-page-builder-template .ast-grid-3 > .site-main > .ast-row:after, .ast-page-builder-template .ast-grid-4 > .site-main > .ast-row:before, .ast-page-builder-template .ast-grid-4 > .site-main > .ast-row:after' => array(\n\t\t\t'flex-basis' => 0,\n\t\t\t'width' => 0,\n\t\t),\n\t\t'.ast-plain-container .ast-grid-2 .ast-article-post, .ast-plain-container .ast-grid-3 .ast-article-post, .ast-plain-container .ast-grid-4 .ast-article-post, .ast-page-builder-template .ast-grid-2 .ast-article-post, .ast-page-builder-template .ast-grid-3 .ast-article-post, .ast-page-builder-template .ast-grid-4 .ast-article-post' => array(\n\t\t\t'display' => 'flex',\n\t\t),\n\t\t'.ast-plain-container .ast-grid-2 .ast-article-post:last-child, .ast-plain-container .ast-grid-3 .ast-article-post:last-child, .ast-plain-container .ast-grid-4 .ast-article-post:last-child, .ast-page-builder-template .ast-grid-2 .ast-article-post:last-child, .ast-page-builder-template .ast-grid-3 .ast-article-post:last-child, .ast-page-builder-template .ast-grid-4 .ast-article-post:last-child' => array(\n\t\t\t'margin-bottom' => '2.5em',\n\t\t),\n\t);\n\n\t/* Parse CSS from array() -> min-width: (tablet-breakpoint + 1)px */\n\t$css_output .= astra_parse_css( $tablet_min_css, astra_addon_get_tablet_breakpoint( '', 1 ) );\n\n\tif ( $is_site_rtl ) {\n\t\t$tablet_min_lang_direction_css = array(\n\t\t\t'.single .post-author-avatar, .single .post-author-bio' => array(\n\t\t\t\t'float' => 'right',\n\t\t\t\t'clear' => 'left',\n\t\t\t),\n\t\t\t'.single .ast-author-meta .post-author-avatar' => array(\n\t\t\t\t'margin-left' => '1.33333em',\n\t\t\t),\n\t\t\t'.single .ast-author-meta .about-author-title-wrapper, .single .ast-author-meta .post-author-bio' => array(\n\t\t\t\t'text-align' => 'right',\n\t\t\t),\n\t\t\t'.blog-layout-2 .post-content' => array(\n\t\t\t\t'padding-left' => '2em',\n\t\t\t),\n\t\t\t'.blog-layout-2.ast-no-date-box.ast-no-thumb .post-content' => array(\n\t\t\t\t'padding-left' => 0,\n\t\t\t),\n\t\t\t'.blog-layout-3 .post-content' => array(\n\t\t\t\t'padding-right' => '2em',\n\t\t\t),\n\t\t\t'.blog-layout-3.ast-no-date-box.ast-no-thumb .post-content' => array(\n\t\t\t\t'padding-right' => 0,\n\t\t\t),\n\t\t\t'.ast-separate-container .ast-grid-2 .ast-article-post.ast-separate-posts:nth-child(2n+0), .ast-separate-container .ast-grid-2 .ast-article-post.ast-separate-posts:nth-child(2n+1), .ast-separate-container .ast-grid-3 .ast-article-post.ast-separate-posts:nth-child(2n+0), .ast-separate-container .ast-grid-3 .ast-article-post.ast-separate-posts:nth-child(2n+1), .ast-separate-container .ast-grid-4 .ast-article-post.ast-separate-posts:nth-child(2n+0), .ast-separate-container .ast-grid-4 .ast-article-post.ast-separate-posts:nth-child(2n+1)' => array(\n\t\t\t\t'padding' => '0 0 0 1em',\n\t\t\t),\n\t\t);\n\t} else {\n\t\t$tablet_min_lang_direction_css = array(\n\t\t\t'.single .post-author-avatar, .single .post-author-bio' => array(\n\t\t\t\t'float' => 'left',\n\t\t\t\t'clear' => 'right',\n\t\t\t),\n\t\t\t'.single .ast-author-meta .post-author-avatar' => array(\n\t\t\t\t'margin-right' => '1.33333em',\n\t\t\t),\n\t\t\t'.single .ast-author-meta .about-author-title-wrapper, .single .ast-author-meta .post-author-bio' => array(\n\t\t\t\t'text-align' => 'left',\n\t\t\t),\n\t\t\t'.blog-layout-2 .post-content' => array(\n\t\t\t\t'padding-right' => '2em',\n\t\t\t),\n\t\t\t'.blog-layout-2.ast-no-date-box.ast-no-thumb .post-content' => array(\n\t\t\t\t'padding-right' => 0,\n\t\t\t),\n\t\t\t'.blog-layout-3 .post-content' => array(\n\t\t\t\t'padding-left' => '2em',\n\t\t\t),\n\t\t\t'.blog-layout-3.ast-no-date-box.ast-no-thumb .post-content' => array(\n\t\t\t\t'padding-left' => 0,\n\t\t\t),\n\t\t\t'.ast-separate-container .ast-grid-2 .ast-article-post.ast-separate-posts:nth-child(2n+0), .ast-separate-container .ast-grid-2 .ast-article-post.ast-separate-posts:nth-child(2n+1), .ast-separate-container .ast-grid-3 .ast-article-post.ast-separate-posts:nth-child(2n+0), .ast-separate-container .ast-grid-3 .ast-article-post.ast-separate-posts:nth-child(2n+1), .ast-separate-container .ast-grid-4 .ast-article-post.ast-separate-posts:nth-child(2n+0), .ast-separate-container .ast-grid-4 .ast-article-post.ast-separate-posts:nth-child(2n+1)' => array(\n\t\t\t\t'padding' => '0 1em 0',\n\t\t\t),\n\t\t);\n\t}\n\n\t/* Parse CSS from array() -> min-width: (tablet-breakpoint + 1)px */\n\t$css_output .= astra_parse_css( $tablet_min_lang_direction_css, astra_addon_get_tablet_breakpoint( '', 1 ) );\n\n\t$mobile_css = array(\n\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .circle .posted-on' => array(\n\t\t\t'margin-top' => '0.5em',\n\t\t),\n\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-thumb-img-content, .ast-separate-container .ast-article-single.remove-featured-img-padding .single-layout-1 .post-thumb-img-content, .ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .square .posted-on, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .square .posted-on, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .square .posted-on' => array(\n\t\t\t'margin-left' => '-1em',\n\t\t\t'margin-right' => '-1em',\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .circle .posted-on, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .circle .posted-on, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .circle .posted-on' => array(\n\t\t\t'margin-left' => '-0.5em',\n\t\t\t'margin-right' => '-0.5em',\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .circle .posted-on, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .circle .posted-on, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section:first-child .circle .posted-on' => array(\n\t\t\t'margin-top' => '0.5em',\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-content .ast-blog-featured-section:first-child .post-thumb-img-content, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-content .ast-blog-featured-section:first-child .post-thumb-img-content, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-content .ast-blog-featured-section:first-child .post-thumb-img-content' => array(\n\t\t\t'margin-top' => '-1.33333em',\n\t\t),\n\t\t'.ast-separate-container.ast-blog-grid-2 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-thumb-img-content, .ast-separate-container.ast-blog-grid-3 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-thumb-img-content, .ast-separate-container.ast-blog-grid-4 .ast-article-post.remove-featured-img-padding .blog-layout-1 .post-thumb-img-content' => array(\n\t\t\t'margin-left' => '-1em',\n\t\t\t'margin-right' => '-1em',\n\t\t),\n\t\t'.ast-separate-container .ast-grid-2 .ast-article-post .blog-layout-1, .ast-separate-container .ast-grid-2 .ast-article-post .blog-layout-2, .ast-separate-container .ast-grid-2 .ast-article-post .blog-layout-3' => array(\n\t\t\t'padding' => '1.33333em 1em',\n\t\t),\n\t\t'.ast-separate-container .ast-grid-3 .ast-article-post .blog-layout-1, .ast-separate-container .ast-grid-4 .ast-article-post .blog-layout-1' => array(\n\t\t\t'padding' => '1.33333em 1em',\n\t\t),\n\t\t'.single.ast-separate-container .ast-author-meta' => array(\n\t\t\t'padding' => '1.5em 1em',\n\t\t),\n\t);\n\n\t/* Parse CSS from array() -> max-width: (mobile-breakpoint)px */\n\t$css_output .= astra_parse_css( $mobile_css, '', astra_addon_get_mobile_breakpoint() );\n\n\tif ( $is_site_rtl ) {\n\t\t$mobile_max_direction_css = array(\n\t\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .square .posted-on' => array(\n\t\t\t\t'margin-right' => '-1em',\n\t\t\t),\n\t\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .circle .posted-on' => array(\n\t\t\t\t'margin-right' => '-0.5em',\n\t\t\t),\n\t\t);\n\t} else {\n\t\t$mobile_max_direction_css = array(\n\t\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .square .posted-on' => array(\n\t\t\t\t'margin-left' => '-1em',\n\t\t\t),\n\t\t\t'.ast-separate-container .ast-article-post.remove-featured-img-padding.has-post-thumbnail .blog-layout-1 .post-content .ast-blog-featured-section .circle .posted-on' => array(\n\t\t\t\t'margin-left' => '-0.5em',\n\t\t\t),\n\t\t);\n\t}\n\n\t/* Parse CSS from array() -> max-width: (mobile-breakpoint)px */\n\t$css_output .= astra_parse_css( $mobile_max_direction_css, '', astra_addon_get_mobile_breakpoint() );\n\n\treturn $dynamic_css . $css_output;\n}", "title": "" }, { "docid": "8841c61c4efddc06fd7303ea09ccafce", "score": "0.5258108", "text": "function monrovia_styles()\r\n{\r\n wp_register_style('normalize', get_template_directory_uri() . '/normalize.min.css', array(), '1.0', 'all');\r\n wp_enqueue_style('normalize'); // Enqueue it!\r\n \r\n\tif(isset($_GET['screen']) && $_GET['screen']=='print'){\r\n\t// Only attach print.css!\r\n\twp_register_style('print', get_template_directory_uri() . '/css/print.min.css', array(), '1.0', 'all');\r\n wp_enqueue_style('print'); // Enqueue it!\r\n\t} else {\r\n wp_register_style('monrovia', get_template_directory_uri() . '/style.css?'.time(), array(), '1.0', 'all');\r\n wp_enqueue_style('monrovia'); // Enqueue it!\r\n\t}\r\n\twp_register_style( 'monrovia-styles', get_template_directory_uri().'/css/customize.css', array(), '1.0', 'all');\r\n\twp_enqueue_style( 'monrovia-styles' );\r\n\twp_register_style( 'monrovia-home-slider-styles', get_template_directory_uri().'/css/home-slider.css', array(), '1.0', 'all');\r\n\twp_enqueue_style( 'monrovia-home-slider-styles' );\r\n}", "title": "" }, { "docid": "265d56dd57748ede7fe42b602d63ace5", "score": "0.5255579", "text": "function kurama_custom_css_mods() {\n\n\techo \"<style id='custom-css-mods'>\";\n\t\n\t\n\t//If Menu Description is Disabled.\n\tif ( !has_nav_menu('primary') || get_theme_mod('kurama_disable_nav_desc') ) :\n\t\techo \"#site-navigation ul li a { padding: 16px 12px; }\";\n\tendif;\n\t\n\t\n\t//Exception: IMage transform origin should be left on Left Alignment, i.e. Default\n\tif ( !get_theme_mod('kurama_center_logo') ) :\n\t\techo \"#masthead #site-logo img { transform-origin: left; }\";\n\tendif;\t\n\t\n\tif ( get_theme_mod('kurama_title_font') ) :\n\t\techo \".title-font, h1, h2, .section-title, .woocommerce ul.products li.product h3 { font-family: \".esc_html( get_theme_mod('kurama_title_font','Lato') ).\"; }\";\n\tendif;\n\t\n\tif ( get_theme_mod('kurama_body_font') ) :\n\t\techo \"body { font-family: \".esc_html( get_theme_mod('kurama_body_font','Open Sans') ).\"; }\";\n\tendif;\n\t\n\tif ( get_theme_mod('kurama_site_titlecolor') ) :\n\t\techo \"#masthead h1.site-title a { color: \".esc_html( get_theme_mod('kurama_site_titlecolor', '#333') ).\"; }\";\n\tendif;\n\t\n\t\n\tif ( get_theme_mod('kurama_header_desccolor','#777777') ) :\n\t\techo \"#masthead h2.site-description { color: \".esc_html( get_theme_mod('kurama_header_desccolor','#777777') ).\"; }\";\n\tendif;\n\t//Check Jetpack is active\n\tif ( class_exists( 'Jetpack' ) && Jetpack::is_module_active( 'infinite-scroll' ) )\n\t\techo '.pagination { display: none; }';\n\t\t\n\tif ( get_theme_mod('kurama_sidebar_loc') == 'left' ) :\n\t\techo \"#secondary { float: left; }#primary,#primary-mono { float: right; }\";\n\tendif;\t\n\t\n\tif ( get_theme_mod('kurama_site_layout') == 'boxed' ) :\n\t\techo \"#page { max-width: 1170px; margin: 20px auto; } @media screen and (min-width: 992px) { #top-bar { padding: 3px 10px; } #top-bar .social-icons { margin-right: 15px; } }\";\n\tendif;\t\n\t\n\twp_reset_postdata();\t\n\tif ( get_post_meta( get_the_ID(), 'hide-title', true ) ):\n\t\techo \"#primary-mono h1.entry-title, .template-entry-title { display: none; }\";\n\tendif;\n\twp_reset_postdata();\t\n\t\n\tif ( get_theme_mod('kurama_logo_resize') ) :\n\t\t$val = esc_html( get_theme_mod('kurama_logo_resize') )/100;\n\t\techo \"#masthead .custom-logo { transform-origin: center; transform: scale(\".$val.\"); -webkit-transform: scale(\".$val.\"); -moz-transform: scale(\".$val.\"); -ms-transform: scale(\".$val.\"); }\";\n\t\tendif;\n\n\techo \"</style>\";\n}", "title": "" } ]
c8089425e1e708c82ffe39be24326cd4
look for a 'custom logo'
[ { "docid": "0004a9fa74f4838ba1176983ec99540b", "score": "0.6870456", "text": "function get_site_logo() {\n $content_logo = '';\n // if we have a custom logo\n\n if (!empty(get_theme_mod('custom_logo'))) {\n $logo_src = wp_get_attachment_image_src(get_theme_mod('custom_logo'));\n $logo_srcset = wp_get_attachment_image_srcset(get_theme_mod('custom_logo'));\n $format_logo = '\n <a class=\"\" href=\"%s\" title=\"Logo button\">\n <img src=\"%s\" srcset=\"%s\" alt=\"%s\">\n </a>\n ';\n $content_logo .= sprintf(\n $format_logo,\n site_url(),\n $logo_src,\n $logo_srcset,\n get_bloginfo('sitename')\n );\n }\n return $content_logo;\n}", "title": "" } ]
[ { "docid": "a72f30478da222e6cb2dc2cc15365439", "score": "0.8019227", "text": "public function domaze_custom_logo() {\n the_custom_logo();\n }", "title": "" }, { "docid": "167ef4eb48c0416f5a3bd4bcfbc38300", "score": "0.78644294", "text": "function excellent_the_custom_logo() { \n \t if (function_exists('the_custom_logo')) { \n \t the_custom_logo(); \n \t }\n \t}", "title": "" }, { "docid": "d3cbabff3305f4eadfe3df50d662ef80", "score": "0.7648176", "text": "function rftheme_logo() {\n\tif ( function_exists( 'the_custom_logo' ) ) {\n\t\tthe_custom_logo();\n\t}\n}", "title": "" }, { "docid": "ec712d04bd8e3309471b86280569414f", "score": "0.7593695", "text": "function mbt_the_custom_logo() {\n // get logo media id\n $custom_logo_id = get_theme_mod('custom_logo');\n\n // get URL to logo\n $logo_url = wp_get_attachment_image_src($custom_logo_id, 'full');\n\n // Do we have custom logo?\n if (has_custom_logo()) {\n // yes we have custom logo, pls display\n echo '<img src=\"' . $logo_url[0] . '\" class=\"img-fluid\" alt=\"Site Logo\" title=\"' . get_bloginfo('name') . '\">';\n } else {\n // we have no logo, show us the title instead\n bloginfo('name');\n }\n}", "title": "" }, { "docid": "03b93ef223b074eda43ecd3f407788cd", "score": "0.7570089", "text": "function hellopro_custom_logo() {\n\t$site_title_display_setting = get_theme_mod( 'site_title_display' );\n\tif ( 'display_logo' === $site_title_display_setting ) {\n\t\tthe_custom_logo();\n\t}\n}", "title": "" }, { "docid": "33863c35f3e179c06c5e68772388557c", "score": "0.7532049", "text": "function nutmeg_the_custom_logo() {\n\tif ( function_exists( 'the_custom_logo' ) ) {\n\n// We don't use the default the_custom_logo() function because of its automatic addition of itemprop attributes (they fail the ARIA tests)\n\n\t\t$site = get_bloginfo('name');\n\t\t$custom_logo_id = get_theme_mod( 'custom_logo' );\n\n\t\tif ( $custom_logo_id ) {\n\t\t\t$html = sprintf( '<a href=\"%1$s\" class=\"custom-logo-link\" rel=\"home\">%2$s</a>', \n\t\t\t\tesc_url( home_url( '/' ) ),\n\t\t\t\twp_get_attachment_image( $custom_logo_id, 'full', false, array(\n\t\t\t\t\t'class' => 'custom-logo',\n\t\t\t\t\t'alt' => __('Logo for ', 'nutmeg') . esc_attr($site),\n\t\t\t\t) )\n\t\t\t);\n\t\t}\n\n\t\techo $html;\n\n\t}\n\n}", "title": "" }, { "docid": "5a76cae33231becbd64bbc5f5981e2b9", "score": "0.7502315", "text": "function starter_custom_logo() {\n\tif ( function_exists( 'the_custom_logo' ) ) {\n\t\tthe_custom_logo();\n\t}\n}", "title": "" }, { "docid": "01b9a6109296a1ec24fe9d587da647b4", "score": "0.7491341", "text": "function maker_site_logo() {\n\tif ( function_exists( 'the_custom_logo' ) ) {\n\t\tthe_custom_logo();\n\t}\n}", "title": "" }, { "docid": "dfe0cbd3fbcdf603a11f9320da615022", "score": "0.72691476", "text": "function javiergarval_custom_logo() {\n\tadd_theme_support(\n\t\t'custom-logo', \n\t\tarray(\n\t\t 'height' => 100,\n\t\t 'width' => 400,\n\t\t 'flex-height' => true,\n\t\t 'flex-width' => true,\n\t\t 'header-text' => array( 'site-title', 'site-description' )\n\t\t) \n\t);\n}", "title": "" }, { "docid": "d115cf42bfc67e5f37a2bdd9e7dd9c63", "score": "0.7249339", "text": "public function getLogo();", "title": "" }, { "docid": "f7f454034def434be8d8e2407641694f", "score": "0.72383136", "text": "function logo_display() {\n\t$logo_id = get_theme_mod( 'custom_logo' );\n\t$logo = wp_get_attachment_image_src( $logo_id , 'full' );\n\n\tif ( has_custom_logo() ) {\n\t\t$logodisplay = '<img src=\"'. esc_url( $logo[0] ) .'\">';\n\t\techo $logodisplay;\n\t} else {\n\t\t$logodisplay = '<h1>'. get_bloginfo( 'name' ) .'</h1>';\n\t\techo $logodisplay;\n\t}\n}", "title": "" }, { "docid": "d3c39e1af3c9b89564579b7abf8b57ca", "score": "0.7235153", "text": "function theme_prefix_the_custom_logo() {\n \n if ( function_exists( 'the_custom_logo' ) ) {\n the_custom_logo();\n }\n\n}", "title": "" }, { "docid": "60e92adb5d901824646f05022c65316e", "score": "0.72197175", "text": "function _h_add_logo_in_login_page() {\n $logo_id = get_theme_mod('custom_logo');\n\n // if logo exists\n if ($logo_id):\n $logo = wp_get_attachment_image_src($logo_id , 'full');\n ?>\n <style>\n .login h1 a {\n background-position: center center;\n background-size: contain;\n background-image: url(\"<?= $logo[0]; ?>\");\n width: 250px;\n }\n </style>\n <?php\n endif;\n}", "title": "" }, { "docid": "56ad496e8b23132ee80b01ed1e549753", "score": "0.7208807", "text": "function hwcoe_ufl_get_custom_logo() {\n\t$custom_logo = '';\n\t\n\tif ( function_exists( 'the_custom_logo' ) ) {\n\t\t$blog_id = get_current_blog_id();\n\t\tif ( has_custom_logo( $blog_id ) ){\n\t\t $custom_logo = get_custom_logo();\n\t\t $custom_logo = preg_replace(\"/(.+)src=\\\"([^\\\"]*)\\\"(.+)/\", \"$2\", $custom_logo);\n\t\t $custom_logo .= \"#Layer_1\";\n\t\t}\n\t\telse {\n\t\t // $custom_logo = get_template_directory_uri() . '/svg/logo-herbert.svg';\n\t\t $custom_logo = get_template_directory_uri() . '/img/logo-hwcoe.svg#hwcoe-logo';\n\t\t}\n }\n return $custom_logo;\n}", "title": "" }, { "docid": "e496a0328cf1f058998bc1b279af8807", "score": "0.7132779", "text": "function avada_logo() {\n\t\tif ( '' == Avada()->settings->get( 'logo' ) && '' == Avada()->settings->get( 'logo_retina' ) ) {\n\t\t\treturn;\n\t\t}\n\t\tget_template_part( 'templates/logo' );\n\t}", "title": "" }, { "docid": "3a9d7694b1ebf93662311abd546d1c99", "score": "0.70846075", "text": "public static function the_logo() {\n\t\t$style = 'style = \"width: 100%; height: auto;\"';\n\t\t$img = ' < img src = \"' . App::$assets_uri . '/images/sethflix-icon.png\\\" ' . $style . '/>';\n\t\techo wp_kses( $img, wp_kses_allowed_html( 'post' ) );\n\t}", "title": "" }, { "docid": "6e0ee9cd66a6297e8d3f954ebbc6291a", "score": "0.7039484", "text": "public function getLogo()\n {\n }", "title": "" }, { "docid": "80fb0d0d664750ba3800e4ef07b19b7f", "score": "0.6992806", "text": "function pitaya_custom_login_logo() {\n $logoBg = get_stylesheet_directory_uri().'/assets/images/logo.svg';\n\n echo \"\n <style type='text/css'>\n #login h1 a, .login h1 a {\n position: relative;\n background-image: none;\n margin: 0;\n height: 96px;\n width: 100%;\n }\n .login h1 a:before {\n content: '';\n position: absolute;\n top: 50%; right: 50%;\n margin-top: -48px;\n margin-right: -48px;\n width: 96px;\n height: 96px;\n background: url($logoBg) 50% 50% no-repeat;\n }\n\n </style>\n \";\n}", "title": "" }, { "docid": "eceba0640cec240504984e5943efc8af", "score": "0.6966113", "text": "private function retina_header_logo() {\n\t\treturn wpex_translate_theme_mod( 'retina_logo', wpex_get_mod( 'retina_logo' ) );\n\t}", "title": "" }, { "docid": "761fc3ca06a6a17eaae208a4b1216275", "score": "0.69616616", "text": "function custom_site_logo( $atts ) {\n\treturn do_action( 'genesis_site_title', 'genesis_seo_site_title' );\n}", "title": "" }, { "docid": "3acc70d919ff59a6611c9475f41e4be9", "score": "0.6959443", "text": "static function fnTestWikiLogo( &$out ) {\n\t\t$setLogo = self::shouldWeSetCustomLogo( $out->getTitle() );\n\t\tif( !$setLogo ) {\n\t\t\treturn true;\n\t\t}\n\t\tglobal $wgLogo;\n\t\t$prefixForPageTitle = str_replace( '/', '-', strtolower( $setLogo['prefix'] ) );\n\t\t$file = wfFindFile( wfMessage( 'Incubator-logo-' . $prefixForPageTitle )->inContentLanguage()->plain() );\n\t\tif( !$file ) {\n\t\t\t# if MediaWiki:Incubator-logo-wx-xx(x) doesn't exist,\n\t\t\t# try a general, default logo for that project\n\t\t\tglobal $wmincProjects;\n\t\t\t$project = $setLogo['project'];\n\t\t\t$projectForFile = str_replace( ' ', '-', strtolower( $wmincProjects[$project] ) );\n\t\t\t$imageobj = wfFindFile( wfMessage( 'wminc-logo-' . $projectForFile )->plain() );\n\t\t\tif( $imageobj ) {\n\t\t\t\t$thumb = $imageobj->transform( array( 'width' => 135, 'height' => 135 ) );\n\t\t\t\t$wgLogo = $thumb->getUrl();\n\t\t\t\treturn true;\n\t\t\t}\n\t\t\treturn true;\n\t\t}\n\t\t# Use MediaWiki:Incubator-logo-wx-xx(x)\n\t\t$thumb = $file->transform( array( 'width' => 135, 'height' => 135 ) );\n\t\t$wgLogo = $thumb->getUrl();\n\t\treturn true;\n\t}", "title": "" }, { "docid": "ed478aab112cfee8d428632a7533dc78", "score": "0.69427913", "text": "public function _render_custom_logo_partial()\n {\n return get_custom_logo();\n }", "title": "" }, { "docid": "a6ad317c4f07d78bd6412042721cdb1c", "score": "0.6902927", "text": "function md_custom_login_logo() {\n\t echo '<style type=\"text/css\">\n\t\t\t h1 a { background-image: url('.get_option('of_login_logo').') !important; }\n\t\t\t</style>';\n\t}", "title": "" }, { "docid": "8836b673fd863db798d21c31c89ead9e", "score": "0.6888894", "text": "function helpwp_custom_logo_output( $html ) {\n\t$html = str_replace('custom-logo', 'custom-logo img-fluid mb-5 d-block mx-auto', $html );\n\treturn $html;\n}", "title": "" }, { "docid": "a5605d176de1a376d13deeac8afdb6f0", "score": "0.6884968", "text": "function get_the_site_logo() {\n\n // Verify if logo exists\n if ( the_option('main_logo') ) {\n\n echo '<a href=\"' . site_url() . '\" class=\"navbar-brand\">'\n . '<img src=\"' . the_option('main_logo') . '\" alt=\"Midrub Docs\" width=\"32\">'\n . '</a>';\n\n }\n \n }", "title": "" }, { "docid": "cf901fda169659cfd3a94b8d535f01af", "score": "0.6884322", "text": "static function shouldWeSetCustomLogo( $title ) {\n\t\t$prefix = IncubatorTest::analyzePrefix( $title->getText() );\n\n\t\t# Maybe do later something like if( isContentProject() && 'recentchanges' ) { return true; }\n\n\t\t# return if the page does not have a valid prefix (info page is considered valid)\n\t\tif( $prefix['error'] ) {\n\t\t\treturn false;\n\t\t}\n\t\t# display the custom logo only if &testwiki=wx/xx or the user's pref is set to the current test wiki\n\t\tif( self::displayPrefix() != $prefix['prefix'] ) {\n\t\t\treturn false;\n\t\t}\n\t\tglobal $wmincTestWikiNamespaces;\n\t\t# return if the page is not in one of the test wiki namespaces\n\t\tif( !in_array( $title->getNamespace(), (array)$wmincTestWikiNamespaces ) ) {\n\t\t\treturn false;\n\t\t}\n\t\treturn $prefix;\n\t}", "title": "" }, { "docid": "d40fc697cd94d5097c61262bab9162f5", "score": "0.688079", "text": "public function custom_login_logo() {\n\t echo '<style type=\"text/css\">\n\t .login h1 a { background-size:auto; width:100%; height:150px; background-position:center center; background-image:url('.get_bloginfo('template_directory').'/public/images/logos/admin-logo.svg) !important; }\n\t </style>';\n\t}", "title": "" }, { "docid": "b9db2aa996d1f25899fbcae4148ac4c4", "score": "0.68624026", "text": "function agriflex_custom_logo() {\n\n $logo = of_get_option( 'custom-agency-logo' );\n $url = of_get_option( 'custom-agency-link' );\n\n if ( $logo ) {\n $html = '<li class=\"top-agency custom-logo\">';\n $html .= '<a href=\"' . $url . '\">';\n $html .= '<span class=\"top-level-hide\"></span>';\n $html .= '<img src=\"' . $logo . '\" />';\n $html .= '</a>';\n $html .= '</li>';\n\n echo $html;\n }\n\n}", "title": "" }, { "docid": "d6fbaa652c8305adf09917a2e7f22432", "score": "0.68497324", "text": "function shoestrap_logo() {\n if ( get_theme_mod( 'shoestrap_logo' ) ) {\n $image = '<img id=\"site-logo\" src=\"%s\" alt=\"%s\" style=\"max-width:100%%; height:auto;\">';\n printf(\n $image,\n get_theme_mod( 'shoestrap_logo' ),\n get_bloginfo( 'name' )\n );\n } else {\n echo '<span class=\"sitename\">';\n bloginfo( 'name' );\n echo '</span>';\n }\n}", "title": "" }, { "docid": "311bd17a2730f947103b41bd2d9db865", "score": "0.68354636", "text": "public static function site_logo(){\r\n\r\n // Custom logo for categories added\r\n if( is_category() || is_tag() ){\r\n\r\n if( is_category() ){\r\n $term_id = get_query_var( 'cat' );\r\n }else{\r\n $tag = get_term_by( 'slug', get_query_var('tag'), 'post_tag' );\r\n $term_id = $tag->term_id;\r\n }\r\n\r\n $logo_image = BF()->taxonomy_meta()->get_term_meta( $term_id, 'logo_image', Better_Mag::get_option( 'logo_image' ) );\r\n $logo_image_retina = BF()->taxonomy_meta()->get_term_meta( $term_id, 'logo_image_retina', Better_Mag::get_option( 'logo_image_retina' ) );\r\n $logo_text = BF()->taxonomy_meta()->get_term_meta( $term_id, 'logo_text', Better_Mag::get_option( 'logo_text' ) );\r\n\r\n }\r\n\r\n // General Logo\r\n else{\r\n\r\n $logo_image = Better_Mag::get_option( 'logo_image' );\r\n $logo_image_retina = Better_Mag::get_option( 'logo_image_retina' );\r\n $logo_text = Better_Mag::get_option( 'logo_text' );\r\n\r\n }\r\n\r\n ?>\r\n <div <?php better_attr( 'site' ) ?>>\r\n <?php if( is_home() || is_front_page() ){ ?>\r\n <h1 <?php better_attr( 'site-title', 'logo' ); ?>>\r\n <?php }else{ ?>\r\n <h2 <?php better_attr( 'site-title', 'logo' ); ?>>\r\n <?php } ?>\r\n <a href=\"<?php echo home_url(); ?>\" <?php better_attr( 'site-url' ); ?>>\r\n <?php if( $logo_image != '' ){ ?>\r\n <img src=\"<?php echo esc_attr( $logo_image ); ?>\" alt=\"<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>\"\r\n <?php if( $logo_image_retina != '' ){ ?>data-at2x=\"<?php echo $logo_image_retina; ?>\"<?php } ?> <?php better_attr( 'site-logo' ); ?> />\r\n <?php }else{\r\n echo $logo_text;\r\n } ?>\r\n </a>\r\n <?php if( is_home() || is_front_page() ){ ?>\r\n </h1>\r\n <?php }else{ ?>\r\n </h2>\r\n <?php }\r\n\r\n if( Better_Mag::get_option( 'show_site_description' ) ){\r\n ?><p <?php better_attr( 'site-description', 'site-description' ); ?>><?php bloginfo('description'); ?></p><?php\r\n }\r\n ?>\r\n </div>\r\n <?php\r\n }", "title": "" }, { "docid": "d705de0703e15469e7ca11d3f8493b28", "score": "0.67936224", "text": "function leadtesting_custom_logo_setup() {\n $defaults = array(\n 'height' => 43,\n 'width' => 160,\n 'flex-height' => true,\n 'flex-width' => true,\n 'header-text' => array( 'City Home Inspections', 'Serving Southeast Wisconsin Since 1998' ),\n );\n add_theme_support( 'custom-logo', $defaults );\n}", "title": "" }, { "docid": "366ce18891587b6e21b9d183b7b1d963", "score": "0.67882055", "text": "function wp_login_custom_logo() {\n ?>\n <style type=\"text/css\">\n body.login div#login h1 a {\n background-image: url('/wp-content/uploads/2019/11/accuranker-logo-svg.png');\n padding-bottom: 30px;\n }\n </style>\n <?php\n}", "title": "" }, { "docid": "50ab2bc82ffb659bf6911cbce2a99fc4", "score": "0.67518455", "text": "function jbst4_theme_prefix_setup() {\n /*\n * Enable support for custom logo.\n *\n */\n\n if ( function_exists( 'the_custom_logo' ) ) {\n add_theme_support( 'custom-logo', array(\n 'height' => 120,\n 'width' => 360,\n 'flex-height' => true\n ) );\n }\n}", "title": "" }, { "docid": "7ebe2173066b576c3363bebf1e859ac8", "score": "0.6725689", "text": "function path_theme_meta_box_logo() { ?>\n\n\t<table class=\"form-table\">\n\n\t\t<!-- Logo -->\n\t\t<tr>\n\t\t\t<th>\n\t\t\t\t<label for=\"<?php echo hybrid_settings_field_id( 'path_custom_logo' ); ?>\"><?php _e( 'Custom logo:', 'path' ); ?></label>\n\t\t\t</th>\n\t\t\t<td>\n\t\t\t\t<p><?php printf( __( 'Want to replace or remove default logo? <a href=\"%s\">Go to Appearance &gt;&gt; Header</a>. ', 'path' ), admin_url( 'themes.php?page=custom-header' ) ); ?></p>\n\t\t\t</td>\n\t\t</tr>\n\n\t\t<!-- End custom form elements. -->\n\t</table><!-- .form-table --><?php\n\t\n}", "title": "" }, { "docid": "c1de2afef3560a50be1bc2eb5272cae5", "score": "0.6708616", "text": "function rinjani_logo_type(){\n\n$options = get_option('rinjani_framework');\n$logo = '';\nif (isset($options['logo_upload'])) {\n$logo = $options['logo_upload'];\n$upload_logo = $logo['url'];\n}\n\n\nif ( ! empty( $upload_logo ) ) { ?>\n\n\t<div class=\"logo-image\">\n\t<a href=\"<?php echo esc_url( home_url( '/' ) ); ?>\"><img src=\"<?php echo esc_url( $upload_logo ); ?>\" class=\"image-logo\" alt=\"logo\" /></a>\n\t</div>\n\t\n\t<?php } else { ?> \n\t\n\t<div class=\"logo-title\">\n\t\t<h1 class=\"site-title\">\n\t\t\t<a href=\"<?php echo esc_url( home_url( '/' ) ); ?>\" rel=\"home\"><?php bloginfo( 'name' ); ?></a>\n\t\t</h1>\n\t\t<h2 style=\"color:#fff;\">The best way to see the future is to Travel</h2>\n\t</div>\n<?php }\n}", "title": "" }, { "docid": "75ead9f66c8bc255aba803d667620645", "score": "0.6706758", "text": "function vbegy_login_logo() {\n\t$login_logo = vpanel_options(\"login_logo\");\n\t$login_logo_height = vpanel_options(\"login_logo_height\");\n\t$login_logo_width = vpanel_options(\"login_logo_width\");\n\tif (isset($login_logo) && $login_logo != \"\") {\n\t\techo '<style type=\"text/css\">\n\t\t.login h1 a {\n\t\t\tbackground-image:url('.$login_logo.') !important;\n\t\t\tbackground-size: auto !important;\n\t\t\t'.(isset($login_logo_height) && $login_logo_height != \"\"?\"height: \".$login_logo_height.\"px !important;\":\"\").'\n\t\t\t'.(isset($login_logo_width) && $login_logo_width != \"\"?\"width: \".$login_logo_width.\"px !important;\":\"\").'\n\t\t}\n\t\t</style>';\n\t}\n}", "title": "" }, { "docid": "bd2386170c64d7d5dd98f77223717aa6", "score": "0.668846", "text": "function grve_admin_login_logo() {\n\n\t$replace_logo = grve_option( 'replace_admin_logo' );\n\tif ( $replace_logo ) {\n\t\t$grve_logo = grve_option( 'logo','','url' );\n\t\tif ( !empty( $grve_logo ) ) {\n\t\t\techo \"\n\t\t\t<style>\n\t\t\tbody.login #login h1 a {\n\t\t\t\tbackground: url('\" . esc_url( $grve_logo ) . \"');\n\t\t\t\tbackground-position: center top;\n\t\t\t\tbackground-repeat: no-repeat;\n\t\t\t\tbackground-size: inherit;\n\t\t\t\twidth: 100%;\n\t\t\t\theight: auto;\n\t\t\t}\n\t\t\t</style>\n\t\t\t\";\n\t\t}\n\t}\n}", "title": "" }, { "docid": "76a6ce3cdf4466fd96cfa4dd549d73b5", "score": "0.66808736", "text": "function custom_login_logo() { ?>\n <style type=\"text/css\">\n .login #login h1 a {\n background-image: url( <?php echo home_url( 'content/themes/theme/img/logo.svg' , __FILE__ ); ?> );\n background-size: 100%;\n background-position: center;\n }\n </style>\n<?php }", "title": "" }, { "docid": "2209f1be78674707fecaffec9f6ef894", "score": "0.6666428", "text": "function base_admin_bar_add_custom_logo() {\n\t?>\n\t<style>\n\t#wpadminbar #wp-admin-bar-wp-logo > .ab-item .ab-icon::before {\n\t\tbackground-image: url('<?php echo esc_url( THEME_IMAGES ); ?>/logo-admin-branding.svg');\n\t\tbackground-position: center;\n\t\tbackground-repeat: no-repeat;\n\t\tcolor: transparent;\n\t}\n\t</style>\n\t<?php\n}", "title": "" }, { "docid": "41608593461d36a28c15fba38e99eb60", "score": "0.66657174", "text": "function nanosoft_logo( $prefix = '', $attrs = array() ) {\n\t$logo_key = 'logo';\n\t$logo_retina_key = 'logoRetina';\n\n\tif ( ! empty( $prefix ) ) {\n\t\t$logo_key = $prefix . '__' . $logo_key;\n\t\t$logo_retina_key = $prefix . '__' . $logo_retina_key;\n\t}\n\n\t$logo = (array) nanosoft_option( $logo_key );\n\t$logo_retina = (array) nanosoft_option( $logo_retina_key );\n\n\t$srcset = array();\n\t$attributes = array();\n\n\tif ( isset( $logo['id'] ) && is_numeric( $logo['id'] ) ) {\n\t\tlist( $url ) = wp_get_attachment_image_src( $logo['id'], 'full' );\n\t\t$srcset[] = sprintf( '%s 1x', $url );\n\t\t$attributes['src'] = $url;\n\t}\n\telseif ( isset( $logo['url'] ) && filter_var( $logo['url'], FILTER_VALIDATE_URL ) ) {\n\t\t$srcset[] = sprintf( '%s 1x', $logo['url'] );\n\t\t$attributes['src'] = $logo['url'];\n\t}\n\n\tif ( isset( $logo_retina['id'] ) && is_numeric( $logo_retina['id'] ) ) {\n\t\tlist( $url ) = wp_get_attachment_image_src( $logo_retina['id'], 'full' );\n\t\t$srcset[] = sprintf( '%s 2x', $url );\n\t}\n\telseif ( isset( $logo_retina['url'] ) && filter_var( $logo_retina['url'], FILTER_VALIDATE_URL ) ) {\n\t\t$srcset[] = sprintf( '%s 2x', $logo_retina['url'] );\n\t}\n\t\n\n\t$attributes['srcset'] = join( ', ', $srcset );\n\t$attributes['alt'] = get_bloginfo( 'name' );\n\t$attributes['class'] = sprintf( 'logo %s', $prefix );\n\n\tprintf( '<img %s />', nanosoft_attributes( $attributes ) );\n}", "title": "" }, { "docid": "19f19a0d7c3b7380012a5850baeae77f", "score": "0.6652855", "text": "function agriflex_small_logo( $link, $args ) {\n\n $style = of_get_option( 'site-title' );\n $logo = of_get_option( 'custom-site-logo' );\n\n if ( $style == 1 && ! empty( $logo ) ) {\n $img = '<img src=\"' . $logo . '\" alt=\"' . $args['name'] . '\" />';\n $display = $img . $args['name'];\n\n $link = '<a href=\"' . $args['url'] . '\" ';\n $link .= 'title=\"' . $args['name'] . '\">';\n $link .= $display;\n $link .= '</a>';\n\n return $link;\n }\n\n return $link;\n\n}", "title": "" }, { "docid": "20fd19ce794b0c0f6cc75476d02dd633", "score": "0.66412544", "text": "function custom_login_logo() {\n\t\techo '<style type=\"text/css\">\n\t\t.login h1 a { background-image: url('.get_bloginfo('template_directory').'/images/logo_natoura_wp_admin.png) !important; height: 130px; background-size: auto; }\n\t\t</style>';\n\t}", "title": "" }, { "docid": "089ac725c5d274347546090da0b20f8b", "score": "0.66382295", "text": "public function change_login_logo()\n {\n $logo_url = esc_url(get_theme_mod($this->logo_setting_name));\n if (get_theme_mod($this->logo_setting_name)): \n ?>\n <style type=\"text/css\">\n #login h1 a, .login h1 a {\n background-image: url(<?php echo $logo_url; ?>);\n width: 200px;\n height: 150px;\n background-size: 200px;\n padding-bottom: 30px;\n }\n </style>\n <?php \n endif;\n }", "title": "" }, { "docid": "bdcca3d6b9d800598e1100a4240292dc", "score": "0.66264534", "text": "function wp_custom_logo_in_login() { ?>\n<style type=\"text/css\">\n#login h1 a, .login h1 a {background-image:url('https://comet-space.nyc3.digitaloceanspaces.com/assets/default/logo-inova-circle-pink.png');background-repeat:no-repeat;background-size: 120px;height:120px;width:120px;}body{background:#141414!important}.login #backtoblog a,.login #nav a{color:#adadad!important}.login #login_error,.login .message,.login .success,.login form{border-radius:10px}.wp-core-ui .button-primary{background:#000!important;border-color:#000!important;box-shadow:none!important;color:#fff!important;text-decoration:none!important;text-shadow:none!important;border-radius:0!important;}input[type=text]:focus, input[type=password]:focus { border-color: #ff0083 !important;\n box-shadow: none !important;}\n</style>\n<?php }", "title": "" }, { "docid": "39ef7c8d1fd80c43ea3d9b4a4b934a64", "score": "0.66161895", "text": "function record_custom_login_logo() {\n echo '<style> h1 a { background-image:url('.get_bloginfo('template_directory').'/images/logo.png) !important; }</style>';\n}", "title": "" }, { "docid": "d02da1ed10b03b80ff3531110f9176c3", "score": "0.6592709", "text": "function md_custom_login_logo() {\n\t echo '<style type=\"text/css\">\n\t\t\t h1 a { background-image: url('.get_template_directory_uri().'/styles/images/general/admin_logo.png) !important; }\n\t\t\t</style>';\n\t}", "title": "" }, { "docid": "ad7a01f071e095c5c6667e88f5654887", "score": "0.6589208", "text": "function getLogo()\r\n\t{\r\n\t\treturn $this->a_info['logo'];\r\n\t}", "title": "" }, { "docid": "cc12894689cbfa8a06eb0585ab2b19fb", "score": "0.6583738", "text": "function my_custom_login_logo() {\n\tif (get_option('rt_custom_login_logo'))\n echo '<style type=\"text/css\">\n h1 a { background-image:url('. get_option('rt_custom_login_logo') .') !important; }\n </style>';\n\telse \n\t echo '<style type=\"text/css\">\n h1 a { background-image:url('.get_bloginfo('template_directory').'/admin/images/logo-login.gif\") !important; }\n </style>';\n}", "title": "" }, { "docid": "e851cce5fbbdda202f9a1d2bf16b02d9", "score": "0.6563897", "text": "function CLM_login_logo() { ?>\n <style type=\"text/css\">\n #login h1 a, .login h1 a {\n background-image: url(<?php echo get_stylesheet_directory_uri(); ?>/assets/images/logo.svg);\n height:275px;\n width:320px;\n background-size: 320px 275px;\n background-repeat: no-repeat;\n padding-bottom: 30px;\n }\n </style>\n<?php }", "title": "" }, { "docid": "a1f267ab056dcf1acbdd9cfc51a44723", "score": "0.6557583", "text": "function custom_header_inline_logo( $title, $inside, $wrap ) {\n\t// If the custom logo function and custom logo exist, set the logo image element inside the wrapping tags.\n\tif ( function_exists( 'has_custom_logo' ) && has_custom_logo() ) {\n\t\t$inside = sprintf( '<span class=\"screen-reader-text\">%s</span>%s', esc_html( get_bloginfo( 'name' ) ), get_custom_logo() );\n\t} else {\n\t\t// If no custom logo, wrap around the site name.\n\t\t$inside\t= sprintf( '<a href=\"%s\">%s</a>', trailingslashit( home_url() ), esc_html( get_bloginfo( 'name' ) ) );\n\t}\n\n\t// Determine which wrapping tags to use.\n\t$wrap = genesis_is_root_page() && 'title' === genesis_get_seo_option( 'home_h1_on' ) ? 'h1' : 'p';\n\n\t// A little fallback, in case a SEO plugin is active.\n\t$wrap = genesis_is_root_page() && ! genesis_get_seo_option( 'home_h1_on' ) ? 'h1' : $wrap;\n\n\t// Wrap homepage site title in p tags if static front page.\n\t$wrap = is_front_page() && ! is_home() ? 'p' : $wrap;\n\n\t// And finally, $wrap in h1 if HTML5 & semantic headings enabled.\n\t$wrap = genesis_html5() && genesis_get_seo_option( 'semantic_headings' ) ? 'h1' : $wrap;\n\n\t// Build the title.\n\t$title = genesis_markup( array(\n\t\t'open' => sprintf( \"<{$wrap} %s>\", genesis_attr( 'site-title' ) ),\n\t\t'close' => \"</{$wrap}>\",\n\t\t'content' => $inside,\n\t\t'context' => 'site-title',\n\t\t'echo' => false,\n\t\t'params' => array(\n\t\t\t'wrap' => $wrap,\n\t\t),\n\t) );\n\n\treturn $title;\n}", "title": "" }, { "docid": "523af6d02df26599c2e63d5aa54803f2", "score": "0.6556616", "text": "function SLUG_custom_login_logo() {\r\n\techo '\r\n <style type=\"text/css\">\r\n\t .login h1 a { background-image: url('. html::getImageUrl('logo.png') .'); background-size: auto; }\r\n </style>';\r\n}", "title": "" }, { "docid": "bece224c682acb78e3a9b89f3a3fa3ef", "score": "0.65516406", "text": "function sp_custom_login_logo() {\n echo '<style type=\"text/css\">\n\t\tbody.login{ background-color:#ffffff; }\n .login h1 a { background-image:url('.SP_ASSETS_THEME.'images/logo.png) !important; height:87px !important; width:395px !important; background-size: auto auto !important; margin-left:-35px;}\n </style>';\n}", "title": "" }, { "docid": "151a366780a8160e7f485b57aca8adb0", "score": "0.65513235", "text": "function wlcms_custom_logo() {\n echo '\n\t <style type=\"text/css\">\n\t\t #header-logo { background-image: url('.get_bloginfo('template_directory').'/images/' . get_option('wlcms_o_header_custom_logo') . ') !important; }\n\t </style>\n ';\n}", "title": "" }, { "docid": "452b97f1e111e26b0d332d24ab5b8ca7", "score": "0.65497535", "text": "function _s_site_logo() {\n\t\n\t$logo = '';\n\t\n\tif( is_silo_page() ) {\n\t\t$logo = '-white';\n\t}\n\t\n\t$logos = sprintf('<div class=\"show-for-xxlarge\"><img src=\"%slogo%s.png\" alt=\"%s\"/></div>', trailingslashit( THEME_IMG ) , $logo, get_bloginfo( 'name' ) );\t\n\t\n\t$logos .= sprintf('<div class=\"show-for-xlarge hide-for-xxlarge\"><img src=\"%stablet-logo%s.png\" alt=\"%s\"/></div>', trailingslashit( THEME_IMG ) , $logo, get_bloginfo( 'name' ) );\t\n\t\n\t$logos .= sprintf('<div class=\"hide-for-xlarge\"><img src=\"%smobile-logo%s.png\" alt=\"%s\"/></div>', trailingslashit( THEME_IMG ) , $logo, get_bloginfo( 'name' ) );\t\n\t\n\treturn $logos;\n}", "title": "" }, { "docid": "3f1b9203d64fcd9b19b874ece59a66b3", "score": "0.65494597", "text": "public function enable_logo_in_header() {\n\t\tglobal $post;\n\n\t\tif ( _is_wcf_checkout_type() ) {\n\t\t\t$checkout_id = $post->ID;\n\t\t} else {\n\t\t\t$checkout_id = _get_wcf_checkout_id_from_shortcode( $post->post_content );\n\t\t}\n\n\t\t$header_logo_image = wcf()->options->get_checkout_meta_value( $checkout_id, 'wcf-header-logo-image' );\n\t\t$add_image_markup = '';\n\n\t\tif ( isset( $header_logo_image ) && ! empty( $header_logo_image ) ) {\n\t\t\t$add_image_markup = '<div class=\"wcf-checkout-header-image\">';\n\t\t\t\t$add_image_markup .= '<img src=\"' . $header_logo_image . '\" />';\n\t\t\t$add_image_markup .= '</div>';\n\t\t}\n\n\t\techo $add_image_markup;\n\t}", "title": "" }, { "docid": "ef92acba612f5da4defa356620164c0d", "score": "0.6543449", "text": "function agriflex_big_logo( $link, $args ) {\n\n $style = of_get_option( 'site-title' );\n $logo = of_get_option( 'custom-site-logo' );\n\n if ( $style == 2 && ! empty( $logo ) ) {\n $img = '<img src=\"' . $logo . '\" alt=\"' . $args['name'] . '\" />';\n $display = $img . '<span class=\"full-img-text\">' . $args['name'] . '</span>';\n\n $link = '<a href=\"' . $args['url'] . '\" ';\n $link .= 'title=\"' . $args['name'] . '\">';\n $link .= $display;\n $link .= '</a>';\n\n return $link;\n }\n\n return $link;\n\n}", "title": "" }, { "docid": "8918a5b59cde16555f6ef4ed21e79f22", "score": "0.6542363", "text": "function my_custom_login_logo()\n{\n\techo '<style type=\"text/css\"> h1 a { background-image:url('.get_bloginfo('template_directory').'/images/logos/bcu.png) !important; } </style>';\n}", "title": "" }, { "docid": "da09de0b07f15b67a045be1deefc9a26", "score": "0.6538631", "text": "function theme_logo( WP_Customize_Manager $manager ) {\n\t$manager->add_setting(\n\t\t'atu_logo_setting',\n\t\t[\n\t\t\t'type' => 'theme_mod',\n\t\t]\n\t);\n\n\t$manager->add_control(\n\t\tnew WP_Customize_Media_Control(\n\t\t\t$manager,\n\t\t\t'atu_logo_setting',\n\t\t\tarray(\n\t\t\t\t'label' => esc_html( 'Upload Logo', 'atu' ),\n\t\t\t\t'section' => 'title_tagline',\n\t\t\t\t'settings' => 'atu_logo_setting',\n\t\t\t)\n\t\t)\n\t);\n}", "title": "" }, { "docid": "0a72e48f18a0b3fc8310d28ea0fa58e6", "score": "0.65354145", "text": "function custom_login_logo() {\n\techo '<style type=\"text/css\">\n\th1 a { background-image: url('.get_bloginfo('template_directory').'/images/custom-login-logo.png) !important; }\n\t</style>';\n}", "title": "" }, { "docid": "e2b755b16898b3734439ffe507d022f8", "score": "0.6529725", "text": "public static function _logo(){\n $logo = @\\Wh::constant_key(_MAIN_OPTIONS_, \"_logo_\");\n return !empty($logo)? '<a href=\"'.url(\"/\").'\"><img class=\"logo\" src=\"'.url('/public/img/'.$logo).'\"/></a>' : '';\n }", "title": "" }, { "docid": "947f8adbac99414608801da86e20d359", "score": "0.6526319", "text": "protected function _headerLogo()\r\n\t{\r\n\t}", "title": "" }, { "docid": "a8572a6beefe1d6b468b9ca8ba0b3b0a", "score": "0.65202355", "text": "function custom_login_logo() {\n\techo '<style type=\"text/css\">\n\th1 a { background-image: url(/wp-content/uploads/logo-admin.png) !important; background-size:150px!Important;height:95px!Important;width:150px!Important;}\n\t</style>';\n}", "title": "" }, { "docid": "4afdbd9cc0ffd462221eb298f70ad658", "score": "0.651829", "text": "function usac_set_logo() {\nthrow new coding_exception('Please call theme_'.__FUNCTION__.' instead of '.__FUNCTION__);\n}", "title": "" }, { "docid": "ffe47cc72d6336b879052c4bbc5bd5e0", "score": "0.6508887", "text": "function tc_display_logo_title() {\n $logo_src \t\t\t= esc_url ( tc__f ( '__get_option' , 'tc_logo_upload' )) ;\n $logo_resize \t\t\t= esc_attr( tc__f ( '__get_option' , 'tc_logo_resize' ));\n //logo styling option\n $logo_img_style\t\t\t= '';\n if( $logo_resize == 1) {\n \t $logo_img_style \t\t= 'style=\"max-width:250px;max-height:100px\"';\n }\n\t\t?>\n\n\t\t<?php if( $logo_src != null) :?>\n\n <div class=\"brand span3\">\n <h1><a class=\"site-logo\" href=\"<?php echo esc_url( home_url( '/' ) ); ?>\" title=\"<?php echo esc_attr( get_bloginfo( 'name' , 'display' ) ); ?> | <?php bloginfo( 'description' ); ?>\"><img src=\"<?php echo $logo_src ?>\" alt=\"<?php _e( 'Back Home' , 'customizr' ); ?>\" <?php echo $logo_img_style ?>/></a>\n </h1>\n </div>\n\n\t <?php else : ?>\n\n <div class=\"brand span3 pull-left\">\n <h1><a class=\"site-title\" href=\"<?php echo esc_url( home_url( '/' ) ); ?>\" title=\"<?php echo esc_attr( get_bloginfo( 'name' , 'display' ) ); ?> | <?php bloginfo( 'description' ); ?>\"><?php bloginfo( 'name' ); ?></a>\n </h1>\n </div>\n\n\t <?php endif; ?>\n\t \n\t <?php \n\t}", "title": "" }, { "docid": "81a9dac28d67e447b54ab3b4d23a7d9b", "score": "0.6502723", "text": "function si_doc_header_logo_url() {\n\t\t$fullpath = si_locate_file( array(\n\t\t\t\t\t'logo.png',\n\t\t\t\t\t'logo.jpg',\n\t\t\t\t\t'logo.gif',\n\t\t\t\t) );\n\t\t$path = str_replace( WP_CONTENT_DIR, '', $fullpath );\n\t\treturn content_url( $path );\n\t}", "title": "" }, { "docid": "a540b68474bebfebd557bdf370e15291", "score": "0.64929825", "text": "function my_custom_login_logo() {\n echo '<style type=\"text/css\">\n\t\t h1 a {\n\t\t background-size: 227px 85px !important;\n\t\t margin-bottom: 20px !important;\n\t\t background-image:url('.get_bloginfo('template_directory').'/images/logo.png) !important; }\n\t\t </style>';\n}", "title": "" }, { "docid": "a540b68474bebfebd557bdf370e15291", "score": "0.64929825", "text": "function my_custom_login_logo() {\n echo '<style type=\"text/css\">\n\t\t h1 a {\n\t\t background-size: 227px 85px !important;\n\t\t margin-bottom: 20px !important;\n\t\t background-image:url('.get_bloginfo('template_directory').'/images/logo.png) !important; }\n\t\t </style>';\n}", "title": "" }, { "docid": "d13bc2f7673b0c6d5d9837f8f2f00276", "score": "0.648651", "text": "function escapade_custom_logo_args( $args ) {\n\n\t$args['width'] = 180;\n\t$args['height'] = 80;\n\n\treturn $args;\n\n}", "title": "" }, { "docid": "41a12dc2d62f680cfefc03440c1f3a8c", "score": "0.6485711", "text": "function one_page_express_logo( $footer = false ) {\n\tif ( function_exists( 'has_custom_logo' ) && has_custom_logo() ) {\n\t\t$dark_logo_image = get_theme_mod( 'one_page_express_logo_dark', false );\n\t\tif ( $dark_logo_image ) {\n\t\t\t$dark_logo_html = sprintf( '<a href=\"%1$s\" class=\"logo-link dark\" rel=\"home\" itemprop=\"url\">%2$s</a>',\n\t\t\t\tesc_url( home_url( '/' ) ),\n\t\t\t\twp_get_attachment_image( $dark_logo_image, 'full', false, array(\n\t\t\t\t\t'class' => 'logo dark',\n\t\t\t\t\t'itemprop' => 'logo',\n\t\t\t\t) )\n\t\t\t);\n\n\t\t\techo $dark_logo_html;\n\t\t}\n\n\t\tthe_custom_logo();\n\t} elseif ( $footer ) {\n\t\tprintf( '<h2 class=\"footer-logo\">%1$s</h2>', get_bloginfo( 'name' ) );\n\t} else {\n\t\tprintf( '<a class=\"text-logo\" href=\"%1$s\">%2$s</a>', esc_url( home_url( '/' ) ), one_page_express_bold( get_bloginfo( 'name' ) ) );\n\t}\n}", "title": "" }, { "docid": "24b7077e640248d2c53a47ec0218bc1e", "score": "0.6482023", "text": "function logo_image(){\n\tglobal $sf_data;\n\t$logo_image = $sf_data['logo'];\n\t\n\t// Filter\n\t$logo_image = apply_filters( 'sf_logo_image', $logo_image );\n\t\n\treturn $logo_image;\n}", "title": "" }, { "docid": "5064cd9ef376aac7d150efc79a1bf014", "score": "0.64779484", "text": "function wpb_custom_logo() {\r\necho '<style type=\"text/css\">\r\n #wpadminbar #wp-admin-bar-wp-logo > .ab-item .ab-icon:before {\r\n background-image: url(' . get_bloginfo('stylesheet_directory') . '/images/core-image/icon.png) !important;\r\n background-position: center center;\r\n background-size: cover;\r\n backgroun-repeat: no-repeat;\r\n color:rgba(0, 0, 0, 0);\r\n }\r\n #wpadminbar #wp-admin-bar-wp-logo.hover > .ab-item .ab-icon {\r\n background-position: 0 0;\r\n }\r\n </style>\r\n';\r\n}", "title": "" }, { "docid": "8be340cbbf07a23ca1153fa89fe9310f", "score": "0.6476912", "text": "function my_custom_login_logo()\n{\n echo '\n <style>\n .login h1 a {\n background-image:url(\"' . get_option('consilio_options')['login_logo'] . '\");\n background-size: ' . get_option('consilio_options')['width_login_logo'] . ' ' . get_option('consilio_options')['height_login_logo'] . ';\n color: blue;\n fill: currentColor;\n width: 100%;\n }\n ' . get_option('consilio_options')['login_css'] . '\n </style>\n ';\n}", "title": "" }, { "docid": "fe49ebcda2891ed952455a80836ef19d", "score": "0.6466516", "text": "function custom_logo_url() {\n\treturn get_bloginfo( 'url' );\n}", "title": "" }, { "docid": "295dbb77cb7103015c97fb916c4c32eb", "score": "0.6465175", "text": "function eati_setup_theme () {\r\n\tadd_theme_support( 'custom-logo', array(\r\n 'height' => 50, // 200px de largura\r\n 'flex-width' => true,\r\n 'header-text' => array( 'site-title' ),\r\n ));\r\n}", "title": "" }, { "docid": "b321e74bb127e44b24eb44ddc6eea63c", "score": "0.6454357", "text": "function wpb_login_logo() { ?>\n <style type=\"text/css\">\n #login h1 a, .login h1 a {\n background-image: url(<?php echo IMAGE_PATH; ?>/logo.svg);\n height:100px;\n width:300px;\n background-size: 300px 100px;\n background-repeat: no-repeat;\n padding-bottom: 10px;\n }\n </style>\n <?php }", "title": "" }, { "docid": "c8e056b59c9421327f17a4bbc761bc62", "score": "0.64418226", "text": "function theme_prefix_setup() {\r\n\tadd_theme_support( 'custom-logo');\r\n}", "title": "" }, { "docid": "c0d7743135af828be835151e84f90512", "score": "0.64411354", "text": "function my_login_logo_url_title() {\n\t return 'Huecis Team Freelance';\n\t}", "title": "" }, { "docid": "23fa153a01ff8e4e1c9c01f82ee810f4", "score": "0.64392006", "text": "function theme_usac_set_logo($css, $logo) {\n$tag = '[[setting:logo]]';\n$replacement = $logo;\nif (is_null($replacement)) {\n$replacement = '';\n}\n$css = str_replace($tag, $replacement, $css);\nreturn $css;\n}", "title": "" }, { "docid": "8f516ec07e0581900ab88df4070371b9", "score": "0.6433089", "text": "public function getLogoUrl();", "title": "" }, { "docid": "8f516ec07e0581900ab88df4070371b9", "score": "0.6433089", "text": "public function getLogoUrl();", "title": "" }, { "docid": "56ee4097a8c8a49f7c902c0d43ba43fc", "score": "0.6429385", "text": "function my_login_logo() { ?>\n <style type=\"text/css\">\n #login h1 a, .login h1 a {\n background-image: url(<?php echo get_stylesheet_directory_uri(); ?>/img/au-login-logo.svg);\n height:65px;\n width:320px;\n background-size: 320px 65px;\n background-repeat: no-repeat;\n padding-bottom: 30px;\n }\n </style>\n<?php }", "title": "" }, { "docid": "2d082042c21610f25ea0d07b061487b8", "score": "0.6428027", "text": "function custom_login_logo() {\n\techo '<style type=\"text/css\">\n\t.login h1 a {\n\t\tbackground-image: url('.get_bloginfo('template_directory').'/images/breadwinner_login_logo.png) !important;\n\t\tbackground-size: 150px !important;\n\t\theight: 110px;\n\t\twidth: 150px !important;\n\t}\n\t</style>';\n}", "title": "" }, { "docid": "17eac815c134deefb6b300a6e0635d07", "score": "0.6424194", "text": "function rws_replace_login_logo() {\n\n\t?><style type=\"text/css\">\n\t\t.login h1 a {\n\t\t\tbackground-image: url(<?php echo get_stylesheet_directory_uri() ?>/images/login-logo.png);\n\n\t\t\t/* Adjust to the dimensions of your logo. WP Default: 80px 80px */\n\t\t\tbackground-size: 80px 80px;\n\t\t\twidth: 80px;\n\t\t\theight: 80px;\n\t\t}\n\t</style>\n\t<?php\n\n}", "title": "" }, { "docid": "c6e5056e0d8ae08a074fff76828d2b03", "score": "0.64116055", "text": "function my_login_logo() { ?>\n\t\t<style type=\"text/css\">\n\t\t\tbody.login div#login h1 a {\n\t\t\t\tbackground-image: url(<?php echo get_stylesheet_directory_uri(); ?>/images/bhmLogo.png);\n\t\t\t\tpadding-bottom: 30px;\n\t\t\t\tbackground-size: cover;\n\t\t\t\tmargin-left: 0px;\n\t\t\t\tmargin-bottom: 0px;\n\t\t\t\tmargin-right: 0px;\n\t\t\t\theight: 105px;\n\t\t\t\twidth: 100%;\n\t\t\t}\n\t\t</style>\n\t<?php }", "title": "" }, { "docid": "0bf9943faca8b8520c15aea4a2fdee71", "score": "0.64051163", "text": "function my_login_logo() { ?>\n<style type=\"text/css\">\n body.login div#login h1 a {\n \tbackground-image: url(<?php echo get_stylesheet_directory_uri(); ?>/images/logo.png);\n \tbackground-size: 327px 67px;\n \twidth: 327px;\n \theight: 67px;\n }\n</style>\n<?php }", "title": "" }, { "docid": "47511547014dcfa24eadc0fe1bd3c4f4", "score": "0.64038646", "text": "function custom_login_logo_url() {\n\t\treturn home_url();\n\t}", "title": "" }, { "docid": "ecb7b0550d9910da9ec49186deb24e2d", "score": "0.6402564", "text": "function property_login_logo() { \n\t$ch_data = new ch_option;\n\t$filename = wp_get_attachment_url($ch_data->ch_get_opt('custom_login_logo_id'));\n\t$size = getimagesize($filename);\n\t?>\n <style type=\"text/css\">\n #login h1 a, .login h1 a {\n background-image: url(<?= ( $ch_data->ch_get_opt('custom_login_logo_id'))?wp_get_attachment_url($ch_data->ch_get_opt('custom_login_logo_id')):''; ?>);\n\t\theight:<?= ($size[1])?$size[1]:'0'; ?>px;\n\t\twidth:100%;\n\t\tbackground-size: 100% <?= ($size[1])?$size[1]:'0'; ?>px;\n\t\tbackground-repeat: no-repeat;\n }\n </style>\n<?php }", "title": "" }, { "docid": "a09d1212cae812a48292788310548f28", "score": "0.639975", "text": "function custom_loginpage_logo_title($message)\n{\n return get_bloginfo('name');\n}", "title": "" }, { "docid": "bda64056fcccc0bbd817e42941c59995", "score": "0.63797873", "text": "function custom_logo_class( $html ) {\n // $html = str_replace( 'custom-logo', 'your-custom-class', $html );\n $html = str_replace( 'custom-logo-link', 'custom-logo-link navbar-brand', $html );\n\n return $html;\n }", "title": "" }, { "docid": "ddbc86a643e2fc6ac249f3412cbbc4be", "score": "0.6379392", "text": "function claudinebananal_logo_title() {\n\treturn 'View Portfolio Site';\n}", "title": "" }, { "docid": "867201c24c18a1821bead6da04d35f1c", "score": "0.637469", "text": "function charity_is_hope_get_logo_icon($slug) {\n\t\t// This way ignore the 'Retina' setting and load retina logo on any display with retina support\n\t\t$mult = (int) charity_is_hope_get_value_gpc('charity_is_hope_retina', 0) > 0 ? 2 : 1;\n\t\t$logo_icon = '';\n\t\tif ($mult > 1) \t\t\t$logo_icon = charity_is_hope_get_custom_option($slug.'_retina');\n\t\tif (empty($logo_icon))\t$logo_icon = charity_is_hope_get_custom_option($slug);\n\t\treturn $logo_icon;\n\t}", "title": "" }, { "docid": "22a448c88b151f33cc25a84ee6d5f504", "score": "0.6371474", "text": "function tlpm_custom_logo(){\r\n\techo '<style type=\"text/css\"> #header-logo { background-image: url('.plugins_url().'/tlproductman/images/admin-icon.png) !important; }</style>';\r\n}", "title": "" }, { "docid": "8a0927d562fcb390eaf6665767b3dcef", "score": "0.63705784", "text": "function lawyerist_login_logo() { ?>\n\n\t<style type=\"text/css\">\n\n\t\t#login h1 a,\n\t\t.login h1 a {\n\t\t\tbackground-image: url( <?php echo get_stylesheet_directory_uri(); ?>/images/L-dot-login.png );\n\t\t}\n\n\t</style>\n\n<?php }", "title": "" }, { "docid": "e4a6fc2a86f14a73db19ae1d9604664d", "score": "0.6369164", "text": "function ecrannoir_theme_site_logo( $args = array(), $echo = true, $color = false) {\n\t$logo = get_custom_logo();\n\t$site_title = get_bloginfo( 'name' );\n\t$contents = '';\n\t$classname = '';\n\n\t$defaults = array(\n\t\t'logo' => '<a href=\"%1$s\">%2$s<span class=\"screen-reader-text\">%3$s</span></a>',\n\t\t'logo_class' => 'site-logo',\n\t\t'title' => '<a href=\"%1$s\">%2$s</a>',\n\t\t'title_class' => 'site-title',\n\t\t'home_wrap' => '<h1 class=\"%1$s\">%2$s</h1>',\n\t\t'single_wrap' => '<div class=\"%1$s\">%2$s</div>',\n\t\t'condition' => ( is_front_page() || is_home() ) && ! is_page(),\n );\n \n if (!has_custom_logo()) {\n $logo = Icons::get_svg('logo', 'brand', $color);\n }\n\n\t$args = wp_parse_args( $args, $defaults );\n\n\t/**\n\t * Filters the arguments for `ecrannoir_theme_site_logo()`.\n\t *\n\t * @param array $args Parsed arguments.\n\t * @param array $defaults Function's default arguments.\n\t */\n\t$args = apply_filters( 'ecrannoir_theme_site_logo_args', $args, $defaults );\n\n\tif ( has_custom_logo() || $logo ) {\n\t\t$contents = sprintf( $args['logo'], esc_url( get_home_url( null, '/' ) ), $logo, esc_html( $site_title ) );\n\t\t$classname = $args['logo_class'];\n\t} else {\n\t\t$contents = sprintf( $args['title'], esc_url( get_home_url( null, '/' ) ), esc_html( $site_title ) );\n\t\t$classname = $args['title_class'];\n\t}\n\n\t$wrap = $args['condition'] ? 'home_wrap' : 'single_wrap';\n\n\t$html = sprintf( $args[ $wrap ], $classname, $contents );\n\n\t/**\n\t * Filters the arguments for `ecrannoir_theme_site_logo()`.\n\t *\n\t * @param string $html Compiled html based on our arguments.\n\t * @param array $args Parsed arguments.\n\t * @param string $classname Class name based on current view, home or single.\n\t * @param string $contents HTML for site title or logo.\n\t */\n\t$html = apply_filters( 'ecrannoir_theme_site_logo', $html, $args, $classname, $contents );\n\n\tif ( ! $echo ) {\n\t\treturn $html;\n\t}\n\n\techo $html; //phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped\n\n}", "title": "" }, { "docid": "78ae53c75f52fcf6dcd573ad9a67d2d0", "score": "0.63593227", "text": "function laurel_get_logo() {\r\n\tif(!get_theme_mod('laurel_logo') && !get_theme_mod('laurel_text_logo')) {\r\n\t\t?>\r\n\t\t\t<?php if(is_front_page()) : ?>\r\n\t\t\t\t<a href=\"<?php echo esc_url( home_url( '/' ) ); ?>\"><img src=\"<?php echo get_template_directory_uri(); ?>/img/logo.png\" alt=\"<?php bloginfo( 'name' ); ?>\" /></a>\r\n\t\t\t<?php else : ?>\r\n\t\t\t\t<a href=\"<?php echo esc_url( home_url( '/' ) ); ?>\"><img src=\"<?php echo get_template_directory_uri(); ?>/img/logo.png\" alt=\"<?php bloginfo( 'name' ); ?>\" /></a>\r\n\t\t\t<?php endif; ?>\r\n\t\t<?php\r\n\t} elseif(get_theme_mod('laurel_logo') && !get_theme_mod('laurel_text_logo')) {\r\n\t\t?>\r\n\t\t\t<?php if(is_front_page()) : ?>\r\n\t\t\t\t<a href=\"<?php echo esc_url( home_url( '/' ) ); ?>\"><img src=\"<?php echo esc_url(get_theme_mod('laurel_logo')); ?>\" alt=\"<?php bloginfo( 'name' ); ?>\" /></a>\r\n\t\t\t<?php else : ?>\r\n\t\t\t\t<a href=\"<?php echo esc_url( home_url( '/' ) ); ?>\"><img src=\"<?php echo esc_url(get_theme_mod('laurel_logo')); ?>\" alt=\"<?php bloginfo( 'name' ); ?>\" /></a>\r\n\t\t\t<?php endif; ?>\r\n\t\t<?php\r\n\t} elseif(get_theme_mod('laurel_text_logo')) {\r\n\t\t?>\r\n\t\t\t<?php if(is_front_page()) : ?>\r\n\t\t\t\t<h1 class=\"text-logo\"><a href=\"<?php echo esc_url( home_url( '/' ) ); ?>\"><?php echo bloginfo( 'name' ); ?></a></h1>\r\n\t\t\t<?php else : ?>\r\n\t\t\t\t<h2 class=\"text-logo\"><a href=\"<?php echo esc_url( home_url( '/' ) ); ?>\"><?php echo bloginfo( 'name' ); ?></a></h2>\r\n\t\t\t<?php endif; ?>\r\n\t\t<?php\r\n\t}\r\n}", "title": "" }, { "docid": "462291f093cb797c98b228b520783132", "score": "0.6358945", "text": "function custom_login_logo() {\n echo '<style type=\"text/css\">\n .login h1 { \n background-image:url('.get_bloginfo('template_directory').'/public/images/logo_admin.png) !important;\n background-size: 300px 56px;\n background-position: top center;\n background-repeat: no-repeat;\n width: 326px;\n height: 60px;\n margin-bottom: 5px;\n }\n .login h1 a {display:none; !important;}\n \n </style>';\n}", "title": "" }, { "docid": "970988c8991d711e30c949b66d9fcf59", "score": "0.63510144", "text": "function custom_login_logo() { ?>\n <style type=\"text/css\">\n .login h1 a {\n width: 50%;\n height: 150px;\n background-image: url(<?php echo get_stylesheet_directory_uri(); ?>/dist/images/logo-cedreo-interactive-b.png);\n background-size: 100%;\n }\n </style>\n<?php }", "title": "" }, { "docid": "7185784ffd2ee9f79f3e0cb447b33e14", "score": "0.6346535", "text": "function custom_logo_fields(){\r\n}", "title": "" }, { "docid": "a5b0bc153d67e01e22ea7c26e0825289", "score": "0.6344647", "text": "function logo()\n{\n\techo \"<div style='width:540px;'>\";\n\t\techo\t\"<div style='font-size:60px;color:#AAAAAA;margin-bottom:-13px;'>\";\n\t\techo\t\t\"<b>Docu</b>\";\n\t\techo\t\"</div>\";\n\t\techo\t\"<div style='color:#AAAAAA;'>\";\n\t\techo\t\t\"<b>Version 1.0</b>&nbsp;|&nbsp;Creado por <a href='https://twitter.com/DamCipolat' target='_blank'>@Damcipolat</a>&nbsp;&nbsp;<img src='./imgs/arg_flag.png' style='margin-top:-3px;'>\";\n\t\techo\t\"</div>\";\n\techo\t\"</div>\";\n}", "title": "" }, { "docid": "58c3cd737344196db560e0910483b446", "score": "0.633938", "text": "function rb_custom_login_logo() {\r\n echo '<style type=\"text/css\">\r\n h1 a { background-image:url('.get_template_directory_uri().'/images/customLoginLogo.png) !important; }\r\n </style>';\r\n}", "title": "" } ]
a4ae0f847f2520c72dff185bf602bb76
function: events_messages END function: events_category BEGIN
[ { "docid": "ff71322aee864243cd99713ebe6a9c0c", "score": "0.0", "text": "function events_category()\n{\n register_taxonomy(\n __( \"events_category\" ),\n array(__( \"events\" )),\n array(\n \"hierarchical\" => true,\n \"label\" => __( \"Category\" ),\n \"singular_label\" => __( \"Category\" ),\n 'show_ui' => true,\n 'show_admin_column' => true,\n \"rewrite\" => array(\n 'slug' => 'events_category',\n 'hierarchical' => true\n )\n )\n );\n}", "title": "" } ]
[ { "docid": "2af10dc1ce3752887cf107fd0bc04c90", "score": "0.6385585", "text": "public function messages($event)\n {\n }", "title": "" }, { "docid": "6d28171b0f5ee22e1fcdf3f50e6dab0f", "score": "0.60872483", "text": "function category_updated_messages( $messages ) {\n\n\t$messages['category'] = array(\n\t\t0 => '', // Unused. Messages start at index 1.\n\t\t1 => __( 'Category added.', 'wordplate' ),\n\t\t2 => __( 'Category deleted.', 'wordplate' ),\n\t\t3 => __( 'Category updated.', 'wordplate' ),\n\t\t4 => __( 'Category not added.', 'wordplate' ),\n\t\t5 => __( 'Category not updated.', 'wordplate' ),\n\t\t6 => __( 'Categories deleted.', 'wordplate' ),\n\t);\n\n\treturn $messages;\n}", "title": "" }, { "docid": "1b18a81c7bc095231856ad70740a1a1a", "score": "0.59126467", "text": "public function messages();", "title": "" }, { "docid": "ce1b3dcfee73624c0671cbeb54706bb5", "score": "0.5904653", "text": "abstract public function getEventActionCategory(): string;", "title": "" }, { "docid": "1895b28f15473b3e1e05e4baca9247c0", "score": "0.5691335", "text": "function getMessages(){\r\n\t}", "title": "" }, { "docid": "6fbc0551eb798faeb9e3d0785ccf4a54", "score": "0.5664776", "text": "public function categoryInit($event, $arguments = array())\r\n\t{\r\n\t\t// Only on site side\r\n\t\tif( $this->joomla->isSite() )\r\n\t\t{\r\n\t\t\t$category = $event->getSubject();\r\n\t\t\t\r\n\t\t\t// Parameters\r\n\t\t\t$params = $category->getParams();\r\n\t\t\t\r\n\t\t\t// Current Language\r\n\t\t\t$lang = $this->app->lang->getCurrentLanguage();\r\n\t\t\t\r\n\t\t\t// Name Translation\r\n\t\t\t$name_translations = $params->get('content.name_translation', array());\r\n\t\t\tif( count( $name_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $name_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($name_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->name = $name_translations[$lang];\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Alias Translation\r\n\t\t\t$alias_translations = $params->get('content.alias_translation', array());\r\n\t\t\tif( count( $alias_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $alias_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($alias_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->alias = $alias_translations[$lang];\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Description\r\n\t\t\t$desc_translations = $params->get('content.desc_translation', array());\r\n\t\t\tif( count( $desc_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $desc_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($desc_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->description = $desc_translations[$lang];\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Teaser Description\r\n\t\t\t$desc_translations = $params->get('content.teaser_desc_translation', array());\r\n\t\t\tif( count( $desc_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $desc_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($desc_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('content.teaser_description', $desc_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Categories Title\r\n\t\t\t$desc_translations = $params->get('content.cat_title_translation', array());\r\n\t\t\tif( count( $desc_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $desc_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($desc_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('content.categories_title', $desc_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Items Title\r\n\t\t\t$desc_translations = $params->get('content.item_title_translation', array());\r\n\t\t\tif( count( $desc_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $desc_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($desc_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('content.items_title', $desc_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Sub Headline Title\r\n\t\t\t$sub_translations = $params->get('content.sub_headline_translation', array());\r\n\t\t\tif( count( $sub_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $sub_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($sub_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('content.sub_headline', $sub_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Teaser Image \r\n\t\t\t$timage_translations = $params->get('content.teaser_image_translation', array());\r\n\t\t\tif( count( $timage_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $timage_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($timage_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('content.teaser_image', $timage_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Teaser Image Width\r\n\t\t\t$timagew_translations = $params->get('content.teaser_image_translation_width', array());\r\n\t\t\tif( count( $timagew_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $timagew_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($timagew_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('content.teaser_image_width', $timagew_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Teaser Image Height\r\n\t\t\t$timageh_translations = $params->get('content.teaser_image_translation_height', array());\r\n\t\t\tif( count( $timageh_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $timageh_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($timageh_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('content.teaser_image_height', $timageh_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Image \r\n\t\t\t$image_translations = $params->get('content.image_translation', array());\r\n\t\t\tif( count( $image_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $image_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($image_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('content.image', $image_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Image Width\r\n\t\t\t$imagew_translations = $params->get('content.image_translation_width', array());\r\n\t\t\tif( count( $imagew_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $imagew_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($imagew_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('content.image_width', $imagew_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Image Height\r\n\t\t\t$imageh_translations = $params->get('content.image_translation_height', array());\r\n\t\t\tif( count( $imageh_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $imageh_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($imageh_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('content.image_height', $imageh_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\t// Meta Title\r\n\t\t\t$metaTitle_translations = $params->get('content.meta_title_translation', array());\r\n\t\t\tif( count( $metaTitle_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $metaTitle_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($metaTitle_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('metadata.title', $metaTitle_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Meta Description\r\n\t\t\t$metaDescription_translations = $params->get('content.meta_description_translation', array());\r\n\t\t\tif( count( $metaDescription_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $metaDescription_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($metaDescription_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('metadata.description', $metaDescription_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t// Meta Keywords\r\n\t\t\t$metaKeywords_translations = $params->get('content.meta_keywords_translation', array());\r\n\t\t\tif( count( $metaKeywords_translations ) )\r\n\t\t\t{\r\n\t\t\t\tif( array_key_exists($lang, $metaKeywords_translations))\r\n\t\t\t\t{\r\n\t\t\t\t\tif( strlen($metaKeywords_translations[$lang]) )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$category->getParams()->set('metadata.keywords', $metaKeywords_translations[$lang] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t}\t\t\r\n\t}", "title": "" }, { "docid": "b3199f6b8beee84920c6ca7618376398", "score": "0.56642467", "text": "function onMissingTranslation($event)\n{\n\tif (!$event->message)\n\t\treturn;\n\t$t = 'Message '.$event->category;\n\tif (Yii::app()->params['translation']['onMissingTranslation']['addToBottomDebug'] ||\n\t\tYii::app()->params['translation']['onMissingTranslation']['echo'])\n\t{\n\t\t$csvLine = '\"'.htmlentities(str_replace('\"', '\"\"', $event->message), ENT_QUOTES, 'UTF-8').'\"';\n\t\t$csvLine .= ','.$csvLine;\n\t\tif (Yii::app()->params['translation']['onMissingTranslation']['addToBottomDebug'] && !addToBottomDebug($t, $csvLine, true))\n\t\t\taddToBottomDebug($t, $csvLine);\n\t\tif (Yii::app()->params['translation']['onMissingTranslation']['echo'])\n\t\t\techo '<b>'.$event->category.'</b>: '.$csvLine.'<br/>';\n\t}\n}", "title": "" }, { "docid": "60d319a24c9009ba57a7f9322316a823", "score": "0.562774", "text": "function event_updated_messages( $messages ){\r\n global $post;\r\n if( 'events' == $post->post_type ):\r\n $event_id = $post->ID;\r\n $event_name = $post->post_title;\r\n $event_link = get_permalink($event_id);\r\n $messages['post'][1] = 'Event updated. <a href=\"' . $event_link . '\" >View Event</a>';\r\n $messages['post'][6] = 'Event published. <a href=\"' . $event_link . '\" >View Event</a>';\r\n elseif( 'products' == $post->post_type ):\r\n $event_id = $post->ID;\r\n $event_name = $post->post_title;\r\n $event_link = get_permalink($event_id);\r\n $messages['post'][1] = 'Product updated. <a href=\"' . $event_link . '\" >View Product</a>';\r\n $messages['post'][6] = 'Product published. <a href=\"' . $event_link . '\" >View Product</a>';\r\n endif;\r\n return $messages;\r\n }", "title": "" }, { "docid": "5a922ea5fb4e682df31177e553feb688", "score": "0.56164366", "text": "public function getEventActionCategory(): string;", "title": "" }, { "docid": "9286dac7f567154da0c1bb582b22c9e9", "score": "0.55146956", "text": "function getAllMessages()\n {\n }", "title": "" }, { "docid": "2272cfba803f4d2634235b987cc08c9c", "score": "0.5495423", "text": "public function getMessages( );", "title": "" }, { "docid": "dd8b07534345aa2236cdf71a648fc8a0", "score": "0.54455984", "text": "function message_post_message($userfrom, $userto, $message, $format) {\n global $PAGE;\n\n $eventdata = new \\core\\message\\message();\n $eventdata->courseid = 1;\n $eventdata->component = 'moodle';\n $eventdata->name = 'instantmessage';\n $eventdata->userfrom = $userfrom;\n $eventdata->userto = $userto;\n\n //using string manager directly so that strings in the message will be in the message recipients language rather than the senders\n $eventdata->subject = get_string_manager()->get_string('unreadnewmessage', 'message', fullname($userfrom), $userto->lang);\n\n if ($format == FORMAT_HTML) {\n $eventdata->fullmessagehtml = $message;\n //some message processors may revert to sending plain text even if html is supplied\n //so we keep both plain and html versions if we're intending to send html\n $eventdata->fullmessage = html_to_text($eventdata->fullmessagehtml);\n } else {\n $eventdata->fullmessage = $message;\n $eventdata->fullmessagehtml = '';\n }\n\n $eventdata->fullmessageformat = $format;\n $eventdata->smallmessage = $message;//store the message unfiltered. Clean up on output.\n $eventdata->timecreated = time();\n $eventdata->notification = 0;\n // User image.\n $userpicture = new user_picture($userfrom);\n $userpicture->size = 1; // Use f1 size.\n $userpicture->includetoken = $userto->id; // Generate an out-of-session token for the user receiving the message.\n $eventdata->customdata = [\n 'notificationiconurl' => $userpicture->get_url($PAGE)->out(false),\n 'actionbuttons' => [\n 'send' => get_string_manager()->get_string('send', 'message', null, $eventdata->userto->lang),\n ],\n 'placeholders' => [\n 'send' => get_string_manager()->get_string('writeamessage', 'message', null, $eventdata->userto->lang),\n ],\n ];\n return message_send($eventdata);\n}", "title": "" }, { "docid": "923052aa57e32087da1956bcadf1cd86", "score": "0.5441432", "text": "function wccw_mail_all($event_id)\n{\n die(__FUNCTION__ . \" id=$event_id\");\n}", "title": "" }, { "docid": "abb86f6001d89f5efa7b1a128055f664", "score": "0.5424703", "text": "function process_categories()\n {\n }", "title": "" }, { "docid": "0bcfd3c463f4b45584df29f958eb26af", "score": "0.5417599", "text": "public function section_messages() {\n\n\t\t// Blank.\n\n\t}", "title": "" }, { "docid": "efa89708c07af0a2eeb830bf8c8cf69b", "score": "0.5411137", "text": "public function getEventCategory()\n {\n $db = $this->getDatabaseObject();\n $query = \"select category_name from category\";\n $temp = $db->query($query);\n $result =array();\n if($temp->num_rows>0)\n {\n while($row = $temp->fetch_row())\n {\n $rows[] = $row;\n }\n $result['status'] = 'success';\n $result['message'] = 'Categories fetched successfully';\n $result['data'] = $rows;\n return $result;\n }\n else\n {\n $result['status'] = \"failure\";\n $result['message'] = 'Categories NOT fetched successfully '.$db->error;\n $result['data'] = '';\n return $result;\n }\n }", "title": "" }, { "docid": "a5f0b698409d23d3888c50822b36639c", "score": "0.53172153", "text": "function cats($_content=null,$msg='')\n\t{\n\t\tif ($_GET['msg']) $msg = $_GET['msg'];\n\n\t\tif ($_content['admin'] && $_content['nm']['action'] == 'admin')\n\t\t{\n\t\t\t$_content['nm']['action'] = $_content['admin'];\n\t\t}\n\t\tif($_content['nm']['action'])\n\t\t{\n\t\t\tif (!count($_content['nm']['selected']) && !$_content['nm']['select_all'])\n\t\t\t{\n\t\t\t\t$msg = lang('You need to select some entries first');\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// Some processing to add values in for links and cats\n\t\t\t\t$multi_action = $_content['nm']['action'];\n\t\t\t\t// Action has an additional action - add / delete, etc. Buttons named <multi-action>_action[action_name]\n\t\t\t\tif(in_array($multi_action, array('reader','writer')))\n\t\t\t\t{\n\t\t\t\t\t$_content['nm']['action'] .= '_' . key($_content[$multi_action.'_popup'][$multi_action . '_action'] ?? []);\n\n\t\t\t\t\tif(is_array($_content[$multi_action.'_popup'][$multi_action]))\n\t\t\t\t\t{\n\t\t\t\t\t\t$_content[$multi_action] = implode(',',$_content[$multi_action.'_popup'][$multi_action]);\n\t\t\t\t\t}\n\t\t\t\t\t$_content['nm']['action'] .= '_' . $_content[$multi_action];\n\t\t\t\t\tunset($_content['nm'][$multi_action]);\n\t\t\t\t}\n\t\t\t\t$success = $failed = $action_msg = null;\n\t\t\t\tif ($this->action($_content['nm']['action'],$_content['nm']['selected'],$_content['nm']['select_all'],\n\t\t\t\t\t$success,$failed,$action_msg,'cats',$msg,$_content['nm']['checkboxes']['no_notifications']))\n\t\t\t\t{\n\t\t\t\t\t$msg .= lang('%1 entries %2',$success,$action_msg);\n\t\t\t\t}\n\t\t\t\telseif(is_null($msg))\n\t\t\t\t{\n\t\t\t\t\t$msg .= lang('%1 entries %2, %3 failed because of insufficent rights !!!',$success,$action_msg,$failed);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t$content = array(\n\t\t\t'msg' => $msg,\n\t\t\t'nm' => Api\\Cache::getSession('news_admin', 'cats'),\n\t\t);\n\t\tif (!is_array($content['nm']))\n\t\t{\n\t\t\t$content['nm'] = array(\n\t\t\t\t'get_rows' =>\t'news_admin.news_admin_ui.get_cats', // I method/callback to request the data for the rows eg. 'notes.bo.get_rows'\n\t\t\t\t'start' =>\t0, // IO position in list\n\t\t\t\t'no_cat' =>\ttrue, // IO category, if not 'no_cat' => True\n\t\t\t\t'search' =>\t'', // IO search pattern\n\t\t\t\t'order' => 'news_date',// IO name of the column to sort after (optional for the sortheaders)\n\t\t\t\t'sort' => 'DESC', // IO direction of the sort: 'ASC' or 'DESC'\n\t\t\t\t'col_filter' => array(), // IO array of column-name value pairs (optional for the filterheaders)\n\t\t\t\t'no_filter' => true,\n\t\t\t\t'no_filter2' => true,\n\t\t\t\t'row_id' => 'id',\n\t\t\t\t'actions' => $this->get_actions()\n\t\t\t);\n\t\t}\n\t\t$this->tpl->read('news_admin.cats');\n\t\tif($_GET['user'])\n\t\t{\n\t\t\t$this->tpl->set_dom_id(\"news_admin-cats-user\");\n\t\t}\n\t\treturn $this->tpl->exec('news_admin.news_admin_ui.cats', $content, array(\n\t\t\t'owner' => array(Api\\Categories::GLOBAL_ACCOUNT => lang('All users'))\n\t\t));\n\t}", "title": "" }, { "docid": "0046b1dc5acc7de4970092a011920022", "score": "0.53159046", "text": "public static function USER_MSG()\r\n { \r\n return new EventType(6); \r\n }", "title": "" }, { "docid": "f373171d4998418c022fd700afdb66aa", "score": "0.5278421", "text": "function msg_list()\n{\n global $eh;\n return $eh->message_list;\n}", "title": "" }, { "docid": "ba29893c61b1ec4031469a7af88b4c0f", "score": "0.5239808", "text": "function category_updated_handler($eventdata){\n\t\tglobal $CFG;\n\t\tglobal $COURSE;\n\t global $USER;\n\t //check if this category is a MUMIE-semester\n\t $isinteresting = false;\n\t $modid = get_field('modules', 'id', 'name', 'mumiemodule');\n\t $modcourses = get_records('course_modules', 'module', $modid, '', 'course');\n\t foreach($modcourses as $modcourse){\n\t \tif(record_exists('course', 'id', $modcourse->course, 'category', $eventdata->id)){\n\t \t\t$isinteresting = true;\n\t \t\tbreak;\n\t \t}\n\t }\n\t if($isinteresting){\n\t\t event_logoutput(\"category_updated_handler called \\n\", $eventdata);\n\t\t $semester = new object();\n\t\t $semester->syncid = 'moodle-'.$CFG->prefix.'course_categories-'.$eventdata->id;\n\t\t $semester->name = $eventdata->name;\n\t\t $semester->description = 'a Moodle-category as semester';\n\t\t change_semester_for_mumie($semester);\n\t }\n\t\treturn true;\n\t}", "title": "" }, { "docid": "7105acdcc792b02dd9ccbb4ad6f66382", "score": "0.52347195", "text": "function Xphpblock_topic_categories()\n{\n global $_CONF, $_TABLES, $LANG_LINKS, $topic;\n\n $retval = '';\n\n if (!empty($topic)) {\n $tid = DB_escapeString($topic);\n $result = DB_query(\"SELECT category, cid FROM {$_TABLES['linkcategories']} WHERE tid='{$tid}' OR tid='all'\" . COM_getPermSQL ('AND'));\n $nrows = DB_numRows($result);\n if ($nrows > 0) {\n for ($i = 0; $i < $nrows; $i++) {\n $A = DB_fetchArray($result);\n $content = $A['category'];\n $url = $_CONF['site_url'] . '/links/index.php?category='\n . urlencode($A['cid']);\n $retval .= COM_createLink($content, $url) . '<br/>';\n }\n }\n }\n\n return $retval;\n}", "title": "" }, { "docid": "475e6fc2edfa56723777aee0215da0f8", "score": "0.52299523", "text": "public function getEventCategories() {\n $iCategory = $this->_oApi->get('category_id', null);\n if ($iCategory == 0) {\n $iCategory = null;\n }\n\n $aCategories = Phpfox::getService('event.category')->getForBrowse($iCategory);\n\n if(is_array($aCategories)) {\n foreach($aCategories as $iKey => $aCategory) {\n $aCategories[$iKey]['name'] = Phpfox::getLib('locale')->convert($aCategory['name']);\n }\n return $aCategories;\n }\n\n return array();\n }", "title": "" }, { "docid": "be359662f5b41501368a01413f384fda", "score": "0.52285594", "text": "public function add_event($id='',$msg='',$msg_class='',$user_id='')\n{\n\t$this->error_validation_session_check();//IF User is Not Login then anyone not entire any function\n\tif(!empty($msg))\n\t{\n\t\t$msgsection['id'] = $id;\n\t\t$msgsection['msg'] = $msg;\n\t\t$msgsection['msgclass'] = $msg_class;\n\t}\n\t$msgsection['category'] = $this->urs->getFullUserDetails(CATEGORY,'event','category_type');\n\t$msgsection['country'] = $this->urs->getCountryDetails(COUNTRY,'country_id');\n\t$msgsection['timezone'] = $this->urs->getFieldDetails(TIMEZONE);\n\t$msgsection['all_meetup'] = $this->get_meet_up_data();\n\t$this->load->view('dashboard/add-events-form',$msgsection);\n}", "title": "" }, { "docid": "0e32b87e0b6940f3f5629468d5bd6e4d", "score": "0.5221322", "text": "public function getMessageContainer();", "title": "" }, { "docid": "2ee1ab1b7130508f519149d7fbe8d347", "score": "0.52093595", "text": "function changeMessagesStatus()\n {\n }", "title": "" }, { "docid": "ee24b2a3b61e9961b24067104edf5cda", "score": "0.5203378", "text": "public function getMessages();", "title": "" }, { "docid": "ee24b2a3b61e9961b24067104edf5cda", "score": "0.5203378", "text": "public function getMessages();", "title": "" }, { "docid": "ee24b2a3b61e9961b24067104edf5cda", "score": "0.5203378", "text": "public function getMessages();", "title": "" }, { "docid": "ee24b2a3b61e9961b24067104edf5cda", "score": "0.5203378", "text": "public function getMessages();", "title": "" }, { "docid": "9ad7b5e259d4a740610c814823a06344", "score": "0.5200044", "text": "function categoryNotice()\n {\n \t //Configure::write('debug', 2);\n\t $users= $this->Session->read('infoAdminLogin');\n\t\n\t if($users)\n\t {\n\t \t\tController::loadModel('Option');\n\t\t $this->setup();\n\t\n\t\t $chuyenmuc= $this->Option->getOption('categoryNotice');\n\t\n\t\t $this->set('group', $chuyenmuc['Option']['value']['category']);\n\t\n\t }\n\t else \n {\n\t \t$urlLocal= $this->getUrlLocal();\n\t\t $this->redirect($urlLocal['urlAdmins'].'login');\n }\n }", "title": "" }, { "docid": "7a0eca2de78a70a7d43f233aec7819b3", "score": "0.51904076", "text": "function __c($msg, $category, $args = null) {\n\t\tif (!$msg) {\n\t\t\treturn;\n\t\t}\n\t\tApp::uses('I18n', 'I18n');\n\t\t$translated = I18n::translate($msg, null, null, $category);\n\t\tif ($args === null && func_num_args() < 4) {\n\t\t\treturn $translated;\n\t\t} elseif (!is_array($args)) {\n\t\t\t$args = array_slice(func_get_args(), 2);\n\t\t}\n\n\t\t$translated = preg_replace('/(?<!%)%(?![%\\'\\-+bcdeEfFgGosuxX\\d\\.])/', '%%', $translated);\n\t\treturn vsprintf($translated, $args);\n\t}", "title": "" }, { "docid": "9260fa2842e8b20a82453182d88c925d", "score": "0.51899844", "text": "protected function overloadMessages()\n {\n }", "title": "" }, { "docid": "6cb8b753890cef2a3a4d1ebd5716c1bc", "score": "0.5180518", "text": "public function messages($name=null);", "title": "" }, { "docid": "ca366d34d541cc1c4c2f865996917d4e", "score": "0.51636404", "text": "function sendMessage(){\n\t\t\tprint_r($GLOBALS['globalLecture']);\n\t\t\tprint_r($GLOBALS['globalEventEndTime']);\n\n\t\t\t//Set date of delivery for notification to end time of lecture\n\t\t\t$date = $GLOBALS['globalEventEndTime'];\n\t\t\t//TODO: Set to current date/time for developments purposes\n\t\t\t// $scheduledDelivery = $date;\n\t\t\t$scheduledDelivery = date();\n\n\t\t\t//Set category for use of action buttons connected to said category\n\t $category = 'KurtLecture';\n\n\t\t\t//Set title of notification\n\t $title = array(\n\t \"en\" => 'Behandlades målen adekvat?'\n\t );\n\n\t\t\t//Set subtitle of notification to name of lecture\n\t $lecture = $GLOBALS['globalLecture'];\n\t $subtitle = array(\n\t \"en\" => $lecture\n\t );\n\n\t\t\t//Set content of notification to course goals set by lecturer\n\t $courseGoals = '\n\t • Förstå hjärtats funktion\n\t • Redogöra för hjärtats anatomi\n\t • Dricka kaffe\n\t • Äta macka\n\t • Somna\n\t • Kolla Facebook';\n\n\t $content = array(\n\t \"en\" => 'Följande kursmål ska ha tagits upp:' . $courseGoals\n\t );\n\n\t\t\t//Makes sure notifications are only sent to users who have chosen the same course as set when scheduling notifications\n\t\t\t$courseID = $_GET['courseID'];\n\t\t\t$filters = array(\n\t\t\t\t\"field\" => \"tag\",\n\t\t\t\t\"key\" => 'courseID',\n\t\t\t\t\"relation\" => '=',\n\t\t\t\t\"value\" => $courseID\n\t\t\t);\n\n\t\t\t//Array to be sent to OneSingal\n\t\t\t$fields = array(\n\t\t\t\t'app_id' => \"88aaa3f2-e759-4311-b1fd-d706b1d18335\",\n\t\t\t\t'included_segments' => array('All'),\n\t\t\t\t'filters' => array($filters),\n\t 'send_after' => $scheduledDelivery,\n\t\t\t\t'content_available' => true,\n\t //'template_id' => '576a00f4-2d3b-4441-a9fb-3e4dcea9f962'\n\t 'ios_category' => $category,\n\t 'ios_badgeType' => 'None',\n\t 'headings' => $title,\n\t 'subtitle' => $subtitle,\n\t 'contents' => $content\n\t\t\t);\n\n\t\t\t//Send notification request to OneSignal\n\t\t\t$fields = json_encode($fields);\n\t print(\"\\nJSON sent:\\n\");\n\t print($fields);\n\n\t\t\t$ch = curl_init();\n\t\t\tcurl_setopt($ch, CURLOPT_URL, \"https://onesignal.com/api/v1/notifications\");\n\t\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json; charset=utf-8',\n\t\t\t\t\t\t\t\t\t\t\t\t\t 'Authorization: Basic OTViNGEyM2ItNWRkMC00MmMzLTk2OWMtNzFmZjc1ODgwYmY5')); //Set to App-key from OneSignal\n\t\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);\n\t\t\tcurl_setopt($ch, CURLOPT_HEADER, FALSE);\n\t\t\tcurl_setopt($ch, CURLOPT_POST, TRUE);\n\t\t\tcurl_setopt($ch, CURLOPT_POSTFIELDS, $fields);\n\t\t\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);\n\n\t\t\t$response = curl_exec($ch);\n\t\t\tcurl_close($ch);\n\n\t\t\treturn $response;\n\n\t\t}", "title": "" }, { "docid": "eb0dac3ace4097ef0c9cb12a2f8d0a97", "score": "0.5159866", "text": "protected static function includeMessages()\r\n\t{\r\n\t}", "title": "" }, { "docid": "64850b10e58bc03da1807140ae5f7f7d", "score": "0.51301867", "text": "public static function SYS_MSG() \r\n { \r\n return new EventType(7); \r\n }", "title": "" }, { "docid": "971bee631b802212df2bab1ba809e10b", "score": "0.5122027", "text": "function category_deleted_handler($eventdata){\n\t\tglobal $CFG;\n\t\t$isinteresting = false; //we assume that this is not relevant - check!\n\t\t//if there is no class with an instance of mumiemodule in the parent category, then we can be sure that this event is not interesting\n\t\t//but if there is at least one, we can not be sure - so we better try to send all information\n\t\tif($cat_classes = get_courses($semester->parent, 'c.id')){\n\t\t\tforeach($cat_classes as $cat_class){\n\t\t\t\tif(record_exists('mumiemodule', 'course', $cat_class->id)){\n\t\t\t\t\t$isinteresting = true;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t if($isinteresting){\n\t\t\tevent_logoutput(\"category_deleted_handler called \\n\", $eventdata);\n\t\t\t$js = new JapsSynchronise();\n\t\t\t$deletedsem = new object();\n\t\t\t$deletedsem->syncid = 'moodle-'.$CFG->prefix.'course_categories-'.$eventdata->id;\n\t\t\t$deletedsem->parent = 'moodle-'.$CFG->prefix.'course_categories-'.$eventdata->parent;\n\t\t\t\n\t\t\t//we try to insert the parent-category as a new semester into MUMIE\n\t\t\t$cat = get_record('course_categories', 'id', $eventdata->parent, '', '', '', '', 'name');\n\t\t\t$newsemester = new object();\n\t\t\t$newsemester->syncid = $deletedsem->parent;\n\t\t\t$newsemester->name = $cat->name;\n\t\t\t$newsemester->description = 'a Moodle-category as semester';\n\t\t\tinsert_semester_for_mumie($newsemester, $js);\n\t\t\t\n\t\t\t//the courses were moved from the deleted category into the parent category\n\t\t\t//so we have to change them before deleting the category\n\t\t\tif($cat_classes = get_courses($semester->parent, $fields='c.id')){ //TODO: isn't this deprecated???\n\t\t\t \tforeach($cat_classes as $cat_class){\n\t\t\t \t\tif(record_exists('mumiemodule', 'course', $cat_class->id)){\n\t\t\t \t\t\t$classtochange = new object();\n\t\t\t \t\t\t$classtochange->syncid = 'moodle-'.$CFG->prefix.'course-'.$cat_class->id;;\n\t\t\t \t\t\t$classtochange->semester = $deletedsem->parent;\n\t\t\t \t\t\tchange_class_for_mumie($classtochange, $js);\n\t\t\t \t\t}\n\t\t \t\t}\n\t\t \t}\n\t\t\t\n\t\t\t//delete_semester_for_mumie($deletedsem);\n\t }\n\t\treturn true;\n\t}", "title": "" }, { "docid": "9ecf9627029dd0912934ce3bafa4e547", "score": "0.5112509", "text": "public function categoriesAction() {\n\n // VALIDATE REQUEST METHOD\n $this->validateRequestMethod();\n\n //GET VIEWER\n $viewer = Engine_Api::_()->user()->getViewer();\n $viewer_id = $viewer->getIdentity();\n\n\n // PREPARE RESPONSE\n $values = $response = array();\n $category_id = $this->getRequestParam('category_id', null);\n $subCategory_id = $this->getRequestParam('subCategory_id', null);\n $subsubcategory_id = $this->getRequestParam('subsubcategory_id', null);\n $showAllCategories = $this->getRequestParam('showAllCategories', 1);\n $showCategories = $this->getRequestParam('showCategories', 1);\n $showEvents = $this->getRequestParam('showEvents', 1);\n\n if ($this->getRequestParam('showCount')) {\n $showCount = 1;\n } else {\n $showCount = $this->getRequestParam('showCount', 0);\n }\n $orderBy = $this->getRequestParam('orderBy', 'category_name');\n\n $tableCategory = Engine_Api::_()->getDbtable('categories', 'siteevent');\n Engine_Api::_()->getApi('Core', 'siteapi')->setView();\n\n $categories = array();\n\n //GET EVENT TABLE\n $tableSiteevent = Engine_Api::_()->getDbtable('events', 'siteevent');\n $siteeventShowAllCategories = Engine_Api::_()->getApi('settings', 'core')->getSetting('siteeventshow.allcategories', 1);\n $showAllCategories = !empty($siteeventShowAllCategories) ? $showAllCategories : 0;\n\n if ($showCategories) {\n\n if ($showAllCategories) {\n\n $category_info = $tableCategory->getCategories(array('category_id', 'category_name', 'cat_order', 'photo_id'), null, 0, 0, 1, 0, $orderBy, 1);\n $categoriesCount = count($category_info);\n foreach ($category_info as $value) {\n\n $sub_cat_array = array();\n\n if ($showCount) {\n $categories[] = $category_array = array('category_id' => $value->category_id,\n 'category_name' => $this->translate($value->category_name),\n 'order' => $value->cat_order,\n 'count' => $tableSiteevent->getEventsCount($value->category_id, 'category_id', 1),\n 'images' => Engine_Api::_()->getApi('Core', 'siteapi')->getContentImage($value),\n );\n } else {\n $categories[] = $category_array = array('category_id' => $value->category_id,\n 'category_name' => $this->translate($value->category_name),\n 'order' => $value->cat_order,\n 'images' => Engine_Api::_()->getApi('Core', 'siteapi')->getContentImage($value),\n );\n }\n }\n } else {\n $category_info = $tableCategory->getCategorieshasevents(0, 'category_id', null, array(), array('category_id', 'category_name', 'cat_order', 'photo_id'));\n $categoriesCount = count($category_info);\n foreach ($category_info as $value) {\n if ($showCount) {\n $categories[] = $category_array = array('category_id' => $value->category_id,\n 'category_name' => $value->category_name,\n 'order' => $value->cat_order,\n 'count' => $tableSiteevent->getEventsCount($value->category_id, 'category_id', 1),\n 'images' => Engine_Api::_()->getApi('Core', 'siteapi')->getContentImage($value),\n );\n } else {\n $categories[] = $category_array = array('category_id' => $value->category_id,\n 'category_name' => $this->translate($value->category_name),\n 'order' => $value->cat_order,\n 'images' => Engine_Api::_()->getApi('Core', 'siteapi')->getContentImage($value),\n );\n }\n }\n }\n\n $response['categories'] = $categories;\n\n if (!empty($category_id)) {\n\n if ($showAllCategories) {\n $category_info2 = $tableCategory->getSubcategories($category_id, array('category_id', 'category_name', 'cat_order', 'photo_id'));\n\n foreach ($category_info2 as $subresults) {\n if ($showCount) {\n $sub_cat_array[] = $tmp_array = array('sub_cat_id' => $subresults->category_id,\n 'sub_cat_name' => $this->translate($subresults->category_name),\n 'count' => $tableSiteevent->getEventsCount($subresults->category_id, 'subcategory_id', 1),\n 'order' => $subresults->cat_order);\n } else {\n $sub_cat_array[] = $tmp_array = array('sub_cat_id' => $subresults->category_id,\n 'sub_cat_name' => $this->translate($subresults->category_name),\n 'order' => $subresults->cat_order);\n }\n }\n } else {\n $category_info2 = $tableCategory->getCategorieshasevents($category_id, 'subcategory_id', null, array(), array('category_id', 'category_name', 'cat_order', 'photo_id'));\n foreach ($category_info2 as $subresults) {\n if ($showCount) {\n $sub_cat_array[] = $tmp_array = array('sub_cat_id' => $subresults->category_id,\n 'sub_cat_name' => $this->translate($subresults->category_name),\n 'count' => $tableSiteevent->getEventsCount($subresults->category_id, 'subcategory_id', 1),\n 'order' => $subresults->cat_order);\n } else {\n $sub_cat_array[] = $tmp_array = array('sub_cat_id' => $subresults->category_id,\n 'sub_cat_name' => $this->translate($subresults->category_name),\n 'order' => $subresults->cat_order);\n }\n }\n }\n\n $response['subCategories'] = $sub_cat_array;\n }\n\n if (!empty($subCategory_id)) {\n if ($showAllCategories) {\n $subcategory_info2 = $tableCategory->getSubcategories($subCategory_id, array('category_id', 'category_name', 'cat_order', 'photo_id'));\n $treesubarrays = array();\n foreach ($subcategory_info2 as $subvalues) {\n if ($showCount) {\n $treesubarrays[] = $treesubarray = array('tree_sub_cat_id' => $subvalues->category_id,\n 'tree_sub_cat_name' => $this->translate($subvalues->category_name),\n 'count' => $tableSiteevent->getEventsCount($subvalues->category_id, 'subsubcategory_id', 1),\n 'order' => $subvalues->cat_order,\n );\n } else {\n $treesubarrays[] = $treesubarray = array('tree_sub_cat_id' => $subvalues->category_id,\n 'tree_sub_cat_name' => $this->translate($subvalues->category_name),\n 'order' => $subvalues->cat_order,\n );\n }\n }\n } else {\n $subcategory_info2 = $tableCategory->getCategorieshasevents($subCategory_id, 'subsubcategory_id', null, array(), array('category_id', 'category_name', 'cat_order', 'photo_id'));\n $treesubarrays = array();\n foreach ($subcategory_info2 as $subvalues) {\n if ($showCount) {\n $treesubarrays[] = $treesubarray = array('tree_sub_cat_id' => $subvalues->category_id,\n 'tree_sub_cat_name' => $this->translate($subvalues->category_name),\n 'order' => $subvalues->cat_order,\n 'count' => $tableSiteevent->getEventsCount($subvalues->category_id, 'subsubcategory_id', 1),\n );\n } else {\n $treesubarrays[] = $treesubarray = array('tree_sub_cat_id' => $subvalues->category_id,\n 'tree_sub_cat_name' => $this->translate($subvalues->category_name),\n 'order' => $subvalues->cat_order\n );\n }\n }\n }\n $response['subsubCategories'] = $treesubarrays;\n }\n }\n\n if ($showEvents && isset($category_id) && !empty($category_id)) {\n $params = array();\n $itemCount = $params['itemCount'] = $this->_getParam('itemCount', 0);\n $params['showEventType'] = $this->getRequestParam('showEventType', 'upcoming');\n $params['popularity'] = $popularity = $this->getRequestParam('popularity', 'view_count');\n $params['interval'] = $interval = $this->getRequestParam('interval', 'overall');\n $params['limit'] = $totalPages = $this->getRequestParam('eventCount', 5);\n $params['truncation'] = $this->getRequestParam('truncation', 25);\n\n// $this->view->detactLocation = $params['detactLocation'] = $this->_getParam('detactLocation', 0);\n// if ($this->view->detactLocation) {\n// $this->view->detactLocation = Engine_Api::_()->siteevent()->enableLocation();\n// }\n// if ($this->view->detactLocation) {\n// $params['defaultLocationDistance'] = $this->_getParam('defaultLocationDistance', 1000);\n// $params['latitude'] = $this->_getParam('latitude', 0);\n// $params['longitude'] = $this->_getParam('longitude', 0);\n// }\n //GET CATEGORIES\n $categories = array();\n $category_info = Engine_Api::_()->getDbtable('categories', 'siteevent')->getCategorieshasevents($category_id, 'category_id', $itemCount, $params, array('category_id', 'category_name', 'cat_order'));\n $category_events_array = array();\n\n $params['category_id'] = $category_id;\n $params['subcategory_id'] = $subCategory_id;\n $params['subsubcategory_id'] = $subsubcategory_id;\n //GET PAGE RESULTS\n $category_events_info = $category_events_info = Engine_Api::_()->getDbtable('events', 'siteevent')->eventsBySettings($params);\n foreach ($category_events_info as $result_info) {\n // continue if Deleted member\n if (empty($result_info->host_id))\n continue;\n $occurrence_id = Engine_Api::_()->getDbTable('events', 'siteevent')->getNextOccurID($result_info->getIdentity());\n\n //GET DATES OF EVENT\n $tz = Engine_Api::_()->getApi('settings', 'core')->core_locale_timezone;\n if (!empty($viewer_id)) {\n $tz = $viewer->timezone;\n }\n $occurrenceTable = Engine_Api::_()->getDbTable('occurrences', 'siteevent');\n $dates = $occurrenceTable->getEventDate($result_info->getIdentity(), $occurrence_id);\n\n if (isset($dates['starttime']) && !empty($dates['starttime']) && isset($tz)) {\n $startDateObject = new Zend_Date(strtotime($dates['starttime']));\n $startDateObject->setTimezone($tz);\n $eventdateinfo['starttime'] = $startDateObject->get('YYYY-MM-dd HH:mm:ss');\n }\n if (isset($dates['endtime']) && !empty($dates['endtime']) && isset($tz)) {\n $endDateObject = new Zend_Date(strtotime($dates['endtime']));\n $endDateObject->setTimezone($tz);\n $eventdateinfo['endtime'] = $endDateObject->get('YYYY-MM-dd HH:mm:ss');\n }\n\n $totalEventOccurrences = Engine_Api::_()->getDbtable('occurrences', 'siteevent')->getOccurrenceCount($result_info->event_id);\n if (!empty($result_info->repeat_params) && $totalEventOccurrences > 1) {\n $hasMultipleDates = 1;\n } else {\n $hasMultipleDates = 0;\n }\n\n\n $tmp_array = array('event_id' => $result_info->event_id,\n 'imageSrc' => Engine_Api::_()->getApi('Core', 'siteapi')->getContentImage($result_info),\n 'event_title' => $result_info->title,\n 'owner_id' => $result_info->owner_id,\n 'popularityCount' => $result_info->$popularity,\n 'slug' => $result_info->getSlug(),\n 'starttime' => $eventdateinfo['starttime'],\n 'endtime' => $eventdateinfo['endtime'],\n 'hasMultipleDates' => $hasMultipleDates\n );\n\n if (Engine_Api::_()->getApi('settings', 'core')->getSetting('siteevent.location', 1) && !$result_info->is_online) {\n\n //GET LOCATION\n $locationParams['id'] = $result_info->event_id;\n\n $location = Engine_Api::_()->getDbtable('locations', 'siteevent')->getLocation($locationParams);\n if (isset($location) && isset($location->location))\n $tmp_array['location'] = $location->location;\n }\n\n $host = $result_info->getHost();\n if (isset($host) && !empty($host)) {\n $host_icons = Engine_Api::_()->getApi('Core', 'siteapi')->getContentImage($host);\n $organizer['host_type'] = $host->getType();\n $organizer['host_id'] = $host->getIdentity();\n $organizer['host_title'] = $host->getTitle();\n $organizer['image_icon'] = $host_icons;\n\n $userEvents = Engine_Api::_()->getDbTable('events', 'siteevent')->userEvent($host);\n $organizer['event_hosted'] = count($userEvents);\n $tmp_array['host'] = $organizer;\n }\n $category_events_array[] = $tmp_array;\n }\n\n $response['events'] = $category_events_array;\n }\n if (isset($categoriesCount) && !empty($categoriesCount))\n $response['totalItemCount'] = $categoriesCount;\n $response['canCreate'] = Engine_Api::_()->authorization()->isAllowed('siteevent_event', $viewer, 'create');\n $response['packagesEnabled'] = $this->_packagesEnabled();\n\n $this->respondWithSuccess($response, true);\n }", "title": "" }, { "docid": "3c7991543bd18a707aa6b192cb059396", "score": "0.5109635", "text": "function gettext_dc ($domain, $message, $category)\n{\n return dcgettext($domain, $message, $category);\n}", "title": "" }, { "docid": "d1c69a5c54d131e7a69b6a0fe1e5efaa", "score": "0.51095414", "text": "function dbem_get_events_list($limit = \"3\", $scope = \"future\", $order = \"ASC\", $format = '', $echo = 1, $category = '') {\r\n\tif (strpos ( $limit, \"=\" )) {\r\n\t\t// allows the use of arguments without breaking the legacy code\r\n\t\t$defaults = array ('limit' => 3, 'scope' => 'future', 'order' => 'ASC', 'format' => '', 'echo' => 1 , 'category' => '');\r\n\t\t\r\n\t\t$r = wp_parse_args ( $limit, $defaults );\r\n\t\textract ( $r, EXTR_SKIP );\r\n\t\t$limit = $r ['limit'];\r\n\t\t$scope = $r ['scope'];\r\n\t\t$order = $r ['order'];\r\n\t\t$format = $r ['format'];\r\n\t\t$echo = $r ['echo'];\r\n\t\t$category = ( preg_match('/^([0-9],?)+$/', $r ['category'] ) ) ? $r ['category'] : '' ;\r\n\t}\r\n\tif ($scope == \"\")\r\n\t\t$scope = \"future\";\r\n\tif ($order != \"DESC\")\r\n\t\t$order = \"ASC\";\r\n\tif ($format == ''){\r\n\t\t$orig_format = true;\r\n\t\t$format = get_option ( 'dbem_event_list_item_format' );\r\n\t}\r\n\t$events = dbem_get_events ( $limit, $scope, $order, '', '', $category );\r\n\t$output = \"\";\r\n\tif (! empty ( $events )) {\r\n\t\tforeach ( $events as $event ) {\r\n\t\t\t// $localised_date = mysql2date(\"j M Y\", $event->event_time);\r\n\t\t\t$output .= dbem_replace_placeholders ( $format, $event );\r\n\t\t}\r\n\t\t//Add headers and footers to output\r\n\t\tif( $orig_format ){\r\n\t\t\t$single_event_format_header = get_option ( 'dbem_event_list_item_format_header' );\r\n\t\t\t$single_event_format_header = ( $single_event_format_header != '' ) ? $single_event_format_header : \"<ul class='dbem_events_list'>\";\r\n\t\t\t$single_event_format_footer = get_option ( 'dbem_event_list_item_format_footer' );\r\n\t\t\t$single_event_format_footer = ( $single_event_format_footer != '' ) ? $single_event_format_footer : \"</ul>\";\r\n\t\t\t$output = $single_event_format_header . $output . $single_event_format_footer;\r\n\t\t}\r\n\t} else {\r\n\t\t$output = \"<li class='dbem-no-events'>\" . get_option ( 'dbem_no_events_message' ) . \"</li>\";\r\n\t}\r\n\tif ($echo)\r\n\t\techo $output;\r\n\telse\r\n\t\treturn $output;\r\n}", "title": "" }, { "docid": "5912936a95563fc1e0d69541517c9cec", "score": "0.51040334", "text": "function getAllthreadMessages()\n {\n }", "title": "" }, { "docid": "cefbe4efb944735f0fbe8a0e88e087a4", "score": "0.50960076", "text": "public function get_cat()\n\t{\n\t\t$app = JFactory::getApplication();\n\n\t\t// Getting log_user\n\t\t$log_user = $this->plugin->get('user')->id;\n\t\t$cat = FD::model('eventcategories');\n\n\t\t// Response object\n\t\t$res = new stdclass;\n\t\t$res->result = array();\n\t\t$res->empty_message = '';\n\n\t\t$res->result = $cat->getCategories();\n\t\t$this->plugin->setResponse($res);\n\t}", "title": "" }, { "docid": "f6ba9c7339d956ae8be82bb6d93bb7a0", "score": "0.5089649", "text": "public function message()\n {\n return 'Las categorías deben ser diferentes';\n }", "title": "" }, { "docid": "8472ba83adddc57045d9225f9784d63f", "score": "0.5088031", "text": "function show_and_log_message($serverconnection, $courseid, $message, $tags, $logaction, $showdialog) {\n global $USER;\n echo '<div class=\"' . ($showdialog ? 'export-results' : '') . ' ' .$tags.'\">'.$message.'</div>';\n add_publishing_log($serverconnection->url, $USER->id, $courseid, $logaction, ($tags ? $tags.':' : '').$message);\n}", "title": "" }, { "docid": "2d0a226814559b6fa365927abd28f2c4", "score": "0.5068972", "text": "protected function loadMessagesFromDb($category, $language)\r\n\t{\n\t\t$db = $this->getDbConnection();\r\n\t\t$cmd = $db->createCommand()\n\t\t->select(array('smt.message AS message', 'tmt.translation AS translation'))\n\t\t->from($this->sourceMessageTable.' smt')\n\t\t->join($this->languageTable.' slt', $db->quoteColumnName('slt.code').'=:source_language')\n\t\t->join($this->categoryMessageTable.' cmt', $db->quoteColumnName('smt.id').'='.$db->quoteColumnName('cmt.message_id'))\n\t\t->join($this->categoryTable.' ct', array('and', $db->quoteColumnName('cmt.category_id').'='.$db->quoteColumnName('ct.id'), $db->quoteColumnName('ct.category').'=:category'))\n\t\t->join($this->languageTable.' lt', $db->quoteColumnName('lt.code').'=:language')\n\t\t->join($this->translatedMessageTable.' tmt', array('and', $db->quoteColumnName('smt.id').'='.$db->quoteColumnName('tmt.id'), $db->quoteColumnName('tmt.language_id').'='.$db->quoteColumnName('lt.id')));\n\r\n\t\t$messages = array();\r\n\t\tforeach($cmd->queryAll(true, array(':source_language' => $this->getLanguage($category), ':category' => $category, ':language' => $language)) as $row)\n\t\t{\r\n\t\t\t$messages[$row['message']] = $row['translation'];\n\t\t}\r\n\r\n\t\treturn $messages;\r\n\t}", "title": "" }, { "docid": "061ade2c2dedc95fafab28df86d50a7d", "score": "0.50680196", "text": "public function message()\n {\n return 'This event clashes with another event. Please book at a different time';\n }", "title": "" }, { "docid": "688b26068c24885ea43deaa56cf4cfa9", "score": "0.5063894", "text": "function __getCPChatMessages()\r\n\t{\r\n\t\t//---------------------------------------\r\n\t\t//\tInit\r\n\t\t//---------------------------------------\r\n\t\r\n\t\t$messages\t\t= array();\r\n\t\t$this->pearRegistry->db->query(\"SELECT c.*, u.member_name FROM pear_admin_chat c, pear_members u WHERE c.member_id = u.member_id ORDER BY c.message_id DESC\");\r\n\t\r\n\t\t//---------------------------------------\r\n\t\t//\tBuild...\r\n\t\t//---------------------------------------\r\n\t\twhile( ($message = $this->pearRegistry->db->fetchRow()) !== FALSE )\r\n\t\t{\r\n\t\t\t//---------------------------------------\r\n\t\t\t//\tFormat data\r\n\t\t\t//---------------------------------------\r\n\t\r\n\t\t\t$message['message_added_time']\t\t=\t$this->pearRegistry->getDate($message['message_added_time']);\r\n\t\r\n\t\t\t//---------------------------------------\r\n\t\t\t//\tFilter the post content\r\n\t\t\t//---------------------------------------\r\n\t\r\n\t\t\t$messages[] = $message;\r\n\t\t}\r\n\t\r\n\t\treturn $messages;\r\n\t}", "title": "" }, { "docid": "75d6981acb6bd52b621ba592d0e48cfe", "score": "0.5057623", "text": "function do_add_category($db,$title,$description,$cat,$day,$month,$year,$contact,$email,$url,$start_time_hour,$start_time_minute,$start_time_ampm,$end_days,$end_hours,$end_minutes)\n{\nglobal $bluebdr, $action,$SID;\n\n//----------------------------------------------------------------------------------------\n// setup variables\n//----------------------------------------------------------------------------------------\n\n\t$ti = addslashes(trim($title));\n\t$de = addslashes(trim($description));\n\t$ca = addslashes(trim($cat));\n\t$da = addslashes(trim($day));\n\t$mo = addslashes(trim($month));\n\t$ye = addslashes(trim($year));\n\t$co = addslashes(trim($contact));\n\t$el = addslashes(trim($email));\n\t$ur = addslashes(trim($url));\n\t$sh = addslashes(trim($start_time_hour));\n\t$sm = addslashes(trim($start_time_minute));\n\t$sa = addslashes(trim($start_time_ampm));\n\t$ed = addslashes(trim($end_days));\n\t$eh = addslashes(trim($end_hours));\n\t$em = addslashes(trim($end_minutes));\n\n\t$start_time_hour = extcal_12to24hour($sh, $sa);\n\t$start_date = date(\"Y-m-d H:i:s\", mktime($start_time_hour, $sm, 0, $mo, $da, $ye));\n\n\tif($ed > 0 && !$eh && !$em) {\n\t\t$ed--; // to make sure not to jump to the next day, we push the time to 23:59:59\n\t\t$total_hours = 23;\n\t\t$total_minutes = 59;\n\t\t$total_seconds = 59;\n\t} else {\n\t\t$total_hours = $start_time_hour + $eh;\n\t\t$total_minutes = $sm + $em;\n\t\t$total_seconds = 0;\n\t}\n\t$end_date = date(\"Y-m-d H:i:s\", mktime( $total_hours, $total_minutes, $total_seconds, $mo, $da + $ed, $ye));\n\n\n//----------------------------------------------------------------------------------------\n// insert into database\n//----------------------------------------------------------------------------------------\n\n\t$db->Insert(\"INSERT INTO extcal_events (title,description,cat,day,month,year,start_date,end_date,contact,email,url,approved) VALUES ('$ti','$de','$ca','$da','$mo','$ye','$start_date','$end_date','$co','$el','$ur',1)\");\n\n\tif ($db->a_rows != -1) {\n\t echo \"<p>You have now added a new event.</p>\\n\";\n\t echo \"<p>&raquo; <a href=\\\"main.php?SID=$SID&action=$action&do=sadd\\\">add another event</a></p>\\n\";\n\t echo \"<p>&laquo; <a href=\\\"main.php?SID=$SID&action=$action\\\">return to event list</a></p>\\n\";\n\t} else {\n\t echo \"<p>The event could not be added to the database at this time.</p>\\n\";\n\t echo \"<p>&laquo; <a href=\\\"main.php?SID=$SID&action=$action\\\">return to event list</a></p>\\n\";\n\t}\n}", "title": "" }, { "docid": "cf8edbedd614e0fe0fe2240bace5508a", "score": "0.50568265", "text": "function BH_get_event_categories_menu( $category_type, $current_object_id, $show_events ) {\r\n\r\n\t/**\r\n\t * Variables\r\n\t */\r\n\t$output\t= '';\r\n\r\n\t//Get event categories\r\n\t$args\t= array(\r\n\t\t'taxonomy'\t=> 'event_category',\r\n\t\t'orderby'\t=> 'term_order'\r\n\t);\r\n\r\n\tif ( $category_type ) {\r\n\r\n\t\t$args[ 'meta_query' ] = array(\r\n\t\t\tarray(\r\n\t\t\t\t'key'\t\t=> 'acf-event_category_type',\r\n\t\t\t\t'value'\t\t=> $category_type,\r\n\t\t\t\t'compare'\t=> '='\r\n\t\t\t)\r\n\t\t);\r\n\r\n\t}\r\n\t$categories = get_terms( $args );\r\n\r\n\tif ( $categories ) {\r\n\r\n\t\tforeach ( $categories as $cat ) {\r\n\r\n\t\t\t$category_classes = array( 'menu-item', 'menu-item-type-taxonomy', 'menu-item-object-event_category', 'menu-item-999' . $cat->term_id );\r\n\r\n\t\t\tif ( $cat->term_id == $current_object_id ) {\r\n\t\t\t\t$category_classes[] = 'current-menu-item';\r\n\t\t\t\t$category_classes[] = 'current_page_item';\r\n\t\t\t}\r\n\t\t\telseif ( is_singular( 'event' ) && has_term( $cat->term_id, 'event_category' ) ) {\r\n\t\t\t\t$category_classes[]\t= 'current-menu-ancestor';\r\n\t\t\t\t$category_classes[]\t= 'current-menu-parent';\r\n\t\t\t}\r\n\r\n\t\t\t// Get current and future events\r\n\t\t\t$events = BH_get_event_category_events( $cat->term_id );\r\n\r\n\t\t\tif ( $events ) {\r\n\r\n\t\t\t\tif ( $show_events ) {\r\n\r\n\t\t\t\t\t$events_list\t\t= '';\t\t// Events LIs\r\n\t\t\t\t\t$current_category\t= false;\t// Indicates whether the current category is a parent menu item\r\n\t\t\t\t\t$category_classes[]\t= 'menu-item-has-children';\r\n\r\n\t\t\t\t\tforeach ( $events as $event ) {\r\n\r\n\t\t\t\t\t\t$event_classes = array( 'menu-item', 'menu-item-type-post_type', 'menu-item-object-event', 'menu-item-999' . $event->ID );\r\n\r\n\t\t\t\t\t\tif ( $event->ID == $current_object_id ) {\r\n\r\n\t\t\t\t\t\t\t$event_classes[]\t= 'current-menu-item';\r\n\t\t\t\t\t\t\t$event_classes[]\t= 'current_page_item';\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tif ( ! in_array( 'current-menu-ancestor', $category_classes ) ) {\r\n\r\n\t\t\t\t\t\t\t\t$category_classes[]\t= 'current-menu-ancestor';\r\n\t\t\t\t\t\t\t\t$category_classes[]\t= 'current-menu-parent';\r\n\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t$events_list .=\r\n\t\t\t\t\t\t\t'<li class=\"' . implode( ' ', $event_classes ) . '\">\r\n\t\t\t\t\t\t\t\t<a href=\"' . get_permalink( $event->ID ) . '\" item=\"999' . $event->ID . '\">' . $event->post_title . '</a>\r\n\t\t\t\t\t\t\t</li>';\r\n\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$output .=\r\n\t\t\t\t\t'<li class=\"' . implode( ' ', $category_classes ) . '\">\r\n\t\t\t\t\t\t<a href=\"' . get_term_link( $cat ) . '\" item=\"999' . $cat->term_id . '\">' . $cat->name . '</a>' .\r\n\t\t\t\t\t\t( ( $show_events && $events_list ) ? '<ul class=\"sub-menu\">' . $events_list . '</ul>' : '' ) .\r\n\t\t\t\t\t'</li>';\r\n\r\n\t\t\t}\r\n\r\n\t\t}\r\n\r\n\t}\r\n\r\n\t// return\r\n\treturn $output;\r\n\r\n}", "title": "" }, { "docid": "c5fac216e59bdde1b00a841e5d4879a4", "score": "0.50385725", "text": "function get_subject() {\n return t('Notifications event');\n }", "title": "" }, { "docid": "52631ff4d07c9ee89810c775414bdf03", "score": "0.50335693", "text": "function t($message, $category = 'main', $params = array(), $source = null, $language = null)\n{\n return Yii::t($category, $message, $params, $source, $language);\n}", "title": "" }, { "docid": "e00ce7667a88e2cdb1e6f31a7b1e528e", "score": "0.5024731", "text": "public function getMessages(){ }", "title": "" }, { "docid": "bd41c754df213a8211ed431176b849e9", "score": "0.50163966", "text": "abstract protected function getLogMessage();", "title": "" }, { "docid": "03729ef62a392e0358a65490548c8161", "score": "0.5011512", "text": "public function process()\n\t{\t\t\n\t\tPhpfox::getUserParam('event.can_access_event', true);\n\t\t\n\t\t$aParentModule = $this->getParam('aParentModule');\t\t\n\t\t\n\t\tif ($aParentModule === null && $this->request()->getInt('req2') > 0)\n\t\t{\n\t\t\treturn Phpfox::getLib('module')->setController('event.view');\n\t\t}\t\t\n\t\t\n\t\tif (($sLegacyTitle = $this->request()->get('req2')) && !empty($sLegacyTitle))\n\t\t{\n\t\t\tif ($this->request()->get('req3') != '')\n\t\t\t{\n\t\t\t\t$sLegacyTitle = $this->request()->get('req3');\n\t\t\t}\n\t\t\t\n\t\t\t$aLegacyItem = Phpfox::getService('core')->getLegacyItem(array(\n\t\t\t\t\t'field' => array('category_id', 'name'),\n\t\t\t\t\t'table' => 'event_category',\t\t\n\t\t\t\t\t'redirect' => 'event.category',\n\t\t\t\t\t'title' => $sLegacyTitle,\n\t\t\t\t\t'search' => 'name_url'\n\t\t\t\t)\n\t\t\t);\t\t\n\t\t}\t\t\n\t\t\n\t\tif (($iRedirectId = $this->request()->getInt('redirect')) \n\t\t\t&& ($aEvent = Phpfox::getService('event')->getEvent($iRedirectId, true)) \n\t\t\t&& $aEvent['module_id'] != 'event'\n\t\t\t&& Phpfox::hasCallback($aEvent['module_id'], 'getEventRedirect')\n\t\t)\n\t\t{\n\t\t\tif (($sForward = Phpfox::callback($aEvent['module_id'] . '.getEventRedirect', $aEvent['event_id'])))\n\t\t\t{\t\n\t\t\t\tPhpfox::getService('notification.process')->delete('event_invite', $aEvent['event_id'], Phpfox::getUserId());\n\t\t\t\t\n\t\t\t\t$this->url()->forward($sForward);\n\t\t\t}\n\t\t}\t\t\t\n\t\t\n\t\tif (($iDeleteId = $this->request()->getInt('delete')))\n\t\t{\n\t\t\tif (($mDeleteReturn = Phpfox::getService('event.process')->delete($iDeleteId)))\n\t\t\t{\n\t\t\t\tif (is_bool($mDeleteReturn))\n\t\t\t\t{\n\t\t\t\t\t$this->url()->send('event', null, Phpfox::getPhrase('event.event_successfully_deleted'));\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$this->url()->forward($mDeleteReturn, Phpfox::getPhrase('event.event_successfully_deleted'));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (($iRedirectId = $this->request()->getInt('redirect')) && ($aEvent = Phpfox::getService('event')->getEvent($iRedirectId, true)))\n\t\t{\n\t\t\tPhpfox::getService('notification.process')->delete('event_invite', $aEvent['event_id'], Phpfox::getUserId());\n\t\t\t\n\t\t\t$this->url()->permalink('event', $aEvent['event_id'], $aEvent['title']);\t\n\t\t}\n\t\t\n\t\t$bIsUserProfile = false;\n\t\tif (defined('PHPFOX_IS_AJAX_CONTROLLER'))\n\t\t{\n\t\t\t$bIsUserProfile = true;\n\t\t\t$aUser = Phpfox::getService('user')->get($this->request()->get('profile_id'));\n\t\t\t$this->setParam('aUser', $aUser);\n\t\t}\t\t\n\t\t\n\t\tif (defined('PHPFOX_IS_USER_PROFILE'))\n\t\t{\n\t\t\t$bIsUserProfile = true;\n\t\t\t$aUser = $this->getParam('aUser');\n\t\t}\t\t\n\t\t\n\t\t$oServiceEventBrowse = Phpfox::getService('event.browse');\n\t\t$sCategory = null;\n\t\t$sView = $this->request()->get('view', false);\n\t\t$aCallback = $this->getParam('aCallback', false);\t\t\t\n\t\t\n\t\t$this->search()->set(array(\t\t\t\t\n\t\t\t\t'type' => 'event',\n\t\t\t\t'field' => 'm.event_id',\t\t\t\t\n\t\t\t\t'search_tool' => array(\n\t\t\t\t\t'default_when' => 'upcoming',\n\t\t\t\t\t'when_field' => 'start_time',\n\t\t\t\t\t'when_upcoming' => true,\n\t\t\t\t\t'table_alias' => 'm',\n\t\t\t\t\t'search' => array(\n\t\t\t\t\t\t'action' => ($aParentModule === null ? ($bIsUserProfile === true ? $this->url()->makeUrl($aUser['user_name'], array('event', 'view' => $this->request()->get('view'))) : $this->url()->makeUrl('event', array('view' => $this->request()->get('view')))) : $aParentModule['url'] . 'event/view_' . $this->request()->get('view') . '/'),\n\t\t\t\t\t\t'default_value' => Phpfox::getPhrase('event.search_events'),\n\t\t\t\t\t\t'name' => 'search',\n\t\t\t\t\t\t'field' => 'm.title'\n\t\t\t\t\t),\n\t\t\t\t\t'sort' => array(\n\t\t\t\t\t\t'latest' => array('m.start_time', Phpfox::getPhrase('event.latest'), 'ASC'),\n\t\t\t\t\t\t'most-viewed' => array('m.total_view', Phpfox::getPhrase('event.most_viewed')),\n\t\t\t\t\t\t'most-liked' => array('m.total_like', Phpfox::getPhrase('event.most_liked')),\n\t\t\t\t\t\t'most-talked' => array('m.total_comment', Phpfox::getPhrase('event.most_discussed'))\n\t\t\t\t\t),\n\t\t\t\t\t'show' => array(12, 15, 18, 21)\n\t\t\t\t)\n\t\t\t)\n\t\t);\n\t\t\n\t\t$aBrowseParams = array(\n\t\t\t'module_id' => 'event',\n\t\t\t'alias' => 'm',\n\t\t\t'field' => 'event_id',\n\t\t\t'table' => Phpfox::getT('event'),\n\t\t\t'hide_view' => array('pending', 'my')\n\t\t);\t\t\n\t\t\n\t\tswitch ($sView)\n\t\t{\n\t\t\tcase 'pending':\n\t\t\t\tif (Phpfox::getUserParam('event.can_approve_events'))\n\t\t\t\t{\n\t\t\t\t\t$this->search()->setCondition('AND m.view_id = 1');\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 'my':\n\t\t\t\tPhpfox::isUser(true);\n\t\t\t\t$this->search()->setCondition('AND m.user_id = ' . Phpfox::getUserId());\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tif ($bIsUserProfile)\n\t\t\t\t{\n\t\t\t\t\t$this->search()->setCondition('AND m.view_id ' . ($aUser['user_id'] == Phpfox::getUserId() ? 'IN(0,2)' : '= 0') . ' AND m.privacy IN(' . (Phpfox::getParam('core.section_privacy_item_browsing') ? '%PRIVACY%' : Phpfox::getService('core')->getForBrowse($aUser)) . ') AND m.user_id = ' . (int) $aUser['user_id']);\n\t\t\t\t}\n\t\t\t\telseif ($aParentModule !== null)\n\t\t\t\t{\n\t\t\t\t\t$this->search()->setCondition('AND m.view_id = 0 AND m.privacy IN(%PRIVACY%) AND m.module_id = \\'' . Phpfox::getLib('database')->escape($aParentModule['module_id']) . '\\' AND m.item_id = ' . (int) $aParentModule['item_id'] . '');\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\t\t\t\n\t\t\t\t\tswitch ($sView)\n\t\t\t\t\t{\n\t\t\t\t\t\tcase 'attending':\t\t\t\t\n\t\t\t\t\t\t\t$oServiceEventBrowse->attending(1);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'may-attend':\t\t\t\t\n\t\t\t\t\t\t\t$oServiceEventBrowse->attending(2);\n\t\t\t\t\t\t\tbreak;\t\n\t\t\t\t\t\tcase 'not-attending':\t\t\t\t\n\t\t\t\t\t\t\t$oServiceEventBrowse->attending(3);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'invites':\t\t\t\t\n\t\t\t\t\t\t\t$oServiceEventBrowse->attending(0);\n\t\t\t\t\t\t\tbreak;\t\t\t\t\t\t\t\n\t\t\t\t\t}\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tif ($sView == 'attending')\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->search()->setCondition('AND m.view_id = 0 AND m.privacy IN(%PRIVACY%)');\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->search()->setCondition('AND m.view_id = 0 AND m.privacy IN(%PRIVACY%) AND m.item_id = ' . ($aCallback !== false ? (int) $aCallback['item'] : 0) . '');\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif ($this->request()->getInt('user') && ($aUserSearch = Phpfox::getService('user')->getUser($this->request()->getInt('user'))))\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->search()->setCondition('AND m.user_id = ' . (int) $aUserSearch['user_id']);\n\t\t\t\t\t\t$this->template()->setBreadcrumb($aUserSearch['full_name'] . '\\'s Events', $this->url()->makeUrl('event', array('user' => $aUserSearch['user_id'])), true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\t\t\n\t\tif ($this->request()->getInt('sponsor') == 1)\n\t\t{\n\t\t $this->search()->setCondition('AND m.is_sponsor != 1');\n\t\t Phpfox::addMessage(Phpfox::getPhrase('event.sponsor_help'));\n\t\t}\t\t\t\n\t\t\n\t\tif ($this->request()->get('req2') == 'category')\n\t\t{\n\t\t\t$sCategory = $this->request()->getInt('req3');\n\t\t\t$this->search()->setCondition('AND mcd.category_id = ' . (int) $sCategory);\n\t\t}\n\t\t\n\t\tif ($sView == 'featured')\n\t\t{\n\t\t\t$this->search()->setCondition('AND m.is_featured = 1');\n\t\t}\t\t\n\t\t\n\t\t$this->setParam('sCategory', $sCategory);\t\t\n\t\t\n\t\t$oServiceEventBrowse->callback($aCallback)->category($sCategory);\t\n\t\t\t\n\t\t$this->search()->browse()->params($aBrowseParams)->execute();\n\t\t\n\t\t$aFilterMenu = array();\n\t\t$bSetFilterMenu = (!defined('PHPFOX_IS_USER_PROFILE') && !defined('PHPFOX_IS_PAGES_VIEW') );\n\t\tif ($sPlugin = Phpfox_Plugin::get('event.component_controller_index_set_filter_menu_1'))\n\t\t{\n\t\t\teval($sPlugin);\n\t\t\tif (isset($mReturnFromPlugin))\n\t\t\t{\n\t\t\t\treturn $mReturnFromPlugin;\n\t\t\t}\n\t\t}\n\t\t\n\t\tif ($bSetFilterMenu)\n\t\t{\n\t\t\t$aFilterMenu = array(\n\t\t\t\tPhpfox::getPhrase('event.all_events') => '',\n\t\t\t\tPhpfox::getPhrase('event.my_events') => 'my'\n\t\t\t);\t\t\t\t\t\t\t\n\t\t\t\t\n\t\t\tif (Phpfox::isModule('friend') && !Phpfox::getParam('core.friends_only_community'))\n\t\t\t{\n\t\t\t\t$aFilterMenu[Phpfox::getPhrase('event.friends_events')] = 'friend';\t\n\t\t\t}\t\t\t\n\t\t\t\n\t\t\tlist($iTotalFeatured, $aFeatured) = Phpfox::getService('event')->getFeatured();\n\t\t\tif ($iTotalFeatured)\n\t\t\t{\n\t\t\t\t$aFilterMenu[Phpfox::getPhrase('event.featured_events') . '<span class=\"pending\">' . $iTotalFeatured . '</span>'] = 'featured';\n\t\t\t}\t\t\t\t\n\t\t\t\n\t\t\tif (Phpfox::getUserParam('event.can_approve_events'))\n\t\t\t{\n\t\t\t\t$iPendingTotal = Phpfox::getService('event')->getPendingTotal();\n\t\t\t\t\n\t\t\t\tif ($iPendingTotal)\n\t\t\t\t{\n\t\t\t\t\t$aFilterMenu[Phpfox::getPhrase('event.pending_events') . '<span class=\"pending\">' . $iPendingTotal . '</span>'] = 'pending';\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t$aFilterMenu[] = true;\n\t\t\t\n\t\t\t$aFilterMenu[Phpfox::getPhrase('event.events_i_m_attending')] = 'attending';\n\t\t\t$aFilterMenu[Phpfox::getPhrase('event.events_i_may_attend')] = 'may-attend';\n\t\t\t$aFilterMenu[Phpfox::getPhrase('event.events_i_m_not_attending')] = 'not-attending';\n\t\t\t$aFilterMenu[Phpfox::getPhrase('event.event_invites')] = 'invites';\n\t\t\t\n\t\t\t$this->template()->buildSectionMenu('event', $aFilterMenu);\t\n\t\t}\t\t\t\t\t\t\t\n\t\t\n\t\t$this->template()->setTitle(($bIsUserProfile ? Phpfox::getPhrase('event.full_name_s_events', array('full_name' => $aUser['full_name'])) : Phpfox::getPhrase('event.events')))->setBreadcrumb(Phpfox::getPhrase('event.events'), ($aCallback !== false ? $this->url()->makeUrl($aCallback['url_home'][0], array_merge($aCallback['url_home'][1], array('event'))) : ($bIsUserProfile ? $this->url()->makeUrl($aUser['user_name'], 'event') : $this->url()->makeUrl('event'))))\n\t\t\t->setHeader('cache', array(\n\t\t\t\t\t'pager.css' => 'style_css',\n\t\t\t\t\t'country.js' => 'module_core',\n\t\t\t\t\t'comment.css' => 'style_css',\n\t\t\t\t\t'browse.css' => 'module_event',\n\t\t\t\t\t'feed.js' => 'module_feed'\t\t\t\t\n\t\t\t\t)\n\t\t\t)\n\t\t\t->assign(array(\n\t\t\t\t\t'aEvents' => $this->search()->browse()->getRows(),\n\t\t\t\t\t'sView' => $sView,\n\t\t\t\t\t'aCallback' => $aCallback,\n\t\t\t\t\t'sParentLink' => ($aCallback !== false ? $aCallback['url_home'][0] . '.' . implode('.', $aCallback['url_home'][1]) . '.event' : 'event'),\n\t\t\t\t\t'sApproveLink' => $this->url()->makeUrl('event', array('view' => 'pending'))\n\t\t\t\t)\n\t\t\t);\n\t\t\t\n\t\tif ($sCategory !== null)\n\t\t{\n\t\t\t$aCategories = Phpfox::getService('event.category')->getParentBreadcrumb($sCategory);\t\t\t\n\t\t\t$iCnt = 0;\n\t\t\tforeach ($aCategories as $aCategory)\n\t\t\t{\n\t\t\t\t$iCnt++;\n\t\t\t\t\n\t\t\t\t$this->template()->setTitle($aCategory[0]);\n\t\t\t\t\n\t\t\t\tif ($aCallback !== false)\n\t\t\t\t{\n\t\t\t\t\t$sHomeUrl = '/' . Phpfox::getLib('url')->doRewrite($aCallback['url_home'][0]) . '/' . implode('/', $aCallback['url_home'][1]) . '/' . Phpfox::getLib('url')->doRewrite('event') . '/';\n\t\t\t\t\t$aCategory[1] = preg_replace('/^http:\\/\\/(.*?)\\/' . Phpfox::getLib('url')->doRewrite('event') . '\\/(.*?)$/i', 'http://\\\\1' . $sHomeUrl . '\\\\2', $aCategory[1]);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$this->template()->setBreadcrumb($aCategory[0], $aCategory[1], (empty($sView) ? true : false));\n\t\t\t}\t\t\t\n\t\t}\n\t\t\n\t\tif ($aCallback !== false)\n\t\t{\n\t\t\t$this->template()->rebuildMenu('event.index', $aCallback['url_home']);\t\t\t\n\t\t}\n\n\t\tPhpfox::getLib('pager')->set(array('page' => $this->search()->getPage(), 'size' => $this->search()->getDisplay(), 'count' => $this->search()->browse()->getCount()));\n\t\t\n\t\t$this->setParam('global_moderation', array(\n\t\t\t\t'name' => 'event',\n\t\t\t\t'ajax' => 'event.moderation',\n\t\t\t\t'menu' => array(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'phrase' => Phpfox::getPhrase('event.delete'),\n\t\t\t\t\t\t'action' => 'delete'\n\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'phrase' => Phpfox::getPhrase('event.approve'),\n\t\t\t\t\t\t'action' => 'approve'\n\t\t\t\t\t)\t\t\t\t\t\n\t\t\t\t)\n\t\t\t)\n\t\t);\t\t\t\n\t}", "title": "" }, { "docid": "fa3f5b23bd9e70ce36a7404d988bf0af", "score": "0.5000633", "text": "function NewsCategory()\n {\n $q = \"SELECT `\".TblModNewsCat.\"`.*\n FROM `\".TblModNewsCat.\"`\n WHERE `lang_id`='\"._LANG_ID.\"'\n ORDER BY `move` ASC \";\n $res = $this->db->db_Query( $q );\n $rows = $this->db->db_GetNumRows();\n\n if ($rows>0){\n //if( isset($settings['subscr']) AND $settings['subscr']=='1' ) {$style_add='float:left;';}\n ?>\n <div class=\"newsLinksBlock\" align=\"left\">\n <div class=\"m_title\">\n <?=$this->multi[\"_FLD_NEWS_CATEGORY\"];?>:\n </div>\n <?\n for( $i = 0; $i < $rows; $i++ ){\n $row = $this->db->db_FetchAssoc();\n $name = $row['name'];\n $q1 = \"select * from \".TblModNews.\" where id_category='\".$row['cod'].\"' and status!='i' \";\n $res1 = $this->db->db_Query( $q1 );\n $rows1 = $this->db->db_GetNumRows();\n\n if( $rows1 ) {\n $link = $this->Link($row['cod'], NULL);\n ?><br/><a class=\"t_link\" href=\"<?=$link;?>\"><?=$name;?>&nbsp;→</a>&nbsp;<span class=\"inacive_txt\"><?=$rows1;?></span><?\n } // end if\n } // end for\n ?>\n </div>\n <?\n }\n }", "title": "" }, { "docid": "39597b3b7d1a50cafa87bb485ba71851", "score": "0.49967942", "text": "public function custom_menu_messages() {\n global $USER;\n $messagemenu = new custom_menu();\n\n $addmessagemenu = true;\n\n if (!isloggedin() || isguestuser()) {\n $addmessagemenu = false;\n }\n\n if ($addmessagemenu) {\n $messages = $this->get_user_messages();\n $messagecount = 0;\n foreach ($messages as $message) {\n if (!$message->from) { // Workaround for issue #103 in Elegance.\n continue;\n }\n $messagecount++;\n }\n\n $messagetitle = $messagecount.' ';\n if ($messagecount == 0) {\n $messagemenuicon = html_writer::tag('i', '', array('class' => 'fa fa-envelope-o'));\n $messagetitle .= get_string('messages', 'message');\n } else {\n $messagemenuicon = html_writer::tag('i', '', array('class' => 'fa fa-envelope'));\n if ($messagecount == 1) {\n $messagetitle .= get_string('message', 'message');\n } else {\n $messagetitle .= get_string('messages', 'message');\n }\n }\n $messagemenucount = $messagecount.' ';\n $messagemenutext = html_writer::tag('span', $messagemenucount).$messagemenuicon;\n $messagesubmenu = $messagemenu->add(\n $messagemenutext,\n new moodle_url('/message/index.php', array('viewing' => 'recentconversations')),\n $messagetitle,\n 9999\n );\n foreach ($messages as $message) {\n if (!$message->from) { // Workaround for issue #103.\n continue;\n }\n $senderpicture = new user_picture($message->from);\n $senderpicture->link = false;\n $senderpicture->size = 60;\n\n $messagecontent = html_writer::start_span('msg-picture').$this->render($senderpicture).html_writer::end_span();\n $messagecontent .= html_writer::start_span('msg-body');\n $messagecontent .= html_writer::span($message->from->firstname, 'msg-sender');\n $messagecontent .= html_writer::span($message->text, 'msg-text');\n $messagecontent .= html_writer::start_span('msg-time');\n $messagecontent .= html_writer::tag('i', '', array('class' => 'fa fa-comments'));\n $messagecontent .= html_writer::span($this->get_time_difference($message->date));\n $messagecontent .= html_writer::end_span();\n $messagecontent .= html_writer::end_span();\n\n $messageurl = new moodle_url('/message/index.php', array('user1' => $USER->id, 'user2' => $message->from->id));\n $messagesubmenu->add($messagecontent, $messageurl, $message->text);\n }\n }\n\n return $this->render_custom_menu($messagemenu);\n }", "title": "" }, { "docid": "8894421522d55b4e34fc868d01661763", "score": "0.49954316", "text": "function BH_add_event_categories_submenu( $items, $args ) {\r\n\r\n\tif ( empty( $args->add_events_list_under ) )\r\n\t\t// return\r\n\t\treturn $items;\r\n\r\n\tforeach ( $args->add_events_list_under as $events_page ) {\r\n\r\n\t\t/**\r\n\t\t * Variables\r\n\t\t */\r\n\t\t$categories_type\t= $events_page[ 'type' ];\r\n\t\t$page_id\t\t\t= $events_page[ 'id' ];\r\n\r\n\t\tforeach ( $items as $key => $item ) {\r\n\r\n\t\t\tif ( $item->object_id == $page_id ) {\r\n\t\t\t\tBH_add_event_categories_submenu_items( $items, $key, $categories_type );\r\n\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\r\n\t\t}\r\n\r\n\t}\r\n\r\n\t// return\r\n\treturn $items;\r\n\r\n}", "title": "" }, { "docid": "83db0a8fff6321a71a0f3f4223dadb5c", "score": "0.4990813", "text": "function chat_on() {\n \n }", "title": "" }, { "docid": "2112a500c68e628f14f8db93ca20ff14", "score": "0.49842423", "text": "function mash_status_messages($display = NULL) {\n $output = '';\n foreach (drupal_get_messages($display) as $type => $messages) {\n $output .= \"<div class=\\\"messages $type\\\">\\n\";\n $output .= \"<ul>\\n<li>\" . implode(\"</li>\\n<li>\", $messages) . \"</li>\\n</ul>\\n\";\n $output .= \"</div>\\n\";\n }\n return $output;\n}", "title": "" }, { "docid": "ade827893548fbdabf2d69521894100c", "score": "0.49813136", "text": "function reply_notification_action($hook, $entity_type, $data, $params){\n $topic_guid = (int) get_input('topic_guid');\n $text = get_input('description');\n $reply_guid = (int) get_input('guid');\n\n $from_entity = elgg_get_logged_in_user_entity();\n $entity = get_entity($topic_guid);\n $to_entity = get_entity($entity->owner_guid);\n $group = get_entity($entity->container_guid);\n\n if($text!=\"\"){\n \n $url_user = elgg_view('output/url', array(\n 'href' => $from_entity->getURL(),\n 'text' => $from_entity->name,\n 'class' => 'elgg-river-subject',\n )); \n\n $url_group = elgg_view('output/url', array(\n 'href' => $group->getURL(),\n 'text' => $group->name,\n 'class' => 'elgg-river-subject',\n ));\n \n if($from_entity->guid!=$entity->owner_guid){\n $description = elgg_echo('live_notifications:group:discussion:replyowner', array($url_user, $url_group));\n $description .= '<a href=\"'.$entity->getUrl().'\" title=\"\">'.$entity->title.'</a><br>';\n $description .= '<i>'.elgg_get_excerpt($text,50).'</i>';\n add_new_notification($entity->owner_guid, $from_entity->guid, $type, $entity->guid, $description);\n }\n\n $members = $group->getMembers();\n foreach ($members as $member) {\n $description = elgg_echo('live_notifications:group:discussion:reply', array($url_user, $url_group));\n $description .= '<a href=\"'.$entity->getUrl().'\" title=\"\">'.$entity->title.'</a>';\n $description .= '<i>'.elgg_get_excerpt($text,50).'</i>';\n # Notify to all members\n if($from_entity->guid!=$member->guid && $member->guid!=$entity->owner_guid){\n add_new_notification($member->guid, $from_entity->guid, $type, $entity->guid, $description); \n }\n }\n } \n\n}", "title": "" }, { "docid": "3c3a968c6cad86f8a49deaa1f610106c", "score": "0.4978756", "text": "function construction_type_updated_messages($messages)\n{\n\n $messages['construction-type'] = array(\n 0 => '', // Unused. Messages start at index 1.\n 1 => __('Construction type added.', 'YOUR-TEXTDOMAIN'),\n 2 => __('Construction type deleted.', 'YOUR-TEXTDOMAIN'),\n 3 => __('Construction type updated.', 'YOUR-TEXTDOMAIN'),\n 4 => __('Construction type not added.', 'YOUR-TEXTDOMAIN'),\n 5 => __('Construction type not updated.', 'YOUR-TEXTDOMAIN'),\n 6 => __('Construction types deleted.', 'YOUR-TEXTDOMAIN'),\n );\n\n return $messages;\n}", "title": "" }, { "docid": "4aa60a7afb2719805706636246e82bb1", "score": "0.49773556", "text": "abstract protected function getMessageClass();", "title": "" }, { "docid": "4d37228322b19f3b4a60caa09c22ea5a", "score": "0.49693847", "text": "function convertjcal() {\n\n\t\tglobal $task;\n\n\t\t$cfg = & JEVConfig::getInstance();\n\t\t$option = $cfg->get(\"com_componentname\", \"com_events\");\n\t\t\n\t\t$db\t=& JFactory::getDBO();\n\n\t\t/**\n\t\t * Categories first \n\t\t **/\n\t\t$query = \"SELECT * FROM #__jcalpro_categories\";\n\t\t$db->setQuery($query);\n\t\t$cats = $db->loadObjectList();\n\n\t\tforeach ($cats as $ec){\n\t\t\t// Remove identical category first !!\n\t\t\t// First remove the extra jevents category information\n\t\t\t$query=\"SELECT id FROM #__categories\"\n\t\t\t.\"\\n WHERE title='$ec->cat_name (jcal)' and section='com_events'\";\n\t\t\t$db->setQuery($query);\n\t\t\t$ids = $db->loadResultArray();\n\t\t\t$idlist = implode(\",\",$ids);\n\n\t\t\tif (count($ids)>0){\n\t\t\t\t$idlist = implode(\",\",$ids);\n\t\t\t\t$query=\"DELETE FROM #__events_categories WHERE id IN ($idlist)\";\n\t\t\t\t$db->setQuery($query);\n\t\t\t\tif( !$db->query() ) {\n\t\t\t\t\t$error = array( $db->getErrorMsg(), $query );\n\t\t\t\t\techo \"Error in - \".$error[1].\"<br/>\";\n\t\t\t\t\techo \"Error message is \".$error[0].\"<hr/>\";\n\t\t\t\t}\n\n\t\t\t\t$query=\"DELETE FROM #__categories\"\n\t\t\t\t.\"\\n WHERE id IN ($idlist)\";\n\t\t\t\t$db->setQuery($query);\n\t\t\t\tif( !$db->query() ) {\n\t\t\t\t\t$error = array( $db->getErrorMsg(), $query );\n\t\t\t\t\techo \"Error in - \".$error[1].\"<br/>\";\n\t\t\t\t\techo \"Error message is \".$error[0].\"<hr/>\";\n\t\t\t\t}\n\n\t\t\t}\n\n\n\t\t\t// Assume for time being all parents = 0!!\n\t\t\t$query=\"INSERT INTO #__categories\"\n\t\t\t.\"\\n (parent_id, title, name, image, section, image_position, description, published, checked_out, checked_out_time, editor, ordering, access, count, params)\"\n\t\t\t.\"\\n VALUES (0, '$ec->cat_name (jcal)', '$ec->cat_name (jcal)', '', 'com_events' ,'left', '$ec->description', $ec->published, $ec->checked_out, '$ec->checked_out_time','',0,0,0,'') \";\n\t\t\t$db->setQuery($query);\n\t\t\tif( !$db->query() ) {\n\t\t\t\t$error = array( $db->getErrorMsg(), $query );\n\t\t\t\techo \"Error in - \".$error[1].\"<br/>\";\n\t\t\t\techo \"Error message is \".$error[0].\"<hr/>\";\n\t\t\t}\n\n\t\t\t// Now set the extra jevents category information\n\t\t\t$query=\"SELECT id FROM #__categories\"\n\t\t\t.\"\\n WHERE title='$ec->cat_name (jcal)'\";\n\t\t\t$db->setQuery($query);\n\t\t\t$id = $db->loadResult();\n\n\t\t\tif ($id>0){\n\t\t\t\t$query=\"INSERT INTO #__events_categories\"\n\t\t\t\t.\"\\n (id, color)\"\n\t\t\t\t.\"\\n VALUES ($id, '$ec->color')\";\n\t\t\t\t$db->setQuery($query);\n\t\t\t\tif( !$db->query() ) {\n\t\t\t\t\t$error = array( $db->getErrorMsg(), $query );\n\t\t\t\t\techo \"Error in - \".$error[1].\"<br/>\";\n\t\t\t\t\techo \"Error message is \".$error[0].\"<hr/>\";\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\n\t\t/**\n\t\t * Now to convert the events put them in a special series of icals from scratch called by their category names\n\t\t */\n\t\tinclude_once(JPATH_SITE.\"/components/\".JEV_COM_COMPONENT.\"/libraries/iCalImport.php\");\n\t\tforeach ($cats as $ec) {\n\t\t\t// clean out any aborter migration attempts\n\t\t\t$query=\"DELETE FROM #__jevents_icsfile\"\n\t\t\t.\"\\n WHERE label='$ec->cat_name (jcal)'\"\n\t\t\t.\"\\n AND icaltype=2\";\n\t\t\t$db->setQuery($query);\n\t\t\tif( !$db->query() ) {\n\t\t\t\t$error = array( $db->getErrorMsg(), $query );\n\t\t\t\techo \"Error in - \".$error[1].\"<br/>\";\n\t\t\t\techo \"Error message is \".$error[0].\"<hr/>\";\n\t\t\t}\n\n\t\t\t$query=\"SELECT id FROM #__categories\"\n\t\t\t.\"\\n WHERE title='$ec->cat_name (jcal)' and section='com_events'\";\n\t\t\t$db->setQuery($query);\n\t\t\t$catid = $db->loadResult();\n\t\t\tif (is_null($catid) || \t$catid==0){\n\t\t\t\techo \"missing category selection<br/>\";\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t// Should come from the form or existing item\n\t\t\t$access = 0;\n\t\t\t$state = 1;\n\t\t\t$icsLabel = \"$ec->cat_name (jcal)\";\n\t\t\t$icsid = 0;\n\t\t\t$icsFile = iCalICSFile::editICalendar($icsid,$catid,$access,$state,$icsLabel);\n\t\t\t$icsFileid = $icsFile->store();\n\n\n\t\t\t$query = \"SELECT * FROM #__jcalpro_events\"\n\t\t\t.\"\\n WHERE cat=$ec->cat_id\";\n\t\t\t$db->setQuery($query);\n\t\t\t$exevents = $db->loadObjectList();\n\n\t\t\tforeach ($exevents as $xv){\n\t\t\t\t$temp = new stdClass();\n\t\t\t\t$icalevent = new jEventCal($temp);\n\t\t\t\t$icalevent['uid']=md5(uniqid(rand(),true));\n\t\t\t\t$icalevent['adresse_info']=\"\";\n\t\t\t\t// TODO check this\n\t\t\t\t$icalevent['allDayEvent']=\"off\";\n\t\t\t\t$icalevent['contact_info']=$ec->contact.\"&nbsp;\".$ec->email;\n\t\t\t\t$icalevent['content']=$ec->description.\"<hr/>\".$ec->url;\n\t\t\t\t//$icalevent['publish_down']\n\t\t\t\t//$icalevent['publish_up']\n\t\t\t\t$icalevent['rinterval']=$ec->recur_val;\n\t\t\t\t$icalevent['title']=$ec->title;\n\t\t\t\t$icalevent['ics_id']= $icsFileid;\n\t\t\t\t/*\n\t\t\t\t$icalevent['start_time'] = JArrayHelper::getValue( $array, \"start_time\",\"08:00\");\n\t\t\t\telse $end_time \t\t\t= JArrayHelper::getValue( $array, \"end_time\",\"15:00\");\n\t\t\t\t$countuntil\t\t= JArrayHelper::getValue( $array, \"countuntil\",\"count\");\n\t\t\t\t$count \t\t\t= intval(JArrayHelper::getValue( $array, \"count\",1);\n\t\t\t\t$until\t\t\t= JArrayHelper::getValue($array, \"until\",$data[\"publish_down\"]);\n\t\t\t\t$whichby\t\t\t= JArrayHelper::getValue($array, \"whichby\",\"bd\");\n\t\t\t\t$byd_direction\t\t= JArrayHelper::getValue($array, \"byd_direction\",\"off\")==\"off\"?\"+\":\"-\";\n\t\t\t\t$byyearday \t\t\t= JArrayHelper::getValue($array, \"byyearday\",\"\");\n\t\t\t\t$bm_direction\t\t= JArrayHelper::getValue($array, \"bm_direction\",\"off\")==\"off\"?\"+\":\"-\";\n\t\t\t\t$bymonth\t\t\t= JArrayHelper::getValue($array, \"bymonth\",\"\");\n\t\t\t\t$bwn_direction\t\t= JArrayHelper::getValue($array, \"bwn_direction\",\"off\")==\"off\"?\"+\":\"-\";\n\t\t\t\t$byweekno\t\t\t= JArrayHelper::getValue($array, \"byweekno\",\"\");\n\t\t\t\t$bmd_direction\t\t= JArrayHelper::getValue($array, \"bmd_direction\",\"off\")==\"off\"?\"+\":\"-\";\n\t\t\t\t$bymonthday\t\t\t= JArrayHelper::getValue($array, \"bymonthday\",\"\");\n\t\t\t\t$bd_direction\t\t= JArrayHelper::getValue($array, \"bd_direction\",\"off\")==\"off\"?\"+\":\"-\";\n\t\t\t\t$weekdays\t\t\t= JArrayHelper::getValue($array, \"weekdays\",array());\n\t\t\t\t$weeknums\t\t\t= JArrayHelper::getValue($array, \"weeknums\",array());\n\t\t\t\t$vevent->catid = JArrayHelper::getValue($array, \"catid\",0);\n\t\t\t\t$vevent->access = JArrayHelper::getValue($array, \"access\",0);\n\t\t\t\t$vevent->state = intval(JArrayHelper::getValue($array, \"state\",0));\n\t\t\t\t*/\n\t\t\t}\n\n\n\t\t}\n\n\n\t}", "title": "" }, { "docid": "74c4d2c39c903ad9540db7321ab850ce", "score": "0.4968962", "text": "function BeforeAdd(&$values, &$message, $inline, &$pageObject)\n{\n\n\t\t$data = array();\n$data[\"member_id\"] = $_SESSION[\"member_id\"];\n$rs = DB::Select(\"personal_channel\", $data );\n\nif($rs->fetchAssoc()){\n\treturn true;\n}else{\n\t$message = \"Silahkan Masukkan Personal Channel Terlebbih Dahulu\";\n\treturn false;\n}\n\n// Place event code here.\n// Use \"Add Action\" button to add code snippets.\n\n\n;\t\t\n}", "title": "" }, { "docid": "9d67c069e73d259555b2d4396c439272", "score": "0.49635845", "text": "public function process()\n\t{\n\t\tif ($aOrder = $this->request()->getArray('order'))\n\t\t{\n\t\t\tif (Phpfox::getService('videochannel.category.process')->updateOrder($aOrder))\n\t\t\t{\n\t\t\t\t$this->url()->send('admincp.videochannel', null, Phpfox::getPhrase('videochannel.category_order_successfully_updated'));\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\tif ($iDelete = $this->request()->getInt('delete'))\n\t\t{\n\t\t\tif (Phpfox::getService('videochannel.category.process')->delete($iDelete))\n\t\t\t{\n\t\t\t\t$this->url()->send('admincp.videochannel', null, Phpfox::getPhrase('videochannel.category_successfully_deleted'));\n\t\t\t}\n\t\t}\n\t\n\t\t$this->template()->setTitle(Phpfox::getPhrase('videochannel.manage_categories'))\n\t\t\t->setBreadcrumb(Phpfox::getPhrase('videochannel.manage_categories'), $this->url()->makeUrl('admincp.videochannel'))\n\t\t\t->setPhrase(array('videochannel.are_you_sure_this_will_delete_all_videos_that_belong_to_this_category_and_cannot_be_undone'))\n\t\t\t->setHeader(array(\n\t\t\t\t\t'jquery/ui.js' => 'static_script',\n\t\t\t\t\t'admin.js' => 'module_videochannel',\n\t\t\t\t\t'<script type=\"text/javascript\">\n $Behavior.VideoChannelAdminIndex = function() {\n $Core.videochannel.url(\\'' . $this->url()->makeUrl('admincp.videochannel') . '\\');\n }\n </script>'\n\t\t\t\t)\n\t\t\t)\n\t\t\t->assign(array(\n\t\t\t\t\t'sCategories' => Phpfox::getService('videochannel.category')->display('admincp')->get()\n\t\t\t\t)\n\t\t\t);\t\n\t}", "title": "" }, { "docid": "68fe74b92120d39b5fbb205323b9b809", "score": "0.4959336", "text": "function _util_format_event( $data ){\t\n\t\n\t//PRESET\n\t//\tpreset return object\n\t$var = (object)array(\n\t\t'id' \t\t\t\t=> null,\n\t\t'nid' \t\t\t\t=> null,\n\t\t'title' \t\t\t=> array(),\n\t\t'title_short' \t\t=> array(),\n\t\t'description' \t\t=> array(),\n\t\t'body' \t\t\t\t=> array(),\n\t\t'body_short' \t\t=> array(),\n\t\t'register_email' \t=> null,\n\t\t'register_req' \t\t=> null,\n\t\t'date_from' \t\t=> null,\n\t\t'date_to' \t\t\t=> null,\n\t\t'date_timestamp' \t=> null,\n\t\t'address' \t\t\t=> null,\n\t\t'address_cont' \t\t=> null,\n\t\t'youtube' \t\t\t=> null,\n\t\t'facebook_id' \t\t=> null,\n\t\t'facebook_page' \t=> null,\n\t\t'tickets_avail' \t=> null,\n\t\t'tickets_url'\t\t=> null,\n\t\t'image' \t\t\t=> array(),\n\t\t'thumb' \t\t\t=> array(),\n\t\t'gps_long' \t\t\t=> null,\n\t\t'gps_lat' \t\t\t=> null,\n\t\t'price' \t\t\t=> null,\n\t\t'price_free' \t\t=> null,\n\t\t'event_url' \t\t=> null,\n\t\t'hall' \t\t\t\t=> null,\n\t\t'accessibility' \t=> null,\n\t\t'language' \t\t\t=> null,\n\t\t'category' \t\t\t=> array(),\t\n\t);\n\n\t//FOR EVERY NODE\n\t//\tfor every node inject translations\n\tforeach($data as $n){\n\n\t\t$var->id = _extract_text($n->field_kkrabb_event_id);\n\t\t$var->nid = $n->nid;\n\t\t$var->title[] = (object)array(\n\t\t\t\t'value' => $n->title,\n\t\t\t\t//'save' \t=> $n->title,\n\t\t\t\t'format' => 'string',\n\t\t\t\t'lang' => $n->language);\n\n\t\t$var->title_short[] \t= _extract_text($n->field_kkrabb_event_title_short ,$n->language);\n\t\t$var->description[] \t= _extract_text($n->field_kkrabb_event_teaser_capt ,$n->language);\n\t\t$var->body[] \t\t\t= _extract_text($n->field_kkrabb_event_description ,$n->language);\n\t\t$var->body_short[] \t\t= _extract_text($n->field_kkrabb_event_teaser_text ,$n->language);\n\n\t\t$var->register_email \t= _extract_text($n->field_kkrabb_event_registr_email);\n\t\t$var->register_req \t\t= _extract_bool($n->field_kkrabb_event_registr_req);\n\t\t$var->date_from \t\t= _extract_date($n->field_kkrabb_event_date_from);\n\t\t$var->date_to \t\t\t= _extract_date($n->field_kkrabb_event_date_to);\n\t\t$var->date_timestamp \t= _extract_date($n->field_kkrabb_event_beg_unixtime);\n\t\t$var->address \t\t\t= _extract_text($n->field_kkrabb_event_address1);\n\t\t$var->address_cont \t\t= _extract_text($n->field_kkrabb_event_address2);\n\t\t$var->youtube \t\t\t= _extract_text($n->field_event_video_youtube);\n\t\t$var->facebook_id \t\t= _extract_text($n->field_kkrabb_event_facebook_id);\n\t\t$var->facebook_page \t= _extract_text($n->field_kkrabb_event_facebook_page);\n\t\t$var->tickets_avail \t= _extract_bool($n->field_kkrabb_event_tickets_avail);\n\t\t$var->tickets_url \t\t= _extract_text($n->field_kkrabb_event_tickets_url);\n\t\t$var->image[] \t\t\t= _extract_img($n->field_image_background ,$n->language);\n\t\t$var->thumb[] \t\t\t= _extract_img($n->field_kkrabb_event_imgs ,$n->language);\n\t\t$var->gps_long \t\t\t= _extract_float($n->field_kkrabb_event_gps_long);\n\t\t$var->gps_lat \t\t\t= _extract_float($n->field_kkrabb_event_gps_lat);\n\t\t$var->price \t\t\t= (object)array(\n\t\t\t\t\t\t\t\t\t'value' => array_map(function($i){\n\t\t\t\t\t\t\t\t\t\treturn $i['value'];\n\t\t\t\t\t\t\t\t\t},$n->field_kkrabb_event_price_kr['und']),\n\t\t\t\t\t\t\t\t\t//'save' => null,\n\t\t\t\t\t\t\t\t\t'format' => 'int:array');\n\t\t$var->price_free \t\t= _extract_bool($n->field_kkrabb_event_free);\n\t\t$var->event_url \t\t= _extract_text($n->field_kkrabb_event_url);\n\t\t$var->hall \t\t\t\t= _extract_text($n->field_kkrabb_event_suite);\n\t\t$var->accessibility \t= _extract_bool($n->field_kkrabb_event_disabled_nice);\n\t\t$var->language \t\t\t= _extract_text($n->field_kkrabb_event_language);\n\t\t$var->category \t\t\t= (object)array(\n\t\t\t\t\t\t\t\t\t'value' => array_map(function($i){\n\t\t\t\t\t\t\t\t\t\treturn $i['tid'];\n\t\t\t\t\t\t\t\t\t},$n->field_kkrabb_event_taxonomy['und']),\n\t\t\t\t\t\t\t\t\t//'save' => null,\n\t\t\t\t\t\t\t\t\t'format' => 'int:array');\n\t\t\t\n\t\t$var->times->fimmtudagur->active\t\t= _extract_bool($n->field_fimmtudagur_active);\n\t\t$var->times->fimmtudagur->kl\t\t= _extract_text($n->field_fimmtudagur_kl);\n\t\t$var->times->fimmtudagur->til\t\t= _extract_text($n->field_fimmtudagur_til);\n\t\t$var->times->fostudagur->active\t\t= _extract_bool($n->field_fostudagur_active);\n\t\t$var->times->fostudagur->kl\t\t= _extract_text($n->field_fostudagur_kl);\n\t\t$var->times->fostudagur->til\t\t= _extract_text($n->field_fostudagur_til);\n\t\t$var->times->laugardagur->active\t\t= _extract_bool($n->field_laugardagur_active);\n\t\t$var->times->laugardagur->kl\t\t= _extract_text($n->field_laugardagur_kl);\n\t\t$var->times->laugardagur->til\t\t= _extract_text($n->field_laugardagur_til);\n\t\t$var->times->sunnudagur->active\t\t= _extract_bool($n->field_sunnudagur_active);\n\t\t$var->times->sunnudagur->kl\t\t= _extract_text($n->field_sunnudagur_kl);\n\t\t$var->times->sunnudagur->til\t\t= _extract_text($n->field_sunnudagur_til);\n\t\t\n\t}\n\n\treturn $var;\n}", "title": "" }, { "docid": "ae542ce0a622d72102aae1a93a77cae1", "score": "0.49525058", "text": "public function getEventCategory() {\n return $this->category;\n }", "title": "" }, { "docid": "0e79b959df97714ca3fdfee313f6f652", "score": "0.49466348", "text": "function display_events($args = '') {\n $r = array();\n parse_str($args, $r);\necho \"<style type='text/css'> .event-on { display:block; } .event-off { display:none; } </style>\";\n if (! isset($r['url'])) {\n echo \"iCal Events: No URL specified\\n\";\n return;\n }\n\n if (! isset($r['gmt_start'])) $r['gmt_start'] = null;\n if (! isset($r['gmt_end'])) $r['gmt_end'] = null;\n if (! isset($r['limit'])) $r['limit'] = null;\n if (! isset($r['date_format'])) $r['date_format'] = '%a %b %e';\n if (! isset($r['time_format'])) $r['time_format'] = '%l:%M %p';\n if (! isset($r['before'])) $r['before'] = '<li>';\n if (! isset($r['after'])) $r['after'] = '</li>';\n if (! isset($r['before_date'])) $r['before_date'] = '<strong>';\n if (! isset($r['after_date'])) $r['after_date'] = '</strong>: ';\n if (! isset($r['use_summary'])) $r['use_summary'] = true;\n if (! isset($r['before_summary'])) $r['before_summary'] = '<span style=\"font-size:large;font-weight: bolder; font-variant: small-caps;font-family: Garamond;color: #236B8E;display:block;border-bottom:1px dashed #D1EEEE;\">';\n if (! isset($r['after_summary'])) $r['after_summary'] = '</span>';\n if (! isset($r['use_description'])) $r['use_description'] = true;\n if (! isset($r['replace_newlines_with'])) $r['replace_newlines_with'] = '<br />';\n if (! isset($r['before_description'])) $r['before_description'] = ' - ';\n if (! isset($r['after_description'])) $r['after_description'] = '';\n if (! isset($r['use_location'])) $r['use_location'] = true;\n if (! isset($r['before_location'])) $r['before_location'] = ' (';\n if (! isset($r['after_location'])) $r['after_location'] = ')';\n if (! isset($r['use_url'])) $r['use_url'] = true;\n if (! isset($r['echo'])) $r['echo'] = true;\n if (! isset($r['link_description'])) $r['link_description'] = true;\n if (! isset($r['custom_reload'])) $r['custom_reload'] = ICAL_EVENTS_CACHE_TTL; //added custom_reload\n if (! isset($r['alt_open'])) $r['alt_open'] = false; //added force curl\n //if (! isset($r['link_text'])) $r['link_text'] = 'Link';\n if (! isset($r['charset'])) $r['charset'] = get_bloginfo('charset');\n\n//add link_description above and below\n ICalEvents::do_display_events($r['url'], $r['gmt_start'], $r['gmt_end'], $r['limit'], $r['date_format'], $r['time_format'], $r['before'], $r['after'], $r['before_date'], $r['after_date'], $r['use_summary'], $r['before_summary'], $r['after_summary'], $r['use_description'], $r['before_description'], $r['after_description'], $r['replace_newlines_with'], $r['use_location'], $r['before_location'], $r['after_location'], $r['use_url'], $r['charset'], $r['echo'], $r['link_description'], $r['custom_reload'], $r['alt_open']);\n }", "title": "" }, { "docid": "56f47517cd4a6d0faa8e456cc4d52d95", "score": "0.49453104", "text": "public static function addFlashMessages(){\n\t\t$messages = self::bddSelect(\"SELECT message_text FROM shaoline_flash_message WHERE message_only_for_logged = 0 AND current_date() >= message_start_date AND current_date() <= message_stop_date\");\n\t\twhile ($row = $messages->fetchAssoc()) {\n\t\t\tShaContext::addFlashMessage($row[\"message_text\"]);\n\t\t}\n\t\t\n\t\tif (ShaContext::getUser()->isAuthentified()){\n\t\t\t// Getting message for logged user\n\t\t\t$messages = self::bddSelect(\"\n\t\t\tSELECT message_id, message_text\n\t\t\tFROM shaoline_flash_message\n\t\t\tWHERE\n\t\t\t\tmessage_only_for_logged = 1 AND\n\t\t\t\tcurrent_date() >= message_start_date AND\n\t\t\t\tcurrent_date() <= message_stop_date AND\n\t\t\t\tmessage_id NOT IN (SELECT message_id FROM shaoline_user_flash_message WHERE user_id = \".ShaContext::getUser()->getValue(\"user_id\").\")\n\t\t\t\");\n\t\t\twhile ($row = $messages->fetchAssoc()) {\n\t\t\t\tShaContext::addFlashMessage($row[\"message_text\"]);\n\t\t\t\t$shaUserFlashMessage = new ShaUserFlashMessage();\n\t\t\t\t$shaUserFlashMessage\n\t\t\t\t\t->setValue(\"user_id\", ShaContext::getUser().getValue(\"user_id\"))\n\t\t\t\t\t->setValue(\"message_id\", $row[\"message_id\"])\n\t\t\t\t\t->save()\n\t\t\t\t;\n\t\t\t}\n\t\t\t\n\t\t}\n\t\n\t}", "title": "" }, { "docid": "ef85019cd6b3ce5b19b539c9ae3f92bd", "score": "0.4934987", "text": "public function categories_list($action, $message='', $error='')\n {\n $data = array();\n $data['user_course_categories'] = $this->model->get_user_course_categories();\n $data['action'] = $action;\n $data['message'] = $message;\n $data['error'] = $error;\n\n // render to the view\n $this->view->set_data($data);\n $this->view->set_layout('catalog_layout');\n $this->view->set_template('categories_list');\n $this->view->render();\n }", "title": "" }, { "docid": "315f1c8c411bca131588466fc348ce7f", "score": "0.4934187", "text": "public function messages() {\n // $messages = [];\n $messages = $this->listMessages();\n print $this->render(messages,$messages);\n }", "title": "" }, { "docid": "54d7f8e8e5cee303382e06a469c635cb", "score": "0.4932744", "text": "public function courses_categories(\n $action,\n $category_code = null,\n $message = '',\n $error = '',\n $content = null,\n $limit = array()\n ) {\n $data = array();\n $browse_course_categories = $this->model->browse_course_categories();\n $data['countCoursesInCategory'] = $this->model->count_courses_in_category($category_code);\n if ($action === 'display_random_courses') {\n // Random value is used instead limit filter\n $data['browse_courses_in_category'] = $this->model->browse_courses_in_category(null, 12);\n $data['countCoursesInCategory'] = count($data['browse_courses_in_category']);\n } else {\n if (!isset($category_code)) {\n $category_code = $browse_course_categories[0][1]['code']; // by default first category\n }\n $limit = isset($limit) ? $limit : CourseCategory::getLimitArray();\n $data['browse_courses_in_category'] = $this->model->browse_courses_in_category($category_code, null, $limit);\n }\n\n $data['browse_course_categories'] = $browse_course_categories;\n $data['code'] = Security::remove_XSS($category_code);\n\n // getting all the courses to which the user is subscribed to\n $curr_user_id = api_get_user_id();\n $user_courses = $this->model->get_courses_of_user($curr_user_id);\n $user_coursecodes = array();\n\n // we need only the course codes as these will be used to match against the courses of the category\n if ($user_courses != '') {\n foreach ($user_courses as $key => $value) {\n $user_coursecodes[] = $value['code'];\n }\n }\n\n if (api_is_drh()) {\n $courses = CourseManager::get_courses_followed_by_drh(api_get_user_id());\n foreach ($courses as $course) {\n $user_coursecodes[] = $course['code'];\n }\n }\n\n $data['user_coursecodes'] = $user_coursecodes;\n $data['action'] = $action;\n $data['message'] = $message;\n $data['content'] = $content;\n $data['error'] = $error;\n\n $data['catalogShowCoursesSessions'] = 0;\n\n $showCoursesSessions = intval('catalog_show_courses_sessions');\n if ($showCoursesSessions > 0) {\n $data['catalogShowCoursesSessions'] = $showCoursesSessions;\n }\n\n // render to the view\n\n $this->view->set_data($data);\n $this->view->set_layout('catalog_layout');\n $this->view->set_template('courses_categories');\n $this->view->render();\n }", "title": "" }, { "docid": "82beef83a04b0ba366b68a9f5647663e", "score": "0.4931384", "text": "function subcate_add($data)\n\t {\n\t $table = 'sub_category';\n\t\tif($data['langCode'] != 'zh')\n\t\t{\n\t\t $table = 'sub_category_ext';\n\t\t}\n\t\treturn $this->subcate_add_event($data,$table);\n\t }", "title": "" }, { "docid": "46bb8b9f1a9913f098338dc0559d1689", "score": "0.49312332", "text": "public function parentViewChildRecord(ParentViewChildRecordEvent $event)\n\t{\n\t\t/** @var EntityModel $model */\n\t\t$model = $event->getModel();\n\t\t/** @var \\Avisota\\Contao\\Entity\\Message $message */\n\t\t$message = $model->getEntity();\n\n\t\tif ($message->getCategory()->getBoilerplates()) {\n\t\t\t$language = $message->getLanguage();\n\n\t\t\tif (isset($GLOBALS['TL_LANG']['LNG'][$language])) {\n\t\t\t\t$language = $GLOBALS['TL_LANG']['LNG'][$language];\n\t\t\t}\n\n\t\t\t$label = sprintf(\n\t\t\t\t'%s [%s]',\n\t\t\t\t$message->getSubject(),\n\t\t\t\t$language\n\t\t\t);\n\n\t\t\t$event->setHtml($label);\n\t\t}\n\t\telse {\n\t\t\t$icon = $model->getProperty('sendOn') ? 'visible' : 'invisible';\n\n\t\t\t$label = $model->getProperty('subject');\n\n\t\t\tif ($message->getSendOn()) {\n\t\t\t\t$parseDateEvent = new ParseDateEvent(\n\t\t\t\t\t$message->getSendOn()->getTimestamp(),\n\t\t\t\t\t$GLOBALS['TL_CONFIG']['datimFormat']\n\t\t\t\t);\n\n\t\t\t\t/** @var EventDispatcher $eventDispatcher */\n\t\t\t\t$eventDispatcher = $GLOBALS['container']['event-dispatcher'];\n\t\t\t\t$eventDispatcher->dispatch(ContaoEvents::DATE_PARSE, $parseDateEvent);\n\n\t\t\t\t$label .= ' <span style=\"color:#b3b3b3; padding-left:3px;\">(' . sprintf(\n\t\t\t\t\t\t$GLOBALS['TL_LANG']['orm_avisota_message']['sended'],\n\t\t\t\t\t\t$parseDateEvent->getResult()\n\t\t\t\t\t) . ')</span>';\n\t\t\t}\n\n\t\t\t/** @var EventDispatcher $eventDispatcher */\n\t\t\t$eventDispatcher = $GLOBALS['container']['event-dispatcher'];\n\t\t\t$getThemeEvent = new GetThemeEvent();\n\t\t\t$eventDispatcher->dispatch(ContaoEvents::BACKEND_GET_THEME, $getThemeEvent);\n\n\t\t\t$event->setHtml(\n\t\t\t\tsprintf(\n\t\t\t\t\t'<div class=\"list_icon\" style=\"background-image:url(\\'system/themes/%s/images/%s.gif\\');\">%s</div>',\n\t\t\t\t\t$getThemeEvent->getTheme(),\n\t\t\t\t\t$icon,\n\t\t\t\t\t$label\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\t}", "title": "" }, { "docid": "1cbbd6652f80209e9ee4128324bc421a", "score": "0.49307993", "text": "function __dc($domain, $msg, $category, $args = null) {\n\t\tif (!$msg) {\n\t\t\treturn;\n\t\t}\n\t\tApp::uses('I18n', 'I18n');\n\t\t$translated = I18n::translate($msg, null, $domain, $category);\n\t\tif ($args === null && func_num_args() < 5) {\n\t\t\treturn $translated;\n\t\t} elseif (!is_array($args)) {\n\t\t\t$args = array_slice(func_get_args(), 3);\n\t\t}\n\n\t\t$translated = preg_replace('/(?<!%)%(?![%\\'\\-+bcdeEfFgGosuxX\\d\\.])/', '%%', $translated);\n\t\treturn vsprintf($translated, $args);\n\t}", "title": "" }, { "docid": "66157e04b236ffff4af61f2732b320e8", "score": "0.49217483", "text": "function manageEvent($args){\n\t\t\n\t}", "title": "" }, { "docid": "d920e550207cc8a5736885246e0785dd", "score": "0.49191803", "text": "abstract public function addLogMessage($message);", "title": "" }, { "docid": "dee152460982e1e0199201481b8c8e00", "score": "0.49120817", "text": "public function message()\n {\n return 'Ce sous-categorie est déja utilisé.';\n }", "title": "" }, { "docid": "3f9738d568c08c82930a6255be350021", "score": "0.49114305", "text": "function make_messages_integration()\r\n\t{\r\n\t\t// Setze Variable auf NULL falls nicht existent, zwecks Behebung von Warnungen\r\n\t\tif (!isset($_SESSION['dbp']['papoo_plugins'])){\r\n\t\t\t$_SESSION['dbp']['papoo_plugins'] = NULL;\r\n\t\t}\r\n\t\t// 1. die papoo_plugins-Tabelle nach Einträgen durchsuchen\r\n\t\t$sql = sprintf(\"SELECT * FROM %s\", $this->cms->papoo_plugins);\r\n\t\tif (!is_array($_SESSION['dbp']['papoo_plugins'])) {\r\n\t\t\t$result = $this->db->get_results($sql);\r\n\t\t\t$_SESSION['dbp']['papoo_plugins'] = $result;\r\n\t\t}\r\n\t\telse {\r\n\t\t\t$result=$_SESSION['dbp']['papoo_plugins'];\r\n\t\t}\r\n\r\n\t\tif ($result) {\r\n\t\t\tforeach ($result as $plugin) {\r\n\t\t\t\t// 2. Die Messages-Dateien einbinden (wenn vorhanden)\r\n\t\t\t\tif (!empty($plugin->plugin_messages)){\r\n\t\t\t\t\t$this->message->einbinden(\"/plugins/\".$plugin->plugin_messages);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "f69b0e76df5bf17e4f7794d770c688f8", "score": "0.4908279", "text": "public function onBlogCategory(PageEvent $event)\n\t{\n\t}", "title": "" }, { "docid": "b2ad6cb3638fced6ef2db22002dfc946", "score": "0.4904521", "text": "public static function HighLevelEvents() {return 2;}", "title": "" }, { "docid": "717fa625d8ae04bd4bcb90dffae9212e", "score": "0.4901494", "text": "public function add_conctact_msg()\n {\n $redirect = $this->input->post('redirect');\n $excludeArr = array('redirect', 'discussion', 'experience_title');\n $now = time();\n $dataArr = array('productId' => $this->input->post('rental_id'), 'senderId' => $this->checkLogin('U'), 'receiverId' => $this->input->post('receiver_id'), 'subject' => 'Contact Message on :' . $this->input->post('experience_title'), 'message' => $this->input->post('message'));\n $this->user_model->simple_insert(EXPERIENCE_MED_MSG, $dataArr);\n $dataArr = array('convId' => $now);\n $condition = array();\n $this->product_model->commonInsertUpdate(EXPERIENCE_DISCUSSION, 'insert', $excludeArr, $dataArr, $condition);\n if ($this->lang->line('Your message was successfully sent') != '') {\n $message = stripslashes($this->lang->line('Your message was successfully sent'));\n } else {\n $message = \"Your message was successfully sent\";\n }\n $this->setErrorMessage('success', $message);\n redirect($redirect);\n }", "title": "" }, { "docid": "502187e4da7faab25c5d0658dc330eed", "score": "0.49012518", "text": "function add_category_form($db)\n{\nglobal $bluebdr, $action,$SID;\n\n \techo \"<table width=\\\"100%\\\" border=\\\"1\\\" cellspacing=\\\"0\\\" cellpadding=\\\"0\\\" bordercolor=\\\"$bluebdr\\\" align=\\\"center\\\">\\n\";\n \techo \"<tr>\\n\";\n \techo \" <td bgcolor=\\\"$bluebdr\\\" class=\\\"whitemain\\\" height=\\\"23\\\">&nbsp;Add an event</td>\\n\";\n \techo \"</tr>\\n\";\n \techo \"<tr>\\n\";\n\techo \"<td bgcolor=\\\"#FFFFFF\\\" valign=\\\"top\\\" bordercolor=\\\"#FFFFFF\\\" class=\\\"main\\\" colspan=\\\"2\\\">\\n\";\n\n\n\techo \"<form action=\\\"main.php\\\" method=\\\"post\\\" enctype=\\\"multipart/form-data\\\" validate=\\\"onchange\\\" invalidColor=\\\"yellow\\\">\\n\";\n\techo \"<input type=\\\"hidden\\\" name=\\\"SID\\\" value=\\\"$SID\\\">\\n\";\n\techo \"<input type=\\\"hidden\\\" name=\\\"action\\\" value=\\\"$action\\\">\\n\";\n\techo \"<input type=\\\"hidden\\\" name=\\\"do\\\" value=\\\"sadd\\\">\\n\";\n\techo \"<input type=\\\"hidden\\\" name=\\\"doit\\\" value=\\\"1\\\">\\n\";\n\n\techo \"<table width=\\\"100%\\\" cellspacing=\\\"1\\\" cellpadding=\\\"3\\\" border=\\\"1\\\" align=\\\"left\\\">\\n\";\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\">event title</td>\\n\";\n\techo \" <td class=\\\"trrow1\\\"><input type=\\\"text\\\" name=\\\"title\\\" size=\\\"35\\\" maxlength=\\\"255\\\" required msg=\\\"Please enter an event title\\\"></td>\\n\";\n\techo \" </tr>\\n\";\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\">event description</td>\\n\";\n\techo \" <td class=\\\"trrow1\\\"><textarea name=\\\"description\\\" id=\\\"myText\\\" cols=\\\"50\\\" rows=\\\"15\\\" wrap=\\\"virtual\\\" required msg=\\\"Please enter an event description\\\"></textarea></td>\\n\";\n\techo \" </tr>\\n\";\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\">&nbsp;</td>\\n\";\n\techo \" <td class=\\\"trrow1\\\">\";\n\n\t//-------------------------------------------------\n\t// Rich Text Format Buttons\n\t//-------------------------------------------------\n\n\techo \"<table name=\\\"tblForm\\\" border=\\\"0\\\" cellpadding=\\\"0\\\" cellspacing=\\\"0\\\">\\n\";\n\techo \"<tr>\\n\";\n\techo \"<td colspan=\\\"2\\\">&nbsp;\\n\";\n\techo \"<img type=\\\"image\\\" src=\\\"/images/b_off.gif\\\" name=\\\"btnBold\\\" id=\\\"btnBold\\\" onClick=\\\"add_bold_text();\\\" srcover=\\\"/images/b_on.gif\\\" srcdown=\\\"/images/b_down.gif\\\">\\n\";\n\techo \"<img type=\\\"image\\\" src=\\\"/images/i_off.gif\\\" name=\\\"btnItalic\\\" id=\\\"btnItalic\\\" onClick=\\\"add_italic_text();\\\" srcover=\\\"/images/i_on.gif\\\" srcdown=\\\"/images/i_down.gif\\\">\\n\";\n\techo \"<img type=\\\"image\\\" src=\\\"/images/u_off.gif\\\" name=\\\"btnUnderline\\\" id=\\\"btnUnderline\\\" onClick=\\\"add_underline_text();\\\" srcover=\\\"/images/u_on.gif\\\" srcdown=\\\"/images/u_down.gif\\\">\\n\";\n\techo \"<img type=\\\"image\\\" src=\\\"/images/list_off.gif\\\" name=\\\"btnList\\\" id=\\\"btnList\\\" onClick=\\\"add_list_text();\\\" srcover=\\\"/images/list_on.gif\\\" srcdown=\\\"/images/list_down.gif\\\">\\n\";\n\techo \"<img type=\\\"image\\\" src=\\\"/images/url_off.gif\\\" name=\\\"btnUrl\\\" id=\\\"btnUrl\\\" onClick=\\\"add_url_text();\\\" srcover=\\\"/images/url_on.gif\\\" srcdown=\\\"/images/url_down.gif\\\">\\n\";\n\techo \"<img type=\\\"image\\\" src=\\\"/images/img_off.gif\\\" name=\\\"btnImg\\\" id=\\\"btnImg\\\" onClick=\\\"add_img_text();\\\" srcover=\\\"/images/img_on.gif\\\" srcdown=\\\"/images/img_down.gif\\\">\\n\";\n\techo \"</td>\\n\";\n\techo \"</tr>\\n\";\n\techo \"</table>\\n\";\n\n\techo \" </td>\\n\";\n\techo \" </tr>\\n\";\n\n\t//-------------------------------------------------\n\t// get calendar categories\n\t//-------------------------------------------------\n\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\">category</td>\\n\";\n\n\techo \" <td class=\\\"trrow1\\\">\";\n\techo \" <select name=\\\"cat\\\" required msg=\\\"Please select an event category\\\">\\n\";\n\techo \"\t<option value=\\\"\\\">Select Category</option>\\n\";\n\techo \"\t<option value=\\\"\\\">---------------</option>\\n\";\n\tif ($db->Exists(\"SELECT * FROM extcal_categories\")) {\n\t\t$db->Query(\"SELECT * FROM extcal_categories ORDER BY cat_name\");\n\t\tfor ($g=0; $g<$db->rows; $g++) {\n\t\t\t$db->GetRow($g);\n\t\t\techo \" <option value=\\\"\" . $db->data['cat_id'] . \"\\\">\" . $db->data['cat_name'] . \"</option>\\n\";\n\t\t}\n\t}\n\techo \" </select>\\n\";\n\techo \" </td>\\n\";\n\techo \" </tr>\\n\";\n\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\" rowspan=\\\"5\\\">event date</td>\\n\";\n\techo \" </tr>\\n\";\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trbottom\\\">start time</td>\\n\";\n\techo \" </tr>\\n\";\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\">\";\n\n\t//-------------------------------------------------\n\t// do the day drop down\n\t//-------------------------------------------------\n\n\techo \" <select name=\\\"day\\\" required msg=\\\"Please select a day\\\">\\n\";\n\techo \" <option value=\\\"00\\\">Day</option>\\n\";\n\techo \" <option value=\\\"01\\\" >01</option>\\n\";\n\techo \" <option value=\\\"02\\\" >02</option>\\n\";\n\techo \" <option value=\\\"03\\\" >03</option>\\n\";\n\techo \" <option value=\\\"04\\\" >04</option>\\n\";\n\techo \" <option value=\\\"05\\\" >05</option>\\n\";\n\techo \" <option value=\\\"06\\\" >06</option>\\n\";\n\techo \" <option value=\\\"07\\\" >07</option>\\n\";\n\techo \" <option value=\\\"08\\\" >08</option>\\n\";\n\techo \" <option value=\\\"09\\\" >09</option>\\n\";\n\techo \" <option value=\\\"10\\\" >10</option>\\n\";\n\techo \" <option value=\\\"11\\\" >11</option>\\n\";\n\techo \" <option value=\\\"12\\\" >12</option>\\n\";\n\techo \" <option value=\\\"13\\\" >13</option>\\n\";\n\techo \" <option value=\\\"14\\\" >14</option>\\n\";\n\techo \" <option value=\\\"15\\\" >15</option>\\n\";\n\techo \" <option value=\\\"16\\\" >16</option>\\n\";\n\techo \" <option value=\\\"17\\\" >17</option>\\n\";\n\techo \" <option value=\\\"18\\\" >18</option>\\n\";\n\techo \" <option value=\\\"19\\\" >19</option>\\n\";\n\techo \" <option value=\\\"20\\\" >20</option>\\n\";\n\techo \" <option value=\\\"21\\\" >21</option>\\n\";\n\techo \" <option value=\\\"22\\\" >22</option>\\n\";\n\techo \" <option value=\\\"23\\\" >23</option>\\n\";\n\techo \" <option value=\\\"24\\\" >24</option>\\n\";\n\techo \" <option value=\\\"25\\\" >25</option>\\n\";\n\techo \" <option value=\\\"26\\\" >26</option>\\n\";\n\techo \" <option value=\\\"27\\\" >27</option>\\n\";\n\techo \" <option value=\\\"28\\\" >28</option>\\n\";\n\techo \" <option value=\\\"29\\\" >29</option>\\n\";\n\techo \" <option value=\\\"30\\\" >30</option>\\n\";\n\techo \" <option value=\\\"31\\\" >31</option>\\n\";\n\techo \" </select>&nbsp;\\n\";\n\n\t//-------------------------------------------------\n\t// do the month query and drop down\n\t//-------------------------------------------------\n\n\techo \" <select name=\\\"month\\\" required msg=\\\"Please select a month\\\">\\n\";\n\techo \"\t<option value=\\\"\\\">Month</option>\\n\";\n\techo \"\t<option value=\\\"\\\">-----</option>\\n\";\n\tif ($db->Exists(\"SELECT monthid AS themonth, monthnum, abbrev, title AS monthname FROM month\")) {\n\t\t$db->Query(\"SELECT monthid AS themonth, monthnum, abbrev, title AS monthname FROM month ORDER BY monthid\");\n\t\tfor ($g=0; $g<$db->rows; $g++) {\n\t\t\t$db->GetRow($g);\n\t\t\t$mi = $db->data['themonth'];\n\t\t\t$mn = $db->data['monthname'];\n\t\t\t$mu = $db->data['monthnum'];\n\t\t\t$ma = $db->data['abbrev'];\n\t\t\techo \" <option value=\\\"$mu\\\">$mn</option>\\n\";\n\t\t}\n\t}\n\techo \" </select>&nbsp;\\n\";\n\n\t//-------------------------------------------------\n\t// do the year query and drop down\n\t//-------------------------------------------------\n\n\techo \" <select name=\\\"year\\\" required msg=\\\"Please select a year\\\">\\n\";\n\techo \"\t<option value=\\\"\\\">year</option>\\n\";\n\techo \"\t<option value=\\\"\\\">----</option>\\n\";\n\tif ($db->Exists(\"SELECT yearid AS theyear FROM year\")) {\n\t\t$db->Query(\"SELECT yearid AS theyear FROM year ORDER BY yearid\");\n\t\tfor ($g=0; $g<$db->rows; $g++) {\n\t\t\t$db->GetRow($g);\n\t\t\t$ty = $db->data['theyear'];\n\t\t\techo \" <option value=\\\"$ty\\\">$ty</option>\\n\";\n\t\t}\n\t}\n\techo \" </select>&nbsp;<a href=\\\"javascript:void(0)\\\" onclick=\\\"displayCalendarSelectBox(document.forms[0].year,document.forms[0].month,document.forms[0].day,this)\\\"><img src=\\\"/images/popup_calendar.gif\\\" border=\\\"0\\\"></a>&nbsp;\\n\";\n\techo \" at\\n\";\n\n\t//-------------------------------------------------\n\t// do the hour drop down\n\t//-------------------------------------------------\n\n\techo \" <select name=\\\"start_time_hour\\\">\\n\";\n\techo \" <option value=\\\"1\\\" >01</option>\\n\";\n\techo \" <option value=\\\"2\\\" >02</option>\\n\";\n\techo \" <option value=\\\"3\\\" >03</option>\\n\";\n\techo \" <option value=\\\"4\\\" >04</option>\\n\";\n\techo \" <option value=\\\"5\\\" >05</option>\\n\";\n\techo \" <option value=\\\"6\\\" >06</option>\\n\";\n\techo \" <option value=\\\"7\\\" >07</option>\\n\";\n\techo \" <option value=\\\"8\\\" selected>08</option>\\n\";\n\techo \" <option value=\\\"9\\\" >09</option>\\n\";\n\techo \" <option value=\\\"10\\\" >10</option>\\n\";\n\techo \" <option value=\\\"11\\\" >11</option>\\n\";\n\techo \" <option value=\\\"12\\\" >12</option>\\n\";\n\techo \" </select>\\n\";\n\n\t//-------------------------------------------------\n\t// do the minutes drop down\n\t//-------------------------------------------------\n\n\techo \" <select name=\\\"start_time_minute\\\">\\n\";\n\techo \" <option value=\\\"0\\\" selected>00</option>\\n\";\n\techo \" <option value=\\\"15\\\" >15</option>\\n\";\n\techo \" <option value=\\\"30\\\" >30</option>\\n\";\n\techo \" <option value=\\\"45\\\" >45</option>\\n\";\n\techo \" </select>\\n\";\n\n\t//-------------------------------------------------\n\t// do the AM v PM drop down\n\t//-------------------------------------------------\n\n\techo \" <select name=\\\"start_time_ampm\\\" class=\\\"listbox\\\">\\n\";\n\techo \" <option value=\\\"am\\\" selected>AM</option>\\n\";\n\techo \" <option value=\\\"pm\\\" >PM</option>\\n\";\n\techo \" </select>\\n\";\n\n\techo \" </td>\\n\";\n\techo \" </tr>\\n\";\n\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trbottom\\\">duration</td>\\n\";\n\techo \" </tr>\\n\";\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\">\";\n\techo \" <input type=\\\"text\\\" name=\\\"end_days\\\" class=\\\"textinput\\\" value=\\\"0\\\" size=\\\"3\\\">&nbsp;Days&nbsp;&nbsp;\\n\";\n\techo \" <input type=\\\"text\\\" name=\\\"end_hours\\\" class=\\\"textinput\\\" value=\\\"1\\\" size=\\\"3\\\">&nbsp;Hours&nbsp;&nbsp;\\n\";\n\techo \" <input type=\\\"text\\\" name=\\\"end_minutes\\\" class=\\\"textinput\\\" value=\\\"0\\\" size=\\\"3\\\">&nbsp;Minutes&nbsp;&nbsp;\\n\";\n\techo \" </td>\\n\";\n\techo \" </tr>\\n\";\n\techo \"</table>\\n\";\n\techo \" </td>\\n\";\n\techo \" </tr>\\n\";\n\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"whitemain\\\" bgcolor=\\\"$bluebdr\\\" height=\\\"23\\\">&nbsp;Contact Details</td>\\n\";\n\techo \" </tr>\\n\";\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\">\\n\";\n\n\techo \"<table width=\\\"100%\\\" cellspacing=\\\"1\\\" cellpadding=\\\"3\\\" border=\\\"1\\\" align=\\\"left\\\">\\n\";\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\">contact info</td>\\n\";\n\techo \" <td class=\\\"trrow1\\\"><textarea name=\\\"contact\\\" cols=\\\"50\\\" rows=\\\"15\\\" wrap=\\\"virtual\\\"></textarea></td>\\n\";\n\techo \" </tr>\\n\";\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\">email</td>\\n\";\n\techo \" <td class=\\\"trrow1\\\"><input type=\\\"text\\\" name=\\\"email\\\" size=\\\"35\\\" maxlength=\\\"255\\\"></td>\\n\";\n\techo \" </tr>\\n\";\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\">url</td>\\n\";\n\techo \" <td class=\\\"trrow1\\\"><input type=\\\"text\\\" name=\\\"url\\\" size=\\\"35\\\" maxlength=\\\"255\\\"></td>\\n\";\n\techo \" </tr>\\n\";\n\n\techo \" <tr>\\n\";\n\techo \" <td class=\\\"trrow1\\\" colspan=\\\"2\\\" align=\\\"center\\\"><input type=\\\"submit\\\" value=\\\"add event\\\"> &nbsp; <input type=\\\"reset\\\" value=\\\"reset form\\\"></td>\\n\";\n\techo \" </tr>\\n\";\n\techo \"</table>\\n\";\n\n\techo \"</form>\\n\";\n\techo \"<script src=\\\"/includes/javascript/validation.js\\\" language=\\\"JScript\\\"></SCRIPT>\\n\";\n\n\techo \" </td>\\n\";\n\techo \"</tr>\\n\";\n\techo \"</table>\\n\";\n}", "title": "" }, { "docid": "4b5c13a25eb28fa07ddd76031ef32b9c", "score": "0.48997992", "text": "function convert(){\n\n\t\tif (!JEVHelper::isAdminUser()){\n\t\t\t$this->setRedirect( \"index.php?option=\".JEV_COM_COMPONENT.\"&task=cpanel.cpanel\", JText::_( 'NOT_AUTHORISED_MUST_BE_ADMIN' ));\n\t\t\treturn;\n\t\t}\n\n\t\t$cfg = & JEVConfig::getInstance();\n\t\t$option = JEV_COM_COMPONENT;\n\t\t$db\t=& JFactory::getDBO();\n\n\t\tJLoader::register('vCal',JEV_PATH.\"/libraries/vCal.php\");\n\n\t\t$sql = \"SHOW COLUMNS FROM #__events_categories\";\n\t\t$db->setQuery( $sql );\n\t\t$cols = $db->loadObjectList();\n\t\tif (is_null($cols) ){\n\t\t\t$this->setRedirect(JRoute::_(\"index.php?option=\".JEV_COM_COMPONENT.\"&task=cpanel.show\",false),JText::_( 'OLD_JEVENTS_CATEGORY_TABLE_MISSING' ));\n\t\t\t$this->redirect();\n\t\t}\n\t\t$uptodate = false;\n\t\tforeach ($cols as $col) {\n\t\t\tif ($col->Field==\"migrated\"){\n\t\t\t\t$uptodate = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\tif (!$uptodate){\n\t\t\t$sql = \"ALTER TABLE #__events_categories ADD migrated tinyint(3) NOT NULL default 0\";\n\t\t\t$db->setQuery( $sql );\n\t\t\t@$db->query();\n\n\t\t\t$sql = \"ALTER TABLE #__events_categories ADD newid int(12) NOT NULL default 0\";\n\t\t\t$db->setQuery( $sql );\n\t\t\t@$db->query();\n\n\t\t}\n\n\t\t$sql = \"SHOW COLUMNS FROM #__events\";\n\t\t$db->setQuery( $sql );\n\t\t$cols = $db->loadObjectList();\n\t\tif (is_null($cols) ){\n\t\t\t$this->setRedirect(JRoute::_(\"index.php?option=\".JEV_COM_COMPONENT.\"&task=cpanel.show\",false),JText::_( 'OLD_JEVENTS_EVENTS_TABLE_MISSING' ));\n\t\t\t$this->redirect();\n\t\t}\n\t\t$uptodate = false;\n\t\tforeach ($cols as $col) {\n\t\t\tif ($col->Field==\"migrated\"){\n\t\t\t\t$uptodate = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\tif (!$uptodate){\n\t\t\t$sql = \"ALTER TABLE #__events ADD migrated tinyint(3) NOT NULL default 0\";\n\t\t\t$db->setQuery( $sql );\n\t\t\t@$db->query();\n\t\t}\n\n\t\t// Check to see if a fresh migration\n\t\tif (!JRequest::getInt(\"ongoing\",0)){\n\t\t\t$sql = \"UPDATE #__events_categories set migrated=0\";\n\t\t\t$db->setQuery( $sql );\n\t\t\t@$db->query();\n\n\t\t\t$sql = \"UPDATE #__events set migrated=0\";\n\t\t\t$db->setQuery( $sql );\n\t\t\t@$db->query();\n\t\t}\n\n\t\t/**\n\t\t * find the categories first\n\t\t */\t\t\n\t\t$query = \"SELECT cc.*, ec.color FROM #__categories AS cc LEFT JOIN #__events_categories AS ec ON ec.id=cc.id WHERE cc.section='com_events' and ec.migrated=0\";\n\t\t$db->setQuery( $query );\n\t\t$cats = $db->loadObjectList('id');\n\n\t\tif (count($cats)>0){\n\t\t\t// Create new categories with section com_jevents\"\n\t\t\tJLoader::register('JEventsCategory',JEV_ADMINPATH.\"/libraries/categoryClass.php\");\n\n\t\t\t$query = \"SELECT cc.*, ec.color FROM #__categories AS cc LEFT JOIN #__jevents_categories AS ec ON ec.id=cc.id WHERE cc.section='com_jevents'\";\n\t\t\t$db->setQuery( $query );\n\t\t\t$rows = $db->loadObjectList('id');\n\t\t\t$jcats = array();\n\t\t\tforeach ($rows as $jcat) {\n\t\t\t\t$newcat = new JEventsCategory($db);\n\t\t\t\t$newcat->bind(get_object_vars($jcat));\n\t\t\t\t$jcats[$jcat->id]=$newcat;\n\t\t\t}\n\n\t\t\tforeach ($cats as $cat) {\n\t\t\t\t// check not already mapped\n\t\t\t\t$mapped = false;\n\t\t\t\tforeach ($jcats as $jcat) {\n\t\t\t\t\tif ($jcat->alias==$cat->alias && $jcat->description==$cat->description && $jcat->title==$cat->title){\n\t\t\t\t\t\t$cat->newid = $jcat->id;\n\t\t\t\t\t\t$mapped=true;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (!$mapped){\n\t\t\t\t\t$newcat = new JEventsCategory($db);\n\t\t\t\t\t$newcat->bind(get_object_vars($cat));\n\t\t\t\t\t$newcat->id=null;\n\t\t\t\t\t$newcat->store();\n\t\t\t\t\t$cat->newid = $newcat->id;\n\n\t\t\t\t\t$query = \"UPDATE #__events_categories set migrated=1, newid=\".$cat->newid.\" WHERE id=\".$cat->id;\n\t\t\t\t\t$db->setQuery( $query );\n\t\t\t\t\t$db->query();\n\n\t\t\t\t\t$jcats[$newcat->id] = $newcat;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// make sure parent field is correct\n\t\t\tforeach ($jcats as $key => $jcat) {\n\t\t\t\tif ($jcat->parent_id>0 && array_key_exists($jcat->parent_id,$cats)){\n\t\t\t\t\t$jcat->parent_id = $cats[$jcat->parent_id]->newid;\n\t\t\t\t\t$jcat->store();\n\n\t\t\t\t\t$jcats[$key]=$jcat;\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\n\t\t$query = \"SELECT cc.*, ec.color, ec.newid FROM #__categories AS cc LEFT JOIN #__events_categories AS ec ON ec.id=cc.id WHERE cc.section='com_events'\";\n\t\t$db->setQuery( $query );\n\t\t$cats = $db->loadObjectList('id');\n\n\t\t$remainingevents = 0;\n\t\tob_start();\n\t\tforeach ($cats as $cat) {\n\t\t\t// Break this into blocks of 20 events - in case of memory problems\n\t\t\t$remainingevents += $this->processCat($cat);\n\t\t}\n\t\tob_end_clean();\n\n\t\t// get the view\n\t\t$this->view = & $this->getView(\"config\",\"html\");\n\n\t\t// Set the layout\n\t\t$this->view->setLayout('convert');\n\t\t$this->view->assign(\"remaining\",$remainingevents);\n\t\t$this->view->display();\n\n\t\t//$this->setRedirect( \"index.php?option=\".JEV_COM_COMPONENT.\"&task=cpanel.cpanel\", \"Events Migrated\");\n\n\t}", "title": "" }, { "docid": "2a292859ef8547d18b53746d8f1c10e5", "score": "0.4898837", "text": "abstract protected function getEvents();", "title": "" }, { "docid": "867ef0b3153c41c367c3bd020b45a534", "score": "0.489762", "text": "public function addnewCategory(){\t\n\t \n\t $message_alert='';\n\t \n\t $id_lang=(int)Context::getContext()->language->id; \n\t \n if(Tools::isSubmit('submitAddnewCategory')){ \t \n\t\t\n $QuizCat =new Filter();\n \n\t\t$QuizCat->category_name=Tools::getValue('category_name');\n\t\t$Quiz_chiffre=$QuizCat->category_name;\n\t\t\n\t\tif(Filter::verifyByName($Quiz_chiffre) !=''){\n $message_alert='Please remember duplicated Categories name are not allowed.';\n }\t\n\t\t\n elseif(!$QuizCat->add()){$messaege_alert=\"An error has occurred: Can\\'t save the current object\";\t}\n else{\n \t\t\t\n\t\t//$sql= 'UPDATE`'._DB_PREFIX_.'dynamic_banner` SET `banner_img`=\\''.pSQL($image_url).'\\' \n\t\t //WHERE `id_banner`='.$QuizCat->id; \n // Db::getInstance()->execute($sql); \n $message_alert=\"Your Category has been successfully added.\";\t\n\t\t\n\t\t\n\t\t}\t\n\t\t\n }\n\t return $message_alert;\n\t \n\t \n }", "title": "" }, { "docid": "5a60732902aa9c82f07499f65ab21331", "score": "0.48972377", "text": "function wpachievements_wcpar_description( $event_description, $event_type, $event ) {\n switch ( $event_type ) {\n case 'wpachievements_achievement': $event_description = sprintf( __( '%s earned for getting the achievement: %s', WPACHIEVEMENTS_TEXT_DOMAIN ), $event->points, $event->data['achievement_id'] ); break;\n case 'wpachievements_achievement_added': $event_description = sprintf( __( '%s earned for admin adding the achievement: %s', WPACHIEVEMENTS_TEXT_DOMAIN ), $event->points, $event->data['achievement_id'] ); break;\n case 'wpachievements_achievement_removed': $event_description = sprintf( __( '%s removed by admin removing the achievement: %s', WPACHIEVEMENTS_TEXT_DOMAIN ), $event->points, $event->data['achievement_id'] ); break;\n case 'wpachievements_achievement_edited_add': $event_description = sprintf( __( '%s earned because an achievements points have been increased.', WPACHIEVEMENTS_TEXT_DOMAIN ), $event->points ); break;\n case 'wpachievements_achievement_edited_remove': $event_description = sprintf( __( '%s earned because an achievements points have been decreased.', WPACHIEVEMENTS_TEXT_DOMAIN ), $event->points ); break;\n\n\n case 'wpachievements_quest': $event_description = sprintf( __( '%s earned for getting the quest: %s', WPACHIEVEMENTS_TEXT_DOMAIN ), $event->points, $event->data['achievement_id'] ); break;\n case 'wpachievements_quest_added': $event_description = sprintf( __( '%s earned for admin adding the quest: %s', WPACHIEVEMENTS_TEXT_DOMAIN ), $event->points, $event->data['achievement_id'] ); break;\n case 'wpachievements_quest_removed': $event_description = sprintf( __( '%s removed by admin removing the quest: %s', WPACHIEVEMENTS_TEXT_DOMAIN ), $event->points, $event->data['achievement_id'] ); break;\n case 'wpachievements_quest_edited_add': $event_description = sprintf( __( '%s earned because an quest points have been increased.', WPACHIEVEMENTS_TEXT_DOMAIN ), $event->points ); break;\n case 'wpachievements_quest_edited_remove': $event_description = sprintf( __( '%s earned because an quest points have been decreased.', WPACHIEVEMENTS_TEXT_DOMAIN ), $event->points ); break;\n }\n return $event_description;\n }", "title": "" }, { "docid": "185cd9148fabe3a8304247023d4738b1", "score": "0.48907673", "text": "public function getMessages() : mixed;", "title": "" }, { "docid": "485fa0849f4417c69a741c271e8923a6", "score": "0.48695317", "text": "public function add_business($msg='',$msg_class='',$user_id='')\n{\n$this->error_validation_session_check();\nif(!empty($msg))\n{\n$msgsection['user_id'] = $user_id;\n$msgsection['msg'] = $msg;\n$msgsection['msgclass'] = $msg_class;\n}\n$msgsection['category'] = $this->urs->getFullUserDetails(CATEGORY,'event','category_type');\n$msgsection['country'] = $this->urs->getCountryDetails(COUNTRY,'country_id');\n$msgsection['timezone'] = $this->urs->getFieldDetails(TIMEZONE);\n$msgsection['all_meetup'] = $this->get_meet_up_data();\n$this->load->view('dashboard/add-business',$msgsection);\n}", "title": "" }, { "docid": "dba6ea9b3a41d93a85cfef32d3ce7d55", "score": "0.48666298", "text": "public function getEventCategoryForAdd() {\n $iCategory = $this->_oApi->get('category_id', null);\n\n $aCategories = Phpfox::getService('accountapi.event')->getCategories($iCategory);\n\n return array(\n 'children' => (!empty($iCategory) ? true : false),\n 'category' => $aCategories);\n }", "title": "" }, { "docid": "570bfe650b6b59f7adfdb8ad09638195", "score": "0.48657736", "text": "function wct_get_feedback_messages( $type = '', $id = false ) {\n\t$messages = apply_filters( 'wct_get_feedback_messages', array(\n\t\t'success' => array(\n\t\t\t1 => __( 'Saved successfully', 'wordcamp-talks' ),\n\t\t\t2 => __( 'Registration complete. Please check your mailbox.', 'wordcamp-talks' ),\n\t\t\t3 => __( 'The talk was successfully created.', 'wordcamp-talks' ),\n\t\t\t4 => __( 'The talk was successfully updated.', 'wordcamp-talks' ),\n\t\t\t5 => __( 'For your convenience, you have been automagically logged in.', 'wordcamp-talks' ),\n\t\t\t6 => __( 'Make sure to check you received the email we sent you to reset your password.', 'wordcamp-talks' ),\n\t\t\t7 => __( 'Otherwise, edit your email and password from your profile before logging off the site.', 'wordcamp-talks' ),\n\t\t),\n\t\t'error' => array(\n\t\t\t1 => __( 'Something went wrong, please try again', 'wordcamp-talks' ),\n\t\t\t2 => __( 'You are not allowed to edit this talk.', 'wordcamp-talks' ),\n\t\t\t3 => __( 'You are not allowed to publish talks', 'wordcamp-talks' ),\n\t\t\t4 => __( 'Title and description are required fields.', 'wordcamp-talks' ),\n\t\t\t5 => __( 'Something went wrong while trying to save your talk.', 'wordcamp-talks' ),\n\t\t\t7 => __( 'Please choose a username having at least 4 characters.', 'wordcamp-talks' ),\n\t\t\t8 => __( 'Please fill all required fields.', 'wordcamp-talks' ),\n\t\t\t9 => __( 'The talk you are trying to edit does not seem to exist.', 'wordcamp-talks' ),\n\t\t\t10 => __( 'Something went wrong while trying to update your talk.', 'wordcamp-talks' ),\n\t\t),\n\t\t'info' => array(\n\t\t\t1 => __( 'This talk is already being edited by another user.', 'wordcamp-talks' ),\n\t\t\t2 => __( 'Your talk is currently awaiting moderation.', 'wordcamp-talks' ),\n\t\t\t3 => __( 'This user has not filled any public profile informations.', 'wordcamp-talks' ),\n\t\t\t4 => __( 'You have not filled any public profile informations. You can edit your profile to add some.', 'wordcamp-talks' ),\n\t\t),\n\t) );\n\n\t// Check for a custom pending message\n\t$custom_pending_message = wct_moderation_message();\n\tif ( ! empty( $custom_pending_message ) ) {\n\t\t$messages['info'][2] = $custom_pending_message;\n\t}\n\n\tif ( empty( $type ) ) {\n\t\treturn $messages;\n\t}\n\n\tif ( ! is_array( $type ) && isset( $messages[ $type ] ) ) {\n\t\t$messages = $messages[ $type ];\n\n\t\tif ( false === $id || ! isset( $messages[ $type ][ $id ] ) ) {\n\t\t\treturn $messages;\n\t\t}\n\n\t\treturn $messages[ $type ][ $id ];\n\t}\n\n\tforeach ( $type as $kt => $kv ) {\n\t\t$message_ids = array_filter( wp_parse_id_list( $kv ) );\n\n\t\t// If we have ids, get the corresponding messages.\n\t\tif ( $message_ids ) {\n\t\t\t$type[ $kt ] = array_intersect_key( $messages[ $kt ], array_flip( $message_ids ) );\n\t\t}\n\t}\n\n\treturn $type;\n}", "title": "" }, { "docid": "898718cb7764c6cf7736d76ada3bca37", "score": "0.4860916", "text": "function create_message_for_entity($to_entity, $from_entity, $type, $action_type, $entity, $annotation=NULL){\n\tif($entity->getSubtype()=='thewire'){\n\t\t$tags = live_notifications_tag_user($entity->description, $entity, $from_entity);\n\t\tif($entity->wire_thread != $entity->guid){\n\t\t\t$url_user = elgg_view('output/url', array(\n\t\t\t\t\t\t'href' => $from_entity->getURL(),\n\t\t\t\t\t\t'text' => $from_entity->name,\n\t\t\t\t\t\t'class' => 'elgg-river-subject',\n\t\t\t\t\t));\n\t\t\t$thread = get_entity($entity->wire_thread);\n\n\t\t\tif($thread->owner_guid!=$from_entity->guid && !in_array($thread->owner_guid, $tags)){\n\t\t\t\t$description = elgg_echo('live_notifications:thewire:reply', array($url_user, elgg_get_site_url().'thewire/thread/'.$thread->guid));\t\t\n\t\t\t\t$description .= '<br/><i>'.elgg_get_excerpt($entity->description,60).'</i>';\n\t\t\t\tadd_new_notification($thread->owner_guid, $from_entity->guid, 'thewire', $entity->guid, $description);\t\n\t\t\t}\n\t\t}\t\t\n\t}\n\n\t$container = get_entity($entity->container_guid);\n\n\tif(elgg_instanceof($container, 'group')){\n\n\t\tif($action_type=='create'){\n\t\t\t$url_user = elgg_view('output/url', array(\n\t\t\t\t\t'href' => $from_entity->getURL(),\n\t\t\t\t\t'text' => $from_entity->name,\n\t\t\t\t\t'class' => 'elgg-river-subject',\n\t\t\t\t)); \n\t\t\t$url_group = elgg_view('output/url', array(\n\t\t\t\t\t'href' => $container->getURL(),\n\t\t\t\t\t'text' => $container->name,\n\t\t\t\t\t'class' => 'elgg-river-subject',\n\t\t\t\t));\n\t\t\t$description = elgg_echo('live_notifications:group:create:'.$type, array($url_user, $url_group));\n\t\t\t$description .= '<a href=\"'.$entity->getUrl().'\" title=\"\">'.$entity->title.'</a>';\n\n\t\t\t$members = $container->getMembers();\n\t\t\tforeach ($members as $member) {\n\t\t\t\t# Notify to all members\n\t\t\t\tif($from_entity->guid!=$member->guid){\n\t\t\t\t\tadd_new_notification($member->guid, $from_entity->guid, $type, $entity->guid, $description);\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "title": "" }, { "docid": "aa41964406c7b9a9fc04813148bc0bd3", "score": "0.48601413", "text": "public function c_event_list($logged_user) {\n $pastsevents = $this->organisateurs->m_listPastsEvents($logged_user);\n//recup liste evenements futurs\n $futursevents = $this->organisateurs->m_listFutursEvents($logged_user);\n $this->loader->load('createOrChgeEvent', ['title'=>\"Création ou modification d'un événement\",\n 'pastsevents'=>$pastsevents,\n 'futursevents'=>$futursevents]);\n }", "title": "" }, { "docid": "abfbb5844f8758f31fc56b80c2884aac", "score": "0.48531377", "text": "public function AddTimelineEventsForCategory(Request $request, string $category)\n {\n $survey_id = session('survey_id');\n $survey = Survey::find($survey_id);\n $eventCategory = EventCategory::where('category', $category)->first();\n\n // Clear out any previously set Timeline events for this category\n $this->ClearTimelineEvents($survey, $eventCategory);\n\n // Get all life LifeEvents for this category\n $timelineEvents = $survey->life_events()\n ->where('event_category_id', $eventCategory->id)\n ->where('timeline', true)\n ->orderBy('id')\n ->get();\n\n foreach ($timelineEvents as $timelineEvent)\n {\n $newTimelineEvent = new TimelineEvent;\n $newTimelineEvent->survey_id = $survey_id;\n $newTimelineEvent->life_event_id = $timelineEvent->id;\n $newTimelineEvent->timeframe = $request->input('timeframe_' . $timelineEvent->id);\n $newTimelineEvent->age = $request->input('age_' . $timelineEvent->id);\n $newTimelineEvent->range_from = $request->input('range_from_' . $timelineEvent->id);\n $newTimelineEvent->range_to = $request->input('range_to_' . $timelineEvent->id);\n $newTimelineEvent->save();\n }\n }", "title": "" }, { "docid": "901e9fe91a7c712c8c98f945e6d55285", "score": "0.48519778", "text": "private function manageCategories()\n {\n global $objDatabase, $_ARRAYLANG;\n\n $this->_objTpl->loadTemplateFile('module_news_category.html', true, true);\n $this->pageTitle = $_ARRAYLANG['TXT_CATEGORY_MANAGER'];\n\n $this->_objTpl->setVariable(array(\n 'TXT_ADD_NEW_CATEGORY' => $_ARRAYLANG['TXT_ADD_NEW_CATEGORY'],\n 'TXT_NEWS_NEW_CATEGORY' => $_ARRAYLANG['TXT_NEWS_NEW_CATEGORY'],\n 'TXT_NAME' => $_ARRAYLANG['TXT_NAME'],\n 'TXT_ADD' => $_ARRAYLANG['TXT_ADD'],\n 'TXT_CATEGORY_LIST' => $_ARRAYLANG['TXT_CATEGORY_LIST'],\n 'TXT_ID' => $_ARRAYLANG['TXT_ID'],\n 'TXT_NEWS_CATEGORY_ORDER' => $_ARRAYLANG['TXT_NEWS_CATEGORY_ORDER'],\n 'TXT_ACTION' => $_ARRAYLANG['TXT_ACTION'],\n 'TXT_ACCEPT_CHANGES' => $_ARRAYLANG['TXT_ACCEPT_CHANGES'],\n 'TXT_CONFIRM_DELETE_WITH_SUBENTRIES' => $_ARRAYLANG['TXT_CONFIRM_DELETE_WITH_SUBENTRIES'],\n 'TXT_ACTION_IS_IRREVERSIBLE' => $_ARRAYLANG['TXT_ACTION_IS_IRREVERSIBLE'],\n 'TXT_ATTENTION_SYSTEM_FUNCTIONALITY_AT_RISK' => $_ARRAYLANG['TXT_ATTENTION_SYSTEM_FUNCTIONALITY_AT_RISK'],\n ));\n\n $this->_objTpl->setGlobalVariable(array(\n 'TXT_SAVE' => $_ARRAYLANG['TXT_SAVE'],\n 'TXT_EDIT' => $_ARRAYLANG['TXT_EDIT'],\n 'TXT_DELETE' => $_ARRAYLANG['TXT_DELETE'],\n 'TXT_NEWS_EXTENDED' => $_ARRAYLANG['TXT_NEWS_EXTENDED'],\n ));\n\n // Add a new category\n if (isset($_POST['addCat']) && ($_POST['addCat']==true)) {\n $catName = contrexx_input2db(trim($_POST['newCategorieName']));\n $catParentId = !empty($_POST['newCategorieParentId']) ? intval($_POST['newCategorieParentId']) : $this->nestedSetRootId;\n\n if (empty($catName)) {\n $this->strErrMessage = $_ARRAYLANG['TXT_NEWS_CATEGORY_ADD_ERROR_EMPTY'];\n } else {\n $status = true;\n\n // set new auto increment for sequence table for nested set\n // if you find another way that the sequence table does not update ID while moving node, so change this code\n $objResult = $objDatabase->SelectLimit(\"SELECT MAX(`catid`) AS `maxId` FROM `\".DBPREFIX.\"module_news_categories`\", 1);\n if ($objResult !== false) {\n $objResult2 = $objDatabase->Execute(\"SELECT `id` FROM `\" . DBPREFIX . \"module_news_categories_catid`\");\n if ($objResult2 !== false && $objResult2->fields['id'] > $objResult->fields['maxId']) {\n $objDatabase->Execute(\"UPDATE `\" . DBPREFIX . \"module_news_categories_catid` SET `id` = '\" . contrexx_raw2db($objResult->fields['maxId']) . \"'\");\n }\n }\n\n if (!$catId = $this->objNestedSet->createSubNode($catParentId, array())) {\n $status = false;\n } else {\n if ($objDatabase->Execute('INSERT INTO `'.DBPREFIX.'module_news_categories_locale` (`lang_id`, `category_id`, `name`)\n SELECT `id`, \"'.$catId.'\", \"'.$catName.'\" FROM `'.DBPREFIX.'languages`') === false) {\n $status = false;\n }\n }\n\n if ($status) {\n $this->strOkMessage = $_ARRAYLANG['TXT_DATA_RECORD_ADDED_SUCCESSFUL'];\n } else {\n $this->strErrMessage = $_ARRAYLANG['TXT_DATABASE_QUERY_ERROR'];\n }\n }\n }\n\n // Change sorting\n if (is_array($_POST['newsCatSorting']) && !empty($_POST['newsCatSorting'])) {\n $newSorting = $_POST['newsCatSorting'];\n asort($newSorting);\n foreach($newSorting as $catId => $catSort) {\n $this->objNestedSet->moveTree($catId, $this->objNestedSet->getParent($catId)->id, NESE_MOVE_BELOW);\n }\n \\Message::ok($_ARRAYLANG['TXT_DATA_RECORD_UPDATED_SUCCESSFUL']);\n }\n\n // List all categories\n $arrCatLangData = $this->getCategoriesLangData();\n $firstLevel = 2;\n $levelSpacingLeft = 20;\n\n $i = 0;\n if (count($nodes = $this->objNestedSet->getSubBranch($this->nestedSetRootId, true)) > 0) {\n $nodes = $this->sortNestedSetArray($nodes);\n foreach ($nodes as $node) {\n $level = $node['level']-$firstLevel;\n $cssStyle = (($i++ % 2) == 0) ? 'row2' : 'row1';\n $sort = ($node['level'] == 2) ? $node['norder'] - 1 : $node['norder']; // don't count the root node\n\n if (count($this->objNestedSet->getParents($node['id'])) > 1) {\n $this->_objTpl->touchBlock('categoryHasParent');\n } else {\n $this->_objTpl->hideBlock('categoryHasParent');\n }\n\n $this->_objTpl->setVariable(array(\n 'NEWS_ROWCLASS' => $cssStyle,\n 'NEWS_CAT_ID' => $node['id'],\n 'NEWS_LEVEL_SPACING' => $level*$levelSpacingLeft,\n 'NEWS_CAT_NAME' => contrexx_raw2xhtml($arrCatLangData[$node['id']][\\FWLanguage::getDefaultLangId()]),\n 'NEWS_CAT_SORT' => $sort,\n ));\n $this->_objTpl->parse('newsRow');\n };\n }\n\n $this->_objTpl->setVariable(array(\n 'NEWS_CATEGORIES' => $this->getCategoryMenu(array()),\n ));\n }", "title": "" }, { "docid": "c093d0a373f7a22abb33b370bff0d367", "score": "0.48518986", "text": "public function messages(): array;", "title": "" }, { "docid": "c093d0a373f7a22abb33b370bff0d367", "score": "0.48518986", "text": "public function messages(): array;", "title": "" }, { "docid": "6bb223f6654c0d39b1688d11e23868bf", "score": "0.48516458", "text": "abstract public function events();", "title": "" }, { "docid": "a11034063d3031a54ab6208dfe6e6362", "score": "0.4848034", "text": "public function message()\n {\n return 'Category is not valid';\n }", "title": "" }, { "docid": "904c408a59d65dc4fff575b5d45637b3", "score": "0.48476112", "text": "function eventclass_testmail()\n\t{\n\t\t$this->events[\"BeforeMoveNextList\"]=true;\n\n\t\t$this->events[\"AfterAdd\"]=true;\n\n\t\t$this->events[\"AfterEdit\"]=true;\n\n\n//\tonscreen events\n\n\t}", "title": "" }, { "docid": "ad8f253fb663d47e2ed190583e835c72", "score": "0.4846362", "text": "function t($message, $category = TextCategories::LABEL, $params = array(), $source = null, $language = null)\n{\n return Yii::t($category, $message, $params, $source, $language);\n}", "title": "" } ]
2ff3358e12af1f1dd720d2cf56a5a3d8
overwritten function to apply password
[ { "docid": "e26612ddcf1522618b8e796f60ff8179", "score": "0.0", "text": "public function store()\n {\n if (config('bap.demo')) {\n flash(trans('core::core.you_cant_do_that_its_demo'))->error();\n return redirect()->back();\n }\n $request = \\App::make($this->storeRequest ?? Request::class);\n\n $input = $request->all();\n\n $randomPassword = UserHelper::randomPassword(6);\n\n $input['password'] = bcrypt($randomPassword);\n\n $entity = \\App::make($this->repository)->create($input);\n\n if (is_null($request->get('roles'))) {\n $entity->syncRoles([]);\n } else {\n $entity->syncRoles($request->get('roles'));\n }\n\n flash(trans($this->languageFile . '.created', ['password'=>$randomPassword]))->success();\n\n return redirect(route($this->routes['index']));\n }", "title": "" } ]
[ { "docid": "10aa5b977c51aade906dbd29282f4733", "score": "0.77064675", "text": "public function addPasswordVerify();", "title": "" }, { "docid": "10aa5b977c51aade906dbd29282f4733", "score": "0.77064675", "text": "public function addPasswordVerify();", "title": "" }, { "docid": "80d821092f57a628a24582ea959da015", "score": "0.7663856", "text": "public function authPassword();", "title": "" }, { "docid": "a23e5f91b8a2c69cf2ce80ea20e1fe86", "score": "0.75983346", "text": "public function getPassword();", "title": "" }, { "docid": "a23e5f91b8a2c69cf2ce80ea20e1fe86", "score": "0.75983346", "text": "public function getPassword();", "title": "" }, { "docid": "b29cbfcd73c4337c6b391db16772178c", "score": "0.7460597", "text": "function funcPassword() {\n\t\tglobal $num_words, $use_delim, $use_caps, $use_num, $use_sym, $use_alphanum;\n\t\tglobal $array_words;\n\t\t$array_symbols = array(\"!\", \"@\", \"#\",\"$\", \"%\", \"&\");\n\t\t$array_alphanum = array(\"a\"=>\"4\", \"e\"=>\"3\", \"l\"=>\"1\", \"o\"=>\"0\", \"s\"=>\"5\");\n\t\t$gen_password = \"\";\n\t\t$last_count = count($array_words)-1;\n\t\tfor($i=1;$i<=$num_words;$i++) {\n\t\t\t$current_word = $array_words[rand(0,$last_count)];\n\t\t\tif ($use_delim == \"camel\") {\n\t\t\t\t$current_word = ucfirst($current_word);\n\t\t\t} else if ($i != $num_words) {\n\t\t\t\t$current_word .= $use_delim;\n\t\t\t}\n\t\t\t$gen_password .= $current_word;\n\t\t}\n\t\tif ($use_caps == \"initial\") {\n\t\t\t$gen_password = ucfirst($gen_password);\n\t\t} else if ($use_caps == \"all\") {\n\t\t\t$gen_password = strtoupper($gen_password);\n\t\t} else if ($use_caps == \"word\") {\n\t\t\tif ($use_delim == \" \"){\n\t\t\t\t$gen_password = ucwords($gen_password);\n\t\t\t} else if ($use_delim != \"camel\") {\n\t\t\t\t$gen_password = str_replace(\" \", $use_delim , ucwords(str_replace($use_delim , \" \" , $gen_password)));\n\t\t\t}\n\t\t}\n\t\tif ($use_num==\"use_num\") {\n\t\t\tif ($use_delim != \"camel\") {\n\t\t\t\t$gen_password .= $use_delim;\n\t\t\t}\n\t\t\t$gen_password .= rand(0,9);\n\t\t}\n\t\tif ($use_sym==\"use_sym\") {\n\t\t\t$gen_password .= $array_symbols[rand(0,5)];\n\t\t}\n\t\tif ($use_alphanum==\"use_alphanum\") {\n\t\t\tforeach ($array_alphanum as $letter => $number){\n\t\t\t\t$gen_password = str_replace($letter , $number , $gen_password);\n\t\t\t\t$gen_password = str_replace(strtoupper($letter) , $number , $gen_password);\n\t\t\t}\n\t\t}\n\t\treturn $gen_password;\n\t}", "title": "" }, { "docid": "8ad190536899e873db0ea462b83e9b84", "score": "0.7411107", "text": "public function passwordAction() {\n\n\t}", "title": "" }, { "docid": "8833e0e331ff69cfe0b069e0c6f49842", "score": "0.7395787", "text": "abstract protected function doPwd();", "title": "" }, { "docid": "65f16c2fff24396abcee8b51036fd235", "score": "0.73648256", "text": "public function getPassword()\n {\n }", "title": "" }, { "docid": "680f1a61daff9a507ad145cf69ce1f13", "score": "0.729822", "text": "public static function passwordProcess()\n {\n return true;\n }", "title": "" }, { "docid": "057033f2c4ed0e372994987058371c4d", "score": "0.7271849", "text": "public function getOneTimePassword();", "title": "" }, { "docid": "38d14bf217f342e1150ecbc50c698974", "score": "0.72700024", "text": "public function getPassword(): string;", "title": "" }, { "docid": "fb5666fe1cccc1b6bde207542a277501", "score": "0.72319627", "text": "public function password($name = null);", "title": "" }, { "docid": "d4ca19b31a324120153eafc941ef5af5", "score": "0.71845835", "text": "public function p_password() {\n\t\tforeach($_POST as $field => $value) {\n\t\t\tif(empty($value)) {\n\t\t\t\tdie(Router::redirect('/users/pwdchange/blank-field'));\n\t\t\t}\n\t\t}\n\n\t\t//encode posted password\n\t\t$_POST['password'] = sha1(PASSWORD_SALT.$_POST['password']);\n\n\t\t//generate query to match password and email\n\t\t$q = \n\t\t\t'SELECT password\n\t\t\tFROM users\n\t\t\tWHERE email = \"'.$_POST['email'].'\"\n\t\t\tAND password = \"'.$_POST['password'].'\"';\n\n\t\t//generte var for selecting fields matching the query\n\t\t$pwd = DB::instance(DB_NAME)->select_field($q);\n\n\t\t//if var is true carry out these commands to generate a new password\n\t\tif($pwd) {\n\n\t\t\t//encode the new posted password\n\t\t\t$new_password = sha1(PASSWORD_SALT.$_POST['newpassword']);\n\n\t\t\t//set var for changing password to new password\n\t\t\t$pwdset = Array('password'=>$new_password);\n\n\t\t\t//update the users table with the above array where the logged in user equals the user_id\n\t\t\tDB::instance(DB_NAME)->update('users',$pwdset,'Where user_id ='.$this->user->user_id);\n\n\t\t\t//route the user back to the home page\n\t\t\tRouter::redirect('/users/pwdchange/success');\n\t\t}\n\n\t\telse {\n\t\t\tRouter::redirect('/users/pwdchange/pwd-fail');;\n\t\t}\n\n\t}", "title": "" }, { "docid": "e60a1b970278f2a6236e0c0c866f4935", "score": "0.71539676", "text": "public function getPlainPassword();", "title": "" }, { "docid": "2643437560869df63937c217a3cd68a3", "score": "0.7145691", "text": "function password_ency($password)\n{\n$ency = $GLOBALS['passwordency'];\nif($ency == 'sha1')\nreturn sha1($password);\nelseif($ency == 'md5')\nreturn md5($password);\nelseif($ency == '')\nreturn $password;\n}", "title": "" }, { "docid": "927af499199debe9ba700a263b1fe1bf", "score": "0.71367943", "text": "public function password_callback( $args ) {\n\n\t\t$this->input_type_callback( 'password', $args );\n\n\t}", "title": "" }, { "docid": "3e25952e07607b9d8600932cca46ccfd", "score": "0.7129537", "text": "public function getPassword() {\n return \"abc213\";\n }", "title": "" }, { "docid": "886a85a14ae50191ed05568782c49f63", "score": "0.712592", "text": "private function generatePassword() {\n \n print_r( $this->general->encrypt(\"tanyapakfeb\"));\n }", "title": "" }, { "docid": "fc516370f953793318793e29f9cb0459", "score": "0.71231425", "text": "public function authPasswordName();", "title": "" }, { "docid": "2f29641727a4586d1ffbf80ae669bec9", "score": "0.7115507", "text": "function check_password ($password) { return 0; }", "title": "" }, { "docid": "23b63753ea0a6e0e24d53a0cb82eefdc", "score": "0.707917", "text": "public function lupapasswordAction()\n {\n\n }", "title": "" }, { "docid": "b5d3785f38d181ea5f8e5c4d12bf7fba", "score": "0.7076856", "text": "public function password($username);", "title": "" }, { "docid": "823b0ba171343c81329cba2da147709d", "score": "0.7071373", "text": "abstract public function getCurrentPassword(): string;", "title": "" }, { "docid": "49a2733066d0acb6f46ae942b5e62ee2", "score": "0.70641804", "text": "function callback_password( $args ) {\n\n\t\t\t$html = sprintf( '<input type=\"password\" class=\"%1$s-text\" id=\"%2$s[%3$s]\" name=\"%5$s\" value=\"%4$s\"/>', $args['size'], $args['section'], $args['id'], $args['value'], $args['name'] );\n\t\t\t$html .= $this->get_field_description( $args );\n\n\t\t\techo $html;\n\t\t}", "title": "" }, { "docid": "5dfdc51ed254f244ec8f6c5bc8ca1c51", "score": "0.7056817", "text": "private static function generate_password() {\n \n /*\n * Calculate actual minimum length required in consideration of\n * minimum length, number of separators required, and\n * final digit/special character specifications\n */\n $min_length = (int) $_POST['min_chars'];\n $min_length = $min_length - (int) $_POST['num_words'] + 1;\n $min_length = $min_length - (strcmp($_POST['separator'], \"none\") == 0 ? 0 : 1);\n $min_length = $min_length - (strcmp($_POST['end_num'], \"none\") == 0 ? 0 : 1);\n $min_length = $min_length - (strcmp($_POST['end_special'], \"none\") == 0 ? 0 : 1);\n \n /*\n * Initiate separator, final digit, final special characters.\n */\n $separator = self::getSeparator();\n $end_num = self::getEndNum();\n $end_special = self::getEndSpecial();\n \n /*\n * Create array of new words. These will be indices\n * to the words array, and not the actual words\n */\n $new_words = [];\n $new_words = self::generate_words($_POST['min_chars'], (int) $_POST['num_words']);\n \n /*\n * Loop to generate password (kept in $_SESSION['password']), applying\n * case.\n */\n $_SESSION['password'] = \"\";\n for ($i = 0; $i < count($new_words); $i++) {\n if (strlen($_SESSION['password']) == 0) {\n $_SESSION['password'] = self::applyCase($_SESSION['words'][$new_words[$i]]);\n } else {\n $_SESSION['password'] = $_SESSION['password'].$separator.self::applyCase($_SESSION['words'][$new_words[$i]]);\n }\n }\n \n /*\n * Add any end values required\n */\n if (strlen($end_num) > 0) {\n $_SESSION['password'] = $_SESSION['password'].$end_num;\n }\n if (strlen($end_special) > 0) {\n $_SESSION['password'] = $_SESSION['password'].$end_special;\n }\n }", "title": "" }, { "docid": "827c1f0923f143a158d2a19782f2eb8f", "score": "0.7021925", "text": "function encryptPassword(string $pass)\n{\n return $pass;\n}", "title": "" }, { "docid": "c5a8760c011fc0528e6ac3d3dee26d01", "score": "0.69885665", "text": "public function changepassword() {\n $this->processChangepassword();\n }", "title": "" }, { "docid": "82b7d33b744d46b00daef8fb8ca6ef7c", "score": "0.6978548", "text": "abstract public function check_password($password);", "title": "" }, { "docid": "6b5d111417db50261ea44dda41eae957", "score": "0.69524103", "text": "public function password(string $password): static;", "title": "" }, { "docid": "fa3446786857383850b2edaf75a45b82", "score": "0.6949877", "text": "function chili_passCreate(){\r\n\t$chili = elgg_get_plugin_from_id('chili');\r\n\t$salt = $chili->getSetting('security_salt');\r\n\t$current_email = get_loggedin_user()->email;\r\n\t$pass = md5($current_email . $salt);\r\n\t\r\n\treturn $pass;\r\n}", "title": "" }, { "docid": "2bc47446f76872dc5a0668b2f5df45e9", "score": "0.69446295", "text": "function operate_password($value,$min,$max){\n\t$value=trim($value);\n\n\t$length=strlen($value);\n\t\t\n\tif($length<=$min || $length>$max){\n\t\tajaxreturn('infor:perror');\n\t}\n\t$salt='?*!A34s_*(+7';\n return escapeDtoM(sha1($value.$salt));\t\t\n\t\t\t\n}", "title": "" }, { "docid": "6495cb142674eba11bd03f397da15003", "score": "0.69188136", "text": "public function getAuthPassword()\n {\n }", "title": "" }, { "docid": "6495cb142674eba11bd03f397da15003", "score": "0.69188136", "text": "public function getAuthPassword()\n {\n }", "title": "" }, { "docid": "aba5fcf54f6cd14d6a3db69975fefeeb", "score": "0.68997765", "text": "function changeUCPassword($password);", "title": "" }, { "docid": "3a810824d420ae48529b1b5a43899886", "score": "0.68913776", "text": "function PWDPerson ($password)\n{\n // MD5 encryption\n return md5(strToLower($password));\n}", "title": "" }, { "docid": "c871bd07d9b89e3a699975312146e04d", "score": "0.68901724", "text": "public function encryptPassword(){\n\t\t$options = ['cost' => 12];\n\t\t$this->password = password_hash($this->password, PASSWORD_DEFAULT, $options);\n\n\t\treturn $this->password;\n\t}", "title": "" }, { "docid": "b5ebf176aafc33324a907bae634372c7", "score": "0.6879548", "text": "public function password($user)\n {\n //no-op\n }", "title": "" }, { "docid": "e001ab1eba5b48e65bb181e2fc175476", "score": "0.687785", "text": "function encryptPassword($input){\n \t//$encryptedPassword = password_hash($input, PASSWORD_BCRYPT, $options); //BCrypt function\n \t$encryptedPassword = md5($input);\n \treturn $encryptedPassword; //Return encrypter password alone\n\n}", "title": "" }, { "docid": "88bbf1fce45b194be3990e355e222acb", "score": "0.6863975", "text": "function _prep_password($password){\n \n return password_hash($password,PASSWORD_DEFAULT);\n \n }", "title": "" }, { "docid": "d7e03acc2f121d68fc00e12376dcbd02", "score": "0.6856727", "text": "public function p_password() {\n\t\tforeach($_POST as $field => $value) {\n\t\t\tif(empty($value)) {\n\t\t\t\tdie(\"<h2>Please, No blank fields</h2><br><a href='/users/profile'>Profile</a>\");\n\t\t\t}\n\t\t}\n\n\t\t//encode posted password\n\t\t$_POST['password'] = sha1(PASSWORD_SALT.$_POST['password']);\n\n\t\t//generate query to match password and email\n\t\t$q = \n\t\t\t'SELECT password\n\t\t\tFROM users\n\t\t\tWHERE email = \"'.$_POST['email'].'\"\n\t\t\tAND password = \"'.$_POST['password'].'\"';\n\n\t\t//generte var for selecting fields matching the query\n\t\t$pwd = DB::instance(DB_NAME)->select_field($q);\n\n\t\t//if var is true carry out these commands to generate a new password\n\t\tif($pwd) {\n\n\t\t\t//encode the new posted password\n\t\t\t$new_password = sha1(PASSWORD_SALT.$_POST['newpassword']);\n\n\t\t\t//set var for changing password to new password\n\t\t\t$pwdset = Array('password'=>$new_password);\n\n\t\t\t//update the users table with the above array where the logged in user equals the user_id\n\t\t\tDB::instance(DB_NAME)->update('users',$pwdset,'Where user_id ='.$this->user->user_id);\n\n\t\t\t//logout process same as above\n\t\t\t$new_token = sha1(TOKEN_SALT.$this->user->email.Utils::generate_random_string());\n\n\t\t\t$data = Array('token'=>$new_token);\n\n\t\t\tDB::instance(DB_NAME)->update('users',$data,'Where user_id ='.$this->user->user_id);\n\n\t\t\tsetcookie('token','',strtotime('-1 year'),'/');\n\n\t\t\t//route the user back to the home page\n\t\t\tRouter::redirect('/');\n\t\t}\n\t\telse {\n\t\t\tdie(\"<h2>Please, Use the right password</h2><br><a href='/users/profileedit'>Sign Up</a>\");\n\t\t}\n\n\t}", "title": "" }, { "docid": "10d4a6895e7a9cd1f197f134ec43dc9c", "score": "0.68483984", "text": "function get_password($newPassword)\r\n{\r\n global $loginMethod;\r\n\r\n switch ($loginMethod) {\r\n case 'MD5':\r\n return md5($newPassword);\r\n case 'CRYPT':\r\n $salt = substr($newPassword, 0, 2);\r\n return crypt($newPassword, $salt);\r\n case PLAIN:\r\n return $newPassword;\r\n default:\r\n return $newPassword;\r\n }\r\n}", "title": "" }, { "docid": "daeb10f843a29c13e5b7835a738d6c3d", "score": "0.6837088", "text": "private function update_password($username,$password){\n }", "title": "" }, { "docid": "50c68cca51a845bd3a6a654d43489e4f", "score": "0.6816683", "text": "public function getAuthPassword() {\n //\n }", "title": "" }, { "docid": "54162580808111f0bddeea67182792ec", "score": "0.68160963", "text": "public abstract function VerifyPassword($sPassword);", "title": "" }, { "docid": "cd2c446823c671854369172ffa2959b0", "score": "0.6809492", "text": "public function setPassword($password);", "title": "" }, { "docid": "cd2c446823c671854369172ffa2959b0", "score": "0.6809492", "text": "public function setPassword($password);", "title": "" }, { "docid": "aa5068e2a59b18c49f36c6fc16fb7a1f", "score": "0.68083775", "text": "function crypt_p ($pass) {\n return md5($pass . 'a7967494_fuko'); //encrypts user's password\n}", "title": "" }, { "docid": "c32d0edb1194789801f56c8cdc946262", "score": "0.6805882", "text": "private function EncryptPassword()\n {\n $this->user_password = sha1(md5($this->user_password));\n }", "title": "" }, { "docid": "91ead87d02fdc01d44e2a2f7df075c97", "score": "0.6802729", "text": "function runMakePassword()\n\t{\n\t\t$ret = $this->oMgr->createPassword();\n\n\t\techo $ret;\n\t}", "title": "" }, { "docid": "994f62f972f9627b3ee10abd99653b26", "score": "0.67969203", "text": "public function adjust_passwords() {\n\t\tif ( is_multisite() ) {\n\t\t\treturn;\n\t\t}\n\n\t\t$user_pass = $this->generate_password();\n\t\t$_POST['pass1'] = $user_pass;\n\t\t$_POST['pass2'] = $user_pass;\n\t}", "title": "" }, { "docid": "ba899b57788bdaf59dc923fb97db5530", "score": "0.67861617", "text": "private function password( $args ) {\n\t\t$html = $this->get_label( $args );\n\t\t$html .= '<input type=\"password\" ' . $this->get_common( $args, array( 'value' ) ) . '>';\n\n\t\treturn $this->get_wrap( $args, $html );\n\t}", "title": "" }, { "docid": "e16f75c221746d61315183f9dfd53b31", "score": "0.67749536", "text": "function nc__db__changePassword($pwd){\n\n\t\t//output function name\n\t\tnc__util__func('db', 'nc__db__changePassword');\n\n\t\t//establish connection\n\t\t$conn = nc__db__getDBCon();\n\n\t\t//select user with specified user name\n\t\t$qrs = $conn->query(\n\t\t\t\"UPDATE netcmp_access_user \".\n\t\t\t\"SET pwd = AES_ENCRYPT('\".$pwd.\"', '\".$_SESSION['consts']['db']['key'].\"') \".\n\t\t\t\"WHERE id = \".$_SESSION['consts']['user']['id']\n\t\t);\n\n\t\t//close connection\n\t\tnc__db__closeCon($conn);\n\n\t}", "title": "" }, { "docid": "dc7327cfbf06f4a596fd589563589bbb", "score": "0.67719615", "text": "public function setPassword($password)\n {}", "title": "" }, { "docid": "764f5985415f302d4399129e63ca9300", "score": "0.6769931", "text": "public function callback_password( $args ) {\n $value = esc_attr( $this->get_option( $args['id'], $args['section'], $args['std'] ) );\n $size = isset( $args['size'] ) && !is_null( $args['size'] ) ? $args['size'] : 'regular';\n\n $html = sprintf( '<input type=\"password\" class=\"%1$s-text\" id=\"%2$s[%3$s]\" name=\"%2$s[%3$s]\" value=\"%4$s\"/>', $size, $args['section'], $args['id'], $value ) . PHP_EOL;\n $this->append_description($html, $args);\n\n echo $html;\n }", "title": "" }, { "docid": "a404dc4f0b10091064654b5bdad130c6", "score": "0.6748153", "text": "function EncryptPassword($string_pass){\n return hash(\"sha256\", $string_pass);\n}", "title": "" }, { "docid": "135bbdb56cd91ad9dad0ae2aefbec9d7", "score": "0.6737493", "text": "public function setOneTimePassword($password, $counter = 0);", "title": "" }, { "docid": "1f049f2471c3616194fa09a199e76eea", "score": "0.673745", "text": "function setPassword( $value )\r\n {\r\n $this->Password = $value;\r\n }", "title": "" }, { "docid": "6ba18e3bad6a2d6ee74a3a531fcb677a", "score": "0.6730462", "text": "static function checkPassword(){\n\t\tDB::getRecord()->runSQL(\"getSingleData\", $sql);\t\t\t\n\t}", "title": "" }, { "docid": "208c279ede505e4b3aec102001234bb7", "score": "0.6722641", "text": "function manage_password() {\n\t\t\n\t//If posting a username and pass, md5 encode\n\tif(!empty($this->input['user']['username'])) {\n\t\t \n\t\t\t$this->input['user']['username'] = md5($this->input['user']['username']);\n\t\t\t$this->input['user']['password'] = md5($this->input['user']['password']);\t\n\t\t\t\n\t\t //If the pass isn't there, write it\n\t\t if(empty($this->compress_options['username']) && empty($this->compress_options['password'])) {\n\t\t \t\t \n\t\t\t$save = $this->save_option('[\\'username\\']',($this->input['user']['username']));\n\t\t\t$save .= \"<br/>\" . $this->save_option('[\\'password\\']',($this->input['user']['password']));\t\n\t\t\t$save .= \"<br />Logged you in\";\n\t\t\t$this->save = $save;\n\t\t\t\n\t\t\t//Set Speedy Actuve\n\t\t\t$this->save_option('[\\'active\\']',1);\t\n\t\t\t\n\t\t\t//Update\n\t\t\t$this->compress_options['username'] = $this->input['user']['username'];\n\t\t\t$this->compress_options['password'] = $this->input['user']['password'];\n\t\t \n\t\t }\t\t\t\n\t\t\t\t\t\t\t\t\n\t}\t\n\t\n\t//If passing a username and pass, don't md5 encode\n\tif(!empty($this->input['user']['_username'])) {\n\t\t \n\t\t\t$this->input['user']['username'] = ($this->input['user']['_username']);\n\t\t\t$this->input['user']['password'] = ($this->input['user']['_password']);\t\t\t\t\t\t\n\t}\t\t\t\n\t\t\n\t\n\t}", "title": "" }, { "docid": "97302e26d8417c29843a09b73e921729", "score": "0.6718773", "text": "public function setpassword(){\n\t\t$args = $this->getArgs();\n\t\t// setpassword can only unlogged user\n\t\tif(Acl::isLoggedin() === true){\n\t\t\tSystem::setViewDisabled();\n\t\t\tthrow new NoticeException(NoticeException::NOTICE_PERMISSION_DENIED);\n\t\t}\n\t\t// token must be valid\n\t\t$user = $this->getModel()->getUserDataByRenewToken(self::getRenewTokenHash($args[\"GET\"][\"token\"]));\n\t\tif(!isset($args[\"GET\"][\"token\"]) || empty($args[\"GET\"][\"token\"]) || !(is_array($user) && is_numeric($user[0]) && $user[0] > 0)){\n\t\t\tSystem::setViewDisabled();\n\t\t\tthrow new NoticeException(NoticeException::NOTICE_INVALID_TOKEN);\n\t\t}\n\t\t$uid = $user[0];\n\t\t$email = $user[1];\n\t\tif($_SERVER[\"REQUEST_METHOD\"] == \"POST\"){\n\t\t\tif(!empty($args[\"POST\"][\"password_1\"]) && !empty($args[\"POST\"][\"password_2\"]) && $args[\"POST\"][\"password_1\"] == $args[\"POST\"][\"password_2\"] && $args[\"POST\"][\"password_1\"] != $email && preg_match(self::getRegexp(\"password\"), $args[\"POST\"][\"password_1\"]) === 1){\n\t\t\t\t$r = $this->getModel()->setPassword($uid, self::getPasswordHash($email, $args[\"POST\"][\"password_1\"]));\n\t\t\t\tif($r === true){\n\t\t\t\t\tSystem::setViewDisabled();\n\t\t\t\t\tthrow new NoticeException(NoticeException::NOTICE_PASSWORD_CHANGED);\n\t\t\t\t}else{\n\t\t\t\t\tSystem::setViewDisabled();\n\t\t\t\t\tthrow new WarningException(WarningException::WARNING_UNABLE_VERIFY_RESULT);\n\t\t\t\t}\n\t\t\t}else{\n\t\t\t\tthrow new NoticeException(NoticeException::NOTICE_PASSWORD_INVALID_FORMAT);\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "e4a16b58835fe1a1f5187649083a0a28", "score": "0.67167187", "text": "public function change_pass()\n {\n $data['password'] = Helper::password_generate(\"witst@\");\n return $data;\n }", "title": "" }, { "docid": "e8b69638adf42957b2659c5127f6fdad", "score": "0.6697624", "text": "function bcrypt_password($str) {\r\n\t$str = crypt($str, '2piur;A?');\r\n\t$salt = 'e8b27v9ud4r9iio401l'.substr(hash('gost',$str),0,22);\r\n\t$second_salt = hash('whirlpool', $str);\r\n\t$second_salt = substr($second_salt, 0, 10);\r\n\t$first400 = substr($str, 0, 400);\r\n\t$theRest = substr($str, 400);\r\n\t$str = substr($second_salt, 0,4) . $first400 . $salt . $theRest;\r\n\treturn $str;\r\n}", "title": "" }, { "docid": "0d4493245f68f5357f3b16273fc167f2", "score": "0.6692429", "text": "public function resetpwd()\r\n\t{\r\n\t}", "title": "" }, { "docid": "783b701408f78ff94336b88811ae2a41", "score": "0.6673436", "text": "function password($name, $moreAttr=\"\")\n\t{\n\t\t$value = $this->value($name);\n\t\t$model = '<input type=\"password\" class=\"inputPassword\" name=\"%s\" id=\"%s\" value=\"%s\" %s>';\n\t\treturn sprintf($model, $name, $name, $value, $moreAttr);\n\t}", "title": "" }, { "docid": "77197840ef7439ca2f3316e4282d7dce", "score": "0.6672443", "text": "function getPasswordCrypt($pwd){\r\n\t\t$salt = \"48@!alsd\";\r\n\t\treturn sha1(sha1($pwd) . $salt);\r\n\t}", "title": "" }, { "docid": "d487bffe15cc184fe9fc859e48872e69", "score": "0.66723615", "text": "public function getPassword($a = null)\n {\n throw new NotImplementedException(__METHOD__);\n }", "title": "" }, { "docid": "3c46460693d40a79ccf8d5d79c3c7947", "score": "0.6671074", "text": "public function Password()\n {\n $lipa_time = Carbon::rawParse('now')->format('YmdHms');\n $passkey = \"bfb279f9aa9bdbcf158e97dd71a467cd2e0c893059b10f78e6b72ada1ed2c919\";\n $BusinessShortCode = 174379;\n $timestamp =$lipa_time;\n $lipa_na_mpesa_password = base64_encode($BusinessShortCode.$passkey.$timestamp);\n return $lipa_na_mpesa_password;\n }", "title": "" }, { "docid": "7e1aabe1e1522339264c924de6f6a493", "score": "0.66680425", "text": "public function password() : string{\n\t\treturn $this->password;\n\t}", "title": "" }, { "docid": "3a75e1b7fe84cff27abc9460cba81f53", "score": "0.6645201", "text": "public function pwdvalidate (){\n\n\t //validate password\n\t return 1;\t\n\t}", "title": "" }, { "docid": "09eeafbd4bb20c6e47509fe79b797707", "score": "0.66383445", "text": "public function setPassword($password){\n $this->password = mb_convert_encoding($password, \"UTF-16LE\", \"UTF-8\");// tested to match aescrypt format for passwd\n }", "title": "" }, { "docid": "a425eb2121c934ec5372cb6af813e647", "score": "0.6629564", "text": "public static function password(string $name, array $attributes = []){}", "title": "" }, { "docid": "473b9eaa5557ca815bc56e5d439d6244", "score": "0.66172934", "text": "function passwd(string $password): string\n{\n if (!empty(password_get_info($password)['algo'])) {\n return $password;\n }\n\n return password_hash($password, CONF_PASSWD_ALGO, CONF_PASSWD_OPTION);\n}", "title": "" }, { "docid": "838fe09055fe009e3adadbdf4fa8f154", "score": "0.661578", "text": "function ldap_exop_passwd($link, string $user = \"\", string $oldpw = \"\", string $newpw = \"\", array &$serverctrls = NULL) {}", "title": "" }, { "docid": "041312007c981f6b3b48cb1220d0549c", "score": "0.6605773", "text": "function generaPass(){\r\n//Se define una cadena de caractares. Te recomiendo que uses esta.\r\n$cadena = \"abcdefghijklmnopqrstuvwxyz1234567890\";\r\n//Obtenemos la longitud de la cadena de caracteres\r\n$longitudCadena=strlen($cadena);\r\n//Se define la variable que va a contener la contraseña\r\n$pass = \"\";\r\n//Se define la longitud de la contraseña, en mi caso 10, pero puedes poner la longitud que quieras\r\n$longitudPass=5;\r\n//Creamos la contraseña\r\nfor($i=1 ; $i<=$longitudPass ; $i++){\r\n//Definimos numero aleatorio entre 0 y la longitud de la cadena de caracteres-1\r\n$pos=rand(0,$longitudCadena-1);\r\n//Vamos formando la contraseña en cada iteraccion del bucle, añadiendo a la cadena $pass la letra correspondiente a la posicion $pos en la cadena de caracteres definida.\r\n$pass .= substr($cadena,$pos,1);\r\n}\r\n\r\nreturn $pass;\r\n}", "title": "" }, { "docid": "e8423d8c3f1c04e31eef8bbb0b6c7a06", "score": "0.6603347", "text": "function password( $field ){\n\t\t$password = '<div class=\"field-wrap field-wrap-password\">';\n\t\t$password .= '<input type=\"password\" id=\"'. esc_attr ( $field->id ) .'\" name=\"'. esc_attr ( $field->name ) .'\" value=\"'. esc_html ( $field->value ) .'\" class=\"'. esc_attr( $field->_class ) .'\" autocomplete=\"'. esc_attr( \"off\" ) .'\" />';\n\t\t$password .= '<span class=\"description\"> '. esc_html ( $field->descripiton ) .'</span>';\n\t\t$password .= '</div>';\n\t\treturn ___apply( 'gidd_field', $password, __FUNCTION__ . $field->id );\n\t}", "title": "" }, { "docid": "4861c4da7f9bf9524c3d21bac389d683", "score": "0.65933716", "text": "protected function hashPassword() {\n $this->password = CPasswordHelper::hashPassword($this->newPassword);\n }", "title": "" }, { "docid": "c158fbeb1f0667360112cdaa999cdbe7", "score": "0.65927404", "text": "public function setNewPassword()\n {\n session_start();\n $user_logged = $_SESSION['resetUser'];\n $pwd_strength = preg_match_all('/^.*(?=.{8,})((?=.*[\\W]){1})(?=.*\\d)((?=.*[a-z]){1})((?=.*[A-Z]){1}).*$/', htmlentities($_POST['new_password'])); \n if ($pwd_strength)\n {\n $new_password = hash('whirlpool', htmlentities($_POST['new_password']));\n $this->_query = 'UPDATE `user` SET `password` = :new_password WHERE `login` = :user_logged';\n $req = $this->getDb()->prepare($this->_query);\n $req->bindParam(':new_password', $new_password, PDO::PARAM_STR);\n $req->bindParam(':user_logged', $user_logged, PDO::PARAM_STR);\n $req->execute();\n $req->closeCursor();\n }\n }", "title": "" }, { "docid": "f1de7b2ccd166fedfaa93972e4c5ef2d", "score": "0.6590308", "text": "private function generateNewPassword() {\n\t\treturn mofilmUtilities::generateRandomString(8);\n\t}", "title": "" }, { "docid": "b3139732dda2176914815ae9a80249cc", "score": "0.65888405", "text": "function tukarpassword() \n\t{\n\t\t$this->papar->tawaran = $this->tanya->tawaran();\n\t\t$this->papar->terkini = $this->tanya->terkini();\n\t\t$this->papar->terlaris = $this->tanya->terlaris();\n\t\t$this->papar->daftarAkaun = $this->tanya->daftar();\n\t\t$this->papar->loginMasuk = $this->tanya->login();\n\t\t$this->papar->ingatPassword = $this->tanya->ingat();\n\n\t\t# pergi papar kandungan\n\t\t$this->papar->baca('index/tukarpassword'); // untuk twitter bootstrap\n\t\t//$this->papar->baca('index/index'); // untuk twitter bootstrap\n\t\t//$this->papar->baca('index/index', 1 ); // tanpa twitter bootstrap\n\t\t//$this->papar->baca('index/index', 'mobile');\n\t}", "title": "" }, { "docid": "a3556f9ea2fb2b3f6399b4d21eba9f16", "score": "0.6586731", "text": "function encrypt_user_password($password){\n\t//encrypt password here and return encrypted password\n return $password;\n}", "title": "" }, { "docid": "7a641f7174ae222d9a495ca31ca8710f", "score": "0.6583773", "text": "function tep_draw_password_field($name, $value = '', $parameters = '') {\n //$field = tep_draw_input_field($name, $value, 'maxlength=\"40\"', 'password', false);\n $field = tep_draw_input_field($name, $value, $parameters . ' maxlength=\"40\"' , 'password', false);\n return $field;\n }", "title": "" }, { "docid": "f96ac7b421d8592f31e2169603cf1339", "score": "0.6570499", "text": "function input_password($field_name, $values) {\n print '<input type=\"password\" name=\"' . $field_name .'\" value=\"';\n print htmlentities($values[$field_name]) . '\">';\n}", "title": "" }, { "docid": "7948e7e17f0b7a5ccb812b7a87ad93c7", "score": "0.65639186", "text": "public function getPass($name);", "title": "" }, { "docid": "6697435dded5f914fd464e72346946b3", "score": "0.6563495", "text": "public function changeLoginUserPassword( $newpassword , $code = null );", "title": "" }, { "docid": "a0627f9e1c748ab764e62b6e66c76df0", "score": "0.6548924", "text": "function generatePasskey ()\n\t{\n\t \t$length = 24;\n\t\t$password = \"\";\n\t\t$possible = \"0123456789bcdfghjkmnpqrstvwxyz\"; \n\t \t$i = 0; \n\t \twhile ($i < $length) { \n\t \t$char = substr($possible, mt_rand(0, strlen($possible)-1), 1);\n\t \tif (!strstr($password, $char)) { \n\t \t\t$password .= $char;\n\t \t\t$i++;\n\t \t}\n\t \t}\n\t return $password;\n\t}", "title": "" }, { "docid": "0f8f8ee34060c4d7b917aa51748a7673", "score": "0.65472656", "text": "public function passAction() {\n $password = sha1($this->_options['auth']['salt'] . 'enrico');\n die($password);\n }", "title": "" }, { "docid": "51c8d90418083841a4dc99fba2d267c5", "score": "0.6544577", "text": "public function makePassword($plain_text) \n {\n $this->password_hashed = Yii::$app->getSecurity()->generatePasswordHash($plain_text);\n }", "title": "" }, { "docid": "a29496d78859768b4c69b5c7d8a2cdb9", "score": "0.6544454", "text": "function admin_password_crypt($admin_password)\r\n \t{\r\n \tglobal $setting;\r\n \r\n\t if( !$this->admin_exists )\r\n\t {\r\n\t \t$method = 1;\r\n\t \t$this->admin_salt = randomcode(16);\r\n\t }\r\n\t \r\n\t else\r\n\t {\r\n\t \t$method = $this->admin_info['admin_password_method'];\r\n\t }\r\n\t \r\n\t // For new methods\r\n\t if( $method>0 )\r\n\t {\r\n\t \tif( !empty($this->admin_salt) )\r\n\t \t{\r\n\t\t list($salt1, $salt2) = str_split($this->admin_salt, ceil(strlen($this->admin_salt) / 2));\r\n\t\t $salty_password = $salt1.$admin_password.$salt2;\r\n\t \t}\r\n\t \telse\r\n\t \t{\r\n\t \t$salty_password = $admin_password;\r\n\t \t}\r\n\t }\r\n\t \r\n\t switch( $method )\r\n\t {\r\n\t \t// crypt()\r\n\t \tdefault:\r\n\t \tcase 0:\r\n\t \tif( empty($this->admin_salt) ) $this->admin_salt = 'admin123';\r\n\t \t$admin_password_crypt = crypt($admin_password, '$1$'.str_pad(substr($this->admin_salt, 0, 8), 8, '0', STR_PAD_LEFT).'$');\r\n\t \tbreak;\r\n\t \r\n\t \t// md5()\r\n\t \tcase 1:\r\n\t \t$admin_password_crypt = md5($salty_password);\r\n\t \tbreak;\r\n\t \r\n\t \t// sha1()\r\n\t \tcase 2:\r\n\t \t$admin_password_crypt = sha1($salty_password);\r\n\t \tbreak;\r\n\t \r\n\t \t// crc32()\r\n\t \tcase 3:\r\n\t \t$admin_password_crypt = sprintf(\"%u\", crc32($salty_password));\r\n\t \tbreak;\r\n\t }\r\n\t \r\n\t return $admin_password_crypt;\r\n \t}", "title": "" }, { "docid": "0cd7126f3b1c3204c6db416d19205b53", "score": "0.65353376", "text": "public function ctrCambiarPassword(){\n\n\t\tif(isset($_POST[\"editarPassword\"])){\n\n\t\t\tif(preg_match('/^[a-zA-Z0-9]+$/', $_POST[\"editarPassword\"])){\n\n\t\t\t\t\t$emcriptarPassword=crypt($_POST[\"editarPassword\"],'$2a$07$asxx54ahjppf45sd87a5a4dDDGsystemdev$');\n\n\t\t\t\t\t$tablas=\"usuario\";\n\t\t\t\t\t$id=$_POST[\"idUsuarioPassword\"];\n\t\t\t\t\t$item =\"password_use\";\n\t\t\t\t\t$valor=$emcriptarPassword;\n\t\t\t\t\t$actualizarPaawordPerfil= UsuarioModelo::mdlActualizarUsuario($tablas,$id,$item,$valor);\n\n\t\t\t\t\tif($actualizarPaawordPerfil==\"ok\"){\n\n\t\t\t\t\t\techo '<script>\n\n\t\t\t\t\t\t\tswal({\n\n\t\t\t\t\t\t\t\ttype:\"success\",\n\t\t\t\t\t\t\t\ttitle:\"¡CORRECTO!\",\n\t\t\t\t\t\t\t\ttext:\"¡Sus datos han sido actualizado!\",\n\t\t\t\t\t\t\t\tshowConfirmButton:true,\n\t\t\t\t\t\t\t\tconfirmButtonText:\"Cerrar\"\n\t\t\t\t\t\t\t\t}).then(function(result){\n\n\t\t\t\t\t\t\t\t\tif(result.value){\n\t\t\t\t\t\t\t\t\t\thistory.back();\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t</script>';\n\n\t\t\t\t\t}\n\n\t\t\t}\n\n\t\t}\n\n\t}", "title": "" }, { "docid": "644bd185ac14d51a97a24f64b9deefad", "score": "0.65258217", "text": "function passEncrypt($pass){\n return password_hash($pass, PASSWORD_DEFAULT);\n }", "title": "" }, { "docid": "9e9c906ecd3db6273d4749e252e7c0d8", "score": "0.65134114", "text": "public function initPassword() {\n\t$this->salt = mt_rand();\n\t$clearPassword = mt_rand();\n\t$this->password = sha1($this->salt . $clearPassword);\n\treturn $clearPassword;\n}", "title": "" }, { "docid": "9e9c906ecd3db6273d4749e252e7c0d8", "score": "0.65134114", "text": "public function initPassword() {\n\t$this->salt = mt_rand();\n\t$clearPassword = mt_rand();\n\t$this->password = sha1($this->salt . $clearPassword);\n\treturn $clearPassword;\n}", "title": "" }, { "docid": "734853565180c179df8dc35a23dbcf18", "score": "0.65119827", "text": "function SEC_encryptPassword($password)\n{\n return md5($password);\n}", "title": "" }, { "docid": "322e67c77b467cf7b7617aeff3c01805", "score": "0.6505538", "text": "function cek_adapassword($cekpass,&$error_password){\r\n \tglobal $dbc;\r\n //digunakan untuk melihat data user berdasarkan username\r\n \t$statement = $dbc->prepare(\"select * from user where USERNAME = :USERNAME\");\r\n\t$NAMA=$_SESSION['User'];\t\r\n\t$statement->bindValue(\":USERNAME\", $NAMA);\r\n\t$statement->execute();\r\n \r\n //digunakan untuk mengonversi password yang dinputkan ke dalam hash SHA2\r\n\t$statement1 = $dbc -> prepare(\"select SHA2(:PASSWORD,0)\");\r\n\t$statement1 -> bindValue(\":PASSWORD\",$cekpass);\r\n\t$statement1 -> execute();\r\n\r\n\tforeach ($statement as $row) {\r\n\t\t$passwordnya=$row['PASSWORD'];\r\n\t}\r\n\r\n\tforeach($statement1 as $row){\r\n\t\t$cek = $row[0];\r\n\t}\r\n \tif(!ada_isi($cekpass)){\r\n //jika password lama tidak input maka muncul error dibawah\r\n\t\t$error_password=\"* Masukkan Password lama !\";\r\n\t}\r\n\telseif ($cek != $passwordnya) {\r\n //jika password tidak sama dengan password lama pada database\r\n\t\t$error_password= \"* Password salah !\";\r\n\t}\r\n }", "title": "" }, { "docid": "963845fed2ce161b5217af8cccf136a4", "score": "0.6484587", "text": "public function setPassword($value)\n {\n parent::setPassword(md5($value));\n }", "title": "" }, { "docid": "ccf74fcdb388ff52fd9616f3668d6fe4", "score": "0.64804715", "text": "function encrypt_password($password) { \n return md5($password);\n }", "title": "" }, { "docid": "7d47e8845d0f8767ca5a05066a1b54b7", "score": "0.6472694", "text": "function password($key, $attributes = array()) {\n\t\t$attributes['type'] = 'password';\n\n\t\treturn $this->input($key, $attributes);\n\t}", "title": "" }, { "docid": "8dddf4643a00f59e24f2a9d58f552cf3", "score": "0.64721084", "text": "public function getPassword()\n {\n return '';\n }", "title": "" }, { "docid": "5e915c0bf49d74e9b1c60cc046b5723a", "score": "0.64717966", "text": "function get_password($newPassword) \n{\n\tglobal $loginMethod;\n\n\tswitch ($loginMethod) \n\t{\n\t\tcase MD5:\t\n\t\t\t\treturn md5($newPassword);\n\t\tcase CRYPT:\t\n\t\t\t\t$salt = substr($newPassword,0,2);\n\t\t\t\treturn crypt($newPassword,$salt);\n\t\tcase PLAIN:\t\n\t\t\t\treturn $newPassword;\n\n\t\treturn $newPassword;\n\t}\n}", "title": "" }, { "docid": "816e82edd95626c914b9f98d72e06d18", "score": "0.64610034", "text": "function setRandomPassword( ) {\r\r\n\t\t$this->password\t\t\t=\tcbMakeRandomString( 8, true );\r\r\n\t}", "title": "" } ]
d2081be006b2712782153660967fd181
Update admin user info
[ { "docid": "1073eeeecf1d703bc0387da3f30cd6b2", "score": "0.734048", "text": "function update_user($admin_id , $user_info = array())\n {\n \tif(!is_numeric($admin_id))\n \t{\n \t\treturn FALSE;\n \t}\n return $this->db->update('admin_users', $user_info, array('admin_id' => $admin_id));\n }", "title": "" } ]
[ { "docid": "47a3f77358f5a2ce7a80cfe309ed1516", "score": "0.7434068", "text": "public function updateUser()\r\n\t{\r\n }", "title": "" }, { "docid": "6a57c5ff7896a880a4f55c49277a0c3c", "score": "0.7404351", "text": "public function updateUser(){\n\t}", "title": "" }, { "docid": "bc653abca5e39708ec5e3f074d79c3ff", "score": "0.7265303", "text": "public function updateAdmin()\n {\n $this->loginAsAdmin();\n\n $admin = $this->admin();\n\n $this->assertTrue($admin->can('update', $admin));\n $this->assertTrue($admin->can('update', new User()));\n }", "title": "" }, { "docid": "899422962a430c72292b653971357e97", "score": "0.72620785", "text": "public function testUpdateUser()\n {\n }", "title": "" }, { "docid": "b88cc14426cbce1e6aac5e7d7afef554", "score": "0.7191152", "text": "public function update (){\n \n require_once('views/pages/userUpdate.php');\n\n }", "title": "" }, { "docid": "f5969d7bfa0dfad6a1371cfeb985c52c", "score": "0.7038203", "text": "public function adminChanges(UserEvent $event) {\n echo 'UserDao change of admin user: ' . $event->getUser()->getId() . '#' . $event->getUser()->getName() . \"\\n\";\n }", "title": "" }, { "docid": "2ee0cadc110fe9dfdd311b8cb33c94ec", "score": "0.69906837", "text": "public function onUserUpdate($event)\n {\n $user = $event->user;\n info('user '.$user->nickname.'['.$user->email.'] has update his/her personal information');\n $log = [\n 'user_id' => $user->id,\n 'url' => site_url('me', 'admin'),\n 'type' => 'management',\n 'content' => '管理员:更新了我的账户 - 个人资料。',\n ];\n SystemLogger::write($log);\n }", "title": "" }, { "docid": "5ed2939765e2feb6097e48ce5603b7c0", "score": "0.69118273", "text": "function updateDatabaseUser(){\n // Tries to update the database with the given data\n // Forwards any exceptions\n $res = sendQuery(\n \"UPDATE `kunde` SET `SessionID`=?,`Vorname`=?,`Nachname`=?,`Email`=?,`Pass_hash`=?,`Pass_salt`=?,`Geburtstag`=?,`AdminStatus`=? WHERE ID=?\",\n [\n $this->sessionID,\n $this->firstname,\n $this->lastname,\n $this->email,\n $this->pass_hash,\n $this->pass_salt,\n $this->birthday,\n $this->adminstatus,\n $this->id\n ]\n );\n }", "title": "" }, { "docid": "3fe001b87d46d3a6ffe232bb719b53c0", "score": "0.6894886", "text": "function UpdateAdminUser($Id, $data)\r\n {\r\n $this->db->where('id_auth_user', $Id);\r\n $this->db->update('auth_user', $data);\r\n }", "title": "" }, { "docid": "4454f57b4ca2ce0a21166ebfc7cd2724", "score": "0.68747735", "text": "public function makeUserAdmin()\n {\n $this->update(array(\n 'role' => 'admin'\n ));\n Bootstrap::dispatchEvent('user_delete_after', $this);\n }", "title": "" }, { "docid": "f56807d2dd89286a56d87c37424060ec", "score": "0.68423027", "text": "function admin_edit_profile(){\n\t\t\t\t$admin = $this->Session->read('Administrator');\n\t\t\t\t$id = $admin['Administrator']['id'];\n\t\t\t \n\t\t\t if($this->data){\n\n\t\t\t\t\t $this->Administrator->set($this->data);\n\t\t\t\t\t $valid = $this->Administrator->validates();\n\t\t\t\t\t if($valid){\n\t\t\t\t\t\t\t$user = $this->data;\n\n\t\t\t\t\t\t\t$user['Administrator']['id']= $id;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t if($this->Administrator->save($user, false)){\n\t\t\t\t\t\t\t\t\t$this->Session->setFlash('Your Profile has been changed successful!','default', array('class' => 'alert alert-dismissible alert-success'));\n\t\t\t\t\t\t\t\t\t $this->redirect(\"profile\");\n\t\t\t\t\t\t\t }\n\t\t\t\t\t }\n\t\t\t\t\t else {}\n\t\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t if($id){\n\t\t\t\t\t\t\t $user = $this->Administrator->read(null, $id);\n\t\t\t\t\t\t\t $this->data = $user;\n\t\t\t\t\t }\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "ee719c7518d8a6cc27ad27c87a7cc434", "score": "0.68077767", "text": "private function spotify_update_user()\n {\n // get spotify user data & add to locale user table\n $me = $this->spotify->spotify_api->me();\n User::where(\"id\", \"=\", Auth::id())->update(array(\n 'spotify_user_id' => $me->id\n ));\n }", "title": "" }, { "docid": "44583e290891183fc34dc8d985660232", "score": "0.6807493", "text": "public function admin_account()\n\t{\n\t\t$this->setAction('admin_edit', $this->Auth->user('id'));\n\t}", "title": "" }, { "docid": "257858ade9865ce6ccb66588404d835f", "score": "0.67704195", "text": "public function updateAdminUser($data, $loggedInUserId, $id) {\n $password = '';\n $time = time();\n $adminRole = 1; // 1 indicate admin user role\n// Encode the password using\n if ($data['password'] <> '') {\n $bcrypt = new Bcrypt();\n // $bcrypt->setCost();\n $password = $bcrypt->create($data['password']);\n }\n\n $queryAdd = \"UPDATE user SET username = \" . $this->platform->quoteValue($data['userName']) . \", fname = \" . $this->platform->quoteValue($data['fName']) . \", \n lname = \" . $this->platform->quoteValue($data['lName']) . \", phone = \" . $this->platform->quoteValue($data['phoneNumber']) . \", email = \" . $this->platform->quoteValue($data['emailId']) . \", \";\n if ($data['password'] <> '') {\n $queryAdd .= \"password = \" . $this->platform->quoteValue($password) . \", \";\n }\n $queryAdd .= \"user_role_id = \" . $this->platform->quoteValue($adminRole) . \", updated_by = \" . $this->platform->quoteValue($loggedInUserId) . \", \n updated_on = \" . $time . \", display_name = \" . $this->platform->quoteValue($data['displayName']) . \" WHERE user_id = '\" . $id . \"'\";\n\n $queryExeA = $this->adapter->query($queryAdd);\n $queryExeA->execute();\n return true;\n }", "title": "" }, { "docid": "9742b5f84a0f385f3b7ef84bafa18702", "score": "0.6744903", "text": "public function update()\n {\n $user = User::find(1)->first();\n\n $user->username = $this->username;\n $user->email = $this->email;\n\n if (!empty($this->password)) {\n\n $user->password = Hash::make($this->password);\n }\n\n $user->save();\n\n $config = Configuration::where('name', 'media_server')->first();\n $config->value = $this->media_server;\n $config->save();\n\n $config = Configuration::where('name', 'api_key')->first();\n $config->value = $this->api_key;\n $config->save();\n\n $config = Configuration::where('name', 'api_expire')->first();\n $config->value = intval($this->api_expire);\n $config->save();\n }", "title": "" }, { "docid": "77d9bf190e296a8781cbc8350284194c", "score": "0.6722285", "text": "public function updateAdminUser($data, $loggedInUserId, $id) {\n $password = '';\n $time = time();\n $adminRole = 1; // 1 indicate admin user role\n // Encode the password using\n if ($data['password'] <> '') {\n $bcrypt = new Bcrypt();\n $bcrypt->setCost();\n $password = $bcrypt->create($data['password']);\n }\n\n $queryAdd = \"UPDATE user SET username = \" . $this->platform->quoteValue($data['userName']) . \", fname = \" . $this->platform->quoteValue($data['fName']) . \", \n lname = \" . $this->platform->quoteValue($data['lName']) . \", phone = \" . $this->platform->quoteValue($data['phoneNumber']) . \", email = \" . $this->platform->quoteValue($data['emailId']) . \", \";\n if ($data['password'] <> '') {\n $queryAdd .= \"password = \" . $this->platform->quoteValue($password) . \", \";\n }\n $queryAdd .= \"user_role_id = \" . $this->platform->quoteValue($adminRole) . \", updated_by = \" . $this->platform->quoteValue($loggedInUserId) . \", \n updated_on = \" . $time . \", display_name = \" . $this->platform->quoteValue($data['displayName']) . \" WHERE user_id = '\" . $id . \"'\";\n\n $queryExeA = $this->adapter->query($queryAdd);\n $queryExeA->execute();\n return true;\n }", "title": "" }, { "docid": "93fc3ef298cf15735e0d8fb568ca093f", "score": "0.6689424", "text": "public function updateUser(){\n\t\t\tif($this->comprobarpaciente($this->datos)){\n\n\t\t\t\t$this->paciente->updateUser( $this->datos->id, \n\t\t\t\t\t$this->datos->email, $this->datos->pass, \n\t\t\t\t\t$this->datos->nombre);\n\n\t\t\t\t$this->returnTrue();\n\t\t\t}else{\n\t\t\t\t$this->returnFalse();\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "3989da6e737f29763ae92636dc1ab3b0", "score": "0.66755354", "text": "public function update(Admin $user)\n {\n return$this->getPermission($user,'post-upate');\n\n }", "title": "" }, { "docid": "e85fcf7557f773293ecfef3656f9a6e9", "score": "0.66535556", "text": "function update () {\n\t\t$permissions_json = json_encode($this->permissions);\n\n\t\t$stm = DB::$pdo->prepare(\"update `user` \n\t\t\t\t\t\t\t\t set `username`=:username, `email_address`=:email_address, `timezone`=:timezone, `level`=:level, `permissions`=:permissions_json \n\t\t\t\t\t\t\t\t where `id`=:id\");\n\t\t$stm->bindParam(':username', $this->username);\n\t\t$stm->bindParam(':email_address', $this->email_address);\n\t\t$stm->bindParam(':timezone', $this->timezone);\n\t\t$stm->bindParam(':level', $this->level);\n\t\t$stm->bindParam(':permissions_json', $permissions_json);\n\t\t$stm->bindParam(':id', $this->id);\n\t\t$stm->execute();\n\t}", "title": "" }, { "docid": "a3b06be6f105350e79072fc36a16c6e9", "score": "0.6645367", "text": "public function promote_to_admin()\n {\n check_login_session('user_session');\n is_not_admin('user_session');\n $user_id = base64_decode(Param::get('u'));\n\n $users = new User();\n $users->promoteToAdmin($user_id);\n\n $success_message = \"Promoted User {$user_id} to Admin\";\n redirect(url('user/users', array('m' => $success_message)));\n }", "title": "" }, { "docid": "32424f92760206188366d7bee55b24c7", "score": "0.6644806", "text": "function admin_edit($data){\n\t\tglobal $db;\n\t\tif (!is_array($data))\n\t\t\t{\n\t\t\treturn false;\n\t\t\t}\n\n\t\t//we need not update the password.\n\t\t//this will be done by other link\n\t\t\n\t\t//get the permission array\n\t\t\n\t\t$perms_values = array('man_home','man_link','man_content','man_event','man_admin');\n\t\t$perms = $data['permission'];\n\t\t\n\t\t\n\t\tif (isset($perms)) \n\t\t\t{\n\t\t\tforeach($perms_values as $perm) \n\t\t\t\t{\n\t\t\t\tif ( in_array($perm, $perms)) {\n\t\t\t\t\t\t$admin_perms[$perm] = 1;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$admin_perms[$perm] = 0;\n\t\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tforeach($perms_values as $perm) {\n\t\t\t\t\t$admin_perms[$perm] = 0;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\n\t\t \n\t\t$sQl = \"update cms_admin set\n\t\t\t\t`first_name`='\".$data['fname'].\"',\n\t\t\t\t`last_name`='\".$data['lname'].\"',\n\t\t\t\t`admin_email`='\".$data['email'].\"',\n\t\t\t\t`username`='\".$data['username'].\"',\n\t\t\t\t`admin_status`='\".$data['admin_status'].\"',\n\t\t\t\t`man_home`='\".$admin_perms['man_home'].\"',\n\t\t\t\t`man_link`='\".$admin_perms['man_link'].\"',\n\t\t\t\t`man_content`='\".$admin_perms['man_content'].\"',\n\t\t\t\t`man_event`='\".$admin_perms['man_event'].\"',\n\t\t\t\t`man_admin`='\".$admin_perms['man_admin'].\"'\n\t\t\t\twhere id='\".$data['id'].\"'\";\t\t\t\t\n\t\t\t\n\t\t\t$resAdd = $db->query($sQl);\n\t\t\n\t\tif ($resAdd)\n\t\t\t{\n\t\t\t$this->message = \"Admin details have been changed successfully\";\n\t\t\treturn true;\t\t\n\t\t\t} else {\n\t\t\t\t$this->error = \"Cannot update admin record or no change in record\";\t\t\t\n\t\t\t\treturn false;\n\t\t\t\t}\n\t}", "title": "" }, { "docid": "6900e271d2e3e50000e6806564462d99", "score": "0.6635285", "text": "public function pageUpdateUser()\n\t\t{\n\t\t\t$this->loadDao('User');\n\n\t\t\t// if the user is connected\n\t\t\tif(isset($_SESSION['id']))\n\t\t\t{\n\t\t\t\t// Select and stores data of the user in the variable $d\n\t\t\t\t$d['user'] = $this->DaoUser->read($_SESSION['id']);\n\n\t\t\t\t// Sends them...\n\t\t\t\t$this->set($d);\n\n\t\t\t\t// ...to the view 'pageUpdateUser'\n\t\t\t\t$this->render('User','pageUpdateUser');\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "8a1441514569d239e39d0438283cb74d", "score": "0.6628349", "text": "function promouvoirAdmin($idUser)\n{\n $SQL = \"UPDATE users SET admin = 1 WHERE users.id ='$idUser'\";\n return SQLUpdate($SQL);\n}", "title": "" }, { "docid": "0cc40dde4a24d94b5287205945270e4e", "score": "0.6588733", "text": "public function edit_postAction() {\r\n\t\t$info = $this->getPost(array('id', 'status', 'user_type'));\r\n\t\t$ret = Ola_Service_User::update($info, intval($info['id']));\r\n\t\tif (!$ret) $this->output(-1, '更新用户失败');\r\n\t\t$this->output(0, '更新用户成功.'); \t\t\r\n\t}", "title": "" }, { "docid": "48fbd8f19826a73d7fa0c28b925d1bc8", "score": "0.6559045", "text": "public function update(admin $user)\n {\n //\n return $this->getPermission($user, 5);\n\n }", "title": "" }, { "docid": "526eb07ebee9d46366d3c82f37938d98", "score": "0.65541726", "text": "public function updateUserEntry(){\r\n \t $sql=\"UPDATE z_users \r\n \t \t\tSET first_name='\".$this->dbOb->escape_string($this->data['first_name']).\"',\r\n \t \t\t last_name='\".$this->dbOb->escape_string($this->data['last_name']).\"',\r\n \t \t\t email='\".$this->dbOb->escape_string($this->data['email']).\"',\r\n \t \t\t login='\".$this->dbOb->escape_string($this->data['email']).\"'\r\n \t \t\tWHERE id='\".$this->dbOb->escape_string($this->id).\"'\";\r\n \t $this->dbOb->update($sql);\r\n \t unset($this->data['email']);\r\n \t unset($this->data['first_name']);\r\n \t unset($this->data['last_name']);\r\n \t $sql=\"UPDATE u_profile SET \";\r\n \t $sqlEnt=array();\r\n \t foreach($this->data as $key=>$value){\r\n \t \t$sqlEnt[]=\"`\".$key.\"`='\".$this->dbOb->escape_string($value).\"'\";\r\n \t }\r\n \t $sql.=implode(\",\",$sqlEnt).\" WHERE z_user_id='\".$this->dbOb->escape_string($this->id).\"'\";\r\n \t $this->dbOb->update($sql);\r\n }", "title": "" }, { "docid": "fcdf6897e4dac1f30500e6e93ed46283", "score": "0.65486985", "text": "public function testUpdateUser()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "title": "" }, { "docid": "16883ba9a681574657900ba67b78f67a", "score": "0.6542004", "text": "public function update() {\n\n echo $this->templates->render('user/update');\n }", "title": "" }, { "docid": "b110586a558761eb2687b5e95ecef452", "score": "0.6538321", "text": "public function updateAuthUserSetting($user, $request);", "title": "" }, { "docid": "645d97f559ecb71ba0da9bc53ce9352d", "score": "0.65227777", "text": "public function updateUserMeta()\r\n {\r\n $userId = get_current_user_id();\r\n $currentRev = intval(get_user_meta($userId, 'lbwp_user_meta_revision', true));\r\n\r\n // If revision has been raised, change user meta on certain condition\r\n if ($currentRev < Core::REVISION) {\r\n // Updates for revision 107\r\n if ($currentRev < 107 && Core::REVISION >= 107) {\r\n // Set some variables for yoast\r\n update_user_meta($userId, 'wpseo_seen_about_version', '3.0.7');\r\n update_user_meta($userId, 'wpseo_ignore_tour', 1);\r\n }\r\n if ($currentRev < 192 && Core::REVISION >= 192) {\r\n // Set some variables for yoast\r\n $this->dismissWpPointer('wpmudcs1', $userId);\r\n }\r\n\r\n // Save new revision after doing all upgrades\r\n update_user_meta($userId, 'lbwp_user_meta_revision', Core::REVISION);\r\n }\r\n }", "title": "" }, { "docid": "ee031ea20a8709c6e29e746c41ec806e", "score": "0.6517347", "text": "public function adminAccount($h)\n\t{\n\t\treturn $h->currentUser->updateAccount($h);\n\t}", "title": "" }, { "docid": "3ae4f1edc1082e3a6b9bd5459c848da0", "score": "0.65019697", "text": "public function edit_admin($data){\n $this->db->query(\"UPDATE admins SET admin_name = :name, admin_surname = :surname, admin_mobile_number = :mobile_number, admin_email = :email, admin_username = :username WHERE admin_id = :id\");\n $this->db->bind(':name', $data['name']);\n $this->db->bind(':surname', $data['surname']);\n $this->db->bind(':email', $data['email']);\n $this->db->bind(':mobile_number', $data['mobile_number']);\n $this->db->bind(':id', $data['id']);\n $this->db->bind(':username', $data['username']);\n\n //execute\n if($this->db->execute()){\n return true;\n }\n else{\n return false;\n }\n }", "title": "" }, { "docid": "b4e50be1585fd3011ed887eb43d88d5e", "score": "0.6489277", "text": "public static function updateUsers(): void\n {\n if (!User::getUserSession()->role)\n self::logout();\n $users = User::getAll();\n Router::render(Cfg::get('updateusers'), ['users' => $users]);\n }", "title": "" }, { "docid": "d7a55baab477930a483be32b77277723", "score": "0.6488999", "text": "public function Update() {\n\t\t$sql = \"\n\t\t\t\tUPDATE administrador SET\n\t\t\t\t\n\t\t\t\t login_administrador = '$this->login_administrador',\n\t\t\t\t senha_administrador = '$this->senha_administrador',\n\t\t\t\t nome_administrador = '$this->nome_administrador'\n\t\t\t\t\n\t\t\t\tWHERE id_administrador = '$this->id_administrador';\n\t\t\t\t\n\t\t\t\";\n\t\t\n\t\t$DB = new DB ();\n\t\t$DB->open ();\n\t\t$result = $DB->query ( $sql );\n\t\t$DB->close ();\n\t\treturn $result;\n\t}", "title": "" }, { "docid": "5024a0d6d49b630ccddbb1dd98f708f2", "score": "0.6481873", "text": "public function updateadmin($id=FALSE)\n\t{\n\t\tif($id)\n\t\t{\n\t\t\t$data['aud']=$this->Admin_m->get_update_entity($id);\n\t\t\tget_views('updateadmin', 'Update Admin Details', $data);\n\t\t}\n\t}", "title": "" }, { "docid": "fe554d7b9fd4f5793654da9526d0b42c", "score": "0.64736694", "text": "public function actionUpdate()\n\t{ \n $id=isset($_GET['id']) ? (int) ($_GET['id']) : 0 ;\n \n $this->menu=array_merge($this->menu, \n array(\n array('label'=>t('Update this user'), 'url'=>array('update','id'=>$id),'linkOptions'=>array('class'=>'btn btn-mini')),\n array('label'=>t('View this user'), 'url'=>array('view','id'=>$id),'linkOptions'=>array('class'=>'btn btn-mini'))\n )\n );\n\t\t$this->render('user_update');\n\t}", "title": "" }, { "docid": "b9d76571254af05ee30ce0d1ebf6343b", "score": "0.64728844", "text": "public function change_admin_user( $args, $assoc_args ) {\n\t\t$username = \\WP_CLI\\Utils\\get_flag_value( $assoc_args, 'username' );\n\t\t$change_id = \\WP_CLI\\Utils\\get_flag_value( $assoc_args, 'change-id', false );\n\n\t\tif ( ! $username && ! $change_id ) {\n\t\t\tWP_CLI::error( 'Must include --username or --change-id.' );\n\t\t}\n\n\t\t$changed = itsec_change_admin_user( $username, $change_id );\n\n\t\tif ( $changed ) {\n\t\t\tWP_CLI::success( 'Updated.' );\n\t\t} else {\n\t\t\tWP_CLI::error( 'The user was unable to be successfully updated. This could be due to a plugin or server configuration conflict.' );\n\t\t}\n\t}", "title": "" }, { "docid": "c74143455987a44456887fde8dabaecb", "score": "0.6465697", "text": "public function updateAdminUser(Request $request)\n {\n \t$user_id = $request->id;\n \t$update_array=array();\n\n \tif($request->has('is_block'))\n \t{\n \t\t$is_block = $request->is_block;\n \t\t$update_array = ['is_block'=>$is_block];\n \t}\n \t\n \t$updated_id = Admin::where('id',$user_id)->update($update_array);\n \treturn response()->json(array('message'=>'Successfully updated'));\n }", "title": "" }, { "docid": "70b8c980db2f0851a21b5d720228f8cc", "score": "0.64539397", "text": "public function updateUser(){\n\t\tif (Session::get('user_login_status') == 1) {\n\t\t\tif (isset($_POST['current_password'])) {\n\t\t\t\t$this->versionPhp() AND require PASS_COM_LIB;\n\t\t\t\t$usermodel = $this->model('UserModel');\n\t\t\t\t$result = $usermodel->updateUserData();\n\t\t\t\techo json_encode($result);\n\t\t\t}else{\t\n\t\t\t\theader('location: '.URL.'user');\n\t\t\t}\n\t\t}else{\n\t\t\theader('location: '.URL.'user');\n\t\t}\n\t}", "title": "" }, { "docid": "1acd3c63ad280686e622eac74966d997", "score": "0.64538527", "text": "public function action_update()\n {\n // user validation\n $this->validateUserAuthentification();\n\n // Load the user information\n $user = Auth::instance()->get_user();\n\n // if a user is not logged in, redirect to login page\n if (!$user) {\n HTTP::redirect($this->getProtocol() . $_SERVER['HTTP_HOST'] . 'cms/user/login');\n }\n\n if (HTTP_Request::POST == $this->request->method()) {\n try {\n $d = json_decode($this->request->body());\n $user = ORM::factory('user', $d->id);\n // check if the name stays the same\n if ($d->username == $user->username) {\n $user->email = $d->email;\n $user->save();\n\n echo '{\"success\":true}';\n } // else check if the new name is not yet in use for another user\n else if (!ORM::factory('user')->unique_key_exists($d->username, 'username')) {\n $user->username = $d->username;\n $user->email = $d->email;\n $user->save();\n\n echo '{\"success\":true}';\n } // else give an error\n else {\n echo '{\"success\":false,\"message\":\"This username already exists.\"}';\n }\n } catch (Exception $e) {\n echo '{\"success\":false,\"message\":\"' . $e->getMessage() . '\"}';\n }\n }\n die();\n }", "title": "" }, { "docid": "36f0b2724b4a0897b23e3a432c8901db", "score": "0.64506966", "text": "function putAdmin() {\n\t\ttry{\n\t\t\tglobal $database;\n\n\t\t\tif(is_numeric($_POST['adminId'])) {\n\t\t\t\t$adminId = $_POST['adminId'];\n\t\t\t\t$fName = filterString($_POST['firstName']);\n\t\t\t\t$lName = filterString($_POST['lastName']);\n\t\t\t\t$username = filterString($_POST['username']);\n\n\t\t\t\tif(is_numeric($_POST['accessLevel'])) { //Validate the the access level is an integer\n\t\t\t\t\t$accessLevel = $_POST['accessLevel'];\n\t\t\t\t} else {\n\t\t\t\t\t$accessLevel = 1;\n\t\t\t\t}\n\n\t\t\t\t$department = getDepartmentId(filterString($_POST['department']));\n\n\t\t\t\t$admin = new admin($database, $adminId);\n\t\t\t\t$admin->fetch();\n\t\t\t\t$admin->putParams($fName, $lName, $username, $accessLevel, $department);\n\t\t\t} else {\n\t\t\t\t$returnMessage = alert(\"danger\", \"Please input a numerical ID\");\n\t\t\t}\n\t\t} catch(dbException $db){\n\t\t\t$returnMessage = $db->alert();\t\n\t\t}\n\t}", "title": "" }, { "docid": "e0c014aaa8d1a55462cf7765dd9da6bc", "score": "0.6449708", "text": "public function update()\n {\n Auth::userIs(\"Administrator\");\n\n // Get segment 3 to get passed user ID\n $UserID = isset(App::$segment[3]) ? App::$segment[3] : false;\n\n // Redirect to users list when false\n if(!$UserID) { \n View::redirect('admin/users/');\n }\n\n // Load models {*** Can be loaded in __construct but lets just load the needed model per page}\n $this->load->model('users');\n $this->load->model('usermeta');\n $this->load->model('roles');\n $this->load->model('capabilities');\n $this->load->model('capabilitygroups');\n\n if( App::$post ) { \n\n // Parse post data\n $user = isset(App::$post['user']) ? App::$post['user'] : array();\n $meta = isset(App::$post['meta']) ? App::$post['meta'] : array();\n $capa = isset(App::$post['capa']) ? App::$post['capa'] : array();\n\n $errorText = '';\n $hasError = false;\n\n // Check valid emails\n if( isset($user['Email']) && !filter_var( $user['Email'], FILTER_VALIDATE_EMAIL ) ) {\n $errorText .= '* The email you have entered is invalid! Please enter a valid email address.<br>';\n $hasError = true;\n $errorFields[] = 'Email';\n }\n\n // Check valid password length\n if( strlen( App::$post['Password'] ) > 0 && strlen( App::$post['Password'] ) < 4 ) {\n $errorText .= '* Password should be minimum of 4 alphanumeric characters! please enter the password again.<br>';\n $hasError = true;\n $errorFields[] = 'Password';\n }\n\n // Check if email already exists\n if( User::infoByEmail( 'UserID', $user['Email'] ) != $UserID && User::infoByEmail( 'UserID', $user['Email'] ) ) {\n $errorText .= '* The email you entered already existing.<br>';\n $hasError = true;\n $errorFields[] = 'Email';\n }\n\n if( $hasError ) {\n App::setSession( 'error', $errorText );\n } else { \n \n \n // Get session ID's\n $updateSession = App::getSession('updateSession'.$UserID);\n\n // Check if password is set\n if( strlen(App::$post['Password']) > 0 ) {\n // Encrypt password\n $user['Password'] = App::encrypt( App::$post['Password'] );\n\n // Add hash key\n $user['HashKey'] = App::encryptHash( App::$post['Password'] );\n }\n\n if(App::$file && App::$file['Avatar']['name']) {\n $meta['Avatar'] = Media::upload( App::$file, $UserID, 'Avatar', true );\n }\n\n // Sanitize capabilities array\n $user['Capability'] = (string) App::jsonEncode($capa);\n\n // Update user security information \n Users::update( $user, $UserID );\n\n // Update user meta data\n UserMeta::update( $meta, $updateSession['UserMetaID'] );\n\n if($UserID == User::info('UserID')) {\n Auth::updateUserSession();\n }\n\n // Output a message\n App::setSession( 'message', \"User has been updated!\" );\n }\n }\n\n // Get all capabilities\n $capabilities = Capabilities::all(['group' => 'CapabilityGroupID']);\n\n // Get all capabilitie groups as array\n $capagroup = CapabilityGroups::all(['index' => 'CapabilityGroupID']);\n \n // Get all roles from user_levels table\n $roles = Roles::all();\n $u = Users::getOne($UserID);\n $avatar = Media::getOne($u->Avatar);\n $capas = App::jsonDecode($u->Capability);\n\n $updateSession = [\n 'UserID' => $UserID,\n 'UserMetaID' => $u->UserMetaID\n ]; \n\n App::setSession('updateSession'.$UserID, $updateSession);\n\n // Load the view page\n View::page('users/update', get_defined_vars());\n }", "title": "" }, { "docid": "d8e03eb2f1ce0ab49f1d1e7c433b66f6", "score": "0.64484787", "text": "public function updateUserMainInfo(SGL_Registry $input, SGL_Output $output)\n {\n $aUser = $this->req->get('user');\n\n $aData = array();\n $aAllowedFields = array('first_name', 'last_name');\n foreach ($aAllowedFields as $fieldName) {\n $aData[$fieldName] = isset($aUser[$fieldName])\n ? $aUser[$fieldName] : '';\n }\n\n $ok = $this->da->updateUserById(SGL_Session::getUid(), $aData);\n if (!PEAR::isError($ok)) {\n $this->_raiseMsg('user information updated', $trans = true);\n }\n }", "title": "" }, { "docid": "0f9fbfbcfdc6b7fe95dcb08c861c6e49", "score": "0.6444987", "text": "public function update(Request $request, AdminUser $adminUser)\n {\n //\n }", "title": "" }, { "docid": "6e0bf79632f0148f439a41fe87cffed5", "score": "0.6440132", "text": "public function update_user($data){\n\n }", "title": "" }, { "docid": "62fb5bc7dfef9dbca74ea141d1f4db3f", "score": "0.6438828", "text": "public function updateAction()\r\n {\r\n $this->di->session();\r\n $form = new \\Anax\\HTMLForm\\CFormPsWebUpdateUser();\r\n $form->setDI($this->di);\r\n $form->check();\r\n\r\n $this->di->theme->setTitle(\"Users Delete Menu\");\r\n\r\n $this->di->views->add('default/page', [\r\n 'title' => \"Users Soft Delete (update) Menu\",\r\n 'content' => $form->getHTML()\r\n ]);\r\n }", "title": "" }, { "docid": "1d53766ee08bb1937e65c321cc4617fd", "score": "0.64311683", "text": "public function modify_admin($data){\n\t\t//convert permissions into a string of characters\n\t\t$perms=\"\";\n\t\tif(isset($data['perms'])){\n\t\t\tforeach($data['perms'] as $x){\n\t\t\t\t$perms.= $x;\n\t\t\t}\n\t\t}\n\n\t\t$data['perms'] = $perms;\n\t\t//check for empty fields. If any return error.\n\t\tif(empty($data['username']) || empty($data['email']) || empty($data['perms'])){\n\t\t\t$data['errors']=\"You must complete all fields.\";\n\t\t\treturn $data;\n\t\t\texit;\n\t\t}\n\n\t\t//check that email is a valid email address\n\t\tif(filter_var($data['email'], FILTER_VALIDATE_EMAIL) === false) {\n\t\t\t$data['errors'] = 'Please enter a valid email address';\n\t\t}\n\n\t\t//check if email is already taken. Ignore the admin user being modified form search to prevent false positives if email is being submitted without changes\n\t\t$query = $this->db->prepare(\"select email from `admins` WHERE username<>?\"); \n\t\t$query->bindParam(1, $data['username']); \n\t\ttry{\n\t\t\t$query->execute();\n\t\t}catch(PDOException $e){\n\t\t\tdie($e->getMessage());\n\t\t}\n\t\twhile($results= $query ->fetch(PDO::FETCH_ASSOC)) {\n\t\t\tif($data['email'] == $results['email']){\n\t\t\t\t$data['errors'] = \"The email specified is already in use. [$_POST[email]]\";\n\t\t\t}\n\t\t}\n\n\t\t//if errors then return to form and display errors\n\t\tif(isset($data['errors']) && !empty($data['errors'])){\n\t\t\treturn $data;\n\t\t\texit;\n\t\t}\n\n\n\t\t//detect if password has been changed, run appropriated query\n\t\tif(empty($data['password'])){//no password change\n\t\t\t$query = $this->db->prepare(\"UPDATE admins SET username=?, email=?, permissions=? WHERE username =?\");\n\t\t\t$query->bindParam(1, $data['username']); \n\t\t\t$query->bindParam(2, $data['email']); \n\t\t\t$query->bindParam(3, $data['perms']);\n\t\t\t$query->bindParam(4, $data['username']);\n\t\t}\n\t\telse{//password changed\n\t\t\t//encrypt new password\n\t\t\tglobal $bcrypt;\n\t\t\t$data['password'] = $bcrypt->genHash($data['password']);\n\t\t\t$query = $this->db->prepare(\"UPDATE admins SET username=?, password=?, email=?, permissions=? WHERE username =?\");\n\t\t\t$query->bindParam(1, $data['username']); \n\t\t\t$query->bindParam(2, $data['password']); \n\t\t\t$query->bindParam(3, $data['email']); \n\t\t\t$query->bindParam(4, $data['perms']);\n\t\t\t$query->bindParam(5, $data['username']); \n\n\t\t}\n\t\ttry{\n\t\t\t$query->execute();\n\t\t}catch(PDOException $e){\n\t\t\tdie($e->getMessage());\n\t\t}\n\n\t\theader(\"Location:admins.php\");\n\t\texit;\n\n\t}", "title": "" }, { "docid": "89a241769ca5d270a9895589b882d418", "score": "0.64257383", "text": "function updateUser($wpUser)\n\t{\n\t\t$userData = array(\n\t\t\t\t'uid'=>$wpUser->ID,\n\t\t\t\t'uname'=>$wpUser->display_name,\n\t\t\t\t'login_name'=>$wpUser->user_login,\n\t\t\t\t'email'=>$wpUser->user_email,\n\t\t\t\t'timezone_offset'=> 0,\n\t\t\t\t);\n\t\tif($wpUser->ID!=1)\n\t\t{\n\t\t\tif(Formulize::updateUser($wpUser->ID,$userData))\n\t\t\t{\n\t\n\t\t\t}\n\t\t}\n\t\t\n\t}", "title": "" }, { "docid": "0883ac1547ceb19b269a9e714c2ca8b1", "score": "0.64217997", "text": "protected function update()\n {\n // @TODO: Use prepared statements to ensure data security\n\n // @TODO: You will need to iterate through all the attributes to build the prepared query\n $stmt = self::$dbc->prepare('UPDATE users SET username = :username, password = :password, email = :email WHERE id = :id');\n $stmt->bindValue(':username', $this->attributes['username'], PDO::PARAM_STR);\n $stmt->bindValue(':password', $this->attributes['password'], PDO::PARAM_STR);\n $stmt->bindValue(':email', $this->attributes['email'], PDO::PARAM_STR);\n $stmt->bindValue(':id', $this->attributes['id'], PDO::PARAM_INT);\n $stmt->execute();\n }", "title": "" }, { "docid": "7a0c7522fa6da27241980e040b7084b7", "score": "0.63970107", "text": "function ciniki_users_addSysAdmin($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 'user_id'=>array('required'=>'yes', 'blank'=>'no', 'name'=>'User'), \n ));\n if( $rc['stat'] != 'ok' ) {\n return $rc;\n }\n $args = $rc['args'];\n \n //\n // Check access \n //\n ciniki_core_loadMethod($ciniki, 'ciniki', 'users', 'private', 'checkAccess');\n $rc = ciniki_users_checkAccess($ciniki, 0, 'ciniki.users.addSysAdmin', 0);\n if( $rc['stat'] != 'ok' ) {\n return $rc;\n }\n\n //\n // Update the user to set the sysadmin flag\n //\n $strsql = \"UPDATE ciniki_users SET perms = perms | 0x01 \"\n . \"WHERE id = '\" . ciniki_core_dbQuote($ciniki, $args['user_id']) . \"'\";\n ciniki_core_loadMethod($ciniki, 'ciniki', 'core', 'private', 'dbUpdate');\n return ciniki_core_dbUpdate($ciniki, $strsql, 'ciniki.users');\n}", "title": "" }, { "docid": "59c2d1842292fbcd10a28bca38abdf7f", "score": "0.63956887", "text": "function editadmin($user,$name,$nick,$email,$rol,$phone){\n\n\n\t\t\tif(!empty($user) && !empty($email) && !empty($name)){\n\n\t\t\t\t$sql='SELECT * FROM usuarios WHERE id_usuario = :id_user';\n\t\t\t\t$this->query($sql);\n\t\t\t\t$this->bind(':id_user', $user);\n\t\t\t\t$this->execute();\n\t\t\t\t$this->single();\n\n\t\t\t\tif($this->rowCount() == 0){\n\t\t\t\t\t$msg = array('response' => 'user_not_exists');\n\t\t\t\t}else{\n\n\t\t\t\t\t$sql=\"UPDATE usuarios SET email = :email, nombre = :name, telefono_contacto = :phone, rol = :rol, apodo = :nick WHERE id_usuario = :id_user\";\t\n\t\t\t\t\t$this->query($sql);\n\t\t\t\t\t$this->bind(':id_user', $user);\t\n\t\t\t\t\t$this->bind(':email', $email);\n\t\t\t\t\t$this->bind(':name', $name);\n\t\t\t\t\t$this->bind(':nick', $nick);\n\t\t\t\t\t$this->bind(':phone', $phone);\n\t\t\t\t\t$this->bind(':rol', $rol);\n\t\t\t\t\t$res2 = $this->execute();\n\t\t\t\t\tif($this->rowCount() > 0){\n\t\t\t\t\t\t$msg = array('response' => 'updated');\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$msg = array('response' => 'cannot_update');\n\t\t\t\t\t}\n\t\t\t\t}\t\t\n\t\t\t}else{\n\t\t\t\t$msg = array('response' => 'missing_params');\n\t\t\t}\n\n\t\t\treturn $msg;\n\t\t}", "title": "" }, { "docid": "29b33af83e073a7b7dc0e93b8550d1f9", "score": "0.63951993", "text": "function aupdate_btn(){\n\tglobal $db, $errors, $username, $email;\n\n\t// receive all input values from the form. Call the e() function\n // defined below to escape form values\n\t$id = e($_POST['id']);\n\t$username = e($_POST['username']);\n\t$email = e($_POST['email']);\n\t$firstname = e($_POST['firstname']);\n\t$lastname = e($_POST['lastname']);\n\t$phonenumber = e($_POST['phonenumber']);\n\t$password_1 = e($_POST['password_1']);\n\t$password_2 = e($_POST['password_2']);\n\n\t// form validation: ensure that the form is correctly filled\n\tif (empty($username )) {\n\t\tarray_push($errors, \"Username is required\");\n\t}\n\tif (empty($email)) {\n\t\tarray_push($errors, \"Email is required\");\n\t}\n\tif (empty($password_1)) {\n\t\tarray_push($errors, \"Password is required\");\n\t}\n\tif ($password_1 != $password_2) {\n\t\tarray_push($errors, \"The two passwords do not match\");\n\t}\n\n\t// register user if there are no errors in the form\n//\t\t$password = md5($password_1);//encrypt the password before saving in the database\n\t\t\t$password = $password_1;\n\t\t\tif (isset($_POST['admin'])) {\n\t\t\t\t$user_type = e($_POST['admin']);\n\t\t\t\t$query = \"update users set email='$email', firstname='$firstname', lastname='$lastname', phonenumber='$phonenumber', password='$password' WHERE id='$id'\";\n\t\t\t\tmysqli_query($db, $query);\n\t\t\t\t$_SESSION['success'] = \"Updated successfully!!\";\n\t\t\t}else{\n\t\t\t\t$query = \"update users set email='$email', firstname='$firstname', lastname='$lastname', phonenumber='$phonenumber', password='$password' WHERE id\t='$id'\";\n\t\t\t\tmysqli_query($db, $query);\n\n\t\t\t\t// get id of the created user\n\t\t\t\t$logged_in_user_id = $id;\n\n\t\t\t\t$_SESSION['user'] = getUserById($logged_in_user_id); // put logged in user in session\n\t\t\t\t$_SESSION['success'] = \"Updated Successfully\";\n\t\t\t}\n\n}", "title": "" }, { "docid": "691865aeff35926785aacaa1cb9dd82d", "score": "0.6390006", "text": "static function wp_crm_save_user_data() {\r\n\r\n if ( !empty($_REQUEST[ 'wp_crm_update_user' ]) && wp_verify_nonce( $_REQUEST[ 'wp_crm_update_user' ], 'wp_crm_update_user' ) ) {\r\n $args = !empty($_REQUEST[ 'wp_crm' ][ 'args' ])?$_REQUEST[ 'wp_crm' ][ 'args' ]:array();\r\n\r\n $user_data = $_REQUEST[ 'wp_crm' ][ 'user_data' ];\r\n\r\n //** Add extra user_data data */\r\n $user_data[ 'admin_color' ][ 0 ][ 'value' ] = $_REQUEST[ 'admin_color' ];\r\n $user_data[ 'show_admin_bar_front' ][ 0 ][ 'value' ] = $_REQUEST[ 'show_admin_bar_front' ];\r\n\r\n $args[ 'admin_save_action' ] = true;\r\n\r\n do_action( 'wp_crm_before_save_user_data', $_REQUEST );\r\n wp_crm_save_user_data( $user_data, $args );\r\n }\r\n\r\n }", "title": "" }, { "docid": "be064bc53d71208dcffa3ec8e9ac39b7", "score": "0.6388118", "text": "public function addAdminAction() {\n\n //批量添加\n $user = new Userinfo;\n $list = [\n ['user_name' => 'wangwu', 'password' => 'wangwu.com'],\n ['user_name' => 'lisi', 'password' => 'lisi.com']\n ];\n $user->saveAll($list);\n }", "title": "" }, { "docid": "120bd7c00cd9e4804a49ea2d4ec889f5", "score": "0.6384097", "text": "protected function updateUser($data)\n {\n $user = $this->user;\n\n $user->first_name = $data->first_name;\n $user->last_name = $data->last_name;\n $user->mail = $data->contact_email;\n $user->week_duration = $data->working_time * 60;\n $user->active = ($data->status === 'Active');\n\n if (!$user->exists) {\n $user->hourly_cost = 0;\n $user->applyNewApiKey();\n }\n\n $user->save();\n }", "title": "" }, { "docid": "8eb8da6a69241aca00f9363b4949a53d", "score": "0.6381864", "text": "public function updatePassAdmin()\n {\n $this->loginAsAdmin();\n\n $admin = $this->admin();\n\n $this->assertTrue($admin->can('updatePass', $admin));\n $this->assertTrue($admin->can('updatePass', new User()));\n }", "title": "" }, { "docid": "1989d5fe6363e74153c8bbe1e5328324", "score": "0.6381349", "text": "public function updated(Admin $admin)\n {\n //\n }", "title": "" }, { "docid": "b7221c50f2735ae105d0b89c6998f83f", "score": "0.637679", "text": "function userModify() {\r\n\t$userData = yaml::read('application/config/config.yml');\r\n\t$apikey = $userData['apikey'];\r\n\t$nicename = $userData['nicename'];\r\n\tif ($_POST['nicename'] !== '') {\r\n\t\t$nicenameNew = $_POST['nicename'];\r\n\t} else {\r\n\t\t$nicenameNew = $userData['nicename'];\r\n\t}\r\n\tif ($_POST['passwordNew'] !== '') {\r\n\t\tif(!password::match($_POST['password'], $userData['password'])) {\r\n\t\t\techo '<div class=\"alert alert-danger\" role=\"alert\">\r\n\t\t\t<p class=\"mb-0\">The current password you entered is incorrect.</p>\r\n\t\t\t</div>';\r\n\t\t} else {\r\n\t\t\tif ($_POST['passwordNew'] !== $_POST['passwordNewConfirm']) {\r\n\t\t\t\techo '<div class=\"alert alert-danger\" role=\"alert\">\r\n\t\t\t\t<p class=\"mb-0\">New password and new password confirmation must match.</p>\r\n\t\t\t\t</div>';\r\n\t\t\t} else {\r\n\t\t\t\t$passwordNew = password::hash($_POST['passwordNew']);\r\n\t\t\t}\r\n\t\t}\r\n\t} else {\r\n\t\t$passwordNew = $userData['password'];\r\n\t}\r\n\tif ($_POST['apikeyNew'] !== '') {\r\n\t\t$apikeyNew = $_POST['apikeyNew'];\r\n\t} else {\r\n\t\t$apikeyNew = $userData['apikey'];\r\n\t}\r\n\r\n\tyaml::write('application/config/config.yml', array(\r\n\t\t'username' => $userData['username'],\r\n\t\t'password' => $passwordNew,\r\n\t\t'apikey' => $apikeyNew,\r\n\t\t'nicename' => $nicenameNew\r\n\t));\r\n\r\n\techo '<div class=\"alert alert-success\" role=\"alert\">\r\n\t<p class=\"mb-0\">Your modifications were successfully saved.</p>\r\n\t</div>';\r\n\theader(\"Refresh: 1;url=\");\r\n\texit;\r\n}", "title": "" }, { "docid": "9a0004d9bdbcd0596cef18276751fcd1", "score": "0.63754237", "text": "public function testUpdateProfileBySuperAdmin()\n {\n $token = $this->loginRole('super-admin');\n\n $profile = Profile::first();\n\n // Create data\n $data = [\n 'nickname' => 'Test Update',\n ];\n\n // Request\n $response = $this->put('api/v1/profiles/' . $profile->id . '?token=' . $token, $data);\n\n // Check response status\n $response->assertStatus(200);\n\n // Check response structure\n $response->assertJsonStructure(\n [\n 'success',\n 'code',\n 'data' =>\n [\n 'id',\n 'user_id',\n 'nickname',\n 'quiet_time_from',\n 'quiet_time_to',\n 'created_at',\n 'updated_at'\n ],\n 'message'\n ]\n );\n $responseJSON = json_decode($response->getContent(), true);\n $success = $responseJSON['success']; // array\n $code = $responseJSON['code']; // array\n $message = $responseJSON['message']; // array\n $data = $responseJSON['data']; // array\n\n $this->assertEquals(true, $success);\n $this->assertEquals(200, $code);\n $this->assertCount(7, $data);\n $this->assertEquals('Test Update', $data['nickname']);\n $this->assertEquals(\"Updated The Profile.\", $message);\n }", "title": "" }, { "docid": "6b21b76f66222da9d802b6f329be8526", "score": "0.63681704", "text": "public function p_edit() {\n if(strlen($_POST['alias']) < 3) {\n\n # Send them back to the sign up page\n Router::redirect(\"/users/profile/\".$this->user->alias.\"/length\");\n }\n\n # More data we want stored with the user\n $_POST['modified'] = Time::now();\n\n # Get the users' info\n $q = \"SELECT *\n FROM users\n WHERE user_id = \".$this->user->user_id;\n\n # Execute the query to get the user's info. \n # Store the result array in the variable $user\n $user = DB::instance(DB_NAME)->select_row($q);\n\n # Store the user_id in the variable $user_id\n $user_id = $user['user_id'];\n\n if($_FILES['logo']['name'] != '') {\n\n # Upload the logo image\n $logo = Upload::upload($_FILES, \"/uploads/avatars/\", array(\"jpg\", \"jpeg\", \"gif\", \"png\"), $user_id);\n\n if($logo == 'Invalid file type.') {\n // return an error\n Router::redirect(\"/users/profile/\".$_POST['alias'].\"/filetype\"); \n }\n\n $_POST['logo'] = $user_id;\n # resize the image\n \n $imgObj = new Image($_SERVER[\"DOCUMENT_ROOT\"] . '/uploads/avatars/' . $logo);\n $imgObj->resize(100,100, \"crop\");\n $imgObj->save_image($_SERVER[\"DOCUMENT_ROOT\"] . '/uploads/avatars/' . $logo); \n }\n\n # Set the where condtion to update\n $where_condition = \"WHERE user_id = \".$user_id ;\n\n # Update the database update($table, $data, $where)\n $new_user = DB::instance(DB_NAME)->update('users', $_POST, $where_condition);\n \n # Send to success page if it worked, error if it didn't\n if (count($new_user) == 1){\n Router::redirect(\"/users/profile/\".$_POST['alias'].\"/success\");\n }\n else {\n Router::redirect(\"/users/profile/\");\n $this->template->content->error = \"Something went wrong with the update query. Try again?\";\n }\n }", "title": "" }, { "docid": "b01abe19dce25a1de5fac235422776ee", "score": "0.6365622", "text": "public function edit(AdminUser $adminUser)\n {\n //\n }", "title": "" }, { "docid": "7da5e7727f467f87e48a4146574a519c", "score": "0.6364861", "text": "public function updateUser($id, $email, $pass, $firstname, $lastname, $admin='false') {\r\n\t\t\r\n\t\t//checkeo que password sea mayor a 6 caracteres\r\n\t\tif($this->checkPassword($pass)) {\r\n\t\t\t$updatedUser = new M_User($id, $email, $pass, $firstname, $lastname, $admin);\r\n\r\n\t\t\tif(isset($admin)){\r\n\t\t\t\t$updatedUser->setAdmin($admin);\r\n\t\t\t\t$this->dao->update($updatedUser);\r\n\t\t\t}\r\n\r\n\t\t} else echo \"LA PASSWORD ES MUY CORTA, tiene que tener al menos 6 caracteres\";\r\n\r\n\t\t$this->getAll();\r\n\t}", "title": "" }, { "docid": "6fe34275fe624e6438d87793414d9b06", "score": "0.63443214", "text": "public function update() {\n $query = DB::connection()->prepare('UPDATE Person SET name = :name, username = :username, password = :password, admin = :admin WHERE id = :id');\n $query->execute(array('id' => $this->id, 'name' => $this->name, 'username' => $this->username, 'password' => $this->password, 'admin' => $this->admin));\n }", "title": "" }, { "docid": "92b4af4115d8e81aac07b9339b55fe4d", "score": "0.6341326", "text": "function update($admin_id, $person)\n {\n $this->user_model->update($person['user_id'],$person);\n $admin['name_first']=$person['name_first'];\n $admin['name_last']=$person['name_last'];\n $admin['date_update']=$this->user_model->_get_date_now();\n $admin['status']=$person['status'];\n $this->db->where($this->primary_key,$admin_id);\n $this->db->update($this->table_name,$admin);\n }", "title": "" }, { "docid": "0bc82bac52b36b811cb12f3c681a9b76", "score": "0.63365245", "text": "public function update_user_meta() {\n global $json_api;\n\n $this->_verify_admin();\n $this->_verify_nonce('update_user_meta');\n\n nocache_headers();\n\n if(!isset($_REQUEST['id']))\n $json_api->error(__(\"The user's 'id' must be set.\"));\n\n if(!isset($_REQUEST['key']))\n $json_api->error(__(\"The 'key' must be set.\"));\n\n if(!isset($_REQUEST['value']))\n $json_api->error(__(\"The 'value' must be set.\"));\n\n if(!isset($_REQUEST['prev_value']))\n $prev_value = '';\n else\n $prev_value = $_REQUEST['prev_value'];\n\n if( update_user_meta( $_REQUEST['id'], $_REQUEST['key'], $_REQUEST['value'], $prev_value ) )\n return array( \"message\" => __(\"User meta was updated successfully.\") );\n else\n $json_api->error( __(\"User meta wasn't able to be updated.\") );\n }", "title": "" }, { "docid": "f823b92da326a6839ff305a93d443d6e", "score": "0.63273275", "text": "public function update($data) {\r\n\t\t\t\r\n\t\t\t//should we change the key\r\n\t\t\tif ($data['uPassword'] != null) {\r\n\t\t\t\t\tif ($data['uPassword'] == $data['uPasswordConfirm']) {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t$crypto = Loader::helper(\"crypto\");\r\n\t\t\t\t\t\t$edit_user_uek = $crypto->computeUEK( $data['uPassword'] ); \r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t//get the MEK, via the logged in admin/superuser\r\n\t\t\t\t\t\t$user = new User();\r\n\t\t\t\t\t\t$mek = $user->getMEK();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t//and save it for the user\r\n\t\t\t\t\t\t$edit_user = $this->getUserObject(); \r\n\t\t\t\t\t\t$edit_user->saveMECforUser( $mek, $edit_user_uek );\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//callback to parent for the boring stuff\r\n\t\t\treturn parent::update($data);\r\n\t\t}", "title": "" }, { "docid": "643c20b829ffa5a2d810a4a1d5be78f9", "score": "0.6326928", "text": "public function profile_edit() {\n $_POST = DB::instance(DB_NAME)->sanitize($_POST);\n\n # store current time\n $_POST['modified'] = Time::now();\n\n # Update this profile\n $where_condition = 'WHERE user_id = '.$_POST['user_id'];\n $update = DB::instance(DB_NAME)->update_row('users', $_POST, $where_condition);\n\n # Send them back\n Router::redirect(\"/users/profile\");\n }", "title": "" }, { "docid": "bd4a7f2b3a5570c5474a7d6c3ba01a58", "score": "0.63235277", "text": "function update(){ \n\t\t\t$this->layout='comman';\n\t\t\t$id=$this->Session->read('User.id');\n\t\t\t$details = $this->User->find('first', array('conditions' => array('User.id' => $id)));\n\t\t\t$this->set('userdetail',$details);\n\t\t\tif($this->data){\n\t\t\t\t$this->User->id=$id;\n\t\t\t //unset($this->User->validate['username']);\n\t\t\t if($this->User->save($this->data)){\n\t\t\t\t\t$this->redirect(array('controller'=>'users','action'=>\"profile\"));\t\n\t\t\t\t\t}\t\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t//die('test');\t\n\t\t\t\t\t}\n\t\t\t\t}", "title": "" }, { "docid": "bd3fc6111359a796801242ffc3908ebb", "score": "0.63208675", "text": "protected function check_updated_by_admin($user)\n\t{\n\t\tif ($user->id !== $this->user_id)\n\t\t\t$this->updated_by = $user->username;\n\t}", "title": "" }, { "docid": "c380cfaf2fd9c7dedc9e2341eaf7743d", "score": "0.63149923", "text": "public function update(){\n\t\t$sql = \"update \".self::$tablename.\" set nombre=\\\"$this->nombre\\\",email=\\\"$this->email\\\",username=\\\"$this->username\\\",apellido=\\\"$this->apellido\\\",is_active=\\\"$this->is_active\\\",is_admin=\\\"$this->is_admin\\\" where id=$this->id\";\n\t\tExecutor::doit($sql);\n\t}", "title": "" }, { "docid": "ffd7f061eada44cee0bfdc436bc8de75", "score": "0.63131887", "text": "public function promoteToAdmin()\n {\n $this->admin_flag = 1;\n $this->save();\n }", "title": "" }, { "docid": "08d3dac108a427810d8cb00b9e43e734", "score": "0.63117075", "text": "private function _setNewAdminPassword() {\n\t\tglobal $locale;\n\n\t\t// Only accept if user is admin, updating his profile (not admin panel)\n\t\tif (iADMIN && $this->_method == \"validate_update\" && !$this->isAdminPanel) {\n\n\t\t\tif ($this->_getPasswordInput(\"user_admin_password\") == \"\") {\n\t\t\t\tif ($this->userData['user_admin_password'] == \"\") {\n\t\t\t\t\t$this->_isValidCurrentAdminPassword\t\t\t= true;\n\t\t\t\t\t$showError = false;\n\t\t\t\t} else {\n\t\t\t\t\t$this->_isValidCurrentAdminPassword\t\t\t= false;\n\t\t\t\t\t$showError = true;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$this->_isValidCurrentAdminPassword\t\t\t= $this->_isValidCurrentPassword(false, false);\n\t\t\t\t$showError = true;\n\t\t\t}\n\n\t\t\t//$this->_isValidCurrentAdminPassword\t\t\t\t= $this->_isValidCurrentPassword(false, false);\n\n\t\t\t$this->_newUserAdminPassword \t\t\t\t\t= $this->_getPasswordInput(\"user_new_admin_password\");\n\t\t\t$this->_newUserAdminPassword2 \t\t\t\t\t= $this->_getPasswordInput(\"user_new_admin_password2\");\n\n\t\t\t// Require current password\n\t\t\tif ($this->_isValidCurrentAdminPassword) {\n\t\t\t\t// Require current admin password\n\t\t\t\tif ($this->_isValidCurrentPassword) {\n\t\t\t\t\tif ($this->_userAdminPassword != $this->_userPassword) {\n\t\t\t\t\t\t// Intialize password auth\n\t\t\t\t\t\t$passAuth \t\t\t\t\t\t= new PasswordAuth();\n\t\t\t\t\t\t$passAuth->inputPassword \t\t= $this->_userAdminPassword;\n\t\t\t\t\t\t$passAuth->inputNewPassword\t\t= $this->_newUserAdminPassword;\n\t\t\t\t\t\t$passAuth->inputNewPassword2\t= $this->_newUserAdminPassword2;\n\n\t\t\t\t\t\t// Check admin new password\n\t\t\t\t\t\t$_isValidNewPassword = $passAuth->isValidNewPassword();\n\n\t\t\t\t\t\tif ($_isValidNewPassword === 0) {\n\t\t\t\t\t\t\t// New password is valid\n\t\t\t\t\t\t\t$this->_setDBValue(\"user_admin_algo\", $passAuth->getNewAlgo());\n\t\t\t\t\t\t\t$this->_setDBValue(\"user_admin_salt\", $passAuth->getNewSalt());\n\t\t\t\t\t\t\t$this->_setDBValue(\"user_admin_password\", $passAuth->getNewHash());\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif ($_isValidNewPassword === 1) {\n\t\t\t\t\t\t\t\t// New Password equal old password\n\t\t\t\t\t\t\t\t$this->_setError(\"user_password\", $locale['u144'].$locale['u146'].$locale['u131']);\n\t\t\t\t\t\t\t} elseif ($_isValidNewPassword === 2) {\n\t\t\t\t\t\t\t\t// The two new passwords are not identical\n\t\t\t\t\t\t\t\t$this->_setError(\"user_password\", $locale['u148a']);\n\t\t\t\t\t\t\t} elseif ($_isValidNewPassword === 3) {\n\t\t\t\t\t\t\t\t// New password contains invalid chars / symbols\n\t\t\t\t\t\t\t\t$this->_setError(\"user_password\", $locale['u144'].$locale['u142'].\"<br />\".$locale['u147']);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// New admin password equal Login password\n\t\t\t\t\t\t$this->_setError(\"user_admin_password\", $locale['u144'].$locale['u146'].$locale['u133']);\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t// Current login password is invalid\n\t\t\t\t\t$this->_setError(\"user_admin_password\", $locale['u149b']);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// Current admin password is invalid\n\t\t\t\t$this->_setError(\"user_admin_password\", $locale['u149a'], $showError);\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "50774c8ad2aec7c33a37f9d7bd69c943", "score": "0.63104486", "text": "public function action_addAdmin()\n {\n $modelvar = new Model_MetroUser();\n $modelvar->addUser('Admin','Admin@Admin.com',crypt('Admin'), 'admin');\n\n $this->redirect('index/index');\n }", "title": "" }, { "docid": "9beacf9d86cc3f0257b51eb5fae5156d", "score": "0.630744", "text": "public function ajax_change_admin() {\n $this->autoRender = false;\n $this->loadModel('Group.GroupUser');\n\n if (empty($this->request->data['id']) || empty($this->request->data['type']))\n return;\n\n $this->GroupUser->id = $this->request->data['id'];\n $group_user = $this->GroupUser->findById($this->request->data['id']);\n $admins_list = $this->GroupUser->getUsersList($group_user['GroupUser']['group_id'], GROUP_USER_ADMIN);\n\n $this->_checkPermission(array('admins' => $admins_list));\n $group_user['GroupUser']['status'] = ( $this->request->data['type'] == 'make' ) ? GROUP_USER_ADMIN : GROUP_USER_MEMBER;\n\n $this->GroupUser->save($group_user['GroupUser']);\n\n Cache::delete('admin_count_group_' . $group_user['GroupUser']['group_id'], 'group');\n }", "title": "" }, { "docid": "fa4a11176d6c65aa185cd4f2a6f8766b", "score": "0.6305159", "text": "public function update_user() {\n global $json_api;\n\n if(!isset($_REQUEST['id']))\n $json_api->error(__(\"The user's 'id' must be set.\"));\n\n return $this->create_user();\n }", "title": "" }, { "docid": "20f400f21a3498701d06c4dbb1677a1c", "score": "0.6303579", "text": "public function admin() {\n $date = new Date();\n $usr = new Users();\n $d = array();\n $d = $date->getData();\n $d['Users'] = $usr->getNameList();\n $this->setData($d);\n }", "title": "" }, { "docid": "82f1cbcc6d48154702f2704e24deca6d", "score": "0.6300729", "text": "function changeUser()\n\t{\n\t\tglobal $objSmarty;\n\t\tif($this->chkUser($_REQUEST['txtCurUsr'], $_SESSION['admin_id'])){\n\t\t\t$UpQuery = \"UPDATE `admin` SET `Username` = '\".addslashes($_REQUEST['txtNewUsr']).\"'\" \n\t\t\t\t\t .\" WHERE `Ident` = \". $_SESSION['admin_id'];\n\t\t\t$UpResult\t= $this->ExecuteQuery($UpQuery, \"update\");\n\t\t\t$objSmarty->assign(\"SuccessMessage\", \"Username has been updated successfully\");\n\t\t\t$objSmarty->assign(\"ErrorMessage\", \"\");\n\t\t}else{\n\t\t\t$objSmarty->assign(\"ErrorMessage\", \"Invalid current username\");\n\t\t}\n\t}", "title": "" }, { "docid": "6974e0a264824a7e57d9e57f544d7947", "score": "0.6298699", "text": "function UserAdmin()\n\t{\n\t\t// if we've already worked this out, return it.\n\t\tif (!is_null($this->useradmin)) {\n\t\t\treturn $this->useradmin;\n\t\t}\n\n\t\t$useradmin = false;\n\t\tif ($this->admintype == 'a' || $this->admintype == 'u') {\n\t\t\t$useradmin = true;\n\t\t}\n\t\t$this->useradmin = $useradmin;\n\t\treturn $this->useradmin;\n\t}", "title": "" }, { "docid": "0a07bae21f1831b7d16de9f88bccdc90", "score": "0.62937707", "text": "public function update(){\n Session::access(\"Gerente\");\n\n if(Server::RequestMethod(\"POST\"))\n {\n\t\t\t$_fullId = Server::post(\"full_id\");\t\n\t\t\t$exist = $this->_user->existId(Server::post(\"username\"), $_fullId);\n\t\t\t\n if(!$exist)\n {\n $user = array_shift($this->_user->getUserInfo($_fullId));\n\n //Arreglo con datos para inserción\n $data = array(\n \"id\" => $_fullId,\n \"nombre\" => trim(Server::post(\"full_name\")),\n \"username\" => trim(Server::post(\"username\")),\n \"role\" => Server::post(\"role\"),\n \"correo\" => trim(Server::post(\"correo\")),\n \"status\" => Server::post(\"status\")\n );\n\n //Modificación de datos.\n $result = $this->_user->update($data);\n\n if($result){\n echo json_encode(1); // Usuario creado\n }else {\n echo json_encode(0); // Usuario no ha sido creado\n }\n }\n else\n {\n echo json_encode(2); // Nombre de usuario ya existe\n }\n }else { \n $this->redireccionar(\"error/access/5656\");\n } \n\t\t// $this->redireccionar(\"gestion_usuarios\");\n }", "title": "" }, { "docid": "03b97b5b35e24dca4eb9550fa5e9a57e", "score": "0.62859637", "text": "public function promoteUpdateAction(){\n $helper = $this->get('wchelper');\n $request = $helper->getRequest();\n // get username and role from request\n $username=$request->request->get('username', '');\n $role=$request->request->get('role', '');\n echo $username. \" \" . $role;\n $helper->setUserRole($username, $role);\n\n // Nothing to return really\n return new Response();\n }", "title": "" }, { "docid": "16d725f9ae077e1b9c502e65833d46c1", "score": "0.6285375", "text": "public function adminUser()\n {\n $adminUserList = New Permission();\n $adminUserList->name = 'adminuser.list';\n $adminUserList->display_name = '后台用户列表';\n $adminUserList->description = '后台用户列表';\n $adminUserList->save();\n\n $adminUserAdd = New Permission();\n $adminUserAdd->name = 'adminuser.add';\n $adminUserAdd->display_name = '添加后台用户';\n $adminUserAdd->description = '添加后台用户';\n $adminUserAdd->save();\n\n $adminUserEdit = New Permission();\n $adminUserEdit->name = 'adminuser.edit';\n $adminUserEdit->display_name = '修改后台用户';\n $adminUserEdit->description = '修改后台用户';\n $adminUserEdit->save();\n\n $adminUserDelete = New Permission();\n $adminUserDelete->name = 'adminuser.delete';\n $adminUserDelete->display_name = '删除后台用户';\n $adminUserDelete->description = '删除后台用户';\n $adminUserDelete->save();\n }", "title": "" }, { "docid": "4f77c2874eb2e95ad23fd5319ffe8931", "score": "0.62773657", "text": "public function update(Request $request)\n {\n\n $admin = Admin::where('id', $request->id)->first();\n $admin->username = $request->username;\n $admin->password = $request->password;\n $admin->save();\n\n }", "title": "" }, { "docid": "c463a3c4577ca676fe87ed7c8fdd1c42", "score": "0.62751883", "text": "public function modify() {\n session_set_cookie_params(['lifetime' => 0, 'path' => '/m3104_24', 'domain' => '', 'secure' => false, 'httponly' => false, 'samesite' => '']);\n session_start();\n\n //Met à jour la table de l'utilisateur\n $email = $_SESSION['email'];\n $dbc = SqliteConnection::getInstance()->getConnection();\n $query = \"Select * From User Where email = :email\";\n $stmt = $dbc->prepare($query);\n $stmt->bindValue(':email', $email, PDO::PARAM_STR);\n $stmt->execute();\n $user = $stmt->fetchAll(PDO::FETCH_CLASS, 'User')[0];\n $user->init($email, $user->getPassword(), htmlspecialchars($_POST[\"lname\"]), htmlspecialchars($_POST[\"fname\"]), htmlspecialchars($_POST[\"bdate\"]), htmlspecialchars($_POST[\"gender\"]), htmlspecialchars($_POST[\"height\"]), htmlspecialchars($_POST[\"weight\"]));\n //Mise à jour des variables de session\n $_SESSION[\"lname\"] = htmlspecialchars($_POST[\"lname\"]);\n $_SESSION[\"fname\"] = htmlspecialchars($_POST[\"fname\"]);\n $_SESSION[\"gender\"] = htmlspecialchars($_POST[\"gender\"]);\n $_SESSION[\"bdate\"] = htmlspecialchars($_POST[\"bdate\"]);\n $_SESSION[\"height\"] = htmlspecialchars($_POST[\"height\"]);\n $_SESSION[\"weight\"] = htmlspecialchars($_POST[\"weight\"]);\n\n $UserDAO = UserDAO::getInstance();\n $UserDAO->update($user);\n ?>\n <script type=\"text/javascript\">\n window.location.href = '../?page=profile&msg=Changes%20have%20been%20saved.&color=%2300fc0080';\n </script>\n <?php\n }", "title": "" }, { "docid": "3d32d6bac75014807bd6704f2adbbed4", "score": "0.6271774", "text": "public function update(UserUpdateRequest $request)\n {\n if ($request->has('welcome_completed')) {\n if ($request->welcome_completed === true) {\n $user = auth()->user();\n if (count($user->sourceProviders) > 0 && count($user->serverProviders) > 0) {\n $user->welcome_completed = true;\n $user->save();\n }\n }\n }\n }", "title": "" }, { "docid": "fe4c133fe26b116c0ea155c1279182ff", "score": "0.62607294", "text": "public function actionAdmin()\n\t{ \n\t\t$this->render('user_admin');\n\t}", "title": "" }, { "docid": "d1ed709c0ce93e5d4dfb1b2748dbf28a", "score": "0.6259482", "text": "function modifica_admin_usuario( $id ) {\n\t\t// realiza la actualizaci�n definitiva\n\t\t$actualiza = array(\n\t\t\t'Nombre'\t=> $this->input->post('nombre'),\n\t\t\t'Paterno'\t=> $this->input->post('paterno'),\n\t\t\t'Materno'\t=> $this->input->post('materno'),\n\t\t\t'Correo'\t=> $this->input->post('correo'),\n\t\t\t'Usuario'\t=> $this->input->post('usuario'),\n\t\t);\n\n\t\tif( $this->input->post('mod_contrasena') ) {\n\t\t\t$actualiza['Contrasena'] = $this->input->post('contrasena');\n\t\t}\n\n\t\t$this->db->where( 'IdUsuario', $id );\n\t\t$resp = $this->db->update( 'ab_usuarios', $actualiza );\n\n\t\treturn $resp;\n\t}", "title": "" }, { "docid": "490223c27cae4c18f3b4ce4f2c3ea86b", "score": "0.6255505", "text": "public function updateUser()\n {\n// $query = \"UPDATE `users` SET\n// `email` = :email,\n// `userPassword` = :password,\n// `ACL` = :acl,\n// `lastLoginDate` = :lastLoginDate\n// WHERE `username` = :username\";\n//\n// $email\t\t\t= $this->getEmail();\n// $password\t\t= $this->getPassword();\n// $acl\t\t\t= $this->getAccessLevel();\n// $lastLoginDate\t= $this->getlastLogin();\n// $username\t\t= $this->getUsername();\n//\n//\n// $resultSet = $this->database->prepare($query);\n// $resultSet->bindParam(':email'\t\t\t,\t$email\t\t\t, PDO::PARAM_STR);\n// $resultSet->bindParam(':password'\t\t,\t$password\t\t, PDO::PARAM_STR);\n// $resultSet->bindParam(':acl'\t\t\t, \t$acl\t\t\t, PDO::PARAM_INT);\n// $resultSet->bindParam(':lastLoginDate'\t,\t$lastLoginDate\t, PDO::PARAM_STR);\n// $resultSet->bindParam(':username'\t\t, \t$username\t\t, PDO::PARAM_STR);\n//\n// try {\n// $resultSet->execute();\n// } catch (Exception $e) {\n// return \"Something went wrong\";\n// }\n\n if ($this->save()) {\n return \"Updated\";\n } else {\n return \"Something went wrong\";\n }\n\n\n }", "title": "" }, { "docid": "8a876c787857756554076c1a822f420e", "score": "0.6254558", "text": "public function updateUser($params = null) {\n $id=$params[':ID'];\n $bool=$params[':BOOL'];\n $user=$this->helper->getLoggedUser();\n if($user['USER_TYPE']){\n $this->model->updatePermiso($id,$bool);\n header(\"Location: \".BASE_URL.\"users\");\n }\n }", "title": "" }, { "docid": "6312790a94bc9dd38e7f087a2799c030", "score": "0.62540805", "text": "public function upd_user(){\n $this->load->database();\n $this->load->model('basic');\n // loding database library, because we need to run queries below and configs are already written\n\n // dumping sql\n $dump_file_name = 'initial_db.sql';\n $dump_sql_path = 'assets/backup_db/'.$dump_file_name;\n $this->basic->import_dump($dump_sql_path);\n // dumping sql\n\n //Accept and change the default password ion_auth\n $app_username = addslashes(strip_tags($this->input->post('app_username', true)));\n $app_password = addslashes(strip_tags($this->input->post('app_password', true)));\n \n $this->load->library(array('ion_auth', 'form_validation'));\n \n $data = array(\n 'password' => $app_password,\n 'username' => $app_username,\n );\n \n $this->ion_auth->update('1', $data);\n \n //deleting the install.txt file,because installation is complete\n if (file_exists('install.txt')) {\n unlink('install.txt');\n }\n //deleting the install.txt file,because installation is complete\n redirect(base_url('install/installcomplite'));\n \n }", "title": "" }, { "docid": "fab29b83e583d75358b630ae4d6316db", "score": "0.6252065", "text": "public function updDataUser() {\n $d_user = new DataUser($this->registry);\n if (isset($_POST['upd_d_user'])) {\n $kd_d_user = $_POST['kd_d_user'];\n $kd_r_jenis = $_POST['kd_r_jenis'];\n $kd_r_unit = $_POST['kd_r_unit'];\n $nama_user = $_POST['nama_user'];\n $pass_user = $_POST['pass_user'];\n $d_user->set_kd_d_user($kd_d_user);\n $d_user->set_kd_r_jenis($kd_r_jenis);\n $d_user->set_kd_r_unit($kd_r_unit);\n $d_user->set_nama_user($nama_user);\n $d_user->set_pass_user($pass_user);\n if (!$d_user->update_d_user()) {\n $this->view->d_ubah = $d_user;\n $this->view->error = $d_user->get_error();\n $this->view->data = $d_user->get_d_user();\n $this->view->render('admin/dataUser');\n } else {\n header('location:' . URL . 'dataUser/addDataUser');\n }\n }\n }", "title": "" }, { "docid": "acf898a851926b184af84f825d2eb062", "score": "0.62510747", "text": "public function helphub_profile_edits() {\n\t\t// Don't process anything if the post actions are invalid.\n\t\tif ( ! isset( $_POST['action'] ) || 'helphub-update-user' !== $_POST['action'] ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Get the displayed user ID.\n\t\t$user_id = bbp_get_displayed_user_id();\n\n\t\t// Ensure the proper user capabilities exist for changing user details.\n\t\tif ( ! current_user_can( 'manage_helphub' ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Double-check that nobody is trying to edit their own user.\n\t\tif ( get_current_user_id() === $user_id ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Check that the nonce is valid.\n\t\tif ( ! wp_verify_nonce( $_POST['_helphub_manage'], 'helphub-change-user-role-' . $user_id ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Make sure the new role is a HelpHub one, or is being reset to nothing.\n\t\t$roles = $this->get_helphub_roles();\n\t\tif ( ! empty( $_POST['role'] ) && ! isset( $roles[ $_POST['role'] ] ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\t$user_forum_role = bbp_get_user_role( $user_id );\n\n\t\t$user = new stdClass();\n\n\t\t$user->ID = (int) $user_id;\n\t\t$user->role = $_POST['role'];\n\n\t\t$edit_user = wp_update_user( $user );\n\n\t\t// Updating a user resets the forum role, so let's explicitly update that.\n\t\tbbp_set_user_role( $user_id, $user_forum_role );\n\n\t\t// Error(s) editng the user, so copy them into the global.\n\t\tif ( is_wp_error( $edit_user ) ) {\n\t\t\tbbpress()->errors = $edit_user;\n\n\t\t\t// Successful edit to redirect.\n\t\t} elseif ( is_integer( $edit_user ) ) {\n\t\t\t$redirect = add_query_arg( array( 'updated' => 'true' ), bbp_get_user_profile_url( $edit_user ) );\n\n\t\t\twp_safe_redirect( $redirect );\n\t\t\texit;\n\t\t}\n\t}", "title": "" }, { "docid": "77eec79202dc370346abe06dd847c1ac", "score": "0.62496537", "text": "private function change_admin_user( $username = null, $id = false ) {\r\n\r\n\t\tglobal $wpdb;\r\n\r\n\t\tif ( ITSEC_Lib::get_lock( 'admin_user', 180 ) ) { //make sure it isn't already running\r\n\r\n\t\t\t//sanitize the username\r\n\t\t\t$new_user = sanitize_text_field( $username );\r\n\r\n\t\t\t//Get the full user object\r\n\t\t\t$user_object = get_user_by( 'id', '1' );\r\n\r\n\t\t\tif ( ! is_null( $username ) && validate_username( $new_user ) && false === username_exists( $new_user ) ) { //there is a valid username to change\r\n\r\n\t\t\t\tif ( $id === true ) { //we're changing the id too so we'll set the username\r\n\r\n\t\t\t\t\t$user_login = $new_user;\r\n\r\n\t\t\t\t} else { // we're only changing the username\r\n\r\n\t\t\t\t\t//query main user table\r\n\t\t\t\t\t$wpdb->query( $wpdb->prepare( \"UPDATE `{$wpdb->users}` SET user_login = %s WHERE user_login = %s\", $new_user, 'admin' ) );\r\n\r\n\t\t\t\t\tif ( is_multisite() ) { //process sitemeta if we're in a multi-site situation\r\n\r\n\t\t\t\t\t\t$old_admins = $wpdb->get_var( \"SELECT meta_value FROM `\" . $wpdb->sitemeta . \"` WHERE meta_key = 'site_admins'\" );\r\n\t\t\t\t\t\t// No need to escape the new username. It is already safe via validate_userame() which will check for quotes\r\n\t\t\t\t\t\t$new_admins = str_replace( '5:\"admin\"', strlen( $new_user ) . ':\"' . $new_user . '\"', $old_admins );\r\n\t\t\t\t\t\t$wpdb->query( $wpdb->prepare( \"UPDATE `{$wpdb->sitemeta}` SET meta_value = %s WHERE meta_key = 'site_admins'\", $new_admins ) );\r\n\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tITSEC_Lib::release_lock( 'admin_user' );\r\n\r\n\t\t\t\t\treturn true;\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t} elseif ( $username !== null ) { //username didn't validate\r\n\t\t\t\tITSEC_Lib::release_lock( 'admin_user' );\r\n\r\n\t\t\t\treturn false;\r\n\r\n\t\t\t} else { //only changing the id\r\n\r\n\t\t\t\t$user_login = $user_object->user_login;\r\n\r\n\t\t\t}\r\n\r\n\t\t\tif ( $id === true ) { //change the user id\r\n\r\n\t\t\t\t$wpdb->query( \"DELETE FROM `\" . $wpdb->users . \"` WHERE ID = 1;\" );\r\n\r\n\t\t\t\t$wpdb->insert( $wpdb->users, array(\r\n\t\t\t\t\t'user_login' => $user_login, 'user_pass' => $user_object->user_pass,\r\n\t\t\t\t\t'user_nicename' => $user_object->user_nicename, 'user_email' => $user_object->user_email,\r\n\t\t\t\t\t'user_url' => $user_object->user_url, 'user_registered' => $user_object->user_registered,\r\n\t\t\t\t\t'user_activation_key' => $user_object->user_activation_key,\r\n\t\t\t\t\t'user_status' => $user_object->user_status, 'display_name' => $user_object->display_name\r\n\t\t\t\t) );\r\n\r\n\t\t\t\tif ( is_multisite() && $username !== null && validate_username( $new_user ) ) { //process sitemeta if we're in a multi-site situation\r\n\r\n\t\t\t\t\t$old_admins = $wpdb->get_var( \"SELECT meta_value FROM `{$wpdb->sitemeta}` WHERE meta_key = 'site_admins'\" );\r\n\t\t\t\t\t// No need to escape the new username. It is already safe via validate_userame() which will check for quotes\r\n\t\t\t\t\t$new_admins = str_replace( '5:\"admin\"', strlen( $new_user ) . ':\"' . $new_user . '\"', $old_admins );\r\n\t\t\t\t\t$wpdb->query( $wpdb->prepare( \"UPDATE `{$wpdb->sitemeta}` SET meta_value = %s WHERE meta_key = 'site_admins'\", $new_admins ) );\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$new_user = $wpdb->insert_id;\r\n\r\n\t\t\t\t$wpdb->query( $wpdb->prepare( \"UPDATE {$wpdb->posts} SET post_author = %d WHERE post_author = 1\", $new_user ) );\r\n\t\t\t\t$wpdb->query( $wpdb->prepare( \"UPDATE {$wpdb->usermeta} SET user_id = %d WHERE user_id = 1\", $new_user ) );\r\n\t\t\t\t$wpdb->query( $wpdb->prepare( \"UPDATE {$wpdb->comments} SET user_id = %d WHERE user_id = 1\", $new_user ) );\r\n\t\t\t\t$wpdb->query( $wpdb->prepare( \"UPDATE {$wpdb->links} SET link_owner = %d WHERE link_owner = 1\", $new_user ) );\r\n\r\n\t\t\t\t/**\r\n\t\t\t\t * Fires when the admin user with id of #1 has been changed.\r\n\t\t\t\t *\r\n\t\t\t\t * @since 6.3.0\r\n\t\t\t\t *\r\n\t\t\t\t * @param int $new_user The new user's ID.\r\n\t\t\t\t */\r\n\t\t\t\tdo_action( 'itsec_change_admin_user_id', $new_user );\r\n\r\n\t\t\t\tITSEC_Lib::release_lock( 'admin_user' );\r\n\r\n\t\t\t\treturn true;\r\n\r\n\t\t\t}\r\n\r\n\t\t}\r\n\r\n\t\treturn false;\r\n\r\n\t}", "title": "" }, { "docid": "6b926c8c0fd1750a540feb1c80c513fa", "score": "0.62493503", "text": "public function updateAdmin(Request $request)\n {\n $data_to_update = [];\n if($request->has('name'))\n $data_to_update['name'] = $request->name;\n if($request->has('email'))\n $data_to_update['email'] = $request->email;\n if(count($data_to_update) > 0)\n $this->user()->update($data_to_update);\n\n if($request->has('password'))\n $this->update(['password' => bcrypt($request->password)]);\n return true;\n }", "title": "" }, { "docid": "d3b05b345af888f5917850c5ff6b1c1e", "score": "0.62409675", "text": "function editUser($id,$username,$password,$email){\n$pdo = Database::getInstance()->getConnection(); \n// TODO:Run the proper SQL query to update tbl_user with proper values\n$update_user_data = 'UPDATE tbl_user SET user_name=:username, password =:password, email = :email, count=count+1 WHERE id =:id';\n$update_user_set = $pdo->prepare($update_user_data);\n$update_user_result = $update_user_set->execute(\n array(\n ':id' => $id,\n ':username' => $username ,\n ':password' => $password,\n ':email' => $email\n )\n );\n\n // echo $update_user_set ->debugDumpParams();\n // exit;\n \n\n// TODO:if everything goes well, redirect user to index.php\n// Otherwise, return some error message\n if($update_user_result){\n redirect_to('admin_login.php');\n }else{\n return ' wrong';\n }\n\n}", "title": "" }, { "docid": "98e71bf9fcac64ea127d08ce99e82402", "score": "0.62394875", "text": "public function upgradeuser($id) {\n\t\t$id = mysqli_real_escape_string($this->mysqli, $id);\n $resultado = $this->mysqli->query(\"UPDATE usuarios SET privileges = 'admin' WHERE id = $id\");\n \n echo \"<script type='text/javascript'>\n\t\t\twindow.location='\". Conexion::ruta() .\"?action=usuarios';\n\t\t\t</script>\";\n }", "title": "" }, { "docid": "f27f929481ee825410180d17a7e2dea3", "score": "0.62345415", "text": "public function updateUserAccountSettings()\n {\n # PUT /accounts/{accountId}/users/{userId}/settings\n }", "title": "" }, { "docid": "955c475dc769ac38b205ff403ef1a047", "score": "0.62272954", "text": "public function update()\n {\n PermissionCheck::auth('is_admin');\n PermissionCheck::auth('allow_edit_employees');\n\n $pr = new PasswordReset($this->props->id);\n $pr->process();\n\n $this->status->echo();\n }", "title": "" }, { "docid": "23076c956c62c12dfaa08f028a4244ce", "score": "0.62249076", "text": "public function updateAdminLoginStatus($UserId, $updateData) {\r\n $this->db->where('AdminId', $UserId);\r\n $this->db->update($this->AdminTbl, $updateData);\r\n }", "title": "" }, { "docid": "204453675e7372f73aa23575e15511d1", "score": "0.62242514", "text": "public function update(admin $user)\n {\n return $this->getPermission($user, 3);\n }", "title": "" }, { "docid": "7c666fa6948fe17f90aa172faac77009", "score": "0.6213037", "text": "public function update(User $user)\n {\n return $user->admin === \"oui\";\n }", "title": "" } ]